@jjlmoya/utils-developer 1.11.0 → 1.13.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 (100) hide show
  1. package/package.json +7 -4
  2. package/scripts/postinstall.mjs +27 -0
  3. package/src/entries.ts +74 -0
  4. package/src/tool/aspectRatio/aspect-ratio-calculator.css +276 -0
  5. package/src/tool/aspectRatio/component.astro +0 -278
  6. package/src/tool/aspectRatio/entry.ts +30 -0
  7. package/src/tool/aspectRatio/index.ts +2 -32
  8. package/src/tool/calculadoraTiempoDatos/component.astro +0 -524
  9. package/src/tool/calculadoraTiempoDatos/data-time-calculator-web-speed-impact.css +522 -0
  10. package/src/tool/calculadoraTiempoDatos/entry.ts +29 -0
  11. package/src/tool/calculadoraTiempoDatos/index.ts +2 -31
  12. package/src/tool/colorConverter/color-converter-rgb-hex-hsl.css +262 -0
  13. package/src/tool/colorConverter/component.astro +0 -264
  14. package/src/tool/colorConverter/entry.ts +29 -0
  15. package/src/tool/colorConverter/index.ts +2 -31
  16. package/src/tool/conversorExcelCsvHtml/component.astro +0 -360
  17. package/src/tool/conversorExcelCsvHtml/entry.ts +29 -0
  18. package/src/tool/conversorExcelCsvHtml/excel-csv-html-table-converter.css +358 -0
  19. package/src/tool/conversorExcelCsvHtml/index.ts +2 -31
  20. package/src/tool/cronGenerator/component.astro +0 -317
  21. package/src/tool/cronGenerator/cron.css +315 -0
  22. package/src/tool/cronGenerator/entry.ts +30 -0
  23. package/src/tool/cronGenerator/index.ts +2 -32
  24. package/src/tool/cssSpecificityCalculator/component.astro +0 -205
  25. package/src/tool/cssSpecificityCalculator/css-specificity-calculator.css +203 -0
  26. package/src/tool/cssSpecificityCalculator/entry.ts +30 -0
  27. package/src/tool/cssSpecificityCalculator/index.ts +2 -32
  28. package/src/tool/cssToInlineConverter/component.astro +0 -150
  29. package/src/tool/cssToInlineConverter/css-to-inline-converter.css +148 -0
  30. package/src/tool/cssToInlineConverter/entry.ts +30 -0
  31. package/src/tool/cssToInlineConverter/index.ts +2 -32
  32. package/src/tool/duplicateCssRemover/component.astro +0 -197
  33. package/src/tool/duplicateCssRemover/duplicate-css-remover.css +195 -0
  34. package/src/tool/duplicateCssRemover/entry.ts +30 -0
  35. package/src/tool/duplicateCssRemover/index.ts +2 -32
  36. package/src/tool/generadorSecurityTxt/component.astro +0 -231
  37. package/src/tool/generadorSecurityTxt/entry.ts +29 -0
  38. package/src/tool/generadorSecurityTxt/index.ts +2 -31
  39. package/src/tool/generadorSecurityTxt/security-txt-generator-rfc-9116.css +229 -0
  40. package/src/tool/hashGenerator/component.astro +0 -229
  41. package/src/tool/hashGenerator/entry.ts +29 -0
  42. package/src/tool/hashGenerator/hash-generator.css +227 -0
  43. package/src/tool/hashGenerator/index.ts +2 -31
  44. package/src/tool/inspectorCertificadosSsl/component.astro +0 -261
  45. package/src/tool/inspectorCertificadosSsl/entry.ts +45 -0
  46. package/src/tool/inspectorCertificadosSsl/index.ts +2 -47
  47. package/src/tool/inspectorCertificadosSsl/ssl-tls-certificate-inspector.css +259 -0
  48. package/src/tool/jsonFormatter/component.astro +0 -346
  49. package/src/tool/jsonFormatter/entry.ts +30 -0
  50. package/src/tool/jsonFormatter/index.ts +2 -32
  51. package/src/tool/jsonFormatter/json-formatter.css +344 -0
  52. package/src/tool/keycode/component.astro +0 -298
  53. package/src/tool/keycode/entry.ts +30 -0
  54. package/src/tool/keycode/index.ts +2 -32
  55. package/src/tool/keycode/keycode.css +296 -0
  56. package/src/tool/llmCostCalculator/component.astro +0 -253
  57. package/src/tool/llmCostCalculator/entry.ts +46 -0
  58. package/src/tool/llmCostCalculator/index.ts +2 -48
  59. package/src/tool/llmCostCalculator/llm-cost-calculator.css +251 -0
  60. package/src/tool/mobileMockupGenerator/component.astro +0 -906
  61. package/src/tool/mobileMockupGenerator/entry.ts +45 -0
  62. package/src/tool/mobileMockupGenerator/index.ts +2 -47
  63. package/src/tool/mobileMockupGenerator/mobile-mockup-generator.css +904 -0
  64. package/src/tool/musicalTypography/component.astro +0 -291
  65. package/src/tool/musicalTypography/entry.ts +29 -0
  66. package/src/tool/musicalTypography/index.ts +2 -31
  67. package/src/tool/musicalTypography/musical-typography.css +289 -0
  68. package/src/tool/placeholderGenerator/component.astro +0 -255
  69. package/src/tool/placeholderGenerator/entry.ts +46 -0
  70. package/src/tool/placeholderGenerator/index.ts +2 -48
  71. package/src/tool/placeholderGenerator/placeholder-image-generator.css +253 -0
  72. package/src/tool/promptLibrary/component.astro +0 -689
  73. package/src/tool/promptLibrary/entry.ts +45 -0
  74. package/src/tool/promptLibrary/index.ts +2 -47
  75. package/src/tool/promptLibrary/prompt-library.css +687 -0
  76. package/src/tool/readabilityCalculator/component.astro +0 -322
  77. package/src/tool/readabilityCalculator/entry.ts +45 -0
  78. package/src/tool/readabilityCalculator/index.ts +2 -47
  79. package/src/tool/readabilityCalculator/visual-readability-calculator-wcag-apca.css +320 -0
  80. package/src/tool/svgSanitizer/component.astro +0 -289
  81. package/src/tool/svgSanitizer/entry.ts +45 -0
  82. package/src/tool/svgSanitizer/index.ts +2 -47
  83. package/src/tool/svgSanitizer/svg-sanitizer.css +287 -0
  84. package/src/tool/svgToCss/component.astro +0 -196
  85. package/src/tool/svgToCss/entry.ts +30 -0
  86. package/src/tool/svgToCss/index.ts +2 -32
  87. package/src/tool/svgToCss/svg-to-css-converter.css +194 -0
  88. package/src/tool/urlCleaner/component.astro +0 -282
  89. package/src/tool/urlCleaner/entry.ts +45 -0
  90. package/src/tool/urlCleaner/index.ts +2 -47
  91. package/src/tool/urlCleaner/url-tracking-cleaner.css +280 -0
  92. package/src/tool/urlEncoderDecoder/component.astro +0 -168
  93. package/src/tool/urlEncoderDecoder/entry.ts +30 -0
  94. package/src/tool/urlEncoderDecoder/index.ts +2 -32
  95. package/src/tool/urlEncoderDecoder/url-encoder-decoder.css +166 -0
  96. package/src/tool/utmGenerator/component.astro +0 -156
  97. package/src/tool/utmGenerator/entry.ts +29 -0
  98. package/src/tool/utmGenerator/index.ts +2 -31
  99. package/src/tool/utmGenerator/utm-generator.css +154 -0
  100. package/src/tools.ts +1 -1
