buildgrid-ui 1.1.0-dev.9 → 1.2.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.
Files changed (125) hide show
  1. package/dist/blocks/help-carousel/help-carousel.d.ts +9 -0
  2. package/dist/blocks/help-carousel/index.d.ts +1 -0
  3. package/dist/blocks/index.d.ts +4 -0
  4. package/dist/blocks/month-navigator/index.d.ts +1 -0
  5. package/dist/blocks/month-navigator/month-navigator.d.ts +9 -0
  6. package/dist/blocks/pagination-controls/index.d.ts +1 -0
  7. package/dist/blocks/pagination-controls/pagination-controls.d.ts +7 -0
  8. package/dist/blocks/sidebar/index.d.ts +1 -0
  9. package/dist/blocks/sidebar/sidebar.d.ts +26 -0
  10. package/dist/buildgrid-ui.es.js +8678 -3036
  11. package/dist/buildgrid-ui.umd.js +104 -43
  12. package/dist/components/autocomplete/autocomplete.d.ts +1 -0
  13. package/dist/components/calendar/calendar.d.ts +8 -0
  14. package/dist/components/calendar/index.d.ts +1 -0
  15. package/dist/components/dialog/dialog.d.ts +19 -0
  16. package/dist/components/dialog/index.d.ts +1 -0
  17. package/dist/components/index.d.ts +14 -0
  18. package/dist/components/label/index.d.ts +1 -0
  19. package/dist/components/label/label.d.ts +5 -0
  20. package/dist/components/navigation-menu/index.d.ts +1 -0
  21. package/dist/components/navigation-menu/navigation-menu.d.ts +12 -0
  22. package/dist/components/pagination/index.d.ts +1 -0
  23. package/dist/components/pagination/pagination.d.ts +28 -0
  24. package/dist/components/radio-group/index.d.ts +1 -0
  25. package/dist/components/radio-group/radio-group.d.ts +5 -0
  26. package/dist/components/select/index.d.ts +1 -0
  27. package/dist/components/select/select.d.ts +13 -0
  28. package/dist/components/table/index.d.ts +1 -0
  29. package/dist/components/table/table.d.ts +10 -0
  30. package/dist/components/tabs/index.d.ts +1 -0
  31. package/dist/components/tabs/tabs.d.ts +7 -0
  32. package/dist/components/textarea/index.d.ts +1 -0
  33. package/dist/components/textarea/textarea.d.ts +3 -0
  34. package/dist/components/toaster/index.d.ts +2 -0
  35. package/dist/components/toaster/toaster.d.ts +9 -0
  36. package/dist/components/toggle/index.d.ts +1 -0
  37. package/dist/components/toggle/toggle.d.ts +12 -0
  38. package/dist/components/toggle-group/index.d.ts +1 -0
  39. package/dist/components/toggle-group/toggle-group.d.ts +12 -0
  40. package/dist/components/tooltip/index.d.ts +1 -0
  41. package/dist/components/tooltip/tooltip.d.ts +7 -0
  42. package/dist/index.d.ts +3 -1
  43. package/dist/lib/hooks/index.d.ts +5 -0
  44. package/dist/lib/hooks/use-debounce.d.ts +2 -0
  45. package/dist/lib/hooks/use-dialog.d.ts +30 -0
  46. package/dist/lib/hooks/use-media-query.d.ts +1 -0
  47. package/dist/lib/hooks/use-mobile.d.ts +1 -0
  48. package/dist/lib/hooks/use-pwa-install.d.ts +7 -0
  49. package/dist/lib/utils/date-formatters.d.ts +13 -0
  50. package/dist/lib/utils/formatters.d.ts +1 -7
  51. package/dist/lib/utils/index.d.ts +3 -0
  52. package/package.json +19 -2
  53. package/.editorconfig +0 -5
  54. package/.eslintrc.json +0 -3
  55. package/.github/workflows/release.yml +0 -25
  56. package/.husky/commit-msg +0 -1
  57. package/.prettierignore +0 -6
  58. package/.prettierrc +0 -6
  59. package/.releaserc.json +0 -40
  60. package/.storybook/main.ts +0 -26
  61. package/.storybook/preview.ts +0 -15
  62. package/CHANGELOG.md +0 -53
  63. package/commitlint.config.js +0 -3
  64. package/components.json +0 -21
  65. package/dist/lib/index.d.ts +0 -2
  66. package/eslint.config.mjs +0 -13
  67. package/postcss.config.js +0 -6
  68. package/src/components/adaptive-input/adaptive-input.stories.tsx +0 -31
  69. package/src/components/adaptive-input/adaptive-input.tsx +0 -66
  70. package/src/components/adaptive-input/index.ts +0 -1
  71. package/src/components/alert-dialog/alert-dialog.stories.tsx +0 -49
  72. package/src/components/alert-dialog/alert-dialog.tsx +0 -130
  73. package/src/components/alert-dialog/index.ts +0 -1
  74. package/src/components/autocomplete/autocomplete.stories.tsx +0 -84
  75. package/src/components/autocomplete/autocomplete.tsx +0 -136
  76. package/src/components/autocomplete/index.ts +0 -1
  77. package/src/components/avatar/avatar.stories.tsx +0 -29
  78. package/src/components/avatar/avatar.tsx +0 -48
  79. package/src/components/avatar/index.ts +0 -1
  80. package/src/components/badge/badge.stories.tsx +0 -30
  81. package/src/components/badge/badge.tsx +0 -34
  82. package/src/components/badge/index.ts +0 -1
  83. package/src/components/button/button.stories.tsx +0 -62
  84. package/src/components/button/button.tsx +0 -82
  85. package/src/components/button/index.ts +0 -1
  86. package/src/components/card/card.stories.tsx +0 -41
  87. package/src/components/card/card.tsx +0 -61
  88. package/src/components/card/index.ts +0 -1
  89. package/src/components/checkbox/checkbox.stories.tsx +0 -36
  90. package/src/components/checkbox/checkbox.tsx +0 -28
  91. package/src/components/checkbox/index.ts +0 -1
  92. package/src/components/currency-input/currency-input.stories.tsx +0 -28
  93. package/src/components/currency-input/currency-input.tsx +0 -93
  94. package/src/components/currency-input/index.ts +0 -1
  95. package/src/components/dropdown-menu/dropdown-menu.stories.tsx +0 -90
  96. package/src/components/dropdown-menu/dropdown-menu.tsx +0 -192
  97. package/src/components/dropdown-menu/index.ts +0 -1
  98. package/src/components/index.ts +0 -16
  99. package/src/components/input/index.ts +0 -1
  100. package/src/components/input/input.stories.tsx +0 -22
  101. package/src/components/input/input.tsx +0 -41
  102. package/src/components/password-input/index.ts +0 -1
  103. package/src/components/password-input/password-input.stories.tsx +0 -26
  104. package/src/components/password-input/password-input.tsx +0 -98
  105. package/src/components/popover/index.ts +0 -1
  106. package/src/components/popover/popover.stories.tsx +0 -32
  107. package/src/components/popover/popover.tsx +0 -30
  108. package/src/components/progress/index.ts +0 -1
  109. package/src/components/progress/progress.stories.tsx +0 -21
  110. package/src/components/progress/progress.tsx +0 -26
  111. package/src/components/skeleton/index.ts +0 -1
  112. package/src/components/skeleton/skeleton.stories.tsx +0 -24
  113. package/src/components/skeleton/skeleton.tsx +0 -19
  114. package/src/components/switch/index.ts +0 -1
  115. package/src/components/switch/switch.stories.tsx +0 -21
  116. package/src/components/switch/switch.tsx +0 -26
  117. package/src/index.ts +0 -2
  118. package/src/lib/index.ts +0 -2
  119. package/src/lib/utils/cn.ts +0 -6
  120. package/src/lib/utils/formatters.ts +0 -55
  121. package/src/styles/tailwind.css +0 -66
  122. package/tailwind.config.js +0 -57
  123. package/tsconfig.app.json +0 -10
  124. package/tsconfig.json +0 -29
  125. package/vite.config.ts +0 -34
