use-wc 1.0.0-pre.80 → 1.0.0-pre.82
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/custom-elements.json +140 -35
- package/dist/design-system.css +677 -259
- package/dist/docs/use-layout.md +25 -23
- package/dist/docs/use-pattern.md +27 -0
- package/dist/tokens.css +6 -4
- package/package.json +1 -1
- package/vscode.html-custom-data.json +46 -23
package/custom-elements.json
CHANGED
|
@@ -3157,11 +3157,11 @@
|
|
|
3157
3157
|
"declarations": [
|
|
3158
3158
|
{
|
|
3159
3159
|
"kind": "class",
|
|
3160
|
-
"description": "`use-layout` is a configurable flex-container primitive, styled entirely by the design\nsystem's theme layer (`theme/layout.css`) rather than by any shadow DOM here — this element\nrenders its light-DOM children exactly as given and exists only to give its attributes real,\ntyped properties
|
|
3160
|
+
"description": "`use-layout` is a configurable flex-container primitive, styled entirely by the design\nsystem's theme layer (`theme/layout.css`) rather than by any shadow DOM here — this element\nrenders its light-DOM children exactly as given and exists only to give its attributes real,\ntyped properties.\n\nAdd the `.page` class for an app frame: a topbar `header` and a `footer` laid out as rows of\ntheir own, over a `main` that grows to fill the remaining space and scrolls on its own. A\n`.page` defaults to `spacing` between its regions, `gutter` beside them, and `paddingblock` at\nits own top and bottom, all at the page density, so a focus ring inside the scrolling `main`\nhas room to render. Set any of the three to override its default. Its footer splits status\nfrom actions by default; one that ends in a `type=\"submit\"` button, or carries the `actions`\nclass, aligns to the end instead.\n\n```html\n<use-layout spacing=\"medium\">\n <p>First</p>\n <p>Middle</p>\n <p>Last</p>\n</use-layout>\n```",
|
|
3161
3161
|
"name": "UseLayout",
|
|
3162
3162
|
"slots": [
|
|
3163
3163
|
{
|
|
3164
|
-
"description": "The
|
|
3164
|
+
"description": "The layout's content. Untouched otherwise — `use-layout` renders no shadow DOM and arranges its children with CSS alone.",
|
|
3165
3165
|
"name": ""
|
|
3166
3166
|
}
|
|
3167
3167
|
],
|
|
@@ -3198,12 +3198,22 @@
|
|
|
3198
3198
|
},
|
|
3199
3199
|
{
|
|
3200
3200
|
"kind": "field",
|
|
3201
|
-
"name": "
|
|
3201
|
+
"name": "spacing",
|
|
3202
3202
|
"type": {
|
|
3203
|
-
"text": "
|
|
3203
|
+
"text": "Spacing"
|
|
3204
3204
|
},
|
|
3205
3205
|
"default": "\"\"",
|
|
3206
|
-
"attribute": "
|
|
3206
|
+
"attribute": "spacing",
|
|
3207
|
+
"reflects": true
|
|
3208
|
+
},
|
|
3209
|
+
{
|
|
3210
|
+
"kind": "field",
|
|
3211
|
+
"name": "gutter",
|
|
3212
|
+
"type": {
|
|
3213
|
+
"text": "Gutter"
|
|
3214
|
+
},
|
|
3215
|
+
"default": "\"\"",
|
|
3216
|
+
"attribute": "gutter",
|
|
3207
3217
|
"reflects": true
|
|
3208
3218
|
},
|
|
3209
3219
|
{
|
|
@@ -3223,7 +3233,7 @@
|
|
|
3223
3233
|
"text": "Padding"
|
|
3224
3234
|
},
|
|
3225
3235
|
"default": "\"\"",
|
|
3226
|
-
"attribute": "
|
|
3236
|
+
"attribute": "paddingBlock",
|
|
3227
3237
|
"reflects": true
|
|
3228
3238
|
},
|
|
3229
3239
|
{
|
|
@@ -3233,7 +3243,27 @@
|
|
|
3233
3243
|
"text": "Padding"
|
|
3234
3244
|
},
|
|
3235
3245
|
"default": "\"\"",
|
|
3236
|
-
"attribute": "
|
|
3246
|
+
"attribute": "paddingInline",
|
|
3247
|
+
"reflects": true
|
|
3248
|
+
},
|
|
3249
|
+
{
|
|
3250
|
+
"kind": "field",
|
|
3251
|
+
"name": "gap",
|
|
3252
|
+
"type": {
|
|
3253
|
+
"text": "Gap"
|
|
3254
|
+
},
|
|
3255
|
+
"default": "\"\"",
|
|
3256
|
+
"attribute": "gap",
|
|
3257
|
+
"reflects": true
|
|
3258
|
+
},
|
|
3259
|
+
{
|
|
3260
|
+
"kind": "field",
|
|
3261
|
+
"name": "divided",
|
|
3262
|
+
"type": {
|
|
3263
|
+
"text": "Divided"
|
|
3264
|
+
},
|
|
3265
|
+
"default": "\"\"",
|
|
3266
|
+
"attribute": "divided",
|
|
3237
3267
|
"reflects": true
|
|
3238
3268
|
},
|
|
3239
3269
|
{
|
|
@@ -3269,34 +3299,42 @@
|
|
|
3269
3299
|
],
|
|
3270
3300
|
"attributes": [
|
|
3271
3301
|
{
|
|
3272
|
-
"description": "`
|
|
3273
|
-
"name": "
|
|
3302
|
+
"description": "A named scale from `xsmall` to `super`, or `none`. Puts half its value as padding on every direct child along the layout's main axis — block padding by default, or inline padding when `direction=\"row\"` — so two adjacent children's touching edges add up to one spacing unit between them. The first child's own leading side and the last child's own trailing side on that axis are forced to zero, so the layout carries no outer inset of its own there. Left empty, no attribute is set and children carry no padding at all. Reach for this instead of `gap` when a direct child is its own scroll container (`overflow`) holding focusable content: a focus ring at that content's edge spills into the child's padding, and the child's scrollport clips anything beyond it. `gap` leaves the child with no padding, so the ring gets cut off. `spacing` gives it room between children, but not on the first child's leading side or the last child's trailing side, which stay at zero.",
|
|
3303
|
+
"name": "spacing",
|
|
3274
3304
|
"type": {
|
|
3275
|
-
"text": "
|
|
3305
|
+
"text": "Spacing"
|
|
3276
3306
|
},
|
|
3277
|
-
"default": "\"
|
|
3278
|
-
"fieldName": "
|
|
3307
|
+
"default": "\"\"",
|
|
3308
|
+
"fieldName": "spacing"
|
|
3279
3309
|
},
|
|
3280
3310
|
{
|
|
3281
|
-
"description": "
|
|
3282
|
-
"name": "
|
|
3311
|
+
"description": "A named scale from `xsmall` to `super`, or `none`. Puts its full value as padding on every direct child along the layout's cross axis — inline padding by default, or block padding when `direction=\"row\"` — uniformly, no halving, no first/last exception, since there's nothing side-by-side on that axis for two children to double up with. Left empty, no attribute is set and children carry no cross-axis padding at all. Reach for this instead of the layout's own `padding` when a direct child is itself a scroll container (`overflow`) and can show a focus ring near its own cross-axis edges: the layout's `padding` sits outside the child, so the child's own scrollport still clips the ring. `gutter`'s padding is added directly to the child, so the ring has room inside it on both cross-axis sides.",
|
|
3312
|
+
"name": "gutter",
|
|
3283
3313
|
"type": {
|
|
3284
|
-
"text": "
|
|
3314
|
+
"text": "Gutter"
|
|
3285
3315
|
},
|
|
3286
3316
|
"default": "\"\"",
|
|
3287
|
-
"fieldName": "
|
|
3317
|
+
"fieldName": "gutter"
|
|
3288
3318
|
},
|
|
3289
3319
|
{
|
|
3290
|
-
"description": "
|
|
3291
|
-
"name": "
|
|
3320
|
+
"description": "A named scale from `xsmall` to `super`, or `none`, applied to the layout's own padding on all four sides. Left empty, no attribute is set. Set `paddingblock`/ `paddinginline` instead for different values per axis.",
|
|
3321
|
+
"name": "padding",
|
|
3292
3322
|
"type": {
|
|
3293
|
-
"text": "
|
|
3323
|
+
"text": "Padding"
|
|
3294
3324
|
},
|
|
3295
3325
|
"default": "\"\"",
|
|
3296
|
-
"fieldName": "
|
|
3326
|
+
"fieldName": "padding"
|
|
3327
|
+
},
|
|
3328
|
+
{
|
|
3329
|
+
"description": "A named scale from `xsmall` to `super`, or `none`, applied to the layout's own block padding only. Left empty, no attribute is set.",
|
|
3330
|
+
"name": "paddingblock"
|
|
3297
3331
|
},
|
|
3298
3332
|
{
|
|
3299
|
-
"description": "A named scale from `xsmall` to `super
|
|
3333
|
+
"description": "A named scale from `xsmall` to `super`, or `none`, applied to the layout's own inline padding only. Left empty, no attribute is set.",
|
|
3334
|
+
"name": "paddinginline"
|
|
3335
|
+
},
|
|
3336
|
+
{
|
|
3337
|
+
"description": "A named scale from `xsmall` to `super`, applied to the layout's own real `gap` CSS property. Left empty, no attribute is set and the layout has no gap of its own.",
|
|
3300
3338
|
"name": "gap",
|
|
3301
3339
|
"type": {
|
|
3302
3340
|
"text": "Gap"
|
|
@@ -3305,34 +3343,43 @@
|
|
|
3305
3343
|
"fieldName": "gap"
|
|
3306
3344
|
},
|
|
3307
3345
|
{
|
|
3308
|
-
"description": "
|
|
3309
|
-
"name": "
|
|
3346
|
+
"description": "Boolean, or `full`. Draws a rule on every child that follows another one — the first child never gets one, since there's nothing before it to divide from. Drawn as a plain border on the layout's main axis leading edge — `border-block-start` by default, or `border-inline-start` when `direction=\"row\"` — whenever `spacing` is set or no real `gap` exists to draw into (each child owns its own padding there instead) — but when `gap` is set and `spacing` isn't, drawn natively into the real gap via CSS Gap Decorations on browsers that support it: `row-rule` by default, or `column-rule` when `direction=\"row\"`. Set to `full` to additionally bleed that native rule through the layout's own padding on the cross axis, so it reaches the layout's outer edge instead of stopping at the padding — only has an effect when the layout has both a real `gap` and padding on the relevant axis (`padding` or `paddinginline`/`paddingblock`). With `spacing` or `gutter`, including a `.page`'s own, the rule is a border across each child's whole box and already runs edge to edge.",
|
|
3347
|
+
"name": "divided",
|
|
3310
3348
|
"type": {
|
|
3311
|
-
"text": "
|
|
3349
|
+
"text": "Divided"
|
|
3312
3350
|
},
|
|
3313
3351
|
"default": "\"\"",
|
|
3314
|
-
"fieldName": "
|
|
3352
|
+
"fieldName": "divided"
|
|
3315
3353
|
},
|
|
3316
3354
|
{
|
|
3317
|
-
"description": "
|
|
3318
|
-
"name": "
|
|
3355
|
+
"description": "`column` (the default) or `row`, mapped to `flex-direction`.",
|
|
3356
|
+
"name": "direction",
|
|
3319
3357
|
"type": {
|
|
3320
|
-
"text": "
|
|
3358
|
+
"text": "Direction"
|
|
3359
|
+
},
|
|
3360
|
+
"default": "\"column\"",
|
|
3361
|
+
"fieldName": "direction"
|
|
3362
|
+
},
|
|
3363
|
+
{
|
|
3364
|
+
"description": "Maps to `align-items`: `start`, `center`, `end`, or `stretch`. Left empty, no attribute is set and the browser's own default applies.",
|
|
3365
|
+
"name": "align",
|
|
3366
|
+
"type": {
|
|
3367
|
+
"text": "Align"
|
|
3321
3368
|
},
|
|
3322
3369
|
"default": "\"\"",
|
|
3323
|
-
"fieldName": "
|
|
3370
|
+
"fieldName": "align"
|
|
3324
3371
|
},
|
|
3325
3372
|
{
|
|
3326
|
-
"description": "
|
|
3327
|
-
"name": "
|
|
3373
|
+
"description": "Maps to `justify-content`: `start`, `center`, `end`, `space-between`, or `space-around`. Left empty, no attribute is set.",
|
|
3374
|
+
"name": "justify",
|
|
3328
3375
|
"type": {
|
|
3329
|
-
"text": "
|
|
3376
|
+
"text": "Justify"
|
|
3330
3377
|
},
|
|
3331
3378
|
"default": "\"\"",
|
|
3332
|
-
"fieldName": "
|
|
3379
|
+
"fieldName": "justify"
|
|
3333
3380
|
},
|
|
3334
3381
|
{
|
|
3335
|
-
"description": "Maps to `flex-wrap: wrap`.",
|
|
3382
|
+
"description": "Maps to `flex-wrap: wrap`. Pair it with `gap` rather than `spacing`: per-child padding can't reproduce the room between wrapped lines.",
|
|
3336
3383
|
"name": "wrap",
|
|
3337
3384
|
"type": {
|
|
3338
3385
|
"text": "boolean"
|
|
@@ -3350,13 +3397,29 @@
|
|
|
3350
3397
|
"fieldName": "inline"
|
|
3351
3398
|
},
|
|
3352
3399
|
{
|
|
3353
|
-
"description": "
|
|
3400
|
+
"description": "Grows this layout to fill the space its parent `use-layout` or `use-pattern` has left, scrolling its own overflow, and pins every sibling so it can't shrink. Read only on `use-layout` itself, so an `<svg fill=\"…\">` child is never mistaken for one. A `.page`'s `main` fills the same way without it.",
|
|
3354
3401
|
"name": "fill",
|
|
3355
3402
|
"type": {
|
|
3356
3403
|
"text": "boolean"
|
|
3357
3404
|
},
|
|
3358
3405
|
"default": "false",
|
|
3359
3406
|
"fieldName": "fill"
|
|
3407
|
+
},
|
|
3408
|
+
{
|
|
3409
|
+
"name": "paddingBlock",
|
|
3410
|
+
"type": {
|
|
3411
|
+
"text": "Padding"
|
|
3412
|
+
},
|
|
3413
|
+
"default": "\"\"",
|
|
3414
|
+
"fieldName": "paddingBlock"
|
|
3415
|
+
},
|
|
3416
|
+
{
|
|
3417
|
+
"name": "paddingInline",
|
|
3418
|
+
"type": {
|
|
3419
|
+
"text": "Padding"
|
|
3420
|
+
},
|
|
3421
|
+
"default": "\"\"",
|
|
3422
|
+
"fieldName": "paddingInline"
|
|
3360
3423
|
}
|
|
3361
3424
|
],
|
|
3362
3425
|
"superclass": {
|
|
@@ -4070,6 +4133,48 @@
|
|
|
4070
4133
|
}
|
|
4071
4134
|
]
|
|
4072
4135
|
},
|
|
4136
|
+
{
|
|
4137
|
+
"kind": "javascript-module",
|
|
4138
|
+
"path": "src/elements/use-pattern/use-pattern.ts",
|
|
4139
|
+
"declarations": [
|
|
4140
|
+
{
|
|
4141
|
+
"kind": "class",
|
|
4142
|
+
"description": "`use-pattern` arranges a region-based unit of content — a card, a row in a list, a chat\nmessage, a media object — styled entirely by the design system's theme layer\n(`theme/pattern.css`) rather than by any shadow DOM here. It renders its light-DOM children\nexactly as given.\n\nIts variant classes (`card`, `entry`, `message`, `media`) and their modifiers (`.divided`,\n`.compact`, `.outlined`, `.flush`) are plain classes rather than properties, the same as any\nother themed class in this system, like `use-avatar`'s `.circle`/`.square`. For generic flex\narrangement, or a page frame, use `use-layout`, which nests freely inside a pattern's regions.\n\n```html\n<use-pattern class=\"card\">\n <header>\n <hgroup><h3>Title</h3><p>Subtitle</p></hgroup>\n </header>\n <main><p>Body</p></main>\n <footer><button type=\"button\">Done</button></footer>\n</use-pattern>\n```",
|
|
4143
|
+
"name": "UsePattern",
|
|
4144
|
+
"slots": [
|
|
4145
|
+
{
|
|
4146
|
+
"description": "The pattern's regions — `figure`, `header`, `main`, `footer`, or any other element.",
|
|
4147
|
+
"name": ""
|
|
4148
|
+
}
|
|
4149
|
+
],
|
|
4150
|
+
"members": [],
|
|
4151
|
+
"superclass": {
|
|
4152
|
+
"name": "LitElement",
|
|
4153
|
+
"package": "lit"
|
|
4154
|
+
},
|
|
4155
|
+
"tagName": "use-pattern",
|
|
4156
|
+
"customElement": true
|
|
4157
|
+
}
|
|
4158
|
+
],
|
|
4159
|
+
"exports": [
|
|
4160
|
+
{
|
|
4161
|
+
"kind": "js",
|
|
4162
|
+
"name": "UsePattern",
|
|
4163
|
+
"declaration": {
|
|
4164
|
+
"name": "UsePattern",
|
|
4165
|
+
"module": "src/elements/use-pattern/use-pattern.ts"
|
|
4166
|
+
}
|
|
4167
|
+
},
|
|
4168
|
+
{
|
|
4169
|
+
"kind": "custom-element-definition",
|
|
4170
|
+
"name": "use-pattern",
|
|
4171
|
+
"declaration": {
|
|
4172
|
+
"name": "UsePattern",
|
|
4173
|
+
"module": "src/elements/use-pattern/use-pattern.ts"
|
|
4174
|
+
}
|
|
4175
|
+
}
|
|
4176
|
+
]
|
|
4177
|
+
},
|
|
4073
4178
|
{
|
|
4074
4179
|
"kind": "javascript-module",
|
|
4075
4180
|
"path": "src/elements/use-scrollarea/index.ts",
|