create-brainerce-store 1.4.1 → 1.5.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 (37) hide show
  1. package/dist/index.js +1 -1
  2. package/messages/en.json +9 -1
  3. package/messages/he.json +9 -1
  4. package/package.json +1 -1
  5. package/templates/nextjs/base/src/app/account/page.tsx +8 -4
  6. package/templates/nextjs/base/src/app/auth/callback/page.tsx +90 -90
  7. package/templates/nextjs/base/src/app/cart/page.tsx +110 -110
  8. package/templates/nextjs/base/src/app/checkout/page.tsx +614 -614
  9. package/templates/nextjs/base/src/app/login/page.tsx +58 -58
  10. package/templates/nextjs/base/src/app/order-confirmation/page.tsx +193 -193
  11. package/templates/nextjs/base/src/app/page.tsx +98 -98
  12. package/templates/nextjs/base/src/app/products/[slug]/page.tsx +435 -435
  13. package/templates/nextjs/base/src/app/products/page.tsx +246 -246
  14. package/templates/nextjs/base/src/app/register/page.tsx +68 -68
  15. package/templates/nextjs/base/src/app/verify-email/page.tsx +293 -293
  16. package/templates/nextjs/base/src/components/account/order-history.tsx +198 -198
  17. package/templates/nextjs/base/src/components/account/profile-section.tsx +189 -40
  18. package/templates/nextjs/base/src/components/auth/login-form.tsx +94 -94
  19. package/templates/nextjs/base/src/components/auth/oauth-buttons.tsx +137 -137
  20. package/templates/nextjs/base/src/components/auth/register-form.tsx +184 -184
  21. package/templates/nextjs/base/src/components/cart/cart-item.tsx +153 -153
  22. package/templates/nextjs/base/src/components/cart/cart-summary.tsx +70 -70
  23. package/templates/nextjs/base/src/components/cart/coupon-input.tsx +134 -134
  24. package/templates/nextjs/base/src/components/cart/reservation-countdown.tsx +103 -103
  25. package/templates/nextjs/base/src/components/checkout/checkout-form.tsx +305 -305
  26. package/templates/nextjs/base/src/components/checkout/delivery-method-step.tsx +64 -64
  27. package/templates/nextjs/base/src/components/checkout/payment-step.tsx +350 -344
  28. package/templates/nextjs/base/src/components/checkout/pickup-step.tsx +199 -199
  29. package/templates/nextjs/base/src/components/checkout/shipping-step.tsx +110 -110
  30. package/templates/nextjs/base/src/components/checkout/tax-display.tsx +65 -65
  31. package/templates/nextjs/base/src/components/layout/footer.tsx +38 -38
  32. package/templates/nextjs/base/src/components/layout/header.tsx +332 -332
  33. package/templates/nextjs/base/src/components/products/product-card.tsx +96 -96
  34. package/templates/nextjs/base/src/components/products/product-grid.tsx +35 -35
  35. package/templates/nextjs/base/src/components/shared/loading-spinner.tsx +32 -32
  36. package/templates/nextjs/base/src/lib/translations.ts +11 -11
  37. package/templates/nextjs/base/src/providers/store-provider.tsx.ejs +5 -1
