@aphexcms/ui 0.8.1 → 0.8.3

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.
@@ -0,0 +1,23 @@
1
+ <script lang="ts">
2
+ import { cn } from '../../../utils.js';
3
+ import type { ComponentProps } from 'svelte';
4
+ import { Separator } from '../separator/index.js';
5
+
6
+ let {
7
+ ref = $bindable(null),
8
+ class: className,
9
+ orientation = 'vertical',
10
+ ...restProps
11
+ }: ComponentProps<typeof Separator> = $props();
12
+ </script>
13
+
14
+ <Separator
15
+ bind:ref
16
+ data-slot="button-group-separator"
17
+ {orientation}
18
+ class={cn(
19
+ 'bg-input relative self-stretch data-[orientation=horizontal]:mx-px data-[orientation=horizontal]:w-auto data-[orientation=vertical]:my-px data-[orientation=vertical]:h-auto',
20
+ className
21
+ )}
22
+ {...restProps}
23
+ />
@@ -0,0 +1,13 @@
1
+ declare const ButtonGroupSeparator: import("svelte").Component<Omit<{
2
+ orientation?: import("bits-ui").Orientation;
3
+ decorative?: boolean;
4
+ }, "child" | "children"> & {
5
+ child?: import("svelte").Snippet<[{
6
+ props: Record<string, unknown>;
7
+ }]> | undefined;
8
+ children?: import("svelte").Snippet<[]> | undefined;
9
+ style?: import("bits-ui").StyleProperties | string | null | undefined;
10
+ ref?: HTMLElement | null | undefined;
11
+ } & import("bits-ui").Without<import("bits-ui").BitsPrimitiveDivAttributes, import("bits-ui").SeparatorRootPropsWithoutHTML>, {}, "ref">;
12
+ type ButtonGroupSeparator = ReturnType<typeof ButtonGroupSeparator>;
13
+ export default ButtonGroupSeparator;
@@ -0,0 +1,31 @@
1
+ <script lang="ts">
2
+ import { cn, type WithElementRef } from '../../../utils.js';
3
+ import type { HTMLAttributes } from 'svelte/elements';
4
+ import type { Snippet } from 'svelte';
5
+
6
+ let {
7
+ ref = $bindable(null),
8
+ class: className,
9
+ child,
10
+ ...restProps
11
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> & {
12
+ child?: Snippet<[{ props: Record<string, unknown> }]>;
13
+ } = $props();
14
+
15
+ const mergedProps = $derived({
16
+ ...restProps,
17
+ class: cn(
18
+ "bg-muted gap-2 rounded-lg border px-2.5 text-sm font-medium [&_svg:not([class*='size-'])]:size-4 flex items-center [&_svg]:pointer-events-none",
19
+ className
20
+ ),
21
+ 'data-slot': 'button-group-text'
22
+ });
23
+ </script>
24
+
25
+ {#if child}
26
+ {@render child({ props: mergedProps })}
27
+ {:else}
28
+ <div bind:this={ref} {...mergedProps}>
29
+ {@render mergedProps.children?.()}
30
+ </div>
31
+ {/if}
@@ -0,0 +1,11 @@
1
+ import { type WithElementRef } from '../../../utils.js';
2
+ import type { HTMLAttributes } from 'svelte/elements';
3
+ import type { Snippet } from 'svelte';
4
+ type $$ComponentProps = WithElementRef<HTMLAttributes<HTMLDivElement>> & {
5
+ child?: Snippet<[{
6
+ props: Record<string, unknown>;
7
+ }]>;
8
+ };
9
+ declare const ButtonGroupText: import("svelte").Component<$$ComponentProps, {}, "ref">;
10
+ type ButtonGroupText = ReturnType<typeof ButtonGroupText>;
11
+ export default ButtonGroupText;
@@ -0,0 +1,46 @@
1
+ <script lang="ts" module>
2
+ import { tv, type VariantProps } from 'tailwind-variants';
3
+
4
+ export const buttonGroupVariants = tv({
5
+ base: "has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg flex w-fit items-stretch [&>*]:focus-visible:relative [&>*]:focus-visible:z-10 [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1",
6
+ variants: {
7
+ orientation: {
8
+ horizontal:
9
+ '[&>[data-slot]:not(:has(~[data-slot]))]:rounded-r-lg! [&>[data-slot]]:rounded-r-none [&>[data-slot]~[data-slot]]:rounded-l-none [&>[data-slot]~[data-slot]]:border-l-0',
10
+ vertical:
11
+ '[&>[data-slot]:not(:has(~[data-slot]))]:rounded-b-lg! flex-col [&>[data-slot]]:rounded-b-none [&>[data-slot]~[data-slot]]:rounded-t-none [&>[data-slot]~[data-slot]]:border-t-0'
12
+ }
13
+ },
14
+ defaultVariants: {
15
+ orientation: 'horizontal'
16
+ }
17
+ });
18
+
19
+ export type ButtonGroupOrientation = VariantProps<typeof buttonGroupVariants>['orientation'];
20
+ </script>
21
+
22
+ <script lang="ts">
23
+ import { cn, type WithElementRef } from '../../../utils.js';
24
+ import type { HTMLAttributes } from 'svelte/elements';
25
+
26
+ let {
27
+ ref = $bindable(null),
28
+ class: className,
29
+ children,
30
+ orientation = 'horizontal',
31
+ ...restProps
32
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> & {
33
+ orientation?: ButtonGroupOrientation;
34
+ } = $props();
35
+ </script>
36
+
37
+ <div
38
+ bind:this={ref}
39
+ role="group"
40
+ data-slot="button-group"
41
+ data-orientation={orientation}
42
+ class={cn(buttonGroupVariants({ orientation }), className)}
43
+ {...restProps}
44
+ >
45
+ {@render children?.()}
46
+ </div>
@@ -0,0 +1,26 @@
1
+ import { type VariantProps } from 'tailwind-variants';
2
+ export declare const buttonGroupVariants: import("tailwind-variants").TVReturnType<{
3
+ orientation: {
4
+ horizontal: string;
5
+ vertical: string;
6
+ };
7
+ }, undefined, "has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg flex w-fit items-stretch [&>*]:focus-visible:relative [&>*]:focus-visible:z-10 [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1", {
8
+ orientation: {
9
+ horizontal: string;
10
+ vertical: string;
11
+ };
12
+ }, undefined, import("tailwind-variants").TVReturnType<{
13
+ orientation: {
14
+ horizontal: string;
15
+ vertical: string;
16
+ };
17
+ }, undefined, "has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg flex w-fit items-stretch [&>*]:focus-visible:relative [&>*]:focus-visible:z-10 [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1", unknown, unknown, undefined>>;
18
+ export type ButtonGroupOrientation = VariantProps<typeof buttonGroupVariants>['orientation'];
19
+ import { type WithElementRef } from '../../../utils.js';
20
+ import type { HTMLAttributes } from 'svelte/elements';
21
+ type $$ComponentProps = WithElementRef<HTMLAttributes<HTMLDivElement>> & {
22
+ orientation?: ButtonGroupOrientation;
23
+ };
24
+ declare const ButtonGroup: import("svelte").Component<$$ComponentProps, {}, "ref">;
25
+ type ButtonGroup = ReturnType<typeof ButtonGroup>;
26
+ export default ButtonGroup;
@@ -0,0 +1,4 @@
1
+ import Root, { buttonGroupVariants, type ButtonGroupOrientation } from './button-group.svelte';
2
+ import Text from './button-group-text.svelte';
3
+ import Separator from './button-group-separator.svelte';
4
+ export { Root, Text, Separator, buttonGroupVariants, type ButtonGroupOrientation, Root as ButtonGroup, Text as ButtonGroupText, Separator as ButtonGroupSeparator };
@@ -0,0 +1,6 @@
1
+ import Root, { buttonGroupVariants } from './button-group.svelte';
2
+ import Text from './button-group-text.svelte';
3
+ import Separator from './button-group-separator.svelte';
4
+ export { Root, Text, Separator, buttonGroupVariants,
5
+ //
6
+ Root as ButtonGroup, Text as ButtonGroupText, Separator as ButtonGroupSeparator };
@@ -21,5 +21,6 @@ declare const Root: import("svelte").Component<{
21
21
  children?: import("svelte").Snippet | undefined;
22
22
  } & {
23
23
  _internal_variant?: "context-menu" | "dropdown-menu" | "menubar";
24
+ _internal_should_skip_exit_animation?: () => boolean;
24
25
  }, {}, "open">;
25
26
  export { CheckboxItem, Content, Root as DropdownMenu, CheckboxItem as DropdownMenuCheckboxItem, Content as DropdownMenuContent, Group as DropdownMenuGroup, Item as DropdownMenuItem, Label as DropdownMenuLabel, RadioGroup as DropdownMenuRadioGroup, RadioItem as DropdownMenuRadioItem, Separator as DropdownMenuSeparator, Shortcut as DropdownMenuShortcut, Sub as DropdownMenuSub, SubContent as DropdownMenuSubContent, SubTrigger as DropdownMenuSubTrigger, Trigger as DropdownMenuTrigger, GroupHeading as DropdownMenuGroupHeading, Group, GroupHeading, Item, Label, RadioGroup, RadioItem, Root, Separator, Shortcut, Sub, SubContent, SubTrigger, Trigger };
@@ -21,6 +21,15 @@ class SidebarState {
21
21
  // Event handler to apply to the `<svelte:window>`
22
22
  handleShortcutKeydown = (e) => {
23
23
  if (e.key === SIDEBAR_KEYBOARD_SHORTCUT && (e.metaKey || e.ctrlKey)) {
24
+ // Don't steal the shortcut while the user is typing in an editable field —
25
+ // Cmd/Ctrl+B is bold in the rich-text editor, and this global toggle would
26
+ // otherwise fire alongside it. Bail for inputs, textareas, and any
27
+ // contenteditable (ProseMirror) surface.
28
+ const target = e.target;
29
+ if (target instanceof HTMLElement &&
30
+ (target.isContentEditable || target.closest('input, textarea, [contenteditable="true"]'))) {
31
+ return;
32
+ }
24
33
  e.preventDefault();
25
34
  this.toggle();
26
35
  }
@@ -2,7 +2,7 @@ declare const SidebarInput: import("svelte").Component<(Omit<import("svelte/elem
2
2
  type: "file";
3
3
  files?: FileList;
4
4
  } | {
5
- type?: "number" | "hidden" | "color" | "submit" | "reset" | "button" | (string & {}) | "search" | "checkbox" | "radio" | "text" | "tel" | "url" | "email" | "date" | "time" | "datetime-local" | "image" | "month" | "password" | "range" | "week";
5
+ type?: "number" | "hidden" | "color" | "button" | "search" | "time" | "image" | "text" | "submit" | "reset" | (string & {}) | "checkbox" | "radio" | "tel" | "url" | "email" | "date" | "datetime-local" | "month" | "password" | "range" | "week";
6
6
  files?: undefined;
7
7
  })) & {
8
8
  ref?: HTMLElement | null | undefined;
@@ -0,0 +1,2 @@
1
+ import Root from './slider.svelte';
2
+ export { Root, Root as Slider };
@@ -0,0 +1,4 @@
1
+ import Root from './slider.svelte';
2
+ export { Root,
3
+ //
4
+ Root as Slider };
@@ -0,0 +1,50 @@
1
+ <script lang="ts">
2
+ import { Slider as SliderPrimitive } from 'bits-ui';
3
+ import { cn, type WithoutChildrenOrChild } from '../../../utils.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ value = $bindable(),
8
+ orientation = 'horizontal',
9
+ class: className,
10
+ ...restProps
11
+ }: WithoutChildrenOrChild<SliderPrimitive.RootProps> = $props();
12
+ </script>
13
+
14
+ <!--
15
+ Discriminated Unions + Destructing (required for bindable) do not
16
+ get along, so we shut typescript up by casting `value` to `never`.
17
+ -->
18
+ <SliderPrimitive.Root
19
+ bind:ref
20
+ bind:value={value as never}
21
+ data-slot="slider"
22
+ {orientation}
23
+ class={cn(
24
+ 'relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-vertical:h-full data-vertical:min-h-40 data-vertical:w-auto data-vertical:flex-col',
25
+ className
26
+ )}
27
+ {...restProps}
28
+ >
29
+ {#snippet children({ thumbItems })}
30
+ <span
31
+ data-slot="slider-track"
32
+ data-orientation={orientation}
33
+ class={cn(
34
+ 'bg-muted bg-muted relative grow overflow-hidden rounded-full data-horizontal:h-1 data-horizontal:w-full data-horizontal:w-full data-vertical:h-full data-vertical:h-full data-vertical:w-1'
35
+ )}
36
+ >
37
+ <SliderPrimitive.Range
38
+ data-slot="slider-range"
39
+ class={cn('bg-primary absolute select-none data-horizontal:h-full data-vertical:w-full')}
40
+ />
41
+ </span>
42
+ {#each thumbItems as thumb (thumb.index)}
43
+ <SliderPrimitive.Thumb
44
+ data-slot="slider-thumb"
45
+ index={thumb.index}
46
+ class="border-ring ring-ring/50 relative block size-3 shrink-0 rounded-full border bg-white transition-[color,box-shadow] select-none after:absolute after:-inset-2 hover:ring-3 focus-visible:ring-3 focus-visible:outline-hidden active:ring-3 disabled:pointer-events-none disabled:opacity-50"
47
+ />
48
+ {/each}
49
+ {/snippet}
50
+ </SliderPrimitive.Root>
@@ -0,0 +1,5 @@
1
+ import { Slider as SliderPrimitive } from 'bits-ui';
2
+ import { type WithoutChildrenOrChild } from '../../../utils.js';
3
+ declare const Slider: import("svelte").Component<WithoutChildrenOrChild<SliderPrimitive.RootProps>, {}, "ref" | "value">;
4
+ type Slider = ReturnType<typeof Slider>;
5
+ export default Slider;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aphexcms/ui",
3
- "version": "0.8.1",
3
+ "version": "0.8.3",
4
4
  "description": "Shared UI components for Aphex CMS (shadcn-svelte)",
5
5
  "license": "MIT",
6
6
  "publishConfig": {
@@ -45,6 +45,11 @@
45
45
  "svelte": "./dist/components/ui/button/index.js",
46
46
  "default": "./dist/components/ui/button/index.js"
47
47
  },
48
+ "./shadcn/button-group": {
49
+ "types": "./dist/components/ui/button-group/index.d.ts",
50
+ "svelte": "./dist/components/ui/button-group/index.js",
51
+ "default": "./dist/components/ui/button-group/index.js"
52
+ },
48
53
  "./shadcn/calendar": {
49
54
  "types": "./dist/components/ui/calendar/index.d.ts",
50
55
  "svelte": "./dist/components/ui/calendar/index.js",
@@ -125,6 +130,11 @@
125
130
  "svelte": "./dist/components/ui/skeleton/index.js",
126
131
  "default": "./dist/components/ui/skeleton/index.js"
127
132
  },
133
+ "./shadcn/slider": {
134
+ "types": "./dist/components/ui/slider/index.d.ts",
135
+ "svelte": "./dist/components/ui/slider/index.js",
136
+ "default": "./dist/components/ui/slider/index.js"
137
+ },
128
138
  "./shadcn/sonner": {
129
139
  "types": "./dist/components/ui/sonner/index.d.ts",
130
140
  "svelte": "./dist/components/ui/sonner/index.js",
@@ -168,13 +178,13 @@
168
178
  "tailwind-variants": "^3.2.2"
169
179
  },
170
180
  "devDependencies": {
171
- "@internationalized/date": "^3.10.0",
181
+ "@internationalized/date": "^3.12.2",
172
182
  "@lucide/svelte": "^0.561.0",
173
183
  "@sveltejs/kit": "^2.59.1",
174
184
  "@sveltejs/package": "^2.5.6",
175
185
  "@sveltejs/vite-plugin-svelte": "^6.2.1",
176
186
  "@tailwindcss/vite": "^4.1.17",
177
- "bits-ui": "^2.14.4",
187
+ "bits-ui": "^2.18.1",
178
188
  "clsx": "^2.1.1",
179
189
  "mode-watcher": "^1.1.0",
180
190
  "svelte": "^5.55.5",
package/src/app.css CHANGED
@@ -4,149 +4,131 @@
4
4
 
5
5
  @custom-variant dark (&:is(.dark *));
6
6
 
7
+ /* bits-ui sets data-orientation on slider/progress parts; the shadcn components use
8
+ `data-horizontal:`/`data-vertical:` variants to size the track. Declare them so those
9
+ utilities resolve (otherwise the slider track collapses to zero height — invisible). */
10
+ @custom-variant data-horizontal (&[data-orientation='horizontal']);
11
+ @custom-variant data-vertical (&[data-orientation='vertical']);
12
+
13
+ @import 'tailwindcss';
14
+
15
+ @custom-variant dark (&:is(.dark *));
16
+
7
17
  :root {
8
- --background: oklch(0.98 0.01 95.1);
9
- --foreground: oklch(0.34 0.03 95.72);
10
- --card: oklch(0.98 0.01 95.1);
11
- --card-foreground: oklch(0.19 0 106.59);
18
+ --background: oklch(0.9846 0.0017 247.8389);
19
+ --foreground: oklch(0.2809 0 0);
20
+ --card: oklch(1 0 0);
21
+ --card-foreground: oklch(0.2809 0 0);
12
22
  --popover: oklch(1 0 0);
13
- --popover-foreground: oklch(0.27 0.02 98.94);
14
- --primary: oklch(0.62 0.14 39.04);
23
+ --popover-foreground: oklch(0.2809 0 0);
24
+ --primary: oklch(0.6802 0.1902 32.0008);
15
25
  --primary-foreground: oklch(1 0 0);
16
- --secondary: oklch(0.92 0.01 92.99);
17
- --secondary-foreground: oklch(0.43 0.02 98.6);
18
- --muted: oklch(0.93 0.02 90.24);
19
- --muted-foreground: oklch(0.61 0.01 97.42);
20
- --accent: oklch(0.92 0.01 92.99);
21
- --accent-foreground: oklch(0.27 0.02 98.94);
22
- --destructive: oklch(0.58 0.2 27);
23
- --border: oklch(0.88 0.01 97.36);
24
- --input: oklch(0.76 0.02 98.35);
25
- --ring: oklch(0.59 0.17 253.06);
26
- --chart-1: oklch(0.56 0.13 43);
27
- --chart-2: oklch(0.69 0.16 290.41);
28
- --chart-3: oklch(0.88 0.03 93.13);
29
- --chart-4: oklch(0.88 0.04 298.18);
30
- --chart-5: oklch(0.56 0.13 42.06);
31
- --sidebar: oklch(0.97 0.01 98.88);
32
- --sidebar-foreground: oklch(0.36 0.01 106.65);
33
- --sidebar-primary: oklch(0.62 0.14 39.04);
34
- --sidebar-primary-foreground: oklch(0.99 0 0);
35
- --sidebar-accent: oklch(0.92 0.01 92.99);
36
- --sidebar-accent-foreground: oklch(0.33 0 0);
37
- --sidebar-border: oklch(0.94 0 0);
38
- --sidebar-ring: oklch(0.77 0 0);
26
+ --secondary: oklch(0.9394 0.0046 258.3251);
27
+ --secondary-foreground: oklch(0.4489 0.02 251.0512);
28
+ --muted: oklch(0.9697 0.0017 247.8393);
29
+ --muted-foreground: oklch(0.4999 0.0154 251.6849);
30
+ --accent: oklch(0.9204 0.0203 238.6791);
31
+ --accent-foreground: oklch(0.3808 0.1001 259.7551);
32
+ --destructive: oklch(0.6509 0.2199 25.0358);
39
33
  --destructive-foreground: oklch(1 0 0);
40
- --radius: 0.5rem;
41
- --shadow-2xs: 0px 4px 8px -1px hsl(0 0% 0% / 0.05);
42
- --shadow-xs: 0px 4px 8px -1px hsl(0 0% 0% / 0.05);
43
- --shadow-sm: 0px 4px 8px -1px hsl(0 0% 0% / 0.1), 0px 1px 2px -2px hsl(0 0% 0% / 0.1);
44
- --shadow: 0px 4px 8px -1px hsl(0 0% 0% / 0.1), 0px 1px 2px -2px hsl(0 0% 0% / 0.1);
45
- --shadow-md: 0px 4px 8px -1px hsl(0 0% 0% / 0.1), 0px 2px 4px -2px hsl(0 0% 0% / 0.1);
46
- --shadow-lg: 0px 4px 8px -1px hsl(0 0% 0% / 0.1), 0px 4px 6px -2px hsl(0 0% 0% / 0.1);
47
- --shadow-xl: 0px 4px 8px -1px hsl(0 0% 0% / 0.1), 0px 8px 10px -2px hsl(0 0% 0% / 0.1);
48
- --shadow-2xl: 0px 4px 8px -1px hsl(0 0% 0% / 0.25);
34
+ --border: oklch(0.9209 0.0035 247.8607);
35
+ --input: oklch(0.9659 0.0025 228.7842);
36
+ --ring: oklch(0.6802 0.1902 32.0008);
37
+ --chart-1: oklch(0.7011 0.1193 239.6974);
38
+ --chart-2: oklch(0.7449 0.1558 32.2982);
39
+ --chart-3: oklch(0.765 0.177 163.223);
40
+ --chart-4: oklch(0.879 0.169 91.605);
41
+ --chart-5: oklch(0.785 0.115 274.713);
42
+ --sidebar: oklch(0.9757 0.0017 247.8391);
43
+ --sidebar-foreground: oklch(0.3211 0 0);
44
+ --sidebar-primary: oklch(0.6802 0.1902 32.0008);
45
+ --sidebar-primary-foreground: oklch(1 0 0);
46
+ --sidebar-accent: oklch(0.9204 0.0203 238.6791);
47
+ --sidebar-accent-foreground: oklch(0.3808 0.1001 259.7551);
48
+ --sidebar-border: oklch(0.9106 0.006 239.8262);
49
+ --sidebar-ring: oklch(0.6802 0.1902 32.0008);
50
+ --font-sans: Inter, sans-serif;
51
+ --font-serif: Source Serif 4, serif;
52
+ --font-mono: JetBrains Mono, monospace;
53
+ --radius: 0.75rem;
54
+ --shadow-x: 0px;
55
+ --shadow-y: 1px;
56
+ --shadow-blur: 3px;
57
+ --shadow-spread: 0px;
58
+ --shadow-opacity: 0.1;
59
+ --shadow-color: #29303d;
60
+ --shadow-2xs: 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.05);
61
+ --shadow-xs: 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.05);
62
+ --shadow-sm:
63
+ 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.1), 0px 1px 2px -1px hsl(219 19.6078% 20% / 0.1);
64
+ --shadow:
65
+ 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.1), 0px 1px 2px -1px hsl(219 19.6078% 20% / 0.1);
66
+ --shadow-md:
67
+ 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.1), 0px 2px 4px -1px hsl(219 19.6078% 20% / 0.1);
68
+ --shadow-lg:
69
+ 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.1), 0px 4px 6px -1px hsl(219 19.6078% 20% / 0.1);
70
+ --shadow-xl:
71
+ 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.1), 0px 8px 10px -1px hsl(219 19.6078% 20% / 0.1);
72
+ --shadow-2xl: 0px 1px 3px 0px hsl(219 19.6078% 20% / 0.25);
49
73
  --tracking-normal: 0em;
50
- /* Thinner hairline variant for large dividers — dark mode overrides this */
51
- --rule: oklch(0.9 0.005 95);
74
+ --spacing: 0.25rem;
52
75
  }
53
76
 
54
77
  .dark {
55
- /* ——— Aphex "Night" palette, lifted one notch for a brighter admin ——— */
56
- --night-0: oklch(0.11 0.028 256); /* deep horizon (was 0.08) */
57
- --night-1: oklch(0.16 0.032 258); /* sky mid — main bg (was 0.13) */
58
- --night-2: oklch(0.22 0.04 260); /* sky top — cards/panes (was 0.20) */
59
- --night-3: oklch(0.29 0.05 262);
60
- --form: oklch(0.1 0.012 260);
61
- --form-edge: oklch(0.17 0.025 260);
62
-
63
- --bone: oklch(0.95 0.015 82);
64
- --bone-2: oklch(0.88 0.018 82);
65
- --bone-3: oklch(0.72 0.02 82);
66
- --bone-4: oklch(0.55 0.02 82);
67
-
68
- /* Match light-mode --primary so the brand orange is identical across themes */
69
- --brand: oklch(0.62 0.14 39.04);
70
- --brand-2: oklch(0.7 0.14 41);
71
- --brand-deep: oklch(0.5 0.15 30);
72
- --glow-strength: 0.32;
73
-
74
- /* Two hairline levels:
75
- --rule stays whisper-thin (used on large structural dividers like the doc editor)
76
- --rule-2 is stronger — that's what --border maps to so individual components
77
- (buttons, inputs, badges, cards) get a visible edge */
78
- --rule: color-mix(in oklab, var(--bone) 9%, transparent);
79
- --rule-2: color-mix(in oklab, var(--bone) 22%, transparent);
80
-
81
- /* ——— Shadcn-mapped tokens ——— */
82
- /* Solid blue background — more visibly blue than the near-black night-0 */
83
- --background: var(--night-1);
84
- --foreground: var(--bone);
85
-
86
- /* Cards — one step lighter than bg so they read as lifted panes */
87
- --card: var(--night-2);
88
- --card-foreground: var(--bone);
89
-
90
- --popover: var(--night-2);
91
- --popover-foreground: var(--bone);
92
-
93
- /* BRAND primary — burnt orange, used sparingly */
94
- --primary: var(--brand);
95
- --primary-foreground: var(--bone);
96
-
97
- --secondary: var(--night-2);
98
- --secondary-foreground: var(--bone-2);
99
-
100
- --muted: var(--night-2);
101
- --muted-foreground: var(--bone-3);
102
-
103
- /* Accent = SUBTLE hover surface (NOT brand) — a whisper of bone */
104
- --accent: color-mix(in oklab, var(--bone) 6%, transparent);
105
- --accent-foreground: var(--bone);
106
-
107
- --destructive: oklch(0.58 0.2 27);
108
- --destructive-foreground: var(--bone);
109
-
110
- /* --border → stronger rule (components need visible edges); doc editor can opt into
111
- bg-rule / border-rule on its large panels if it wants the whisper-thin variant */
112
- --border: var(--rule-2);
113
- --input: var(--rule-2);
114
- --ring: var(--brand);
115
-
116
- --chart-1: var(--brand);
117
- --chart-2: var(--brand-2);
118
- --chart-3: var(--brand-deep);
119
- --chart-4: var(--night-3);
120
- --chart-5: var(--bone-3);
121
-
122
- /* Sidebar — same hue/chroma as --background (night-1, 0.16 0.032 258), just a touch darker */
123
- --sidebar: oklch(0.15 0.032 258);
124
- --sidebar-foreground: var(--bone-2);
125
- --sidebar-primary: var(--brand);
126
- --sidebar-primary-foreground: var(--bone);
127
- --sidebar-accent: color-mix(in oklab, var(--bone) 6%, transparent);
128
- --sidebar-accent-foreground: var(--bone);
129
- --sidebar-border: var(--rule);
130
- --sidebar-ring: var(--brand);
131
-
132
- --radius: 0.5rem;
133
-
134
- /* Shadows tuned to the cool blue-black bg — deeper saturation, longer falloff */
135
- --shadow-2xs: 0 1px 2px -1px oklch(0 0 0 / 0.5);
136
- --shadow-xs: 0 2px 6px -2px oklch(0 0 0 / 0.55);
137
- --shadow-sm: 0 4px 14px -4px oklch(0 0 0 / 0.55), 0 1px 2px -1px oklch(0 0 0 / 0.4);
138
- --shadow: 0 8px 24px -8px oklch(0 0 0 / 0.6), 0 2px 4px -2px oklch(0 0 0 / 0.45);
139
- --shadow-md: 0 12px 32px -10px oklch(0 0 0 / 0.6), 0 4px 8px -4px oklch(0 0 0 / 0.5);
140
- --shadow-lg: 0 20px 48px -14px oklch(0 0 0 / 0.65), 0 8px 16px -8px oklch(0 0 0 / 0.5);
141
- --shadow-xl: 0 32px 64px -20px oklch(0 0 0 / 0.7), 0 12px 24px -12px oklch(0 0 0 / 0.55);
142
- --shadow-2xl: 0 48px 96px -28px oklch(0 0 0 / 0.75);
143
-
144
- /* Brand glow — use on buttons / focused inputs to echo the landing's window-glow.
145
- Glow strength scales ring + drop-shadow opacity together. */
146
- --glow-brand:
147
- 0 0 0 1px color-mix(in oklab, var(--brand) calc(var(--glow-strength) * 75%), transparent),
148
- 0 16px 40px -12px
149
- color-mix(in oklab, var(--brand) calc(var(--glow-strength) * 94%), transparent);
78
+ --background: oklch(0.2188 0.0148 248.507);
79
+ --foreground: oklch(0.9189 0 0);
80
+ --card: oklch(0.2617 0.0197 254.8441);
81
+ --card-foreground: oklch(0.9189 0 0);
82
+ --popover: oklch(0.2617 0.0197 254.8441);
83
+ --popover-foreground: oklch(0.9189 0 0);
84
+ --primary: oklch(0.6802 0.1902 32.0008);
85
+ --primary-foreground: oklch(1 0 0);
86
+ --secondary: oklch(0.2988 0.0207 257.2741);
87
+ --secondary-foreground: oklch(0.9006 0 0);
88
+ --muted: oklch(0.2786 0.0211 257.2774);
89
+ --muted-foreground: oklch(0.6993 0 0);
90
+ --accent: oklch(0.3206 0.0396 254.678);
91
+ --accent-foreground: oklch(0.8996 0.0504 251.1357);
92
+ --destructive: oklch(0.6509 0.2199 25.0358);
93
+ --destructive-foreground: oklch(1 0 0);
94
+ --border: oklch(0.3408 0.0192 251.4559);
95
+ --input: oklch(0.3408 0.0192 251.4559);
96
+ --ring: oklch(0.6802 0.1902 32.0008);
97
+ --chart-1: oklch(0.7011 0.1193 239.6974);
98
+ --chart-2: oklch(0.7449 0.1558 32.2982);
99
+ --chart-3: oklch(0.765 0.177 163.223);
100
+ --chart-4: oklch(0.879 0.169 91.605);
101
+ --chart-5: oklch(0.785 0.115 274.713);
102
+ --sidebar: oklch(0.2492 0.02 254.8597);
103
+ --sidebar-foreground: oklch(0.9189 0 0);
104
+ --sidebar-primary: oklch(0.6802 0.1902 32.0008);
105
+ --sidebar-primary-foreground: oklch(1 0 0);
106
+ --sidebar-accent: oklch(0.3206 0.0396 254.678);
107
+ --sidebar-accent-foreground: oklch(0.8996 0.0504 251.1357);
108
+ --sidebar-border: oklch(0.3408 0.0192 251.4559);
109
+ --sidebar-ring: oklch(0.6802 0.1902 32.0008);
110
+ --font-sans: Inter, sans-serif;
111
+ --font-serif: Source Serif 4, serif;
112
+ --font-mono: JetBrains Mono, monospace;
113
+ --radius: 0.75rem;
114
+ --shadow-x: 0px;
115
+ --shadow-y: 1px;
116
+ --shadow-blur: 3px;
117
+ --shadow-spread: 0px;
118
+ --shadow-opacity: 0.1;
119
+ --shadow-color: #0a0c0f;
120
+ --shadow-2xs: 0px 1px 3px 0px hsl(216 20% 4.902% / 0.05);
121
+ --shadow-xs: 0px 1px 3px 0px hsl(216 20% 4.902% / 0.05);
122
+ --shadow-sm:
123
+ 0px 1px 3px 0px hsl(216 20% 4.902% / 0.1), 0px 1px 2px -1px hsl(216 20% 4.902% / 0.1);
124
+ --shadow: 0px 1px 3px 0px hsl(216 20% 4.902% / 0.1), 0px 1px 2px -1px hsl(216 20% 4.902% / 0.1);
125
+ --shadow-md:
126
+ 0px 1px 3px 0px hsl(216 20% 4.902% / 0.1), 0px 2px 4px -1px hsl(216 20% 4.902% / 0.1);
127
+ --shadow-lg:
128
+ 0px 1px 3px 0px hsl(216 20% 4.902% / 0.1), 0px 4px 6px -1px hsl(216 20% 4.902% / 0.1);
129
+ --shadow-xl:
130
+ 0px 1px 3px 0px hsl(216 20% 4.902% / 0.1), 0px 8px 10px -1px hsl(216 20% 4.902% / 0.1);
131
+ --shadow-2xl: 0px 1px 3px 0px hsl(216 20% 4.902% / 0.25);
150
132
  }
