@still-forest/canopy 0.15.0 → 0.16.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.
package/dist/index.d.ts CHANGED
@@ -1,6 +1,9 @@
1
+ import { ClassProp } from 'class-variance-authority/types';
1
2
  import { ComponentProps } from 'react';
2
3
  import { default as default_2 } from 'react';
3
4
  import { JSX } from 'react/jsx-runtime';
5
+ import * as React_2 from 'react';
6
+ import { VariantProps } from 'class-variance-authority';
4
7
 
5
8
  export declare const Box: default_2.ForwardRefExoticComponent<BoxProps & default_2.RefAttributes<HTMLDivElement>>;
6
9
 
@@ -25,6 +28,10 @@ declare type BoxSizing = (typeof BOX_SIZINGS)[number];
25
28
 
26
29
  export declare const Button: ({ children, onClick, variant, size, icon, disabled, className, type, asChild, ...rest }: ButtonProps) => JSX.Element;
27
30
 
31
+ declare function Button_2({ className, variant, size, asChild, ...props }: React_2.ComponentProps<"button"> & VariantProps<typeof buttonVariants> & {
32
+ asChild?: boolean;
33
+ }): JSX.Element;
34
+
28
35
  export declare const ButtonGroup: {
29
36
  ({ children, className }: ButtonGroupProps): JSX.Element;
30
37
  Button({ children, className, ...props }: ButtonProps): JSX.Element;
@@ -47,6 +54,11 @@ export declare interface ButtonProps extends default_2.ComponentProps<"button">
47
54
  asChild?: boolean;
48
55
  }
49
56
 
57
+ declare const buttonVariants: (props?: ({
58
+ variant?: "link" | "secondary" | "destructive" | "default" | "outline" | "ghost" | null | undefined;
59
+ size?: "default" | "sm" | "lg" | "icon" | null | undefined;
60
+ } & ClassProp) | undefined) => string;
61
+
50
62
  export declare const Checkbox: ({ label, name, value, checked, onCheckedChange }: CheckboxProps) => JSX.Element;
51
63
 
52
64
  export declare interface CheckboxProps {
@@ -234,6 +246,10 @@ declare const LAYOUT_VARIANTS: readonly ["default", "primary", "secondary", "mut
234
246
 
235
247
  declare type LayoutVariant = (typeof LAYOUT_VARIANTS)[number];
236
248
 
249
+ export declare const MenuItemText: ({ children }: {
250
+ children: React.ReactNode;
251
+ }) => JSX.Element;
252
+
237
253
  /**
238
254
  + * A specialized input component for numeric values.
239
255
  + * Extends TextInput with number-specific functionality.
@@ -274,6 +290,10 @@ declare interface Props_2 extends ButtonProps {
274
290
  submittingIcon?: React.ComponentType<React.SVGProps<SVGSVGElement>>;
275
291
  }
276
292
 
293
+ declare interface Props_3 extends SidebarProps {
294
+ children?: React.ReactNode;
295
+ }
296
+
277
297
  export declare const RadioSelect: ({ label, name, options, value, onChange }: RadioSelectProps) => JSX.Element;
278
298
 
279
299
  declare interface RadioSelectProps {
@@ -327,6 +347,38 @@ declare interface SeparatorProps extends React.HTMLAttributes<HTMLDivElement> {
327
347
  gap?: Gap;
328
348
  }
329
349
 
350
+ export declare const Sidebar: ({ brandContent, brandOnClick, activeSlug, itemSets, bottomItemSets, ...props }: SidebarProps) => JSX.Element;
351
+
352
+ declare function Sidebar_2({ side, variant, collapsible, className, children, ...props }: React_2.ComponentProps<"div"> & {
353
+ side?: "left" | "right";
354
+ variant?: "sidebar" | "floating" | "inset";
355
+ collapsible?: "offcanvas" | "icon" | "none";
356
+ }): JSX.Element;
357
+
358
+ export declare const SidebarLayout: ({ children, ...props }: Props_3) => JSX.Element;
359
+
360
+ export declare interface SidebarProps extends React.ComponentProps<typeof Sidebar_2> {
361
+ brandContent: React.ReactNode;
362
+ brandOnClick?: () => void;
363
+ activeSlug?: string;
364
+ itemSets: SideLinkSet[];
365
+ bottomItemSets: SideLinkSet[];
366
+ }
367
+
368
+ export declare function SidebarTrigger({ className, onClick, children, ...props }: React_2.ComponentProps<typeof Button_2>): JSX.Element;
369
+
370
+ declare interface SideLink {
371
+ slug: string;
372
+ title: string;
373
+ icon: React.ElementType;
374
+ onClick?: () => void;
375
+ external?: boolean;
376
+ }
377
+
378
+ declare interface SideLinkSet {
379
+ links: SideLink[];
380
+ }
381
+
330
382
  declare type Size = (typeof SIZES)[number];
331
383
 
332
384
  declare const SIZES: readonly [...string[], "auto", "full", "min", "max", "fit", "px"];