@threadlabs/looma 0.47.4 → 0.47.6

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/docs/catalog.json CHANGED
@@ -468,7 +468,7 @@
468
468
  ],
469
469
  "schemaVersion": 1,
470
470
  "package": "@threadlabs/looma",
471
- "version": "0.47.4",
471
+ "version": "0.47.6",
472
472
  "groups": [
473
473
  {
474
474
  "id": "layout",
@@ -3749,7 +3749,7 @@
3749
3749
  "tag": "ui-card",
3750
3750
  "package": "@threadlabs/looma",
3751
3751
  "root": "div",
3752
- "description": "A surface that groups content with shared spacing and corners. Choose outlined, subtle or elevated; standard or expressive treatment independently follows the theme's material. Tones change colour without changing geometry. Supply a header slot, default body content and an actions slot. CardGroup aligns these regions with native subgrid; ordinary cards keep their stacked layout.",
3752
+ "description": "A surface that groups content with shared spacing and corners. Choose outlined, subtle or elevated; standard or expressive treatment independently follows the theme's material. Tones change colour without changing geometry. All slots are optional; content uses the default slot. Omit the header to keep the title and description together in the body. Use ActionBar in the actions slot, with the main action in its primary slot. CardGroup aligns these regions with native subgrid; ordinary cards keep their stacked layout.",
3753
3753
  "designTokens": {
3754
3754
  "sources": [
3755
3755
  "packages/looma/src/components/ui-card/ui-card.html"
@@ -4142,7 +4142,7 @@
4142
4142
  "tag": "ui-card-group",
4143
4143
  "package": "@threadlabs/looma",
4144
4144
  "root": "div",
4145
- "description": "Responsive cards with shared header, content and action rows. Uses Grid for wrapping columns and Card for native subgrid alignment. Each Card supplies a header slot, default body content and an actions slot.",
4145
+ "description": "Responsive cards with shared header, content and action rows. Uses Grid for wrapping columns and Card for native subgrid alignment. All Card slots are optional; content uses the default slot. Omit the header when the title and description should stay together in the body; that body starts at the card’s content edge without an empty header band. Use the header slot only when separate heading alignment is useful. Put an ActionBar in the actions slot, with the main action in its primary slot, for trailing alignment.",
4146
4146
  "designTokens": {
4147
4147
  "sources": [
4148
4148
  "packages/looma/src/components/ui-card-group/ui-card-group.html"
@@ -4251,6 +4251,16 @@
4251
4251
  "resizable": false,
4252
4252
  "bindings": "",
4253
4253
  "frameworks": {}
4254
+ },
4255
+ {
4256
+ "id": "@threadlabs/looma/ui-card-group/03-optional-header",
4257
+ "name": "03-optional-header",
4258
+ "title": "Body content with optional headers",
4259
+ "description": "Omit the header slot to keep each title and description in natural flow. ActionBar keeps primary actions at the trailing edge and aligned across cards.",
4260
+ "markup": "<ui-card-group columns=\"2\" min=\"md\">\n <ui-card>\n <ui-stack gap=\"s\">\n <ui-text as=\"h2\" variant=\"heading\">Archive</ui-text>\n <ui-text>A short description follows its own title.</ui-text>\n </ui-stack>\n <ui-action-bar slot=\"actions\"><ui-button slot=\"primary\" preset=\"primary\">Open archive</ui-button></ui-action-bar>\n </ui-card>\n <ui-card>\n <ui-stack gap=\"s\">\n <ui-text as=\"h2\" variant=\"heading\">Letters and records from the journey</ui-text>\n <ui-text>A longer title and description remain one continuous body while the action aligns with its neighbour.</ui-text>\n </ui-stack>\n <ui-action-bar slot=\"actions\"><ui-button slot=\"primary\" preset=\"primary\">Browse records</ui-button></ui-action-bar>\n </ui-card>\n</ui-card-group>",
4261
+ "resizable": false,
4262
+ "bindings": "",
4263
+ "frameworks": {}
4254
4264
  }
4255
4265
  ]
4256
4266
  },
@@ -10754,7 +10764,7 @@
10754
10764
  {
10755
10765
  "name": "match-button",
10756
10766
  "property": "matchButton",
10757
- "description": "Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row's height, on mouse and touch alike. Leave it off for compact toolbar and inline icon buttons.",
10767
+ "description": "Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row's height, on mouse and touch alike. Touch expansion stays vertical so an adjacent action keeps its own horizontal boundary. Leave it off for compact toolbar and inline icon buttons.",
10758
10768
  "type": "boolean",
10759
10769
  "default": false
10760
10770
  },
@@ -10871,7 +10881,7 @@
10871
10881
  },
10872
10882
  {
10873
10883
  "name": "matchButton",
10874
- "description": "Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row's height, on mouse and touch alike. Leave it off for compact toolbar and inline icon buttons.",
10884
+ "description": "Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row's height, on mouse and touch alike. Touch expansion stays vertical so an adjacent action keeps its own horizontal boundary. Leave it off for compact toolbar and inline icon buttons.",
10875
10885
  "type": "boolean",
10876
10886
  "default": false
10877
10887
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@threadlabs/looma",
3
- "version": "0.47.4",
3
+ "version": "0.47.6",
4
4
  "type": "module",
5
5
  "description": "Looma components as HTML, Vue, and plain DOM, with design tokens.",
6
6
  "license": "MIT",
@@ -46,6 +46,14 @@
46
46
  --_ui-card-group-region-layout: initial;
47
47
  }
48
48
 
49
+ .header:empty {
50
+ display: none !important;
51
+ }
52
+
53
+ .header:empty + .content {
54
+ grid-row: span 2 !important;
55
+ }
56
+
49
57
  :scope:where([data-component~="ui-card"])[data-ui-card-state~="padding=xs"] {
50
58
  gap: var(--ui-space-1) !important;
51
59
  padding: var(--ui-space-2) !important;
@@ -354,6 +354,12 @@
354
354
  align-self: stretch;
355
355
  }
356
356
 
357
+ /* A paired action may grow vertically for touch, without intercepting its neighbour. */
358
+ :scope:where([data-component~="ui-icon-button"])[data-ui-icon-button-state~="matchButton"]::after,
359
+ html[data-ui-input-modality="touch"] :scope:where([data-component~="ui-icon-button"])[data-ui-icon-button-state~="matchButton"]::after {
360
+ inline-size: 100%;
361
+ }
362
+
357
363
  :scope:where([data-component~="ui-icon-button"])[data-ui-icon-button-state~="matchButton"][data-ui-icon-button-state~="size=sm"] {
358
364
  --_size: var(--ui-control-size-sm);
359
365
  }
@@ -569,6 +575,8 @@
569
575
 
570
576
  /* A text button's companion uses control geometry; compact icon buttons keep their own density. */
571
577
 
578
+ /* A paired action may grow vertically for touch, without intercepting its neighbour. */
579
+
572
580
  /* Native toggle state persists after pointer release, including during loading. */
573
581
 
574
582
  @media (prefers-reduced-motion: reduce) {
package/vue/UiCard.vue CHANGED
@@ -362,6 +362,14 @@ const hostState = computed(() =>
362
362
  --_ui-card-group-region-layout: initial;
363
363
  }
364
364
 
365
+ :global(.header:empty:where([data-hn-ui-card])) {
366
+ display: none !important;
367
+ }
368
+
369
+ :global(.header:empty + .content:where([data-hn-ui-card])) {
370
+ grid-row: span 2 !important;
371
+ }
372
+
365
373
  :global(:scope[data-ui-card-state~="padding=xs"]:where([data-hn-ui-card])) {
366
374
  gap: var(--ui-space-1) !important;
367
375
  padding: var(--ui-space-2) !important;
@@ -77,7 +77,7 @@ const propValidityContract = {
77
77
  required: false,
78
78
  target: { attribute: 'data-match-button' },
79
79
  description:
80
- 'Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row\'s height, on mouse and\n touch alike. Leave it off for compact toolbar and inline icon buttons.',
80
+ 'Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row\'s height, on mouse and\n touch alike. Touch expansion stays vertical so an adjacent action keeps its own horizontal boundary. Leave it off for compact toolbar and inline icon\n buttons.',
81
81
  default: false,
82
82
  },
83
83
  pending: {
@@ -515,6 +515,8 @@ useComponentHost(() => import('../components/ui-icon-button/ui-icon-button.js'),
515
515
 
516
516
  /* A text button's companion uses control geometry; compact icon buttons keep their own density. */
517
517
 
518
+ /* A paired action may grow vertically for touch, without intercepting its neighbour. */
519
+
518
520
  /* Native toggle state persists after pointer release, including during loading. */
519
521
 
520
522
  /* Disabled is a flat neutral control, independent of the active variant's tone. */
@@ -904,6 +906,11 @@ useComponentHost(() => import('../components/ui-icon-button/ui-icon-button.js'),
904
906
  block-size: auto;
905
907
  align-self: stretch;
906
908
  }
909
+ :global(:scope[data-ui-icon-button-state~="matchButton"]:where([data-hn-ui-icon-button])::after),
910
+ :global(html[data-ui-input-modality="touch"]
911
+ :scope[data-ui-icon-button-state~="matchButton"]:where([data-hn-ui-icon-button])::after) {
912
+ inline-size: 100%;
913
+ }
907
914
 
908
915
  :global(:scope[data-ui-icon-button-state~="matchButton"][data-ui-icon-button-state~="size=sm"]:where([data-hn-ui-icon-button])) {
909
916
  --_size: var(--ui-control-size-sm);
@@ -364,6 +364,6 @@ var UiCard_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
364
364
  }]]);
365
365
  };
366
366
  }
367
- }), [["__scopeId", "data-v-54ed7533"]]);
367
+ }), [["__scopeId", "data-v-84b508aa"]]);
368
368
  //#endregion
