Remaining work
Props that are not bound to any element (no content/visibility/instanceOf binding) are never created as Figma component properties on render — the whole props: block is missing from round-tripped specs. The reader does not require a binding: an orphan TEXT property with a default value round-trips fine, and inferNumberProps re-types numeric defaults on read.
Approach
In Props.apply(), after the bound-type pass, create a plain TEXT property for unbound string/number props (stringified default/example as the Figma default value). Skip code-only, slot, and variant props as today. Number-guard fixtures (notANumberParens, notANumberVersion) must stay strings — inference is read-side.
Affected fixtures
testNumberProp, testPropExamples
Verification
Round-trip diffs show the props blocks restored with correct types on the fixtures above.
Where (code)
specs-from-figma/packages/figma-from-specs/src/Props/Props.ts — apply() (bound-type loop + the unbound skip), inferBoundTypes(), textDefault()
- Reader counterpart (no binding required):
specs-from-figma/packages/specs-from-figma/src/Component/Props/Props.ts (numeric re-typing per ADR-029 / inferNumberProps)
Shared verification loop and working context: see parent #208.
Remaining work
Props that are not bound to any element (no content/visibility/instanceOf binding) are never created as Figma component properties on render — the whole
props:block is missing from round-tripped specs. The reader does not require a binding: an orphan TEXT property with a default value round-trips fine, andinferNumberPropsre-types numeric defaults on read.Approach
In
Props.apply(), after the bound-type pass, create a plain TEXT property for unbound string/number props (stringified default/example as the Figma default value). Skip code-only, slot, and variant props as today. Number-guard fixtures (notANumberParens, notANumberVersion) must stay strings — inference is read-side.Affected fixtures
testNumberProp, testPropExamples
Verification
Round-trip diffs show the props blocks restored with correct types on the fixtures above.
Where (code)
specs-from-figma/packages/figma-from-specs/src/Props/Props.ts—apply()(bound-type loop + the unbound skip),inferBoundTypes(),textDefault()specs-from-figma/packages/specs-from-figma/src/Component/Props/Props.ts(numeric re-typing per ADR-029 /inferNumberProps)Shared verification loop and working context: see parent #208.