@threadlabs/looma 0.10.12 → 0.11.1

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.
Files changed (154) hide show
  1. package/components/shared/editor.js +2 -26
  2. package/components/shared/icons.js +53 -0
  3. package/components/ui-action-bar/ui-action-bar.html +72 -0
  4. package/components/ui-avatar-group/ui-avatar-group.html +6 -6
  5. package/components/ui-avatar-group/ui-avatar-group.js +1 -1
  6. package/components/ui-breadcrumb-item/ui-breadcrumb-item.html +60 -0
  7. package/components/ui-breadcrumbs/ui-breadcrumbs.html +31 -0
  8. package/components/ui-card/ui-card.html +55 -0
  9. package/components/ui-combobox/ui-combobox.js +2 -2
  10. package/components/ui-context-menu/ui-context-menu.js +4 -4
  11. package/components/ui-cover/ui-cover.html +36 -0
  12. package/components/ui-description-item/ui-description-item.html +46 -0
  13. package/components/ui-description-list/ui-description-list.html +37 -0
  14. package/components/ui-icon/ui-icon.js +1 -1
  15. package/components/ui-menu/ui-menu.js +3 -3
  16. package/components/ui-page-header/ui-page-header.html +97 -0
  17. package/components/ui-radio/ui-radio.js +1 -1
  18. package/components/ui-radio-group/ui-radio-group.js +1 -1
  19. package/components/ui-section/ui-section.html +108 -0
  20. package/components/ui-spinner/ui-spinner.html +48 -0
  21. package/components/ui-status-message/ui-status-message.html +84 -0
  22. package/components/ui-text/ui-text.html +96 -0
  23. package/components/ui-tree/ui-tree.js +2 -2
  24. package/components/ui-tree-item/ui-tree-item.js +3 -3
  25. package/dist/index.js +1 -1
  26. package/editor/icons.d.ts +5 -0
  27. package/editor/index.js +6 -1
  28. package/package.json +1 -1
  29. package/styles/ui-action-bar.css +77 -0
  30. package/styles/ui-avatar-group.css +6 -6
  31. package/styles/ui-breadcrumb-item.css +57 -0
  32. package/styles/ui-breadcrumbs.css +32 -0
  33. package/styles/ui-card.css +51 -0
  34. package/styles/ui-cover.css +35 -0
  35. package/styles/ui-description-item.css +43 -0
  36. package/styles/ui-description-list.css +38 -0
  37. package/styles/ui-page-header.css +89 -0
  38. package/styles/ui-section.css +94 -0
  39. package/styles/ui-spinner.css +42 -0
  40. package/styles/ui-status-message.css +72 -0
  41. package/styles/ui-text.css +85 -0
  42. package/vanilla/UiActionBar.d.ts +13 -0
  43. package/vanilla/UiActionBar.js +59 -0
  44. package/vanilla/UiBreadcrumbItem.d.ts +14 -0
  45. package/vanilla/UiBreadcrumbItem.js +38 -0
  46. package/vanilla/UiBreadcrumbs.d.ts +14 -0
  47. package/vanilla/UiBreadcrumbs.js +39 -0
  48. package/vanilla/UiCard.d.ts +17 -0
  49. package/vanilla/UiCard.js +32 -0
  50. package/vanilla/UiCover.d.ts +14 -0
  51. package/vanilla/UiCover.js +28 -0
  52. package/vanilla/UiDescriptionItem.d.ts +14 -0
  53. package/vanilla/UiDescriptionItem.js +39 -0
  54. package/vanilla/UiDescriptionList.d.ts +14 -0
  55. package/vanilla/UiDescriptionList.js +28 -0
  56. package/vanilla/UiPageHeader.d.ts +14 -0
  57. package/vanilla/UiPageHeader.js +78 -0
  58. package/vanilla/UiSection.d.ts +16 -0
  59. package/vanilla/UiSection.js +64 -0
  60. package/vanilla/UiSpinner.d.ts +15 -0
  61. package/vanilla/UiSpinner.js +23 -0
  62. package/vanilla/UiStatusMessage.d.ts +16 -0
  63. package/vanilla/UiStatusMessage.js +53 -0
  64. package/vanilla/UiText.d.ts +20 -0
  65. package/vanilla/UiText.js +38 -0
  66. package/vanilla/index.js +12 -0
  67. package/vue/UiActionBar.d.ts +19 -0
  68. package/vue/UiActionBar.js +2 -0
  69. package/vue/UiActionBar.vue +77 -0
  70. package/vue/UiAvatarGroup.vue +6 -6
  71. package/vue/UiBreadcrumbItem.d.ts +18 -0
  72. package/vue/UiBreadcrumbItem.js +2 -0
  73. package/vue/UiBreadcrumbItem.vue +101 -0
  74. package/vue/UiBreadcrumbs.d.ts +18 -0
  75. package/vue/UiBreadcrumbs.js +2 -0
  76. package/vue/UiBreadcrumbs.vue +45 -0
  77. package/vue/UiCard.d.ts +24 -0
  78. package/vue/UiCard.js +2 -0
  79. package/vue/UiCard.vue +82 -0
  80. package/vue/UiCombobox.d.ts +1 -1
  81. package/vue/UiCover.d.ts +18 -0
  82. package/vue/UiCover.js +2 -0
  83. package/vue/UiCover.vue +57 -0
  84. package/vue/UiDescriptionItem.d.ts +18 -0
  85. package/vue/UiDescriptionItem.js +2 -0
  86. package/vue/UiDescriptionItem.vue +58 -0
  87. package/vue/UiDescriptionList.d.ts +18 -0
  88. package/vue/UiDescriptionList.js +2 -0
  89. package/vue/UiDescriptionList.vue +62 -0
  90. package/vue/UiIconButton.d.ts +1 -1
  91. package/vue/UiPageHeader.d.ts +26 -0
  92. package/vue/UiPageHeader.js +2 -0
  93. package/vue/UiPageHeader.vue +118 -0
  94. package/vue/UiRadioGroup.d.ts +1 -1
  95. package/vue/UiSection.d.ts +26 -0
  96. package/vue/UiSection.js +2 -0
  97. package/vue/UiSection.vue +128 -0
  98. package/vue/UiSpinner.d.ts +10 -0
  99. package/vue/UiSpinner.js +2 -0
  100. package/vue/UiSpinner.vue +87 -0
  101. package/vue/UiStatusMessage.d.ts +24 -0
  102. package/vue/UiStatusMessage.js +2 -0
  103. package/vue/UiStatusMessage.vue +121 -0
  104. package/vue/UiText.d.ts +30 -0
  105. package/vue/UiText.js +2 -0
  106. package/vue/UiText.vue +125 -0
  107. package/vue/chunks/UiActionBar.js +24 -0
  108. package/vue/chunks/UiAffordanceScope.js +1 -1
  109. package/vue/chunks/UiAvatar.js +1 -1
  110. package/vue/chunks/UiAvatarGroup.js +2 -2
  111. package/vue/chunks/UiBreadcrumbItem.js +50 -0
  112. package/vue/chunks/UiBreadcrumbs.js +19 -0
  113. package/vue/chunks/UiCard.js +31 -0
  114. package/vue/chunks/UiCheckbox.js +1 -1
  115. package/vue/chunks/UiCombobox.js +1 -1
  116. package/vue/chunks/UiContextMenu.js +1 -1
  117. package/vue/chunks/UiCover.js +21 -0
  118. package/vue/chunks/UiDescriptionItem.js +16 -0
  119. package/vue/chunks/UiDescriptionList.js +21 -0
  120. package/vue/chunks/UiDialog.js +1 -1
  121. package/vue/chunks/UiDisclosure.js +1 -1
  122. package/vue/chunks/UiEditable.js +1 -1
  123. package/vue/chunks/UiEditorInsertTableGrid.js +1 -1
  124. package/vue/chunks/UiEditorMentionMenu.js +1 -1
  125. package/vue/chunks/UiEditorSlashMenu.js +1 -1
  126. package/vue/chunks/UiEditorTableContextMenu.js +1 -1
  127. package/vue/chunks/UiEditorTableOverlay.js +1 -1
  128. package/vue/chunks/UiEditorTableToolbar.js +1 -1
  129. package/vue/chunks/UiFormField.js +1 -1
  130. package/vue/chunks/UiIcon.js +1 -1
  131. package/vue/chunks/UiIconButton.js +1 -1
  132. package/vue/chunks/UiInput.js +1 -1
  133. package/vue/chunks/UiMenu.js +1 -1
  134. package/vue/chunks/UiPageHeader.js +35 -0
  135. package/vue/chunks/UiPopover.js +1 -1
  136. package/vue/chunks/UiRadio.js +1 -1
  137. package/vue/chunks/UiRadioGroup.js +1 -1
  138. package/vue/chunks/UiSearchShell.js +1 -1
  139. package/vue/chunks/UiSection.js +34 -0
  140. package/vue/chunks/UiSelect.js +1 -1
  141. package/vue/chunks/UiSidebar.js +1 -1
  142. package/vue/chunks/UiSpinner.js +64 -0
  143. package/vue/chunks/UiStatusMessage.js +54 -0
  144. package/vue/chunks/UiSwitch.js +1 -1
  145. package/vue/chunks/UiTabs.js +1 -1
  146. package/vue/chunks/UiText.js +40 -0
  147. package/vue/chunks/UiTextarea.js +1 -1
  148. package/vue/chunks/UiToastRegion.js +1 -1
  149. package/vue/chunks/UiTooltip.js +1 -1
  150. package/vue/chunks/UiTree.js +1 -1
  151. package/vue/chunks/UiTreeItem.js +1 -1
  152. package/vue/components.css +577 -29
  153. package/vue/index.d.ts +12 -0
  154. package/vue/index.js +14 -2
