@salesql/sql_components_vue3 3.6.0 → 3.7.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/composables/useViewportClamp.d.ts +13 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.es.js +1466 -1437
- package/dist/index.es.js.map +1 -1
- package/dist/sql_components_vue3.css +1 -1
- package/dist/ui/DsPopover/DsPopover.types.d.ts +11 -2
- package/llms-full.txt +12 -1
- package/package.json +1 -1
|
@@ -12,11 +12,23 @@ export type ClampSide = 'top' | 'bottom' | 'left' | 'right' | 'over';
|
|
|
12
12
|
* DsPopover is 12-way).
|
|
13
13
|
*/
|
|
14
14
|
export type ClampPlacement = ClampSide | `${ClampSide}-start` | `${ClampSide}-end`;
|
|
15
|
-
|
|
15
|
+
/**
|
|
16
|
+
* Turns the main-axis FLIP on for `useViewportClamp` (DsPopover only — see the module
|
|
17
|
+
* header). `trigger` is the element the floating panel is placed against: DsPopover's root,
|
|
18
|
+
* whose rect a `teleported` anchor mirrors, so this is the same ref either way. `gap` mirrors
|
|
19
|
+
* the CSS gap between panel and trigger, so the free-space math matches what the CSS
|
|
20
|
+
* actually renders (DsPopover's `PANEL_GAP`, next to the `calc(100% + 6px)` it repeats).
|
|
21
|
+
*/
|
|
22
|
+
export interface ClampFlipOptions {
|
|
23
|
+
trigger: Ref<HTMLElement | null>;
|
|
24
|
+
gap: number;
|
|
25
|
+
}
|
|
26
|
+
export declare function useViewportClamp(elRef: Ref<HTMLElement | null>, placement: () => ClampPlacement, flip?: ClampFlipOptions): {
|
|
16
27
|
shift: Ref<number, number>;
|
|
17
28
|
shiftStyle: import("vue").ComputedRef<{
|
|
18
29
|
"--ds-overlay-shift": string;
|
|
19
30
|
} | null>;
|
|
31
|
+
resolvedPlacement: import("vue").ComputedRef<ClampPlacement>;
|
|
20
32
|
measure: () => Promise<void>;
|
|
21
33
|
activate: () => void;
|
|
22
34
|
deactivate: () => void;
|