@tsparticles/template-login 4.1.3 → 4.2.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 (69) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/README.md +3 -0
  3. package/package.json +4 -3
  4. package/template/angular/package.json +34 -0
  5. package/template/angular/src/app/app.component.css +151 -0
  6. package/template/angular/src/app/app.component.html +32 -0
  7. package/template/angular/src/app/app.component.ts +105 -0
  8. package/template/angular/src/app/app.module.ts +13 -0
  9. package/template/angular-confetti/package.json +36 -0
  10. package/template/angular-confetti/src/app/app.component.css +151 -0
  11. package/template/angular-confetti/src/app/app.component.html +32 -0
  12. package/template/angular-confetti/src/app/app.component.ts +105 -0
  13. package/template/angular-confetti/src/app/app.module.ts +13 -0
  14. package/template/angular-fireworks/package.json +36 -0
  15. package/template/angular-fireworks/src/app/app.component.css +151 -0
  16. package/template/angular-fireworks/src/app/app.component.html +32 -0
  17. package/template/angular-fireworks/src/app/app.component.ts +105 -0
  18. package/template/angular-fireworks/src/app/app.module.ts +13 -0
  19. package/template/astro/package.json +22 -0
  20. package/template/astro/src/pages/index.astro +173 -0
  21. package/template/ember/app/templates/application.hbs +61 -0
  22. package/template/ember/package.json +42 -0
  23. package/template/inferno/package.json +24 -0
  24. package/template/inferno/src/App.css +151 -0
  25. package/template/inferno/src/App.tsx +158 -0
  26. package/template/jquery/package.json +22 -0
  27. package/template/jquery/src/main.ts +110 -0
  28. package/template/jquery/src/style.css +151 -0
  29. package/template/lit/package.json +22 -0
  30. package/template/lit/src/my-app.ts +143 -0
  31. package/template/nextjs/package.json +25 -0
  32. package/template/nextjs/src/app/page.tsx +168 -0
  33. package/template/nextjs/src/app/providers.tsx +13 -0
  34. package/template/nuxt2/package.json +17 -0
  35. package/template/nuxt2/pages/index.vue +303 -0
  36. package/template/nuxt3/app.vue +288 -0
  37. package/template/nuxt3/package.json +21 -0
  38. package/template/nuxt4/app.vue +288 -0
  39. package/template/nuxt4/package.json +21 -0
  40. package/template/preact/package.json +23 -0
  41. package/template/preact/src/App.css +151 -0
  42. package/template/preact/src/App.tsx +140 -0
  43. package/template/qwik/package.json +22 -0
  44. package/template/qwik/src/App.tsx +139 -0
  45. package/template/react/package.json +19 -0
  46. package/template/react/src/App.css +151 -0
  47. package/template/react/src/App.tsx +140 -0
  48. package/template/riot/package.json +24 -0
  49. package/template/riot/src/app.riot +156 -0
  50. package/template/solid/package.json +18 -0
  51. package/template/solid/src/App.tsx +169 -0
  52. package/template/solid/src/index.css +151 -0
  53. package/template/solid/src/main.tsx +9 -0
  54. package/template/stencil/package.json +20 -0
  55. package/template/stencil/src/components/app-home/app-home.tsx +164 -0
  56. package/template/svelte/package.json +20 -0
  57. package/template/svelte/src/App.svelte +325 -0
  58. package/template/svelte/src/main.ts +12 -0
  59. package/template/vanilla/LICENSE +21 -0
  60. package/template/vanilla/package.json +1 -1
  61. package/template/vanilla/src/main.ts +1 -1
  62. package/template/vue2/package.json +24 -0
  63. package/template/vue2/src/App.vue +287 -0
  64. package/template/vue3/package.json +19 -0
  65. package/template/vue3/src/App.vue +286 -0
  66. package/template/vue3/src/main.ts +14 -0
  67. package/template/webcomponents/package.json +21 -0
  68. package/template/webcomponents/src/main.ts +125 -0
  69. package/template/webcomponents/src/style.css +151 -0
