@promakeai/inspector 0.2.1 → 1.0.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.
Files changed (170) hide show
  1. package/dist/inspector.css +1 -0
  2. package/dist/inspector.js +8740 -0
  3. package/dist/packages/inspector/src/App.d.ts +5 -0
  4. package/dist/packages/inspector/src/App.d.ts.map +1 -0
  5. package/dist/packages/inspector/src/__tests__/App.test.d.ts +5 -0
  6. package/dist/packages/inspector/src/__tests__/App.test.d.ts.map +1 -0
  7. package/dist/packages/inspector/src/components/Badge.d.ts +9 -0
  8. package/dist/packages/inspector/src/components/Badge.d.ts.map +1 -0
  9. package/dist/packages/inspector/src/components/ControlBox/ContentArea.d.ts +10 -0
  10. package/dist/packages/inspector/src/components/ControlBox/ContentArea.d.ts.map +1 -0
  11. package/dist/packages/inspector/src/components/ControlBox/PromptInput.d.ts +12 -0
  12. package/dist/packages/inspector/src/components/ControlBox/PromptInput.d.ts.map +1 -0
  13. package/dist/packages/inspector/src/components/ControlBox/index.d.ts +21 -0
  14. package/dist/packages/inspector/src/components/ControlBox/index.d.ts.map +1 -0
  15. package/dist/packages/inspector/src/components/ImageEditor/UploadBox.d.ts +10 -0
  16. package/dist/packages/inspector/src/components/ImageEditor/UploadBox.d.ts.map +1 -0
  17. package/dist/packages/inspector/src/components/ImageEditor/index.d.ts +11 -0
  18. package/dist/packages/inspector/src/components/ImageEditor/index.d.ts.map +1 -0
  19. package/dist/packages/inspector/src/components/Overlay.d.ts +11 -0
  20. package/dist/packages/inspector/src/components/Overlay.d.ts.map +1 -0
  21. package/dist/packages/inspector/src/components/StyleEditor/BorderSection.d.ts +13 -0
  22. package/dist/packages/inspector/src/components/StyleEditor/BorderSection.d.ts.map +1 -0
  23. package/dist/packages/inspector/src/components/StyleEditor/ColorPicker.d.ts +13 -0
  24. package/dist/packages/inspector/src/components/StyleEditor/ColorPicker.d.ts.map +1 -0
  25. package/dist/packages/inspector/src/components/StyleEditor/DisplaySection.d.ts +13 -0
  26. package/dist/packages/inspector/src/components/StyleEditor/DisplaySection.d.ts.map +1 -0
  27. package/dist/packages/inspector/src/components/StyleEditor/ImageSection.d.ts +13 -0
  28. package/dist/packages/inspector/src/components/StyleEditor/ImageSection.d.ts.map +1 -0
  29. package/dist/packages/inspector/src/components/StyleEditor/LayoutSection.d.ts +13 -0
  30. package/dist/packages/inspector/src/components/StyleEditor/LayoutSection.d.ts.map +1 -0
  31. package/dist/packages/inspector/src/components/StyleEditor/NumberInput.d.ts +17 -0
  32. package/dist/packages/inspector/src/components/StyleEditor/NumberInput.d.ts.map +1 -0
  33. package/dist/packages/inspector/src/components/StyleEditor/SliderInput.d.ts +16 -0
  34. package/dist/packages/inspector/src/components/StyleEditor/SliderInput.d.ts.map +1 -0
  35. package/dist/packages/inspector/src/components/StyleEditor/SpacingSection.d.ts +13 -0
  36. package/dist/packages/inspector/src/components/StyleEditor/SpacingSection.d.ts.map +1 -0
  37. package/dist/packages/inspector/src/components/StyleEditor/TextSection.d.ts +13 -0
  38. package/dist/packages/inspector/src/components/StyleEditor/TextSection.d.ts.map +1 -0
  39. package/dist/packages/inspector/src/components/StyleEditor/index.d.ts +12 -0
  40. package/dist/packages/inspector/src/components/StyleEditor/index.d.ts.map +1 -0
  41. package/dist/packages/inspector/src/components/TextEditor/index.d.ts +11 -0
  42. package/dist/packages/inspector/src/components/TextEditor/index.d.ts.map +1 -0
  43. package/dist/packages/inspector/src/components/ui/CustomCollapsible.d.ts +26 -0
  44. package/dist/packages/inspector/src/components/ui/CustomCollapsible.d.ts.map +1 -0
  45. package/dist/packages/inspector/src/components/ui/button.d.ts +9 -0
  46. package/dist/packages/inspector/src/components/ui/button.d.ts.map +1 -0
  47. package/dist/packages/inspector/src/components/ui/color-picker.d.ts +10 -0
  48. package/dist/packages/inspector/src/components/ui/color-picker.d.ts.map +1 -0
  49. package/dist/packages/inspector/src/components/ui/input.d.ts +6 -0
  50. package/dist/packages/inspector/src/components/ui/input.d.ts.map +1 -0
  51. package/dist/packages/inspector/src/components/ui/popover.d.ts +8 -0
  52. package/dist/packages/inspector/src/components/ui/popover.d.ts.map +1 -0
  53. package/dist/packages/inspector/src/components/ui/select.d.ts +16 -0
  54. package/dist/packages/inspector/src/components/ui/select.d.ts.map +1 -0
  55. package/dist/packages/inspector/src/components/ui/slider.d.ts +5 -0
  56. package/dist/packages/inspector/src/components/ui/slider.d.ts.map +1 -0
  57. package/dist/packages/inspector/src/components/ui/textarea.d.ts +4 -0
  58. package/dist/packages/inspector/src/components/ui/textarea.d.ts.map +1 -0
  59. package/dist/packages/inspector/src/components/ui/tooltip.d.ts +8 -0
  60. package/dist/packages/inspector/src/components/ui/tooltip.d.ts.map +1 -0
  61. package/dist/packages/inspector/src/core/highlighter.d.ts +40 -0
  62. package/dist/packages/inspector/src/core/highlighter.d.ts.map +1 -0
  63. package/dist/packages/inspector/src/hooks/useMessageBridge.d.ts +9 -0
  64. package/dist/packages/inspector/src/hooks/useMessageBridge.d.ts.map +1 -0
  65. package/dist/packages/inspector/src/hooks/useStylePreview.d.ts +11 -0
  66. package/dist/packages/inspector/src/hooks/useStylePreview.d.ts.map +1 -0
  67. package/dist/packages/inspector/src/index.d.ts +16 -0
  68. package/dist/packages/inspector/src/index.d.ts.map +1 -0
  69. package/dist/packages/inspector/src/lib/utils.d.ts +3 -0
  70. package/dist/packages/inspector/src/lib/utils.d.ts.map +1 -0
  71. package/dist/packages/inspector/src/plugin.d.ts +4 -0
  72. package/dist/packages/inspector/src/plugin.d.ts.map +1 -0
  73. package/dist/packages/inspector/src/store/useInspectorStore.d.ts +13 -0
  74. package/dist/packages/inspector/src/store/useInspectorStore.d.ts.map +1 -0
  75. package/dist/packages/inspector/src/styles.d.ts +5 -0
  76. package/dist/packages/inspector/src/styles.d.ts.map +1 -0
  77. package/dist/packages/inspector/src/utils/colorUtils.d.ts +49 -0
  78. package/dist/packages/inspector/src/utils/colorUtils.d.ts.map +1 -0
  79. package/dist/packages/inspector/src/utils/elementNames.d.ts +7 -0
  80. package/dist/packages/inspector/src/utils/elementNames.d.ts.map +1 -0
  81. package/dist/packages/inspector/src/utils/elementUtils.d.ts +28 -0
  82. package/dist/packages/inspector/src/utils/elementUtils.d.ts.map +1 -0
  83. package/dist/packages/inspector/src/utils/errorTracker.d.ts +48 -0
  84. package/dist/packages/inspector/src/utils/errorTracker.d.ts.map +1 -0
  85. package/dist/packages/inspector/src/utils/inputStyles.d.ts +23 -0
  86. package/dist/packages/inspector/src/utils/inputStyles.d.ts.map +1 -0
  87. package/dist/packages/inspector/src/utils/styleUtils.d.ts +27 -0
  88. package/dist/packages/inspector/src/utils/styleUtils.d.ts.map +1 -0
  89. package/dist/packages/inspector/src/utils/tailwindMapper.d.ts +9 -0
  90. package/dist/packages/inspector/src/utils/tailwindMapper.d.ts.map +1 -0
  91. package/dist/packages/inspector/src/utils/urlTracker.d.ts +27 -0
  92. package/dist/packages/inspector/src/utils/urlTracker.d.ts.map +1 -0
  93. package/dist/packages/inspector/tsconfig.tsbuildinfo +1 -0
  94. package/dist/plugin.js +10 -1813
  95. package/package.json +86 -76
  96. package/src/App.tsx +912 -0
  97. package/src/__tests__/App.test.tsx +373 -0
  98. package/src/assets/fonts/Satoshi-Variable.woff +0 -0
  99. package/src/assets/fonts/Satoshi-Variable.woff2 +0 -0
  100. package/src/components/Badge.tsx +118 -0
  101. package/src/components/ControlBox/ContentArea.tsx +13 -0
  102. package/src/components/ControlBox/PromptInput.module.css +66 -0
  103. package/src/components/ControlBox/PromptInput.tsx +104 -0
  104. package/src/components/ControlBox/index.module.css +81 -0
  105. package/src/components/ControlBox/index.tsx +409 -0
  106. package/src/components/ImageEditor/UploadBox.module.css +69 -0
  107. package/src/components/ImageEditor/UploadBox.tsx +113 -0
  108. package/src/components/ImageEditor/index.module.css +11 -0
  109. package/src/components/ImageEditor/index.tsx +84 -0
  110. package/src/components/Overlay.tsx +157 -0
  111. package/src/components/StyleEditor/BorderSection.tsx +147 -0
  112. package/src/components/StyleEditor/ColorPicker.tsx +182 -0
  113. package/src/components/StyleEditor/DisplaySection.tsx +349 -0
  114. package/src/components/StyleEditor/ImageSection.tsx +105 -0
  115. package/src/components/StyleEditor/LayoutSection.tsx +63 -0
  116. package/src/components/StyleEditor/NumberInput.tsx +138 -0
  117. package/src/components/StyleEditor/SliderInput.tsx +121 -0
  118. package/src/components/StyleEditor/SpacingSection.tsx +365 -0
  119. package/src/components/StyleEditor/TextSection.tsx +381 -0
  120. package/src/components/StyleEditor/index.module.css +133 -0
  121. package/src/components/StyleEditor/index.tsx +612 -0
  122. package/src/components/StyleEditor/shared.module.css +193 -0
  123. package/src/components/TextEditor/index.module.css +31 -0
  124. package/src/components/TextEditor/index.tsx +166 -0
  125. package/src/components/ui/CustomCollapsible.tsx +159 -0
  126. package/src/components/ui/button.module.css +141 -0
  127. package/src/components/ui/button.tsx +73 -0
  128. package/src/components/ui/color-picker.module.css +112 -0
  129. package/src/components/ui/color-picker.tsx +146 -0
  130. package/src/components/ui/input.module.css +49 -0
  131. package/src/components/ui/input.tsx +34 -0
  132. package/src/components/ui/popover.module.css +42 -0
  133. package/src/components/ui/popover.tsx +59 -0
  134. package/src/components/ui/select.module.css +160 -0
  135. package/src/components/ui/select.tsx +216 -0
  136. package/src/components/ui/slider.module.css +75 -0
  137. package/src/components/ui/slider.tsx +60 -0
  138. package/src/components/ui/textarea.module.css +30 -0
  139. package/src/components/ui/textarea.tsx +23 -0
  140. package/src/components/ui/tooltip.module.css +11 -0
  141. package/src/components/ui/tooltip.tsx +37 -0
  142. package/src/core/highlighter.ts +197 -0
  143. package/src/hooks/useMessageBridge.ts +49 -0
  144. package/src/hooks/useStylePreview.ts +332 -0
  145. package/src/index.ts +20 -0
  146. package/src/lib/utils.ts +5 -0
  147. package/src/plugin.ts +11 -0
  148. package/src/store/useInspectorStore.ts +235 -0
  149. package/src/styles/fonts.css +15 -0
  150. package/src/styles/global.css +138 -0
  151. package/src/styles/variables.css +151 -0
  152. package/src/styles.ts +5 -0
  153. package/src/utils/colorUtils.ts +133 -0
  154. package/src/utils/elementNames.ts +103 -0
  155. package/src/utils/elementUtils.ts +90 -0
  156. package/src/utils/errorTracker.ts +186 -0
  157. package/src/utils/inputStyles.ts +30 -0
  158. package/src/utils/styleUtils.ts +226 -0
  159. package/src/utils/tailwindMapper.ts +554 -0
  160. package/src/utils/urlTracker.ts +75 -0
  161. package/src/vite-env.d.ts +7 -0
  162. package/README.md +0 -866
  163. package/dist/hook.d.ts +0 -115
  164. package/dist/hook.d.ts.map +0 -1
  165. package/dist/hook.js +0 -288
  166. package/dist/plugin.d.ts +0 -44
  167. package/dist/plugin.d.ts.map +0 -1
  168. package/dist/types.d.ts +0 -139
  169. package/dist/types.d.ts.map +0 -1
  170. package/dist/types.js +0 -7
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAGH,OAAO,qBAAqB,CAAC;AAE7B,OAAO,EAAE,GAAG,IAAI,SAAS,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAG9C,mBAAmB,4BAA4B,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { ClassValue } from "clsx";
2
+ export declare function cn(...inputs: ClassValue[]): string;
3
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../src/lib/utils.ts"],"names":[],"mappings":"AAAA,OAAa,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAExC,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,UAEzC"}
@@ -0,0 +1,4 @@
1
+ import { TagOptions } from "vite-plugin-component-debugger";
2
+ import type { Plugin } from "vite";
3
+ export declare const inspectorDebugger: (options?: TagOptions) => Plugin<any>;
4
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugin.ts"],"names":[],"mappings":"AAAA,OAA0B,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AAC/E,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAEnC,eAAO,MAAM,iBAAiB,GAAI,UAAS,UAAe,KAAG,MAAM,CAAC,GAAG,CAOtE,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Zustand store for Inspector global state
3
+ */
4
+ import type { InspectorTheme, InspectorLabels } from "@promakeai/inspector-types";
5
+ interface InspectorStore {
6
+ theme: Required<InspectorTheme>;
7
+ labels: Required<InspectorLabels>;
8
+ setTheme: (theme: Partial<InspectorTheme>) => void;
9
+ setLabels: (labels: Partial<InspectorLabels>) => void;
10
+ }
11
+ export declare const useInspectorStore: import("zustand").UseBoundStore<import("zustand").StoreApi<InspectorStore>>;
12
+ export {};
13
+ //# sourceMappingURL=useInspectorStore.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useInspectorStore.d.ts","sourceRoot":"","sources":["../../../../../src/store/useInspectorStore.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,KAAK,EACV,cAAc,EACd,eAAe,EAChB,MAAM,4BAA4B,CAAC;AAEpC,UAAU,cAAc;IACtB,KAAK,EAAE,QAAQ,CAAC,cAAc,CAAC,CAAC;IAChC,MAAM,EAAE,QAAQ,CAAC,eAAe,CAAC,CAAC;IAClC,QAAQ,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,cAAc,CAAC,KAAK,IAAI,CAAC;IACnD,SAAS,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC,eAAe,CAAC,KAAK,IAAI,CAAC;CACvD;AAgND,eAAO,MAAM,iBAAiB,6EAW3B,CAAC"}
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Import this file to load inspector styles
3
+ */
4
+ import "./styles/global.css";
5
+ //# sourceMappingURL=styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../../src/styles.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,qBAAqB,CAAC"}
@@ -0,0 +1,49 @@
1
+ /**
2
+ * Color utility functions for converting between formats
3
+ */
4
+ /**
5
+ * Convert RGB color string to HEX format
6
+ * @example rgbToHex('rgb(255, 0, 0)') => '#ff0000'
7
+ */
8
+ export declare function rgbToHex(rgb: string): string;
9
+ /**
10
+ * Convert HEX color to RGB format
11
+ * @example hexToRgb('#ff0000') => 'rgb(255, 0, 0)'
12
+ */
13
+ export declare function hexToRgb(hex: string): string;
14
+ /**
15
+ * Convert HEX color to RGBA object
16
+ * @example hexToRgba('#ff0000') => { r: 255, g: 0, b: 0, a: 1 }
17
+ * @example hexToRgba('#f00') => { r: 255, g: 0, b: 0, a: 1 }
18
+ * @example hexToRgba('#ff000080') => { r: 255, g: 0, b: 0, a: 0.5 }
19
+ */
20
+ export declare function hexToRgba(hex: string): {
21
+ r: number;
22
+ g: number;
23
+ b: number;
24
+ a: number;
25
+ } | null;
26
+ /**
27
+ * Convert RGBA object to HEX format
28
+ * @example rgbaToHex({ r: 255, g: 0, b: 0, a: 1 }) => '#ff0000'
29
+ * @example rgbaToHex({ r: 255, g: 0, b: 0, a: 0.5 }) => '#ff000080'
30
+ */
31
+ export declare function rgbaToHex(rgba: {
32
+ r: number;
33
+ g: number;
34
+ b: number;
35
+ a: number;
36
+ }): string;
37
+ /**
38
+ * Validate if string is a valid hex color
39
+ */
40
+ export declare function isValidHex(hex: string): boolean;
41
+ /**
42
+ * Ensure color string has # prefix
43
+ */
44
+ export declare function ensureHashPrefix(color: string): string;
45
+ /**
46
+ * Get contrasting text color (black or white) for a background color
47
+ */
48
+ export declare function getContrastColor(hexColor: string): string;
49
+ //# sourceMappingURL=colorUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"colorUtils.d.ts","sourceRoot":"","sources":["../../../../../src/utils/colorUtils.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAU5C;AAED;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAU5C;AAED;;;;;GAKG;AACH,wBAAgB,SAAS,CACvB,GAAG,EAAE,MAAM,GACV;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CA4BvD;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE;IAC9B,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACX,GAAG,MAAM,CAiBT;AAED;;GAEG;AACH,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAE/C;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAItD;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAUzD"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Element name mapping utilities
3
+ * Maps HTML tags to user-friendly names
4
+ */
5
+ export declare const getElementDisplayName: (element: HTMLElement | Element, labels?: Record<string, string>) => string;
6
+ export declare const getElementLabel: (element: HTMLElement | Element, labels?: Record<string, string>) => string;
7
+ //# sourceMappingURL=elementNames.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"elementNames.d.ts","sourceRoot":"","sources":["../../../../../src/utils/elementNames.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA0CH,eAAO,MAAM,qBAAqB,GAChC,SAAS,WAAW,GAAG,OAAO,EAC9B,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAC9B,MAyCF,CAAC;AAEF,eAAO,MAAM,eAAe,GAC1B,SAAS,WAAW,GAAG,OAAO,EAC9B,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAC9B,MAQF,CAAC"}
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Element detection utilities for determining which style sections to show
3
+ */
4
+ /**
5
+ * Determine if a specific section should be shown for an element
6
+ */
7
+ export declare function shouldShowSection(element: HTMLElement, section: string): boolean;
8
+ /**
9
+ * Get element type for conditional rendering
10
+ */
11
+ export declare function getElementType(element: HTMLElement): string;
12
+ /**
13
+ * Check if element is a specific type
14
+ */
15
+ export declare function isElementType(element: HTMLElement, type: string): boolean;
16
+ /**
17
+ * Check if element can have text content
18
+ */
19
+ export declare function canHaveTextContent(element: HTMLElement): boolean;
20
+ /**
21
+ * Check if element is an image
22
+ */
23
+ export declare function isImage(element: HTMLElement): boolean;
24
+ /**
25
+ * Check if element is an anchor tag
26
+ */
27
+ export declare function isAnchor(element: HTMLElement): boolean;
28
+ //# sourceMappingURL=elementUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"elementUtils.d.ts","sourceRoot":"","sources":["../../../../../src/utils/elementUtils.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,MAAM,GACd,OAAO,CAuCT;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,WAAW,GAAG,MAAM,CAE3D;AAED;;GAEG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,WAAW,EACpB,IAAI,EAAE,MAAM,GACX,OAAO,CAET;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,WAAW,GAAG,OAAO,CAGhE;AAED;;GAEG;AACH,wBAAgB,OAAO,CAAC,OAAO,EAAE,WAAW,GAAG,OAAO,CAErD;AAED;;GAEG;AACH,wBAAgB,QAAQ,CAAC,OAAO,EAAE,WAAW,GAAG,OAAO,CAEtD"}
@@ -0,0 +1,48 @@
1
+ /**
2
+ * Error Tracker - Captures and reports all types of errors
3
+ */
4
+ export interface ErrorData {
5
+ type: "javascript" | "promise" | "console" | "vite";
6
+ message: string;
7
+ stack?: string;
8
+ fileName?: string;
9
+ lineNumber?: number;
10
+ columnNumber?: number;
11
+ frame?: string;
12
+ plugin?: string;
13
+ }
14
+ export type ErrorCallback = (error: ErrorData) => void;
15
+ export declare class ErrorTracker {
16
+ private callback;
17
+ private viteObserver;
18
+ constructor(callback: ErrorCallback);
19
+ /**
20
+ * Start tracking all error types
21
+ */
22
+ start(): void;
23
+ /**
24
+ * Stop tracking all errors
25
+ */
26
+ stop(): void;
27
+ /**
28
+ * Track JavaScript runtime errors
29
+ */
30
+ private trackJavaScriptErrors;
31
+ /**
32
+ * Track unhandled promise rejections
33
+ */
34
+ private trackPromiseRejections;
35
+ /**
36
+ * Track console.error calls
37
+ */
38
+ private trackConsoleErrors;
39
+ /**
40
+ * Track Vite dev server errors
41
+ */
42
+ private trackViteErrors;
43
+ /**
44
+ * Parse Vite error overlay content
45
+ */
46
+ private parseViteError;
47
+ }
48
+ //# sourceMappingURL=errorTracker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errorTracker.d.ts","sourceRoot":"","sources":["../../../../../src/utils/errorTracker.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,YAAY,GAAG,SAAS,GAAG,SAAS,GAAG,MAAM,CAAC;IACpD,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,aAAa,GAAG,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;AAEvD,qBAAa,YAAY;IACvB,OAAO,CAAC,QAAQ,CAAgB;IAChC,OAAO,CAAC,YAAY,CAAiC;gBAEzC,QAAQ,EAAE,aAAa;IAInC;;OAEG;IACH,KAAK;IAOL;;OAEG;IACH,IAAI;IASJ;;OAEG;IACH,OAAO,CAAC,qBAAqB;IAqB7B;;OAEG;IACH,OAAO,CAAC,sBAAsB;IAe9B;;OAEG;IACH,OAAO,CAAC,kBAAkB;IA4B1B;;OAEG;IACH,OAAO,CAAC,eAAe;IAuBvB;;OAEG;IACH,OAAO,CAAC,cAAc;CAoCvB"}
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Central input styling utilities
3
+ */
4
+ import type { InspectorTheme } from "@promakeai/inspector-types";
5
+ export declare const getInputContainerStyles: (theme: InspectorTheme) => {
6
+ backgroundColor: string | undefined;
7
+ borderColor: string | undefined;
8
+ };
9
+ export declare const getInputStyles: (theme: InspectorTheme) => {
10
+ backgroundColor: string;
11
+ color: string | undefined;
12
+ };
13
+ export declare const getLabelStyles: (theme: InspectorTheme) => {
14
+ color: string | undefined;
15
+ };
16
+ export declare const getSectionTitleStyles: (theme: InspectorTheme) => {
17
+ color: string | undefined;
18
+ };
19
+ export declare const INPUT_CONTAINER_CLASSES = "rounded-lg px-2 py-1 shadow-sm border";
20
+ export declare const INPUT_CLASSES = "text-xs border-none shadow-none focus-visible:ring-0 focus-visible:outline-none h-7 px-1.5";
21
+ export declare const LABEL_CLASSES = "block text-xs mb-1";
22
+ export declare const SECTION_TITLE_CLASSES = "text-sm font-semibold mb-2";
23
+ //# sourceMappingURL=inputStyles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"inputStyles.d.ts","sourceRoot":"","sources":["../../../../../src/utils/inputStyles.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAEjE,eAAO,MAAM,uBAAuB,GAAI,OAAO,cAAc;;;CAG3D,CAAC;AAEH,eAAO,MAAM,cAAc,GAAI,OAAO,cAAc;;;CAGlD,CAAC;AAEH,eAAO,MAAM,cAAc,GAAI,OAAO,cAAc;;CAElD,CAAC;AAEH,eAAO,MAAM,qBAAqB,GAAI,OAAO,cAAc;;CAEzD,CAAC;AAGH,eAAO,MAAM,uBAAuB,0CAA0C,CAAC;AAC/E,eAAO,MAAM,aAAa,+FAA+F,CAAC;AAC1H,eAAO,MAAM,aAAa,uBAAuB,CAAC;AAClD,eAAO,MAAM,qBAAqB,+BAA+B,CAAC"}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Style utility functions for parsing and converting styles
3
+ */
4
+ import type { StyleChanges } from "@promakeai/inspector-types";
5
+ /**
6
+ * Get element's own styles (inline + className styles) for input prefill
7
+ * Returns only explicitly defined styles, not inherited/computed defaults
8
+ */
9
+ export declare function getElementOwnStyles(element: HTMLElement): StyleChanges;
10
+ /**
11
+ * Convert StyleChanges to inline style object for React
12
+ * All values include !important flag for maximum specificity
13
+ */
14
+ export declare function convertToInlineStyle(styles: StyleChanges): Record<string, string>;
15
+ /**
16
+ * Parse pixel value from string
17
+ */
18
+ export declare function parsePixelValue(value: string): number;
19
+ /**
20
+ * Format number to pixel string
21
+ */
22
+ export declare function toPixelString(value: number): string;
23
+ /**
24
+ * Map StyleChanges property names to CSS property names for removeProperty()
25
+ */
26
+ export declare const stylePropToCSSProp: Record<keyof StyleChanges, string>;
27
+ //# sourceMappingURL=styleUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styleUtils.d.ts","sourceRoot":"","sources":["../../../../../src/utils/styleUtils.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAoB/D;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,WAAW,GAAG,YAAY,CAqDtE;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,YAAY,GACnB,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAmFxB;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAGrD;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAEnD;AAED;;GAEG;AACH,eAAO,MAAM,kBAAkB,EAAE,MAAM,CAAC,MAAM,YAAY,EAAE,MAAM,CAiCjE,CAAC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Tailwind Class Mapper - Convert style values to Tailwind class names
3
+ */
4
+ import type { StyleChanges } from '@promakeai/inspector-types';
5
+ /**
6
+ * Map style changes to Tailwind class names
7
+ */
8
+ export declare function mapStylesToTailwindClasses(styles: StyleChanges): string[];
9
+ //# sourceMappingURL=tailwindMapper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tailwindMapper.d.ts","sourceRoot":"","sources":["../../../../../src/utils/tailwindMapper.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE/D;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,YAAY,GAAG,MAAM,EAAE,CA6JzE"}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * URL Tracker - Monitors and reports URL changes
3
+ */
4
+ export interface UrlChangeData {
5
+ oldUrl: string;
6
+ newUrl: string;
7
+ timestamp: number;
8
+ }
9
+ export type UrlChangeCallback = (data: UrlChangeData) => void;
10
+ export declare class UrlTracker {
11
+ private callback;
12
+ private lastUrl;
13
+ constructor(callback: UrlChangeCallback);
14
+ /**
15
+ * Start tracking URL changes
16
+ */
17
+ start(): void;
18
+ /**
19
+ * Check if URL has changed and notify
20
+ */
21
+ private checkUrlChange;
22
+ /**
23
+ * Intercept history methods to catch programmatic navigation
24
+ */
25
+ private interceptHistoryMethods;
26
+ }
27
+ //# sourceMappingURL=urlTracker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"urlTracker.d.ts","sourceRoot":"","sources":["../../../../../src/utils/urlTracker.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,MAAM,iBAAiB,GAAG,CAAC,IAAI,EAAE,aAAa,KAAK,IAAI,CAAC;AAE9D,qBAAa,UAAU;IACrB,OAAO,CAAC,QAAQ,CAAoB;IACpC,OAAO,CAAC,OAAO,CAAS;gBAEZ,QAAQ,EAAE,iBAAiB;IAKvC;;OAEG;IACH,KAAK;IAeL;;OAEG;IACH,OAAO,CAAC,cAAc;IActB;;OAEG;IACH,OAAO,CAAC,uBAAuB;CAchC"}
@@ -0,0 +1 @@
1
+ {"root":["../../../src/app.tsx","../../../src/index.ts","../../../src/plugin.ts","../../../src/styles.ts","../../../src/vite-env.d.ts","../../../src/__tests__/app.test.tsx","../../../src/components/badge.tsx","../../../src/components/overlay.tsx","../../../src/components/controlbox/contentarea.tsx","../../../src/components/controlbox/promptinput.tsx","../../../src/components/controlbox/index.tsx","../../../src/components/imageeditor/uploadbox.tsx","../../../src/components/imageeditor/index.tsx","../../../src/components/styleeditor/bordersection.tsx","../../../src/components/styleeditor/colorpicker.tsx","../../../src/components/styleeditor/displaysection.tsx","../../../src/components/styleeditor/imagesection.tsx","../../../src/components/styleeditor/layoutsection.tsx","../../../src/components/styleeditor/numberinput.tsx","../../../src/components/styleeditor/sliderinput.tsx","../../../src/components/styleeditor/spacingsection.tsx","../../../src/components/styleeditor/textsection.tsx","../../../src/components/styleeditor/index.tsx","../../../src/components/texteditor/index.tsx","../../../src/components/ui/customcollapsible.tsx","../../../src/components/ui/button.tsx","../../../src/components/ui/color-picker.tsx","../../../src/components/ui/input.tsx","../../../src/components/ui/popover.tsx","../../../src/components/ui/select.tsx","../../../src/components/ui/slider.tsx","../../../src/components/ui/textarea.tsx","../../../src/components/ui/tooltip.tsx","../../../src/core/highlighter.ts","../../../src/hooks/usemessagebridge.ts","../../../src/hooks/usestylepreview.ts","../../../src/lib/utils.ts","../../../src/store/useinspectorstore.ts","../../../src/utils/colorutils.ts","../../../src/utils/elementnames.ts","../../../src/utils/elementutils.ts","../../../src/utils/errortracker.ts","../../../src/utils/inputstyles.ts","../../../src/utils/styleutils.ts","../../../src/utils/tailwindmapper.ts","../../../src/utils/urltracker.ts"],"version":"5.9.3"}