@granto-umbrella/umbrella-components 3.0.53 → 3.0.55

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@granto-umbrella/umbrella-components",
3
- "version": "3.0.53",
3
+ "version": "3.0.55",
4
4
  "description": "Umbrella Components for React",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
@@ -79,6 +79,7 @@
79
79
  "@storybook/addon-docs": "10.1.6",
80
80
  "@storybook/addon-essentials": "^8.6.14",
81
81
  "@storybook/addon-onboarding": "10.1.6",
82
+ "@storybook/cli": "^10.1.10",
82
83
  "@storybook/react-vite": "^10.1.6",
83
84
  "@storybook/test": "^8.6.14",
84
85
  "@testing-library/dom": "^10.4.1",
@@ -115,7 +116,8 @@
115
116
  "ts-node": "^10.9.2",
116
117
  "typescript": "~5.6.2",
117
118
  "typescript-eslint": "^8.18.1",
118
- "vite": "^6.0.3"
119
+ "vite": "^6.0.3",
120
+ "vite-plugin-dts": "^4.5.4"
119
121
  },
120
122
  "keywords": [
121
123
  "cli",
@@ -1,28 +1,27 @@
1
- export interface ButtonProps
2
- extends React.ButtonHTMLAttributes<HTMLButtonElement> {
3
- size?: 'sm' | 'md' | 'lg';
4
- variant?:
5
- | 'primary'
6
- | 'outline'
7
- | 'outline_ghost'
8
- | 'outline_ghost_disabled'
9
- | 'outline_danger'
10
- | 'danger'
11
- | 'ghost'
12
- | 'ghost_alert'
13
- | 'alert'
14
- | 'danger-no-fill'
15
- | 'accent-outline'
16
- | 'accent-fill'
17
- | 'secondary-outline'
18
- | 'danger-fill';
19
- radius?: string;
20
- isLoading?: boolean;
21
- leftIcon?: string;
22
- rightIcon?: string;
23
- iconSize?: string;
24
- fontSize?: string;
25
- width?: string;
26
- height?: string;
27
- testId?: string;
28
- }
1
+ export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
2
+ size?: 'sm' | 'md' | 'lg';
3
+ variant?:
4
+ | 'primary'
5
+ | 'outline'
6
+ | 'outline_ghost'
7
+ | 'outline_ghost_disabled'
8
+ | 'outline_danger'
9
+ | 'danger'
10
+ | 'ghost'
11
+ | 'ghost_alert'
12
+ | 'alert'
13
+ | 'danger-no-fill'
14
+ | 'accent-outline'
15
+ | 'accent-fill'
16
+ | 'secondary-outline'
17
+ | 'danger-fill';
18
+ radius?: string;
19
+ isLoading?: boolean;
20
+ leftIcon?: string;
21
+ rightIcon?: string;
22
+ iconSize?: string;
23
+ fontSize?: string;
24
+ width?: string;
25
+ height?: string;
26
+ testId?: string;
27
+ }
@@ -1,14 +1,13 @@
1
- export interface CheckboxProps
2
- extends React.InputHTMLAttributes<HTMLInputElement> {
3
- label?: string;
4
- checked?: boolean;
5
- onChange?: () => void;
6
- disabled?: boolean;
7
- }
8
-
9
- export interface CheckboxGroupProps {
10
- options: { label: string; value: string }[];
11
- selected: string[];
12
- setSelected: (values: string[]) => void;
13
- direction?: 'vertical' | 'horizontal';
14
- }
1
+ export interface CheckboxProps extends React.InputHTMLAttributes<HTMLInputElement> {
2
+ label?: string;
3
+ checked?: boolean;
4
+ onChange?: () => void;
5
+ disabled?: boolean;
6
+ }
7
+
8
+ export interface CheckboxGroupProps {
9
+ options: { label: string; value: string }[];
10
+ selected: string[];
11
+ setSelected: (values: string[]) => void;
12
+ direction?: 'vertical' | 'horizontal';
13
+ }
@@ -1,7 +1,6 @@
1
- export interface TextareaProps
2
- extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {
3
- label?: string;
4
- supportingText?: string;
5
- testId?: string;
6
- info?: string;
7
- }
1
+ export interface TextareaProps extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {
2
+ label?: string;
3
+ supportingText?: string;
4
+ testId?: string;
5
+ info?: string;
6
+ }
@@ -1,4 +1,3 @@
1
-
2
1
  import React, { useState } from 'react';
