@threadlabs/looma 0.52.4 → 0.52.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
@@ -497,6 +497,13 @@
497
497
  "angularHost": "ng-template",
498
498
  "resource": "@threadlabs/looma/components/ui-nav-item/ui-nav-item.html"
499
499
  },
500
+ {
501
+ "tag": "ui-notice-stripe",
502
+ "package": "@threadlabs/looma",
503
+ "root": "div",
504
+ "angularHost": "div",
505
+ "resource": "@threadlabs/looma/components/ui-notice-stripe/ui-notice-stripe.html"
506
+ },
500
507
  {
501
508
  "tag": "ui-number-input",
502
509
  "package": "@threadlabs/looma",
@@ -752,7 +759,7 @@
752
759
  ],
753
760
  "schemaVersion": 1,
754
761
  "package": "@threadlabs/looma",
755
- "version": "0.52.4",
762
+ "version": "0.52.6",
756
763
  "groups": [
757
764
  {
758
765
  "id": "layout",
@@ -24484,6 +24491,246 @@
24484
24491
  }
24485
24492
  ]
24486
24493
  },
24494
+ {
24495
+ "angularHost": "div",
24496
+ "tag": "ui-notice-stripe",
24497
+ "package": "@threadlabs/looma",
24498
+ "root": "div",
24499
+ "description": "A compact, full-width notification for announcements and service notices. The default slot carries the message and the actions slot carries links or buttons. Content wraps at narrow widths. Optional dismissal reports intent while the consumer owns visibility, persistence and scheduling.",
24500
+ "designTokens": {
24501
+ "sources": [
24502
+ "packages/looma/src/components/ui-notice-stripe/ui-notice-stripe.html"
24503
+ ],
24504
+ "component": [],
24505
+ "shared": [
24506
+ {
24507
+ "name": "--ui-border-strong"
24508
+ },
24509
+ {
24510
+ "name": "--ui-border-width"
24511
+ },
24512
+ {
24513
+ "name": "--ui-danger-soft"
24514
+ },
24515
+ {
24516
+ "name": "--ui-danger-soft-border"
24517
+ },
24518
+ {
24519
+ "name": "--ui-danger-subtle-text"
24520
+ },
24521
+ {
24522
+ "name": "--ui-font-family-sans"
24523
+ },
24524
+ {
24525
+ "name": "--ui-font-normal"
24526
+ },
24527
+ {
24528
+ "name": "--ui-font-size-sm"
24529
+ },
24530
+ {
24531
+ "name": "--ui-info-soft"
24532
+ },
24533
+ {
24534
+ "name": "--ui-info-soft-border"
24535
+ },
24536
+ {
24537
+ "name": "--ui-info-subtle-text"
24538
+ },
24539
+ {
24540
+ "name": "--ui-line-height-md"
24541
+ },
24542
+ {
24543
+ "name": "--ui-space-1"
24544
+ },
24545
+ {
24546
+ "name": "--ui-space-2"
24547
+ },
24548
+ {
24549
+ "name": "--ui-space-3"
24550
+ },
24551
+ {
24552
+ "name": "--ui-success-soft"
24553
+ },
24554
+ {
24555
+ "name": "--ui-success-soft-border"
24556
+ },
24557
+ {
24558
+ "name": "--ui-success-subtle-text"
24559
+ },
24560
+ {
24561
+ "name": "--ui-surface-muted"
24562
+ },
24563
+ {
24564
+ "name": "--ui-text-primary"
24565
+ },
24566
+ {
24567
+ "name": "--ui-warning-soft"
24568
+ },
24569
+ {
24570
+ "name": "--ui-warning-soft-border"
24571
+ },
24572
+ {
24573
+ "name": "--ui-warning-subtle-text"
24574
+ }
24575
+ ]
24576
+ },
24577
+ "attributes": [
24578
+ {
24579
+ "name": "dismiss-label",
24580
+ "property": "dismissLabel",
24581
+ "description": "Accessible name of the close control, including translated or message-specific wording.",
24582
+ "type": "string",
24583
+ "valueType": {
24584
+ "kind": "terminal",
24585
+ "name": "string"
24586
+ },
24587
+ "default": "Dismiss notification"
24588
+ },
24589
+ {
24590
+ "name": "dismissible",
24591
+ "property": "dismissible",
24592
+ "description": "Show a close control that requests dismissal. The consumer owns removing or hiding the stripe.",
24593
+ "type": "boolean",
24594
+ "valueType": {
24595
+ "kind": "terminal",
24596
+ "name": "boolean"
24597
+ },
24598
+ "default": false
24599
+ },
24600
+ {
24601
+ "name": "tone",
24602
+ "property": "tone",
24603
+ "description": "Semantic message tone. Danger uses alert semantics; other tones use a polite status.",
24604
+ "type": "keyword",
24605
+ "valueType": {
24606
+ "kind": "terminal",
24607
+ "name": "keyword"
24608
+ },
24609
+ "default": "info",
24610
+ "options": [
24611
+ "neutral",
24612
+ "info",
24613
+ "success",
24614
+ "warning",
24615
+ "danger"
24616
+ ]
24617
+ }
24618
+ ],
24619
+ "properties": [
24620
+ {
24621
+ "name": "dismissible",
24622
+ "description": "Show a close control that requests dismissal. The consumer owns removing or hiding the stripe.",
24623
+ "type": "boolean",
24624
+ "default": false
24625
+ },
24626
+ {
24627
+ "name": "dismissLabel",
24628
+ "description": "Accessible name of the close control, including translated or message-specific wording.",
24629
+ "type": "string",
24630
+ "default": "Dismiss notification"
24631
+ },
24632
+ {
24633
+ "name": "tone",
24634
+ "description": "Semantic message tone. Danger uses alert semantics; other tones use a polite status.",
24635
+ "type": "\"neutral\" | \"info\" | \"success\" | \"warning\" | \"danger\"",
24636
+ "default": "info",
24637
+ "options": [
24638
+ "neutral",
24639
+ "info",
24640
+ "success",
24641
+ "warning",
24642
+ "danger"
24643
+ ]
24644
+ }
24645
+ ],
24646
+ "events": [
24647
+ {
24648
+ "name": "dismiss",
24649
+ "detailType": "{ readonly reason: \"action\"; readonly trigger: \"keyboard\" | \"pointer\" | \"programmatic\" }",
24650
+ "detailSchema": "object",
24651
+ "fields": [
24652
+ {
24653
+ "path": "reason",
24654
+ "type": "keyword",
24655
+ "required": true,
24656
+ "values": [
24657
+ "action"
24658
+ ]
24659
+ },
24660
+ {
24661
+ "path": "trigger",
24662
+ "type": "keyword",
24663
+ "required": true,
24664
+ "values": [
24665
+ "keyboard",
24666
+ "pointer",
24667
+ "programmatic"
24668
+ ]
24669
+ }
24670
+ ],
24671
+ "detailDocs": "Emitted when a toast item is dismissed from its region."
24672
+ }
24673
+ ],
24674
+ "slots": [
24675
+ {
24676
+ "name": "default",
24677
+ "description": "Default child content."
24678
+ },
24679
+ {
24680
+ "name": "actions",
24681
+ "description": "Named content for the actions region."
24682
+ }
24683
+ ],
24684
+ "summary": "Edge-to-edge announcements with optional actions and dismissal.",
24685
+ "group": "display",
24686
+ "id": "@threadlabs/looma/ui-notice-stripe",
24687
+ "title": "Notice Stripe",
24688
+ "resource": "@threadlabs/looma/components/ui-notice-stripe/ui-notice-stripe.html",
24689
+ "targets": [
24690
+ "html-next",
24691
+ "vue",
24692
+ "react",
24693
+ "preact",
24694
+ "svelte",
24695
+ "angular"
24696
+ ],
24697
+ "examples": [
24698
+ {
24699
+ "id": "@threadlabs/looma/ui-notice-stripe/01-announcement",
24700
+ "name": "01-announcement",
24701
+ "title": "Announcement with action",
24702
+ "description": "A compact announcement keeps a related guide link at the trailing edge.",
24703
+ "markup": "<ui-notice-stripe>New documentation is available.<ui-button slot=\"actions\" variant=\"link\" size=\"sm\" href=\"#documentation\"\n >Read the guide</ui-button></ui-notice-stripe>",
24704
+ "resizable": false,
24705
+ "stretch": true,
24706
+ "bindings": "",
24707
+ "frameworks": {}
24708
+ },
24709
+ {
24710
+ "id": "@threadlabs/looma/ui-notice-stripe/02-service-notice",
24711
+ "name": "02-service-notice",
24712
+ "title": "Dismissible service notice",
24713
+ "description": "The application hides this maintenance notice after the close control requests dismissal.",
24714
+ "markup": "<ui-notice-stripe data-example-id=\"maintenance-notice\" tone=\"warning\" dismissible dismiss-label=\"Dismiss maintenance notice\">Scheduled maintenance starts at\n 22:00 UTC. Some actions may take longer during this time.<ui-button slot=\"actions\" variant=\"link\" size=\"sm\" href=\"#status\"\n >Service status</ui-button></ui-notice-stripe>",
24715
+ "resizable": false,
24716
+ "stretch": true,
24717
+ "bindings": "",
24718
+ "frameworks": {},
24719
+ "behavior": "@threadlabs/looma/docs/examples/ui-notice-stripe/examples/02-service-notice.behavior.js"
24720
+ },
24721
+ {
24722
+ "id": "@threadlabs/looma/ui-notice-stripe/03-tones",
24723
+ "name": "03-tones",
24724
+ "title": "Semantic tones",
24725
+ "description": "The shared semantic palette communicates information, status and urgency.",
24726
+ "markup": "<ui-stack gap=\"xs\">\n <ui-notice-stripe tone=\"neutral\">Neutral notice.</ui-notice-stripe>\n <ui-notice-stripe tone=\"info\">Info notice.</ui-notice-stripe>\n <ui-notice-stripe tone=\"success\">Success notice.</ui-notice-stripe>\n <ui-notice-stripe tone=\"warning\">Warning notice.</ui-notice-stripe>\n <ui-notice-stripe tone=\"danger\">Danger notice.</ui-notice-stripe>\n</ui-stack>",
24727
+ "resizable": false,
24728
+ "stretch": true,
24729
+ "bindings": "",
24730
+ "frameworks": {}
24731
+ }
24732
+ ]
24733
+ },
24487
24734
  {
24488
24735
  "angularHost": "span",
24489
24736
  "tag": "ui-number-input",
@@ -0,0 +1,7 @@
1
+ export default function connect(root) {
2
+ const stripe = root.querySelector("[data-example-id=maintenance-notice]");
3
+ const dismiss = () => { if (stripe)
4
+ stripe.hidden = true; };
5
+ stripe?.addEventListener("dismiss", dismiss);
6
+ return () => stripe?.removeEventListener("dismiss", dismiss);
7
+ }
@@ -136,6 +136,7 @@
136
136
 
137
137
  /* Projected marks may be images or composed elements, including block-level image resets. */
138
138
  .label:has(> *) {
139
+ max-inline-size: 100%;
139
140
  display: inline-flex !important;
140
141
  align-items: center !important;
141
142
  gap: var(--ui-space-2) !important;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@threadlabs/looma",
3
- "version": "0.52.4",
3
+ "version": "0.52.6",
4
4
  "type": "module",
5
5
  "description": "HTML Next UI components, native DOM support and design tokens.",
6
6
  "license": "MIT",
@@ -136,6 +136,7 @@
136
136
 
137
137
  /* Projected marks may be images or composed elements, including block-level image resets. */
138
138
  .label:has(> *) {
139
+ max-inline-size: 100%;
139
140
  display: inline-flex !important;
140
141
  align-items: center !important;
141
142
  gap: var(--ui-space-2) !important;
@@ -0,0 +1,172 @@
1
+ /* Generated by HTML Next 1.0.0-alpha.84. Do not edit. */
2
+ @supports (-moz-appearance: none) {
3
+ :where(:is([component]:not(template), [data-component]:not([component])), [data-slotted]) { --html-next-scope-owner: boundary; }
4
+ :where([data-slotted]:not(:is([component]:not(template), [data-component]:not([component])))) { --html-next-scope-owner: projected !important; }
5
+ }
6
+ @supports (-moz-appearance: none) {
7
+ :is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])) { --html-next-scope-owner: "ui-notice-stripe" !important; }
8
+ }
9
+ @scope (:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component]))) to (:is([component]:not(template), [data-component]:not([component])), [data-slotted]) {
10
+ :scope:where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component]))) {
11
+ --_ui-notice-stripe-surface: var(--ui-info-soft);
12
+ --_ui-notice-stripe-border: var(--ui-info-soft-border);
13
+ --_ui-surface-text: var(--ui-info-subtle-text);
14
+ display: flex !important;
15
+ align-items: center !important;
16
+ gap: var(--ui-space-2) !important;
17
+ box-sizing: border-box !important;
18
+ inline-size: 100%;
19
+ min-inline-size: 0;
20
+ min-block-size: 44px;
21
+ margin: 0 !important;
22
+ padding: var(--ui-space-1) var(--ui-space-3) !important;
23
+ border: 0;
24
+ border-block-end: var(--ui-border-width) solid var(--_ui-notice-stripe-border);
25
+ border-radius: 0;
26
+ background: var(--_ui-notice-stripe-surface);
27
+ color: var(--_ui-surface-text);
28
+ font-family: var(--ui-font-family-sans);
29
+ font-size: var(--ui-font-size-sm);
30
+ font-weight: var(--ui-font-normal);
31
+ line-height: var(--ui-line-height-md);
32
+ }
33
+ :scope:where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=neutral"] {
34
+ --_ui-notice-stripe-surface: var(--ui-surface-muted);
35
+ --_ui-notice-stripe-border: var(--ui-border-strong);
36
+ --_ui-surface-text: var(--ui-text-primary);
37
+ }
38
+ :scope:where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=success"] {
39
+ --_ui-notice-stripe-surface: var(--ui-success-soft);
40
+ --_ui-notice-stripe-border: var(--ui-success-soft-border);
41
+ --_ui-surface-text: var(--ui-success-subtle-text);
42
+ }
43
+ :scope:where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=warning"] {
44
+ --_ui-notice-stripe-surface: var(--ui-warning-soft);
45
+ --_ui-notice-stripe-border: var(--ui-warning-soft-border);
46
+ --_ui-surface-text: var(--ui-warning-subtle-text);
47
+ }
48
+ :scope:where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=danger"] {
49
+ --_ui-notice-stripe-surface: var(--ui-danger-soft);
50
+ --_ui-notice-stripe-border: var(--ui-danger-soft-border);
51
+ --_ui-surface-text: var(--ui-danger-subtle-text);
52
+ }
53
+ .content {
54
+ display: flex !important;
55
+ flex: 1;
56
+ flex-wrap: wrap !important;
57
+ align-items: center !important;
58
+ gap: var(--ui-space-1) var(--ui-space-3) !important;
59
+ min-inline-size: 0;
60
+ }
61
+ .message {
62
+ flex: 1 1 16rem;
63
+ min-inline-size: 0;
64
+ overflow-wrap: anywhere;
65
+ }
66
+ .actions {
67
+ display: flex !important;
68
+ flex-wrap: wrap !important;
69
+ align-items: center !important;
70
+ justify-content: flex-end !important;
71
+ gap: var(--ui-space-2) !important;
72
+ min-inline-size: 0;
73
+ max-inline-size: 100%;
74
+ overflow-wrap: anywhere;
75
+ margin-inline-start: auto !important;
76
+ }
77
+ .actions:empty {
78
+ display: none !important;
79
+ }
80
+ .dismiss {
81
+ flex: none;
82
+ }
83
+ :scope:where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[hidden] {
84
+ display: none !important;
85
+ }
86
+ }
87
+ @scope (:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component]))) to (:is([component]:not(template), [data-component]:not([component]))) {
88
+ .message :where([data-slotted], [data-slotted] *):is(a),
89
+ .actions :where([data-slotted], [data-slotted] *):is(a) {
90
+ color: inherit;
91
+ text-decoration: underline;
92
+ text-underline-offset: 0.18em;
93
+ }
94
+ }
95
+ @scope ([data-slotted~="ui-notice-stripe"]:not(:is([component]:not(template), [data-component]:not([component])))) to (:is([component]:not(template), [data-component]:not([component])), [data-slotted]) {
96
+ :where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component]))):where(:scope, :not(:is([component]:not(template), [data-component]:not([component])), [data-slotted]:not([data-slotted~="ui-notice-stripe"]))) {
97
+ --_ui-notice-stripe-surface: var(--ui-info-soft);
98
+ --_ui-notice-stripe-border: var(--ui-info-soft-border);
99
+ --_ui-surface-text: var(--ui-info-subtle-text);
100
+ display: flex !important;
101
+ align-items: center !important;
102
+ gap: var(--ui-space-2) !important;
103
+ box-sizing: border-box !important;
104
+ inline-size: 100%;
105
+ min-inline-size: 0;
106
+ min-block-size: 44px;
107
+ margin: 0 !important;
108
+ padding: var(--ui-space-1) var(--ui-space-3) !important;
109
+ border: 0;
110
+ border-block-end: var(--ui-border-width) solid var(--_ui-notice-stripe-border);
111
+ border-radius: 0;
112
+ background: var(--_ui-notice-stripe-surface);
113
+ color: var(--_ui-surface-text);
114
+ font-family: var(--ui-font-family-sans);
115
+ font-size: var(--ui-font-size-sm);
116
+ font-weight: var(--ui-font-normal);
117
+ line-height: var(--ui-line-height-md);
118
+ }
119
+ :where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=neutral"]:where(:scope, :not(:is([component]:not(template), [data-component]:not([component])), [data-slotted]:not([data-slotted~="ui-notice-stripe"]))) {
120
+ --_ui-notice-stripe-surface: var(--ui-surface-muted);
121
+ --_ui-notice-stripe-border: var(--ui-border-strong);
122
+ --_ui-surface-text: var(--ui-text-primary);
123
+ }
124
+ :where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=success"]:where(:scope, :not(:is([component]:not(template), [data-component]:not([component])), [data-slotted]:not([data-slotted~="ui-notice-stripe"]))) {
125
+ --_ui-notice-stripe-surface: var(--ui-success-soft);
126
+ --_ui-notice-stripe-border: var(--ui-success-soft-border);
127
+ --_ui-surface-text: var(--ui-success-subtle-text);
128
+ }
129
+ :where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=warning"]:where(:scope, :not(:is([component]:not(template), [data-component]:not([component])), [data-slotted]:not([data-slotted~="ui-notice-stripe"]))) {
130
+ --_ui-notice-stripe-surface: var(--ui-warning-soft);
131
+ --_ui-notice-stripe-border: var(--ui-warning-soft-border);
132
+ --_ui-surface-text: var(--ui-warning-subtle-text);
133
+ }
134
+ :where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[data-ui-notice-stripe-state~="tone=danger"]:where(:scope, :not(:is([component]:not(template), [data-component]:not([component])), [data-slotted]:not([data-slotted~="ui-notice-stripe"]))) {
135
+ --_ui-notice-stripe-surface: var(--ui-danger-soft);
136
+ --_ui-notice-stripe-border: var(--ui-danger-soft-border);
137
+ --_ui-surface-text: var(--ui-danger-subtle-text);
138
+ }
139
+ .content:where(:scope, :scope *) {
140
+ display: flex !important;
141
+ flex: 1;
142
+ flex-wrap: wrap !important;
143
+ align-items: center !important;
144
+ gap: var(--ui-space-1) var(--ui-space-3) !important;
145
+ min-inline-size: 0;
146
+ }
147
+ .message:where(:scope, :scope *) {
148
+ flex: 1 1 16rem;
149
+ min-inline-size: 0;
150
+ overflow-wrap: anywhere;
151
+ }
152
+ .actions:where(:scope, :scope *) {
153
+ display: flex !important;
154
+ flex-wrap: wrap !important;
155
+ align-items: center !important;
156
+ justify-content: flex-end !important;
157
+ gap: var(--ui-space-2) !important;
158
+ min-inline-size: 0;
159
+ max-inline-size: 100%;
160
+ overflow-wrap: anywhere;
161
+ margin-inline-start: auto !important;
162
+ }
163
+ .actions:empty:where(:scope, :scope *) {
164
+ display: none !important;
165
+ }
166
+ .dismiss:where(:scope, :scope *) {
167
+ flex: none;
168
+ }
169
+ :where(:is([component~="ui-notice-stripe"]:not(template), [data-component~="ui-notice-stripe"]:not([component])))[hidden]:where(:scope, :not(:is([component]:not(template), [data-component]:not([component])), [data-slotted]:not([data-slotted~="ui-notice-stripe"]))) {
170
+ display: none !important;
171
+ }
172
+ }