@rogieking/figui3 6.31.1 → 6.31.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -2
- package/components.css +19 -3
- package/dist/components.css +1 -1
- package/dist/fig.css +1 -1
- package/dist/fig.js +19 -19
- package/fig.js +47 -42
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1404,7 +1404,7 @@ Use `slot="overlay"` for custom overlay controls. Slotted overlays stay as direc
|
|
|
1404
1404
|
|
|
1405
1405
|
`<fig-card>` — [demo](https://rog.ie/figui3/#card)
|
|
1406
1406
|
|
|
1407
|
-
A media card with a truncated label, optional link, and attribute-only selection chrome. With `src`, it composes a generated `fig-image`.
|
|
1407
|
+
A media card with a truncated label, optional link, and attribute-only selection chrome. With `src`, it composes a generated `fig-image`. The `label` and `sublabel` attributes render inside a generated `fig-footer`.
|
|
1408
1408
|
|
|
1409
1409
|
| Attribute | Type | Default | Description |
|
|
1410
1410
|
|---|---|---|---|
|
|
@@ -1432,9 +1432,13 @@ A media card with a truncated label, optional link, and attribute-only selection
|
|
|
1432
1432
|
<fig-card label="Custom preview">
|
|
1433
1433
|
<fig-preview>...</fig-preview>
|
|
1434
1434
|
</fig-card>
|
|
1435
|
+
<fig-card>
|
|
1436
|
+
<fig-preview>...</fig-preview>
|
|
1437
|
+
<fig-footer><label>Authored footer</label></fig-footer>
|
|
1438
|
+
</fig-card>
|
|
1435
1439
|
```
|
|
1436
1440
|
|
|
1437
|
-
When `src` is omitted, authored direct children such as `fig-image`, `fig-media`, or `fig-preview` remain direct children of the card.
|
|
1441
|
+
When `src` is omitted, authored direct children such as `fig-image`, `fig-media`, or `fig-preview` remain direct children of the card. An authored `fig-footer` is preserved; when no `label`, `text`, or `sublabel` attributes are present, the card does not generate another footer.
|
|
1438
1442
|
|
|
1439
1443
|
Place cards in a CSS grid for multi-column layouts — there is no built-in columns attribute. Prefer `full` in fluid layouts for consistency with other FigUI controls.
|
|
1440
1444
|
|
package/components.css
CHANGED
|
@@ -5028,7 +5028,8 @@ fig-card {
|
|
|
5028
5028
|
&[size="large"] {
|
|
5029
5029
|
--fig-card-padding: var(--spacer-2);
|
|
5030
5030
|
|
|
5031
|
-
|
|
5031
|
+
> fig-footer,
|
|
5032
|
+
.fig-card-link > fig-footer {
|
|
5032
5033
|
margin-top: var(--spacer-1);
|
|
5033
5034
|
}
|
|
5034
5035
|
|
|
@@ -5088,14 +5089,23 @@ fig-card {
|
|
|
5088
5089
|
min-height: auto;
|
|
5089
5090
|
}
|
|
5090
5091
|
|
|
5091
|
-
|
|
5092
|
+
> fig-footer,
|
|
5093
|
+
.fig-card-link > fig-footer {
|
|
5092
5094
|
display: flex;
|
|
5093
5095
|
flex-direction: column;
|
|
5096
|
+
flex-wrap: nowrap;
|
|
5097
|
+
align-items: stretch;
|
|
5098
|
+
justify-content: flex-start;
|
|
5094
5099
|
gap: 0;
|
|
5100
|
+
width: auto;
|
|
5101
|
+
padding: 0;
|
|
5102
|
+
box-shadow: none;
|
|
5103
|
+
box-sizing: border-box;
|
|
5095
5104
|
min-width: 0;
|
|
5096
5105
|
}
|
|
5097
5106
|
|
|
5098
|
-
|
|
5107
|
+
> fig-footer[hidden],
|
|
5108
|
+
.fig-card-link > fig-footer[hidden] {
|
|
5099
5109
|
display: none;
|
|
5100
5110
|
}
|
|
5101
5111
|
|
|
@@ -5104,7 +5114,10 @@ fig-card {
|
|
|
5104
5114
|
line-height: var(--line-height);
|
|
5105
5115
|
color: var(--figma-color-text);
|
|
5106
5116
|
min-width: 0;
|
|
5117
|
+
min-height: 0;
|
|
5107
5118
|
padding-inline: var(--spacer-1);
|
|
5119
|
+
justify-content: flex-start;
|
|
5120
|
+
text-align: start;
|
|
5108
5121
|
display: -webkit-box;
|
|
5109
5122
|
-webkit-box-orient: vertical;
|
|
5110
5123
|
-webkit-line-clamp: var(--fig-card-label-line-clamp);
|
|
@@ -5122,6 +5135,9 @@ fig-card {
|
|
|
5122
5135
|
color: var(--figma-color-text-secondary);
|
|
5123
5136
|
padding-inline: var(--spacer-1);
|
|
5124
5137
|
min-width: 0;
|
|
5138
|
+
min-height: 0;
|
|
5139
|
+
justify-content: flex-start;
|
|
5140
|
+
text-align: start;
|
|
5125
5141
|
white-space: nowrap;
|
|
5126
5142
|
overflow: hidden;
|
|
5127
5143
|
text-overflow: ellipsis;
|