@still-forest/canopy 0.21.0 → 0.22.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 +86 -27
- package/dist/index.js +16124 -13841
- package/dist/index.js.map +1 -1
- package/package.json +25 -40
package/dist/index.d.ts
CHANGED
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { Accordion as Accordion_2 } from 'radix-ui';
|
|
2
2
|
import { ClassProp } from 'class-variance-authority/types';
|
|
3
3
|
import { ComponentProps } from 'react';
|
|
4
4
|
import { default as default_2 } from 'react';
|
|
5
5
|
import { JSX } from 'react/jsx-runtime';
|
|
6
|
+
import { Popover as Popover_3 } from 'radix-ui';
|
|
6
7
|
import * as React_2 from 'react';
|
|
7
|
-
import
|
|
8
|
+
import { Tabs as Tabs_2 } from 'radix-ui';
|
|
8
9
|
import { VariantProps } from 'class-variance-authority';
|
|
9
10
|
|
|
10
|
-
export declare function Accordion({ ...props }: React_2.ComponentProps<typeof
|
|
11
|
+
export declare function Accordion({ ...props }: React_2.ComponentProps<typeof Accordion_2.Root>): JSX.Element;
|
|
11
12
|
|
|
12
|
-
export declare function AccordionContent({ className, children, ...props }: React_2.ComponentProps<typeof
|
|
13
|
+
export declare function AccordionContent({ className, children, ...props }: React_2.ComponentProps<typeof Accordion_2.Content>): JSX.Element;
|
|
13
14
|
|
|
14
|
-
export declare function AccordionItem({ className, ...props }: React_2.ComponentProps<typeof
|
|
15
|
+
export declare function AccordionItem({ className, ...props }: React_2.ComponentProps<typeof Accordion_2.Item>): JSX.Element;
|
|
15
16
|
|
|
16
|
-
export declare function AccordionTrigger({ className, children, ...props }: React_2.ComponentProps<typeof
|
|
17
|
+
export declare function AccordionTrigger({ className, children, ...props }: React_2.ComponentProps<typeof Accordion_2.Trigger>): JSX.Element;
|
|
17
18
|
|
|
18
19
|
export declare const Alert: ({ type, title, message, className }: AlertProps) => JSX.Element;
|
|
19
20
|
|
|
20
|
-
declare interface AlertProps {
|
|
21
|
+
export declare interface AlertProps {
|
|
21
22
|
type: "info" | "success" | "warning" | "error";
|
|
22
23
|
title?: string;
|
|
23
24
|
message: string;
|
|
@@ -34,6 +35,16 @@ declare interface BadgeProps {
|
|
|
34
35
|
className?: string;
|
|
35
36
|
}
|
|
36
37
|
|
|
38
|
+
export declare type BaseButtonSize = "default" | "sm" | "lg" | "icon";
|
|
39
|
+
|
|
40
|
+
export declare type BaseButtonVariant = "default" | "secondary" | "destructive" | "outline" | "ghost" | "link";
|
|
41
|
+
|
|
42
|
+
declare const Body_2: ({ children, className, withContainer, ...props }: BodyProps) => JSX.Element;
|
|
43
|
+
|
|
44
|
+
declare interface BodyProps extends FlexProps {
|
|
45
|
+
withContainer?: boolean;
|
|
46
|
+
}
|
|
47
|
+
|
|
37
48
|
export declare const Box: default_2.ForwardRefExoticComponent<BoxProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
38
49
|
|
|
39
50
|
declare const BOX_SIZINGS: readonly ["content", "border"];
|
|
@@ -127,8 +138,9 @@ export declare const Code: ({ children, ...props }: TextProps) => JSX.Element;
|
|
|
127
138
|
|
|
128
139
|
export declare const Container: ({ children, className, ...props }: ContainerProps) => JSX.Element;
|
|
129
140
|
|
|
130
|
-
export declare interface ContainerProps extends
|
|
141
|
+
export declare interface ContainerProps extends FlexProps {
|
|
131
142
|
children: React.ReactNode;
|
|
143
|
+
display?: Display_2;
|
|
132
144
|
className?: string;
|
|
133
145
|
}
|
|
134
146
|
|
|
@@ -139,19 +151,22 @@ export declare const DateInput: ({ name, label, placeholder, note, className, ..
|
|
|
139
151
|
declare interface DateInputProps extends Omit<TextInputProps, "type"> {
|
|
140
152
|
}
|
|
141
153
|
|
|
142
|
-
export declare const DatePicker: ({ onDateSelection, initialValue, className, size }: DatePickerProps) => JSX.Element;
|
|
154
|
+
export declare const DatePicker: ({ onDateSelection, initialValue, className, size, error }: DatePickerProps) => JSX.Element;
|
|
143
155
|
|
|
144
156
|
declare interface DatePickerProps {
|
|
145
157
|
onDateSelection: (date: Date) => void;
|
|
146
158
|
initialValue?: Date;
|
|
147
159
|
className?: string;
|
|
148
160
|
size?: "default" | "xs" | "sm" | "lg";
|
|
161
|
+
error?: string;
|
|
149
162
|
}
|
|
150
163
|
|
|
151
164
|
export declare const DeleteButton: ({ disabled, handleDelete, ...rest }: Props_4) => JSX.Element;
|
|
152
165
|
|
|
153
166
|
declare type Display = (typeof DISPLAYS)[number];
|
|
154
167
|
|
|
168
|
+
declare type Display_2 = "block" | "flex";
|
|
169
|
+
|
|
155
170
|
declare const DISPLAYS: readonly ["block", "flex", "grid", "inline", "inline-block", "inline-flex", "inline-grid", "inline-table", "list-item", "flow-root", "contents", "table", "table-header-group", "table-footer-group", "table-column-group", "table-column", "table-row-group", "table-row", "table-cell", "table-caption", "hidden", "sr-only", "not-sr-only"];
|
|
156
171
|
|
|
157
172
|
export declare const ErrorFallback: ({ error, onRetry }: ErrorFallbackProps) => JSX.Element;
|
|
@@ -261,6 +276,13 @@ export declare interface GridProps extends default_2.HTMLAttributes<HTMLDivEleme
|
|
|
261
276
|
|
|
262
277
|
declare type GridRows = (typeof GRID_ROWS)[number];
|
|
263
278
|
|
|
279
|
+
export declare const Header: ({ children, sticky, className, ...props }: HeaderProps) => JSX.Element;
|
|
280
|
+
|
|
281
|
+
declare interface HeaderProps extends ContainerProps {
|
|
282
|
+
children: React.ReactNode;
|
|
283
|
+
sticky?: boolean;
|
|
284
|
+
}
|
|
285
|
+
|
|
264
286
|
export declare const Heading: default_2.ForwardRefExoticComponent<HeadingProps & default_2.RefAttributes<HTMLHeadingElement>>;
|
|
265
287
|
|
|
266
288
|
declare const HEADING_LEVELS: readonly ["1", "2", "3", "4", "5", "6"];
|
|
@@ -289,6 +311,10 @@ declare type Height = (typeof HEIGHTS)[number];
|
|
|
289
311
|
|
|
290
312
|
declare const HEIGHTS: readonly [...string[], "auto", "full", "min", "max", "fit", "px", "screen"];
|
|
291
313
|
|
|
314
|
+
export declare const InputError: ({ message }: {
|
|
315
|
+
message: string;
|
|
316
|
+
}) => JSX.Element;
|
|
317
|
+
|
|
292
318
|
export declare const InputGroup: ({ label, labelFor, className, labelClassName, children }: InputGroupProps) => JSX.Element;
|
|
293
319
|
|
|
294
320
|
declare interface InputGroupProps {
|
|
@@ -317,8 +343,20 @@ export declare interface LabelProps extends ComponentProps<"label"> {
|
|
|
317
343
|
className?: string;
|
|
318
344
|
}
|
|
319
345
|
|
|
346
|
+
export declare const Layout: typeof LayoutComponent & {
|
|
347
|
+
Header: typeof Header;
|
|
348
|
+
Body: typeof Body_2;
|
|
349
|
+
Footer: typeof Footer;
|
|
350
|
+
};
|
|
351
|
+
|
|
320
352
|
declare const LAYOUT_VARIANTS: readonly ["default", "primary", "secondary", "muted", "accent", "info", "success", "warning", "destructive"];
|
|
321
353
|
|
|
354
|
+
declare const LayoutComponent: default_2.ForwardRefExoticComponent<LayoutProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
355
|
+
|
|
356
|
+
declare interface LayoutProps extends FlexProps {
|
|
357
|
+
children: default_2.ReactNode;
|
|
358
|
+
}
|
|
359
|
+
|
|
322
360
|
declare type LayoutVariant = (typeof LAYOUT_VARIANTS)[number];
|
|
323
361
|
|
|
324
362
|
export declare const MenuItemText: ({ children }: {
|
|
@@ -368,6 +406,21 @@ declare interface PageNotFoundProps {
|
|
|
368
406
|
|
|
369
407
|
export declare const Pagination: ({ pageCount, currentPage, onChange }: Props_3) => JSX.Element;
|
|
370
408
|
|
|
409
|
+
export declare const Paragraph: ({ children, className, ...props }: TextProps) => JSX.Element;
|
|
410
|
+
|
|
411
|
+
export declare const Popover: PopoverComponent;
|
|
412
|
+
|
|
413
|
+
declare function Popover_2({ ...props }: React_2.ComponentProps<typeof Popover_3.Root>): JSX.Element;
|
|
414
|
+
|
|
415
|
+
declare type PopoverComponent = default_2.FC<default_2.ComponentProps<typeof Popover_2>> & {
|
|
416
|
+
Trigger: typeof PopoverTrigger;
|
|
417
|
+
Content: typeof PopoverContent;
|
|
418
|
+
};
|
|
419
|
+
|
|
420
|
+
declare function PopoverContent({ className, align, sideOffset, ...props }: React_2.ComponentProps<typeof Popover_3.Content>): JSX.Element;
|
|
421
|
+
|
|
422
|
+
declare function PopoverTrigger({ ...props }: React_2.ComponentProps<typeof Popover_3.Trigger>): JSX.Element;
|
|
423
|
+
|
|
371
424
|
declare type Position = (typeof POSITIONS)[number];
|
|
372
425
|
|
|
373
426
|
declare const POSITIONS: readonly ["static", "fixed", "absolute", "relative", "sticky"];
|
|
@@ -404,17 +457,11 @@ declare interface Props_4 extends ButtonProps {
|
|
|
404
457
|
handleDelete: () => void;
|
|
405
458
|
}
|
|
406
459
|
|
|
407
|
-
declare interface Props_5 extends
|
|
408
|
-
submitting?: boolean;
|
|
409
|
-
disabled?: boolean;
|
|
410
|
-
submittingIcon?: React.ComponentType<React.SVGProps<SVGSVGElement>>;
|
|
411
|
-
}
|
|
412
|
-
|
|
413
|
-
declare interface Props_6 extends SidebarProps {
|
|
460
|
+
declare interface Props_5 extends SidebarProps {
|
|
414
461
|
children?: React.ReactNode;
|
|
415
462
|
}
|
|
416
463
|
|
|
417
|
-
export declare const RadioSelect: ({ label, name, options, value, onChange }: RadioSelectProps) => JSX.Element;
|
|
464
|
+
export declare const RadioSelect: ({ label, name, options, value, onChange, error }: RadioSelectProps) => JSX.Element;
|
|
418
465
|
|
|
419
466
|
declare interface RadioSelectProps {
|
|
420
467
|
name: string;
|
|
@@ -422,15 +469,14 @@ declare interface RadioSelectProps {
|
|
|
422
469
|
value?: string;
|
|
423
470
|
options: Option_3[];
|
|
424
471
|
onChange?: (value: string) => void;
|
|
472
|
+
error?: string;
|
|
425
473
|
}
|
|
426
474
|
|
|
427
475
|
declare const ROUNDED_SIZES: readonly ["none", "xs", "sm", "md", "lg", "xl", "2xl", "3xl", "full", true, false];
|
|
428
476
|
|
|
429
477
|
declare type RoundedSize = (typeof ROUNDED_SIZES)[number];
|
|
430
478
|
|
|
431
|
-
export declare const
|
|
432
|
-
|
|
433
|
-
export declare const SelectInput: ({ name, defaultValue, options, label, placeholder, note, className, value, onValueChange, ...props }: SelectInputProps) => JSX.Element;
|
|
479
|
+
export declare const SelectInput: ({ name, defaultValue, options, label, placeholder, note, className, value, onValueChange, error, ...props }: SelectInputProps) => JSX.Element;
|
|
434
480
|
|
|
435
481
|
export declare interface SelectInputProps extends Omit<React.ComponentProps<"select">, "dir"> {
|
|
436
482
|
name: string;
|
|
@@ -441,6 +487,7 @@ export declare interface SelectInputProps extends Omit<React.ComponentProps<"sel
|
|
|
441
487
|
placeholder?: string;
|
|
442
488
|
note?: string;
|
|
443
489
|
className?: string;
|
|
490
|
+
error?: string;
|
|
444
491
|
}
|
|
445
492
|
|
|
446
493
|
export declare const SelectPicker: ({ options, value, placeholder, className, onSelect, renderSelected, }: SelectPickerProps) => JSX.Element;
|
|
@@ -475,7 +522,7 @@ declare function Sidebar_2({ side, variant, collapsible, className, children, ..
|
|
|
475
522
|
collapsible?: "offcanvas" | "icon" | "none";
|
|
476
523
|
}): JSX.Element;
|
|
477
524
|
|
|
478
|
-
export declare const SidebarLayout: ({ children, ...props }:
|
|
525
|
+
export declare const SidebarLayout: ({ children, ...props }: Props_5) => JSX.Element;
|
|
479
526
|
|
|
480
527
|
export declare interface SidebarProps extends React.ComponentProps<typeof Sidebar_2> {
|
|
481
528
|
brandContent: React.ReactNode;
|
|
@@ -507,6 +554,16 @@ declare const SIZES: readonly [...string[], "auto", "full", "min", "max", "fit",
|
|
|
507
554
|
|
|
508
555
|
export declare function Skeleton({ className, ...props }: React.ComponentProps<"div">): JSX.Element;
|
|
509
556
|
|
|
557
|
+
export declare const SubmitButton: ({ submitting, disabled, submittingIcon, action, noIcon, ...rest }: SubmitButtonProps) => JSX.Element;
|
|
558
|
+
|
|
559
|
+
export declare interface SubmitButtonProps extends ButtonProps {
|
|
560
|
+
action?: "default" | "submit" | "save" | "send";
|
|
561
|
+
submitting?: boolean;
|
|
562
|
+
disabled?: boolean;
|
|
563
|
+
submittingIcon?: React.ComponentType<React.SVGProps<SVGSVGElement>>;
|
|
564
|
+
noIcon?: boolean;
|
|
565
|
+
}
|
|
566
|
+
|
|
510
567
|
export declare const Table: TableComponent;
|
|
511
568
|
|
|
512
569
|
export declare function TableBody({ className, ...props }: React_2.ComponentProps<"tbody">): JSX.Element;
|
|
@@ -530,13 +587,13 @@ export declare function TableHeader({ className, ...props }: React_2.ComponentPr
|
|
|
530
587
|
|
|
531
588
|
export declare function TableRow({ className, ...props }: React_2.ComponentProps<"tr">): JSX.Element;
|
|
532
589
|
|
|
533
|
-
export declare function Tabs({ className, ...props }: React_2.ComponentProps<typeof
|
|
590
|
+
export declare function Tabs({ className, ...props }: React_2.ComponentProps<typeof Tabs_2.Root>): JSX.Element;
|
|
534
591
|
|
|
535
|
-
export declare function TabsContent({ className, ...props }: React_2.ComponentProps<typeof
|
|
592
|
+
export declare function TabsContent({ className, ...props }: React_2.ComponentProps<typeof Tabs_2.Content>): JSX.Element;
|
|
536
593
|
|
|
537
|
-
export declare function TabsList({ className, ...props }: React_2.ComponentProps<typeof
|
|
594
|
+
export declare function TabsList({ className, ...props }: React_2.ComponentProps<typeof Tabs_2.List>): JSX.Element;
|
|
538
595
|
|
|
539
|
-
export declare function TabsTrigger({ className, ...props }: React_2.ComponentProps<typeof
|
|
596
|
+
export declare function TabsTrigger({ className, ...props }: React_2.ComponentProps<typeof Tabs_2.Trigger>): JSX.Element;
|
|
540
597
|
|
|
541
598
|
declare const TAILWIND_COLORS: readonly ["red", "orange", "amber", "yellow", "lime", "green", "emerald", "teal", "cyan", "sky", "blue", "indigo", "violet", "purple", "fuchsia", "pink", "rose", "slate", "gray", "zinc", "neutral", "stone", "white", "black"];
|
|
542
599
|
|
|
@@ -553,7 +610,7 @@ declare const TEXT_TRACKINGS: readonly ["tighter", "tight", "normal", "wide", "w
|
|
|
553
610
|
|
|
554
611
|
declare type TextAlign = (typeof TEXT_ALIGNS)[number];
|
|
555
612
|
|
|
556
|
-
export declare function Textarea({ label, name, note, placeholder, className, ...props }: TextareaProps): JSX.Element;
|
|
613
|
+
export declare function Textarea({ label, name, note, placeholder, className, error, ...props }: TextareaProps): JSX.Element;
|
|
557
614
|
|
|
558
615
|
export declare interface TextareaProps extends React.ComponentProps<"textarea"> {
|
|
559
616
|
name: string;
|
|
@@ -561,6 +618,7 @@ export declare interface TextareaProps extends React.ComponentProps<"textarea">
|
|
|
561
618
|
placeholder?: string;
|
|
562
619
|
note?: string;
|
|
563
620
|
className?: string;
|
|
621
|
+
error?: string;
|
|
564
622
|
}
|
|
565
623
|
|
|
566
624
|
declare interface TextBaseProps {
|
|
@@ -581,7 +639,7 @@ declare interface TextBaseProps {
|
|
|
581
639
|
as?: TypographyElement;
|
|
582
640
|
}
|
|
583
641
|
|
|
584
|
-
export declare const TextInput: ({ name, type, placeholder, label, labelOrientation, note, className, ...props }: TextInputProps) => JSX.Element;
|
|
642
|
+
export declare const TextInput: ({ name, type, placeholder, label, labelOrientation, note, className, error, ...props }: TextInputProps) => JSX.Element;
|
|
585
643
|
|
|
586
644
|
export declare interface TextInputProps extends React.ComponentProps<"input"> {
|
|
587
645
|
name: string;
|
|
@@ -591,6 +649,7 @@ export declare interface TextInputProps extends React.ComponentProps<"input"> {
|
|
|
591
649
|
labelOrientation?: "top" | "left";
|
|
592
650
|
note?: string;
|
|
593
651
|
className?: string;
|
|
652
|
+
error?: string;
|
|
594
653
|
}
|
|
595
654
|
|
|
596
655
|
declare type TextLeading = (typeof TEXT_LEADINGS)[number];
|