diff --git a/package.json b/package.json index a6cb514..47a8683 100644 --- a/package.json +++ b/package.json @@ -18,8 +18,10 @@ "@radix-ui/react-slot": "^1.1.0", "@supabase/supabase-js": "^2.45.0", "animejs": "^4.0.2", + "canvas-confetti": "^1.9.4", "class-variance-authority": "^0.7.0", "clsx": "^2.1.1", + "embla-carousel-react": "^8.6.0", "lucide-react": "^0.454.0", "motion": "^12.4.0", "qrcode.react": "^4.2.0", @@ -34,6 +36,7 @@ "@tailwindcss/vite": "^4.0.0", "@testing-library/jest-dom": "^6.5.0", "@testing-library/react": "^16.0.0", + "@types/canvas-confetti": "^1.9.0", "@types/node": "^22.9.0", "@types/react": "^19.0.0", "@types/react-dom": "^19.0.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 7d42831..72deb33 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,12 +17,18 @@ importers: animejs: specifier: ^4.0.2 version: 4.3.6 + canvas-confetti: + specifier: ^1.9.4 + version: 1.9.4 class-variance-authority: specifier: ^0.7.0 version: 0.7.1 clsx: specifier: ^2.1.1 version: 2.1.1 + embla-carousel-react: + specifier: ^8.6.0 + version: 8.6.0(react@19.2.5) lucide-react: specifier: ^0.454.0 version: 0.454.0(react@19.2.5) @@ -60,6 +66,9 @@ importers: '@testing-library/react': specifier: ^16.0.0 version: 16.3.2(@testing-library/dom@10.4.1)(@types/react-dom@19.2.3(@types/react@19.2.14))(@types/react@19.2.14)(react-dom@19.2.5(react@19.2.5))(react@19.2.5) + '@types/canvas-confetti': + specifier: ^1.9.0 + version: 1.9.0 '@types/node': specifier: ^22.9.0 version: 22.19.17 @@ -768,6 +777,9 @@ packages: '@types/babel__traverse@7.28.0': resolution: {integrity: sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==} + '@types/canvas-confetti@1.9.0': + resolution: {integrity: sha512-aBGj/dULrimR1XDZLtG9JwxX1b4HPRF6CX9Yfwh3NvstZEm1ZL7RBnel4keCPSqs1ANRu1u2Aoz9R+VmtjYuTg==} + '@types/chai@5.2.3': resolution: {integrity: sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==} @@ -976,6 +988,9 @@ packages: caniuse-lite@1.0.30001787: resolution: {integrity: sha512-mNcrMN9KeI68u7muanUpEejSLghOKlVhRqS/Za2IeyGllJ9I9otGpR9g3nsw7n4W378TE/LyIteA0+/FOZm4Kg==} + canvas-confetti@1.9.4: + resolution: {integrity: sha512-yxQbJkAVrFXWNbTUjPqjF7G+g6pDotOUHGbkZq2NELZUMDpiJ85rIEazVb8GTaAptNW2miJAXbs1BtioA251Pw==} + chai@5.3.3: resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==} engines: {node: '>=18'} @@ -1078,6 +1093,19 @@ packages: electron-to-chromium@1.5.336: resolution: {integrity: sha512-AbH9q9J455r/nLmdNZes0G0ZKcRX73FicwowalLs6ijwOmCJSRRrLX63lcAlzy9ux3dWK1w1+1nsBJEWN11hcQ==} + embla-carousel-react@8.6.0: + resolution: {integrity: sha512-0/PjqU7geVmo6F734pmPqpyHqiM99olvyecY7zdweCw+6tKEXnrE90pBiBbMMU8s5tICemzpQ3hi5EpxzGW+JA==} + peerDependencies: + react: ^16.8.0 || ^17.0.1 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc + + embla-carousel-reactive-utils@8.6.0: + resolution: {integrity: sha512-fMVUDUEx0/uIEDM0Mz3dHznDhfX+znCCDCeIophYb1QGVM7YThSWX+wz11zlYwWFOr74b4QLGg0hrGPJeG2s4A==} + peerDependencies: + embla-carousel: 8.6.0 + + embla-carousel@8.6.0: + resolution: {integrity: sha512-SjWyZBHJPbqxHOzckOfo8lHisEaJWmwd23XppYFYVh10bU66/Pn5tkVkbkCMZVdbUE5eTCI2nD8OyIP4Z+uwkA==} + enhanced-resolve@5.20.1: resolution: {integrity: sha512-Qohcme7V1inbAfvjItgw0EaxVX5q2rdVEZHRBrEQdRZTssLDGsL8Lwrznl8oQ/6kuTJONLaDcGjkNP247XEhcA==} engines: {node: '>=10.13.0'} @@ -2514,6 +2542,8 @@ snapshots: dependencies: '@babel/types': 7.29.0 + '@types/canvas-confetti@1.9.0': {} + '@types/chai@5.2.3': dependencies: '@types/deep-eql': 4.0.2 @@ -2757,6 +2787,8 @@ snapshots: caniuse-lite@1.0.30001787: {} + canvas-confetti@1.9.4: {} + chai@5.3.3: dependencies: assertion-error: 2.0.1 @@ -2842,6 +2874,18 @@ snapshots: electron-to-chromium@1.5.336: {} + embla-carousel-react@8.6.0(react@19.2.5): + dependencies: + embla-carousel: 8.6.0 + embla-carousel-reactive-utils: 8.6.0(embla-carousel@8.6.0) + react: 19.2.5 + + embla-carousel-reactive-utils@8.6.0(embla-carousel@8.6.0): + dependencies: + embla-carousel: 8.6.0 + + embla-carousel@8.6.0: {} + enhanced-resolve@5.20.1: dependencies: graceful-fs: 4.2.11 diff --git a/src/components/checkout/PixCheckout.tsx b/src/components/checkout/PixCheckout.tsx index 037733b..befa924 100644 --- a/src/components/checkout/PixCheckout.tsx +++ b/src/components/checkout/PixCheckout.tsx @@ -1,5 +1,6 @@ import { useEffect, useState } from 'react' import { QRCodeSVG } from 'qrcode.react' +import { motion } from 'motion/react' import { chatwootApi, type CreateReservationResponse } from '@/lib/chatwootApi' import { Button } from '@/components/ui/button' import { formatBRL } from '@/lib/formatters' @@ -56,9 +57,19 @@ export function PixCheckout({ reservation, depositCents, onPaid, onCancel }: Pro

{statusMsg}

-
+ -
+