create-nuclo 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -0
- package/package.json +35 -0
- package/src/create-nuclo.mjs +193 -0
- package/templates/basic/README.md +16 -0
- package/templates/basic/_gitignore +5 -0
- package/templates/basic/index.html +26 -0
- package/templates/basic/node_modules/.package-lock.json +348 -0
- package/templates/basic/node_modules/.vite/deps/_metadata.json +15 -0
- package/templates/basic/node_modules/.vite/deps/nuclo.js +1665 -0
- package/templates/basic/node_modules/.vite/deps/nuclo.js.map +1 -0
- package/templates/basic/node_modules/.vite/deps/package.json +3 -0
- package/templates/basic/node_modules/@oxc-project/types/LICENSE +22 -0
- package/templates/basic/node_modules/@oxc-project/types/README.md +3 -0
- package/templates/basic/node_modules/@oxc-project/types/package.json +26 -0
- package/templates/basic/node_modules/@oxc-project/types/types.d.ts +1912 -0
- package/templates/basic/node_modules/@rolldown/binding-darwin-arm64/README.md +3 -0
- package/templates/basic/node_modules/@rolldown/binding-darwin-arm64/package.json +37 -0
- package/templates/basic/node_modules/@rolldown/binding-darwin-arm64/rolldown-binding.darwin-arm64.node +0 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/LICENSE +21 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/README.md +145 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/dist/filter/index.d.mts +194 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/dist/filter/index.mjs +2 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/dist/filter-B_mD-HGz.mjs +323 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/dist/index.d.mts +2 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/dist/index.mjs +2 -0
- package/templates/basic/node_modules/@rolldown/pluginutils/package.json +40 -0
- package/templates/basic/node_modules/detect-libc/LICENSE +201 -0
- package/templates/basic/node_modules/detect-libc/README.md +163 -0
- package/templates/basic/node_modules/detect-libc/index.d.ts +14 -0
- package/templates/basic/node_modules/detect-libc/lib/detect-libc.js +313 -0
- package/templates/basic/node_modules/detect-libc/lib/elf.js +39 -0
- package/templates/basic/node_modules/detect-libc/lib/filesystem.js +51 -0
- package/templates/basic/node_modules/detect-libc/lib/process.js +24 -0
- package/templates/basic/node_modules/detect-libc/package.json +44 -0
- package/templates/basic/node_modules/fdir/LICENSE +7 -0
- package/templates/basic/node_modules/fdir/README.md +91 -0
- package/templates/basic/node_modules/fdir/dist/index.cjs +588 -0
- package/templates/basic/node_modules/fdir/dist/index.d.cts +155 -0
- package/templates/basic/node_modules/fdir/dist/index.d.mts +155 -0
- package/templates/basic/node_modules/fdir/dist/index.mjs +570 -0
- package/templates/basic/node_modules/fdir/package.json +103 -0
- package/templates/basic/node_modules/lightningcss/LICENSE +373 -0
- package/templates/basic/node_modules/lightningcss/README.md +105 -0
- package/templates/basic/node_modules/lightningcss/node/ast.d.ts +9892 -0
- package/templates/basic/node_modules/lightningcss/node/ast.js.flow +10539 -0
- package/templates/basic/node_modules/lightningcss/node/browserslistToTargets.js +48 -0
- package/templates/basic/node_modules/lightningcss/node/composeVisitors.js +450 -0
- package/templates/basic/node_modules/lightningcss/node/flags.js +28 -0
- package/templates/basic/node_modules/lightningcss/node/index.d.ts +494 -0
- package/templates/basic/node_modules/lightningcss/node/index.js +59 -0
- package/templates/basic/node_modules/lightningcss/node/index.js.flow +843 -0
- package/templates/basic/node_modules/lightningcss/node/index.mjs +4 -0
- package/templates/basic/node_modules/lightningcss/node/targets.d.ts +40 -0
- package/templates/basic/node_modules/lightningcss/node/targets.js.flow +39 -0
- package/templates/basic/node_modules/lightningcss/package.json +110 -0
- package/templates/basic/node_modules/lightningcss-darwin-arm64/LICENSE +373 -0
- package/templates/basic/node_modules/lightningcss-darwin-arm64/README.md +1 -0
- package/templates/basic/node_modules/lightningcss-darwin-arm64/lightningcss.darwin-arm64.node +0 -0
- package/templates/basic/node_modules/lightningcss-darwin-arm64/package.json +34 -0
- package/templates/basic/node_modules/nanoid/LICENSE +20 -0
- package/templates/basic/node_modules/nanoid/README.md +36 -0
- package/templates/basic/node_modules/nanoid/async/index.browser.cjs +42 -0
- package/templates/basic/node_modules/nanoid/async/index.browser.js +42 -0
- package/templates/basic/node_modules/nanoid/async/index.cjs +44 -0
- package/templates/basic/node_modules/nanoid/async/index.d.ts +56 -0
- package/templates/basic/node_modules/nanoid/async/index.js +44 -0
- package/templates/basic/node_modules/nanoid/async/index.native.js +35 -0
- package/templates/basic/node_modules/nanoid/async/package.json +12 -0
- package/templates/basic/node_modules/nanoid/bin/nanoid.cjs +55 -0
- package/templates/basic/node_modules/nanoid/index.browser.cjs +44 -0
- package/templates/basic/node_modules/nanoid/index.browser.js +44 -0
- package/templates/basic/node_modules/nanoid/index.cjs +57 -0
- package/templates/basic/node_modules/nanoid/index.d.cts +91 -0
- package/templates/basic/node_modules/nanoid/index.d.ts +91 -0
- package/templates/basic/node_modules/nanoid/index.js +62 -0
- package/templates/basic/node_modules/nanoid/nanoid.js +1 -0
- package/templates/basic/node_modules/nanoid/non-secure/index.cjs +24 -0
- package/templates/basic/node_modules/nanoid/non-secure/index.d.ts +33 -0
- package/templates/basic/node_modules/nanoid/non-secure/index.js +24 -0
- package/templates/basic/node_modules/nanoid/non-secure/package.json +6 -0
- package/templates/basic/node_modules/nanoid/package.json +89 -0
- package/templates/basic/node_modules/nanoid/url-alphabet/index.cjs +4 -0
- package/templates/basic/node_modules/nanoid/url-alphabet/index.js +4 -0
- package/templates/basic/node_modules/nanoid/url-alphabet/package.json +6 -0
- package/templates/basic/node_modules/nuclo/LICENSE.md +45 -0
- package/templates/basic/node_modules/nuclo/README.md +727 -0
- package/templates/basic/node_modules/nuclo/dist/bootstrap.d.ts +5 -0
- package/templates/basic/node_modules/nuclo/dist/bootstrap.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/attributes.d.ts +3 -0
- package/templates/basic/node_modules/nuclo/dist/element/attributes.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/class-name.d.ts +6 -0
- package/templates/basic/node_modules/nuclo/dist/element/class-name.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/events.d.ts +35 -0
- package/templates/basic/node_modules/nuclo/dist/element/events.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/factory.d.ts +32 -0
- package/templates/basic/node_modules/nuclo/dist/element/factory.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/inline-style.d.ts +9 -0
- package/templates/basic/node_modules/nuclo/dist/element/inline-style.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/modifiers.d.ts +11 -0
- package/templates/basic/node_modules/nuclo/dist/element/modifiers.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/element/tags.d.ts +5 -0
- package/templates/basic/node_modules/nuclo/dist/element/tags.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/hydration.d.ts +73 -0
- package/templates/basic/node_modules/nuclo/dist/hydration.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/index.d.ts +17 -0
- package/templates/basic/node_modules/nuclo/dist/index.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/list/index.d.ts +7 -0
- package/templates/basic/node_modules/nuclo/dist/list/index.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/list/runtime.d.ts +6 -0
- package/templates/basic/node_modules/nuclo/dist/list/runtime.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/list/types.d.ts +18 -0
- package/templates/basic/node_modules/nuclo/dist/list/types.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/nuclo.cjs +2 -0
- package/templates/basic/node_modules/nuclo/dist/nuclo.cjs.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/nuclo.mjs +2 -0
- package/templates/basic/node_modules/nuclo/dist/nuclo.mjs.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/nuclo.umd.js +2 -0
- package/templates/basic/node_modules/nuclo/dist/nuclo.umd.js.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Document.d.ts +19 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Document.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Element.d.ts +48 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Element.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Event.d.ts +43 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Event.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Node.d.ts +13 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Node.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Text.d.ts +11 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/Text.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/index.d.ts +24 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/index.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/nuclo.polyfill.cjs +2 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/nuclo.polyfill.cjs.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/nuclo.polyfill.mjs +2 -0
- package/templates/basic/node_modules/nuclo/dist/polyfill/nuclo.polyfill.mjs.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/render.d.ts +33 -0
- package/templates/basic/node_modules/nuclo/dist/render.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/conditions.d.ts +4 -0
- package/templates/basic/node_modules/nuclo/dist/shared/conditions.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/dom.d.ts +69 -0
- package/templates/basic/node_modules/nuclo/dist/shared/dom.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/environment.d.ts +5 -0
- package/templates/basic/node_modules/nuclo/dist/shared/environment.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/errors.d.ts +2 -0
- package/templates/basic/node_modules/nuclo/dist/shared/errors.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/renderables.d.ts +4 -0
- package/templates/basic/node_modules/nuclo/dist/shared/renderables.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/strings.d.ts +19 -0
- package/templates/basic/node_modules/nuclo/dist/shared/strings.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/shared/type-guards.d.ts +16 -0
- package/templates/basic/node_modules/nuclo/dist/shared/type-guards.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/index.d.ts +19 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/index.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/nuclo.ssr.cjs +2 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/nuclo.ssr.cjs.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/nuclo.ssr.mjs +2 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/nuclo.ssr.mjs.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/render-to-string.d.ts +41 -0
- package/templates/basic/node_modules/nuclo/dist/ssr/render-to-string.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/style/css.d.ts +19 -0
- package/templates/basic/node_modules/nuclo/dist/style/css.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/style/engine.d.ts +34 -0
- package/templates/basic/node_modules/nuclo/dist/style/engine.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/style/index.d.ts +3 -0
- package/templates/basic/node_modules/nuclo/dist/style/index.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/update/conditional.d.ts +3 -0
- package/templates/basic/node_modules/nuclo/dist/update/conditional.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/update/reactive-attributes.d.ts +45 -0
- package/templates/basic/node_modules/nuclo/dist/update/reactive-attributes.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/update/reactive-text.d.ts +38 -0
- package/templates/basic/node_modules/nuclo/dist/update/reactive-text.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/update/registry.d.ts +97 -0
- package/templates/basic/node_modules/nuclo/dist/update/registry.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/update/scope.d.ts +7 -0
- package/templates/basic/node_modules/nuclo/dist/update/scope.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/update/update.d.ts +4 -0
- package/templates/basic/node_modules/nuclo/dist/update/update.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/when/builder.d.ts +16 -0
- package/templates/basic/node_modules/nuclo/dist/when/builder.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/when/index.d.ts +44 -0
- package/templates/basic/node_modules/nuclo/dist/when/index.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/dist/when/runtime.d.ts +59 -0
- package/templates/basic/node_modules/nuclo/dist/when/runtime.d.ts.map +1 -0
- package/templates/basic/node_modules/nuclo/package.json +88 -0
- package/templates/basic/node_modules/nuclo/types/core/base.d.ts +113 -0
- package/templates/basic/node_modules/nuclo/types/features/list.d.ts +38 -0
- package/templates/basic/node_modules/nuclo/types/features/on.d.ts +59 -0
- package/templates/basic/node_modules/nuclo/types/features/render.d.ts +49 -0
- package/templates/basic/node_modules/nuclo/types/features/scope.d.ts +6 -0
- package/templates/basic/node_modules/nuclo/types/features/style.d.ts +77 -0
- package/templates/basic/node_modules/nuclo/types/features/update.d.ts +6 -0
- package/templates/basic/node_modules/nuclo/types/features/when.d.ts +18 -0
- package/templates/basic/node_modules/nuclo/types/html/tags.d.ts +119 -0
- package/templates/basic/node_modules/nuclo/types/index.d.ts +137 -0
- package/templates/basic/node_modules/nuclo/types/polyfill.d.ts +131 -0
- package/templates/basic/node_modules/nuclo/types/ssr.d.ts +45 -0
- package/templates/basic/node_modules/nuclo/types/style.d.ts +404 -0
- package/templates/basic/node_modules/nuclo/types/svg/base.d.ts +118 -0
- package/templates/basic/node_modules/nuclo/types/svg/tags.d.ts +68 -0
- package/templates/basic/node_modules/picocolors/LICENSE +15 -0
- package/templates/basic/node_modules/picocolors/README.md +21 -0
- package/templates/basic/node_modules/picocolors/package.json +25 -0
- package/templates/basic/node_modules/picocolors/picocolors.browser.js +4 -0
- package/templates/basic/node_modules/picocolors/picocolors.d.ts +5 -0
- package/templates/basic/node_modules/picocolors/picocolors.js +75 -0
- package/templates/basic/node_modules/picocolors/types.d.ts +51 -0
- package/templates/basic/node_modules/picomatch/LICENSE +21 -0
- package/templates/basic/node_modules/picomatch/README.md +743 -0
- package/templates/basic/node_modules/picomatch/index.js +17 -0
- package/templates/basic/node_modules/picomatch/lib/constants.js +184 -0
- package/templates/basic/node_modules/picomatch/lib/parse.js +1416 -0
- package/templates/basic/node_modules/picomatch/lib/picomatch.js +361 -0
- package/templates/basic/node_modules/picomatch/lib/scan.js +391 -0
- package/templates/basic/node_modules/picomatch/lib/utils.js +72 -0
- package/templates/basic/node_modules/picomatch/package.json +83 -0
- package/templates/basic/node_modules/picomatch/posix.js +3 -0
- package/templates/basic/node_modules/postcss/LICENSE +20 -0
- package/templates/basic/node_modules/postcss/README.md +25 -0
- package/templates/basic/node_modules/postcss/lib/at-rule.d.ts +139 -0
- package/templates/basic/node_modules/postcss/lib/at-rule.js +25 -0
- package/templates/basic/node_modules/postcss/lib/comment.d.ts +67 -0
- package/templates/basic/node_modules/postcss/lib/comment.js +13 -0
- package/templates/basic/node_modules/postcss/lib/container.d.ts +478 -0
- package/templates/basic/node_modules/postcss/lib/container.js +447 -0
- package/templates/basic/node_modules/postcss/lib/css-syntax-error.d.ts +247 -0
- package/templates/basic/node_modules/postcss/lib/css-syntax-error.js +133 -0
- package/templates/basic/node_modules/postcss/lib/declaration.d.ts +150 -0
- package/templates/basic/node_modules/postcss/lib/declaration.js +24 -0
- package/templates/basic/node_modules/postcss/lib/document.d.ts +68 -0
- package/templates/basic/node_modules/postcss/lib/document.js +33 -0
- package/templates/basic/node_modules/postcss/lib/fromJSON.d.ts +9 -0
- package/templates/basic/node_modules/postcss/lib/fromJSON.js +68 -0
- package/templates/basic/node_modules/postcss/lib/input.d.ts +226 -0
- package/templates/basic/node_modules/postcss/lib/input.js +276 -0
- package/templates/basic/node_modules/postcss/lib/lazy-result.d.ts +189 -0
- package/templates/basic/node_modules/postcss/lib/lazy-result.js +563 -0
- package/templates/basic/node_modules/postcss/lib/list.d.ts +60 -0
- package/templates/basic/node_modules/postcss/lib/list.js +58 -0
- package/templates/basic/node_modules/postcss/lib/map-generator.js +376 -0
- package/templates/basic/node_modules/postcss/lib/no-work-result.d.ts +45 -0
- package/templates/basic/node_modules/postcss/lib/no-work-result.js +137 -0
- package/templates/basic/node_modules/postcss/lib/node.d.ts +555 -0
- package/templates/basic/node_modules/postcss/lib/node.js +456 -0
- package/templates/basic/node_modules/postcss/lib/parse.d.ts +9 -0
- package/templates/basic/node_modules/postcss/lib/parse.js +42 -0
- package/templates/basic/node_modules/postcss/lib/parser.js +618 -0
- package/templates/basic/node_modules/postcss/lib/postcss.d.mts +66 -0
- package/templates/basic/node_modules/postcss/lib/postcss.d.ts +461 -0
- package/templates/basic/node_modules/postcss/lib/postcss.js +101 -0
- package/templates/basic/node_modules/postcss/lib/postcss.mjs +30 -0
- package/templates/basic/node_modules/postcss/lib/previous-map.d.ts +80 -0
- package/templates/basic/node_modules/postcss/lib/previous-map.js +161 -0
- package/templates/basic/node_modules/postcss/lib/processor.d.ts +114 -0
- package/templates/basic/node_modules/postcss/lib/processor.js +67 -0
- package/templates/basic/node_modules/postcss/lib/result.d.ts +204 -0
- package/templates/basic/node_modules/postcss/lib/result.js +42 -0
- package/templates/basic/node_modules/postcss/lib/root.d.ts +86 -0
- package/templates/basic/node_modules/postcss/lib/root.js +61 -0
- package/templates/basic/node_modules/postcss/lib/rule.d.ts +126 -0
- package/templates/basic/node_modules/postcss/lib/rule.js +27 -0
- package/templates/basic/node_modules/postcss/lib/stringifier.d.ts +45 -0
- package/templates/basic/node_modules/postcss/lib/stringifier.js +374 -0
- package/templates/basic/node_modules/postcss/lib/stringify.d.ts +9 -0
- package/templates/basic/node_modules/postcss/lib/stringify.js +11 -0
- package/templates/basic/node_modules/postcss/lib/symbols.js +5 -0
- package/templates/basic/node_modules/postcss/lib/terminal-highlight.js +70 -0
- package/templates/basic/node_modules/postcss/lib/tokenize.js +270 -0
- package/templates/basic/node_modules/postcss/lib/warn-once.js +13 -0
- package/templates/basic/node_modules/postcss/lib/warning.d.ts +146 -0
- package/templates/basic/node_modules/postcss/lib/warning.js +37 -0
- package/templates/basic/node_modules/postcss/package.json +88 -0
- package/templates/basic/node_modules/rolldown/LICENSE +25 -0
- package/templates/basic/node_modules/rolldown/README.md +11 -0
- package/templates/basic/node_modules/rolldown/bin/cli.mjs +2 -0
- package/templates/basic/node_modules/rolldown/dist/cli.d.mts +1 -0
- package/templates/basic/node_modules/rolldown/dist/cli.mjs +1202 -0
- package/templates/basic/node_modules/rolldown/dist/config.d.mts +14 -0
- package/templates/basic/node_modules/rolldown/dist/config.mjs +4 -0
- package/templates/basic/node_modules/rolldown/dist/experimental-index.d.mts +280 -0
- package/templates/basic/node_modules/rolldown/dist/experimental-index.mjs +331 -0
- package/templates/basic/node_modules/rolldown/dist/experimental-runtime-types.d.ts +107 -0
- package/templates/basic/node_modules/rolldown/dist/filter-index.d.mts +195 -0
- package/templates/basic/node_modules/rolldown/dist/filter-index.mjs +380 -0
- package/templates/basic/node_modules/rolldown/dist/get-log-filter.d.mts +3 -0
- package/templates/basic/node_modules/rolldown/dist/get-log-filter.mjs +68 -0
- package/templates/basic/node_modules/rolldown/dist/index.d.mts +4 -0
- package/templates/basic/node_modules/rolldown/dist/index.mjs +50 -0
- package/templates/basic/node_modules/rolldown/dist/parallel-plugin-worker.d.mts +1 -0
- package/templates/basic/node_modules/rolldown/dist/parallel-plugin-worker.mjs +29 -0
- package/templates/basic/node_modules/rolldown/dist/parallel-plugin.d.mts +13 -0
- package/templates/basic/node_modules/rolldown/dist/parallel-plugin.mjs +6 -0
- package/templates/basic/node_modules/rolldown/dist/parse-ast-index.d.mts +32 -0
- package/templates/basic/node_modules/rolldown/dist/parse-ast-index.mjs +60 -0
- package/templates/basic/node_modules/rolldown/dist/plugins-index.d.mts +33 -0
- package/templates/basic/node_modules/rolldown/dist/plugins-index.mjs +40 -0
- package/templates/basic/node_modules/rolldown/dist/shared/binding-B1q9aYT-.d.mts +1947 -0
- package/templates/basic/node_modules/rolldown/dist/shared/binding-BmkJW3Wy.mjs +588 -0
- package/templates/basic/node_modules/rolldown/dist/shared/bindingify-input-options-BsDhfYrS.mjs +2240 -0
- package/templates/basic/node_modules/rolldown/dist/shared/constructors-2i1T9YcF.d.mts +36 -0
- package/templates/basic/node_modules/rolldown/dist/shared/constructors-CE6zZSUt.mjs +65 -0
- package/templates/basic/node_modules/rolldown/dist/shared/define-config-BBz954-q.d.mts +3901 -0
- package/templates/basic/node_modules/rolldown/dist/shared/define-config-Demdg3_4.mjs +6 -0
- package/templates/basic/node_modules/rolldown/dist/shared/error-BlQ0-ek7.mjs +85 -0
- package/templates/basic/node_modules/rolldown/dist/shared/get-log-filter-BpNVNJ5-.d.mts +35 -0
- package/templates/basic/node_modules/rolldown/dist/shared/load-config-FRmAU9xl.mjs +120 -0
- package/templates/basic/node_modules/rolldown/dist/shared/logging-BSNejiLS.d.mts +50 -0
- package/templates/basic/node_modules/rolldown/dist/shared/logs-aMKUxRpj.mjs +180 -0
- package/templates/basic/node_modules/rolldown/dist/shared/misc-CoQm4NHO.mjs +21 -0
- package/templates/basic/node_modules/rolldown/dist/shared/normalize-string-or-regex-BYkbbGqQ.mjs +68 -0
- package/templates/basic/node_modules/rolldown/dist/shared/parse-DVMnkavl.mjs +74 -0
- package/templates/basic/node_modules/rolldown/dist/shared/prompt-B1Yc1NPt.mjs +847 -0
- package/templates/basic/node_modules/rolldown/dist/shared/resolve-tsconfig-CdIAR1Eb.mjs +124 -0
- package/templates/basic/node_modules/rolldown/dist/shared/rolldown-build-aV0QeeTW.mjs +3264 -0
- package/templates/basic/node_modules/rolldown/dist/shared/rolldown-tbHvKzVl.mjs +40 -0
- package/templates/basic/node_modules/rolldown/dist/shared/transform-CEmFsvJW.d.mts +149 -0
- package/templates/basic/node_modules/rolldown/dist/shared/watch-DIhJ-T1s.mjs +374 -0
- package/templates/basic/node_modules/rolldown/dist/utils-index.d.mts +376 -0
- package/templates/basic/node_modules/rolldown/dist/utils-index.mjs +2414 -0
- package/templates/basic/node_modules/rolldown/package.json +153 -0
- package/templates/basic/node_modules/source-map-js/LICENSE +28 -0
- package/templates/basic/node_modules/source-map-js/README.md +765 -0
- package/templates/basic/node_modules/source-map-js/lib/array-set.js +121 -0
- package/templates/basic/node_modules/source-map-js/lib/base64-vlq.js +140 -0
- package/templates/basic/node_modules/source-map-js/lib/base64.js +67 -0
- package/templates/basic/node_modules/source-map-js/lib/binary-search.js +111 -0
- package/templates/basic/node_modules/source-map-js/lib/mapping-list.js +79 -0
- package/templates/basic/node_modules/source-map-js/lib/quick-sort.js +132 -0
- package/templates/basic/node_modules/source-map-js/lib/source-map-consumer.d.ts +1 -0
- package/templates/basic/node_modules/source-map-js/lib/source-map-consumer.js +1188 -0
- package/templates/basic/node_modules/source-map-js/lib/source-map-generator.d.ts +1 -0
- package/templates/basic/node_modules/source-map-js/lib/source-map-generator.js +444 -0
- package/templates/basic/node_modules/source-map-js/lib/source-node.d.ts +1 -0
- package/templates/basic/node_modules/source-map-js/lib/source-node.js +413 -0
- package/templates/basic/node_modules/source-map-js/lib/util.js +594 -0
- package/templates/basic/node_modules/source-map-js/package.json +71 -0
- package/templates/basic/node_modules/source-map-js/source-map.d.ts +104 -0
- package/templates/basic/node_modules/source-map-js/source-map.js +8 -0
- package/templates/basic/node_modules/tinyglobby/LICENSE +21 -0
- package/templates/basic/node_modules/tinyglobby/README.md +25 -0
- package/templates/basic/node_modules/tinyglobby/dist/index.cjs +335 -0
- package/templates/basic/node_modules/tinyglobby/dist/index.d.cts +148 -0
- package/templates/basic/node_modules/tinyglobby/dist/index.d.mts +148 -0
- package/templates/basic/node_modules/tinyglobby/dist/index.mjs +307 -0
- package/templates/basic/node_modules/tinyglobby/package.json +70 -0
- package/templates/basic/node_modules/typescript/LICENSE.txt +55 -0
- package/templates/basic/node_modules/typescript/README.md +50 -0
- package/templates/basic/node_modules/typescript/SECURITY.md +39 -0
- package/templates/basic/node_modules/typescript/ThirdPartyNoticeText.txt +193 -0
- package/templates/basic/node_modules/typescript/bin/tsc +2 -0
- package/templates/basic/node_modules/typescript/bin/tsserver +2 -0
- package/templates/basic/node_modules/typescript/lib/_tsc.js +134465 -0
- package/templates/basic/node_modules/typescript/lib/_tsserver.js +659 -0
- package/templates/basic/node_modules/typescript/lib/_typingsInstaller.js +222 -0
- package/templates/basic/node_modules/typescript/lib/cs/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/de/diagnosticMessages.generated.json +2125 -0
- package/templates/basic/node_modules/typescript/lib/es/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/fr/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/it/diagnosticMessages.generated.json +2125 -0
- package/templates/basic/node_modules/typescript/lib/ja/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/ko/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/lib.d.ts +20 -0
- package/templates/basic/node_modules/typescript/lib/lib.decorators.d.ts +382 -0
- package/templates/basic/node_modules/typescript/lib/lib.decorators.legacy.d.ts +20 -0
- package/templates/basic/node_modules/typescript/lib/lib.dom.asynciterable.d.ts +18 -0
- package/templates/basic/node_modules/typescript/lib/lib.dom.d.ts +45125 -0
- package/templates/basic/node_modules/typescript/lib/lib.dom.iterable.d.ts +18 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.collection.d.ts +150 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.core.d.ts +595 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.d.ts +26 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.generator.d.ts +75 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.iterable.d.ts +603 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.promise.d.ts +79 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.proxy.d.ts +126 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.reflect.d.ts +142 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.symbol.d.ts +44 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts +324 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2016.array.include.d.ts +114 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2016.d.ts +19 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2016.full.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2016.intl.d.ts +29 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.arraybuffer.d.ts +19 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.d.ts +24 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.date.d.ts +29 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.full.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.intl.d.ts +42 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.object.d.ts +47 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts +133 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.string.d.ts +43 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts +51 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts +75 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts +51 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.intl.d.ts +81 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.promise.d.ts +28 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2018.regexp.d.ts +35 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.array.d.ts +77 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.intl.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.object.d.ts +31 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.string.d.ts +35 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2019.symbol.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.bigint.d.ts +763 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.d.ts +25 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.date.d.ts +40 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.intl.d.ts +472 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.number.d.ts +26 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.promise.d.ts +45 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts +97 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.string.d.ts +42 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts +39 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2021.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2021.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2021.intl.d.ts +164 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2021.promise.d.ts +46 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2021.string.d.ts +31 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2021.weakref.d.ts +76 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.array.d.ts +119 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.d.ts +23 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.error.d.ts +73 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.intl.d.ts +143 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.object.d.ts +24 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.regexp.d.ts +37 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2022.string.d.ts +23 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2023.array.d.ts +922 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2023.collection.d.ts +19 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2023.d.ts +20 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2023.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2023.intl.d.ts +62 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.arraybuffer.d.ts +63 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.collection.d.ts +27 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.d.ts +24 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.object.d.ts +27 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.promise.d.ts +33 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.regexp.d.ts +23 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.sharedmemory.d.ts +66 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2024.string.d.ts +27 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.collection.d.ts +94 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.d.ts +23 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.float16.d.ts +443 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.intl.d.ts +200 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.iterator.d.ts +146 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.promise.d.ts +32 -0
- package/templates/basic/node_modules/typescript/lib/lib.es2025.regexp.d.ts +30 -0
- package/templates/basic/node_modules/typescript/lib/lib.es5.d.ts +4599 -0
- package/templates/basic/node_modules/typescript/lib/lib.es6.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.array.d.ts +33 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.collection.d.ts +47 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.d.ts +27 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.date.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.decorators.d.ts +26 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.disposable.d.ts +191 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.error.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.full.d.ts +22 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.intl.d.ts +107 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.sharedmemory.d.ts +23 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.temporal.d.ts +485 -0
- package/templates/basic/node_modules/typescript/lib/lib.esnext.typedarrays.d.ts +90 -0
- package/templates/basic/node_modules/typescript/lib/lib.scripthost.d.ts +320 -0
- package/templates/basic/node_modules/typescript/lib/lib.webworker.asynciterable.d.ts +18 -0
- package/templates/basic/node_modules/typescript/lib/lib.webworker.d.ts +15606 -0
- package/templates/basic/node_modules/typescript/lib/lib.webworker.importscripts.d.ts +21 -0
- package/templates/basic/node_modules/typescript/lib/lib.webworker.iterable.d.ts +18 -0
- package/templates/basic/node_modules/typescript/lib/pl/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/pt-br/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/ru/diagnosticMessages.generated.json +2125 -0
- package/templates/basic/node_modules/typescript/lib/tr/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/tsc.js +8 -0
- package/templates/basic/node_modules/typescript/lib/tsserver.js +8 -0
- package/templates/basic/node_modules/typescript/lib/tsserverlibrary.d.ts +17 -0
- package/templates/basic/node_modules/typescript/lib/tsserverlibrary.js +21 -0
- package/templates/basic/node_modules/typescript/lib/typesMap.json +497 -0
- package/templates/basic/node_modules/typescript/lib/typescript.d.ts +11448 -0
- package/templates/basic/node_modules/typescript/lib/typescript.js +201039 -0
- package/templates/basic/node_modules/typescript/lib/typingsInstaller.js +8 -0
- package/templates/basic/node_modules/typescript/lib/watchGuard.js +53 -0
- package/templates/basic/node_modules/typescript/lib/zh-cn/diagnosticMessages.generated.json +2129 -0
- package/templates/basic/node_modules/typescript/lib/zh-tw/diagnosticMessages.generated.json +2125 -0
- package/templates/basic/node_modules/typescript/package.json +118 -0
- package/templates/basic/node_modules/vite/LICENSE.md +2287 -0
- package/templates/basic/node_modules/vite/README.md +20 -0
- package/templates/basic/node_modules/vite/bin/openChrome.js +68 -0
- package/templates/basic/node_modules/vite/bin/vite.js +79 -0
- package/templates/basic/node_modules/vite/client.d.ts +285 -0
- package/templates/basic/node_modules/vite/dist/client/client.mjs +1269 -0
- package/templates/basic/node_modules/vite/dist/client/env.mjs +18 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/build.js +5371 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/dist.js +6784 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/lib.js +371 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/logger.js +364 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/moduleRunnerTransport.d.ts +96 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/node.js +35836 -0
- package/templates/basic/node_modules/vite/dist/node/chunks/postcss-import.js +467 -0
- package/templates/basic/node_modules/vite/dist/node/cli.js +836 -0
- package/templates/basic/node_modules/vite/dist/node/index.d.ts +4011 -0
- package/templates/basic/node_modules/vite/dist/node/index.js +3 -0
- package/templates/basic/node_modules/vite/dist/node/internal.d.ts +2 -0
- package/templates/basic/node_modules/vite/dist/node/internal.js +2 -0
- package/templates/basic/node_modules/vite/dist/node/module-runner.d.ts +314 -0
- package/templates/basic/node_modules/vite/dist/node/module-runner.js +1274 -0
- package/templates/basic/node_modules/vite/misc/false.js +1 -0
- package/templates/basic/node_modules/vite/misc/true.js +1 -0
- package/templates/basic/node_modules/vite/package.json +194 -0
- package/templates/basic/node_modules/vite/types/customEvent.d.ts +79 -0
- package/templates/basic/node_modules/vite/types/hmrPayload.d.ts +80 -0
- package/templates/basic/node_modules/vite/types/hot.d.ts +39 -0
- package/templates/basic/node_modules/vite/types/import-meta.d.ts +5 -0
- package/templates/basic/node_modules/vite/types/importGlob.d.ts +131 -0
- package/templates/basic/node_modules/vite/types/importMeta.d.ts +30 -0
- package/templates/basic/node_modules/vite/types/internal/cssPreprocessorOptions.d.ts +44 -0
- package/templates/basic/node_modules/vite/types/internal/esbuildOptions.d.ts +28 -0
- package/templates/basic/node_modules/vite/types/internal/lightningcssOptions.d.ts +18 -0
- package/templates/basic/node_modules/vite/types/internal/rollupTypeCompat.d.ts +24 -0
- package/templates/basic/node_modules/vite/types/internal/terserOptions.d.ts +11 -0
- package/templates/basic/node_modules/vite/types/metadata.d.ts +47 -0
- package/templates/basic/package-lock.json +926 -0
- package/templates/basic/package.json +18 -0
- package/templates/basic/public/apple-touch-icon.png +0 -0
- package/templates/basic/public/favicon-16x16.png +0 -0
- package/templates/basic/public/favicon-32x32.png +0 -0
- package/templates/basic/public/favicon.ico +0 -0
- package/templates/basic/public/icon-192.png +0 -0
- package/templates/basic/public/icon-512.png +0 -0
- package/templates/basic/public/nuclo-logo.svg +24 -0
- package/templates/basic/public/site.webmanifest +23 -0
- package/templates/basic/src/app.ts +37 -0
- package/templates/basic/src/main.ts +5 -0
- package/templates/basic/src/styles.ts +85 -0
- package/templates/basic/tsconfig.json +23 -0
- package/templates/basic/vite.config.ts +3 -0
|
@@ -0,0 +1,404 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* nuclo styling type definitions — atomic, theme-aware, typed CSS-in-TS.
|
|
3
|
+
*
|
|
4
|
+
* This module is the single source of truth for the styling types. It lives in
|
|
5
|
+
* `types/` (shipped in the npm package alongside `dist/`) so that both the
|
|
6
|
+
* hand-written global declarations (`types/features/style.d.ts`) and the
|
|
7
|
+
* runtime implementation (`src/style/css.ts`) can import it — in the repo and
|
|
8
|
+
* in the published tarball alike. Do not move these into `src/`: `src/` is not
|
|
9
|
+
* published, and a d.ts import into it breaks every consumer's types.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
// ---------------------------------------------------------------------------
|
|
13
|
+
// Value types — keyword autocomplete without banning valid CSS.
|
|
14
|
+
// `Loose<"a" | "b">` suggests "a"/"b" but accepts any string.
|
|
15
|
+
// ---------------------------------------------------------------------------
|
|
16
|
+
type Loose<T extends string> = T | (string & {});
|
|
17
|
+
|
|
18
|
+
/** Length values: numbers become px (except unitless properties), strings pass through. */
|
|
19
|
+
export type Size = number | (string & {});
|
|
20
|
+
|
|
21
|
+
type Display = Loose<
|
|
22
|
+
| "block" | "inline" | "inline-block" | "flex" | "inline-flex"
|
|
23
|
+
| "grid" | "inline-grid" | "none" | "contents" | "flow-root"
|
|
24
|
+
| "table" | "table-cell" | "list-item"
|
|
25
|
+
>;
|
|
26
|
+
type Position = Loose<"static" | "relative" | "absolute" | "fixed" | "sticky">;
|
|
27
|
+
type Overflow = Loose<"visible" | "hidden" | "clip" | "scroll" | "auto">;
|
|
28
|
+
type TextAlign = Loose<"left" | "right" | "center" | "justify" | "start" | "end">;
|
|
29
|
+
type FontWeight = number | Loose<"normal" | "bold" | "lighter" | "bolder" | "400" | "500" | "600" | "700">;
|
|
30
|
+
type AlignItems = Loose<"stretch" | "center" | "start" | "end" | "flex-start" | "flex-end" | "baseline">;
|
|
31
|
+
type JustifyContent = Loose<
|
|
32
|
+
| "center" | "start" | "end" | "flex-start" | "flex-end"
|
|
33
|
+
| "space-between" | "space-around" | "space-evenly" | "stretch"
|
|
34
|
+
>;
|
|
35
|
+
type FlexDirection = Loose<"row" | "row-reverse" | "column" | "column-reverse">;
|
|
36
|
+
type FlexWrap = Loose<"nowrap" | "wrap" | "wrap-reverse">;
|
|
37
|
+
type BorderStyle = Loose<"none" | "solid" | "dashed" | "dotted" | "double" | "hidden">;
|
|
38
|
+
type Cursor = Loose<
|
|
39
|
+
| "auto" | "default" | "pointer" | "grab" | "grabbing" | "text" | "move"
|
|
40
|
+
| "not-allowed" | "wait" | "crosshair" | "zoom-in" | "zoom-out"
|
|
41
|
+
>;
|
|
42
|
+
type ObjectFit = Loose<"fill" | "contain" | "cover" | "none" | "scale-down">;
|
|
43
|
+
type UserSelect = Loose<"none" | "auto" | "text" | "all" | "contain">;
|
|
44
|
+
type PointerEvents = Loose<"auto" | "none">;
|
|
45
|
+
type WhiteSpace = Loose<"normal" | "nowrap" | "pre" | "pre-wrap" | "pre-line" | "break-spaces">;
|
|
46
|
+
type TextTransform = Loose<"none" | "capitalize" | "uppercase" | "lowercase">;
|
|
47
|
+
type BoxSizing = Loose<"border-box" | "content-box">;
|
|
48
|
+
type Visibility = Loose<"visible" | "hidden" | "collapse">;
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Plain CSS properties (camelCase, converted to kebab-case at runtime).
|
|
52
|
+
* Color/font/shadow/radius properties live in TokenProps so they pick up theme tokens.
|
|
53
|
+
*/
|
|
54
|
+
export interface CSSProperties {
|
|
55
|
+
// Layout
|
|
56
|
+
display?: Display;
|
|
57
|
+
position?: Position;
|
|
58
|
+
inset?: Size;
|
|
59
|
+
top?: Size;
|
|
60
|
+
right?: Size;
|
|
61
|
+
bottom?: Size;
|
|
62
|
+
left?: Size;
|
|
63
|
+
zIndex?: number | "auto";
|
|
64
|
+
boxSizing?: BoxSizing;
|
|
65
|
+
aspectRatio?: Size;
|
|
66
|
+
overflow?: Overflow;
|
|
67
|
+
overflowX?: Overflow;
|
|
68
|
+
overflowY?: Overflow;
|
|
69
|
+
visibility?: Visibility;
|
|
70
|
+
objectFit?: ObjectFit;
|
|
71
|
+
objectPosition?: string;
|
|
72
|
+
isolation?: Loose<"auto" | "isolate">;
|
|
73
|
+
float?: Loose<"none" | "left" | "right" | "inline-start" | "inline-end">;
|
|
74
|
+
clear?: Loose<"none" | "left" | "right" | "both" | "inline-start" | "inline-end">;
|
|
75
|
+
|
|
76
|
+
// Flex / grid
|
|
77
|
+
flex?: Size;
|
|
78
|
+
flexDirection?: FlexDirection;
|
|
79
|
+
flexWrap?: FlexWrap;
|
|
80
|
+
flexGrow?: number;
|
|
81
|
+
flexShrink?: number;
|
|
82
|
+
flexBasis?: Size;
|
|
83
|
+
order?: number;
|
|
84
|
+
alignItems?: AlignItems;
|
|
85
|
+
alignContent?: JustifyContent;
|
|
86
|
+
alignSelf?: AlignItems | "auto";
|
|
87
|
+
justifyContent?: JustifyContent;
|
|
88
|
+
justifyItems?: AlignItems;
|
|
89
|
+
justifySelf?: AlignItems | "auto";
|
|
90
|
+
placeItems?: string;
|
|
91
|
+
placeContent?: string;
|
|
92
|
+
placeSelf?: string;
|
|
93
|
+
gap?: Size;
|
|
94
|
+
rowGap?: Size;
|
|
95
|
+
columnGap?: Size;
|
|
96
|
+
gridTemplateColumns?: string;
|
|
97
|
+
gridTemplateRows?: string;
|
|
98
|
+
gridTemplateAreas?: string;
|
|
99
|
+
gridColumn?: Size;
|
|
100
|
+
gridRow?: Size;
|
|
101
|
+
gridArea?: string;
|
|
102
|
+
gridAutoFlow?: Loose<"row" | "column" | "dense" | "row dense" | "column dense">;
|
|
103
|
+
gridAutoRows?: Size;
|
|
104
|
+
gridAutoColumns?: Size;
|
|
105
|
+
|
|
106
|
+
// Spacing / sizing (full names; short aliases in ShorthandProps)
|
|
107
|
+
padding?: Size;
|
|
108
|
+
paddingTop?: Size;
|
|
109
|
+
paddingRight?: Size;
|
|
110
|
+
paddingBottom?: Size;
|
|
111
|
+
paddingLeft?: Size;
|
|
112
|
+
margin?: Size;
|
|
113
|
+
marginTop?: Size;
|
|
114
|
+
marginRight?: Size;
|
|
115
|
+
marginBottom?: Size;
|
|
116
|
+
marginLeft?: Size;
|
|
117
|
+
width?: Size;
|
|
118
|
+
height?: Size;
|
|
119
|
+
minWidth?: Size;
|
|
120
|
+
minHeight?: Size;
|
|
121
|
+
maxWidth?: Size;
|
|
122
|
+
maxHeight?: Size;
|
|
123
|
+
|
|
124
|
+
// Typography
|
|
125
|
+
fontSize?: Size;
|
|
126
|
+
fontStyle?: Loose<"normal" | "italic" | "oblique">;
|
|
127
|
+
fontWeight?: FontWeight;
|
|
128
|
+
lineHeight?: Size;
|
|
129
|
+
letterSpacing?: Size;
|
|
130
|
+
textAlign?: TextAlign;
|
|
131
|
+
textTransform?: TextTransform;
|
|
132
|
+
textDecoration?: Loose<"none" | "underline" | "overline" | "line-through">;
|
|
133
|
+
textDecorationLine?: Loose<"none" | "underline" | "overline" | "line-through">;
|
|
134
|
+
textDecorationStyle?: Loose<"solid" | "double" | "dotted" | "dashed" | "wavy">;
|
|
135
|
+
textDecorationThickness?: Size;
|
|
136
|
+
textUnderlineOffset?: Size;
|
|
137
|
+
textOverflow?: Loose<"clip" | "ellipsis">;
|
|
138
|
+
textShadow?: string;
|
|
139
|
+
textIndent?: Size;
|
|
140
|
+
whiteSpace?: WhiteSpace;
|
|
141
|
+
wordBreak?: Loose<"normal" | "break-all" | "keep-all" | "break-word">;
|
|
142
|
+
overflowWrap?: Loose<"normal" | "break-word" | "anywhere">;
|
|
143
|
+
verticalAlign?: Loose<"baseline" | "top" | "middle" | "bottom" | "text-top" | "text-bottom">;
|
|
144
|
+
fontVariantNumeric?: string;
|
|
145
|
+
fontFeatureSettings?: string;
|
|
146
|
+
|
|
147
|
+
// Border / outline (colors + radius in TokenProps)
|
|
148
|
+
border?: string;
|
|
149
|
+
borderTop?: string;
|
|
150
|
+
borderRight?: string;
|
|
151
|
+
borderBottom?: string;
|
|
152
|
+
borderLeft?: string;
|
|
153
|
+
borderWidth?: Size;
|
|
154
|
+
borderStyle?: BorderStyle;
|
|
155
|
+
outline?: string;
|
|
156
|
+
outlineWidth?: Size;
|
|
157
|
+
outlineStyle?: BorderStyle;
|
|
158
|
+
outlineOffset?: Size;
|
|
159
|
+
|
|
160
|
+
// Background (color in TokenProps via `bg`)
|
|
161
|
+
backgroundImage?: string;
|
|
162
|
+
backgroundSize?: Loose<"auto" | "cover" | "contain">;
|
|
163
|
+
backgroundPosition?: string;
|
|
164
|
+
backgroundRepeat?: Loose<"repeat" | "no-repeat" | "repeat-x" | "repeat-y" | "round" | "space">;
|
|
165
|
+
backgroundAttachment?: Loose<"scroll" | "fixed" | "local">;
|
|
166
|
+
backgroundClip?: Loose<"border-box" | "padding-box" | "content-box" | "text">;
|
|
167
|
+
|
|
168
|
+
// Effects
|
|
169
|
+
opacity?: number | string;
|
|
170
|
+
filter?: string;
|
|
171
|
+
backdropFilter?: string;
|
|
172
|
+
mixBlendMode?: string;
|
|
173
|
+
transform?: string;
|
|
174
|
+
transformOrigin?: string;
|
|
175
|
+
transition?: string;
|
|
176
|
+
transitionProperty?: string;
|
|
177
|
+
transitionDuration?: string;
|
|
178
|
+
transitionTimingFunction?: string;
|
|
179
|
+
transitionDelay?: string;
|
|
180
|
+
animation?: string;
|
|
181
|
+
willChange?: string;
|
|
182
|
+
clipPath?: string;
|
|
183
|
+
|
|
184
|
+
// Interaction
|
|
185
|
+
cursor?: Cursor;
|
|
186
|
+
pointerEvents?: PointerEvents;
|
|
187
|
+
userSelect?: UserSelect;
|
|
188
|
+
touchAction?: string;
|
|
189
|
+
resize?: Loose<"none" | "both" | "horizontal" | "vertical">;
|
|
190
|
+
scrollBehavior?: Loose<"auto" | "smooth">;
|
|
191
|
+
scrollSnapType?: string;
|
|
192
|
+
scrollSnapAlign?: string;
|
|
193
|
+
appearance?: Loose<"none" | "auto">;
|
|
194
|
+
accentColor?: string;
|
|
195
|
+
|
|
196
|
+
// Misc
|
|
197
|
+
content?: string;
|
|
198
|
+
listStyle?: string;
|
|
199
|
+
tableLayout?: Loose<"auto" | "fixed">;
|
|
200
|
+
borderCollapse?: Loose<"collapse" | "separate">;
|
|
201
|
+
borderSpacing?: Size;
|
|
202
|
+
colorScheme?: Loose<"light" | "dark" | "light dark">;
|
|
203
|
+
containerType?: Loose<"normal" | "size" | "inline-size">;
|
|
204
|
+
containerName?: string;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
// ---------------------------------------------------------------------------
|
|
208
|
+
// Theme
|
|
209
|
+
// ---------------------------------------------------------------------------
|
|
210
|
+
export interface ThemeConfig {
|
|
211
|
+
/** Color tokens — usable in bg, color, borderColor, outlineColor, caretColor, textDecorationColor. */
|
|
212
|
+
colors?: Record<string, string>;
|
|
213
|
+
/** Font-family tokens — usable in font / fontFamily. */
|
|
214
|
+
fonts?: Record<string, string>;
|
|
215
|
+
/** Box-shadow tokens — usable in shadow / boxShadow. */
|
|
216
|
+
shadows?: Record<string, string>;
|
|
217
|
+
/** Border-radius tokens — usable in rounded / borderRadius. */
|
|
218
|
+
radii?: Record<string, string>;
|
|
219
|
+
/**
|
|
220
|
+
* Responsive variants: name → media condition ("(min-width: 768px)")
|
|
221
|
+
* or a full at-rule prelude ("@container (min-width: 400px)").
|
|
222
|
+
* Declaration order = cascade order. Names must not collide with property names.
|
|
223
|
+
*/
|
|
224
|
+
screens?: Record<string, string>;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
type Tokens<T extends ThemeConfig, K extends keyof ThemeConfig> =
|
|
228
|
+
T[K] extends Record<string, string> ? Extract<keyof T[K], string> : never;
|
|
229
|
+
|
|
230
|
+
/** Properties whose string values resolve against theme tokens. */
|
|
231
|
+
interface TokenProps<T extends ThemeConfig> {
|
|
232
|
+
/** background — color token, color, gradient, or any CSS background shorthand */
|
|
233
|
+
bg?: Loose<Tokens<T, "colors">>;
|
|
234
|
+
backgroundColor?: Loose<Tokens<T, "colors">>;
|
|
235
|
+
color?: Loose<Tokens<T, "colors">>;
|
|
236
|
+
borderColor?: Loose<Tokens<T, "colors">>;
|
|
237
|
+
borderTopColor?: Loose<Tokens<T, "colors">>;
|
|
238
|
+
borderRightColor?: Loose<Tokens<T, "colors">>;
|
|
239
|
+
borderBottomColor?: Loose<Tokens<T, "colors">>;
|
|
240
|
+
borderLeftColor?: Loose<Tokens<T, "colors">>;
|
|
241
|
+
outlineColor?: Loose<Tokens<T, "colors">>;
|
|
242
|
+
caretColor?: Loose<Tokens<T, "colors">>;
|
|
243
|
+
textDecorationColor?: Loose<Tokens<T, "colors">>;
|
|
244
|
+
/** font-family — token or font stack */
|
|
245
|
+
font?: Loose<Tokens<T, "fonts">>;
|
|
246
|
+
fontFamily?: Loose<Tokens<T, "fonts">>;
|
|
247
|
+
/** box-shadow — token or raw value */
|
|
248
|
+
shadow?: Loose<Tokens<T, "shadows">>;
|
|
249
|
+
boxShadow?: Loose<Tokens<T, "shadows">>;
|
|
250
|
+
/** border-radius — token, number (px), or raw value */
|
|
251
|
+
rounded?: Tokens<T, "radii"> | Size;
|
|
252
|
+
borderRadius?: Tokens<T, "radii"> | Size;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
/** Tailwind-flavored short aliases. */
|
|
256
|
+
interface ShorthandProps {
|
|
257
|
+
/** padding */ p?: Size;
|
|
258
|
+
/** padding-left + padding-right */ px?: Size;
|
|
259
|
+
/** padding-top + padding-bottom */ py?: Size;
|
|
260
|
+
pt?: Size; pr?: Size; pb?: Size; pl?: Size;
|
|
261
|
+
/** margin */ m?: Size;
|
|
262
|
+
/** margin-left + margin-right */ mx?: Size;
|
|
263
|
+
/** margin-top + margin-bottom */ my?: Size;
|
|
264
|
+
mt?: Size; mr?: Size; mb?: Size; ml?: Size;
|
|
265
|
+
/** width */ w?: Size;
|
|
266
|
+
/** height */ h?: Size;
|
|
267
|
+
minW?: Size; maxW?: Size; minH?: Size; maxH?: Size;
|
|
268
|
+
/** width + height */ size?: Size;
|
|
269
|
+
/** font-size */ text?: Size;
|
|
270
|
+
/** font-weight */ weight?: FontWeight;
|
|
271
|
+
/** line-height */ leading?: Size;
|
|
272
|
+
/** letter-spacing */ tracking?: Size;
|
|
273
|
+
/** text-align */ align?: TextAlign;
|
|
274
|
+
/** align-items */ items?: AlignItems;
|
|
275
|
+
/** justify-content */ justify?: JustifyContent;
|
|
276
|
+
/** z-index */ z?: number | "auto";
|
|
277
|
+
/** user-select */ select?: UserSelect;
|
|
278
|
+
|
|
279
|
+
// Composite utilities (value must be `true`)
|
|
280
|
+
/** display:flex + flex-direction:row */ row?: boolean;
|
|
281
|
+
/** display:flex + flex-direction:column */ col?: boolean;
|
|
282
|
+
/** align-items:center + justify-content:center */ center?: boolean;
|
|
283
|
+
/** overflow:hidden + text-overflow:ellipsis + white-space:nowrap */ truncate?: boolean;
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
/**
|
|
287
|
+
* Pseudo-class / pseudo-element variant keys usable inside style objects.
|
|
288
|
+
* The runtime selector for each key lives in the `PSEUDO` table in
|
|
289
|
+
* `src/style/css.ts`, which is typed `satisfies Record<Pseudo, string>` —
|
|
290
|
+
* adding a key on either side without the other is a compile error.
|
|
291
|
+
*/
|
|
292
|
+
export type Pseudo =
|
|
293
|
+
| "hover" | "focus" | "focusVisible" | "focusWithin" | "active" | "visited"
|
|
294
|
+
| "disabled" | "enabled" | "checked" | "required" | "invalid" | "valid"
|
|
295
|
+
| "readOnly" | "first" | "last" | "only" | "odd" | "even" | "empty"
|
|
296
|
+
| "placeholderShown" | "placeholder" | "before" | "after" | "selection"
|
|
297
|
+
| "marker" | "firstLine" | "firstLetter";
|
|
298
|
+
|
|
299
|
+
/** Flat style: properties only, no variant nesting (used by keyframes/globalStyle). */
|
|
300
|
+
export type FlatStyle<T extends ThemeConfig = ThemeConfig> =
|
|
301
|
+
TokenProps<T> & ShorthandProps & CSSProperties & {
|
|
302
|
+
/** Escape hatch: raw CSS declarations, property names passed through as-is. */
|
|
303
|
+
raw?: Record<string, string | number>;
|
|
304
|
+
};
|
|
305
|
+
|
|
306
|
+
/**
|
|
307
|
+
* Keyframe selectors: `from`, `to`, and percentage stops autocomplete; any other
|
|
308
|
+
* string (e.g. a comma-separated list like "0%, 100%") is still accepted.
|
|
309
|
+
*/
|
|
310
|
+
export type KeyframeStop = "from" | "to" | `${number}%`;
|
|
311
|
+
|
|
312
|
+
/** Frames passed to keyframes(): selector → flat declarations. */
|
|
313
|
+
export type KeyframeFrames<T extends ThemeConfig = ThemeConfig> =
|
|
314
|
+
& { [Stop in KeyframeStop]?: FlatStyle<T> }
|
|
315
|
+
& { [stop: string]: FlatStyle<T> | undefined };
|
|
316
|
+
|
|
317
|
+
/**
|
|
318
|
+
* Full style object: properties + pseudo variants + theme screens +
|
|
319
|
+
* arbitrary selectors ("&:nth-child(2)", "& > svg") + inline at-rules
|
|
320
|
+
* ("@media (min-width: 768px)", "@container (…)", "@supports (…)").
|
|
321
|
+
*/
|
|
322
|
+
export type Style<T extends ThemeConfig = ThemeConfig> = FlatStyle<T>
|
|
323
|
+
& { [K in Pseudo]?: Style<T> }
|
|
324
|
+
& { [K in Tokens<T, "screens">]?: Style<T> }
|
|
325
|
+
& { [K in `&${string}`]?: Style<T> }
|
|
326
|
+
& { [K in `@${string}`]?: Style<T> };
|
|
327
|
+
|
|
328
|
+
// Type alias (not interface) so it keeps the implicit index signature that
|
|
329
|
+
// makes it assignable to ExpandedElementAttributes — usable directly as a
|
|
330
|
+
// nuclo attributes object.
|
|
331
|
+
export type StyleResult = {
|
|
332
|
+
className: string;
|
|
333
|
+
toString(): string;
|
|
334
|
+
};
|
|
335
|
+
|
|
336
|
+
// ---------------------------------------------------------------------------
|
|
337
|
+
// Variants — typed, atomic style recipes (base + named variant groups +
|
|
338
|
+
// defaults + compound variants). One recipe in, a call-with-props function out.
|
|
339
|
+
// ---------------------------------------------------------------------------
|
|
340
|
+
|
|
341
|
+
/** A map of variant groups: group name → variant value name → style object. */
|
|
342
|
+
export type VariantDefinitions<T extends ThemeConfig = ThemeConfig> =
|
|
343
|
+
Record<string, Record<string, Style<T>>>;
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* A group whose only values are "true"/"false" is selected with a real boolean;
|
|
347
|
+
* every other group is selected by its declared value names.
|
|
348
|
+
*/
|
|
349
|
+
type VariantValue<Keys extends PropertyKey> =
|
|
350
|
+
[Extract<Keys, string>] extends ["true" | "false"] ? boolean : Extract<Keys, string>;
|
|
351
|
+
|
|
352
|
+
/** Strongly-typed selection of variant values for a given variant definition. */
|
|
353
|
+
export type VariantProps<V extends VariantDefinitions> = {
|
|
354
|
+
[Group in keyof V]?: VariantValue<keyof V[Group]>;
|
|
355
|
+
};
|
|
356
|
+
|
|
357
|
+
/** Configuration object accepted by variants(). */
|
|
358
|
+
export interface VariantsConfig<T extends ThemeConfig, V extends VariantDefinitions<T>> {
|
|
359
|
+
/** Styles always applied, before any variant. */
|
|
360
|
+
base?: Style<T>;
|
|
361
|
+
/**
|
|
362
|
+
* Named variant groups: each value maps to a style object. `V` is inferred
|
|
363
|
+
* with its literal group/value names (so selection, defaults and compounds
|
|
364
|
+
* are strictly typed), and each style object is checked against `Style<T>`.
|
|
365
|
+
*/
|
|
366
|
+
variants?: V;
|
|
367
|
+
/** Variant values applied when a prop is omitted at the call site. */
|
|
368
|
+
defaultVariants?: VariantProps<NoInfer<V>>;
|
|
369
|
+
/** Extra styles applied when a specific combination of variants is active. */
|
|
370
|
+
compoundVariants?: Array<VariantProps<NoInfer<V>> & { css: Style<T> }>;
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
/** A compiled recipe: call with a selection to get a composed StyleResult. */
|
|
374
|
+
export type VariantsFn<V extends VariantDefinitions> = (props?: VariantProps<V>) => StyleResult;
|
|
375
|
+
|
|
376
|
+
/** Inputs accepted by cx(): results, raw class strings, falsy values, and nested arrays. */
|
|
377
|
+
export type ClassInput = StyleResult | string | false | null | undefined | readonly ClassInput[];
|
|
378
|
+
|
|
379
|
+
/** A themed styling instance returned by createCss(). */
|
|
380
|
+
export interface CssInstance<T extends ThemeConfig = ThemeConfig> {
|
|
381
|
+
/**
|
|
382
|
+
* Compile a style object into atomic CSS classes.
|
|
383
|
+
* Returns `{ className }` — usable directly as a nuclo attributes object.
|
|
384
|
+
*/
|
|
385
|
+
css(style: Style<T>): StyleResult;
|
|
386
|
+
/**
|
|
387
|
+
* Compose class lists with exact conflict resolution: when two inputs
|
|
388
|
+
* style the same (query, selector, property), the last one wins.
|
|
389
|
+
* Accepts results, raw class strings, nested arrays, and falsy values.
|
|
390
|
+
*/
|
|
391
|
+
cx(...inputs: ClassInput[]): StyleResult;
|
|
392
|
+
/**
|
|
393
|
+
* Compile a typed variants recipe (base + named variant groups + defaults
|
|
394
|
+
* + compound variants) into a call-with-props function returning a
|
|
395
|
+
* composed StyleResult. Variant names and values are inferred and checked.
|
|
396
|
+
*/
|
|
397
|
+
variants<const V extends VariantDefinitions<T>>(config: VariantsConfig<T, V>): VariantsFn<V>;
|
|
398
|
+
/** Register a @keyframes block; returns its generated animation name. */
|
|
399
|
+
keyframes(frames: KeyframeFrames<T>): string;
|
|
400
|
+
/** Global selector styles (body, resets). Flat properties only. */
|
|
401
|
+
globalStyle(selector: string, style: FlatStyle<T>): void;
|
|
402
|
+
/** The theme this instance was created with. */
|
|
403
|
+
theme: T;
|
|
404
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
declare global {
|
|
2
|
+
export type SVGAttributeValue<TValue = string | number | boolean | null | undefined> =
|
|
3
|
+
ValueOrFactory<TValue>;
|
|
4
|
+
|
|
5
|
+
// SVG attribute types that accept string values for all SVG properties
|
|
6
|
+
// This is needed because SVG DOM properties like 'width' are SVGAnimatedLength,
|
|
7
|
+
// but we set them as strings using setAttribute()
|
|
8
|
+
// Supports reactive values (functions) for dynamic attributes
|
|
9
|
+
export type SVGAttributes = {
|
|
10
|
+
// Common SVG attributes
|
|
11
|
+
width?: SVGAttributeValue<string | number>;
|
|
12
|
+
height?: SVGAttributeValue<string | number>;
|
|
13
|
+
viewBox?: SVGAttributeValue<string>;
|
|
14
|
+
fill?: SVGAttributeValue<string>;
|
|
15
|
+
stroke?: SVGAttributeValue<string>;
|
|
16
|
+
"stroke-width"?: SVGAttributeValue<string | number>;
|
|
17
|
+
"stroke-linecap"?: SVGAttributeValue<"butt" | "round" | "square">;
|
|
18
|
+
"stroke-linejoin"?: SVGAttributeValue<"miter" | "round" | "bevel">;
|
|
19
|
+
"stroke-dasharray"?: SVGAttributeValue<string>;
|
|
20
|
+
"stroke-dashoffset"?: SVGAttributeValue<string | number>;
|
|
21
|
+
opacity?: SVGAttributeValue<string | number>;
|
|
22
|
+
"fill-opacity"?: SVGAttributeValue<string | number>;
|
|
23
|
+
"stroke-opacity"?: SVGAttributeValue<string | number>;
|
|
24
|
+
transform?: SVGAttributeValue<string>;
|
|
25
|
+
className?: SVGAttributeValue<string>;
|
|
26
|
+
id?: SVGAttributeValue<string>;
|
|
27
|
+
|
|
28
|
+
// Path attributes
|
|
29
|
+
d?: SVGAttributeValue<string>;
|
|
30
|
+
|
|
31
|
+
// Circle/Ellipse attributes
|
|
32
|
+
cx?: SVGAttributeValue<string | number>;
|
|
33
|
+
cy?: SVGAttributeValue<string | number>;
|
|
34
|
+
r?: SVGAttributeValue<string | number>;
|
|
35
|
+
rx?: SVGAttributeValue<string | number>;
|
|
36
|
+
ry?: SVGAttributeValue<string | number>;
|
|
37
|
+
|
|
38
|
+
// Line attributes
|
|
39
|
+
x1?: SVGAttributeValue<string | number>;
|
|
40
|
+
y1?: SVGAttributeValue<string | number>;
|
|
41
|
+
x2?: SVGAttributeValue<string | number>;
|
|
42
|
+
y2?: SVGAttributeValue<string | number>;
|
|
43
|
+
|
|
44
|
+
// Rect attributes
|
|
45
|
+
x?: SVGAttributeValue<string | number>;
|
|
46
|
+
y?: SVGAttributeValue<string | number>;
|
|
47
|
+
|
|
48
|
+
// Polygon/Polyline attributes
|
|
49
|
+
points?: SVGAttributeValue<string>;
|
|
50
|
+
|
|
51
|
+
// Text attributes
|
|
52
|
+
"text-anchor"?: SVGAttributeValue<"start" | "middle" | "end">;
|
|
53
|
+
"dominant-baseline"?: SVGAttributeValue<string>;
|
|
54
|
+
"font-family"?: SVGAttributeValue<string>;
|
|
55
|
+
"font-size"?: SVGAttributeValue<string | number>;
|
|
56
|
+
"font-weight"?: SVGAttributeValue<string | number>;
|
|
57
|
+
|
|
58
|
+
// Gradient attributes
|
|
59
|
+
offset?: SVGAttributeValue<string>;
|
|
60
|
+
"stop-color"?: SVGAttributeValue<string>;
|
|
61
|
+
"stop-opacity"?: SVGAttributeValue<string | number>;
|
|
62
|
+
|
|
63
|
+
// Use element
|
|
64
|
+
href?: SVGAttributeValue<string>;
|
|
65
|
+
|
|
66
|
+
// Filter attributes
|
|
67
|
+
filter?: SVGAttributeValue<string>;
|
|
68
|
+
|
|
69
|
+
// Clipping and masking
|
|
70
|
+
"clip-path"?: SVGAttributeValue<string>;
|
|
71
|
+
mask?: SVGAttributeValue<string>;
|
|
72
|
+
|
|
73
|
+
// Allow any other string attributes (including reactive functions)
|
|
74
|
+
// Using a more restrictive type to maintain type safety
|
|
75
|
+
} & {
|
|
76
|
+
[K in string]?: SVGAttributeValue;
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
// SVG element modifier types
|
|
80
|
+
export type SVGRenderable<TTagName extends SVGTagName = SVGTagName> =
|
|
81
|
+
| Primitive
|
|
82
|
+
| SVGAttributes
|
|
83
|
+
| SVGElementTagNameMap[TTagName]
|
|
84
|
+
| SVGElement
|
|
85
|
+
| Node;
|
|
86
|
+
|
|
87
|
+
export type SVGElementModifier<TTagName extends keyof SVGElementTagNameMap = keyof SVGElementTagNameMap> =
|
|
88
|
+
| SVGRenderable<TTagName>
|
|
89
|
+
| ValueFactory<Primitive>
|
|
90
|
+
| ((parent: SVGElementTagNameMap[TTagName], index: number) => SVGElement | Node); // Allow SVG element and Node builders as children
|
|
91
|
+
|
|
92
|
+
export type SVGElementModifierFn<TTagName extends keyof SVGElementTagNameMap = keyof SVGElementTagNameMap> = (
|
|
93
|
+
parent: SVGElementTagNameMap[TTagName],
|
|
94
|
+
index: number,
|
|
95
|
+
) => SVGElementModifier<TTagName> | Node | void;
|
|
96
|
+
|
|
97
|
+
export type SVGElementModifierLike<TTagName extends SVGTagName = SVGTagName> =
|
|
98
|
+
| SVGElementModifier<TTagName>
|
|
99
|
+
| SVGElementModifierFn<TTagName>;
|
|
100
|
+
|
|
101
|
+
export type DetachedSVGElementFactory<
|
|
102
|
+
TTagName extends SVGTagName = SVGTagName,
|
|
103
|
+
> = SVGElementModifierFn<TTagName> & ((
|
|
104
|
+
parent?: SVGElementTagNameMap[TTagName] | ExpandedElement<ElementTagName>,
|
|
105
|
+
index?: number,
|
|
106
|
+
) => SVGElementTagNameMap[TTagName]);
|
|
107
|
+
|
|
108
|
+
// SVG builder type - returns a NodeModFn-compatible function
|
|
109
|
+
// Parameters are optional to allow standalone usage (e.g., svg()() for creating detached SVG)
|
|
110
|
+
// but the function signature is compatible with NodeModFn when used as a child
|
|
111
|
+
export type ExpandedSVGElementBuilder<
|
|
112
|
+
TTagName extends keyof SVGElementTagNameMap = keyof SVGElementTagNameMap,
|
|
113
|
+
> = (
|
|
114
|
+
...rawMods: readonly SVGElementModifierLike<TTagName>[]
|
|
115
|
+
) => DetachedSVGElementFactory<TTagName>;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export {};
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
declare global {
|
|
2
|
+
// SVG tags - all use Svg suffix
|
|
3
|
+
export const aSvg: ExpandedSVGElementBuilder<"a">;
|
|
4
|
+
export const animateSvg: ExpandedSVGElementBuilder<"animate">;
|
|
5
|
+
export const animateMotionSvg: ExpandedSVGElementBuilder<"animateMotion">;
|
|
6
|
+
export const animateTransformSvg: ExpandedSVGElementBuilder<"animateTransform">;
|
|
7
|
+
export const circleSvg: ExpandedSVGElementBuilder<"circle">;
|
|
8
|
+
export const clipPathSvg: ExpandedSVGElementBuilder<"clipPath">;
|
|
9
|
+
export const defsSvg: ExpandedSVGElementBuilder<"defs">;
|
|
10
|
+
export const descSvg: ExpandedSVGElementBuilder<"desc">;
|
|
11
|
+
export const ellipseSvg: ExpandedSVGElementBuilder<"ellipse">;
|
|
12
|
+
export const feBlendSvg: ExpandedSVGElementBuilder<"feBlend">;
|
|
13
|
+
export const feColorMatrixSvg: ExpandedSVGElementBuilder<"feColorMatrix">;
|
|
14
|
+
export const feComponentTransferSvg: ExpandedSVGElementBuilder<"feComponentTransfer">;
|
|
15
|
+
export const feCompositeSvg: ExpandedSVGElementBuilder<"feComposite">;
|
|
16
|
+
export const feConvolveMatrixSvg: ExpandedSVGElementBuilder<"feConvolveMatrix">;
|
|
17
|
+
export const feDiffuseLightingSvg: ExpandedSVGElementBuilder<"feDiffuseLighting">;
|
|
18
|
+
export const feDisplacementMapSvg: ExpandedSVGElementBuilder<"feDisplacementMap">;
|
|
19
|
+
export const feDistantLightSvg: ExpandedSVGElementBuilder<"feDistantLight">;
|
|
20
|
+
export const feDropShadowSvg: ExpandedSVGElementBuilder<"feDropShadow">;
|
|
21
|
+
export const feFloodSvg: ExpandedSVGElementBuilder<"feFlood">;
|
|
22
|
+
export const feFuncASvg: ExpandedSVGElementBuilder<"feFuncA">;
|
|
23
|
+
export const feFuncBSvg: ExpandedSVGElementBuilder<"feFuncB">;
|
|
24
|
+
export const feFuncGSvg: ExpandedSVGElementBuilder<"feFuncG">;
|
|
25
|
+
export const feFuncRSvg: ExpandedSVGElementBuilder<"feFuncR">;
|
|
26
|
+
export const feGaussianBlurSvg: ExpandedSVGElementBuilder<"feGaussianBlur">;
|
|
27
|
+
export const feImageSvg: ExpandedSVGElementBuilder<"feImage">;
|
|
28
|
+
export const feMergeSvg: ExpandedSVGElementBuilder<"feMerge">;
|
|
29
|
+
export const feMergeNodeSvg: ExpandedSVGElementBuilder<"feMergeNode">;
|
|
30
|
+
export const feMorphologySvg: ExpandedSVGElementBuilder<"feMorphology">;
|
|
31
|
+
export const feOffsetSvg: ExpandedSVGElementBuilder<"feOffset">;
|
|
32
|
+
export const fePointLightSvg: ExpandedSVGElementBuilder<"fePointLight">;
|
|
33
|
+
export const feSpecularLightingSvg: ExpandedSVGElementBuilder<"feSpecularLighting">;
|
|
34
|
+
export const feSpotLightSvg: ExpandedSVGElementBuilder<"feSpotLight">;
|
|
35
|
+
export const feTileSvg: ExpandedSVGElementBuilder<"feTile">;
|
|
36
|
+
export const feTurbulenceSvg: ExpandedSVGElementBuilder<"feTurbulence">;
|
|
37
|
+
export const filterSvg: ExpandedSVGElementBuilder<"filter">;
|
|
38
|
+
export const foreignObjectSvg: ExpandedSVGElementBuilder<"foreignObject">;
|
|
39
|
+
export const gSvg: ExpandedSVGElementBuilder<"g">;
|
|
40
|
+
export const imageSvg: ExpandedSVGElementBuilder<"image">;
|
|
41
|
+
export const lineSvg: ExpandedSVGElementBuilder<"line">;
|
|
42
|
+
export const linearGradientSvg: ExpandedSVGElementBuilder<"linearGradient">;
|
|
43
|
+
export const markerSvg: ExpandedSVGElementBuilder<"marker">;
|
|
44
|
+
export const maskSvg: ExpandedSVGElementBuilder<"mask">;
|
|
45
|
+
export const metadataSvg: ExpandedSVGElementBuilder<"metadata">;
|
|
46
|
+
export const mpathSvg: ExpandedSVGElementBuilder<"mpath">;
|
|
47
|
+
export const pathSvg: ExpandedSVGElementBuilder<"path">;
|
|
48
|
+
export const patternSvg: ExpandedSVGElementBuilder<"pattern">;
|
|
49
|
+
export const polygonSvg: ExpandedSVGElementBuilder<"polygon">;
|
|
50
|
+
export const polylineSvg: ExpandedSVGElementBuilder<"polyline">;
|
|
51
|
+
export const radialGradientSvg: ExpandedSVGElementBuilder<"radialGradient">;
|
|
52
|
+
export const rectSvg: ExpandedSVGElementBuilder<"rect">;
|
|
53
|
+
export const scriptSvg: ExpandedSVGElementBuilder<"script">;
|
|
54
|
+
export const setSvg: ExpandedSVGElementBuilder<"set">;
|
|
55
|
+
export const stopSvg: ExpandedSVGElementBuilder<"stop">;
|
|
56
|
+
export const styleSvg: ExpandedSVGElementBuilder<"style">;
|
|
57
|
+
export const svgSvg: ExpandedSVGElementBuilder<"svg">;
|
|
58
|
+
export const switchSvg: ExpandedSVGElementBuilder<"switch">;
|
|
59
|
+
export const symbolSvg: ExpandedSVGElementBuilder<"symbol">;
|
|
60
|
+
export const textSvg: ExpandedSVGElementBuilder<"text">;
|
|
61
|
+
export const textPathSvg: ExpandedSVGElementBuilder<"textPath">;
|
|
62
|
+
export const titleSvg: ExpandedSVGElementBuilder<"title">;
|
|
63
|
+
export const tspanSvg: ExpandedSVGElementBuilder<"tspan">;
|
|
64
|
+
export const useSvg: ExpandedSVGElementBuilder<"use">;
|
|
65
|
+
export const viewSvg: ExpandedSVGElementBuilder<"view">;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
ISC License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2021-2024 Oleksii Raspopov, Kostiantyn Denysov, Anton Verinov
|
|
4
|
+
|
|
5
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
+
purpose with or without fee is hereby granted, provided that the above
|
|
7
|
+
copyright notice and this permission notice appear in all copies.
|
|
8
|
+
|
|
9
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
10
|
+
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
11
|
+
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
12
|
+
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
13
|
+
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
14
|
+
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
15
|
+
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# picocolors
|
|
2
|
+
|
|
3
|
+
The tiniest and the fastest library for terminal output formatting with ANSI colors.
|
|
4
|
+
|
|
5
|
+
```javascript
|
|
6
|
+
import pc from "picocolors"
|
|
7
|
+
|
|
8
|
+
console.log(
|
|
9
|
+
pc.green(`How are ${pc.italic(`you`)} doing?`)
|
|
10
|
+
)
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
- **No dependencies.**
|
|
14
|
+
- **14 times** smaller and **2 times** faster than chalk.
|
|
15
|
+
- Used by popular tools like PostCSS, SVGO, Stylelint, and Browserslist.
|
|
16
|
+
- Node.js v6+ & browsers support. Support for both CJS and ESM projects.
|
|
17
|
+
- TypeScript type declarations included.
|
|
18
|
+
- [`NO_COLOR`](https://no-color.org/) friendly.
|
|
19
|
+
|
|
20
|
+
## Docs
|
|
21
|
+
Read **[full docs](https://github.com/alexeyraspopov/picocolors#readme)** on GitHub.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "picocolors",
|
|
3
|
+
"version": "1.1.1",
|
|
4
|
+
"main": "./picocolors.js",
|
|
5
|
+
"types": "./picocolors.d.ts",
|
|
6
|
+
"browser": {
|
|
7
|
+
"./picocolors.js": "./picocolors.browser.js"
|
|
8
|
+
},
|
|
9
|
+
"sideEffects": false,
|
|
10
|
+
"description": "The tiniest and the fastest library for terminal output formatting with ANSI colors",
|
|
11
|
+
"files": [
|
|
12
|
+
"picocolors.*",
|
|
13
|
+
"types.d.ts"
|
|
14
|
+
],
|
|
15
|
+
"keywords": [
|
|
16
|
+
"terminal",
|
|
17
|
+
"colors",
|
|
18
|
+
"formatting",
|
|
19
|
+
"cli",
|
|
20
|
+
"console"
|
|
21
|
+
],
|
|
22
|
+
"author": "Alexey Raspopov",
|
|
23
|
+
"repository": "alexeyraspopov/picocolors",
|
|
24
|
+
"license": "ISC"
|
|
25
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
var x=String;
|
|
2
|
+
var create=function() {return {isColorSupported:false,reset:x,bold:x,dim:x,italic:x,underline:x,inverse:x,hidden:x,strikethrough:x,black:x,red:x,green:x,yellow:x,blue:x,magenta:x,cyan:x,white:x,gray:x,bgBlack:x,bgRed:x,bgGreen:x,bgYellow:x,bgBlue:x,bgMagenta:x,bgCyan:x,bgWhite:x,blackBright:x,redBright:x,greenBright:x,yellowBright:x,blueBright:x,magentaBright:x,cyanBright:x,whiteBright:x,bgBlackBright:x,bgRedBright:x,bgGreenBright:x,bgYellowBright:x,bgBlueBright:x,bgMagentaBright:x,bgCyanBright:x,bgWhiteBright:x}};
|
|
3
|
+
module.exports=create();
|
|
4
|
+
module.exports.createColors = create;
|