@allxsmith/bestax-bulma 5.67.10 → 5.67.11

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.
@@ -49,11 +49,15 @@ export interface ModalProps extends Omit<React.HTMLAttributes<HTMLDivElement>, '
49
49
  closeOnEscape?: boolean;
50
50
  /**
51
51
  * Lock page scroll while the modal is active, padding the page by the room
52
- * its scrollbar took so the content stays put. An element fixed to the
53
- * window's right edge, such as a `fixed` Navbar, isn't padded, and moves by
54
- * the scrollbar's width while the page is locked. Ref-counted and shared
55
- * with `Dialog`, `Sidebar` and `Loading`, so whichever overlay closes first
56
- * does not unlock the page underneath one that is still open.
52
+ * its scrollbar took so the content stays put. A `fixed` Navbar, the toast
53
+ * and notification stacks and an Affix stay put too. The padding doesn't
54
+ * reach an element of your own fixed to the window's edge, which moves by
55
+ * the scrollbar's width unless it adds
56
+ * `var(--bulma-scroll-lock-offset-right, 0px)` to its `right` (the `-left`
57
+ * one to its `left`), which the lock sets on `<html>` while it's on.
58
+ * Ref-counted and shared with `Dialog`, `Sidebar` and `Loading`, so
59
+ * whichever overlay closes first does not unlock the page underneath one
60
+ * that is still open.
57
61
  * @defaultValue true
58
62
  */
59
63
  lockScroll?: boolean;
@@ -1,3 +1,15 @@
1
+ /** A side of the window the page's scrollbar can take room on. */
2
+ type ScrollLockSide = 'left' | 'right';
3
+ /**
4
+ * The room the page's scrollbar gave back on one side while a lock is on,
5
+ * and `0px` otherwise, as a CSS value. An element fixed to that edge of the
6
+ * window adds it to its offset there, so it stays where it was as the
7
+ * scrollbar goes.
8
+ *
9
+ * @param side - The edge of the window the element is fixed to.
10
+ * @returns A `var()` with a `0px` fallback.
11
+ */
12
+ export declare const scrollLockOffset: (side: ScrollLockSide) => string;
1
13
  /**
2
14
  * Locks (and ref-counted-ly unlocks) the page's scrolling while `active` is
3
15
  * true. Safe to call from multiple components at once: the page is only
@@ -7,3 +19,4 @@
7
19
  * @param active - Whether this caller wants the page's scrolling locked.
8
20
  */
9
21
  export declare function useScrollLock(active: boolean): void;
22
+ export {};
@@ -49,11 +49,15 @@ export interface ModalProps extends Omit<React.HTMLAttributes<HTMLDivElement>, '
49
49
  closeOnEscape?: boolean;
50
50
  /**
51
51
  * Lock page scroll while the modal is active, padding the page by the room
52
- * its scrollbar took so the content stays put. An element fixed to the
53
- * window's right edge, such as a `fixed` Navbar, isn't padded, and moves by
54
- * the scrollbar's width while the page is locked. Ref-counted and shared
55
- * with `Dialog`, `Sidebar` and `Loading`, so whichever overlay closes first
56
- * does not unlock the page underneath one that is still open.
52
+ * its scrollbar took so the content stays put. A `fixed` Navbar, the toast
53
+ * and notification stacks and an Affix stay put too. The padding doesn't
54
+ * reach an element of your own fixed to the window's edge, which moves by
55
+ * the scrollbar's width unless it adds
56
+ * `var(--bulma-scroll-lock-offset-right, 0px)` to its `right` (the `-left`
57
+ * one to its `left`), which the lock sets on `<html>` while it's on.
58
+ * Ref-counted and shared with `Dialog`, `Sidebar` and `Loading`, so
59
+ * whichever overlay closes first does not unlock the page underneath one
60
+ * that is still open.
57
61
  * @defaultValue true
58
62
  */
59
63
  lockScroll?: boolean;
@@ -1,3 +1,15 @@
1
+ /** A side of the window the page's scrollbar can take room on. */
2
+ type ScrollLockSide = 'left' | 'right';
3
+ /**
4
+ * The room the page's scrollbar gave back on one side while a lock is on,
5
+ * and `0px` otherwise, as a CSS value. An element fixed to that edge of the
6
+ * window adds it to its offset there, so it stays where it was as the
7
+ * scrollbar goes.
8
+ *
9
+ * @param side - The edge of the window the element is fixed to.
10
+ * @returns A `var()` with a `0px` fallback.
11
+ */
12
+ export declare const scrollLockOffset: (side: ScrollLockSide) => string;
1
13
  /**
2
14
  * Locks (and ref-counted-ly unlocks) the page's scrolling while `active` is
3
15
  * true. Safe to call from multiple components at once: the page is only
@@ -7,3 +19,4 @@
7
19
  * @param active - Whether this caller wants the page's scrolling locked.
8
20
  */
9
21
  export declare function useScrollLock(active: boolean): void;
22
+ export {};