Skip to content

feat(landing): reuse standard shared file cards - #1531

Open
yevheniia0831 wants to merge 189 commits into
mainfrom
fileitem
Open

yevheniia0831 wants to merge 189 commits into
mainfrom
fileitem

Conversation

@yevheniia0831

@yevheniia0831 yevheniia0831 commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Related #1529.

Changes

  1. Move this PR to main. Include only Content: its box, heading, filters, view toggle, Show all, Show more, cards/list, states, styles and tests.
  2. Reuse standard Browse cards at 151x200px. Recent starts with six and expands directly to eighteen. Keep favorites, menus, lazy image thumbnails, existing list columns and site-change cleanup.
  3. Add a lazy landing=true entry through Browse. Normal Browse and global Home navigation stay unchanged. No greeting, chat/composer, branding, site picker or editor changes.

The destination override from #1616 is included for a working combined preview. Merge that shared PR first, then update this PR with main. Neither PR has been merged. List-only preview/details helpers stay with Content and reuse main's status APIs. Existing matching Spectrum tokens are reused. Fixed shared card/icon metrics and the custom panel surface/shadow stay unchanged.

Preview

Before: https://main--da-live--adobe.aem.live/drafts/mhaack/landing?nx=main&nxver=2

After: https://fileitem--da-live--adobe.aem.live/drafts/mhaack/landing?nx=main&nxver=2&landing=true#/exp-workspace/frescopaco

This preview is Content only. The full LP/chat page is not part of this main-targeting PR.

Testing

node_modules/.bin/wtr --config web-test-runner.config.js --node-resolve --port=2114 --files 'test/unit/blocks/landing/*.test.js' --files 'test/unit/blocks/browse/**/*.test.js' --files 'test/unit/blocks/shared/da-file-item/**/*.test.js'

Passed: 839 tests across 34 files. Includes normal Browse, editor selection/failure, stale requests, navigation parameters, favorites, list compatibility and image cleanup.

