@surdeddd/bottom-sheet 0.1.0 → 0.2.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/README.md +6 -0
- package/dist/BottomSheetEngine-CIT9Htti.d.cts +219 -0
- package/dist/BottomSheetEngine-Df9MwBbm.d.ts +219 -0
- package/dist/element.cjs +95 -440
- package/dist/element.d.cts +3 -56
- package/dist/element.d.ts +3 -56
- package/dist/element.iife.global.js +2 -2
- package/dist/element.js +95 -440
- package/dist/index.cjs +84 -494
- package/dist/index.d.cts +3 -84
- package/dist/index.d.ts +3 -84
- package/dist/index.js +84 -494
- package/dist/integrations/formik.d.cts +2 -8
- package/dist/integrations/formik.d.ts +2 -8
- package/dist/integrations/react-hook-form.d.cts +2 -11
- package/dist/integrations/react-hook-form.d.ts +2 -11
- package/dist/overlay.cjs +0 -87
- package/dist/overlay.d.cts +1 -137
- package/dist/overlay.d.ts +1 -137
- package/dist/overlay.js +0 -87
- package/dist/preact.d.cts +2 -2
- package/dist/preact.d.ts +2 -2
- package/dist/preact.js +0 -1
- package/dist/qwik.cjs +87 -439
- package/dist/qwik.d.cts +3 -24
- package/dist/qwik.d.ts +3 -24
- package/dist/qwik.js +87 -439
- package/dist/react.cjs +91 -496
- package/dist/react.d.cts +16 -158
- package/dist/react.d.ts +16 -158
- package/dist/react.js +91 -496
- package/dist/solid.cjs +87 -439
- package/dist/solid.d.cts +4 -31
- package/dist/solid.d.ts +4 -31
- package/dist/solid.js +87 -439
- package/dist/styles.css +27 -102
- package/dist/svelte.cjs +139 -462
- package/dist/svelte.d.ts +9 -2
- package/dist/svelte.js +139 -462
- package/dist/themes/ios.css +0 -3
- package/dist/themes/material.css +0 -3
- package/dist/themes/vercel.css +0 -3
- package/dist/{transform-Brkf-wzo.d.cts → transform-jVfAikE9.d.cts} +0 -1
- package/dist/{transform-Brkf-wzo.d.ts → transform-jVfAikE9.d.ts} +0 -1
- package/dist/vue.cjs +104 -446
- package/dist/vue.d.ts +7 -1
- package/dist/vue.js +105 -447
- package/package.json +3 -3
- package/dist/BottomSheetEngine-CvSVbo6c.d.cts +0 -704
- package/dist/BottomSheetEngine-DbO8rW_3.d.ts +0 -704
package/dist/qwik.d.cts
CHANGED
|
@@ -1,28 +1,9 @@
|
|
|
1
1
|
import * as _builder_io_qwik from '@builder.io/qwik';
|
|
2
2
|
import { QRL } from '@builder.io/qwik';
|
|
3
|
-
import { S as SnapPointDef, a as SheetMode, E as EngineState } from './BottomSheetEngine-
|
|
4
|
-
export { b as EngineOptions, c as SnapPoint } from './BottomSheetEngine-
|
|
5
|
-
import './transform-
|
|
3
|
+
import { S as SnapPointDef, a as SheetMode, E as EngineState } from './BottomSheetEngine-CIT9Htti.cjs';
|
|
4
|
+
export { b as EngineOptions, c as SnapPoint } from './BottomSheetEngine-CIT9Htti.cjs';
|
|
5
|
+
import './transform-jVfAikE9.cjs';
|
|
6
6
|
|
|
7
|
-
/**
|
|
8
|
-
* Props for the Qwik `BottomSheet` component. Optionally narrows to a
|
|
9
|
-
* literal-id union `TId` when the consumer pins `snapPoints` with `as const`
|
|
10
|
-
* and explicitly types the call site:
|
|
11
|
-
*
|
|
12
|
-
* ```tsx
|
|
13
|
-
* const points = [
|
|
14
|
-
* { id: "min", size: 96 },
|
|
15
|
-
* { id: "full", size: "85%" },
|
|
16
|
-
* ] as const;
|
|
17
|
-
* <BottomSheet<"min" | "full"> snapPoints={points} onSnap$={$((id) => ...)} />
|
|
18
|
-
* ```
|
|
19
|
-
*
|
|
20
|
-
* Without an explicit type argument `TId` defaults to `string` so existing
|
|
21
|
-
* call sites compile unchanged. The underlying engine stays `string`-typed;
|
|
22
|
-
* the literal narrowing is a TS-only convenience layered on top of the
|
|
23
|
-
* runtime. Note: Qwik wraps event handlers in `QRL<...>` because component
|
|
24
|
-
* boundaries are serialised — that wrapper preserves the inner `TId`.
|
|
25
|
-
*/
|
|
26
7
|
type BottomSheetProps<TId extends string = string> = {
|
|
27
8
|
snapPoints: SnapPointDef<TId>[] | ReadonlyArray<SnapPointDef<TId>>;
|
|
28
9
|
allowed?: TId[] | ReadonlyArray<TId>;
|
|
@@ -43,9 +24,7 @@ type BottomSheetProps<TId extends string = string> = {
|
|
|
43
24
|
backdrop?: boolean;
|
|
44
25
|
closeOnBackdrop?: boolean;
|
|
45
26
|
ariaLabel?: string;
|
|
46
|
-
/** Fires when the active snap settles. */
|
|
47
27
|
onSnap$?: QRL<(id: TId) => void>;
|
|
48
|
-
/** Fires on every state-affecting engine event (snap/dragstart/dragend). */
|
|
49
28
|
onChange$?: QRL<(state: EngineState & {
|
|
50
29
|
activeId: TId;
|
|
51
30
|
}) => void>;
|
package/dist/qwik.d.ts
CHANGED
|
@@ -1,28 +1,9 @@
|
|
|
1
1
|
import * as _builder_io_qwik from '@builder.io/qwik';
|
|
2
2
|
import { QRL } from '@builder.io/qwik';
|
|
3
|
-
import { S as SnapPointDef, a as SheetMode, E as EngineState } from './BottomSheetEngine-
|
|
4
|
-
export { b as EngineOptions, c as SnapPoint } from './BottomSheetEngine-
|
|
5
|
-
import './transform-
|
|
3
|
+
import { S as SnapPointDef, a as SheetMode, E as EngineState } from './BottomSheetEngine-Df9MwBbm.js';
|
|
4
|
+
export { b as EngineOptions, c as SnapPoint } from './BottomSheetEngine-Df9MwBbm.js';
|
|
5
|
+
import './transform-jVfAikE9.js';
|
|
6
6
|
|
|
7
|
-
/**
|
|
8
|
-
* Props for the Qwik `BottomSheet` component. Optionally narrows to a
|
|
9
|
-
* literal-id union `TId` when the consumer pins `snapPoints` with `as const`
|
|
10
|
-
* and explicitly types the call site:
|
|
11
|
-
*
|
|
12
|
-
* ```tsx
|
|
13
|
-
* const points = [
|
|
14
|
-
* { id: "min", size: 96 },
|
|
15
|
-
* { id: "full", size: "85%" },
|
|
16
|
-
* ] as const;
|
|
17
|
-
* <BottomSheet<"min" | "full"> snapPoints={points} onSnap$={$((id) => ...)} />
|
|
18
|
-
* ```
|
|
19
|
-
*
|
|
20
|
-
* Without an explicit type argument `TId` defaults to `string` so existing
|
|
21
|
-
* call sites compile unchanged. The underlying engine stays `string`-typed;
|
|
22
|
-
* the literal narrowing is a TS-only convenience layered on top of the
|
|
23
|
-
* runtime. Note: Qwik wraps event handlers in `QRL<...>` because component
|
|
24
|
-
* boundaries are serialised — that wrapper preserves the inner `TId`.
|
|
25
|
-
*/
|
|
26
7
|
type BottomSheetProps<TId extends string = string> = {
|
|
27
8
|
snapPoints: SnapPointDef<TId>[] | ReadonlyArray<SnapPointDef<TId>>;
|
|
28
9
|
allowed?: TId[] | ReadonlyArray<TId>;
|
|
@@ -43,9 +24,7 @@ type BottomSheetProps<TId extends string = string> = {
|
|
|
43
24
|
backdrop?: boolean;
|
|
44
25
|
closeOnBackdrop?: boolean;
|
|
45
26
|
ariaLabel?: string;
|
|
46
|
-
/** Fires when the active snap settles. */
|
|
47
27
|
onSnap$?: QRL<(id: TId) => void>;
|
|
48
|
-
/** Fires on every state-affecting engine event (snap/dragstart/dragend). */
|
|
49
28
|
onChange$?: QRL<(state: EngineState & {
|
|
50
29
|
activeId: TId;
|
|
51
30
|
}) => void>;
|