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
U4-11168 : Making the dropdown menu more user friendly within the Document Type icon picker #2555
Conversation
Getting latest changes
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.
Thanks @OwainWilliams - I understand the thought behind this but unfortunately it becomes a bit of an unreadable mess. I think it would be way better to have each color represented as a square in front of it's name, like the way Chrome does it for example:
Any chance you can look into doing that instead?
Hi @nul800sebastiaan |
I agree it should use a different approach than changing the text color of the options. Something like Github label colors: An option could be to use the Alternatively it could use a third party component like Selectize https://selectize.github.io/selectize.js/ (or another component (Angular/jQuery/javascript) extending the navtive dropdownlist, which allow to have custom labels like these https://tabler.github.io/tabler/form-elements.html (based on Selectize). Maybe @madsrasmussen has some input on this? 😉 🦄 |
I think it is a great idea to add the colored box next to the label instead of coloring the label itself. As far as I remember the umbDropdown component should be able to do what you are looking for. You might need to set a max-height on the drop-down element though to allow scrolling. |
A few other ideas could be to list the defined colors and act like a radiobutton list http://prplv.me/ngjs-color-picker/#/ or some kind of dialog (e.g. by using the Some other inspiration: http://daxushequ.com/color-picker/60376804.html |
Oh nice! Yes, no need for it to be a dropdown, the color names are not actually used anywhere else anyway. |
Brilliant - love the ideas. I'll have a look and see what I can come up with over the coming days. |
Thinking about implementing something like this: https://codepen.io/richiksc/pen/dovpyB Alternatively, why even limit the user to the colours they can pick. Just give them a colour picker with an droplet picker e.g. https://codepen.io/Wardee-IDUK/pen/zqyWWg |
I found these two color/swactch pickers, which are simple, yet pretty awesome. Alternatively there is a swatch picker like this. I think it is fine to limit the colors to some predefined colors for consistency. I like all these three examples. @madsrasmussen any thoughts on these examples? should we have a "swatch picker" component like this in core? Maybe to be re-useable in prevalue editors and property editors? |
Nice @bjarnef - I've got some free time next week so I plan to jump back on to this. 👍 |
Found the solution I'm going to try and implement - unless others have better ideas: |
Replacing color drop down with colour pickers
@OwainWilliams I haven't looked code, but your screenshots look awesome 👍 One tiny detail I've noticed is that the rounded corners (border radius) may be a little too much compared to other components in Umbraco. Umbraco appears to be using a border radius of 3 pixels - eg: I'll look forward to seeing this in the core ;) |
@OwainWilliams I think it would be great to create a array of objects for the colors and then use ng-repeat and ng-model It would also be great to create it as a directive, so it could be re-used e.g. as a property editor or a prevalue editor editor, incl. in grid editor settings/styles config. |
Changed the order of the colours and also took the drop shadow off the buttons. Put a grey border around the active button instead.
Hit problems with pull requests overwriting the original changes!
removing files that shouldn't be part of my PR and updating my gitignore file.
Missed a file
Missed a file
removing ngjs-color-picker.js as it's now not used.
Note: when we get to this PR, we'll also incorporate the sorting of the colors as requested in #2657 |
WIP - Add basic color swatches directive
Any suggestions on how to fix the conflict? |
@OwainWilliams if you merge the branches in e.g. SourceTree you can choose something like "Use Mine", "Use Theirs" or "Merge using external" tool. I use Beyond Compare as a compare/merge tool, but WinMerge should work as well and is free to use. |
WIP - Add basic color swatches directive
@bjarnef It's strange because my local repo says there are no conflicts. |
@OwainWilliams it seems from what I can see in the changes it removes this file. |
So, maybe take this file out of the ignore file? |
Yes, I think. This isn't necessary to add for this PR: and I guess you could revert this change or merge this part from |
Agggh! This is totally bust now. Going to need to look at reverting everything I think to a previous verison. |
@OwainWilliams Hold on, relax, we can look at it. :) |
Cheers @nul800sebastiaan - I'll wait but if you need me to do anything, let me know. |
@OwainWilliams Alright mate, had a bit of a look and indeed it's a bit of a mess! 🙈 Not to worry though. Let's just start over. The easiest thing for you to do now is to create a fresh clone of your fork in a different directory than your current clone. You'll end up with Make sure to fetch the changes from the main repository, there's a few commands listed here that will help you get the latest changed from Then you can create a new branch from I see that in the process, you've deleted all kinds of files and updated Note that I've recently merged a PR that affects your changes as well: #2712 Another thing I noticed in your changes is that you've collapsed some of the We process and minify less files during the grunt build already. 😄 I'll close this one for now. I think starting fresh with all the knowledge we have from the discussions above is going to make it very easy to implement this feature easily now by just copy/pasting the changes over! Great work so far Owain, I tested out the changes earlier and they work wonderfully. So once you can submit a new PR, we'll be able to merge them in pretty quickly. Good times! 🎉 |
Oh and it would be good of you re-order the colors a little, as suggested in #2657 ! |
Cheers for the feedback! I'll see if I can get on to this at lunch time and over the weekend. All makes sense. 👍 |
No description provided.