@insymetri/styleguide 0.1.89 → 0.1.91

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.
@@ -58,6 +58,10 @@
58
58
  </script>
59
59
 
60
60
  <div bind:this={containerEl} class={cn('min-w-0 relative', className)}>
61
+ <!-- Edges come from `shadow-pill` / `shadow-selected-pill` rather than borders: a shadow
62
+ takes no layout space, so the row doesn't reflow as the selection moves. Uniform font
63
+ weight for the same reason. Selected is a step DOWN from white under a darker
64
+ hairline, so it reads pressed in while its neighbours read raised. -->
61
65
  {#snippet pill(tab: Tab)}
62
66
  <button
63
67
  class={cn(
@@ -66,8 +70,8 @@
66
70
  tab.disabled
67
71
  ? 'bg-surface text-tertiary opacity-50'
68
72
  : value === tab.value
69
- ? 'bg-gray-100 text-gray-700'
70
- : 'bg-surface text-secondary shadow-pill hover:bg-gray-100 hover:text-gray-700'
73
+ ? 'bg-background-alt text-body shadow-selected-pill'
74
+ : 'bg-surface text-secondary shadow-pill hover:bg-background-alt hover:text-secondary-strong'
71
75
  )}
72
76
  style="transition: all var(--transition-fast)"
73
77
  disabled={tab.disabled}
@@ -37,7 +37,7 @@
37
37
  </span>
38
38
  {/if}
39
39
  <Switch.Root
40
- class="group relative w-32 h-18 bg-strong rounded-full cursor-default transition-all duration-fast shrink-0 appearance-none border-none outline-none focus-visible:ring-3 focus-visible:ring-primary data-[state=checked]:bg-success data-[disabled]:opacity-50 motion-reduce:transition-none"
40
+ class="group relative w-32 h-18 bg-muted rounded-full cursor-default transition-all duration-fast shrink-0 appearance-none border-none outline-none focus-visible:ring-3 focus-visible:ring-primary data-[state=checked]:bg-success data-[disabled]:opacity-50 motion-reduce:transition-none"
41
41
  {checked}
42
42
  onCheckedChange={newChecked => {
43
43
  checked = newChecked
@@ -54,6 +54,9 @@
54
54
  /* Text */
55
55
  --ii-text-primary: #111827;
56
56
  --ii-text-accent: #111827;
57
+ /* Between secondary and body. Off the ramp, not a literal, so it follows a
58
+ consuming app's own neutrals. */
59
+ --ii-text-secondary-strong: var(--ii-gray-700);
57
60
  --ii-text-secondary: #6b7280;
58
61
  --ii-text-tertiary: #9ca3af;
59
62
  --ii-text-inverse: white;
@@ -48,6 +48,8 @@
48
48
  /* Text — neutral gray, brightest step softened so it doesn't glare on charcoal */
49
49
  --ii-text-primary: #dcdce0;
50
50
  --ii-text-accent: #ececee;
51
+ /* Ramp inverts here, so gray-700 again lands between secondary and primary. */
52
+ --ii-text-secondary-strong: var(--ii-gray-700);
51
53
  --ii-text-secondary: #9a9a9f;
52
54
  --ii-text-tertiary: #737377;
53
55
  --ii-text-inverse: #17171a;
@@ -125,6 +125,7 @@ export declare const textColor: {
125
125
  'dropdown-item-selected': string;
126
126
  body: string;
127
127
  secondary: string;
128
+ 'secondary-strong': string;
128
129
  tertiary: string;
129
130
  inverse: string;
130
131
  'on-primary': string;
@@ -158,6 +158,7 @@ export const textColor = {
158
158
  // Text hierarchy
159
159
  body: 'var(--ii-text-primary)',
160
160
  secondary: 'var(--ii-text-secondary)',
161
+ 'secondary-strong': 'var(--ii-text-secondary-strong)',
161
162
  tertiary: 'var(--ii-text-tertiary)',
162
163
  inverse: 'var(--ii-text-inverse)',
163
164
  'on-primary': 'var(--ii-text-on-primary)',
@@ -128,6 +128,7 @@ declare const _default: {
128
128
  'dropdown-item-selected': string;
129
129
  body: string;
130
130
  secondary: string;
131
+ 'secondary-strong': string;
131
132
  tertiary: string;
132
133
  inverse: string;
133
134
  'on-primary': string;
@@ -405,6 +406,7 @@ declare const _default: {
405
406
  boxShadow: {
406
407
  none: string;
407
408
  pill: string;
409
+ 'selected-pill': string;
408
410
  subtle: string;
409
411
  card: string;
410
412
  'comm-hover': string;
@@ -1,6 +1,7 @@
1
1
  export declare const boxShadow: {
2
2
  none: string;
3
3
  pill: string;
4
+ 'selected-pill': string;
4
5
  subtle: string;
5
6
  card: string;
6
7
  'comm-hover': string;
@@ -11,7 +11,11 @@ const T3 = 'var(--ii-shadow-3)';
11
11
  export const boxShadow = {
12
12
  none: 'none',
13
13
  // Tier 1 — at rest
14
- pill: T1,
14
+ // Inset hairline + the lift. T1 alone has no spread, so it only darkens the bottom edge;
15
+ // an outset ring would sit in that same band and paint over the glow.
16
+ pill: `inset 0 0 0 1px var(--ii-border), ${T1}`,
17
+ // Selected: same hairline, stronger tone, no lift. Ring-for-ring keeps widths stable.
18
+ 'selected-pill': 'inset 0 0 0 1px var(--ii-border-strong)',
15
19
  subtle: T1,
16
20
  card: T1,
17
21
  'comm-hover': T1,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@insymetri/styleguide",
3
- "version": "0.1.89",
3
+ "version": "0.1.91",
4
4
  "description": "Insymetri shared UI component library built with Svelte 5",
5
5
  "type": "module",
6
6
  "scripts": {