@usefragments/core 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-MLRDNSSA.js → chunk-CBSNXFOD.js} +1 -1
- package/dist/chunk-CBSNXFOD.js.map +1 -0
- package/dist/codes/index.d.ts +1 -1
- package/dist/codes/index.js +1 -1
- package/dist/compiled-types/index.d.ts +1 -1
- package/dist/generate/index.d.ts +1 -1
- package/dist/{governance-DYSirwJu.d.ts → governance-DxdJV6lx.d.ts} +10 -0
- package/dist/index.d.ts +97 -75
- package/dist/index.js +163 -30
- package/dist/index.js.map +1 -1
- package/dist/react-types.d.ts +1 -1
- package/dist/registry.d.ts +18 -18
- package/dist/schemas/index.d.ts +1 -1
- package/dist/test-utils.d.ts +1 -1
- package/package.json +1 -1
- package/src/constants.ts +3 -0
- package/src/facts/builders.ts +1 -1
- package/src/facts/types.ts +14 -1
- package/src/rules/components-prefer-library.test.ts +148 -0
- package/src/rules/components-prefer-library.ts +52 -1
- package/src/rules/styles-no-raw-color.test.ts +213 -0
- package/src/rules/styles-no-raw-color.ts +125 -0
- package/src/schema.ts +6 -2
- package/src/token-types.ts +12 -0
- package/src/tokens/categories.ts +54 -24
- package/src/tokens/scss.test.ts +94 -0
- package/src/tokens/scss.ts +11 -4
- package/src/types.ts +11 -0
- package/dist/chunk-MLRDNSSA.js.map +0 -1
- package/dist/{index-h_yWj15D.d.ts → index-0lmh0Lbo.d.ts} +8 -8
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { F as Finding, A as AgentFormat, E as EvidenceGrade, a as FindingFix } from './index-
|
|
2
|
-
export { b as AGENT_FORMAT_SCHEMA_VERSION, c as AgentErrorEnvelope, d as AgentOutput, G as CanonicalGovernanceVerdict, e as EVIDENCE_ORDER, f as FindingReplaceClassTokenFix, g as FindingReplaceComponentFix, h as FindingReplaceImportFix, i as FindingReplacePropValueFix, j as FindingReplaceStyleValueFix, k as Fix, l as GovernanceVerdictMetadata, I as InspectClaim, m as InspectClaimTier, S as SuppressionDirective, V as ValidatorResult, n as Violation, o as agentErrorEnvelopeSchema, p as agentFormatSchema, q as agentIntegritySchema, r as agentOutputSchema, s as canBlock, t as factEvidenceSchema, u as factLocationSchema, v as findingFixSchema, w as findingReplaceClassTokenFixSchema, x as findingReplaceComponentFixSchema, y as findingReplaceImportFixSchema, z as findingReplacePropValueFixSchema, B as findingReplaceStyleValueFixSchema, C as findingSchema, D as fixSchema, H as governanceVerdictMetadataSchema, J as governanceVerdictSchema, K as normalizeFinding, L as normalizeSeverity, M as normalizeViolation, N as suppressionDirectiveSchema, O as validatorResultSchema, P as violationSchema } from './index-
|
|
1
|
+
import { F as Finding, A as AgentFormat, E as EvidenceGrade, a as FindingFix } from './index-0lmh0Lbo.js';
|
|
2
|
+
export { b as AGENT_FORMAT_SCHEMA_VERSION, c as AgentErrorEnvelope, d as AgentOutput, G as CanonicalGovernanceVerdict, e as EVIDENCE_ORDER, f as FindingReplaceClassTokenFix, g as FindingReplaceComponentFix, h as FindingReplaceImportFix, i as FindingReplacePropValueFix, j as FindingReplaceStyleValueFix, k as Fix, l as GovernanceVerdictMetadata, I as InspectClaim, m as InspectClaimTier, S as SuppressionDirective, V as ValidatorResult, n as Violation, o as agentErrorEnvelopeSchema, p as agentFormatSchema, q as agentIntegritySchema, r as agentOutputSchema, s as canBlock, t as factEvidenceSchema, u as factLocationSchema, v as findingFixSchema, w as findingReplaceClassTokenFixSchema, x as findingReplaceComponentFixSchema, y as findingReplaceImportFixSchema, z as findingReplacePropValueFixSchema, B as findingReplaceStyleValueFixSchema, C as findingSchema, D as fixSchema, H as governanceVerdictMetadataSchema, J as governanceVerdictSchema, K as normalizeFinding, L as normalizeSeverity, M as normalizeViolation, N as suppressionDirectiveSchema, O as validatorResultSchema, P as violationSchema } from './index-0lmh0Lbo.js';
|
|
3
3
|
import { Severity } from './severity.js';
|
|
4
4
|
export { SEVERITIES, SEVERITY_RANK, SEVERITY_WEIGHTS, SeverityLevel, compareSeverity, maxSeverity, severityLevel, severitySchema, sortBySeverity } from './severity.js';
|
|
5
5
|
export { BridgeViolationInput, CODES, CodeCategory, CodeLifecycle, EXPLAIN_URL_BASE, FuiCode, bridgeSourceViolation, bridgeSourceViolations, byCode, byRuleId, explainUrlForCode } from './codes/index.js';
|
|
6
|
-
import { c as ContractDomain, d as ContractCatalogInput, G as GovernanceSeverity, b as CompiledFragment, e as GovernedFragmentDefinition, R as ResolvedGovernedFragmentDefinition, f as GovernanceConfig, g as FragmentsConfig, T as TokenConfig, h as FragmentComponent, B as BlockDefinition, C as CompiledBlock, F as FragmentDefinition, a as FragmentDefinitionV2, S as StorybookFilterConfig, i as FigmaStringMapping, j as FigmaBooleanMapping, k as FigmaEnumMapping, l as FigmaInstanceMapping, m as FigmaChildrenMapping, n as FigmaTextContentMapping, o as RelationshipType, V as VariantRenderOptions, p as VariantLoader, q as CanonicalSource } from './governance-
|
|
7
|
-
export { A as AIMetadata, r as AccessibilityGovernanceBuilder, s as AppConfig, t as BaselineInfo, u as BoundingBox, v as CONTRACT_DOMAINS, w as CONTRACT_PREIMAGE_CAPABILITY_HEADER, x as CONTRACT_PREIMAGE_SCHEMA, y as CanonicalMappingStatus, z as CompiledFragmentsFile, D as CompiledRecipe, E as CompiledTokenData, H as CompiledTokenEntry, I as ComponentGovernanceBuilder, J as ComponentGovernanceRecord, K as ComponentRef, L as ComponentRelation, M as CompositionMetadata, N as ContractCanonicalMappingInput, O as ContractComponentInput, P as ContractIdentityPin, Q as ContractPolicyInput, U as ContractPreimage, W as ContractPropMappingInput, X as ContractTokenInput, Y as ContractWaiverInput, Z as ControlType, _ as DesignSystemConfig, $ as DiffResult, a0 as FigmaPropMapping, a1 as FragmentContract, a2 as FragmentExample, a3 as FragmentGenerated, a4 as FragmentGuidance, a5 as FragmentMeta, a6 as FragmentProvenance, a7 as FragmentUsage, a8 as FragmentVariant, a9 as GlobalGovernanceRecord, aa as GlobalJsxGovernanceRecord, ab as GlobalStyleGovernanceRecord, ac as GovernancePropValue, ad as InspectConfig, ae as LocalCanonicalDeclaration, af as LocalCanonicalResolveRule, ag as Manifest, ah as ObservedComponentUsage, ai as ObservedUsageProp, aj as PlayFunction, ak as PlayFunctionContext, al as PropDefinition, am as PropGovernanceBuilder, an as PropGovernanceOptions, ao as PropKey, ap as PropType, aq as RecipeDefinition, ar as RegistryOptions, as as RepoRelativePath, at as ScaleGovernanceRecord, au as Screenshot, av as ScreenshotConfig, aw as ScreenshotMetadata, ax as ServiceConfig, ay as SnapshotConfig, az as SnippetPolicyConfig, aA as Theme, aB as ThemeSeeds, aC as TokenSourceConfig, aD as TokenSourceFormat, aE as VerifyRequest, aF as VerifyResult, aG as Viewport, aH as componentGovernanceRecordSchema, aI as componentGovernanceRecordsSchema, aJ as contractComponentsFromFragments, aK as contractPolicyFromGovernanceConfig, aL as diffContractDomains, aM as g, aN as globalGovernanceRecordSchema, aO as globalJsxGovernanceRecordSchema, aP as globalStyleGovernanceRecordSchema, aQ as governanceConfigSchema, aR as governanceConfigWithLocalCanonical, aS as governanceSeveritySchema, aT as localCanonicalContractMappings, aU as normalizeGovernanceConfig, aV as projectContractPreimage, aW as scaleGovernanceRecordSchema, aX as verifiedContractPreimageFromPin } from './governance-
|
|
6
|
+
import { c as ContractDomain, d as ContractCatalogInput, G as GovernanceSeverity, b as CompiledFragment, e as GovernedFragmentDefinition, R as ResolvedGovernedFragmentDefinition, f as GovernanceConfig, g as FragmentsConfig, T as TokenConfig, h as FragmentComponent, B as BlockDefinition, C as CompiledBlock, F as FragmentDefinition, a as FragmentDefinitionV2, S as StorybookFilterConfig, i as FigmaStringMapping, j as FigmaBooleanMapping, k as FigmaEnumMapping, l as FigmaInstanceMapping, m as FigmaChildrenMapping, n as FigmaTextContentMapping, o as RelationshipType, V as VariantRenderOptions, p as VariantLoader, q as CanonicalSource } from './governance-DxdJV6lx.js';
|
|
7
|
+
export { A as AIMetadata, r as AccessibilityGovernanceBuilder, s as AppConfig, t as BaselineInfo, u as BoundingBox, v as CONTRACT_DOMAINS, w as CONTRACT_PREIMAGE_CAPABILITY_HEADER, x as CONTRACT_PREIMAGE_SCHEMA, y as CanonicalMappingStatus, z as CompiledFragmentsFile, D as CompiledRecipe, E as CompiledTokenData, H as CompiledTokenEntry, I as ComponentGovernanceBuilder, J as ComponentGovernanceRecord, K as ComponentRef, L as ComponentRelation, M as CompositionMetadata, N as ContractCanonicalMappingInput, O as ContractComponentInput, P as ContractIdentityPin, Q as ContractPolicyInput, U as ContractPreimage, W as ContractPropMappingInput, X as ContractTokenInput, Y as ContractWaiverInput, Z as ControlType, _ as DesignSystemConfig, $ as DiffResult, a0 as FigmaPropMapping, a1 as FragmentContract, a2 as FragmentExample, a3 as FragmentGenerated, a4 as FragmentGuidance, a5 as FragmentMeta, a6 as FragmentProvenance, a7 as FragmentUsage, a8 as FragmentVariant, a9 as GlobalGovernanceRecord, aa as GlobalJsxGovernanceRecord, ab as GlobalStyleGovernanceRecord, ac as GovernancePropValue, ad as InspectConfig, ae as LocalCanonicalDeclaration, af as LocalCanonicalResolveRule, ag as Manifest, ah as ObservedComponentUsage, ai as ObservedUsageProp, aj as PlayFunction, ak as PlayFunctionContext, al as PropDefinition, am as PropGovernanceBuilder, an as PropGovernanceOptions, ao as PropKey, ap as PropType, aq as RecipeDefinition, ar as RegistryOptions, as as RepoRelativePath, at as ScaleGovernanceRecord, au as Screenshot, av as ScreenshotConfig, aw as ScreenshotMetadata, ax as ServiceConfig, ay as SnapshotConfig, az as SnippetPolicyConfig, aA as Theme, aB as ThemeSeeds, aC as TokenSourceConfig, aD as TokenSourceFormat, aE as VerifyRequest, aF as VerifyResult, aG as Viewport, aH as componentGovernanceRecordSchema, aI as componentGovernanceRecordsSchema, aJ as contractComponentsFromFragments, aK as contractPolicyFromGovernanceConfig, aL as diffContractDomains, aM as g, aN as globalGovernanceRecordSchema, aO as globalJsxGovernanceRecordSchema, aP as globalStyleGovernanceRecordSchema, aQ as governanceConfigSchema, aR as governanceConfigWithLocalCanonical, aS as governanceSeveritySchema, aT as localCanonicalContractMappings, aU as normalizeGovernanceConfig, aV as projectContractPreimage, aW as scaleGovernanceRecordSchema, aX as verifiedContractPreimageFromPin } from './governance-DxdJV6lx.js';
|
|
8
8
|
import { z } from 'zod';
|
|
9
9
|
import { RegistryArtifact, RegistryDependency, RegistryInstallReceipt } from './registry.js';
|
|
10
10
|
export { REGISTRY_ARTIFACT_SCHEMA_VERSION, REGISTRY_INSTALL_RECEIPT_SCHEMA_VERSION, REGISTRY_MANIFEST_SCHEMA_VERSION, RegistryArtifactInput, RegistryComponent, RegistryComponentExport, RegistryDependencyType, RegistryEntrypoint, RegistryFile, RegistryFileContent, RegistryFileInput, RegistryFileRole, RegistryInstallProfile, RegistryInstallReceiptComponent, RegistryInstallReceiptFile, RegistryManifest, RegistryManifestDraft, RegistrySource, assertValidRegistryArtifact, buildRegistryArtifact, buildRegistryFile, computeRegistryHash, finalizeRegistryManifest, hashRegistryFileContent, registryArtifactDigest, registryArtifactSchema, registryComponentExportSchema, registryComponentSchema, registryDependencySchema, registryDependencyTypeSchema, registryEntrypointSchema, registryFileContentSchema, registryFileRoleSchema, registryFileSchema, registryFileSize, registryInstallProfileSchema, registryInstallReceiptComponentSchema, registryInstallReceiptFileSchema, registryInstallReceiptSchema, registryManifestCanonicalPreimage, registryManifestDraftSchema, registryManifestSchema, registrySourceSchema } from './registry.js';
|
|
@@ -39,6 +39,8 @@ declare const BRAND: {
|
|
|
39
39
|
readonly legacyConfigFile: "segments.config.ts";
|
|
40
40
|
/** CLI command name (e.g., "fragments") */
|
|
41
41
|
readonly cliCommand: "fragments";
|
|
42
|
+
/** Full user-facing CLI invocation for copy printed to end users (e.g., "npx @usefragments/cli") */
|
|
43
|
+
readonly cliInvocation: "npx @usefragments/cli";
|
|
42
44
|
/** Directory for storing fragments, registry, and cache */
|
|
43
45
|
readonly dataDir: ".fragments";
|
|
44
46
|
/** Components subdirectory within .fragments/ */
|
|
@@ -824,7 +826,20 @@ interface UsageInlineStyleFact extends BaseFact {
|
|
|
824
826
|
kind: "usage_inline_style";
|
|
825
827
|
nodeId: FactId;
|
|
826
828
|
property: string;
|
|
827
|
-
|
|
829
|
+
/**
|
|
830
|
+
* How the extractor resolved the value:
|
|
831
|
+
* - `static` — a string literal (`"#f00"`, `"12px"`).
|
|
832
|
+
* - `number` — a numeric literal (React treats it as `px`).
|
|
833
|
+
* - `css-variable` — a `var(--token)` reference; rules treat it as a token.
|
|
834
|
+
* - `dynamic-raw` — a value constructed at runtime whose *static* fragments
|
|
835
|
+
* unambiguously begin a raw color literal (`` `#${red}` ``,
|
|
836
|
+
* `` `rgb(${r},${g},${b})` ``, `"#" + hex`). `value` carries a reconstructed
|
|
837
|
+
* skeleton with each interpolation rendered as `‹expr›`. Detect-only: a rule
|
|
838
|
+
* may flag it as a raw color but must NEVER attach a deterministic fix
|
|
839
|
+
* (the value is partly runtime). Only color-shaped dynamic values ever
|
|
840
|
+
* surface as facts — a non-color dynamic value stays opaque.
|
|
841
|
+
*/
|
|
842
|
+
valueKind: "static" | "number" | "css-variable" | "dynamic-raw";
|
|
828
843
|
value: string;
|
|
829
844
|
}
|
|
830
845
|
interface UsageTextChildFact extends BaseFact {
|
|
@@ -1224,7 +1239,7 @@ declare function makeUsagePropResolvedFact(input: {
|
|
|
1224
1239
|
declare function makeUsageInlineStyleFact(input: {
|
|
1225
1240
|
nodeId: FactId;
|
|
1226
1241
|
property: string;
|
|
1227
|
-
valueKind: "static" | "number" | "css-variable";
|
|
1242
|
+
valueKind: "static" | "number" | "css-variable" | "dynamic-raw";
|
|
1228
1243
|
value: string;
|
|
1229
1244
|
}): UsageInlineStyleFact;
|
|
1230
1245
|
declare function makeUsageTextChildFact(input: {
|
|
@@ -1774,7 +1789,7 @@ declare const bundleManifestComponentEntrySchema: z.ZodObject<{
|
|
|
1774
1789
|
name: string;
|
|
1775
1790
|
}[];
|
|
1776
1791
|
publicSlug: string | null;
|
|
1777
|
-
tier: "
|
|
1792
|
+
tier: "composition" | "core";
|
|
1778
1793
|
propCount: number;
|
|
1779
1794
|
hasExamples: boolean;
|
|
1780
1795
|
hasCompoundChildren: boolean;
|
|
@@ -1795,7 +1810,7 @@ declare const bundleManifestComponentEntrySchema: z.ZodObject<{
|
|
|
1795
1810
|
name: string;
|
|
1796
1811
|
}[];
|
|
1797
1812
|
publicSlug: string | null;
|
|
1798
|
-
tier: "
|
|
1813
|
+
tier: "composition" | "core";
|
|
1799
1814
|
propCount: number;
|
|
1800
1815
|
hasExamples: boolean;
|
|
1801
1816
|
hasCompoundChildren: boolean;
|
|
@@ -1904,7 +1919,7 @@ declare const bundleManifestSchema: z.ZodObject<{
|
|
|
1904
1919
|
name: string;
|
|
1905
1920
|
}[];
|
|
1906
1921
|
publicSlug: string | null;
|
|
1907
|
-
tier: "
|
|
1922
|
+
tier: "composition" | "core";
|
|
1908
1923
|
propCount: number;
|
|
1909
1924
|
hasExamples: boolean;
|
|
1910
1925
|
hasCompoundChildren: boolean;
|
|
@@ -1925,7 +1940,7 @@ declare const bundleManifestSchema: z.ZodObject<{
|
|
|
1925
1940
|
name: string;
|
|
1926
1941
|
}[];
|
|
1927
1942
|
publicSlug: string | null;
|
|
1928
|
-
tier: "
|
|
1943
|
+
tier: "composition" | "core";
|
|
1929
1944
|
propCount: number;
|
|
1930
1945
|
hasExamples: boolean;
|
|
1931
1946
|
hasCompoundChildren: boolean;
|
|
@@ -1948,7 +1963,7 @@ declare const bundleManifestSchema: z.ZodObject<{
|
|
|
1948
1963
|
name: string;
|
|
1949
1964
|
}[];
|
|
1950
1965
|
publicSlug: string | null;
|
|
1951
|
-
tier: "
|
|
1966
|
+
tier: "composition" | "core";
|
|
1952
1967
|
propCount: number;
|
|
1953
1968
|
hasExamples: boolean;
|
|
1954
1969
|
hasCompoundChildren: boolean;
|
|
@@ -1994,7 +2009,7 @@ declare const bundleManifestSchema: z.ZodObject<{
|
|
|
1994
2009
|
name: string;
|
|
1995
2010
|
}[];
|
|
1996
2011
|
publicSlug: string | null;
|
|
1997
|
-
tier: "
|
|
2012
|
+
tier: "composition" | "core";
|
|
1998
2013
|
propCount: number;
|
|
1999
2014
|
hasExamples: boolean;
|
|
2000
2015
|
hasCompoundChildren: boolean;
|
|
@@ -2198,7 +2213,7 @@ declare const bundleComponentShardSchema: z.ZodObject<{
|
|
|
2198
2213
|
}[];
|
|
2199
2214
|
source: "design-system";
|
|
2200
2215
|
publicSlug: string | null;
|
|
2201
|
-
tier: "
|
|
2216
|
+
tier: "composition" | "core";
|
|
2202
2217
|
relations: Record<string, unknown>[];
|
|
2203
2218
|
publicId: string | null;
|
|
2204
2219
|
usageGuidance: string;
|
|
@@ -2224,7 +2239,7 @@ declare const bundleComponentShardSchema: z.ZodObject<{
|
|
|
2224
2239
|
}[];
|
|
2225
2240
|
source: "design-system";
|
|
2226
2241
|
publicSlug: string | null;
|
|
2227
|
-
tier: "
|
|
2242
|
+
tier: "composition" | "core";
|
|
2228
2243
|
relations: Record<string, unknown>[];
|
|
2229
2244
|
publicId: string | null;
|
|
2230
2245
|
usageGuidance: string;
|
|
@@ -2255,7 +2270,7 @@ declare const bundleComponentShardSchema: z.ZodObject<{
|
|
|
2255
2270
|
}[];
|
|
2256
2271
|
source: "design-system";
|
|
2257
2272
|
publicSlug: string | null;
|
|
2258
|
-
tier: "
|
|
2273
|
+
tier: "composition" | "core";
|
|
2259
2274
|
relations: Record<string, unknown>[];
|
|
2260
2275
|
publicId: string | null;
|
|
2261
2276
|
usageGuidance: string;
|
|
@@ -2288,7 +2303,7 @@ declare const bundleComponentShardSchema: z.ZodObject<{
|
|
|
2288
2303
|
}[];
|
|
2289
2304
|
source: "design-system";
|
|
2290
2305
|
publicSlug: string | null;
|
|
2291
|
-
tier: "
|
|
2306
|
+
tier: "composition" | "core";
|
|
2292
2307
|
relations: Record<string, unknown>[];
|
|
2293
2308
|
publicId: string | null;
|
|
2294
2309
|
usageGuidance: string;
|
|
@@ -5510,6 +5525,7 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
5510
5525
|
path: string;
|
|
5511
5526
|
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
5512
5527
|
}>, "many">>;
|
|
5528
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
5513
5529
|
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
5514
5530
|
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
5515
5531
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -5527,6 +5543,7 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
5527
5543
|
path: string;
|
|
5528
5544
|
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
5529
5545
|
}>, "many">>;
|
|
5546
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
5530
5547
|
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
5531
5548
|
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
5532
5549
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -5544,6 +5561,7 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
5544
5561
|
path: string;
|
|
5545
5562
|
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
5546
5563
|
}>, "many">>;
|
|
5564
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
5547
5565
|
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
5548
5566
|
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
5549
5567
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -5561,6 +5579,7 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
5561
5579
|
path: string;
|
|
5562
5580
|
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
5563
5581
|
}>, "many">>;
|
|
5582
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
5564
5583
|
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
5565
5584
|
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
5566
5585
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -5578,6 +5597,7 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
5578
5597
|
path: string;
|
|
5579
5598
|
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
5580
5599
|
}>, "many">>;
|
|
5600
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
5581
5601
|
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
5582
5602
|
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
5583
5603
|
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -6726,6 +6746,33 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
6726
6746
|
}>>;
|
|
6727
6747
|
recognizedClassHelpers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
6728
6748
|
}, "strip", z.ZodTypeAny, {
|
|
6749
|
+
components?: string[] | undefined;
|
|
6750
|
+
screenshots?: z.objectOutputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
6751
|
+
tokens?: z.objectOutputType<{
|
|
6752
|
+
include: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
6753
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6754
|
+
path: z.ZodEffects<z.ZodString, string, string>;
|
|
6755
|
+
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
6756
|
+
}, "strip", z.ZodTypeAny, {
|
|
6757
|
+
path: string;
|
|
6758
|
+
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
6759
|
+
}, {
|
|
6760
|
+
path: string;
|
|
6761
|
+
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
6762
|
+
}>, "many">>;
|
|
6763
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
6764
|
+
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
6765
|
+
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
6766
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
6767
|
+
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
6768
|
+
namespace: z.ZodOptional<z.ZodString>;
|
|
6769
|
+
}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
6770
|
+
performance?: "strict" | "relaxed" | "standard" | {
|
|
6771
|
+
preset?: "strict" | "relaxed" | "standard" | undefined;
|
|
6772
|
+
budgets?: {
|
|
6773
|
+
bundleSize?: number | undefined;
|
|
6774
|
+
} | undefined;
|
|
6775
|
+
} | undefined;
|
|
6729
6776
|
govern?: {
|
|
6730
6777
|
components?: Record<string, {
|
|
6731
6778
|
rules: ({
|
|
@@ -6901,32 +6948,6 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
6901
6948
|
failOnWarnings: z.ZodOptional<z.ZodBoolean>;
|
|
6902
6949
|
}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
6903
6950
|
} | undefined;
|
|
6904
|
-
components?: string[] | undefined;
|
|
6905
|
-
screenshots?: z.objectOutputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
6906
|
-
tokens?: z.objectOutputType<{
|
|
6907
|
-
include: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
6908
|
-
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6909
|
-
path: z.ZodEffects<z.ZodString, string, string>;
|
|
6910
|
-
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
6911
|
-
}, "strip", z.ZodTypeAny, {
|
|
6912
|
-
path: string;
|
|
6913
|
-
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
6914
|
-
}, {
|
|
6915
|
-
path: string;
|
|
6916
|
-
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
6917
|
-
}>, "many">>;
|
|
6918
|
-
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
6919
|
-
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
6920
|
-
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
6921
|
-
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
6922
|
-
namespace: z.ZodOptional<z.ZodString>;
|
|
6923
|
-
}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
6924
|
-
performance?: "strict" | "relaxed" | "standard" | {
|
|
6925
|
-
preset?: "strict" | "relaxed" | "standard" | undefined;
|
|
6926
|
-
budgets?: {
|
|
6927
|
-
bundleSize?: number | undefined;
|
|
6928
|
-
} | undefined;
|
|
6929
|
-
} | undefined;
|
|
6930
6951
|
include?: string[] | undefined;
|
|
6931
6952
|
exclude?: string[] | undefined;
|
|
6932
6953
|
registry?: z.objectOutputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
@@ -6984,6 +7005,33 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
6984
7005
|
} | undefined;
|
|
6985
7006
|
recognizedClassHelpers?: string[] | undefined;
|
|
6986
7007
|
}, {
|
|
7008
|
+
components?: string[] | undefined;
|
|
7009
|
+
screenshots?: z.objectInputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
7010
|
+
tokens?: z.objectInputType<{
|
|
7011
|
+
include: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
7012
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
7013
|
+
path: z.ZodEffects<z.ZodString, string, string>;
|
|
7014
|
+
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
7015
|
+
}, "strip", z.ZodTypeAny, {
|
|
7016
|
+
path: string;
|
|
7017
|
+
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
7018
|
+
}, {
|
|
7019
|
+
path: string;
|
|
7020
|
+
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
7021
|
+
}>, "many">>;
|
|
7022
|
+
packages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
7023
|
+
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
7024
|
+
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
7025
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
7026
|
+
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
7027
|
+
namespace: z.ZodOptional<z.ZodString>;
|
|
7028
|
+
}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
7029
|
+
performance?: "strict" | "relaxed" | "standard" | {
|
|
7030
|
+
preset?: "strict" | "relaxed" | "standard" | undefined;
|
|
7031
|
+
budgets?: {
|
|
7032
|
+
bundleSize?: number | undefined;
|
|
7033
|
+
} | undefined;
|
|
7034
|
+
} | undefined;
|
|
6987
7035
|
govern?: {
|
|
6988
7036
|
components?: Record<string, {
|
|
6989
7037
|
rules: ({
|
|
@@ -7159,32 +7207,6 @@ declare const fragmentsConfigSchema: z.ZodObject<{
|
|
|
7159
7207
|
failOnWarnings: z.ZodOptional<z.ZodBoolean>;
|
|
7160
7208
|
}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
7161
7209
|
} | undefined;
|
|
7162
|
-
components?: string[] | undefined;
|
|
7163
|
-
screenshots?: z.objectInputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
7164
|
-
tokens?: z.objectInputType<{
|
|
7165
|
-
include: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
7166
|
-
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
7167
|
-
path: z.ZodEffects<z.ZodString, string, string>;
|
|
7168
|
-
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
7169
|
-
}, "strip", z.ZodTypeAny, {
|
|
7170
|
-
path: string;
|
|
7171
|
-
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
7172
|
-
}, {
|
|
7173
|
-
path: string;
|
|
7174
|
-
format?: "tailwind" | "auto" | "css" | "scss" | "dtcg" | undefined;
|
|
7175
|
-
}>, "many">>;
|
|
7176
|
-
exclude: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
|
|
7177
|
-
themeSelectors: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
7178
|
-
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
7179
|
-
format: z.ZodOptional<z.ZodEnum<["auto", "css", "scss", "dtcg", "tailwind"]>>;
|
|
7180
|
-
namespace: z.ZodOptional<z.ZodString>;
|
|
7181
|
-
}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
7182
|
-
performance?: "strict" | "relaxed" | "standard" | {
|
|
7183
|
-
preset?: "strict" | "relaxed" | "standard" | undefined;
|
|
7184
|
-
budgets?: {
|
|
7185
|
-
bundleSize?: number | undefined;
|
|
7186
|
-
} | undefined;
|
|
7187
|
-
} | undefined;
|
|
7188
7210
|
include?: string[] | undefined;
|
|
7189
7211
|
exclude?: string[] | undefined;
|
|
7190
7212
|
registry?: z.objectInputType<{}, z.ZodTypeAny, "passthrough"> | undefined;
|
|
@@ -8669,7 +8691,6 @@ declare const governedFragmentDefinitionSchema: z.ZodObject<{
|
|
|
8669
8691
|
guidelines?: string[] | undefined;
|
|
8670
8692
|
accessibility?: string[] | undefined;
|
|
8671
8693
|
};
|
|
8672
|
-
govern?: ((...args: unknown[]) => unknown) | undefined;
|
|
8673
8694
|
composition?: {
|
|
8674
8695
|
pattern?: "compound" | "simple" | "controlled" | "wrapper" | undefined;
|
|
8675
8696
|
subComponents?: string[] | undefined;
|
|
@@ -8685,6 +8706,7 @@ declare const governedFragmentDefinitionSchema: z.ZodObject<{
|
|
|
8685
8706
|
constraints?: string[] | undefined;
|
|
8686
8707
|
typeDetails?: Record<string, unknown> | undefined;
|
|
8687
8708
|
}> | undefined;
|
|
8709
|
+
govern?: ((...args: unknown[]) => unknown) | undefined;
|
|
8688
8710
|
contract?: {
|
|
8689
8711
|
composition?: {
|
|
8690
8712
|
rule: {
|
|
@@ -8815,7 +8837,6 @@ declare const governedFragmentDefinitionSchema: z.ZodObject<{
|
|
|
8815
8837
|
guidelines?: string[] | undefined;
|
|
8816
8838
|
accessibility?: string[] | undefined;
|
|
8817
8839
|
};
|
|
8818
|
-
govern?: ((...args: unknown[]) => unknown) | undefined;
|
|
8819
8840
|
composition?: {
|
|
8820
8841
|
pattern?: "compound" | "simple" | "controlled" | "wrapper" | undefined;
|
|
8821
8842
|
subComponents?: string[] | undefined;
|
|
@@ -8831,6 +8852,7 @@ declare const governedFragmentDefinitionSchema: z.ZodObject<{
|
|
|
8831
8852
|
constraints?: string[] | undefined;
|
|
8832
8853
|
typeDetails?: Record<string, unknown> | undefined;
|
|
8833
8854
|
}> | undefined;
|
|
8855
|
+
govern?: ((...args: unknown[]) => unknown) | undefined;
|
|
8834
8856
|
contract?: {
|
|
8835
8857
|
composition?: {
|
|
8836
8858
|
rule: {
|
|
@@ -9699,7 +9721,7 @@ interface ThemeParserResult {
|
|
|
9699
9721
|
|
|
9700
9722
|
declare function inferTokenCategory(name: string, value?: string): TokenCategory;
|
|
9701
9723
|
declare function inferTokenGroup(name: string): string;
|
|
9702
|
-
declare function normalizeTokenGroupComment(comment: string): string;
|
|
9724
|
+
declare function normalizeTokenGroupComment(comment: string): string | null;
|
|
9703
9725
|
|
|
9704
9726
|
declare function parseScssVariables(content: string): Map<string, string>;
|
|
9705
9727
|
declare function resolveTokenValue(rawValue: string, scssVars: Map<string, string>, cssVarValues: Map<string, string>, depth?: number): string;
|
|
@@ -10241,6 +10263,8 @@ declare const componentContractSchema: z.ZodObject<{
|
|
|
10241
10263
|
accessibility?: string[] | undefined;
|
|
10242
10264
|
};
|
|
10243
10265
|
$schema: string;
|
|
10266
|
+
status?: "experimental" | "stable" | "deprecated" | "beta" | undefined;
|
|
10267
|
+
tokens?: string[] | undefined;
|
|
10244
10268
|
preview?: {
|
|
10245
10269
|
css?: string[] | undefined;
|
|
10246
10270
|
theme?: "light" | "dark" | undefined;
|
|
@@ -10248,8 +10272,6 @@ declare const componentContractSchema: z.ZodObject<{
|
|
|
10248
10272
|
wrapperModule?: string | undefined;
|
|
10249
10273
|
wrapperExport?: string | undefined;
|
|
10250
10274
|
} | undefined;
|
|
10251
|
-
status?: "experimental" | "stable" | "deprecated" | "beta" | undefined;
|
|
10252
|
-
tokens?: string[] | undefined;
|
|
10253
10275
|
contract?: {
|
|
10254
10276
|
compoundChildren?: Record<string, {
|
|
10255
10277
|
description?: string | undefined;
|
|
@@ -10322,6 +10344,8 @@ declare const componentContractSchema: z.ZodObject<{
|
|
|
10322
10344
|
accessibility?: string[] | undefined;
|
|
10323
10345
|
};
|
|
10324
10346
|
$schema: string;
|
|
10347
|
+
status?: "experimental" | "stable" | "deprecated" | "beta" | undefined;
|
|
10348
|
+
tokens?: string[] | undefined;
|
|
10325
10349
|
preview?: {
|
|
10326
10350
|
css?: string[] | undefined;
|
|
10327
10351
|
theme?: "light" | "dark" | undefined;
|
|
@@ -10329,8 +10353,6 @@ declare const componentContractSchema: z.ZodObject<{
|
|
|
10329
10353
|
wrapperModule?: string | undefined;
|
|
10330
10354
|
wrapperExport?: string | undefined;
|
|
10331
10355
|
} | undefined;
|
|
10332
|
-
status?: "experimental" | "stable" | "deprecated" | "beta" | undefined;
|
|
10333
|
-
tokens?: string[] | undefined;
|
|
10334
10356
|
contract?: {
|
|
10335
10357
|
compoundChildren?: Record<string, {
|
|
10336
10358
|
description?: string | undefined;
|