-
-
Notifications
You must be signed in to change notification settings - Fork 82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Web UI: Rework the Attach Device section to be universal #1393
Conversation
d1248fc
to
66545e2
Compare
51f9157
to
6f65f24
Compare
@rdmark Yes, the SAHD type is offered now. What confuses me is that an image file is displayed for "SCHD", but not for any other drive. In the "Attach Device" section I would expect no image files to be attached by default. |
@uweseimet The SCHD device cannot be attached without specifying an image file, can it? That’s why I filtered out the “None” option for it. If SAHD was a known device type I’d do the same for it. Thanks for the German localization suggestions. I’ll get them pushed to the branch later. (In fact, I'll do that in a later PR, since translating new strings require regenerating the po file which adds a lot of noise to the changeset.) |
@rdmark Yes, you have to provide an image file for SCHD, but I'm not sure whether the UI should suggest one. From all the image files I have in my folder, it suggests most likely one I am not interested in. IMO some kind of a placeholder would be better, if technically possible. The UI might say in the color red "Select an image file", for instance. |
@uweseimet I like the idea of having the default selected item being something like "Choose an image file". This change has been pushed now, alongside a number of small improvements. For the removable drive types, I still want to allow attaching them without specifying an image file. This is a handy workflow when when you want prepare for inserting an image after booting the host system, or preparing a set of devices to be saved as a default configuration. The logic for creating the list of images to suggest for a particular device type is:
So basically, the first matching file alphabetically gets suggested by default. |
@rdmark Sure, SCRM is a different case. I was just referring to SCHD. I will have a look at the changes later. |
@rdmark I noticed that for SCRM you also ask the user for choosing an image file. Maybe this should better say "Optionally choose an image file" or something similar? Otherwise it's not clear for the user that you can simply proceed without attaching a file yet. |
@uweseimet I pushed a change now that I think makes for an intuitive form UI. For non-removable disk drives, it should now default to a greyed-out image file selection, and with html5 form validation in place that forces you to choose a file. For removable disk drives, the default "None" selection should signal that you can attach without an image file, I think. |
@rdmark I cannot confirm that, I'm afraid, see screenshot. There is nothing greyed out. It would also be nice if there was some kind of alignment for "Identify as:", "Image file:" and so on. |
@uweseimet You seem to not be running the very latest code there. You may have to force the web UI to restart. I agree that the alignment is a bit messy right now. Let me think about how to make it cleaner. However there is only so much you can with the nesting of web forms and tables, while also making it work on very old browsers running on vintage computers. Regarding translations, our process right now is to ask for community members to translate 2 weeks before we plan to tag a release. Web UI strings are often in flux as we're adding and refining features. |
@rdmark It's strange, now still nothing is greyed out, but SAHD is listed as "Unknown fixed disk drive". How do you know that it is a fixed disk drive? It could be anything. In case you derive this from "HD" at the end: The UI should not try to be too smart. This can backfire ;-). |
@uweseimet If you expand the dropdowns you should be able to see that the "Choose a file" option is greyed out. (It's up to the browser how it wants to render the
I know by asking piscsi if the device is |
46a9dd7
to
e1278f8
Compare
I pushed a small css style update that adds a width style to the attach device dropdowns, so that they line up under most circumstances. Tested that it looks good on my iPhone as well. |
SonarCloud Quality Gate failed. 0 Bugs 0.0% Coverage Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
Are you sure? Neither Firefox nor Chrome, the latter having the biggest market share by far, grey it out on my machine.
This may work, indeed. |
* Correct German translation for Key * Web UI: Rework the Attach Device section to be universal * Web UI: Warn when working dirs are missing * Refactor tests to use global endpoint constants * Add fallback for unknown disk type devices * Rearrange the index page sections * Move Macproxy help text to admins page * Remove image list exception for SCHD * Show Settings button when auth is diabled * Tweak CSS styles for both themes * Move Eject action next to the file name, and improve UI labels
What was known as the "Attach Peripheral Device" has been reworked as "Attach Device" and now lists all devices that the piscsi backend can support. As part of this change, Attach Device has been reimagined as the primary way one would attach a disk image as well, and moved up above the Image Management section.