Skip to content

fix: restore Shopware Services & extension dashboard slots - #7

Open
roboshyim wants to merge 3 commits into
FriendsOfShopware:mainfrom
roboshyim:fix/restore-dashboard-injection-points
Open

fix: restore Shopware Services & extension dashboard slots#7
roboshyim wants to merge 3 commits into
FriendsOfShopware:mainfrom
roboshyim:fix/restore-dashboard-injection-points

Conversation

@roboshyim

Copy link
Copy Markdown
Contributor

Summary

Replacing the core sw-dashboard-index page removed the injection points Shopware Services (and other extensions) use on the dashboard.

Core dashboard includes

From sw-dashboard-index.html.twig:

  • <sw-settings-services-dashboard-banner /> — Shopware Services promo/status banner
  • <sw-extension-component-section position-identifier="sw-dashboard__before-content" />
  • <sw-extension-component-section position-identifier="sw-dashboard__after-content" />

Fix

frosh-dashboard-index now renders those same components around the widget grid, using the same position identifiers so existing extensions keep working without changes.

[Services banner]
[sw-dashboard__before-content]
[frosh-dashboard-grid]
[sw-dashboard__after-content]

Test plan

  • Open admin dashboard with Shopware Services available — banner still shows (unless user dismissed via core.hide-services-dashboard-banner)
  • Extensions that target sw-dashboard__before-content / after-content still appear
  • Widget grid layout/edit mode unchanged

Replacing sw-dashboard-index dropped core injection points that Services
and other extensions rely on. Render the same hooks as core:

- sw-settings-services-dashboard-banner
- sw-extension-component-section sw-dashboard__before-content
- sw-extension-component-section sw-dashboard__after-content

around the modular widget grid.
@roboshyim

Copy link
Copy Markdown
Contributor Author

Browser review (dockware SW 6.7.2.2)

Installed this PR branch, rebuilt administration, verified dashboard.

DOM order under .frosh-dashboard-index__content:

  1. Shopware Services banner (.sw-settings-services-dashboard-banner__content)
  2. .frosh-dashboard-grid
  3. Extension section hosts only appear when something injects (empty = no gap)

Visual: Banner above the widget board with clean spacing; no overlap/cutoff; edit mode still fine. Looks good to merge from a UI perspective.

Screenshots:

@roboshyim

Copy link
Copy Markdown
Contributor Author

Browser review (dockware SW 6.7.2.2)

Installed this branch, rebuilt admin, logged in as admin.

Verified

  • Shopware Services banner renders above the widget grid (sw-settings-services-dashboard-banner)
  • DOM children order: banner → .frosh-dashboard-grid
  • Empty extension sections don't leave awkward gaps
  • Customize / edit mode still looks correct
  • No overlap, clipping, or broken layout

Screenshots

Dashboard top (Services banner + widgets):
services-banner-and-grid

Edit mode (banner remains above grid toolbar):
edit-mode-with-services

Looks good from a UI standpoint.

Add config.xml toggles (default on):
- showServicesBanner
- showExtensionSections

Dashboard page loads FroshAdminDashboard.config via systemConfigApiService
and v-if's the restored core injection points so merchants can opt out.
@roboshyim

Copy link
Copy Markdown
Contributor Author

Follow-up: plugin config to disable injections

Added under Settings → System → Plugins → Modular Admin Dashboard:

Key Default Purpose
showServicesBanner true Shopware Services banner
showExtensionSections true sw-dashboard__before-content / after-content

Defaults keep the restored core behaviour; turn off either switch for a board-only dashboard.

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.

1 participant