@@ -0,0 +1,128 @@
1
+ <!-- Generated by HTML Next 1.0.0-alpha.5 for Vue 3.5. Do not edit. -->
2
+ <script setup lang="ts">
3
+ import { computed } from 'vue'
4
+
5
+ defineOptions({ inheritAttrs: false })
6
+
7
+ const props = withDefaults(
8
+ defineProps<{
9
+ heading?: string
10
+ tone?: 'neutral' | 'danger'
11
+ variant?: 'plain' | 'card' | 'divided'
12
+ }>(),
13
+ {
14
+ heading: '',
15
+ tone: 'neutral',
16
+ variant: 'plain',
17
+ },
18
+ )
19
+
20
+ /** The values the styles' :host-state() rules test. */
21
+ const hostState = computed(() =>
22
+ [
23
+ props.variant && `variant variant=${props.variant}`,
24
+ props.tone && `tone tone=${props.tone}`,
25
+ ].filter(Boolean).join(' ')
26
+ )
27
+ </script>
28
+
29
+ <template>
30
+ <section
31
+ data-component="ui-section"
32
+ v-bind="$attrs"
33
+ :data-ui-section-state="hostState || undefined"
34
+ >
35
+ <span class="head"><span class="copy"><h2 class="heading" :hidden="!heading">{{ heading }}</h2>
36
+ <span class="description"><slot name="description" /></span></span>
37
+ <span class="actions"><slot name="actions" /></span></span>
38
+ <span class="body"><slot /></span>
39
+ </section>
40
+ </template>
41
+
42
+ <style scoped>
43
+ /* A part of a view: a heading, an optional line under it, actions for the whole section at its
44
+ end, and the content. Sections space themselves out through the Stack around them. */
45
+ [data-component~="ui-section"] {
46
+ display: flex;
47
+ flex-direction: column;
48
+ gap: var(--ui-space-4);
49
+ min-inline-size: 0;
50
+ }
51
+
52
+ [data-component~="ui-section"][data-ui-section-state~="variant=card"] {
53
+ padding: var(--ui-space-5);
54
+ border: 1px solid var(--ui-border-default);
55
+ border-radius: var(--ui-radius-lg);
56
+ background: var(--ui-surface-raised);
57
+ }
58
+
59
+ [data-component~="ui-section"][data-ui-section-state~="variant=divided"] {
60
+ padding-block-start: var(--ui-space-6);
61
+ border-block-start: 1px solid var(--ui-border-default);
62
+ }
63
+
64
+ [data-component~="ui-section"][data-ui-section-state~="variant=card"][data-ui-section-state~="tone=danger"] {
65
+ border-color: var(--ui-danger);
66
+ }
67
+
68
+ .head {
69
+ display: flex;
70
+ flex-wrap: wrap;
71
+ align-items: flex-start;
72
+ justify-content: space-between;
73
+ gap: var(--ui-space-2) var(--ui-space-4);
74
+ }
75
+
76
+ .copy {
77
+ display: flex;
78
+ flex: 1 1 16rem;
79
+ flex-direction: column;
80
+ gap: var(--ui-space-1);
81
+ min-inline-size: 0;
82
+ }
83
+
84
+ .heading {
85
+ margin: 0;
86
+ color: var(--ui-text-primary);
87
+ font-size: var(--ui-font-size-lg);
88
+ font-weight: var(--ui-font-semibold);
89
+ line-height: var(--ui-line-height-tight);
90
+ }
91
+
92
+ [data-component~="ui-section"][data-ui-section-state~="tone=danger"] .heading {
93
+ color: var(--ui-danger);
94
+ }
95
+
96
+ .description {
97
+ color: var(--ui-text-secondary);
98
+ font-size: var(--ui-font-size-sm);
99
+ line-height: var(--ui-line-height);
100
+ }
101
+
102
+ .actions {
103
+ display: inline-flex;
104
+ flex-wrap: wrap;
105
+ gap: var(--ui-space-2);
106
+ }
107
+
108
+ .body {
109
+ display: flex;
110
+ flex-direction: column;
111
+ gap: var(--ui-space-4);
112
+ min-inline-size: 0;
113
+ }
114
+
115
+ .description:empty,
116
+ .actions:empty {
117
+ display: none;
118
+ }
119
+
120
+ .head:has(.heading[hidden]):has(.description:empty):has(.actions:empty) {
121
+ display: none;
122
+ }
123
+
124
+ /* A component that sets its display still honours the hidden attribute on its root. */
125
+ [data-component~="ui-section"][hidden] {
126
+ display: none;
127
+ }
128
+ </style>
@@ -0,0 +1,10 @@
1
+ type __VLS_Props = {
2
+ label?: string;
3
+ size?: 'sm' | 'md';
4
+ };
5
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
6
+ label: string;
7
+ size: "sm" | "md";
8
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
+ declare const _default: typeof __VLS_export;
10
+ export default _default;
@@ -0,0 +1,2 @@
1
+ import { t as UiSpinner_default } from "./chunks/UiSpinner.js";
2
+ export { UiSpinner_default as default };
@@ -0,0 +1,87 @@
1
+ <!-- Generated by HTML Next 1.0.0-alpha.5 for Vue 3.5. Do not edit. -->
2
+ <script setup lang="ts">
3
+ import { computed } from 'vue'
4
+ import UiIcon from './UiIcon.vue'
5
+
6
+ defineOptions({ inheritAttrs: false })
7
+
8
+ const props = withDefaults(
9
+ defineProps<{
10
+ label?: string
11
+ size?: 'sm' | 'md'
12
+ }>(),
13
+ {
14
+ label: '',
15
+ size: 'md',
16
+ },
17
+ )
18
+
19
+ /** The values the styles' :host-state() rules test. */
20
+ const hostState = computed(() =>
21
+ [
22
+ props.size && `size size=${props.size}`,
23
+ ].filter(Boolean).join(' ')
24
+ )
25
+
26
+ function text(value: unknown): string {
27
+ if (Array.isArray(value)) return value.map(text).join(' ')
28
+ return value === null || value === undefined || typeof value === 'object' ? '' : String(value)
29
+ }
30
+
31
+ function attribute(value: unknown): any {
32
+ if (
33
+ value === null || value === undefined || value === false
34
+ || (typeof value === 'object' && !Array.isArray(value))
35
+ ) return undefined
36
+ return value === true ? '' : text(value)
37
+ }
38
+ </script>
39
+
40
+ <template>
41
+ <span
42
+ data-component="ui-spinner"
43
+ v-bind="$attrs"
44
+ :role="attribute(({ true: 'status', false: null })[`${label !== ''}`])"
45
+ :aria-label="typeof (({ true: label, false: null })[`${label !== ''}`]) === 'boolean'
46
+ ? String(({ true: label, false: null })[`${label !== ''}`])
47
+ : attribute(({ true: label, false: null })[`${label !== ''}`])"
48
+ :aria-hidden="typeof (({ true: null, false: 'true' })[`${label !== ''}`]) === 'boolean'
49
+ ? String(({ true: null, false: 'true' })[`${label !== ''}`])
50
+ : attribute(({ true: null, false: 'true' })[`${label !== ''}`])"
51
+ :data-ui-spinner-state="hostState || undefined"
52
+ ><UiIcon name="loader" /></span>
53
+ </template>
54
+
55
+ <style scoped>
56
+ /* Something is on its way. It turns in the current text colour; with reduced motion it holds still,
57
+ and the label (or the text beside it) still says what is happening. */
58
+ [data-component~="ui-spinner"] {
59
+ display: inline-flex;
60
+ flex: none;
61
+ color: currentColor;
62
+ font-size: var(--ui-font-size-lg);
63
+ line-height: 1;
64
+ animation: ui-spinner-turn 0.8s linear infinite;
65
+ }
66
+
67
+ [data-component~="ui-spinner"][data-ui-spinner-state~="size=sm"] {
68
+ font-size: var(--ui-font-size-md);
69
+ }
70
+
71
+ @keyframes ui-spinner-turn {
72
+ to {
73
+ transform: rotate(1turn);
74
+ }
75
+ }
76
+
77
+ @media (prefers-reduced-motion: reduce) {
78
+ [data-component~="ui-spinner"] {
79
+ animation: none;
80
+ }
81
+ }
82
+
83
+ /* A component that sets its display still honours the hidden attribute on its root. */
84
+ [data-component~="ui-spinner"][hidden] {
85
+ display: none;
86
+ }
87
+ </style>
@@ -0,0 +1,24 @@
1
+ type __VLS_Props = {
2
+ heading?: string;
3
+ kind?: 'empty' | 'loading' | 'error';
4
+ layout?: 'inline' | 'panel' | 'fill';
5
+ };
6
+ declare var __VLS_6: {}, __VLS_8: {};
7
+ type __VLS_Slots = {} & {
8
+ default?: (props: typeof __VLS_6) => any;
9
+ } & {
10
+ action?: (props: typeof __VLS_8) => any;
11
+ };
12
+ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
13
+ kind: "empty" | "loading" | "error";
14
+ layout: "inline" | "panel" | "fill";
15
+ heading: string;
16
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
17
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
18
+ declare const _default: typeof __VLS_export;
19
+ export default _default;
20
+ type __VLS_WithSlots<T, S> = T & {
21
+ new (): {
22
+ $slots: S;
23
+ };
24
+ };
@@ -0,0 +1,2 @@
1
+ import { t as UiStatusMessage_default } from "./chunks/UiStatusMessage.js";
2
+ export { UiStatusMessage_default as default };
@@ -0,0 +1,121 @@
1
+ <!-- Generated by HTML Next 1.0.0-alpha.5 for Vue 3.5. Do not edit. -->
2
+ <script setup lang="ts">
3
+ import { computed } from 'vue'
4
+ import UiSpinner from './UiSpinner.vue'
5
+
6
+ defineOptions({ inheritAttrs: false })
7
+
8
+ const props = withDefaults(
9
+ defineProps<{
10
+ heading?: string
11
+ kind?: 'empty' | 'loading' | 'error'
12
+ layout?: 'inline' | 'panel' | 'fill'
13
+ }>(),
14
+ {
15
+ heading: '',
16
+ kind: 'empty',
17
+ layout: 'inline',
18
+ },
19
+ )
20
+
21
+ /** The values the styles' :host-state() rules test. */
22
+ const hostState = computed(() =>
23
+ [
24
+ props.kind && `kind kind=${props.kind}`,
25
+ props.layout && `layout layout=${props.layout}`,
26
+ ].filter(Boolean).join(' ')
27
+ )
28
+
29
+ function text(value: unknown): string {
30
+ if (Array.isArray(value)) return value.map(text).join(' ')
31
+ return value === null || value === undefined || typeof value === 'object' ? '' : String(value)
32
+ }
33
+
34
+ function attribute(value: unknown): any {
35
+ if (
36
+ value === null || value === undefined || value === false
37
+ || (typeof value === 'object' && !Array.isArray(value))
38
+ ) return undefined
39
+ return value === true ? '' : text(value)
40
+ }
41
+ </script>
42
+
43
+ <template>
44
+ <div
45
+ data-component="ui-status-message"
46
+ v-bind="$attrs"
47
+ :role="attribute(({ true: 'alert', false: 'status' })[`${kind === 'error'}`])"
48
+ :data-ui-status-message-state="hostState || undefined"
49
+ >
50
+ <UiSpinner size="sm" :hidden="kind !== 'loading'" />
51
+ <span class="copy"><strong class="heading" :hidden="!heading">{{ heading }}</strong>
52
+ <span class="message"><slot /></span></span>
53
+ <span class="action"><slot name="action" /></span>
54
+ </div>
55
+ </template>
56
+
57
+ <style scoped>
58
+ /* The one way a view says it is loading, has nothing yet, or failed, with an optional next step.
59
+ Every view says it the same way, in the same place, at the same size. */
60
+ [data-component~="ui-status-message"] {
61
+ display: flex;
62
+ flex-wrap: wrap;
63
+ align-items: center;
64
+ gap: var(--ui-space-2) var(--ui-space-4);
65
+ padding-block: var(--ui-space-4);
66
+ color: var(--ui-text-muted);
67
+ font-size: var(--ui-font-size-md);
68
+ line-height: var(--ui-line-height);
69
+ }
70
+
71
+ [data-component~="ui-status-message"][data-ui-status-message-state~="kind=error"] {
72
+ color: var(--ui-danger);
73
+ }
74
+
75
+ [data-component~="ui-status-message"][data-ui-status-message-state~="layout=panel"] {
76
+ padding: var(--ui-space-6);
77
+ border: 1px dashed var(--ui-border-default);
78
+ border-radius: var(--ui-radius-lg);
79
+ }
80
+
81
+ [data-component~="ui-status-message"][data-ui-status-message-state~="layout=fill"] {
82
+ flex: 1;
83
+ flex-direction: column;
84
+ justify-content: center;
85
+ min-block-size: 50vh;
86
+ text-align: center;
87
+ }
88
+
89
+ .copy {
90
+ display: flex;
91
+ flex: 1 1 12rem;
92
+ flex-direction: column;
93
+ gap: var(--ui-space-1);
94
+ min-inline-size: 0;
95
+ }
96
+
97
+ [data-component~="ui-status-message"][data-ui-status-message-state~="layout=fill"] .copy {
98
+ flex: none;
99
+ align-items: center;
100
+ }
101
+
102
+ .heading {
103
+ color: var(--ui-text-primary);
104
+ font-weight: var(--ui-font-semibold);
105
+ }
106
+
107
+ .action {
108
+ display: inline-flex;
109
+ flex-wrap: wrap;
110
+ gap: var(--ui-space-2);
111
+ }
112
+
113
+ .action:empty {
114
+ display: none;
115
+ }
116
+
117
+ /* A component that sets its display still honours the hidden attribute on its root. */
118
+ [data-component~="ui-status-message"][hidden] {
119
+ display: none;
120
+ }
121
+ </style>
@@ -0,0 +1,30 @@
1
+ type __VLS_Props = {
2
+ as?: 'p' | 'span' | 'div' | 'small' | 'strong' | 'label';
3
+ align?: 'start' | 'center';
4
+ size?: 'inherit' | 'xs' | 'sm' | 'md' | 'lg';
5
+ tone?: 'default' | 'secondary' | 'muted' | 'accent' | 'danger' | 'success';
6
+ truncate?: boolean;
7
+ variant?: 'body' | 'eyebrow' | 'code';
8
+ weight?: 'inherit' | 'normal' | 'medium' | 'semibold';
9
+ };
10
+ declare var __VLS_8: {};
11
+ type __VLS_Slots = {} & {
12
+ default?: (props: typeof __VLS_8) => any;
13
+ };
14
+ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
15
+ tone: "default" | "secondary" | "muted" | "accent" | "danger" | "success";
16
+ variant: "body" | "eyebrow" | "code";
17
+ as: "p" | "span" | "div" | "small" | "strong" | "label";
18
+ align: "start" | "center";
19
+ size: "inherit" | "xs" | "sm" | "md" | "lg";
20
+ truncate: boolean;
21
+ weight: "inherit" | "normal" | "medium" | "semibold";
22
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
23
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
24
+ declare const _default: typeof __VLS_export;
25
+ export default _default;
26
+ type __VLS_WithSlots<T, S> = T & {
27
+ new (): {
28
+ $slots: S;
29
+ };
30
+ };
package/vue/UiText.js ADDED
@@ -0,0 +1,2 @@
1
+ import { t as UiText_default } from "./chunks/UiText.js";
2
+ export { UiText_default as default };
package/vue/UiText.vue ADDED
@@ -0,0 +1,125 @@
1
+ <!-- Generated by HTML Next 1.0.0-alpha.5 for Vue 3.5. Do not edit. -->
2
+ <script setup lang="ts">
3
+ import { computed } from 'vue'
4
+
5
+ defineOptions({ inheritAttrs: false })
6
+
7
+ const props = withDefaults(
8
+ defineProps<{
9
+ as?: 'p' | 'span' | 'div' | 'small' | 'strong' | 'label'
10
+ align?: 'start' | 'center'
11
+ size?: 'inherit' | 'xs' | 'sm' | 'md' | 'lg'
12
+ tone?: 'default' | 'secondary' | 'muted' | 'accent' | 'danger' | 'success'
13
+ truncate?: boolean
14
+ variant?: 'body' | 'eyebrow' | 'code'
15
+ weight?: 'inherit' | 'normal' | 'medium' | 'semibold'
16
+ }>(),
17
+ {
18
+ as: 'p',
19
+ align: 'start',
20
+ size: 'inherit',
21
+ tone: 'default',
22
+ truncate: false,
23
+ variant: 'body',
24
+ weight: 'inherit',
25
+ },
26
+ )
27
+
28
+ /** The values the styles' :host-state() rules test. */
29
+ const hostState = computed(() =>
30
+ [
31
+ props.size && `size size=${props.size}`,
32
+ props.tone && `tone tone=${props.tone}`,
33
+ props.weight && `weight weight=${props.weight}`,
34
+ props.variant && `variant variant=${props.variant}`,
35
+ props.truncate && 'truncate',
36
+ props.align && `align align=${props.align}`,
37
+ ].filter(Boolean).join(' ')
38
+ )
39
+ </script>
40
+
41
+ <template>
42
+ <component
43
+ :is="as" data-component="ui-text" v-bind="$attrs" :data-ui-text-state="hostState || undefined">
44
+ <slot />
45
+ </component>
46
+ </template>
47
+
48
+ <style scoped>
49
+ /* Running text, set on the type scale and in a tone that says what it is, so a view never styles
50
+ text of its own. The root is a paragraph unless as= names a span, div, small, strong, or label. */
51
+ [data-component~="ui-text"] {
52
+ margin: 0;
53
+ min-inline-size: 0;
54
+ color: var(--ui-text-primary);
55
+ text-align: start;
56
+ }
57
+
58
+ [data-component~="ui-text"][data-ui-text-state~="size=xs"] {
59
+ font-size: var(--ui-font-size-xs);
60
+ line-height: var(--ui-line-height);
61
+ }
62
+ [data-component~="ui-text"][data-ui-text-state~="size=sm"] {
63
+ font-size: var(--ui-font-size-sm);
64
+ line-height: var(--ui-line-height);
65
+ }
66
+ [data-component~="ui-text"][data-ui-text-state~="size=md"] {
67
+ font-size: var(--ui-font-size-md);
68
+ line-height: var(--ui-line-height);
69
+ }
70
+ [data-component~="ui-text"][data-ui-text-state~="size=lg"] {
71
+ font-size: var(--ui-font-size-lg);
72
+ line-height: var(--ui-line-height-relaxed);
73
+ }
74
+
75
+ [data-component~="ui-text"][data-ui-text-state~="tone=secondary"] {
76
+ color: var(--ui-text-secondary);
77
+ }
78
+ [data-component~="ui-text"][data-ui-text-state~="tone=muted"] {
79
+ color: var(--ui-text-muted);
80
+ }
81
+ [data-component~="ui-text"][data-ui-text-state~="tone=accent"] {
82
+ color: var(--ui-accent-active);
83
+ }
84
+ [data-component~="ui-text"][data-ui-text-state~="tone=danger"] {
85
+ color: var(--ui-danger);
86
+ }
87
+ [data-component~="ui-text"][data-ui-text-state~="tone=success"] {
88
+ color: var(--ui-success);
89
+ }
90
+
91
+ [data-component~="ui-text"][data-ui-text-state~="weight=normal"] {
92
+ font-weight: var(--ui-font-normal);
93
+ }
94
+ [data-component~="ui-text"][data-ui-text-state~="weight=medium"] {
95
+ font-weight: var(--ui-font-medium);
96
+ }
97
+ [data-component~="ui-text"][data-ui-text-state~="weight=semibold"] {
98
+ font-weight: var(--ui-font-semibold);
99
+ }
100
+
101
+ [data-component~="ui-text"][data-ui-text-state~="variant=eyebrow"] {
102
+ font-size: var(--ui-font-size-xs);
103
+ font-weight: var(--ui-font-semibold);
104
+ letter-spacing: 0.06em;
105
+ text-transform: uppercase;
106
+ }
107
+ [data-component~="ui-text"][data-ui-text-state~="variant=code"] {
108
+ font-family: var(--ui-font-family-mono);
109
+ }
110
+
111
+ [data-component~="ui-text"][data-ui-text-state~="truncate"] {
112
+ overflow: hidden;
113
+ text-overflow: ellipsis;
114
+ white-space: nowrap;
115
+ }
116
+
117
+ [data-component~="ui-text"][data-ui-text-state~="align=center"] {
118
+ text-align: center;
119
+ }
120
+
121
+ /* A component that sets its display still honours the hidden attribute on its root. */
122
+ [data-component~="ui-text"][hidden] {
123
+ display: none;
124
+ }
125
+ </style>
@@ -0,0 +1,24 @@
1
+ import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
2
+ import { createElementBlock, createElementVNode, defineComponent, mergeProps, openBlock, renderSlot } from "vue";
3
+ //#region .build/vue/UiActionBar.vue?vue&type=script&setup=true&lang.ts
4
+ var _hoisted_1 = { class: "bar" };
5
+ var _hoisted_2 = { class: "tertiary" };
6
+ var _hoisted_3 = { class: "secondary" };
7
+ var _hoisted_4 = { class: "primary" };
8
+ //#endregion
9
+ //#region .build/vue/UiActionBar.vue
10
+ var UiActionBar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
11
+ inheritAttrs: false,
12
+ __name: "UiActionBar",
13
+ setup(__props) {
14
+ return (_ctx, _cache) => {
15
+ return openBlock(), createElementBlock("div", mergeProps({ "data-component": "ui-action-bar" }, _ctx.$attrs), [createElementVNode("div", _hoisted_1, [
16
+ createElementVNode("span", _hoisted_2, [renderSlot(_ctx.$slots, "tertiary", {}, void 0, true)]),
17
+ createElementVNode("span", _hoisted_3, [renderSlot(_ctx.$slots, "secondary", {}, void 0, true), renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
18
+ createElementVNode("span", _hoisted_4, [renderSlot(_ctx.$slots, "primary", {}, void 0, true)])
19
+ ])], 16);
20
+ };
21
+ }
22
+ }), [["__scopeId", "data-v-f4ba10f3"]]);
23
+ //#endregion
24
+ export { UiActionBar_default as t };
@@ -1,5 +1,5 @@
1
- import { n as useComponentHost, t as createDispatch } from "./host.js";
2
1
  import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
