srcdev-nuxt-components 9.1.36 → 9.1.38
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.
- package/.claude/settings.json +2 -1
- package/.claude/settings.local.json +2 -2
- package/.claude/skills/components/capture-qr-code.md +84 -0
- package/.claude/skills/components/data-grid.md +167 -0
- package/.claude/skills/components/decode-qr-code.md +84 -0
- package/.claude/skills/components/display-qr-code.md +64 -0
- package/.claude/skills/index.md +5 -2
- package/app/components/01.atoms/grids/data-grid/DataGrid.vue +39 -0
- package/app/components/01.atoms/grids/data-grid/stories/DataGrid.stories.ts +234 -0
- package/app/components/01.atoms/grids/data-grid/tests/DataGrid.spec.ts +140 -0
- package/app/components/01.atoms/grids/data-grid/tests/__snapshots__/DataGrid.spec.ts.snap +11 -0
- package/app/components/01.atoms/qr-code/DisplayQrCode.vue +50 -0
- package/app/components/01.atoms/qr-code/stories/DisplayQrCode.stories.ts +206 -0
- package/app/components/01.atoms/qr-code/tests/DisplayQrCode.spec.ts +139 -0
- package/app/components/02.molecules/qr-code/CaptureQrCode.vue +142 -0
- package/app/components/{qr-code → 02.molecules/qr-code}/DecodeQrCode.vue +11 -35
- package/app/components/02.molecules/qr-code/stories/QrCode.stories.ts +101 -0
- package/app/components/02.molecules/qr-code/tests/CaptureQrCode.spec.ts +212 -0
- package/app/components/02.molecules/qr-code/tests/DecodeQrCode.spec.ts +145 -0
- package/app/layouts/default.vue +0 -1
- package/app/pages/ui/qr-code/[componentName].vue +3 -3
- package/app/pages/ui/simple-grid.vue +2 -2
- package/package.json +1 -1
- package/.claude/skills/components/scroll-parallax-section.md +0 -148
- package/app/components/01.atoms/scroll-parallax-section/ScrollParallaxSection.vue +0 -108
- package/app/components/01.atoms/scroll-parallax-section/stories/ScrollParallaxSection.stories.ts +0 -151
- package/app/components/01.atoms/scroll-parallax-section/tests/ScrollParallaxSection.spec.ts +0 -91
- package/app/components/display-grid/DisplayGridCore.vue +0 -22
- package/app/components/qr-code/CaptureQrCode.vue +0 -183
- package/app/components/qr-code/DisplayQrCode.vue +0 -53
- package/app/components/qr-code/stories/QrCode.stories.ts +0 -933
- package/app/pages/ui/scroll-parallax-section.vue +0 -65
|
@@ -1,933 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryFn } from "@nuxtjs/storybook";
|
|
2
|
-
import DisplayQrCodeComponent from "../DisplayQrCode.vue";
|
|
3
|
-
import CaptureQrCodeComponent from "../CaptureQrCode.vue";
|
|
4
|
-
import DecodeQrCodeComponent from "../DecodeQrCode.vue";
|
|
5
|
-
import type { QrCodeVariant } from "../../../types/components";
|
|
6
|
-
|
|
7
|
-
// Display QR Code Stories
|
|
8
|
-
const DisplayQrCodeMeta: Meta<typeof DisplayQrCodeComponent> = {
|
|
9
|
-
title: "Components/UI/QR Code/DisplayQrCode",
|
|
10
|
-
component: DisplayQrCodeComponent,
|
|
11
|
-
argTypes: {
|
|
12
|
-
// Content Configuration
|
|
13
|
-
qrValue: {
|
|
14
|
-
control: { type: "text" },
|
|
15
|
-
description: "The value/content to encode in the QR code",
|
|
16
|
-
table: {
|
|
17
|
-
category: "Content",
|
|
18
|
-
},
|
|
19
|
-
},
|
|
20
|
-
// Visual Configuration
|
|
21
|
-
size: {
|
|
22
|
-
control: { type: "text" },
|
|
23
|
-
description: "Size of the QR code (CSS value like '256px', '10rem')",
|
|
24
|
-
table: {
|
|
25
|
-
category: "Appearance",
|
|
26
|
-
},
|
|
27
|
-
},
|
|
28
|
-
radius: {
|
|
29
|
-
control: { type: "range", min: 0, max: 20, step: 1 },
|
|
30
|
-
description: "Border radius of the QR code corners",
|
|
31
|
-
table: {
|
|
32
|
-
category: "Appearance",
|
|
33
|
-
},
|
|
34
|
-
},
|
|
35
|
-
blackColor: {
|
|
36
|
-
control: { type: "color" },
|
|
37
|
-
description: "Color of the QR code foreground elements",
|
|
38
|
-
table: {
|
|
39
|
-
category: "Appearance",
|
|
40
|
-
},
|
|
41
|
-
},
|
|
42
|
-
whiteColor: {
|
|
43
|
-
control: { type: "color" },
|
|
44
|
-
description: "Color of the QR code background",
|
|
45
|
-
table: {
|
|
46
|
-
category: "Appearance",
|
|
47
|
-
},
|
|
48
|
-
},
|
|
49
|
-
// Hide complex props from controls
|
|
50
|
-
variant: {
|
|
51
|
-
table: {
|
|
52
|
-
disable: true,
|
|
53
|
-
},
|
|
54
|
-
},
|
|
55
|
-
styleClassPassthrough: {
|
|
56
|
-
table: {
|
|
57
|
-
disable: true,
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
},
|
|
61
|
-
args: {
|
|
62
|
-
qrValue: "https://github.com/srcdev/nuxt-components",
|
|
63
|
-
size: "256px",
|
|
64
|
-
radius: 0,
|
|
65
|
-
blackColor: "#000000",
|
|
66
|
-
whiteColor: "transparent",
|
|
67
|
-
styleClassPassthrough: [],
|
|
68
|
-
},
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
interface QrStoryArgs {
|
|
72
|
-
qrValue: string;
|
|
73
|
-
size: string;
|
|
74
|
-
radius: number;
|
|
75
|
-
blackColor: string;
|
|
76
|
-
whiteColor: string;
|
|
77
|
-
styleClassPassthrough: string[];
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
const DisplayTemplate: StoryFn<QrStoryArgs> = (args, { parameters }) => ({
|
|
81
|
-
components: { DisplayQrCodeComponent },
|
|
82
|
-
setup() {
|
|
83
|
-
const variant: QrCodeVariant = parameters?.variant || {
|
|
84
|
-
inner: "default",
|
|
85
|
-
marker: "default",
|
|
86
|
-
pixel: "default",
|
|
87
|
-
};
|
|
88
|
-
|
|
89
|
-
return { args, variant };
|
|
90
|
-
},
|
|
91
|
-
template: `
|
|
92
|
-
<div style="padding: 40px; display: flex; align-items: center; justify-content: center; background: #f5f5f5; border-radius: 8px;">
|
|
93
|
-
<DisplayQrCodeComponent
|
|
94
|
-
:qrValue="args.qrValue"
|
|
95
|
-
:variant="variant"
|
|
96
|
-
:radius="args.radius"
|
|
97
|
-
:blackColor="args.blackColor"
|
|
98
|
-
:whiteColor="args.whiteColor"
|
|
99
|
-
:size="args.size"
|
|
100
|
-
:style-class-passthrough="args.styleClassPassthrough"
|
|
101
|
-
/>
|
|
102
|
-
</div>
|
|
103
|
-
`,
|
|
104
|
-
});
|
|
105
|
-
|
|
106
|
-
// ===== BASIC DISPLAY STORIES =====
|
|
107
|
-
|
|
108
|
-
export const DisplayDefault = DisplayTemplate.bind({});
|
|
109
|
-
export const DisplayDefaultMeta = DisplayQrCodeMeta;
|
|
110
|
-
|
|
111
|
-
export const DisplayWebsite = DisplayTemplate.bind({});
|
|
112
|
-
DisplayWebsite.args = {
|
|
113
|
-
qrValue: "https://nuxt.com",
|
|
114
|
-
radius: 8,
|
|
115
|
-
blackColor: "#000000",
|
|
116
|
-
};
|
|
117
|
-
DisplayWebsite.parameters = {
|
|
118
|
-
variant: {
|
|
119
|
-
inner: "circle",
|
|
120
|
-
marker: "rounded",
|
|
121
|
-
pixel: "dots",
|
|
122
|
-
},
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
// ===== VARIANT SHOWCASE STORIES =====
|
|
126
|
-
|
|
127
|
-
export const VariantDefault = DisplayTemplate.bind({});
|
|
128
|
-
VariantDefault.args = {
|
|
129
|
-
qrValue: "Default variant style",
|
|
130
|
-
radius: 4,
|
|
131
|
-
};
|
|
132
|
-
VariantDefault.parameters = {
|
|
133
|
-
variant: { inner: "default", marker: "default", pixel: "default" },
|
|
134
|
-
};
|
|
135
|
-
|
|
136
|
-
export const VariantCircle = DisplayTemplate.bind({});
|
|
137
|
-
VariantCircle.args = {
|
|
138
|
-
qrValue: "Circle variant style",
|
|
139
|
-
radius: 8,
|
|
140
|
-
blackColor: "#1e40af",
|
|
141
|
-
};
|
|
142
|
-
VariantCircle.parameters = {
|
|
143
|
-
variant: { inner: "circle", marker: "circle", pixel: "circle" },
|
|
144
|
-
};
|
|
145
|
-
|
|
146
|
-
export const VariantRounded = DisplayTemplate.bind({});
|
|
147
|
-
VariantRounded.args = {
|
|
148
|
-
qrValue: "Rounded variant style",
|
|
149
|
-
radius: 12,
|
|
150
|
-
blackColor: "#059669",
|
|
151
|
-
};
|
|
152
|
-
VariantRounded.parameters = {
|
|
153
|
-
variant: { inner: "rounded", marker: "rounded", pixel: "rounded" },
|
|
154
|
-
};
|
|
155
|
-
|
|
156
|
-
export const VariantDots = DisplayTemplate.bind({});
|
|
157
|
-
VariantDots.args = {
|
|
158
|
-
qrValue: "Dots variant style",
|
|
159
|
-
radius: 6,
|
|
160
|
-
blackColor: "#dc2626",
|
|
161
|
-
};
|
|
162
|
-
VariantDots.parameters = {
|
|
163
|
-
variant: { inner: "dots", marker: "dots", pixel: "dots" },
|
|
164
|
-
};
|
|
165
|
-
|
|
166
|
-
export const VariantMixed = DisplayTemplate.bind({});
|
|
167
|
-
VariantMixed.args = {
|
|
168
|
-
qrValue: "Mixed variants for creative styling",
|
|
169
|
-
radius: 10,
|
|
170
|
-
blackColor: "#7c3aed",
|
|
171
|
-
};
|
|
172
|
-
VariantMixed.parameters = {
|
|
173
|
-
variant: { inner: "circle", marker: "rounded", pixel: "dots" },
|
|
174
|
-
};
|
|
175
|
-
|
|
176
|
-
// ===== REAL-WORLD USE CASE STORIES =====
|
|
177
|
-
|
|
178
|
-
export const WiFiConnection = DisplayTemplate.bind({});
|
|
179
|
-
WiFiConnection.args = {
|
|
180
|
-
qrValue: "WIFI:T:WPA;S:MyHomeNetwork;P:mySecurePassword123;H:false;",
|
|
181
|
-
blackColor: "#1e40af",
|
|
182
|
-
radius: 4,
|
|
183
|
-
};
|
|
184
|
-
WiFiConnection.parameters = {
|
|
185
|
-
variant: { inner: "rounded", marker: "circle", pixel: "default" },
|
|
186
|
-
docs: {
|
|
187
|
-
description: {
|
|
188
|
-
story: "WiFi connection QR code that allows users to automatically connect to a network.",
|
|
189
|
-
},
|
|
190
|
-
},
|
|
191
|
-
};
|
|
192
|
-
|
|
193
|
-
export const VCardContact = DisplayTemplate.bind({});
|
|
194
|
-
VCardContact.args = {
|
|
195
|
-
qrValue:
|
|
196
|
-
"BEGIN:VCARD\\nVERSION:3.0\\nFN:John Doe\\nORG:Acme Corp\\nTITLE:Software Engineer\\nTEL:+1234567890\\nEMAIL:john.doe@acme.com\\nURL:https://johndoe.dev\\nEND:VCARD",
|
|
197
|
-
blackColor: "#059669",
|
|
198
|
-
radius: 12,
|
|
199
|
-
};
|
|
200
|
-
VCardContact.parameters = {
|
|
201
|
-
variant: { inner: "dots", marker: "rounded", pixel: "circle" },
|
|
202
|
-
docs: {
|
|
203
|
-
description: {
|
|
204
|
-
story: "Business card QR code containing complete contact information in vCard format.",
|
|
205
|
-
},
|
|
206
|
-
},
|
|
207
|
-
};
|
|
208
|
-
|
|
209
|
-
export const SMSMessage = DisplayTemplate.bind({});
|
|
210
|
-
SMSMessage.args = {
|
|
211
|
-
qrValue: "sms:+1234567890?body=Hello! I scanned your QR code.",
|
|
212
|
-
blackColor: "#dc2626",
|
|
213
|
-
};
|
|
214
|
-
SMSMessage.parameters = {
|
|
215
|
-
variant: { inner: "circle", marker: "dots", pixel: "rounded" },
|
|
216
|
-
docs: {
|
|
217
|
-
description: {
|
|
218
|
-
story: "SMS QR code that pre-fills a text message when scanned.",
|
|
219
|
-
},
|
|
220
|
-
},
|
|
221
|
-
};
|
|
222
|
-
|
|
223
|
-
export const EmailTemplate = DisplayTemplate.bind({});
|
|
224
|
-
EmailTemplate.args = {
|
|
225
|
-
qrValue: "mailto:support@company.com?subject=Customer Inquiry&body=Hello, I have a question about...",
|
|
226
|
-
blackColor: "#7c3aed",
|
|
227
|
-
};
|
|
228
|
-
EmailTemplate.parameters = {
|
|
229
|
-
variant: { inner: "rounded", marker: "default", pixel: "dots" },
|
|
230
|
-
docs: {
|
|
231
|
-
description: {
|
|
232
|
-
story: "Email QR code with pre-filled subject and body content.",
|
|
233
|
-
},
|
|
234
|
-
},
|
|
235
|
-
};
|
|
236
|
-
|
|
237
|
-
export const CalendarEvent = DisplayTemplate.bind({});
|
|
238
|
-
CalendarEvent.args = {
|
|
239
|
-
qrValue:
|
|
240
|
-
"BEGIN:VCALENDAR\\nVERSION:2.0\\nBEGIN:VEVENT\\nSUMMARY:Team Meeting\\nDTSTART:20260301T140000Z\\nDTEND:20260301T150000Z\\nLOCATION:Conference Room A\\nDESCRIPTION:Weekly team sync meeting\\nEND:VEVENT\\nEND:VCALENDAR",
|
|
241
|
-
blackColor: "#f59e0b",
|
|
242
|
-
radius: 8,
|
|
243
|
-
};
|
|
244
|
-
CalendarEvent.parameters = {
|
|
245
|
-
variant: { inner: "circle", marker: "rounded", pixel: "dots" },
|
|
246
|
-
docs: {
|
|
247
|
-
description: {
|
|
248
|
-
story: "Calendar event QR code that adds an event to the user's calendar when scanned.",
|
|
249
|
-
},
|
|
250
|
-
},
|
|
251
|
-
};
|
|
252
|
-
|
|
253
|
-
export const GeolocationPin = DisplayTemplate.bind({});
|
|
254
|
-
GeolocationPin.args = {
|
|
255
|
-
qrValue: "geo:37.7749,-122.4194?q=37.7749,-122.4194(San Francisco Office)",
|
|
256
|
-
blackColor: "#ec4899",
|
|
257
|
-
radius: 6,
|
|
258
|
-
};
|
|
259
|
-
GeolocationPin.parameters = {
|
|
260
|
-
variant: { inner: "dots", marker: "circle", pixel: "rounded" },
|
|
261
|
-
docs: {
|
|
262
|
-
description: {
|
|
263
|
-
story: "Location QR code that opens maps application with specific coordinates.",
|
|
264
|
-
},
|
|
265
|
-
},
|
|
266
|
-
};
|
|
267
|
-
|
|
268
|
-
// ===== SIZE AND STYLING STORIES =====
|
|
269
|
-
|
|
270
|
-
export const SmallSize = DisplayTemplate.bind({});
|
|
271
|
-
SmallSize.args = {
|
|
272
|
-
qrValue: "Small QR for tight spaces",
|
|
273
|
-
size: "128px",
|
|
274
|
-
radius: 2,
|
|
275
|
-
blackColor: "#f59e0b",
|
|
276
|
-
};
|
|
277
|
-
SmallSize.parameters = {
|
|
278
|
-
variant: { inner: "dots", marker: "circle", pixel: "rounded" },
|
|
279
|
-
};
|
|
280
|
-
|
|
281
|
-
export const LargeSize = DisplayTemplate.bind({});
|
|
282
|
-
LargeSize.args = {
|
|
283
|
-
qrValue: "Large QR for posters and signage with detailed content",
|
|
284
|
-
size: "400px",
|
|
285
|
-
radius: 16,
|
|
286
|
-
blackColor: "#0ea5e9",
|
|
287
|
-
};
|
|
288
|
-
LargeSize.parameters = {
|
|
289
|
-
variant: { inner: "circle", marker: "rounded", pixel: "dots" },
|
|
290
|
-
};
|
|
291
|
-
|
|
292
|
-
export const CustomBranding = DisplayTemplate.bind({});
|
|
293
|
-
CustomBranding.args = {
|
|
294
|
-
qrValue: "https://brand.example.com",
|
|
295
|
-
blackColor: "#ec4899",
|
|
296
|
-
whiteColor: "#ffffff",
|
|
297
|
-
radius: 8,
|
|
298
|
-
size: "300px",
|
|
299
|
-
};
|
|
300
|
-
CustomBranding.parameters = {
|
|
301
|
-
variant: { inner: "circle", marker: "rounded", pixel: "dots" },
|
|
302
|
-
docs: {
|
|
303
|
-
description: {
|
|
304
|
-
story: "QR code with custom brand colors and styling for marketing materials.",
|
|
305
|
-
},
|
|
306
|
-
},
|
|
307
|
-
};
|
|
308
|
-
|
|
309
|
-
export const HighContrast = DisplayTemplate.bind({});
|
|
310
|
-
HighContrast.args = {
|
|
311
|
-
qrValue: "High contrast for accessibility",
|
|
312
|
-
blackColor: "#000000",
|
|
313
|
-
whiteColor: "#ffffff",
|
|
314
|
-
radius: 0,
|
|
315
|
-
size: "256px",
|
|
316
|
-
};
|
|
317
|
-
HighContrast.parameters = {
|
|
318
|
-
variant: { inner: "default", marker: "default", pixel: "default" },
|
|
319
|
-
docs: {
|
|
320
|
-
description: {
|
|
321
|
-
story: "High contrast QR code optimized for accessibility and scanning reliability.",
|
|
322
|
-
},
|
|
323
|
-
},
|
|
324
|
-
};
|
|
325
|
-
|
|
326
|
-
// ===== INTERACTIVE PLAYGROUND STORY =====
|
|
327
|
-
|
|
328
|
-
const PlaygroundTemplate: StoryFn<QrStoryArgs> = (args) => ({
|
|
329
|
-
components: { DisplayQrCodeComponent },
|
|
330
|
-
setup() {
|
|
331
|
-
const qrValue = ref(args.qrValue);
|
|
332
|
-
const variant = ref<QrCodeVariant>({
|
|
333
|
-
inner: "circle",
|
|
334
|
-
marker: "rounded",
|
|
335
|
-
pixel: "dots",
|
|
336
|
-
});
|
|
337
|
-
const radius = ref(args.radius);
|
|
338
|
-
const blackColor = ref(args.blackColor);
|
|
339
|
-
const whiteColor = ref(args.whiteColor);
|
|
340
|
-
const sizeValue = ref(256);
|
|
341
|
-
const size = computed(() => `${sizeValue.value}px`);
|
|
342
|
-
|
|
343
|
-
const presetValues = [
|
|
344
|
-
{ label: "Website URL", value: "https://nuxt.com" },
|
|
345
|
-
{ label: "WiFi Network", value: "WIFI:T:WPA;S:MyNetwork;P:password123;" },
|
|
346
|
-
{ label: "Phone Number", value: "tel:+1234567890" },
|
|
347
|
-
{ label: "Email", value: "mailto:hello@example.com" },
|
|
348
|
-
{ label: "SMS", value: "sms:+1234567890?body=Hello!" },
|
|
349
|
-
{ label: "Location", value: "geo:40.7128,-74.0060" },
|
|
350
|
-
];
|
|
351
|
-
|
|
352
|
-
const variantOptions = ["default", "circle", "rounded", "dots"];
|
|
353
|
-
|
|
354
|
-
return {
|
|
355
|
-
qrValue,
|
|
356
|
-
variant,
|
|
357
|
-
radius,
|
|
358
|
-
blackColor,
|
|
359
|
-
whiteColor,
|
|
360
|
-
sizeValue,
|
|
361
|
-
size,
|
|
362
|
-
presetValues,
|
|
363
|
-
variantOptions,
|
|
364
|
-
};
|
|
365
|
-
},
|
|
366
|
-
template: `
|
|
367
|
-
<div style="padding: 40px;">
|
|
368
|
-
<div style="display: grid; grid-template-columns: 1fr 300px; gap: 40px; align-items: start;">
|
|
369
|
-
|
|
370
|
-
<!-- QR Code Display -->
|
|
371
|
-
<div style="display: flex; align-items: center; justify-content: center; min-height: 400px; background: #f8fafc; border-radius: 8px; padding: 40px;">
|
|
372
|
-
<DisplayQrCodeComponent
|
|
373
|
-
:qrValue="qrValue"
|
|
374
|
-
:variant="variant"
|
|
375
|
-
:radius="radius"
|
|
376
|
-
:blackColor="blackColor"
|
|
377
|
-
:whiteColor="whiteColor"
|
|
378
|
-
:size="size"
|
|
379
|
-
/>
|
|
380
|
-
</div>
|
|
381
|
-
|
|
382
|
-
<!-- Controls Panel -->
|
|
383
|
-
<div style="background: white; padding: 24px; border-radius: 8px; border: 1px solid #e5e7eb;">
|
|
384
|
-
<h3 style="margin: 0 0 20px 0; color: #374151; font-size: 18px;">QR Code Playground</h3>
|
|
385
|
-
|
|
386
|
-
<!-- Content Presets -->
|
|
387
|
-
<div style="margin-bottom: 20px;">
|
|
388
|
-
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: #374151;">Quick Presets:</label>
|
|
389
|
-
<select @change="qrValue = $event.target.value" style="width: 100%; padding: 8px; border: 1px solid #d1d5db; border-radius: 4px;">
|
|
390
|
-
<option value="">Select a preset...</option>
|
|
391
|
-
<option v-for="preset in presetValues" :key="preset.label" :value="preset.value">
|
|
392
|
-
{{ preset.label }}
|
|
393
|
-
</option>
|
|
394
|
-
</select>
|
|
395
|
-
</div>
|
|
396
|
-
|
|
397
|
-
<!-- Custom Content -->
|
|
398
|
-
<div style="margin-bottom: 20px;">
|
|
399
|
-
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: #374151;">Custom Content:</label>
|
|
400
|
-
<textarea
|
|
401
|
-
v-model="qrValue"
|
|
402
|
-
rows="3"
|
|
403
|
-
style="width: 100%; padding: 8px; border: 1px solid #d1d5db; border-radius: 4px; font-family: monospace; font-size: 12px;"
|
|
404
|
-
placeholder="Enter QR code content..."
|
|
405
|
-
/>
|
|
406
|
-
</div>
|
|
407
|
-
|
|
408
|
-
<!-- Variant Controls -->
|
|
409
|
-
<div style="margin-bottom: 20px;">
|
|
410
|
-
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: #374151;">Style Variants:</label>
|
|
411
|
-
<div style="display: grid; gap: 8px;">
|
|
412
|
-
<div>
|
|
413
|
-
<label style="font-size: 12px; color: #6b7280;">Inner:</label>
|
|
414
|
-
<select v-model="variant.inner" style="width: 100%; padding: 4px; border: 1px solid #d1d5db; border-radius: 4px; font-size: 12px;">
|
|
415
|
-
<option v-for="option in variantOptions" :key="option" :value="option">{{ option }}</option>
|
|
416
|
-
</select>
|
|
417
|
-
</div>
|
|
418
|
-
<div>
|
|
419
|
-
<label style="font-size: 12px; color: #6b7280;">Marker:</label>
|
|
420
|
-
<select v-model="variant.marker" style="width: 100%; padding: 4px; border: 1px solid #d1d5db; border-radius: 4px; font-size: 12px;">
|
|
421
|
-
<option v-for="option in variantOptions" :key="option" :value="option">{{ option }}</option>
|
|
422
|
-
</select>
|
|
423
|
-
</div>
|
|
424
|
-
<div>
|
|
425
|
-
<label style="font-size: 12px; color: #6b7280;">Pixel:</label>
|
|
426
|
-
<select v-model="variant.pixel" style="width: 100%; padding: 4px; border: 1px solid #d1d5db; border-radius: 4px; font-size: 12px;">
|
|
427
|
-
<option v-for="option in variantOptions" :key="option" :value="option">{{ option }}</option>
|
|
428
|
-
</select>
|
|
429
|
-
</div>
|
|
430
|
-
</div>
|
|
431
|
-
</div>
|
|
432
|
-
|
|
433
|
-
<!-- Visual Controls -->
|
|
434
|
-
<div style="margin-bottom: 20px;">
|
|
435
|
-
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: #374151;">Appearance:</label>
|
|
436
|
-
<div style="display: grid; gap: 12px;">
|
|
437
|
-
<div>
|
|
438
|
-
<label style="font-size: 12px; color: #6b7280;">Size: {{ sizeValue }}px</label>
|
|
439
|
-
<input v-model.number="sizeValue" type="range" min="128" max="400" step="16" style="width: 100%;" />
|
|
440
|
-
</div>
|
|
441
|
-
<div>
|
|
442
|
-
<label style="font-size: 12px; color: #6b7280;">Radius: {{ radius }}px</label>
|
|
443
|
-
<input v-model.number="radius" type="range" min="0" max="20" step="1" style="width: 100%;" />
|
|
444
|
-
</div>
|
|
445
|
-
<div style="display: grid; grid-template-columns: 1fr 1fr; gap: 8px;">
|
|
446
|
-
<div>
|
|
447
|
-
<label style="font-size: 12px; color: #6b7280;">Foreground:</label>
|
|
448
|
-
<input v-model="blackColor" type="color" style="width: 100%; height: 32px; border: 1px solid #d1d5db; border-radius: 4px;" />
|
|
449
|
-
</div>
|
|
450
|
-
<div>
|
|
451
|
-
<label style="font-size: 12px; color: #6b7280;">Background:</label>
|
|
452
|
-
<input v-model="whiteColor" type="color" style="width: 100%; height: 32px; border: 1px solid #d1d5db; border-radius: 4px;" />
|
|
453
|
-
</div>
|
|
454
|
-
</div>
|
|
455
|
-
</div>
|
|
456
|
-
</div>
|
|
457
|
-
|
|
458
|
-
</div>
|
|
459
|
-
</div>
|
|
460
|
-
</div>
|
|
461
|
-
`,
|
|
462
|
-
});
|
|
463
|
-
|
|
464
|
-
export const InteractivePlayground = PlaygroundTemplate.bind({});
|
|
465
|
-
InteractivePlayground.args = {
|
|
466
|
-
qrValue: "https://github.com/srcdev/nuxt-components",
|
|
467
|
-
radius: 8,
|
|
468
|
-
blackColor: "#000000",
|
|
469
|
-
whiteColor: "transparent",
|
|
470
|
-
size: "256px",
|
|
471
|
-
styleClassPassthrough: [],
|
|
472
|
-
};
|
|
473
|
-
InteractivePlayground.parameters = {
|
|
474
|
-
docs: {
|
|
475
|
-
description: {
|
|
476
|
-
story:
|
|
477
|
-
"Interactive playground to experiment with QR code content, variants, and styling options. Try different presets or enter custom content.",
|
|
478
|
-
},
|
|
479
|
-
},
|
|
480
|
-
};
|
|
481
|
-
|
|
482
|
-
// ===== CAPTURE QR CODE STORIES =====
|
|
483
|
-
|
|
484
|
-
const CaptureQrCodeMeta: Meta<typeof CaptureQrCodeComponent> = {
|
|
485
|
-
title: "Components/UI/QR Code/CaptureQrCode",
|
|
486
|
-
component: CaptureQrCodeComponent,
|
|
487
|
-
argTypes: {
|
|
488
|
-
styleClassPassthrough: {
|
|
489
|
-
table: {
|
|
490
|
-
disable: true,
|
|
491
|
-
},
|
|
492
|
-
},
|
|
493
|
-
},
|
|
494
|
-
args: {
|
|
495
|
-
styleClassPassthrough: [],
|
|
496
|
-
},
|
|
497
|
-
parameters: {
|
|
498
|
-
docs: {
|
|
499
|
-
description: {
|
|
500
|
-
component:
|
|
501
|
-
"Interactive QR code scanner using device camera. Requires camera permissions to function properly. Features automatic detection, error handling, and camera management.",
|
|
502
|
-
},
|
|
503
|
-
},
|
|
504
|
-
},
|
|
505
|
-
};
|
|
506
|
-
|
|
507
|
-
const CaptureTemplate: StoryFn<typeof CaptureQrCodeComponent> = (args) => ({
|
|
508
|
-
components: { CaptureQrCodeComponent },
|
|
509
|
-
setup() {
|
|
510
|
-
return { args };
|
|
511
|
-
},
|
|
512
|
-
template: `
|
|
513
|
-
<div style="padding: 40px; max-width: 600px; margin: 0 auto;">
|
|
514
|
-
<div style="background: #f8fafc; padding: 20px; border-radius: 8px; margin-bottom: 20px;">
|
|
515
|
-
<h3 style="margin: 0 0 10px 0; color: #374151;">📱 Live Camera QR Scanner</h3>
|
|
516
|
-
<p style="margin: 0 0 10px 0; color: #6b7280; font-size: 14px;">
|
|
517
|
-
This component uses your device camera to scan QR codes in real-time.
|
|
518
|
-
Make sure to allow camera access when prompted.
|
|
519
|
-
</p>
|
|
520
|
-
<div style="background: #fff3cd; padding: 12px; border-radius: 4px; border: 1px solid #ffeaa7;">
|
|
521
|
-
<p style="margin: 0; color: #856404; font-size: 12px;">
|
|
522
|
-
<strong>Features:</strong> Automatic detection, multiple code scanning, camera management, error recovery
|
|
523
|
-
</p>
|
|
524
|
-
</div>
|
|
525
|
-
</div>
|
|
526
|
-
<CaptureQrCodeComponent :style-class-passthrough="args.styleClassPassthrough" />
|
|
527
|
-
</div>
|
|
528
|
-
`,
|
|
529
|
-
});
|
|
530
|
-
|
|
531
|
-
export const CaptureDefault = CaptureTemplate.bind({});
|
|
532
|
-
export const CaptureDefaultMeta = CaptureQrCodeMeta;
|
|
533
|
-
|
|
534
|
-
// ===== DECODE QR CODE STORIES =====
|
|
535
|
-
|
|
536
|
-
const DecodeQrCodeMeta: Meta<typeof DecodeQrCodeComponent> = {
|
|
537
|
-
title: "Components/UI/QR Code/DecodeQrCode",
|
|
538
|
-
component: DecodeQrCodeComponent,
|
|
539
|
-
argTypes: {
|
|
540
|
-
styleClassPassthrough: {
|
|
541
|
-
table: {
|
|
542
|
-
disable: true,
|
|
543
|
-
},
|
|
544
|
-
},
|
|
545
|
-
},
|
|
546
|
-
args: {
|
|
547
|
-
styleClassPassthrough: [],
|
|
548
|
-
},
|
|
549
|
-
parameters: {
|
|
550
|
-
docs: {
|
|
551
|
-
description: {
|
|
552
|
-
component:
|
|
553
|
-
"Upload or drag-and-drop QR code images to decode their content. Supports various image formats including PNG, JPEG, WEBP, and more.",
|
|
554
|
-
},
|
|
555
|
-
},
|
|
556
|
-
},
|
|
557
|
-
};
|
|
558
|
-
|
|
559
|
-
const DecodeTemplate: StoryFn<typeof DecodeQrCodeComponent> = (args) => ({
|
|
560
|
-
components: { DecodeQrCodeComponent },
|
|
561
|
-
setup() {
|
|
562
|
-
return { args };
|
|
563
|
-
},
|
|
564
|
-
template: `
|
|
565
|
-
<div style="padding: 40px; max-width: 600px; margin: 0 auto;">
|
|
566
|
-
<div style="background: #f8fafc; padding: 20px; border-radius: 8px; margin-bottom: 20px;">
|
|
567
|
-
<h3 style="margin: 0 0 10px 0; color: #374151;">📁 QR Image Decoder</h3>
|
|
568
|
-
<p style="margin: 0 0 10px 0; color: #6b7280; font-size: 14px;">
|
|
569
|
-
Upload or drag QR code images to extract their content.
|
|
570
|
-
Supports PNG, JPEG, WEBP, and other common image formats.
|
|
571
|
-
</p>
|
|
572
|
-
<div style="background: #d1ecf1; padding: 12px; border-radius: 4px; border: 1px solid #bee5eb;">
|
|
573
|
-
<p style="margin: 0; color: #0c5460; font-size: 12px;">
|
|
574
|
-
<strong>Supported formats:</strong> PNG, JPEG, WEBP, BMP, GIF • <strong>Methods:</strong> File upload, drag & drop
|
|
575
|
-
</p>
|
|
576
|
-
</div>
|
|
577
|
-
</div>
|
|
578
|
-
<DecodeQrCodeComponent :style-class-passthrough="args.styleClassPassthrough" />
|
|
579
|
-
</div>
|
|
580
|
-
`,
|
|
581
|
-
});
|
|
582
|
-
|
|
583
|
-
export const DecodeDefault = DecodeTemplate.bind({});
|
|
584
|
-
export const DecodeDefaultMeta = DecodeQrCodeMeta;
|
|
585
|
-
|
|
586
|
-
// ===== COMPREHENSIVE INTEGRATION STORIES =====
|
|
587
|
-
|
|
588
|
-
const IntegrationTemplate: StoryFn = () => ({
|
|
589
|
-
components: {
|
|
590
|
-
DisplayQrCodeComponent,
|
|
591
|
-
CaptureQrCodeComponent,
|
|
592
|
-
DecodeQrCodeComponent,
|
|
593
|
-
},
|
|
594
|
-
setup() {
|
|
595
|
-
const selectedDemo = ref("display");
|
|
596
|
-
const qrValue = ref("https://github.com/srcdev/nuxt-components");
|
|
597
|
-
|
|
598
|
-
const businessCardVariant: QrCodeVariant = {
|
|
599
|
-
inner: "circle",
|
|
600
|
-
marker: "rounded",
|
|
601
|
-
pixel: "dots",
|
|
602
|
-
};
|
|
603
|
-
|
|
604
|
-
const wifiVariant: QrCodeVariant = {
|
|
605
|
-
inner: "rounded",
|
|
606
|
-
marker: "circle",
|
|
607
|
-
pixel: "default",
|
|
608
|
-
};
|
|
609
|
-
|
|
610
|
-
const contactVariant: QrCodeVariant = {
|
|
611
|
-
inner: "dots",
|
|
612
|
-
marker: "rounded",
|
|
613
|
-
pixel: "circle",
|
|
614
|
-
};
|
|
615
|
-
|
|
616
|
-
return {
|
|
617
|
-
selectedDemo,
|
|
618
|
-
qrValue,
|
|
619
|
-
businessCardVariant,
|
|
620
|
-
wifiVariant,
|
|
621
|
-
contactVariant,
|
|
622
|
-
};
|
|
623
|
-
},
|
|
624
|
-
template: `
|
|
625
|
-
<div style="padding: 40px;">
|
|
626
|
-
<!-- Demo Selector -->
|
|
627
|
-
<div style="text-align: center; margin-bottom: 40px;">
|
|
628
|
-
<h2 style="margin: 0 0 20px 0; color: #374151;">QR Code Component Suite</h2>
|
|
629
|
-
<div style="display: inline-flex; background: #f3f4f6; border-radius: 8px; padding: 4px;">
|
|
630
|
-
<button
|
|
631
|
-
@click="selectedDemo = 'display'"
|
|
632
|
-
:style="{
|
|
633
|
-
padding: '8px 16px',
|
|
634
|
-
borderRadius: '6px',
|
|
635
|
-
border: 'none',
|
|
636
|
-
background: selectedDemo === 'display' ? '#fff' : 'transparent',
|
|
637
|
-
color: selectedDemo === 'display' ? '#374151' : '#6b7280',
|
|
638
|
-
cursor: 'pointer',
|
|
639
|
-
fontWeight: selectedDemo === 'display' ? '500' : '400'
|
|
640
|
-
}"
|
|
641
|
-
>
|
|
642
|
-
Display Examples
|
|
643
|
-
</button>
|
|
644
|
-
<button
|
|
645
|
-
@click="selectedDemo = 'interactive'"
|
|
646
|
-
:style="{
|
|
647
|
-
padding: '8px 16px',
|
|
648
|
-
borderRadius: '6px',
|
|
649
|
-
border: 'none',
|
|
650
|
-
background: selectedDemo === 'interactive' ? '#fff' : 'transparent',
|
|
651
|
-
color: selectedDemo === 'interactive' ? '#374151' : '#6b7280',
|
|
652
|
-
cursor: 'pointer',
|
|
653
|
-
fontWeight: selectedDemo === 'interactive' ? '500' : '400'
|
|
654
|
-
}"
|
|
655
|
-
>
|
|
656
|
-
Interactive Tools
|
|
657
|
-
</button>
|
|
658
|
-
<button
|
|
659
|
-
@click="selectedDemo = 'showcase'"
|
|
660
|
-
:style="{
|
|
661
|
-
padding: '8px 16px',
|
|
662
|
-
borderRadius: '6px',
|
|
663
|
-
border: 'none',
|
|
664
|
-
background: selectedDemo === 'showcase' ? '#fff' : 'transparent',
|
|
665
|
-
color: selectedDemo === 'showcase' ? '#374151' : '#6b7280',
|
|
666
|
-
cursor: 'pointer',
|
|
667
|
-
fontWeight: selectedDemo === 'showcase' ? '500' : '400'
|
|
668
|
-
}"
|
|
669
|
-
>
|
|
670
|
-
Complete Showcase
|
|
671
|
-
</button>
|
|
672
|
-
</div>
|
|
673
|
-
</div>
|
|
674
|
-
|
|
675
|
-
<!-- Display Examples -->
|
|
676
|
-
<div v-if="selectedDemo === 'display'" style="display: grid; gap: 32px;">
|
|
677
|
-
|
|
678
|
-
<!-- Business Use Cases -->
|
|
679
|
-
<div style="background: #f8fafc; padding: 24px; border-radius: 8px;">
|
|
680
|
-
<h3 style="margin: 0 0 20px 0; color: #374151;">Business & Marketing</h3>
|
|
681
|
-
<div style="display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; text-align: center;">
|
|
682
|
-
|
|
683
|
-
<div>
|
|
684
|
-
<DisplayQrCodeComponent
|
|
685
|
-
qrValue="https://company.com/promo2024"
|
|
686
|
-
:variant="businessCardVariant"
|
|
687
|
-
:radius="8"
|
|
688
|
-
blackColor="#1e40af"
|
|
689
|
-
size="160px"
|
|
690
|
-
/>
|
|
691
|
-
<h4 style="margin: 12px 0 4px 0; font-size: 14px; color: #374151;">Promotional Campaign</h4>
|
|
692
|
-
<p style="margin: 0; font-size: 12px; color: #6b7280;">Marketing materials & ads</p>
|
|
693
|
-
</div>
|
|
694
|
-
|
|
695
|
-
<div>
|
|
696
|
-
<DisplayQrCodeComponent
|
|
697
|
-
qrValue="BEGIN:VCARD
|
|
698
|
-
VERSION:3.0
|
|
699
|
-
FN:Jane Smith
|
|
700
|
-
ORG:Tech Solutions Inc
|
|
701
|
-
TITLE:Senior Developer
|
|
702
|
-
TEL:+1-555-0123
|
|
703
|
-
EMAIL:jane@techsolutions.com
|
|
704
|
-
URL:https://linkedin.com/in/janesmith
|
|
705
|
-
END:VCARD"
|
|
706
|
-
:variant="contactVariant"
|
|
707
|
-
:radius="12"
|
|
708
|
-
blackColor="#059669"
|
|
709
|
-
size="160px"
|
|
710
|
-
/>
|
|
711
|
-
<h4 style="margin: 12px 0 4px 0; font-size: 14px; color: #374151;">Digital Business Card</h4>
|
|
712
|
-
<p style="margin: 0; font-size: 12px; color: #6b7280;">Contact information sharing</p>
|
|
713
|
-
</div>
|
|
714
|
-
|
|
715
|
-
<div>
|
|
716
|
-
<DisplayQrCodeComponent
|
|
717
|
-
qrValue="WIFI:T:WPA;S:CompanyGuest;P:Welcome2024!;H:false;"
|
|
718
|
-
:variant="wifiVariant"
|
|
719
|
-
:radius="6"
|
|
720
|
-
blackColor="#dc2626"
|
|
721
|
-
size="160px"
|
|
722
|
-
/>
|
|
723
|
-
<h4 style="margin: 12px 0 4px 0; font-size: 14px; color: #374151;">Guest WiFi Access</h4>
|
|
724
|
-
<p style="margin: 0; font-size: 12px; color: #6b7280;">Easy network connection</p>
|
|
725
|
-
</div>
|
|
726
|
-
|
|
727
|
-
</div>
|
|
728
|
-
</div>
|
|
729
|
-
|
|
730
|
-
<!-- Event & Social -->
|
|
731
|
-
<div style="background: #f8fafc; padding: 24px; border-radius: 8px;">
|
|
732
|
-
<h3 style="margin: 0 0 20px 0; color: #374151;">Events & Social</h3>
|
|
733
|
-
<div style="display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; text-align: center;">
|
|
734
|
-
|
|
735
|
-
<div>
|
|
736
|
-
<DisplayQrCodeComponent
|
|
737
|
-
qrValue="BEGIN:VCALENDAR
|
|
738
|
-
VERSION:2.0
|
|
739
|
-
BEGIN:VEVENT
|
|
740
|
-
SUMMARY:Product Launch Event
|
|
741
|
-
DTSTART:20260315T180000Z
|
|
742
|
-
DTEND:20260315T210000Z
|
|
743
|
-
LOCATION:Convention Center Hall A
|
|
744
|
-
DESCRIPTION:Join us for the biggest product launch of the year!
|
|
745
|
-
END:VEVENT
|
|
746
|
-
END:VCALENDAR"
|
|
747
|
-
:variant="{ inner: 'circle', marker: 'rounded', pixel: 'dots' }"
|
|
748
|
-
:radius="10"
|
|
749
|
-
blackColor="#7c3aed"
|
|
750
|
-
size="160px"
|
|
751
|
-
/>
|
|
752
|
-
<h4 style="margin: 12px 0 4px 0; font-size: 14px; color: #374151;">Event Registration</h4>
|
|
753
|
-
<p style="margin: 0; font-size: 12px; color: #6b7280;">Calendar integration</p>
|
|
754
|
-
</div>
|
|
755
|
-
|
|
756
|
-
<div>
|
|
757
|
-
<DisplayQrCodeComponent
|
|
758
|
-
qrValue="sms:+1-555-0199?body=I'm interested in learning more about your services!"
|
|
759
|
-
:variant="{ inner: 'rounded', marker: 'dots', pixel: 'circle' }"
|
|
760
|
-
:radius="8"
|
|
761
|
-
blackColor="#f59e0b"
|
|
762
|
-
size="160px"
|
|
763
|
-
/>
|
|
764
|
-
<h4 style="margin: 12px 0 4px 0; font-size: 14px; color: #374151;">Quick Contact</h4>
|
|
765
|
-
<p style="margin: 0; font-size: 12px; color: #6b7280;">Pre-filled SMS message</p>
|
|
766
|
-
</div>
|
|
767
|
-
|
|
768
|
-
<div>
|
|
769
|
-
<DisplayQrCodeComponent
|
|
770
|
-
qrValue="geo:40.7589,-73.9851?q=40.7589,-73.9851(Times Square, New York)"
|
|
771
|
-
:variant="{ inner: 'dots', marker: 'circle', pixel: 'rounded' }"
|
|
772
|
-
:radius="4"
|
|
773
|
-
blackColor="#ec4899"
|
|
774
|
-
size="160px"
|
|
775
|
-
/>
|
|
776
|
-
<h4 style="margin: 12px 0 4px 0; font-size: 14px; color: #374151;">Location Sharing</h4>
|
|
777
|
-
<p style="margin: 0; font-size: 12px; color: #6b7280;">GPS coordinates</p>
|
|
778
|
-
</div>
|
|
779
|
-
|
|
780
|
-
</div>
|
|
781
|
-
</div>
|
|
782
|
-
|
|
783
|
-
</div>
|
|
784
|
-
|
|
785
|
-
<!-- Interactive Tools -->
|
|
786
|
-
<div v-if="selectedDemo === 'interactive'" style="display: grid; grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); gap: 32px;">
|
|
787
|
-
|
|
788
|
-
<div style="background: #f8fafc; padding: 24px; border-radius: 8px;">
|
|
789
|
-
<h3 style="margin: 0 0 16px 0; color: #374151; display: flex; align-items: center;">
|
|
790
|
-
📱 <span style="margin-left: 8px;">Camera Scanner</span>
|
|
791
|
-
</h3>
|
|
792
|
-
<p style="margin: 0 0 16px 0; color: #6b7280; font-size: 14px;">
|
|
793
|
-
Real-time QR code detection using device camera. Perfect for mobile apps and kiosks.
|
|
794
|
-
</p>
|
|
795
|
-
<div style="border: 2px dashed #d1d5db; border-radius: 8px; padding: 20px; text-align: center;">
|
|
796
|
-
<p style="margin: 0; color: #9ca3af;">Interactive camera component would appear here</p>
|
|
797
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Requires camera permissions in live environment</p>
|
|
798
|
-
</div>
|
|
799
|
-
</div>
|
|
800
|
-
|
|
801
|
-
<div style="background: #f8fafc; padding: 24px; border-radius: 8px;">
|
|
802
|
-
<h3 style="margin: 0 0 16px 0; color: #374151; display: flex; align-items: center;">
|
|
803
|
-
📁 <span style="margin-left: 8px;">File Decoder</span>
|
|
804
|
-
</h3>
|
|
805
|
-
<p style="margin: 0 0 16px 0; color: #6b7280; font-size: 14px;">
|
|
806
|
-
Upload or drag QR code images for instant decoding. Supports all major image formats.
|
|
807
|
-
</p>
|
|
808
|
-
<div style="border: 2px dashed #d1d5db; border-radius: 8px; padding: 20px; text-align: center; min-height: 120px; display: flex; align-items: center; justify-content: center;">
|
|
809
|
-
<div>
|
|
810
|
-
<p style="margin: 0; color: #9ca3af;">Drop QR code images here</p>
|
|
811
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">or click to upload</p>
|
|
812
|
-
</div>
|
|
813
|
-
</div>
|
|
814
|
-
</div>
|
|
815
|
-
|
|
816
|
-
</div>
|
|
817
|
-
|
|
818
|
-
<!-- Complete Showcase -->
|
|
819
|
-
<div v-if="selectedDemo === 'showcase'">
|
|
820
|
-
<div style="display: grid; gap: 40px;">
|
|
821
|
-
|
|
822
|
-
<!-- Style Variants Matrix -->
|
|
823
|
-
<div style="background: #f8fafc; padding: 24px; border-radius: 8px;">
|
|
824
|
-
<h3 style="margin: 0 0 20px 0; color: #374151;">Style Variant Matrix</h3>
|
|
825
|
-
<div style="display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; text-align: center;">
|
|
826
|
-
|
|
827
|
-
<div>
|
|
828
|
-
<DisplayQrCodeComponent
|
|
829
|
-
qrValue="Default Style"
|
|
830
|
-
:variant="{ inner: 'default', marker: 'default', pixel: 'default' }"
|
|
831
|
-
:radius="0"
|
|
832
|
-
blackColor="#000000"
|
|
833
|
-
size="120px"
|
|
834
|
-
/>
|
|
835
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Default</p>
|
|
836
|
-
</div>
|
|
837
|
-
|
|
838
|
-
<div>
|
|
839
|
-
<DisplayQrCodeComponent
|
|
840
|
-
qrValue="Circle Style"
|
|
841
|
-
:variant="{ inner: 'circle', marker: 'circle', pixel: 'circle' }"
|
|
842
|
-
:radius="8"
|
|
843
|
-
blackColor="#1e40af"
|
|
844
|
-
size="120px"
|
|
845
|
-
/>
|
|
846
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Circle</p>
|
|
847
|
-
</div>
|
|
848
|
-
|
|
849
|
-
<div>
|
|
850
|
-
<DisplayQrCodeComponent
|
|
851
|
-
qrValue="Rounded Style"
|
|
852
|
-
:variant="{ inner: 'rounded', marker: 'rounded', pixel: 'rounded' }"
|
|
853
|
-
:radius="12"
|
|
854
|
-
blackColor="#059669"
|
|
855
|
-
size="120px"
|
|
856
|
-
/>
|
|
857
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Rounded</p>
|
|
858
|
-
</div>
|
|
859
|
-
|
|
860
|
-
<div>
|
|
861
|
-
<DisplayQrCodeComponent
|
|
862
|
-
qrValue="Dots Style"
|
|
863
|
-
:variant="{ inner: 'dots', marker: 'dots', pixel: 'dots' }"
|
|
864
|
-
:radius="6"
|
|
865
|
-
blackColor="#dc2626"
|
|
866
|
-
size="120px"
|
|
867
|
-
/>
|
|
868
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Dots</p>
|
|
869
|
-
</div>
|
|
870
|
-
|
|
871
|
-
</div>
|
|
872
|
-
</div>
|
|
873
|
-
|
|
874
|
-
<!-- Size Variations -->
|
|
875
|
-
<div style="background: #f8fafc; padding: 24px; border-radius: 8px;">
|
|
876
|
-
<h3 style="margin: 0 0 20px 0; color: #374151;">Size Variations</h3>
|
|
877
|
-
<div style="display: flex; align-items: center; justify-content: space-around; flex-wrap: wrap; gap: 20px;">
|
|
878
|
-
|
|
879
|
-
<div style="text-align: center;">
|
|
880
|
-
<DisplayQrCodeComponent
|
|
881
|
-
qrValue="Small 96px"
|
|
882
|
-
:variant="businessCardVariant"
|
|
883
|
-
:radius="4"
|
|
884
|
-
blackColor="#7c3aed"
|
|
885
|
-
size="96px"
|
|
886
|
-
/>
|
|
887
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Small (96px)</p>
|
|
888
|
-
</div>
|
|
889
|
-
|
|
890
|
-
<div style="text-align: center;">
|
|
891
|
-
<DisplayQrCodeComponent
|
|
892
|
-
qrValue="Medium 160px"
|
|
893
|
-
:variant="businessCardVariant"
|
|
894
|
-
:radius="6"
|
|
895
|
-
blackColor="#7c3aed"
|
|
896
|
-
size="160px"
|
|
897
|
-
/>
|
|
898
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Medium (160px)</p>
|
|
899
|
-
</div>
|
|
900
|
-
|
|
901
|
-
<div style="text-align: center;">
|
|
902
|
-
<DisplayQrCodeComponent
|
|
903
|
-
qrValue="Large 240px"
|
|
904
|
-
:variant="businessCardVariant"
|
|
905
|
-
:radius="8"
|
|
906
|
-
blackColor="#7c3aed"
|
|
907
|
-
size="240px"
|
|
908
|
-
/>
|
|
909
|
-
<p style="margin: 8px 0 0 0; font-size: 12px; color: #6b7280;">Large (240px)</p>
|
|
910
|
-
</div>
|
|
911
|
-
|
|
912
|
-
</div>
|
|
913
|
-
</div>
|
|
914
|
-
|
|
915
|
-
</div>
|
|
916
|
-
</div>
|
|
917
|
-
|
|
918
|
-
</div>
|
|
919
|
-
`,
|
|
920
|
-
});
|
|
921
|
-
|
|
922
|
-
export const ComponentIntegration = IntegrationTemplate.bind({});
|
|
923
|
-
ComponentIntegration.parameters = {
|
|
924
|
-
docs: {
|
|
925
|
-
description: {
|
|
926
|
-
story:
|
|
927
|
-
"Complete integration showcase of all QR Code components with real-world examples, interactive tools, and comprehensive styling options. Switch between different demo modes to explore all capabilities.",
|
|
928
|
-
},
|
|
929
|
-
},
|
|
930
|
-
};
|
|
931
|
-
|
|
932
|
-
// Export the meta for the main component
|
|
933
|
-
export default DisplayQrCodeMeta;
|