@producteca/producteca-ui-kit 1.23.0 → 1.24.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/menuAction/index.d.ts +1 -1
- package/dist/components/menuAction/menuAction.d.ts +4 -3
- package/dist/locales/description.d.ts +1 -0
- package/dist/locales/es.d.ts +9 -0
- package/dist/producteca-ui-kit.es.js +4377 -4352
- package/dist/producteca-ui-kit.umd.js +140 -127
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
export { MenuAction, type MenuActionProps, type
|
|
1
|
+
export { MenuAction, type MenuActionProps, type MenuActionItemProps } from './menuAction';
|
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
|
|
3
|
-
interface
|
|
3
|
+
interface MenuActionItemProps {
|
|
4
4
|
label: React.ReactNode;
|
|
5
|
+
icon?: React.ReactElement;
|
|
5
6
|
onClick?: () => void;
|
|
6
7
|
selected?: boolean;
|
|
7
8
|
disabled?: boolean;
|
|
8
9
|
}
|
|
9
10
|
interface MenuActionProps {
|
|
10
|
-
items:
|
|
11
|
+
items: MenuActionItemProps[];
|
|
11
12
|
id?: string;
|
|
12
13
|
maxItemsVisible?: number;
|
|
13
14
|
icon?: React.ReactNode;
|
|
14
15
|
otherProps?: React.HTMLAttributes<HTMLButtonElement>;
|
|
15
16
|
}
|
|
16
17
|
export declare const MenuAction: React.FC<MenuActionProps>;
|
|
17
|
-
export type { MenuActionProps,
|
|
18
|
+
export type { MenuActionProps, MenuActionItemProps };
|
|
18
19
|
export default MenuAction;
|
|
@@ -13,3 +13,4 @@ export declare const searcherExample = " \n Note la diferencia entre onChange
|
|
|
13
13
|
export declare const saveBarExample = "\n #### Uso b\u00E1sico\n ```typescript\n <SaveBar\n saveProps={{\n onSave: () => handleSave(),\n label: 'Save'\n }}\n cancelProps={{\n onCancel: () => handleCancel(),\n label: 'Cancel'\n }}\n />\n ```\n #### Con bot\u00F3n de navegaci\u00F3n\n ```typescript\n <SaveBar\n saveProps={{\n onSave: () => handleSave(),\n label: 'Save',\n variant: 'primary'\n }}\n cancelProps={{\n onCancel: () => handleCancel(),\n label: 'Cancel'\n }}\n previousProps={{\n onPrevious: () => handlePrevious(),\n label: 'Previous'\n }}\n />\n ```\n #### Ejemplo completo\n ```typescript\n <SaveBar\n saveProps={{\n onSave: () => handleSave(),\n label: 'Guardar cambios',\n variant: 'success',\n disabled: false,\n onClick: () => {},\n }}\n cancelProps={{\n onCancel: () => handleCancel(),\n label: 'Descartar',\n }}\n previousProps={{\n onPrevious: () => handlePrevious(),\n label: 'Anterior',\n variant: 'primary',\n outline: true,\n disabled: false,\n onClick: () => console.log('Previous clicked'),\n }}\n />\n ```\n";
|
|
14
14
|
export declare const checkboxInputReduxFormExample = "\n #### Ejemplo de uso con Redux Form - CheckboxInput\n \n ```typescript\n <Field\n name=\"salesSync\"\n component={CheckboxInput}\n classComponent={'decrease-stock'}\n props={{\n name: 'cancelSales',\n value: this.salesSync().cancelSales,\n checked: this.salesSync().cancelSales,\n label: this.context.localize('settings.cancelSales')\n }}\n />\n ```\n";
|
|
15
15
|
export declare const breadcrumbItemFormat = "\n ## Formato de BreadcrumbItem\n\n El componente Breadcrumb acepta un array de objetos `BreadcrumbItem` con las siguientes propiedades:\n\n ### Propiedades disponibles:\n\n - **`text`** (string, requerido): El texto que se muestra para el item del breadcrumb\n - **`onClick`** (function, opcional): Funci\u00F3n que se ejecuta al hacer click en el item\n - **`isActive`** (boolean, opcional): Indica si el item est\u00E1 activo. Por defecto, el \u00FAltimo item se considera activo\n - **`href`** (string, opcional): URL del enlace (actualmente no implementado en el renderizado)\n\n ### Comportamiento:\n\n - Los items con `onClick` se renderizan como botones clickeables\n - Los items sin `onClick` se renderizan como texto est\u00E1tico\n - El \u00FAltimo item siempre se considera activo (a menos que se especifique `isActive: true` en otro item)\n - Cada item se separa autom\u00E1ticamente con el s\u00EDmbolo \">\"\n\n ### Ejemplo de uso:\n\n ```tsx\n const breadcrumbItems = [\n { text: 'Dashboard' },\n { text: 'Productos', onClick: () => navigate('/products') },\n { text: 'Detalles', isActive: true }\n ]\n\n <Breadcrumb items={breadcrumbItems} />\n ```\n";
|
|
16
|
+
export declare const menuItems = "Lista de \u00EDtems que se mostrar\u00E1n en el men\u00FA.\n \n**Tipo:** `MenuActionItem[]`\n\n```ts\ninterface MenuActionItem {\n label: React.ReactNode\n icon?: React.ReactElement\n onClick?: () => void\n selected?: boolean\n disabled?: boolean\n}\n```\n";
|
package/dist/locales/es.d.ts
CHANGED
|
@@ -224,6 +224,15 @@ declare const _default: {
|
|
|
224
224
|
tab2: string;
|
|
225
225
|
tab3: string;
|
|
226
226
|
};
|
|
227
|
+
menuAction: {
|
|
228
|
+
edit: string;
|
|
229
|
+
delete: string;
|
|
230
|
+
duplicate: string;
|
|
231
|
+
itemsDescription: string;
|
|
232
|
+
id: string;
|
|
233
|
+
maxItems: string;
|
|
234
|
+
icon: string;
|
|
235
|
+
};
|
|
227
236
|
sidebar: {
|
|
228
237
|
monitoringCenter: string;
|
|
229
238
|
history: string;
|