@linto-ai/transcript-ui-ui 0.9.5 → 0.9.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@linto-ai/transcript-ui-ui",
3
- "version": "0.9.5",
3
+ "version": "0.9.7",
4
4
  "description": "Design-system components and CSS tokens for @linto-ai/transcript-ui",
5
5
  "keywords": [
6
6
  "vue",
@@ -86,11 +86,18 @@ const classes = computed(() => [
86
86
  --btn-height: 32px;
87
87
  --btn-gap: var(--spacing-xs);
88
88
 
89
+ /* Same reset as every other custom button in this codebase (see
90
+ EditableText, EditorCheckbox, Tabs, SpeakerPopover, TranscriptionTurn):
91
+ `all: unset` clears the UA button chrome (margin, appearance, inherited
92
+ font mismatches on Safari/Firefox, the Firefox ::-moz-focus-inner
93
+ padding) that the previous per-property overrides below left in place.
94
+ Every property the button actually needs is re-declared after it. */
95
+ all: unset;
96
+ box-sizing: border-box;
89
97
  display: inline-flex;
90
98
  align-items: center;
91
99
  justify-content: center;
92
100
  gap: var(--btn-gap);
93
- box-sizing: border-box;
94
101
  height: var(--btn-height);
95
102
  padding: var(--btn-padding-y) var(--btn-padding-x);
96
103
  font-family: var(--font-family);
@@ -64,25 +64,25 @@ function keyFor(item: T, index: number): string | number {
64
64
  </DropdownMenuTrigger>
65
65
  <DropdownMenuPortal disabled>
66
66
  <DropdownMenuContent
67
- class="popover-list"
67
+ class="transcript-ui-popover-list"
68
68
  position-strategy="absolute"
69
69
  :side="side"
70
70
  :align="align"
71
71
  :side-offset="sideOffset">
72
- <ul v-if="items.length > 0" class="popover-list__items">
72
+ <ul v-if="items.length > 0" class="transcript-ui-popover-list__items">
73
73
  <DropdownMenuItem
74
74
  v-for="(item, index) in items"
75
75
  :key="keyFor(item, index)"
76
76
  as="li"
77
- class="popover-list__item"
78
- :class="{ 'popover-list__item--current': isCurrent?.(item) }"
77
+ class="transcript-ui-popover-list__item"
78
+ :class="{ 'transcript-ui-popover-list__item--current': isCurrent?.(item) }"
79
79
  @select="emit('select', item)">
80
80
  <slot name="item" :item="item" />
81
81
  </DropdownMenuItem>
82
82
  </ul>
83
83
  <template v-if="$slots.footer">
84
- <div v-if="items.length > 0" class="popover-list__divider" />
85
- <div class="popover-list__footer">
84
+ <div v-if="items.length > 0" class="transcript-ui-popover-list__divider" />
85
+ <div class="transcript-ui-popover-list__footer">
86
86
  <slot name="footer" />
87
87
  </div>
88
88
  </template>
@@ -80,13 +80,17 @@ const emit = defineEmits<{
80
80
 
81
81
  /* ── The selectable button ── */
82
82
  .selectable-list-item__main {
83
+ /* Full reset (same convention as Button, EditableText, Tabs…): the
84
+ previous partial reset (background/border/font only) left margin,
85
+ padding, and appearance to whatever the host page's UA/global styles
86
+ happened to set. */
87
+ all: unset;
88
+ box-sizing: border-box;
83
89
  flex: 1;
84
90
  min-width: 0;
85
91
  display: flex;
86
92
  align-items: center;
87
93
  gap: var(--spacing-sm);
88
- background: none;
89
- border: none;
90
94
  font: inherit;
91
95
  color: var(--color-text-primary);
92
96
  text-align: left;
@@ -1,5 +1,5 @@
1
1
  /* Utility */
2
- .sr-only {
2
+ .transcript-ui-sr-only {
3
3
  position: absolute;
4
4
  width: 1px;
5
5
  height: 1px;
@@ -12,16 +12,16 @@
12
12
  }
13
13
 
14
14
  /* Overlay (shared by sidebar drawer + sheet select) */
15
- .editor-overlay {
15
+ .transcript-ui-overlay {
16
16
  position: fixed;
17
17
  inset: 0;
18
18
  background-color: rgba(0, 0, 0, 0.4);
19
19
  z-index: var(--z-overlay);
20
- animation: overlay-fade-in 200ms ease;
20
+ animation: transcript-ui-overlay-fade-in 200ms ease;
21
21
  }
22
22
 
23
23
  /* Drawer mobile (sidebar) */
24
- .sidebar-drawer {
24
+ .transcript-ui-sidebar-drawer {
25
25
  position: fixed;
26
26
  top: 0;
27
27
  right: 0;
@@ -30,13 +30,13 @@
30
30
  z-index: var(--z-drawer);
31
31
  background-color: var(--color-surface);
32
32
  box-shadow: var(--shadow-md);
33
- animation: drawer-slide-in 250ms ease;
33
+ animation: transcript-ui-drawer-slide-in 250ms ease;
34
34
  overflow-y: auto;
35
35
  display: flex;
36
36
  flex-direction: column;
37
37
  }
38
38
 
39
- .sidebar-close {
39
+ .transcript-ui-sidebar-close {
40
40
  position: absolute;
41
41
  top: var(--spacing-sm);
42
42
  right: var(--spacing-sm);
@@ -53,13 +53,13 @@
53
53
  z-index: 1;
54
54
  }
55
55
 
56
- .sidebar-close:hover {
56
+ .transcript-ui-sidebar-close:hover {
57
57
  background-color: var(--color-surface-hover);
58
58
  color: var(--color-text-primary);
59
59
  }
60
60
 
61
61
  /* Keyframes */
62
- @keyframes overlay-fade-in {
62
+ @keyframes transcript-ui-overlay-fade-in {
63
63
  from {
64
64
  opacity: 0;
65
65
  }
@@ -68,7 +68,7 @@
68
68
  }
69
69
  }
70
70
 
71
- @keyframes drawer-slide-in {
71
+ @keyframes transcript-ui-drawer-slide-in {
72
72
  from {
73
73
  translate: 100% 0;
74
74
  }
@@ -78,8 +78,8 @@
78
78
  }
79
79
 
80
80
  @media (prefers-reduced-motion: reduce) {
81
- .editor-overlay,
82
- .sidebar-drawer {
81
+ .transcript-ui-overlay,
82
+ .transcript-ui-sidebar-drawer {
83
83
  animation: none;
84
84
  }
85
85
  }
@@ -89,7 +89,7 @@
89
89
  transcript), and each backdrop-filter forces a separate WebRender backdrop
90
90
  render target — on a multi-hour document this balloons GPU/GTT memory to
91
91
  several GB and freezes weaker machines. The border/shadow alone read fine. */
92
- .waveform-container ::part(region) {
92
+ .transcript-ui-waveform-container ::part(region) {
93
93
  border-top: 2px solid var(--region-color, rgba(255, 255, 255, 0.4));
94
94
  border-bottom: 1px solid var(--region-color, rgba(255, 255, 255, 0.4));
95
95
  box-shadow:
@@ -2,7 +2,7 @@
2
2
  Kept global because Reka portals render outside the component's scoped
3
3
  CSS boundary. */
4
4
 
5
- .popover-list {
5
+ .transcript-ui-popover-list {
6
6
  min-width: 180px;
7
7
  padding: var(--spacing-xs);
8
8
  background-color: var(--color-surface);
@@ -13,7 +13,7 @@
13
13
  z-index: 50;
14
14
  }
15
15
 
16
- .popover-list__items {
16
+ .transcript-ui-popover-list__items {
17
17
  list-style: none;
18
18
  display: flex;
19
19
  flex-direction: column;
@@ -24,7 +24,7 @@
24
24
  overflow-y: auto;
25
25
  }
26
26
 
27
- .popover-list__item {
27
+ .transcript-ui-popover-list__item {
28
28
  all: unset;
29
29
  box-sizing: border-box;
30
30
  display: flex;
@@ -38,17 +38,17 @@
38
38
  cursor: pointer;
39
39
  }
40
40
 
41
- .popover-list__item:hover,
42
- .popover-list__item[data-highlighted] {
41
+ .transcript-ui-popover-list__item:hover,
42
+ .transcript-ui-popover-list__item[data-highlighted] {
43
43
  background-color: var(--color-surface-hover);
44
44
  }
45
45
 
46
- .popover-list__item:focus-visible {
46
+ .transcript-ui-popover-list__item:focus-visible {
47
47
  outline: 2px solid var(--color-primary);
48
48
  outline-offset: -2px;
49
49
  }
50
50
 
51
- .popover-list__item--current {
51
+ .transcript-ui-popover-list__item--current {
52
52
  background-color: color-mix(
53
53
  in srgb,
54
54
  var(--color-primary) 10%,
@@ -56,12 +56,12 @@
56
56
  );
57
57
  }
58
58
 
59
- .popover-list__divider {
59
+ .transcript-ui-popover-list__divider {
60
60
  height: 1px;
61
61
  background-color: var(--color-border);
62
62
  margin: var(--spacing-xs) 0;
63
63
  }
64
64
 
65
- .popover-list__footer {
65
+ .transcript-ui-popover-list__footer {
66
66
  padding: var(--spacing-xs);
67
67
  }
@@ -22,9 +22,15 @@
22
22
  * --color-border-light Light borders
23
23
  *
24
24
  * Typography, spacing, radius, and shadows are also overridable.
25
+ *
26
+ * Scoped to .transcript-ui-root (the embedder's root element) instead of
27
+ * :root — until the web-component wrapper puts this behind a real Shadow
28
+ * DOM, `:root`/`body`/`*` here would leak straight onto the host app's own
29
+ * page (its tokens, its font, its box-sizing reset on every element). :host
30
+ * stays for that future shadow-root case.
25
31
  */
26
32
 
27
- :root,
33
+ .transcript-ui-root,
28
34
  :host {
29
35
  /* Colors — light theme */
30
36
  --color-background: #f8f9fa;
@@ -92,8 +98,8 @@
92
98
  --glass-border: rgba(255, 255, 255, 0.3);
93
99
  }
94
100
 
95
- :host,
96
- body {
101
+ .transcript-ui-root,
102
+ :host {
97
103
  font-family: var(--font-family);
98
104
  font-size: var(--font-size-base);
99
105
  line-height: var(--line-height);
@@ -109,10 +115,12 @@ body {
109
115
  overflow: hidden;
110
116
  }
111
117
 
112
- /* Reset */
113
- *,
114
- *::before,
115
- *::after {
118
+ /* Reset, scoped to our own subtree so the host app's elements outside
119
+ .transcript-ui-root keep their own margin/padding/box-sizing. */
120
+ .transcript-ui-root,
121
+ .transcript-ui-root *,
122
+ .transcript-ui-root *::before,
123
+ .transcript-ui-root *::after {
116
124
  box-sizing: border-box;
117
125
  margin: 0;
118
126
  padding: 0;