@vincisys/eyeson 0.2.0 → 0.4.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.
- package/dist/components/Attachment/Attachment.d.ts +98 -0
- package/dist/components/Attachment/Attachment.d.ts.map +1 -0
- package/dist/components/Button/Button.d.ts +7 -7
- package/dist/components/Button/Button.d.ts.map +1 -1
- package/dist/components/Card/Card.d.ts.map +1 -1
- package/dist/components/DatePicker/DatePicker.d.ts +13 -1
- package/dist/components/DatePicker/DatePicker.d.ts.map +1 -1
- package/dist/components/Dialog/Dialog.d.ts +40 -29
- package/dist/components/Dialog/Dialog.d.ts.map +1 -1
- package/dist/components/FormDialog/FormDialog.d.ts +84 -0
- package/dist/components/FormDialog/FormDialog.d.ts.map +1 -0
- package/dist/components/IconButton/IconButton.d.ts.map +1 -1
- package/dist/components/Input/Input.d.ts +18 -1
- package/dist/components/Input/Input.d.ts.map +1 -1
- package/dist/components/Select/Select.d.ts +14 -2
- package/dist/components/Select/Select.d.ts.map +1 -1
- package/dist/index.d.ts +10 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +853 -625
- package/dist/lib/field-styles.d.ts +3 -0
- package/dist/lib/field-styles.d.ts.map +1 -1
- package/dist/styles/eyes-binding.css +1 -1
- package/dist/styles/eyes-standalone.css +1 -1
- package/dist/styles/theme-eyes.css +12 -1
- package/package.json +5 -2
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import type { ComponentProps, ReactNode } from 'react';
|
|
2
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
3
|
+
import { type IconButtonProps } from '../IconButton/IconButton';
|
|
4
|
+
export type AttachmentState = 'idle' | 'uploading' | 'processing' | 'error' | 'done';
|
|
5
|
+
export type AttachmentSize = 'default' | 'sm' | 'xs';
|
|
6
|
+
export type AttachmentOrientation = 'horizontal' | 'vertical';
|
|
7
|
+
export type AttachmentMediaVariant = 'icon' | 'image';
|
|
8
|
+
export type AttachmentProps = ComponentProps<'div'> & {
|
|
9
|
+
/**
|
|
10
|
+
* Estado do upload.
|
|
11
|
+
* - `"idle"` — pronto para enviar (borda tracejada)
|
|
12
|
+
* - `"uploading"` / `"processing"` — em progresso (shimmer no título)
|
|
13
|
+
* - `"error"` — falha
|
|
14
|
+
* - `"done"` — concluído (padrão)
|
|
15
|
+
* @default "done"
|
|
16
|
+
*/
|
|
17
|
+
state?: AttachmentState;
|
|
18
|
+
/** Tamanho do attachment. @default "default" */
|
|
19
|
+
size?: AttachmentSize;
|
|
20
|
+
/** Layout do media em relação ao conteúdo. @default "horizontal" */
|
|
21
|
+
orientation?: AttachmentOrientation;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Exibe um anexo (arquivo ou imagem) com mídia, metadados, estado de upload e ações.
|
|
25
|
+
* Compound component baseado no padrão shadcn Attachment, com tokens EDS e azul predominante.
|
|
26
|
+
*
|
|
27
|
+
* @example
|
|
28
|
+
* ```tsx
|
|
29
|
+
* <Attachment>
|
|
30
|
+
* <Attachment.Media><FileText /></Attachment.Media>
|
|
31
|
+
* <Attachment.Content>
|
|
32
|
+
* <Attachment.Title>relatorio.pdf</Attachment.Title>
|
|
33
|
+
* <Attachment.Description>PDF · 2.4 MB</Attachment.Description>
|
|
34
|
+
* </Attachment.Content>
|
|
35
|
+
* <Attachment.Actions>
|
|
36
|
+
* <Attachment.Action icon={X} label="Remover relatorio.pdf" />
|
|
37
|
+
* </Attachment.Actions>
|
|
38
|
+
* </Attachment>
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
declare function AttachmentRoot({ className, state, size, orientation, ...props }: AttachmentProps): import("react").JSX.Element;
|
|
42
|
+
export type AttachmentMediaProps = ComponentProps<'div'> & {
|
|
43
|
+
/** `"icon"` para ícone; `"image"` para preview com `<img>`. @default "icon" */
|
|
44
|
+
variant?: AttachmentMediaVariant;
|
|
45
|
+
};
|
|
46
|
+
declare function AttachmentMedia({ className, variant, ...props }: AttachmentMediaProps): import("react").JSX.Element;
|
|
47
|
+
declare namespace AttachmentMedia {
|
|
48
|
+
var displayName: string;
|
|
49
|
+
}
|
|
50
|
+
export type AttachmentContentProps = ComponentProps<'div'>;
|
|
51
|
+
declare function AttachmentContent({ className, ...props }: AttachmentContentProps): import("react").JSX.Element;
|
|
52
|
+
declare namespace AttachmentContent {
|
|
53
|
+
var displayName: string;
|
|
54
|
+
}
|
|
55
|
+
export type AttachmentTitleProps = ComponentProps<'span'>;
|
|
56
|
+
declare function AttachmentTitle({ className, ...props }: AttachmentTitleProps): import("react").JSX.Element;
|
|
57
|
+
declare namespace AttachmentTitle {
|
|
58
|
+
var displayName: string;
|
|
59
|
+
}
|
|
60
|
+
export type AttachmentDescriptionProps = ComponentProps<'span'>;
|
|
61
|
+
declare function AttachmentDescription({ className, ...props }: AttachmentDescriptionProps): import("react").JSX.Element;
|
|
62
|
+
declare namespace AttachmentDescription {
|
|
63
|
+
var displayName: string;
|
|
64
|
+
}
|
|
65
|
+
export type AttachmentActionsProps = ComponentProps<'div'>;
|
|
66
|
+
declare function AttachmentActions({ className, ...props }: AttachmentActionsProps): import("react").JSX.Element;
|
|
67
|
+
declare namespace AttachmentActions {
|
|
68
|
+
var displayName: string;
|
|
69
|
+
}
|
|
70
|
+
export type AttachmentActionProps = IconButtonProps;
|
|
71
|
+
declare function AttachmentAction({ variant, color, size, className, ...props }: AttachmentActionProps): import("react").JSX.Element;
|
|
72
|
+
declare namespace AttachmentAction {
|
|
73
|
+
var displayName: string;
|
|
74
|
+
}
|
|
75
|
+
export type AttachmentTriggerProps = useRender.ComponentProps<'button'> & {
|
|
76
|
+
children?: ReactNode;
|
|
77
|
+
};
|
|
78
|
+
declare function AttachmentTrigger({ className, render, type, ...props }: AttachmentTriggerProps): import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>>;
|
|
79
|
+
declare namespace AttachmentTrigger {
|
|
80
|
+
var displayName: string;
|
|
81
|
+
}
|
|
82
|
+
export type AttachmentGroupProps = ComponentProps<'div'>;
|
|
83
|
+
declare function AttachmentGroup({ className, ...props }: AttachmentGroupProps): import("react").JSX.Element;
|
|
84
|
+
declare namespace AttachmentGroup {
|
|
85
|
+
var displayName: string;
|
|
86
|
+
}
|
|
87
|
+
export declare const Attachment: typeof AttachmentRoot & {
|
|
88
|
+
Media: typeof AttachmentMedia;
|
|
89
|
+
Content: typeof AttachmentContent;
|
|
90
|
+
Title: typeof AttachmentTitle;
|
|
91
|
+
Description: typeof AttachmentDescription;
|
|
92
|
+
Actions: typeof AttachmentActions;
|
|
93
|
+
Action: typeof AttachmentAction;
|
|
94
|
+
Trigger: typeof AttachmentTrigger;
|
|
95
|
+
Group: typeof AttachmentGroup;
|
|
96
|
+
};
|
|
97
|
+
export { AttachmentGroup, AttachmentMedia, AttachmentContent, AttachmentTitle, AttachmentDescription, AttachmentActions, AttachmentAction, AttachmentTrigger, };
|
|
98
|
+
//# sourceMappingURL=Attachment.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Attachment.d.ts","sourceRoot":"","sources":["../../../src/components/Attachment/Attachment.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvD,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,OAAmB,EAAE,KAAK,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE5E,MAAM,MAAM,eAAe,GAC1B,MAAM,GAAG,WAAW,GAAG,YAAY,GAAG,OAAO,GAAG,MAAM,CAAC;AACxD,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,IAAI,GAAG,IAAI,CAAC;AACrD,MAAM,MAAM,qBAAqB,GAAG,YAAY,GAAG,UAAU,CAAC;AAC9D,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,OAAO,CAAC;AAwBtD,MAAM,MAAM,eAAe,GAAG,cAAc,CAAC,KAAK,CAAC,GAAG;IACrD;;;;;;;OAOG;IACH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MAAM,qBAAqB,GAAG,eAAe,CAAC;AAEpD,iBAAS,gBAAgB,CAAC,EACzB,OAAiB,EACjB,KAAmB,EACnB,IAAW,EACX,SAAS,EACT,GAAG,KAAK,EACR,EAAE,qBAAqB,+BAWvB;kBAjBQ,gBAAgB;;;AAmBzB,MAAM,MAAM,sBAAsB,GAAG,SAAS,CAAC,cAAc,CAAC,QAAQ,CAAC,GAAG;IACzE,QAAQ,CAAC,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF,iBAAS,iBAAiB,CAAC,EAC1B,SAAS,EACT,MAAM,EACN,IAAI,EACJ,GAAG,KAAK,EACR,EAAE,sBAAsB,8FAkBxB;kBAvBQ,iBAAiB;;;AAyB1B,MAAM,MAAM,oBAAoB,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC;AAEzD,iBAAS,eAAe,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,oBAAoB,+BAarE;kBAbQ,eAAe;;;AAwBxB,eAAO,MAAM,UAAU;;;;;;;;;CASrB,CAAC;AAGH,OAAO,EACN,eAAe,EACf,eAAe,EACf,iBAAiB,EACjB,eAAe,EACf,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,EAChB,iBAAiB,GACjB,CAAC"}
|
|
@@ -10,27 +10,27 @@ export declare const SOLID_WHITE_TEXT_COLORS: Set<"blue-background" | "blue-dark
|
|
|
10
10
|
export declare const EDS_BUTTON_VARIANTS: {
|
|
11
11
|
readonly size: {
|
|
12
12
|
readonly sm: {
|
|
13
|
-
readonly classes: "
|
|
13
|
+
readonly classes: "h-[calc(1.75rem*1.188*1.1)] gap-1 rounded-[min(var(--radius-eds-xs),12px)] px-[calc(0.625rem*1.188*1.15)] text-[0.8rem] has-data-[icon=inline-end]:pr-[calc(0.375rem*1.188*1.15)] has-data-[icon=inline-start]:pl-[calc(0.375rem*1.188*1.15)] [&_svg:not([class*='size-'])]:size-3.5 [&_.eds-btn-icon-wrap]:size-3.5";
|
|
14
14
|
};
|
|
15
15
|
readonly md: {
|
|
16
|
-
readonly classes: "
|
|
16
|
+
readonly classes: "h-[calc(2rem*1.188*1.1)] gap-1.5 px-[calc(0.625rem*1.188*1.15)] has-data-[icon=inline-end]:pr-[calc(0.5rem*1.188*1.15)] has-data-[icon=inline-start]:pl-[calc(0.5rem*1.188*1.15)] [&_.eds-btn-icon-wrap]:size-4";
|
|
17
17
|
};
|
|
18
18
|
readonly lg: {
|
|
19
|
-
readonly classes: "gap-
|
|
19
|
+
readonly classes: "h-[calc(2.25rem*1.188*1.1)] gap-1.5 px-[calc(0.625rem*1.188*1.15)] has-data-[icon=inline-end]:pr-[calc(0.5rem*1.188*1.15)] has-data-[icon=inline-start]:pl-[calc(0.5rem*1.188*1.15)] [&_.eds-btn-icon-wrap]:size-4";
|
|
20
20
|
};
|
|
21
21
|
};
|
|
22
22
|
readonly variant: {
|
|
23
23
|
readonly solid: {
|
|
24
|
-
readonly classes: "border-
|
|
24
|
+
readonly classes: "border-transparent bg-[var(--eds-btn-accent)] text-[var(--eds-btn-solid-fg,#fff)] hover:bg-[color-mix(in_srgb,var(--eds-btn-accent)_80%,transparent)] data-disabled:not-data-loading:bg-eds-neutral-disabled data-disabled:not-data-loading:text-white data-loading:data-disabled:bg-[var(--eds-btn-accent)] data-loading:data-disabled:text-[var(--eds-btn-solid-fg,#fff)]";
|
|
25
25
|
};
|
|
26
26
|
readonly outline: {
|
|
27
|
-
readonly classes: "border
|
|
27
|
+
readonly classes: "border-eds-outline-border bg-transparent text-[var(--eds-btn-accent)] hover:bg-[color-mix(in_srgb,var(--eds-btn-accent)_10%,transparent)] hover:text-[color-mix(in_srgb,var(--eds-btn-accent)_88%,black)] data-disabled:not-data-loading:border-eds-outline-border data-disabled:not-data-loading:bg-transparent data-disabled:not-data-loading:text-eds-neutral-disabled data-loading:data-disabled:border-eds-outline-border data-loading:data-disabled:bg-transparent data-loading:data-disabled:text-[var(--eds-btn-accent)] data-loading:data-disabled:opacity-100";
|
|
28
28
|
};
|
|
29
29
|
readonly ghost: {
|
|
30
|
-
readonly classes: "border-
|
|
30
|
+
readonly classes: "border-transparent bg-transparent text-[var(--eds-btn-accent)] hover:bg-[color-mix(in_srgb,var(--eds-btn-accent)_10%,transparent)] hover:text-[color-mix(in_srgb,var(--eds-btn-accent)_88%,black)] data-disabled:not-data-loading:text-eds-neutral-disabled data-loading:data-disabled:text-[var(--eds-btn-accent)]";
|
|
31
31
|
};
|
|
32
32
|
readonly link: {
|
|
33
|
-
readonly classes: "
|
|
33
|
+
readonly classes: "h-auto border-transparent bg-transparent px-0 text-[var(--eds-btn-accent)] underline-offset-4 hover:underline data-disabled:not-data-loading:text-eds-neutral-disabled data-loading:data-disabled:text-[var(--eds-btn-accent)]";
|
|
34
34
|
};
|
|
35
35
|
};
|
|
36
36
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/components/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAW,KAAK,UAAU,EAAE,MAAM,cAAc,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAiB,MAAM,OAAO,CAAC;AAC3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAI/D,MAAM,MAAM,aAAa,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,CAAC;AACnE,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAC5C,MAAM,MAAM,kBAAkB,GAAG,OAAO,GAAG,KAAK,CAAC;AACjD,MAAM,MAAM,WAAW,GAAG,gBAAgB,CAAC;AAE3C,eAAO,MAAM,uBAAuB,8VAYlC,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;CAiCtB,CAAC;AAEX,eAAO,MAAM,2BAA2B;;;CAG9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AS,SAAS,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,cAAc,+BAWzD;kBAXQ,SAAS;;;AAalB,MAAM,MAAM,oBAAoB,GAAG,cAAc,CAAC,GAAG,CAAC,CAAC;AAEvD,iBAAS,eAAe,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,oBAAoB,+BAQrE;kBARQ,eAAe;;;AAUxB,MAAM,MAAM,eAAe,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC;AAEpD,iBAAS,UAAU,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,eAAe,+BAW3D;kBAXQ,UAAU;;;AAanB,MAAM,MAAM,gBAAgB,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC;AAErD,iBAAS,WAAW,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,gBAAgB,+BAQ7D;kBARQ,WAAW;;;AAUpB,MAAM,MAAM,eAAe,GAAG,cAAc,CAAC,KAAK,CAAC,CAAC;AAEpD,iBAAS,UAAU,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,eAAe,+BAW3D;kBAXQ,UAAU;;;AAoBnB,eAAO,MAAM,IAAI;;;;;;;CAOf,CAAC"}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import { type FieldLabelVariant } from '../../lib/field-styles';
|
|
1
2
|
export type DatePickerState = 'default' | 'valid' | 'invalid';
|
|
2
3
|
export type DatePickerSize = 'sm' | 'md' | 'lg';
|
|
3
4
|
export type DatePickerMode = 'single' | 'range';
|
|
5
|
+
export type DatePickerLabelVariant = FieldLabelVariant;
|
|
4
6
|
/** Intervalo de datas selecionado no modo `range`. `to` fica indefinido até o segundo clique. */
|
|
5
7
|
export type DateRange = {
|
|
6
8
|
from: Date;
|
|
@@ -10,7 +12,17 @@ type WeekStartsOn = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
|
10
12
|
type DatePickerSharedProps = {
|
|
11
13
|
/** Texto do label acima do campo. */
|
|
12
14
|
label?: string;
|
|
13
|
-
/**
|
|
15
|
+
/**
|
|
16
|
+
* Posição do label.
|
|
17
|
+
* - `"floating"` — label flutuante na borda do campo (padrão)
|
|
18
|
+
* - `"outside"` — label acima do campo, fora da borda
|
|
19
|
+
* @default "floating"
|
|
20
|
+
*/
|
|
21
|
+
labelVariant?: DatePickerLabelVariant;
|
|
22
|
+
/**
|
|
23
|
+
* @deprecated Use `labelVariant="floating" | "outside"` instead.
|
|
24
|
+
* Quando `false`, equivale a `labelVariant="outside"`.
|
|
25
|
+
*/
|
|
14
26
|
floatingLabel?: boolean;
|
|
15
27
|
/** Texto exibido quando nenhuma data está selecionada. */
|
|
16
28
|
placeholder?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../src/components/DatePicker/DatePicker.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../src/components/DatePicker/DatePicker.tsx"],"names":[],"mappings":"AAmBA,OAAO,EAQN,KAAK,iBAAiB,EACtB,MAAM,wBAAwB,CAAC;AAIhC,MAAM,MAAM,eAAe,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;AAC9D,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAChD,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,OAAO,CAAC;AAChD,MAAM,MAAM,sBAAsB,GAAG,iBAAiB,CAAC;AAEvD,iGAAiG;AACjG,MAAM,MAAM,SAAS,GAAG;IAAE,IAAI,EAAE,IAAI,CAAC;IAAC,EAAE,CAAC,EAAE,IAAI,CAAA;CAAE,CAAC;AAmClD,KAAK,YAAY,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AAiB9C,KAAK,qBAAqB,GA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CAAC;IACd,KAAK,EAAE,SAAS,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG,qBAAqB,GAAG;IAC1D,sDAAsD;IACtD,IAAI,EAAE,OAAO,CAAC;IACd,0DAA0D;IAC1D,KAAK,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;IACzB,+DAA+D;IAC/D,YAAY,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;IAChC,wEAAwE;IACxE,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;IAC3C,sEAAsE;IACtE,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,4EAA4E;IAC5E,OAAO,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAC7B,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG,qBAAqB,GAAG,oBAAoB,CAAC;AAQ3E;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,KAAK,EAAE,eAAe,+BA6cxD"}
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { type ComponentPropsWithoutRef, type ReactNode } from 'react';
|
|
1
|
+
import { type ComponentPropsWithoutRef, type HTMLAttributes, type ReactNode } from 'react';
|
|
2
2
|
import { Dialog as DialogBase } from '@base-ui/react/dialog';
|
|
3
3
|
import { AlertDialog as AlertDialogBase } from '@base-ui/react/alert-dialog';
|
|
4
4
|
/** Dialog size variant definitions mapping sizes to their widths. */
|
|
5
5
|
export declare const EDS_DIALOG_VARIANTS: {
|
|
6
6
|
readonly size: {
|
|
7
7
|
readonly sm: {
|
|
8
|
-
readonly classes: "sm:w-
|
|
8
|
+
readonly classes: "sm:max-w-xs";
|
|
9
9
|
readonly description: "Small dialog for simple confirmations (288px)";
|
|
10
10
|
};
|
|
11
11
|
readonly md: {
|
|
12
|
-
readonly classes: "sm:w-
|
|
12
|
+
readonly classes: "sm:max-w-sm";
|
|
13
13
|
readonly description: "Default dialog width (384px)";
|
|
14
14
|
};
|
|
15
15
|
readonly lg: {
|
|
16
|
-
readonly classes: "sm:w-
|
|
16
|
+
readonly classes: "sm:max-w-lg";
|
|
17
17
|
readonly description: "Large dialog for complex content (512px)";
|
|
18
18
|
};
|
|
19
19
|
readonly xl: {
|
|
20
|
-
readonly classes: "sm:w-
|
|
20
|
+
readonly classes: "sm:max-w-3xl";
|
|
21
21
|
readonly description: "Extra large dialog for detailed views (768px)";
|
|
22
22
|
};
|
|
23
23
|
};
|
|
@@ -38,6 +38,7 @@ export interface EdsDialogVariantsProps {
|
|
|
38
38
|
*/
|
|
39
39
|
size?: DialogSize;
|
|
40
40
|
}
|
|
41
|
+
export declare function useDialogRole(): DialogRole;
|
|
41
42
|
/**
|
|
42
43
|
* Dialog content — the modal panel itself.
|
|
43
44
|
*
|
|
@@ -45,10 +46,14 @@ export interface EdsDialogVariantsProps {
|
|
|
45
46
|
* ```tsx
|
|
46
47
|
* <Dialog.Root>
|
|
47
48
|
* <Dialog.Trigger render={(p) => <Button {...p}>Abrir</Button>} />
|
|
48
|
-
* <Dialog
|
|
49
|
-
* <Dialog.
|
|
50
|
-
*
|
|
51
|
-
*
|
|
49
|
+
* <Dialog>
|
|
50
|
+
* <Dialog.Header>
|
|
51
|
+
* <Dialog.Title>Confirmar ação</Dialog.Title>
|
|
52
|
+
* <Dialog.Description>Tem certeza?</Dialog.Description>
|
|
53
|
+
* </Dialog.Header>
|
|
54
|
+
* <Dialog.Footer>
|
|
55
|
+
* <Dialog.Close render={(p) => <Button {...p}>Cancelar</Button>} />
|
|
56
|
+
* </Dialog.Footer>
|
|
52
57
|
* </Dialog>
|
|
53
58
|
* </Dialog.Root>
|
|
54
59
|
* ```
|
|
@@ -56,10 +61,12 @@ export interface EdsDialogVariantsProps {
|
|
|
56
61
|
export type DialogProps = EdsDialogVariantsProps & {
|
|
57
62
|
/** Classes CSS adicionais combinadas via `cn()`. */
|
|
58
63
|
className?: string;
|
|
59
|
-
/** Conteúdo do dialog (geralmente Title, Description
|
|
64
|
+
/** Conteúdo do dialog (geralmente Header, Footer, Title, Description e botões). */
|
|
60
65
|
children: ReactNode;
|
|
66
|
+
/** Exibe o botão de fechar (X) no canto superior direito. @default true */
|
|
67
|
+
showCloseButton?: boolean;
|
|
61
68
|
};
|
|
62
|
-
declare function DialogContent({ className, children, size }: DialogProps): import("react").JSX.Element;
|
|
69
|
+
declare function DialogContent({ className, children, size, showCloseButton, }: DialogProps): import("react").JSX.Element;
|
|
63
70
|
type BaseDialogRootProps = ComponentPropsWithoutRef<typeof DialogBase.Root>;
|
|
64
71
|
type BaseAlertDialogRootProps = ComponentPropsWithoutRef<typeof AlertDialogBase.Root>;
|
|
65
72
|
type StandardDialogRootProps = BaseDialogRootProps & {
|
|
@@ -91,6 +98,16 @@ declare function DialogTrigger({ children, ...props }: DialogTriggerProps): impo
|
|
|
91
98
|
declare namespace DialogTrigger {
|
|
92
99
|
var displayName: string;
|
|
93
100
|
}
|
|
101
|
+
export type DialogHeaderProps = HTMLAttributes<HTMLDivElement>;
|
|
102
|
+
declare function DialogHeader({ className, ...props }: DialogHeaderProps): import("react").JSX.Element;
|
|
103
|
+
declare namespace DialogHeader {
|
|
104
|
+
var displayName: string;
|
|
105
|
+
}
|
|
106
|
+
export type DialogFooterProps = HTMLAttributes<HTMLDivElement>;
|
|
107
|
+
declare function DialogFooter({ className, ...props }: DialogFooterProps): import("react").JSX.Element;
|
|
108
|
+
declare namespace DialogFooter {
|
|
109
|
+
var displayName: string;
|
|
110
|
+
}
|
|
94
111
|
export type DialogTitleProps = ComponentPropsWithoutRef<typeof DialogBase.Title>;
|
|
95
112
|
declare function DialogTitle({ className, ...props }: DialogTitleProps): import("react").JSX.Element;
|
|
96
113
|
declare namespace DialogTitle {
|
|
@@ -106,31 +123,24 @@ declare function DialogClose({ children, ...props }: DialogCloseProps): import("
|
|
|
106
123
|
declare namespace DialogClose {
|
|
107
124
|
var displayName: string;
|
|
108
125
|
}
|
|
126
|
+
export { DialogRoot, DialogTrigger, DialogClose, DialogHeader, DialogFooter, DialogTitle, DialogDescription, };
|
|
109
127
|
/**
|
|
110
128
|
* Modal dialog com backdrop. Compound component com `Dialog.Root`,
|
|
111
|
-
* `Dialog.Trigger`, `Dialog.
|
|
129
|
+
* `Dialog.Trigger`, `Dialog.Header`, `Dialog.Footer`, `Dialog.Title`,
|
|
130
|
+
* `Dialog.Description` e `Dialog.Close`.
|
|
112
131
|
*
|
|
113
132
|
* @example
|
|
114
133
|
* ```tsx
|
|
115
134
|
* <Dialog.Root>
|
|
116
135
|
* <Dialog.Trigger render={(p) => <Button {...p}>Excluir</Button>} />
|
|
117
136
|
* <Dialog>
|
|
118
|
-
* <Dialog.
|
|
119
|
-
*
|
|
120
|
-
*
|
|
121
|
-
*
|
|
122
|
-
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
125
|
-
* @example Alert dialog para ações destrutivas
|
|
126
|
-
* ```tsx
|
|
127
|
-
* <Dialog.Root role="alertdialog">
|
|
128
|
-
* <Dialog.Trigger render={(p) => <Button color="red-main" {...p}>Excluir projeto</Button>} />
|
|
129
|
-
* <Dialog>
|
|
130
|
-
* <Dialog.Title>Excluir projeto?</Dialog.Title>
|
|
131
|
-
* <Dialog.Description>Essa ação não pode ser desfeita.</Dialog.Description>
|
|
132
|
-
* <Dialog.Close render={(p) => <Button variant="outline" {...p}>Cancelar</Button>} />
|
|
133
|
-
* <Dialog.Close render={(p) => <Button color="red-main" {...p}>Excluir</Button>} />
|
|
137
|
+
* <Dialog.Header>
|
|
138
|
+
* <Dialog.Title>Excluir item</Dialog.Title>
|
|
139
|
+
* <Dialog.Description>Essa ação não pode ser desfeita.</Dialog.Description>
|
|
140
|
+
* </Dialog.Header>
|
|
141
|
+
* <Dialog.Footer>
|
|
142
|
+
* <Dialog.Close render={(p) => <Button variant="outline" {...p}>Cancelar</Button>} />
|
|
143
|
+
* </Dialog.Footer>
|
|
134
144
|
* </Dialog>
|
|
135
145
|
* </Dialog.Root>
|
|
136
146
|
* ```
|
|
@@ -138,9 +148,10 @@ declare namespace DialogClose {
|
|
|
138
148
|
export declare const Dialog: typeof DialogContent & {
|
|
139
149
|
Root: typeof DialogRoot;
|
|
140
150
|
Trigger: typeof DialogTrigger;
|
|
151
|
+
Header: typeof DialogHeader;
|
|
152
|
+
Footer: typeof DialogFooter;
|
|
141
153
|
Title: typeof DialogTitle;
|
|
142
154
|
Description: typeof DialogDescription;
|
|
143
155
|
Close: typeof DialogClose;
|
|
144
156
|
};
|
|
145
|
-
export {};
|
|
146
157
|
//# sourceMappingURL=Dialog.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dialog.d.ts","sourceRoot":"","sources":["../../../src/components/Dialog/Dialog.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGN,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAC7D,OAAO,EAAE,WAAW,IAAI,eAAe,EAAE,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"Dialog.d.ts","sourceRoot":"","sources":["../../../src/components/Dialog/Dialog.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGN,KAAK,wBAAwB,EAC7B,KAAK,cAAc,EACnB,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAC7D,OAAO,EAAE,WAAW,IAAI,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAK7E,qEAAqE;AACrE,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;CAmBtB,CAAC;AAEX,eAAO,MAAM,2BAA2B;;CAE9B,CAAC;AAEX,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,mBAAmB,CAAC,IAAI,CAAC;AAC/D,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,aAAa,CAAC;AAElD,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';
|
|
3
|
+
import { type LucideIcon } from 'lucide-react';
|
|
4
|
+
import { DialogClose, DialogRoot, DialogTrigger, type DialogCloseProps, type DialogRootProps, type DialogSize, type DialogTriggerProps, type EdsDialogVariantsProps } from '../Dialog/Dialog';
|
|
5
|
+
export type FormDialogProps = EdsDialogVariantsProps & {
|
|
6
|
+
/** Classes CSS adicionais combinadas via `cn()`. */
|
|
7
|
+
className?: string;
|
|
8
|
+
/** Conteúdo do dialog (Header, Body, Footer). */
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Dialog otimizado para formulários: header com ícone/título/subtítulo,
|
|
13
|
+
* corpo scrollável e footer destacado.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```tsx
|
|
17
|
+
* <FormDialog.Root>
|
|
18
|
+
* <FormDialog.Trigger render={(p) => <Button {...p} text="Abrir" />} />
|
|
19
|
+
* <FormDialog size="xl">
|
|
20
|
+
* <FormDialog.Header
|
|
21
|
+
* icon={Fuel}
|
|
22
|
+
* title="Abastecimento"
|
|
23
|
+
* subtitle="Criando Uma"
|
|
24
|
+
* />
|
|
25
|
+
* <FormDialog.Body>campos do formulário</FormDialog.Body>
|
|
26
|
+
* <FormDialog.Footer>
|
|
27
|
+
* <FormDialog.Close render={(p) => <Button variant="outline" {...p} text="Cancelar" />} />
|
|
28
|
+
* <Button text="Salvar" />
|
|
29
|
+
* </FormDialog.Footer>
|
|
30
|
+
* </FormDialog>
|
|
31
|
+
* </FormDialog.Root>
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
declare function FormDialogContent({ className, children, size, }: FormDialogProps): import("react").JSX.Element;
|
|
35
|
+
export type FormDialogHeaderProps = HTMLAttributes<HTMLDivElement> & {
|
|
36
|
+
/** Ícone exibido à esquerda do título/subtítulo. */
|
|
37
|
+
icon?: LucideIcon;
|
|
38
|
+
/** Título principal do formulário. */
|
|
39
|
+
title?: ReactNode;
|
|
40
|
+
/** Subtítulo / descrição curta abaixo do título. */
|
|
41
|
+
subtitle?: ReactNode;
|
|
42
|
+
/** Exibe o botão X no canto direito. @default true */
|
|
43
|
+
showCloseButton?: boolean;
|
|
44
|
+
};
|
|
45
|
+
declare function FormDialogHeader({ className, icon: Icon, title, subtitle, showCloseButton, children, ...props }: FormDialogHeaderProps): import("react").JSX.Element;
|
|
46
|
+
declare namespace FormDialogHeader {
|
|
47
|
+
var displayName: string;
|
|
48
|
+
}
|
|
49
|
+
export type FormDialogBodyProps = HTMLAttributes<HTMLDivElement>;
|
|
50
|
+
declare function FormDialogBody({ className, ...props }: FormDialogBodyProps): import("react").JSX.Element;
|
|
51
|
+
declare namespace FormDialogBody {
|
|
52
|
+
var displayName: string;
|
|
53
|
+
}
|
|
54
|
+
export type FormDialogFooterProps = HTMLAttributes<HTMLDivElement>;
|
|
55
|
+
declare function FormDialogFooter({ className, ...props }: FormDialogFooterProps): import("react").JSX.Element;
|
|
56
|
+
declare namespace FormDialogFooter {
|
|
57
|
+
var displayName: string;
|
|
58
|
+
}
|
|
59
|
+
export type FormDialogTitleProps = ComponentPropsWithoutRef<typeof DialogBase.Title>;
|
|
60
|
+
declare function FormDialogTitle({ className, ...props }: FormDialogTitleProps): import("react").JSX.Element;
|
|
61
|
+
declare namespace FormDialogTitle {
|
|
62
|
+
var displayName: string;
|
|
63
|
+
}
|
|
64
|
+
export type FormDialogDescriptionProps = ComponentPropsWithoutRef<typeof DialogBase.Description>;
|
|
65
|
+
declare function FormDialogDescription({ className, ...props }: FormDialogDescriptionProps): import("react").JSX.Element;
|
|
66
|
+
declare namespace FormDialogDescription {
|
|
67
|
+
var displayName: string;
|
|
68
|
+
}
|
|
69
|
+
export type FormDialogRootProps = DialogRootProps;
|
|
70
|
+
export type FormDialogTriggerProps = DialogTriggerProps;
|
|
71
|
+
export type FormDialogCloseProps = DialogCloseProps;
|
|
72
|
+
export type FormDialogSize = DialogSize;
|
|
73
|
+
export declare const FormDialog: typeof FormDialogContent & {
|
|
74
|
+
Root: typeof DialogRoot;
|
|
75
|
+
Trigger: typeof DialogTrigger;
|
|
76
|
+
Close: typeof DialogClose;
|
|
77
|
+
Header: typeof FormDialogHeader;
|
|
78
|
+
Body: typeof FormDialogBody;
|
|
79
|
+
Footer: typeof FormDialogFooter;
|
|
80
|
+
Title: typeof FormDialogTitle;
|
|
81
|
+
Description: typeof FormDialogDescription;
|
|
82
|
+
};
|
|
83
|
+
export {};
|
|
84
|
+
//# sourceMappingURL=FormDialog.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FormDialog.d.ts","sourceRoot":"","sources":["../../../src/components/FormDialog/FormDialog.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACX,wBAAwB,EACxB,cAAc,EACd,SAAS,EACT,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAE7D,OAAO,EAAK,KAAK,UAAU,EAAE,MAAM,cAAc,CAAC;AAGlD,OAAO,EACN,WAAW,EACX,UAAU,EACV,aAAa,EAIb,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,UAAU,EACf,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,EAC3B,MAAM,kBAAkB,CAAC;AAa1B,MAAM,MAAM,eAAe,GAAG,sBAAsB,GAAG;IACtD,oDAAoD;IACpD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iDAAiD;IACjD,QAAQ,EAAE,SAAS,CAAC;CACpB,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,iBAAS,iBAAiB,CAAC,EAC1B,SAAS,EACT,QAAQ,EACR,IAAW,GACX,EAAE,eAAe,+BAqBjB;AAED,MAAM,MAAM,qBAAqB,GAAG,cAAc,CAAC,cAAc,CAAC,GAAG;IACpE,oDAAoD;IACpD,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,sCAAsC;IACtC,KAAK,CAAC,EAAE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;CASrB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../../src/components/IconButton/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,KAAK,EAAE,cAAc,EAAiB,MAAM,OAAO,CAAC;AAC3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAS/D,MAAM,MAAM,iBAAiB,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,CAAC;AACvE,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAChD,MAAM,MAAM,eAAe,GAAG,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../../src/components/IconButton/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,KAAK,EAAE,cAAc,EAAiB,MAAM,OAAO,CAAC;AAC3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAS/D,MAAM,MAAM,iBAAiB,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,CAAC;AACvE,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAChD,MAAM,MAAM,eAAe,GAAG,gBAAgB,CAAC;AAe/C,MAAM,MAAM,eAAe,GAAG,IAAI,CACjC,cAAc,CAAC,OAAO,YAAY,CAAC,EACnC,WAAW,GAAG,UAAU,CACxB,GAAG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,8BAA8B;IAC9B,IAAI,EAAE,UAAU,CAAC;IACjB,yFAAyF;IACzF,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B,KAAK,CAAC,EAAE,eAAe,CAAC;IACxB,IAAI,CAAC,EAAE,cAAc,CAAC;CACtB,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,EAClC,IAAI,EAAE,IAAI,EACV,KAAK,EACL,SAAS,EACT,OAAiB,EACjB,KAAsB,EACtB,IAAW,EACX,QAAQ,EACR,KAAK,EACL,GAAG,KAAK,EACR,EAAE,eAAe,+BA8CjB"}
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
+
import { type LucideIcon } from 'lucide-react';
|
|
1
2
|
import { type ChangeEvent, type ComponentProps } from 'react';
|
|
3
|
+
import { type FieldLabelVariant } from '../../lib/field-styles';
|
|
2
4
|
export type InputState = 'default' | 'valid' | 'loading' | 'invalid';
|
|
3
5
|
export type InputFormat = 'cep' | 'cpf' | 'cnpj' | 'cpfOrCnpj' | 'phone';
|
|
4
6
|
export type InputSize = 'sm' | 'md' | 'lg';
|
|
7
|
+
/** @deprecated Use `FieldLabelVariant` from the shared field styles. */
|
|
8
|
+
export type InputLabelVariant = FieldLabelVariant;
|
|
5
9
|
export type InputProps = Omit<ComponentProps<'input'>, 'className' | 'type' | 'required' | 'onChange' | 'size'> & {
|
|
6
10
|
className?: string;
|
|
7
11
|
label?: string;
|
|
@@ -22,11 +26,24 @@ export type InputProps = Omit<ComponentProps<'input'>, 'className' | 'type' | 'r
|
|
|
22
26
|
supportLinkUrl?: string | null;
|
|
23
27
|
supportingText?: string;
|
|
24
28
|
lazy?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Posição do label.
|
|
31
|
+
* - `"floating"` — label flutuante na borda do campo (padrão)
|
|
32
|
+
* - `"outside"` — label acima do campo, fora da borda
|
|
33
|
+
* @default "floating"
|
|
34
|
+
*/
|
|
35
|
+
labelVariant?: InputLabelVariant;
|
|
36
|
+
/**
|
|
37
|
+
* @deprecated Use `labelVariant="floating" | "outside"` instead.
|
|
38
|
+
* Quando `false`, equivale a `labelVariant="outside"`.
|
|
39
|
+
*/
|
|
25
40
|
floatingLabel?: boolean;
|
|
26
41
|
disableAutocomplete?: boolean;
|
|
27
42
|
isLoading?: boolean;
|
|
28
43
|
loadingIconPosition?: 'start' | 'end';
|
|
44
|
+
/** Ícone decorativo exibido no início do campo (ex.: `Search` para um campo de busca). */
|
|
45
|
+
icon?: LucideIcon;
|
|
29
46
|
onChange?: (value: string, event: ChangeEvent<HTMLInputElement>) => void;
|
|
30
47
|
};
|
|
31
|
-
export default function Input({ className, label, disabled, state, size, inputType, required, placeholder, errorMessage, fluid, format, tooltip, linkText, linkUrl, supportLink, supportLinkUrl, supportingText, lazy, floatingLabel, disableAutocomplete, isLoading, loadingIconPosition, defaultValue, value, id, name, onBlur, onFocus, onKeyDown, onClick, onChange, ...props }: InputProps): import("react").JSX.Element;
|
|
48
|
+
export default function Input({ className, label, disabled, state, size, inputType, required, placeholder, errorMessage, fluid, format, tooltip, linkText, linkUrl, supportLink, supportLinkUrl, supportingText, lazy, labelVariant, floatingLabel, disableAutocomplete, isLoading, loadingIconPosition, icon: Icon, defaultValue, value, id, name, onBlur, onFocus, onKeyDown, onClick, onChange, ...props }: InputProps): import("react").JSX.Element;
|
|
32
49
|
//# sourceMappingURL=Input.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.d.ts","sourceRoot":"","sources":["../../../src/components/Input/Input.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Input.d.ts","sourceRoot":"","sources":["../../../src/components/Input/Input.tsx"],"names":[],"mappings":"AACA,OAAO,EAAiB,KAAK,UAAU,EAAE,MAAM,cAAc,CAAC;AAC9D,OAAO,EAAmB,KAAK,WAAW,EAAE,KAAK,cAAc,EAAE,MAAM,OAAO,CAAC;AAQ/E,OAAO,EASN,KAAK,iBAAiB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AY,CAAC,EAAE,iBAAiB,CAAC;IACjC;;;OAGG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,mBAAmB,CAAC,EAAE,OAAO,GAAG,KAAK,CAAC;IACtC,0FAA0F;IAC1F,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,WAAW,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;CACzE,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,KAAK,CAAC,EAC7B,SAAS,EACT,KAAe,EACf,QAAgB,EAChB,KAAiB,EACjB,IAAW,EACX,SAAkB,EAClB,QAAgB,EAChB,WAA8B,EAC9B,YAAkC,EAClC,KAAa,EACb,MAAM,EACN,OAAc,EACd,QAAe,EACf,OAAc,EACd,WAAkB,EAClB,cAAqB,EACrB,cAAmB,EACnB,IAAY,EACZ,YAAY,EACZ,aAAa,EACb,mBAA2B,EAC3B,SAAiB,EACjB,mBAA2B,EAC3B,IAAI,EAAE,IAAI,EACV,YAAY,EACZ,KAAK,EACL,EAAE,EACF,IAAI,EACJ,MAAM,EACN,OAAO,EACP,SAAS,EACT,OAAO,EACP,QAAQ,EACR,GAAG,KAAK,EACR,EAAE,UAAU,+BAwMZ"}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { type SelectRootChangeEventDetails } from '@base-ui/react/select';
|
|
2
2
|
import { type ReactNode } from 'react';
|
|
3
|
+
import { type FieldLabelVariant } from '../../lib/field-styles';
|
|
3
4
|
export type SelectState = 'default' | 'valid' | 'invalid';
|
|
4
5
|
export type SelectSize = 'sm' | 'md' | 'lg';
|
|
6
|
+
export type SelectLabelVariant = FieldLabelVariant;
|
|
5
7
|
export type SelectOption = {
|
|
6
8
|
label: string;
|
|
7
9
|
value: string;
|
|
@@ -9,7 +11,17 @@ export type SelectOption = {
|
|
|
9
11
|
export type SelectProps = {
|
|
10
12
|
/** Texto do label acima do campo. */
|
|
11
13
|
label?: string;
|
|
12
|
-
/**
|
|
14
|
+
/**
|
|
15
|
+
* Posição do label.
|
|
16
|
+
* - `"floating"` — label flutuante na borda do campo (padrão)
|
|
17
|
+
* - `"outside"` — label acima do campo, fora da borda
|
|
18
|
+
* @default "floating"
|
|
19
|
+
*/
|
|
20
|
+
labelVariant?: SelectLabelVariant;
|
|
21
|
+
/**
|
|
22
|
+
* @deprecated Use `labelVariant="floating" | "outside"` instead.
|
|
23
|
+
* Quando `false`, equivale a `labelVariant="outside"`.
|
|
24
|
+
*/
|
|
13
25
|
floatingLabel?: boolean;
|
|
14
26
|
/** Lista de itens disponíveis para seleção. */
|
|
15
27
|
items: readonly SelectOption[];
|
|
@@ -44,5 +56,5 @@ export type SelectProps = {
|
|
|
44
56
|
/** Classe CSS extra aplicada ao elemento raiz. */
|
|
45
57
|
className?: string;
|
|
46
58
|
};
|
|
47
|
-
export default function Select({ label, floatingLabel, items, placeholder, disabled, required, fluid, state, size, supportingText, errorMessage, id, name, value, defaultValue, onValueChange, renderItem, className, }: SelectProps): import("react").JSX.Element;
|
|
59
|
+
export default function Select({ label, labelVariant, floatingLabel, items, placeholder, disabled, required, fluid, state, size, supportingText, errorMessage, id, name, value, defaultValue, onValueChange, renderItem, className, }: SelectProps): import("react").JSX.Element;
|
|
48
60
|
//# sourceMappingURL=Select.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../src/components/Select/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,EAEN,KAAK,4BAA4B,EACjC,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAS,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../src/components/Select/Select.tsx"],"names":[],"mappings":"AAAA,OAA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K,CAAC,EAAE,YAAY,GAAG,IAAI,CAAC;IAC5B,0DAA0D;IAC1D,YAAY,CAAC,EAAE,YAAY,GAAG,IAAI,CAAC;IACnC,uDAAuD;IACvD,aAAa,CAAC,EAAE,CACf,KAAK,EAAE,YAAY,GAAG,IAAI,EAC1B,YAAY,EAAE,4BAA4B,KACtC,IAAI,CAAC;IACV,sDAAsD;IACtD,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,YAAY,KAAK,SAAS,CAAC;IAC/C,kDAAkD;IAClD,SAAS,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAC9B,KAAe,EACf,YAAY,EACZ,aAAa,EACb,KAAK,EACL,WAAmC,EACnC,QAAgB,EAChB,QAAgB,EAChB,KAAa,EACb,KAAiB,EACjB,IAAW,EACX,cAAmB,EACnB,YAA2C,EAC3C,EAAE,EACF,IAAI,EACJ,KAAiB,EACjB,YAAwB,EACxB,aAAyB,EACzB,UAAsB,EACtB,SAAS,GACT,EAAE,WAAW,+BAuIb"}
|
package/dist/index.d.ts
CHANGED
|
@@ -6,22 +6,28 @@ export { default as Calendar } from './components/Calendar/Calendar';
|
|
|
6
6
|
export type { CalendarProps, CalendarEvent, } from './components/Calendar/Calendar';
|
|
7
7
|
export { Card } from './components/Card/Card';
|
|
8
8
|
export type { CardProps, CardHeaderProps, CardTitleProps, CardDescriptionProps, CardActionProps, CardContentProps, CardFooterProps, } from './components/Card/Card';
|
|
9
|
+
export { Attachment } from './components/Attachment/Attachment';
|
|
10
|
+
export type { AttachmentProps, AttachmentMediaProps, AttachmentContentProps, AttachmentTitleProps, AttachmentDescriptionProps, AttachmentActionsProps, AttachmentActionProps, AttachmentTriggerProps, AttachmentGroupProps, AttachmentState, AttachmentSize, AttachmentOrientation, AttachmentMediaVariant, } from './components/Attachment/Attachment';
|
|
11
|
+
export { AttachmentGroup, AttachmentMedia, AttachmentContent, AttachmentTitle, AttachmentDescription, AttachmentActions, AttachmentAction, AttachmentTrigger, } from './components/Attachment/Attachment';
|
|
9
12
|
export { default as Checkbox } from './components/Checkbox/Checkbox';
|
|
10
13
|
export type { CheckboxProps } from './components/Checkbox/Checkbox';
|
|
11
14
|
export { default as Combobox } from './components/ComboBox/Combobox';
|
|
12
15
|
export type { ComboboxProps, ComboboxOption, ComboboxState, } from './components/ComboBox/Combobox';
|
|
13
16
|
export { default as DatePicker } from './components/DatePicker/DatePicker';
|
|
14
|
-
export type { DatePickerProps, DatePickerSingleProps, DatePickerRangeProps, DatePickerState, DatePickerSize, DatePickerMode, DatePickerPreset, DateRange, } from './components/DatePicker/DatePicker';
|
|
17
|
+
export type { DatePickerProps, DatePickerSingleProps, DatePickerRangeProps, DatePickerState, DatePickerSize, DatePickerMode, DatePickerPreset, DatePickerLabelVariant, DateRange, } from './components/DatePicker/DatePicker';
|
|
15
18
|
export { Dialog } from './components/Dialog/Dialog';
|
|
16
|
-
export type { DialogProps, DialogRootProps, DialogTriggerProps, DialogTitleProps, DialogDescriptionProps, DialogCloseProps, DialogSize, DialogRole, } from './components/Dialog/Dialog';
|
|
19
|
+
export type { DialogProps, DialogRootProps, DialogTriggerProps, DialogHeaderProps, DialogFooterProps, DialogTitleProps, DialogDescriptionProps, DialogCloseProps, DialogSize, DialogRole, } from './components/Dialog/Dialog';
|
|
20
|
+
export { FormDialog } from './components/FormDialog/FormDialog';
|
|
21
|
+
export type { FormDialogProps, FormDialogRootProps, FormDialogTriggerProps, FormDialogHeaderProps, FormDialogBodyProps, FormDialogFooterProps, FormDialogTitleProps, FormDialogDescriptionProps, FormDialogCloseProps, FormDialogSize, } from './components/FormDialog/FormDialog';
|
|
17
22
|
export { Empty } from './components/Empty/Empty';
|
|
18
23
|
export type { EmptyProps, EmptySize } from './components/Empty/Empty';
|
|
19
24
|
export { default as IconButton } from './components/IconButton/IconButton';
|
|
20
25
|
export type { IconButtonProps, IconButtonVariant, IconButtonSize, IconButtonColor, } from './components/IconButton/IconButton';
|
|
21
26
|
export { default as Input } from './components/Input/Input';
|
|
22
|
-
export type { InputProps } from './components/Input/Input';
|
|
27
|
+
export type { InputProps, InputLabelVariant, InputSize, InputState, InputFormat, } from './components/Input/Input';
|
|
23
28
|
export { default as Select } from './components/Select/Select';
|
|
24
|
-
export type { SelectProps, SelectOption, SelectState, SelectSize, } from './components/Select/Select';
|
|
29
|
+
export type { SelectProps, SelectOption, SelectState, SelectSize, SelectLabelVariant, } from './components/Select/Select';
|
|
30
|
+
export type { FieldLabelVariant } from './lib/field-styles';
|
|
25
31
|
export { Text } from './components/Text/Text';
|
|
26
32
|
export type { TextProps, TextVariant, TextSize, TextElement, } from './components/Text/Text';
|
|
27
33
|
export { Table } from './components/Table/Table';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC5C,YAAY,EACX,WAAW,EACX,WAAW,EACX,kBAAkB,EAClB,UAAU,EACV,aAAa,GACb,MAAM,4BAA4B,CAAC;AACpC,YAAY,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE3D,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AACrE,YAAY,EACX,aAAa,EACb,aAAa,GACb,MAAM,gCAAgC,CAAC;AAExC,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAC9C,YAAY,EACX,SAAS,EACT,eAAe,EACf,cAAc,EACd,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,eAAe,GACf,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AACrE,YAAY,EAAE,aAAa,EAAE,MAAM,g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