mirror of
https://github.com/FJurmanovic/wallet-web.git
synced 2026-11-11 07:41:09 +00:00
added responsivenes to sidebar and layout
This commit is contained in:
@@ -105,6 +105,11 @@ class AppMenuElement extends BaseComponentElement {
|
||||
}
|
||||
return html`<menu-item data-path="${path}">${title}</menu-item>`;
|
||||
};
|
||||
const menuButton = (title: string, action?: string): TemplateResult => {
|
||||
return html` <div class="menu-item --retract" data-target="menu-item.itemEl">
|
||||
<button class="btn btn-link" data-target="app-link.main" app-action="${action}">${title}</button>
|
||||
</div>`;
|
||||
};
|
||||
const authMenu = (path: string, title: string, action?: string): TemplateResult => {
|
||||
if (isAuth) {
|
||||
return regularMenu(path, title, action);
|
||||
@@ -133,7 +138,8 @@ class AppMenuElement extends BaseComponentElement {
|
||||
${authMenu('/subscriptions', 'Subscriptions', 'click:app-menu#modalSubscription')}
|
||||
${authMenu('/wallet/all', 'My Wallets', 'click:app-menu#modalWallet')} ${renderWallets(walletData)}
|
||||
<span class="menu-item divider"></span>
|
||||
${authMenu('/logout', 'Logout')} ${notAuthMenu('/login', 'Login')} ${notAuthMenu('/register', 'Register')}
|
||||
${authMenu('/logout', 'Logout')} ${notAuthMenu('/login', 'Login')}
|
||||
${notAuthMenu('/register', 'Register')}${menuButton('Retract', 'click:menu-layout#retractMenu')}
|
||||
</div>
|
||||
`;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user