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

fix(list-item, stack): stretch dropdown when placed inside a list-item or stack #8204

Merged
merged 1 commit into from
Nov 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,8 @@ td:focus {
.actions-end {
::slotted(calcite-action),
::slotted(calcite-action-menu),
::slotted(calcite-handle) {
::slotted(calcite-handle),
::slotted(calcite-dropdown) {
@apply self-stretch;

color: inherit;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,14 @@ export const stretchSlottedContent = (): string => html`
<calcite-action appearance="transparent" text="Minus" icon="minus" text-enabled></calcite-action>
<calcite-action appearance="transparent" text="Table" icon="table" text-enabled></calcite-action>
</calcite-action-menu>
<calcite-dropdown slot="actions-end">
<calcite-action appearance="transparent" icon="plus" slot="trigger"></calcite-action>
<calcite-dropdown-group selection-mode="single" group-title="Sort by">
<calcite-dropdown-item>Relevance</calcite-dropdown-item>
<calcite-dropdown-item selected="">Date modified</calcite-dropdown-item>
<calcite-dropdown-item>Title</calcite-dropdown-item>
</calcite-dropdown-group>
</calcite-dropdown>
</calcite-list-item>
</calcite-list>
`;
Expand Down
3 changes: 2 additions & 1 deletion packages/calcite-components/src/components/stack/stack.scss
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@
.actions-end {
::slotted(calcite-action),
::slotted(calcite-action-menu),
::slotted(calcite-handle) {
::slotted(calcite-handle),
::slotted(calcite-dropdown) {
@apply self-stretch;

color: inherit;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,14 @@ export const stretchSlottedContent = (): string => html`
<calcite-action appearance="transparent" text="Minus" icon="minus" text-enabled></calcite-action>
<calcite-action appearance="transparent" text="Table" icon="table" text-enabled></calcite-action>
</calcite-action-menu>
<calcite-dropdown slot="actions-end">
<calcite-action appearance="transparent" icon="plus" slot="trigger"></calcite-action>
<calcite-dropdown-group selection-mode="single" group-title="Sort by">
<calcite-dropdown-item>Relevance</calcite-dropdown-item>
<calcite-dropdown-item selected="">Date modified</calcite-dropdown-item>
<calcite-dropdown-item>Title</calcite-dropdown-item>
</calcite-dropdown-group>
</calcite-dropdown>
</calcite-stack>
`;

Expand Down
Loading