369
369
  export { UiCard_default as t };
@@ -110,7 +110,7 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
110
110
  },
111
111
  required: false,
112
112
  target: { attribute: "data-match-button" },
113
- description: "Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row's height, on mouse and\n touch alike. Leave it off for compact toolbar and inline icon buttons.",
113
+ description: "Matches a boxed Button of the same size when the two share a flex row. Uses the control-size theme tokens and stretches to the row's height, on mouse and\n touch alike. Touch expansion stays vertical so an adjacent action keeps its own horizontal boundary. Leave it off for compact toolbar and inline icon\n buttons.",
114
114
  default: false
115
115
  },
116
116
  pending: {
@@ -464,6 +464,6 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
464
464
  }]]);
465
465
  };
466
466
  }
467
- }), [["__scopeId", "data-v-c80d216b"]]);
467
+ }), [["__scopeId", "data-v-87630da3"]]);
468
468
  //#endregion
469
469
  export { UiIconButton_default as t };
@@ -1729,6 +1729,12 @@ html[data-ui-input-modality="touch"]
1729
1729
  --_ui-card-group-span: initial;
1730
1730
  --_ui-card-group-region-layout: initial;
1731
1731
  }
1732
+ .header:empty:where([data-hn-ui-card]) {
1733
+ display: none !important;
1734
+ }
1735
+ .header:empty + .content:where([data-hn-ui-card]) {
1736
+ grid-row: span 2 !important;
1737
+ }
1732
1738
  :scope[data-ui-card-state~="padding=xs"]:where([data-hn-ui-card]) {
1733
1739
  gap: var(--ui-space-1) !important;
1734
1740
  padding: var(--ui-space-2) !important;
@@ -3817,6 +3823,8 @@ input:disabled:where(:scope, :scope *):where([data-hn-ui-combobox]),button:disab
3817
3823
 
3818
3824
  /* A text button's companion uses control geometry; compact icon buttons keep their own density. */
3819
3825
 
3826
+ /* A paired action may grow vertically for touch, without intercepting its neighbour. */
3827
+
3820
3828
  /* Native toggle state persists after pointer release, including during loading. */
3821
3829
 
3822
3830
  /* Disabled is a flat neutral control, independent of the active variant's tone. */
@@ -4191,6 +4199,10 @@ html[data-ui-input-modality="touch"] :scope:where([data-hn-ui-icon-button])::aft
4191
4199
  block-size: auto;
4192
4200
  align-self: stretch;
4193
4201
  }