2
+ import { n as useComponentHost, t as createDispatch } from "./host.js";
3
3
  import { computed, createElementBlock, defineComponent, mergeProps, openBlock, ref, renderSlot } from "vue";
4
4
  import * as controllerModule from "@threadlabs/looma/components/ui-affordance-scope/ui-affordance-scope.js";
5
5
  //#region .build/vue/UiAffordanceScope.vue?vue&type=script&setup=true&lang.ts
@@ -1,5 +1,5 @@
1
- import { n as useComponentHost, t as createDispatch } from "./host.js";
2
1
  import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
2
+ import { n as useComponentHost, t as createDispatch } from "./host.js";
3
3
  import { createElementBlock, createElementVNode, defineComponent, mergeProps, openBlock, ref, renderSlot, toDisplayString, useTemplateRef } from "vue";
4
4
  import * as controllerModule from "@threadlabs/looma/components/ui-avatar/ui-avatar.js";
5
5
  //#region .build/vue/UiAvatar.vue?vue&type=script&setup=true&lang.ts
@@ -1,5 +1,5 @@
1
- import { n as useComponentHost, t as createDispatch } from "./host.js";
2
1
  import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
2
+ import { n as useComponentHost, t as createDispatch } from "./host.js";
3
3
  import { createElementBlock, createElementVNode, defineComponent, mergeProps, openBlock, ref, renderSlot, toDisplayString, useTemplateRef } from "vue";
