-
Notifications
You must be signed in to change notification settings - Fork 844
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
[EuiToken] Update tokenKeyword
and rename old tokenKeyword
as tokenTag
#5251
Conversation
Preview documentation changes for this PR: https://eui.elastic.co/pr_5251/ |
Preview documentation changes for this PR: https://eui.elastic.co/pr_5251/ |
Thanks @andreadelrio, The code looks good. 🎉 But IMO the "K" might seem like an "R". What do you think of removing the rounded "leg" and just have a straight line? |
@miukimiu I see what you mean, I really like the proposed |
@andreadelrio option "A" is also my favorite! 😍 |
Preview documentation changes for this PR: https://eui.elastic.co/pr_5251/ |
@cchaos that's a good observation. But the icon is not custom. It exists in EUI: It was introduced in #3165. That's why @Andrea chose the name
But yes... It seems that both icons have the same purpose. So should we replace |
Ahh.. hmm, so it looks like the ES-UI team has already created this mapping of ES fields to token, using the old I would consider talking with them to see if it makes sense in general to change that token icon and maybe ask @mdefazio too since he originally created this one. |
This was part of a batch of icons we updated/created. Unfortunately the rationale as to the design choice here escapes me. Sorry for the lack of help here. |
That mapping was made recently by @qn895 from ML. My understanding is that she's using It's been a bit hard to track down how these tokens were created in the first place. Based on my research the |
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.
Searching in Kibana for tokenKeyword
only returns what @cchaos indicated: https://github.com/elastic/kibana/blob/master/x-pack/plugins/data_visualizer/public/application/common/components/field_type_icon/field_type_icon.tsx#L33
That mapping was made recently by @qn895 from ML. My understanding is that she's using tokenKeyword only as a temporary solution as we (and the Discover team) are in agreement that we need a better suited icon for the keyword field type.
If the new icon is better suited and the ML and Discover team are in agreement I would just replace the tokenKeyword
with the new one.
@cchaos and @andreadelrio what do you think? Is there anything I'm not considering?
For the old token and because it looks like a tag. I would just rename it to tokenTag
so we don't lose it.
@andreadelrio all the code and design look good to me. We just need to decide this and then it's good to merge.
I'm good with that approach, though I would consider it a breaking change (which is ok) because it will completely change an icon that others may be using because they wanted the tag-like looking one. |
That's correct. It was a temporary switch until this one is merged in. We are happy with the swap to the new |
tokenKeyword
styles and rename old tokenKeyword
as tokenTag
tokenKeyword
styles and rename old tokenKeyword
as tokenTag
tokenKeyword
and rename old tokenKeyword
as tokenTag
Preview documentation changes for this PR: https://eui.elastic.co/pr_5251/ |
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, @andreadelrio! Tested in Chrome, Safari, Edge, and Firefox, and LGTM! 🎉
Preview documentation changes for this PR: https://eui.elastic.co/pr_5251/ |
@andreadelrio Can you also be sure to add this to the Figma library as well? |
@cchaos will do! |
Summary
This PR updates the icon called
tokenKeyword
to better match the definition ofkeyword field type
(details described here). In order to preserve the previous icon design for those who might be using it I've kept it under a new nametokenTag
.Token in the context of Discover / Data Visualizer
Closes #5240
Checklist
- [ ] Checked in mobile- [ ] Checked in Chrome, Safari, Edge, and Firefox- [ ] Checked for breaking changes and labeled appropriately- [ ] Checked for accessibility including keyboard-only and screenreader modes