zyzz 0.0.0 → 0.0.3
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/LICENSE +21 -0
- package/README.md +380 -0
- package/dist/Config.d.ts +170 -0
- package/dist/Config.d.ts.map +1 -0
- package/dist/Config.js +249 -0
- package/dist/Config.js.map +1 -0
- package/dist/Props.d.ts +7 -0
- package/dist/Props.d.ts.map +1 -0
- package/dist/Props.js +3 -0
- package/dist/Props.js.map +1 -0
- package/dist/Style.d.ts +170 -0
- package/dist/Style.d.ts.map +1 -0
- package/dist/Style.js +325 -0
- package/dist/Style.js.map +1 -0
- package/dist/Theme.d.ts +157 -0
- package/dist/Theme.d.ts.map +1 -0
- package/dist/Theme.js +273 -0
- package/dist/Theme.js.map +1 -0
- package/dist/babel/NativeEdits.d.ts +8 -0
- package/dist/babel/NativeEdits.d.ts.map +1 -0
- package/dist/babel/NativeEdits.js +233 -0
- package/dist/babel/NativeEdits.js.map +1 -0
- package/dist/babel/NativeJsx.d.ts +10 -0
- package/dist/babel/NativeJsx.d.ts.map +1 -0
- package/dist/babel/NativeJsx.js +204 -0
- package/dist/babel/NativeJsx.js.map +1 -0
- package/dist/babel/index.d.ts +51 -0
- package/dist/babel/index.d.ts.map +1 -0
- package/dist/babel/index.js +220 -0
- package/dist/babel/index.js.map +1 -0
- package/dist/cli/index.d.ts +3 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +178 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/compiler/Graph.d.ts +64 -0
- package/dist/compiler/Graph.d.ts.map +1 -0
- package/dist/compiler/Graph.js +1111 -0
- package/dist/compiler/Graph.js.map +1 -0
- package/dist/compiler/Native.d.ts +53 -0
- package/dist/compiler/Native.d.ts.map +1 -0
- package/dist/compiler/Native.js +617 -0
- package/dist/compiler/Native.js.map +1 -0
- package/dist/compiler/Source.d.ts +167 -0
- package/dist/compiler/Source.d.ts.map +1 -0
- package/dist/compiler/Source.js +1012 -0
- package/dist/compiler/Source.js.map +1 -0
- package/dist/compiler/Transform.d.ts +57 -0
- package/dist/compiler/Transform.d.ts.map +1 -0
- package/dist/compiler/Transform.js +886 -0
- package/dist/compiler/Transform.js.map +1 -0
- package/dist/compiler/index.d.ts +13 -0
- package/dist/compiler/index.d.ts.map +1 -0
- package/dist/compiler/index.js +13 -0
- package/dist/compiler/index.js.map +1 -0
- package/dist/compiler/internal/Applications.d.ts +35 -0
- package/dist/compiler/internal/Applications.d.ts.map +1 -0
- package/dist/compiler/internal/Applications.js +248 -0
- package/dist/compiler/internal/Applications.js.map +1 -0
- package/dist/compiler/internal/AtRules.d.ts +8 -0
- package/dist/compiler/internal/AtRules.d.ts.map +1 -0
- package/dist/compiler/internal/AtRules.js +180 -0
- package/dist/compiler/internal/AtRules.js.map +1 -0
- package/dist/compiler/internal/Catalogs.d.ts +19 -0
- package/dist/compiler/internal/Catalogs.d.ts.map +1 -0
- package/dist/compiler/internal/Catalogs.js +68 -0
- package/dist/compiler/internal/Catalogs.js.map +1 -0
- package/dist/compiler/internal/ColorProfiles.d.ts +3 -0
- package/dist/compiler/internal/ColorProfiles.d.ts.map +1 -0
- package/dist/compiler/internal/ColorProfiles.js +84 -0
- package/dist/compiler/internal/ColorProfiles.js.map +1 -0
- package/dist/compiler/internal/CompositionBindings.d.ts +16 -0
- package/dist/compiler/internal/CompositionBindings.d.ts.map +1 -0
- package/dist/compiler/internal/CompositionBindings.js +89 -0
- package/dist/compiler/internal/CompositionBindings.js.map +1 -0
- package/dist/compiler/internal/Compositions.d.ts +32 -0
- package/dist/compiler/internal/Compositions.d.ts.map +1 -0
- package/dist/compiler/internal/Compositions.js +464 -0
- package/dist/compiler/internal/Compositions.js.map +1 -0
- package/dist/compiler/internal/Configurations.d.ts +21 -0
- package/dist/compiler/internal/Configurations.d.ts.map +1 -0
- package/dist/compiler/internal/Configurations.js +171 -0
- package/dist/compiler/internal/Configurations.js.map +1 -0
- package/dist/compiler/internal/Contract.d.ts +27 -0
- package/dist/compiler/internal/Contract.d.ts.map +1 -0
- package/dist/compiler/internal/Contract.js +607 -0
- package/dist/compiler/internal/Contract.js.map +1 -0
- package/dist/compiler/internal/Contributions.d.ts +54 -0
- package/dist/compiler/internal/Contributions.d.ts.map +1 -0
- package/dist/compiler/internal/Contributions.js +1109 -0
- package/dist/compiler/internal/Contributions.js.map +1 -0
- package/dist/compiler/internal/Descriptors.d.ts +15 -0
- package/dist/compiler/internal/Descriptors.d.ts.map +1 -0
- package/dist/compiler/internal/Descriptors.js +183 -0
- package/dist/compiler/internal/Descriptors.js.map +1 -0
- package/dist/compiler/internal/Dynamic.d.ts +14 -0
- package/dist/compiler/internal/Dynamic.d.ts.map +1 -0
- package/dist/compiler/internal/Dynamic.js +172 -0
- package/dist/compiler/internal/Dynamic.js.map +1 -0
- package/dist/compiler/internal/Edits.d.ts +12 -0
- package/dist/compiler/internal/Edits.d.ts.map +1 -0
- package/dist/compiler/internal/Edits.js +5 -0
- package/dist/compiler/internal/Edits.js.map +1 -0
- package/dist/compiler/internal/Expression.d.ts +12 -0
- package/dist/compiler/internal/Expression.d.ts.map +1 -0
- package/dist/compiler/internal/Expression.js +98 -0
- package/dist/compiler/internal/Expression.js.map +1 -0
- package/dist/compiler/internal/Functions.d.ts +5 -0
- package/dist/compiler/internal/Functions.d.ts.map +1 -0
- package/dist/compiler/internal/Functions.js +191 -0
- package/dist/compiler/internal/Functions.js.map +1 -0
- package/dist/compiler/internal/Identifiers.d.ts +9 -0
- package/dist/compiler/internal/Identifiers.d.ts.map +1 -0
- package/dist/compiler/internal/Identifiers.js +106 -0
- package/dist/compiler/internal/Identifiers.js.map +1 -0
- package/dist/compiler/internal/Keyframes.d.ts +5 -0
- package/dist/compiler/internal/Keyframes.d.ts.map +1 -0
- package/dist/compiler/internal/Keyframes.js +51 -0
- package/dist/compiler/internal/Keyframes.js.map +1 -0
- package/dist/compiler/internal/Namespaces.d.ts +17 -0
- package/dist/compiler/internal/Namespaces.d.ts.map +1 -0
- package/dist/compiler/internal/Namespaces.js +265 -0
- package/dist/compiler/internal/Namespaces.js.map +1 -0
- package/dist/compiler/internal/NativeBindings.d.ts +74 -0
- package/dist/compiler/internal/NativeBindings.d.ts.map +1 -0
- package/dist/compiler/internal/NativeBindings.js +117 -0
- package/dist/compiler/internal/NativeBindings.js.map +1 -0
- package/dist/compiler/internal/PackedStyles.d.ts +35 -0
- package/dist/compiler/internal/PackedStyles.d.ts.map +1 -0
- package/dist/compiler/internal/PackedStyles.js +345 -0
- package/dist/compiler/internal/PackedStyles.js.map +1 -0
- package/dist/compiler/internal/Properties.d.ts +5 -0
- package/dist/compiler/internal/Properties.d.ts.map +1 -0
- package/dist/compiler/internal/Properties.js +82 -0
- package/dist/compiler/internal/Properties.js.map +1 -0
- package/dist/compiler/internal/RecipeConditions.d.ts +41 -0
- package/dist/compiler/internal/RecipeConditions.d.ts.map +1 -0
- package/dist/compiler/internal/RecipeConditions.js +82 -0
- package/dist/compiler/internal/RecipeConditions.js.map +1 -0
- package/dist/compiler/internal/RecipePayloads.d.ts +31 -0
- package/dist/compiler/internal/RecipePayloads.d.ts.map +1 -0
- package/dist/compiler/internal/RecipePayloads.js +99 -0
- package/dist/compiler/internal/RecipePayloads.js.map +1 -0
- package/dist/compiler/internal/Recipes.d.ts +32 -0
- package/dist/compiler/internal/Recipes.d.ts.map +1 -0
- package/dist/compiler/internal/Recipes.js +339 -0
- package/dist/compiler/internal/Recipes.js.map +1 -0
- package/dist/compiler/internal/Relative.d.ts +19 -0
- package/dist/compiler/internal/Relative.d.ts.map +1 -0
- package/dist/compiler/internal/Relative.js +62 -0
- package/dist/compiler/internal/Relative.js.map +1 -0
- package/dist/compiler/internal/Scope.d.ts +10 -0
- package/dist/compiler/internal/Scope.d.ts.map +1 -0
- package/dist/compiler/internal/Scope.js +28 -0
- package/dist/compiler/internal/Scope.js.map +1 -0
- package/dist/compiler/internal/Selectors.d.ts +12 -0
- package/dist/compiler/internal/Selectors.d.ts.map +1 -0
- package/dist/compiler/internal/Selectors.js +265 -0
- package/dist/compiler/internal/Selectors.js.map +1 -0
- package/dist/compiler/internal/Static.d.ts +39 -0
- package/dist/compiler/internal/Static.d.ts.map +1 -0
- package/dist/compiler/internal/Static.js +532 -0
- package/dist/compiler/internal/Static.js.map +1 -0
- package/dist/compiler/internal/Stylesheets.d.ts +47 -0
- package/dist/compiler/internal/Stylesheets.d.ts.map +1 -0
- package/dist/compiler/internal/Stylesheets.js +272 -0
- package/dist/compiler/internal/Stylesheets.js.map +1 -0
- package/dist/compiler/internal/Syntax.d.ts +17 -0
- package/dist/compiler/internal/Syntax.d.ts.map +1 -0
- package/dist/compiler/internal/Syntax.js +19 -0
- package/dist/compiler/internal/Syntax.js.map +1 -0
- package/dist/compiler/internal/Themes.d.ts +158 -0
- package/dist/compiler/internal/Themes.d.ts.map +1 -0
- package/dist/compiler/internal/Themes.js +1169 -0
- package/dist/compiler/internal/Themes.js.map +1 -0
- package/dist/compiler/internal/Variables.d.ts +31 -0
- package/dist/compiler/internal/Variables.d.ts.map +1 -0
- package/dist/compiler/internal/Variables.js +376 -0
- package/dist/compiler/internal/Variables.js.map +1 -0
- package/dist/compiler/internal/ViewTransitions.d.ts +3 -0
- package/dist/compiler/internal/ViewTransitions.d.ts.map +1 -0
- package/dist/compiler/internal/ViewTransitions.js +68 -0
- package/dist/compiler/internal/ViewTransitions.js.map +1 -0
- package/dist/cx.d.ts +18 -0
- package/dist/cx.d.ts.map +1 -0
- package/dist/cx.js +60 -0
- package/dist/cx.js.map +1 -0
- package/dist/default.d.ts +3225 -0
- package/dist/default.d.ts.map +1 -0
- package/dist/default.js +547 -0
- package/dist/default.js.map +7 -0
- package/dist/default.js.zyzz.json +1 -0
- package/dist/index.d.ts +21 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +19 -0
- package/dist/index.js.map +1 -0
- package/dist/internal/Authoring.d.ts +26 -0
- package/dist/internal/Authoring.d.ts.map +1 -0
- package/dist/internal/Authoring.js +134 -0
- package/dist/internal/Authoring.js.map +1 -0
- package/dist/internal/Binding.d.ts +64 -0
- package/dist/internal/Binding.d.ts.map +1 -0
- package/dist/internal/Binding.js +27 -0
- package/dist/internal/Binding.js.map +1 -0
- package/dist/internal/BindingDomains.d.ts +11 -0
- package/dist/internal/BindingDomains.d.ts.map +1 -0
- package/dist/internal/BindingDomains.js +459 -0
- package/dist/internal/BindingDomains.js.map +1 -0
- package/dist/internal/Cascade.d.ts +45 -0
- package/dist/internal/Cascade.d.ts.map +1 -0
- package/dist/internal/Cascade.js +165 -0
- package/dist/internal/Cascade.js.map +1 -0
- package/dist/internal/Compound.d.ts +132 -0
- package/dist/internal/Compound.d.ts.map +1 -0
- package/dist/internal/Compound.js +2 -0
- package/dist/internal/Compound.js.map +1 -0
- package/dist/internal/Condition.d.ts +33 -0
- package/dist/internal/Condition.d.ts.map +1 -0
- package/dist/internal/Condition.js +180 -0
- package/dist/internal/Condition.js.map +1 -0
- package/dist/internal/Corner.d.ts +9 -0
- package/dist/internal/Corner.d.ts.map +1 -0
- package/dist/internal/Corner.js +14 -0
- package/dist/internal/Corner.js.map +1 -0
- package/dist/internal/FunctionSyntax.d.ts +27 -0
- package/dist/internal/FunctionSyntax.d.ts.map +1 -0
- package/dist/internal/FunctionSyntax.js +91 -0
- package/dist/internal/FunctionSyntax.js.map +1 -0
- package/dist/internal/FunctionValue.d.ts +19 -0
- package/dist/internal/FunctionValue.d.ts.map +1 -0
- package/dist/internal/FunctionValue.js +2 -0
- package/dist/internal/FunctionValue.js.map +1 -0
- package/dist/internal/Geometry.d.ts +8 -0
- package/dist/internal/Geometry.d.ts.map +1 -0
- package/dist/internal/Geometry.js +2 -0
- package/dist/internal/Geometry.js.map +1 -0
- package/dist/internal/Grid.d.ts +15 -0
- package/dist/internal/Grid.d.ts.map +1 -0
- package/dist/internal/Grid.js +2 -0
- package/dist/internal/Grid.js.map +1 -0
- package/dist/internal/Identifier.d.ts +15 -0
- package/dist/internal/Identifier.d.ts.map +1 -0
- package/dist/internal/Identifier.js +2 -0
- package/dist/internal/Identifier.js.map +1 -0
- package/dist/internal/Identity.d.ts +16 -0
- package/dist/internal/Identity.d.ts.map +1 -0
- package/dist/internal/Identity.js +78 -0
- package/dist/internal/Identity.js.map +1 -0
- package/dist/internal/Lexical.d.ts +89 -0
- package/dist/internal/Lexical.d.ts.map +1 -0
- package/dist/internal/Lexical.js +15 -0
- package/dist/internal/Lexical.js.map +1 -0
- package/dist/internal/Literal.d.ts +3459 -0
- package/dist/internal/Literal.d.ts.map +1 -0
- package/dist/internal/Literal.js +3371 -0
- package/dist/internal/Literal.js.map +1 -0
- package/dist/internal/NativeProperties.d.ts +596 -0
- package/dist/internal/NativeProperties.d.ts.map +1 -0
- package/dist/internal/NativeProperties.js +2 -0
- package/dist/internal/NativeProperties.js.map +1 -0
- package/dist/internal/Numeric.d.ts +23 -0
- package/dist/internal/Numeric.d.ts.map +1 -0
- package/dist/internal/Numeric.js +2 -0
- package/dist/internal/Numeric.js.map +1 -0
- package/dist/internal/Query.d.ts +15 -0
- package/dist/internal/Query.d.ts.map +1 -0
- package/dist/internal/Query.js +58 -0
- package/dist/internal/Query.js.map +1 -0
- package/dist/internal/Recipe.d.ts +17 -0
- package/dist/internal/Recipe.d.ts.map +1 -0
- package/dist/internal/Recipe.js +2 -0
- package/dist/internal/Recipe.js.map +1 -0
- package/dist/internal/RuleReference.d.ts +23 -0
- package/dist/internal/RuleReference.d.ts.map +1 -0
- package/dist/internal/RuleReference.js +65 -0
- package/dist/internal/RuleReference.js.map +1 -0
- package/dist/internal/Scheme.d.ts +12 -0
- package/dist/internal/Scheme.d.ts.map +1 -0
- package/dist/internal/Scheme.js +16 -0
- package/dist/internal/Scheme.js.map +1 -0
- package/dist/internal/Shorthands.d.ts +20 -0
- package/dist/internal/Shorthands.d.ts.map +1 -0
- package/dist/internal/Shorthands.js +50 -0
- package/dist/internal/Shorthands.js.map +1 -0
- package/dist/internal/Targets.d.ts +43 -0
- package/dist/internal/Targets.d.ts.map +1 -0
- package/dist/internal/Targets.js +60 -0
- package/dist/internal/Targets.js.map +1 -0
- package/dist/internal/Token.d.ts +104 -0
- package/dist/internal/Token.d.ts.map +1 -0
- package/dist/internal/Token.js +162 -0
- package/dist/internal/Token.js.map +1 -0
- package/dist/internal/Tuple.d.ts +23 -0
- package/dist/internal/Tuple.d.ts.map +1 -0
- package/dist/internal/Tuple.js +2 -0
- package/dist/internal/Tuple.js.map +1 -0
- package/dist/internal/Typography.d.ts +23 -0
- package/dist/internal/Typography.d.ts.map +1 -0
- package/dist/internal/Typography.js +18 -0
- package/dist/internal/Typography.js.map +1 -0
- package/dist/internal/Value.d.ts +74 -0
- package/dist/internal/Value.d.ts.map +1 -0
- package/dist/internal/Value.js +60 -0
- package/dist/internal/Value.js.map +1 -0
- package/dist/metro/Graph.d.ts +8 -0
- package/dist/metro/Graph.d.ts.map +1 -0
- package/dist/metro/Graph.js +63 -0
- package/dist/metro/Graph.js.map +1 -0
- package/dist/metro/Watch.d.ts +21 -0
- package/dist/metro/Watch.d.ts.map +1 -0
- package/dist/metro/Watch.js +51 -0
- package/dist/metro/Watch.js.map +1 -0
- package/dist/metro/index.d.ts +30 -0
- package/dist/metro/index.d.ts.map +1 -0
- package/dist/metro/index.js +52 -0
- package/dist/metro/index.js.map +1 -0
- package/dist/metro/transformer.d.ts +21 -0
- package/dist/metro/transformer.d.ts.map +1 -0
- package/dist/metro/transformer.js +71 -0
- package/dist/metro/transformer.js.map +1 -0
- package/dist/next/index.d.ts +18 -0
- package/dist/next/index.d.ts.map +1 -0
- package/dist/next/index.js +92 -0
- package/dist/next/index.js.map +1 -0
- package/dist/next/loader.d.ts +16 -0
- package/dist/next/loader.d.ts.map +1 -0
- package/dist/next/loader.js +282 -0
- package/dist/next/loader.js.map +1 -0
- package/dist/node/Host.d.ts +80 -0
- package/dist/node/Host.d.ts.map +1 -0
- package/dist/node/Host.js +882 -0
- package/dist/node/Host.js.map +1 -0
- package/dist/node/index.d.ts +7 -0
- package/dist/node/index.d.ts.map +1 -0
- package/dist/node/index.js +7 -0
- package/dist/node/index.js.map +1 -0
- package/dist/react-native/Host.d.ts +76 -0
- package/dist/react-native/Host.d.ts.map +1 -0
- package/dist/react-native/Host.js +209 -0
- package/dist/react-native/Host.js.map +1 -0
- package/dist/react-native/StyleSheet.d.ts +226 -0
- package/dist/react-native/StyleSheet.d.ts.map +1 -0
- package/dist/react-native/StyleSheet.js +606 -0
- package/dist/react-native/StyleSheet.js.map +1 -0
- package/dist/react-native/Variants.d.ts +38 -0
- package/dist/react-native/Variants.d.ts.map +1 -0
- package/dist/react-native/Variants.js +66 -0
- package/dist/react-native/Variants.js.map +1 -0
- package/dist/react-native/index.d.ts +8 -0
- package/dist/react-native/index.d.ts.map +1 -0
- package/dist/react-native/index.js +8 -0
- package/dist/react-native/index.js.map +1 -0
- package/dist/react-native/internal/Color.d.ts +7 -0
- package/dist/react-native/internal/Color.d.ts.map +1 -0
- package/dist/react-native/internal/Color.js +93 -0
- package/dist/react-native/internal/Color.js.map +1 -0
- package/dist/react-native/internal/NativeSchema.d.ts +5138 -0
- package/dist/react-native/internal/NativeSchema.d.ts.map +1 -0
- package/dist/react-native/internal/NativeSchema.js +3097 -0
- package/dist/react-native/internal/NativeSchema.js.map +1 -0
- package/dist/react-native/internal/Scalar.d.ts +95 -0
- package/dist/react-native/internal/Scalar.d.ts.map +1 -0
- package/dist/react-native/internal/Scalar.js +199 -0
- package/dist/react-native/internal/Scalar.js.map +1 -0
- package/dist/react-native/internal/Values.d.ts +5 -0
- package/dist/react-native/internal/Values.d.ts.map +1 -0
- package/dist/react-native/internal/Values.js +65 -0
- package/dist/react-native/internal/Values.js.map +1 -0
- package/dist/react-native/react.d.ts +22 -0
- package/dist/react-native/react.d.ts.map +1 -0
- package/dist/react-native/react.js +26 -0
- package/dist/react-native/react.js.map +1 -0
- package/dist/reset.css +244 -0
- package/dist/runtime/Appearance.d.ts +55 -0
- package/dist/runtime/Appearance.d.ts.map +1 -0
- package/dist/runtime/Appearance.js +84 -0
- package/dist/runtime/Appearance.js.map +1 -0
- package/dist/runtime/Composition.d.ts +46 -0
- package/dist/runtime/Composition.d.ts.map +1 -0
- package/dist/runtime/Composition.js +52 -0
- package/dist/runtime/Composition.js.map +1 -0
- package/dist/runtime/CompositionHtml.d.ts +15 -0
- package/dist/runtime/CompositionHtml.d.ts.map +1 -0
- package/dist/runtime/CompositionHtml.js +20 -0
- package/dist/runtime/CompositionHtml.js.map +1 -0
- package/dist/runtime/ConditionalRecipe.d.ts +30 -0
- package/dist/runtime/ConditionalRecipe.d.ts.map +1 -0
- package/dist/runtime/ConditionalRecipe.js +39 -0
- package/dist/runtime/ConditionalRecipe.js.map +1 -0
- package/dist/runtime/Dynamic.d.ts +19 -0
- package/dist/runtime/Dynamic.d.ts.map +1 -0
- package/dist/runtime/Dynamic.js +22 -0
- package/dist/runtime/Dynamic.js.map +1 -0
- package/dist/runtime/Html.d.ts +32 -0
- package/dist/runtime/Html.d.ts.map +1 -0
- package/dist/runtime/Html.js +63 -0
- package/dist/runtime/Html.js.map +1 -0
- package/dist/runtime/Native.d.ts +48 -0
- package/dist/runtime/Native.d.ts.map +1 -0
- package/dist/runtime/Native.js +78 -0
- package/dist/runtime/Native.js.map +1 -0
- package/dist/runtime/NativeContext.d.ts +17 -0
- package/dist/runtime/NativeContext.d.ts.map +1 -0
- package/dist/runtime/NativeContext.js +47 -0
- package/dist/runtime/NativeContext.js.map +1 -0
- package/dist/runtime/NativeDynamic.d.ts +47 -0
- package/dist/runtime/NativeDynamic.d.ts.map +1 -0
- package/dist/runtime/NativeDynamic.js +141 -0
- package/dist/runtime/NativeDynamic.js.map +1 -0
- package/dist/runtime/PayloadRecipe.d.ts +22 -0
- package/dist/runtime/PayloadRecipe.d.ts.map +1 -0
- package/dist/runtime/PayloadRecipe.js +59 -0
- package/dist/runtime/PayloadRecipe.js.map +1 -0
- package/dist/runtime/Props.d.ts +21 -0
- package/dist/runtime/Props.d.ts.map +1 -0
- package/dist/runtime/Props.js +17 -0
- package/dist/runtime/Props.js.map +1 -0
- package/dist/runtime/Recipe.d.ts +52 -0
- package/dist/runtime/Recipe.d.ts.map +1 -0
- package/dist/runtime/Recipe.js +30 -0
- package/dist/runtime/Recipe.js.map +1 -0
- package/dist/runtime/Selection.d.ts +31 -0
- package/dist/runtime/Selection.d.ts.map +1 -0
- package/dist/runtime/Selection.js +30 -0
- package/dist/runtime/Selection.js.map +1 -0
- package/dist/runtime/Variable.d.ts +6 -0
- package/dist/runtime/Variable.d.ts.map +1 -0
- package/dist/runtime/Variable.js +10 -0
- package/dist/runtime/Variable.js.map +1 -0
- package/dist/runtime/index.d.ts +33 -0
- package/dist/runtime/index.d.ts.map +1 -0
- package/dist/runtime/index.js +33 -0
- package/dist/runtime/index.js.map +1 -0
- package/dist/styleFunction.d.ts +72 -0
- package/dist/styleFunction.d.ts.map +1 -0
- package/dist/styleFunction.js +18 -0
- package/dist/styleFunction.js.map +1 -0
- package/dist/themes/LICENSE.tailwind +21 -0
- package/dist/variable.d.ts +50 -0
- package/dist/variable.d.ts.map +1 -0
- package/dist/variable.js +20 -0
- package/dist/variable.js.map +1 -0
- package/dist/variants.d.ts +84 -0
- package/dist/variants.d.ts.map +1 -0
- package/dist/variants.js +21 -0
- package/dist/variants.js.map +1 -0
- package/dist/vite/index.d.ts +24 -0
- package/dist/vite/index.d.ts.map +1 -0
- package/dist/vite/index.js +1089 -0
- package/dist/vite/index.js.map +1 -0
- package/dist/web/Css.d.ts +81 -0
- package/dist/web/Css.d.ts.map +1 -0
- package/dist/web/Css.js +593 -0
- package/dist/web/Css.js.map +1 -0
- package/dist/web/colorProfile.d.ts +28 -0
- package/dist/web/colorProfile.d.ts.map +1 -0
- package/dist/web/colorProfile.js +8 -0
- package/dist/web/colorProfile.js.map +1 -0
- package/dist/web/counterStyle.d.ts +48 -0
- package/dist/web/counterStyle.d.ts.map +1 -0
- package/dist/web/counterStyle.js +8 -0
- package/dist/web/counterStyle.js.map +1 -0
- package/dist/web/cssFunction.d.ts +80 -0
- package/dist/web/cssFunction.d.ts.map +1 -0
- package/dist/web/cssFunction.js +18 -0
- package/dist/web/cssFunction.js.map +1 -0
- package/dist/web/customMedia.d.ts +12 -0
- package/dist/web/customMedia.d.ts.map +1 -0
- package/dist/web/customMedia.js +7 -0
- package/dist/web/customMedia.js.map +1 -0
- package/dist/web/fontFace.d.ts +26 -0
- package/dist/web/fontFace.d.ts.map +1 -0
- package/dist/web/fontFace.js +7 -0
- package/dist/web/fontFace.js.map +1 -0
- package/dist/web/fontFeatureValues.d.ts +40 -0
- package/dist/web/fontFeatureValues.d.ts.map +1 -0
- package/dist/web/fontFeatureValues.js +7 -0
- package/dist/web/fontFeatureValues.js.map +1 -0
- package/dist/web/fontPaletteValues.d.ts +21 -0
- package/dist/web/fontPaletteValues.d.ts.map +1 -0
- package/dist/web/fontPaletteValues.js +9 -0
- package/dist/web/fontPaletteValues.js.map +1 -0
- package/dist/web/global.d.ts +19 -0
- package/dist/web/global.d.ts.map +1 -0
- package/dist/web/global.js +6 -0
- package/dist/web/global.js.map +1 -0
- package/dist/web/importCss.d.ts +18 -0
- package/dist/web/importCss.d.ts.map +1 -0
- package/dist/web/importCss.js +7 -0
- package/dist/web/importCss.js.map +1 -0
- package/dist/web/index.d.ts +22 -0
- package/dist/web/index.d.ts.map +1 -0
- package/dist/web/index.js +22 -0
- package/dist/web/index.js.map +1 -0
- package/dist/web/internal/Block.d.ts +18 -0
- package/dist/web/internal/Block.d.ts.map +1 -0
- package/dist/web/internal/Block.js +13 -0
- package/dist/web/internal/Block.js.map +1 -0
- package/dist/web/internal/ClassName.d.ts +19 -0
- package/dist/web/internal/ClassName.d.ts.map +1 -0
- package/dist/web/internal/ClassName.js +77 -0
- package/dist/web/internal/ClassName.js.map +1 -0
- package/dist/web/internal/Context.d.ts +11 -0
- package/dist/web/internal/Context.d.ts.map +1 -0
- package/dist/web/internal/Context.js +2 -0
- package/dist/web/internal/Context.js.map +1 -0
- package/dist/web/internal/Contributions.d.ts +70 -0
- package/dist/web/internal/Contributions.d.ts.map +1 -0
- package/dist/web/internal/Contributions.js +109 -0
- package/dist/web/internal/Contributions.js.map +1 -0
- package/dist/web/internal/Namespace.d.ts +13 -0
- package/dist/web/internal/Namespace.d.ts.map +1 -0
- package/dist/web/internal/Namespace.js +13 -0
- package/dist/web/internal/Namespace.js.map +1 -0
- package/dist/web/internal/Themes.d.ts +13 -0
- package/dist/web/internal/Themes.d.ts.map +1 -0
- package/dist/web/internal/Themes.js +96 -0
- package/dist/web/internal/Themes.js.map +1 -0
- package/dist/web/keyframes.d.ts +14 -0
- package/dist/web/keyframes.d.ts.map +1 -0
- package/dist/web/keyframes.js +8 -0
- package/dist/web/keyframes.js.map +1 -0
- package/dist/web/layers.d.ts +4 -0
- package/dist/web/layers.d.ts.map +1 -0
- package/dist/web/layers.js +7 -0
- package/dist/web/layers.js.map +1 -0
- package/dist/web/namespace.d.ts +14 -0
- package/dist/web/namespace.d.ts.map +1 -0
- package/dist/web/namespace.js +7 -0
- package/dist/web/namespace.js.map +1 -0
- package/dist/web/page.d.ts +38 -0
- package/dist/web/page.d.ts.map +1 -0
- package/dist/web/page.js +7 -0
- package/dist/web/page.js.map +1 -0
- package/dist/web/positionTry.d.ts +14 -0
- package/dist/web/positionTry.d.ts.map +1 -0
- package/dist/web/positionTry.js +9 -0
- package/dist/web/positionTry.js.map +1 -0
- package/dist/web/property.d.ts +24 -0
- package/dist/web/property.d.ts.map +1 -0
- package/dist/web/property.js +7 -0
- package/dist/web/property.js.map +1 -0
- package/dist/web/viewTransition.d.ts +29 -0
- package/dist/web/viewTransition.d.ts.map +1 -0
- package/dist/web/viewTransition.js +7 -0
- package/dist/web/viewTransition.js.map +1 -0
- package/package.json +136 -10
- package/src/Config.ts +691 -0
- package/src/Props.ts +8 -0
- package/src/Style.ts +812 -0
- package/src/Theme.ts +784 -0
- package/src/babel/NativeEdits.ts +273 -0
- package/src/babel/NativeJsx.ts +260 -0
- package/src/babel/index.ts +332 -0
- package/src/cli/index.ts +196 -0
- package/src/compiler/Graph.ts +1586 -0
- package/src/compiler/Native.ts +801 -0
- package/src/compiler/Source.ts +1579 -0
- package/src/compiler/Transform.ts +1241 -0
- package/src/compiler/index.ts +12 -0
- package/src/compiler/internal/Applications.ts +378 -0
- package/src/compiler/internal/AtRules.ts +202 -0
- package/src/compiler/internal/Catalogs.ts +114 -0
- package/src/compiler/internal/ColorProfiles.ts +93 -0
- package/src/compiler/internal/CompositionBindings.ts +120 -0
- package/src/compiler/internal/Compositions.ts +629 -0
- package/src/compiler/internal/Configurations.ts +244 -0
- package/src/compiler/internal/Contract.ts +860 -0
- package/src/compiler/internal/Contributions.ts +1507 -0
- package/src/compiler/internal/Descriptors.ts +238 -0
- package/src/compiler/internal/Dynamic.ts +266 -0
- package/src/compiler/internal/Edits.ts +13 -0
- package/src/compiler/internal/Expression.ts +135 -0
- package/src/compiler/internal/Functions.ts +206 -0
- package/src/compiler/internal/Identifiers.ts +124 -0
- package/src/compiler/internal/Keyframes.ts +62 -0
- package/src/compiler/internal/Namespaces.ts +296 -0
- package/src/compiler/internal/NativeBindings.ts +151 -0
- package/src/compiler/internal/PackedStyles.ts +464 -0
- package/src/compiler/internal/Properties.ts +121 -0
- package/src/compiler/internal/RecipeConditions.ts +139 -0
- package/src/compiler/internal/RecipePayloads.ts +132 -0
- package/src/compiler/internal/Recipes.ts +531 -0
- package/src/compiler/internal/Relative.ts +87 -0
- package/src/compiler/internal/Scope.ts +36 -0
- package/src/compiler/internal/Selectors.ts +334 -0
- package/src/compiler/internal/Static.ts +783 -0
- package/src/compiler/internal/Stylesheets.ts +361 -0
- package/src/compiler/internal/Syntax.ts +31 -0
- package/src/compiler/internal/Themes.ts +1794 -0
- package/src/compiler/internal/Variables.ts +497 -0
- package/src/compiler/internal/ViewTransitions.ts +82 -0
- package/src/cx.ts +98 -0
- package/src/default.ts +1177 -0
- package/src/index.ts +20 -0
- package/src/internal/Authoring.ts +199 -0
- package/src/internal/Binding.ts +187 -0
- package/src/internal/BindingDomains.ts +458 -0
- package/src/internal/Cascade.ts +165 -0
- package/src/internal/Compound.ts +522 -0
- package/src/internal/Condition.ts +283 -0
- package/src/internal/Corner.ts +17 -0
- package/src/internal/FunctionSyntax.ts +271 -0
- package/src/internal/FunctionValue.ts +96 -0
- package/src/internal/Geometry.ts +30 -0
- package/src/internal/Grid.ts +67 -0
- package/src/internal/Identifier.ts +14 -0
- package/src/internal/Identity.ts +89 -0
- package/src/internal/Lexical.ts +202 -0
- package/src/internal/Literal.ts +3820 -0
- package/src/internal/NativeProperties.ts +936 -0
- package/src/internal/Numeric.ts +77 -0
- package/src/internal/Query.ts +87 -0
- package/src/internal/Recipe.ts +17 -0
- package/src/internal/RuleReference.ts +102 -0
- package/src/internal/Scheme.ts +20 -0
- package/src/internal/Shorthands.ts +122 -0
- package/src/internal/Targets.ts +162 -0
- package/src/internal/Token.ts +380 -0
- package/src/internal/Tuple.ts +29 -0
- package/src/internal/Typography.ts +51 -0
- package/src/internal/Value.ts +320 -0
- package/src/metro/Graph.ts +78 -0
- package/src/metro/Watch.ts +88 -0
- package/src/metro/index.ts +99 -0
- package/src/metro/transformer.ts +97 -0
- package/src/next/index.ts +114 -0
- package/src/next/loader.ts +369 -0
- package/src/node/Host.ts +1204 -0
- package/src/node/index.ts +6 -0
- package/src/react-native/Host.ts +289 -0
- package/src/react-native/StyleSheet.ts +1084 -0
- package/src/react-native/Variants.ts +122 -0
- package/src/react-native/index.ts +7 -0
- package/src/react-native/internal/Color.ts +110 -0
- package/src/react-native/internal/NativeSchema.ts +3096 -0
- package/src/react-native/internal/Scalar.ts +253 -0
- package/src/react-native/internal/Values.ts +87 -0
- package/src/react-native/react.ts +47 -0
- package/src/reset.css +244 -0
- package/src/runtime/Appearance.ts +155 -0
- package/src/runtime/Composition.ts +87 -0
- package/src/runtime/CompositionHtml.ts +38 -0
- package/src/runtime/ConditionalRecipe.ts +70 -0
- package/src/runtime/Dynamic.ts +51 -0
- package/src/runtime/Html.ts +91 -0
- package/src/runtime/Native.ts +144 -0
- package/src/runtime/NativeContext.ts +74 -0
- package/src/runtime/NativeDynamic.ts +246 -0
- package/src/runtime/PayloadRecipe.ts +96 -0
- package/src/runtime/Props.ts +33 -0
- package/src/runtime/Recipe.ts +74 -0
- package/src/runtime/Selection.ts +82 -0
- package/src/runtime/Variable.ts +15 -0
- package/src/runtime/index.ts +45 -0
- package/src/styleFunction.ts +138 -0
- package/src/themes/LICENSE.tailwind +21 -0
- package/src/variable.ts +105 -0
- package/src/variants.ts +218 -0
- package/src/vite/index.ts +1473 -0
- package/src/web/Css.ts +801 -0
- package/src/web/colorProfile.ts +60 -0
- package/src/web/counterStyle.ts +82 -0
- package/src/web/cssFunction.ts +181 -0
- package/src/web/customMedia.ts +16 -0
- package/src/web/fontFace.ts +41 -0
- package/src/web/fontFeatureValues.ts +79 -0
- package/src/web/fontPaletteValues.ts +42 -0
- package/src/web/global.ts +39 -0
- package/src/web/importCss.ts +23 -0
- package/src/web/index.ts +22 -0
- package/src/web/internal/Block.ts +29 -0
- package/src/web/internal/ClassName.ts +112 -0
- package/src/web/internal/Context.ts +16 -0
- package/src/web/internal/Contributions.ts +219 -0
- package/src/web/internal/Namespace.ts +21 -0
- package/src/web/internal/Themes.ts +133 -0
- package/src/web/keyframes.ts +43 -0
- package/src/web/layers.ts +6 -0
- package/src/web/namespace.ts +19 -0
- package/src/web/page.ts +140 -0
- package/src/web/positionTry.ts +71 -0
- package/src/web/property.ts +35 -0
- package/src/web/viewTransition.ts +89 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Exposes static source extraction and module rewriting without a file host.
|
|
3
|
+
* @module
|
|
4
|
+
*/
|
|
5
|
+
/** Source graph compilation with shared theme contracts. */
|
|
6
|
+
export * as Graph from './Graph.js'
|
|
7
|
+
/** Static native source compilation and finite callable output. */
|
|
8
|
+
export * as Native from './Native.js'
|
|
9
|
+
/** Static source extraction without application evaluation or file loading. */
|
|
10
|
+
export * as Source from './Source.js'
|
|
11
|
+
/** Literal module rewriting and source maps for web output. */
|
|
12
|
+
export * as Transform from './Transform.js'
|
|
@@ -0,0 +1,378 @@
|
|
|
1
|
+
/** Finds nonescaping local static callables whose applications can become props. @module */
|
|
2
|
+
import type * as Ast from '@oxc-project/types'
|
|
3
|
+
import * as Walker from 'oxc-walker'
|
|
4
|
+
import * as Scope from './Scope.js'
|
|
5
|
+
import type * as Source from '../Source.js'
|
|
6
|
+
|
|
7
|
+
/** Conservatively proves direct applications without changing binding reads. */
|
|
8
|
+
export function create(
|
|
9
|
+
program: Ast.Program,
|
|
10
|
+
calls: readonly Source.Call[],
|
|
11
|
+
options: create.Options = {},
|
|
12
|
+
): Collector | undefined {
|
|
13
|
+
const definitions = new Map(calls.map((call) => [call.start, call]))
|
|
14
|
+
const memberBindings = new Map<number, string>()
|
|
15
|
+
const referencedDefinitions = new Set<string>()
|
|
16
|
+
const namespaceCounts = new Map<string, number>()
|
|
17
|
+
|
|
18
|
+
for (const statement of program.body) {
|
|
19
|
+
const node =
|
|
20
|
+
statement.type === 'ExportNamedDeclaration'
|
|
21
|
+
? statement.declaration
|
|
22
|
+
: statement
|
|
23
|
+
|
|
24
|
+
if (node?.type === 'TSModuleDeclaration' && node.id.type === 'Identifier')
|
|
25
|
+
namespaceCounts.set(
|
|
26
|
+
node.id.name,
|
|
27
|
+
(namespaceCounts.get(node.id.name) ?? 0) + 1,
|
|
28
|
+
)
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
const candidates: {
|
|
32
|
+
declaration: {
|
|
33
|
+
id: Extract<Ast.Node, { type: 'Identifier' }>
|
|
34
|
+
}
|
|
35
|
+
direct: Source.Call | undefined
|
|
36
|
+
members: Map<string, Source.Call>
|
|
37
|
+
}[] = []
|
|
38
|
+
|
|
39
|
+
for (const statement of program.body) {
|
|
40
|
+
if (
|
|
41
|
+
statement.type === 'TSModuleDeclaration' &&
|
|
42
|
+
statement.id.type === 'Identifier' &&
|
|
43
|
+
statement.body?.type === 'TSModuleBlock'
|
|
44
|
+
) {
|
|
45
|
+
const members = new Map<string, Source.Call>()
|
|
46
|
+
let valid = true
|
|
47
|
+
|
|
48
|
+
for (const member of statement.body.body) {
|
|
49
|
+
const node =
|
|
50
|
+
member.type === 'ExportNamedDeclaration'
|
|
51
|
+
? member.declaration
|
|
52
|
+
: undefined
|
|
53
|
+
|
|
54
|
+
if (node?.type !== 'VariableDeclaration' || node.kind !== 'const') {
|
|
55
|
+
valid = false
|
|
56
|
+
break
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
for (const declaration of node.declarations) {
|
|
60
|
+
const call =
|
|
61
|
+
declaration.init && definitions.get(declaration.init.start)
|
|
62
|
+
|
|
63
|
+
if (
|
|
64
|
+
declaration.id.type !== 'Identifier' ||
|
|
65
|
+
declaration.init?.type !== 'CallExpression' ||
|
|
66
|
+
declaration.init.end !== call?.end ||
|
|
67
|
+
members.has(declaration.id.name)
|
|
68
|
+
) {
|
|
69
|
+
valid = false
|
|
70
|
+
break
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
members.set(declaration.id.name, call)
|
|
74
|
+
memberBindings.set(declaration.id.start, call.name)
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
if (valid && members.size)
|
|
79
|
+
candidates.push({
|
|
80
|
+
declaration: { id: statement.id },
|
|
81
|
+
direct: undefined,
|
|
82
|
+
members,
|
|
83
|
+
})
|
|
84
|
+
|
|
85
|
+
continue
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
// Exported values can escape and object members can subsequently be replaced.
|
|
89
|
+
if (statement.type !== 'VariableDeclaration' || statement.kind !== 'const')
|
|
90
|
+
continue
|
|
91
|
+
|
|
92
|
+
for (const declaration of statement.declarations) {
|
|
93
|
+
if (declaration.id.type !== 'Identifier' || !declaration.init) continue
|
|
94
|
+
|
|
95
|
+
const members = new Map<string, Source.Call>()
|
|
96
|
+
const candidate = definitions.get(declaration.init.start)
|
|
97
|
+
|
|
98
|
+
const direct =
|
|
99
|
+
declaration.init.type === 'CallExpression' &&
|
|
100
|
+
declaration.init.end === candidate?.end
|
|
101
|
+
? candidate
|
|
102
|
+
: undefined
|
|
103
|
+
|
|
104
|
+
if (!direct) {
|
|
105
|
+
if (declaration.init.type !== 'ObjectExpression') continue
|
|
106
|
+
|
|
107
|
+
let valid = true
|
|
108
|
+
|
|
109
|
+
for (const property of declaration.init.properties) {
|
|
110
|
+
if (
|
|
111
|
+
property.type !== 'Property' ||
|
|
112
|
+
property.computed ||
|
|
113
|
+
property.method ||
|
|
114
|
+
property.kind !== 'init'
|
|
115
|
+
) {
|
|
116
|
+
valid = false
|
|
117
|
+
break
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
const key =
|
|
121
|
+
property.key.type === 'Identifier' ? property.key.name : undefined
|
|
122
|
+
const candidate = definitions.get(property.value.start)
|
|
123
|
+
|
|
124
|
+
const call =
|
|
125
|
+
property.value.type === 'CallExpression' &&
|
|
126
|
+
property.value.end === candidate?.end
|
|
127
|
+
? candidate
|
|
128
|
+
: undefined
|
|
129
|
+
|
|
130
|
+
if (!key || key === '__proto__' || !call || members.has(key)) {
|
|
131
|
+
valid = false
|
|
132
|
+
break
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
members.set(key, call)
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
if (!valid || !members.size) continue
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
candidates.push({
|
|
142
|
+
declaration: { ...declaration, id: declaration.id },
|
|
143
|
+
direct,
|
|
144
|
+
members,
|
|
145
|
+
})
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
if (!candidates.length) return undefined
|
|
150
|
+
|
|
151
|
+
const lexical = new Set<Ast.Node>()
|
|
152
|
+
const scope = new Scope.Tracker({ preserveExitedScopes: true })
|
|
153
|
+
Walker.walk(program, { scopeTracker: scope })
|
|
154
|
+
scope.freeze()
|
|
155
|
+
const ancestors: Ast.Node[] = []
|
|
156
|
+
Walker.walk(program, {
|
|
157
|
+
scopeTracker: scope,
|
|
158
|
+
enter(node, parent) {
|
|
159
|
+
ancestors.push(node)
|
|
160
|
+
if (
|
|
161
|
+
node.type !== 'Identifier' ||
|
|
162
|
+
!parent ||
|
|
163
|
+
!Walker.isReferenceIdentifier(node, parent)
|
|
164
|
+
)
|
|
165
|
+
return
|
|
166
|
+
if (
|
|
167
|
+
ancestors.some((node) =>
|
|
168
|
+
[
|
|
169
|
+
'TSTypeQuery',
|
|
170
|
+
'TSTypeAnnotation',
|
|
171
|
+
'TSTypeAliasDeclaration',
|
|
172
|
+
'TSInterfaceDeclaration',
|
|
173
|
+
'TSTypeParameterInstantiation',
|
|
174
|
+
'TSTypeParameterDeclaration',
|
|
175
|
+
].includes(node.type),
|
|
176
|
+
)
|
|
177
|
+
)
|
|
178
|
+
return
|
|
179
|
+
const binding = scope.getDeclaration(node.name, { mode: 'value' })
|
|
180
|
+
const id = binding?.node
|
|
181
|
+
const member = id && memberBindings.get(id.start)
|
|
182
|
+
if (member) referencedDefinitions.add(member)
|
|
183
|
+
if (
|
|
184
|
+
id &&
|
|
185
|
+
candidates.some(
|
|
186
|
+
(candidate) => candidate.declaration.id.start === id.start,
|
|
187
|
+
)
|
|
188
|
+
)
|
|
189
|
+
lexical.add(node)
|
|
190
|
+
},
|
|
191
|
+
leave() {
|
|
192
|
+
ancestors.pop()
|
|
193
|
+
},
|
|
194
|
+
})
|
|
195
|
+
|
|
196
|
+
const parents = new Map<Ast.Node, Ast.Node>()
|
|
197
|
+
const references = new Map<
|
|
198
|
+
string,
|
|
199
|
+
Extract<Ast.Node, { type: 'Identifier' }>[]
|
|
200
|
+
>(candidates.map(({ declaration }) => [declaration.id.name, []]))
|
|
201
|
+
let evaluation = false
|
|
202
|
+
|
|
203
|
+
return {
|
|
204
|
+
dead() {
|
|
205
|
+
if (evaluation) return new Set<string>()
|
|
206
|
+
|
|
207
|
+
const result = new Set<string>()
|
|
208
|
+
const counts = new Map<string, number>()
|
|
209
|
+
|
|
210
|
+
for (const { declaration } of candidates)
|
|
211
|
+
counts.set(
|
|
212
|
+
declaration.id.name,
|
|
213
|
+
(counts.get(declaration.id.name) ?? 0) + 1,
|
|
214
|
+
)
|
|
215
|
+
|
|
216
|
+
for (const { declaration, direct, members } of candidates) {
|
|
217
|
+
if (
|
|
218
|
+
counts.get(declaration.id.name)! > 1 ||
|
|
219
|
+
(namespaceCounts.get(declaration.id.name) ?? 0) > 1
|
|
220
|
+
)
|
|
221
|
+
continue
|
|
222
|
+
|
|
223
|
+
const reads = references.get(declaration.id.name) ?? []
|
|
224
|
+
|
|
225
|
+
if (direct) {
|
|
226
|
+
if (!reads.length) result.add(direct.name)
|
|
227
|
+
continue
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
const used = new Set<string>()
|
|
231
|
+
let escapes = false
|
|
232
|
+
|
|
233
|
+
for (const reference of reads) {
|
|
234
|
+
const member = parents.get(reference)
|
|
235
|
+
|
|
236
|
+
if (
|
|
237
|
+
member?.type !== 'MemberExpression' ||
|
|
238
|
+
member.object !== reference ||
|
|
239
|
+
member.computed ||
|
|
240
|
+
member.optional ||
|
|
241
|
+
member.property.type !== 'Identifier'
|
|
242
|
+
) {
|
|
243
|
+
escapes = true
|
|
244
|
+
break
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
used.add(member.property.name)
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
if (!escapes)
|
|
251
|
+
for (const [name, call] of members)
|
|
252
|
+
if (!used.has(name) && !referencedDefinitions.has(call.name))
|
|
253
|
+
result.add(call.name)
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
return result
|
|
257
|
+
},
|
|
258
|
+
enter(node, parent) {
|
|
259
|
+
if (
|
|
260
|
+
node.type === 'MemberExpression' &&
|
|
261
|
+
node.object.type === 'Identifier' &&
|
|
262
|
+
references.has(node.object.name) &&
|
|
263
|
+
parent
|
|
264
|
+
)
|
|
265
|
+
parents.set(node, parent)
|
|
266
|
+
|
|
267
|
+
if (node.type !== 'Identifier') return
|
|
268
|
+
|
|
269
|
+
if (node.name === 'eval') evaluation = true
|
|
270
|
+
|
|
271
|
+
if (!lexical.has(node)) return
|
|
272
|
+
|
|
273
|
+
const nodes = references.get(node.name)
|
|
274
|
+
if (!nodes) return
|
|
275
|
+
|
|
276
|
+
nodes.push(node)
|
|
277
|
+
|
|
278
|
+
if (parent) parents.set(node, parent)
|
|
279
|
+
},
|
|
280
|
+
find() {
|
|
281
|
+
if (evaluation) return []
|
|
282
|
+
|
|
283
|
+
const result: Application[] = []
|
|
284
|
+
|
|
285
|
+
for (const { declaration, direct, members } of candidates) {
|
|
286
|
+
const applications: Application[] = []
|
|
287
|
+
let valid = true
|
|
288
|
+
|
|
289
|
+
for (const reference of references.get(declaration.id.name) ?? []) {
|
|
290
|
+
if (reference === declaration.id) continue
|
|
291
|
+
|
|
292
|
+
let callee: Ast.Node = reference
|
|
293
|
+
let call = direct
|
|
294
|
+
|
|
295
|
+
if (!direct) {
|
|
296
|
+
const member = parents.get(reference)
|
|
297
|
+
|
|
298
|
+
if (
|
|
299
|
+
member?.type !== 'MemberExpression' ||
|
|
300
|
+
member.object !== reference ||
|
|
301
|
+
member.computed ||
|
|
302
|
+
member.optional ||
|
|
303
|
+
member.property.type !== 'Identifier'
|
|
304
|
+
) {
|
|
305
|
+
valid = false
|
|
306
|
+
break
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
call = members.get(member.property.name)
|
|
310
|
+
callee = member
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
if (
|
|
314
|
+
call?.composition ||
|
|
315
|
+
call?.runtimeComposition ||
|
|
316
|
+
(!options.dynamic && (call?.slots || call?.recipe))
|
|
317
|
+
)
|
|
318
|
+
continue
|
|
319
|
+
|
|
320
|
+
const application = parents.get(callee)
|
|
321
|
+
|
|
322
|
+
if (
|
|
323
|
+
!call ||
|
|
324
|
+
application?.type !== 'CallExpression' ||
|
|
325
|
+
application.callee !== callee ||
|
|
326
|
+
application.optional ||
|
|
327
|
+
(!options.dynamic && application.arguments.length)
|
|
328
|
+
) {
|
|
329
|
+
valid = false
|
|
330
|
+
break
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
applications.push({
|
|
334
|
+
calleeEnd: callee.end,
|
|
335
|
+
end: application.end,
|
|
336
|
+
name: call.name,
|
|
337
|
+
start: application.start,
|
|
338
|
+
})
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
if (valid) result.push(...applications)
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
return result
|
|
345
|
+
},
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
/** Proven call site and its compiled definition. */
|
|
350
|
+
type Application = {
|
|
351
|
+
/** End of the original binding or property read. */
|
|
352
|
+
readonly calleeEnd: number
|
|
353
|
+
/** End of the application. */
|
|
354
|
+
readonly end: number
|
|
355
|
+
/** Extracted class identity. */
|
|
356
|
+
readonly name: string
|
|
357
|
+
/** Start of the application. */
|
|
358
|
+
readonly start: number
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
/** Binding references gathered during the transform's existing walk. */
|
|
362
|
+
type Collector = {
|
|
363
|
+
/** Definitions with no observable value reads, retaining escaped containers. */
|
|
364
|
+
dead: () => ReadonlySet<string>
|
|
365
|
+
/** Records relevant reads and their immediate parents. */
|
|
366
|
+
enter: (node: Ast.Node, parent: Ast.Node | null | undefined) => void
|
|
367
|
+
/** Resolves applications after traversal completes. */
|
|
368
|
+
find: () => readonly Application[]
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
/** Local application collection modes. */
|
|
372
|
+
export declare namespace create {
|
|
373
|
+
/** Controls whether arguments are retained for fixed runtime compositions. */
|
|
374
|
+
type Options = {
|
|
375
|
+
/** Includes recipe/value applications while preserving their runtime calls. */
|
|
376
|
+
readonly dynamic?: boolean | undefined
|
|
377
|
+
}
|
|
378
|
+
}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
/** Adapts standard descriptor extensions that precede the pinned parser's grammar. @module */
|
|
2
|
+
import * as ColorProfiles from './ColorProfiles.js'
|
|
3
|
+
import * as Descriptors from './Descriptors.js'
|
|
4
|
+
import * as Functions from './Functions.js'
|
|
5
|
+
import * as Identifiers from './Identifiers.js'
|
|
6
|
+
import * as Keyframes from './Keyframes.js'
|
|
7
|
+
import * as Lightning from 'lightningcss'
|
|
8
|
+
import * as Properties from './Properties.js'
|
|
9
|
+
import * as ViewTransitions from './ViewTransitions.js'
|
|
10
|
+
|
|
11
|
+
/** Parses structured contributions while retaining newer font descriptors. */
|
|
12
|
+
export function transform<C extends Lightning.CustomAtRules>(
|
|
13
|
+
options: Lightning.TransformOptions<C>,
|
|
14
|
+
): Lightning.TransformResult {
|
|
15
|
+
// Stylesheets without an @ byte cannot require at-keyword transport.
|
|
16
|
+
if (!options.code.includes(64)) return Lightning.transform(options)
|
|
17
|
+
|
|
18
|
+
const source = new TextDecoder().decode(options.code)
|
|
19
|
+
if (
|
|
20
|
+
/@(?:counter-style|custom-media|document|font-face|font-palette-values|page)\b/i.test(
|
|
21
|
+
source,
|
|
22
|
+
)
|
|
23
|
+
)
|
|
24
|
+
Descriptors.validate(source)
|
|
25
|
+
if (/@function\b/i.test(source)) Functions.validate(source)
|
|
26
|
+
const properties = /@property\b/i.test(source) && Properties.validate(source)
|
|
27
|
+
let propertyMarker = 'zyzz-property'
|
|
28
|
+
while (source.includes(propertyMarker)) propertyMarker += '-x'
|
|
29
|
+
validateFeatures(source)
|
|
30
|
+
// The pinned visitor cannot round-trip the nested Option used for anonymous import layers.
|
|
31
|
+
// Give emitted anonymous layers a temporary name while URL visitors run, then restore them.
|
|
32
|
+
let importMarker = 'zyzz-anonymous-import'
|
|
33
|
+
while (source.includes(importMarker)) importMarker += '-x'
|
|
34
|
+
const imports = options.visitor
|
|
35
|
+
? source.replace(
|
|
36
|
+
/^(\s*@import\s+(?:url\()?"(?:\\.|[^"\\])*"\)?\s+)layer(?=[\s;])/gm,
|
|
37
|
+
`$1layer(${importMarker})`,
|
|
38
|
+
)
|
|
39
|
+
: source
|
|
40
|
+
const lower = source.toLowerCase()
|
|
41
|
+
let marker = '-zyzz-ffv-000000000'
|
|
42
|
+
let suffix = 0
|
|
43
|
+
while (lower.includes(marker))
|
|
44
|
+
marker = `-zyzz-ffv-${(++suffix).toString(36).padStart(9, '0')}`
|
|
45
|
+
let paletteMarker = '-zyzz-fpv-000000000'
|
|
46
|
+
let paletteSuffix = 0
|
|
47
|
+
while (lower.includes(paletteMarker))
|
|
48
|
+
paletteMarker = `-zyzz-fpv-${(++paletteSuffix).toString(36).padStart(9, '0')}`
|
|
49
|
+
// The pinned parser silently drops font-family lists from palette rules.
|
|
50
|
+
const registered = properties
|
|
51
|
+
? rename(imports, 'property', propertyMarker)
|
|
52
|
+
: imports
|
|
53
|
+
const features = lower.includes('@font-feature-values')
|
|
54
|
+
? rename(registered, 'font-feature-values', marker)
|
|
55
|
+
: registered
|
|
56
|
+
const renamed = lower.includes('@font-palette-values')
|
|
57
|
+
? rename(features, 'font-palette-values', paletteMarker)
|
|
58
|
+
: features
|
|
59
|
+
if (lower.includes('@color-profile')) ColorProfiles.validate(renamed)
|
|
60
|
+
if (lower.includes('@keyframes')) Keyframes.validate(renamed)
|
|
61
|
+
if (source.toLowerCase().includes('@view-transition')) {
|
|
62
|
+
let marker = '-zyzz-view-transition'
|
|
63
|
+
while (source.includes(marker)) marker += '-x'
|
|
64
|
+
ViewTransitions.validate(rename(renamed, 'view-transition', marker), marker)
|
|
65
|
+
}
|
|
66
|
+
if (source === renamed) return Lightning.transform(options)
|
|
67
|
+
const result = Lightning.transform({
|
|
68
|
+
...options,
|
|
69
|
+
code: new TextEncoder().encode(renamed),
|
|
70
|
+
})
|
|
71
|
+
return {
|
|
72
|
+
...result,
|
|
73
|
+
code: new TextEncoder().encode(
|
|
74
|
+
rename(
|
|
75
|
+
rename(
|
|
76
|
+
rename(
|
|
77
|
+
new TextDecoder()
|
|
78
|
+
.decode(result.code)
|
|
79
|
+
.replaceAll(`layer(${importMarker})`, 'layer'),
|
|
80
|
+
propertyMarker,
|
|
81
|
+
'property',
|
|
82
|
+
),
|
|
83
|
+
marker,
|
|
84
|
+
'font-feature-values',
|
|
85
|
+
),
|
|
86
|
+
paletteMarker,
|
|
87
|
+
'font-palette-values',
|
|
88
|
+
),
|
|
89
|
+
),
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
// Contribution extraction validates feature blocks and their descriptors before this adapter.
|
|
94
|
+
// At-keyword substitution keeps Lightning's token/URL traversal without discarding newer descriptors.
|
|
95
|
+
/** Renames actual at-keywords without touching strings, comments, or function arguments. */
|
|
96
|
+
export function rename(source: string, before: string, after: string): string {
|
|
97
|
+
let output = ''
|
|
98
|
+
let quote = ''
|
|
99
|
+
let parentheses = 0
|
|
100
|
+
for (let index = 0; index < source.length; index++) {
|
|
101
|
+
const char = source[index]!
|
|
102
|
+
if (char === '\\') {
|
|
103
|
+
output += char + (source[++index] ?? '')
|
|
104
|
+
continue
|
|
105
|
+
}
|
|
106
|
+
if (quote) {
|
|
107
|
+
output += char
|
|
108
|
+
if (char === quote) quote = ''
|
|
109
|
+
continue
|
|
110
|
+
}
|
|
111
|
+
if (char === '"' || char === "'") quote = char
|
|
112
|
+
else if (char === '/' && source[index + 1] === '*') {
|
|
113
|
+
const end = source.indexOf('*/', index + 2)
|
|
114
|
+
if (end < 0) return source
|
|
115
|
+
output += source.slice(index, end + 2)
|
|
116
|
+
index = end + 1
|
|
117
|
+
continue
|
|
118
|
+
} else if (char === '(') parentheses++
|
|
119
|
+
else if (char === ')') parentheses--
|
|
120
|
+
else if (
|
|
121
|
+
!parentheses &&
|
|
122
|
+
char === '@' &&
|
|
123
|
+
source.slice(index + 1, index + 1 + before.length).toLowerCase() ===
|
|
124
|
+
before &&
|
|
125
|
+
!/[\w-]/.test(source[index + 1 + before.length] ?? '')
|
|
126
|
+
) {
|
|
127
|
+
output += `@${after}`
|
|
128
|
+
index += before.length
|
|
129
|
+
continue
|
|
130
|
+
}
|
|
131
|
+
output += char
|
|
132
|
+
}
|
|
133
|
+
return output
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/** Relocates an import while omitting absent conditions in the parser's visitor return format. */
|
|
137
|
+
export function relocateImport(
|
|
138
|
+
value: Lightning.ImportRule,
|
|
139
|
+
url: string,
|
|
140
|
+
): Lightning.ReturnedRule {
|
|
141
|
+
const { layer, supports, ...rest } = value
|
|
142
|
+
return {
|
|
143
|
+
type: 'import',
|
|
144
|
+
value: {
|
|
145
|
+
...rest,
|
|
146
|
+
url,
|
|
147
|
+
...(layer ? { layer } : {}),
|
|
148
|
+
...(supports ? { supports } : {}),
|
|
149
|
+
},
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
// Validate the standard rule before shielding the newer font-display descriptor.
|
|
154
|
+
function validateFeatures(source: string): void {
|
|
155
|
+
if (!source.toLowerCase().includes('@font-feature-values')) return
|
|
156
|
+
const masked = source.replace(
|
|
157
|
+
/"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\/\*[\s\S]*?\*\//g,
|
|
158
|
+
(value) => ' '.repeat(value.length),
|
|
159
|
+
)
|
|
160
|
+
for (const match of masked.matchAll(/@font-feature-values(?=[\s{])/gi)) {
|
|
161
|
+
const start = match.index
|
|
162
|
+
const open = masked.indexOf('{', start)
|
|
163
|
+
if (open < 0) throw new Error('Invalid font-feature-values block.')
|
|
164
|
+
let depth = 1
|
|
165
|
+
let end = open + 1
|
|
166
|
+
let plain = source.slice(start, open + 1)
|
|
167
|
+
let cursor = open + 1
|
|
168
|
+
for (; end < masked.length && depth; end++) {
|
|
169
|
+
const char = masked[end]
|
|
170
|
+
if (char === '{') depth++
|
|
171
|
+
else if (char === '}') depth--
|
|
172
|
+
else if (depth === 1 && masked.slice(end).match(/^font-display\s*:/i)) {
|
|
173
|
+
const finish = masked.indexOf(';', end)
|
|
174
|
+
const close = masked.indexOf('}', end)
|
|
175
|
+
const boundary = finish >= 0 && finish < close ? finish : close
|
|
176
|
+
if (boundary < 0) throw new Error('Invalid font-display descriptor.')
|
|
177
|
+
const descriptor = source.slice(end, boundary)
|
|
178
|
+
const names = Identifiers.list(
|
|
179
|
+
descriptor.slice(descriptor.indexOf(':') + 1),
|
|
180
|
+
'space',
|
|
181
|
+
)
|
|
182
|
+
if (
|
|
183
|
+
names?.length !== 1 ||
|
|
184
|
+
!['auto', 'block', 'fallback', 'optional', 'swap'].includes(
|
|
185
|
+
names[0]!.replace(/[A-Z]/g, (letter) => letter.toLowerCase()),
|
|
186
|
+
)
|
|
187
|
+
)
|
|
188
|
+
throw new Error('Invalid font-display descriptor.')
|
|
189
|
+
plain += source.slice(cursor, end)
|
|
190
|
+
cursor = boundary + (boundary === finish ? 1 : 0)
|
|
191
|
+
end = cursor - 1
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
if (depth) throw new Error('Invalid font-feature-values block.')
|
|
195
|
+
plain += source.slice(cursor, end)
|
|
196
|
+
Lightning.transform({
|
|
197
|
+
filename: 'font-feature-values.css',
|
|
198
|
+
code: new TextEncoder().encode(plain),
|
|
199
|
+
errorRecovery: false,
|
|
200
|
+
})
|
|
201
|
+
}
|
|
202
|
+
}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
/** Reads configuration theme catalogs from packed contracts and serializes their root initialization. @module */
|
|
2
|
+
import * as Appearance from '../../runtime/Appearance.js'
|
|
3
|
+
import * as ThemeValues from '../../web/internal/Themes.js'
|
|
4
|
+
|
|
5
|
+
/** Initialization inputs read from one compiled configuration. */
|
|
6
|
+
export type Catalog = {
|
|
7
|
+
/** Theme names paired with the compiled scope classes the stylesheet emits. */
|
|
8
|
+
readonly entries: readonly (readonly [string, string])[]
|
|
9
|
+
/** Configuration identity that prefixes every scope key. */
|
|
10
|
+
readonly identity: string
|
|
11
|
+
/** localStorage key shared by the configuration's script and root controls. */
|
|
12
|
+
readonly storageKey: string | undefined
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/** Reads each configuration's theme catalog and storage key from a contract, one per configuration identity. */
|
|
16
|
+
export function read(contract: string): readonly Catalog[] {
|
|
17
|
+
const parsed = JSON.parse(contract) as {
|
|
18
|
+
exports?: Record<
|
|
19
|
+
string,
|
|
20
|
+
{
|
|
21
|
+
kind?: string
|
|
22
|
+
members?: Record<string, { theme?: string }>
|
|
23
|
+
options?: { storageKey?: string; themes?: Record<string, unknown> }
|
|
24
|
+
selection?: boolean
|
|
25
|
+
theme?: string
|
|
26
|
+
}
|
|
27
|
+
>
|
|
28
|
+
configurations?: readonly {
|
|
29
|
+
identity?: string
|
|
30
|
+
storageKey?: string
|
|
31
|
+
themes?: readonly string[]
|
|
32
|
+
}[]
|
|
33
|
+
themes?: Record<string, { identity?: string }>
|
|
34
|
+
}
|
|
35
|
+
const configurations = new Map<
|
|
36
|
+
string,
|
|
37
|
+
{ entries: Map<string, string>; storageKey: string | undefined }
|
|
38
|
+
>()
|
|
39
|
+
|
|
40
|
+
// Local configuration calls publish their catalogs without an export.
|
|
41
|
+
for (const local of parsed.configurations ?? []) {
|
|
42
|
+
if (!local.identity) continue
|
|
43
|
+
|
|
44
|
+
const configuration = configurations.get(local.identity) ?? {
|
|
45
|
+
entries: new Map<string, string>(),
|
|
46
|
+
storageKey: local.storageKey,
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
configurations.set(local.identity, configuration)
|
|
50
|
+
|
|
51
|
+
for (const name of local.themes ?? [])
|
|
52
|
+
configuration.entries.set(name, `${local.identity}-${name}`)
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
for (const binding of Object.values(parsed.exports ?? {})) {
|
|
56
|
+
if (binding.kind !== 'config' || binding.theme === undefined) continue
|
|
57
|
+
|
|
58
|
+
// A binding names its selected default scope; the theme metadata carries
|
|
59
|
+
// the configuration identity that prefixes every scope key.
|
|
60
|
+
const identity = parsed.themes?.[binding.theme]?.identity ?? binding.theme
|
|
61
|
+
let configuration = configurations.get(identity)
|
|
62
|
+
|
|
63
|
+
if (!configuration) {
|
|
64
|
+
configuration = {
|
|
65
|
+
entries: new Map(),
|
|
66
|
+
storageKey: binding.options?.storageKey,
|
|
67
|
+
}
|
|
68
|
+
configurations.set(identity, configuration)
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// Script and root bindings carry no members, so the catalog derives their scope keys.
|
|
72
|
+
for (const name of Object.keys(binding.options?.themes ?? {}))
|
|
73
|
+
configuration.entries.set(name, `${identity}-${name}`)
|
|
74
|
+
|
|
75
|
+
for (const [path, member] of Object.entries(binding.members ?? {})) {
|
|
76
|
+
const names = JSON.parse(path) as readonly string[]
|
|
77
|
+
const name = (() => {
|
|
78
|
+
if (binding.selection) return names.length === 1 ? names[0] : undefined
|
|
79
|
+
return names.length === 2 && names[0] === 'themes'
|
|
80
|
+
? names[1]
|
|
81
|
+
: undefined
|
|
82
|
+
})()
|
|
83
|
+
|
|
84
|
+
if (name !== undefined && member.theme)
|
|
85
|
+
configuration.entries.set(name, member.theme)
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
// Scope keys become classes through the same escaping the emitted stylesheet used.
|
|
90
|
+
return [...configurations].map(([identity, { entries, storageKey }]) => ({
|
|
91
|
+
entries: [...entries].map(
|
|
92
|
+
([name, scope]) =>
|
|
93
|
+
[name, `z_theme-${ThemeValues.encode(scope)}`] as const,
|
|
94
|
+
),
|
|
95
|
+
identity,
|
|
96
|
+
storageKey,
|
|
97
|
+
}))
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* Serializes the initialization script of every configuration, once per
|
|
102
|
+
* distinct script so configurations sharing a catalog and key run once.
|
|
103
|
+
* @param catalogs - Configurations read from the contracts a document loads.
|
|
104
|
+
* @returns Self-contained scripts that restore a saved selection before paint.
|
|
105
|
+
*/
|
|
106
|
+
export function scripts(catalogs: readonly Catalog[]): readonly string[] {
|
|
107
|
+
return [
|
|
108
|
+
...new Set(
|
|
109
|
+
catalogs.map(({ entries, storageKey }) =>
|
|
110
|
+
Appearance.create(entries, { storageKey })(),
|
|
111
|
+
),
|
|
112
|
+
),
|
|
113
|
+
]
|
|
114
|
+
}
|