@codefluss/sandbox 0.0.1-alpha.1

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 (233) hide show
  1. package/CHANGELOG.md +75 -0
  2. package/README.md +413 -0
  3. package/dist/__tests__/auto-resize-script.test.d.ts +2 -0
  4. package/dist/__tests__/auto-resize-script.test.d.ts.map +1 -0
  5. package/dist/__tests__/auto-resize-script.test.js +49 -0
  6. package/dist/__tests__/auto-resize-script.test.js.map +1 -0
  7. package/dist/__tests__/sandbox-component.test.d.ts +2 -0
  8. package/dist/__tests__/sandbox-component.test.d.ts.map +1 -0
  9. package/dist/__tests__/sandbox-component.test.js +281 -0
  10. package/dist/__tests__/sandbox-component.test.js.map +1 -0
  11. package/dist/__tests__/sandbox-config.test.d.ts +2 -0
  12. package/dist/__tests__/sandbox-config.test.d.ts.map +1 -0
  13. package/dist/__tests__/sandbox-config.test.js +148 -0
  14. package/dist/__tests__/sandbox-config.test.js.map +1 -0
  15. package/dist/__tests__/sandbox-iframe.test.d.ts +2 -0
  16. package/dist/__tests__/sandbox-iframe.test.d.ts.map +1 -0
  17. package/dist/__tests__/sandbox-iframe.test.js +212 -0
  18. package/dist/__tests__/sandbox-iframe.test.js.map +1 -0
  19. package/dist/__tests__/setup.d.ts +2 -0
  20. package/dist/__tests__/setup.d.ts.map +1 -0
  21. package/dist/__tests__/setup.js +27 -0
  22. package/dist/__tests__/setup.js.map +1 -0
  23. package/dist/components/index.d.ts +5 -0
  24. package/dist/components/index.d.ts.map +1 -0
  25. package/dist/components/index.js +5 -0
  26. package/dist/components/index.js.map +1 -0
  27. package/dist/components/performance-wrapper.d.ts +12 -0
  28. package/dist/components/performance-wrapper.d.ts.map +1 -0
  29. package/dist/components/performance-wrapper.js +162 -0
  30. package/dist/components/performance-wrapper.js.map +1 -0
  31. package/dist/components/sandbox-component.d.ts +3 -0
  32. package/dist/components/sandbox-component.d.ts.map +1 -0
  33. package/dist/components/sandbox-component.js +123 -0
  34. package/dist/components/sandbox-component.js.map +1 -0
  35. package/dist/components/sandbox-iframe-cached.d.ts +3 -0
  36. package/dist/components/sandbox-iframe-cached.d.ts.map +1 -0
  37. package/dist/components/sandbox-iframe-cached.js +176 -0
  38. package/dist/components/sandbox-iframe-cached.js.map +1 -0
  39. package/dist/components/sandbox-iframe.d.ts +3 -0
  40. package/dist/components/sandbox-iframe.d.ts.map +1 -0
  41. package/dist/components/sandbox-iframe.js +131 -0
  42. package/dist/components/sandbox-iframe.js.map +1 -0
  43. package/dist/converters/auto-detect/auto-detect.d.ts +13 -0
  44. package/dist/converters/auto-detect/auto-detect.d.ts.map +1 -0
  45. package/dist/converters/auto-detect/auto-detect.js +224 -0
  46. package/dist/converters/auto-detect/auto-detect.js.map +1 -0
  47. package/dist/converters/auto-detect/index.d.ts +3 -0
  48. package/dist/converters/auto-detect/index.d.ts.map +1 -0
  49. package/dist/converters/auto-detect/index.js +2 -0
  50. package/dist/converters/auto-detect/index.js.map +1 -0
  51. package/dist/converters/codepen/codepen-converter.d.ts +9 -0
  52. package/dist/converters/codepen/codepen-converter.d.ts.map +1 -0
  53. package/dist/converters/codepen/codepen-converter.js +99 -0
  54. package/dist/converters/codepen/codepen-converter.js.map +1 -0
  55. package/dist/converters/codepen/index.d.ts +2 -0
  56. package/dist/converters/codepen/index.d.ts.map +1 -0
  57. package/dist/converters/codepen/index.js +2 -0
  58. package/dist/converters/codepen/index.js.map +1 -0
  59. package/dist/converters/gist/gist-converter.d.ts +31 -0
  60. package/dist/converters/gist/gist-converter.d.ts.map +1 -0
  61. package/dist/converters/gist/gist-converter.js +162 -0
  62. package/dist/converters/gist/gist-converter.js.map +1 -0
  63. package/dist/converters/gist/index.d.ts +2 -0
  64. package/dist/converters/gist/index.d.ts.map +1 -0
  65. package/dist/converters/gist/index.js +2 -0
  66. package/dist/converters/gist/index.js.map +1 -0
  67. package/dist/converters/shared/html-parser.d.ts +4 -0
  68. package/dist/converters/shared/html-parser.d.ts.map +1 -0
  69. package/dist/converters/shared/html-parser.js +39 -0
  70. package/dist/converters/shared/html-parser.js.map +1 -0
  71. package/dist/converters/shared/index.d.ts +4 -0
  72. package/dist/converters/shared/index.d.ts.map +1 -0
  73. package/dist/converters/shared/index.js +3 -0
  74. package/dist/converters/shared/index.js.map +1 -0
  75. package/dist/converters/shared/sanitization.d.ts +5 -0
  76. package/dist/converters/shared/sanitization.d.ts.map +1 -0
  77. package/dist/converters/shared/sanitization.js +176 -0
  78. package/dist/converters/shared/sanitization.js.map +1 -0
  79. package/dist/converters/shared/types.d.ts +23 -0
  80. package/dist/converters/shared/types.d.ts.map +1 -0
  81. package/dist/converters/shared/types.js +2 -0
  82. package/dist/converters/shared/types.js.map +1 -0
  83. package/dist/core/index.d.ts +13 -0
  84. package/dist/core/index.d.ts.map +1 -0
  85. package/dist/core/index.js +10 -0
  86. package/dist/core/index.js.map +1 -0
  87. package/dist/frameworks/__tests__/file-utils.test.d.ts +2 -0
  88. package/dist/frameworks/__tests__/file-utils.test.d.ts.map +1 -0
  89. package/dist/frameworks/__tests__/file-utils.test.js +408 -0
  90. package/dist/frameworks/__tests__/file-utils.test.js.map +1 -0
  91. package/dist/frameworks/__tests__/sandpack-wrapper.test.d.ts +2 -0
  92. package/dist/frameworks/__tests__/sandpack-wrapper.test.d.ts.map +1 -0
  93. package/dist/frameworks/__tests__/sandpack-wrapper.test.js +147 -0
  94. package/dist/frameworks/__tests__/sandpack-wrapper.test.js.map +1 -0
  95. package/dist/frameworks/file-utils.d.ts +20 -0
  96. package/dist/frameworks/file-utils.d.ts.map +1 -0
  97. package/dist/frameworks/file-utils.js +293 -0
  98. package/dist/frameworks/file-utils.js.map +1 -0
  99. package/dist/frameworks/framework-detector.d.ts +5 -0
  100. package/dist/frameworks/framework-detector.d.ts.map +1 -0
  101. package/dist/frameworks/framework-detector.js +117 -0
  102. package/dist/frameworks/framework-detector.js.map +1 -0
  103. package/dist/frameworks/index.d.ts +6 -0
  104. package/dist/frameworks/index.d.ts.map +1 -0
  105. package/dist/frameworks/index.js +5 -0
  106. package/dist/frameworks/index.js.map +1 -0
  107. package/dist/frameworks/sandpack-wrapper.d.ts +28 -0
  108. package/dist/frameworks/sandpack-wrapper.d.ts.map +1 -0
  109. package/dist/frameworks/sandpack-wrapper.js +55 -0
  110. package/dist/frameworks/sandpack-wrapper.js.map +1 -0
  111. package/dist/frameworks/templates/index.d.ts +8 -0
  112. package/dist/frameworks/templates/index.d.ts.map +1 -0
  113. package/dist/frameworks/templates/index.js +29 -0
  114. package/dist/frameworks/templates/index.js.map +1 -0
  115. package/dist/frameworks/templates/react-template.d.ts +3 -0
  116. package/dist/frameworks/templates/react-template.d.ts.map +1 -0
  117. package/dist/frameworks/templates/react-template.js +376 -0
  118. package/dist/frameworks/templates/react-template.js.map +1 -0
  119. package/dist/frameworks/templates/svelte-template.d.ts +3 -0
  120. package/dist/frameworks/templates/svelte-template.d.ts.map +1 -0
  121. package/dist/frameworks/templates/svelte-template.js +373 -0
  122. package/dist/frameworks/templates/svelte-template.js.map +1 -0
  123. package/dist/frameworks/templates/vanilla-template.d.ts +3 -0
  124. package/dist/frameworks/templates/vanilla-template.d.ts.map +1 -0
  125. package/dist/frameworks/templates/vanilla-template.js +455 -0
  126. package/dist/frameworks/templates/vanilla-template.js.map +1 -0
  127. package/dist/frameworks/templates/vue-template.d.ts +3 -0
  128. package/dist/frameworks/templates/vue-template.d.ts.map +1 -0
  129. package/dist/frameworks/templates/vue-template.js +388 -0
  130. package/dist/frameworks/templates/vue-template.js.map +1 -0
  131. package/dist/frameworks/types.d.ts +57 -0
  132. package/dist/frameworks/types.d.ts.map +1 -0
  133. package/dist/frameworks/types.js +2 -0
  134. package/dist/frameworks/types.js.map +1 -0
  135. package/dist/index.d.ts +7 -0
  136. package/dist/index.d.ts.map +1 -0
  137. package/dist/index.js +7 -0
  138. package/dist/index.js.map +1 -0
  139. package/dist/lib/performance-tracker.d.ts +45 -0
  140. package/dist/lib/performance-tracker.d.ts.map +1 -0
  141. package/dist/lib/performance-tracker.js +165 -0
  142. package/dist/lib/performance-tracker.js.map +1 -0
  143. package/dist/lib/sandbox-cache.d.ts +24 -0
  144. package/dist/lib/sandbox-cache.d.ts.map +1 -0
  145. package/dist/lib/sandbox-cache.js +138 -0
  146. package/dist/lib/sandbox-cache.js.map +1 -0
  147. package/dist/locales/de.json +72 -0
  148. package/dist/locales/en.json +72 -0
  149. package/dist/locales/index.d.ts +148 -0
  150. package/dist/locales/index.d.ts.map +1 -0
  151. package/dist/locales/index.js +7 -0
  152. package/dist/locales/index.js.map +1 -0
  153. package/dist/performance/sandpack-bundle-cache.d.ts +19 -0
  154. package/dist/performance/sandpack-bundle-cache.d.ts.map +1 -0
  155. package/dist/performance/sandpack-bundle-cache.js +48 -0
  156. package/dist/performance/sandpack-bundle-cache.js.map +1 -0
  157. package/dist/sandbox-config.d.ts +4 -0
  158. package/dist/sandbox-config.d.ts.map +1 -0
  159. package/dist/sandbox-config.js +235 -0
  160. package/dist/sandbox-config.js.map +1 -0
  161. package/dist/storage/__tests__/indexeddb-adapter.test.d.ts +2 -0
  162. package/dist/storage/__tests__/indexeddb-adapter.test.d.ts.map +1 -0
  163. package/dist/storage/__tests__/indexeddb-adapter.test.js +192 -0
  164. package/dist/storage/__tests__/indexeddb-adapter.test.js.map +1 -0
  165. package/dist/storage/__tests__/project-manager.test.d.ts +2 -0
  166. package/dist/storage/__tests__/project-manager.test.d.ts.map +1 -0
  167. package/dist/storage/__tests__/project-manager.test.js +266 -0
  168. package/dist/storage/__tests__/project-manager.test.js.map +1 -0
  169. package/dist/storage/index.d.ts +5 -0
  170. package/dist/storage/index.d.ts.map +1 -0
  171. package/dist/storage/index.js +4 -0
  172. package/dist/storage/index.js.map +1 -0
  173. package/dist/storage/indexeddb-adapter.d.ts +18 -0
  174. package/dist/storage/indexeddb-adapter.d.ts.map +1 -0
  175. package/dist/storage/indexeddb-adapter.js +232 -0
  176. package/dist/storage/indexeddb-adapter.js.map +1 -0
  177. package/dist/storage/project-manager.d.ts +35 -0
  178. package/dist/storage/project-manager.d.ts.map +1 -0
  179. package/dist/storage/project-manager.js +213 -0
  180. package/dist/storage/project-manager.js.map +1 -0
  181. package/dist/storage/types.d.ts +59 -0
  182. package/dist/storage/types.d.ts.map +1 -0
  183. package/dist/storage/types.js +2 -0
  184. package/dist/storage/types.js.map +1 -0
  185. package/dist/storage/zip-handler.d.ts +5 -0
  186. package/dist/storage/zip-handler.d.ts.map +1 -0
  187. package/dist/storage/zip-handler.js +200 -0
  188. package/dist/storage/zip-handler.js.map +1 -0
  189. package/dist/types/sandbox-types.d.ts +54 -0
  190. package/dist/types/sandbox-types.d.ts.map +1 -0
  191. package/dist/types/sandbox-types.js +2 -0
  192. package/dist/types/sandbox-types.js.map +1 -0
  193. package/dist/utils/__tests__/converters/auto-detect.test.d.ts +2 -0
  194. package/dist/utils/__tests__/converters/auto-detect.test.d.ts.map +1 -0
  195. package/dist/utils/__tests__/converters/auto-detect.test.js +381 -0
  196. package/dist/utils/__tests__/converters/auto-detect.test.js.map +1 -0
  197. package/dist/utils/__tests__/converters/codepen-converter.test.d.ts +2 -0
  198. package/dist/utils/__tests__/converters/codepen-converter.test.d.ts.map +1 -0
  199. package/dist/utils/__tests__/converters/codepen-converter.test.js +408 -0
  200. package/dist/utils/__tests__/converters/codepen-converter.test.js.map +1 -0
  201. package/dist/utils/__tests__/converters/gist-converter.test.d.ts +2 -0
  202. package/dist/utils/__tests__/converters/gist-converter.test.d.ts.map +1 -0
  203. package/dist/utils/__tests__/converters/gist-converter.test.js +458 -0
  204. package/dist/utils/__tests__/converters/gist-converter.test.js.map +1 -0
  205. package/dist/utils/__tests__/converters/html-parser.test.d.ts +2 -0
  206. package/dist/utils/__tests__/converters/html-parser.test.d.ts.map +1 -0
  207. package/dist/utils/__tests__/converters/html-parser.test.js +285 -0
  208. package/dist/utils/__tests__/converters/html-parser.test.js.map +1 -0
  209. package/dist/utils/__tests__/converters/sanitization.test.d.ts +2 -0
  210. package/dist/utils/__tests__/converters/sanitization.test.d.ts.map +1 -0
  211. package/dist/utils/__tests__/converters/sanitization.test.js +210 -0
  212. package/dist/utils/__tests__/converters/sanitization.test.js.map +1 -0
  213. package/dist/utils/auto-resize-script.d.ts +4 -0
  214. package/dist/utils/auto-resize-script.d.ts.map +1 -0
  215. package/dist/utils/auto-resize-script.js +125 -0
  216. package/dist/utils/auto-resize-script.js.map +1 -0
  217. package/dist/widgets/banner/BannerWidget.d.ts +15 -0
  218. package/dist/widgets/banner/BannerWidget.d.ts.map +1 -0
  219. package/dist/widgets/banner/BannerWidget.js +33 -0
  220. package/dist/widgets/banner/BannerWidget.js.map +1 -0
  221. package/dist/widgets/form/FormWidget.d.ts +23 -0
  222. package/dist/widgets/form/FormWidget.d.ts.map +1 -0
  223. package/dist/widgets/form/FormWidget.js +42 -0
  224. package/dist/widgets/form/FormWidget.js.map +1 -0
  225. package/dist/widgets/index.d.ts +8 -0
  226. package/dist/widgets/index.d.ts.map +1 -0
  227. package/dist/widgets/index.js +28 -0
  228. package/dist/widgets/index.js.map +1 -0
  229. package/dist/widgets/types.d.ts +28 -0
  230. package/dist/widgets/types.d.ts.map +1 -0
  231. package/dist/widgets/types.js +2 -0
  232. package/dist/widgets/types.js.map +1 -0
  233. package/package.json +116 -0
