@stll/ui 0.23.0 → 0.23.1

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.
@@ -10,8 +10,8 @@
10
10
  */
11
11
  declare const buttonAccessibleDisabledClass = "cursor-not-allowed opacity-64";
12
12
  declare const buttonVariants: (props?: ({
13
- size?: "default" | "xs" | "sm" | "icon" | "lg" | "chip" | "icon-lg" | "icon-sm" | "icon-xl" | "icon-xs" | "xl" | null | undefined;
14
- variant?: "link" | "default" | "destructive" | "outline" | "destructive-outline" | "ghost" | "secondary" | null | undefined;
13
+ size?: "xs" | "sm" | "icon" | "default" | "lg" | "chip" | "icon-lg" | "icon-sm" | "icon-xl" | "icon-xs" | "xl" | null | undefined;
14
+ variant?: "link" | "destructive" | "outline" | "default" | "destructive-outline" | "ghost" | "secondary" | null | undefined;
15
15
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
16
16
  //#endregion
17
17
  export { buttonAccessibleDisabledClass, buttonVariants };
@@ -5,7 +5,7 @@ import { VariantProps } from "class-variance-authority";
5
5
  //#region src/components/input-group.d.ts
6
6
  declare const InputGroup: ({ className, ...props }: React$1.ComponentProps<"div">) => React$1.JSX.Element;
7
7
  declare const inputGroupAddonVariants: (props?: ({
8
- align?: "inline-end" | "inline-start" | "block-end" | "block-start" | null | undefined;
8
+ align?: "inline-end" | "inline-start" | "block-start" | "block-end" | null | undefined;
9
9
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
10
10
  declare const InputGroupAddon: ({ className, align, ...props }: React$1.ComponentProps<"div"> & VariantProps<typeof inputGroupAddonVariants>) => React$1.JSX.Element;
11
11
  declare const InputGroupText: ({ className, ...props }: React$1.ComponentProps<"span">) => React$1.JSX.Element;
@@ -30,7 +30,7 @@ declare function useSidebar(): SidebarContextProps;
30
30
  * left for the content column. Mobile reports 0: there the sidebar is an
31
31
  * overlay sheet and occupies no layout width.
32
32
  */
33
- declare function useSidebarInlineSize(): 0 | 48 | 256;
33
+ declare function useSidebarInlineSize(): 0 | 256 | 48;
34
34
  declare const SidebarProvider: ({ defaultOpen, forceCollapsed, open: openProp, onOpenChange: setOpenProp, className, style, children, ...props }: React.ComponentProps<"div"> & {
35
35
  defaultOpen?: boolean;
36
36
  forceCollapsed?: boolean;
@@ -82,8 +82,8 @@ declare const SidebarGroupContent: ({ className, ...props }: React.ComponentProp
82
82
  declare const SidebarMenu: ({ className, ...props }: React.ComponentProps<"ul">) => import("react").JSX.Element;
83
83
  declare const SidebarMenuItem: ({ className, ...props }: React.ComponentProps<"li">) => import("react").JSX.Element;
84
84
  declare const sidebarMenuButtonVariants: (props?: ({
85
- variant?: "default" | "outline" | null | undefined;
86
- size?: "default" | "sm" | "lg" | "rail" | null | undefined;
85
+ variant?: "outline" | "default" | null | undefined;
86
+ size?: "sm" | "default" | "lg" | "rail" | null | undefined;
87
87
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
88
88
  declare const SidebarMenuButton: ({ asChild, isActive, variant, size, tooltip, className, ...props }: React.ComponentProps<"button"> & {
89
89
  asChild?: boolean;
@@ -3,7 +3,7 @@ import { KANBAN_CARD_STICKY_TOP_VAR, KANBAN_STICKY_TOP_CLASS, resolveKanbanCardS
3
3
  import { useKanbanDropTarget } from "./sortable-interactions.js";
4
4
  import { resolveOptionColor } from "../lib/option-color.js";
5
5
  import { jsx, jsxs } from "react/jsx-runtime";
6
- import { useEffect, useId, useRef, useState } from "react";
6
+ import { useId, useLayoutEffect, useRef, useState } from "react";
7
7
  import { useDndContext } from "@dnd-kit/core";
8
8
  import { SortableContext, verticalListSortingStrategy } from "@dnd-kit/sortable";
9
9
  import { defaultRangeExtractor, useVirtualizer } from "@tanstack/react-virtual";
@@ -102,14 +102,18 @@ const KanbanVirtualCell = ({ rows, getRowKey, renderRow, pagination, sortable, c
102
102
  const hasStickyFooter = footerPlacement === "sticky-start" && footer !== null && footer !== void 0;
103
103
  const stickyFooterRef = useRef(null);
104
104
  const [stickyFooterHeight, setStickyFooterHeight] = useState(0);
105
- useEffect(() => {
105
+ useLayoutEffect(() => {
106
106
  const element = stickyFooterRef.current;
107
107
  if (element === null) {
108
108
  setStickyFooterHeight(0);
109
109
  return;
110
110
  }
111
+ const measure = (height) => {
112
+ setStickyFooterHeight((current) => current === height ? current : height);
113
+ };
114
+ measure(element.getBoundingClientRect().height);
111
115
  const observer = new ResizeObserver(() => {
112
- setStickyFooterHeight(element.getBoundingClientRect().height);
116
+ measure(element.getBoundingClientRect().height);
113
117
  });
114
118
  observer.observe(element);
115
119
  return () => observer.disconnect();
@@ -5,6 +5,6 @@ declare const CONTROL_SIZE: Readonly<{
5
5
  readonly lg: "lg";
6
6
  }>;
7
7
  type ControlSize = (typeof CONTROL_SIZE)[keyof typeof CONTROL_SIZE];
8
- declare const CONTROL_SIZES: readonly ("default" | "sm" | "lg")[];
8
+ declare const CONTROL_SIZES: readonly ("sm" | "default" | "lg")[];
9
9
  //#endregion
10
10
  export { CONTROL_SIZE, CONTROL_SIZES, type ControlSize };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stll/ui",
3
- "version": "0.23.0",
3
+ "version": "0.23.1",
4
4
  "description": "Stella's design system: bidi-aware React primitives built on Base UI, the dockable inspector pane, and the Tailwind v4 theme they are styled with.",
5
5
  "keywords": [
6
6
  "base-ui",