├── .changeset ├── README.md ├── better-goats-swim.md ├── big-women-follow.md ├── bitter-rice-do.md ├── blue-crews-deny.md ├── brown-roses-knock.md ├── bumpy-clocks-feel.md ├── bumpy-parts-scream.md ├── bumpy-windows-mix.md ├── clean-tips-judge.md ├── clear-coats-jam.md ├── clever-crews-retire.md ├── clever-eagles-turn.md ├── cold-apples-speak.md ├── cold-grapes-eat.md ├── common-rabbits-open.md ├── config.json ├── cool-eels-argue.md ├── cruel-wolves-throw.md ├── curvy-buttons-float.md ├── curvy-frogs-grin.md ├── cute-apples-marry.md ├── dark-lines-show.md ├── dirty-nails-push.md ├── dull-balloons-rush.md ├── eager-clouds-cry.md ├── early-wings-tell.md ├── eighty-crabs-allow.md ├── eleven-cloths-cut.md ├── empty-bears-attend.md ├── empty-birds-learn.md ├── empty-cooks-brush.md ├── empty-hats-crash.md ├── every-dots-ring.md ├── every-ducks-press.md ├── fancy-cobras-switch.md ├── fine-days-follow.md ├── fine-glasses-raise.md ├── five-tools-joke.md ├── fluffy-dots-hunt.md ├── free-adults-talk.md ├── fresh-pans-tell.md ├── fruity-trees-tap.md ├── giant-days-allow.md ├── giant-impalas-fold.md ├── good-lies-notice.md ├── green-hands-carry.md ├── green-items-cheat.md ├── huge-planes-learn.md ├── hungry-breads-rescue.md ├── icy-trains-exist.md ├── lazy-rocks-run.md ├── legal-keys-fly.md ├── little-monkeys-hammer.md ├── little-otters-carry.md ├── loud-monkeys-jog.md ├── loud-parrots-enjoy.md ├── many-badgers-move.md ├── mean-carpets-poke.md ├── moody-doors-dance.md ├── nasty-comics-pay.md ├── neat-carrots-eat.md ├── nine-olives-say.md ├── nine-pianos-tie.md ├── odd-memes-enjoy.md ├── olive-books-burn.md ├── open-clouds-change.md ├── plenty-streets-sing.md ├── pre.json ├── proud-squids-sniff.md ├── proud-trams-stare.md ├── quick-candies-rescue.md ├── quick-cycles-sniff.md ├── rare-buckets-begin.md ├── rare-meals-bathe.md ├── ready-flowers-carry.md ├── ready-windows-shop.md ├── red-coats-slide.md ├── red-dogs-retire.md ├── red-pillows-roll.md ├── rude-news-learn.md ├── seven-poets-enjoy.md ├── shiny-plums-develop.md ├── six-mails-scream.md ├── slow-berries-beam.md ├── small-jobs-look.md ├── smooth-donkeys-play.md ├── social-cameras-stand.md ├── soft-pigs-doubt.md ├── some-mails-sneeze.md ├── some-sloths-speak.md ├── spicy-donkeys-make.md ├── spicy-peaches-call.md ├── spicy-planets-slide.md ├── spotty-webs-wear.md ├── swift-apples-chew.md ├── swift-areas-enjoy.md ├── tall-phones-slide.md ├── tame-guests-push.md ├── tame-taxis-itch.md ├── tangy-kings-work.md ├── thick-carrots-type.md ├── thick-friends-retire.md ├── tidy-deer-heal.md ├── tiny-forks-dance.md ├── tough-bears-lose.md ├── tough-paths-feel.md ├── tough-ravens-raise.md ├── tricky-ideas-send.md ├── twelve-cats-train.md ├── twenty-jeans-deny.md ├── two-wings-double.md ├── upset-snails-smile.md ├── violet-ants-win.md ├── violet-taxes-brake.md ├── warm-swans-wait.md ├── weak-ants-dig.md ├── weak-suits-clap.md ├── weak-things-jump.md ├── whole-buckets-camp.md ├── whole-snakes-allow.md ├── wicked-hoops-win.md ├── wide-planes-hope.md ├── wild-pets-raise.md └── wise-dodos-ring.md ├── .envrc ├── .github └── workflows │ ├── deploy-pages.yaml │ └── version-and-publish.yaml ├── .gitignore ├── .vscode └── launch.json ├── LICENSE ├── README.md ├── apps ├── docs2 │ ├── .gitignore │ ├── .vscode │ │ ├── extensions.json │ │ └── launch.json │ ├── CHANGELOG.md │ ├── README.md │ ├── astro.config.mjs │ ├── package.json │ ├── public │ │ └── favicon.svg │ ├── src │ │ ├── assets │ │ │ └── houston.webp │ │ ├── astro.svelte.ts │ │ ├── components │ │ │ ├── custom-head.astro │ │ │ ├── declarative-shadow-dom.astro │ │ │ ├── form-card.astro │ │ │ ├── form-defaults.ts │ │ │ ├── header-with-links.astro │ │ │ ├── markdown-content.astro │ │ │ ├── my-form.svelte │ │ │ ├── my-form.ts │ │ │ ├── npm.astro │ │ │ ├── picker.astro │ │ │ └── shadow │ │ │ │ ├── host.svelte │ │ │ │ ├── index.ts │ │ │ │ └── root.svelte │ │ ├── content │ │ │ ├── config.ts │ │ │ └── docs │ │ │ │ ├── _on-submit.ts │ │ │ │ ├── _schema.ts │ │ │ │ ├── _theme-form.svelte │ │ │ │ ├── _themes.astro │ │ │ │ ├── _validator.ts │ │ │ │ ├── _with-basic.svelte │ │ │ │ ├── _with-daisyui5.svelte │ │ │ │ ├── _with-flowbite3.svelte │ │ │ │ ├── _with-shadcn4.svelte │ │ │ │ ├── _with-skeleton3.svelte │ │ │ │ ├── changelogs │ │ │ │ ├── ajv8-validator.mdx │ │ │ │ ├── basic-theme.mdx │ │ │ │ ├── cfworker-validator.mdx │ │ │ │ ├── daisyui5-theme.mdx │ │ │ │ ├── docs.mdx │ │ │ │ ├── flowbite-icons.mdx │ │ │ │ ├── flowbite3-theme.mdx │ │ │ │ ├── form.mdx │ │ │ │ ├── lucide-icons.mdx │ │ │ │ ├── moving-icons.mdx │ │ │ │ ├── playground.mdx │ │ │ │ ├── radix-icons.mdx │ │ │ │ ├── shadcn4-theme.mdx │ │ │ │ ├── skeleton3-theme.mdx │ │ │ │ ├── sveltekit.mdx │ │ │ │ └── zod-validator.mdx │ │ │ │ ├── examples │ │ │ │ ├── advanced-examples.svelte │ │ │ │ ├── buttons.svelte │ │ │ │ ├── index.mdx │ │ │ │ └── playground.svelte │ │ │ │ ├── form │ │ │ │ ├── _extra-ui-options.ts │ │ │ │ ├── _form-state.svelte │ │ │ │ ├── _ui-schema-example.ts │ │ │ │ ├── components.mdx │ │ │ │ ├── fields-validation-mode.mdx │ │ │ │ ├── merger.mdx │ │ │ │ ├── options.mdx │ │ │ │ ├── schema.mdx │ │ │ │ ├── state.mdx │ │ │ │ ├── theme.mdx │ │ │ │ ├── translation.mdx │ │ │ │ ├── ui-schema.mdx │ │ │ │ └── validator.mdx │ │ │ │ ├── guides │ │ │ │ ├── _async-validation.svelte │ │ │ │ ├── _demo-schemas.ts │ │ │ │ ├── _errors-list.svelte │ │ │ │ ├── _fields-validation.svelte │ │ │ │ ├── _flowbite-icons-install.md │ │ │ │ ├── _focus-on-first-error.svelte │ │ │ │ ├── _form-state.svelte │ │ │ │ ├── _form-value-type-inference.ts │ │ │ │ ├── _icons-demo.svelte │ │ │ │ ├── _icons.astro │ │ │ │ ├── _icons.svelte │ │ │ │ ├── _live-validation.svelte │ │ │ │ ├── _multiple-forms.svelte │ │ │ │ ├── _prevent-page-reload.svelte │ │ │ │ ├── _programmatic-control.svelte │ │ │ │ ├── _simple-setup.svelte │ │ │ │ ├── _ui-schema.svelte │ │ │ │ ├── custom-components.mdx │ │ │ │ ├── fields-resolution.mdx │ │ │ │ ├── form-value-type-inference.mdx │ │ │ │ ├── labels-and-icons.mdx │ │ │ │ ├── multiple-forms.mdx │ │ │ │ ├── prevent-page-reload.mdx │ │ │ │ ├── programmatic-control.mdx │ │ │ │ ├── quickstart.mdx │ │ │ │ ├── reusable-defaults.mdx │ │ │ │ ├── state-transformation.mdx │ │ │ │ └── validation.mdx │ │ │ │ ├── index.mdx │ │ │ │ ├── integrations │ │ │ │ ├── _generic-backend.svelte │ │ │ │ ├── _sveltekit-client.svelte.api │ │ │ │ ├── _sveltekit-flex-client.svelte.api │ │ │ │ ├── _sveltekit-server.ts.api │ │ │ │ ├── generic-backend.mdx │ │ │ │ └── sveltekit.mdx │ │ │ │ ├── misc │ │ │ │ ├── contributing.mdx │ │ │ │ └── migration-from-v1.mdx │ │ │ │ ├── themes │ │ │ │ ├── _demo-schema.ts │ │ │ │ ├── basic.mdx │ │ │ │ ├── basic │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── daisyui.mdx │ │ │ │ ├── daisyui │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── daisyui5.mdx │ │ │ │ ├── daisyui5 │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── flowbite.mdx │ │ │ │ ├── flowbite │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── flowbite3.mdx │ │ │ │ ├── flowbite3 │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── shadcn.mdx │ │ │ │ ├── shadcn │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── shadcn4.mdx │ │ │ │ ├── shadcn4 │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── skeleton.mdx │ │ │ │ ├── skeleton │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ ├── skeleton3.mdx │ │ │ │ └── skeleton3 │ │ │ │ │ ├── form.svelte │ │ │ │ │ └── ui-options.ts │ │ │ │ └── validators │ │ │ │ ├── ajv.mdx │ │ │ │ ├── ajv │ │ │ │ ├── form.svelte │ │ │ │ └── precompile │ │ │ │ │ ├── compile-schema-script.ts │ │ │ │ │ ├── form.svelte │ │ │ │ │ ├── input-schema.json │ │ │ │ │ ├── patched-schema.ts │ │ │ │ │ └── validate-functions.js │ │ │ │ ├── cfworker.mdx │ │ │ │ ├── cfworker │ │ │ │ └── form.svelte │ │ │ │ ├── schemasafe.mdx │ │ │ │ ├── schemasafe │ │ │ │ ├── form.svelte │ │ │ │ └── precompile │ │ │ │ │ ├── compile-schema-script.ts │ │ │ │ │ ├── form.svelte │ │ │ │ │ ├── input-schema.json │ │ │ │ │ ├── patched-schema.ts │ │ │ │ │ └── validate-functions.js │ │ │ │ ├── shared │ │ │ │ └── index.ts │ │ │ │ ├── standard-schema.mdx │ │ │ │ ├── standard-schema │ │ │ │ └── form.svelte │ │ │ │ ├── zod.mdx │ │ │ │ └── zod │ │ │ │ └── form.svelte │ │ ├── env.d.ts │ │ ├── i18n.ts │ │ ├── pages │ │ │ └── with-[theme].astro │ │ ├── shared.ts │ │ ├── styles.css │ │ └── web-ide │ │ │ ├── examples │ │ │ ├── animated-array.ts │ │ │ ├── async-combobox.ts │ │ │ ├── formulas.ts │ │ │ ├── markdown-description.ts │ │ │ ├── pattern-properties-validator.ts │ │ │ ├── starter.ts │ │ │ └── tabbed-layout.ts │ │ │ ├── index.ts │ │ │ ├── layer.ts │ │ │ └── layers │ │ │ ├── basic.ts │ │ │ ├── daisyui5.ts │ │ │ ├── flowbite3.ts │ │ │ ├── shadcn4.ts │ │ │ ├── skeleton3.ts │ │ │ ├── sveltekit.ts │ │ │ └── tailwind4.ts │ ├── svelte.config.js │ └── tsconfig.json └── playground2 │ ├── CHANGELOG.md │ ├── components.json │ ├── index.html │ ├── package.json │ ├── public │ └── vite.svg │ ├── src │ ├── app.css │ ├── app.svelte │ ├── bits.svelte │ ├── copy-to-clipboard.ts │ ├── core │ │ ├── icons.ts │ │ ├── index.ts │ │ ├── resolvers.ts │ │ ├── sample.ts │ │ ├── themes.ts │ │ └── validators.ts │ ├── custom-form-components │ │ ├── custom-layout.svelte │ │ ├── index.ts │ │ ├── markdown-description.svelte │ │ └── transparent-layout.svelte │ ├── debug.svelte │ ├── editor.svelte │ ├── github.svelte │ ├── lib │ │ ├── components │ │ │ └── ui │ │ │ │ ├── button │ │ │ │ ├── button.svelte │ │ │ │ └── index.ts │ │ │ │ ├── checkbox │ │ │ │ ├── checkbox.svelte │ │ │ │ └── index.ts │ │ │ │ ├── command │ │ │ │ ├── command-dialog.svelte │ │ │ │ ├── command-empty.svelte │ │ │ │ ├── command-group.svelte │ │ │ │ ├── command-input.svelte │ │ │ │ ├── command-item.svelte │ │ │ │ ├── command-link-item.svelte │ │ │ │ ├── command-list.svelte │ │ │ │ ├── command-separator.svelte │ │ │ │ ├── command-shortcut.svelte │ │ │ │ ├── command.svelte │ │ │ │ └── index.ts │ │ │ │ ├── dialog │ │ │ │ ├── dialog-close.svelte │ │ │ │ ├── dialog-content.svelte │ │ │ │ ├── dialog-description.svelte │ │ │ │ ├── dialog-footer.svelte │ │ │ │ ├── dialog-header.svelte │ │ │ │ ├── dialog-overlay.svelte │ │ │ │ ├── dialog-title.svelte │ │ │ │ ├── dialog-trigger.svelte │ │ │ │ └── index.ts │ │ │ │ ├── label │ │ │ │ ├── index.ts │ │ │ │ └── label.svelte │ │ │ │ ├── popover │ │ │ │ ├── index.ts │ │ │ │ ├── popover-content.svelte │ │ │ │ └── popover-trigger.svelte │ │ │ │ ├── select │ │ │ │ ├── index.ts │ │ │ │ ├── select-content.svelte │ │ │ │ ├── select-group.svelte │ │ │ │ ├── select-item.svelte │ │ │ │ ├── select-label.svelte │ │ │ │ ├── select-scroll-down-button.svelte │ │ │ │ ├── select-scroll-up-button.svelte │ │ │ │ ├── select-separator.svelte │ │ │ │ └── select-trigger.svelte │ │ │ │ └── separator │ │ │ │ ├── index.ts │ │ │ │ └── separator.svelte │ │ └── utils.ts │ ├── main.ts │ ├── open-book.svelte │ ├── popup.svelte │ ├── sample-picker.svelte │ ├── samples │ │ ├── additional-properties.ts │ │ ├── all-of.ts │ │ ├── alternatives.ts │ │ ├── any-of.ts │ │ ├── arrays.ts │ │ ├── date.ts │ │ ├── defaults.ts │ │ ├── enum-objects.ts │ │ ├── errors.ts │ │ ├── examples.ts │ │ ├── files.ts │ │ ├── grid.ts │ │ ├── if-then-else.ts │ │ ├── large.ts │ │ ├── layout-grid.ts │ │ ├── nested.ts │ │ ├── null.ts │ │ ├── nullable.ts │ │ ├── numbers.ts │ │ ├── one-of-defaults.ts │ │ ├── one-of.ts │ │ ├── options.ts │ │ ├── ordering.ts │ │ ├── pattern-properties.ts │ │ ├── property-dependencies.ts │ │ ├── references.ts │ │ ├── schema-dependencies.ts │ │ ├── simple.ts │ │ ├── single.ts │ │ └── widgets.ts │ ├── scheduler.d.ts │ ├── select.svelte │ ├── shadow │ │ ├── host.svelte │ │ ├── index.ts │ │ └── root.svelte │ ├── shared │ │ ├── index.ts │ │ └── theme.ts │ ├── theme.svelte.ts │ └── vite-env.d.ts │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── examples ├── animated-array │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +page.svelte │ │ │ └── animated-array.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── async-combobox │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +page.svelte │ │ │ ├── async-combobox-widget.svelte │ │ │ ├── async-combobox.svelte │ │ │ └── countries.ts │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── basic-starter │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── daisyui5-starter │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +layout.svelte │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── flowbite3-starter │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +layout.svelte │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── formulas │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +page.svelte │ │ │ └── object-field.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── markdown-description │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +page.svelte │ │ │ └── description.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── pattern-properties-validator │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── shadcn4-starter │ ├── .gitignore │ ├── .npmrc │ ├── components.json │ ├── package.json │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ ├── form-defaults.ts │ │ │ └── utils.ts │ │ └── routes │ │ │ ├── +layout.svelte │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── skeleton3-starter │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── lib │ │ │ └── form-defaults.ts │ │ └── routes │ │ │ ├── +layout.svelte │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts └── tabbed-layout │ ├── .gitignore │ ├── .npmrc │ ├── package.json │ ├── src │ ├── app.d.ts │ ├── app.html │ ├── lib │ │ ├── form-defaults.ts │ │ └── tabs │ │ │ ├── context.svelte.ts │ │ │ ├── focus.ts │ │ │ ├── index.ts │ │ │ ├── layout.svelte │ │ │ ├── schema.ts │ │ │ ├── tab.svelte │ │ │ └── tabs.svelte │ └── routes │ │ ├── +page.svelte │ │ ├── sub-tabs.svelte │ │ └── top-tabs.svelte │ ├── static │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── flake.lock ├── flake.nix ├── mkfile ├── package.json ├── packages ├── ajv8-validator │ ├── CHANGELOG.md │ ├── README.md │ ├── package.json │ ├── src │ │ ├── errors.ts │ │ ├── index.ts │ │ ├── model.ts │ │ ├── precompile │ │ │ ├── index.ts │ │ │ └── validator.ts │ │ ├── schema-compilers.ts │ │ ├── validator.test.ts │ │ └── validator.ts │ ├── tsconfig.json │ └── vitest.config.ts ├── basic-theme │ ├── CHANGELOG.md │ ├── README.md │ ├── index.html │ ├── package.json │ ├── src │ │ ├── app.svelte │ │ ├── app.ts │ │ ├── components │ │ │ ├── button.svelte │ │ │ ├── description.svelte │ │ │ ├── errors-list.svelte │ │ │ ├── exports.ts │ │ │ ├── form.svelte │ │ │ ├── help.svelte │ │ │ ├── label.svelte │ │ │ ├── layout.svelte │ │ │ ├── submit-button.svelte │ │ │ └── title.svelte │ │ ├── definitions.ts │ │ ├── extra-widgets │ │ │ ├── checkboxes-include.ts │ │ │ ├── checkboxes.svelte │ │ │ ├── date-picker-include.ts │ │ │ ├── date-picker.svelte │ │ │ ├── file-include.ts │ │ │ ├── file.svelte │ │ │ ├── multi-select-include.ts │ │ │ ├── multi-select.svelte │ │ │ ├── radio-include.ts │ │ │ ├── radio.svelte │ │ │ ├── range-include.ts │ │ │ ├── range.svelte │ │ │ ├── textarea-include.ts │ │ │ └── textarea.svelte │ │ ├── index.ts │ │ ├── specs.ts │ │ ├── vite-env.d.ts │ │ └── widgets │ │ │ ├── checkbox.svelte │ │ │ ├── exports.ts │ │ │ ├── number.svelte │ │ │ ├── select.svelte │ │ │ └── text.svelte │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts ├── cfworker-validator │ ├── CHANGELOG.md │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.ts │ │ ├── validator.svelte.test.ts │ │ └── validator.svelte.ts │ ├── tsconfig.json │ └── vitest.config.ts ├── daisyui5-theme │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── components │ │ │ │ ├── button.svelte │ │ │ │ ├── description.svelte │ │ │ │ ├── errors-list.svelte │ │ │ │ ├── exports.ts │ │ │ │ ├── form.svelte │ │ │ │ ├── help.svelte │ │ │ │ ├── label.svelte │ │ │ │ ├── layout.svelte │ │ │ │ ├── submit-button.svelte │ │ │ │ └── title.svelte │ │ │ ├── definitions.ts │ │ │ ├── extra-widgets │ │ │ │ ├── cally-date-picker-include.ts │ │ │ │ ├── cally-date-picker.svelte │ │ │ │ ├── checkboxes-include.ts │ │ │ │ ├── checkboxes.svelte │ │ │ │ ├── file-include.ts │ │ │ │ ├── file.svelte │ │ │ │ ├── filter-radio-buttons-include.ts │ │ │ │ ├── filter-radio-buttons.svelte │ │ │ │ ├── multi-select-include.ts │ │ │ │ ├── multi-select.svelte │ │ │ │ ├── pikaday-date-picker-include.ts │ │ │ │ ├── pikaday-date-picker.svelte │ │ │ │ ├── radio-buttons-include.ts │ │ │ │ ├── radio-buttons.svelte │ │ │ │ ├── radio-include.ts │ │ │ │ ├── radio.svelte │ │ │ │ ├── range-include.ts │ │ │ │ ├── range.svelte │ │ │ │ ├── rating-include.ts │ │ │ │ ├── rating.svelte │ │ │ │ ├── switch-include.ts │ │ │ │ ├── switch.svelte │ │ │ │ ├── textarea-include.ts │ │ │ │ └── textarea.svelte │ │ │ ├── index.ts │ │ │ ├── specs.ts │ │ │ └── widgets │ │ │ │ ├── checkbox.svelte │ │ │ │ ├── exports.ts │ │ │ │ ├── number.svelte │ │ │ │ ├── select.svelte │ │ │ │ └── text.svelte │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── flowbite-icons │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── icons.svelte │ │ │ ├── index.ts │ │ │ └── preset.ts │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── flowbite3-theme │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── App.svelte │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── components │ │ │ │ ├── button.svelte │ │ │ │ ├── description.svelte │ │ │ │ ├── errors-list.svelte │ │ │ │ ├── exports.ts │ │ │ │ ├── form.svelte │ │ │ │ ├── help.svelte │ │ │ │ ├── label.svelte │ │ │ │ ├── layout.svelte │ │ │ │ ├── submit-button.svelte │ │ │ │ └── title.svelte │ │ │ ├── definitions.ts │ │ │ ├── extra-widgets │ │ │ │ ├── checkboxes-include.ts │ │ │ │ ├── checkboxes.svelte │ │ │ │ ├── date-picker-include.ts │ │ │ │ ├── date-picker.svelte │ │ │ │ ├── file-include.ts │ │ │ │ ├── file.svelte │ │ │ │ ├── multi-select-include.ts │ │ │ │ ├── multi-select.svelte │ │ │ │ ├── radio-buttons-include.ts │ │ │ │ ├── radio-buttons.svelte │ │ │ │ ├── radio-include.ts │ │ │ │ ├── radio.svelte │ │ │ │ ├── range-include.ts │ │ │ │ ├── range.svelte │ │ │ │ ├── switch-include.ts │ │ │ │ ├── switch.svelte │ │ │ │ ├── tags-include.ts │ │ │ │ ├── tags.svelte │ │ │ │ ├── textarea-include.ts │ │ │ │ └── textarea.svelte │ │ │ ├── index.ts │ │ │ ├── specs.ts │ │ │ └── widgets │ │ │ │ ├── checkbox.svelte │ │ │ │ ├── exports.ts │ │ │ │ ├── number.svelte │ │ │ │ ├── select.svelte │ │ │ │ └── text.svelte │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── form │ ├── CHANGELOG.md │ ├── LICENSE │ ├── LICENSE-APACHE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── core │ │ │ ├── constant-schema.ts │ │ │ ├── deep-equal.ts │ │ │ ├── default-state.test.ts │ │ │ ├── default-state.ts │ │ │ ├── definitions.test.ts │ │ │ ├── definitions.ts │ │ │ ├── discriminator.test.ts │ │ │ ├── discriminator.ts │ │ │ ├── enum-option.ts │ │ │ ├── fixtures │ │ │ │ └── test-data.ts │ │ │ ├── index.ts │ │ │ ├── is-additional-property.ts │ │ │ ├── is-expandable.ts │ │ │ ├── is-file-schema.ts │ │ │ ├── is-fixed-items.ts │ │ │ ├── is-select.test.ts │ │ │ ├── is-select.ts │ │ │ ├── known-properties.ts │ │ │ ├── matching.test.ts │ │ │ ├── matching.ts │ │ │ ├── merge.test.ts │ │ │ ├── merge.ts │ │ │ ├── merger.ts │ │ │ ├── order-properties.test.ts │ │ │ ├── order-properties.ts │ │ │ ├── path.test.ts │ │ │ ├── path.ts │ │ │ ├── prefix-schema-refs.test.ts │ │ │ ├── prefix-schema-refs.ts │ │ │ ├── resolve.test.ts │ │ │ ├── resolve.ts │ │ │ ├── sanitize-data-for-new-schema.test.ts │ │ │ ├── sanitize-data-for-new-schema.ts │ │ │ ├── schema-hash.ts │ │ │ ├── schema-transformer.ts │ │ │ ├── schema-traverser.test.ts │ │ │ ├── schema-traverser.ts │ │ │ ├── schema-value-traverser.ts │ │ │ ├── schema.ts │ │ │ ├── test-validator.ts │ │ │ ├── traverser.ts │ │ │ ├── type.test.ts │ │ │ ├── type.ts │ │ │ ├── validator.ts │ │ │ └── value.ts │ │ ├── fields │ │ │ ├── any-of.svelte │ │ │ ├── array │ │ │ │ ├── array-base.svelte │ │ │ │ ├── array-field.svelte │ │ │ │ ├── array-item-field.svelte │ │ │ │ ├── context.svelte.ts │ │ │ │ ├── exports.ts │ │ │ │ ├── model.ts │ │ │ │ ├── tuple-field.svelte │ │ │ │ └── ui-options.ts │ │ │ ├── boolean.svelte │ │ │ ├── combination.svelte │ │ │ ├── components.ts │ │ │ ├── enum.ts │ │ │ ├── exports.ts │ │ │ ├── extra-fields │ │ │ │ ├── boolean-select-include.ts │ │ │ │ ├── boolean-select.svelte │ │ │ │ ├── enum-include.ts │ │ │ │ ├── enum.svelte │ │ │ │ ├── file-include.ts │ │ │ │ ├── file.svelte │ │ │ │ ├── files-include.ts │ │ │ │ ├── files.svelte │ │ │ │ ├── multi-enum-include.ts │ │ │ │ ├── multi-enum.svelte │ │ │ │ ├── tags-include.ts │ │ │ │ └── tags.svelte │ │ │ ├── extra-widgets │ │ │ │ ├── checkboxes.ts │ │ │ │ ├── combobox.ts │ │ │ │ ├── date-picker.ts │ │ │ │ ├── file.ts │ │ │ │ ├── multi-select.ts │ │ │ │ ├── radio-buttons.ts │ │ │ │ ├── radio.ts │ │ │ │ ├── range.ts │ │ │ │ ├── rating.ts │ │ │ │ ├── switch.ts │ │ │ │ ├── tags.ts │ │ │ │ └── textarea.ts │ │ │ ├── field-base.svelte │ │ │ ├── integer.svelte │ │ │ ├── null.svelte │ │ │ ├── number-field.svelte │ │ │ ├── object │ │ │ │ ├── context.svelte.ts │ │ │ │ ├── exports.ts │ │ │ │ ├── model.ts │ │ │ │ ├── object-field.svelte │ │ │ │ ├── object-key-input.svelte │ │ │ │ ├── object-property-field.svelte │ │ │ │ └── ui-options.ts │ │ │ ├── one-of.svelte │ │ │ ├── resolver │ │ │ │ ├── definitions.ts │ │ │ │ └── index.ts │ │ │ ├── string.svelte │ │ │ ├── templates.ts │ │ │ ├── ui-options.ts │ │ │ └── widgets.ts │ │ ├── focus-on-first-error.ts │ │ ├── form │ │ │ ├── basic-form.svelte │ │ │ ├── components.ts │ │ │ ├── config.ts │ │ │ ├── content.module.ts │ │ │ ├── content.svelte │ │ │ ├── context │ │ │ │ ├── attributes.ts │ │ │ │ ├── components.ts │ │ │ │ ├── context.ts │ │ │ │ ├── event-handlers.svelte.ts │ │ │ │ ├── files.ts │ │ │ │ ├── index.ts │ │ │ │ ├── schema.ts │ │ │ │ ├── ui-schema.ts │ │ │ │ └── validation.ts │ │ │ ├── create-form.svelte.ts │ │ │ ├── datalist.svelte │ │ │ ├── error-message.svelte │ │ │ ├── errors.ts │ │ │ ├── extra-fields │ │ │ │ ├── boolean-select.ts │ │ │ │ ├── date-field.ts │ │ │ │ ├── enum.ts │ │ │ │ ├── file.ts │ │ │ │ ├── files.ts │ │ │ │ ├── multi-enum.ts │ │ │ │ └── tags.ts │ │ │ ├── fields.ts │ │ │ ├── form.module.ts │ │ │ ├── form.svelte │ │ │ ├── icons.ts │ │ │ ├── id.ts │ │ │ ├── index.ts │ │ │ ├── main.ts │ │ │ ├── merger.ts │ │ │ ├── model.ts │ │ │ ├── resolvers │ │ │ │ ├── basic.ts │ │ │ │ └── compat.ts │ │ │ ├── simple-form.svelte │ │ │ ├── submit-button.module.ts │ │ │ ├── submit-button.svelte │ │ │ ├── text.module.ts │ │ │ ├── text.svelte │ │ │ ├── translation.ts │ │ │ ├── ui-schema.test.ts │ │ │ ├── ui-schema.ts │ │ │ ├── validation.ts │ │ │ └── validator.ts │ │ ├── lib │ │ │ ├── action.svelte.test.ts │ │ │ ├── action.svelte.ts │ │ │ ├── array.ts │ │ │ ├── component.ts │ │ │ ├── css.ts │ │ │ ├── dynamic.svelte │ │ │ ├── env.ts │ │ │ ├── file.ts │ │ │ ├── function.ts │ │ │ ├── keyed-array.svelte.ts │ │ │ ├── memoize.ts │ │ │ ├── object.ts │ │ │ ├── reg-exp.ts │ │ │ ├── resolver.ts │ │ │ ├── scheduler.ts │ │ │ ├── svelte.svelte.ts │ │ │ ├── trie.ts │ │ │ └── types.ts │ │ ├── omit-extra-data.test.ts │ │ ├── omit-extra-data.ts │ │ ├── options.svelte.ts │ │ ├── prevent-page-reload.svelte.ts │ │ ├── scheduler.d.ts │ │ ├── static-analysis.ts │ │ ├── templates │ │ │ ├── array-item-template.svelte │ │ │ ├── array-template.svelte │ │ │ ├── components.ts │ │ │ ├── exports.ts │ │ │ ├── field-template.svelte │ │ │ ├── get-template-props.ts │ │ │ ├── multi-field-template.svelte │ │ │ ├── object-property-template.svelte │ │ │ └── object-template.svelte │ │ ├── translations │ │ │ ├── en.ts │ │ │ └── ru.ts │ │ ├── validators │ │ │ ├── precompile.test.ts │ │ │ ├── precompile.ts │ │ │ ├── properties.ts │ │ │ └── standard-schema.ts │ │ └── vite-env.d.ts │ ├── svelte.config.js │ ├── tsconfig.json │ ├── vite.config.ts │ └── vitest-setup.ts ├── lucide-icons │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── icons.svelte │ │ │ └── index.ts │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── moving-icons │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── arrow-down.svelte │ │ │ ├── arrow-up.svelte │ │ │ ├── copy.svelte │ │ │ ├── icons.svelte │ │ │ ├── index.ts │ │ │ └── trash.svelte │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── radix-icons │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── icons.svelte │ │ │ └── index.ts │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── schemasafe-validator │ ├── CHANGELOG.md │ ├── README.md │ ├── package.json │ ├── src │ │ ├── errors.ts │ │ ├── index.ts │ │ ├── model.ts │ │ ├── precompile │ │ │ ├── index.ts │ │ │ └── validator.ts │ │ └── validator.ts │ ├── tsconfig.json │ └── vitest.config.ts ├── shadcn4-theme │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── components.json │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── demo.spec.ts │ │ ├── lib │ │ │ ├── components │ │ │ │ └── ui │ │ │ │ │ ├── button │ │ │ │ │ ├── button.svelte │ │ │ │ │ └── index.ts │ │ │ │ │ ├── calendar │ │ │ │ │ ├── calendar-cell.svelte │ │ │ │ │ ├── calendar-day.svelte │ │ │ │ │ ├── calendar-grid-body.svelte │ │ │ │ │ ├── calendar-grid-head.svelte │ │ │ │ │ ├── calendar-grid-row.svelte │ │ │ │ │ ├── calendar-grid.svelte │ │ │ │ │ ├── calendar-head-cell.svelte │ │ │ │ │ ├── calendar-header.svelte │ │ │ │ │ ├── calendar-heading.svelte │ │ │ │ │ ├── calendar-months.svelte │ │ │ │ │ ├── calendar-next-button.svelte │ │ │ │ │ ├── calendar-prev-button.svelte │ │ │ │ │ ├── calendar.svelte │ │ │ │ │ └── index.ts │ │ │ │ │ ├── checkbox │ │ │ │ │ ├── checkbox.svelte │ │ │ │ │ └── index.ts │ │ │ │ │ ├── command │ │ │ │ │ ├── command-dialog.svelte │ │ │ │ │ ├── command-empty.svelte │ │ │ │ │ ├── command-group.svelte │ │ │ │ │ ├── command-input.svelte │ │ │ │ │ ├── command-item.svelte │ │ │ │ │ ├── command-link-item.svelte │ │ │ │ │ ├── command-list.svelte │ │ │ │ │ ├── command-separator.svelte │ │ │ │ │ ├── command-shortcut.svelte │ │ │ │ │ ├── command.svelte │ │ │ │ │ └── index.ts │ │ │ │ │ ├── dialog │ │ │ │ │ ├── dialog-close.svelte │ │ │ │ │ ├── dialog-content.svelte │ │ │ │ │ ├── dialog-description.svelte │ │ │ │ │ ├── dialog-footer.svelte │ │ │ │ │ ├── dialog-header.svelte │ │ │ │ │ ├── dialog-overlay.svelte │ │ │ │ │ ├── dialog-title.svelte │ │ │ │ │ ├── dialog-trigger.svelte │ │ │ │ │ └── index.ts │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── input │ │ │ │ │ ├── index.ts │ │ │ │ │ └── input.svelte │ │ │ │ │ ├── label │ │ │ │ │ ├── index.ts │ │ │ │ │ └── label.svelte │ │ │ │ │ ├── popover │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── popover-content.svelte │ │ │ │ │ └── popover-trigger.svelte │ │ │ │ │ ├── radio-group │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── radio-group-item.svelte │ │ │ │ │ └── radio-group.svelte │ │ │ │ │ ├── select │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── select-content.svelte │ │ │ │ │ ├── select-group.svelte │ │ │ │ │ ├── select-item.svelte │ │ │ │ │ ├── select-label.svelte │ │ │ │ │ ├── select-scroll-down-button.svelte │ │ │ │ │ ├── select-scroll-up-button.svelte │ │ │ │ │ ├── select-separator.svelte │ │ │ │ │ └── select-trigger.svelte │ │ │ │ │ ├── separator │ │ │ │ │ ├── index.ts │ │ │ │ │ └── separator.svelte │ │ │ │ │ ├── slider │ │ │ │ │ ├── index.ts │ │ │ │ │ └── slider.svelte │ │ │ │ │ ├── switch │ │ │ │ │ ├── index.ts │ │ │ │ │ └── switch.svelte │ │ │ │ │ ├── textarea │ │ │ │ │ ├── index.ts │ │ │ │ │ └── textarea.svelte │ │ │ │ │ ├── toggle-group │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── toggle-group-item.svelte │ │ │ │ │ └── toggle-group.svelte │ │ │ │ │ └── toggle │ │ │ │ │ ├── index.ts │ │ │ │ │ └── toggle.svelte │ │ │ ├── specs.ts │ │ │ ├── theme │ │ │ │ ├── components │ │ │ │ │ ├── button.svelte │ │ │ │ │ ├── description.svelte │ │ │ │ │ ├── errors-list.svelte │ │ │ │ │ ├── exports.ts │ │ │ │ │ ├── form.svelte │ │ │ │ │ ├── help.svelte │ │ │ │ │ ├── label.svelte │ │ │ │ │ ├── layout.svelte │ │ │ │ │ ├── submit-button.svelte │ │ │ │ │ └── title.svelte │ │ │ │ ├── context.ts │ │ │ │ ├── definitions.ts │ │ │ │ ├── extra-widgets │ │ │ │ │ ├── checkboxes-include.ts │ │ │ │ │ ├── checkboxes.svelte │ │ │ │ │ ├── combobox-include.ts │ │ │ │ │ ├── combobox.svelte │ │ │ │ │ ├── date-picker-include.ts │ │ │ │ │ ├── date-picker.svelte │ │ │ │ │ ├── file-include.ts │ │ │ │ │ ├── file.svelte │ │ │ │ │ ├── multi-select-include.ts │ │ │ │ │ ├── multi-select.svelte │ │ │ │ │ ├── radio-buttons-include.ts │ │ │ │ │ ├── radio-buttons.svelte │ │ │ │ │ ├── radio-include.ts │ │ │ │ │ ├── radio.svelte │ │ │ │ │ ├── range-include.ts │ │ │ │ │ ├── range.svelte │ │ │ │ │ ├── switch-include.ts │ │ │ │ │ ├── switch.svelte │ │ │ │ │ ├── textarea-include.ts │ │ │ │ │ └── textarea.svelte │ │ │ │ ├── index.ts │ │ │ │ ├── types │ │ │ │ │ ├── button.ts │ │ │ │ │ ├── checkbox.ts │ │ │ │ │ ├── input.ts │ │ │ │ │ ├── label.ts │ │ │ │ │ ├── popover.ts │ │ │ │ │ └── select.ts │ │ │ │ └── widgets │ │ │ │ │ ├── checkbox.svelte │ │ │ │ │ ├── exports.ts │ │ │ │ │ ├── number.svelte │ │ │ │ │ ├── select.svelte │ │ │ │ │ └── text.svelte │ │ │ └── utils.ts │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tsconfig.json │ ├── vite.config.ts │ └── vitest-setup-client.ts ├── skeleton3-theme │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.css │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── components │ │ │ │ ├── button.svelte │ │ │ │ ├── description.svelte │ │ │ │ ├── errors-list.svelte │ │ │ │ ├── exports.ts │ │ │ │ ├── form.svelte │ │ │ │ ├── help.svelte │ │ │ │ ├── label.svelte │ │ │ │ ├── layout.svelte │ │ │ │ ├── submit-button.svelte │ │ │ │ └── title.svelte │ │ │ ├── definitions.ts │ │ │ ├── extra-widgets │ │ │ │ ├── checkboxes-include.ts │ │ │ │ ├── checkboxes.svelte │ │ │ │ ├── date-picker-include.ts │ │ │ │ ├── date-picker.svelte │ │ │ │ ├── file-include.ts │ │ │ │ ├── file-upload-include.ts │ │ │ │ ├── file-upload.svelte │ │ │ │ ├── file.svelte │ │ │ │ ├── multi-select-include.ts │ │ │ │ ├── multi-select.svelte │ │ │ │ ├── radio-buttons-include.ts │ │ │ │ ├── radio-buttons.svelte │ │ │ │ ├── radio-include.ts │ │ │ │ ├── radio.svelte │ │ │ │ ├── range-include.ts │ │ │ │ ├── range.svelte │ │ │ │ ├── rating-include.ts │ │ │ │ ├── rating.svelte │ │ │ │ ├── slider-include.ts │ │ │ │ ├── slider.svelte │ │ │ │ ├── switch-include.ts │ │ │ │ ├── switch.svelte │ │ │ │ ├── tags-include.ts │ │ │ │ ├── tags.svelte │ │ │ │ ├── textarea-include.ts │ │ │ │ └── textarea.svelte │ │ │ ├── index.ts │ │ │ ├── specs.ts │ │ │ └── widgets │ │ │ │ ├── checkbox.svelte │ │ │ │ ├── exports.ts │ │ │ │ ├── number.svelte │ │ │ │ ├── select.svelte │ │ │ │ └── text.svelte │ │ └── routes │ │ │ └── +page.svelte │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── sveltekit │ ├── .gitignore │ ├── .npmrc │ ├── .prettierignore │ ├── .prettierrc │ ├── CHANGELOG.md │ ├── README.md │ ├── eslint.config.js │ ├── package.json │ ├── playwright.config.ts │ ├── src │ │ ├── app.d.ts │ │ ├── app.html │ │ ├── index.test.ts │ │ ├── lib │ │ │ ├── client │ │ │ │ ├── additional-property-key-validator.ts │ │ │ │ ├── form.svelte.ts │ │ │ │ ├── index.ts │ │ │ │ ├── meta.ts │ │ │ │ ├── request.svelte.ts │ │ │ │ └── simple-form.svelte │ │ │ ├── model.ts │ │ │ └── server │ │ │ │ ├── convert-form-data-entries.test.ts │ │ │ │ ├── convert-form-data-entries.ts │ │ │ │ ├── entry.ts │ │ │ │ ├── index.ts │ │ │ │ ├── schema-value-parser.test.ts │ │ │ │ ├── schema-value-parser.ts │ │ │ │ └── server.ts │ │ └── routes │ │ │ ├── +page.server.ts │ │ │ ├── +page.svelte │ │ │ ├── form1.svelte │ │ │ ├── form2.svelte │ │ │ ├── form3.svelte │ │ │ └── model.ts │ ├── static │ │ └── favicon.png │ ├── svelte.config.js │ ├── tests │ │ └── test.ts │ ├── tsconfig.json │ └── vite.config.ts ├── testing │ ├── CHANGELOG.md │ ├── README.md │ ├── package.json │ ├── src │ │ ├── components │ │ │ └── shadow │ │ │ │ ├── index.ts │ │ │ │ ├── shadow-host.svelte │ │ │ │ └── shadow-root.svelte │ │ ├── demo │ │ │ ├── all-icons.svelte │ │ │ ├── components-and-widgets.svelte │ │ │ ├── form.svelte │ │ │ ├── index.ts │ │ │ └── schemas.ts │ │ └── vite-env.d.ts │ ├── svelte.config.js │ ├── tsconfig.json │ └── vite.config.ts └── zod-validator │ ├── CHANGELOG.md │ ├── README.md │ ├── package.json │ ├── src │ ├── errors.ts │ ├── index.ts │ └── validator.ts │ └── tsconfig.json ├── patches └── svelte2tsx.patch ├── pnpm-lock.yaml ├── pnpm-workspace.yaml ├── turbo.json └── vitest.workspace.ts /.changeset/better-goats-swim.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/ajv8-validator": patch 3 | --- 4 | 5 | Fix async fields validation 6 | -------------------------------------------------------------------------------- /.changeset/big-women-follow.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `fromFactories` function to `lib/resolver` 6 | -------------------------------------------------------------------------------- /.changeset/bitter-rice-do.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Port https://github.com/rjsf-team/react-jsonschema-form/pull/4617 6 | -------------------------------------------------------------------------------- /.changeset/blue-crews-deny.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": minor 3 | --- 4 | 5 | Add extra widgets: `FileUpload` (alternative `fileWidget`), `radioButtonsWidget`, `ratingWidget`, `Slider` (alternative `rangeWidget`), `switchWidget` 6 | -------------------------------------------------------------------------------- /.changeset/brown-roses-knock.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/basic-theme": minor 3 | --- 4 | 5 | Add support for extra ui options 6 | -------------------------------------------------------------------------------- /.changeset/bumpy-clocks-feel.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/cfworker-validator": minor 3 | --- 4 | 5 | Add `fixUndefined` option to handle `undefined` values. 6 | 7 | Remove field value wrapping in `fieldValue` validator. 8 | -------------------------------------------------------------------------------- /.changeset/bumpy-parts-scream.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `tagsField` extra field and `tagsWidget` extra widget definition 6 | -------------------------------------------------------------------------------- /.changeset/bumpy-windows-mix.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/shadcn4-theme": minor 3 | --- 4 | 5 | Add `@sjsf/shadcn4-theme` package 6 | -------------------------------------------------------------------------------- /.changeset/clean-tips-judge.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Add support for `$ref` in UI schema 6 | -------------------------------------------------------------------------------- /.changeset/clear-coats-jam.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": patch 3 | --- 4 | 5 | Fix switch label 6 | -------------------------------------------------------------------------------- /.changeset/clever-crews-retire.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Add `label` component 6 | -------------------------------------------------------------------------------- /.changeset/clever-eagles-turn.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `lib/deep-equal` submodule 6 | -------------------------------------------------------------------------------- /.changeset/cold-apples-speak.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/basic-theme": minor 3 | --- 4 | 5 | Add `@sjsf/basic-theme` package 6 | -------------------------------------------------------------------------------- /.changeset/cold-grapes-eat.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Fix 6 | -------------------------------------------------------------------------------- /.changeset/common-rabbits-open.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": major 3 | --- 4 | 5 | Increase font size in title component 6 | -------------------------------------------------------------------------------- /.changeset/cool-eels-argue.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Port https://github.com/rjsf-team/react-jsonschema-form/pull/4644 6 | -------------------------------------------------------------------------------- /.changeset/cruel-wolves-throw.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": minor 3 | --- 4 | 5 | Add `tags` extra widget 6 | -------------------------------------------------------------------------------- /.changeset/curvy-buttons-float.md: -------------------------------------------------------------------------------- 1 | --- 2 | "docs2": patch 3 | --- 4 | 5 | Add a note about the explicit use of `extra` widgets (#120) 6 | -------------------------------------------------------------------------------- /.changeset/curvy-frogs-grin.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Add `useLabel` property for the `fieldTemplate` component 6 | -------------------------------------------------------------------------------- /.changeset/cute-apples-marry.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Refactor async logic in file fields 6 | -------------------------------------------------------------------------------- /.changeset/dark-lines-show.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/shadcn4-theme": patch 3 | --- 4 | 5 | Fix missing extra widgets 6 | -------------------------------------------------------------------------------- /.changeset/dirty-nails-push.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Extract array field logic into `createArrayContext` function 6 | -------------------------------------------------------------------------------- /.changeset/dull-balloons-rush.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `env` lib 6 | -------------------------------------------------------------------------------- /.changeset/eager-clouds-cry.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add combobox widget type 6 | -------------------------------------------------------------------------------- /.changeset/early-wings-tell.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Port https://github.com/rjsf-team/react-jsonschema-form/pull/4637 6 | -------------------------------------------------------------------------------- /.changeset/eighty-crabs-allow.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `forId` from the `errorList` component props 6 | -------------------------------------------------------------------------------- /.changeset/eleven-cloths-cut.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `uiOptions` property from `Config` 6 | -------------------------------------------------------------------------------- /.changeset/empty-bears-attend.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | The `getValueByPath` function has been returned. 6 | -------------------------------------------------------------------------------- /.changeset/empty-birds-learn.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `css` lib 6 | -------------------------------------------------------------------------------- /.changeset/empty-cooks-brush.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/shadcn4-theme": major 3 | --- 4 | 5 | Change widget type from `selectWidget` to `comboboxWidget` for combobox widget 6 | -------------------------------------------------------------------------------- /.changeset/empty-hats-crash.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `extraUiOptions` property to form options 6 | -------------------------------------------------------------------------------- /.changeset/every-dots-ring.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Pass `widgetType` property to the `fieldTemplate` component 6 | -------------------------------------------------------------------------------- /.changeset/every-ducks-press.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": major 3 | "@sjsf/skeleton3-theme": major 4 | "@sjsf/daisyui5-theme": major 5 | "@sjsf/flowbite-icons": major 6 | "@sjsf/shadcn4-theme": major 7 | "@sjsf/lucide-icons": major 8 | "@sjsf/moving-icons": major 9 | "@sjsf/basic-theme": major 10 | "@sjsf/radix-icons": major 11 | "@sjsf/sveltekit": major 12 | "testing": major 13 | "@sjsf/form": major 14 | --- 15 | 16 | Bump peer and dev dependencies 17 | -------------------------------------------------------------------------------- /.changeset/fancy-cobras-switch.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Rename `fields/extra-widgets/file-widget` to `fields/extra-widgets/file` 6 | -------------------------------------------------------------------------------- /.changeset/fine-days-follow.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Make `checkboxes` and `file` widgets optional 6 | -------------------------------------------------------------------------------- /.changeset/fine-glasses-raise.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": patch 3 | "@sjsf/basic-theme": patch 4 | "@sjsf/form": patch 5 | --- 6 | 7 | Fix theme resolver type 8 | -------------------------------------------------------------------------------- /.changeset/five-tools-joke.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": minor 3 | --- 4 | 5 | Add flowbite v3 package 6 | -------------------------------------------------------------------------------- /.changeset/fluffy-dots-hunt.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": patch 3 | --- 4 | 5 | Fix extra input ids 6 | -------------------------------------------------------------------------------- /.changeset/free-adults-talk.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Replace `asyncProxy` with `createAsyncBinding` 6 | -------------------------------------------------------------------------------- /.changeset/fresh-pans-tell.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Refactor action logic: 6 | 7 | - Remove `debounce` combinator 8 | - Add `untrack` combinator result 9 | -------------------------------------------------------------------------------- /.changeset/fruity-trees-tap.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `useDatePickerForDateFormat` function to `fields/extra-widgets/date-picker` 6 | -------------------------------------------------------------------------------- /.changeset/giant-days-allow.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": minor 3 | "@sjsf/skeleton3-theme": minor 4 | "@sjsf/daisyui5-theme": minor 5 | "@sjsf/basic-theme": minor 6 | --- 7 | 8 | Add `label` component, implement two level title 9 | -------------------------------------------------------------------------------- /.changeset/giant-impalas-fold.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": minor 3 | --- 4 | 5 | Add `tags` widget 6 | -------------------------------------------------------------------------------- /.changeset/good-lies-notice.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": major 3 | --- 4 | 5 | Bump flowbite-svelte version to `1.0.0` 6 | -------------------------------------------------------------------------------- /.changeset/green-hands-carry.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | The `DefaultFormMerger` class has been replaced by the `createFormMerger` factory. 6 | -------------------------------------------------------------------------------- /.changeset/green-items-cheat.md: -------------------------------------------------------------------------------- 1 | --- 2 | "testing": minor 3 | --- 4 | 5 | Allow to provide additional specs for widgets schemas 6 | -------------------------------------------------------------------------------- /.changeset/huge-planes-learn.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": patch 3 | --- 4 | 5 | Add `basic-theme` as peer dependency 6 | -------------------------------------------------------------------------------- /.changeset/hungry-breads-rescue.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": major 3 | --- 4 | 5 | Change ui options prefix to `flowbite3` 6 | -------------------------------------------------------------------------------- /.changeset/icy-trains-exist.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Use `untrack` inside the following `Action` methods: `run`, `runAsync`, and `abort`. 6 | -------------------------------------------------------------------------------- /.changeset/lazy-rocks-run.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": minor 3 | --- 4 | 5 | Add rating extra widget 6 | -------------------------------------------------------------------------------- /.changeset/legal-keys-fly.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Rename `FoundationalComponent` to `FoundationalComponentType` 6 | -------------------------------------------------------------------------------- /.changeset/little-monkeys-hammer.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Relax component compatibility checks. 6 | Add a `type` discriminator for field, template, and widget properties. 7 | Remove `Equal` and `ExpandAndEqual` types from `lib/types` 8 | -------------------------------------------------------------------------------- /.changeset/little-otters-carry.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `getSchemaDefinitionByPath` function 6 | -------------------------------------------------------------------------------- /.changeset/loud-monkeys-jog.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `use-mutation` submodule 6 | -------------------------------------------------------------------------------- /.changeset/loud-parrots-enjoy.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite-icons": major 3 | --- 4 | 5 | Migrate to Tailwind v4 6 | -------------------------------------------------------------------------------- /.changeset/many-badgers-move.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": major 3 | "@sjsf/skeleton3-theme": major 4 | "@sjsf/daisyui5-theme": major 5 | "@sjsf/basic-theme": major 6 | --- 7 | 8 | Remove automatic setting of "default values" for `undefined` value in `Range` and `Switch` widgets 9 | -------------------------------------------------------------------------------- /.changeset/mean-carpets-poke.md: -------------------------------------------------------------------------------- 1 | --- 2 | "playground2": minor 3 | --- 4 | 5 | Add `Share` button 6 | -------------------------------------------------------------------------------- /.changeset/moody-doors-dance.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `proxy` function from `lib/svelte.svelte` 6 | -------------------------------------------------------------------------------- /.changeset/nasty-comics-pay.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": major 3 | --- 4 | 5 | Replace `label` with `fieldset-legend` class for field label 6 | -------------------------------------------------------------------------------- /.changeset/neat-carrots-eat.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `validators/precompile` submodule 6 | -------------------------------------------------------------------------------- /.changeset/nine-olives-say.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/ajv8-validator": minor 3 | --- 4 | 5 | Add `ajvPlugins` option for `createFormValidator` function 6 | -------------------------------------------------------------------------------- /.changeset/nine-pianos-tie.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/cfworker-validator": patch 3 | --- 4 | 5 | Use `getValueByPath` to extract title from json schema 6 | -------------------------------------------------------------------------------- /.changeset/odd-memes-enjoy.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": minor 3 | --- 4 | 5 | Remove client only import from pikaday date picker 6 | -------------------------------------------------------------------------------- /.changeset/olive-books-burn.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `lib/component` submodule 6 | -------------------------------------------------------------------------------- /.changeset/open-clouds-change.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite-icons": major 3 | "@sjsf/lucide-icons": major 4 | "@sjsf/radix-icons": major 5 | "@sjsf/form": major 6 | --- 7 | 8 | Migrate to `resolver` based providers 9 | -------------------------------------------------------------------------------- /.changeset/plenty-streets-sing.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Port https://github.com/rjsf-team/react-jsonschema-form/pull/4570 6 | -------------------------------------------------------------------------------- /.changeset/proud-squids-sniff.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": minor 3 | --- 4 | 5 | Add radio buttons widget 6 | -------------------------------------------------------------------------------- /.changeset/proud-trams-stare.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/cfworker-validator": major 3 | "@sjsf/ajv8-validator": major 4 | "@sjsf/daisyui5-theme": major 5 | "@sjsf/flowbite-icons": major 6 | "@sjsf/zod-validator": major 7 | "@sjsf/lucide-icons": major 8 | "@sjsf/moving-icons": major 9 | "@sjsf/basic-theme": major 10 | "@sjsf/radix-icons": major 11 | "@sjsf/sveltekit": major 12 | "@sjsf/form": major 13 | --- 14 | 15 | Bump svelte to 5.25.0, relax patch versions of peer dependencies. 16 | -------------------------------------------------------------------------------- /.changeset/quick-candies-rescue.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": patch 3 | --- 4 | 5 | Fix theme resolver type via post build script 6 | -------------------------------------------------------------------------------- /.changeset/quick-cycles-sniff.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": minor 3 | --- 4 | 5 | Add `daisyui5-theme` package 6 | -------------------------------------------------------------------------------- /.changeset/rare-buckets-begin.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Refactor form API: 6 | 7 | - Renames: 8 | - `form.validation` -> `form.submission` 9 | - `validationCombinator` -> `submissionCombinator` 10 | - `validationDelayedMs` -> `submissionDelayedMs` 11 | - `validationTimeoutMs` -> `submissionTimeoutMs` 12 | - `form.submit` now returns `void` 13 | -------------------------------------------------------------------------------- /.changeset/rare-meals-bathe.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Add support for extra attributes in input, textarea, and select attribute functions 6 | -------------------------------------------------------------------------------- /.changeset/ready-flowers-carry.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": major 3 | "@sjsf/basic-theme": major 4 | "@sjsf/form": major 5 | --- 6 | 7 | Move `checkboxes` and `file` widgets to extra folder 8 | -------------------------------------------------------------------------------- /.changeset/ready-windows-shop.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove the UI options `submitButtonText` and `additionalPropertyKeyPrefix` in favor of the new `translations` option. 6 | -------------------------------------------------------------------------------- /.changeset/red-coats-slide.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Fix 6 | 7 | Renames in the following submodules: 8 | 9 | - `@sjsf/form/fields/array/*` 10 | - `@sjsf/form/fields/object/*` 11 | - `@sjsf/form/templates/*` 12 | -------------------------------------------------------------------------------- /.changeset/red-dogs-retire.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": minor 3 | --- 4 | 5 | Add support for extra ui options 6 | -------------------------------------------------------------------------------- /.changeset/red-pillows-roll.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Port 6 | -------------------------------------------------------------------------------- /.changeset/rude-news-learn.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `matches` method to `Action` for type narrowing 6 | -------------------------------------------------------------------------------- /.changeset/seven-poets-enjoy.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": patch 3 | "@sjsf/skeleton3-theme": patch 4 | "@sjsf/daisyui5-theme": patch 5 | "@sjsf/shadcn4-theme": patch 6 | "@sjsf/basic-theme": patch 7 | --- 8 | 9 | Use `grid` layout for `object-property` layout 10 | -------------------------------------------------------------------------------- /.changeset/shiny-plums-develop.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `legacy-omit-extra-data` submodule 6 | -------------------------------------------------------------------------------- /.changeset/six-mails-scream.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Refactor action logic: 6 | 7 | - `run` methods now returns `void` 8 | - Added `runAsync` method that returns `Promise` 9 | - Fixed `state_referenced_locally` warning 10 | -------------------------------------------------------------------------------- /.changeset/slow-berries-beam.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `asSnippet` function 6 | -------------------------------------------------------------------------------- /.changeset/small-jobs-look.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Refactor matching logic to improve validation performance and accuracy 6 | -------------------------------------------------------------------------------- /.changeset/smooth-donkeys-play.md: -------------------------------------------------------------------------------- 1 | --- 2 | "playground2": major 3 | --- 4 | 5 | - Store playground state in a URL hash 6 | - Migration to shadcn-svelte UI 7 | -------------------------------------------------------------------------------- /.changeset/social-cameras-stand.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Rename `FormTag` to `Form` 6 | -------------------------------------------------------------------------------- /.changeset/soft-pigs-doubt.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": patch 3 | --- 4 | 5 | Fix types collisions 6 | -------------------------------------------------------------------------------- /.changeset/some-mails-sneeze.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Rename `setFromContext` to `setFormContext` 6 | -------------------------------------------------------------------------------- /.changeset/some-sloths-speak.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": major 3 | "@sjsf/skeleton3-theme": major 4 | "@sjsf/daisyui5-theme": major 5 | "@sjsf/basic-theme": major 6 | --- 7 | 8 | Removed automatic setting of `false` for `undefined` value in `Checkbox` widgets. 9 | -------------------------------------------------------------------------------- /.changeset/spicy-donkeys-make.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `UiSchemaRootContent` type 6 | -------------------------------------------------------------------------------- /.changeset/spicy-peaches-call.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Extract object field logic into `createObjectContext` function 6 | -------------------------------------------------------------------------------- /.changeset/spicy-planets-slide.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `arraySubSchemasMergeType` option for `mergeSchemas` function 6 | -------------------------------------------------------------------------------- /.changeset/spotty-webs-wear.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Add support for `patternProperties` keyword 6 | -------------------------------------------------------------------------------- /.changeset/swift-apples-chew.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Fixed `enumField` recognition in `compat` resolver 6 | -------------------------------------------------------------------------------- /.changeset/swift-areas-enjoy.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/lucide-icons": major 3 | --- 4 | 5 | Migration to `@lucide/svelte` 6 | -------------------------------------------------------------------------------- /.changeset/tall-phones-slide.md: -------------------------------------------------------------------------------- 1 | --- 2 | "playground2": minor 3 | --- 4 | 5 | Use CodeMirror editor 6 | -------------------------------------------------------------------------------- /.changeset/tame-guests-push.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/skeleton3-theme": minor 3 | --- 4 | 5 | Add skeleton v3 theme package 6 | -------------------------------------------------------------------------------- /.changeset/tame-taxis-itch.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Rename submodule `prevent-data-loss` to `prevent-page-reload` 6 | -------------------------------------------------------------------------------- /.changeset/tangy-kings-work.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `getUiSchemaByPath` function 6 | -------------------------------------------------------------------------------- /.changeset/thick-carrots-type.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `resolver` lib 6 | -------------------------------------------------------------------------------- /.changeset/thick-friends-retire.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Replace action `Status` enum with string literals 6 | -------------------------------------------------------------------------------- /.changeset/tidy-deer-heal.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `validate` and `validateAsync` form state methods 6 | -------------------------------------------------------------------------------- /.changeset/tiny-forks-dance.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": patch 3 | --- 4 | 5 | Fix input event handlers propagation 6 | -------------------------------------------------------------------------------- /.changeset/tough-bears-lose.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `AnyKey` type 6 | -------------------------------------------------------------------------------- /.changeset/tough-paths-feel.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/moving-icons": minor 3 | --- 4 | 5 | Add `@sjsf/moving-icons` package 6 | -------------------------------------------------------------------------------- /.changeset/tough-ravens-raise.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add options parameter to `createFormMerger` factory 6 | -------------------------------------------------------------------------------- /.changeset/tricky-ideas-send.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add support for `discriminator` schema property 6 | -------------------------------------------------------------------------------- /.changeset/twelve-cats-train.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/ajv8-validator": patch 3 | --- 4 | 5 | Remove field value wrapping in `fieldValue` validator 6 | -------------------------------------------------------------------------------- /.changeset/twenty-jeans-deny.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/ajv8-validator": minor 3 | --- 4 | 5 | Add `precompile` submodule to support precompiled mode 6 | -------------------------------------------------------------------------------- /.changeset/two-wings-double.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add standard schema form value validator 6 | -------------------------------------------------------------------------------- /.changeset/upset-snails-smile.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/cfworker-validator": major 3 | "@sjsf/ajv8-validator": major 4 | "@sjsf/zod-validator": major 5 | "@sjsf/form": major 6 | --- 7 | 8 | Migrate to a new `Validator` type model 9 | -------------------------------------------------------------------------------- /.changeset/violet-ants-win.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/basic-theme": patch 3 | --- 4 | 5 | Increase gap between fields to 1rem 6 | -------------------------------------------------------------------------------- /.changeset/violet-taxes-brake.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add `registry` form option 6 | -------------------------------------------------------------------------------- /.changeset/warm-swans-wait.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": major 3 | --- 4 | 5 | Bump `flowbite-svelte` peer dependency to `^1.0.0-next.11` 6 | -------------------------------------------------------------------------------- /.changeset/weak-ants-dig.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `required` and `forId` from the `title` component props 6 | -------------------------------------------------------------------------------- /.changeset/weak-suits-clap.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Fix type of `fields` resolver 6 | -------------------------------------------------------------------------------- /.changeset/weak-things-jump.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/zod-validator": patch 3 | --- 4 | 5 | Remove field value wrapping in `fieldValue` validator 6 | -------------------------------------------------------------------------------- /.changeset/whole-buckets-camp.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/schemasafe-validator": minor 3 | --- 4 | 5 | Add `@sjsf/schemasafe-validator` package 6 | -------------------------------------------------------------------------------- /.changeset/whole-snakes-allow.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": major 3 | --- 4 | 5 | Remove `getValueByPath` function 6 | -------------------------------------------------------------------------------- /.changeset/wicked-hoops-win.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/flowbite3-theme": minor 3 | --- 4 | 5 | Add support for extra ui options 6 | -------------------------------------------------------------------------------- /.changeset/wide-planes-hope.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": patch 3 | --- 4 | 5 | Port https://github.com/rjsf-team/react-jsonschema-form/pull/4626 6 | -------------------------------------------------------------------------------- /.changeset/wild-pets-raise.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/daisyui5-theme": minor 3 | --- 4 | 5 | Add support for extra ui options 6 | -------------------------------------------------------------------------------- /.changeset/wise-dodos-ring.md: -------------------------------------------------------------------------------- 1 | --- 2 | "@sjsf/form": minor 3 | --- 4 | 5 | Add function `getRootSchemaTitleByPath` 6 | -------------------------------------------------------------------------------- /.envrc: -------------------------------------------------------------------------------- 1 | use flake -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # build output 2 | dist/ 3 | .turbo/ 4 | .eslintcache 5 | .pnpm-store 6 | 7 | # generated types 8 | .astro/ 9 | .svelte-kit/ 10 | 11 | # dependencies 12 | node_modules/ 13 | 14 | # logs 15 | npm-debug.log* 16 | yarn-debug.log* 17 | yarn-error.log* 18 | pnpm-debug.log* 19 | 20 | # environment variables 21 | .env 22 | .env.production 23 | .direnv 24 | 25 | # macOS-specific files 26 | .DS_Store 27 | 28 | # jetbrains setting folder 29 | .idea/ 30 | 31 | *.tsbuildinfo 32 | *.log -------------------------------------------------------------------------------- /apps/docs2/.gitignore: -------------------------------------------------------------------------------- 1 | # build output 2 | dist/ 3 | # generated types 4 | .astro/ 5 | 6 | # dependencies 7 | node_modules/ 8 | 9 | # logs 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | pnpm-debug.log* 14 | 15 | 16 | # environment variables 17 | .env 18 | .env.production 19 | 20 | # macOS-specific files 21 | .DS_Store 22 | -------------------------------------------------------------------------------- /apps/docs2/.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": ["astro-build.astro-vscode"], 3 | "unwantedRecommendations": [] 4 | } 5 | -------------------------------------------------------------------------------- /apps/docs2/.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.2.0", 3 | "configurations": [ 4 | { 5 | "command": "./node_modules/.bin/astro dev", 6 | "name": "Development server", 7 | "request": "launch", 8 | "type": "node-terminal" 9 | } 10 | ] 11 | } 12 | -------------------------------------------------------------------------------- /apps/docs2/README.md: -------------------------------------------------------------------------------- 1 | # Docs 2 | -------------------------------------------------------------------------------- /apps/docs2/src/assets/houston.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/apps/docs2/src/assets/houston.webp -------------------------------------------------------------------------------- /apps/docs2/src/components/custom-head.astro: -------------------------------------------------------------------------------- 1 | --- 2 | import StarlightHead from "@astrojs/starlight/components/Head.astro"; 3 | import VtbotStarlight from "astro-vtbot/components/starlight/Base.astro"; 4 | import PageOffset from "astro-vtbot/components/PageOffset.astro"; 5 | --- 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /apps/docs2/src/components/declarative-shadow-dom.astro: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/apps/docs2/src/components/declarative-shadow-dom.astro -------------------------------------------------------------------------------- /apps/docs2/src/components/markdown-content.astro: -------------------------------------------------------------------------------- 1 | --- 2 | import Default from "@astrojs/starlight/components/MarkdownContent.astro"; 3 | 4 | const isChangelog = Astro.originPathname.startsWith("/changelogs/"); 5 | --- 6 | 7 | 8 | 9 | 10 | 11 | {isChangelog && } 16 | -------------------------------------------------------------------------------- /apps/docs2/src/components/my-form.svelte: -------------------------------------------------------------------------------- 1 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /apps/docs2/src/components/npm.astro: -------------------------------------------------------------------------------- 1 | --- 2 | import { PKG_MANGERS } from "@/shared"; 3 | import { 4 | PackageManagers, 5 | type PackageManagersProps, 6 | } from "starlight-package-managers"; 7 | 8 | export type Props = PackageManagersProps; 9 | --- 10 | 11 | 12 | -------------------------------------------------------------------------------- /apps/docs2/src/components/picker.astro: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 | 5 | 21 | -------------------------------------------------------------------------------- /apps/docs2/src/components/shadow/index.ts: -------------------------------------------------------------------------------- 1 | export { default as ShadowHost } from './host.svelte' 2 | -------------------------------------------------------------------------------- /apps/docs2/src/components/shadow/root.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | {@render children?.()} 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/config.ts: -------------------------------------------------------------------------------- 1 | import { defineCollection } from 'astro:content'; 2 | import { docsLoader } from '@astrojs/starlight/loaders'; 3 | import { docsSchema } from '@astrojs/starlight/schema'; 4 | 5 | export const collections = { 6 | docs: defineCollection({ schema: docsSchema(), loader: docsLoader() }), 7 | }; 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/_on-submit.ts: -------------------------------------------------------------------------------- 1 | export const onSubmit = () => window.alert("Thank you for your response!"); 2 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/ajv8-validator.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/ajv8-validator" 3 | --- 4 | 5 | import Changelog from '#/ajv8-validator/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/basic-theme.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/basic-theme" 3 | --- 4 | 5 | import Changelog from '#/basic-theme/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/cfworker-validator.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/cfworker-validator" 3 | --- 4 | 5 | import Changelog from '#/cfworker-validator/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/daisyui5-theme.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/daisyui5-theme" 3 | --- 4 | 5 | import Changelog from '#/daisyui5-theme/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/docs.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "docs" 3 | --- 4 | 5 | import Changelog from 'apps/docs2/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/flowbite-icons.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/flowbite-icons" 3 | --- 4 | 5 | import Changelog from '#/flowbite-icons/CHANGELOG.md' 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/flowbite3-theme.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/flowbite3-theme" 3 | --- 4 | 5 | import Changelog from '#/flowbite3-theme/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/form.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/form" 3 | --- 4 | 5 | import Changelog from '#/form/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/lucide-icons.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/lucide-icons" 3 | --- 4 | 5 | import Changelog from '#/lucide-icons/CHANGELOG.md' 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/moving-icons.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/moving-icons" 3 | --- 4 | 5 | import Changelog from '#/moving-icons/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/playground.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "playground" 3 | --- 4 | 5 | import Changelog from 'apps/playground2/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/radix-icons.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/radix-icons" 3 | --- 4 | 5 | import Changelog from '#/radix-icons/CHANGELOG.md' 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/shadcn4-theme.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/shadcn4-theme" 3 | --- 4 | 5 | import Changelog from '#/shadcn4-theme/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/skeleton3-theme.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/skeleton3-theme" 3 | --- 4 | 5 | import Changelog from '#/skeleton3-theme/CHANGELOG.md' 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/sveltekit.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/sveltekit" 3 | --- 4 | 5 | import Changelog from '#/sveltekit/CHANGELOG.md' 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/changelogs/zod-validator.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: "@sjsf/zod-validator" 3 | --- 4 | 5 | import Changelog from '#/zod-validator/CHANGELOG.md' 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/form/_extra-ui-options.ts: -------------------------------------------------------------------------------- 1 | import { fromRecord } from "@sjsf/form/lib/resolver"; 2 | 3 | import { createMyForm } from "@/components/my-form"; 4 | 5 | const form = createMyForm({ 6 | schema: {}, 7 | extraUiOptions: fromRecord({ 8 | titleAttributes: { 9 | style: "font-weight: bolder;", 10 | }, 11 | }), 12 | }); 13 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/form/translation.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Translation 3 | --- 4 | 5 | import { Code } from '@astrojs/starlight/components' 6 | 7 | import code from '#/form/src/form/translation?raw' 8 | 9 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/guides/_fields-validation.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 14 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/guides/_flowbite-icons-install.md: -------------------------------------------------------------------------------- 1 | Add icons content to the tailwindcss config: 2 | 3 | ```typescript 4 | import { FLOWBITE_ICONS_CONTENT } from '@sjsf/flowbite-icons/preset' 5 | 6 | /** @type {import('tailwindcss').Config} */ 7 | export default { 8 | content: ['./src/**/*.{html,js,svelte,ts}', FLOWBITE_ICONS_CONTENT], 9 | } 10 | ``` 11 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/guides/_focus-on-first-error.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 14 | -------------------------------------------------------------------------------- /apps/docs2/src/content/docs/guides/_icons.svelte: -------------------------------------------------------------------------------- 1 | 10 | 11 | 19 | -------------------------------------------------------------------------------- /apps/docs2/src/env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | -------------------------------------------------------------------------------- /apps/docs2/src/i18n.ts: -------------------------------------------------------------------------------- 1 | import { getAbsoluteLocaleUrl } from "astro:i18n"; 2 | 3 | export const DEFAULT_LOCALE = "en"; 4 | 5 | export const PLAYGROUND_LINK = getAbsoluteLocaleUrl( 6 | DEFAULT_LOCALE, 7 | "/../playground2/" 8 | ); 9 | -------------------------------------------------------------------------------- /apps/docs2/src/styles.css: -------------------------------------------------------------------------------- 1 | @view-transition { 2 | navigation: auto; 3 | } 4 | -------------------------------------------------------------------------------- /apps/docs2/src/web-ide/examples/animated-array.ts: -------------------------------------------------------------------------------- 1 | import animatedArraySvelte from "%/animated-array/src/routes/animated-array.svelte?raw"; 2 | import pageSvelte from "%/animated-array/src/routes/+page.svelte?raw"; 3 | 4 | import type { Layer } from "../layer"; 5 | 6 | export const layer = { 7 | files: { 8 | "src/routes/animated-array.svelte": animatedArraySvelte, 9 | "src/routes/+page.svelte": pageSvelte, 10 | }, 11 | } satisfies Layer; 12 | -------------------------------------------------------------------------------- /apps/docs2/src/web-ide/examples/pattern-properties-validator.ts: -------------------------------------------------------------------------------- 1 | import pageSvelte from "%/pattern-properties-validator/src/routes/+page.svelte?raw"; 2 | 3 | import type { Layer } from "../layer"; 4 | 5 | export const layer = { 6 | files: { 7 | "src/routes/+page.svelte": pageSvelte, 8 | }, 9 | } satisfies Layer; 10 | -------------------------------------------------------------------------------- /apps/docs2/src/web-ide/examples/starter.ts: -------------------------------------------------------------------------------- 1 | import sveltePage from "%/basic-starter/src/routes/+page.svelte?raw"; 2 | 3 | import type { Layer } from "../layer"; 4 | 5 | export const layer = { 6 | files: { 7 | "src/routes/+page.svelte": sveltePage, 8 | }, 9 | } satisfies Layer; 10 | -------------------------------------------------------------------------------- /apps/docs2/src/web-ide/layers/basic.ts: -------------------------------------------------------------------------------- 1 | import { dependencies } from "%/basic-starter/package.json"; 2 | 3 | import type { Layer } from "../layer"; 4 | 5 | export const layer = { 6 | package: { 7 | dependencies, 8 | }, 9 | formDefaults: { theme: "basic" }, 10 | } satisfies Layer; 11 | -------------------------------------------------------------------------------- /apps/docs2/src/web-ide/layers/daisyui5.ts: -------------------------------------------------------------------------------- 1 | import packageJson from "%/daisyui5-starter/package.json"; 2 | import appCss from "%/daisyui5-starter/src/app.css?raw"; 3 | 4 | import { omitBasePackages, type Layer } from "../layer"; 5 | 6 | export const layer = { 7 | package: omitBasePackages(packageJson), 8 | formDefaults: { theme: "daisyui5" }, 9 | files: { 10 | "src/app.css": appCss, 11 | }, 12 | } satisfies Layer; 13 | -------------------------------------------------------------------------------- /apps/docs2/src/web-ide/layers/flowbite3.ts: -------------------------------------------------------------------------------- 1 | import packageJson from "%/flowbite3-starter/package.json"; 2 | import appCss from "%/flowbite3-starter/src/app.css?raw"; 3 | 4 | import { omitBasePackages, type Layer } from "../layer"; 5 | 6 | export const layer = { 7 | package: omitBasePackages(packageJson), 8 | formDefaults: { theme: "flowbite3" }, 9 | files: { 10 | "src/app.css": appCss, 11 | }, 12 | } satisfies Layer; 13 | -------------------------------------------------------------------------------- /apps/playground2/components.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://next.shadcn-svelte.com/schema.json", 3 | "tailwind": { 4 | "css": "src/app.css", 5 | "baseColor": "neutral" 6 | }, 7 | "aliases": { 8 | "components": "$lib/components", 9 | "utils": "$lib/utils", 10 | "ui": "$lib/components/ui", 11 | "hooks": "$lib/hooks", 12 | "lib": "$lib" 13 | }, 14 | "typescript": true, 15 | "registry": "https://next.shadcn-svelte.com/registry" 16 | } 17 | -------------------------------------------------------------------------------- /apps/playground2/src/core/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./themes.js"; 2 | export * from "./sample.js"; 3 | export * from "./icons.js"; 4 | export * from "./resolvers.js"; 5 | export * from "./validators.js"; 6 | -------------------------------------------------------------------------------- /apps/playground2/src/core/resolvers.ts: -------------------------------------------------------------------------------- 1 | import { resolver as basic } from "@sjsf/form/resolvers/basic"; 2 | import { resolver as compat } from "@sjsf/form/resolvers/compat"; 3 | 4 | export const resolvers = { 5 | basic, 6 | compat, 7 | }; 8 | -------------------------------------------------------------------------------- /apps/playground2/src/core/validators.ts: -------------------------------------------------------------------------------- 1 | import { createFormValidator as ajv8 } from "@sjsf/ajv8-validator"; 2 | import { createFormValidator as cfworker } from "@sjsf/cfworker-validator"; 3 | import { createFormValidator as schemasafe } from "@sjsf/schemasafe-validator"; 4 | 5 | export const validators = { 6 | ajv8, 7 | cfworker, 8 | schemasafe, 9 | }; 10 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/button/index.ts: -------------------------------------------------------------------------------- 1 | import Root, { 2 | type ButtonProps, 3 | type ButtonSize, 4 | type ButtonVariant, 5 | buttonVariants, 6 | } from "./button.svelte"; 7 | 8 | export { 9 | Root, 10 | type ButtonProps as Props, 11 | // 12 | Root as Button, 13 | buttonVariants, 14 | type ButtonProps, 15 | type ButtonSize, 16 | type ButtonVariant, 17 | }; 18 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/checkbox/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./checkbox.svelte"; 2 | export { 3 | Root, 4 | // 5 | Root as Checkbox, 6 | }; 7 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/dialog/dialog-close.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/dialog/dialog-trigger.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/label/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./label.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Label, 7 | }; 8 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/popover/popover-trigger.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 18 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/select/select-group.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /apps/playground2/src/lib/components/ui/separator/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./separator.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Separator, 7 | }; 8 | -------------------------------------------------------------------------------- /apps/playground2/src/main.ts: -------------------------------------------------------------------------------- 1 | import { mount } from "svelte"; 2 | 3 | import App from "./app.svelte"; 4 | import "./app.css"; 5 | 6 | mount(App, { target: document.getElementById("app")! }); 7 | -------------------------------------------------------------------------------- /apps/playground2/src/samples/single.ts: -------------------------------------------------------------------------------- 1 | import type { Sample } from '@/core/index.js'; 2 | 3 | export default { 4 | 5 | schema: { 6 | title: 'A single-field form', 7 | type: 'string', 8 | }, 9 | initialValue: 'initial value', 10 | uiSchema: {}, 11 | } satisfies Sample; 12 | -------------------------------------------------------------------------------- /apps/playground2/src/shadow/index.ts: -------------------------------------------------------------------------------- 1 | export { default as ShadowHost } from './host.svelte' 2 | -------------------------------------------------------------------------------- /apps/playground2/src/shadow/root.svelte: -------------------------------------------------------------------------------- 1 | 9 | 10 | {@render children(shadowRoot)} 11 | -------------------------------------------------------------------------------- /apps/playground2/src/shared/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./theme.js"; 2 | -------------------------------------------------------------------------------- /apps/playground2/src/shared/theme.ts: -------------------------------------------------------------------------------- 1 | export enum Theme { 2 | System = "system", 3 | Light = "light", 4 | Dark = "dark", 5 | } 6 | 7 | export const THEME_TITLES: Record = { 8 | [Theme.System]: "System", 9 | [Theme.Light]: "Light", 10 | [Theme.Dark]: "Dark", 11 | } 12 | 13 | export const THEMES = Object.values(Theme); 14 | 15 | export type DarkOrLight = Theme.Dark | Theme.Light; 16 | -------------------------------------------------------------------------------- /apps/playground2/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | -------------------------------------------------------------------------------- /apps/playground2/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { resolve } from "node:path"; 2 | import { defineConfig } from "vite"; 3 | import tailwindcss from "@tailwindcss/vite"; 4 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 5 | 6 | export default defineConfig({ 7 | base: "/svelte-jsonschema-form/playground2/", 8 | plugins: [tailwindcss(), svelte()], 9 | resolve: { 10 | alias: { "@": resolve(__dirname, "./src"), $lib: resolve("./src/lib") }, 11 | }, 12 | }); 13 | -------------------------------------------------------------------------------- /examples/animated-array/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/animated-array/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/animated-array/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/animated-array/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/animated-array/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/animated-array/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/animated-array/static/favicon.png -------------------------------------------------------------------------------- /examples/animated-array/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /examples/async-combobox/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/async-combobox/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/async-combobox/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/async-combobox/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/async-combobox/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/async-combobox/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/async-combobox/static/favicon.png -------------------------------------------------------------------------------- /examples/async-combobox/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /examples/basic-starter/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/basic-starter/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/basic-starter/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/basic-starter/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/basic-starter/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/basic-starter/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/basic-starter/static/favicon.png -------------------------------------------------------------------------------- /examples/basic-starter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/src/app.css: -------------------------------------------------------------------------------- 1 | @import "tailwindcss"; 2 | 3 | /* Workaround for StackBlitz, use @source in production */ 4 | @import "@sjsf/daisyui5-theme/styles.css"; 5 | /* @source "../node_modules/@sjsf/daisyui5-theme/dist"; */ 6 | 7 | @plugin "daisyui"; 8 | 9 | html { 10 | padding: 2rem; 11 | } 12 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/daisyui5-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/daisyui5-starter/src/routes/+layout.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | {@render children()} 8 | -------------------------------------------------------------------------------- /examples/daisyui5-starter/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/daisyui5-starter/static/favicon.png -------------------------------------------------------------------------------- /examples/daisyui5-starter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import tailwindcss from '@tailwindcss/vite'; 2 | import { sveltekit } from '@sveltejs/kit/vite'; 3 | import { defineConfig } from 'vite'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()] 7 | }); 8 | -------------------------------------------------------------------------------- /examples/flowbite3-starter/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/flowbite3-starter/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/flowbite3-starter/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/flowbite3-starter/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/flowbite3-starter/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/flowbite3-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/flowbite3-starter/src/routes/+layout.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | {@render children()} 8 | -------------------------------------------------------------------------------- /examples/flowbite3-starter/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/flowbite3-starter/static/favicon.png -------------------------------------------------------------------------------- /examples/flowbite3-starter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import tailwindcss from '@tailwindcss/vite'; 2 | import { sveltekit } from '@sveltejs/kit/vite'; 3 | import { defineConfig } from 'vite'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()] 7 | }); 8 | -------------------------------------------------------------------------------- /examples/formulas/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/formulas/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/formulas/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/formulas/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/formulas/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/formulas/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/formulas/static/favicon.png -------------------------------------------------------------------------------- /examples/formulas/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /examples/markdown-description/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/markdown-description/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/markdown-description/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/markdown-description/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/markdown-description/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/markdown-description/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/markdown-description/static/favicon.png -------------------------------------------------------------------------------- /examples/markdown-description/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /examples/pattern-properties-validator/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/pattern-properties-validator/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/pattern-properties-validator/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/pattern-properties-validator/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/pattern-properties-validator/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/pattern-properties-validator/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/pattern-properties-validator/static/favicon.png -------------------------------------------------------------------------------- /examples/pattern-properties-validator/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/components.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://next.shadcn-svelte.com/schema.json", 3 | "tailwind": { 4 | "css": "src/app.css", 5 | "baseColor": "zinc" 6 | }, 7 | "aliases": { 8 | "components": "$lib/components", 9 | "utils": "$lib/utils", 10 | "ui": "$lib/components/ui", 11 | "hooks": "$lib/hooks", 12 | "lib": "$lib" 13 | }, 14 | "typescript": true, 15 | "registry": "https://next.shadcn-svelte.com/registry" 16 | } 17 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/shadcn4-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/shadcn4-starter/src/routes/+layout.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | {@render children()} 13 | -------------------------------------------------------------------------------- /examples/shadcn4-starter/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/shadcn4-starter/static/favicon.png -------------------------------------------------------------------------------- /examples/shadcn4-starter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import tailwindcss from '@tailwindcss/vite'; 2 | import { sveltekit } from '@sveltejs/kit/vite'; 3 | import { defineConfig } from 'vite'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()] 7 | }); 8 | -------------------------------------------------------------------------------- /examples/skeleton3-starter/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/skeleton3-starter/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/skeleton3-starter/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/skeleton3-starter/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/skeleton3-starter/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/skeleton3-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/skeleton3-starter/src/routes/+layout.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | {@render children()} 8 | -------------------------------------------------------------------------------- /examples/skeleton3-starter/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/skeleton3-starter/static/favicon.png -------------------------------------------------------------------------------- /examples/skeleton3-starter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import tailwindcss from '@tailwindcss/vite'; 2 | import { sveltekit } from '@sveltejs/kit/vite'; 3 | import { defineConfig } from 'vite'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()] 7 | }); 8 | -------------------------------------------------------------------------------- /examples/tabbed-layout/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | .netlify 7 | .wrangler 8 | /.svelte-kit 9 | /build 10 | 11 | # OS 12 | .DS_Store 13 | Thumbs.db 14 | 15 | # Env 16 | .env 17 | .env.* 18 | !.env.example 19 | !.env.test 20 | 21 | # Vite 22 | vite.config.js.timestamp-* 23 | vite.config.ts.timestamp-* 24 | -------------------------------------------------------------------------------- /examples/tabbed-layout/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /examples/tabbed-layout/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /examples/tabbed-layout/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/tabbed-layout/src/lib/form-defaults.ts: -------------------------------------------------------------------------------- 1 | export { resolver } from "@sjsf/form/resolvers/basic"; 2 | 3 | export { theme } from "@sjsf/basic-theme"; 4 | 5 | export { translation } from "@sjsf/form/translations/en"; 6 | 7 | import { createFormValidator } from "@sjsf/ajv8-validator"; 8 | 9 | // NOTE: One validator will be used for all forms 10 | export const validator = createFormValidator(); -------------------------------------------------------------------------------- /examples/tabbed-layout/src/lib/tabs/index.ts: -------------------------------------------------------------------------------- 1 | export * from './context.svelte' 2 | export * from './focus' 3 | export * from './schema' 4 | export { default as Layout } from './layout.svelte' 5 | -------------------------------------------------------------------------------- /examples/tabbed-layout/src/lib/tabs/tab.svelte: -------------------------------------------------------------------------------- 1 | 11 | -------------------------------------------------------------------------------- /examples/tabbed-layout/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 9 | 10 | 14 | 15 |
16 | -------------------------------------------------------------------------------- /examples/tabbed-layout/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/examples/tabbed-layout/static/favicon.png -------------------------------------------------------------------------------- /examples/tabbed-layout/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vite'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()] 6 | }); 7 | -------------------------------------------------------------------------------- /packages/ajv8-validator/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./model.js"; 2 | export * from "./schema-compilers.js"; 3 | export * from "./validator.js"; 4 | -------------------------------------------------------------------------------- /packages/ajv8-validator/src/precompile/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./validator.js"; 2 | -------------------------------------------------------------------------------- /packages/ajv8-validator/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@total-typescript/tsconfig/tsc/no-dom/library", 3 | "compilerOptions": { 4 | "moduleResolution": "NodeNext", 5 | "outDir": "dist", 6 | "rootDir": "src", 7 | "sourceMap": false 8 | }, 9 | "exclude": [ 10 | "vitest.config.ts", 11 | "dist", 12 | "node_modules" 13 | ] 14 | } -------------------------------------------------------------------------------- /packages/ajv8-validator/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vitest/config'; 2 | 3 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 4 | 5 | export default defineConfig({ 6 | plugins: [svelte()], 7 | }); 8 | -------------------------------------------------------------------------------- /packages/basic-theme/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Basic theme 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /packages/basic-theme/src/app.svelte: -------------------------------------------------------------------------------- 1 | 7 | 8 | 12 | -------------------------------------------------------------------------------- /packages/basic-theme/src/app.ts: -------------------------------------------------------------------------------- 1 | import { mount } from "svelte"; 2 | 3 | import App from "./app.svelte"; 4 | 5 | const target = document.getElementById("app"); 6 | 7 | export default mount(App, { target: target! }); 8 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/checkboxes-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import Checkboxes from "./checkboxes.svelte"; 4 | import "./checkboxes.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | checkboxesWidget: {} 9 | } 10 | } 11 | 12 | definitions.checkboxesWidget = Checkboxes; 13 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/date-picker-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import DatePicker from "./date-picker.svelte"; 4 | import "./date-picker.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | datePickerWidget: {}; 9 | } 10 | } 11 | 12 | definitions.datePickerWidget = DatePicker; 13 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/file-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import File from "./file.svelte"; 4 | import "./file.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | fileWidget: {}; 9 | } 10 | } 11 | 12 | definitions.fileWidget = File; 13 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/multi-select-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import MultiSelect from "./multi-select.svelte"; 4 | import "./multi-select.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | multiSelectWidget: {}; 9 | } 10 | } 11 | 12 | definitions.multiSelectWidget = MultiSelect; 13 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/radio-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import Radio from "./radio.svelte"; 4 | import "./radio.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | radioWidget: {}; 9 | } 10 | } 11 | 12 | 13 | definitions.radioWidget = Radio; 14 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/range-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import Range from "./range.svelte"; 4 | import "./range.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | rangeWidget: {}; 9 | } 10 | } 11 | 12 | definitions.rangeWidget = Range; 13 | -------------------------------------------------------------------------------- /packages/basic-theme/src/extra-widgets/textarea-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import Textarea from "./textarea.svelte"; 4 | import "./textarea.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | textareaWidget: {}; 9 | } 10 | } 11 | 12 | definitions.textareaWidget = Textarea; 13 | -------------------------------------------------------------------------------- /packages/basic-theme/src/index.ts: -------------------------------------------------------------------------------- 1 | import { extendByRecord } from "@sjsf/form/lib/resolver"; 2 | import { fields } from "@sjsf/form/fields/resolver"; 3 | 4 | import { definitions } from "./definitions.js"; 5 | 6 | export const theme = extendByRecord(fields, definitions); 7 | -------------------------------------------------------------------------------- /packages/basic-theme/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// -------------------------------------------------------------------------------- /packages/basic-theme/src/widgets/exports.ts: -------------------------------------------------------------------------------- 1 | export { default as textWidget } from "./text.svelte"; 2 | export { default as numberWidget } from "./number.svelte"; 3 | export { default as selectWidget } from "./select.svelte"; 4 | export { default as checkboxWidget } from "./checkbox.svelte"; 5 | -------------------------------------------------------------------------------- /packages/basic-theme/vite.config.ts: -------------------------------------------------------------------------------- 1 | /// 2 | import { resolve } from "node:path"; 3 | 4 | import { defineConfig } from "vite"; 5 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | plugins: [svelte()], 10 | resolve: { 11 | alias: { 12 | "@": resolve(__dirname, "src"), 13 | }, 14 | }, 15 | }); 16 | -------------------------------------------------------------------------------- /packages/cfworker-validator/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./validator.svelte.js"; 2 | -------------------------------------------------------------------------------- /packages/cfworker-validator/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@total-typescript/tsconfig/tsc/dom/library", 3 | "compilerOptions": { 4 | "moduleResolution": "NodeNext", 5 | "outDir": "dist", 6 | "rootDir": "src", 7 | "sourceMap": false 8 | }, 9 | "exclude": [ 10 | "vitest.config.ts", 11 | "dist", 12 | "node_modules" 13 | ] 14 | } -------------------------------------------------------------------------------- /packages/cfworker-validator/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vitest/config'; 2 | 3 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 4 | 5 | export default defineConfig({ 6 | plugins: [svelte()], 7 | }); 8 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/app.css: -------------------------------------------------------------------------------- 1 | @import "tailwindcss"; 2 | @plugin "daisyui"; 3 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/components/help.svelte: -------------------------------------------------------------------------------- 1 | 9 | 10 |

