noph-ui 0.4.0 → 0.4.2
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/README.md +4 -3
- package/dist/button/Button.svelte +6 -24
- package/dist/button/Button.svelte.d.ts +2 -15
- package/dist/button/IconButton.svelte +4 -23
- package/dist/button/IconButton.svelte.d.ts +2 -16
- package/dist/button/SegmentedButton.svelte +2 -15
- package/dist/button/SegmentedButton.svelte.d.ts +2 -14
- package/dist/button/types.d.ts +46 -0
- package/dist/button/types.js +1 -0
- package/dist/card/Card.svelte +14 -41
- package/dist/card/Card.svelte.d.ts +2 -33
- package/dist/card/types.d.ts +37 -0
- package/dist/card/types.js +1 -0
- package/dist/chip/types.d.ts +1 -0
- package/dist/chip/types.js +1 -0
- package/dist/divider/Divider.svelte +24 -4
- package/dist/divider/Divider.svelte.d.ts +2 -1
- package/dist/divider/types.d.ts +4 -0
- package/dist/divider/types.js +1 -0
- package/dist/index.js +0 -1
- package/dist/list/Item.svelte +2 -27
- package/dist/list/Item.svelte.d.ts +2 -27
- package/dist/list/ListItem.svelte +2 -27
- package/dist/list/ListItem.svelte.d.ts +2 -27
- package/dist/list/types.d.ts +27 -0
- package/dist/list/types.js +1 -1
- package/dist/menu/Menu.svelte +1 -7
- package/dist/menu/Menu.svelte.d.ts +2 -6
- package/dist/menu/MenuItem.svelte +3 -19
- package/dist/menu/MenuItem.svelte.d.ts +2 -17
- package/dist/menu/types.d.ts +21 -0
- package/dist/menu/types.js +1 -0
- package/dist/progress/CircularProgress.svelte +3 -9
- package/dist/progress/LinearProgress.svelte +3 -10
- package/dist/progress/LinearProgress.svelte.d.ts +2 -9
- package/dist/progress/types.d.ts +13 -0
- package/dist/progress/types.js +1 -0
- package/dist/ripple/Ripple.svelte +1 -6
- package/dist/ripple/Ripple.svelte.d.ts +2 -6
- package/dist/ripple/types.d.ts +6 -0
- package/dist/ripple/types.js +1 -0
- package/dist/snackbar/Snackbar.svelte +2 -17
- package/dist/snackbar/Snackbar.svelte.d.ts +2 -15
- package/dist/snackbar/types.d.ts +15 -0
- package/dist/snackbar/types.js +1 -0
- package/dist/text-field/TextField.svelte +10 -10
- package/dist/text-field/TextField.svelte.d.ts +2 -3
- package/dist/text-field/types.d.ts +4 -1
- package/dist/tooltip/Tooltip.svelte +1 -5
- package/dist/tooltip/Tooltip.svelte.d.ts +2 -4
- package/dist/tooltip/types.d.ts +4 -0
- package/dist/tooltip/types.js +1 -0
- package/dist/types.d.ts +13 -3
- package/dist/types.js +13 -1
- package/package.json +92 -91
- package/dist/progress/CircularProgress.svelte.d.ts +0 -10
package/dist/list/types.d.ts
CHANGED
|
@@ -1 +1,28 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
import type { HTMLAnchorAttributes, HTMLAttributes, HTMLButtonAttributes } from 'svelte/elements';
|
|
3
|
+
interface ButtonProps extends HTMLButtonAttributes {
|
|
4
|
+
selected?: boolean;
|
|
5
|
+
start?: Snippet;
|
|
6
|
+
end?: Snippet;
|
|
7
|
+
variant: 'button';
|
|
8
|
+
supportingText?: Snippet;
|
|
9
|
+
}
|
|
10
|
+
interface AnchorProps extends HTMLAnchorAttributes {
|
|
11
|
+
selected?: boolean;
|
|
12
|
+
start?: Snippet;
|
|
13
|
+
end?: Snippet;
|
|
14
|
+
disabled?: boolean;
|
|
15
|
+
variant: 'link';
|
|
16
|
+
supportingText?: Snippet;
|
|
17
|
+
}
|
|
18
|
+
interface TextProps extends HTMLAttributes<HTMLDivElement> {
|
|
19
|
+
selected?: boolean;
|
|
20
|
+
start?: Snippet;
|
|
21
|
+
end?: Snippet;
|
|
22
|
+
disabled?: boolean;
|
|
23
|
+
variant?: 'text';
|
|
24
|
+
supportingText?: Snippet;
|
|
25
|
+
}
|
|
26
|
+
export type ItemProps = ButtonProps | AnchorProps | TextProps;
|
|
27
|
+
export type ListItemProps = ButtonProps | AnchorProps | TextProps;
|
|
1
28
|
export {};
|
package/dist/list/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
export {};
|
package/dist/menu/Menu.svelte
CHANGED
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import { generateUUIDv4 } from '../utils.js'
|
|
3
|
-
import type {
|
|
4
|
-
import type { HTMLAttributes } from 'svelte/elements'
|
|
5
|
-
|
|
6
|
-
interface MenuProps extends HTMLAttributes<HTMLDivElement> {
|
|
7
|
-
children: Snippet
|
|
8
|
-
anchor?: HTMLElement | undefined
|
|
9
|
-
}
|
|
3
|
+
import type { MenuProps } from './types.ts'
|
|
10
4
|
|
|
11
5
|
let { anchor, children, ...attributes }: MenuProps = $props()
|
|
12
6
|
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
declare const Menu: import("svelte").Component<HTMLAttributes<HTMLDivElement> & {
|
|
4
|
-
children: Snippet;
|
|
5
|
-
anchor?: HTMLElement | undefined;
|
|
6
|
-
}, {}, "">;
|
|
1
|
+
import type { MenuProps } from './types.ts';
|
|
2
|
+
declare const Menu: import("svelte").Component<MenuProps, {}, "">;
|
|
7
3
|
type Menu = ReturnType<typeof Menu>;
|
|
8
4
|
export default Menu;
|
|
@@ -1,27 +1,11 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import Item from '../list/Item.svelte'
|
|
3
|
-
import type { Snippet } from 'svelte'
|
|
4
3
|
import type { HTMLAnchorAttributes, HTMLButtonAttributes } from 'svelte/elements'
|
|
4
|
+
import type { MenuItemProps } from './types.ts'
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
selected?: boolean
|
|
8
|
-
start?: Snippet
|
|
9
|
-
end?: Snippet
|
|
10
|
-
supportingText?: Snippet
|
|
11
|
-
}
|
|
12
|
-
interface AnchorProps extends HTMLAnchorAttributes {
|
|
13
|
-
selected?: boolean
|
|
14
|
-
start?: Snippet
|
|
15
|
-
end?: Snippet
|
|
16
|
-
disabled?: boolean
|
|
17
|
-
supportingText?: Snippet
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
let { ...attributes }: ButtonProps | AnchorProps = $props()
|
|
6
|
+
let { ...attributes }: MenuItemProps = $props()
|
|
21
7
|
|
|
22
|
-
const isButton = (
|
|
23
|
-
obj: HTMLAnchorAttributes | HTMLButtonAttributes,
|
|
24
|
-
): obj is HTMLButtonAttributes => {
|
|
8
|
+
const isButton = (obj: unknown): obj is HTMLButtonAttributes => {
|
|
25
9
|
return (obj as HTMLAnchorAttributes).href === undefined
|
|
26
10
|
}
|
|
27
11
|
</script>
|
|
@@ -1,19 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
interface ButtonProps extends HTMLButtonAttributes {
|
|
4
|
-
selected?: boolean;
|
|
5
|
-
start?: Snippet;
|
|
6
|
-
end?: Snippet;
|
|
7
|
-
supportingText?: Snippet;
|
|
8
|
-
}
|
|
9
|
-
interface AnchorProps extends HTMLAnchorAttributes {
|
|
10
|
-
selected?: boolean;
|
|
11
|
-
start?: Snippet;
|
|
12
|
-
end?: Snippet;
|
|
13
|
-
disabled?: boolean;
|
|
14
|
-
supportingText?: Snippet;
|
|
15
|
-
}
|
|
16
|
-
type $$ComponentProps = ButtonProps | AnchorProps;
|
|
17
|
-
declare const MenuItem: import("svelte").Component<$$ComponentProps, {}, "">;
|
|
1
|
+
import type { MenuItemProps } from './types.ts';
|
|
2
|
+
declare const MenuItem: import("svelte").Component<MenuItemProps, {}, "">;
|
|
18
3
|
type MenuItem = ReturnType<typeof MenuItem>;
|
|
19
4
|
export default MenuItem;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
import type { HTMLAttributes, HTMLAnchorAttributes, HTMLButtonAttributes } from 'svelte/elements';
|
|
3
|
+
export interface MenuProps extends HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
children: Snippet;
|
|
5
|
+
anchor?: HTMLElement | undefined;
|
|
6
|
+
}
|
|
7
|
+
interface ButtonProps extends HTMLButtonAttributes {
|
|
8
|
+
selected?: boolean;
|
|
9
|
+
start?: Snippet;
|
|
10
|
+
end?: Snippet;
|
|
11
|
+
supportingText?: Snippet;
|
|
12
|
+
}
|
|
13
|
+
interface AnchorProps extends HTMLAnchorAttributes {
|
|
14
|
+
selected?: boolean;
|
|
15
|
+
start?: Snippet;
|
|
16
|
+
end?: Snippet;
|
|
17
|
+
disabled?: boolean;
|
|
18
|
+
supportingText?: Snippet;
|
|
19
|
+
}
|
|
20
|
+
export type MenuItemProps = ButtonProps | AnchorProps;
|
|
21
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
max?: number
|
|
5
|
-
indeterminate?: boolean
|
|
6
|
-
fourColor?: boolean
|
|
7
|
-
'aria-label'?: string | undefined | null
|
|
8
|
-
element?: HTMLDivElement
|
|
9
|
-
}
|
|
2
|
+
import type { CircularProgressProps } from './types.ts'
|
|
3
|
+
|
|
10
4
|
let {
|
|
11
5
|
value = 0,
|
|
12
6
|
max = 1,
|
|
@@ -14,7 +8,7 @@
|
|
|
14
8
|
fourColor = false,
|
|
15
9
|
element = $bindable(),
|
|
16
10
|
...attributes
|
|
17
|
-
}:
|
|
11
|
+
}: CircularProgressProps = $props()
|
|
18
12
|
|
|
19
13
|
let dashOffset = $derived((1 - value / max) * 100)
|
|
20
14
|
</script>
|
|
@@ -1,13 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
max?: number
|
|
5
|
-
indeterminate?: boolean
|
|
6
|
-
fourColor?: boolean
|
|
7
|
-
buffer?: number
|
|
8
|
-
'aria-label'?: string | undefined | null
|
|
9
|
-
element?: HTMLDivElement
|
|
10
|
-
}
|
|
2
|
+
import type { LinearProgressProps } from './types.ts'
|
|
3
|
+
|
|
11
4
|
let {
|
|
12
5
|
value = 0,
|
|
13
6
|
max = 1,
|
|
@@ -16,7 +9,7 @@
|
|
|
16
9
|
buffer = 0,
|
|
17
10
|
element = $bindable(),
|
|
18
11
|
...attributes
|
|
19
|
-
}:
|
|
12
|
+
}: LinearProgressProps = $props()
|
|
20
13
|
|
|
21
14
|
let progressStyles = $derived(`transform: scaleX(${(indeterminate ? 1 : value / max) * 100}%)`)
|
|
22
15
|
|
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
max?: number;
|
|
4
|
-
indeterminate?: boolean;
|
|
5
|
-
fourColor?: boolean;
|
|
6
|
-
buffer?: number;
|
|
7
|
-
'aria-label'?: string | undefined | null;
|
|
8
|
-
element?: HTMLDivElement;
|
|
9
|
-
}, {}, "element">;
|
|
1
|
+
import type { LinearProgressProps } from './types.ts';
|
|
2
|
+
declare const LinearProgress: import("svelte").Component<LinearProgressProps, {}, "element">;
|
|
10
3
|
type LinearProgress = ReturnType<typeof LinearProgress>;
|
|
11
4
|
export default LinearProgress;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
interface ProgressProps {
|
|
2
|
+
value?: number;
|
|
3
|
+
max?: number;
|
|
4
|
+
indeterminate?: boolean;
|
|
5
|
+
fourColor?: boolean;
|
|
6
|
+
'aria-label'?: string | undefined | null;
|
|
7
|
+
element?: HTMLDivElement;
|
|
8
|
+
}
|
|
9
|
+
export interface LinearProgressProps extends ProgressProps {
|
|
10
|
+
buffer?: number;
|
|
11
|
+
}
|
|
12
|
+
export type CircularProgressProps = ProgressProps;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
-
import type {
|
|
2
|
+
import type { RippleProps } from './types.ts'
|
|
3
3
|
|
|
4
|
-
interface RippleProps extends HTMLAttributes<HTMLDivElement> {
|
|
5
|
-
forceHover?: boolean
|
|
6
|
-
element?: HTMLDivElement
|
|
7
|
-
forElement?: HTMLElement
|
|
8
|
-
}
|
|
9
4
|
let {
|
|
10
5
|
forceHover = false,
|
|
11
6
|
element = $bindable(),
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
declare const Ripple: import("svelte").Component<
|
|
3
|
-
forceHover?: boolean;
|
|
4
|
-
element?: HTMLDivElement;
|
|
5
|
-
forElement?: HTMLElement;
|
|
6
|
-
}, {}, "element">;
|
|
1
|
+
import type { RippleProps } from './types.ts';
|
|
2
|
+
declare const Ripple: import("svelte").Component<RippleProps, {}, "element">;
|
|
7
3
|
type Ripple = ReturnType<typeof Ripple>;
|
|
8
4
|
export default Ripple;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,22 +1,7 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import Button from '../button/Button.svelte'
|
|
3
3
|
import IconButton from '../button/IconButton.svelte'
|
|
4
|
-
import type {
|
|
5
|
-
import type { HTMLAttributes } from 'svelte/elements'
|
|
6
|
-
|
|
7
|
-
interface SnackbarProps extends HTMLAttributes<HTMLDivElement> {
|
|
8
|
-
label: string
|
|
9
|
-
supportingText?: string | undefined
|
|
10
|
-
actionLabel?: string | undefined
|
|
11
|
-
onActionClick?: (event: Event) => void
|
|
12
|
-
icon?: Snippet | undefined
|
|
13
|
-
onIconClick?: (event: Event) => void
|
|
14
|
-
showPopover?: () => void
|
|
15
|
-
hidePopover?: () => void
|
|
16
|
-
timeout?: number
|
|
17
|
-
element?: HTMLElement
|
|
18
|
-
popover?: 'auto' | 'manual'
|
|
19
|
-
}
|
|
4
|
+
import type { SnackbarProps } from './types.ts'
|
|
20
5
|
|
|
21
6
|
let {
|
|
22
7
|
label,
|
|
@@ -61,7 +46,7 @@
|
|
|
61
46
|
<div
|
|
62
47
|
{...attributes}
|
|
63
48
|
{popover}
|
|
64
|
-
class="np-snackbar"
|
|
49
|
+
class="np-snackbar {attributes.class}"
|
|
65
50
|
onbeforetoggle={toggleHandler}
|
|
66
51
|
bind:this={element}
|
|
67
52
|
>
|
|
@@ -1,17 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
declare const Snackbar: import("svelte").Component<HTMLAttributes<HTMLDivElement> & {
|
|
4
|
-
label: string;
|
|
5
|
-
supportingText?: string | undefined;
|
|
6
|
-
actionLabel?: string | undefined;
|
|
7
|
-
onActionClick?: (event: Event) => void;
|
|
8
|
-
icon?: Snippet | undefined;
|
|
9
|
-
onIconClick?: (event: Event) => void;
|
|
10
|
-
showPopover?: () => void;
|
|
11
|
-
hidePopover?: () => void;
|
|
12
|
-
timeout?: number;
|
|
13
|
-
element?: HTMLElement;
|
|
14
|
-
popover?: "auto" | "manual";
|
|
15
|
-
}, {}, "element" | "showPopover" | "hidePopover">;
|
|
1
|
+
import type { SnackbarProps } from './types.ts';
|
|
2
|
+
declare const Snackbar: import("svelte").Component<SnackbarProps, {}, "element" | "showPopover" | "hidePopover">;
|
|
16
3
|
type Snackbar = ReturnType<typeof Snackbar>;
|
|
17
4
|
export default Snackbar;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
import type { HTMLAttributes } from 'svelte/elements';
|
|
3
|
+
export interface SnackbarProps extends HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
label: string;
|
|
5
|
+
supportingText?: string | undefined;
|
|
6
|
+
actionLabel?: string | undefined;
|
|
7
|
+
onActionClick?: (event: Event) => void;
|
|
8
|
+
icon?: Snippet | undefined;
|
|
9
|
+
onIconClick?: (event: Event) => void;
|
|
10
|
+
showPopover?: () => void;
|
|
11
|
+
hidePopover?: () => void;
|
|
12
|
+
timeout?: number;
|
|
13
|
+
element?: HTMLElement;
|
|
14
|
+
popover?: 'auto' | 'manual';
|
|
15
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import { isFirstInvalidControlInForm } from './report-validity.js'
|
|
3
|
-
import type { TextFieldProps
|
|
3
|
+
import type { TextFieldProps } from './types.ts'
|
|
4
4
|
|
|
5
5
|
let {
|
|
6
6
|
value = $bindable(),
|
|
@@ -16,19 +16,19 @@
|
|
|
16
16
|
noAsterisk = false,
|
|
17
17
|
variant = 'filled',
|
|
18
18
|
placeholder = ' ',
|
|
19
|
+
element = $bindable(),
|
|
19
20
|
...attributes
|
|
20
|
-
}: TextFieldProps
|
|
21
|
+
}: TextFieldProps = $props()
|
|
21
22
|
|
|
22
|
-
let contentEl: HTMLInputElement | HTMLTextAreaElement | undefined = $state()
|
|
23
23
|
let errorTextRaw = $state(errorText)
|
|
24
24
|
|
|
25
25
|
$effect(() => {
|
|
26
|
-
if (
|
|
27
|
-
|
|
26
|
+
if (element) {
|
|
27
|
+
element.form?.addEventListener('reset', () => {
|
|
28
28
|
error = false
|
|
29
29
|
value = ''
|
|
30
30
|
})
|
|
31
|
-
|
|
31
|
+
element.addEventListener('invalid', (event) => {
|
|
32
32
|
event.preventDefault()
|
|
33
33
|
const { currentTarget } = event as Event & {
|
|
34
34
|
currentTarget: HTMLInputElement | HTMLTextAreaElement
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
}
|
|
43
43
|
})
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
element.addEventListener('change', (event) => {
|
|
46
46
|
const { currentTarget } = event as Event & {
|
|
47
47
|
currentTarget: HTMLInputElement | HTMLTextAreaElement
|
|
48
48
|
}
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
if (attributes.disabled) {
|
|
69
69
|
return
|
|
70
70
|
}
|
|
71
|
-
|
|
71
|
+
element?.focus()
|
|
72
72
|
}}
|
|
73
73
|
>
|
|
74
74
|
<div
|
|
@@ -117,7 +117,7 @@
|
|
|
117
117
|
<textarea
|
|
118
118
|
{...attributes}
|
|
119
119
|
bind:value
|
|
120
|
-
bind:this={
|
|
120
|
+
bind:this={element}
|
|
121
121
|
class="input"
|
|
122
122
|
aria-label={label}
|
|
123
123
|
{placeholder}
|
|
@@ -133,7 +133,7 @@
|
|
|
133
133
|
<input
|
|
134
134
|
{...attributes}
|
|
135
135
|
bind:value
|
|
136
|
-
bind:this={
|
|
136
|
+
bind:this={element}
|
|
137
137
|
class="input"
|
|
138
138
|
{placeholder}
|
|
139
139
|
aria-label={label}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type { TextFieldProps
|
|
2
|
-
|
|
3
|
-
declare const TextField: import("svelte").Component<$$ComponentProps, {}, "value">;
|
|
1
|
+
import type { TextFieldProps } from './types.ts';
|
|
2
|
+
declare const TextField: import("svelte").Component<TextFieldProps, {}, "element" | "value">;
|
|
4
3
|
type TextField = ReturnType<typeof TextField>;
|
|
5
4
|
export default TextField;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Snippet } from 'svelte';
|
|
2
2
|
import type { HTMLInputAttributes, HTMLTextareaAttributes } from 'svelte/elements';
|
|
3
|
-
export interface
|
|
3
|
+
export interface InputFieldProps extends Omit<HTMLInputAttributes, 'class'> {
|
|
4
4
|
label?: string;
|
|
5
5
|
type?: 'text' | 'password' | 'email' | 'number' | 'search' | 'tel' | 'url';
|
|
6
6
|
supportingText?: string;
|
|
@@ -12,6 +12,7 @@ export interface TextFieldProps extends Omit<HTMLInputAttributes, 'class'> {
|
|
|
12
12
|
start?: Snippet;
|
|
13
13
|
end?: Snippet;
|
|
14
14
|
noAsterisk?: boolean;
|
|
15
|
+
element?: HTMLInputElement;
|
|
15
16
|
}
|
|
16
17
|
export interface TextAreaFieldProps extends Omit<HTMLTextareaAttributes, 'class'> {
|
|
17
18
|
label?: string;
|
|
@@ -25,4 +26,6 @@ export interface TextAreaFieldProps extends Omit<HTMLTextareaAttributes, 'class'
|
|
|
25
26
|
start?: Snippet;
|
|
26
27
|
end?: Snippet;
|
|
27
28
|
noAsterisk?: boolean;
|
|
29
|
+
element?: HTMLTextAreaElement;
|
|
28
30
|
}
|
|
31
|
+
export type TextFieldProps = InputFieldProps | TextAreaFieldProps;
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
interface TooltipProps extends HTMLAttributes<HTMLDivElement> {
|
|
5
|
-
anchor: HTMLElement
|
|
6
|
-
}
|
|
2
|
+
import type { TooltipProps } from './types.ts'
|
|
7
3
|
|
|
8
4
|
let { children, anchor, ...attributes }: TooltipProps = $props()
|
|
9
5
|
let clientWidth = $state(0)
|
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
declare const Tooltip: import("svelte").Component<
|
|
3
|
-
anchor: HTMLElement;
|
|
4
|
-
}, {}, "">;
|
|
1
|
+
import type { TooltipProps } from './types.ts';
|
|
2
|
+
declare const Tooltip: import("svelte").Component<TooltipProps, {}, "">;
|
|
5
3
|
type Tooltip = ReturnType<typeof Tooltip>;
|
|
6
4
|
export default Tooltip;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/types.d.ts
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
export
|
|
1
|
+
export * from './button/types.ts';
|
|
2
|
+
export * from './card/types.ts';
|
|
3
|
+
export * from './checkbox/types.ts';
|
|
4
|
+
export * from './chip/types.ts';
|
|
5
|
+
export * from './divider/types.js';
|
|
6
|
+
export * from './list/types.ts';
|
|
7
|
+
export * from './menu/types.ts';
|
|
8
|
+
export * from './progress/types.js';
|
|
9
|
+
export * from './radio/types.ts';
|
|
10
|
+
export * from './ripple/types.ts';
|
|
11
|
+
export * from './snackbar/types.ts';
|
|
12
|
+
export * from './text-field/types.ts';
|
|
13
|
+
export * from './tooltip/types.ts';
|
package/dist/types.js
CHANGED
|
@@ -1 +1,13 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from './button/types.ts';
|
|
2
|
+
export * from './card/types.ts';
|
|
3
|
+
export * from './checkbox/types.ts';
|
|
4
|
+
export * from './chip/types.ts';
|
|
5
|
+
export * from './divider/types.js';
|
|
6
|
+
export * from './list/types.ts';
|
|
7
|
+
export * from './menu/types.ts';
|
|
8
|
+
export * from './progress/types.js';
|
|
9
|
+
export * from './radio/types.ts';
|
|
10
|
+
export * from './ripple/types.ts';
|
|
11
|
+
export * from './snackbar/types.ts';
|
|
12
|
+
export * from './text-field/types.ts';
|
|
13
|
+
export * from './tooltip/types.ts';
|