### Install React QrCode with shadcn (npm, yarn, pnpm, bun, deno) Source: https://moduix.dev/docs/qr-code Install the React QrCode component with shadcn. Use the command for your package manager. See Quick Start for full package setup, registry configuration, and styling guidance. ```bash npx shadcn@latest add @moduix-react/qr-code ``` ```bash yarn dlx shadcn@latest add @moduix-react/qr-code ``` ```bash pnpm dlx shadcn@latest add @moduix-react/qr-code ``` ```bash bunx shadcn@latest add @moduix-react/qr-code ``` ```bash deno run -A npm:shadcn@latest add @moduix-react/qr-code ``` -------------------------------- ### Download QR Code Example (Solid) Source: https://moduix.dev/docs/qr-code Solid example showing how to add a download trigger with fileName and mimeType to save the QR code as a PNG image. ```jsx import { QrCode } from '@moduix/solid/qr-code'; export default function DownloadQrCodeDemo() { return ( Download QR code (PNG) ); } ``` -------------------------------- ### Install @moduix-solid-tailwind/alert with shadcn (Tailwind CSS) Source: https://moduix.dev/docs/alert Install the Solid alert component with shadcn using Tailwind CSS. See Quick Start for full package setup and registry configuration. ```bash npx shadcn@latest add @moduix-solid-tailwind/alert ``` ```bash yarn dlx shadcn@latest add @moduix-solid-tailwind/alert ``` ```bash pnpm dlx shadcn@latest add @moduix-solid-tailwind/alert ``` ```bash bunx shadcn@latest add @moduix-solid-tailwind/alert ``` ```bash deno run -A npm:shadcn@latest add @moduix-solid-tailwind/alert ``` -------------------------------- ### Install @moduix-react-tailwind/alert with shadcn (Tailwind CSS) Source: https://moduix.dev/docs/alert Install the React alert component with shadcn using Tailwind CSS. See Quick Start for full package setup and registry configuration. ```bash npx shadcn@latest add @moduix-react-tailwind/alert ``` ```bash yarn dlx shadcn@latest add @moduix-react-tailwind/alert ``` ```bash pnpm dlx shadcn@latest add @moduix-react-tailwind/alert ``` ```bash bunx shadcn@latest add @moduix-react-tailwind/alert ``` ```bash deno run -A npm:shadcn@latest add @moduix-react-tailwind/alert ``` -------------------------------- ### Install Solid Pagination with deno Source: https://moduix.dev/docs/pagination?page=1 Install the Solid Pagination component using deno. ```bash deno run -A npm:shadcn@latest add @moduix-solid/pagination ``` -------------------------------- ### Basic EnvironmentProvider setup for React and Solid Source: https://moduix.dev/docs/environment Basic setup wrapping a subtree with EnvironmentProvider and using useEnvironmentContext to resolve the root node, document, and window. In Solid, useEnvironmentContext() returns an accessor, so call it before reading getRootNode, getDocument, or getWindow. ```tsx import { EnvironmentProvider, useEnvironmentContext } from '@ark-ui/react/environment'; import { Card } from '@moduix/react/card'; import { Stack } from '@moduix/react/stack'; import { useEffect, useState } from 'react'; interface EnvironmentDetails { documentName: string; rootNode: string; windowHost: string; } function EnvironmentSummary() { const { getDocument, getRootNode, getWindow } = useEnvironmentContext(); const [details, setDetails] = useState({ documentName: 'Detecting…', rootNode: 'Detecting…', windowHost: 'Detecting…', }); useEffect(() => { const rootNode = getRootNode(); const rootName = rootNode.nodeType === Node.DOCUMENT_NODE ? 'Document' : rootNode.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? 'Shadow root' : rootNode.nodeName; setDetails({ rootNode: rootName, documentName: getDocument().title || 'Untitled document', windowHost: getWindow().location.hostname || 'Local preview', }); }, [getDocument, getRootNode, getWindow]); return ( Resolved environment Ark queries DOM APIs from this environment. Root node: {details.rootNode} Document: {details.documentName} Window: {details.windowHost} ); } export default function EnvironmentBasicDemo() { return ( ); } ``` ```tsx import { EnvironmentProvider, useEnvironmentContext } from '@ark-ui/solid/environment'; import { Card } from '@moduix/solid/card'; import { Stack } from '@moduix/solid/stack'; import { createEffect, createSignal } from 'solid-js'; interface EnvironmentDetails { documentName: string; rootNode: string; windowHost: string; } function EnvironmentSummary() { const environment = useEnvironmentContext(); const [details, setDetails] = createSignal({ documentName: 'Detecting…', rootNode: 'Detecting…', windowHost: 'Detecting…', }); createEffect(() => { const { getDocument, getRootNode, getWindow } = environment(); const rootNode = getRootNode(); const rootName = rootNode.nodeType === Node.DOCUMENT_NODE ? 'Document' : rootNode.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? 'Shadow root' : rootNode.nodeName; setDetails({ rootNode: rootName, documentName: getDocument().title || 'Untitled document', windowHost: getWindow().location.hostname || 'Local preview', }); }); return ( Resolved environment Ark queries DOM APIs from this environment. Root node: {details().rootNode} Document: {details().documentName} Window: {details().windowHost} ); } export default function EnvironmentBasicDemo() { return ( ); } ``` -------------------------------- ### Install @moduix-solid/alert with shadcn Source: https://moduix.dev/docs/alert Install the Solid alert component with shadcn using npm, yarn, pnpm, bun, or deno. See Quick Start for full package setup and registry configuration. ```bash npx shadcn@latest add @moduix-solid/alert ``` ```bash yarn dlx shadcn@latest add @moduix-solid/alert ``` ```bash pnpm dlx shadcn@latest add @moduix-solid/alert ``` ```bash bunx shadcn@latest add @moduix-solid/alert ``` ```bash deno run -A npm:shadcn@latest add @moduix-solid/alert ``` -------------------------------- ### Install @moduix-react/alert with shadcn Source: https://moduix.dev/docs/alert Install the React alert component with shadcn using npm, yarn, pnpm, bun, or deno. See Quick Start for full package setup and registry configuration. ```bash npx shadcn@latest add @moduix-react/alert ``` ```bash yarn dlx shadcn@latest add @moduix-react/alert ``` ```bash pnpm dlx shadcn@latest add @moduix-react/alert ``` ```bash bunx shadcn@latest add @moduix-react/alert ``` ```bash deno run -A npm:shadcn@latest add @moduix-react/alert ``` -------------------------------- ### Install Solid Pagination with bun Source: https://moduix.dev/docs/pagination?page=1 Install the Solid Pagination component using bun. ```bash bunx shadcn@latest add @moduix-solid/pagination ``` -------------------------------- ### Solid RootProvider Implementation Source: https://moduix.dev/docs/steps Demonstrates the SolidJS implementation of a multi-step workflow using Steps.RootProvider. ```tsx import { Steps } from '@moduix/solid/steps'; import styles from '@/components/examples/steps/steps-root-provider.module.css'; const items = [ { title: 'Account', description: 'Create the workspace owner account.', }, { title: 'Profile', description: 'Set team details and locale.', }, { title: 'Billing', description: 'Choose the plan and payment method.', }, ]; export default function RootProviderStepsDemo() { const steps = Steps.useSteps({ count: items.length }); return ( <> {items.map((item, index) => ( {item.title} {item.description} ))} {items.map((item, index) => ( {item.title} - {item.description} ))} Steps complete. The workspace is ready.
Back Next
Current step: {steps().value + 1} ); } ``` -------------------------------- ### Install @tanstack/solid-form with deno Source: https://moduix.dev/docs/tanstack-form Install the Solid adapter for TanStack Form using deno. ```bash deno add npm:@tanstack/solid-form ``` -------------------------------- ### Install @moduix/solid and @ark-ui/solid (CSS Modules) Source: https://moduix.dev/docs/quick-start Install the CSS Modules setup for Solid. Use one of these commands. The install adds the moduix package and the Ark UI runtime package. ```shell npm install @moduix/solid @ark-ui/solid ``` ```shell yarn add @moduix/solid @ark-ui/solid ``` ```shell pnpm add @moduix/solid @ark-ui/solid ``` ```shell bun add @moduix/solid @ark-ui/solid ``` ```shell deno add npm:@moduix/solid npm:@ark-ui/solid ``` -------------------------------- ### Install @moduix-solid/segment-group with shadcn Source: https://moduix.dev/docs/segment-group Install the Solid segment-group component with shadcn using your preferred package manager. The same package is used for both the default and CSS Modules setups. ```bash npx shadcn@latest add @moduix-solid/segment-group ``` ```bash yarn dlx shadcn@latest add @moduix-solid/segment-group ``` ```bash pnpm dlx shadcn@latest add @moduix-solid/segment-group ``` ```bash bunx shadcn@latest add @moduix-solid/segment-group ``` ```bash deno run -A npm:shadcn@latest add @moduix-solid/segment-group ``` -------------------------------- ### Install Solid Pagination with npm Source: https://moduix.dev/docs/pagination?page=1 Install the Solid Pagination component using npm. ```bash npx shadcn@latest add @moduix-solid/pagination ``` -------------------------------- ### Install @moduix-react/segment-group with shadcn Source: https://moduix.dev/docs/segment-group Install the React segment-group component with shadcn using your preferred package manager. The same package is used for both the default and CSS Modules setups. ```bash npx shadcn@latest add @moduix-react/segment-group ``` ```bash yarn dlx shadcn@latest add @moduix-react/segment-group ``` ```bash pnpm dlx shadcn@latest add @moduix-react/segment-group ``` ```bash bunx shadcn@latest add @moduix-react/segment-group ``` ```bash deno run -A npm:shadcn@latest add @moduix-react/segment-group ``` -------------------------------- ### Install Solid QrCode with shadcn (npm, yarn, pnpm, bun, deno) Source: https://moduix.dev/docs/qr-code Install the Solid QrCode component with shadcn. Use the command for your package manager. ```bash npx shadcn@latest add @moduix-solid/qr-code ``` ```bash yarn dlx shadcn@latest add @moduix-solid/qr-code ``` ```bash pnpm dlx shadcn@latest add @moduix-solid/qr-code ``` ```bash bunx shadcn@latest add @moduix-solid/qr-code ``` ```bash deno run -A npm:shadcn@latest add @moduix-solid/qr-code ``` -------------------------------- ### Solid: RootProvider with useFileUpload and paste handling Source: https://moduix.dev/docs/file-upload Solid version of the same example. Uses `useFileUpload` with `RootProvider` and `setClipboardFiles` to handle pasted files. Requires `@moduix/solid/file-upload` and `@moduix/solid/textarea`. ```tsx import { FileUpload, useFileUpload } from '@moduix/solid/file-upload'; import { Textarea } from '@moduix/solid/textarea'; import { For } from 'solid-js'; import styles from '@/components/examples/file-upload/file-upload-root-provider-and-paste.module.css'; const maxFiles = 3; const accept = 'image/*'; export default function RootProviderPasteUploadDemo() { const fileUpload = useFileUpload({ maxFiles, accept, }); return ( Images