@onpe/ui 1.0.50 → 1.0.52

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 (36) hide show
  1. package/dist/cli.esm.js +12 -8
  2. package/dist/cli.js +12 -8
  3. package/dist/icons/Actions/IconCheck/IconCheck.d.ts +0 -1
  4. package/dist/icons/Actions/IconCheck/index.d.ts +0 -1
  5. package/dist/icons/Actions/IconClose/IconClose.d.ts +0 -1
  6. package/dist/icons/Actions/IconClose/index.d.ts +0 -1
  7. package/dist/icons/Actions/IconHome/IconHome.d.ts +0 -1
  8. package/dist/icons/Actions/IconHome/index.d.ts +1 -2
  9. package/dist/icons/Actions/IconSpinnerDesktop/IconSpinnerDesktop.d.ts +0 -1
  10. package/dist/icons/Actions/IconSpinnerDesktop/index.d.ts +0 -1
  11. package/dist/icons/Actions/IconSpinnerMobile/IconSpinnerMobile.d.ts +0 -1
  12. package/dist/icons/Actions/IconSpinnerMobile/index.d.ts +0 -1
  13. package/dist/icons/Actions/IconWarning/IconWarning.d.ts +0 -1
  14. package/dist/icons/Actions/IconWarning/index.d.ts +0 -1
  15. package/dist/icons/Browsers/IconChrome/IconChrome.d.ts +0 -1
  16. package/dist/icons/Browsers/IconChromeColor/IconChromeColor.d.ts +0 -1
  17. package/dist/icons/Browsers/IconChromeColor/index.d.ts +0 -1
  18. package/dist/icons/Browsers/IconEdge/IconEdge.d.ts +0 -1
  19. package/dist/icons/Browsers/IconEdgeColor/IconEdgeColor.d.ts +0 -1
  20. package/dist/icons/Browsers/IconEdgeColor/index.d.ts +0 -1
  21. package/dist/icons/Browsers/IconMozilla/IconMozilla.d.ts +0 -1
  22. package/dist/icons/Browsers/IconMozillaColor/IconMozillaColor.d.ts +0 -1
  23. package/dist/icons/Browsers/IconMozillaColor/index.d.ts +0 -1
  24. package/dist/icons/Browsers/IconSafari/IconSafari.d.ts +0 -1
  25. package/dist/icons/Browsers/IconSafariColor/IconSafariColor.d.ts +0 -1
  26. package/dist/icons/Browsers/IconSafariColor/index.d.ts +0 -1
  27. package/dist/icons/ONPE/ElectionsIcon/ElectionsIcon.d.ts +0 -1
  28. package/dist/icons/ONPE/IconElectionsGeneral/IconElectionsGeneral.d.ts +0 -1
  29. package/dist/icons/ONPE/IconVotoDigital/IconVotoDigital.d.ts +0 -1
  30. package/dist/icons/OperatingSystems/IconAndroid/IconAndroid.d.ts +0 -1
  31. package/dist/icons/OperatingSystems/IconAndroid/index.d.ts +0 -1
  32. package/dist/icons/OperatingSystems/IconApple/IconApple.d.ts +0 -1
  33. package/dist/icons/OperatingSystems/IconApple/index.d.ts +0 -1
  34. package/dist/icons/OperatingSystems/IconWindow/IconWindow.d.ts +0 -1
  35. package/dist/icons/OperatingSystems/IconWindow/index.d.ts +0 -1
  36. package/package.json +1 -1
package/dist/cli.esm.js CHANGED
@@ -5865,22 +5865,22 @@ var COMPONENTS_URL = "https://raw.githubusercontent.com/ricardosv46/onpe-ui/main
5865
5865
  var ICONS_URL = "https://raw.githubusercontent.com/ricardosv46/onpe-ui/main/src/icons";
