Usage
Grant Permission Service Banner displays a permission request for a Shopware Service, with a primary action to grant the permissions and a secondary link to more information. It is intended for internal Shopware Services only.
import { MtGrantPermissionServiceBanner } from "@shopware-ag/meteor-component-library";
<template>
<mt-grant-permission-service-banner
@grant-success="onGranted"
@grant-error="onGrantFailed"
/>
</template>
API reference
Events
| Event | Payload |
|---|---|
grant-success | [] |
grant-error | [error: unknown] |
more-info | [] |
Behavior
- The banner manages its own visibility through the
useServicePermissioncomposable: it renders only while permissions still need to be granted and hides itself after a successful grant. - Clicking the primary action runs the grant flow and emits
grant-successon success orgrant-errorwith the error on failure. - The more-info action opens the Shopware Services documentation in a new tab and emits
more-info. - Title, description, and action labels are built in and localized (English and German); they cannot be overridden.
- The layout adapts to the width of its container, switching from a stacked to a horizontal arrangement as space allows.
Related
- useServicePermission: the composable the banner uses, for building custom permission UI instead.
- Banner: for general inline notices that are not tied to service permissions.