4202
+ :scope[data-ui-icon-button-state~="matchButton"]:where([data-hn-ui-icon-button])::after,html[data-ui-input-modality="touch"]
4203
+ :scope[data-ui-icon-button-state~="matchButton"]:where([data-hn-ui-icon-button])::after {
4204
+ inline-size: 100%;
4205
+ }
4194
4206
  :scope[data-ui-icon-button-state~="matchButton"][data-ui-icon-button-state~="size=sm"]:where([data-hn-ui-icon-button]) {
4195
4207
  --_size: var(--ui-control-size-sm);
4196
4208
  }
@@ -15114,6 +15126,12 @@ html[data-ui-input-modality="touch"]
15114
15126
  align-self: stretch;
15115
15127
  }
15116
15128
 
15129
+ /* A paired action may grow vertically for touch, without intercepting its neighbour. */
15130
+ :scope:where([data-component~="ui-icon-button"])[data-ui-icon-button-state~="matchButton"]::after,
15131
+ html[data-ui-input-modality="touch"] :scope:where([data-component~="ui-icon-button"])[data-ui-icon-button-state~="matchButton"]::after {
15132
+ inline-size: 100%;
15133
+ }
15134
+
15117
15135
  :scope:where([data-component~="ui-icon-button"])[data-ui-icon-button-state~="matchButton"][data-ui-icon-button-state~="size=sm"] {
15118
15136
  --_size: var(--ui-control-size-sm);
15119
15137
  }
@@ -15329,6 +15347,8 @@ html[data-ui-input-modality="touch"]
15329
15347
 
15330
15348
  /* A text button's companion uses control geometry; compact icon buttons keep their own density. */
15331
15349
 
15350
+ /* A paired action may grow vertically for touch, without intercepting its neighbour. */
15351
+
15332
15352
  /* Native toggle state persists after pointer release, including during loading. */
15333
15353
 
15334
15354
  @media (prefers-reduced-motion: reduce) {