node_modules/.bin/eslint blocks/landing/*.js blocks/browse/browse.js blocks/shared/da-file-item/da-file-item.js test/unit/blocks/landing/*.test.js test/unit/blocks/browse/browse-entry.test.js test/fixtures/nx2/utils/ewFlags.js test/unit/blocks/shared/da-file-item/*.test.js
node_modules/.bin/stylelint blocks/landing/*.css
git diff --check origin/main...HEAD

All passed.

Local browser fixtures use deployed Nexter main components and icons. Passed light/dark, full/sidebar-width layouts, simulated S/M role values, 151x200 cards, 16px insets, 6-to-18 expansion, real view-toggle/list details, card menus, favorites, keyboard focus and site switching. No browser errors. Nexter main currently has no production M toggle; role-value fixtures do not prove one. Authenticated Playwright has not been run for this port.

Deployment check passed: all 45 changed production JS/CSS files match the published branch, including the main loader and Content dependencies.

GitHub CI passed: npm run lint, npm test (3,818 passed, four skipped, zero failures across 225 files) and npm run semantic-release-dry. Run: https://github.com/adobe/da-live/actions/runs/41461780407

mhaack and others added 30 commits September 21, 2026 09:13
Adds a Metadata view to the EW tool panel that reads/writes the page's
metadata block directly, driven by the site library's block-options
sheet (blocks=metadata rows) with a Title/Description fallback when
none is configured. Supports single/multi-select dropdowns, color
swatches, and always-on add/delete controls; creates the metadata
block on first write if the page doesn't have one yet.
…plify add dialog

- Read metadata rows directly from the ProseMirror doc (readMetadataRows)
  instead of re-parsing rendered aemHtml, so the panel stays correct
  regardless of what triggered the change and no longer depends on the
  real editor's table-wrapper plugins for serialization.
- Single-select dropdowns and color-swatch radios now include a leading
  empty option so an unset value doesn't appear to default to the first
  choice.
- The add-field dialog now only asks for a key; the row is added with an
  empty value and immediately editable in the panel.
… first

- Panel-selector label is now "Page" and the in-panel headline is "Page
  Metadata".
- Title and Description are now always the first two fields, regardless
  of library config, and stay plain text even if the config gives them
  values/type. If the config explicitly sets a label for a title/
  description row, that label is used instead of the default.
… copy, delete alignment

- Add canvasBus.editorDocState, emitted from the extensions-bridge plugin
  on every doc-changing transaction (not just the ones that trigger a
  full re-render). The metadata panel now subscribes to it directly, so
  plain in-place typing in the metadata table refreshes the panel, not
  just structural changes like adding a row.
- readMetadataRows now skips rows with a blank key, so an empty table
  row added directly in the doc doesn't show up as a field until it has
  a key.
- Title and Description are no longer deletable (no delete icon), since
  they're always-present fields.
- Dropdown/swatch-radio empty option now reads "Please Select".
- Delete button is pinned to the row's right edge via margin-left: auto,
  independent of how wide the field control renders.
Each field row is now label+delete on one line, field control full
width below it, instead of a cramped label/control/delete single row.
Label stays on its own line; the field control and its delete icon
share the row below it, delete icon flush right as before.
The token is defined globally in da-nx's shared stylesheet, always loaded
before this component renders — matches ew-page-outline.css and other
sibling components that reference it with no fallback.
Matches ew-canvas-versions' "new version" input style (rounded border,
gray-25 background) instead of an unstyled native input; drops the
now-redundant custom font-size override since da-input supplies it.
metadata-fields.js was reaching into ew-editor-doc/slash-menu/ just for
this pure string-matching helper. Moved it to editor-utils/color-code.js
so both the slash menu and the metadata panel depend on a real shared
utility instead of crossing feature-folder boundaries. Also fixes a
latent bug caught by the new direct unit test: isColorCode(undefined)
returned undefined instead of false.

Also sets nx-picker's size="m" on the metadata panel's dropdowns.
- Field rows now carry da-form-field alongside their own hook class, for
  the shared label typography/spacing (nx2/styles/form.css) instead of
  a hand-rolled duplicate.
- Multiselect checkboxes now load form.css and use da-checkbox instead
  of unstyled native checkboxes.
addMetadataRow and setMetadataValue now rebuild the table's row order
after every write, canonicalizing to Title, Description, then everything
else in its existing relative order — regardless of which field was
actually written, so a page with rows in the "wrong" order (or added
before Title/Description existed) self-corrects on the next edit.
"Are you sure you want to delete X?" -> "Are you sure you want to
remove X metadata from the page?"
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use a localhost-only JPEG mock when AEM Assets is unavailable for local testing. Keep authenticated image bytes in the host and relay drops to the preview image target.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Expand Recent cards in six-card increments and hide Show more at eighteen or the end of the listing. Keep list pagination and Favorite behavior unchanged.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Remove custom HTML thumbnails and retain Browse document icons and existing image previews. Keep card sizing, navigation and six-to-eighteen expansion unchanged.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Yevheniia Severinovska and others added 2 commits November 2, 2026 13:28
Move outer Content box presentation out of lp so the card integration PR owns its padding, surface, radius and shadow.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Merge the box-free lp base while preserving the Content panel in this integration. The cards PR now includes the panel presentation as an explicit addition without changing its rendered appearance.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Yevheniia Severinovska and others added 2 commits November 2, 2026 13:40
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Yevheniia Severinovska and others added 2 commits November 2, 2026 15:24
Keep the Content section independently reviewable without LP chat, site-picker, branding or editor changes. Preserve standard Browse cards and add only the opt-in loader.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace the inherited LP tree with the validated main-based Content-only port. Preserve this branch and PR history without shipping unrelated chat, site-picker, branding or editor changes.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

This branch was successfully deployed

1 active deployment
fileitem — 03d20990 Deployed Nov 2, 2026 by aem-code-sync[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants