-
Notifications
You must be signed in to change notification settings - Fork 76
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
[Block] Add icon property, update slot nomenclature #4932
Comments
Probably a good candidate for the internal Stack component here - even "icon" could probably just be "content-start". |
Similar to #6918, existing slots should be deprecated to allow developers time to migrate to the new ones before we remove them in a future breaking change release. |
Figma file documenting the changes for the above and deprecating the |
**Related Issue:** #7180 ## Summary Adds the following component tokens (CSS props): * `--calcite-block-background-color` * `--calcite-block-border-color` * `--calcite-block-content-space` * `--calcite-block-description-text-color` * `--calcite-block-header-background-color-hover` * `--calcite-block-header-background-color` * `--calcite-block-heading-text-color-open` * `--calcite-block-heading-text-color` * `--calcite-block-text-color` * `--calcite-block-toggle-icon-color` Deprecates the following: * `--calcite-block-padding` **Note**: added internal icon color token for [upcoming `icon` prop](#4932).
We reworked it a bit with @ashetland to keep the current behavior and deprecate it. Currently, there is a conditional for three items Eventually loading triple conditional will go away, and we'll add a progress bar on top to make up for it. #7492 will improve on this at that time. |
…nd `status`), add `actions-end` slot (deprecate `control`), add `content-start` (#9535) **Related Issue:** #4932 ## Summary - Add `icon-start` and `icon-end` properties. - Deprecate `status`. - Deprecate `icon` in favor of `icon-start`. - Add `actions-end` slot and deprecate `control` slot. - Add `content-start`.
Installed and assigned for verification. |
🍡 Verified locally on |
Description
The current Block slot documentation / naming is overly limiting, in practice an action or other element may be applicable :
https://developers.arcgis.com/calcite-design-system/components/block/#component-api-slots-control
Which Component
Block
Proposing that we rename the current slots to ones more consistent with the system:
Control -> Actions End
Icon -> Content Start
Additionally:
Icons are extremely common to see in Blocks. The vast majority of the time, they are simply using Calcite UI Icons that could be provided via prop. Sometimes they need to be custom image or other graphic, and for those cases, the "content-start" slot should be sufficient.
Add: Add an icon property that can be used in lieu of icon slot. Of course, folks can still slot a custom icon here, but providing an icon slot will ensure more consistently implemented designs in more cases while still preserving the location for custom icon or image. This will display alongside "content-slot", and if populated, that slot should not replace this icon provided via property.
The text was updated successfully, but these errors were encountered: