Skip to content

fix(desktop): keep storyboards distinct from dashboards on shared code paths - #787

Draft
lauren-jacksonSFDC wants to merge 3 commits into
feature/desktopfrom
dev/ljackson/aug19/storyboard-parity
Draft

fix(desktop): keep storyboards distinct from dashboards on shared code paths#787
lauren-jacksonSFDC wants to merge 3 commits into
feature/desktopfrom
dev/ljackson/aug19/storyboard-parity

Conversation

@lauren-jacksonSFDC

Copy link
Copy Markdown

Work item: W-23854534 — bring storyboards to parity with worksheets/dashboards.

Decision

A story serializes as <dashboard type='storyboard'> and already rides the dashboard machinery (apply, cache, validation, inventory). This closes the storyboard/dashboard consistency gaps that do not need the deferred whole-workbook read fallback. The rule the codebase now keeps: the dashboard metadata resolvers treat a <dashboard type='storyboard'> as not a dashboard, so a story never leaks into the dashboard surface.

Changes

  • Dashboard fallback excludes storyboards (bug fix). listDashboardRefs / resolveDashboardRef / extractDashboardXml now skip @_type='storyboard'. Before this, on an older Desktop build using the whole-workbook-document fallback, list-dashboards returned stories and get-dashboard-xml could hand back a story fragment as a dashboard.
  • Kind-aware apply errors. resolveCanonicalDashboardName takes the load kind, so a storyboard apply that trips the name / workbook-document gate is told about storyboardName, not dashboard_name. The <dashboard> element tag and the read-cached-xml dashboard= selector stay literal — a story is a <dashboard> element and is sliced with that selector.
  • get-storyboard-xml aligned to its get-xml siblings. storyboardName is now required, the deprecated storyboard alias param is dropped, and the description matches get-dashboard-xml / get-worksheet-xml. Shrinks the dynamic-authoring tool surface by 51 bytes (byte-budget re-pinned in server.desktop.test.ts).
  • Tests. New listStoryboards.test.ts; storyboard slice/splice cases in the cache tests; dashboard-resolver exclusion cases.

Deferred (out of scope, by design)

  • The whole-workbook read fallback for list-storyboards / get-storyboard-xml — only helps Desktop builds that serve /v0/workbook/document but not the newer /storyboards routes (a narrow window). Consequence: with dashboards now excluding stories, a story on such an old build is simply not enumerable there (correct, not misclassified).
  • Adding list-storyboards to the default DYNAMIC_AUTHORING_TOOL_PROFILE (discovery-only; editing a named story still works).

Testing

  • Touched-file unit tests green; downstream suites (read gateway, storyboard apply, compose, contract, http, emitted-references) green.
  • npm run lint clean.
  • npm run build:desktop succeeds.

🤖 Generated with Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant