Skip to content

Commit 1648742

Browse files
committed
description item changes
1 parent 2501843 commit 1648742

File tree

2 files changed

+15
-3
lines changed

2 files changed

+15
-3
lines changed

docs/pages/components/description-item.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,11 @@ layout: component
1414
Margot Foster
1515
</zn-description-item>
1616
<zn-description-item label="Full name">
17-
Margot Foster
17+
margot.foster@example.com
1818
</zn-description-item>
1919
<zn-description-item label="Full name">
20-
Margot Foster
20+
lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna
21+
aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
2122
</zn-description-item>
2223
</zn-sp>
2324
```

src/components/description-item/description-item.scss

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,34 @@
22

33
:host {
44
display: block;
5+
container-type: inline-size;
56

67
--zn-description-item-label-max-width: 300px;
78
}
89

910
.description-item {
1011
display: flex;
1112
flex-direction: row;
12-
padding: var(--zn-spacing-medium);
13+
padding: var(--zn-spacing-x-large) var(--zn-spacing-large);
1314

1415
@include wc.container-query(null, md) {
16+
--zn-description-item-label-max-width: 200px;
17+
}
18+
19+
@include wc.container-query(null, smd) {
20+
--zn-description-item-label-max-width: 150px;
21+
}
22+
23+
@include wc.container-query(null, sm) {
1524
flex-direction: column;
25+
gap: 10px;
1626
}
1727

1828
&__label {
1929
font-weight: 500;
2030
color: rgb(var(--zn-text-heading));
2131
max-width: var(--zn-description-item-label-max-width);
2232
width: 100%;
33+
flex-shrink: 0;
2334
}
2435
}

0 commit comments

Comments
 (0)