labellife-design-tool 1.0.3 → 1.0.4

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 (91) hide show
  1. package/dist/types/CanvasEditor.d.ts +17 -0
  2. package/dist/types/CanvasEditor.d.ts.map +1 -0
  3. package/dist/types/components/Header.d.ts +19 -0
  4. package/dist/types/components/Header.d.ts.map +1 -0
  5. package/dist/types/components/LeftMenu.d.ts +13 -0
  6. package/dist/types/components/LeftMenu.d.ts.map +1 -0
  7. package/dist/types/components/TemplateInputModal.d.ts +10 -0
  8. package/dist/types/components/TemplateInputModal.d.ts.map +1 -0
  9. package/dist/types/components/header/AppName.d.ts +7 -0
  10. package/dist/types/components/header/AppName.d.ts.map +1 -0
  11. package/dist/types/components/header/ExportButton.d.ts +8 -0
  12. package/dist/types/components/header/ExportButton.d.ts.map +1 -0
  13. package/dist/types/components/header/HistoryControls.d.ts +10 -0
  14. package/dist/types/components/header/HistoryControls.d.ts.map +1 -0
  15. package/dist/types/components/header/ZoomControls.d.ts +10 -0
  16. package/dist/types/components/header/ZoomControls.d.ts.map +1 -0
  17. package/dist/types/components/sidebar/RightSidebar.d.ts +16 -0
  18. package/dist/types/components/sidebar/RightSidebar.d.ts.map +1 -0
  19. package/dist/types/config.d.ts +11 -0
  20. package/dist/types/config.d.ts.map +1 -0
  21. package/dist/types/constants/CanvasPresets.d.ts +6 -0
  22. package/dist/types/constants/CanvasPresets.d.ts.map +1 -0
  23. package/dist/types/constants/DefaultColors.d.ts +2 -0
  24. package/dist/types/constants/DefaultColors.d.ts.map +1 -0
  25. package/dist/types/constants/FontFamilies.d.ts +2 -0
  26. package/dist/types/constants/FontFamilies.d.ts.map +1 -0
  27. package/dist/types/constants/index.d.ts +4 -0
  28. package/dist/types/constants/index.d.ts.map +1 -0
  29. package/dist/types/constants/themes.d.ts +17 -0
  30. package/dist/types/constants/themes.d.ts.map +1 -0
  31. package/dist/types/elements/EditableTextElement.d.ts +10 -0
  32. package/dist/types/elements/EditableTextElement.d.ts.map +1 -0
  33. package/dist/types/elements/ShapeElement.d.ts +10 -0
  34. package/dist/types/elements/ShapeElement.d.ts.map +1 -0
  35. package/dist/types/elements/UrlImageElement.d.ts +10 -0
  36. package/dist/types/elements/UrlImageElement.d.ts.map +1 -0
  37. package/dist/types/elements/index.d.ts +4 -0
  38. package/dist/types/elements/index.d.ts.map +1 -0
  39. package/dist/types/lib/index.d.ts +20 -0
  40. package/dist/types/lib/index.d.ts.map +1 -0
  41. package/dist/types/panels/BackgroundPanel.d.ts +11 -0
  42. package/dist/types/panels/BackgroundPanel.d.ts.map +1 -0
  43. package/dist/types/panels/DesignPanel.d.ts +15 -0
  44. package/dist/types/panels/DesignPanel.d.ts.map +1 -0
  45. package/dist/types/panels/ElementPanel.d.ts +8 -0
  46. package/dist/types/panels/ElementPanel.d.ts.map +1 -0
  47. package/dist/types/panels/ExportPanel.d.ts +10 -0
  48. package/dist/types/panels/ExportPanel.d.ts.map +1 -0
  49. package/dist/types/panels/ImagePanel.d.ts +13 -0
  50. package/dist/types/panels/ImagePanel.d.ts.map +1 -0
  51. package/dist/types/panels/TextPanel.d.ts +11 -0
  52. package/dist/types/panels/TextPanel.d.ts.map +1 -0
  53. package/dist/types/panels/VariablesPanel.d.ts +11 -0
  54. package/dist/types/panels/VariablesPanel.d.ts.map +1 -0
  55. package/dist/types/types/CanvasDesign.d.ts +13 -0
  56. package/dist/types/types/CanvasDesign.d.ts.map +1 -0
  57. package/dist/types/types/CanvasEditor.d.ts +6 -0
  58. package/dist/types/types/CanvasEditor.d.ts.map +1 -0
  59. package/dist/types/types/CanvasEditorRef.d.ts +28 -0
  60. package/dist/types/types/CanvasEditorRef.d.ts.map +1 -0
  61. package/dist/types/types/CanvasElement.d.ts +80 -0
  62. package/dist/types/types/CanvasElement.d.ts.map +1 -0
  63. package/dist/types/types/Config.d.ts +40 -0
  64. package/dist/types/types/Config.d.ts.map +1 -0
  65. package/dist/types/types/Feature.d.ts +4 -0
  66. package/dist/types/types/Feature.d.ts.map +1 -0
  67. package/dist/types/types/MenuElement.d.ts +7 -0
  68. package/dist/types/types/MenuElement.d.ts.map +1 -0
  69. package/dist/types/types/Page.d.ts +9 -0
  70. package/dist/types/types/Page.d.ts.map +1 -0
  71. package/dist/types/types/Panel.d.ts +17 -0
  72. package/dist/types/types/Panel.d.ts.map +1 -0
  73. package/dist/types/types/ShapeType.d.ts +2 -0
  74. package/dist/types/types/ShapeType.d.ts.map +1 -0
  75. package/dist/types/types/Theme.d.ts +38 -0
  76. package/dist/types/types/Theme.d.ts.map +1 -0
  77. package/dist/types/types/ToolType.d.ts +3 -0
  78. package/dist/types/types/ToolType.d.ts.map +1 -0
  79. package/dist/types/types/UnsplashSearchResult.d.ts +11 -0
  80. package/dist/types/types/UnsplashSearchResult.d.ts.map +1 -0
  81. package/dist/types/types/UserInput.d.ts +21 -0
  82. package/dist/types/types/UserInput.d.ts.map +1 -0
  83. package/dist/types/types/index.d.ts +14 -0
  84. package/dist/types/types/index.d.ts.map +1 -0
  85. package/dist/types/utils/exportImportUtils.d.ts +35 -0
  86. package/dist/types/utils/exportImportUtils.d.ts.map +1 -0
  87. package/dist/types/utils/objectUtils.d.ts +11 -0
  88. package/dist/types/utils/objectUtils.d.ts.map +1 -0
  89. package/dist/types/utils/themeUtils.d.ts +8 -0
  90. package/dist/types/utils/themeUtils.d.ts.map +1 -0
  91. package/package.json +4 -3
@@ -0,0 +1,17 @@
1
+ import React from "react";
2
+ import Konva from "konva";
3
+ import { CanvasDesign } from "./types";
4
+ import { Config } from "./types/Config";
5
+ export interface CanvasEditorRef {
6
+ stage: Konva.Stage | null;
7
+ exportToPNG: () => void;
8
+ exportToJPG: () => void;
9
+ exportToJSON: () => void;
10
+ getDesign: () => CanvasDesign;
11
+ }
12
+ declare const CanvasEditor: React.ForwardRefExoticComponent<{
13
+ name: string;
14
+ config?: Config;
15
+ } & React.RefAttributes<CanvasEditorRef>>;
16
+ export default CanvasEditor;
17
+ //# sourceMappingURL=CanvasEditor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasEditor.d.ts","sourceRoot":"","sources":["../../src/CanvasEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoF,MAAM,OAAO,CAAC;AAGzG,OAAO,KAAK,MAAM,OAAO,CAAC;AAyC1B,OAAO,EAEL,YAAY,EAKb,MAAM,SAAS,CAAC;AAgCjB,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAGxC,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,CAAC;IAC1B,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,SAAS,EAAE,MAAM,YAAY,CAAC;CAC/B;AAED,QAAA,MAAM,YAAY;UAAuC,MAAM;aAAW,MAAM;yCA29B9E,CAAC;AAEH,eAAe,YAAY,CAAC"}
@@ -0,0 +1,19 @@
1
+ import React from 'react';
2
+ import { ActivePanelId } from '../types';
3
+ import { NavbarConfig } from '../types/Config';
4
+ export interface HeaderProps {
5
+ name?: string;
6
+ zoom: number;
7
+ historyIndex: number;
8
+ historyLength: number;
9
+ onUndo: () => void;
10
+ onRedo: () => void;
11
+ onZoomIn: () => void;
12
+ onZoomOut: () => void;
13
+ onZoomReset: () => void;
14
+ onSetActivePanel: (panel: ActivePanelId | "export") => void;
15
+ navbarConfig?: NavbarConfig;
16
+ }
17
+ export declare const Header: React.FC<HeaderProps>;
18
+ export default Header;
19
+ //# sourceMappingURL=Header.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Header.d.ts","sourceRoot":"","sources":["../../../src/components/Header.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,YAAY,EAAiB,MAAM,iBAAiB,CAAC;AAE9D,MAAM,WAAW,WAAW;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,gBAAgB,EAAE,CAAC,KAAK,EAAE,aAAa,GAAG,QAAQ,KAAK,IAAI,CAAC;IAC5D,YAAY,CAAC,EAAE,YAAY,CAAC;CAC7B;AAED,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,WAAW,CAgKxC,CAAC;AAEF,eAAe,MAAM,CAAC"}
@@ -0,0 +1,13 @@
1
+ import React from "react";
2
+ import { ToolType, ActivePanelId } from "../types";
3
+ import { Config } from "../types/Config";
4
+ export interface LeftMenuProps {
5
+ tool: ToolType;
6
+ activePanel: ActivePanelId;
7
+ onSetTool: (tool: ToolType) => void;
8
+ onSetActivePanel: (panel: ActivePanelId) => void;
9
+ config?: Config;
10
+ }
11
+ export declare const LeftMenu: React.FC<LeftMenuProps>;
12
+ export default LeftMenu;
13
+ //# sourceMappingURL=LeftMenu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LeftMenu.d.ts","sourceRoot":"","sources":["../../../src/components/LeftMenu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAWzC,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,QAAQ,CAAC;IACf,WAAW,EAAE,aAAa,CAAC;IAC3B,SAAS,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,IAAI,CAAC;IACpC,gBAAgB,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IACjD,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CAqH5C,CAAC;AAEF,eAAe,QAAQ,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from "react";
2
+ import { UserInputItem } from "../types/UserInput";
3
+ interface TemplateInputModalProps {
4
+ inputs: UserInputItem[];
5
+ onComplete: (values: Record<string, any>) => void;
6
+ onCancel: () => void;
7
+ }
8
+ declare const TemplateInputModal: React.FC<TemplateInputModalProps>;
9
+ export default TemplateInputModal;
10
+ //# sourceMappingURL=TemplateInputModal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateInputModal.d.ts","sourceRoot":"","sources":["../../../src/components/TemplateInputModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2B,MAAM,OAAO,CAAC;AAEhD,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAEnD,UAAU,uBAAuB;IAC/B,MAAM,EAAE,aAAa,EAAE,CAAC;IACxB,UAAU,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,IAAI,CAAC;IAClD,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,QAAA,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CA2ezD,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
@@ -0,0 +1,7 @@
1
+ import React from "react";
2
+ interface AppNameProps {
3
+ customName?: string;
4
+ }
5
+ declare const AppName: React.FC<AppNameProps>;
6
+ export default AppName;
7
+ //# sourceMappingURL=AppName.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AppName.d.ts","sourceRoot":"","sources":["../../../../src/components/header/AppName.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,UAAU,YAAY;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,QAAA,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CAEnC,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,8 @@
1
+ import React from "react";
2
+ import { ActivePanelId } from "../../types";
3
+ interface ExportButtonProps {
4
+ onSetActivePanel: (panel: ActivePanelId | "export") => void;
5
+ }
6
+ declare const ExportButton: React.FC<ExportButtonProps>;
7
+ export default ExportButton;
8
+ //# sourceMappingURL=ExportButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExportButton.d.ts","sourceRoot":"","sources":["../../../../src/components/header/ExportButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,UAAU,iBAAiB;IACzB,gBAAgB,EAAE,CAAC,KAAK,EAAE,aAAa,GAAG,QAAQ,KAAK,IAAI,CAAC;CAC7D;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAW7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ interface HistoryControlsProps {
3
+ historyIndex: number;
4
+ historyLength: number;
5
+ onUndo: () => void;
6
+ onRedo: () => void;
7
+ }
8
+ declare const HistoryControls: React.FC<HistoryControlsProps>;
9
+ export default HistoryControls;
10
+ //# sourceMappingURL=HistoryControls.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"HistoryControls.d.ts","sourceRoot":"","sources":["../../../../src/components/header/HistoryControls.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,oBAAoB;IAC5B,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,MAAM,EAAE,MAAM,IAAI,CAAC;CACpB;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CA2BnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ interface ZoomControlsProps {
3
+ zoom: number;
4
+ onZoomIn: () => void;
5
+ onZoomOut: () => void;
6
+ onZoomReset: () => void;
7
+ }
8
+ declare const ZoomControls: React.FC<ZoomControlsProps>;
9
+ export default ZoomControls;
10
+ //# sourceMappingURL=ZoomControls.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ZoomControls.d.ts","sourceRoot":"","sources":["../../../../src/components/header/ZoomControls.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,iBAAiB;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,WAAW,EAAE,MAAM,IAAI,CAAC;CACzB;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAmC7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -0,0 +1,16 @@
1
+ import React from "react";
2
+ import { CanvasElement } from "../../types";
3
+ interface RightSidebarProps {
4
+ currentPageElements: CanvasElement[];
5
+ selectedElement: CanvasElement | undefined | null;
6
+ selectedId: string | null;
7
+ onSelectElement: (id: string) => void;
8
+ onUpdateElement: (id: string, attrs: Partial<CanvasElement>) => void;
9
+ onDuplicateSelected: () => void;
10
+ onMoveElementUp: (id: string) => void;
11
+ onMoveElementDown: (id: string) => void;
12
+ onDeleteSelected: () => void;
13
+ }
14
+ declare const RightSidebar: React.FC<RightSidebarProps>;
15
+ export default RightSidebar;
16
+ //# sourceMappingURL=RightSidebar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RightSidebar.d.ts","sourceRoot":"","sources":["../../../../src/components/sidebar/RightSidebar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAc1B,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,UAAU,iBAAiB;IACzB,mBAAmB,EAAE,aAAa,EAAE,CAAC;IACrC,eAAe,EAAE,aAAa,GAAG,SAAS,GAAG,IAAI,CAAC;IAClD,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,eAAe,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,eAAe,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;IACrE,mBAAmB,EAAE,MAAM,IAAI,CAAC;IAChC,eAAe,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,iBAAiB,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,gBAAgB,EAAE,MAAM,IAAI,CAAC;CAC9B;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAqL7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -0,0 +1,11 @@
1
+ export declare const UNSPLASH_ACCESS_KEY: string;
2
+ /**
3
+ * Set the Unsplash API access key programmatically
4
+ * @param key - Your Unsplash API access key
5
+ */
6
+ export declare function setUnsplashAccessKey(key: string): void;
7
+ /**
8
+ * Get the current Unsplash API access key
9
+ */
10
+ export declare function getUnsplashAccessKey(): string | undefined;
11
+ //# sourceMappingURL=config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,mBAAmB,QAAwD,CAAC;AAEzF;;;GAGG;AACH,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAEtD;AAED;;GAEG;AACH,wBAAgB,oBAAoB,IAAI,MAAM,GAAG,SAAS,CAEzD"}
@@ -0,0 +1,6 @@
1
+ export declare const CANVAS_PRESETS: {
2
+ name: string;
3
+ width: number;
4
+ height: number;
5
+ }[];
6
+ //# sourceMappingURL=CanvasPresets.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasPresets.d.ts","sourceRoot":"","sources":["../../../src/constants/CanvasPresets.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,cAAc;;;;GAS1B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const DEFAULT_COLORS: string[];
2
+ //# sourceMappingURL=DefaultColors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DefaultColors.d.ts","sourceRoot":"","sources":["../../../src/constants/DefaultColors.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,cAAc,UAgB1B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const FONT_FAMILIES: string[];
2
+ //# sourceMappingURL=FontFamilies.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"FontFamilies.d.ts","sourceRoot":"","sources":["../../../src/constants/FontFamilies.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,aAAa,UAczB,CAAC"}
@@ -0,0 +1,4 @@
1
+ export * from './CanvasPresets';
2
+ export * from './DefaultColors';
3
+ export * from './FontFamilies';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC"}
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Default theme configurations for LabelLife Design Tool
3
+ */
4
+ import { ThemeColors } from '../types/Theme';
5
+ /**
6
+ * Default dark theme (matches current styling)
7
+ */
8
+ export declare const DEFAULT_THEME: ThemeColors;
9
+ /**
10
+ * Light theme variant
11
+ */
12
+ export declare const LIGHT_THEME: ThemeColors;
13
+ /**
14
+ * Dark theme variant with higher contrast
15
+ */
16
+ export declare const DARK_THEME: ThemeColors;
17
+ //# sourceMappingURL=themes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"themes.d.ts","sourceRoot":"","sources":["../../../src/constants/themes.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C;;GAEG;AACH,eAAO,MAAM,aAAa,EAAE,WA6B3B,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,WAAW,EAAE,WA6BzB,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,UAAU,EAAE,WA6BxB,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from "react";
2
+ import { CanvasElement } from "../types/CanvasElement";
3
+ export declare const EditableTextElement: React.FC<{
4
+ element: CanvasElement;
5
+ isSelected: boolean;
6
+ onSelect: () => void;
7
+ onChange: (attrs: Partial<CanvasElement>) => void;
8
+ }>;
9
+ export default EditableTextElement;
10
+ //# sourceMappingURL=EditableTextElement.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"EditableTextElement.d.ts","sourceRoot":"","sources":["../../../src/elements/EditableTextElement.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAIjD,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAuBvD,eAAO,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC;IACzC,OAAO,EAAE,aAAa,CAAC;IACvB,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;CACnD,CAgNA,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from "react";
2
+ import { CanvasElement } from "../types/CanvasElement";
3
+ export declare const ShapeElement: React.FC<{
4
+ element: CanvasElement;
5
+ isSelected: boolean;
6
+ onSelect: () => void;
7
+ onChange: (attrs: Partial<CanvasElement>) => void;
8
+ }>;
9
+ export default ShapeElement;
10
+ //# sourceMappingURL=ShapeElement.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ShapeElement.d.ts","sourceRoot":"","sources":["../../../src/elements/ShapeElement.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAcjD,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAEvD,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC;IAClC,OAAO,EAAE,aAAa,CAAC;IACvB,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;CACnD,CA+YA,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from "react";
2
+ import { CanvasElement } from "../types";
3
+ export declare const UrlImageElement: React.FC<{
4
+ element: CanvasElement;
5
+ isSelected: boolean;
6
+ onSelect: () => void;
7
+ onChange: (attrs: Partial<CanvasElement>) => void;
8
+ }>;
9
+ export default UrlImageElement;
10
+ //# sourceMappingURL=UrlImageElement.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UrlImageElement.d.ts","sourceRoot":"","sources":["../../../src/elements/UrlImageElement.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmD,MAAM,OAAO,CAAC;AAIxE,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAGzC,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC;IACrC,OAAO,EAAE,aAAa,CAAC;IACvB,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;CACnD,CA6cA,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -0,0 +1,4 @@
1
+ export * from './EditableTextElement';
2
+ export * from './ShapeElement';
3
+ export * from './UrlImageElement';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/elements/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Canvas Editor Library
3
+ * Main entry point for npm package
4
+ */
5
+ import Konva from "konva";
6
+ import { CanvasDesign } from "../types";
7
+ export interface CanvasEditorRef {
8
+ stage: Konva.Stage | null;
9
+ exportToPNG: () => void;
10
+ exportToJPG: () => void;
11
+ exportToJSON: () => void;
12
+ getDesign: () => CanvasDesign;
13
+ }
14
+ export { default as CanvasEditor } from '../CanvasEditor';
15
+ export * from '../types';
16
+ export { exportToPNG, exportToJPG, exportToJSON, importFromJSON, findRequiredInputs, replaceUserInputs, convertTemplateToCanvasDesign, canvasToBlob, } from '../utils/exportImportUtils';
17
+ export * from '../elements';
18
+ export { FONT_FAMILIES, DEFAULT_COLORS, CANVAS_PRESETS } from '../constants';
19
+ export { setUnsplashAccessKey, getUnsplashAccessKey } from '../config';
20
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAGxC,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,CAAC;IAC1B,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,SAAS,EAAE,MAAM,YAAY,CAAC;CAC/B;AAGD,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAG1D,cAAc,UAAU,CAAC;AAGzB,OAAO,EACL,WAAW,EACX,WAAW,EACX,YAAY,EACZ,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,6BAA6B,EAC7B,YAAY,GACb,MAAM,4BAA4B,CAAC;AAGpC,cAAc,aAAa,CAAC;AAG5B,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAG7E,OAAO,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { CanvasDesign, Page } from '../types';
3
+ interface BackgroundPanelProps {
4
+ design: CanvasDesign;
5
+ currentPage: Page;
6
+ setDesign: (design: CanvasDesign | ((prev: CanvasDesign) => CanvasDesign)) => void;
7
+ onSetUnsplashBackground: () => void;
8
+ }
9
+ declare const BackgroundPanel: React.FC<BackgroundPanelProps>;
10
+ export default BackgroundPanel;
11
+ //# sourceMappingURL=BackgroundPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackgroundPanel.d.ts","sourceRoot":"","sources":["../../../src/panels/BackgroundPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,YAAY,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAE9C,UAAU,oBAAoB;IAC5B,MAAM,EAAE,YAAY,CAAC;IACrB,WAAW,EAAE,IAAI,CAAC;IAClB,SAAS,EAAE,CAAC,MAAM,EAAE,YAAY,GAAG,CAAC,CAAC,IAAI,EAAE,YAAY,KAAK,YAAY,CAAC,KAAK,IAAI,CAAC;IACnF,uBAAuB,EAAE,MAAM,IAAI,CAAC;CACrC;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CA4DnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import { CanvasDesign, Page, CanvasElement } from '../types';
3
+ import { Config } from '../types/Config';
4
+ interface DesignPanelProps {
5
+ design: CanvasDesign;
6
+ currentPage: Page;
7
+ selectedElement: CanvasElement | undefined | null;
8
+ setDesign: (design: CanvasDesign | ((prev: CanvasDesign) => CanvasDesign)) => void;
9
+ updateElement: (id: string, attrs: Partial<CanvasElement>) => void;
10
+ onSetUnsplashBackground: () => void;
11
+ config?: Config;
12
+ }
13
+ declare const DesignPanel: React.FC<DesignPanelProps>;
14
+ export default DesignPanel;
15
+ //# sourceMappingURL=DesignPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DesignPanel.d.ts","sourceRoot":"","sources":["../../../src/panels/DesignPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,YAAY,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAG7D,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC,UAAU,gBAAgB;IACxB,MAAM,EAAE,YAAY,CAAC;IACrB,WAAW,EAAE,IAAI,CAAC;IAClB,eAAe,EAAE,aAAa,GAAG,SAAS,GAAG,IAAI,CAAC;IAClD,SAAS,EAAE,CAAC,MAAM,EAAE,YAAY,GAAG,CAAC,CAAC,IAAI,EAAE,YAAY,KAAK,YAAY,CAAC,KAAK,IAAI,CAAC;IACnF,aAAa,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;IACnE,uBAAuB,EAAE,MAAM,IAAI,CAAC;IACpC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CA+H3C,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -0,0 +1,8 @@
1
+ import React from "react";
2
+ import { ShapeType } from "../types";
3
+ interface ElementPanelProps {
4
+ onAddShape: (shapeType: ShapeType) => void;
5
+ }
6
+ declare const ElementPanel: React.FC<ElementPanelProps>;
7
+ export default ElementPanel;
8
+ //# sourceMappingURL=ElementPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ElementPanel.d.ts","sourceRoot":"","sources":["../../../src/panels/ElementPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAE3C,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,UAAU,iBAAiB;IACzB,UAAU,EAAE,CAAC,SAAS,EAAE,SAAS,KAAK,IAAI,CAAC;CAC5C;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAuI7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from "react";
2
+ interface ExportPanelProps {
3
+ onExportToPNG: () => void;
4
+ onExportToJPG: () => void;
5
+ onExportToJSON: () => void;
6
+ onImportJSON: () => void;
7
+ }
8
+ declare const ExportPanel: React.FC<ExportPanelProps>;
9
+ export default ExportPanel;
10
+ //# sourceMappingURL=ExportPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExportPanel.d.ts","sourceRoot":"","sources":["../../../src/panels/ExportPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,UAAU,gBAAgB;IACxB,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,YAAY,EAAE,MAAM,IAAI,CAAC;CAC1B;AAED,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAqC3C,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -0,0 +1,13 @@
1
+ import React from "react";
2
+ import { CanvasElement } from "../types";
3
+ interface ImagePanelProps {
4
+ selectedElement: CanvasElement | undefined | null;
5
+ updateElement: (id: string, attrs: Partial<CanvasElement>) => void;
6
+ onUploadClick: () => void;
7
+ onUnsplashClick: () => void;
8
+ canvasWidth: number;
9
+ canvasHeight: number;
10
+ }
11
+ declare const ImagePanel: React.FC<ImagePanelProps>;
12
+ export default ImagePanel;
13
+ //# sourceMappingURL=ImagePanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ImagePanel.d.ts","sourceRoot":"","sources":["../../../src/panels/ImagePanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,aAAa,EAAa,MAAM,UAAU,CAAC;AAIpD,UAAU,eAAe;IACvB,eAAe,EAAE,aAAa,GAAG,SAAS,GAAG,IAAI,CAAC;IAClD,aAAa,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;IACnE,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,eAAe,EAAE,MAAM,IAAI,CAAC;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,QAAA,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CAiVzC,CAAC;AAEF,eAAe,UAAU,CAAC"}
@@ -0,0 +1,11 @@
1
+ import React from "react";
2
+ import { CanvasElement, ToolType } from "../types";
3
+ interface TextPanelProps {
4
+ selectedElement: CanvasElement | undefined | null;
5
+ updateElement: (id: string, attrs: Partial<CanvasElement>) => void;
6
+ setTool: (tool: ToolType) => void;
7
+ onAddText: () => void;
8
+ }
9
+ declare const TextPanel: React.FC<TextPanelProps>;
10
+ export default TextPanel;
11
+ //# sourceMappingURL=TextPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextPanel.d.ts","sourceRoot":"","sources":["../../../src/panels/TextPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsB,MAAM,OAAO,CAAC;AAI3C,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAanD,UAAU,cAAc;IACtB,eAAe,EAAE,aAAa,GAAG,SAAS,GAAG,IAAI,CAAC;IAClD,aAAa,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,KAAK,IAAI,CAAC;IACnE,OAAO,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,IAAI,CAAC;IAClC,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB;AAGD,QAAA,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,cAAc,CAsSvC,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { Config } from '../types/Config';
3
+ import { CanvasDesign } from '../types';
4
+ interface VariablesPanelProps {
5
+ config: Config;
6
+ design: CanvasDesign;
7
+ setDesign: (design: CanvasDesign | ((prev: CanvasDesign) => CanvasDesign)) => void;
8
+ }
9
+ declare const VariablesPanel: React.FC<VariablesPanelProps>;
10
+ export default VariablesPanel;
11
+ //# sourceMappingURL=VariablesPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VariablesPanel.d.ts","sourceRoot":"","sources":["../../../src/panels/VariablesPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAExC,UAAU,mBAAmB;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,YAAY,CAAC;IACrB,SAAS,EAAE,CAAC,MAAM,EAAE,YAAY,GAAG,CAAC,CAAC,IAAI,EAAE,YAAY,KAAK,YAAY,CAAC,KAAK,IAAI,CAAC;CACpF;AAED,QAAA,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC,mBAAmB,CAmEjD,CAAC;AAEF,eAAe,cAAc,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { Page } from './Page';
2
+ import { UserInputConfig } from './UserInput';
3
+ export interface CanvasDesign {
4
+ id: string;
5
+ name: string;
6
+ width: number;
7
+ height: number;
8
+ pages: Page[];
9
+ fonts: string[];
10
+ colors: string[];
11
+ templateInputs?: UserInputConfig[];
12
+ }
13
+ //# sourceMappingURL=CanvasDesign.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasDesign.d.ts","sourceRoot":"","sources":["../../../src/types/CanvasDesign.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAE9C,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,IAAI,EAAE,CAAC;IACd,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,cAAc,CAAC,EAAE,eAAe,EAAE,CAAC;CACpC"}
@@ -0,0 +1,6 @@
1
+ import { Feature } from "./Feature";
2
+ export interface CanvasEditor {
3
+ name: string;
4
+ enabledFeatures: Array<Feature>;
5
+ }
6
+ //# sourceMappingURL=CanvasEditor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasEditor.d.ts","sourceRoot":"","sources":["../../../src/types/CanvasEditor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,MAAM,WAAW,YAAY;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,eAAe,EAAE,KAAK,CAAC,OAAO,CAAC,CAAA;CAClC"}
@@ -0,0 +1,28 @@
1
+ import Konva from "konva";
2
+ import { CanvasDesign } from "./index";
3
+ /**
4
+ * Interface for the ref object exposed by the CanvasEditor component
5
+ */
6
+ export interface CanvasEditorRef {
7
+ /**
8
+ * Reference to the Konva.Stage instance
9
+ */
10
+ stage: Konva.Stage | null;
11
+ /**
12
+ * Export the canvas to a PNG file
13
+ */
14
+ exportToPNG: () => void;
15
+ /**
16
+ * Export the canvas to a JPG file
17
+ */
18
+ exportToJPG: () => void;
19
+ /**
20
+ * Export the design to a JSON file
21
+ */
22
+ exportToJSON: () => void;
23
+ /**
24
+ * Get the current design object
25
+ */
26
+ getDesign: () => CanvasDesign;
27
+ }
28
+ //# sourceMappingURL=CanvasEditorRef.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasEditorRef.d.ts","sourceRoot":"","sources":["../../../src/types/CanvasEditorRef.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAEvC;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,CAAC;IAE1B;;OAEG;IACH,WAAW,EAAE,MAAM,IAAI,CAAC;IAExB;;OAEG;IACH,WAAW,EAAE,MAAM,IAAI,CAAC;IAExB;;OAEG;IACH,YAAY,EAAE,MAAM,IAAI,CAAC;IAEzB;;OAEG;IACH,SAAS,EAAE,MAAM,YAAY,CAAC;CAC/B"}
@@ -0,0 +1,80 @@
1
+ import { ShapeType } from './ShapeType';
2
+ export interface CanvasElement {
3
+ id: string;
4
+ type: "text" | "image" | "shape" | "line";
5
+ name: string;
6
+ x: number;
7
+ y: number;
8
+ width?: number;
9
+ height?: number;
10
+ rotation: number;
11
+ scaleX?: number;
12
+ scaleY?: number;
13
+ visible: boolean;
14
+ locked: boolean;
15
+ opacity: number;
16
+ text?: string;
17
+ fontSize?: number;
18
+ fontFamily?: string;
19
+ fontStyle?: string;
20
+ textDecoration?: string;
21
+ fill?: string;
22
+ stroke?: string;
23
+ strokeWidth?: number;
24
+ align?: string;
25
+ verticalAlign?: string;
26
+ lineHeight?: number;
27
+ letterSpacing?: number;
28
+ strikethrough?: boolean;
29
+ textCase?: "uppercase" | "lowercase" | "capitalize" | "none";
30
+ textWidth?: number;
31
+ textHeight?: number;
32
+ src?: string;
33
+ cropX?: number;
34
+ cropY?: number;
35
+ cropWidth?: number;
36
+ cropHeight?: number;
37
+ cornerRadius?: number;
38
+ filters?: {
39
+ blur?: number;
40
+ brightness?: number;
41
+ contrast?: number;
42
+ saturation?: number;
43
+ hue?: number;
44
+ sepia?: boolean;
45
+ grayscale?: boolean;
46
+ };
47
+ mask?: {
48
+ type: ShapeType;
49
+ };
50
+ shapeType?: ShapeType;
51
+ innerRadius?: number;
52
+ outerRadius?: number;
53
+ points?: number[];
54
+ numPoints?: number;
55
+ tension?: number;
56
+ closed?: boolean;
57
+ sides?: number;
58
+ pointerLength?: number;
59
+ pointerWidth?: number;
60
+ dash?: number[];
61
+ pathData?: string;
62
+ pathNaturalWidth?: number;
63
+ pathNaturalHeight?: number;
64
+ userInput?: {
65
+ required: boolean;
66
+ type: "image" | "text" | "number" | "color" | "url";
67
+ id: string;
68
+ label: string;
69
+ property?: string;
70
+ placeholder?: string;
71
+ defaultValue?: string;
72
+ accept?: string;
73
+ maxSize?: number;
74
+ maxLength?: number;
75
+ minLength?: number;
76
+ helpText?: string;
77
+ order?: number;
78
+ };
79
+ }
80
+ //# sourceMappingURL=CanvasElement.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasElement.d.ts","sourceRoot":"","sources":["../../../src/types/CanvasElement.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,40 @@
1
+ export interface NavbarSection {
2
+ id: string;
3
+ type: 'default' | 'custom';
4
+ position: 'left' | 'center' | 'right';
5
+ visible?: boolean;
6
+ content?: React.ReactNode | (() => React.ReactNode);
7
+ label?: string;
8
+ icon?: string;
9
+ onClick?: () => void;
10
+ order?: number;
11
+ }
12
+ export interface NavbarConfig {
13
+ showAppName?: boolean;
14
+ showHistoryControls?: boolean;
15
+ showZoomControls?: boolean;
16
+ customSections?: NavbarSection[];
17
+ defaultSections?: {
18
+ [key: string]: Partial<NavbarSection>;
19
+ };
20
+ }
21
+ export interface Config {
22
+ export?: {
23
+ png?: boolean;
24
+ jpg?: boolean;
25
+ json?: boolean;
26
+ };
27
+ multiPage?: boolean;
28
+ designSize?: {
29
+ width?: boolean;
30
+ height?: boolean;
31
+ };
32
+ variables?: boolean;
33
+ steps?: {
34
+ name: string;
35
+ type: "text" | "image";
36
+ variable: string;
37
+ }[];
38
+ navbar?: NavbarConfig;
39
+ }
40
+ //# sourceMappingURL=Config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Config.d.ts","sourceRoot":"","sources":["../../../src/types/Config.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC3B,QAAQ,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IACtC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,GAAG,CAAC,MAAM,KAAK,CAAC,SAAS,CAAC,CAAC;IACpD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,YAAY;IAC3B,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,cAAc,CAAC,EAAE,aAAa,EAAE,CAAC;IAEjC,eAAe,CAAC,EAAE;QAChB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,aAAa,CAAC,CAAC;KACvC,CAAC;CACH;AAED,MAAM,WAAW,MAAM;IACrB,MAAM,CAAC,EAAE;QACP,GAAG,CAAC,EAAE,OAAO,CAAC;QACd,GAAG,CAAC,EAAE,OAAO,CAAC;QACd,IAAI,CAAC,EAAE,OAAO,CAAC;KAChB,CAAC;IACF,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE;QACX,KAAK,CAAC,EAAE,OAAO,CAAC;QAChB,MAAM,CAAC,EAAE,OAAO,CAAC;KAClB,CAAC;IACF,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,KAAK,CAAC,EAAE;QACN,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;QACvB,QAAQ,EAAE,MAAM,CAAC;KAClB,EAAE,CAAC;IACJ,MAAM,CAAC,EAAE,YAAY,CAAC;CACvB"}
@@ -0,0 +1,4 @@
1
+ export interface Feature {
2
+ name: "pages" | "export" | "import" | "text" | "image" | "shape";
3
+ }
4
+ //# sourceMappingURL=Feature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Feature.d.ts","sourceRoot":"","sources":["../../../src/types/Feature.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACpB,IAAI,EAAE,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,MAAM,GAAG,OAAO,GAAG,OAAO,CAAA;CACnE"}
@@ -0,0 +1,7 @@
1
+ export interface MenuElement {
2
+ icon: string;
3
+ name: string;
4
+ label: string;
5
+ enabled: boolean;
6
+ }
7
+ //# sourceMappingURL=MenuElement.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MenuElement.d.ts","sourceRoot":"","sources":["../../../src/types/MenuElement.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,WAAW;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,OAAO,CAAC;CACpB"}
@@ -0,0 +1,9 @@
1
+ import { CanvasElement } from "./CanvasElement";
2
+ export interface Page {
3
+ id: string;
4
+ name: string;
5
+ elements: CanvasElement[];
6
+ background: string;
7
+ backgroundImageObject?: HTMLImageElement;
8
+ }
9
+ //# sourceMappingURL=Page.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Page.d.ts","sourceRoot":"","sources":["../../../src/types/Page.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,MAAM,WAAW,IAAI;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,qBAAqB,CAAC,EAAE,gBAAgB,CAAC;CAC1C"}
@@ -0,0 +1,17 @@
1
+ import { CanvasDesign } from "./CanvasDesign";
2
+ export interface Panel {
3
+ icon: string;
4
+ name: string;
5
+ design: CanvasDesign;
6
+ enabled: boolean;
7
+ }
8
+ import React from 'react';
9
+ export interface PanelConfig {
10
+ id: string;
11
+ title: string;
12
+ icon?: React.ElementType;
13
+ component: React.ComponentType<any>;
14
+ props?: Record<string, any>;
15
+ }
16
+ export type ActivePanelId = "elements" | "design" | "text" | "image" | "export" | string;
17
+ //# sourceMappingURL=Panel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Panel.d.ts","sourceRoot":"","sources":["../../../src/types/Panel.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,MAAM,WAAW,KAAK;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,YAAY,CAAC;IACrB,OAAO,EAAE,OAAO,CAAC;CACpB;AAED,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC;IACzB,SAAS,EAAE,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAC7B;AAaD,MAAM,MAAM,aAAa,GAAG,UAAU,GAAG,QAAQ,GAAG,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAC"}
@@ -0,0 +1,2 @@
1
+ export type ShapeType = "rect" | "circle" | "triangle" | "star" | "polygon" | "line" | "arrow" | "pentagon" | "octagon" | "nonagon" | "decagon" | "hendecagon" | "dodecagon" | "rectangle" | "right-triangle" | "isosceles-triangle" | "scalene-triangle" | "dashed-line" | "dotted-line" | "custom-path";
2
+ //# sourceMappingURL=ShapeType.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ShapeType.d.ts","sourceRoot":"","sources":["../../../src/types/ShapeType.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GACjB,MAAM,GACN,QAAQ,GACR,UAAU,GACV,MAAM,GACN,SAAS,GACT,MAAM,GACN,OAAO,GACP,UAAU,GACV,SAAS,GACT,SAAS,GACT,SAAS,GACT,YAAY,GACZ,WAAW,GACX,WAAW,GACX,gBAAgB,GAChB,oBAAoB,GACpB,kBAAkB,GAClB,aAAa,GACb,aAAa,GACb,aAAa,CAAC"}
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Theme configuration types for LabelLife Design Tool
3
+ * Enables customization of colors and other theme properties
4
+ */
5
+ export interface ThemeColors {
6
+ primary: string;
7
+ background: {
8
+ main: string;
9
+ sidebar: string;
10
+ panel: string;
11
+ };
12
+ text: {
13
+ primary: string;
14
+ secondary: string;
15
+ };
16
+ border: string;
17
+ button: {
18
+ primary: {
19
+ background: string;
20
+ hover: string;
21
+ text: string;
22
+ };
23
+ secondary: {
24
+ background: string;
25
+ hover: string;
26
+ text: string;
27
+ };
28
+ danger: {
29
+ background: string;
30
+ hover: string;
31
+ text: string;
32
+ };
33
+ };
34
+ }
35
+ export interface ThemeConfig {
36
+ colors: Partial<ThemeColors>;
37
+ }
38
+ //# sourceMappingURL=Theme.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Theme.d.ts","sourceRoot":"","sources":["../../../src/types/Theme.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,WAAW,WAAW;IAE1B,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE;QACV,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,MAAM,CAAC;QAChB,KAAK,EAAE,MAAM,CAAC;KACf,CAAC;IACF,IAAI,EAAE;QACJ,OAAO,EAAE,MAAM,CAAC;QAChB,SAAS,EAAE,MAAM,CAAC;KACnB,CAAC;IACF,MAAM,EAAE,MAAM,CAAC;IAGf,MAAM,EAAE;QACN,OAAO,EAAE;YACP,UAAU,EAAE,MAAM,CAAC;YACnB,KAAK,EAAE,MAAM,CAAC;YACd,IAAI,EAAE,MAAM,CAAC;SACd,CAAC;QACF,SAAS,EAAE;YACT,UAAU,EAAE,MAAM,CAAC;YACnB,KAAK,EAAE,MAAM,CAAC;YACd,IAAI,EAAE,MAAM,CAAC;SACd,CAAC;QACF,MAAM,EAAE;YACN,UAAU,EAAE,MAAM,CAAC;YACnB,KAAK,EAAE,MAAM,CAAC;YACd,IAAI,EAAE,MAAM,CAAC;SACd,CAAC;KACH,CAAC;CACH;AAED,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;CAE9B"}
@@ -0,0 +1,3 @@
1
+ export interface ToolType {
2
+ }
3
+ //# sourceMappingURL=ToolType.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ToolType.d.ts","sourceRoot":"","sources":["../../../src/types/ToolType.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,QAAQ;CACxB"}
@@ -0,0 +1,11 @@
1
+ export interface UnsplashSearchResult {
2
+ id: string;
3
+ urls: {
4
+ regular: string;
5
+ thumb: string;
6
+ };
7
+ user: {
8
+ name: string;
9
+ };
10
+ }
11
+ //# sourceMappingURL=UnsplashSearchResult.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UnsplashSearchResult.d.ts","sourceRoot":"","sources":["../../../src/types/UnsplashSearchResult.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE;QACJ,OAAO,EAAE,MAAM,CAAC;QAChB,KAAK,EAAE,MAAM,CAAC;KACf,CAAC;IACF,IAAI,EAAE;QACJ,IAAI,EAAE,MAAM,CAAC;KACd,CAAC;CACH"}
@@ -0,0 +1,21 @@
1
+ export interface UserInputConfig {
2
+ required: boolean;
3
+ type: "image" | "text" | "number" | "color" | "url";
4
+ id: string;
5
+ label: string;
6
+ property?: string;
7
+ placeholder?: string;
8
+ defaultValue?: string;
9
+ accept?: string;
10
+ maxSize?: number;
11
+ maxLength?: number;
12
+ minLength?: number;
13
+ helpText?: string;
14
+ order?: number;
15
+ }
16
+ export interface UserInputItem {
17
+ config: UserInputConfig;
18
+ elementId: string;
19
+ elementType: string;
20
+ }
21
+ //# sourceMappingURL=UserInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserInput.d.ts","sourceRoot":"","sources":["../../../src/types/UserInput.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,OAAO,CAAC;IAClB,IAAI,EAAE,OAAO,GAAG,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,KAAK,CAAC;IACpD,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IAGtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IAGjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IAGnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,eAAe,CAAC;IACxB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;CACrB"}
@@ -0,0 +1,14 @@
1
+ export * from './CanvasDesign';
2
+ export * from './CanvasEditor';
3
+ export * from './CanvasElement';
4
+ export * from './Feature';
5
+ export * from './MenuElement';
6
+ export * from './Page';
7
+ export * from './Panel';
8
+ export * from './ToolType';
9
+ export * from './UnsplashSearchResult';
10
+ export * from './ShapeType';
11
+ export * from './UserInput';
12
+ export * from './CanvasEditorRef';
13
+ export * from './Config';
14
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAA;AACvB,cAAc,YAAY,CAAA;AAC1B,cAAc,wBAAwB,CAAC;AACvC,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAmB,CAAC;AAClC,cAAc,UAAU,CAAC"}
@@ -0,0 +1,35 @@
1
+ import { type CanvasDesign } from "../types/CanvasDesign";
2
+ import { type UserInputItem } from "../types/UserInput";
3
+ import Konva from "konva";
4
+ /**
5
+ * Converts a template JSON format to CanvasDesign format
6
+ * Handles differences like:
7
+ * - "children" instead of "elements" in pages
8
+ * - Missing top-level "id" and "name" fields
9
+ * - Other structural variations
10
+ */
11
+ export declare function convertTemplateToCanvasDesign(json: any): CanvasDesign;
12
+ /**
13
+ * Finds all elements that require user input
14
+ */
15
+ export declare function findRequiredInputs(design: CanvasDesign): UserInputItem[];
16
+ /**
17
+ * Replaces user input values in the design
18
+ */
19
+ export declare function replaceUserInputs(design: CanvasDesign, collectedInputs: Record<string, any>): CanvasDesign;
20
+ export declare const exportToPNG: (stage: Konva.Stage, design: CanvasDesign) => void;
21
+ export declare const exportToJPG: (stage: Konva.Stage, design: CanvasDesign) => void;
22
+ export declare const exportToJSON: (design: CanvasDesign) => void;
23
+ /**
24
+ * Converts the canvas to a Blob that can be used for various purposes
25
+ * @param stage - The Konva.Stage to convert
26
+ * @param format - The image format to use ('png' or 'jpg')
27
+ * @param options - Additional options for conversion
28
+ * @returns Promise that resolves with a Blob
29
+ */
30
+ export declare const canvasToBlob: (stage: Konva.Stage, format?: "png" | "jpg", options?: {
31
+ quality?: number;
32
+ pixelRatio?: number;
33
+ }) => Promise<Blob>;
34
+ export declare const importFromJSON: (event: React.ChangeEvent<HTMLInputElement>, onLoad: (design: CanvasDesign) => void, onError: (message: string) => void, onInputsRequired?: (inputs: UserInputItem[], onComplete: (values: Record<string, any>) => void) => void) => void;
35
+ //# sourceMappingURL=exportImportUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"exportImportUtils.d.ts","sourceRoot":"","sources":["../../../src/utils/exportImportUtils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAE1D,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAExD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B;;;;;;GAMG;AACH,wBAAgB,6BAA6B,CAAC,IAAI,EAAE,GAAG,GAAG,YAAY,CAkGrE;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,YAAY,GAAG,aAAa,EAAE,CAsHxE;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAC7B,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GACrC,YAAY,CAuNd;AAGD,eAAO,MAAM,WAAW,GAAI,OAAO,KAAK,CAAC,KAAK,EAAE,QAAQ,YAAY,SAanE,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,OAAO,KAAK,CAAC,KAAK,EAAE,QAAQ,YAAY,SAiBnE,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,QAAQ,YAAY,SAWhD,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,YAAY,GACrB,OAAO,KAAK,CAAC,KAAK,EAClB,SAAQ,KAAK,GAAG,KAAa,EAC7B,UAAU;IACN,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB,KACF,OAAO,CAAC,IAAI,CAsCd,CAAC;AAEF,eAAO,MAAM,cAAc,GACvB,OAAO,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,EAC1C,QAAQ,CAAC,MAAM,EAAE,YAAY,KAAK,IAAI,EACtC,SAAS,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,EAClC,mBAAmB,CAAC,MAAM,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,IAAI,KAAK,IAAI,SA0C1G,CAAC"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Utility functions for working with objects
3
+ */
4
+ /**
5
+ * Deep merges two objects
6
+ * @param target - The target object
7
+ * @param source - The source object to merge into target
8
+ * @returns A new object with the merged properties
9
+ */
10
+ export declare function deepMerge<T extends Record<string, any>>(target: T, source: Partial<T>): T;
11
+ //# sourceMappingURL=objectUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"objectUtils.d.ts","sourceRoot":"","sources":["../../../src/utils/objectUtils.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,CAAC,CAiCzF"}
@@ -0,0 +1,8 @@
1
+ import { ThemeColors } from '../types/Theme';
2
+ /**
3
+ * Generates CSS variables from theme colors
4
+ * @param theme Theme colors object
5
+ * @returns CSS variables string to be injected into style tag
6
+ */
7
+ export declare function generateCssVariables(theme: ThemeColors): string;
8
+ //# sourceMappingURL=themeUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"themeUtils.d.ts","sourceRoot":"","sources":["../../../src/utils/themeUtils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,WAAW,GAAG,MAAM,CA2B/D"}
package/package.json CHANGED
@@ -1,20 +1,21 @@
1
1
  {
2
2
  "name": "labellife-design-tool",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "Professional canvas editor built with React, TypeScript, and Konva",
5
5
  "main": "./dist/lib/index.js",
6
6
  "module": "./dist/lib/index.js",
7
- "types": "./dist/lib/lib/index.d.ts",
7
+ "types": "./dist/lib/index.d.ts",
8
8
  "type": "module",
9
9
  "exports": {
10
10
  ".": {
11
11
  "import": "./dist/lib/index.js",
12
- "types": "./dist/lib/lib/index.d.ts"
12
+ "types": "./dist/lib/index.d.ts"
13
13
  },
14
14
  "./styles": "./dist/lib/index.css"
15
15
  },
16
16
  "files": [
17
17
  "dist/lib",
18
+ "dist/types",
18
19
  "README.md",
19
20
  "LICENSE"
20
21
  ],