@@ -9,6 +9,7 @@ interface AutoCompleteProps {
9
9
  className?: string;
10
10
  placeholder?: string;
11
11
  emptyMessage?: string;
12
+ defaultOption?: Option;
12
13
  }
13
14
  export declare function Autocomplete(props: AutoCompleteProps): import("react/jsx-runtime").JSX.Element;
14
15
  export {};
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ type CalendarProps = {
3
+ selectedDate?: Date;
4
+ onChange?: (date: Date) => void;
5
+ language?: 'enUS' | 'ptBR';
6
+ };
7
+ export declare const Calendar: React.FC<CalendarProps>;
8
+ export {};
@@ -0,0 +1 @@
1
+ export * from './calendar';
@@ -0,0 +1,19 @@
1
+ import * as DialogPrimitive from '@radix-ui/react-dialog';
2
+ import * as React from 'react';
3
+ declare const Dialog: React.FC<DialogPrimitive.DialogProps>;
4
+ declare const DialogTrigger: React.ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
5
+ declare const DialogPortal: React.FC<DialogPrimitive.DialogPortalProps>;
6
+ declare const DialogClose: React.ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
7
+ declare const DialogOverlay: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
8
+ declare const DialogContent: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const DialogHeader: {
10
+ ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
11
+ displayName: string;
12
+ };
13
+ declare const DialogFooter: {
14
+ ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
15
+ displayName: string;
16
+ };
17
+ declare const DialogTitle: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
18
+ declare const DialogDescription: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
19
+ export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, };
@@ -0,0 +1 @@
1
+ export * from './dialog';
@@ -4,13 +4,27 @@ export * from './autocomplete';
4
4
  export * from './avatar';
