tanstack_start_ts 1.0.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.
- package/.wrangler/deploy/config.json +1 -0
- package/bunfig.toml +6 -0
- package/components.json +22 -0
- package/config.json +0 -0
- package/dist/client/.assetsignore +2 -0
- package/dist/client/assets/ProductCard-DbIkJAE-.js +1 -0
- package/dist/client/assets/about-AskxOruL.js +1 -0
- package/dist/client/assets/admin-BZVcAQM3.js +1 -0
- package/dist/client/assets/admin.functions--RdVcuBx.js +1 -0
- package/dist/client/assets/admin.login-QgrF_9Fp.js +1 -0
- package/dist/client/assets/affiliate-disclosure-BIAsA-HO.js +1 -0
- package/dist/client/assets/categories-D0N418mK.js +1 -0
- package/dist/client/assets/category._slug-aCaQm14E.js +1 -0
- package/dist/client/assets/contact-PhvO-V15.js +1 -0
- package/dist/client/assets/faq-BsiHWPM8.js +1 -0
- package/dist/client/assets/hero-bg-BP2eVUIX.jpg +0 -0
- package/dist/client/assets/index-BU9rnkF3.js +1 -0
- package/dist/client/assets/index-BpJWZkva.js +1 -0
- package/dist/client/assets/index-vRX-zAyq.js +1 -0
- package/dist/client/assets/login-DteE0ZGp.js +1 -0
- package/dist/client/assets/logo-pSNfLJQk.png +0 -0
- package/dist/client/assets/privacy-B_Pu7040.js +1 -0
- package/dist/client/assets/product-links-BkZ41Gv3.js +1 -0
- package/dist/client/assets/product._id-BVUysCW-.js +1 -0
- package/dist/client/assets/products.functions-cGzRziKO.js +1 -0
- package/dist/client/assets/profile-CveRcKq2.js +1 -0
- package/dist/client/assets/reset-password-ySEjItX_.js +1 -0
- package/dist/client/assets/saved-CHtdQDJF.js +1 -0
- package/dist/client/assets/search-CXWfET1y.js +1 -0
- package/dist/client/assets/signup-CEx90iuV.js +1 -0
- package/dist/client/assets/styles-DrNJG0BO.css +1 -0
- package/dist/client/assets/terms-VqJ9kX9b.js +1 -0
- package/dist/client/assets/update-password-C-d0ix5e.js +1 -0
- package/dist/client/assets/vendor-aria-hidden-DvXkyWUv.js +1 -0
- package/dist/client/assets/vendor-class-variance-authority-5VPnzWs2.js +1 -0
- package/dist/client/assets/vendor-clsx-B-dksMZM.js +1 -0
- package/dist/client/assets/vendor-cookie-es-CS0aJGDi.js +1 -0
- package/dist/client/assets/vendor-detect-node-es-l0sNRNKZ.js +1 -0
- package/dist/client/assets/vendor-floating-ui-core-BlUy28sp.js +1 -0
- package/dist/client/assets/vendor-floating-ui-dom-BxK0hn2R.js +1 -0
- package/dist/client/assets/vendor-floating-ui-react-dom-Bas3975S.js +1 -0
- package/dist/client/assets/vendor-floating-ui-utils-BfYUAVcw.js +1 -0
- package/dist/client/assets/vendor-framer-motion-BMdL-cuX.js +9 -0
- package/dist/client/assets/vendor-get-nonce-C-Z93AgS.js +1 -0
- package/dist/client/assets/vendor-iceberg-js-tWD4K6Lg.js +1 -0
- package/dist/client/assets/vendor-lovable.dev-cloud-auth-js-VuzqtJVg.js +1 -0
- package/dist/client/assets/vendor-lucide-react-b5K2fehp.js +1 -0
- package/dist/client/assets/vendor-motion-dom-BETJamZt.js +1 -0
- package/dist/client/assets/vendor-motion-utils-BuWewJbj.js +1 -0
- package/dist/client/assets/vendor-radix-ui-primitive-Dc_FVRD7.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-accordion-C22Rgxe9.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-arrow-DMHj2mKI.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-avatar-CVPBkFXg.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-collapsible-BvM-4sKX.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-collection-D9KtqmHm.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-compose-refs-Cvq0AS8Z.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-context-CAqqn5Nx.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-dialog-DZ01vOLq.js +5 -0
- package/dist/client/assets/vendor-radix-ui-react-direction-DxZwNuei.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-dismissable-layer-Dqgrs55Y.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-dropdown-menu-0uzvrqkn.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-focus-guards-DgWoZ-fP.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-focus-scope-BLIu5QaL.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-id-bpga_rLa.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-menu-D0qf2r6_.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-popper-BafIylxU.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-portal-BnAsfNCS.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-presence-C-f3UKQ2.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-primitive-zTHwXNoz.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-roving-focus-jyJB8K2E.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-slot-6LXHJrHl.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-callback-ref-E91aPc6s.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-controllable-state-Ca3eMtxa.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-effect-event-CPeX4A3c.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-escape-keydown-7n3YsXFo.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-is-hydrated-C1PY1qNv.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-layout-effect-B3AcGWPy.js +1 -0
- package/dist/client/assets/vendor-radix-ui-react-use-size-CXS04sct.js +1 -0
- package/dist/client/assets/vendor-react-dom-BnNs-kzm.js +9 -0
- package/dist/client/assets/vendor-react-gJPiVnX5.js +1 -0
- package/dist/client/assets/vendor-react-remove-scroll-DHKl-IMP.js +4 -0
- package/dist/client/assets/vendor-react-remove-scroll-bar-CSjdInc2.js +38 -0
- package/dist/client/assets/vendor-react-style-singleton-BqHpkgXn.js +1 -0
- package/dist/client/assets/vendor-scheduler-7OC5HNn7.js +1 -0
- package/dist/client/assets/vendor-seroval-B_Fur-nl.js +3 -0
- package/dist/client/assets/vendor-seroval-plugins-CBHnPkZJ.js +1 -0
- package/dist/client/assets/vendor-sonner-71-LdGG1.js +1 -0
- package/dist/client/assets/vendor-supabase-auth-js-DWrN-bIx.js +18 -0
- package/dist/client/assets/vendor-supabase-functions-js-uY_V-TxC.js +1 -0
- package/dist/client/assets/vendor-supabase-phoenix-BzEf37Ve.js +2 -0
- package/dist/client/assets/vendor-supabase-postgrest-js-C4rBWbCx.js +4 -0
- package/dist/client/assets/vendor-supabase-realtime-js-D6BlOYKE.js +23 -0
- package/dist/client/assets/vendor-supabase-storage-js-BG98L3Zz.js +1 -0
- package/dist/client/assets/vendor-supabase-supabase-js-DCCzdwBJ.js +1 -0
- package/dist/client/assets/vendor-tailwind-merge-Ct12j0u0.js +1 -0
- package/dist/client/assets/vendor-tanstack-history-C617CaxG.js +1 -0
- package/dist/client/assets/vendor-tanstack-query-core-7wuJJ5ZL.js +1 -0
- package/dist/client/assets/vendor-tanstack-react-query-HImzo8sX.js +1 -0
- package/dist/client/assets/vendor-tanstack-react-router-sIZLK-LU.js +1 -0
- package/dist/client/assets/vendor-tanstack-react-start-client-GiYCfWmf.js +1 -0
- package/dist/client/assets/vendor-tanstack-react-store-EvTi3ahh.js +1 -0
- package/dist/client/assets/vendor-tanstack-router-core-Cr7bYUZv.js +1 -0
- package/dist/client/assets/vendor-tanstack-start-client-core-C-00BBOu.js +2 -0
- package/dist/client/assets/vendor-tanstack-start-fn-stubs-l0sNRNKZ.js +1 -0
- package/dist/client/assets/vendor-tanstack-store-BC7mA7pq.js +1 -0
- package/dist/client/assets/vendor-tslib-Du-meQkk.js +1 -0
- package/dist/client/assets/vendor-use-callback-ref-C_fIAtot.js +1 -0
- package/dist/client/assets/vendor-use-sidecar-Bh0DDN6h.js +1 -0
- package/dist/client/assets/vendor-use-sync-external-store-ZvKHXaIn.js +1 -0
- package/dist/client/assets/vendor-vercel-analytics-DwPM5BWs.js +1 -0
- package/dist/client/assets/vendor-zod-By9teAtI.js +1 -0
- package/dist/client/robots.txt +2 -0
- package/dist/server/.dev.vars +5 -0
- package/dist/server/.vite/manifest.json +2528 -0
- package/dist/server/assets/ProductCard-CUPXy5Eo.js +149 -0
- package/dist/server/assets/_tanstack-start-manifest_v-do7vTWFD.js +4 -0
- package/dist/server/assets/about-TfKQw0Ga.js +28 -0
- package/dist/server/assets/admin-DspfJOJk.js +578 -0
- package/dist/server/assets/admin.functions-B78ppWLR.js +645 -0
- package/dist/server/assets/admin.functions-BWlKBoTL.js +93 -0
- package/dist/server/assets/admin.login-CV7QfeA6.js +139 -0
- package/dist/server/assets/affiliate-disclosure-B1wI1cDb.js +86 -0
- package/dist/server/assets/auth-middleware-Cn49MidW.js +62 -0
- package/dist/server/assets/categories-Z7jnAYZP.js +108 -0
- package/dist/server/assets/category._slug-D0XY3FGK.js +112 -0
- package/dist/server/assets/contact-IzyONsXs.js +104 -0
- package/dist/server/assets/faq-aRhB_CR3.js +133 -0
- package/dist/server/assets/hero-bg-BP2eVUIX.jpg +0 -0
- package/dist/server/assets/index-BTPHbXw9.js +221 -0
- package/dist/server/assets/index-ByJkHkrU.js +30 -0
- package/dist/server/assets/login-Dvy5Dm0f.js +175 -0
- package/dist/server/assets/logo-pSNfLJQk.png +0 -0
- package/dist/server/assets/privacy-B6Wiez1P.js +93 -0
- package/dist/server/assets/product-links-CGYEPP56.js +16 -0
- package/dist/server/assets/product._id-BpRa-1z0.js +231 -0
- package/dist/server/assets/products.functions-DSlmibYN.js +209 -0
- package/dist/server/assets/products.functions-DlHkRiqi.js +24 -0
- package/dist/server/assets/profile-B0NWzVAZ.js +314 -0
- package/dist/server/assets/reset-password-CY-rmqMr.js +115 -0
- package/dist/server/assets/saved-7FA6Dbom.js +126 -0
- package/dist/server/assets/search-Yw5c_fZa.js +329 -0
- package/dist/server/assets/signup-UPzgZo4i.js +143 -0
- package/dist/server/assets/styles-DrNJG0BO.css +1 -0
- package/dist/server/assets/terms-CMnX95bP.js +89 -0
- package/dist/server/assets/update-password-Cr94ea8n.js +131 -0
- package/dist/server/assets/vendor-aria-hidden-DPa16MWu.js +122 -0
- package/dist/server/assets/vendor-class-variance-authority-0YxJPB9Y.js +44 -0
- package/dist/server/assets/vendor-cloudflare-unenv-preset-ya0VEFBz.js +250 -0
- package/dist/server/assets/vendor-clsx-DgYk2OaC.js +16 -0
- package/dist/server/assets/vendor-cookie-es-DAoofYiI.js +44 -0
- package/dist/server/assets/vendor-detect-node-es-l0sNRNKZ.js +1 -0
- package/dist/server/assets/vendor-floating-ui-core-3tkK0THV.js +726 -0
- package/dist/server/assets/vendor-floating-ui-dom-C-cPtgJv.js +626 -0
- package/dist/server/assets/vendor-floating-ui-react-dom-CRG6gBpH.js +319 -0
- package/dist/server/assets/vendor-floating-ui-utils-DmXANH-E.js +320 -0
- package/dist/server/assets/vendor-framer-motion-X4zAkX3J.js +1979 -0
- package/dist/server/assets/vendor-get-nonce-DiSj3EHl.js +9 -0
- package/dist/server/assets/vendor-h3-v2-CCobnLY5.js +287 -0
- package/dist/server/assets/vendor-iceberg-js-bHCkXyJn.js +534 -0
- package/dist/server/assets/vendor-isbot-CZ7WjwVs.js +21 -0
- package/dist/server/assets/vendor-lovable.dev-cloud-auth-js-BE03njZw.js +180 -0
- package/dist/server/assets/vendor-lucide-react-Ddew6HYb.js +458 -0
- package/dist/server/assets/vendor-motion-dom-D2MTwGIG.js +5983 -0
- package/dist/server/assets/vendor-motion-utils-LJlIFN6m.js +161 -0
- package/dist/server/assets/vendor-radix-ui-primitive-B-mNdDrH.js +11 -0
- package/dist/server/assets/vendor-radix-ui-react-accordion-1Izf6x00.js +308 -0
- package/dist/server/assets/vendor-radix-ui-react-arrow-B882lnFK.js +23 -0
- package/dist/server/assets/vendor-radix-ui-react-avatar-BVgZt2Ab.js +209 -0
- package/dist/server/assets/vendor-radix-ui-react-collapsible-DCBbMZiS.js +147 -0
- package/dist/server/assets/vendor-radix-ui-react-collection-BZ2srfgU.js +150 -0
- package/dist/server/assets/vendor-radix-ui-react-compose-refs-D3qsKVk1.js +39 -0
- package/dist/server/assets/vendor-radix-ui-react-context-BVoNDLue.js +78 -0
- package/dist/server/assets/vendor-radix-ui-react-dialog-DlxMaNYK.js +406 -0
- package/dist/server/assets/vendor-radix-ui-react-direction-Dt_WDL1t.js +9 -0
- package/dist/server/assets/vendor-radix-ui-react-dismissable-layer-CjsuPohV.js +210 -0
- package/dist/server/assets/vendor-radix-ui-react-dropdown-menu-DVxKumY8.js +263 -0
- package/dist/server/assets/vendor-radix-ui-react-focus-guards-D_6NoePE.js +29 -0
- package/dist/server/assets/vendor-radix-ui-react-focus-scope-DEIhTJJH.js +206 -0
- package/dist/server/assets/vendor-radix-ui-react-id-DFFpgh6m.js +14 -0
- package/dist/server/assets/vendor-radix-ui-react-menu-CiTMLwjT.js +893 -0
- package/dist/server/assets/vendor-radix-ui-react-popper-23Ye2Vyc.js +286 -0
- package/dist/server/assets/vendor-radix-ui-react-portal-CZCH5uPk.js +16 -0
- package/dist/server/assets/vendor-radix-ui-react-presence-CaAULlDU.js +128 -0
- package/dist/server/assets/vendor-radix-ui-react-primitive-BeOk3UYa.js +124 -0
- package/dist/server/assets/vendor-radix-ui-react-roving-focus-DES9GR8l.js +224 -0
- package/dist/server/assets/vendor-radix-ui-react-slot-DUhZbzoH.js +103 -0
- package/dist/server/assets/vendor-radix-ui-react-use-callback-ref-BynBgohw.js +11 -0
- package/dist/server/assets/vendor-radix-ui-react-use-controllable-state-C9KpT6DG.js +69 -0
- package/dist/server/assets/vendor-radix-ui-react-use-effect-event-gpNY2xjS.js +1 -0
- package/dist/server/assets/vendor-radix-ui-react-use-escape-keydown-CcYRQ2pp.js +17 -0
- package/dist/server/assets/vendor-radix-ui-react-use-is-hydrated-D_LcBPXY.js +15 -0
- package/dist/server/assets/vendor-radix-ui-react-use-layout-effect-1LNLXAjr.js +6 -0
- package/dist/server/assets/vendor-radix-ui-react-use-size-D6fiKJQo.js +39 -0
- package/dist/server/assets/vendor-react-DvBrY0qp.js +511 -0
- package/dist/server/assets/vendor-react-dom-yvMLPM0j.js +10484 -0
- package/dist/server/assets/vendor-react-remove-scroll-BNtiEvVN.js +328 -0
- package/dist/server/assets/vendor-react-remove-scroll-bar-hLqRASRk.js +82 -0
- package/dist/server/assets/vendor-react-style-singleton-BXjcXskB.js +69 -0
- package/dist/server/assets/vendor-rou3-3NaGPdI8.js +8 -0
- package/dist/server/assets/vendor-seroval-dJyC-Zhz.js +1775 -0
- package/dist/server/assets/vendor-seroval-plugins-Pq_U2meB.js +58 -0
- package/dist/server/assets/vendor-sonner-CqbjhsRh.js +1086 -0
- package/dist/server/assets/vendor-srvx-BA-baEX9.js +6 -0
- package/dist/server/assets/vendor-supabase-auth-js-D4xjVprw.js +7602 -0
- package/dist/server/assets/vendor-supabase-functions-js-sWy4UYn1.js +322 -0
- package/dist/server/assets/vendor-supabase-phoenix-Bw3Uh2Nn.js +1777 -0
- package/dist/server/assets/vendor-supabase-postgrest-js-AO-BXa7I.js +4938 -0
- package/dist/server/assets/vendor-supabase-realtime-js-BtdNgJbm.js +2111 -0
- package/dist/server/assets/vendor-supabase-storage-js-Dk_MrPYO.js +2679 -0
- package/dist/server/assets/vendor-supabase-supabase-js-D1EEtG3j.js +697 -0
- package/dist/server/assets/vendor-tailwind-merge-BHb_obmC.js +3255 -0
- package/dist/server/assets/vendor-tanstack-history-C4pKJmkt.js +204 -0
- package/dist/server/assets/vendor-tanstack-query-core-PwwTR5ld.js +2552 -0
- package/dist/server/assets/vendor-tanstack-react-query-hhHzXAK1.js +190 -0
- package/dist/server/assets/vendor-tanstack-react-router-XzqpA65A.js +1120 -0
- package/dist/server/assets/vendor-tanstack-react-start-RvWUpvat.js +37 -0
- package/dist/server/assets/vendor-tanstack-react-start-client-gpNY2xjS.js +1 -0
- package/dist/server/assets/vendor-tanstack-react-start-server-uj_Y9pEN.js +15 -0
- package/dist/server/assets/vendor-tanstack-react-store-gpNY2xjS.js +1 -0
- package/dist/server/assets/vendor-tanstack-router-core-6wywV3KN.js +4252 -0
- package/dist/server/assets/vendor-tanstack-start-client-core-DoOKV2pA.js +1741 -0
- package/dist/server/assets/vendor-tanstack-start-fn-stubs-l0sNRNKZ.js +1 -0
- package/dist/server/assets/vendor-tanstack-start-server-core-CsAstXv7.js +1421 -0
- package/dist/server/assets/vendor-tanstack-start-storage-context-DgH9hIJT.js +17 -0
- package/dist/server/assets/vendor-tanstack-store-l0sNRNKZ.js +1 -0
- package/dist/server/assets/vendor-tslib-_8ICaZ64.js +67 -0
- package/dist/server/assets/vendor-unenv-DUvF4YIF.js +544 -0
- package/dist/server/assets/vendor-use-callback-ref-DMFDRvmi.js +66 -0
- package/dist/server/assets/vendor-use-sidecar-DG1tHua4.js +106 -0
- package/dist/server/assets/vendor-use-sync-external-store-rZ8vi0It.js +64 -0
- package/dist/server/assets/vendor-vercel-analytics-oP8BDp0L.js +168 -0
- package/dist/server/assets/vendor-zod-BRyQdbC-.js +3580 -0
- package/dist/server/index.js +158 -0
- package/dist/server/wrangler.json +1 -0
- package/enable-powershell.ps1 +7 -0
- package/eslint.config.js +41 -0
- package/lint.bat +4 -0
- package/package.json +95 -0
- package/public/robots.txt +2 -0
- package/run-npm-build.cjs +20 -0
- package/run-npm-build.js +20 -0
- package/src/assets/hero-bg.jpg +0 -0
- package/src/assets/logo.png +0 -0
- package/src/components/scrollsy/Footer.tsx +68 -0
- package/src/components/scrollsy/LiveTicker.tsx +31 -0
- package/src/components/scrollsy/Logo.tsx +28 -0
- package/src/components/scrollsy/Nav.tsx +255 -0
- package/src/components/scrollsy/ProductCard.tsx +190 -0
- package/src/components/scrollsy/ProductFilters.tsx +226 -0
- package/src/components/scrollsy/SupportWidget.tsx +197 -0
- package/src/components/ui/accordion.tsx +51 -0
- package/src/components/ui/alert-dialog.tsx +115 -0
- package/src/components/ui/alert.tsx +49 -0
- package/src/components/ui/aspect-ratio.tsx +5 -0
- package/src/components/ui/avatar.tsx +47 -0
- package/src/components/ui/badge.tsx +32 -0
- package/src/components/ui/breadcrumb.tsx +101 -0
- package/src/components/ui/button.tsx +49 -0
- package/src/components/ui/calendar.tsx +177 -0
- package/src/components/ui/card.tsx +55 -0
- package/src/components/ui/carousel.tsx +240 -0
- package/src/components/ui/chart.tsx +331 -0
- package/src/components/ui/checkbox.tsx +26 -0
- package/src/components/ui/collapsible.tsx +11 -0
- package/src/components/ui/command.tsx +143 -0
- package/src/components/ui/context-menu.tsx +187 -0
- package/src/components/ui/dialog.tsx +104 -0
- package/src/components/ui/drawer.tsx +98 -0
- package/src/components/ui/dropdown-menu.tsx +188 -0
- package/src/components/ui/form.tsx +171 -0
- package/src/components/ui/hover-card.tsx +27 -0
- package/src/components/ui/input-otp.tsx +69 -0
- package/src/components/ui/input.tsx +22 -0
- package/src/components/ui/label.tsx +21 -0
- package/src/components/ui/menubar.tsx +229 -0
- package/src/components/ui/navigation-menu.tsx +120 -0
- package/src/components/ui/pagination.tsx +98 -0
- package/src/components/ui/popover.tsx +31 -0
- package/src/components/ui/progress.tsx +25 -0
- package/src/components/ui/radio-group.tsx +36 -0
- package/src/components/ui/resizable.tsx +37 -0
- package/src/components/ui/scroll-area.tsx +44 -0
- package/src/components/ui/select.tsx +152 -0
- package/src/components/ui/separator.tsx +24 -0
- package/src/components/ui/sheet.tsx +122 -0
- package/src/components/ui/sidebar.tsx +744 -0
- package/src/components/ui/skeleton.tsx +7 -0
- package/src/components/ui/slider.tsx +23 -0
- package/src/components/ui/sonner.tsx +23 -0
- package/src/components/ui/switch.tsx +27 -0
- package/src/components/ui/table.tsx +94 -0
- package/src/components/ui/tabs.tsx +53 -0
- package/src/components/ui/textarea.tsx +21 -0
- package/src/components/ui/toggle-group.tsx +57 -0
- package/src/components/ui/toggle.tsx +42 -0
- package/src/components/ui/tooltip.tsx +32 -0
- package/src/hooks/use-auth.ts +26 -0
- package/src/hooks/use-mobile.tsx +19 -0
- package/src/integrations/lovable/index.ts +41 -0
- package/src/lib/admin.functions.ts +564 -0
- package/src/lib/error-capture.ts +27 -0
- package/src/lib/error-page.ts +30 -0
- package/src/lib/product-links.ts +39 -0
- package/src/lib/products.functions.ts +101 -0
- package/src/lib/utils.ts +6 -0
- package/src/routeTree.gen.ts +480 -0
- package/src/router.tsx +16 -0
- package/src/routes/__root.tsx +177 -0
- package/src/routes/about.tsx +66 -0
- package/src/routes/admin.login.tsx +95 -0
- package/src/routes/admin.tsx +811 -0
- package/src/routes/affiliate-disclosure.tsx +35 -0
- package/src/routes/categories.tsx +57 -0
- package/src/routes/category.$slug.tsx +51 -0
- package/src/routes/contact.tsx +69 -0
- package/src/routes/faq.tsx +63 -0
- package/src/routes/index.tsx +269 -0
- package/src/routes/login.tsx +160 -0
- package/src/routes/privacy.tsx +39 -0
- package/src/routes/product.$id.tsx +212 -0
- package/src/routes/profile.tsx +393 -0
- package/src/routes/reset-password.tsx +71 -0
- package/src/routes/saved.tsx +83 -0
- package/src/routes/search.tsx +136 -0
- package/src/routes/signup.tsx +108 -0
- package/src/routes/sitemap[.]xml.ts +34 -0
- package/src/routes/terms.tsx +40 -0
- package/src/routes/update-password.tsx +91 -0
- package/src/server.ts +80 -0
- package/src/start.ts +24 -0
- package/src/styles.css +333 -0
- package/terminal-test-output.txt +1 -0
- package/tsconfig.json +27 -0
- package/vercel.json +26 -0
- package/vite.config.ts +38 -0
- package/wrangler.jsonc +7 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import * as DialogPrimitive from "@radix-ui/react-dialog";
|
|
5
|
+
import { X } from "lucide-react";
|
|
6
|
+
|
|
7
|
+
import { cn } from "@/lib/utils";
|
|
8
|
+
|
|
9
|
+
const Dialog = DialogPrimitive.Root;
|
|
10
|
+
|
|
11
|
+
const DialogTrigger = DialogPrimitive.Trigger;
|
|
12
|
+
|
|
13
|
+
const DialogPortal = DialogPrimitive.Portal;
|
|
14
|
+
|
|
15
|
+
const DialogClose = DialogPrimitive.Close;
|
|
16
|
+
|
|
17
|
+
const DialogOverlay = React.forwardRef<
|
|
18
|
+
React.ElementRef<typeof DialogPrimitive.Overlay>,
|
|
19
|
+
React.ComponentPropsWithoutRef<typeof DialogPrimitive.Overlay>
|
|
20
|
+
>(({ className, ...props }, ref) => (
|
|
21
|
+
<DialogPrimitive.Overlay
|
|
22
|
+
ref={ref}
|
|
23
|
+
className={cn(
|
|
24
|
+
"fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
|
|
25
|
+
className,
|
|
26
|
+
)}
|
|
27
|
+
{...props}
|
|
28
|
+
/>
|
|
29
|
+
));
|
|
30
|
+
DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
|
|
31
|
+
|
|
32
|
+
const DialogContent = React.forwardRef<
|
|
33
|
+
React.ElementRef<typeof DialogPrimitive.Content>,
|
|
34
|
+
React.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>
|
|
35
|
+
>(({ className, children, ...props }, ref) => (
|
|
36
|
+
<DialogPortal>
|
|
37
|
+
<DialogOverlay />
|
|
38
|
+
<DialogPrimitive.Content
|
|
39
|
+
ref={ref}
|
|
40
|
+
className={cn(
|
|
41
|
+
"fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 sm:rounded-lg",
|
|
42
|
+
className,
|
|
43
|
+
)}
|
|
44
|
+
{...props}
|
|
45
|
+
>
|
|
46
|
+
{children}
|
|
47
|
+
<DialogPrimitive.Close className="absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background cursor-pointer transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground">
|
|
48
|
+
<X className="h-4 w-4" />
|
|
49
|
+
<span className="sr-only">Close</span>
|
|
50
|
+
</DialogPrimitive.Close>
|
|
51
|
+
</DialogPrimitive.Content>
|
|
52
|
+
</DialogPortal>
|
|
53
|
+
));
|
|
54
|
+
DialogContent.displayName = DialogPrimitive.Content.displayName;
|
|
55
|
+
|
|
56
|
+
const DialogHeader = ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) => (
|
|
57
|
+
<div className={cn("flex flex-col space-y-1.5 text-center sm:text-left", className)} {...props} />
|
|
58
|
+
);
|
|
59
|
+
DialogHeader.displayName = "DialogHeader";
|
|
60
|
+
|
|
61
|
+
const DialogFooter = ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) => (
|
|
62
|
+
<div
|
|
63
|
+
className={cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className)}
|
|
64
|
+
{...props}
|
|
65
|
+
/>
|
|
66
|
+
);
|
|
67
|
+
DialogFooter.displayName = "DialogFooter";
|
|
68
|
+
|
|
69
|
+
const DialogTitle = React.forwardRef<
|
|
70
|
+
React.ElementRef<typeof DialogPrimitive.Title>,
|
|
71
|
+
React.ComponentPropsWithoutRef<typeof DialogPrimitive.Title>
|
|
72
|
+
>(({ className, ...props }, ref) => (
|
|
73
|
+
<DialogPrimitive.Title
|
|
74
|
+
ref={ref}
|
|
75
|
+
className={cn("text-lg font-semibold leading-none tracking-tight", className)}
|
|
76
|
+
{...props}
|
|
77
|
+
/>
|
|
78
|
+
));
|
|
79
|
+
DialogTitle.displayName = DialogPrimitive.Title.displayName;
|
|
80
|
+
|
|
81
|
+
const DialogDescription = React.forwardRef<
|
|
82
|
+
React.ElementRef<typeof DialogPrimitive.Description>,
|
|
83
|
+
React.ComponentPropsWithoutRef<typeof DialogPrimitive.Description>
|
|
84
|
+
>(({ className, ...props }, ref) => (
|
|
85
|
+
<DialogPrimitive.Description
|
|
86
|
+
ref={ref}
|
|
87
|
+
className={cn("text-sm text-muted-foreground", className)}
|
|
88
|
+
{...props}
|
|
89
|
+
/>
|
|
90
|
+
));
|
|
91
|
+
DialogDescription.displayName = DialogPrimitive.Description.displayName;
|
|
92
|
+
|
|
93
|
+
export {
|
|
94
|
+
Dialog,
|
|
95
|
+
DialogPortal,
|
|
96
|
+
DialogOverlay,
|
|
97
|
+
DialogTrigger,
|
|
98
|
+
DialogClose,
|
|
99
|
+
DialogContent,
|
|
100
|
+
DialogHeader,
|
|
101
|
+
DialogFooter,
|
|
102
|
+
DialogTitle,
|
|
103
|
+
DialogDescription,
|
|
104
|
+
};
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Drawer as DrawerPrimitive } from "vaul";
|
|
3
|
+
|
|
4
|
+
import { cn } from "@/lib/utils";
|
|
5
|
+
|
|
6
|
+
const Drawer = ({
|
|
7
|
+
shouldScaleBackground = true,
|
|
8
|
+
...props
|
|
9
|
+
}: React.ComponentProps<typeof DrawerPrimitive.Root>) => (
|
|
10
|
+
<DrawerPrimitive.Root shouldScaleBackground={shouldScaleBackground} {...props} />
|
|
11
|
+
);
|
|
12
|
+
Drawer.displayName = "Drawer";
|
|
13
|
+
|
|
14
|
+
const DrawerTrigger = DrawerPrimitive.Trigger;
|
|
15
|
+
|
|
16
|
+
const DrawerPortal = DrawerPrimitive.Portal;
|
|
17
|
+
|
|
18
|
+
const DrawerClose = DrawerPrimitive.Close;
|
|
19
|
+
|
|
20
|
+
const DrawerOverlay = React.forwardRef<
|
|
21
|
+
React.ElementRef<typeof DrawerPrimitive.Overlay>,
|
|
22
|
+
React.ComponentPropsWithoutRef<typeof DrawerPrimitive.Overlay>
|
|
23
|
+
>(({ className, ...props }, ref) => (
|
|
24
|
+
<DrawerPrimitive.Overlay
|
|
25
|
+
ref={ref}
|
|
26
|
+
className={cn("fixed inset-0 z-50 bg-black/80", className)}
|
|
27
|
+
{...props}
|
|
28
|
+
/>
|
|
29
|
+
));
|
|
30
|
+
DrawerOverlay.displayName = DrawerPrimitive.Overlay.displayName;
|
|
31
|
+
|
|
32
|
+
const DrawerContent = React.forwardRef<
|
|
33
|
+
React.ElementRef<typeof DrawerPrimitive.Content>,
|
|
34
|
+
React.ComponentPropsWithoutRef<typeof DrawerPrimitive.Content>
|
|
35
|
+
>(({ className, children, ...props }, ref) => (
|
|
36
|
+
<DrawerPortal>
|
|
37
|
+
<DrawerOverlay />
|
|
38
|
+
<DrawerPrimitive.Content
|
|
39
|
+
ref={ref}
|
|
40
|
+
className={cn(
|
|
41
|
+
"fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background",
|
|
42
|
+
className,
|
|
43
|
+
)}
|
|
44
|
+
{...props}
|
|
45
|
+
>
|
|
46
|
+
<div className="mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted" />
|
|
47
|
+
{children}
|
|
48
|
+
</DrawerPrimitive.Content>
|
|
49
|
+
</DrawerPortal>
|
|
50
|
+
));
|
|
51
|
+
DrawerContent.displayName = "DrawerContent";
|
|
52
|
+
|
|
53
|
+
const DrawerHeader = ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) => (
|
|
54
|
+
<div className={cn("grid gap-1.5 p-4 text-center sm:text-left", className)} {...props} />
|
|
55
|
+
);
|
|
56
|
+
DrawerHeader.displayName = "DrawerHeader";
|
|
57
|
+
|
|
58
|
+
const DrawerFooter = ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) => (
|
|
59
|
+
<div className={cn("mt-auto flex flex-col gap-2 p-4", className)} {...props} />
|
|
60
|
+
);
|
|
61
|
+
DrawerFooter.displayName = "DrawerFooter";
|
|
62
|
+
|
|
63
|
+
const DrawerTitle = React.forwardRef<
|
|
64
|
+
React.ElementRef<typeof DrawerPrimitive.Title>,
|
|
65
|
+
React.ComponentPropsWithoutRef<typeof DrawerPrimitive.Title>
|
|
66
|
+
>(({ className, ...props }, ref) => (
|
|
67
|
+
<DrawerPrimitive.Title
|
|
68
|
+
ref={ref}
|
|
69
|
+
className={cn("text-lg font-semibold leading-none tracking-tight", className)}
|
|
70
|
+
{...props}
|
|
71
|
+
/>
|
|
72
|
+
));
|
|
73
|
+
DrawerTitle.displayName = DrawerPrimitive.Title.displayName;
|
|
74
|
+
|
|
75
|
+
const DrawerDescription = React.forwardRef<
|
|
76
|
+
React.ElementRef<typeof DrawerPrimitive.Description>,
|
|
77
|
+
React.ComponentPropsWithoutRef<typeof DrawerPrimitive.Description>
|
|
78
|
+
>(({ className, ...props }, ref) => (
|
|
79
|
+
<DrawerPrimitive.Description
|
|
80
|
+
ref={ref}
|
|
81
|
+
className={cn("text-sm text-muted-foreground", className)}
|
|
82
|
+
{...props}
|
|
83
|
+
/>
|
|
84
|
+
));
|
|
85
|
+
DrawerDescription.displayName = DrawerPrimitive.Description.displayName;
|
|
86
|
+
|
|
87
|
+
export {
|
|
88
|
+
Drawer,
|
|
89
|
+
DrawerPortal,
|
|
90
|
+
DrawerOverlay,
|
|
91
|
+
DrawerTrigger,
|
|
92
|
+
DrawerClose,
|
|
93
|
+
DrawerContent,
|
|
94
|
+
DrawerHeader,
|
|
95
|
+
DrawerFooter,
|
|
96
|
+
DrawerTitle,
|
|
97
|
+
DrawerDescription,
|
|
98
|
+
};
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
|
|
5
|
+
import { Check, ChevronRight, Circle } from "lucide-react";
|
|
6
|
+
|
|
7
|
+
import { cn } from "@/lib/utils";
|
|
8
|
+
|
|
9
|
+
const DropdownMenu = DropdownMenuPrimitive.Root;
|
|
10
|
+
|
|
11
|
+
const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
|
|
12
|
+
|
|
13
|
+
const DropdownMenuGroup = DropdownMenuPrimitive.Group;
|
|
14
|
+
|
|
15
|
+
const DropdownMenuPortal = DropdownMenuPrimitive.Portal;
|
|
16
|
+
|
|
17
|
+
const DropdownMenuSub = DropdownMenuPrimitive.Sub;
|
|
18
|
+
|
|
19
|
+
const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;
|
|
20
|
+
|
|
21
|
+
const DropdownMenuSubTrigger = React.forwardRef<
|
|
22
|
+
React.ElementRef<typeof DropdownMenuPrimitive.SubTrigger>,
|
|
23
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.SubTrigger> & {
|
|
24
|
+
inset?: boolean;
|
|
25
|
+
}
|
|
26
|
+
>(({ className, inset, children, ...props }, ref) => (
|
|
27
|
+
<DropdownMenuPrimitive.SubTrigger
|
|
28
|
+
ref={ref}
|
|
29
|
+
className={cn(
|
|
30
|
+
"flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
|
|
31
|
+
inset && "pl-8",
|
|
32
|
+
className,
|
|
33
|
+
)}
|
|
34
|
+
{...props}
|
|
35
|
+
>
|
|
36
|
+
{children}
|
|
37
|
+
<ChevronRight className="ml-auto" />
|
|
38
|
+
</DropdownMenuPrimitive.SubTrigger>
|
|
39
|
+
));
|
|
40
|
+
DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;
|
|
41
|
+
|
|
42
|
+
const DropdownMenuSubContent = React.forwardRef<
|
|
43
|
+
React.ElementRef<typeof DropdownMenuPrimitive.SubContent>,
|
|
44
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.SubContent>
|
|
45
|
+
>(({ className, ...props }, ref) => (
|
|
46
|
+
<DropdownMenuPrimitive.SubContent
|
|
47
|
+
ref={ref}
|
|
48
|
+
className={cn(
|
|
49
|
+
"z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-(--radix-dropdown-menu-content-transform-origin)",
|
|
50
|
+
className,
|
|
51
|
+
)}
|
|
52
|
+
{...props}
|
|
53
|
+
/>
|
|
54
|
+
));
|
|
55
|
+
DropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;
|
|
56
|
+
|
|
57
|
+
const DropdownMenuContent = React.forwardRef<
|
|
58
|
+
React.ElementRef<typeof DropdownMenuPrimitive.Content>,
|
|
59
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Content>
|
|
60
|
+
>(({ className, sideOffset = 4, ...props }, ref) => (
|
|
61
|
+
<DropdownMenuPrimitive.Portal>
|
|
62
|
+
<DropdownMenuPrimitive.Content
|
|
63
|
+
ref={ref}
|
|
64
|
+
sideOffset={sideOffset}
|
|
65
|
+
className={cn(
|
|
66
|
+
"z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md",
|
|
67
|
+
"data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-(--radix-dropdown-menu-content-transform-origin)",
|
|
68
|
+
className,
|
|
69
|
+
)}
|
|
70
|
+
{...props}
|
|
71
|
+
/>
|
|
72
|
+
</DropdownMenuPrimitive.Portal>
|
|
73
|
+
));
|
|
74
|
+
DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
|
|
75
|
+
|
|
76
|
+
const DropdownMenuItem = React.forwardRef<
|
|
77
|
+
React.ElementRef<typeof DropdownMenuPrimitive.Item>,
|
|
78
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Item> & {
|
|
79
|
+
inset?: boolean;
|
|
80
|
+
}
|
|
81
|
+
>(({ className, inset, ...props }, ref) => (
|
|
82
|
+
<DropdownMenuPrimitive.Item
|
|
83
|
+
ref={ref}
|
|
84
|
+
className={cn(
|
|
85
|
+
"relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",
|
|
86
|
+
inset && "pl-8",
|
|
87
|
+
className,
|
|
88
|
+
)}
|
|
89
|
+
{...props}
|
|
90
|
+
/>
|
|
91
|
+
));
|
|
92
|
+
DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
|
|
93
|
+
|
|
94
|
+
const DropdownMenuCheckboxItem = React.forwardRef<
|
|
95
|
+
React.ElementRef<typeof DropdownMenuPrimitive.CheckboxItem>,
|
|
96
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.CheckboxItem>
|
|
97
|
+
>(({ className, children, checked, ...props }, ref) => (
|
|
98
|
+
<DropdownMenuPrimitive.CheckboxItem
|
|
99
|
+
ref={ref}
|
|
100
|
+
className={cn(
|
|
101
|
+
"relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
102
|
+
className,
|
|
103
|
+
)}
|
|
104
|
+
checked={checked}
|
|
105
|
+
{...props}
|
|
106
|
+
>
|
|
107
|
+
<span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
|
|
108
|
+
<DropdownMenuPrimitive.ItemIndicator>
|
|
109
|
+
<Check className="h-4 w-4" />
|
|
110
|
+
</DropdownMenuPrimitive.ItemIndicator>
|
|
111
|
+
</span>
|
|
112
|
+
{children}
|
|
113
|
+
</DropdownMenuPrimitive.CheckboxItem>
|
|
114
|
+
));
|
|
115
|
+
DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;
|
|
116
|
+
|
|
117
|
+
const DropdownMenuRadioItem = React.forwardRef<
|
|
118
|
+
React.ElementRef<typeof DropdownMenuPrimitive.RadioItem>,
|
|
119
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.RadioItem>
|
|
120
|
+
>(({ className, children, ...props }, ref) => (
|
|
121
|
+
<DropdownMenuPrimitive.RadioItem
|
|
122
|
+
ref={ref}
|
|
123
|
+
className={cn(
|
|
124
|
+
"relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
125
|
+
className,
|
|
126
|
+
)}
|
|
127
|
+
{...props}
|
|
128
|
+
>
|
|
129
|
+
<span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
|
|
130
|
+
<DropdownMenuPrimitive.ItemIndicator>
|
|
131
|
+
<Circle className="h-2 w-2 fill-current" />
|
|
132
|
+
</DropdownMenuPrimitive.ItemIndicator>
|
|
133
|
+
</span>
|
|
134
|
+
{children}
|
|
135
|
+
</DropdownMenuPrimitive.RadioItem>
|
|
136
|
+
));
|
|
137
|
+
DropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;
|
|
138
|
+
|
|
139
|
+
const DropdownMenuLabel = React.forwardRef<
|
|
140
|
+
React.ElementRef<typeof DropdownMenuPrimitive.Label>,
|
|
141
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Label> & {
|
|
142
|
+
inset?: boolean;
|
|
143
|
+
}
|
|
144
|
+
>(({ className, inset, ...props }, ref) => (
|
|
145
|
+
<DropdownMenuPrimitive.Label
|
|
146
|
+
ref={ref}
|
|
147
|
+
className={cn("px-2 py-1.5 text-sm font-semibold", inset && "pl-8", className)}
|
|
148
|
+
{...props}
|
|
149
|
+
/>
|
|
150
|
+
));
|
|
151
|
+
DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
|
|
152
|
+
|
|
153
|
+
const DropdownMenuSeparator = React.forwardRef<
|
|
154
|
+
React.ElementRef<typeof DropdownMenuPrimitive.Separator>,
|
|
155
|
+
React.ComponentPropsWithoutRef<typeof DropdownMenuPrimitive.Separator>
|
|
156
|
+
>(({ className, ...props }, ref) => (
|
|
157
|
+
<DropdownMenuPrimitive.Separator
|
|
158
|
+
ref={ref}
|
|
159
|
+
className={cn("-mx-1 my-1 h-px bg-muted", className)}
|
|
160
|
+
{...props}
|
|
161
|
+
/>
|
|
162
|
+
));
|
|
163
|
+
DropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;
|
|
164
|
+
|
|
165
|
+
const DropdownMenuShortcut = ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => {
|
|
166
|
+
return (
|
|
167
|
+
<span className={cn("ml-auto text-xs tracking-widest opacity-60", className)} {...props} />
|
|
168
|
+
);
|
|
169
|
+
};
|
|
170
|
+
DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
|
|
171
|
+
|
|
172
|
+
export {
|
|
173
|
+
DropdownMenu,
|
|
174
|
+
DropdownMenuTrigger,
|
|
175
|
+
DropdownMenuContent,
|
|
176
|
+
DropdownMenuItem,
|
|
177
|
+
DropdownMenuCheckboxItem,
|
|
178
|
+
DropdownMenuRadioItem,
|
|
179
|
+
DropdownMenuLabel,
|
|
180
|
+
DropdownMenuSeparator,
|
|
181
|
+
DropdownMenuShortcut,
|
|
182
|
+
DropdownMenuGroup,
|
|
183
|
+
DropdownMenuPortal,
|
|
184
|
+
DropdownMenuSub,
|
|
185
|
+
DropdownMenuSubContent,
|
|
186
|
+
DropdownMenuSubTrigger,
|
|
187
|
+
DropdownMenuRadioGroup,
|
|
188
|
+
};
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
3
|
+
import { Slot } from "@radix-ui/react-slot";
|
|
4
|
+
import {
|
|
5
|
+
Controller,
|
|
6
|
+
FormProvider,
|
|
7
|
+
useFormContext,
|
|
8
|
+
type ControllerProps,
|
|
9
|
+
type FieldPath,
|
|
10
|
+
type FieldValues,
|
|
11
|
+
} from "react-hook-form";
|
|
12
|
+
|
|
13
|
+
import { cn } from "@/lib/utils";
|
|
14
|
+
import { Label } from "@/components/ui/label";
|
|
15
|
+
|
|
16
|
+
const Form = FormProvider;
|
|
17
|
+
|
|
18
|
+
type FormFieldContextValue<
|
|
19
|
+
TFieldValues extends FieldValues = FieldValues,
|
|
20
|
+
TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>,
|
|
21
|
+
> = {
|
|
22
|
+
name: TName;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
const FormFieldContext = React.createContext<FormFieldContextValue | null>(null);
|
|
26
|
+
|
|
27
|
+
const FormField = <
|
|
28
|
+
TFieldValues extends FieldValues = FieldValues,
|
|
29
|
+
TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>,
|
|
30
|
+
>({
|
|
31
|
+
...props
|
|
32
|
+
}: ControllerProps<TFieldValues, TName>) => {
|
|
33
|
+
return (
|
|
34
|
+
<FormFieldContext.Provider value={{ name: props.name }}>
|
|
35
|
+
<Controller {...props} />
|
|
36
|
+
</FormFieldContext.Provider>
|
|
37
|
+
);
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
const useFormField = () => {
|
|
41
|
+
const fieldContext = React.useContext(FormFieldContext);
|
|
42
|
+
const itemContext = React.useContext(FormItemContext);
|
|
43
|
+
const { getFieldState, formState } = useFormContext();
|
|
44
|
+
|
|
45
|
+
if (!fieldContext) {
|
|
46
|
+
throw new Error("useFormField should be used within <FormField>");
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
if (!itemContext) {
|
|
50
|
+
throw new Error("useFormField should be used within <FormItem>");
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
const fieldState = getFieldState(fieldContext.name, formState);
|
|
54
|
+
|
|
55
|
+
const { id } = itemContext;
|
|
56
|
+
|
|
57
|
+
return {
|
|
58
|
+
id,
|
|
59
|
+
name: fieldContext.name,
|
|
60
|
+
formItemId: `${id}-form-item`,
|
|
61
|
+
formDescriptionId: `${id}-form-item-description`,
|
|
62
|
+
formMessageId: `${id}-form-item-message`,
|
|
63
|
+
...fieldState,
|
|
64
|
+
};
|
|
65
|
+
};
|
|
66
|
+
|
|
67
|
+
type FormItemContextValue = {
|
|
68
|
+
id: string;
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
const FormItemContext = React.createContext<FormItemContextValue | null>(null);
|
|
72
|
+
|
|
73
|
+
const FormItem = React.forwardRef<HTMLDivElement, React.HTMLAttributes<HTMLDivElement>>(
|
|
74
|
+
({ className, ...props }, ref) => {
|
|
75
|
+
const id = React.useId();
|
|
76
|
+
|
|
77
|
+
return (
|
|
78
|
+
<FormItemContext.Provider value={{ id }}>
|
|
79
|
+
<div ref={ref} className={cn("space-y-2", className)} {...props} />
|
|
80
|
+
</FormItemContext.Provider>
|
|
81
|
+
);
|
|
82
|
+
},
|
|
83
|
+
);
|
|
84
|
+
FormItem.displayName = "FormItem";
|
|
85
|
+
|
|
86
|
+
const FormLabel = React.forwardRef<
|
|
87
|
+
React.ElementRef<typeof LabelPrimitive.Root>,
|
|
88
|
+
React.ComponentPropsWithoutRef<typeof LabelPrimitive.Root>
|
|
89
|
+
>(({ className, ...props }, ref) => {
|
|
90
|
+
const { error, formItemId } = useFormField();
|
|
91
|
+
|
|
92
|
+
return (
|
|
93
|
+
<Label
|
|
94
|
+
ref={ref}
|
|
95
|
+
className={cn(error && "text-destructive", className)}
|
|
96
|
+
htmlFor={formItemId}
|
|
97
|
+
{...props}
|
|
98
|
+
/>
|
|
99
|
+
);
|
|
100
|
+
});
|
|
101
|
+
FormLabel.displayName = "FormLabel";
|
|
102
|
+
|
|
103
|
+
const FormControl = React.forwardRef<
|
|
104
|
+
React.ElementRef<typeof Slot>,
|
|
105
|
+
React.ComponentPropsWithoutRef<typeof Slot>
|
|
106
|
+
>(({ ...props }, ref) => {
|
|
107
|
+
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
108
|
+
|
|
109
|
+
return (
|
|
110
|
+
<Slot
|
|
111
|
+
ref={ref}
|
|
112
|
+
id={formItemId}
|
|
113
|
+
aria-describedby={!error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`}
|
|
114
|
+
aria-invalid={!!error}
|
|
115
|
+
{...props}
|
|
116
|
+
/>
|
|
117
|
+
);
|
|
118
|
+
});
|
|
119
|
+
FormControl.displayName = "FormControl";
|
|
120
|
+
|
|
121
|
+
const FormDescription = React.forwardRef<
|
|
122
|
+
HTMLParagraphElement,
|
|
123
|
+
React.HTMLAttributes<HTMLParagraphElement>
|
|
124
|
+
>(({ className, ...props }, ref) => {
|
|
125
|
+
const { formDescriptionId } = useFormField();
|
|
126
|
+
|
|
127
|
+
return (
|
|
128
|
+
<p
|
|
129
|
+
ref={ref}
|
|
130
|
+
id={formDescriptionId}
|
|
131
|
+
className={cn("text-[0.8rem] text-muted-foreground", className)}
|
|
132
|
+
{...props}
|
|
133
|
+
/>
|
|
134
|
+
);
|
|
135
|
+
});
|
|
136
|
+
FormDescription.displayName = "FormDescription";
|
|
137
|
+
|
|
138
|
+
const FormMessage = React.forwardRef<
|
|
139
|
+
HTMLParagraphElement,
|
|
140
|
+
React.HTMLAttributes<HTMLParagraphElement>
|
|
141
|
+
>(({ className, children, ...props }, ref) => {
|
|
142
|
+
const { error, formMessageId } = useFormField();
|
|
143
|
+
const body = error ? String(error?.message ?? "") : children;
|
|
144
|
+
|
|
145
|
+
if (!body) {
|
|
146
|
+
return null;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
return (
|
|
150
|
+
<p
|
|
151
|
+
ref={ref}
|
|
152
|
+
id={formMessageId}
|
|
153
|
+
className={cn("text-[0.8rem] font-medium text-destructive", className)}
|
|
154
|
+
{...props}
|
|
155
|
+
>
|
|
156
|
+
{body}
|
|
157
|
+
</p>
|
|
158
|
+
);
|
|
159
|
+
});
|
|
160
|
+
FormMessage.displayName = "FormMessage";
|
|
161
|
+
|
|
162
|
+
export {
|
|
163
|
+
useFormField,
|
|
164
|
+
Form,
|
|
165
|
+
FormItem,
|
|
166
|
+
FormLabel,
|
|
167
|
+
FormControl,
|
|
168
|
+
FormDescription,
|
|
169
|
+
FormMessage,
|
|
170
|
+
FormField,
|
|
171
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
|
|
3
|
+
|
|
4
|
+
import { cn } from "@/lib/utils";
|
|
5
|
+
|
|
6
|
+
const HoverCard = HoverCardPrimitive.Root;
|
|
7
|
+
|
|
8
|
+
const HoverCardTrigger = HoverCardPrimitive.Trigger;
|
|
9
|
+
|
|
10
|
+
const HoverCardContent = React.forwardRef<
|
|
11
|
+
React.ElementRef<typeof HoverCardPrimitive.Content>,
|
|
12
|
+
React.ComponentPropsWithoutRef<typeof HoverCardPrimitive.Content>
|
|
13
|
+
>(({ className, align = "center", sideOffset = 4, ...props }, ref) => (
|
|
14
|
+
<HoverCardPrimitive.Content
|
|
15
|
+
ref={ref}
|
|
16
|
+
align={align}
|
|
17
|
+
sideOffset={sideOffset}
|
|
18
|
+
className={cn(
|
|
19
|
+
"z-50 w-64 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-(--radix-hover-card-content-transform-origin)",
|
|
20
|
+
className,
|
|
21
|
+
)}
|
|
22
|
+
{...props}
|
|
23
|
+
/>
|
|
24
|
+
));
|
|
25
|
+
HoverCardContent.displayName = HoverCardPrimitive.Content.displayName;
|
|
26
|
+
|
|
27
|
+
export { HoverCard, HoverCardTrigger, HoverCardContent };
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { OTPInput, OTPInputContext } from "input-otp";
|
|
3
|
+
import { Minus } from "lucide-react";
|
|
4
|
+
|
|
5
|
+
import { cn } from "@/lib/utils";
|
|
6
|
+
|
|
7
|
+
const InputOTP = React.forwardRef<
|
|
8
|
+
React.ElementRef<typeof OTPInput>,
|
|
9
|
+
React.ComponentPropsWithoutRef<typeof OTPInput>
|
|
10
|
+
>(({ className, containerClassName, ...props }, ref) => (
|
|
11
|
+
<OTPInput
|
|
12
|
+
ref={ref}
|
|
13
|
+
containerClassName={cn(
|
|
14
|
+
"flex items-center gap-2 has-[:disabled]:opacity-50",
|
|
15
|
+
containerClassName,
|
|
16
|
+
)}
|
|
17
|
+
className={cn("disabled:cursor-not-allowed", className)}
|
|
18
|
+
{...props}
|
|
19
|
+
/>
|
|
20
|
+
));
|
|
21
|
+
InputOTP.displayName = "InputOTP";
|
|
22
|
+
|
|
23
|
+
const InputOTPGroup = React.forwardRef<
|
|
24
|
+
React.ElementRef<"div">,
|
|
25
|
+
React.ComponentPropsWithoutRef<"div">
|
|
26
|
+
>(({ className, ...props }, ref) => (
|
|
27
|
+
<div ref={ref} className={cn("flex items-center", className)} {...props} />
|
|
28
|
+
));
|
|
29
|
+
InputOTPGroup.displayName = "InputOTPGroup";
|
|
30
|
+
|
|
31
|
+
const InputOTPSlot = React.forwardRef<
|
|
32
|
+
React.ElementRef<"div">,
|
|
33
|
+
React.ComponentPropsWithoutRef<"div"> & { index: number }
|
|
34
|
+
>(({ index, className, ...props }, ref) => {
|
|
35
|
+
const inputOTPContext = React.useContext(OTPInputContext);
|
|
36
|
+
const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
|
|
37
|
+
|
|
38
|
+
return (
|
|
39
|
+
<div
|
|
40
|
+
ref={ref}
|
|
41
|
+
className={cn(
|
|
42
|
+
"relative flex h-9 w-9 items-center justify-center border-y border-r border-input text-sm shadow-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md",
|
|
43
|
+
isActive && "z-10 ring-1 ring-ring",
|
|
44
|
+
className,
|
|
45
|
+
)}
|
|
46
|
+
{...props}
|
|
47
|
+
>
|
|
48
|
+
{char}
|
|
49
|
+
{hasFakeCaret && (
|
|
50
|
+
<div className="pointer-events-none absolute inset-0 flex items-center justify-center">
|
|
51
|
+
<div className="h-4 w-px animate-caret-blink bg-foreground duration-1000" />
|
|
52
|
+
</div>
|
|
53
|
+
)}
|
|
54
|
+
</div>
|
|
55
|
+
);
|
|
56
|
+
});
|
|
57
|
+
InputOTPSlot.displayName = "InputOTPSlot";
|
|
58
|
+
|
|
59
|
+
const InputOTPSeparator = React.forwardRef<
|
|
60
|
+
React.ElementRef<"div">,
|
|
61
|
+
React.ComponentPropsWithoutRef<"div">
|
|
62
|
+
>(({ ...props }, ref) => (
|
|
63
|
+
<div ref={ref} role="separator" {...props}>
|
|
64
|
+
<Minus />
|
|
65
|
+
</div>
|
|
66
|
+
));
|
|
67
|
+
InputOTPSeparator.displayName = "InputOTPSeparator";
|
|
68
|
+
|
|
69
|
+
export { InputOTP, InputOTPGroup, InputOTPSlot, InputOTPSeparator };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
|
|
3
|
+
import { cn } from "@/lib/utils";
|
|
4
|
+
|
|
5
|
+
const Input = React.forwardRef<HTMLInputElement, React.ComponentProps<"input">>(
|
|
6
|
+
({ className, type, ...props }, ref) => {
|
|
7
|
+
return (
|
|
8
|
+
<input
|
|
9
|
+
type={type}
|
|
10
|
+
className={cn(
|
|
11
|
+
"flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
12
|
+
className,
|
|
13
|
+
)}
|
|
14
|
+
ref={ref}
|
|
15
|
+
{...props}
|
|
16
|
+
/>
|
|
17
|
+
);
|
|
18
|
+
},
|
|
19
|
+
);
|
|
20
|
+
Input.displayName = "Input";
|
|
21
|
+
|
|
22
|
+
export { Input };
|