5866
5866
  function addComponent(componentName) {
5867
5867
  return __awaiter(this, void 0, void 0, function () {
5868
- var isIcon, isModal, componentPath, componentDependencies, availableComponents, availableIcons, componentFile, availableItems, dependencies, _i, dependencies_1, dependency, depError_1, downloadUrl, response, componentCode, personalizedCode, fileName, filePath, componentNamePascal, importPath, dependencies, error_1;
5868
+ var isIcon, isModalComponent, componentPath, componentDependencies, availableComponents, availableIcons, componentFile, availableItems, dependencies, _i, dependencies_1, dependency, depError_1, downloadUrl, response, componentCode, personalizedCode, fileName, filePath, componentNamePascal, importPath, dependencies, error_1;
5869
5869
  return __generator(this, function (_a) {
5870
5870
  switch (_a.label) {
5871
5871
  case 0:
5872
5872
  isIcon = componentName.toLowerCase().startsWith("icon-");
5873
- isModal = componentName.toLowerCase().startsWith("modal");
5873
+ isModalComponent = componentName.toLowerCase().startsWith("modal") && componentName !== "modal";
5874
5874
  if (isIcon) {
5875
5875
  // Los iconos van en src/components/onpe-icons/
5876
5876
  componentPath = require$$1.join(process.cwd(), "src", "components", "onpe-icons");
5877
5877
  }
5878
- else if (isModal) {
5879
- // Los modales van en src/components/onpe-modals/
5878
+ else if (isModalComponent) {
5879
+ // Los modales específicos van en src/components/onpe-modals/
5880
5880
  componentPath = require$$1.join(process.cwd(), "src", "components", "onpe-modals");
5881
5881
  }
5882
5882
  else {
5883
- // Los componentes básicos van en src/components/onpe-ui/
5883
+ // Los componentes básicos (incluyendo Modal base) van en src/components/onpe-ui/
5884
5884
  componentPath = require$$1.join(process.cwd(), "src", "components", "onpe-ui");
5885
5885
  }
5886
5886
  // Crear directorio si no existe
@@ -5988,7 +5988,7 @@ function addComponent(componentName) {
5988
5988
  }
5989
5989
  else {
5990
5990
  // Los componentes van en onpe-modals o onpe-ui
5991
- if (componentName.toLowerCase().includes("modal")) {
5991
+ if (componentName.toLowerCase().startsWith("modal") && componentName !== "modal") {
5992
5992
  importPath = "../onpe-modals/".concat(componentNamePascal);
5993
5993
  }
5994
5994
  else {
@@ -6006,7 +6006,7 @@ function addComponent(componentName) {
6006
6006
  if (dep.startsWith("icon-")) {
6007
6007
  depPath = "../onpe-icons/".concat(depPascal);
6008
6008
  }
6009
- else if (dep.startsWith("modal")) {
6009
+ else if (dep.startsWith("modal") && dep !== "modal") {
6010
6010
  depPath = "../onpe-modals/".concat(depPascal);
6011
6011
  }
6012
6012
  else {
@@ -6047,7 +6047,7 @@ function personalizeComponent(code, componentName) {
6047
6047
  Portal: "../onpe-ui/Portal",
6048
6048
  Show: "../onpe-ui/Show",
6049
6049
  // Modales
6050
- Modal: "../onpe-modals/Modal",
6050
+ Modal: "../onpe-ui/Modal", // Modal base va en onpe-ui
6051
6051
  ModalConfirm: "../onpe-modals/ModalConfirm",
6052
6052
  ModalLoading: "../onpe-modals/ModalLoading",
6053
6053
  ModalBrowserIncompatible: "../onpe-modals/ModalBrowserIncompatible",
@@ -6103,6 +6103,10 @@ function personalizeComponent(code, componentName) {
6103
6103
  personalizedCode = personalizedCode.replace(pattern, "from \"".concat(newPath, "\""));
6104
6104
  });
6105
6105
  });
6106
+ // Agregar export default si no existe
6107
+ if (!personalizedCode.includes("export default")) {
6108
+ personalizedCode += "\n\nexport default ".concat(componentNamePascal, ";");
6109
+ }
6106
6110
  var finalCode = "// Componente ".concat(componentNamePascal, " copiado y ajustado para la nueva estructura\n// Las rutas de importaci\u00F3n han sido actualizadas autom\u00E1ticamente\n\n").concat(personalizedCode);
6107
6111
  return finalCode;
6108
6112
  }
package/dist/cli.js CHANGED
@@ -5865,22 +5865,22 @@ var COMPONENTS_URL = "https://raw.githubusercontent.com/ricardosv46/onpe-ui/main
5865
5865
  var ICONS_URL = "https://raw.githubusercontent.com/ricardosv46/onpe-ui/main/src/icons";
5866
5866
  function addComponent(componentName) {
5867
5867
  return __awaiter(this, void 0, void 0, function () {
5868
- var isIcon, isModal, componentPath, componentDependencies, availableComponents, availableIcons, componentFile, availableItems, dependencies, _i, dependencies_1, dependency, depError_1, downloadUrl, response, componentCode, personalizedCode, fileName, filePath, componentNamePascal, importPath, dependencies, error_1;
5868
+ var isIcon, isModalComponent, componentPath, componentDependencies, availableComponents, availableIcons, componentFile, availableItems, dependencies, _i, dependencies_1, dependency, depError_1, downloadUrl, response, componentCode, personalizedCode, fileName, filePath, componentNamePascal, importPath, dependencies, error_1;
5869
5869
  return __generator(this, function (_a) {
5870
5870
  switch (_a.label) {
5871
5871
  case 0:
5872
5872
  isIcon = componentName.toLowerCase().startsWith("icon-");
5873
- isModal = componentName.toLowerCase().startsWith("modal");
5873
+ isModalComponent = componentName.toLowerCase().startsWith("modal") && componentName !== "modal";
5874
5874
  if (isIcon) {
5875
5875
  // Los iconos van en src/components/onpe-icons/
5876
5876
  componentPath = require$$1.join(process.cwd(), "src", "components", "onpe-icons");
5877
5877
  }
5878
- else if (isModal) {
5879
- // Los modales van en src/components/onpe-modals/
5878
+ else if (isModalComponent) {
5879
+ // Los modales específicos van en src/components/onpe-modals/
5880
5880
  componentPath = require$$1.join(process.cwd(), "src", "components", "onpe-modals");
5881
5881
  }
5882
5882
  else {
5883
- // Los componentes básicos van en src/components/onpe-ui/
5883
+ // Los componentes básicos (incluyendo Modal base) van en src/components/onpe-ui/
5884
5884
  componentPath = require$$1.join(process.cwd(), "src", "components", "onpe-ui");
5885
5885
  }
5886
5886
  // Crear directorio si no existe
@@ -5988,7 +5988,7 @@ function addComponent(componentName) {
5988
5988
  }
5989
5989
  else {
5990
5990
  // Los componentes van en onpe-modals o onpe-ui
5991
- if (componentName.toLowerCase().includes("modal")) {
5991
+ if (componentName.toLowerCase().startsWith("modal") && componentName !== "modal") {
5992
5992
  importPath = "../onpe-modals/".concat(componentNamePascal);
5993
5993
  }
5994
5994
  else {
@@ -6006,7 +6006,7 @@ function addComponent(componentName) {
6006
6006
  if (dep.startsWith("icon-")) {
6007
6007
  depPath = "../onpe-icons/".concat(depPascal);
6008
6008
  }
6009
- else if (dep.startsWith("modal")) {
6009
+ else if (dep.startsWith("modal") && dep !== "modal") {
6010
6010
  depPath = "../onpe-modals/".concat(depPascal);
6011
6011
  }
6012
6012
  else {
@@ -6047,7 +6047,7 @@ function personalizeComponent(code, componentName) {
6047
6047
  Portal: "../onpe-ui/Portal",
6048
6048
  Show: "../onpe-ui/Show",
6049
6049
  // Modales
6050
- Modal: "../onpe-modals/Modal",
6050
+ Modal: "../onpe-ui/Modal", // Modal base va en onpe-ui
6051
6051
  ModalConfirm: "../onpe-modals/ModalConfirm",
6052
6052
  ModalLoading: "../onpe-modals/ModalLoading",
6053
6053
  ModalBrowserIncompatible: "../onpe-modals/ModalBrowserIncompatible",
@@ -6103,6 +6103,10 @@ function personalizeComponent(code, componentName) {
6103
6103
  personalizedCode = personalizedCode.replace(pattern, "from \"".concat(newPath, "\""));
6104
6104
  });
6105
6105
  });
6106
+ // Agregar export default si no existe
6107
+ if (!personalizedCode.includes("export default")) {
6108
+ personalizedCode += "\n\nexport default ".concat(componentNamePascal, ";");
6109
+ }
6106
6110
  var finalCode = "// Componente ".concat(componentNamePascal, " copiado y ajustado para la nueva estructura\n// Las rutas de importaci\u00F3n han sido actualizadas autom\u00E1ticamente\n\n").concat(personalizedCode);
6107
6111
  return finalCode;
6108
6112
  }
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconCheckProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconCheck: (props: IconCheckProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconCheck;
6
5
  //# sourceMappingURL=IconCheck.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconCheck } from "./IconCheck";
2
2
  export type { IconCheckProps } from "./IconCheck";
3
- export { default } from "./IconCheck";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconCloseProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconClose: (props: IconCloseProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconClose;
6
5
  //# sourceMappingURL=IconClose.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconClose } from "./IconClose";
2
2
  export type { IconCloseProps } from "./IconClose";
3
- export { default } from "./IconClose";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -3,5 +3,4 @@ export interface IconHomeProps extends React.SVGProps<SVGSVGElement> {
3
3
  size?: number | string;
4
4
  }
5
5
  export declare const IconHome: ({ size, ...props }: IconHomeProps) => import("react/jsx-runtime").JSX.Element;
6
- export default IconHome;
7
6
  //# sourceMappingURL=IconHome.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconHome } from "./IconHome";
2
- export { default } from "./IconHome";
3
- export { default as IconHomeStories } from "./IconHome.stories";
2
+ export { IconHomeStories } from "./IconHome.stories";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconSpinnerDesktopProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconSpinnerDesktop: (props: IconSpinnerDesktopProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconSpinnerDesktop;
6
5
  //# sourceMappingURL=IconSpinnerDesktop.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconSpinnerDesktop } from "./IconSpinnerDesktop";
2
2
  export type { IconSpinnerDesktopProps } from "./IconSpinnerDesktop";
3
- export { default } from "./IconSpinnerDesktop";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconSpinnerMobileProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconSpinnerMobile: (props: IconSpinnerMobileProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconSpinnerMobile;
6
5
  //# sourceMappingURL=IconSpinnerMobile.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconSpinnerMobile } from "./IconSpinnerMobile";
2
2
  export type { IconSpinnerMobileProps } from "./IconSpinnerMobile";
3
- export { default } from "./IconSpinnerMobile";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconWarningProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconWarning: (props: IconWarningProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconWarning;
6
5
  //# sourceMappingURL=IconWarning.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconWarning } from "./IconWarning";
2
2
  export type { IconWarningProps } from "./IconWarning";
3
- export { default } from "./IconWarning";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconChromeProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconChrome: (props: IconChromeProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconChrome;
6
5
  //# sourceMappingURL=IconChrome.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconChromeColorProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconChromeColor: (props: IconChromeColorProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconChromeColor;
6
5
  //# sourceMappingURL=IconChromeColor.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconChromeColor } from "./IconChromeColor";
2
2
  export type { IconChromeColorProps } from "./IconChromeColor";
3
- export { default } from "./IconChromeColor";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconEdgeProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconEdge: (props: IconEdgeProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconEdge;
6
5
  //# sourceMappingURL=IconEdge.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconEdgeColorProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconEdgeColor: (props: IconEdgeColorProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconEdgeColor;
6
5
  //# sourceMappingURL=IconEdgeColor.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconEdgeColor } from "./IconEdgeColor";
2
2
  export type { IconEdgeColorProps } from "./IconEdgeColor";
3
- export { default } from "./IconEdgeColor";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconMozillaProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconMozilla: (props: IconMozillaProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconMozilla;
6
5
  //# sourceMappingURL=IconMozilla.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconMozillaColorProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconMozillaColor: (props: IconMozillaColorProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconMozillaColor;
6
5
  //# sourceMappingURL=IconMozillaColor.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconMozillaColor } from "./IconMozillaColor";
2
2
  export type { IconMozillaColorProps } from "./IconMozillaColor";
3
- export { default } from "./IconMozillaColor";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconSafariProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconSafari: (props: IconSafariProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconSafari;
6
5
  //# sourceMappingURL=IconSafari.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconSafariColorProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconSafariColor: (props: IconSafariColorProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconSafariColor;
6
5
  //# sourceMappingURL=IconSafariColor.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconSafariColor } from "./IconSafariColor";
2
2
  export type { IconSafariColorProps } from "./IconSafariColor";
3
- export { default } from "./IconSafariColor";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -1,5 +1,4 @@
1
1
  import { SVGProps } from "react";
2
2
  export type ElectionsIconProps = SVGProps<SVGSVGElement>;
3
3
  export declare const ElectionsIcon: (props: ElectionsIconProps) => import("react/jsx-runtime").JSX.Element;
4
- export default ElectionsIcon;
5
4
  //# sourceMappingURL=ElectionsIcon.d.ts.map
@@ -1,5 +1,4 @@
1
1
  import { SVGProps } from "react";
2
2
  export type IconElectionsGeneralProps = SVGProps<SVGSVGElement>;
3
3
  export declare const IconElectionsGeneral: (props: IconElectionsGeneralProps) => import("react/jsx-runtime").JSX.Element;
4
- export default IconElectionsGeneral;
5
4
  //# sourceMappingURL=IconElectionsGeneral.d.ts.map
@@ -1,5 +1,4 @@
1
1
  import { SVGProps } from "react";
2
2
  export type IconVotoDigitalProps = SVGProps<SVGSVGElement>;
3
3
  export declare const IconVotoDigital: (props: IconVotoDigitalProps) => import("react/jsx-runtime").JSX.Element;
4
- export default IconVotoDigital;
5
4
  //# sourceMappingURL=IconVotoDigital.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconAndroidProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconAndroid: (props: IconAndroidProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconAndroid;
6
5
  //# sourceMappingURL=IconAndroid.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconAndroid } from "./IconAndroid";
2
2
  export type { IconAndroidProps } from "./IconAndroid";
3
- export { default } from "./IconAndroid";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconAppleProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconApple: (props: IconAppleProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconApple;
6
5
  //# sourceMappingURL=IconApple.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconApple } from "./IconApple";
2
2
  export type { IconAppleProps } from "./IconApple";
3
- export { default } from "./IconApple";
4
3
  //# sourceMappingURL=index.d.ts.map
@@ -2,5 +2,4 @@ import { SVGProps } from "react";
2
2
  export interface IconWindowProps extends SVGProps<SVGSVGElement> {
3
3
  }
4
4
  export declare const IconWindow: (props: IconWindowProps) => import("react/jsx-runtime").JSX.Element;
5
- export default IconWindow;
6
5
  //# sourceMappingURL=IconWindow.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { IconWindow } from "./IconWindow";
2
2
  export type { IconWindowProps } from "./IconWindow";
3
- export { default } from "./IconWindow";
4
3
  //# sourceMappingURL=index.d.ts.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onpe/ui",
3
- "version": "1.0.50",
3
+ "version": "1.0.52",
4
4
  "type": "module",
5
5
  "description": "Librería completa de UI para ONPE - Componentes, Hooks, Utils y Librerías",
6
6
  "main": "dist/index.js",