2020-01-09 22:11:00 +00:00
|
|
|
import mustache from 'mustache';
|
|
|
|
import navTemplate from '!!raw-loader!../includes/templates/Navigation.mustache';
|
|
|
|
import '../.storybook/common.less';
|
|
|
|
import '../resources/skins.vector.styles/navigation.less';
|
|
|
|
|
|
|
|
import { loggedOut, loggedInWithEcho } from './personalNavigation.stories';
|
|
|
|
import { viewTabs, namespaceTabs } from './tabs.stories';
|
|
|
|
import { more, variants } from './menu.stories';
|
|
|
|
import { simpleSearch } from './searchBox.stories';
|
2020-02-14 20:33:54 +00:00
|
|
|
import { sidebarWithPortals } from './sidebar.stories';
|
2020-01-09 22:11:00 +00:00
|
|
|
|
|
|
|
export default {
|
2020-02-14 20:33:54 +00:00
|
|
|
title: 'Navigation (Header + Sidebar)'
|
2020-01-09 22:11:00 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
export const navigationLoggedOutWithVariants = () => mustache.render( navTemplate,
|
|
|
|
{
|
|
|
|
'html-personalmenu': loggedOut(),
|
|
|
|
'html-navigation-left-tabs': namespaceTabs() + variants(),
|
|
|
|
'html-navigation-right-tabs': `${viewTabs()} ${simpleSearch()}`,
|
2020-02-14 20:33:54 +00:00
|
|
|
'html-sidebar': sidebarWithPortals(),
|
2020-01-09 22:11:00 +00:00
|
|
|
'html-navigation-heading': 'Navigation menu',
|
|
|
|
'html-logo-attributes': `class="mw-wiki-logo" href="/wiki/Main_Page" title="Visit the main page"`
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
export const navigationLoggedInWithMore = () => mustache.render( navTemplate,
|
|
|
|
{
|
|
|
|
'html-personalmenu': loggedInWithEcho(),
|
|
|
|
'html-navigation-left-tabs': namespaceTabs(),
|
|
|
|
'html-navigation-right-tabs': `${viewTabs()} ${more()} ${simpleSearch()}`,
|
2020-02-14 20:33:54 +00:00
|
|
|
'html-sidebar': sidebarWithPortals(),
|
2020-01-09 22:11:00 +00:00
|
|
|
'html-navigation-heading': 'Navigation menu',
|
|
|
|
'html-logo-attributes': `class="mw-wiki-logo" href="/wiki/Main_Page" title="Visit the main page"`
|
|
|
|
}
|
|
|
|
);
|