5
5
  export * from './badge';
6
6
  export * from './button';
7
+ export * from './calendar';
7
8
  export * from './card';
8
9
  export * from './checkbox';
9
10
  export * from './currency-input';
11
+ export * from './dialog';
10
12
  export * from './dropdown-menu';
11
13
  export * from './input';
14
+ export * from './label';
15
+ export * from './navigation-menu';
16
+ export * from './pagination';
12
17
  export * from './password-input';
13
18
  export * from './popover';
14
19
  export * from './progress';
20
+ export * from './radio-group';
21
+ export * from './select';
15
22
  export * from './skeleton';
16
23
  export * from './switch';
24
+ export * from './table';
25
+ export * from './tabs';
26
+ export * from './textarea';
27
+ export * from './toaster';
28
+ export * from './toggle';
29
+ export * from './toggle-group';
30
+ export * from './tooltip';
@@ -0,0 +1 @@
1
+ export * from './label';
@@ -0,0 +1,5 @@
1
+ import * as LabelPrimitive from '@radix-ui/react-label';
2
+ import { type VariantProps } from 'class-variance-authority';
3
+ import * as React from 'react';
4
+ declare const Label: React.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React.RefAttributes<HTMLLabelElement>, "ref"> & VariantProps<(props?: import("class-variance-authority/dist/types").ClassProp | undefined) => string> & React.RefAttributes<HTMLLabelElement>>;
5
+ export { Label };
@@ -0,0 +1 @@
1
+ export * from './navigation-menu';
@@ -0,0 +1,12 @@
1
+ import * as React from "react";
2
+ import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
3
+ declare const NavigationMenu: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuProps & React.RefAttributes<HTMLElement>, "ref"> & React.RefAttributes<HTMLElement>>;
4
+ declare const NavigationMenuList: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuListProps & React.RefAttributes<HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
5
+ declare const NavigationMenuItem: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuItemProps & React.RefAttributes<HTMLLIElement>>;
6
+ declare const navigationMenuTriggerStyle: (props?: import("class-variance-authority/dist/types").ClassProp | undefined) => string;
7
+ declare const NavigationMenuTrigger: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
8
+ declare const NavigationMenuContent: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const NavigationMenuLink: React.ForwardRefExoticComponent<NavigationMenuPrimitive.NavigationMenuLinkProps & React.RefAttributes<HTMLAnchorElement>>;
10
+ declare const NavigationMenuViewport: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuViewportProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const NavigationMenuIndicator: React.ForwardRefExoticComponent<Omit<NavigationMenuPrimitive.NavigationMenuIndicatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ export { navigationMenuTriggerStyle, NavigationMenu, NavigationMenuList, NavigationMenuItem, NavigationMenuContent, NavigationMenuTrigger, NavigationMenuLink, NavigationMenuIndicator, NavigationMenuViewport, };
@@ -0,0 +1 @@
1
+ export * from './pagination';
@@ -0,0 +1,28 @@
1
+ import * as React from 'react';
2
+ import { ButtonProps } from '../button';
3
+ declare const Pagination: {
4
+ ({ className, ...props }: React.ComponentProps<"nav">): import("react/jsx-runtime").JSX.Element;
5
+ displayName: string;
6
+ };
7
+ declare const PaginationContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
8
+ declare const PaginationItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
9
+ type PaginationLinkProps = {
10
+ isActive?: boolean;
11
+ } & ButtonProps;
12
+ declare const PaginationLink: {
13
+ ({ className, isActive, size, ...props }: PaginationLinkProps): import("react/jsx-runtime").JSX.Element;
14
+ displayName: string;
15
+ };
16
+ declare const PaginationPrevious: {
17
+ ({ className, ...props }: React.ComponentProps<typeof PaginationLink>): import("react/jsx-runtime").JSX.Element;
18
+ displayName: string;
19
+ };
20
+ declare const PaginationNext: {
21
+ ({ className, ...props }: React.ComponentProps<typeof PaginationLink>): import("react/jsx-runtime").JSX.Element;
22
+ displayName: string;
23
+ };
24
+ declare const PaginationEllipsis: {
25
+ ({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
26
+ displayName: string;
27
+ };
28
+ export { Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, };
@@ -0,0 +1 @@
1
+ export * from './radio-group';
@@ -0,0 +1,5 @@
1
+ import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
2
+ import * as React from 'react';
3
+ declare const RadioGroup: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
+ declare const RadioGroupItem: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
5
+ export { RadioGroup, RadioGroupItem };
@@ -0,0 +1 @@
1
+ export * from './select';
@@ -0,0 +1,13 @@
1
+ import * as SelectPrimitive from '@radix-ui/react-select';
2
+ import * as React from 'react';
3
+ declare const Select: React.FC<SelectPrimitive.SelectProps>;
4
+ declare const SelectGroup: React.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React.RefAttributes<HTMLDivElement>>;
5
+ declare const SelectValue: React.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React.RefAttributes<HTMLSpanElement>>;
6
+ declare const SelectTrigger: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
7
+ declare const SelectScrollUpButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
8
+ declare const SelectScrollDownButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const SelectContent: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
10
+ declare const SelectLabel: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const SelectItem: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ declare const SelectSeparator: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
13
+ export { Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, };
@@ -0,0 +1 @@
1
+ export * from './table';
@@ -0,0 +1,10 @@
1
+ import * as React from 'react';
2
+ declare const Table: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableElement> & React.RefAttributes<HTMLTableElement>>;
3
+ declare const TableHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableSectionElement> & React.RefAttributes<HTMLTableSectionElement>>;
4
+ declare const TableBody: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableSectionElement> & React.RefAttributes<HTMLTableSectionElement>>;
5
+ declare const TableFooter: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableSectionElement> & React.RefAttributes<HTMLTableSectionElement>>;
6
+ declare const TableRow: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableRowElement> & React.RefAttributes<HTMLTableRowElement>>;
7
+ declare const TableHead: React.ForwardRefExoticComponent<React.ThHTMLAttributes<HTMLTableCellElement> & React.RefAttributes<HTMLTableCellElement>>;
8
+ declare const TableCell: React.ForwardRefExoticComponent<React.TdHTMLAttributes<HTMLTableCellElement> & React.RefAttributes<HTMLTableCellElement>>;
9
+ declare const TableCaption: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableCaptionElement> & React.RefAttributes<HTMLTableCaptionElement>>;
10
+ export { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, };
@@ -0,0 +1 @@
1
+ export * from './tabs';
@@ -0,0 +1,7 @@
1
+ import * as TabsPrimitive from '@radix-ui/react-tabs';
2
+ import * as React from 'react';
3
+ declare const Tabs: React.ForwardRefExoticComponent<TabsPrimitive.TabsProps & React.RefAttributes<HTMLDivElement>>;
4
+ declare const TabsList: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsListProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
5
+ declare const TabsTrigger: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
6
+ declare const TabsContent: React.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
7
+ export { Tabs, TabsContent, TabsList, TabsTrigger };
@@ -0,0 +1 @@
1
+ export * from './textarea';
@@ -0,0 +1,3 @@
1
+ import * as React from 'react';
2
+ declare const Textarea: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, "ref"> & React.RefAttributes<HTMLTextAreaElement>>;
3
+ export { Textarea };
@@ -0,0 +1,2 @@
1
+ export { toast } from 'sonner';
2
+ export * from './toaster';
@@ -0,0 +1,9 @@
1
+ import { Toaster as Sonner } from 'sonner';
2
+ type ToasterProps = React.ComponentProps<typeof Sonner>;
3
+ /**
4
+ * A toast notification component that uses `sonner` under the hood.
5
+ *
6
+ * It automatically uses the active theme and applies some sensible defaults.
7
+ */
8
+ declare const Toaster: ({ ...props }: ToasterProps) => import("react/jsx-runtime").JSX.Element;
9
+ export { Toaster };
@@ -0,0 +1 @@
1
+ export * from './toggle';
@@ -0,0 +1,12 @@
1
+ import * as TogglePrimitive from '@radix-ui/react-toggle';
2
+ import { type VariantProps } from 'class-variance-authority';
3
+ import * as React from 'react';
4
+ declare const toggleVariants: (props?: ({
5
+ variant?: "default" | "outline" | null | undefined;
6
+ size?: "default" | "sm" | "lg" | null | undefined;
7
+ } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
8
+ declare const Toggle: React.ForwardRefExoticComponent<Omit<TogglePrimitive.ToggleProps & React.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
9
+ variant?: "default" | "outline" | null | undefined;
10
+ size?: "default" | "sm" | "lg" | null | undefined;
11
+ } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string> & React.RefAttributes<HTMLButtonElement>>;
12
+ export { Toggle, toggleVariants };
@@ -0,0 +1 @@
1
+ export * from './toggle-group';
@@ -0,0 +1,12 @@
1
+ import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
2
+ import { type VariantProps } from 'class-variance-authority';
3
+ import * as React from 'react';
4
+ declare const ToggleGroup: React.ForwardRefExoticComponent<((Omit<ToggleGroupPrimitive.ToggleGroupSingleProps & React.RefAttributes<HTMLDivElement>, "ref"> | Omit<ToggleGroupPrimitive.ToggleGroupMultipleProps & React.RefAttributes<HTMLDivElement>, "ref">) & VariantProps<(props?: ({
5
+ variant?: "default" | "outline" | null | undefined;
6
+ size?: "default" | "sm" | "lg" | null | undefined;
7
+ } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string>) & React.RefAttributes<HTMLDivElement>>;
8
+ declare const ToggleGroupItem: React.ForwardRefExoticComponent<Omit<ToggleGroupPrimitive.ToggleGroupItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
9
+ variant?: "default" | "outline" | null | undefined;
10
+ size?: "default" | "sm" | "lg" | null | undefined;
11
+ } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string> & React.RefAttributes<HTMLButtonElement>>;
12
+ export { ToggleGroup, ToggleGroupItem };
@@ -0,0 +1 @@
1
+ export * from './tooltip';
@@ -0,0 +1,7 @@
1
+ import * as TooltipPrimitive from '@radix-ui/react-tooltip';
2
+ import * as React from 'react';
3
+ declare const TooltipProvider: React.FC<TooltipPrimitive.TooltipProviderProps>;
4
+ declare const Tooltip: React.FC<TooltipPrimitive.TooltipProps>;
5
+ declare const TooltipTrigger: React.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React.RefAttributes<HTMLButtonElement>>;
6
+ declare const TooltipContent: React.ForwardRefExoticComponent<Omit<TooltipPrimitive.TooltipContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
7
+ export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };
package/dist/index.d.ts CHANGED
@@ -1,2 +1,4 @@
1
+ export * from './blocks';
1
2
  export * from './components';
2
- export * from './lib';
3
+ export * from './lib/hooks';
4
+ export * from './lib/utils';
@@ -0,0 +1,5 @@
1
+ export * from './use-debounce';
2
+ export * from './use-dialog';
3
+ export * from './use-media-query';
4
+ export * from './use-mobile';
5
+ export * from './use-pwa-install';
@@ -0,0 +1,2 @@
1
+ /**https://usehooks.com/useDebounce/ */
2
+ export declare function useDebounce<T>(value: T, delay?: number): T;
@@ -0,0 +1,30 @@
1
+ import * as React from 'react';
2
+ type DialogType = 'info' | 'success' | 'error' | 'warning' | 'custom' | 'confirm';
3
+ type DialogSize = 'sm' | 'md' | 'lg' | 'xl';
4
+ interface DialogOptions {
5
+ title?: string;
6
+ message: string;
7
+ icon?: React.ElementType;
8
+ className?: string;
9
+ type?: DialogType;
10
+ confirmLabel?: string;
11
+ cancelLabel?: string;
12
+ displayCancel?: boolean;
13
+ onConfirm?: () => void;
14
+ size?: DialogSize;
15
+ }
16
+ interface DialogContextType {
17
+ open: (options: DialogOptions) => void;
18
+ close: () => void;
19
+ info: (options: Omit<DialogOptions, 'type'>) => void;
20
+ success: (options: Omit<DialogOptions, 'type'>) => void;
21
+ error: (options: Omit<DialogOptions, 'type'>) => void;
22
+ warning: (options: Omit<DialogOptions, 'type'>) => void;
23
+ custom: (options: DialogOptions) => void;
24
+ confirm: (options: Omit<DialogOptions, 'type'>) => void;
25
+ }
26
+ export declare function DialogProvider({ children }: {
27
+ children: React.ReactNode;
28
+ }): import("react/jsx-runtime").JSX.Element;
29
+ export declare function useDialog(): DialogContextType;
30
+ export {};
@@ -0,0 +1 @@
1
+ export declare function useMediaQuery(query: string): boolean;
@@ -0,0 +1 @@
1
+ export declare function useIsMobile(): boolean;
@@ -0,0 +1,7 @@
1
+ interface UsePWAInstallResult {
2
+ isPromptReady: boolean;
3
+ isInstalled: boolean;
4
+ showInstallPrompt: () => void;
5
+ }
6
+ export declare const usePWAInstall: () => UsePWAInstallResult;
7
+ export {};
@@ -0,0 +1,13 @@
1
+ export declare const formatDateUTC: (date: any) => string;
2
+ export declare const formatDateMonthYear: (date: Date) => string;
3
+ export declare const formatDateDayMonth: (date: Date) => string;
4
+ export declare const formatDateAndTime: (date: Date | string) => string;
5
+ export declare const getMonthName: (date: Date) => string;
6
+ export declare const getLongDate: (date: Date) => string;
7
+ export declare const formatDateAndWeekday: (date: Date | string, language?: string) => string;
8
+ export declare const formatDateAndWeekdayAndYear: (date: Date | string, language?: string) => string;
9
+ export declare const formatDateAndMonth: (date: Date | string, language?: string) => string;
10
+ export declare const formatLongDate: (date: Date | string, language?: string) => string;
11
+ export declare const formatShortDate: (date: Date, language?: string) => string;
12
+ export declare const getMonthYearFromISODate: (date: string) => string;
13
+ export declare const formatWeekDayAndShortDate: (date: Date, language?: string) => string;
@@ -1,8 +1,2 @@
1
1
  export declare const formatCurrency: (number: number, language?: string, currency?: string) => string;
2
- export declare const formatDateAndWeekday: (date: Date | string, language?: string) => string;
3
- export declare const formatDateAndWeekdayAndYear: (date: Date | string, language?: string) => string;
4
- export declare const formatDateAndMonth: (date: Date | string, language?: string) => string;
5
- export declare const formatLongDate: (date: Date | string, language?: string) => string;
6
- export declare const formatShortDate: (date: Date, language?: string) => string;
7
- export declare const getMonthYearFromISODate: (date: string) => string;
8
- export declare const formatWeekDayAndShortDate: (date: Date, language?: string) => string;
2
+ export declare const padString: (num: number | string, size?: number) => string;
@@ -0,0 +1,3 @@
1
+ export * from './cn';
2
+ export * from './date-formatters';
3
+ export * from './formatters';
package/package.json CHANGED
@@ -1,18 +1,22 @@
1
1
  {
2
2
  "name": "buildgrid-ui",
3
- "version": "1.1.0-dev.9",
3
+ "version": "1.2.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
7
  "main": "dist/buildgrid-ui.umd.js",
8
8
  "module": "dist/buildgrid-ui.esm.js",
9
9
  "types": "dist/index.d.ts",
10
+ "files": [
11
+ "dist"
12
+ ],
10
13
  "scripts": {
11
14
  "test": "echo \"Error: no test specified\" && exit 1",
12
15
  "build": "vite build && npm run build:types",
13
16
  "build:types": "tsc --emitDeclarationOnly",
14
17
  "build:link": "npm run build && npm link",
15
18
  "storybook": "storybook dev -p 6006",
19
+ "sb": "storybook dev -p 6006",
16
20
  "build-storybook": "storybook build",
17
21
  "release": "semantic-release",
18
22
  "prepublishOnly": "npm run build",
@@ -27,17 +31,29 @@
27
31
  "@radix-ui/react-avatar": "^1.1.2",
28
32
  "@radix-ui/react-checkbox": "^1.1.3",
29
33
  "@radix-ui/react-dropdown-menu": "^2.1.4",
34
+ "@radix-ui/react-label": "^2.1.1",
35
+ "@radix-ui/react-navigation-menu": "^1.2.3",
30
36
  "@radix-ui/react-popover": "^1.1.4",
31
37
  "@radix-ui/react-progress": "^1.1.1",
38
+ "@radix-ui/react-radio-group": "^1.2.2",
39
+ "@radix-ui/react-select": "^2.1.4",
32
40
  "@radix-ui/react-slot": "^1.1.1",
33
41
  "@radix-ui/react-switch": "^1.1.2",
42
+ "@radix-ui/react-tabs": "^1.1.2",
43
+ "@radix-ui/react-toggle": "^1.1.1",
44
+ "@radix-ui/react-toggle-group": "^1.1.1",
45
+ "@radix-ui/react-tooltip": "^1.1.6",
34
46
  "@shadcn/ui": "^0.0.4",
35
47
  "class-variance-authority": "^0.7.1",
36
48
  "clsx": "^2.1.1",
49
+ "date-fns": "^4.1.0",
50
+ "date-fns-tz": "^3.2.0",
37
51
  "lucide-react": "^0.469.0",
52
+ "react-day-picker": "^9.5.0",
53
+ "sonner": "^1.7.1",
38
54
  "tailwind-merge": "^2.6.0",
39
55
  "tailwindcss-animate": "^1.0.7",
40
- "vite": "^6.0.6"
56
+ "vite": "^6.0.7"
41
57
  },
42
58
  "peerDependencies": {
43
59
  "react": "^19.0.0",
@@ -59,6 +75,7 @@
59
75
  "@storybook/react": "^8.4.7",
60
76
  "@storybook/react-vite": "^8.4.7",
61
77
  "@storybook/test": "^8.4.7",
78
+ "@types/jest": "^29.5.14",
62
79
  "@types/node": "^22.10.3",
63
80
  "@types/react": "^19.0.2",
64
81
  "@types/react-dom": "^19.0.2",
package/.editorconfig DELETED
@@ -1,5 +0,0 @@
1
- root = true
2
-
3
- [*]
4
- indent_style = tab
5
- indent_size = 2
package/.eslintrc.json DELETED
@@ -1,3 +0,0 @@
1
- {
2
- "extends": ["next/core-web-vitals", "next/typescript", "prettier"]
3
- }
@@ -1,25 +0,0 @@
1
- name: Release
2
- on:
3
- push:
4
- branches:
5
- - main
6
- - alpha
7
- - beta
8
- - rc
9
- jobs:
10
- release:
11
- runs-on: ubuntu-latest
12
- steps:
13
- - name: Checkout code
14
- uses: actions/checkout@v3
15
- - name: Setup Node.js
16
- uses: actions/setup-node@v3
17
- with:
18
- node-version: "20.8.1"
19
- - name: Install dependencies
20
- run: npm ci
21
- - name: Run semantic-release
22
- env:
23
- GH_TOKEN: ${{ secrets.GH_TOKEN }}
24
- NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
25
- run: npm run release
package/.husky/commit-msg DELETED
@@ -1 +0,0 @@
1
- npx --no-install commitlint --edit "$1"
package/.prettierignore DELETED
@@ -1,6 +0,0 @@
1
- .github
2
- node_modules
3
- build
4
- dist
5
-
6
- *.md
package/.prettierrc DELETED
@@ -1,6 +0,0 @@
1
- {
2
- "semi": false,
3
- "singleQuote": true,
4
- "printWidth": 90,
5
- "plugins": ["prettier-plugin-tailwindcss", "prettier-plugin-organize-imports"]
6
- }
package/.releaserc.json DELETED
@@ -1,40 +0,0 @@
1
- {
2
- "branches": [
3
- "main",
4
- {
5
- "name": "alpha",
6
- "prerelease": "alpha"
7
- },
8
- {
9
- "name": "beta",
10
- "prerelease": "beta"
11
- },
12
- {
13
- "name": "release-candidate",
14
- "prerelease": "rc"
15
- }
16
- ],
17
- "plugins": [
18
- "@semantic-release/commit-analyzer",
19
- "@semantic-release/release-notes-generator",
20
- [
21
- "@semantic-release/changelog",
22
- {
23
- "changelogFile": "CHANGELOG.md"
24
- }
25
- ],
26
- [
27
- "@semantic-release/npm",
28
- {
29
- "npmPublish": true
30
- }
31
- ],
32
- [
33
- "@semantic-release/git",
34
- {
35
- "assets": ["package.json", "CHANGELOG.md"],
36
- "message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"
37
- }
38
- ]
39
- ]
40
- }
@@ -1,26 +0,0 @@
1
- import type { StorybookConfig } from '@storybook/react-vite'
2
- import { mergeConfig } from 'vite'
3
-
4
- const config: StorybookConfig = {
5
- stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
6
- addons: [
7
- '@storybook/addon-onboarding',
8
- '@storybook/addon-essentials',
9
- '@chromatic-com/storybook',
10
- '@storybook/addon-interactions',
11
- ],
12
- framework: {
13
- name: '@storybook/react-vite',
14
- options: {},
15
- },
16
- async viteFinal(config) {
17
- return mergeConfig(config, {
18
- css: {
19
- postcss: {
20
- plugins: [require('tailwindcss'), require('autoprefixer')],
21
- },
22
- },
23
- })
24
- },
25
- }
26
- export default config
@@ -1,15 +0,0 @@
1
- import type { Preview } from "@storybook/react";
2
- import "../src/styles/tailwind.css";
3
-
4
- const preview: Preview = {
5
- parameters: {
6
- controls: {
7
- matchers: {
8
- color: /(background|color)$/i,
9
- date: /Date$/i,
10
- },
11
- },
12
- },
13
- };
14
-
15
- export default preview;
package/CHANGELOG.md DELETED
@@ -1,53 +0,0 @@
1
- # [1.1.0-alpha.6](https://github.com/adrianomaringolo/buildgrid-ui/compare/v1.1.0-alpha.5...v1.1.0-alpha.6) (2025-01-03)
2
-
3
-
4
- ### Features
5
-
6
- * **avatar:** add Avatar component with fallback and image support ([893a16e](https://github.com/adrianomaringolo/buildgrid-ui/commit/893a16e8c45a35f56f91d1a11e1615cb4fa35347))
7
- * **dropdown-menu:** add DropdownMenu component with stories and functionality ([5006e9d](https://github.com/adrianomaringolo/buildgrid-ui/commit/5006e9dd4c41354cda4f664f2169b6fd77a75e87))
8
-
9
- # [1.1.0-alpha.5](https://github.com/adrianomaringolo/buildgrid-ui/compare/v1.1.0-alpha.4...v1.1.0-alpha.5) (2025-01-03)
10
-
11
-
12
- ### Features
13
-
14
- * **adaptive-input:** add AdaptiveInput component with masking functionality and stories ([d2d9794](https://github.com/adrianomaringolo/buildgrid-ui/commit/d2d97944b150163d69342ddb68e6e188283f0348))
15
- * **autocomplete:** add Autocomplete component with stories and functionality ([c35b4ae](https://github.com/adrianomaringolo/buildgrid-ui/commit/c35b4ae634654b1451ab0f3936f1d757ff70e122))
16
- * **input:** add Input component with stories ([8078ee7](https://github.com/adrianomaringolo/buildgrid-ui/commit/8078ee7c0e9b986007d89096d08065300c36b7c9))
17
- * **popover:** add Popover component with stories ([32373a1](https://github.com/adrianomaringolo/buildgrid-ui/commit/32373a13c235e0899b9c332f42b48f13c704f82c))
18
-
19
- # [1.1.0-alpha.4](https://github.com/adrianomaringolo/buildgrid-ui/compare/v1.1.0-alpha.3...v1.1.0-alpha.4) (2025-01-02)
20
-
21
-
22
- ### Features
23
-
24
- * add Checkbox component and related stories ([7e2d66b](https://github.com/adrianomaringolo/buildgrid-ui/commit/7e2d66b7a19f8ddb5a6a5e5f827f1df552977113))
25
-
26
- # [1.1.0-alpha.3](https://github.com/adrianomaringolo/buildgrid-ui/compare/v1.1.0-alpha.2...v1.1.0-alpha.3) (2025-01-02)
27
-
28
-
29
- ### Features
30
-
31
- * add new components ([acc2538](https://github.com/adrianomaringolo/buildgrid-ui/commit/acc253867cbadec11b61c3d9dcf1b5151ac3096b))
32
-
33
- # [1.1.0-alpha.2](https://github.com/adrianomaringolo/buildgrid-ui/compare/v1.1.0-alpha.1...v1.1.0-alpha.2) (2025-01-02)
34
-
35
-
36
- ### Features
37
-
38
- * add Badge component and related stories ([4106287](https://github.com/adrianomaringolo/buildgrid-ui/commit/41062872c2807cfa14494c9cab1f2b8fe506d246))
39
-
40
- # [1.1.0-alpha.1](https://github.com/adrianomaringolo/buildgrid-ui/compare/v1.0.0...v1.1.0-alpha.1) (2025-01-02)
41
-
42
-
43
- ### Features
44
-
45
- * adding shadcn configuration ([5841434](https://github.com/adrianomaringolo/buildgrid-ui/commit/584143402fad7aa19e477693d2a4727f5625e430))
46
- * enhance Button component stories with props and update export ([69292b3](https://github.com/adrianomaringolo/buildgrid-ui/commit/69292b3d467dd5ed8eacf521e9c5f89e465af323))
47
-
48
- # 1.0.0 (2025-01-02)
49
-
50
-
51
- ### Features
52
-
53
- * add Button component with Storybook integration and initial configuration ([bbc4e9a](https://github.com/adrianomaringolo/buildgrid-ui/commit/bbc4e9a54e3ea295622c8598d51576f3cddd1b3d))