3
2
  import {
4
3
  TooltipContainer,
@@ -9,7 +8,7 @@ import {
9
8
  } from '../Tooltip/Tootip.styles';
10
9
  import { TooltipProps } from './tooltip.types';
11
10
  import { ArrowSquareOut } from '@phosphor-icons/react';
12
- import info from "../../../assets/info.png";
11
+ import info from '../../../assets/info.png';
13
12
 
14
13
  const Tooltip: React.FC<TooltipProps> = ({
15
14
  children,
@@ -44,7 +43,11 @@ const Tooltip: React.FC<TooltipProps> = ({
44
43
  >
45
44
  <TooltipText>{content}</TooltipText>
46
45
  {helpLink && (
47
- <TooltipLink href={helpLink} target="_blank" rel="noopener noreferrer">
46
+ <TooltipLink
47
+ href={helpLink}
48
+ target="_blank"
49
+ rel="noopener noreferrer"
50
+ >
48
51
  Saiba mais
49
52
  <ArrowSquareOut size={12} weight="bold" />
50
53
  </TooltipLink>
@@ -1,4 +1,3 @@
1
-
2
1
  import styled, { css } from 'styled-components';
3
2
  import {
4
3
  semanticColors,
@@ -123,7 +122,9 @@ export const TooltipContent = styled.div<{
123
122
 
124
123
  opacity: ${({ $visible }) => ($visible ? '1' : '0')};
125
124
  visibility: ${({ $visible }) => ($visible ? 'visible' : 'hidden')};
126
- transition: opacity 0.2s ease, visibility 0.2s ease;
125
+ transition:
126
+ opacity 0.2s ease,
127
+ visibility 0.2s ease;
127
128
  pointer-events: ${({ $visible }) => ($visible ? 'auto' : 'none')};
128
129
 
129
130
  ${({ $position }) => positionStyles[$position]}
@@ -150,4 +151,3 @@ export const TooltipLink = styled.a`
150
151
  color: ${primitiveColors.blue[800]};
151
152
  }
152
153
  `;
153
-
@@ -1,4 +1,3 @@
1
-
2
1
  export type TooltipPosition = 'top' | 'bottom' | 'left' | 'right';
3
2
 
4
3
  export interface TooltipProps {
@@ -7,4 +6,3 @@ export interface TooltipProps {
7
6
  position?: TooltipPosition;
8
7
  helpLink?: string;
9
8
  }
10
-
@@ -5,6 +5,8 @@ export interface RadioOption {
5
5
  label: string;
6
6
  iconActive?: ReactNode;
7
7
  iconInactive?: ReactNode;
8
+ iconDesactive?: ReactNode;
9
+ testId?: string;
8
10
  }
9
11
 
10
12
  export interface RadioGroupFieldProps {
package/src/index.ts CHANGED
@@ -1,161 +1,159 @@
1
- import { Form } from 'react-hook-form';
2
-
3
- // Import all components
4
- import {
5
- Dialog,
6
- DialogContent,
7
- DialogDescription,
8
- DialogPortal,
9
- DialogTitle,
10
- DialogTrigger,
11
- } from '@radix-ui/react-dialog';
12
-
13
- import Badge from './components/atoms/Badge/Badge';
14
- import Breadcrumb from './components/atoms/Breadcrumb/Breadcrumb';
15
- import Button from './components/atoms/Button';
16
- import { Checkbox } from './components/atoms/Checkbox/Checkbox';
17
- import CodeInput from './components/atoms/CodeInput/CodeInput';
18
- import { DatePickerInput } from './components/atoms/DatePickerInput/DatePickerInput';
19
- import { DropdownMenu } from './components/atoms/DropDownMenu/DropdownMenu';
20
- import ErrorMessage from './components/atoms/ErrorMessage';
21
- import Footer from './components/atoms/Footer/Footer';
22
- import { GenericContainer } from './components/atoms/GenericContainer';
23
- import Icon from './components/atoms/Icon';
24
- import Input from './components/atoms/Input';
25
- import { Label } from './components/atoms/Label/Label';
26
- import Loading from './components/atoms/Loading';
27
- import { LogoContainer } from './components/atoms/LogoContainer';
28
- import { ModalAviso } from './components/atoms/ModalAviso';
29
- import { MultiSelect } from './components/atoms/MultiSelect';
30
- import Pill from './components/atoms/Pill/Pill';
31
- import RadioButton from './components/atoms/RadioButton/RadioButton';
32
- import { ResendLink } from './components/atoms/ResendLink';
33
- import Select from './components/atoms/Select';
34
- import { Subtitle } from './components/atoms/Subtitle';
35
- import Switch from './components/atoms/Switch/Switch';
36
- import { TabBar } from './components/atoms/TabBar';
37
- import Text from './components/atoms/Text';
38
- import Textarea from './components/atoms/Textarea/Textarea';
39
- import { Title } from './components/atoms/Title';
40
- import { BannerAjuda } from './components/molecules/BannerAjuda';
41
- import ButtonGroup from './components/molecules/ButtonGroup/ButtonGroup';
42
- import { Calendar } from './components/molecules/Calendar/Calendar';
43
- import { CodeInputContainer } from './components/molecules/CodeInputContainer';
44
- import FieldSelector from './components/molecules/FieldSelector/FieldSelector';
45
- import { HighlightsCard } from './components/molecules/HighlightsCard/HighlightsCard';
46
- import { InsuranceCard } from './components/molecules/InsuranceCard/InsuranceCard';
47
- import { PieChartComponent } from './components/molecules/PieChartComponent/PieChartComponent';
48
- import {
49
- Popover,
50
- PopoverContent,
51
- PopoverTrigger,
52
- } from './components/molecules/Popover/Popover';
53
- import RadioGroup from './components/molecules/RadioBoxGroup/RadioBoxGroup';
54
- import { RadioGroupField } from './components/molecules/RadioGroupField';
55
- import { TabToggle } from './components/molecules/TabToggle/TabToggle';
56
- import { Timeline } from './components/molecules/TimeLine/TimeLine';
57
- import AlertDialog from './components/organisms/AlertDialog/AlertDialog';
58
- import {
59
- DialogFooter,
60
- DialogHeader,
61
- } from './components/organisms/Dialog/Dialog';
62
- import {
63
- StyledDialogClose,
64
- StyledDialogOverlay,
65
- } from './components/organisms/Dialog/Dialog.styles';
66
- import DonutEmissionsChart from './components/organisms/DonutEmissionsChart';
67
- import { ExportExcelModal } from './components/organisms/ExportExcelModal/ExportExcelModal';
68
- import {
69
- FormControl,
70
- FormDescription,
71
- FormField,
72
- FormItem,
73
- FormLabel,
74
- FormMessage,
75
- useFormField,
76
- } from './components/organisms/Form/Form';
77
- import { ListagemUltimasEmissoes } from './components/organisms/ListagemUltimasEmissoes/ListagemUltimasEmissoes';
78
- import NavbarContainer from './components/organisms/Navbar/Navbar';
79
- import { TimelineModal } from './components/organisms/TimelineModal/TimelineModal';
80
-
81
- // Export all components
82
- export {
83
- InsuranceCard,
84
- DonutEmissionsChart,
85
- RadioGroupField,
86
- PieChartComponent,
87
- AlertDialog,
88
- FieldSelector,
89
- BannerAjuda,
90
- Badge,
91
- ExportExcelModal,
92
- Breadcrumb,
93
- Button,
94
- ButtonGroup,
95
- Calendar,
96
- CodeInput,
97
- CodeInputContainer,
98
- Checkbox,
99
- DatePickerInput,
100
- Dialog,
101
- DialogContent,
102
- DialogDescription,
103
- ListagemUltimasEmissoes,
104
- DialogFooter,
105
- DialogHeader,
106
- DialogPortal,
107
- DialogTitle,
108
- DialogTrigger,
109
- DropdownMenu,
110
- ErrorMessage,
111
- HighlightsCard,
112
- Footer,
113
- Form,
114
- FormControl,
115
- FormDescription,
116
- FormField,
117
- FormItem,
118
- FormLabel,
119
- FormMessage,
120
- GenericContainer,
121
- Loading,
122
- LogoContainer,
123
- ModalAviso,
124
- MultiSelect,
125
- Icon,
126
- Input,
127
- Label,
128
- Pill,
129
- Popover,
130
- PopoverContent,
131
- PopoverTrigger,
132
- RadioButton,
133
- RadioGroup,
134
- ResendLink,
135
- Select,
136
- Subtitle,
137
- StyledDialogClose,
138
- StyledDialogOverlay,
139
- Switch,
140
- TabBar,
141
- TabToggle,
142
- Text,
143
- Textarea,
144
- Title,
145
- useFormField,
146
- Timeline,
147
- TimelineModal,
148
- NavbarContainer,
149
- };
150
-
151
- // Export all tokens from a new file
152
- export { primitiveBorders, semanticBorders } from './styles/tokens/borders';
153
- export { primitiveColors, semanticColors } from './styles/tokens/colors';
154
- export { primitiveRadius, semanticRadius } from './styles/tokens/radius';
155
- export { primitiveShadows, semanticShadows } from './styles/tokens/shadows';
156
- export { primitiveSizes, semanticSizes } from './styles/tokens/sizes';
157
- export { typographyTokens } from './styles/tokens/typography';
158
-
159
- // Export all types
160
- export type { Radius } from './types/radius.types';
161
- export type { Shadows } from './types/shadows.types';
1
+ import { Form } from 'react-hook-form';
2
+
3
+ import {
4
+ Dialog,
5
+ DialogContent,
6
+ DialogDescription,
7
+ DialogPortal,
8
+ DialogTitle,
9
+ DialogTrigger,
10
+ } from '@radix-ui/react-dialog';
11
+
12
+ import Badge from './components/atoms/Badge/Badge';
13
+ import Breadcrumb from './components/atoms/Breadcrumb/Breadcrumb';
14
+ import Button from './components/atoms/Button';
15
+ import { Checkbox } from './components/atoms/Checkbox/Checkbox';
16
+ import CodeInput from './components/atoms/CodeInput/CodeInput';
17
+ import { DatePickerInput } from './components/atoms/DatePickerInput/DatePickerInput';
18
+ import { DropdownMenu } from './components/atoms/DropDownMenu/DropdownMenu';
19
+ import ErrorMessage from './components/atoms/ErrorMessage';
20
+ import Footer from './components/atoms/Footer/Footer';
21
+ import { GenericContainer } from './components/atoms/GenericContainer';
22
+ import Icon from './components/atoms/Icon';
23
+ import Input from './components/atoms/Input';
24
+ import { Label } from './components/atoms/Label/Label';
25
+ import Loading from './components/atoms/Loading';
26
+ import { LogoContainer } from './components/atoms/LogoContainer';
27
+ import { ModalAviso } from './components/atoms/ModalAviso';
28
+ import { MultiSelect } from './components/atoms/MultiSelect';
29
+ import Pill from './components/atoms/Pill/Pill';
30
+ import RadioButton from './components/atoms/RadioButton/RadioButton';
31
+ import { ResendLink } from './components/atoms/ResendLink';
32
+ import Select from './components/atoms/Select';
33
+ import { Subtitle } from './components/atoms/Subtitle';
34
+ import Switch from './components/atoms/Switch/Switch';
35
+ import { TabBar } from './components/atoms/TabBar';
36
+ import Text from './components/atoms/Text';
37
+ import Textarea from './components/atoms/Textarea/Textarea';
38
+ import { Title } from './components/atoms/Title';
39
+ import { BannerAjuda } from './components/molecules/BannerAjuda';
40
+ import ButtonGroup from './components/molecules/ButtonGroup/ButtonGroup';
41
+ import { Calendar } from './components/molecules/Calendar/Calendar';
42
+ import { CodeInputContainer } from './components/molecules/CodeInputContainer';
43
+ import FieldSelector from './components/molecules/FieldSelector/FieldSelector';
44
+ import { HighlightsCard } from './components/molecules/HighlightsCard/HighlightsCard';
45
+ import { InsuranceCard } from './components/molecules/InsuranceCard/InsuranceCard';
46
+ import { PieChartComponent } from './components/molecules/PieChartComponent/PieChartComponent';
47
+ import {
48
+ Popover,
49
+ PopoverContent,
50
+ PopoverTrigger,
51
+ } from './components/molecules/Popover/Popover';
52
+ import RadioGroup from './components/molecules/RadioBoxGroup/RadioBoxGroup';
53
+ import { RadioGroupField } from './components/molecules/RadioGroupField';
54
+ import { TabToggle } from './components/molecules/TabToggle/TabToggle';
55
+ import { Timeline } from './components/molecules/TimeLine/TimeLine';
56
+ import AlertDialog from './components/organisms/AlertDialog/AlertDialog';
57
+ import {
58
+ DialogFooter,
59
+ DialogHeader,
60
+ } from './components/organisms/Dialog/Dialog';
61
+ import {
62
+ StyledDialogClose,
63
+ StyledDialogOverlay,
64
+ } from './components/organisms/Dialog/Dialog.styles';
65
+ import DonutEmissionsChart from './components/organisms/DonutEmissionsChart';
66
+ import { ExportExcelModal } from './components/organisms/ExportExcelModal/ExportExcelModal';
67
+ import {
68
+ FormControl,
69
+ FormDescription,
70
+ FormField,
71
+ FormItem,
72
+ FormLabel,
73
+ FormMessage,
74
+ useFormField,
75
+ } from './components/organisms/Form/Form';
76
+ import { ListagemUltimasEmissoes } from './components/organisms/ListagemUltimasEmissoes/ListagemUltimasEmissoes';
77
+ import NavbarContainer from './components/organisms/Navbar/Navbar';
78
+ import { TimelineModal } from './components/organisms/TimelineModal/TimelineModal';
79
+ import Tooltip from './components/atoms/Tooltip/Tooltip';
80
+
81
+ export {
82
+ InsuranceCard,
83
+ DonutEmissionsChart,
84
+ RadioGroupField,
85
+ PieChartComponent,
86
+ AlertDialog,
87
+ FieldSelector,
88
+ BannerAjuda,
89
+ Badge,
90
+ ExportExcelModal,
91
+ Breadcrumb,
92
+ Button,
93
+ ButtonGroup,
94
+ Calendar,
95
+ CodeInput,
96
+ CodeInputContainer,
97
+ Checkbox,
98
+ DatePickerInput,
99
+ Dialog,
100
+ DialogContent,
101
+ DialogDescription,
102
+ ListagemUltimasEmissoes,
103
+ DialogFooter,
104
+ DialogHeader,
105
+ DialogPortal,
106
+ DialogTitle,
107
+ DialogTrigger,
108
+ DropdownMenu,
109
+ ErrorMessage,
110
+ HighlightsCard,
111
+ Footer,
112
+ Form,
113
+ FormControl,
114
+ FormDescription,
115
+ FormField,
116
+ FormItem,
117
+ FormLabel,
118
+ FormMessage,
119
+ GenericContainer,
120
+ Loading,
121
+ LogoContainer,
122
+ ModalAviso,
123
+ MultiSelect,
124
+ Icon,
125
+ Input,
126
+ Label,
127
+ Pill,
128
+ Popover,
129
+ PopoverContent,
130
+ PopoverTrigger,
131
+ RadioButton,
132
+ RadioGroup,
133
+ ResendLink,
134
+ Select,
135
+ Subtitle,
136
+ StyledDialogClose,
137
+ StyledDialogOverlay,
138
+ Switch,
139
+ TabBar,
140
+ TabToggle,
141
+ Text,
142
+ Textarea,
143
+ Title,
144
+ useFormField,
145
+ Timeline,
146
+ TimelineModal,
147
+ NavbarContainer,
148
+ Tooltip,
149
+ };
150
+
151
+ export { primitiveBorders, semanticBorders } from './styles/tokens/borders';
152
+ export { primitiveColors, semanticColors } from './styles/tokens/colors';
153
+ export { primitiveRadius, semanticRadius } from './styles/tokens/radius';
154
+ export { primitiveShadows, semanticShadows } from './styles/tokens/shadows';
155
+ export { primitiveSizes, semanticSizes } from './styles/tokens/sizes';
156
+ export { typographyTokens } from './styles/tokens/typography';
157
+
158
+ export type { Radius } from './types/radius.types';
159
+ export type { Shadows } from './types/shadows.types';