@sprawlify/svelte 0.0.109 → 0.0.111
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/alert-dialog/alert-dialog-anatomy.d.ts +2 -2
- package/dist/components/anatomy.d.ts +1 -1
- package/dist/components/anatomy.js +1 -1
- package/dist/components/carousel/carousel-anatomy.d.ts +1 -1
- package/dist/components/checkbox/checkbox-anatomy.d.ts +1 -1
- package/dist/components/color-picker/color-picker-anatomy.d.ts +1 -1
- package/dist/components/combobox/combobox-anatomy.d.ts +1 -1
- package/dist/components/date-picker/date-picker-anatomy.d.ts +1 -1
- package/dist/components/drawer/drawer-anatomy.d.ts +1 -0
- package/dist/components/drawer/drawer-anatomy.js +1 -0
- package/dist/components/{bottom-sheet/bottom-sheet-backdrop.svelte → drawer/drawer-backdrop.svelte} +7 -7
- package/dist/components/drawer/drawer-backdrop.svelte.d.ts +9 -0
- package/dist/components/drawer/drawer-close-trigger.svelte +19 -0
- package/dist/components/drawer/drawer-close-trigger.svelte.d.ts +8 -0
- package/dist/components/{bottom-sheet/bottom-sheet-content.svelte → drawer/drawer-content.svelte} +7 -8
- package/dist/components/drawer/drawer-content.svelte.d.ts +10 -0
- package/dist/components/drawer/drawer-context.svelte +18 -0
- package/dist/components/drawer/drawer-context.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-description.svelte +19 -0
- package/dist/components/drawer/drawer-description.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-grabber-indicator.svelte +19 -0
- package/dist/components/drawer/drawer-grabber-indicator.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-grabber.svelte +19 -0
- package/dist/components/drawer/drawer-grabber.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-indent-background.svelte +19 -0
- package/dist/components/drawer/drawer-indent-background.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-indent.svelte +19 -0
- package/dist/components/drawer/drawer-indent.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-positioner.svelte +23 -0
- package/dist/components/drawer/drawer-positioner.svelte.d.ts +8 -0
- package/dist/components/{bottom-sheet/bottom-sheet-root-provider.svelte → drawer/drawer-root-provider.svelte} +7 -7
- package/dist/components/drawer/drawer-root-provider.svelte.d.ts +11 -0
- package/dist/components/{bottom-sheet/bottom-sheet-root.svelte → drawer/drawer-root.svelte} +10 -10
- package/dist/components/drawer/drawer-root.svelte.d.ts +11 -0
- package/dist/components/drawer/drawer-stack.svelte +29 -0
- package/dist/components/drawer/drawer-stack.svelte.d.ts +6 -0
- package/dist/components/drawer/drawer-swipe-area.svelte +19 -0
- package/dist/components/drawer/drawer-swipe-area.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-title.svelte +19 -0
- package/dist/components/drawer/drawer-title.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer-trigger.svelte +29 -0
- package/dist/components/drawer/drawer-trigger.svelte.d.ts +8 -0
- package/dist/components/drawer/drawer.d.ts +17 -0
- package/dist/components/drawer/drawer.js +16 -0
- package/dist/components/drawer/index.d.ts +22 -0
- package/dist/components/drawer/index.js +21 -0
- package/dist/components/drawer/use-drawer-context.d.ts +4 -0
- package/dist/components/drawer/use-drawer-context.js +4 -0
- package/dist/components/drawer/use-drawer-stack-context.d.ts +6 -0
- package/dist/components/drawer/use-drawer-stack-context.js +6 -0
- package/dist/components/drawer/use-drawer-stack-store.d.ts +3 -0
- package/dist/components/drawer/use-drawer-stack-store.js +4 -0
- package/dist/components/drawer/use-drawer.svelte.d.ts +10 -0
- package/dist/components/{bottom-sheet/use-bottom-sheet.svelte.js → drawer/use-drawer.svelte.js} +7 -4
- package/dist/components/tour/tour-anatomy.d.ts +1 -1
- package/package.json +7 -7
- package/dist/components/bottom-sheet/bottom-sheet-anatomy.d.ts +0 -1
- package/dist/components/bottom-sheet/bottom-sheet-anatomy.js +0 -1
- package/dist/components/bottom-sheet/bottom-sheet-backdrop.svelte.d.ts +0 -9
- package/dist/components/bottom-sheet/bottom-sheet-close-trigger.svelte +0 -19
- package/dist/components/bottom-sheet/bottom-sheet-close-trigger.svelte.d.ts +0 -8
- package/dist/components/bottom-sheet/bottom-sheet-content.svelte.d.ts +0 -10
- package/dist/components/bottom-sheet/bottom-sheet-context.svelte +0 -18
- package/dist/components/bottom-sheet/bottom-sheet-context.svelte.d.ts +0 -8
- package/dist/components/bottom-sheet/bottom-sheet-grabber-indicator.svelte +0 -20
- package/dist/components/bottom-sheet/bottom-sheet-grabber-indicator.svelte.d.ts +0 -8
- package/dist/components/bottom-sheet/bottom-sheet-grabber.svelte +0 -19
- package/dist/components/bottom-sheet/bottom-sheet-grabber.svelte.d.ts +0 -8
- package/dist/components/bottom-sheet/bottom-sheet-root-provider.svelte.d.ts +0 -11
- package/dist/components/bottom-sheet/bottom-sheet-root.svelte.d.ts +0 -11
- package/dist/components/bottom-sheet/bottom-sheet-title.svelte +0 -19
- package/dist/components/bottom-sheet/bottom-sheet-title.svelte.d.ts +0 -8
- package/dist/components/bottom-sheet/bottom-sheet-trigger.svelte +0 -29
- package/dist/components/bottom-sheet/bottom-sheet-trigger.svelte.d.ts +0 -8
- package/dist/components/bottom-sheet/bottom-sheet.d.ts +0 -11
- package/dist/components/bottom-sheet/bottom-sheet.js +0 -10
- package/dist/components/bottom-sheet/index.d.ts +0 -15
- package/dist/components/bottom-sheet/index.js +0 -14
- package/dist/components/bottom-sheet/use-bottom-sheet-context.d.ts +0 -4
- package/dist/components/bottom-sheet/use-bottom-sheet-context.js +0 -4
- package/dist/components/bottom-sheet/use-bottom-sheet.svelte.d.ts +0 -9
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types'
|
|
3
|
+
|
|
4
|
+
export interface DrawerTriggerBaseProps extends PolymorphicProps<'button'>, RefAttribute {}
|
|
5
|
+
export interface DrawerTriggerProps extends Assign<HTMLProps<'button'>, DrawerTriggerBaseProps> {}
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<script lang="ts">
|
|
9
|
+
import { mergeProps } from '../../core'
|
|
10
|
+
import { Sprawlify } from '../factory'
|
|
11
|
+
import { usePresenceContext } from '../presence'
|
|
12
|
+
import { useDrawerContext } from './use-drawer-context'
|
|
13
|
+
|
|
14
|
+
let { ref = $bindable(null), ...props }: DrawerTriggerProps = $props()
|
|
15
|
+
|
|
16
|
+
const drawer = useDrawerContext()
|
|
17
|
+
const presence = usePresenceContext()
|
|
18
|
+
const mergedProps = $derived(
|
|
19
|
+
mergeProps(
|
|
20
|
+
{
|
|
21
|
+
...drawer().getTriggerProps(),
|
|
22
|
+
'aria-controls': presence().unmounted ? undefined : drawer().getTriggerProps()['aria-controls'],
|
|
23
|
+
},
|
|
24
|
+
props,
|
|
25
|
+
),
|
|
26
|
+
)
|
|
27
|
+
</script>
|
|
28
|
+
|
|
29
|
+
<Sprawlify as="button" bind:ref {...mergedProps} />
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
+
export interface DrawerTriggerBaseProps extends PolymorphicProps<'button'>, RefAttribute {
|
|
3
|
+
}
|
|
4
|
+
export interface DrawerTriggerProps extends Assign<HTMLProps<'button'>, DrawerTriggerBaseProps> {
|
|
5
|
+
}
|
|
6
|
+
declare const DrawerTrigger: import("svelte").Component<DrawerTriggerProps, {}, "ref">;
|
|
7
|
+
type DrawerTrigger = ReturnType<typeof DrawerTrigger>;
|
|
8
|
+
export default DrawerTrigger;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export type { OpenChangeDetails, SnapPointChangeDetails, } from "@sprawlify/primitives/machines/drawer";
|
|
2
|
+
export { default as Backdrop, type DrawerBackdropBaseProps as BackdropBaseProps, type DrawerBackdropProps as BackdropProps, } from "./drawer-backdrop.svelte";
|
|
3
|
+
export { default as CloseTrigger, type DrawerCloseTriggerBaseProps as CloseTriggerBaseProps, type DrawerCloseTriggerProps as CloseTriggerProps, } from "./drawer-close-trigger.svelte";
|
|
4
|
+
export { default as Content, type DrawerContentBaseProps as ContentBaseProps, type DrawerContentProps as ContentProps, } from "./drawer-content.svelte";
|
|
5
|
+
export { default as Description, type DrawerDescriptionBaseProps as DescriptionBaseProps, type DrawerDescriptionProps as DescriptionProps, } from "./drawer-description.svelte";
|
|
6
|
+
export { default as Context, type DrawerContextProps as ContextProps, } from "./drawer-context.svelte";
|
|
7
|
+
export { default as Positioner, type DrawerPositionerBaseProps as PositionerBaseProps, type DrawerPositionerProps as PositionerProps, } from "./drawer-positioner.svelte";
|
|
8
|
+
export { default as Grabber, type DrawerGrabberBaseProps as GrabberBaseProps, type DrawerGrabberProps as GrabberProps, } from "./drawer-grabber.svelte";
|
|
9
|
+
export { default as GrabberIndicator, type DrawerGrabberIndicatorBaseProps as GrabberIndicatorBaseProps, type DrawerGrabberIndicatorProps as GrabberIndicatorProps, } from "./drawer-grabber-indicator.svelte";
|
|
10
|
+
export { default as Root, type DrawerRootBaseProps as RootBaseProps, type DrawerRootProps as RootProps, } from "./drawer-root.svelte";
|
|
11
|
+
export { default as RootProvider, type DrawerRootProviderBaseProps as RootProviderBaseProps, type DrawerRootProviderProps as RootProviderProps, } from "./drawer-root-provider.svelte";
|
|
12
|
+
export { default as Title, type DrawerTitleBaseProps as TitleBaseProps, type DrawerTitleProps as TitleProps, } from "./drawer-title.svelte";
|
|
13
|
+
export { default as Trigger, type DrawerTriggerBaseProps as TriggerBaseProps, type DrawerTriggerProps as TriggerProps, } from "./drawer-trigger.svelte";
|
|
14
|
+
export { default as Indent, type DrawerIndentBaseProps as IndentBaseProps, type DrawerIndentProps as IndentProps, } from "./drawer-indent.svelte";
|
|
15
|
+
export { default as IndentBackground, type DrawerIndentBackgroundBaseProps as IndentBackgroundBaseProps, type DrawerIndentBackgroundProps as IndentBackgroundProps, } from "./drawer-indent-background.svelte";
|
|
16
|
+
export { default as Stack, type DrawerStackProps as StackProps } from "./drawer-stack.svelte";
|
|
17
|
+
export { default as SwipeArea, type DrawerSwipeAreaBaseProps as SwipeAreaBaseProps, type DrawerSwipeAreaProps as SwipeAreaProps, } from "./drawer-swipe-area.svelte";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export { default as Backdrop, } from "./drawer-backdrop.svelte";
|
|
2
|
+
export { default as CloseTrigger, } from "./drawer-close-trigger.svelte";
|
|
3
|
+
export { default as Content, } from "./drawer-content.svelte";
|
|
4
|
+
export { default as Description, } from "./drawer-description.svelte";
|
|
5
|
+
export { default as Context, } from "./drawer-context.svelte";
|
|
6
|
+
export { default as Positioner, } from "./drawer-positioner.svelte";
|
|
7
|
+
export { default as Grabber, } from "./drawer-grabber.svelte";
|
|
8
|
+
export { default as GrabberIndicator, } from "./drawer-grabber-indicator.svelte";
|
|
9
|
+
export { default as Root, } from "./drawer-root.svelte";
|
|
10
|
+
export { default as RootProvider, } from "./drawer-root-provider.svelte";
|
|
11
|
+
export { default as Title, } from "./drawer-title.svelte";
|
|
12
|
+
export { default as Trigger, } from "./drawer-trigger.svelte";
|
|
13
|
+
export { default as Indent, } from "./drawer-indent.svelte";
|
|
14
|
+
export { default as IndentBackground, } from "./drawer-indent-background.svelte";
|
|
15
|
+
export { default as Stack } from "./drawer-stack.svelte";
|
|
16
|
+
export { default as SwipeArea, } from "./drawer-swipe-area.svelte";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export type { OpenChangeDetails as DrawerOpenChangeDetails, SnapPointChangeDetails as DrawerSnapPointChangeDetails, } from "@sprawlify/primitives/machines/drawer";
|
|
2
|
+
export { default as DrawerBackdrop, type DrawerBackdropBaseProps, type DrawerBackdropProps, } from "./drawer-backdrop.svelte";
|
|
3
|
+
export { default as DrawerCloseTrigger, type DrawerCloseTriggerBaseProps, type DrawerCloseTriggerProps, } from "./drawer-close-trigger.svelte";
|
|
4
|
+
export { default as DrawerContent, type DrawerContentBaseProps, type DrawerContentProps, } from "./drawer-content.svelte";
|
|
5
|
+
export { default as DrawerDescription, type DrawerDescriptionBaseProps, type DrawerDescriptionProps, } from "./drawer-description.svelte";
|
|
6
|
+
export { default as DrawerContext, type DrawerContextProps } from "./drawer-context.svelte";
|
|
7
|
+
export { default as DrawerPositioner, type DrawerPositionerBaseProps, type DrawerPositionerProps, } from "./drawer-positioner.svelte";
|
|
8
|
+
export { default as DrawerGrabber, type DrawerGrabberBaseProps, type DrawerGrabberProps, } from "./drawer-grabber.svelte";
|
|
9
|
+
export { default as DrawerGrabberIndicator, type DrawerGrabberIndicatorBaseProps, type DrawerGrabberIndicatorProps, } from "./drawer-grabber-indicator.svelte";
|
|
10
|
+
export { default as DrawerRoot, type DrawerRootBaseProps, type DrawerRootProps, } from "./drawer-root.svelte";
|
|
11
|
+
export { default as DrawerRootProvider, type DrawerRootProviderBaseProps, type DrawerRootProviderProps, } from "./drawer-root-provider.svelte";
|
|
12
|
+
export { default as DrawerTitle, type DrawerTitleBaseProps, type DrawerTitleProps, } from "./drawer-title.svelte";
|
|
13
|
+
export { default as DrawerTrigger, type DrawerTriggerBaseProps, type DrawerTriggerProps, } from "./drawer-trigger.svelte";
|
|
14
|
+
export { default as DrawerIndent, type DrawerIndentBaseProps, type DrawerIndentProps, } from "./drawer-indent.svelte";
|
|
15
|
+
export { default as DrawerIndentBackground, type DrawerIndentBackgroundBaseProps, type DrawerIndentBackgroundProps, } from "./drawer-indent-background.svelte";
|
|
16
|
+
export { default as DrawerStack, type DrawerStackProps } from "./drawer-stack.svelte";
|
|
17
|
+
export { default as DrawerSwipeArea, type DrawerSwipeAreaBaseProps, type DrawerSwipeAreaProps, } from "./drawer-swipe-area.svelte";
|
|
18
|
+
export { drawerAnatomy } from "./drawer-anatomy";
|
|
19
|
+
export { useDrawerContext, type UseDrawerContext } from "./use-drawer-context";
|
|
20
|
+
export { useDrawerStackContext, type UseDrawerStackContext } from "./use-drawer-stack-context";
|
|
21
|
+
export { useDrawer, type UseDrawerProps, type UseDrawerReturn } from "./use-drawer.svelte";
|
|
22
|
+
export * as Drawer from "./drawer";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export { default as DrawerBackdrop, } from "./drawer-backdrop.svelte";
|
|
2
|
+
export { default as DrawerCloseTrigger, } from "./drawer-close-trigger.svelte";
|
|
3
|
+
export { default as DrawerContent, } from "./drawer-content.svelte";
|
|
4
|
+
export { default as DrawerDescription, } from "./drawer-description.svelte";
|
|
5
|
+
export { default as DrawerContext } from "./drawer-context.svelte";
|
|
6
|
+
export { default as DrawerPositioner, } from "./drawer-positioner.svelte";
|
|
7
|
+
export { default as DrawerGrabber, } from "./drawer-grabber.svelte";
|
|
8
|
+
export { default as DrawerGrabberIndicator, } from "./drawer-grabber-indicator.svelte";
|
|
9
|
+
export { default as DrawerRoot, } from "./drawer-root.svelte";
|
|
10
|
+
export { default as DrawerRootProvider, } from "./drawer-root-provider.svelte";
|
|
11
|
+
export { default as DrawerTitle, } from "./drawer-title.svelte";
|
|
12
|
+
export { default as DrawerTrigger, } from "./drawer-trigger.svelte";
|
|
13
|
+
export { default as DrawerIndent, } from "./drawer-indent.svelte";
|
|
14
|
+
export { default as DrawerIndentBackground, } from "./drawer-indent-background.svelte";
|
|
15
|
+
export { default as DrawerStack } from "./drawer-stack.svelte";
|
|
16
|
+
export { default as DrawerSwipeArea, } from "./drawer-swipe-area.svelte";
|
|
17
|
+
export { drawerAnatomy } from "./drawer-anatomy";
|
|
18
|
+
export { useDrawerContext } from "./use-drawer-context";
|
|
19
|
+
export { useDrawerStackContext } from "./use-drawer-stack-context";
|
|
20
|
+
export { useDrawer } from "./use-drawer.svelte";
|
|
21
|
+
export * as Drawer from "./drawer";
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { UseDrawerReturn } from "./use-drawer.svelte";
|
|
2
|
+
export interface UseDrawerContext extends UseDrawerReturn {
|
|
3
|
+
}
|
|
4
|
+
export declare const DrawerProvider: (opts: UseDrawerContext) => void, useDrawerContext: (fallback?: UseDrawerContext | undefined) => UseDrawerContext;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { DrawerStackApi } from "@sprawlify/primitives/machines/drawer";
|
|
2
|
+
import type { PropTypes } from "../../core";
|
|
3
|
+
import type { Accessor } from "../../types";
|
|
4
|
+
export interface UseDrawerStackContext extends Accessor<DrawerStackApi<PropTypes>> {
|
|
5
|
+
}
|
|
6
|
+
export declare const DrawerStackProvider: (opts: UseDrawerStackContext) => void, useDrawerStackContext: (fallback?: UseDrawerStackContext | undefined) => UseDrawerStackContext;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { getContext, hasContext, setContext } from "svelte";
|
|
2
|
+
const DRAWER_STACK_STORE_KEY = Symbol("DrawerStackStore");
|
|
3
|
+
export const provideDrawerStackStore = (stack) => setContext(DRAWER_STACK_STORE_KEY, stack);
|
|
4
|
+
export const useDrawerStackStore = () => hasContext(DRAWER_STACK_STORE_KEY) ? getContext(DRAWER_STACK_STORE_KEY) : undefined;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { Accessor, Optional } from "../../types";
|
|
2
|
+
import * as drawer from "@sprawlify/primitives/machines/drawer";
|
|
3
|
+
import { type PropTypes } from "../../core";
|
|
4
|
+
import { type MaybeFunction } from "@sprawlify/primitives/utils";
|
|
5
|
+
export interface UseDrawerProps extends Optional<Omit<drawer.Props, "dir" | "getRootNode" | "defaultSnapPoint">, "id"> {
|
|
6
|
+
defaultSnapPoint?: drawer.SnapPoint | undefined;
|
|
7
|
+
}
|
|
8
|
+
export interface UseDrawerReturn extends Accessor<drawer.Api<PropTypes>> {
|
|
9
|
+
}
|
|
10
|
+
export declare const useDrawer: (props: MaybeFunction<UseDrawerProps>) => UseDrawerReturn;
|
package/dist/components/{bottom-sheet/use-bottom-sheet.svelte.js → drawer/use-drawer.svelte.js}
RENAMED
|
@@ -1,20 +1,23 @@
|
|
|
1
1
|
import { useEnvironmentContext } from "../../providers/environment";
|
|
2
2
|
import { useLocaleContext } from "../../providers/locale";
|
|
3
|
-
import * as
|
|
3
|
+
import * as drawer from "@sprawlify/primitives/machines/drawer";
|
|
4
4
|
import { normalizeProps, useMachine } from "../../core";
|
|
5
5
|
import { runIfFn } from "@sprawlify/primitives/utils";
|
|
6
|
-
|
|
6
|
+
import { useDrawerStackStore } from "./use-drawer-stack-store";
|
|
7
|
+
export const useDrawer = (props) => {
|
|
7
8
|
const env = useEnvironmentContext();
|
|
8
9
|
const locale = useLocaleContext();
|
|
10
|
+
const stack = useDrawerStackStore();
|
|
9
11
|
const machineProps = $derived.by(() => {
|
|
10
12
|
const resolvedProps = runIfFn(props);
|
|
11
13
|
return {
|
|
12
14
|
dir: locale().dir,
|
|
13
15
|
getRootNode: env().getRootNode,
|
|
16
|
+
stack,
|
|
14
17
|
...resolvedProps,
|
|
15
18
|
};
|
|
16
19
|
});
|
|
17
|
-
const service = useMachine(
|
|
18
|
-
const api = $derived(
|
|
20
|
+
const service = useMachine(drawer.machine, () => machineProps);
|
|
21
|
+
const api = $derived(drawer.connect(service, normalizeProps));
|
|
19
22
|
return () => api;
|
|
20
23
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const tourAnatomy: import("@sprawlify/primitives/anatomy").AnatomyInstance<"description" | "title" | "content" | "
|
|
1
|
+
export declare const tourAnatomy: import("@sprawlify/primitives/anatomy").AnatomyInstance<"description" | "title" | "content" | "positioner" | "backdrop" | "closeTrigger" | "control" | "progressText" | "arrow" | "actionTrigger" | "arrowTip" | "spotlight">;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sprawlify/svelte",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.111",
|
|
4
4
|
"description": "Svelte wrapper for primitives.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "sprawlify <npm@sprawlify.com>",
|
|
@@ -46,11 +46,6 @@
|
|
|
46
46
|
"svelte": "./dist/components/avatar/index.js",
|
|
47
47
|
"default": "./dist/components/avatar/index.js"
|
|
48
48
|
},
|
|
49
|
-
"./bottom-sheet": {
|
|
50
|
-
"types": "./dist/components/bottom-sheet/index.d.ts",
|
|
51
|
-
"svelte": "./dist/components/bottom-sheet/index.js",
|
|
52
|
-
"default": "./dist/components/bottom-sheet/index.js"
|
|
53
|
-
},
|
|
54
49
|
"./carousel": {
|
|
55
50
|
"types": "./dist/components/carousel/index.d.ts",
|
|
56
51
|
"svelte": "./dist/components/carousel/index.js",
|
|
@@ -106,6 +101,11 @@
|
|
|
106
101
|
"svelte": "./dist/components/download-trigger/index.js",
|
|
107
102
|
"default": "./dist/components/download-trigger/index.js"
|
|
108
103
|
},
|
|
104
|
+
"./drawer": {
|
|
105
|
+
"types": "./dist/components/drawer/index.d.ts",
|
|
106
|
+
"svelte": "./dist/components/drawer/index.js",
|
|
107
|
+
"default": "./dist/components/drawer/index.js"
|
|
108
|
+
},
|
|
109
109
|
"./dropdown-menu": {
|
|
110
110
|
"types": "./dist/components/dropdown-menu/index.d.ts",
|
|
111
111
|
"svelte": "./dist/components/dropdown-menu/index.js",
|
|
@@ -341,7 +341,7 @@
|
|
|
341
341
|
"access": "public"
|
|
342
342
|
},
|
|
343
343
|
"dependencies": {
|
|
344
|
-
"@sprawlify/primitives": "0.0.
|
|
344
|
+
"@sprawlify/primitives": "0.0.111"
|
|
345
345
|
},
|
|
346
346
|
"peerDependencies": {
|
|
347
347
|
"svelte": "^5.0.0"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { anatomy as bottomSheetAnatomy } from "@sprawlify/primitives/machines/bottom-sheet";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { anatomy as bottomSheetAnatomy } from "@sprawlify/primitives/machines/bottom-sheet";
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
export interface BottomSheetBackdropBaseProps extends PolymorphicProps<'div'>, RefAttribute {
|
|
3
|
-
ref?: Element | null;
|
|
4
|
-
}
|
|
5
|
-
export interface BottomSheetBackdropProps extends Assign<HTMLProps<'div'>, BottomSheetBackdropBaseProps> {
|
|
6
|
-
}
|
|
7
|
-
declare const BottomSheetBackdrop: import("svelte").Component<BottomSheetBackdropProps, {}, "ref">;
|
|
8
|
-
type BottomSheetBackdrop = ReturnType<typeof BottomSheetBackdrop>;
|
|
9
|
-
export default BottomSheetBackdrop;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<script module lang="ts">
|
|
2
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types'
|
|
3
|
-
|
|
4
|
-
export interface BottomSheetCloseTriggerBaseProps extends PolymorphicProps<'button'>, RefAttribute {}
|
|
5
|
-
export interface BottomSheetCloseTriggerProps extends Assign<HTMLProps<'button'>, BottomSheetCloseTriggerBaseProps> {}
|
|
6
|
-
</script>
|
|
7
|
-
|
|
8
|
-
<script lang="ts">
|
|
9
|
-
import { mergeProps } from '../../core'
|
|
10
|
-
import { Sprawlify } from '../factory'
|
|
11
|
-
import { useBottomSheetContext } from './use-bottom-sheet-context'
|
|
12
|
-
|
|
13
|
-
let { ref = $bindable(null), ...props }: BottomSheetCloseTriggerProps = $props()
|
|
14
|
-
|
|
15
|
-
const bottomSheet = useBottomSheetContext()
|
|
16
|
-
const mergedProps = $derived(mergeProps(bottomSheet().getCloseTriggerProps(), props))
|
|
17
|
-
</script>
|
|
18
|
-
|
|
19
|
-
<Sprawlify as="button" bind:ref {...mergedProps} />
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
export interface BottomSheetCloseTriggerBaseProps extends PolymorphicProps<'button'>, RefAttribute {
|
|
3
|
-
}
|
|
4
|
-
export interface BottomSheetCloseTriggerProps extends Assign<HTMLProps<'button'>, BottomSheetCloseTriggerBaseProps> {
|
|
5
|
-
}
|
|
6
|
-
declare const BottomSheetCloseTrigger: import("svelte").Component<BottomSheetCloseTriggerProps, {}, "ref">;
|
|
7
|
-
type BottomSheetCloseTrigger = ReturnType<typeof BottomSheetCloseTrigger>;
|
|
8
|
-
export default BottomSheetCloseTrigger;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
import type { ContentProps } from '@sprawlify/primitives/machines/bottom-sheet';
|
|
3
|
-
export interface BottomSheetContentBaseProps extends PolymorphicProps<'div'>, ContentProps, RefAttribute {
|
|
4
|
-
ref?: Element | null;
|
|
5
|
-
}
|
|
6
|
-
export interface BottomSheetContentProps extends Assign<Omit<HTMLProps<'div'>, 'draggable'>, BottomSheetContentBaseProps> {
|
|
7
|
-
}
|
|
8
|
-
declare const BottomSheetContent: import("svelte").Component<BottomSheetContentProps, {}, "ref">;
|
|
9
|
-
type BottomSheetContent = ReturnType<typeof BottomSheetContent>;
|
|
10
|
-
export default BottomSheetContent;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<script module lang="ts">
|
|
2
|
-
import type { Snippet } from 'svelte'
|
|
3
|
-
import type { UseBottomSheetContext } from './use-bottom-sheet-context'
|
|
4
|
-
|
|
5
|
-
export interface BottomSheetContextProps {
|
|
6
|
-
children: Snippet<[UseBottomSheetContext]>
|
|
7
|
-
}
|
|
8
|
-
</script>
|
|
9
|
-
|
|
10
|
-
<script lang="ts">
|
|
11
|
-
import { useBottomSheetContext } from './use-bottom-sheet-context'
|
|
12
|
-
|
|
13
|
-
const { children }: BottomSheetContextProps = $props()
|
|
14
|
-
|
|
15
|
-
const bottomSheet = useBottomSheetContext()
|
|
16
|
-
</script>
|
|
17
|
-
|
|
18
|
-
{@render children(bottomSheet)}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Snippet } from 'svelte';
|
|
2
|
-
import type { UseBottomSheetContext } from './use-bottom-sheet-context';
|
|
3
|
-
export interface BottomSheetContextProps {
|
|
4
|
-
children: Snippet<[UseBottomSheetContext]>;
|
|
5
|
-
}
|
|
6
|
-
declare const BottomSheetContext: import("svelte").Component<BottomSheetContextProps, {}, "">;
|
|
7
|
-
type BottomSheetContext = ReturnType<typeof BottomSheetContext>;
|
|
8
|
-
export default BottomSheetContext;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
<script module lang="ts">
|
|
2
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types'
|
|
3
|
-
|
|
4
|
-
export interface BottomSheetGrabberIndicatorBaseProps extends PolymorphicProps<'div'>, RefAttribute {}
|
|
5
|
-
export interface BottomSheetGrabberIndicatorProps
|
|
6
|
-
extends Assign<HTMLProps<'div'>, BottomSheetGrabberIndicatorBaseProps> {}
|
|
7
|
-
</script>
|
|
8
|
-
|
|
9
|
-
<script lang="ts">
|
|
10
|
-
import { mergeProps } from '../../core'
|
|
11
|
-
import { Sprawlify } from '../factory'
|
|
12
|
-
import { useBottomSheetContext } from './use-bottom-sheet-context'
|
|
13
|
-
|
|
14
|
-
let { ref = $bindable(null), ...props }: BottomSheetGrabberIndicatorProps = $props()
|
|
15
|
-
|
|
16
|
-
const bottomSheet = useBottomSheetContext()
|
|
17
|
-
const mergedProps = $derived(mergeProps(bottomSheet().getGrabberIndicatorProps(), props))
|
|
18
|
-
</script>
|
|
19
|
-
|
|
20
|
-
<Sprawlify as="div" bind:ref {...mergedProps} />
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
export interface BottomSheetGrabberIndicatorBaseProps extends PolymorphicProps<'div'>, RefAttribute {
|
|
3
|
-
}
|
|
4
|
-
export interface BottomSheetGrabberIndicatorProps extends Assign<HTMLProps<'div'>, BottomSheetGrabberIndicatorBaseProps> {
|
|
5
|
-
}
|
|
6
|
-
declare const BottomSheetGrabberIndicator: import("svelte").Component<BottomSheetGrabberIndicatorProps, {}, "ref">;
|
|
7
|
-
type BottomSheetGrabberIndicator = ReturnType<typeof BottomSheetGrabberIndicator>;
|
|
8
|
-
export default BottomSheetGrabberIndicator;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<script module lang="ts">
|
|
2
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types'
|
|
3
|
-
|
|
4
|
-
export interface BottomSheetGrabberBaseProps extends PolymorphicProps<'div'>, RefAttribute {}
|
|
5
|
-
export interface BottomSheetGrabberProps extends Assign<HTMLProps<'div'>, BottomSheetGrabberBaseProps> {}
|
|
6
|
-
</script>
|
|
7
|
-
|
|
8
|
-
<script lang="ts">
|
|
9
|
-
import { mergeProps } from '../../core'
|
|
10
|
-
import { Sprawlify } from '../factory'
|
|
11
|
-
import { useBottomSheetContext } from './use-bottom-sheet-context'
|
|
12
|
-
|
|
13
|
-
let { ref = $bindable(null), ...props }: BottomSheetGrabberProps = $props()
|
|
14
|
-
|
|
15
|
-
const bottomSheet = useBottomSheetContext()
|
|
16
|
-
const mergedProps = $derived(mergeProps(bottomSheet().getGrabberProps(), props))
|
|
17
|
-
</script>
|
|
18
|
-
|
|
19
|
-
<Sprawlify as="div" bind:ref {...mergedProps} />
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
export interface BottomSheetGrabberBaseProps extends PolymorphicProps<'div'>, RefAttribute {
|
|
3
|
-
}
|
|
4
|
-
export interface BottomSheetGrabberProps extends Assign<HTMLProps<'div'>, BottomSheetGrabberBaseProps> {
|
|
5
|
-
}
|
|
6
|
-
declare const BottomSheetGrabber: import("svelte").Component<BottomSheetGrabberProps, {}, "ref">;
|
|
7
|
-
type BottomSheetGrabber = ReturnType<typeof BottomSheetGrabber>;
|
|
8
|
-
export default BottomSheetGrabber;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Snippet } from 'svelte';
|
|
2
|
-
import type { UseBottomSheetReturn } from './use-bottom-sheet.svelte';
|
|
3
|
-
export interface BottomSheetRootProviderBaseProps {
|
|
4
|
-
value: UseBottomSheetReturn;
|
|
5
|
-
}
|
|
6
|
-
export interface BottomSheetRootProviderProps extends BottomSheetRootProviderBaseProps {
|
|
7
|
-
children?: Snippet;
|
|
8
|
-
}
|
|
9
|
-
declare const BottomSheetRootProvider: import("svelte").Component<BottomSheetRootProviderProps, {}, "">;
|
|
10
|
-
type BottomSheetRootProvider = ReturnType<typeof BottomSheetRootProvider>;
|
|
11
|
-
export default BottomSheetRootProvider;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Snippet } from 'svelte';
|
|
2
|
-
import type { UsePresenceProps } from '../presence';
|
|
3
|
-
import type { UseBottomSheetProps } from './use-bottom-sheet.svelte';
|
|
4
|
-
export interface BottomSheetRootBaseProps extends UseBottomSheetProps, UsePresenceProps {
|
|
5
|
-
}
|
|
6
|
-
export interface BottomSheetRootProps extends BottomSheetRootBaseProps {
|
|
7
|
-
children?: Snippet;
|
|
8
|
-
}
|
|
9
|
-
declare const BottomSheetRoot: import("svelte").Component<BottomSheetRootProps, {}, "open">;
|
|
10
|
-
type BottomSheetRoot = ReturnType<typeof BottomSheetRoot>;
|
|
11
|
-
export default BottomSheetRoot;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<script module lang="ts">
|
|
2
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types'
|
|
3
|
-
|
|
4
|
-
export interface BottomSheetTitleBaseProps extends PolymorphicProps<'h2'>, RefAttribute {}
|
|
5
|
-
export interface BottomSheetTitleProps extends Assign<HTMLProps<'h2'>, BottomSheetTitleBaseProps> {}
|
|
6
|
-
</script>
|
|
7
|
-
|
|
8
|
-
<script lang="ts">
|
|
9
|
-
import { mergeProps } from '../../core'
|
|
10
|
-
import { Sprawlify } from '../factory'
|
|
11
|
-
import { useBottomSheetContext } from './use-bottom-sheet-context'
|
|
12
|
-
|
|
13
|
-
let { ref = $bindable(null), ...props }: BottomSheetTitleProps = $props()
|
|
14
|
-
|
|
15
|
-
const bottomSheet = useBottomSheetContext()
|
|
16
|
-
const mergedProps = $derived(mergeProps(bottomSheet().getTitleProps(), props))
|
|
17
|
-
</script>
|
|
18
|
-
|
|
19
|
-
<Sprawlify as="h2" bind:ref {...mergedProps} />
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
export interface BottomSheetTitleBaseProps extends PolymorphicProps<'h2'>, RefAttribute {
|
|
3
|
-
}
|
|
4
|
-
export interface BottomSheetTitleProps extends Assign<HTMLProps<'h2'>, BottomSheetTitleBaseProps> {
|
|
5
|
-
}
|
|
6
|
-
declare const BottomSheetTitle: import("svelte").Component<BottomSheetTitleProps, {}, "ref">;
|
|
7
|
-
type BottomSheetTitle = ReturnType<typeof BottomSheetTitle>;
|
|
8
|
-
export default BottomSheetTitle;
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
<script module lang="ts">
|
|
2
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types'
|
|
3
|
-
|
|
4
|
-
export interface BottomSheetTriggerBaseProps extends PolymorphicProps<'button'>, RefAttribute {}
|
|
5
|
-
export interface BottomSheetTriggerProps extends Assign<HTMLProps<'button'>, BottomSheetTriggerBaseProps> {}
|
|
6
|
-
</script>
|
|
7
|
-
|
|
8
|
-
<script lang="ts">
|
|
9
|
-
import { mergeProps } from '../../core'
|
|
10
|
-
import { Sprawlify } from '../factory'
|
|
11
|
-
import { usePresenceContext } from '../presence'
|
|
12
|
-
import { useBottomSheetContext } from './use-bottom-sheet-context'
|
|
13
|
-
|
|
14
|
-
let { ref = $bindable(null), ...props }: BottomSheetTriggerProps = $props()
|
|
15
|
-
|
|
16
|
-
const bottomSheet = useBottomSheetContext()
|
|
17
|
-
const presence = usePresenceContext()
|
|
18
|
-
const mergedProps = $derived(
|
|
19
|
-
mergeProps(
|
|
20
|
-
{
|
|
21
|
-
...bottomSheet().getTriggerProps(),
|
|
22
|
-
'aria-controls': presence().unmounted ? undefined : bottomSheet().getTriggerProps()['aria-controls'],
|
|
23
|
-
},
|
|
24
|
-
props,
|
|
25
|
-
),
|
|
26
|
-
)
|
|
27
|
-
</script>
|
|
28
|
-
|
|
29
|
-
<Sprawlify as="button" bind:ref {...mergedProps} />
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Assign, HTMLProps, PolymorphicProps, RefAttribute } from '../../types';
|
|
2
|
-
export interface BottomSheetTriggerBaseProps extends PolymorphicProps<'button'>, RefAttribute {
|
|
3
|
-
}
|
|
4
|
-
export interface BottomSheetTriggerProps extends Assign<HTMLProps<'button'>, BottomSheetTriggerBaseProps> {
|
|
5
|
-
}
|
|
6
|
-
declare const BottomSheetTrigger: import("svelte").Component<BottomSheetTriggerProps, {}, "ref">;
|
|
7
|
-
type BottomSheetTrigger = ReturnType<typeof BottomSheetTrigger>;
|
|
8
|
-
export default BottomSheetTrigger;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export type { OpenChangeDetails } from "@sprawlify/primitives/machines/bottom-sheet";
|
|
2
|
-
export { default as Backdrop, type BottomSheetBackdropBaseProps as BackdropBaseProps, type BottomSheetBackdropProps as BackdropProps, } from "./bottom-sheet-backdrop.svelte";
|
|
3
|
-
export { default as CloseTrigger, type BottomSheetCloseTriggerBaseProps as CloseTriggerBaseProps, type BottomSheetCloseTriggerProps as CloseTriggerProps, } from "./bottom-sheet-close-trigger.svelte";
|
|
4
|
-
export { default as Content, type BottomSheetContentBaseProps as ContentBaseProps, type BottomSheetContentProps as ContentProps, } from "./bottom-sheet-content.svelte";
|
|
5
|
-
export { default as Context, type BottomSheetContextProps as ContextProps, } from "./bottom-sheet-context.svelte";
|
|
6
|
-
export { default as Grabber, type BottomSheetGrabberBaseProps as GrabberBaseProps, type BottomSheetGrabberProps as GrabberProps, } from "./bottom-sheet-grabber.svelte";
|
|
7
|
-
export { default as GrabberIndicator, type BottomSheetGrabberIndicatorBaseProps as GrabberIndicatorBaseProps, type BottomSheetGrabberIndicatorProps as GrabberIndicatorProps, } from "./bottom-sheet-grabber-indicator.svelte";
|
|
8
|
-
export { default as Root, type BottomSheetRootBaseProps as RootBaseProps, type BottomSheetRootProps as RootProps, } from "./bottom-sheet-root.svelte";
|
|
9
|
-
export { default as RootProvider, type BottomSheetRootProviderBaseProps as RootProviderBaseProps, type BottomSheetRootProviderProps as RootProviderProps, } from "./bottom-sheet-root-provider.svelte";
|
|
10
|
-
export { default as Title, type BottomSheetTitleBaseProps as TitleBaseProps, type BottomSheetTitleProps as TitleProps, } from "./bottom-sheet-title.svelte";
|
|
11
|
-
export { default as Trigger, type BottomSheetTriggerBaseProps as TriggerBaseProps, type BottomSheetTriggerProps as TriggerProps, } from "./bottom-sheet-trigger.svelte";
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export { default as Backdrop, } from "./bottom-sheet-backdrop.svelte";
|
|
2
|
-
export { default as CloseTrigger, } from "./bottom-sheet-close-trigger.svelte";
|
|
3
|
-
export { default as Content, } from "./bottom-sheet-content.svelte";
|
|
4
|
-
export { default as Context, } from "./bottom-sheet-context.svelte";
|
|
5
|
-
export { default as Grabber, } from "./bottom-sheet-grabber.svelte";
|
|
6
|
-
export { default as GrabberIndicator, } from "./bottom-sheet-grabber-indicator.svelte";
|
|
7
|
-
export { default as Root, } from "./bottom-sheet-root.svelte";
|
|
8
|
-
export { default as RootProvider, } from "./bottom-sheet-root-provider.svelte";
|
|
9
|
-
export { default as Title, } from "./bottom-sheet-title.svelte";
|
|
10
|
-
export { default as Trigger, } from "./bottom-sheet-trigger.svelte";
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export type { OpenChangeDetails as BottomSheetOpenChangeDetails } from "@sprawlify/primitives/machines/bottom-sheet";
|
|
2
|
-
export { default as BottomSheetBackdrop, type BottomSheetBackdropBaseProps, type BottomSheetBackdropProps, } from "./bottom-sheet-backdrop.svelte";
|
|
3
|
-
export { default as BottomSheetCloseTrigger, type BottomSheetCloseTriggerBaseProps, type BottomSheetCloseTriggerProps, } from "./bottom-sheet-close-trigger.svelte";
|
|
4
|
-
export { default as BottomSheetContent, type BottomSheetContentBaseProps, type BottomSheetContentProps, } from "./bottom-sheet-content.svelte";
|
|
5
|
-
export { default as BottomSheetContext, type BottomSheetContextProps, } from "./bottom-sheet-context.svelte";
|
|
6
|
-
export { default as BottomSheetGrabber, type BottomSheetGrabberBaseProps, type BottomSheetGrabberProps, } from "./bottom-sheet-grabber.svelte";
|
|
7
|
-
export { default as BottomSheetGrabberIndicator, type BottomSheetGrabberIndicatorBaseProps, type BottomSheetGrabberIndicatorProps, } from "./bottom-sheet-grabber-indicator.svelte";
|
|
8
|
-
export { default as BottomSheetRoot, type BottomSheetRootBaseProps, type BottomSheetRootProps, } from "./bottom-sheet-root.svelte";
|
|
9
|
-
export { default as BottomSheetRootProvider, type BottomSheetRootProviderBaseProps, type BottomSheetRootProviderProps, } from "./bottom-sheet-root-provider.svelte";
|
|
10
|
-
export { default as BottomSheetTitle, type BottomSheetTitleBaseProps, type BottomSheetTitleProps, } from "./bottom-sheet-title.svelte";
|
|
11
|
-
export { default as BottomSheetTrigger, type BottomSheetTriggerBaseProps, type BottomSheetTriggerProps, } from "./bottom-sheet-trigger.svelte";
|
|
12
|
-
export { bottomSheetAnatomy } from "./bottom-sheet-anatomy";
|
|
13
|
-
export { useBottomSheetContext, type UseBottomSheetContext } from "./use-bottom-sheet-context";
|
|
14
|
-
export { useBottomSheet, type UseBottomSheetProps, type UseBottomSheetReturn, } from "./use-bottom-sheet.svelte";
|
|
15
|
-
export * as BottomSheet from "./bottom-sheet";
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export { default as BottomSheetBackdrop, } from "./bottom-sheet-backdrop.svelte";
|
|
2
|
-
export { default as BottomSheetCloseTrigger, } from "./bottom-sheet-close-trigger.svelte";
|
|
3
|
-
export { default as BottomSheetContent, } from "./bottom-sheet-content.svelte";
|
|
4
|
-
export { default as BottomSheetContext, } from "./bottom-sheet-context.svelte";
|
|
5
|
-
export { default as BottomSheetGrabber, } from "./bottom-sheet-grabber.svelte";
|
|
6
|
-
export { default as BottomSheetGrabberIndicator, } from "./bottom-sheet-grabber-indicator.svelte";
|
|
7
|
-
export { default as BottomSheetRoot, } from "./bottom-sheet-root.svelte";
|
|
8
|
-
export { default as BottomSheetRootProvider, } from "./bottom-sheet-root-provider.svelte";
|
|
9
|
-
export { default as BottomSheetTitle, } from "./bottom-sheet-title.svelte";
|
|
10
|
-
export { default as BottomSheetTrigger, } from "./bottom-sheet-trigger.svelte";
|
|
11
|
-
export { bottomSheetAnatomy } from "./bottom-sheet-anatomy";
|
|
12
|
-
export { useBottomSheetContext } from "./use-bottom-sheet-context";
|
|
13
|
-
export { useBottomSheet, } from "./use-bottom-sheet.svelte";
|
|
14
|
-
export * as BottomSheet from "./bottom-sheet";
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import type { UseBottomSheetReturn } from "./use-bottom-sheet.svelte";
|
|
2
|
-
export interface UseBottomSheetContext extends UseBottomSheetReturn {
|
|
3
|
-
}
|
|
4
|
-
export declare const BottomSheetProvider: (opts: UseBottomSheetContext) => void, useBottomSheetContext: (fallback?: UseBottomSheetContext | undefined) => UseBottomSheetContext;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Accessor, Optional } from "../../types";
|
|
2
|
-
import * as bottomSheet from "@sprawlify/primitives/machines/bottom-sheet";
|
|
3
|
-
import { type PropTypes } from "../../core";
|
|
4
|
-
import { type MaybeFunction } from "@sprawlify/primitives/utils";
|
|
5
|
-
export interface UseBottomSheetProps extends Optional<Omit<bottomSheet.Props, "getRootNode" | "dir">, "id"> {
|
|
6
|
-
}
|
|
7
|
-
export interface UseBottomSheetReturn extends Accessor<bottomSheet.Api<PropTypes>> {
|
|
8
|
-
}
|
|
9
|
-
export declare const useBottomSheet: (props: MaybeFunction<UseBottomSheetProps>) => UseBottomSheetReturn;
|