11 | {help} 12 |

13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/cally-date-picker-include.ts: -------------------------------------------------------------------------------- 1 | import { clientOnly } from '@sjsf/form/lib/env'; 2 | 3 | import { definitions } from '../definitions.js'; 4 | 5 | export type * as __preserveCallyTypes from './cally-date-picker.svelte'; 6 | 7 | declare module "../definitions.js" { 8 | interface ExtraWidgets { 9 | datePickerWidget: {} 10 | } 11 | } 12 | 13 | definitions.datePickerWidget = clientOnly(() => import('./cally-date-picker.svelte')); 14 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/checkboxes-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Checkboxes from './checkboxes.svelte'; 4 | import './checkboxes.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | checkboxesWidget: {}; 9 | } 10 | } 11 | 12 | definitions.checkboxesWidget = Checkboxes; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/file-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import File from "./file.svelte"; 4 | import "./file.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | fileWidget: {} 9 | } 10 | } 11 | 12 | 13 | 14 | definitions.fileWidget = File; 15 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/filter-radio-buttons-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import RadioButtons from './filter-radio-buttons.svelte'; 4 | import './filter-radio-buttons.svelte'; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | radioButtonsWidget: {} 9 | } 10 | } 11 | 12 | 13 | 14 | definitions.radioButtonsWidget = RadioButtons; 15 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/multi-select-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import MultiSelect from './multi-select.svelte'; 4 | import './multi-select.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | multiSelectWidget: {}; 9 | } 10 | } 11 | 12 | definitions.multiSelectWidget = MultiSelect; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/pikaday-date-picker-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import PikadayDatePicker from './pikaday-date-picker.svelte'; 4 | import './pikaday-date-picker.svelte'; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | datePickerWidget: {} 9 | } 10 | } 11 | 12 | definitions.datePickerWidget = PikadayDatePicker 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/radio-buttons-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import RadioButtons from './radio-buttons.svelte'; 4 | import './radio-buttons.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioButtonsWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioButtonsWidget = RadioButtons; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/radio-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import Radio from "./radio.svelte"; 4 | import "./radio.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | radioWidget: {} 9 | } 10 | } 11 | 12 | definitions.radioWidget = Radio; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/range-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Range from './range.svelte'; 4 | import './range.svelte'; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | rangeWidget: {} 9 | } 10 | } 11 | 12 | definitions.rangeWidget = Range; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/rating-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Rating from './rating.svelte'; 4 | import './rating.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | ratingWidget: {}; 9 | } 10 | } 11 | 12 | definitions.ratingWidget = Rating; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/switch-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Switch from './switch.svelte'; 4 | import './switch.svelte'; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | switchWidget: {} 9 | } 10 | } 11 | 12 | definitions.switchWidget = Switch; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/extra-widgets/textarea-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import Textarea from "./textarea.svelte"; 4 | import "./textarea.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | textareaWidget: {} 9 | } 10 | } 11 | 12 | definitions.textareaWidget = Textarea; 13 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/index.ts: -------------------------------------------------------------------------------- 1 | import { extendByRecord } from '@sjsf/form/lib/resolver'; 2 | import { fields } from '@sjsf/form/fields/resolver'; 3 | 4 | import { definitions } from './definitions.js'; 5 | 6 | export const theme = extendByRecord(fields, definitions); 7 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/lib/widgets/exports.ts: -------------------------------------------------------------------------------- 1 | export { default as textWidget } from './text.svelte'; 2 | export { default as numberWidget } from './number.svelte'; 3 | export { default as selectWidget } from './select.svelte'; 4 | export { default as checkboxWidget } from './checkbox.svelte'; 5 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/daisyui5-theme/static/favicon.png -------------------------------------------------------------------------------- /packages/daisyui5-theme/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/daisyui5-theme/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "NodeNext", 14 | } 15 | } -------------------------------------------------------------------------------- /packages/daisyui5-theme/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | 4 | import tailwindcss from '@tailwindcss/vite'; 5 | 6 | export default defineConfig({ 7 | plugins: [ 8 | tailwindcss(), 9 | sveltekit() 10 | ], 11 | test: { 12 | include: ['src/**/*.{test,spec}.{js,ts}'] 13 | } 14 | }); 15 | -------------------------------------------------------------------------------- /packages/flowbite-icons/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/flowbite-icons/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/flowbite-icons/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/flowbite-icons/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/flowbite-icons/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/flowbite-icons/src/app.css: -------------------------------------------------------------------------------- 1 | @import 'tailwindcss'; 2 | 3 | @custom-variant dark (&:where(.dark, .dark *)); 4 | 5 | @source "../node_modules/flowbite-svelte-icons/dist"; 6 | -------------------------------------------------------------------------------- /packages/flowbite-icons/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/flowbite-icons/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/flowbite-icons/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/flowbite-icons/src/lib/preset.ts: -------------------------------------------------------------------------------- 1 | import type { Config } from 'tailwindcss'; 2 | 3 | export const APP_CONTENT = './src/**/*.{html,js,svelte,ts}'; 4 | export const FLOWBITE_ICONS_CONTENT = 5 | './node_modules/flowbite-svelte-icons/**/*.{html,js,svelte,ts}'; 6 | 7 | export default { 8 | content: [APP_CONTENT, FLOWBITE_ICONS_CONTENT] 9 | } satisfies Config; 10 | -------------------------------------------------------------------------------- /packages/flowbite-icons/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /packages/flowbite-icons/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/flowbite-icons/static/favicon.png -------------------------------------------------------------------------------- /packages/flowbite-icons/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/flowbite-icons/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "Preserve", 13 | "moduleResolution": "Bundler" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/flowbite-icons/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | import tailwindcss from '@tailwindcss/vite'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()], 7 | test: { 8 | include: ['src/**/*.{test,spec}.{js,ts}'] 9 | } 10 | }); 11 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/App.svelte: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/checkboxes-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Checkboxes from './checkboxes.svelte'; 4 | import './checkboxes.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | checkboxesWidget: {}; 9 | } 10 | } 11 | 12 | definitions.checkboxesWidget = Checkboxes; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/date-picker-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import DatePicker from './date-picker.svelte'; 4 | import './date-picker.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | datePickerWidget: {}; 9 | } 10 | } 11 | 12 | definitions.datePickerWidget = DatePicker; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/file-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../definitions.js"; 2 | 3 | import File from "./file.svelte"; 4 | import "./file.svelte"; 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | fileWidget: {} 9 | } 10 | } 11 | 12 | definitions.fileWidget = File; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/multi-select-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import MultiSelect from './multi-select.svelte'; 4 | import './multi-select.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | multiSelectWidget: {}; 9 | } 10 | } 11 | 12 | definitions.multiSelectWidget = MultiSelect; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/radio-buttons-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import RadioButtons from './radio-buttons.svelte'; 4 | import './radio-buttons.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioButtonsWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioButtonsWidget = RadioButtons; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/radio-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Radio from './radio.svelte'; 4 | import './radio.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioWidget = Radio; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/range-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import Range from './range.svelte'; 4 | import './range.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | rangeWidget: {}; 9 | } 10 | } 11 | 12 | definitions.rangeWidget = Range; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/switch-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import Switch from './switch.svelte'; 4 | import './switch.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | switchWidget: {}; 9 | } 10 | } 11 | 12 | definitions.switchWidget = Switch; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/tags-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import Tags from './tags.svelte'; 4 | import './tags.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | tagsWidget: {}; 9 | } 10 | } 11 | 12 | definitions.tagsWidget = Tags; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/extra-widgets/textarea-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Textarea from './textarea.svelte'; 4 | import './textarea.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | textareaWidget: {}; 9 | } 10 | } 11 | 12 | definitions.textareaWidget = Textarea; 13 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/index.ts: -------------------------------------------------------------------------------- 1 | import { extendByRecord } from '@sjsf/form/lib/resolver'; 2 | import { fields } from '@sjsf/form/fields/resolver'; 3 | 4 | import { definitions } from './definitions'; 5 | 6 | export const theme = extendByRecord(fields, definitions); 7 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/lib/widgets/exports.ts: -------------------------------------------------------------------------------- 1 | export { default as textWidget } from './text.svelte'; 2 | export { default as numberWidget } from './number.svelte'; 3 | export { default as selectWidget } from './select.svelte'; 4 | export { default as checkboxWidget } from './checkbox.svelte'; 5 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/flowbite3-theme/static/favicon.png -------------------------------------------------------------------------------- /packages/flowbite3-theme/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "Preserve", 13 | "moduleResolution": "Bundler" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/flowbite3-theme/vite.config.ts: -------------------------------------------------------------------------------- 1 | import tailwindcss from '@tailwindcss/vite'; 2 | import { sveltekit } from '@sveltejs/kit/vite'; 3 | import { defineConfig } from 'vitest/config'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()], 7 | test: { include: ['src/**/*.{test,spec}.{js,ts}'] } 8 | }); 9 | -------------------------------------------------------------------------------- /packages/form/src/core/enum-option.ts: -------------------------------------------------------------------------------- 1 | import type { Schema } from './schema.js'; 2 | 3 | export interface SimpleEnumOption { 4 | id: string; 5 | value: T; 6 | label: string; 7 | disabled: boolean; 8 | } 9 | 10 | export interface ComplexEnumOption extends SimpleEnumOption { 11 | schema: Schema; 12 | } 13 | 14 | export type EnumOption = SimpleEnumOption | ComplexEnumOption; 15 | -------------------------------------------------------------------------------- /packages/form/src/core/is-additional-property.ts: -------------------------------------------------------------------------------- 1 | import { ADDITIONAL_PROPERTY_FLAG, type Schema } from "./schema.js"; 2 | 3 | export function isAdditionalProperty( 4 | properties: Exclude, 5 | property: string 6 | ) { 7 | const propertySchema = properties[property]; 8 | if (typeof propertySchema === "boolean" || !propertySchema) { 9 | return false; 10 | } 11 | return ADDITIONAL_PROPERTY_FLAG in propertySchema; 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/core/traverser.ts: -------------------------------------------------------------------------------- 1 | export interface Visitor { 2 | onEnter?: (node: Node, ctx: Context) => Generator; 3 | onLeave?: (node: Node, ctx: Context) => Generator; 4 | } 5 | -------------------------------------------------------------------------------- /packages/form/src/core/validator.ts: -------------------------------------------------------------------------------- 1 | import type { Schema, SchemaDefinition, SchemaValue } from "./schema.js"; 2 | 3 | export interface Validator { 4 | isValid( 5 | schema: SchemaDefinition, 6 | rootSchema: Schema, 7 | formValue: SchemaValue | undefined 8 | ): boolean; 9 | } 10 | -------------------------------------------------------------------------------- /packages/form/src/fields/array/exports.ts: -------------------------------------------------------------------------------- 1 | import "./ui-options.js"; 2 | 3 | export type * from "./model.js"; 4 | 5 | export { default as arrayField } from "./array-field.svelte"; 6 | export { default as tupleField } from "./tuple-field.svelte"; 7 | export { default as arrayItemField } from "./array-item-field.svelte"; 8 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-fields/boolean-select-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../resolver/definitions.js"; 2 | 3 | import BooleanSelect from "./boolean-select.svelte"; 4 | import "./boolean-select.svelte"; 5 | 6 | declare module "../resolver/definitions.js" { 7 | interface ExtraFields { 8 | booleanSelectField: {}; 9 | } 10 | } 11 | 12 | definitions.booleanSelectField = BooleanSelect; 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-fields/enum-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../resolver/definitions.js"; 2 | 3 | import Enum from "./enum.svelte"; 4 | import "./enum.svelte"; 5 | 6 | declare module "../resolver/definitions.js" { 7 | interface ExtraFields { 8 | enumField: {}; 9 | } 10 | } 11 | 12 | definitions.enumField = Enum; 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-fields/file-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../resolver/definitions.js"; 2 | 3 | import File from "./file.svelte"; 4 | import "./file.svelte"; 5 | 6 | declare module "../resolver/definitions.js" { 7 | interface ExtraFields { 8 | fileField: {}; 9 | } 10 | } 11 | 12 | definitions.fileField = File; 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-fields/files-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../resolver/definitions.js"; 2 | 3 | import Files from "./files.svelte"; 4 | import "./files.svelte"; 5 | 6 | declare module "../resolver/definitions.js" { 7 | interface ExtraFields { 8 | filesField: {}; 9 | } 10 | } 11 | 12 | definitions.filesField = Files; 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-fields/multi-enum-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../resolver/definitions.js"; 2 | 3 | import MultiEnum from "./multi-enum.svelte"; 4 | import "./multi-enum.svelte"; 5 | 6 | declare module "../resolver/definitions.js" { 7 | interface ExtraFields { 8 | multiEnumField: {}; 9 | } 10 | } 11 | 12 | definitions.multiEnumField = MultiEnum; 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-fields/tags-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from "../resolver/definitions.js"; 2 | 3 | import Tags from "./tags.svelte"; 4 | import "./tags.svelte"; 5 | 6 | declare module "../resolver/definitions.js" { 7 | interface ExtraFields { 8 | tagsField: {}; 9 | } 10 | } 11 | 12 | definitions.tagsField = Tags 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/checkboxes.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaArrayValue } from "@/core/index.js"; 2 | 3 | import type { Options, WidgetCommonProps } from "../widgets.js"; 4 | 5 | declare module "../../form/index.js" { 6 | interface ComponentProps { 7 | checkboxesWidget: WidgetCommonProps & Options; 8 | } 9 | interface ComponentBindings { 10 | checkboxesWidget: "value"; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/combobox.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaValue } from "@/core/index.js"; 2 | 3 | import type { Options, WidgetCommonProps } from "../widgets.js"; 4 | 5 | declare module "../../form/index.js" { 6 | interface ComponentProps { 7 | comboboxWidget: WidgetCommonProps & Options; 8 | } 9 | interface ComponentBindings { 10 | comboboxWidget: "value"; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/file.ts: -------------------------------------------------------------------------------- 1 | import type { WidgetCommonProps } from "../widgets.js"; 2 | 3 | declare module "../../form/index.js" { 4 | interface ComponentProps { 5 | fileWidget: WidgetCommonProps & { 6 | multiple: boolean; 7 | loading: boolean; 8 | processing: boolean; 9 | }; 10 | } 11 | interface ComponentBindings { 12 | fileWidget: "value"; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/multi-select.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaArrayValue } from "@/core/index.js"; 2 | 3 | import type { Options, WidgetCommonProps } from "../widgets.js"; 4 | 5 | declare module "../../form/index.js" { 6 | interface ComponentProps { 7 | multiSelectWidget: WidgetCommonProps & Options; 8 | } 9 | interface ComponentBindings { 10 | multiSelectWidget: "value"; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/radio-buttons.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaValue } from "@/form/index.js"; 2 | 3 | import type { Options, WidgetCommonProps } from "../widgets.js"; 4 | 5 | declare module "../../form/index.js" { 6 | interface ComponentProps { 7 | radioButtonsWidget: WidgetCommonProps & Options; 8 | } 9 | interface ComponentBindings { 10 | radioButtonsWidget: "value"; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/radio.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaValue } from "@/form/index.js"; 2 | 3 | import type { Options, WidgetCommonProps } from "../widgets.js"; 4 | 5 | declare module "../../form/index.js" { 6 | interface ComponentProps { 7 | radioWidget: WidgetCommonProps & Options; 8 | } 9 | interface ComponentBindings { 10 | radioWidget: "value"; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/range.ts: -------------------------------------------------------------------------------- 1 | import type { WidgetCommonProps } from "../widgets.js"; 2 | 3 | declare module "../../form/index.js" { 4 | interface ComponentProps { 5 | rangeWidget: WidgetCommonProps; 6 | } 7 | interface ComponentBindings { 8 | rangeWidget: "value"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/rating.ts: -------------------------------------------------------------------------------- 1 | import type { WidgetCommonProps } from "../widgets.js"; 2 | 3 | declare module "../../form/index.js" { 4 | interface ComponentProps { 5 | ratingWidget: WidgetCommonProps; 6 | } 7 | interface ComponentBindings { 8 | ratingWidget: "value"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/tags.ts: -------------------------------------------------------------------------------- 1 | import type { WidgetCommonProps } from "../widgets.js"; 2 | 3 | declare module "../../form/index.js" { 4 | interface ComponentProps { 5 | tagsWidget: WidgetCommonProps 6 | } 7 | interface ComponentBindings { 8 | tagsWidget: "value"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/form/src/fields/extra-widgets/textarea.ts: -------------------------------------------------------------------------------- 1 | import type { WidgetCommonProps } from "../widgets.js"; 2 | 3 | declare module "../../form/index.js" { 4 | interface ComponentProps { 5 | textareaWidget: WidgetCommonProps; 6 | } 7 | interface ComponentBindings { 8 | textareaWidget: "value"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/form/src/fields/object/exports.ts: -------------------------------------------------------------------------------- 1 | import "./ui-options.js"; 2 | 3 | export type * from "./model.js"; 4 | 5 | export { default as objectField } from "./object-field.svelte"; 6 | export { default as objectPropertyField } from "./object-property-field.svelte"; 7 | -------------------------------------------------------------------------------- /packages/form/src/fields/resolver/definitions.ts: -------------------------------------------------------------------------------- 1 | import type { ComponentDefinitions } from "@/form/index.js"; 2 | 3 | import * as fields from "../exports.js"; 4 | 5 | export interface ExtraFields {} 6 | 7 | export const definitions = Object.assign( 8 | {}, 9 | fields 10 | ) satisfies Partial as typeof fields & 11 | Pick; 12 | -------------------------------------------------------------------------------- /packages/form/src/fields/resolver/index.ts: -------------------------------------------------------------------------------- 1 | import { fromRecord } from "@/lib/resolver.js"; 2 | 3 | import "../exports.js"; 4 | 5 | import { definitions } from "./definitions.js"; 6 | 7 | export const fields = fromRecord(definitions); 8 | -------------------------------------------------------------------------------- /packages/form/src/form/config.ts: -------------------------------------------------------------------------------- 1 | import type { Schema } from "@/core/index.js"; 2 | 3 | import type { Id } from "./id.js"; 4 | import type { UiSchema } from "./ui-schema.js"; 5 | 6 | export interface Config { 7 | id: Id; 8 | name: string; 9 | title: string; 10 | schema: Schema; 11 | uiSchema: UiSchema; 12 | required: boolean; 13 | } 14 | -------------------------------------------------------------------------------- /packages/form/src/form/content.module.ts: -------------------------------------------------------------------------------- 1 | declare module "./ui-schema.js" { 2 | interface UiOptions { 3 | /** 4 | * Overrides the title of the field. 5 | */ 6 | title?: string; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /packages/form/src/form/context/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./context.js"; 2 | export * from "./schema.js"; 3 | export * from "./ui-schema.js"; 4 | export * from "./validation.js"; 5 | export * from "./event-handlers.svelte.js"; 6 | export * from "./attributes.js"; 7 | export * from "./files.js"; 8 | export * from "./components.js"; 9 | -------------------------------------------------------------------------------- /packages/form/src/form/error-message.svelte: -------------------------------------------------------------------------------- 1 | 10 | 11 | 14 | 15 |
{message}
16 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/boolean-select.ts: -------------------------------------------------------------------------------- 1 | import type { FieldCommonProps } from "../fields.js"; 2 | 3 | declare module "../components.js" { 4 | interface ComponentProps { 5 | booleanSelectField: FieldCommonProps; 6 | } 7 | interface ComponentBindings { 8 | booleanSelectField: "value"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/date-field.ts: -------------------------------------------------------------------------------- 1 | import type { FieldCommonProps } from "../fields.js"; 2 | 3 | declare module "../components.js" { 4 | interface FoundationalComponents { 5 | dateField: {}; 6 | } 7 | interface ComponentProps { 8 | dateField: FieldCommonProps; 9 | } 10 | interface ComponentBindings { 11 | dateField: "value"; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/enum.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaValue } from '@/core/index.js'; 2 | 3 | import type { FieldCommonProps } from "../fields.js"; 4 | 5 | declare module "../components.js" { 6 | interface FoundationalComponents { 7 | enumField: {} 8 | } 9 | interface ComponentProps { 10 | enumField: FieldCommonProps; 11 | } 12 | interface ComponentBindings { 13 | enumField: "value"; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/file.ts: -------------------------------------------------------------------------------- 1 | import type { FieldCommonProps } from "../fields.js"; 2 | 3 | declare module "../components.js" { 4 | interface FoundationalComponents { 5 | fileField: {} 6 | } 7 | interface ComponentProps { 8 | fileField: FieldCommonProps; 9 | } 10 | interface ComponentBindings { 11 | fileField: "value"; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/files.ts: -------------------------------------------------------------------------------- 1 | import type { FieldCommonProps } from "../fields.js"; 2 | 3 | declare module "../components.js" { 4 | interface FoundationalComponents { 5 | filesField: {} 6 | } 7 | interface ComponentProps { 8 | filesField: FieldCommonProps; 9 | } 10 | interface ComponentBindings { 11 | filesField: "value"; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/multi-enum.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaArrayValue } from "@/core/schema.js"; 2 | 3 | import type { FieldCommonProps } from "../fields.js"; 4 | 5 | declare module "../components.js" { 6 | interface FoundationalComponents { 7 | multiEnumField: {} 8 | } 9 | interface ComponentProps { 10 | multiEnumField: FieldCommonProps; 11 | } 12 | interface ComponentBindings { 13 | multiEnumField: "value"; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/form/src/form/extra-fields/tags.ts: -------------------------------------------------------------------------------- 1 | import type { FieldCommonProps } from "../fields.js"; 2 | 3 | declare module "../components.js" { 4 | interface ComponentProps { 5 | tagsField: FieldCommonProps; 6 | } 7 | interface ComponentBindings { 8 | tagsField: "value"; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/form/src/form/simple-form.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/form/src/form/submit-button.module.ts: -------------------------------------------------------------------------------- 1 | import type { Snippet } from "svelte"; 2 | 3 | import type { Config } from "./config.js"; 4 | 5 | declare module "./components.js" { 6 | interface FoundationalComponents { 7 | submitButton: {}; 8 | } 9 | interface ComponentProps { 10 | submitButton: { 11 | config: Config; 12 | children: Snippet; 13 | }; 14 | } 15 | interface ComponentBindings { 16 | submitButton: ""; 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /packages/form/src/form/text.module.ts: -------------------------------------------------------------------------------- 1 | import type { TranslatorDefinitions } from "./translation.js"; 2 | 3 | declare module "./ui-schema.js" { 4 | interface UiOptions { 5 | translations?: Partial; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /packages/form/src/lib/array.ts: -------------------------------------------------------------------------------- 1 | export const array = (count: number, factory: (index: number) => R): R[] => 2 | Array.from(new Array(count), (_, i) => factory(i)); 3 | 4 | export function some( 5 | data: T | T[], 6 | predicate: (item: T) => boolean 7 | ): boolean { 8 | return Array.isArray(data) ? data.some(predicate) : predicate(data); 9 | } 10 | -------------------------------------------------------------------------------- /packages/form/src/lib/css.ts: -------------------------------------------------------------------------------- 1 | // custom property names: 2 | // Alphanumeric characters (a-z, A-Z, 0-9) 3 | // Hyphens (-) are allowed as separators. 4 | // Underscores (_) work but are less common. 5 | // Custom properties must start with --. 6 | 7 | export function formatAsCustomPropertyName(name: string): string { 8 | return `--${name.replaceAll(/[^A-Za-z0-9_-]/g, '-')}` 9 | } 10 | -------------------------------------------------------------------------------- /packages/form/src/lib/function.ts: -------------------------------------------------------------------------------- 1 | export function noop() {} 2 | 3 | export function identity(v: T): T { 4 | return v; 5 | } 6 | -------------------------------------------------------------------------------- /packages/form/src/lib/reg-exp.ts: -------------------------------------------------------------------------------- 1 | export function escapeRegex(str: string) { 2 | return str.replace(/[/\-\\^$*+?.()|[\]{}]/g, '\\$&'); 3 | } 4 | -------------------------------------------------------------------------------- /packages/form/src/lib/scheduler.ts: -------------------------------------------------------------------------------- 1 | export type SchedulerYield = (options: { signal: AbortSignal }) => Promise 2 | -------------------------------------------------------------------------------- /packages/form/src/prevent-page-reload.svelte.ts: -------------------------------------------------------------------------------- 1 | import { on } from "svelte/events"; 2 | 3 | export function preventPageReload(data: { isChanged: boolean }) { 4 | $effect(() => 5 | on(window, "beforeunload", (e) => { 6 | if (data.isChanged) { 7 | e.preventDefault(); 8 | e.returnValue = ""; 9 | } 10 | }) 11 | ); 12 | } 13 | -------------------------------------------------------------------------------- /packages/form/src/templates/get-template-props.ts: -------------------------------------------------------------------------------- 1 | import type { Config, UiOption } from "@/form/index.js"; 2 | 3 | export function getTemplateProps(uiOption: UiOption, config: Config) { 4 | return { 5 | title: config.title, 6 | showMeta: uiOption("hideTitle") !== true, 7 | description: uiOption("description") ?? config.schema.description, 8 | }; 9 | } 10 | -------------------------------------------------------------------------------- /packages/form/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | -------------------------------------------------------------------------------- /packages/form/svelte.config.js: -------------------------------------------------------------------------------- 1 | import { vitePreprocess } from "@sveltejs/vite-plugin-svelte"; 2 | 3 | export default { 4 | // Consult https://svelte.dev/docs#compile-time-svelte-preprocess 5 | // for more information about preprocessors 6 | preprocess: vitePreprocess(), 7 | kit: { 8 | files: { 9 | lib: "src", 10 | }, 11 | alias: { 12 | "@/": "./src/", 13 | } 14 | }, 15 | compilerOptions: { 16 | runes: true, 17 | }, 18 | }; 19 | -------------------------------------------------------------------------------- /packages/form/vite.config.ts: -------------------------------------------------------------------------------- 1 | /// 2 | import { resolve } from "node:path"; 3 | 4 | import { defineConfig } from "vite"; 5 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | plugins: [svelte()], 10 | resolve: { 11 | alias: { 12 | "@": resolve(__dirname, "src"), 13 | }, 14 | }, 15 | }); 16 | -------------------------------------------------------------------------------- /packages/form/vitest-setup.ts: -------------------------------------------------------------------------------- 1 | import '@testing-library/jest-dom/vitest' 2 | -------------------------------------------------------------------------------- /packages/lucide-icons/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/lucide-icons/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/lucide-icons/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/lucide-icons/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/lucide-icons/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/lucide-icons/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/lucide-icons/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/lucide-icons/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/lucide-icons/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /packages/lucide-icons/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/lucide-icons/static/favicon.png -------------------------------------------------------------------------------- /packages/lucide-icons/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/lucide-icons/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "Preserve", 13 | "moduleResolution": "Bundler" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/lucide-icons/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()], 6 | test: { 7 | include: ['src/**/*.{test,spec}.{js,ts}'] 8 | } 9 | }); 10 | -------------------------------------------------------------------------------- /packages/moving-icons/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/moving-icons/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/moving-icons/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/moving-icons/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/moving-icons/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/moving-icons/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/moving-icons/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/moving-icons/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/moving-icons/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /packages/moving-icons/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/moving-icons/static/favicon.png -------------------------------------------------------------------------------- /packages/moving-icons/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/moving-icons/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "nodenext" 14 | } 15 | } -------------------------------------------------------------------------------- /packages/moving-icons/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()], 6 | test: { 7 | include: ['src/**/*.{test,spec}.{js,ts}'] 8 | } 9 | }); 10 | -------------------------------------------------------------------------------- /packages/radix-icons/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/radix-icons/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/radix-icons/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/radix-icons/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/radix-icons/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/radix-icons/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/radix-icons/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/radix-icons/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/radix-icons/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /packages/radix-icons/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/radix-icons/static/favicon.png -------------------------------------------------------------------------------- /packages/radix-icons/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/radix-icons/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "Preserve", 13 | "moduleResolution": "Bundler" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/radix-icons/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()], 6 | test: { 7 | include: ['src/**/*.{test,spec}.{js,ts}'] 8 | } 9 | }); 10 | -------------------------------------------------------------------------------- /packages/schemasafe-validator/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./model.js"; 2 | export * from "./validator.js"; 3 | -------------------------------------------------------------------------------- /packages/schemasafe-validator/src/precompile/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./validator.js"; 2 | -------------------------------------------------------------------------------- /packages/schemasafe-validator/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@total-typescript/tsconfig/tsc/dom/library", 3 | "compilerOptions": { 4 | "moduleResolution": "NodeNext", 5 | "outDir": "dist", 6 | "rootDir": "src", 7 | "sourceMap": false 8 | }, 9 | "exclude": [ 10 | "vitest.config.ts", 11 | "dist", 12 | "node_modules" 13 | ] 14 | } -------------------------------------------------------------------------------- /packages/schemasafe-validator/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vitest/config'; 2 | 3 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 4 | 5 | export default defineConfig({ 6 | plugins: [svelte()], 7 | }); 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/.gitignore: -------------------------------------------------------------------------------- 1 | test-results 2 | node_modules 3 | 4 | # Output 5 | .output 6 | .vercel 7 | .netlify 8 | .wrangler 9 | /.svelte-kit 10 | /build 11 | /dist 12 | 13 | # OS 14 | .DS_Store 15 | Thumbs.db 16 | 17 | # Env 18 | .env 19 | .env.* 20 | !.env.example 21 | !.env.test 22 | 23 | # Vite 24 | vite.config.js.timestamp-* 25 | vite.config.ts.timestamp-* 26 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | bun.lock 6 | bun.lockb 7 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte", "prettier-plugin-tailwindcss"], 7 | "overrides": [ 8 | { 9 | "files": "*.svelte", 10 | "options": { 11 | "parser": "svelte" 12 | } 13 | } 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/components.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://next.shadcn-svelte.com/schema.json", 3 | "tailwind": { 4 | "css": "src/app.css", 5 | "baseColor": "slate" 6 | }, 7 | "aliases": { 8 | "components": "$lib/components", 9 | "utils": "$lib/utils", 10 | "ui": "$lib/components/ui", 11 | "hooks": "$lib/hooks", 12 | "lib": "$lib" 13 | }, 14 | "typescript": true, 15 | "registry": "https://next.shadcn-svelte.com/registry" 16 | } 17 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from '@playwright/test'; 2 | 3 | export default defineConfig({ 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'e2e' 9 | }); 10 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://svelte.dev/docs/kit/types#app.d.ts 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/demo.spec.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/button/index.ts: -------------------------------------------------------------------------------- 1 | import Root, { 2 | type ButtonProps, 3 | type ButtonSize, 4 | type ButtonVariant, 5 | buttonVariants, 6 | } from "./button.svelte"; 7 | 8 | export { 9 | Root, 10 | type ButtonProps as Props, 11 | // 12 | Root as Button, 13 | buttonVariants, 14 | type ButtonProps, 15 | type ButtonSize, 16 | type ButtonVariant, 17 | }; 18 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/calendar/calendar-grid-body.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/calendar/calendar-grid-head.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/calendar/calendar-grid-row.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/calendar/calendar-heading.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/checkbox/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./checkbox.svelte"; 2 | export { 3 | Root, 4 | // 5 | Root as Checkbox, 6 | }; 7 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/dialog/dialog-close.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/dialog/dialog-trigger.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/input/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./input.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Input, 7 | }; 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/label/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./label.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Label, 7 | }; 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/radio-group/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./radio-group.svelte"; 2 | import Item from "./radio-group-item.svelte"; 3 | 4 | export { 5 | Root, 6 | Item, 7 | // 8 | Root as RadioGroup, 9 | Item as RadioGroupItem, 10 | }; 11 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/select/select-group.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/separator/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./separator.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Separator, 7 | }; 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/slider/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./slider.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Slider, 7 | }; 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/switch/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./switch.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Switch, 7 | }; 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/textarea/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./textarea.svelte"; 2 | 3 | export { 4 | Root, 5 | // 6 | Root as Textarea, 7 | }; 8 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/toggle-group/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./toggle-group.svelte"; 2 | import Item from "./toggle-group-item.svelte"; 3 | 4 | export { 5 | Root, 6 | Item, 7 | // 8 | Root as ToggleGroup, 9 | Item as ToggleGroupItem, 10 | }; 11 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/components/ui/toggle/index.ts: -------------------------------------------------------------------------------- 1 | import Root from "./toggle.svelte"; 2 | export { 3 | toggleVariants, 4 | type ToggleSize, 5 | type ToggleVariant, 6 | type ToggleVariants, 7 | } from "./toggle.svelte"; 8 | 9 | export { 10 | Root, 11 | // 12 | Root as Toggle, 13 | }; 14 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/components/help.svelte: -------------------------------------------------------------------------------- 1 | 9 | 10 |
11 | {help} 12 |
13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/checkboxes-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Checkboxes from './checkboxes.svelte'; 4 | import './checkboxes.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | checkboxesWidget: {}; 9 | } 10 | } 11 | 12 | definitions.checkboxesWidget = Checkboxes; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/combobox-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Combobox from './combobox.svelte'; 4 | import './combobox.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | comboboxWidget: {}; 9 | } 10 | } 11 | 12 | definitions.comboboxWidget = Combobox; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/date-picker-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import DatePicker from './date-picker.svelte'; 4 | import './date-picker.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | datePickerWidget: {}; 9 | } 10 | } 11 | 12 | definitions.datePickerWidget = DatePicker; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/file-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import File from './file.svelte'; 4 | import './file.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | fileWidget: {}; 9 | } 10 | } 11 | 12 | definitions.fileWidget = File; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/multi-select-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import MultiSelect from './multi-select.svelte'; 4 | import './multi-select.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | multiSelectWidget: {}; 9 | } 10 | } 11 | 12 | definitions.multiSelectWidget = MultiSelect; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/radio-buttons-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import RadioButtons from './radio-buttons.svelte'; 4 | import './radio-buttons.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioButtonsWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioButtonsWidget = RadioButtons; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/radio-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Radio from './radio.svelte'; 4 | import './radio.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioWidget = Radio; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/range-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Range from './range.svelte'; 4 | import './range.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | rangeWidget: {}; 9 | } 10 | } 11 | 12 | definitions.rangeWidget = Range; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/switch-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Switch from './switch.svelte'; 4 | import './switch.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | switchWidget: {}; 9 | } 10 | } 11 | 12 | definitions.switchWidget = Switch; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/extra-widgets/textarea-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Textarea from './textarea.svelte'; 4 | import './textarea.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | textareaWidget: {}; 9 | } 10 | } 11 | 12 | definitions.textareaWidget = Textarea; 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/index.ts: -------------------------------------------------------------------------------- 1 | import { extendByRecord } from '@sjsf/form/lib/resolver'; 2 | import { fields } from '@sjsf/form/fields/resolver'; 3 | 4 | import { definitions } from './definitions.js'; 5 | 6 | export * from './context.js'; 7 | 8 | export const theme = extendByRecord(fields, definitions); 9 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/types/button.ts: -------------------------------------------------------------------------------- 1 | import type { Component } from 'svelte'; 2 | 3 | import type { ButtonProps } from '$lib/components/ui/button/button.svelte'; 4 | 5 | export type { ButtonProps } 6 | 7 | declare module '../context.js' { 8 | interface ThemeComponents { 9 | Button: Component; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/types/checkbox.ts: -------------------------------------------------------------------------------- 1 | import type { Component } from 'svelte'; 2 | import type { CheckboxRootProps, WithoutChildrenOrChild } from 'bits-ui'; 3 | 4 | export type CheckboxProps = WithoutChildrenOrChild; 5 | 6 | declare module '../context.js' { 7 | interface ThemeComponents { 8 | Checkbox: Component; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/types/label.ts: -------------------------------------------------------------------------------- 1 | import type { Component } from 'svelte'; 2 | import type { LabelRootProps } from 'bits-ui'; 3 | 4 | export type LabelProps = LabelRootProps; 5 | 6 | declare module '../context.js' { 7 | interface ThemeComponents { 8 | Label: Component; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/types/popover.ts: -------------------------------------------------------------------------------- 1 | import type { Component } from 'svelte'; 2 | import type { Popover } from 'bits-ui'; 3 | 4 | declare module '../context.js' { 5 | interface ThemeComponents { 6 | Popover: Component; 7 | PopoverTrigger: Component; 8 | PopoverContent: Component; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/lib/theme/widgets/exports.ts: -------------------------------------------------------------------------------- 1 | export { default as textWidget } from './text.svelte'; 2 | export { default as numberWidget } from './number.svelte'; 3 | export { default as selectWidget } from './select.svelte'; 4 | export { default as checkboxWidget } from './checkbox.svelte'; 5 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/shadcn4-theme/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/shadcn4-theme/static/favicon.png -------------------------------------------------------------------------------- /packages/shadcn4-theme/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "NodeNext" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "useTabs": true, 3 | "singleQuote": true, 4 | "trailingComma": "none", 5 | "printWidth": 100, 6 | "plugins": ["prettier-plugin-svelte"], 7 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 8 | } 9 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/app.css: -------------------------------------------------------------------------------- 1 | @import 'tailwindcss'; 2 | 3 | @plugin '@tailwindcss/forms'; 4 | 5 | @source '../node_modules/@skeletonlabs/skeleton-svelte/dist'; 6 | 7 | @import '@skeletonlabs/skeleton'; 8 | @import '@skeletonlabs/skeleton/optional/presets'; 9 | @import '@skeletonlabs/skeleton/themes/cerberus'; 10 | 11 | @custom-variant dark (&:where(.dark, .dark *)); 12 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | %sveltekit.head% 9 | 10 | 11 | 12 |
%sveltekit.body%
13 | 14 | 15 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/components/help.svelte: -------------------------------------------------------------------------------- 1 | 9 | 10 |
11 | {help} 12 |
13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/checkboxes-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Checkboxes from './checkboxes.svelte'; 4 | import './checkboxes.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | checkboxesWidget: {}; 9 | } 10 | } 11 | 12 | definitions.checkboxesWidget = Checkboxes; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/date-picker-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import DatePicker from './date-picker.svelte'; 4 | import './date-picker.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | datePickerWidget: {}; 9 | } 10 | } 11 | 12 | definitions.datePickerWidget = DatePicker; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/file-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import File from './file.svelte'; 4 | import './file.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | fileWidget: {}; 9 | } 10 | } 11 | 12 | definitions.fileWidget = File; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/file-upload-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import FileUpload from './file-upload.svelte'; 4 | import './file-upload.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | fileWidget: {}; 9 | } 10 | } 11 | 12 | definitions.fileWidget = FileUpload; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/multi-select-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import MultiSelect from './multi-select.svelte'; 4 | import './multi-select.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | multiSelectWidget: {}; 9 | } 10 | } 11 | 12 | definitions.multiSelectWidget = MultiSelect; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/radio-buttons-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import RadioButtons from './radio-buttons.svelte'; 4 | import './radio-buttons.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioButtonsWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioButtonsWidget = RadioButtons; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/radio-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Radio from './radio.svelte'; 4 | import './radio.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | radioWidget: {}; 9 | } 10 | } 11 | 12 | definitions.radioWidget = Radio; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/range-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import Range from './range.svelte'; 4 | import './range.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | rangeWidget: {}; 9 | } 10 | } 11 | 12 | definitions.rangeWidget = Range; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/rating-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js' 2 | 3 | import Rating from './rating.svelte' 4 | import './rating.svelte' 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | ratingWidget: {} 9 | } 10 | } 11 | 12 | definitions.ratingWidget = Rating 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/slider-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import Slider from './slider.svelte'; 4 | import './slider.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | rangeWidget: {}; 9 | } 10 | } 11 | 12 | definitions.rangeWidget = Slider; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/switch-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions'; 2 | 3 | import Switch from './switch.svelte'; 4 | import './switch.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | switchWidget: {}; 9 | } 10 | } 11 | 12 | definitions.switchWidget = Switch; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/tags-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions' 2 | 3 | import Tags from './tags.svelte' 4 | import './tags.svelte' 5 | 6 | declare module "../definitions.js" { 7 | interface ExtraWidgets { 8 | tagsWidget: {} 9 | } 10 | } 11 | 12 | definitions.tagsWidget = Tags 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/extra-widgets/textarea-include.ts: -------------------------------------------------------------------------------- 1 | import { definitions } from '../definitions.js'; 2 | 3 | import Textarea from './textarea.svelte'; 4 | import './textarea.svelte'; 5 | 6 | declare module '../definitions.js' { 7 | interface ExtraWidgets { 8 | textareaWidget: {}; 9 | } 10 | } 11 | 12 | definitions.textareaWidget = Textarea; 13 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/index.ts: -------------------------------------------------------------------------------- 1 | import { extendByRecord } from '@sjsf/form/lib/resolver'; 2 | import { fields } from '@sjsf/form/fields/resolver'; 3 | 4 | import { definitions } from './definitions'; 5 | 6 | export const theme = extendByRecord(fields, definitions); 7 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/lib/widgets/exports.ts: -------------------------------------------------------------------------------- 1 | export { default as textWidget } from './text.svelte'; 2 | export { default as numberWidget } from './number.svelte'; 3 | export { default as selectWidget } from './select.svelte'; 4 | export { default as checkboxWidget } from './checkbox.svelte'; 5 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/skeleton3-theme/static/favicon.png -------------------------------------------------------------------------------- /packages/skeleton3-theme/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "Preserve", 13 | "moduleResolution": "Bundler" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/skeleton3-theme/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | import tailwindcss from '@tailwindcss/vite'; 4 | 5 | export default defineConfig({ 6 | plugins: [tailwindcss(), sveltekit()], 7 | test: { 8 | include: ['src/**/*.{test,spec}.{js,ts}'] 9 | } 10 | }); 11 | -------------------------------------------------------------------------------- /packages/sveltekit/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | 3 | # Output 4 | .output 5 | .vercel 6 | /.svelte-kit 7 | /build 8 | /dist 9 | 10 | # OS 11 | .DS_Store 12 | Thumbs.db 13 | 14 | # Env 15 | .env 16 | .env.* 17 | !.env.example 18 | !.env.test 19 | 20 | # Vite 21 | vite.config.js.timestamp-* 22 | vite.config.ts.timestamp-* 23 | -------------------------------------------------------------------------------- /packages/sveltekit/.npmrc: -------------------------------------------------------------------------------- 1 | engine-strict=true 2 | -------------------------------------------------------------------------------- /packages/sveltekit/.prettierignore: -------------------------------------------------------------------------------- 1 | # Package Managers 2 | package-lock.json 3 | pnpm-lock.yaml 4 | yarn.lock 5 | -------------------------------------------------------------------------------- /packages/sveltekit/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "singleQuote": true, 3 | "trailingComma": "none", 4 | "printWidth": 100, 5 | "plugins": ["prettier-plugin-svelte"], 6 | "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] 7 | } 8 | -------------------------------------------------------------------------------- /packages/sveltekit/playwright.config.ts: -------------------------------------------------------------------------------- 1 | import type { PlaywrightTestConfig } from '@playwright/test'; 2 | 3 | const config: PlaywrightTestConfig = { 4 | webServer: { 5 | command: 'npm run build && npm run preview', 6 | port: 4173 7 | }, 8 | testDir: 'tests', 9 | testMatch: /(.+\.)?(test|spec)\.[jt]s/ 10 | }; 11 | 12 | export default config; 13 | -------------------------------------------------------------------------------- /packages/sveltekit/src/app.d.ts: -------------------------------------------------------------------------------- 1 | // See https://kit.svelte.dev/docs/types#app 2 | // for information about these interfaces 3 | declare global { 4 | namespace App { 5 | // interface Error {} 6 | // interface Locals {} 7 | // interface PageData {} 8 | // interface PageState {} 9 | // interface Platform {} 10 | } 11 | } 12 | 13 | export {}; 14 | -------------------------------------------------------------------------------- /packages/sveltekit/src/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | %sveltekit.head% 8 | 9 | 10 |
%sveltekit.body%
11 | 12 | 13 | -------------------------------------------------------------------------------- /packages/sveltekit/src/index.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it, expect } from 'vitest'; 2 | 3 | describe('sum test', () => { 4 | it('adds 1 + 2 to equal 3', () => { 5 | expect(1 + 2).toBe(3); 6 | }); 7 | }); 8 | -------------------------------------------------------------------------------- /packages/sveltekit/src/lib/client/index.ts: -------------------------------------------------------------------------------- 1 | export * from './meta.js'; 2 | export * from './request.svelte'; 3 | export * from './form.svelte'; 4 | export * from './additional-property-key-validator.js'; 5 | export { default as SvelteKitForm } from './simple-form.svelte'; 6 | -------------------------------------------------------------------------------- /packages/sveltekit/src/lib/server/index.ts: -------------------------------------------------------------------------------- 1 | export * from './entry.js'; 2 | export * from './server.js'; 3 | export * from './convert-form-data-entries.js'; 4 | export * from './schema-value-parser.js'; 5 | -------------------------------------------------------------------------------- /packages/sveltekit/src/routes/+page.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /packages/sveltekit/src/routes/model.ts: -------------------------------------------------------------------------------- 1 | import { AdditionalPropertyKeyValidationErrorType } from '$lib/client/index.js'; 2 | 3 | export const ERROR_TYPE_OBJECTS: Record = { 4 | [AdditionalPropertyKeyValidationErrorType.ForbiddenSequence]: 'sequences', 5 | [AdditionalPropertyKeyValidationErrorType.ForbiddenSuffix]: 'suffixes' 6 | }; 7 | -------------------------------------------------------------------------------- /packages/sveltekit/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/x0k/svelte-jsonschema-form/bc8bd9afd16be720df7f9fd0733b8b26351ea640/packages/sveltekit/static/favicon.png -------------------------------------------------------------------------------- /packages/sveltekit/tests/test.ts: -------------------------------------------------------------------------------- 1 | import { expect, test } from '@playwright/test'; 2 | 3 | test('home page has expected h1', async ({ page }) => { 4 | await page.goto('/'); 5 | await expect(page.locator('h1')).toBeVisible(); 6 | }); 7 | -------------------------------------------------------------------------------- /packages/sveltekit/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./.svelte-kit/tsconfig.json", 3 | "compilerOptions": { 4 | "allowJs": true, 5 | "checkJs": true, 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "resolveJsonModule": true, 9 | "skipLibCheck": true, 10 | "sourceMap": true, 11 | "strict": true, 12 | "module": "NodeNext", 13 | "moduleResolution": "NodeNext" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/sveltekit/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { sveltekit } from '@sveltejs/kit/vite'; 2 | import { defineConfig } from 'vitest/config'; 3 | 4 | export default defineConfig({ 5 | plugins: [sveltekit()], 6 | test: { 7 | include: ['src/**/*.{test,spec}.{js,ts}'] 8 | }, 9 | resolve: { 10 | conditions: process.env.VITEST ? ['browser'] : ['module', 'browser', 'development|production'] 11 | } 12 | }); 13 | -------------------------------------------------------------------------------- /packages/testing/README.md: -------------------------------------------------------------------------------- 1 | # Shared 2 | -------------------------------------------------------------------------------- /packages/testing/src/components/shadow/index.ts: -------------------------------------------------------------------------------- 1 | export { default as ShadowHost } from './shadow-host.svelte' 2 | -------------------------------------------------------------------------------- /packages/testing/src/components/shadow/shadow-root.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 | {@render children?.()} 8 | -------------------------------------------------------------------------------- /packages/testing/src/demo/index.ts: -------------------------------------------------------------------------------- 1 | import "@sjsf/form/fields/exports"; 2 | 3 | export * as s from "./schemas"; 4 | export { default as Form } from "./form.svelte"; 5 | export { default as ComponentsAndWidgets } from "./components-and-widgets.svelte"; 6 | export { default as AllIcons } from "./all-icons.svelte"; 7 | -------------------------------------------------------------------------------- /packages/testing/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | -------------------------------------------------------------------------------- /packages/testing/svelte.config.js: -------------------------------------------------------------------------------- 1 | import { vitePreprocess } from "@sveltejs/vite-plugin-svelte"; 2 | 3 | export default { 4 | // Consult https://svelte.dev/docs#compile-time-svelte-preprocess 5 | // for more information about preprocessors 6 | preprocess: vitePreprocess(), 7 | kit: { 8 | files: { 9 | lib: "src", 10 | }, 11 | alias: { 12 | "@/": "./src/", 13 | } 14 | }, 15 | compilerOptions: { 16 | runes: true, 17 | }, 18 | }; 19 | -------------------------------------------------------------------------------- /packages/testing/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@total-typescript/tsconfig/bundler/dom/library-monorepo", 3 | "compilerOptions": { 4 | "moduleResolution": "Bundler", 5 | "outDir": "dist", 6 | "rootDir": "src", 7 | }, 8 | } -------------------------------------------------------------------------------- /packages/testing/vite.config.ts: -------------------------------------------------------------------------------- 1 | /// 2 | import { resolve } from "node:path"; 3 | 4 | import { defineConfig } from "vite"; 5 | import { svelte } from "@sveltejs/vite-plugin-svelte"; 6 | 7 | // https://vitejs.dev/config/ 8 | export default defineConfig({ 9 | test: {}, 10 | plugins: [svelte()], 11 | resolve: { 12 | alias: { 13 | "@": resolve(__dirname, "src"), 14 | }, 15 | }, 16 | }); 17 | -------------------------------------------------------------------------------- /packages/zod-validator/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from './validator.js' 2 | -------------------------------------------------------------------------------- /packages/zod-validator/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@total-typescript/tsconfig/tsc/dom/library", 3 | "compilerOptions": { 4 | "moduleResolution": "NodeNext", 5 | "outDir": "dist", 6 | "rootDir": "src", 7 | }, 8 | } -------------------------------------------------------------------------------- /pnpm-workspace.yaml: -------------------------------------------------------------------------------- 1 | packages: 2 | - "examples/*" 3 | - "packages/*" 4 | - "apps/*" 5 | 6 | catalog: 7 | "vite": "^6.3.5" 8 | "ajv": "^8.17.1" 9 | "svelte": "^5.33.10" 10 | "esm-env": "^1.2.2" 11 | "globals": "^16.2.0" 12 | "zod": "^3.25.42" 13 | "tailwindcss": "^4.1.8" 14 | "@tailwindcss/vite": "^4.1.8" 15 | "@exodus/schemasafe": "^1.3.0" 16 | --------------------------------------------------------------------------------