@@ -1,64 +1,64 @@
1
- 'use client';
2
-
3
- import { useTranslations } from '@/lib/translations';
4
- import { cn } from '@/lib/utils';
5
-
6
- interface DeliveryMethodStepProps {
7
- onSelect: (method: 'shipping' | 'pickup') => void;
8
- className?: string;
9
- }
10
-
11
- export function DeliveryMethodStep({ onSelect, className }: DeliveryMethodStepProps) {
12
- const t = useTranslations('checkout');
13
- return (
14
- <div className={cn('space-y-3', className)}>
15
- <button
16
- type="button"
17
- onClick={() => onSelect('shipping')}
18
- className="border-border hover:border-primary flex w-full items-center gap-4 rounded border px-4 py-4 text-start transition-colors"
19
- >
20
- <svg
21
- className="text-muted-foreground h-6 w-6 flex-shrink-0"
22
- fill="none"
23
- viewBox="0 0 24 24"
24
- stroke="currentColor"
25
- >
26
- <path
27
- strokeLinecap="round"
28
- strokeLinejoin="round"
29
- strokeWidth={1.5}
30
- d="M8.25 18.75a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m3 0h6m-9 0H3.375a1.125 1.125 0 01-1.125-1.125V14.25m17.25 4.5a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m3 0h1.125c.621 0 1.129-.504 1.09-1.124a17.902 17.902 0 00-3.213-9.193 2.056 2.056 0 00-1.58-.86H14.25M16.5 18.75h-2.25m0-11.177v-.958c0-.568-.422-1.048-.987-1.106a48.554 48.554 0 00-10.026 0 1.106 1.106 0 00-.987 1.106v7.635m12-6.677v6.677m0 4.5v-4.5m0 0h-12"
31
- />
32
- </svg>
33
- <div>
34
- <p className="text-foreground text-sm font-medium">{t('shipToAddress')}</p>
35
- <p className="text-muted-foreground mt-0.5 text-xs">{t('shipToAddressDesc')}</p>
36
- </div>
37
- </button>
38
-
39
- <button
40
- type="button"
41
- onClick={() => onSelect('pickup')}
42
- className="border-border hover:border-primary flex w-full items-center gap-4 rounded border px-4 py-4 text-start transition-colors"
43
- >
44
- <svg
45
- className="text-muted-foreground h-6 w-6 flex-shrink-0"
46
- fill="none"
47
- viewBox="0 0 24 24"
48
- stroke="currentColor"
49
- >
50
- <path
51
- strokeLinecap="round"
52
- strokeLinejoin="round"
53
- strokeWidth={1.5}
54
- d="M13.5 21v-7.5a.75.75 0 01.75-.75h3a.75.75 0 01.75.75V21m-4.5 0H2.36m11.14 0H18m0 0h3.64m-1.39 0V9.349m-16.5 11.65V9.35m0 0a3.001 3.001 0 003.75-.615A2.993 2.993 0 009.75 9.75c.896 0 1.7-.393 2.25-1.016a2.993 2.993 0 002.25 1.016c.896 0 1.7-.393 2.25-1.016a3.001 3.001 0 003.75.614m-16.5 0a3.004 3.004 0 01-.621-4.72L4.318 3.44A1.5 1.5 0 015.378 3h13.243a1.5 1.5 0 011.06.44l1.19 1.189a3 3 0 01-.621 4.72m-13.5 8.65h3.75a.75.75 0 00.75-.75V13.5a.75.75 0 00-.75-.75H6.75a.75.75 0 00-.75.75v3.15c0 .415.336.75.75.75z"
55
- />
56
- </svg>
57
- <div>
58
- <p className="text-foreground text-sm font-medium">{t('pickUpInStore')}</p>
59
- <p className="text-muted-foreground mt-0.5 text-xs">{t('pickUpInStoreDesc')}</p>
60
- </div>
61
- </button>
62
- </div>
63
- );
64
- }
1
+ 'use client';
2
+
3
+ import { useTranslations } from '@/lib/translations';
4
+ import { cn } from '@/lib/utils';
5
+
6
+ interface DeliveryMethodStepProps {
7
+ onSelect: (method: 'shipping' | 'pickup') => void;
8
+ className?: string;
9
+ }
10
+
11
+ export function DeliveryMethodStep({ onSelect, className }: DeliveryMethodStepProps) {
12
+ const t = useTranslations('checkout');
13
+ return (
14
+ <div className={cn('space-y-3', className)}>
15
+ <button
16
+ type="button"
17
+ onClick={() => onSelect('shipping')}
18
+ className="border-border hover:border-primary flex w-full items-center gap-4 rounded border px-4 py-4 text-start transition-colors"
19
+ >
20
+ <svg
21
+ className="text-muted-foreground h-6 w-6 flex-shrink-0"
22
+ fill="none"
23
+ viewBox="0 0 24 24"
24
+ stroke="currentColor"
25
+ >
26
+ <path
27
+ strokeLinecap="round"
28
+ strokeLinejoin="round"
29
+ strokeWidth={1.5}
30
+ d="M8.25 18.75a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m3 0h6m-9 0H3.375a1.125 1.125 0 01-1.125-1.125V14.25m17.25 4.5a1.5 1.5 0 01-3 0m3 0a1.5 1.5 0 00-3 0m3 0h1.125c.621 0 1.129-.504 1.09-1.124a17.902 17.902 0 00-3.213-9.193 2.056 2.056 0 00-1.58-.86H14.25M16.5 18.75h-2.25m0-11.177v-.958c0-.568-.422-1.048-.987-1.106a48.554 48.554 0 00-10.026 0 1.106 1.106 0 00-.987 1.106v7.635m12-6.677v6.677m0 4.5v-4.5m0 0h-12"
31
+ />
32
+ </svg>
33
+ <div>
34
+ <p className="text-foreground text-sm font-medium">{t('shipToAddress')}</p>
35
+ <p className="text-muted-foreground mt-0.5 text-xs">{t('shipToAddressDesc')}</p>
36
+ </div>
37
+ </button>
38
+
39
+ <button
40
+ type="button"
41
+ onClick={() => onSelect('pickup')}
42
+ className="border-border hover:border-primary flex w-full items-center gap-4 rounded border px-4 py-4 text-start transition-colors"
43
+ >
44
+ <svg
45
+ className="text-muted-foreground h-6 w-6 flex-shrink-0"
46
+ fill="none"
47
+ viewBox="0 0 24 24"
48
+ stroke="currentColor"
49
+ >
50
+ <path
51
+ strokeLinecap="round"
52
+ strokeLinejoin="round"
53
+ strokeWidth={1.5}
54
+ d="M13.5 21v-7.5a.75.75 0 01.75-.75h3a.75.75 0 01.75.75V21m-4.5 0H2.36m11.14 0H18m0 0h3.64m-1.39 0V9.349m-16.5 11.65V9.35m0 0a3.001 3.001 0 003.75-.615A2.993 2.993 0 009.75 9.75c.896 0 1.7-.393 2.25-1.016a2.993 2.993 0 002.25 1.016c.896 0 1.7-.393 2.25-1.016a3.001 3.001 0 003.75.614m-16.5 0a3.004 3.004 0 01-.621-4.72L4.318 3.44A1.5 1.5 0 015.378 3h13.243a1.5 1.5 0 011.06.44l1.19 1.189a3 3 0 01-.621 4.72m-13.5 8.65h3.75a.75.75 0 00.75-.75V13.5a.75.75 0 00-.75-.75H6.75a.75.75 0 00-.75.75v3.15c0 .415.336.75.75.75z"
55
+ />
56
+ </svg>
57
+ <div>
58
+ <p className="text-foreground text-sm font-medium">{t('pickUpInStore')}</p>
59
+ <p className="text-muted-foreground mt-0.5 text-xs">{t('pickUpInStoreDesc')}</p>
60
+ </div>
61
+ </button>
62
+ </div>
63
+ );
64
+ }