diff --git a/packages/web-components/src/components/masthead/__stories__/links.ts b/packages/web-components/src/components/masthead/__stories__/links.ts index 0543637e395..d0724e98c7b 100644 --- a/packages/web-components/src/components/masthead/__stories__/links.ts +++ b/packages/web-components/src/components/masthead/__stories__/links.ts @@ -472,6 +472,22 @@ const mastheadL1Data: MastheadL1 = { }, }; +const mastheadL1EmptyMenuItemsData: MastheadL1 = { + title: 'IBM Data Virtualization', + url: 'https://www.ibm.com/products/watson\u002Dquery', + actions: { + login: { + title: 'Try it free', + url: 'https://dataplatform.cloud.ibm.com/registration/stepone?context=cpdaas\x26uucid=04fff6e19e3bf9ae\x26utm_content=CPDWW', + }, + cta: { + title: 'Book a meeting', + url: 'https://www.ibm.com/products/watson\u002Dquery?schedulerform=', + }, + }, + menuItems: [], +}; + const mastheadL0Data: L0MenuItem[] = [ { title: 'Faceted Megamenu', @@ -2194,4 +2210,9 @@ const mastheadL0Data: L0MenuItem[] = [ /* eslint-enable max-len */ -export { mastheadLogoData, mastheadL1Data, mastheadL0Data }; +export { + mastheadLogoData, + mastheadL1Data, + mastheadL1EmptyMenuItemsData, + mastheadL0Data, +}; diff --git a/packages/web-components/src/components/masthead/__stories__/masthead.stories.ts b/packages/web-components/src/components/masthead/__stories__/masthead.stories.ts index c74ef5947ef..6d614d1eb3d 100644 --- a/packages/web-components/src/components/masthead/__stories__/masthead.stories.ts +++ b/packages/web-components/src/components/masthead/__stories__/masthead.stories.ts @@ -17,7 +17,12 @@ import '../masthead-container'; import { L1_CTA_TYPES } from '../defs'; import styles from './masthead.stories.scss'; import { ifDefined } from 'lit/directives/if-defined.js'; -import { mastheadL0Data, mastheadL1Data, mastheadLogoData } from './links'; +import { + mastheadL0Data, + mastheadL1Data, + mastheadL1EmptyMenuItemsData, + mastheadLogoData, +} from './links'; import { UNAUTHENTICATED_STATUS, MASTHEAD_AUTH_METHOD, @@ -323,8 +328,13 @@ withPlatform.story = { }; export const withL1 = (args) => { - const { selectedMenuItem, selectedMenuItemL1, l1CtaType, useMock } = - args?.MastheadComposite ?? {}; + const { + selectedMenuItem, + selectedMenuItemL1, + l1CtaType, + useMock, + useL1EmptyData, + } = args?.MastheadComposite ?? {}; let l1Data = { ...mastheadL1Data }; if (l1Data?.actions?.cta) { @@ -347,7 +357,7 @@ export const withL1 = (args) => { .unauthenticatedProfileItems="${ifNonEmpty( unauthenticatedProfileItems )}" - .l1Data="${l1Data}" + .l1Data="${useL1EmptyData ? mastheadL1EmptyMenuItemsData : l1Data}" selected-menu-item="${ifNonEmpty(selectedMenuItem)}" selected-menu-item-l1="${ifNonEmpty( selectedMenuItemL1 @@ -356,7 +366,7 @@ export const withL1 = (args) => { : html`