Feature: website builder - #1633
Draft
Jakob1999 wants to merge 108 commits into
Draft
Conversation
Introduce the foundation for the drag-and-drop website builder. The editor model reuses the runtime grid plugin's config shape (TGridPluginConfig) so the build format equals the runtime format. Includes pure, immutable transforms (add/remove/move widget, overlap/clamp/free-area helpers) and serialize/ deserialize to the canonical DMSS grid entity JSON. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add the WYSIWYG editing surfaces: a categorised widget palette of draggable blocks (Section, Text, Image, Table, Form) built on @dnd-kit, and a CSS-grid canvas that renders placed widgets, supports selection and deletion, shows a drop-target highlight and an empty state. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Wire the palette and canvas together under a DndContext: dragging a palette block onto the canvas (or clicking it) adds a widget to the model. Add a toolbar with Edit/Preview toggle and a read-only JSON inspector. Preview mode round-trips the model through serialize/deserialize and renders it with the existing grid plugin, proving build format equals runtime format. Register the plugin as @development-framework/dm-core-plugins/builder. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Address review findings on the Phase 0 spike: - clampArea now clamps spans larger than the grid so areas stay in bounds. - findFreeArea returns null when full; addWidget grows the grid and places the widget at the bottom instead of silently overlapping existing items. - Generated widgets use a valid InlineRecipeViewConfig pointing at the block's runtime plugin, so preview renders through the real grid plugin. - JSON inspector replaces the canvas area instead of obscuring it. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Cover model transforms (add/remove/move with immutability), overlap/clamp helpers including oversized and full-grid edge cases, free-area placement, and the serialize/deserialize round-trip with DMSS type discriminators. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Phase 0 completed: scaffolded the drag-and-drop website builder plugin with a widget palette, a dnd-kit grid canvas (drag/click to add, select, delete), an edit/preview toggle that round-trips through the runtime grid plugin, a JSON inspector, and a unit-tested pure editor model. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…trics Extend the editor model with pure transforms needed for canvas editing: translateArea, resizeWidget (clamped, min 1x1), duplicateWidget (placed in the first free area), and wouldOverlap for collision checks. Add a gridMetrics helper that converts pixel deltas into whole grid-cell deltas from the measured grid rect, accounting for the canvas padding and gap. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Canvas widgets can now be edited directly: - Drag a widget by its header to reposition it; the pixel delta is snapped to grid cells (useDraggable + useDndMonitor) and committed via moveWidget. - A corner resize handle resizes a widget live using pointer events, kept separate from dnd-kit so move and resize never conflict. - Duplicate action added to the widget chrome. - Moves and resizes are clamped to the grid and rejected when they would overlap another widget, preserving the no-overlap invariant. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- duplicateWidget now shares allocateArea with addWidget, so duplicating into a full grid grows the grid instead of overlapping an existing widget. - gridMetrics and the canvas grid use separate column/row gaps, so drag/resize snapping stays correct when columnGap != rowGap. - move/resize handlers guard against stale indices to avoid crashes when an item is removed around a gesture. - resize pointer-up only releases an active pointer capture and also handles pointer cancel, avoiding a rare throw. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add unit tests for translateArea, resizeWidget (min 1x1, clamping, immutability), duplicateWidget (free-space placement, deep-cloned view config, out-of-range index, and growing a full grid without overlap), wouldOverlap, and the pixel-to-cell grid metrics including per-axis gaps and degenerate strides. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Phase 1 completed: widgets can be moved by dragging their header (snapped to grid cells), resized via a corner handle, and duplicated, with moves/resizes clamped to the grid and overlap-guarded. Existing pages load for editing. Documents known limitations (index-based ids, px gap assumption). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add a right-hand inspector that edits the selected widget through typed form controls instead of raw JSON: - General: title and label. - Layout: column/row position and width/height, clamped and overlap-guarded. - Data binding: scope, for data-bound widgets (Table, Form). - Content: block-specific fields driven by the manifest (Text content, Image src/alt, Table page size, Form read-only), rendered as text/textarea/number/ boolean controls. Introduce a typed inspector-field schema on blocks, immutable model setters (setWidgetTitle/Area/Scope/Label/ConfigValue) and a 3-column builder layout. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Address review of the property inspector: - Block fields now target config keys the runtime plugins actually consume. Image exposes caption/width/height (read by the media-viewer); the speculative text/table/form config fields are removed. - Blocks carry a sensible defaultConfig that seeds the recipe config, so a dropped Table renders in preview instead of throwing on a missing variant. - The scope (data binding) field is shown for every widget, since content and media widgets also bind to a document via scope. - Number inputs ignore non-finite intermediate values so NaN never enters the model. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add unit tests for the inspector model setters (setWidgetTitle/Scope/Label/ ConfigValue with immutability and string-recipe no-op, setWidgetArea clamping) and for default config seeding (image fill, valid table variant, no shared config between widgets of the same block). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Phase 2 completed: a property inspector lets users configure the selected widget (title, label, grid layout, data-binding scope, and block-specific settings) through typed form controls instead of JSON. Blocks seed a valid default config so widgets render in preview. Documents the inline-recipe limitation. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
A Section widget now holds its own grid (seeded via defaultConfig) and can be edited in place: - model helpers isContainerItem, ensureModel, getSubModel and setSubModel read and immutably update the grid at a path of nested container indices. - BuilderPlugin tracks an edit path; all canvas/inspector actions operate on the active (possibly nested) grid via updateActive, with breadcrumb navigation. - Container widgets expose an Open action (and double-click) to drill in; the canvas shows the child count. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add a Templates menu to the toolbar offering Blank, Landing page, Dashboard and Article presets that build a ready-to-edit layout. Add a desktop/tablet/mobile width switcher that frames the canvas and preview so layouts can be checked at common breakpoints. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…nested paths getSubModel and setSubModel previously treated any item with an object recipe as a nestable container, which could traverse into a widget whose inline recipe happened to carry a config. Both now guard traversal with isContainerItem so only section-style nested grids are entered, keeping drill-in navigation consistent with what the canvas renders as a container. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add unit tests for isContainerItem, ensureModel, getSubModel and setSubModel (path traversal, immutability and invalid-path no-ops), and for the template presets (uniqueness, fresh builds, non-overlapping dashboard layout). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Record section nesting with drill-in editing, starter templates and the device-width preview switcher. Note the nested-grid serialization limit (root-only type discriminators) as deferred to phase 5. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add an immutable undo/redo history (history.ts + useHistory hook) backing the editor model. Toolbar Undo/Redo buttons and Ctrl/Cmd+Z, Shift+Z and Y shortcuts step through changes. Consecutive related edits coalesce into a single undo step via labels: a drag-resize commits on pointer-up and typing in an inspector field commits on blur. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add a single-slot toast (useToast + EDS Snackbar) so the builder explains itself instead of silently ignoring actions. Moves and inspector size edits that would overlap another widget now surface a friendly message, and delete/duplicate/template actions confirm what happened. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add an insertWidgetItem model helper (now shared with duplicate) that appends an independent deep-cloned widget into free space. Wire a clipboard plus shortcuts: Ctrl/Cmd+C copy, Ctrl/Cmd+V paste, Ctrl/Cmd+D duplicate, Delete/Backspace remove the selected widget and Escape clears the selection. Shortcuts stay inert while typing in a field. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add an Outline panel beneath the palette listing the widgets in the grid currently being edited. Clicking a row selects that widget; container rows show their child count and can be opened to drill into the nested section, mirroring the canvas and breadcrumb. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Track the page against the last-saved JSON and show a toolbar status (All changes saved / Saving… / Unsaved changes). When the host provides an onChange handler, edits autosave after a short debounce; either way the browser warns before navigating away while changes are unsaved. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Address review findings on the phase 4 history work: - Undo/redo only tracked the model, so the drill-in path could outlive the section it pointed at and silently route edits into a no-op. Add clampPath and validate the path (and clear stale selection) whenever the model changes. - handleMove/handleSetArea now re-derive and re-check inside the functional updater so a concurrent edit is never dropped; the render-closure check is kept only for immediate overlap feedback. - Give toasts a monotonic id so rapid messages always restart the timer. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add history.test.ts for the pure history stack (push/coalesce/undo/redo, limit trimming, break) and extend model.test.ts with insertWidgetItem (independent deep copy, free placement, grid growth, immutability) and clampPath (truncation at non-container, missing index and removed ancestor). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Record undo/redo, copy/paste and keyboard editing, the outline panel, toast feedback and the dirty-state/autosave guard. Note alignment guides and outline drag-to-reorder as deferred (the latter needs stable widget ids). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sections were emitted as raw builder models; the runtime grid plugin needs the same DMSS type tags on nested grids. serialize/deserialize now recurse into Section containers so nested layouts render and round-trip. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add a BuilderPluginConfig blueprint (mode + initialConfig grid) so the plugin config is importable, plus a DemoDataSource example: a Page blueprint, entity and a recipe mounting the builder with a seeded layout incl. a nested section. Open it at view?documentId=DemoDataSource/builderPageExample. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
And change borderradius of Website Cards
There was a problem hiding this comment.
Pull request overview
Adds a new website builder feature set to dm-core-plugins, exposing a public builder/grid contract, extending existing plugins to support builder-authored inline content/uploads, and updating the example app + E2E coverage to exercise the new flow.
Changes:
- Introduces a drag-and-drop website builder (widgets registry, editor chrome, persistence model, site directory) with unit tests.
- Extends the grid plugin contract with per-item styling and a dedicated public
gridentrypoint. - Updates Markdown + Media Viewer plugins to support inline markdown content and direct file-address binding; updates example app seeding and adds a Playwright smoke test.
Reviewed changes
Copilot reviewed 120 out of 122 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/dm-core-plugins/src/mediaViewer/MediaViewerPlugin.types.ts | Adds address override to media viewer config for direct file binding. |
| packages/dm-core-plugins/src/mediaViewer/MediaViewerPlugin.tsx | Uses config.address when provided; renders a friendly empty state when not bound to a file. |
| packages/dm-core-plugins/src/markdown/MarkdownPlugin.tsx | Adds inline markdown config path and bypasses DMSS fetch when inline content is present. |
| packages/dm-core-plugins/src/index.tsx | Re-exports builder/grid public types/helpers and registers builder static widgets into the plugin map. |
| packages/dm-core-plugins/src/grid/types.ts | Adds TGridItemStyle plus style/titleStyle on grid items. |
| packages/dm-core-plugins/src/grid/index.ts | New public barrel entry for the grid plugin and its contract types. |
| packages/dm-core-plugins/src/grid/GridElement.tsx | Applies optional item/title styling at render time (alignment, font, padding, etc.). |
| packages/dm-core-plugins/src/builder/widgets/types.ts | Defines the widget registry contract (TWidgetDefinition). |
| packages/dm-core-plugins/src/builder/widgets/text.widget.ts | Adds Text widget definition that reuses the markdown runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/table.widget.ts | Adds Table widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/spacer.widget.ts | Adds Spacer widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/section.widget.ts | Adds Section (container) widget definition that reuses the grid runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/metric.widget.ts | Adds Metric widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/liveTable.widget.ts | Adds Live table widget definition backed by a DMSS-bound runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/index.ts | Adds central widget registry + derived BLOCKS/icons + runtime plugin-map entries for static widgets. |
| packages/dm-core-plugins/src/builder/widgets/image.widget.ts | Adds Image widget definition that reuses the media viewer runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/heading.widget.ts | Adds Heading widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/embed.widget.ts | Adds Embed widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/divider.widget.ts | Adds Divider widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/datePicker.widget.tsx | Adds a self-contained Date picker widget (widget definition + runtime component co-located). |
| packages/dm-core-plugins/src/builder/widgets/datePicker.widget.styles.ts | Styling for the Date picker widget. |
| packages/dm-core-plugins/src/builder/widgets/chart.widget.ts | Adds Chart widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/widgets/button.widget.ts | Adds Button widget definition backed by a static runtime plugin. |
| packages/dm-core-plugins/src/builder/utils/toast.ts | Adds minimal toast state hook used by the builder UI. |
| packages/dm-core-plugins/src/builder/utils/spreadsheet.ts | Adds CSV/Excel parsing utility (SheetJS) with row/col caps. |
| packages/dm-core-plugins/src/builder/utils/mathUtils.ts | Adds pure numeric utilities for builder data widgets (metric/chart). |
| packages/dm-core-plugins/src/builder/utils/markdownTable.ts | Adds markdown-table <-> string[][] conversion used by table widgets. |
| packages/dm-core-plugins/src/builder/utils/icons.ts | Centralizes editor chrome icons and merges widget palette icons. |
| packages/dm-core-plugins/src/builder/utils/gridMetrics.ts | Adds pixel-to-grid-cell delta conversion for drag/resize behaviors. |
| packages/dm-core-plugins/src/builder/types/siteDirectory.ts | Defines configuration type for the site directory plugin. |
| packages/dm-core-plugins/src/builder/types/index.ts | Defines builder editor model, plugin config, blocks, and inspector field contracts. |
| packages/dm-core-plugins/src/builder/tests/WidgetPalette.test.tsx | Tests widget palette renders and triggers add behavior. |
| packages/dm-core-plugins/src/builder/tests/templates.test.ts | Tests template registry integrity and layout validity. |
| packages/dm-core-plugins/src/builder/tests/SiteGrid.test.tsx | Tests read-only site renderer renders inline-config widgets and nested grids. |
| packages/dm-core-plugins/src/builder/tests/siteBlueprints.test.ts | Validates serialized builder site output against builder blueprints and round-tripping. |
| packages/dm-core-plugins/src/builder/tests/registry.test.ts | Adds guardrail tests for widget registry uniqueness and icon/runtime registration. |
| packages/dm-core-plugins/src/builder/tests/Outline.test.tsx | Tests outline panel behavior (selection and container navigation). |
| packages/dm-core-plugins/src/builder/tests/NavSidebar.test.tsx | Tests navigation sidebar behavior (navigate/add/rename/delete/collapse/reorder). |
| packages/dm-core-plugins/src/builder/tests/Navbar.test.tsx | Tests navbar editing/preview behavior and accessibility attributes. |
| packages/dm-core-plugins/src/builder/tests/mathUtils.test.ts | Unit tests for numeric utilities. |
| packages/dm-core-plugins/src/builder/tests/markdownTable.test.ts | Unit tests for markdown-table conversion logic. |
| packages/dm-core-plugins/src/builder/tests/Inspector.test.tsx | Tests inspector event routing for title/scope/config/layout edits. |
| packages/dm-core-plugins/src/builder/tests/history.test.ts | Unit tests for undo/redo history model and coalescing behavior. |
| packages/dm-core-plugins/src/builder/tests/gridMetrics.test.ts | Unit tests for pixel-to-cell delta conversion. |
| packages/dm-core-plugins/src/builder/styles/directory.styles.ts | Adds styling for the site directory page and cards. |
| packages/dm-core-plugins/src/builder/static/staticWidgets.tsx | Implements multiple self-contained runtime widgets (heading/button/divider/spacer/embed/metric). |
| packages/dm-core-plugins/src/builder/static/staticWidgets.styles.ts | Styling for the static runtime widgets bundle. |
| packages/dm-core-plugins/src/builder/static/StaticTablePlugin.tsx | Implements inline-config, paginated static table widget runtime. |
| packages/dm-core-plugins/src/builder/static/StaticTablePlugin.styles.ts | Styling for the static table widget runtime. |
| packages/dm-core-plugins/src/builder/static/StaticChartPlugin.styles.ts | Styling scaffold for the static chart widget runtime. |
| packages/dm-core-plugins/src/builder/static/LiveTablePlugin.tsx | Implements DMSS-bound, viewer-editable live table runtime plugin. |
| packages/dm-core-plugins/src/builder/static/LiveTablePlugin.styles.ts | Styling for the live table runtime plugin. |
| packages/dm-core-plugins/src/builder/model/templates.ts | Defines starter page templates and lookup helper. |
| packages/dm-core-plugins/src/builder/model/history.ts | Adds undo/redo history model + useHistory hook. |
| packages/dm-core-plugins/src/builder/model/blocks.ts | Re-exports palette blocks from the widget registry for compatibility. |
| packages/dm-core-plugins/src/builder/index.ts | Adds builder public entrypoint exporting plugin + persistence/types + directory plugin. |
| packages/dm-core-plugins/src/builder/hooks/usePersistence.ts | Implements site hydration, autosave, manual save, and unload guard. |
| packages/dm-core-plugins/src/builder/hooks/useEditorShortcuts.ts | Adds keyboard shortcuts for edit-mode interactions (undo/redo/copy/paste/etc.). |
| packages/dm-core-plugins/src/builder/components/WidgetPalette.tsx | Widget palette UI with dnd-kit draggable cards grouped by category. |
| packages/dm-core-plugins/src/builder/components/WidgetPalette.styles.ts | Dragging state styling for widget palette cards. |
| packages/dm-core-plugins/src/builder/components/Toast.tsx | Snackbar wrapper for transient builder notifications. |
| packages/dm-core-plugins/src/builder/components/TemplatesMenu.tsx | Templates menu UI for applying starter layouts. |
| packages/dm-core-plugins/src/builder/components/TableUploadField.tsx | Empty placeholder file (currently no implementation). |
| packages/dm-core-plugins/src/builder/components/TableSourceField.tsx | Inspector field supporting CSV/Excel upload or markdown-table authoring. |
| packages/dm-core-plugins/src/builder/components/TableSourceField.styles.ts | Styling for the table source field editor controls. |
| packages/dm-core-plugins/src/builder/components/SiteShellView.tsx | Shared chrome-free site shell renderer for preview/read-only modes. |
| packages/dm-core-plugins/src/builder/components/SiteGrid.tsx | Read-only site grid renderer that renders inline-config widgets directly (avoids DMSS resolution). |
| packages/dm-core-plugins/src/builder/components/SiteCard.tsx | Site directory tile UI with open/edit/delete actions. |
| packages/dm-core-plugins/src/builder/components/Outline.tsx | Outline panel listing widgets and allowing container drill-in. |
| packages/dm-core-plugins/src/builder/components/NavSidebar.tsx | Nested page navigation sidebar with edit-mode affordances and DnD reordering. |
| packages/dm-core-plugins/src/builder/components/NavSidebar.styles.ts | Styling for nested depth indentation and action buttons. |
| packages/dm-core-plugins/src/builder/components/Navbar.styles.ts | Styling helpers for navbar editing vs preview. |
| packages/dm-core-plugins/src/builder/components/ImageUploadField.tsx | Inspector field uploading an image blob and creating a File entity, storing its address in widget config. |
| packages/dm-core-plugins/src/builder/components/ImageUploadField.styles.ts | Styling for image upload field controls. |
| packages/dm-core-plugins/src/builder/components/Canvas.styles.ts | Styling for builder canvas items and alignment previews. |
| packages/dm-core-plugins/src/builder/components/BuilderToolbar.tsx | Builder toolbar (save state, templates, undo/redo, device widths, density controls, mode toggle). |
| packages/dm-core-plugins/src/builder/components/BuilderToolbar.styles.ts | Styling for the builder toolbar UI. |
| packages/dm-core-plugins/package.json | Adds xlsx dependency and defines package export entrypoints for root/builder/grid. |
| packages/dm-core-plugins/jestSetup.js | Adds JSDOM dialog polyfills for EDS Dialog usage in tests. |
| packages/dm-core-plugins/blueprints/grid/GridItemStyle.json | Adds blueprint for per-item style metadata (but currently missing verticalAlign). |
| packages/dm-core-plugins/blueprints/grid/GridItem.json | Extends GridItem blueprint to include optional style and titleStyle. |
| packages/dm-core-plugins/blueprints/builder/SiteDirectoryConfig.json | Adds blueprint for site directory plugin config. |
| packages/dm-core-plugins/blueprints/builder/Site.json | Adds builder Site blueprint (navbar + pages + schemaVersion + published flag). |
| packages/dm-core-plugins/blueprints/builder/Page.json | Adds builder Page blueprint (id/title/layout + nested children). |
| packages/dm-core-plugins/blueprints/builder/package.json | Adds builder blueprints package metadata. |
| packages/dm-core-plugins/blueprints/builder/NavbarItem.json | Adds blueprint for navbar item nodes. |
| packages/dm-core-plugins/blueprints/builder/Navbar.json | Adds blueprint for navbar config (enabled/brand/colors/items/etc.). |
| packages/dm-core-plugins/blueprints/builder/BuilderPluginConfig.json | Adds blueprint for builder plugin config (mode/readOnly/editorRoles/etc.). |
| example/src/ViewPage.tsx | Allows selecting a named recipe via ?recipe= query param when rendering entities. |
| example/reset-app.sh | Seeds demo websites into the Sites data source via raw add endpoint. |
| example/app/demo_sites/teamHandbook.json | Demo site seed data exercising builder site schema. |
| example/app/demo_sites/acmeMarketing.json | Demo site seed data exercising builder site schema. |
| example/app/data/DemoDataSource/recipes/plugins/builder/sites/website.recipe.json | Adds View/Edit UI recipes for website entities using builder plugin. |
| example/app/data/DemoDataSource/recipes/plugins/builder/sites/package.json | Package metadata for site recipes. |
| example/app/data/DemoDataSource/recipes/plugins/builder/sites/directory.recipe.json | Recipe for site directory gallery plugin entity. |
| example/app/data/DemoDataSource/recipes/plugins/builder/example/page.recipe.json | Example builder page recipe seed config for demoing the editor. |
| example/app/data/DemoDataSource/recipes/plugins/builder/example/package.json | Package metadata for builder example recipes. |
| example/app/data/DemoDataSource/plugins/builder/sites/siteDirectory.entity.json | Adds site directory landing entity for the demo app. |
| example/app/data/DemoDataSource/plugins/builder/sites/blueprints/Website.blueprint.json | Demo Website blueprint extending builder Site. |
| example/app/data/DemoDataSource/plugins/builder/sites/blueprints/SiteDirectory.blueprint.json | Demo blueprint for the directory landing entity. |
| example/app/data/DemoDataSource/plugins/builder/example/pageExample.entity.json | Example page entity used by the builder demo route/test. |
| example/app/data/DemoDataSource/plugins/builder/example/blueprints/Page.blueprint.json | Demo page blueprint used by the builder example entity. |
| example/app/data/DemoDataSource/plugins/builder/example/blueprints/Member.blueprint.json | Demo Member blueprint used by the builder example entity. |
| example/app/data_source_templates/Sites.json | Adds Sites datasource template for local demo environment. |
| example/app/data_source_templates_radix_demo/Sites.json | Adds Sites datasource template for Radix demo environment. |
| e2e/tests/plugin-builder-website.spec.ts | Adds Playwright smoke tests covering builder mount and edit/preview switching. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Extract navigateTo() from SiteDirectoryPlugin so tests can spy on it without fighting jsdom's non-configurable window.location - Update delete dialog button queries from 'Yes, delete'/'No' to match actual rendered labels 'Delete'/'Cancel' Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…verride' step After submitting the maximumWaveHeight edit, clicking the 'waveForm' tree node was showing the stale form (value 10.1 from step 2) instead of the updated value (88888). The WaveForm plugin is already mounted and does not re-fetch when the same tree node is re-selected in the explorer. Step 2 avoids this by calling navigate() (full page reload) after submit, which guarantees that DMSS data is fetched fresh. Apply the same pattern to step 4 so the assertions always see the just-saved values. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The strict-mode violation occurs because two success toasts (from steps 3
and 4) are both visible simultaneously when step 4 checks that no error
occurred. getByRole('alert') then resolves to 2 elements and Playwright's
strict mode throws.
The intent of the assertion is 'the save did not error', so scope it to
.Toastify__toast--error instead of any alert role. Multiple success toasts
can coexist without triggering the check.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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 does this pull request change?
Why is this pull request needed?
Issues related to this change