@unified-product-graph/core 0.38.0 → 0.40.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/index.d.cts CHANGED
@@ -2264,6 +2264,13 @@ declare const UPG_EDGE_CATALOG: {
2264
2264
  source_type: string;
2265
2265
  target_type: string;
2266
2266
  };
2267
+ feature_area_groups_design_component: {
2268
+ forward_verb: string;
2269
+ reverse_verb: string;
2270
+ classification: "hierarchy";
2271
+ source_type: string;
2272
+ target_type: string;
2273
+ };
2267
2274
  outcome_delivered_by_feature: {
2268
2275
  forward_verb: string;
2269
2276
  reverse_verb: string;
@@ -2896,6 +2903,14 @@ declare const UPG_EDGE_CATALOG: {
2896
2903
  source_type: string;
2897
2904
  target_type: string;
2898
2905
  };
2906
+ design_token_derives_from_design_token: {
2907
+ forward_verb: string;
2908
+ reverse_verb: string;
2909
+ classification: "causal";
2910
+ source_type: string;
2911
+ target_type: string;
2912
+ cross_product_eligible: true;
2913
+ };
2899
2914
  design_component_follows_design_pattern: {
2900
2915
  forward_verb: string;
2901
2916
  reverse_verb: string;
@@ -2923,6 +2938,7 @@ declare const UPG_EDGE_CATALOG: {
2923
2938
  classification: "hierarchy";
2924
2939
  source_type: string;
2925
2940
  target_type: string;
2941
+ cross_product_eligible: true;
2926
2942
  };
2927
2943
  prototype_annotated_with_annotation: {
2928
2944
  forward_verb: string;
@@ -14345,8 +14361,28 @@ interface DesignComponentProperties {
14345
14361
  * }
14346
14362
  */
14347
14363
  interface DesignTokenProperties {
14348
- /** Category */
14349
- category?: 'color' | 'spacing' | 'typography' | 'radius' | 'motion';
14364
+ /**
14365
+ * What kind of value this token holds. Aligned to the Design Tokens
14366
+ * Community Group `$type` vocabulary so a DTCG export maps across without
14367
+ * translation; the five original UPG values are kept, `color` and `spacing`
14368
+ * being the ones DTCG spells the same and `typography`, `radius`, `motion`
14369
+ * being groupings a design system names in its own terms.
14370
+ *
14371
+ * @remarks
14372
+ * DTCG mapping for the values that are not one-to-one: a `radius` token is a
14373
+ * DTCG `dimension`, a `motion` token is usually a `duration` or a
14374
+ * `cubicBezier`, and a `typography` token is a composite over `fontFamily` /
14375
+ * `fontWeight` / `dimension`. Both spellings are accepted: an estate that
14376
+ * speaks DTCG writes the `$type` name, one that speaks UPG's original five
14377
+ * keeps writing them, and neither has to translate at the boundary.
14378
+ *
14379
+ * Extended at 0.39.0 from a measured estate (163 DTCG primitives) whose
14380
+ * `shadow`, `dimension` and `opacity` tokens had no category to land on. The
14381
+ * enum was documented but unenforced then; `validate_graph`'s
14382
+ * `property_enum_drift` class (same release) is what makes it real, which is
14383
+ * why the vocabulary had to be right before the check arrived.
14384
+ */
14385
+ category?: 'color' | 'spacing' | 'typography' | 'radius' | 'motion' | 'dimension' | 'fontFamily' | 'fontWeight' | 'duration' | 'cubicBezier' | 'number' | 'shadow' | 'gradient' | 'border' | 'transition' | 'strokeStyle' | 'opacity';
14350
14386
  /** Resolved value */
14351
14387
  value: string;
14352
14388
  /** CSS custom property name */
@@ -26999,7 +27035,7 @@ declare function checkHeaderSealText(text: string): UPGHeaderSealReport;
26999
27035
  * it stamps the `upg_version` field of every `.upg` file written by the SDK.
27000
27036
  * The `check:version-lockstep` gate enforces this at release time.
27001
27037
  */
27002
- declare const UPG_VERSION: "0.38.0";
27038
+ declare const UPG_VERSION: "0.40.0";
27003
27039
  /**
27004
27040
  * The `.upg` JSON document format version. Written to the `upg_version` field.
27005
27041
  * Evolves independently from `UPG_VERSION` (the catalogue version).
package/dist/index.d.ts CHANGED
@@ -2264,6 +2264,13 @@ declare const UPG_EDGE_CATALOG: {
2264
2264
  source_type: string;
2265
2265
  target_type: string;
2266
2266
  };
2267
+ feature_area_groups_design_component: {
2268
+ forward_verb: string;
2269
+ reverse_verb: string;
2270
+ classification: "hierarchy";
2271
+ source_type: string;
2272
+ target_type: string;
2273
+ };
2267
2274
  outcome_delivered_by_feature: {
2268
2275
  forward_verb: string;
2269
2276
  reverse_verb: string;
@@ -2896,6 +2903,14 @@ declare const UPG_EDGE_CATALOG: {
2896
2903
  source_type: string;
2897
2904
  target_type: string;
2898
2905
  };
2906
+ design_token_derives_from_design_token: {
2907
+ forward_verb: string;
2908
+ reverse_verb: string;
2909
+ classification: "causal";
2910
+ source_type: string;
2911
+ target_type: string;
2912
+ cross_product_eligible: true;
2913
+ };
2899
2914
  design_component_follows_design_pattern: {
2900
2915
  forward_verb: string;
2901
2916
  reverse_verb: string;
@@ -2923,6 +2938,7 @@ declare const UPG_EDGE_CATALOG: {
2923
2938
  classification: "hierarchy";
2924
2939
  source_type: string;
2925
2940
  target_type: string;
2941
+ cross_product_eligible: true;
2926
2942
  };
2927
2943
  prototype_annotated_with_annotation: {
2928
2944
  forward_verb: string;
@@ -14345,8 +14361,28 @@ interface DesignComponentProperties {
14345
14361
  * }
14346
14362
  */
14347
14363
  interface DesignTokenProperties {
14348
- /** Category */
14349
- category?: 'color' | 'spacing' | 'typography' | 'radius' | 'motion';
14364
+ /**
14365
+ * What kind of value this token holds. Aligned to the Design Tokens
14366
+ * Community Group `$type` vocabulary so a DTCG export maps across without
14367
+ * translation; the five original UPG values are kept, `color` and `spacing`
14368
+ * being the ones DTCG spells the same and `typography`, `radius`, `motion`
14369
+ * being groupings a design system names in its own terms.
14370
+ *
14371
+ * @remarks
14372
+ * DTCG mapping for the values that are not one-to-one: a `radius` token is a
14373
+ * DTCG `dimension`, a `motion` token is usually a `duration` or a
14374
+ * `cubicBezier`, and a `typography` token is a composite over `fontFamily` /
14375
+ * `fontWeight` / `dimension`. Both spellings are accepted: an estate that
14376
+ * speaks DTCG writes the `$type` name, one that speaks UPG's original five
14377
+ * keeps writing them, and neither has to translate at the boundary.
14378
+ *
14379
+ * Extended at 0.39.0 from a measured estate (163 DTCG primitives) whose
14380
+ * `shadow`, `dimension` and `opacity` tokens had no category to land on. The
14381
+ * enum was documented but unenforced then; `validate_graph`'s
14382
+ * `property_enum_drift` class (same release) is what makes it real, which is
14383
+ * why the vocabulary had to be right before the check arrived.
14384
+ */
14385
+ category?: 'color' | 'spacing' | 'typography' | 'radius' | 'motion' | 'dimension' | 'fontFamily' | 'fontWeight' | 'duration' | 'cubicBezier' | 'number' | 'shadow' | 'gradient' | 'border' | 'transition' | 'strokeStyle' | 'opacity';
14350
14386
  /** Resolved value */
14351
14387
  value: string;
14352
14388
  /** CSS custom property name */
@@ -26999,7 +27035,7 @@ declare function checkHeaderSealText(text: string): UPGHeaderSealReport;
26999
27035
  * it stamps the `upg_version` field of every `.upg` file written by the SDK.
27000
27036
  * The `check:version-lockstep` gate enforces this at release time.
27001
27037
  */
27002
- declare const UPG_VERSION: "0.38.0";
27038
+ declare const UPG_VERSION: "0.40.0";
27003
27039
  /**
27004
27040
  * The `.upg` JSON document format version. Written to the `upg_version` field.
27005
27041
  * Evolves independently from `UPG_VERSION` (the catalogue version).
package/dist/index.js CHANGED
@@ -1494,6 +1494,15 @@ var UPG_EDGE_CATALOG = {
1494
1494
  product_categorises_by_roadmap_theme: { forward_verb: "categorises_by", reverse_verb: "categorises", classification: "hierarchy", source_type: "product", target_type: "roadmap_theme" },
1495
1495
  feature_area_contains_feature: { forward_verb: "contains", reverse_verb: "belongs_to", classification: "hierarchy", source_type: "feature_area", target_type: "feature" },
1496
1496
  feature_area_contains_feature_area: { forward_verb: "contains", reverse_verb: "belongs_to", classification: "hierarchy", source_type: "feature_area", target_type: "feature_area" },
1497
+ // (0.39.0, B4) Component catalogs group by area -- a storybook sidebar that
1498
+ // follows the source tree, a visual-coverage report -- and the graph had no
1499
+ // edge for it, so a measured estate tagged 133 components `area:<group>`
1500
+ // instead. `groups`, not `contains`: the area does not OWN the component
1501
+ // (a design_system or product does); it is a grouping view over components
1502
+ // owned elsewhere, the same non-owning relationship `journey_phase_spans_journey_step`
1503
+ // records. Multi-parent GRAMMAR with single per-instance parentage, the
1504
+ // `quote` precedent.
1505
+ feature_area_groups_design_component: { forward_verb: "groups", reverse_verb: "grouped_in", classification: "hierarchy", source_type: "feature_area", target_type: "design_component" },
1497
1506
  outcome_delivered_by_feature: { forward_verb: "delivered_by", reverse_verb: "delivers", classification: "cross-domain", source_type: "outcome", target_type: "feature" },
1498
1507
  outcome_delivered_via_feature_area: { forward_verb: "delivered_via", reverse_verb: "delivers_for", classification: "cross-domain", source_type: "outcome", target_type: "feature_area" },
1499
1508
  feature_decomposed_into_epic: { forward_verb: "decomposed_into", reverse_verb: "implements", classification: "hierarchy", source_type: "feature", target_type: "epic" },
@@ -1813,10 +1822,32 @@ var UPG_EDGE_CATALOG = {
1813
1822
  // decision records design choices about the system; not contained by it.
1814
1823
  design_system_decided_via_decision: { forward_verb: "decided_via", reverse_verb: "decided_for", classification: "semantic", source_type: "design_system", target_type: "decision" },
1815
1824
  design_component_styled_by_design_token: { forward_verb: "styled_by", reverse_verb: "styles", classification: "hierarchy", source_type: "design_component", target_type: "design_token" },
1825
+ // (0.39.0, B2) The alias tier. A modern token system is two or three tiers --
1826
+ // primitives (`--gray-100`) that semantic tokens alias
1827
+ // (`--background-high: light-dark(var(--gray-100), var(--gray-900))`) that
1828
+ // components consume -- and the spec could hold the ends but not the middle,
1829
+ // so a measured estate (163 DTCG primitives, 45 semantic aliases) kept its
1830
+ // alias chain in descriptions. `causal`, not `semantic`: the alias's VALUE is
1831
+ // computed from the primitive's, so the dependency is real and directional.
1832
+ // `cross_product_eligible` because the primitive tier is routinely its own
1833
+ // published package (its own graph) while the semantic tier lives with the
1834
+ // component library. Makes "which primitives does this component ultimately
1835
+ // depend on" and "which primitives are dead" traversals rather than scripts.
1836
+ design_token_derives_from_design_token: { forward_verb: "derives_from", reverse_verb: "derived_into", classification: "causal", source_type: "design_token", target_type: "design_token", cross_product_eligible: true },
1816
1837
  design_component_follows_design_pattern: { forward_verb: "follows", reverse_verb: "followed_by", classification: "hierarchy", source_type: "design_component", target_type: "design_pattern" },
1817
1838
  design_component_governed_by_design_guideline: { forward_verb: "governed_by", reverse_verb: "governs", classification: "hierarchy", source_type: "design_component", target_type: "design_guideline" },
1818
1839
  design_component_specified_by_interaction_spec: { forward_verb: "specified_by", reverse_verb: "specifies", classification: "hierarchy", source_type: "design_component", target_type: "interaction_spec" },
1819
- design_component_composes_design_component: { forward_verb: "composes", reverse_verb: "composed_in", classification: "hierarchy", source_type: "design_component", target_type: "design_component" },
1840
+ // (0.39.0, B1) `cross_product_eligible` because a design system and the
1841
+ // product that consumes it are two graphs: a Studio shadow component wrapping
1842
+ // the @sanity/ui primitive it is built on could not be stated, and 11 such
1843
+ // wrappers recorded the relationship in prose instead. Widened rather than
1844
+ // minting `design_component_wraps_design_component`: a wrap IS composition
1845
+ // read across a graph boundary, and a second verb for one relationship is the
1846
+ // shadow-pair shape Pattern D collapses. `design_component` is already
1847
+ // portfolio_shared, and the three sibling component edges
1848
+ // (surface_renders_, screen_renders_, feature_uses_) are already eligible;
1849
+ // this closes the last link between a product graph and its design system.
1850
+ design_component_composes_design_component: { forward_verb: "composes", reverse_verb: "composed_in", classification: "hierarchy", source_type: "design_component", target_type: "design_component", cross_product_eligible: true },
1820
1851
  prototype_annotated_with_annotation: { forward_verb: "annotated_with", reverse_verb: "annotates", classification: "hierarchy", source_type: "prototype", target_type: "annotation" },
1821
1852
  screen_renders_design_component: { forward_verb: "renders", reverse_verb: "rendered_on", classification: "hierarchy", source_type: "screen", target_type: "design_component", cross_product_eligible: true },
1822
1853
  // Marketing surface to product (0.12.7, UPG-696/698). A marketing/landing screen
@@ -7520,7 +7551,7 @@ var UPG_VALID_CHILDREN = {
7520
7551
  // parent. Same widening shape as the 0.23.0 epic twins: an existing leaf type
7521
7552
  // gains a second, SHALLOWER parent, verbs inherited from the deeper edge.
7522
7553
  feature: ["epic", "bug", "task", "user_story"],
7523
- feature_area: ["feature", "feature_area"],
7554
+ feature_area: ["feature", "feature_area", "design_component"],
7524
7555
  // epic owns user_story (the templated promise) and, mirroring feature, may
7525
7556
  // also directly contain bug/task — heterogeneous imported tickets that belong
7526
7557
  // to one epic rather than the feature as a whole (feedback df99026a).
@@ -13081,7 +13112,7 @@ var UPG_PROPERTY_SCHEMA = {
13081
13112
  },
13082
13113
  // DesignTokenProperties: Design token.
13083
13114
  design_token: {
13084
- category: { type: "string", enum: ["color", "spacing", "typography", "radius", "motion"], description: "Category" },
13115
+ category: { type: "string", enum: ["color", "spacing", "typography", "radius", "motion", "dimension", "fontFamily", "fontWeight", "duration", "cubicBezier", "number", "shadow", "gradient", "border", "transition", "strokeStyle", "opacity"], description: "What kind of value this token holds. Aligned to the Design Tokens Community Group `$type` vocabulary so a DTCG export maps across without translation; the five original UPG values are kept, `color` and `spacing` being the ones DTCG spells the same and `typography`, `radius`, `motion` being groupings a design system names in its own terms.", notes: "DTCG mapping for the values that are not one-to-one: a `radius` token is a DTCG `dimension`, a `motion` token is usually a `duration` or a `cubicBezier`, and a `typography` token is a composite over `fontFamily` / `fontWeight` / `dimension`. Both spellings are accepted: an estate that speaks DTCG writes the `$type` name, one that speaks UPG's original five keeps writing them, and neither has to translate at the boundary. Extended at 0.39.0 from a measured estate (163 DTCG primitives) whose `shadow`, `dimension` and `opacity` tokens had no category to land on. The enum was documented but unenforced then; `validate_graph`'s `property_enum_drift` class (same release) is what makes it real, which is why the vocabulary had to be right before the check arrived." },
13085
13116
  value: { type: "string", description: "Resolved value" },
13086
13117
  css_variable: { type: "string", description: "CSS custom property name" }
13087
13118
  },
@@ -33863,7 +33894,7 @@ function checkHeaderSealText(text) {
33863
33894
  }
33864
33895
 
33865
33896
  // src/index.ts
33866
- var UPG_VERSION = "0.38.0";
33897
+ var UPG_VERSION = "0.40.0";
33867
33898
  var UPG_FORMAT_VERSION = "0.4.0";
33868
33899
  var MARKDOWN_FORMAT_VERSION = "0.1";
33869
33900
  var UPG_TYPES = getTypes();