-
Notifications
You must be signed in to change notification settings - Fork 77
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
feat(handle): add component tokens #8780
feat(handle): add component tokens #8780
Conversation
…nent-tokens-for-handle
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.
Move custom props to host and style based on the host state if you can.
Would be nice to have a story that applies these vars for test coverage. |
e7fe8de
to
33491b2
Compare
…nent-tokens-for-handle
…nent-tokens-for-handle
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.
Awesome stuff, @Elijbet! One more round of changes and I think this will be good to land. 🛬
@@ -23,16 +54,23 @@ | |||
:host(:not([disabled])) .handle { | |||
@apply cursor-move; | |||
&:hover { | |||
@apply bg-foreground-2 text-color-1; | |||
color: var(--calcite-handle-icon-color-hover, var(--calcite-color-text-1)); | |||
background-color: var(--calcite-handle-background-color-hover, var(--calcite-color-foreground-2)); | |||
} | |||
&:focus { |
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.
Not for this PR, but I think the :focus
block can be moved outside of the parent block since :focus
doesn't apply when components are disabled.
packages/calcite-components/src/components/handle/handle.stories.ts
Outdated
Show resolved
Hide resolved
|
||
export const focused_TestOnly = (): string => html` <calcite-handle focused></calcite-handle> `; | ||
|
||
export const themedStates_TestOnly = (): string => html` |
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.
🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘
🤘🎸🎸🎸🎸🤘🎸🤘🤘🤘🤘🤘🎸🤘🎸🎸🎸🎸🤘🤘🎸🎸🎸🤘🤘🎸🎸🤘🤘🎸🤘🤘🤘🎸🤘🎸🎸🎸🎸🤘🎸🤘
🤘🎸🤘🤘🎸🤘🎸🤘🤘🤘🤘🤘🎸🤘🎸🤘🤘🤘🤘🎸🤘🤘🤘🤘🎸🤘🤘🎸🤘🎸🎸🤘🎸🎸🤘🎸🤘🤘🤘🤘🎸🤘
🤘🎸🎸🎸🎸🤘🎸🤘🤘🎸🤘🤘🎸🤘🎸🎸🎸🤘🤘🤘🎸🎸🤘🤘🎸🤘🤘🎸🤘🎸🤘🎸🤘🎸🤘🎸🎸🎸🤘🤘🎸🤘
🤘🎸🤘🤘🎸🤘🎸🤘🎸🤘🎸🤘🎸🤘🎸🤘🤘🤘🤘🤘🤘🤘🎸🤘🎸🤘🤘🎸🤘🎸🤘🤘🤘🎸🤘🎸🤘🤘🤘🤘🤘🤘
🤘🎸🤘🤘🎸🤘🤘🎸🤘🤘🤘🎸🤘🤘🎸🎸🎸🎸🤘🎸🎸🎸🤘🤘🤘🎸🎸🤘🤘🎸🤘🤘🤘🎸🤘🎸🎸🎸🎸🤘🎸🤘
🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘🤘
@alisonailea Would you mind giving this a quick glance? 👀 |
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.
🎉
* These properties can be overridden using the component's tag as selector. | ||
* | ||
* @prop --calcite-handle-icon-color: Specifies the icon color of the component. | ||
* @prop --calcite-handle-icon-color-hover: Specifies the icon color of the component when in hover state. |
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.
question: do we prefer the term hover state
or hovered
? cc @geospatialem
Should this be worded like defines the color of an icon sub-component when hovered inside the component.
Thats how i've seen these worded in other PRs. I guess we'll probably need to do some cleanup/consistency doc checks before we merge the "real" PR?
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 we can check the epic PR every so often and fix any inconsistencies in wording/description?
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.
question: do we prefer the term hover state or hovered? cc @geospatialem
Should this be worded like
defines the color of an icon sub-component when hovered inside the component.
Great question. The sentence reads a bit weird when coupled with "when hovered"
. WDYT about another option altogether, and something like "on hover"
? For instance:
Specifies the component's icon color on hover.
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 like the simplicity of that phrasing.
…nent-tokens-for-handle
Related Issue: #7180
Summary
Adds the following component tokens: