-
Notifications
You must be signed in to change notification settings - Fork 2
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
Feature/#176 tooltips #180
Conversation
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
Test summaryRun details
View run in Cypress Dashboard ➡️ Failures are unavailable for this run. For more information, see the Cypress Dashboard This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very good job, only had some small comments :)
And very nice that you knew about sveltestrap tooltips!
<svg height="48" width="48" xmlns="http://www.w3.org/2000/svg" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also introduced a new icon for grounding 😆. Yours looks very good as well, guess we'll have to decide which one we'll take while merging.
@@ -29,12 +29,13 @@ | |||
"prettier": "2.8.0", | |||
"prettier-plugin-svelte": "^2.8.1", | |||
"sass": "^1.56.2", | |||
"svelte": "^3.52.0", | |||
"svelte": "^3.55.1", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a question. Does sveltestrap require/prefer a newer version of svelte or why did you update?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the feedback!
It automaticallly updated when installing sveltestrap
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we currently even have a mechanism like dependabot that regularly checks the version of our dependencies?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
None that I know of
offsetY -= baseOffset; | ||
<div> | ||
<button | ||
id="btn-distribute" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Saw in sveltestrap that you can also use bind:this
to specify the tooltip's target. Would imo look cleaner (especially when looking at the website in "Inspect" mode since there is no unnecessary id
visible). Would this be too much of a change or can you adjust this?
Additionally, if you decide on keeping the id
, does sveltestrap require button to be written as btn
? Cause if it doesn't, I'd much prefer it to be written out to stay consistent with the rest of the code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes but then we need additional variables on which we bind the buttons that we would not need elsewise. I changed it anyways.
if ($channelActivated[index]) { | ||
$offsetAdjustment[index] = offsetY; | ||
offsetY -= baseOffset; | ||
<div> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right. Removed the divs.
<div> | ||
<button | ||
id="btn-gnd" | ||
class="icon-button mui-icon--drop-down" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already adapted in #171, so you can decide if you want to keep it like this till the merge. This is the ground/gnd button, not drop-down
.
<Tooltip target="btn-onoff" placement="bottom" | ||
>{TOOLTIP_BUTTON_OFFOFF_BASE}{$osciEnabled | ||
? TOOLTIP_BUTTON_OFFOFF_OFF | ||
: TOOLTIP_BUTTON_OFFOFF_ON}</Tooltip |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this correctly linted?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably not :)
I will check it.
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please run the linter over it. At least two files (which you have not touched yourself) are changed for me. ChannelConfigControlPanel.svelte
and ChannelConfigPopup.svelte
At least Reset and Distribute should be described even more precisely.
{TOOLTIP_BUTTON_OFFOFF_BASE}{$osciEnabled | ||
? TOOLTIP_BUTTON_OFFOFF_OFF | ||
: TOOLTIP_BUTTON_OFFOFF_ON} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really want three labels for this?
Wouldn't one be good enough? And even if we want to describe the state, two labels would be fine instead of putting the two states together from three labels.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed it to two.
@@ -29,12 +29,13 @@ | |||
"prettier": "2.8.0", | |||
"prettier-plugin-svelte": "^2.8.1", | |||
"sass": "^1.56.2", | |||
"svelte": "^3.52.0", | |||
"svelte": "^3.55.1", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we currently even have a mechanism like dependabot that regularly checks the version of our dependencies?
Apps/frontend/src/labels.js
Outdated
export const TOOLTIP_BUTTON_DISTRIBUTE = "Distribute"; | ||
export const TOOLTIP_BUTTON_RESET = "Reset"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe a little more descriptive labels. Especially the ones that should contain a bit more information. What is distributed? What is reset?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't reset self-explanatory, what text would you prefer elsewise?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think so. After all, it doesn't reset everything like the sliders, for example. Maybe you should write "Cleans the canvas and stops plotting"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, sounds good. I'll change the label text :)
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The cypress tests are not going through.
Signed-off-by: nicolaskolbenschlag <nicolas.kolbenschlag@googlemail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look good, the only thing I don't quite like are the extensively long tooltips for distribute and reset. I would've simply written "Distribute vertically" (/"Distribute") and "Reset channels" (/"Reset"). But that's only my opinion :)
Edit: Saw that you just changed it, do you have an opinion what you'd prefer?
Moreover, I for some reason have a problem with white and dark mode on this branch, but I don't know where those stem from. Might actually be related to your problems in #171. We can/should look into it next sprint.
Thank you for the feedback. |
No description provided.