@octavius2929-personal/design-system 0.12.0 → 0.13.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/index.cjs +485 -386
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +26 -1
- package/dist/index.d.ts +26 -1
- package/dist/index.js +363 -266
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -856,6 +856,8 @@ interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
856
856
|
startIcon?: Icon;
|
|
857
857
|
endIcon?: Icon;
|
|
858
858
|
full?: boolean;
|
|
859
|
+
/** Segmento de contexto para el data-testid (no es un override del id completo). */
|
|
860
|
+
testId?: string;
|
|
859
861
|
}
|
|
860
862
|
|
|
861
863
|
declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
@@ -940,6 +942,8 @@ interface TextFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "on
|
|
|
940
942
|
multiline?: boolean;
|
|
941
943
|
rows?: number;
|
|
942
944
|
onChange?: (value: string) => void;
|
|
945
|
+
/** Segmento de contexto para el data-testid. */
|
|
946
|
+
testId?: string;
|
|
943
947
|
}
|
|
944
948
|
|
|
945
949
|
declare const TextField: react.ForwardRefExoticComponent<TextFieldProps & react.RefAttributes<HTMLInputElement>>;
|
|
@@ -979,6 +983,8 @@ interface IconButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>,
|
|
|
979
983
|
active?: boolean;
|
|
980
984
|
tone?: IconButtonTone;
|
|
981
985
|
title: string;
|
|
986
|
+
/** Segmento de contexto para el data-testid. */
|
|
987
|
+
testId?: string;
|
|
982
988
|
}
|
|
983
989
|
|
|
984
990
|
declare const IconButton: react.ForwardRefExoticComponent<IconButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
@@ -1381,6 +1387,8 @@ interface MenuItemDef {
|
|
|
1381
1387
|
interface MenuProps {
|
|
1382
1388
|
trigger: ReactElement;
|
|
1383
1389
|
items: MenuItemDef[];
|
|
1390
|
+
/** Segmento de contexto para el data-testid. */
|
|
1391
|
+
testId?: string;
|
|
1384
1392
|
}
|
|
1385
1393
|
|
|
1386
1394
|
declare const Menu: react.ForwardRefExoticComponent<MenuProps & react.RefAttributes<HTMLDivElement>>;
|
|
@@ -1391,6 +1399,8 @@ interface DialogProps {
|
|
|
1391
1399
|
title?: ReactNode;
|
|
1392
1400
|
actions?: ReactNode;
|
|
1393
1401
|
children?: ReactNode;
|
|
1402
|
+
/** Segmento de contexto para el data-testid. */
|
|
1403
|
+
testId?: string;
|
|
1394
1404
|
}
|
|
1395
1405
|
|
|
1396
1406
|
declare const Dialog: react.ForwardRefExoticComponent<DialogProps & react.RefAttributes<HTMLDivElement>>;
|
|
@@ -1499,4 +1509,19 @@ interface ThemeProviderProps {
|
|
|
1499
1509
|
declare function ThemeProvider({ children, defaultSchema, defaultMode, storageKey, persist, }: ThemeProviderProps): react.JSX.Element;
|
|
1500
1510
|
declare function useTheme(): ThemeContextValue;
|
|
1501
1511
|
|
|
1502
|
-
|
|
1512
|
+
interface TestIdProviderProps {
|
|
1513
|
+
/** Segmento de contexto que este provider agrega a la cadena (ej. "checkout"). */
|
|
1514
|
+
context: string;
|
|
1515
|
+
children: ReactNode;
|
|
1516
|
+
}
|
|
1517
|
+
declare function TestIdProvider({ context, children }: TestIdProviderProps): react.JSX.Element;
|
|
1518
|
+
|
|
1519
|
+
interface TestIdHandle {
|
|
1520
|
+
/** data-testid del nodo root: `<tipo>__<...contexto>__<ownTestId>`. */
|
|
1521
|
+
testId: string;
|
|
1522
|
+
/** Deriva el id de un slot interno: `<testId>__<slot>`. */
|
|
1523
|
+
slot: (name: string) => string;
|
|
1524
|
+
}
|
|
1525
|
+
declare function useTestId(type: string, ownTestId?: string): TestIdHandle;
|
|
1526
|
+
|
|
1527
|
+
export { Accordion, type AccordionItem, type AccordionProps, Alert, type AlertProps, type AlertSeverity, AppBar, type AppBarProps, Avatar, type AvatarProps, type AvatarSize, Badge, type BadgeProps, type BadgeTone, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, type ButtonSize, type ButtonTone, type ButtonVariant, Card, type CardProps, type CardSectionProps, CheckIcon, Checkbox, type CheckboxProps, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, Chip, type ChipProps, type ChipTone, CircleCheckIcon, CircleXIcon, type ColorTokens, Container, type ContainerProps, type Crumb, Dialog, type DialogProps, Divider, type DividerProps, EyeIcon, EyeOffIcon, type Icon, IconButton, type IconButtonProps, type IconButtonTone, type IconProps, InfoIcon, ListItem, type ListItemProps, Menu, type MenuItemDef, type MenuProps, MinusIcon, type Mode, type ModePreference, MoneyField, type MoneyFieldProps, MoreHorizontalIcon, Pagination, type PaginationProps, PasswordField, type PasswordFieldProps, PlusIcon, Progress, type ProgressProps, type ProgressVariant, Radio, type RadioProps, type SchemaName, SearchIcon, Select, type SelectOption, type SelectProps, Slider, type SliderProps, Snackbar, type SnackbarProps, type Step, Stepper, type StepperProps, Switch, type SwitchProps, type TabItem, Table, type TableColumn, type TableProps, Tabs, type TabsProps, type TestIdHandle, TestIdProvider, type TestIdProviderProps, TextField, type TextFieldProps, ThemeProvider, type ThemeProviderProps, Tooltip, type TooltipPlacement, type TooltipProps, TriangleAlertIcon, Typography, type TypographyAlign, type TypographyColor, type TypographyProps, type TypographyVariant, XIcon, colorVars, modeNames, schemaNames, text, vars as theme, themes, usePrevious, useTestId, useTheme, useToggle };
|
package/dist/index.d.ts
CHANGED
|
@@ -856,6 +856,8 @@ interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
856
856
|
startIcon?: Icon;
|
|
857
857
|
endIcon?: Icon;
|
|
858
858
|
full?: boolean;
|
|
859
|
+
/** Segmento de contexto para el data-testid (no es un override del id completo). */
|
|
860
|
+
testId?: string;
|
|
859
861
|
}
|
|
860
862
|
|
|
861
863
|
declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
@@ -940,6 +942,8 @@ interface TextFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "on
|
|
|
940
942
|
multiline?: boolean;
|
|
941
943
|
rows?: number;
|
|
942
944
|
onChange?: (value: string) => void;
|
|
945
|
+
/** Segmento de contexto para el data-testid. */
|
|
946
|
+
testId?: string;
|
|
943
947
|
}
|
|
944
948
|
|
|
945
949
|
declare const TextField: react.ForwardRefExoticComponent<TextFieldProps & react.RefAttributes<HTMLInputElement>>;
|
|
@@ -979,6 +983,8 @@ interface IconButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>,
|
|
|
979
983
|
active?: boolean;
|
|
980
984
|
tone?: IconButtonTone;
|
|
981
985
|
title: string;
|
|
986
|
+
/** Segmento de contexto para el data-testid. */
|
|
987
|
+
testId?: string;
|
|
982
988
|
}
|
|
983
989
|
|
|
984
990
|
declare const IconButton: react.ForwardRefExoticComponent<IconButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
@@ -1381,6 +1387,8 @@ interface MenuItemDef {
|
|
|
1381
1387
|
interface MenuProps {
|
|
1382
1388
|
trigger: ReactElement;
|
|
1383
1389
|
items: MenuItemDef[];
|
|
1390
|
+
/** Segmento de contexto para el data-testid. */
|
|
1391
|
+
testId?: string;
|
|
1384
1392
|
}
|
|
1385
1393
|
|
|
1386
1394
|
declare const Menu: react.ForwardRefExoticComponent<MenuProps & react.RefAttributes<HTMLDivElement>>;
|
|
@@ -1391,6 +1399,8 @@ interface DialogProps {
|
|
|
1391
1399
|
title?: ReactNode;
|
|
1392
1400
|
actions?: ReactNode;
|
|
1393
1401
|
children?: ReactNode;
|
|
1402
|
+
/** Segmento de contexto para el data-testid. */
|
|
1403
|
+
testId?: string;
|
|
1394
1404
|
}
|
|
1395
1405
|
|
|
1396
1406
|
declare const Dialog: react.ForwardRefExoticComponent<DialogProps & react.RefAttributes<HTMLDivElement>>;
|
|
@@ -1499,4 +1509,19 @@ interface ThemeProviderProps {
|
|
|
1499
1509
|
declare function ThemeProvider({ children, defaultSchema, defaultMode, storageKey, persist, }: ThemeProviderProps): react.JSX.Element;
|
|
1500
1510
|
declare function useTheme(): ThemeContextValue;
|
|
1501
1511
|
|
|
1502
|
-
|
|
1512
|
+
interface TestIdProviderProps {
|
|
1513
|
+
/** Segmento de contexto que este provider agrega a la cadena (ej. "checkout"). */
|
|
1514
|
+
context: string;
|
|
1515
|
+
children: ReactNode;
|
|
1516
|
+
}
|
|
1517
|
+
declare function TestIdProvider({ context, children }: TestIdProviderProps): react.JSX.Element;
|
|
1518
|
+
|
|
1519
|
+
interface TestIdHandle {
|
|
1520
|
+
/** data-testid del nodo root: `<tipo>__<...contexto>__<ownTestId>`. */
|
|
1521
|
+
testId: string;
|
|
1522
|
+
/** Deriva el id de un slot interno: `<testId>__<slot>`. */
|
|
1523
|
+
slot: (name: string) => string;
|
|
1524
|
+
}
|
|
1525
|
+
declare function useTestId(type: string, ownTestId?: string): TestIdHandle;
|
|
1526
|
+
|
|
1527
|
+
export { Accordion, type AccordionItem, type AccordionProps, Alert, type AlertProps, type AlertSeverity, AppBar, type AppBarProps, Avatar, type AvatarProps, type AvatarSize, Badge, type BadgeProps, type BadgeTone, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, type ButtonSize, type ButtonTone, type ButtonVariant, Card, type CardProps, type CardSectionProps, CheckIcon, Checkbox, type CheckboxProps, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, Chip, type ChipProps, type ChipTone, CircleCheckIcon, CircleXIcon, type ColorTokens, Container, type ContainerProps, type Crumb, Dialog, type DialogProps, Divider, type DividerProps, EyeIcon, EyeOffIcon, type Icon, IconButton, type IconButtonProps, type IconButtonTone, type IconProps, InfoIcon, ListItem, type ListItemProps, Menu, type MenuItemDef, type MenuProps, MinusIcon, type Mode, type ModePreference, MoneyField, type MoneyFieldProps, MoreHorizontalIcon, Pagination, type PaginationProps, PasswordField, type PasswordFieldProps, PlusIcon, Progress, type ProgressProps, type ProgressVariant, Radio, type RadioProps, type SchemaName, SearchIcon, Select, type SelectOption, type SelectProps, Slider, type SliderProps, Snackbar, type SnackbarProps, type Step, Stepper, type StepperProps, Switch, type SwitchProps, type TabItem, Table, type TableColumn, type TableProps, Tabs, type TabsProps, type TestIdHandle, TestIdProvider, type TestIdProviderProps, TextField, type TextFieldProps, ThemeProvider, type ThemeProviderProps, Tooltip, type TooltipPlacement, type TooltipProps, TriangleAlertIcon, Typography, type TypographyAlign, type TypographyColor, type TypographyProps, type TypographyVariant, XIcon, colorVars, modeNames, schemaNames, text, vars as theme, themes, usePrevious, useTestId, useTheme, useToggle };
|