Skip to content

Commit

Permalink
Removendo limitador do menu lateral e pequeno bugfix
Browse files Browse the repository at this point in the history
Problema do menu lateral => ionicthemes/ionic6-starter-app#13
  • Loading branch information
JMTheo committed Jun 6, 2021
1 parent 57f17f2 commit c679708
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 13 deletions.
10 changes: 5 additions & 5 deletions src/app/app.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<ion-menu contentId="main-content" type="overlay">
<ion-content>
<ion-list id="inbox-list">
<ion-list-header>Olá, User</ion-list-header>
<ion-note>[email protected]</ion-note>
<ion-list-header>Olá</ion-list-header>
<ion-note>Seja bem vindo</ion-note>

<ion-menu-toggle
auto-hide="false"
Expand All @@ -23,11 +23,11 @@
[md]="p.icon + '-sharp'"
></ion-icon>
<ion-label>{{ p.title }}</ion-label>
</ion-item>
</ion-item>
</ion-menu-toggle>
</ion-list>


</ion-content>
</ion-menu>
<ion-router-outlet id="main-content"></ion-router-outlet>
Expand Down
8 changes: 8 additions & 0 deletions src/app/interface/user.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
export interface User {
nome: string;
sobrenome: string;
email: string;
sexo: string;
dataDeNasc: Date;
salario: number;
}
2 changes: 1 addition & 1 deletion src/app/pages/configuracoes/configuracoes.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<ion-item lines="full">
<ion-label position="floating">Data de Nascimento</ion-label>
<ion-datetime [(ngModel)] ="dataDeNasc" name= "dataDeNasc"
displayFormat="MMMM YYYY"
displayFormat="DD MMMM YYYY"
min="1940-01"
max="2028-12"
value="2021-04-21T13:47:20.789"
Expand Down
6 changes: 4 additions & 2 deletions src/app/pages/configuracoes/configuracoes.page.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { Component, OnInit } from '@angular/core';
import { LocalStorageService } from '../../service/local-storage-service.service';
import { User } from '../../interface/user'

@Component({
selector: 'app-configuracoes',
Expand All @@ -20,12 +21,12 @@ export class ConfiguracoesPage implements OnInit {
//this.getTheValue()
this.storage = this.storageService;
}

ionViewDidEnter() {
this.getTheValue();
}
async setTheValue() {
let user = {
let user: User = {
nome: this.nome,
sobrenome: this.sobrenome,
email: this.email,
Expand All @@ -38,6 +39,7 @@ export class ConfiguracoesPage implements OnInit {

async getTheValue() {
let userData = await this.storage.get('user');
console.log(userData);
this.nome = userData.nome;
this.sobrenome = userData.sobrenome;
this.email = userData.email;
Expand Down
2 changes: 1 addition & 1 deletion src/app/pages/home/home.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { Component, OnInit, ElementRef, ViewChild } from '@angular/core';
import { Chart } from 'chart.js';
import { LocalStorageService } from '../../service/local-storage-service.service';
import { Lancamento } from '../../interface/lancamento';

@Component({
selector: 'app-home',
templateUrl: './home.page.html',
Expand Down Expand Up @@ -121,7 +122,6 @@ export class HomePage implements OnInit {
async retornaTodosLancamentos() {
let arr = await this.storage.retornaTodosLancamentos();
if(arr) {
console.log(arr)
this.listaLancamentos = arr;
this.listaLancamentosCard = arr.slice().sort((a: Lancamento, b: Lancamento) =>
new Date(b.diaCompra).getTime() - new Date(a.diaCompra).getTime())
Expand Down
6 changes: 2 additions & 4 deletions src/app/pages/inicial/inicial.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@ import { Component, OnInit } from '@angular/core';
styleUrls: ['./inicial.page.scss'],
})
export class InicialPage implements OnInit {
constructor() {}

constructor() { }

ngOnInit() {
}
ngOnInit() {}

}

0 comments on commit c679708

Please sign in to comment.