package/package.json CHANGED
@@ -1,15 +1,17 @@
1
1
  {
2
2
  "name": "@jjlmoya/utils-developer",
3
- "version": "1.11.0",
3
+ "version": "1.13.0",
4
4
  "type": "module",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
7
7
  "exports": {
8
8
  ".": "./src/index.ts",
9
- "./data": "./src/data.ts"
9
+ "./data": "./src/data.ts",
10
+ "./entries": "./src/entries.ts"
10
11
  },
11
12
  "files": [
12
- "src"
13
+ "src",
14
+ "scripts"
13
15
  ],
14
16
  "publishConfig": {
15
17
  "access": "public"
@@ -28,7 +30,8 @@
28
30
  "postversion": "git push && git push --tags",
29
31
  "patch": "npm version patch",
30
32
  "minor": "npm version minor",
31
- "major": "npm version major"
33
+ "major": "npm version major",
34
+ "postinstall": "node scripts/postinstall.mjs"
32
35
  },
33
36
  "lint-staged": {
34
37
  "*.{ts,tsx,astro}": [
@@ -0,0 +1,27 @@
1
+ import { readFileSync, writeFileSync, mkdirSync, readdirSync } from 'fs';
2
+ import { join, dirname } from 'path';
3
+ import { fileURLToPath } from 'url';
4
+
5
+ const libDir = dirname(fileURLToPath(import.meta.url));
6
+ const toolsDir = join(libDir, '../src/tool');
7
+
8
+ const inNodeModules = libDir.includes('node_modules');
9
+ if (!inNodeModules) process.exit(0);
10
+
11
+ const projectRoot = join(libDir, '../../../..');
12
+ const categoryKey = JSON.parse(readFileSync(join(libDir, '../package.json'), 'utf8')).name.replace('@jjlmoya/utils-', '');
13
+ const destDir = join(projectRoot, `public/styles/lib/${categoryKey}`);
14
+
15
+ mkdirSync(destDir, { recursive: true });
16
+
17
+ const tools = readdirSync(toolsDir, { withFileTypes: true }).filter(d => d.isDirectory());
18
+ for (const tool of tools) {
19
+ const toolDir = join(toolsDir, tool.name);
20
+ let files;
21
+ try { files = readdirSync(toolDir).filter(f => f.endsWith('.css')); }
22
+ catch { continue; }
23
+ for (const file of files) {
24
+ writeFileSync(join(destDir, file), readFileSync(join(toolDir, file)));
25
+ console.log(`[@jjlmoya/utils-${categoryKey}] copied ${file}`);
26
+ }
27
+ }
package/src/entries.ts ADDED
@@ -0,0 +1,74 @@
1
+ export { aspectRatio } from './tool/aspectRatio/entry';
2
+ export type { AspectRatioLocaleContent } from './tool/aspectRatio/entry';
3
+ export { calculadoraTiempoDatos } from './tool/calculadoraTiempoDatos/entry';
4
+ export type { CalculadoraTiempoDatosLocaleContent } from './tool/calculadoraTiempoDatos/entry';
5
+ export { colorConverter } from './tool/colorConverter/entry';
6
+ export type { ColorConverterLocaleContent } from './tool/colorConverter/entry';
7
+ export { conversorExcelCsvHtml } from './tool/conversorExcelCsvHtml/entry';
8
+ export type { ConversorExcelCsvHtmlLocaleContent } from './tool/conversorExcelCsvHtml/entry';
9
+ export { cronGenerator } from './tool/cronGenerator/entry';
10
+ export type { CronGeneratorLocaleContent } from './tool/cronGenerator/entry';
11
+ export { cssSpecificityCalculator } from './tool/cssSpecificityCalculator/entry';
12
+ export type { CssSpecificityCalculatorLocaleContent } from './tool/cssSpecificityCalculator/entry';
13
+ export { cssToInlineConverter } from './tool/cssToInlineConverter/entry';
14
+ export type { CssToInlineConverterLocaleContent } from './tool/cssToInlineConverter/entry';
15
+ export { duplicateCssRemover } from './tool/duplicateCssRemover/entry';
16
+ export type { DuplicateCssRemoverLocaleContent } from './tool/duplicateCssRemover/entry';
17
+ export { generadorSecurityTxt } from './tool/generadorSecurityTxt/entry';
18
+ export type { GeneradorSecurityTxtLocaleContent } from './tool/generadorSecurityTxt/entry';
19
+ export { hashGenerator } from './tool/hashGenerator/entry';
20
+ export type { HashGeneratorLocaleContent } from './tool/hashGenerator/entry';
21
+ export { inspectorCertificadosSsl } from './tool/inspectorCertificadosSsl/entry';
22
+ export type { InspectorCertificadosSslLocaleContent } from './tool/inspectorCertificadosSsl/entry';
23
+ export { jsonFormatter } from './tool/jsonFormatter/entry';
24
+ export type { JsonFormatterLocaleContent } from './tool/jsonFormatter/entry';
25
+ export { keycode } from './tool/keycode/entry';
26
+ export type { KeycodeLocaleContent } from './tool/keycode/entry';
27
+ export { llmCostCalculator } from './tool/llmCostCalculator/entry';
28
+ export type { LlmCostCalculatorLocaleContent } from './tool/llmCostCalculator/entry';
29
+ export { mobileMockupGenerator } from './tool/mobileMockupGenerator/entry';
30
+ export type { MobileMockupGeneratorLocaleContent } from './tool/mobileMockupGenerator/entry';
31
+ export { musicalTypography } from './tool/musicalTypography/entry';
32
+ export type { MusicalTypographyLocaleContent } from './tool/musicalTypography/entry';
33
+ export { placeholderGenerator } from './tool/placeholderGenerator/entry';
34
+ export type { PlaceholderGeneratorLocaleContent } from './tool/placeholderGenerator/entry';
35
+ export { promptLibrary } from './tool/promptLibrary/entry';
36
+ export type { PromptLibraryLocaleContent } from './tool/promptLibrary/entry';
37
+ export { readabilityCalculator } from './tool/readabilityCalculator/entry';
38
+ export type { ReadabilityCalculatorLocaleContent } from './tool/readabilityCalculator/entry';
39
+ export { svgSanitizer } from './tool/svgSanitizer/entry';
40
+ export type { SvgSanitizerLocaleContent } from './tool/svgSanitizer/entry';
41
+ export { svgToCss } from './tool/svgToCss/entry';
42
+ export type { SvgToCssLocaleContent } from './tool/svgToCss/entry';
43
+ export { urlCleaner } from './tool/urlCleaner/entry';
44
+ export type { UrlCleanerLocaleContent } from './tool/urlCleaner/entry';
45
+ export { urlEncoderDecoder } from './tool/urlEncoderDecoder/entry';
46
+ export type { UrlEncoderDecoderLocaleContent } from './tool/urlEncoderDecoder/entry';
47
+ export { utmGenerator } from './tool/utmGenerator/entry';
48
+ export type { UtmGeneratorLocaleContent } from './tool/utmGenerator/entry';
49
+ export { developerCategory } from './category';
50
+ import { aspectRatio } from './tool/aspectRatio/entry';
51
+ import { calculadoraTiempoDatos } from './tool/calculadoraTiempoDatos/entry';
52
+ import { colorConverter } from './tool/colorConverter/entry';
53
+ import { conversorExcelCsvHtml } from './tool/conversorExcelCsvHtml/entry';
54
+ import { cronGenerator } from './tool/cronGenerator/entry';
55
+ import { cssSpecificityCalculator } from './tool/cssSpecificityCalculator/entry';
56
+ import { cssToInlineConverter } from './tool/cssToInlineConverter/entry';
57
+ import { duplicateCssRemover } from './tool/duplicateCssRemover/entry';
58
+ import { generadorSecurityTxt } from './tool/generadorSecurityTxt/entry';
59
+ import { hashGenerator } from './tool/hashGenerator/entry';
60
+ import { inspectorCertificadosSsl } from './tool/inspectorCertificadosSsl/entry';
61
+ import { jsonFormatter } from './tool/jsonFormatter/entry';
62
+ import { keycode } from './tool/keycode/entry';
63
+ import { llmCostCalculator } from './tool/llmCostCalculator/entry';
64
+ import { mobileMockupGenerator } from './tool/mobileMockupGenerator/entry';
65
+ import { musicalTypography } from './tool/musicalTypography/entry';
66
+ import { placeholderGenerator } from './tool/placeholderGenerator/entry';
67
+ import { promptLibrary } from './tool/promptLibrary/entry';
68
+ import { readabilityCalculator } from './tool/readabilityCalculator/entry';
69
+ import { svgSanitizer } from './tool/svgSanitizer/entry';
70
+ import { svgToCss } from './tool/svgToCss/entry';
71
+ import { urlCleaner } from './tool/urlCleaner/entry';
72
+ import { urlEncoderDecoder } from './tool/urlEncoderDecoder/entry';
73
+ import { utmGenerator } from './tool/utmGenerator/entry';
74
+ export const ALL_ENTRIES = [aspectRatio, calculadoraTiempoDatos, colorConverter, conversorExcelCsvHtml, cronGenerator, cssSpecificityCalculator, cssToInlineConverter, duplicateCssRemover, generadorSecurityTxt, hashGenerator, inspectorCertificadosSsl, jsonFormatter, keycode, llmCostCalculator, mobileMockupGenerator, musicalTypography, placeholderGenerator, promptLibrary, readabilityCalculator, svgSanitizer, svgToCss, urlCleaner, urlEncoderDecoder, utmGenerator];
@@ -0,0 +1,276 @@
1
+ .arc-container {
2
+ --arc-primary: #0ea5e9;
3
+ --arc-secondary: #8b5cf6;
4
+ --arc-bg: #f8fafc;
5
+ --arc-card-bg: #fff;
6
+ --arc-text: #0f172a;
7
+ --arc-text-muted: #64748b;
8
+ --arc-border: #e2e8f0;
9
+ --arc-input-bg: #f1f5f9;
10
+ --arc-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
11
+ --arc-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
12
+ --arc-shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
13
+
14
+ max-width: 1100px;
15
+ margin: 4rem auto;
16
+ color: var(--arc-text);
17
+ }
18
+
19
+ :global(.theme-dark) .arc-container {
20
+ --arc-bg: #0f172a;
21
+ --arc-card-bg: #1e293b;
22
+ --arc-text: #f8fafc;
23
+ --arc-text-muted: #94a3b8;
24
+ --arc-border: #334155;
25
+ --arc-input-bg: #0f172a;
26
+ }
27
+
28
+ .arc-layout {
29
+ display: grid;
30
+ grid-template-columns: 1fr;
31
+ gap: 2rem;
32
+ }
33
+
34
+ @media (min-width: 992px) {
35
+ .arc-layout {
36
+ grid-template-columns: 420px 1fr;
37
+ }
38
+ }
39
+
40
+ .arc-panel {
41
+ background: var(--arc-card-bg);
42
+ border: 1px solid var(--arc-border);
43
+ border-radius: 1.5rem;
44
+ padding: 2.5rem;
45
+ box-shadow: var(--arc-shadow-lg);
46
+ display: flex;
47
+ flex-direction: column;
48
+ gap: 2.5rem;
49
+ }
50
+
51
+ .arc-title-group {
52
+ display: flex;
53
+ align-items: center;
54
+ gap: 0.75rem;
55
+ }
56
+
57
+ .arc-icon-box {
58
+ width: 40px;
59
+ height: 40px;
60
+ background: linear-gradient(135deg, var(--arc-primary), var(--arc-secondary));
61
+ border-radius: 0.75rem;
62
+ display: flex;
63
+ align-items: center;
64
+ justify-content: center;
65
+ color: white;
66
+ box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
67
+ }
68
+
69
+ .arc-panel-title {
70
+ font-size: 1.5rem;
71
+ font-weight: 800;
72
+ margin: 0;
73
+ letter-spacing: -0.025em;
74
+ }
75
+
76
+ .arc-section {
77
+ display: flex;
78
+ flex-direction: column;
79
+ gap: 1.5rem;
80
+ }
81
+
82
+ .arc-section-header {
83
+ font-size: 0.875rem;
84
+ font-weight: 700;
85
+ color: var(--arc-primary);
86
+ text-transform: uppercase;
87
+ letter-spacing: 0.1em;
88
+ }
89
+
90
+ .arc-input-grid {
91
+ display: grid;
92
+ grid-template-columns: 1fr auto 1fr;
93
+ align-items: center;
94
+ gap: 1rem;
95
+ }
96
+
97
+ .arc-field {
98
+ display: flex;
99
+ flex-direction: column;
100
+ gap: 0.5rem;
101
+ }
102
+
103
+ .arc-label {
104
+ font-size: 0.75rem;
105
+ font-weight: 600;
106
+ color: var(--arc-text-muted);
107
+ }
108
+
109
+ .arc-input {
110
+ width: 100%;
111
+ background: var(--arc-input-bg);
112
+ border: 2px solid var(--arc-border);
113
+ border-radius: 1rem;
114
+ padding: 1rem;
115
+ font-size: 1.25rem;
116
+ font-weight: 700;
117
+ color: var(--arc-text);
118
+ text-align: center;
119
+ outline: none;
120
+ transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
121
+ }
122
+
123
+ .arc-input:focus {
124
+ border-color: var(--arc-primary);
125
+ background: var(--arc-card-bg);
126
+ box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.1);
127
+ }
128
+
129
+ .arc-separator {
130
+ font-size: 1.5rem;
131
+ font-weight: 900;
132
+ opacity: 0.3;
133
+ padding-top: 1.5rem;
134
+ }
135
+
136
+ .arc-presets {
137
+ display: grid;
138
+ grid-template-columns: repeat(3, 1fr);
139
+ gap: 0.5rem;
140
+ }
141
+
142
+ .arc-preset-btn {
143
+ background: var(--arc-input-bg);
144
+ border: 1px solid var(--arc-border);
145
+ border-radius: 0.75rem;
146
+ padding: 0.6rem;
147
+ font-size: 0.75rem;
148
+ font-weight: 700;
149
+ color: var(--arc-text);
150
+ cursor: pointer;
151
+ transition: all 0.2s;
152
+ }
153
+
154
+ .arc-preset-btn:hover {
155
+ background: var(--arc-primary);
156
+ color: white;
157
+ border-color: var(--arc-primary);
158
+ transform: translateY(-2px);
159
+ box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
160
+ }
161
+
162
+ .arc-preview-panel {
163
+ background: var(--arc-input-bg);
164
+ border: 1px solid var(--arc-border);
165
+ border-radius: 1.5rem;
166
+ display: flex;
167
+ flex-direction: column;
168
+ overflow: hidden;
169
+ position: relative;
170
+ }
171
+
172
+ .arc-preview-header {
173
+ padding: 1.5rem 2rem;
174
+ background: var(--arc-card-bg);
175
+ border-bottom: 1px solid var(--arc-border);
176
+ display: flex;
177
+ justify-content: space-between;
178
+ align-items: center;
179
+ }
180
+
181
+ .arc-preview-title {
182
+ font-size: 1rem;
183
+ font-weight: 700;
184
+ display: flex;
185
+ align-items: center;
186
+ gap: 0.5rem;
187
+ }
188
+
189
+ .arc-badge {
190
+ background: rgba(14, 165, 233, 0.1);
191
+ color: var(--arc-primary);
192
+ padding: 0.25rem 0.75rem;
193
+ border-radius: 2rem;
194
+ font-size: 0.75rem;
195
+ font-weight: 800;
196
+ }
197
+
198
+ .arc-viewport {
199
+ flex: 1;
200
+ display: flex;
201
+ align-items: center;
202
+ justify-content: center;
203
+ padding: 3rem;
204
+ min-height: 500px;
205
+ background-image: radial-gradient(var(--arc-border) 1px, transparent 1px);
206
+ background-size: 30px 30px;
207
+ }
208
+
209
+ .arc-box {
210
+ background: linear-gradient(45deg, var(--arc-primary), var(--arc-secondary));
211
+ border-radius: 1rem;
212
+ box-shadow: var(--arc-shadow-lg);
213
+ display: flex;
214
+ flex-direction: column;
215
+ align-items: center;
216
+ justify-content: center;
217
+ color: white;
218
+ transition:
219
+ width 0.5s cubic-bezier(0.34, 1.56, 0.64, 1),
220
+ height 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
221
+ position: relative;
222
+ border: 1px solid rgba(255, 255, 255, 0.2);
223
+ overflow: hidden;
224
+ }
225
+
226
+ .arc-box::before {
227
+ content: "";
228
+ position: absolute;
229
+ inset: 0;
230
+ background: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.1' fill-rule='evenodd'%3E%3Ccircle cx='3' cy='3' r='3'/%3E%3Ccircle cx='13' cy='13' r='3'/%3E%3C/g%3E%3C/svg%3E");
231
+ opacity: 0.2;
232
+ }
233
+
234
+ .arc-box-ratio {
235
+ font-size: 2.5rem;
236
+ font-weight: 900;
237
+ text-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
238
+ z-index: 1;
239
+ }
240
+
241
+ .arc-box-res {
242
+ font-size: 0.875rem;
243
+ font-weight: 600;
244
+ opacity: 0.9;
245
+ background: rgba(0, 0, 0, 0.2);
246
+ padding: 0.4rem 1rem;
247
+ border-radius: 2rem;
248
+ margin-top: 1rem;
249
+ z-index: 1;
250
+ }
251
+
252
+ .arc-status {
253
+ position: absolute;
254
+ bottom: 1.5rem;
255
+ left: 1.5rem;
256
+ right: 1.5rem;
257
+ display: flex;
258
+ justify-content: space-between;
259
+ font-size: 0.75rem;
260
+ font-weight: 600;
261
+ color: var(--arc-text-muted);
262
+ }
263
+
264
+ .arc-status-item {
265
+ display: flex;
266
+ align-items: center;
267
+ gap: 0.5rem;
268
+ }
269
+
270
+ .arc-dot {
271
+ width: 6px;
272
+ height: 6px;
273
+ border-radius: 50%;
274
+ background: var(--arc-primary);
275
+ box-shadow: 0 0 8px var(--arc-primary);
276
+ }
@@ -99,284 +99,6 @@ const t = (ui ?? {}) as AspectRatioUI;
99
99
  </div>
100
100
  </div>
101
101
 
102
- <style>
103
- .arc-container {
104
- --arc-primary: #0ea5e9;
105
- --arc-secondary: #8b5cf6;
106
- --arc-bg: #f8fafc;
107
- --arc-card-bg: #fff;
108
- --arc-text: #0f172a;
109
- --arc-text-muted: #64748b;
110
- --arc-border: #e2e8f0;
111
- --arc-input-bg: #f1f5f9;
112
- --arc-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
113
- --arc-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
114
- --arc-shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
115
-
116
- max-width: 1100px;
117
- margin: 4rem auto;
118
- color: var(--arc-text);
119
- }
120
-
121
- :global(.theme-dark) .arc-container {
122
- --arc-bg: #0f172a;
123
- --arc-card-bg: #1e293b;
124
- --arc-text: #f8fafc;
125
- --arc-text-muted: #94a3b8;
126
- --arc-border: #334155;
127
- --arc-input-bg: #0f172a;
128
- }
129
-
130
- .arc-layout {
131
- display: grid;
132
- grid-template-columns: 1fr;
133
- gap: 2rem;
134
- }
135
-
136
- @media (min-width: 992px) {
137
- .arc-layout {
138
- grid-template-columns: 420px 1fr;
139
- }
140
- }
141
-
142
- .arc-panel {
143
- background: var(--arc-card-bg);
144
- border: 1px solid var(--arc-border);
145
- border-radius: 1.5rem;
146
- padding: 2.5rem;
147
- box-shadow: var(--arc-shadow-lg);
148
- display: flex;
149
- flex-direction: column;
150
- gap: 2.5rem;
151
- }
152
-
153
- .arc-title-group {
154
- display: flex;
155
- align-items: center;
156
- gap: 0.75rem;
157
- }
158
-
159
- .arc-icon-box {
160
- width: 40px;
161
- height: 40px;
162
- background: linear-gradient(135deg, var(--arc-primary), var(--arc-secondary));
163
- border-radius: 0.75rem;
164
- display: flex;
165
- align-items: center;
166
- justify-content: center;
167
- color: white;
168
- box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
169
- }
170
-
171
- .arc-panel-title {
172
- font-size: 1.5rem;
173
- font-weight: 800;
174
- margin: 0;
175
- letter-spacing: -0.025em;
176
- }
177
-
178
- .arc-section {
179
- display: flex;
180
- flex-direction: column;
181
- gap: 1.5rem;
182
- }
183
-
184
- .arc-section-header {
185
- font-size: 0.875rem;
186
- font-weight: 700;
187
- color: var(--arc-primary);
188
- text-transform: uppercase;
189
- letter-spacing: 0.1em;
190
- }
191
-
192
- .arc-input-grid {
193
- display: grid;
194
- grid-template-columns: 1fr auto 1fr;
195
- align-items: center;
196
- gap: 1rem;
197
- }
198
-
199
- .arc-field {
200
- display: flex;
201
- flex-direction: column;
202
- gap: 0.5rem;
203
- }
204
-
205
- .arc-label {
206
- font-size: 0.75rem;
207
- font-weight: 600;
208
- color: var(--arc-text-muted);
209
- }
210
-
211
- .arc-input {
212
- width: 100%;
213
- background: var(--arc-input-bg);
214
- border: 2px solid var(--arc-border);
215
- border-radius: 1rem;
216
- padding: 1rem;
217
- font-size: 1.25rem;
218
- font-weight: 700;
219
- color: var(--arc-text);
220
- text-align: center;
221
- outline: none;
222
- transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
223
- }
224
-
225
- .arc-input:focus {
226
- border-color: var(--arc-primary);
227
- background: var(--arc-card-bg);
228
- box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.1);
229
- }
230
-
231
- .arc-separator {
232
- font-size: 1.5rem;
233
- font-weight: 900;
234
- opacity: 0.3;
235
- padding-top: 1.5rem;
236
- }
237
-
238
- .arc-presets {
239
- display: grid;
240
- grid-template-columns: repeat(3, 1fr);
241
- gap: 0.5rem;
242
- }
243
-
244
- .arc-preset-btn {
245
- background: var(--arc-input-bg);
246
- border: 1px solid var(--arc-border);
247
- border-radius: 0.75rem;
248
- padding: 0.6rem;
249
- font-size: 0.75rem;
250
- font-weight: 700;
251
- color: var(--arc-text);
252
- cursor: pointer;
253
- transition: all 0.2s;
254
- }
255
-
256
- .arc-preset-btn:hover {
257
- background: var(--arc-primary);
258
- color: white;
259
- border-color: var(--arc-primary);
260
- transform: translateY(-2px);
261
- box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
262
- }
263
-
264
- .arc-preview-panel {
265
- background: var(--arc-input-bg);
266
- border: 1px solid var(--arc-border);
267
- border-radius: 1.5rem;
268
- display: flex;
269
- flex-direction: column;
270
- overflow: hidden;
271
- position: relative;
272
- }
273
-
274
- .arc-preview-header {
275
- padding: 1.5rem 2rem;
276
- background: var(--arc-card-bg);
277
- border-bottom: 1px solid var(--arc-border);
278
- display: flex;
279
- justify-content: space-between;
280
- align-items: center;
281
- }
282
-
283
- .arc-preview-title {
284
- font-size: 1rem;
285
- font-weight: 700;
286
- display: flex;
287
- align-items: center;
288
- gap: 0.5rem;
289
- }
290
-
291
- .arc-badge {
292
- background: rgba(14, 165, 233, 0.1);
293
- color: var(--arc-primary);
294
- padding: 0.25rem 0.75rem;
295
- border-radius: 2rem;
296
- font-size: 0.75rem;
297
- font-weight: 800;
298
- }
299
-
300
- .arc-viewport {
301
- flex: 1;
302
- display: flex;
303
- align-items: center;
304
- justify-content: center;
305
- padding: 3rem;
306
- min-height: 500px;
307
- background-image: radial-gradient(var(--arc-border) 1px, transparent 1px);
308
- background-size: 30px 30px;
309
- }
310
-
311
- .arc-box {
312
- background: linear-gradient(45deg, var(--arc-primary), var(--arc-secondary));
313
- border-radius: 1rem;
314
- box-shadow: var(--arc-shadow-lg);
315
- display: flex;
316
- flex-direction: column;
317
- align-items: center;
318
- justify-content: center;
319
- color: white;
320
- transition:
321
- width 0.5s cubic-bezier(0.34, 1.56, 0.64, 1),
322
- height 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
323
- position: relative;
324
- border: 1px solid rgba(255, 255, 255, 0.2);
325
- overflow: hidden;
326
- }
327
-
328
- .arc-box::before {
329
- content: "";
330
- position: absolute;
331
- inset: 0;
332
- background: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.1' fill-rule='evenodd'%3E%3Ccircle cx='3' cy='3' r='3'/%3E%3Ccircle cx='13' cy='13' r='3'/%3E%3C/g%3E%3C/svg%3E");
333
- opacity: 0.2;
334
- }
335
-
336
- .arc-box-ratio {
337
- font-size: 2.5rem;
338
- font-weight: 900;
339
- text-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
340
- z-index: 1;
341
- }
342
-
343
- .arc-box-res {
344
- font-size: 0.875rem;
345
- font-weight: 600;
346
- opacity: 0.9;
347
- background: rgba(0, 0, 0, 0.2);
348
- padding: 0.4rem 1rem;
349
- border-radius: 2rem;
350
- margin-top: 1rem;
351
- z-index: 1;
352
- }
353
-
354
- .arc-status {
355
- position: absolute;
356
- bottom: 1.5rem;
357
- left: 1.5rem;
358
- right: 1.5rem;
359
- display: flex;
360
- justify-content: space-between;
361
- font-size: 0.75rem;
362
- font-weight: 600;
363
- color: var(--arc-text-muted);
364
- }
365
-
366
- .arc-status-item {
367
- display: flex;
368
- align-items: center;
369
- gap: 0.5rem;
370
- }
371
-
372
- .arc-dot {
373
- width: 6px;
374
- height: 6px;
375
- border-radius: 50%;
376
- background: var(--arc-primary);
377
- box-shadow: 0 0 8px var(--arc-primary);
378
- }
379
- </style>
380
102
 
381
103
  <script>
382
104
  const rwInput = document.getElementById('arc-ratio-w') as HTMLInputElement;