Skip to content

Hide colors from icon picker#13079

Merged
mikecp merged 5 commits intoumbraco:v11/contribfrom
bjarnef:v10/feature/icon-picker-swatches
Jan 7, 2023
Merged

Hide colors from icon picker#13079
mikecp merged 5 commits intoumbraco:v11/contribfrom
bjarnef:v10/feature/icon-picker-swatches

Conversation

@bjarnef
Copy link
Copy Markdown
Contributor

@bjarnef bjarnef commented Sep 29, 2022

Prerequisites

  • I have added steps to test this contribution in the description below

Description

I noticed it wasn't possible to hide colors from icon picker infinite editor. Sometimes when using this in custom property editors etc. one may not need the colors, just a icon to select.

I also noticed it "jumped" a bit on icon selection, because it add a 1px border (so it need to 1px transparent border by default - or something else to compensate the 1px solid border on selection.

Furthermore it seems the icons didn't align well for different sizes of overlay. While it may work in small overlay, it would be difficult to adjust correct for medium and large overlays also.

I have replaced this with CSS grid instead with fill the icons to its container, a bit gap between and minimum 70px 60px width for each icon. auto-fill fill the container, while I noticed auto-fit would stretch the icon to full width when filtering for instance "umbraco".

chrome_HGomCJuKDr.mp4

I have attached the dashboard from the video above: MyDashboard.zip

@github-actions
Copy link
Copy Markdown

github-actions bot commented Sep 29, 2022

Hi there @bjarnef, thank you for this contribution! 👍

While we wait for one of the Core Collaborators team to have a look at your work, we wanted to let you know about that we have a checklist for some of the things we will consider during review:

  • It's clear what problem this is solving, there's a connected issue or a description of what the changes do and how to test them
  • The automated tests all pass (see "Checks" tab on this PR)
  • The level of security for this contribution is the same or improved
  • The level of performance for this contribution is the same or improved
  • Avoids creating breaking changes; note that behavioral changes might also be perceived as breaking
  • If this is a new feature, Umbraco HQ provided guidance on the implementation beforehand
  • 💡 The contribution looks original and the contributor is presumably allowed to share it

Don't worry if you got something wrong. We like to think of a pull request as the start of a conversation, we're happy to provide guidance on improving your contribution.

If you realize that you might want to make some changes then you can do that by adding new commits to the branch you created for this work and pushing new commits. They should then automatically show up as updates to this pull request.

Thanks, from your friendly Umbraco GitHub bot 🤖 🙂

@bjarnef bjarnef changed the title Hide icon picker colors Hide colors from icon picker Sep 29, 2022
@bjarnef
Copy link
Copy Markdown
Contributor Author

bjarnef commented Sep 29, 2022

The current icon picker.

Small

image

Medium

image

Large

image

@bjarnef
Copy link
Copy Markdown
Contributor Author

bjarnef commented Sep 29, 2022

With changes in this PR.

Small

image

Medium

image

Large

image

@nul800sebastiaan nul800sebastiaan changed the base branch from v10/contrib to v11/contrib October 25, 2022 13:01
@bjarnef
Copy link
Copy Markdown
Contributor Author

bjarnef commented Jan 6, 2023

@mikecp any chance you can review this one. It would be great to be able to hide colors ... and the icons are much better aligned in large overlay.

@mikecp
Copy link
Copy Markdown
Contributor

mikecp commented Jan 6, 2023

Hi @bjarnef ,
Sure, I'll have a look at it tonight or over the week-end. Thanks for the reminder 😉

@mikecp
Copy link
Copy Markdown
Contributor

mikecp commented Jan 7, 2023

Hi @bjarnef ,

Thanks for this PR, I checked and tested it and it works perfectly 👍
The spacing is indeed looking better now 😁
So I guess it's time to finally merge it! 😅

Cheers!

@mikecp mikecp merged commit 3e415b2 into umbraco:v11/contrib Jan 7, 2023
@bjarnef bjarnef deleted the v10/feature/icon-picker-swatches branch January 7, 2023 06:35
a-t-k pushed a commit to a-t-k/Umbraco-CMS that referenced this pull request Jan 11, 2023
* Ensure border is set so it doesn't jump on selection

* Allow to hide color from icon picker

* Use CSS grid instead to fill icons and with minimum width

* Remove odd flex size

* Set minimum to 60px instead
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants