@lyeve-labs/ui-kit 0.29.0 → 0.30.0
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/dist/components/Dropdown.svelte +2 -2
- package/dist/components/Input.svelte +8 -1
- package/dist/components/Input.svelte.d.ts +6 -0
- package/dist/components/SegmentedControl.svelte +1 -1
- package/dist/components/Textarea.svelte +8 -1
- package/dist/components/Textarea.svelte.d.ts +6 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -257,7 +257,7 @@
|
|
|
257
257
|
role="menu"
|
|
258
258
|
use:placePanel
|
|
259
259
|
transition:motion.popover|global
|
|
260
|
-
class="{PANEL_SURFACE} min-w-36 {align === 'right' ? 'end-0' : 'start-0'}"
|
|
260
|
+
class="{PANEL_SURFACE} w-max min-w-36 max-w-xs {align === 'right' ? 'end-0' : 'start-0'}"
|
|
261
261
|
>
|
|
262
262
|
<div class={PANEL_LIST} data-panel-list>
|
|
263
263
|
{#each items as item, index}
|
|
@@ -267,7 +267,7 @@
|
|
|
267
267
|
disabled={item.disabled}
|
|
268
268
|
tabindex={index === active ? 0 : -1}
|
|
269
269
|
onclick={() => handleItemClick(item)}
|
|
270
|
-
class="{TOUCH_GROW} flex w-full items-center gap-2.5 rounded-lg px-2 py-2 text-sm transition-colors
|
|
270
|
+
class="{TOUCH_GROW} flex w-full items-center gap-2.5 rounded-lg px-2 py-2 text-start text-sm whitespace-nowrap transition-colors
|
|
271
271
|
outline-none focus-visible:ring-2 focus-visible:ring-inset
|
|
272
272
|
focus-visible:ring-brand disabled:cursor-not-allowed disabled:opacity-40
|
|
273
273
|
{item.variant === 'danger' ? 'text-danger hover:bg-danger/10' : 'hover:bg-surface-2'}"
|
|
@@ -31,6 +31,12 @@
|
|
|
31
31
|
required?: boolean;
|
|
32
32
|
id?: string;
|
|
33
33
|
name?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Monospace for the control alone: a slug, a key, a locale tag. Passing
|
|
36
|
+
* `font-mono` as a class reached the wrapper, so the label and the hint
|
|
37
|
+
* turned monospace with it.
|
|
38
|
+
*/
|
|
39
|
+
mono?: boolean;
|
|
34
40
|
class?: string;
|
|
35
41
|
}
|
|
36
42
|
|
|
@@ -44,6 +50,7 @@
|
|
|
44
50
|
disabled = false,
|
|
45
51
|
required = false,
|
|
46
52
|
id = undefined,
|
|
53
|
+
mono = false,
|
|
47
54
|
class: klass = '',
|
|
48
55
|
...rest
|
|
49
56
|
}: Props = $props();
|
|
@@ -67,7 +74,7 @@
|
|
|
67
74
|
bind:value
|
|
68
75
|
aria-invalid={error ? 'true' : undefined}
|
|
69
76
|
aria-describedby={describedBy(fieldId, error, hint)}
|
|
70
|
-
class="{CONTROL_BASE} {controlBorder(!!error)}"
|
|
77
|
+
class="{CONTROL_BASE} {controlBorder(!!error)} {mono ? 'font-mono' : ''}"
|
|
71
78
|
{...rest}
|
|
72
79
|
/>
|
|
73
80
|
|
|
@@ -16,6 +16,12 @@ interface Props extends Forwarded {
|
|
|
16
16
|
required?: boolean;
|
|
17
17
|
id?: string;
|
|
18
18
|
name?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Monospace for the control alone: a slug, a key, a locale tag. Passing
|
|
21
|
+
* `font-mono` as a class reached the wrapper, so the label and the hint
|
|
22
|
+
* turned monospace with it.
|
|
23
|
+
*/
|
|
24
|
+
mono?: boolean;
|
|
19
25
|
class?: string;
|
|
20
26
|
}
|
|
21
27
|
declare const Input: import("svelte").Component<Props, {}, "value">;
|
|
@@ -199,7 +199,7 @@
|
|
|
199
199
|
'inline-flex items-center justify-center rounded-md outline-none transition-colors focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-brand disabled:cursor-not-allowed ' +
|
|
200
200
|
SIZES[size].segment +
|
|
201
201
|
(selected
|
|
202
|
-
? ' bg-surface text-
|
|
202
|
+
? ' bg-surface text-brand shadow-sm ring-1 ring-inset ring-brand/40'
|
|
203
203
|
: ' text-muted hover:text-fg active:bg-surface active:text-fg')}
|
|
204
204
|
{#snippet content()}
|
|
205
205
|
{#if Icon}
|
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
resize = true,
|
|
27
27
|
error,
|
|
28
28
|
hint,
|
|
29
|
+
mono = false,
|
|
29
30
|
class: cls = '',
|
|
30
31
|
oninput,
|
|
31
32
|
onblur,
|
|
@@ -43,6 +44,12 @@
|
|
|
43
44
|
resize?: boolean;
|
|
44
45
|
error?: string;
|
|
45
46
|
hint?: string;
|
|
47
|
+
/**
|
|
48
|
+
* Monospace for the control alone: code, JSON, a key. Passing `font-mono`
|
|
49
|
+
* as a class reached the wrapper, so the label and the hint turned
|
|
50
|
+
* monospace with it.
|
|
51
|
+
*/
|
|
52
|
+
mono?: boolean;
|
|
46
53
|
class?: string;
|
|
47
54
|
oninput?: (e: TAE) => void;
|
|
48
55
|
onblur?: (e: FocusEvent & { currentTarget: TA }) => void;
|
|
@@ -69,7 +76,7 @@
|
|
|
69
76
|
{placeholder}
|
|
70
77
|
aria-invalid={error ? 'true' : undefined}
|
|
71
78
|
aria-describedby={describedBy(fieldId, error, hint)}
|
|
72
|
-
class="{CONTROL_MULTILINE} {controlBorder(!!error)} {resize ? 'resize-y' : 'resize-none'}"
|
|
79
|
+
class="{CONTROL_MULTILINE} {controlBorder(!!error)} {resize ? 'resize-y' : 'resize-none'} {mono ? 'font-mono' : ''}"
|
|
73
80
|
bind:value
|
|
74
81
|
{oninput}
|
|
75
82
|
{onblur}
|
|
@@ -16,6 +16,12 @@ type $$ComponentProps = {
|
|
|
16
16
|
resize?: boolean;
|
|
17
17
|
error?: string;
|
|
18
18
|
hint?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Monospace for the control alone: code, JSON, a key. Passing `font-mono`
|
|
21
|
+
* as a class reached the wrapper, so the label and the hint turned
|
|
22
|
+
* monospace with it.
|
|
23
|
+
*/
|
|
24
|
+
mono?: boolean;
|
|
19
25
|
class?: string;
|
|
20
26
|
oninput?: (e: TAE) => void;
|
|
21
27
|
onblur?: (e: FocusEvent & {
|
package/dist/index.d.ts
CHANGED
|
@@ -93,4 +93,4 @@ export { cn, type ClassValue } from './utils/cn.js';
|
|
|
93
93
|
export { getTheme, getThemePreference, nextThemePreference, resolveTheme, setTheme, setThemePreference, systemTheme, themeBootScript, toggleTheme, watchSystemTheme, THEME_PREFERENCES, type Theme, type ThemePreference, } from './utils/theme.js';
|
|
94
94
|
export * as motion from './motion.js';
|
|
95
95
|
export type { Rung as MotionRung, Curve as MotionCurve } from './motion.js';
|
|
96
|
-
export declare const VERSION = "0.
|
|
96
|
+
export declare const VERSION = "0.30.0";
|
package/dist/index.js
CHANGED
|
@@ -103,4 +103,4 @@ export * as motion from './motion.js';
|
|
|
103
103
|
// ── Version ────────────────────────────────────────────────────────────────
|
|
104
104
|
// Generated from package.json by `pnpm version:sync`. Bump package.json, never
|
|
105
105
|
// this line; the build and the test suite fail when the two disagree.
|
|
106
|
-
export const VERSION = '0.
|
|
106
|
+
export const VERSION = '0.30.0';
|
package/package.json
CHANGED