MOBILE-3807 usermenu: Show on side main menu bar

main
Pau Ferrer Ocaña 2021-10-28 16:15:27 +02:00
parent ed19df5c8e
commit b9bf018966
5 changed files with 15 additions and 1 deletions

View File

@ -0,0 +1,3 @@
:host-context(ion-tabs.placement-side div.tabs-inner) {
display: none;
}

View File

@ -27,6 +27,7 @@ import { CoreMainMenuUserMenuComponent } from '../user-menu/user-menu';
@Component({
selector: 'core-user-menu-button',
templateUrl: 'user-menu-button.html',
styleUrls: ['user-menu-button.scss'],
})
export class CoreMainMenuUserButtonComponent implements OnInit {

View File

@ -22,6 +22,7 @@ import { MAIN_MENU_ROUTES } from './mainmenu-routing.module';
import { CoreMainMenuPage } from './pages/menu/menu';
import { CoreMainMenuHomeHandlerService } from './services/handlers/mainmenu';
import { CoreMainMenuProvider } from './services/mainmenu';
import { CoreMainMenuComponentsModule } from './components/components.module';
function buildRoutes(injector: Injector): Routes {
const routes = resolveModuleRoutes(injector, MAIN_MENU_ROUTES);
@ -54,6 +55,7 @@ function buildRoutes(injector: Injector): Routes {
@NgModule({
imports: [
CoreSharedModule,
CoreMainMenuComponentsModule,
],
declarations: [
CoreMainMenuPage,

View File

@ -4,6 +4,8 @@
[@menuShowHideAnimation]="tabsPlacement == 'side' ? '' : (isMainScreen ? 'visible' : 'hidden')">
<ion-spinner *ngIf="!loaded" [attr.aria-label]="'core.loading' | translate"></ion-spinner>
<core-user-menu-button *ngIf="loaded && tabsPlacement == 'side'"></core-user-menu-button>
<ion-tab-button *ngFor="let tab of tabs" (keydown)="tabAction.keyDown($event)" (keyup)="tabAction.keyUp(tab.page, $event)"
[hidden]="!loaded && tab.hide" [tab]="tab.page" [disabled]="tab.hide" layout="label-hide" class="{{tab.class}}"
[selected]="tab.page === selectedTab" [tabindex]="selectedTab == tab.page ? 0 : -1" [attr.aria-controls]="tab.id">

View File

@ -71,7 +71,7 @@
@include padding(var(--ion-safe-area-top), 0px, var(--ion-safe-area-bottom), var(--ion-safe-area-left));
ion-tab-button {
ion-tab-button, core-user-menu-button {
width: 100%;
min-height: var(--menutabbar-size);
flex: 0;
@ -83,6 +83,12 @@
}
}
core-user-menu-button {
align-items: center;
display: flex;
justify-content: center;
}
.core-network-message {
--network-message-height: 16px;
position: absolute;