Skip to content
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

[field formatters] Unable to enter hex code for color formatter due to lack of rendering space #123527

Closed
mattkime opened this issue Jan 21, 2022 · 13 comments · Fixed by #201676
Closed
Assignees
Labels
bug Fixes for quality problems that affect the customer experience Feature:FieldFormatters good first issue low hanging fruit impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:medium Medium Level of Effort papercut Small "burr" in the product that we should fix. Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL.

Comments

@mattkime
Copy link
Contributor

mattkime commented Jan 21, 2022

The current field formatter color selector doesn't show the hex values -
Screen Shot 2022-01-20 at 10 30 46 PM

...because they're hidden due to rendering constraints (modified via dev tools) -
Screen Shot 2022-01-20 at 10 29 00 PM

The layout should be altered so the user can see and edit these values. Discovered on 7.15.2 and verified on main/8.1.

@mattkime mattkime added bug Fixes for quality problems that affect the customer experience Team:AppServicesSv Feature:FieldFormatters labels Jan 21, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app-services (Team:AppServicesSv)

@Dosant Dosant added the good first issue low hanging fruit label Jan 24, 2022
@exalate-issue-sync exalate-issue-sync bot added impact:needs-assessment Product and/or Engineering needs to evaluate the impact of the change. loe:small Small Level of Effort labels Jan 24, 2022
@Dosant Dosant removed their assignment Jan 24, 2022
@exalate-issue-sync exalate-issue-sync bot added impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. and removed impact:needs-assessment Product and/or Engineering needs to evaluate the impact of the change. impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. labels Jan 24, 2022
@rushilp2311
Copy link

@mattkime Can I look into this?

@Dosant
Copy link
Contributor

Dosant commented Feb 7, 2022

@rushilp2311, sure! Go ahead :)

@Dosant
Copy link
Contributor

Dosant commented Mar 9, 2022

@elastic/kibana-design could you suggest a good fix here?

Things I've considered:

  1. Force internal horizontal scroll:
    Screen Shot 2022-03-09 at 13 48 59

  2. Force switch table to mobile mode (not sure if this is allowed by EUI, maybe will need to add a prop to allow it):

Screen Shot 2022-03-09 at 13 47 26

@MichaelMarcialis
Copy link
Contributor

@elastic/kibana-design could you suggest a good fix here?

Hi, @Dosant! I'm coming into this conversation a bit sideways, but I did have a quick thought regarding one possible way to address your color formatting spatial concerns. I've put together a quick little mockup below of that thought:

Frame 171

I thought it may be better to save space by taking advantage of the fact that EuiColorPicker can use a custom button to trigger the color selection popover (example in EUI docs). In this example, I'm using a slightly modified EuiButton that uses an EuiColorPickerSwatch as a child instead of text and has no minimum width. I've also applied a prepend label to the regex input, removed the containing table (since I thought the labels provided were sufficient to no longer require column headings), and suggested adding a link for folks to get some help on regex syntax.

Let me know if this suggestion helps, or if you require additional support. Thanks!

@mdefazio
Copy link
Contributor

One way to save a bit more horizontal space would be to remove the switch for formatting and simply show 'Default'.
When turning on the switch, it currently just shows 'Default', which is a bit odd to me.

This would likely mean having to move the switches for the other 2 options as well. (Probably need to include 'Off / On' after the switches as well. Doesn't fully solve the issue, but may save a bit more room and solve a UX bug as well.

I def like the above suggestion to the color formatter—do we need to include the output example somewhere too?

image

@exalate-issue-sync exalate-issue-sync bot added loe:medium Medium Level of Effort and removed loe:small Small Level of Effort labels Mar 30, 2022
@petrklapka petrklapka added Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL. and removed Team:AppServicesSv labels Dec 12, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-data-discovery (Team:DataDiscovery)

@Dripcoding
Copy link

hi is anyone still working on this? If not I'd like to contribute a PR as a community member.

@jughosta
Copy link
Contributor

Hi @Dripcoding,

Thanks for your interest in solving this issue!
Seems like nobody is working on it at the moment. How would you approach it?

@Dripcoding
Copy link

@jughosta I would move away from using the table component and favor using a card for each format definition. @MichaelMarcialis solution looks like a good starting point.

I would try using a non-interactive card with a border to make it clear that each format definition is separate from subsequent definitions. Each card could have a row to show the inputs horizontally as in Michael's mock and another row below it to show the example of the applied color formatting and the delete icon.

Let me know if that sounds reasonable to you.

@jughosta
Copy link
Contributor

@Dripcoding Sounds good! Let's maybe start with a PoC for your suggestion before committing fully. Thanks!

@davismcphee davismcphee added the papercut Small "burr" in the product that we should fix. label Nov 14, 2024
@MichaelMarcialis
Copy link
Contributor

Note that #201676 only address the color picker portion of my suggestion. Additional suggestions such as taking the interface out of a table component, removing the example text outright, increasing the width of the regex input, etc. were not addressed. If those additional suggestions are desirable to include, please feel free to re-open.

@davismcphee
Copy link
Contributor

@MichaelMarcialis This issue was originally for the hex code issue specifically, but I think these improvements are worth tracking. I opened a dedicated issue for them here: #202620.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience Feature:FieldFormatters good first issue low hanging fruit impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:medium Medium Level of Effort papercut Small "burr" in the product that we should fix. Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL.
Projects
None yet
Development

Successfully merging a pull request may close this issue.