151
133
 
152
134
  @theme inline {
@@ -165,6 +147,7 @@
165
147
  --color-accent: var(--accent);
166
148
  --color-accent-foreground: var(--accent-foreground);
167
149
  --color-destructive: var(--destructive);
150
+ --color-destructive-foreground: var(--destructive-foreground);
168
151
  --color-border: var(--border);
169
152
  --color-input: var(--input);
170
153
  --color-ring: var(--ring);
@@ -181,12 +164,6 @@
181
164
  --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
182
165
  --color-sidebar-border: var(--sidebar-border);
183
166
  --color-sidebar-ring: var(--sidebar-ring);
184
- --color-destructive-foreground: var(--destructive-foreground);
185
-
186
- /* Thinner hairline — opt-in via border-rule / bg-rule / text-rule utilities.
187
- Use on large structural dividers (doc editor panels, section separators) where
188
- the component --border (22%) reads too loud. */
189
- --color-rule: var(--rule);
190
167
 
191
168
  --font-sans: var(--font-sans);
192
169
  --font-mono: var(--font-mono);
@@ -214,48 +191,4 @@
214
191
  body {
215
192
  @apply bg-background text-foreground;
216
193
  }
217
-
218
- /* Dark-mode text reads heavier than light due to halation on dark bgs.
219
- Antialiased smoothing + suppressing the browser's auto-bolding brings
220
- dark-mode text one visual step lighter, matching light mode. */
221
- .dark {
222
- -webkit-font-smoothing: antialiased;
223
- -moz-osx-font-smoothing: grayscale;
224
- }
225
-
226
- /* Selection in burnt orange — the landing's signature */
227
- .dark ::selection {
228
- background: var(--brand);
229
- color: var(--night-0);
230
- }
231
-
232
- /* Popovers/dialogs get a backdrop blur when translucent so content under doesn't fight text */
233
- .dark [data-slot='popover-content'],
234
- .dark [data-slot='dropdown-menu-content'],
235
- .dark [data-slot='select-content'],
236
- .dark [data-slot='command'],
237
- .dark [data-radix-popper-content-wrapper] > * {
238
- backdrop-filter: blur(12px) saturate(1.2);
239
- -webkit-backdrop-filter: blur(12px) saturate(1.2);
240
- }
241
-
242
- /* Primary buttons carry the landing's window-glow: accent ring + drop-shadow bloom */
243
- .dark button[data-slot='button'].bg-primary,
244
- .dark [data-slot='button'].bg-primary {
245
- box-shadow: var(--glow-brand);
246
- }
247
-
248
- /* Subtle top-edge highlight on cards so they read as "lit from above" on the gradient.
249
- This is the "floating" cue — a 1px inset bone highlight at the top. */
250
- .dark [data-slot='card'] {
251
- box-shadow:
252
- inset 0 1px 0 0 color-mix(in oklab, var(--bone) 6%, transparent),
253
- var(--shadow-sm);
254
- }
255
-
256
- /* Shadcn's sidebar-container applies border-r / border-l with the default --border,
257
- which resolves to rule-2 (thicker). Force the thin --rule for this structural divider. */
258
- .dark [data-slot='sidebar-container'] {
259
- border-color: var(--rule);
260
- }
261
194
  }
@@ -1,7 +0,0 @@
1
- import { Tooltip as TooltipPrimitive } from 'bits-ui';
2
- import Trigger from './tooltip-trigger.svelte';
3
- import Content from './tooltip-content.svelte';
4
- declare const Root: import("svelte").Component<TooltipPrimitive.RootProps, {}, "open">;
5
- declare const Provider: import("svelte").Component<TooltipPrimitive.ProviderProps, {}, "">;
6
- declare const Portal: import("svelte").Component<TooltipPrimitive.PortalProps, {}, "">;
7
- export { Root, Trigger, Content, Provider, Portal, Root as Tooltip, Content as TooltipContent, Trigger as TooltipTrigger, Provider as TooltipProvider, Portal as TooltipPortal };