@@ -0,0 +1,29 @@
1
+ export { reactTemplate } from './react-template';
2
+ export { vueTemplate } from './vue-template';
3
+ export { svelteTemplate } from './svelte-template';
4
+ export { vanillaTemplate } from './vanilla-template';
5
+ import { reactTemplate } from './react-template';
6
+ import { vueTemplate } from './vue-template';
7
+ import { svelteTemplate } from './svelte-template';
8
+ import { vanillaTemplate } from './vanilla-template';
9
+ export function getTemplate(framework) {
10
+ switch (framework) {
11
+ case 'react':
12
+ return reactTemplate;
13
+ case 'vue':
14
+ return vueTemplate;
15
+ case 'svelte':
16
+ return svelteTemplate;
17
+ case 'vanilla':
18
+ return vanillaTemplate;
19
+ default:
20
+ return vanillaTemplate;
21
+ }
22
+ }
23
+ export const allTemplates = {
24
+ react: reactTemplate,
25
+ vue: vueTemplate,
26
+ svelte: svelteTemplate,
27
+ vanilla: vanillaTemplate,
28
+ };
29
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/frameworks/templates/index.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAMrD,MAAM,UAAU,WAAW,CAAC,SAAoB;IAC/C,QAAQ,SAAS,EAAE,CAAC;QACnB,KAAK,OAAO;YACX,OAAO,aAAa,CAAC;QACtB,KAAK,KAAK;YACT,OAAO,WAAW,CAAC;QACpB,KAAK,QAAQ;YACZ,OAAO,cAAc,CAAC;QACvB,KAAK,SAAS;YACb,OAAO,eAAe,CAAC;QACxB;YACC,OAAO,eAAe,CAAC;IACzB,CAAC;AACF,CAAC;AAKD,MAAM,CAAC,MAAM,YAAY,GAAyC;IACjE,KAAK,EAAE,aAAa;IACpB,GAAG,EAAE,WAAW;IAChB,MAAM,EAAE,cAAc;IACtB,OAAO,EAAE,eAAe;CACxB,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { FrameworkTemplate } from '../types';
2
+ export declare const reactTemplate: FrameworkTemplate;
3
+ //# sourceMappingURL=react-template.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"react-template.d.ts","sourceRoot":"","sources":["../../../src/frameworks/templates/react-template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAElD,eAAO,MAAM,aAAa,EAAE,iBAsX3B,CAAC"}
@@ -0,0 +1,376 @@
1
+ export const reactTemplate = {
2
+ id: 'react',
3
+ name: 'React',
4
+ description: 'React 18+ with modern hooks and TypeScript',
5
+ sandpackTemplate: 'vanilla',
6
+ files: {
7
+ '/index.js': {
8
+ code: `import React, { StrictMode } from 'react';
9
+ import { createRoot } from 'react-dom/client';
10
+ import App from './App.jsx';
11
+ import './styles.css';
12
+
13
+ const root = createRoot(document.getElementById('app'));
14
+
15
+ root.render(
16
+ <StrictMode>
17
+ <App />
18
+ </StrictMode>
19
+ );`,
20
+ },
21
+ '/App.jsx': {
22
+ code: `import React, { useState, useEffect } from 'react';
23
+
24
+ function App() {
25
+ const [count, setCount] = useState(0);
26
+ const [totalClicks, setTotalClicks] = useState(0);
27
+
28
+ useEffect(() => {
29
+ // Load from localStorage on mount
30
+ try {
31
+ const data = localStorage.getItem('react-counter-data');
32
+ if (data) {
33
+ const parsed = JSON.parse(data);
34
+ setCount(parsed.count || 0);
35
+ setTotalClicks(parsed.totalClicks || 0);
36
+ }
37
+ } catch (error) {
38
+ console.warn('Failed to load from localStorage:', error);
39
+ }
40
+ }, []);
41
+
42
+ const increment = () => {
43
+ setCount(prev => prev + 1);
44
+ setTotalClicks(prev => prev + 1);
45
+ };
46
+
47
+ const decrement = () => {
48
+ if (count > 0) {
49
+ setCount(prev => prev - 1);
50
+ setTotalClicks(prev => prev + 1);
51
+ }
52
+ };
53
+
54
+ const reset = () => {
55
+ setCount(0);
56
+ setTotalClicks(prev => prev + 1);
57
+ };
58
+
59
+ useEffect(() => {
60
+ // Save to localStorage whenever count changes
61
+ try {
62
+ const data = { count, totalClicks };
63
+ localStorage.setItem('react-counter-data', JSON.stringify(data));
64
+ } catch (error) {
65
+ console.warn('Failed to save to localStorage:', error);
66
+ }
67
+ }, [count, totalClicks]);
68
+
69
+ return (
70
+ <div className="app">
71
+ <header>
72
+ <h1>Hello React! 🎉</h1>
73
+ <p>Edit this component to see live updates.</p>
74
+ </header>
75
+
76
+ <main>
77
+ <section className="card">
78
+ <h2>Counter: <span id="count">{count}</span></h2>
79
+ <div className="button-group">
80
+ <button className="btn-primary" onClick={increment}>
81
+ <span>+</span> Increment
82
+ </button>
83
+ <button className="btn-secondary" onClick={decrement}>
84
+ <span>-</span> Decrement
85
+ </button>
86
+ <button className="btn-outline" onClick={reset}>
87
+ Reset
88
+ </button>
89
+ </div>
90
+ <div className="stats">
91
+ <small>Total clicks: {totalClicks}</small>
92
+ </div>
93
+ </section>
94
+
95
+ <section className="card">
96
+ <h3>Modern React Features</h3>
97
+ <ul>
98
+ <li>✅ React 18+ Hooks</li>
99
+ <li>✅ TypeScript Support</li>
100
+ <li>✅ LocalStorage Persistence</li>
101
+ <li>✅ Event Handling</li>
102
+ <li>✅ Vite Build System</li>
103
+ </ul>
104
+ </section>
105
+ </main>
106
+ </div>
107
+ );
108
+ }
109
+
110
+ export default App;`,
111
+ },
112
+ '/styles.css': {
113
+ code: `/* Modern React App Styles - Same as Vue Template */
114
+
115
+ * {
116
+ box-sizing: border-box;
117
+ margin: 0;
118
+ padding: 0;
119
+ }
120
+
121
+ body {
122
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
123
+ line-height: 1.6;
124
+ color: #333;
125
+ background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
126
+ min-height: 100vh;
127
+ padding: 2rem;
128
+ }
129
+
130
+ .app {
131
+ max-width: 800px;
132
+ margin: 0 auto;
133
+ background: white;
134
+ border-radius: 12px;
135
+ box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
136
+ padding: 2rem;
137
+ }
138
+
139
+ header {
140
+ text-align: center;
141
+ margin-bottom: 3rem;
142
+ }
143
+
144
+ h1 {
145
+ font-size: clamp(2rem, 5vw, 3rem);
146
+ font-weight: 800;
147
+ margin-bottom: 0.5rem;
148
+ background: linear-gradient(135deg, #61dafb, #6366f1);
149
+ -webkit-background-clip: text;
150
+ background-clip: text;
151
+ -webkit-text-fill-color: transparent;
152
+ animation: titleGlow 3s ease-in-out infinite alternate;
153
+ }
154
+
155
+ @keyframes titleGlow {
156
+ from { filter: drop-shadow(0 0 20px rgba(97, 218, 251, 0.3)); }
157
+ to { filter: drop-shadow(0 0 30px rgba(97, 218, 251, 0.3)); }
158
+ }
159
+
160
+ p {
161
+ color: #64748b;
162
+ font-size: 1.1rem;
163
+ margin-bottom: 2rem;
164
+ }
165
+
166
+ .card {
167
+ background: white;
168
+ border: 1px solid #e2e8f0;
169
+ border-radius: 12px;
170
+ padding: 2rem;
171
+ margin-bottom: 2rem;
172
+ box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
173
+ transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
174
+ }
175
+
176
+ .card:hover {
177
+ box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
178
+ transform: translateY(-2px);
179
+ }
180
+
181
+ .card h2 {
182
+ font-size: 2rem;
183
+ font-weight: 700;
184
+ margin-bottom: 1.5rem;
185
+ text-align: center;
186
+ color: #1e293b;
187
+ }
188
+
189
+ .card h3 {
190
+ font-size: 1.5rem;
191
+ font-weight: 600;
192
+ margin-bottom: 1rem;
193
+ color: #1e293b;
194
+ }
195
+
196
+ #count {
197
+ display: inline-block;
198
+ font-weight: 800;
199
+ font-size: 2.5rem;
200
+ color: #61dafb;
201
+ text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
202
+ transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
203
+ min-width: 100px;
204
+ }
205
+
206
+ .button-group {
207
+ display: flex;
208
+ gap: 1rem;
209
+ justify-content: center;
210
+ margin: 2rem 0;
211
+ flex-wrap: wrap;
212
+ }
213
+
214
+ button {
215
+ display: inline-flex;
216
+ align-items: center;
217
+ gap: 0.5rem;
218
+ padding: 0.875rem 1.5rem;
219
+ font-size: 1rem;
220
+ font-weight: 600;
221
+ border: 2px solid transparent;
222
+ border-radius: 8px;
223
+ cursor: pointer;
224
+ transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
225
+ position: relative;
226
+ overflow: hidden;
227
+ white-space: nowrap;
228
+ }
229
+
230
+ button::before {
231
+ content: '';
232
+ position: absolute;
233
+ top: 0;
234
+ left: -100%;
235
+ width: 100%;
236
+ height: 100%;
237
+ background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
238
+ transition: left 0.5s;
239
+ }
240
+
241
+ button:hover::before {
242
+ left: 100%;
243
+ }
244
+
245
+ button:active {
246
+ transform: scale(0.95);
247
+ }
248
+
249
+ button span {
250
+ font-size: 1.2rem;
251
+ font-weight: 700;
252
+ }
253
+
254
+ .btn-primary {
255
+ background: #61dafb;
256
+ color: #333;
257
+ border-color: #61dafb;
258
+ }
259
+
260
+ .btn-primary:hover {
261
+ background: #4fa8c5;
262
+ border-color: #4fa8c5;
263
+ box-shadow: 0 4px 12px rgba(97, 218, 251, 0.3);
264
+ }
265
+
266
+ .btn-secondary {
267
+ background: #6366f1;
268
+ color: white;
269
+ border-color: #6366f1;
270
+ }
271
+
272
+ .btn-secondary:hover {
273
+ background: #4f46e5;
274
+ box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
275
+ }
276
+
277
+ .btn-outline {
278
+ background: transparent;
279
+ color: #64748b;
280
+ border-color: #e2e8f0;
281
+ }
282
+
283
+ .btn-outline:hover {
284
+ background: #f8fafc;
285
+ color: #ef4444;
286
+ border-color: #ef4444;
287
+ }
288
+
289
+ .stats {
290
+ text-align: center;
291
+ margin-top: 1.5rem;
292
+ padding-top: 1.5rem;
293
+ border-top: 1px solid #e2e8f0;
294
+ }
295
+
296
+ .stats small {
297
+ color: #64748b;
298
+ font-size: 0.875rem;
299
+ text-transform: uppercase;
300
+ letter-spacing: 0.05em;
301
+ }
302
+
303
+ ul {
304
+ list-style: none;
305
+ padding: 0;
306
+ }
307
+
308
+ li {
309
+ padding: 0.5rem 0;
310
+ color: #64748b;
311
+ border-bottom: 1px solid #e2e8f0;
312
+ }
313
+
314
+ li:last-child {
315
+ border-bottom: none;
316
+ }
317
+
318
+ /* Focus styles */
319
+ button:focus-visible {
320
+ outline: 2px solid #61dafb;
321
+ outline-offset: 2px;
322
+ }
323
+
324
+ /* Responsive design */
325
+ @media (max-width: 768px) {
326
+ body {
327
+ padding: 1rem;
328
+ }
329
+
330
+ .app {
331
+ padding: 1.5rem;
332
+ }
333
+
334
+ .button-group {
335
+ flex-direction: column;
336
+ align-items: center;
337
+ }
338
+
339
+ button {
340
+ width: 100%;
341
+ max-width: 200px;
342
+ }
343
+ }`,
344
+ },
345
+ '/index.html': {
346
+ code: `<!DOCTYPE html>
347
+ <html lang="en">
348
+ <head>
349
+ <meta charset="UTF-8" />
350
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
351
+ <title>React App</title>
352
+ </head>
353
+ <body>
354
+ <div id="app"></div>
355
+ <script type="module" src="/index.js"></script>
356
+ </body>
357
+ </html>`,
358
+ },
359
+ },
360
+ dependencies: {
361
+ react: '^18.2.0',
362
+ 'react-dom': '^18.2.0',
363
+ },
364
+ devDependencies: {
365
+ '@types/react': '^18.2.0',
366
+ '@types/react-dom': '^18.2.0',
367
+ typescript: '^5.0.0',
368
+ },
369
+ config: {
370
+ entry: '/src/main.jsx',
371
+ main: '/src/App.jsx',
372
+ showConsole: true,
373
+ showDevTools: false,
374
+ },
375
+ };
376
+ //# sourceMappingURL=react-template.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"react-template.js","sourceRoot":"","sources":["../../../src/frameworks/templates/react-template.ts"],"names":[],"mappings":"AAYA,MAAM,CAAC,MAAM,aAAa,GAAsB;IAC/C,EAAE,EAAE,OAAO;IACX,IAAI,EAAE,OAAO;IACb,WAAW,EAAE,4CAA4C;IACzD,gBAAgB,EAAE,SAAS;IAC3B,KAAK,EAAE;QACN,WAAW,EAAE;YACZ,IAAI,EAAE;;;;;;;;;;;GAWN;SACA;QACD,UAAU,EAAE;YACX,IAAI,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAwFW;SACjB;QACD,aAAa,EAAE;YACd,IAAI,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsOP;SACC;QACD,aAAa,EAAE;YACd,IAAI,EAAE;;;;;;;;;;;QAWD;SACL;KACD;IACD,YAAY,EAAE;QACb,KAAK,EAAE,SAAS;QAChB,WAAW,EAAE,SAAS;KACtB;IACD,eAAe,EAAE;QAChB,cAAc,EAAE,SAAS;QACzB,kBAAkB,EAAE,SAAS;QAC7B,UAAU,EAAE,QAAQ;KACpB;IACD,MAAM,EAAE;QACP,KAAK,EAAE,eAAe;QACtB,IAAI,EAAE,cAAc;QACpB,WAAW,EAAE,IAAI;QACjB,YAAY,EAAE,KAAK;KACnB;CACD,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { FrameworkTemplate } from '../types';
2
+ export declare const svelteTemplate: FrameworkTemplate;
3
+ //# sourceMappingURL=svelte-template.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"svelte-template.d.ts","sourceRoot":"","sources":["../../../src/frameworks/templates/svelte-template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAElD,eAAO,MAAM,cAAc,EAAE,iBAmX5B,CAAC"}