4
4
  import * as controllerModule from "@threadlabs/looma/components/ui-avatar-group/ui-avatar-group.js";
5
5
  //#region .build/vue/UiAvatarGroup.vue?vue&type=script&setup=true&lang.ts
@@ -44,6 +44,6 @@ var UiAvatarGroup_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @
44
44
  }, toDisplayString(`+${overflowCount.value}`), 9, _hoisted_2)], 16, _hoisted_1);
45
45
  };
46
46
  }
47
- }), [["__scopeId", "data-v-9d727004"]]);
47
+ }), [["__scopeId", "data-v-6c48e0e3"]]);
48
48
  //#endregion
49
49
  export { UiAvatarGroup_default as t };
@@ -0,0 +1,50 @@
1
+ import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
2
+ import { t as UiIcon_default } from "./UiIcon.js";
3
+ import { computed, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, openBlock, renderSlot } from "vue";
4
+ //#region .build/vue/UiBreadcrumbItem.vue?vue&type=script&setup=true&lang.ts
5
+ var _hoisted_1 = ["aria-current", "data-ui-breadcrumb-item-state"];
6
+ var _hoisted_2 = {
7
+ class: "separator",
8
+ "aria-hidden": "true"
9
+ };
10
+ var _hoisted_3 = { class: "content" };
11
+ //#endregion
12
+ //#region .build/vue/UiBreadcrumbItem.vue
13
+ var UiBreadcrumbItem_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
14
+ inheritAttrs: false,
15
+ __name: "UiBreadcrumbItem",
16
+ props: { current: {
17
+ type: Boolean,
18
+ default: false
19
+ } },
20
+ setup(__props) {
21
+ const props = __props;
22
+ /** The values the styles' :host-state() rules test. */
23
+ const hostState = computed(() => [props.current && "current"].filter(Boolean).join(" "));
24
+ function text(value) {
25
+ if (Array.isArray(value)) return value.map(text).join(" ");
26
+ return value === null || value === void 0 || typeof value === "object" ? "" : String(value);
27
+ }
28
+ function attribute(value) {
29
+ if (value === null || value === void 0 || value === false || typeof value === "object" && !Array.isArray(value)) return void 0;
30
+ return value === true ? "" : text(value);
31
+ }
32
+ return (_ctx, _cache) => {
33
+ return openBlock(), createElementBlock("li", mergeProps({ "data-component": "ui-breadcrumb-item" }, _ctx.$attrs, {
34
+ "aria-current": typeof {
35
+ true: "page",
36
+ false: null
37
+ }[`${__props.current}`] === "boolean" ? String({
38
+ true: "page",
39
+ false: null
40
+ }[`${__props.current}`]) : attribute({
41
+ true: "page",
42
+ false: null
43
+ }[`${__props.current}`]),
44
+ "data-ui-breadcrumb-item-state": hostState.value || void 0
45
+ }), [createElementVNode("span", _hoisted_2, [createVNode(UiIcon_default, { name: "chevron-right" })]), createElementVNode("span", _hoisted_3, [renderSlot(_ctx.$slots, "default")])], 16, _hoisted_1);
46
+ };
47
+ }
48
+ }), [["__scopeId", "data-v-9de59def"]]);
49
+ //#endregion
50
+ export { UiBreadcrumbItem_default as t };
@@ -0,0 +1,19 @@
1
+ import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
2
+ import { createElementBlock, createElementVNode, defineComponent, mergeProps, openBlock, renderSlot } from "vue";
3
+ //#region .build/vue/UiBreadcrumbs.vue?vue&type=script&setup=true&lang.ts
4
+ var _hoisted_1 = ["aria-label"];
5
+ var _hoisted_2 = { role: "list" };
6
+ //#endregion
7
+ //#region .build/vue/UiBreadcrumbs.vue
8
+ var UiBreadcrumbs_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
9
+ inheritAttrs: false,
10
+ __name: "UiBreadcrumbs",
11
+ props: { label: { default: "Breadcrumb" } },
12
+ setup(__props) {
13
+ return (_ctx, _cache) => {
14
+ return openBlock(), createElementBlock("nav", mergeProps({ "data-component": "ui-breadcrumbs" }, _ctx.$attrs, { "aria-label": __props.label }), [createElementVNode("ol", _hoisted_2, [renderSlot(_ctx.$slots, "default", {}, void 0, true)])], 16, _hoisted_1);
15
+ };
16
+ }
17
+ }), [["__scopeId", "data-v-0d86d58e"]]);
18
+ //#endregion
19
+ export { UiBreadcrumbs_default as t };