@@ -0,0 +1,325 @@
1
+ <script lang="ts">
2
+ import Particles from "@tsparticles/svelte";
3
+ import type { ISourceOptions } from "@tsparticles/engine";
4
+
5
+ let isLogin = $state(true);
6
+ let email = $state("");
7
+ let password = $state("");
8
+ let confirmPassword = $state("");
9
+ let emailError = $state("");
10
+ let passwordError = $state("");
11
+ let confirmError = $state("");
12
+ let theme = $state("dark");
13
+
14
+ function validateEmail(value: string): boolean {
15
+ return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(value);
16
+ }
17
+
18
+ function setTheme(value: string): void {
19
+ theme = value;
20
+ document.documentElement.setAttribute("data-theme", value);
21
+ localStorage.setItem("theme", value);
22
+ }
23
+
24
+ function toggleTheme(): void {
25
+ setTheme(theme === "dark" ? "light" : "dark");
26
+ }
27
+
28
+ const savedTheme = typeof localStorage !== "undefined" ? localStorage.getItem("theme") || "dark" : "dark";
29
+ setTheme(savedTheme);
30
+
31
+ function validate(): boolean {
32
+ let valid = true;
33
+
34
+ if (!email || !validateEmail(email)) {
35
+ emailError = "Please enter a valid email address";
36
+ valid = false;
37
+ } else {
38
+ emailError = "";
39
+ }
40
+
41
+ if (!password || password.length < 6) {
42
+ passwordError = "Password must be at least 6 characters";
43
+ valid = false;
44
+ } else {
45
+ passwordError = "";
46
+ }
47
+
48
+ if (!isLogin) {
49
+ if (password !== confirmPassword) {
50
+ confirmError = "Passwords do not match";
51
+ valid = false;
52
+ } else {
53
+ confirmError = "";
54
+ }
55
+ }
56
+
57
+ return valid;
58
+ }
59
+
60
+ function toggleMode(): void {
61
+ isLogin = !isLogin;
62
+ emailError = "";
63
+ passwordError = "";
64
+ confirmError = "";
65
+ }
66
+
67
+ function handleSubmit(e: Event): void {
68
+ e.preventDefault();
69
+
70
+ if (!validate()) {
71
+ return;
72
+ }
73
+
74
+ if (isLogin) {
75
+ alert("Logged in successfully! (demo)");
76
+ } else {
77
+ alert("Account created successfully! (demo)");
78
+ isLogin = true;
79
+ }
80
+
81
+ email = "";
82
+ password = "";
83
+ confirmPassword = "";
84
+ }
85
+
86
+ const options: ISourceOptions = {
87
+ background: { color: { value: "transparent" } },
88
+ fpsLimit: 60,
89
+ particles: {
90
+ number: { value: 60, density: { enable: true } },
91
+ color: { value: ["#6c5ce7", "#a29bfe", "#fd79a8", "#00cec9"] },
92
+ shape: { type: "circle" },
93
+ opacity: { value: 0.5, random: true },
94
+ size: { value: { min: 1, max: 3 }, random: true },
95
+ move: {
96
+ enable: true,
97
+ speed: 1,
98
+ direction: "none",
99
+ random: true,
100
+ straight: false,
101
+ outModes: { default: "out" },
102
+ },
103
+ },
104
+ interactivity: {
105
+ events: {
106
+ onHover: { enable: true, mode: "bubble" },
107
+ },
108
+ modes: {
109
+ bubble: { distance: 200, size: 6, duration: 2, opacity: 0.8 },
110
+ },
111
+ },
112
+ detectRetina: true,
113
+ };
114
+ </script>
115
+
116
+ <div class="auth-container">
117
+ <div class="auth-card">
118
+ <div class="auth-header">
119
+ <h1>{isLogin ? "Login" : "Register"}</h1>
120
+ <button class="theme-btn" onclick={toggleTheme}>
121
+ {theme === "dark" ? "🌙" : "☀️"}
122
+ </button>
123
+ </div>
124
+
125
+ <form onsubmit={handleSubmit}>
126
+ <div class="form-group">
127
+ <label for="email">Email</label>
128
+ <input
129
+ id="email"
130
+ type="email"
131
+ placeholder="your@email.com"
132
+ bind:value={email}
133
+ />
134
+ <span class="error">{emailError}</span>
135
+ </div>
136
+
137
+ <div class="form-group">
138
+ <label for="password">Password</label>
139
+ <input
140
+ id="password"
141
+ type="password"
142
+ placeholder="Enter password"
143
+ bind:value={password}
144
+ />
145
+ <span class="error">{passwordError}</span>
146
+ </div>
147
+
148
+ {#if !isLogin}
149
+ <div class="form-group">
150
+ <label for="confirmPassword">Confirm Password</label>
151
+ <input
152
+ id="confirmPassword"
153
+ type="password"
154
+ placeholder="Confirm password"
155
+ bind:value={confirmPassword}
156
+ />
157
+ <span class="error">{confirmError}</span>
158
+ </div>
159
+ {/if}
160
+
161
+ <button type="submit">{isLogin ? "Sign In" : "Create Account"}</button>
162
+ </form>
163
+
164
+ <div class="toggle-text">
165
+ {isLogin ? "Don't have an account?" : "Already have an account?"}
166
+ <a href="#" onclick={toggleMode}>{isLogin ? "Register" : "Login"}</a>
167
+ </div>
168
+ </div>
169
+ </div>
170
+
171
+ <Particles id="tsparticles" options={options} />
172
+
173
+ <style>
174
+ :global(:root) {
175
+ --bg: #0f0f1a;
176
+ --card-bg: rgba(255, 255, 255, 0.05);
177
+ --text: #fff;
178
+ --border: rgba(255, 255, 255, 0.1);
179
+ --input-bg: rgba(255, 255, 255, 0.08);
180
+ --accent: #6c5ce7;
181
+ --accent-hover: #a29bfe;
182
+ --error: #e74c3c;
183
+ }
184
+
185
+ :global([data-theme="light"]) {
186
+ --bg: #f0f0f5;
187
+ --card-bg: rgba(255, 255, 255, 0.8);
188
+ --text: #1a1a2e;
189
+ --border: rgba(0, 0, 0, 0.1);
190
+ --input-bg: rgba(0, 0, 0, 0.05);
191
+ }
192
+
193
+ :global(*) {
194
+ box-sizing: border-box;
195
+ }
196
+
197
+ :global(body) {
198
+ margin: 0;
199
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
200
+ background: var(--bg);
201
+ color: var(--text);
202
+ transition: background 0.3s, color 0.3s;
203
+ }
204
+
205
+ .auth-container {
206
+ position: absolute;
207
+ top: 50%;
208
+ left: 50%;
209
+ transform: translate(-50%, -50%);
210
+ z-index: 10;
211
+ width: 100%;
212
+ max-width: 400px;
213
+ padding: 1rem;
214
+ }
215
+
216
+ .auth-card {
217
+ background: var(--card-bg);
218
+ backdrop-filter: blur(10px);
219
+ border: 1px solid var(--border);
220
+ border-radius: 16px;
221
+ padding: 2rem;
222
+ box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
223
+ }
224
+
225
+ .auth-header {
226
+ display: flex;
227
+ justify-content: space-between;
228
+ align-items: center;
229
+ margin-bottom: 1.5rem;
230
+ }
231
+
232
+ .auth-header h1 {
233
+ margin: 0;
234
+ font-size: 1.8em;
235
+ }
236
+
237
+ .theme-btn {
238
+ background: none;
239
+ border: 1px solid var(--border);
240
+ border-radius: 8px;
241
+ padding: 0.4em 0.6em;
242
+ font-size: 1.2em;
243
+ cursor: pointer;
244
+ transition: background 0.2s;
245
+ }
246
+
247
+ .theme-btn:hover {
248
+ background: var(--input-bg);
249
+ }
250
+
251
+ .form-group {
252
+ margin-bottom: 1rem;
253
+ }
254
+
255
+ label {
256
+ display: block;
257
+ margin-bottom: 0.3em;
258
+ font-size: 0.9em;
259
+ opacity: 0.8;
260
+ }
261
+
262
+ input {
263
+ width: 100%;
264
+ padding: 0.7em 1em;
265
+ font-size: 1em;
266
+ border: 1px solid var(--border);
267
+ border-radius: 8px;
268
+ background: var(--input-bg);
269
+ color: var(--text);
270
+ outline: none;
271
+ transition: border-color 0.2s;
272
+ }
273
+
274
+ input:focus {
275
+ border-color: var(--accent);
276
+ }
277
+
278
+ input::placeholder {
279
+ color: var(--text);
280
+ opacity: 0.4;
281
+ }
282
+
283
+ .error {
284
+ display: block;
285
+ margin-top: 0.3em;
286
+ font-size: 0.8em;
287
+ color: var(--error);
288
+ min-height: 1em;
289
+ }
290
+
291
+ button[type="submit"] {
292
+ width: 100%;
293
+ padding: 0.8em;
294
+ font-size: 1em;
295
+ font-weight: 600;
296
+ border: none;
297
+ border-radius: 8px;
298
+ background: var(--accent);
299
+ color: #fff;
300
+ cursor: pointer;
301
+ transition: background 0.2s;
302
+ margin-top: 0.5rem;
303
+ }
304
+
305
+ button[type="submit"]:hover {
306
+ background: var(--accent-hover);
307
+ }
308
+
309
+ .toggle-text {
310
+ text-align: center;
311
+ margin-top: 1.5rem;
312
+ font-size: 0.9em;
313
+ opacity: 0.7;
314
+ }
315
+
316
+ .toggle-text a {
317
+ color: var(--accent);
318
+ text-decoration: none;
319
+ margin-left: 0.3em;
320
+ }
321
+
322
+ .toggle-text a:hover {
323
+ text-decoration: underline;
324
+ }
325
+ </style>
@@ -0,0 +1,12 @@
1
+ import { mount } from "svelte";
2
+ import { initParticlesEngine } from "@tsparticles/svelte";
3
+ import { loadSlim } from "@tsparticles/slim";
4
+ import App from "./App.svelte";
5
+
6
+ void initParticlesEngine(async (engine) => {
7
+ await loadSlim(engine);
8
+ });
9
+
10
+ const app = mount(App, { target: document.getElementById("app")! });
11
+
12
+ export default app;
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 Matteo Bruni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -1,5 +1,5 @@
1
1
  {
2
- "name": "{{projectName}}",
2
+ "name": "{{packageName}}",
3
3
  "private": true,
4
4
  "version": "1.0.0",
5
5
  "type": "module",
@@ -37,7 +37,7 @@ setTheme(savedTheme);
37
37
  themeToggle.addEventListener("click", toggleTheme);
38
38
 
39
39
  function validateEmail(email: string): boolean {
40
- return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(email);
40
+ return /^[^\s@]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)+$/.test(email);
41
41
  }
42
42
 
43
43
  function validate(): boolean {
@@ -0,0 +1,24 @@
1
+ {
2
+ "name": "{{packageName}}",
3
+ "private": true,
4
+ "version": "1.0.0",
5
+ "type": "module",
6
+ "scripts": {
7
+ "dev": "vite",
8
+ "build": "vite build",
9
+ "preview": "vite preview"
10
+ },
11
+ "dependencies": {
12
+ "vue": "^2.7.16",
13
+ "@tsparticles/vue2": "^4.1.3",
14
+ "@tsparticles/slim": "^4.1.3",
15
+ "@tsparticles/configs": "^4.1.3",
16
+ "@tsparticles/engine": "^4.1.3"
17
+ },
18
+ "devDependencies": {
19
+ "@vitejs/plugin-vue2": "^2.0.1",
20
+ "vue-template-compiler": "^2.7.16",
21
+ "typescript": "^5.7.2",
22
+ "vite": "^6.0.0"
23
+ }
24
+ }
@@ -0,0 +1,287 @@
1
+ <template>
2
+ <div>
3
+ <vue-particles id="tsparticles" :options="options" />
4
+ <div class="auth-container">
5
+ <div class="auth-card">
6
+ <div class="auth-header">
7
+ <h1>{{ isLogin ? 'Login' : 'Register' }}</h1>
8
+ <button class="theme-btn" @click="toggleTheme" aria-label="Toggle theme">{{ theme === 'dark' ? '🌙' : '☀️' }}</button>
9
+ </div>
10
+ <form @submit="handleSubmit" novalidate>
11
+ <div class="form-group">
12
+ <label for="email">Email</label>
13
+ <input id="email" v-model="email" type="email" placeholder="you@example.com" required />
14
+ <span class="error">{{ emailErr }}</span>
15
+ </div>
16
+ <div class="form-group">
17
+ <label for="password">Password</label>
18
+ <input id="password" v-model="password" type="password" placeholder="Enter password" required />
19
+ <span class="error">{{ passErr }}</span>
20
+ </div>
21
+ <div v-if="!isLogin" class="form-group">
22
+ <label for="confirmPassword">Confirm Password</label>
23
+ <input id="confirmPassword" v-model="confirm" type="password" placeholder="Confirm password" />
24
+ <span class="error">{{ confirmErr }}</span>
25
+ </div>
26
+ <button type="submit">{{ isLogin ? 'Sign In' : 'Create Account' }}</button>
27
+ </form>
28
+ <p class="toggle-text">
29
+ <span>{{ isLogin ? "Don't have an account?" : 'Already have an account?' }}</span>
30
+ <a href="#" @click="toggleMode">{{ isLogin ? 'Register' : 'Login' }}</a>
31
+ </p>
32
+ </div>
33
+ </div>
34
+ </div>
35
+ </template>
36
+
37
+ <script lang="ts">
38
+ import Vue from "vue";
39
+ import type { ISourceOptions } from "@tsparticles/engine";
40
+
41
+ function validateEmail(val: string): boolean {
42
+ return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(val);
43
+ }
44
+
45
+ export default Vue.extend({
46
+ data() {
47
+ return {
48
+ isLogin: true,
49
+ theme: localStorage.getItem("theme") || "dark",
50
+ email: "",
51
+ password: "",
52
+ confirm: "",
53
+ emailErr: "",
54
+ passErr: "",
55
+ confirmErr: "",
56
+ options: {
57
+ background: { color: { value: "transparent" } },
58
+ fpsLimit: 60,
59
+ particles: {
60
+ number: { value: 60, density: { enable: true } },
61
+ color: { value: ["#6c5ce7", "#a29bfe", "#fd79a8", "#00cec9"] },
62
+ shape: { type: "circle" },
63
+ opacity: { value: 0.5, random: true },
64
+ size: { value: { min: 1, max: 3 }, random: true },
65
+ move: { enable: true, speed: 1, direction: "none", random: true, straight: false, outModes: { default: "out" } },
66
+ },
67
+ interactivity: {
68
+ events: { onHover: { enable: true, mode: "bubble" } },
69
+ modes: { bubble: { distance: 200, size: 6, duration: 2, opacity: 0.8 } },
70
+ },
71
+ detectRetina: true,
72
+ } as ISourceOptions,
73
+ };
74
+ },
75
+ mounted() {
76
+ document.documentElement.setAttribute("data-theme", this.theme);
77
+ },
78
+ methods: {
79
+ toggleTheme(): void {
80
+ this.theme = this.theme === "dark" ? "light" : "dark";
81
+ document.documentElement.setAttribute("data-theme", this.theme);
82
+ localStorage.setItem("theme", this.theme);
83
+ },
84
+ handleSubmit(e: Event): void {
85
+ e.preventDefault();
86
+ let valid = true;
87
+
88
+ if (!this.email || !validateEmail(this.email)) {
89
+ this.emailErr = "Please enter a valid email address";
90
+ valid = false;
91
+ } else {
92
+ this.emailErr = "";
93
+ }
94
+
95
+ if (!this.password || this.password.length < 6) {
96
+ this.passErr = "Password must be at least 6 characters";
97
+ valid = false;
98
+ } else {
99
+ this.passErr = "";
100
+ }
101
+
102
+ if (!this.isLogin) {
103
+ if (this.password !== this.confirm) {
104
+ this.confirmErr = "Passwords do not match";
105
+ valid = false;
106
+ } else {
107
+ this.confirmErr = "";
108
+ }
109
+ }
110
+
111
+ if (!valid) return;
112
+
113
+ if (this.isLogin) {
114
+ alert("Logged in successfully! (demo)");
115
+ } else {
116
+ alert("Account created successfully! (demo)");
117
+ this.isLogin = true;
118
+ }
119
+
120
+ this.email = "";
121
+ this.password = "";
122
+ this.confirm = "";
123
+ },
124
+ toggleMode(e: Event): void {
125
+ e.preventDefault();
126
+ this.isLogin = !this.isLogin;
127
+ this.emailErr = "";
128
+ this.passErr = "";
129
+ this.confirmErr = "";
130
+ },
131
+ },
132
+ });
133
+ </script>
134
+
135
+ <style>
136
+ :root {
137
+ --bg: #0f0f1a;
138
+ --card-bg: rgba(255, 255, 255, 0.05);
139
+ --text: #fff;
140
+ --border: rgba(255, 255, 255, 0.1);
141
+ --input-bg: rgba(255, 255, 255, 0.08);
142
+ --accent: #6c5ce7;
143
+ --accent-hover: #a29bfe;
144
+ --error: #e74c3c;
145
+ }
146
+
147
+ [data-theme="light"] {
148
+ --bg: #f0f0f5;
149
+ --card-bg: rgba(255, 255, 255, 0.8);
150
+ --text: #1a1a2e;
151
+ --border: rgba(0, 0, 0, 0.1);
152
+ --input-bg: rgba(0, 0, 0, 0.05);
153
+ }
154
+
155
+ * {
156
+ box-sizing: border-box;
157
+ }
158
+
159
+ body {
160
+ margin: 0;
161
+ font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
162
+ background: var(--bg);
163
+ color: var(--text);
164
+ transition: background 0.3s, color 0.3s;
165
+ }
166
+
167
+ .auth-container {
168
+ position: absolute;
169
+ top: 50%;
170
+ left: 50%;
171
+ transform: translate(-50%, -50%);
172
+ z-index: 10;
173
+ width: 100%;
174
+ max-width: 400px;
175
+ padding: 1rem;
176
+ }
177
+
178
+ .auth-card {
179
+ background: var(--card-bg);
180
+ backdrop-filter: blur(10px);
181
+ border: 1px solid var(--border);
182
+ border-radius: 16px;
183
+ padding: 2rem;
184
+ box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
185
+ }
186
+
187
+ .auth-header {
188
+ display: flex;
189
+ justify-content: space-between;
190
+ align-items: center;
191
+ margin-bottom: 1.5rem;
192
+ }
193
+
194
+ .auth-header h1 {
195
+ margin: 0;
196
+ font-size: 1.8em;
197
+ }
198
+
199
+ .theme-btn {
200
+ background: none;
201
+ border: 1px solid var(--border);
202
+ border-radius: 8px;
203
+ padding: 0.4em 0.6em;
204
+ font-size: 1.2em;
205
+ cursor: pointer;
206
+ transition: background 0.2s;
207
+ }
208
+
209
+ .theme-btn:hover {
210
+ background: var(--input-bg);
211
+ }
212
+
213
+ .form-group {
214
+ margin-bottom: 1rem;
215
+ }
216
+
217
+ label {
218
+ display: block;
219
+ margin-bottom: 0.3em;
220
+ font-size: 0.9em;
221
+ opacity: 0.8;
222
+ }
223
+
224
+ input {
225
+ width: 100%;
226
+ padding: 0.7em 1em;
227
+ font-size: 1em;
228
+ border: 1px solid var(--border);
229
+ border-radius: 8px;
230
+ background: var(--input-bg);
231
+ color: var(--text);
232
+ outline: none;
233
+ transition: border-color 0.2s;
234
+ }
235
+
236
+ input:focus {
237
+ border-color: var(--accent);
238
+ }
239
+
240
+ input::placeholder {
241
+ color: var(--text);
242
+ opacity: 0.4;
243
+ }
244
+
245
+ .error {
246
+ display: block;
247
+ margin-top: 0.3em;
248
+ font-size: 0.8em;
249
+ color: var(--error);
250
+ min-height: 1em;
251
+ }
252
+
253
+ button[type="submit"] {
254
+ width: 100%;
255
+ padding: 0.8em;
256
+ font-size: 1em;
257
+ font-weight: 600;
258
+ border: none;
259
+ border-radius: 8px;
260
+ background: var(--accent);
261
+ color: #fff;
262
+ cursor: pointer;
263
+ transition: background 0.2s;
264
+ margin-top: 0.5rem;
265
+ }
266
+
267
+ button[type="submit"]:hover {
268
+ background: var(--accent-hover);
269
+ }
270
+
271
+ .toggle-text {
272
+ text-align: center;
273
+ margin-top: 1.5rem;
274
+ font-size: 0.9em;
275
+ opacity: 0.7;
276
+ }
277
+
278
+ .toggle-text a {
279
+ color: var(--accent);
280
+ text-decoration: none;
281
+ margin-left: 0.3em;
282
+ }
283
+
284
+ .toggle-text a:hover {
285
+ text-decoration: underline;
286
+ }
287
+ </style>
@@ -0,0 +1,19 @@
1
+ {
2
+ "name": "{{packageName}}",
3
+ "private": true,
4
+ "version": "1.0.0",
5
+ "type": "module",
6
+ "scripts": {
7
+ "dev": "vite",
8
+ "build": "vue-tsc --noEmit && vite build",
9
+ "preview": "vite preview"
10
+ },
11
+ "dependencies": {
12
+ "vue": "^3.5.32",
13
+ "@tsparticles/vue3": "^4.1.3"
14
+ },
15
+ "devDependencies": {
16
+ "@vitejs/plugin-vue": "^6.0.5",
17
+ "vue-tsc": "^3.2.6"
18
+ }
19
+ }