fix(core,types): fix Map content type — schema/component API mismatch, missing tests, schema hygiene#449
Merged
Merged
Conversation
Contributor
✅ Visual Regression Test ResultsStatus: ✅ All visual tests passed! All screenshots match the baseline. No visual regressions detected! 🎉 |
Contributor
⚡ Performance Benchmark Results✅ Build Time Benchmarks: PASSED✅ Bundle Size Benchmarks: PASSED❌ Runtime Vitals Benchmarks: FAILED📝 Note: Detailed results are available in the job logs. 🎯 Performance Budgets:
Updated: 2026-05-19T01:50:49.106Z |
…hygiene, tests - Map.tsx: assemble MapConfig from flat YAML props (center, zoom, markers, etc.) instead of expecting a pre-built config object that never arrived at runtime; absorb label and type so they don't pollute ...rest spread to DOM - Move Map.tsx from orphaned content/ to base/ alongside other schema components; update all imports in componentRegistry.ts, base/index.ts, core/src/index.ts - mapLayerSchema.data: z.any() → z.unknown() (explicit escape hatch) - plugin.ts: remove duplicate ZodLike interface declaration - secret-detection.ts: fix entropy threshold direction — warn on low-entropy plaintext passwords (< 3.8 bits/char) not high-entropy random values - Delete TASK-1.4-COMPLETE.md task artifact from packages/types/ - Add changeset: @stackwright/types patch, @stackwright/core patch - packages/types/test/map-content.test.ts: 28 new schema tests - packages/core/test/components/map.test.tsx: 22 new component tests - Full suite: 1,147 tests, 0 failures
1b3259d to
47360f0
Compare
Contributor
✅ Visual Regression Test ResultsStatus: ✅ All visual tests passed! All screenshots match the baseline. No visual regressions detected! 🎉 |
Contributor
♿ Accessibility Test ResultsOverall Status: ✅ 0/0 tests passed 🦮 WCAG 2.1 AA ComplianceNo WCAG test results available ⌨️ Keyboard NavigationNo keyboard navigation test results available 📊 Detailed ReportDownload the full HTML accessibility report from the workflow artifacts for:
🔍 Testing ChecklistOur accessibility tests verify:
Powered by @axe-core/playwright and Playwright |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What broke
The
mapcontent type was registered, documented, and agent-writable but silently crashed on render.contentRendererspreads YAML fields as flat props; theMapcomponent expected a pre-assembledconfig: MapConfigsub-object that never arrived.configwas alwaysundefinedat runtime.What was fixed
Map.tsx: now assemblesMapConfigfrom flat YAML props (center,zoom,markers,layers,view,terrain) before passing to the MapProvider.labelandtypeare explicitly absorbed so they don't pollute...rest→ DOM.Map.tsxfrom the orphanedcontent/directory tobase/(where all other schema-backed content components live). Updated all imports incomponentRegistry.ts,base/index.ts,core/src/index.ts.mapLayerSchema.data:z.any()→z.unknown()(philosophy: escape hatches should be explicit, not invisible)ZodLikeinterface declaration inplugin.tsremovedTASK-1.4-COMPLETE.mdtask artifact deleted frompackages/types/checkForPlaintextSecret: entropy threshold corrected —entropy > 4.5was warning on high-entropy random values (wrong direction); fixed toentropy < 3.8which catches weak plaintext passwords likepassword123(entropy ≈ 3.59) while leaving higher-entropy generated values alone (entropy ≈ 3.91+). Follow-up issue filed in beads for bi-directional detection (stackwright-wao).Tests added
packages/types/test/map-content.test.ts— 28 schema validation tests (markers, layers, mapContent, boundary zoom values, all optional fields, view enum coverage)packages/core/test/components/map.test.tsx— 22 component tests (config assembly from flat props, DOM attribute hygiene forlabel/type, dimension defaults, theming)Test suite
1,147 tests, 0 failures across 13 packages.
Changeset
.changeset/fix-map-component-api.md—@stackwright/typespatch,@stackwright/corepatch.