-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Introduce ha-dropdown #27417
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
base: dev
Are you sure you want to change the base?
Introduce ha-dropdown #27417
Conversation
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.
Really nice addition, seems to work well, might need some ha styling on top of the default
We need to add shadows. There is already a PR for this: #27320 Please use (md) when this will be available. |
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 tested it. Looks good 🙂
I also quickly tried to use it in automations and this should also be no big issue, I can to it in a follow up PR.
--wa-color-danger-on-quiet: var(--ha-color-on-danger-quiet); | ||
--wa-color-text-normal: var(--ha-color-text-primary); | ||
--wa-color-surface-default: var(--card-background-color); |
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.
--wa-color-surface-default: var(--card-background-color); | |
--wa-color-surface-default: var(--ha-color-surface-default); |
--wa-color-text-normal: var(--ha-color-text-primary); | ||
--wa-color-surface-default: var(--card-background-color); | ||
--wa-color-surface-raised: var(--ha-dialog-surface-background, var(--mdc-theme-surface, #fff)); |
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.
We should use a semantic color here, but I am not sure which one. Where is this color used?
@marcinbauer85 can you help out here please?
import { css, type CSSResultGroup } from "lit"; | ||
import { customElement, property } from "lit/decorators"; | ||
|
||
@customElement("ha-dropdown") |
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.
add js docs with reference to WA
import { css, type CSSResultGroup } from "lit"; | ||
import { customElement } from "lit/decorators"; | ||
|
||
@customElement("ha-dropdown-item") |
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.
add js docs with reference to WA
title: Dropdown | ||
--- | ||
|
||
# Dropdown `<ha-dropdown>` |
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.
Add more docs please. When to use it and reference to WA docs
Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍 |
Breaking change
Proposed change
Type of change
Example configuration
Additional information
Checklist
If user exposed functionality or configuration variables are added/changed: