From dd80c8d9bb181a2355bcbd8ad7579d41cf72464a Mon Sep 17 00:00:00 2001 From: 230415 <230415@epvc.pt> Date: Thu, 30 Apr 2026 10:42:47 +0100 Subject: [PATCH] design --- .vscode/settings.json | 3 + .../example/lifegrid/TelaInicialActivity.java | 147 ++-- .../example/lifegrid/menu/HomeFragment.java | 139 +++- app/src/main/res/drawable/ic_home.xml | 10 + app/src/main/res/drawable/ic_nav_chart.xml | 13 + app/src/main/res/drawable/ic_nav_home.xml | 20 + app/src/main/res/drawable/ic_nav_settings.xml | 20 + app/src/main/res/drawable/ic_nav_target.xml | 21 + app/src/main/res/drawable/ic_nav_trending.xml | 13 + app/src/main/res/drawable/ic_nav_wallet.xml | 29 + .../main/res/drawable/linear_backgound.xml | 13 +- .../res/drawable/nav_item_selected_bg.xml | 6 + app/src/main/res/layout/activity_login.xml | 2 +- .../res/layout/activity_recupear_password.xml | 2 +- .../main/res/layout/activity_tela_inicial.xml | 636 ++++++------------ app/src/main/res/layout/fragment_ativos.xml | 39 +- app/src/main/res/layout/fragment_home.xml | 295 +++++++- app/src/main/res/layout/fragment_metas.xml | 16 +- .../main/res/layout/fragment_transacoes.xml | 27 +- 19 files changed, 851 insertions(+), 600 deletions(-) create mode 100644 .vscode/settings.json create mode 100644 app/src/main/res/drawable/ic_home.xml create mode 100644 app/src/main/res/drawable/ic_nav_chart.xml create mode 100644 app/src/main/res/drawable/ic_nav_home.xml create mode 100644 app/src/main/res/drawable/ic_nav_settings.xml create mode 100644 app/src/main/res/drawable/ic_nav_target.xml create mode 100644 app/src/main/res/drawable/ic_nav_trending.xml create mode 100644 app/src/main/res/drawable/ic_nav_wallet.xml create mode 100644 app/src/main/res/drawable/nav_item_selected_bg.xml diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..c5f3f6b --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "java.configuration.updateBuildConfiguration": "interactive" +} \ No newline at end of file diff --git a/app/src/main/java/com/example/lifegrid/TelaInicialActivity.java b/app/src/main/java/com/example/lifegrid/TelaInicialActivity.java index 9fed1a2..51f4f0b 100644 --- a/app/src/main/java/com/example/lifegrid/TelaInicialActivity.java +++ b/app/src/main/java/com/example/lifegrid/TelaInicialActivity.java @@ -19,6 +19,7 @@ import com.example.lifegrid.menu.AtivosFragment; import com.example.lifegrid.menu.DefinicoesFragment; import com.example.lifegrid.menu.DocumentosFragment; import com.example.lifegrid.menu.GraficosFragment; +import com.example.lifegrid.menu.HomeFragment; import com.example.lifegrid.menu.MetasFragment; import com.example.lifegrid.menu.TransacoesFragment; import com.example.lifegrid.models.Transacao; @@ -48,16 +49,7 @@ import java.util.Locale; */ public class TelaInicialActivity extends AppCompatActivity { - private TextView tvValor; - private TextView tvTransacoes; - private TextView tvValor2; - private TextView tvTransacoes2; - private TextView tvValor3; - private TextView tvTransacoes3; - private TextView tvValor4; - private TextView tvTransacoes4; - private TextView tvTitulo; - private TextView tvTitulo2; + private ImageView ivHeaderProfilePicture; private TextView tvHeaderUsername; @@ -78,16 +70,6 @@ public class TelaInicialActivity extends AppCompatActivity { return insets; }); - tvValor = findViewById(R.id.tvValor); - tvTransacoes = findViewById(R.id.tvTransacoes); - tvValor2 = findViewById(R.id.tvValor2); - tvTransacoes2 = findViewById(R.id.tvTransacoes2); - tvValor3 = findViewById(R.id.tvValor3); - tvTransacoes3 = findViewById(R.id.tvTransacoes3); - tvValor4 = findViewById(R.id.tvValor4); - tvTransacoes4 = findViewById(R.id.tvTransacoes4); - tvTitulo = findViewById(R.id.tvTitulo); - tvTitulo2 = findViewById(R.id.tvTitulo2); ivHeaderProfilePicture = findViewById(R.id.ivHeaderProfilePicture); tvHeaderUsername = findViewById(R.id.tvHeaderUsername); @@ -97,50 +79,64 @@ public class TelaInicialActivity extends AppCompatActivity { setupSpinners(); - Fragment transacoesFragment2 = new TransacoesFragment(); + Fragment homeFragment = new HomeFragment(); getSupportFragmentManager().beginTransaction() - .replace(R.id.fragmentContainerView, transacoesFragment2) + .replace(R.id.fragmentContainerView, homeFragment) .commit(); android.view.View.OnClickListener openTransacoesListener = v -> { + updateNavSelection(findViewById(R.id.carteiraImageView)); Fragment transacoesFragment = new TransacoesFragment(); getSupportFragmentManager().beginTransaction() .replace(R.id.fragmentContainerView, transacoesFragment) .commit(); - scrollToFragment(); + }; - findViewById(R.id.receitasCardView).setOnClickListener(openTransacoesListener); - findViewById(R.id.despesasCardView).setOnClickListener(openTransacoesListener); + android.view.View.OnClickListener openHomeListener = v -> { + updateNavSelection(findViewById(R.id.homeImageView)); + Fragment newHomeFragment = new HomeFragment(); + getSupportFragmentManager().beginTransaction() + .replace(R.id.fragmentContainerView, newHomeFragment) + .commit(); + + }; + + ImageView homeImageView = findViewById(R.id.homeImageView); + homeImageView.setOnClickListener(openHomeListener); ImageView carteiraImageView = findViewById(R.id.carteiraImageView); carteiraImageView.setOnClickListener(openTransacoesListener); ImageView setaImageView = findViewById(R.id.setaImageView); setaImageView.setOnClickListener(v -> { + updateNavSelection(setaImageView); Fragment ativosFragment = new AtivosFragment(); getSupportFragmentManager().beginTransaction() .replace(R.id.fragmentContainerView, ativosFragment) .commit(); - scrollToFragment(); + }); ImageView graficoImageView = findViewById(R.id.graficoImageView); graficoImageView.setOnClickListener(v -> { + updateNavSelection(graficoImageView); Fragment graficosFragment = new GraficosFragment(); getSupportFragmentManager().beginTransaction() .replace(R.id.fragmentContainerView, graficosFragment) .commit(); - scrollToFragment(); + }); ImageView alvoImageView = findViewById(R.id.alvoImageView); alvoImageView.setOnClickListener(v -> { + updateNavSelection(alvoImageView); Fragment metasFragment = new MetasFragment(); getSupportFragmentManager().beginTransaction() .replace(R.id.fragmentContainerView, metasFragment) .commit(); - scrollToFragment(); + }); ImageView definicoesImageView = findViewById(R.id.definicoesImageView); definicoesImageView.setOnClickListener(v -> { + updateNavSelection(definicoesImageView); Intent intent = new Intent(TelaInicialActivity.this, DefinicoesActivity.class); startActivity(intent); }); @@ -204,7 +200,7 @@ public class TelaInicialActivity extends AppCompatActivity { AdapterView.OnItemSelectedListener listener = new AdapterView.OnItemSelectedListener() { @Override public void onItemSelected(AdapterView parent, android.view.View view, int position, long id) { - carregarDados(); + atualizarDadosHome(); } @Override @@ -215,75 +211,28 @@ public class TelaInicialActivity extends AppCompatActivity { spinnerAno.setOnItemSelectedListener(listener); } - private void carregarDados() { - FirebaseUser user = FirebaseAuth.getInstance().getCurrentUser(); - if (user == null) return; - - int mesSelecionado = spinnerMes.getSelectedItemPosition() + 1; // 1 to 12 - String anoSelecionado = spinnerAno.getSelectedItem().toString(); - - String mesNome = meses[spinnerMes.getSelectedItemPosition()]; - tvTitulo.setText("Receitas (" + mesNome + " " + anoSelecionado + ")"); - tvTitulo2.setText("Despesas (" + mesNome + " " + anoSelecionado + ")"); - - DatabaseReference transacoesRef = FirebaseDatabase.getInstance().getReference() - .child("users").child(user.getUid()).child("transacoes"); - - transacoesRef.addValueEventListener(new ValueEventListener() { - @Override - public void onDataChange(@NonNull DataSnapshot snapshot) { - double totalReceitas = 0; - double totalDespesas = 0; - int countReceitas = 0; - int countDespesas = 0; - - for (DataSnapshot ds : snapshot.getChildren()) { - Transacao transacao = ds.getValue(Transacao.class); - if (transacao != null && transacao.getData() != null) { - String[] parts = transacao.getData().split("/"); - if (parts.length == 3) { - try { - int mesTransacao = Integer.parseInt(parts[1]); - String anoTransacao = parts[2]; - - if (mesTransacao == mesSelecionado && anoTransacao.equals(anoSelecionado)) { - double valor = Double.parseDouble(transacao.getValor().replace(",", ".")); - if ("Receita".equals(transacao.getTipo())) { - totalReceitas += valor; - countReceitas++; - } else if ("Despesa".equals(transacao.getTipo())) { - totalDespesas += valor; - countDespesas++; - } - } - } catch (NumberFormatException e) { - e.printStackTrace(); - } - } - } - } - - tvValor.setText(String.format(Locale.getDefault(), "%.2f€", totalReceitas)); - tvTransacoes.setText(countReceitas + " transações"); - - tvValor2.setText(String.format(Locale.getDefault(), "%.2f€", totalDespesas)); - tvTransacoes2.setText(countDespesas + " transações"); - - double saldo = totalReceitas - totalDespesas; - tvValor3.setText(String.format(Locale.getDefault(), "%.2f€", saldo)); - if (saldo >= 0) { - tvTransacoes3.setText("Poupança positiva"); - tvTransacoes3.setTextColor(android.graphics.Color.parseColor("#8E8E8E")); - } else { - tvTransacoes3.setText("Poupança negativa"); - tvTransacoes3.setTextColor(android.graphics.Color.parseColor("#FF0000")); - } - } - - @Override - public void onCancelled(@NonNull DatabaseError error) { - Toast.makeText(TelaInicialActivity.this, "Erro ao carregar dados", Toast.LENGTH_SHORT).show(); - } - }); + public void atualizarDadosHome() { + Fragment currentFragment = getSupportFragmentManager().findFragmentById(R.id.fragmentContainerView); + if (currentFragment instanceof HomeFragment) { + int mesSelecionado = spinnerMes.getSelectedItemPosition() + 1; // 1 to 12 + String anoSelecionado = spinnerAno.getSelectedItem().toString(); + String mesNome = meses[spinnerMes.getSelectedItemPosition()]; + ((HomeFragment) currentFragment).carregarDados(mesSelecionado, anoSelecionado, mesNome); + } } + + private void updateNavSelection(android.widget.ImageView selectedItem) { + int[] ids = {R.id.homeImageView, R.id.carteiraImageView, R.id.setaImageView, R.id.graficoImageView, R.id.alvoImageView, R.id.definicoesImageView}; + for (int id : ids) { + android.widget.ImageView iv = findViewById(id); + if (iv != null) { + if (iv == selectedItem) { + iv.setBackgroundResource(R.drawable.nav_item_selected_bg); + } else { + iv.setBackground(null); + } + } + } + } + } diff --git a/app/src/main/java/com/example/lifegrid/menu/HomeFragment.java b/app/src/main/java/com/example/lifegrid/menu/HomeFragment.java index b7b57e7..7db611c 100644 --- a/app/src/main/java/com/example/lifegrid/menu/HomeFragment.java +++ b/app/src/main/java/com/example/lifegrid/menu/HomeFragment.java @@ -3,31 +3,158 @@ package com.example.lifegrid.menu; import android.os.Bundle; import androidx.fragment.app.Fragment; +import androidx.annotation.NonNull; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; +import android.widget.TextView; +import android.widget.Toast; import com.example.lifegrid.R; +import com.example.lifegrid.models.Transacao; +import com.google.firebase.auth.FirebaseAuth; +import com.google.firebase.auth.FirebaseUser; +import com.google.firebase.database.DataSnapshot; +import com.google.firebase.database.DatabaseError; +import com.google.firebase.database.DatabaseReference; +import com.google.firebase.database.FirebaseDatabase; +import com.google.firebase.database.ValueEventListener; +import java.util.Locale; public class HomeFragment extends Fragment { + private TextView tvValor; + private TextView tvTransacoes; + private TextView tvValor2; + private TextView tvTransacoes2; + private TextView tvValor3; + private TextView tvTransacoes3; + private TextView tvValor4; + private TextView tvTransacoes4; + private TextView tvTitulo; + private TextView tvTitulo2; + public HomeFragment() { // Required empty public constructor } - @Override - public void onCreate(Bundle savedInstanceState) { - super.onCreate(savedInstanceState); - - } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { - // Inflate the layout for this fragment View root = inflater.inflate(R.layout.fragment_home, container, false); + tvValor = root.findViewById(R.id.tvValor); + tvTransacoes = root.findViewById(R.id.tvTransacoes); + tvValor2 = root.findViewById(R.id.tvValor2); + tvTransacoes2 = root.findViewById(R.id.tvTransacoes2); + tvValor3 = root.findViewById(R.id.tvValor3); + tvTransacoes3 = root.findViewById(R.id.tvTransacoes3); + tvValor4 = root.findViewById(R.id.tvValor4); + tvTransacoes4 = root.findViewById(R.id.tvTransacoes4); + tvTitulo = root.findViewById(R.id.tvTitulo); + tvTitulo2 = root.findViewById(R.id.tvTitulo2); + + // Se precisarmos que o fragmento carregue dados logo ao iniciar, + // a atividade vai chamar este método quando o fragmento estiver pronto. + + root.findViewById(R.id.receitasCardView).setOnClickListener(v -> { + Fragment transacoesFragment = new TransacoesFragment(); + requireActivity().getSupportFragmentManager().beginTransaction() + .replace(R.id.fragmentContainerView, transacoesFragment) + .commit(); + }); + + root.findViewById(R.id.despesasCardView).setOnClickListener(v -> { + Fragment transacoesFragment = new TransacoesFragment(); + requireActivity().getSupportFragmentManager().beginTransaction() + .replace(R.id.fragmentContainerView, transacoesFragment) + .commit(); + }); + return root; } + + @Override + public void onResume() { + super.onResume(); + if (getActivity() instanceof com.example.lifegrid.TelaInicialActivity) { + ((com.example.lifegrid.TelaInicialActivity) getActivity()).atualizarDadosHome(); + } + } + + public void carregarDados(int mesSelecionado, String anoSelecionado, String mesNome) { + if (tvTitulo == null) return; + + FirebaseUser user = FirebaseAuth.getInstance().getCurrentUser(); + if (user == null) return; + + tvTitulo.setText("Receitas (" + mesNome + " " + anoSelecionado + ")"); + tvTitulo2.setText("Despesas (" + mesNome + " " + anoSelecionado + ")"); + + DatabaseReference transacoesRef = FirebaseDatabase.getInstance().getReference() + .child("users").child(user.getUid()).child("transacoes"); + + transacoesRef.addValueEventListener(new ValueEventListener() { + @Override + public void onDataChange(@NonNull DataSnapshot snapshot) { + if (!isAdded()) return; + + double totalReceitas = 0; + double totalDespesas = 0; + int countReceitas = 0; + int countDespesas = 0; + + for (DataSnapshot ds : snapshot.getChildren()) { + Transacao transacao = ds.getValue(Transacao.class); + if (transacao != null && transacao.getData() != null) { + String[] parts = transacao.getData().split("/"); + if (parts.length == 3) { + try { + int mesTransacao = Integer.parseInt(parts[1]); + String anoTransacao = parts[2]; + + if (mesTransacao == mesSelecionado && anoTransacao.equals(anoSelecionado)) { + double valor = Double.parseDouble(transacao.getValor().replace(",", ".")); + if ("Receita".equals(transacao.getTipo())) { + totalReceitas += valor; + countReceitas++; + } else if ("Despesa".equals(transacao.getTipo())) { + totalDespesas += valor; + countDespesas++; + } + } + } catch (NumberFormatException e) { + e.printStackTrace(); + } + } + } + } + + tvValor.setText(String.format(Locale.getDefault(), "%.2f€", totalReceitas)); + tvTransacoes.setText(countReceitas + " transações"); + + tvValor2.setText(String.format(Locale.getDefault(), "%.2f€", totalDespesas)); + tvTransacoes2.setText(countDespesas + " transações"); + + double saldo = totalReceitas - totalDespesas; + tvValor3.setText(String.format(Locale.getDefault(), "%.2f€", saldo)); + if (saldo >= 0) { + tvTransacoes3.setText("Poupança positiva"); + tvTransacoes3.setTextColor(android.graphics.Color.parseColor("#8E8E8E")); + } else { + tvTransacoes3.setText("Poupança negativa"); + tvTransacoes3.setTextColor(android.graphics.Color.parseColor("#FF0000")); + } + } + + @Override + public void onCancelled(@NonNull DatabaseError error) { + if (isAdded()) { + Toast.makeText(getContext(), "Erro ao carregar dados", Toast.LENGTH_SHORT).show(); + } + } + }); + } } \ No newline at end of file diff --git a/app/src/main/res/drawable/ic_home.xml b/app/src/main/res/drawable/ic_home.xml new file mode 100644 index 0000000..39bbeaa --- /dev/null +++ b/app/src/main/res/drawable/ic_home.xml @@ -0,0 +1,10 @@ + + + diff --git a/app/src/main/res/drawable/ic_nav_chart.xml b/app/src/main/res/drawable/ic_nav_chart.xml new file mode 100644 index 0000000..2edeeac --- /dev/null +++ b/app/src/main/res/drawable/ic_nav_chart.xml @@ -0,0 +1,13 @@ + + + diff --git a/app/src/main/res/drawable/ic_nav_home.xml b/app/src/main/res/drawable/ic_nav_home.xml new file mode 100644 index 0000000..9130f0c --- /dev/null +++ b/app/src/main/res/drawable/ic_nav_home.xml @@ -0,0 +1,20 @@ + + + + diff --git a/app/src/main/res/drawable/ic_nav_settings.xml b/app/src/main/res/drawable/ic_nav_settings.xml new file mode 100644 index 0000000..d3ec23a --- /dev/null +++ b/app/src/main/res/drawable/ic_nav_settings.xml @@ -0,0 +1,20 @@ + + + + diff --git a/app/src/main/res/drawable/ic_nav_target.xml b/app/src/main/res/drawable/ic_nav_target.xml new file mode 100644 index 0000000..3f18e5e --- /dev/null +++ b/app/src/main/res/drawable/ic_nav_target.xml @@ -0,0 +1,21 @@ + + + + + diff --git a/app/src/main/res/drawable/ic_nav_trending.xml b/app/src/main/res/drawable/ic_nav_trending.xml new file mode 100644 index 0000000..5ebf246 --- /dev/null +++ b/app/src/main/res/drawable/ic_nav_trending.xml @@ -0,0 +1,13 @@ + + + diff --git a/app/src/main/res/drawable/ic_nav_wallet.xml b/app/src/main/res/drawable/ic_nav_wallet.xml new file mode 100644 index 0000000..7fb066f --- /dev/null +++ b/app/src/main/res/drawable/ic_nav_wallet.xml @@ -0,0 +1,29 @@ + + + + + + + diff --git a/app/src/main/res/drawable/linear_backgound.xml b/app/src/main/res/drawable/linear_backgound.xml index 4c64c86..d350ba2 100644 --- a/app/src/main/res/drawable/linear_backgound.xml +++ b/app/src/main/res/drawable/linear_backgound.xml @@ -1,9 +1,6 @@ - - - - - - - - \ No newline at end of file + + + + \ No newline at end of file diff --git a/app/src/main/res/drawable/nav_item_selected_bg.xml b/app/src/main/res/drawable/nav_item_selected_bg.xml new file mode 100644 index 0000000..0efda5f --- /dev/null +++ b/app/src/main/res/drawable/nav_item_selected_bg.xml @@ -0,0 +1,6 @@ + + + + + diff --git a/app/src/main/res/layout/activity_login.xml b/app/src/main/res/layout/activity_login.xml index 2944149..8360312 100644 --- a/app/src/main/res/layout/activity_login.xml +++ b/app/src/main/res/layout/activity_login.xml @@ -53,7 +53,7 @@ android:layout_height="50dp" android:layout_marginTop="28dp" android:backgroundTint="#050505" - android:text="Entrar ->" + android:text="Entrar" app:cornerRadius="10dp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" diff --git a/app/src/main/res/layout/activity_recupear_password.xml b/app/src/main/res/layout/activity_recupear_password.xml index d986d9a..f069133 100644 --- a/app/src/main/res/layout/activity_recupear_password.xml +++ b/app/src/main/res/layout/activity_recupear_password.xml @@ -14,7 +14,7 @@ android:layout_height="50dp" android:layout_marginTop="24dp" android:backgroundTint="#050505" - android:text="Entrar ->" + android:text="Enviar email" app:cornerRadius="10dp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" diff --git a/app/src/main/res/layout/activity_tela_inicial.xml b/app/src/main/res/layout/activity_tela_inicial.xml index ce3e736..69aa4b5 100644 --- a/app/src/main/res/layout/activity_tela_inicial.xml +++ b/app/src/main/res/layout/activity_tela_inicial.xml @@ -12,481 +12,221 @@ android:id="@+id/mainScrollView" android:layout_width="match_parent" android:layout_height="match_parent" - android:background="@color/cinza"> - - - - - - - - - - - - - - - - - + app:layout_constraintTop_toTopOf="parent"> - - - - + android:layout_marginHorizontal="24dp" + android:layout_marginTop="32dp" + android:gravity="center_vertical" + android:orientation="horizontal" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintTop_toTopOf="parent"> - + + + + + + android:layout_marginStart="16dp" + android:orientation="vertical"> - + + + + - - + - + - - - + + + + + + + + + + - - - - - - - - - - - - - + app:layout_constraintTop_toBottomOf="@+id/textView11"> - + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/app/src/main/res/layout/fragment_ativos.xml b/app/src/main/res/layout/fragment_ativos.xml index 42c5506..77cad1e 100644 --- a/app/src/main/res/layout/fragment_ativos.xml +++ b/app/src/main/res/layout/fragment_ativos.xml @@ -9,7 +9,7 @@ android:id="@+id/adicionarCardView" android:layout_width="376dp" android:layout_height="match_parent" - android:layout_marginTop="624dp" + android:layout_marginTop="604dp" android:background="@drawable/cardview_background" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.492" @@ -23,6 +23,7 @@ android:layout_marginTop="32dp" android:text="Ativos e Investimentos" android:textSize="25sp" + android:textStyle="bold" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.501" app:layout_constraintStart_toStartOf="parent" @@ -36,7 +37,7 @@ android:backgroundTint="@color/preto" android:text=" + Novo Ativo" android:textSize="15sp" - app:cornerRadius="14sp" + app:cornerRadius="10sp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.502" app:layout_constraintStart_toStartOf="parent" @@ -57,8 +58,8 @@ @@ -96,7 +99,9 @@ android:layout_marginStart="36dp" android:layout_marginBottom="36dp" android:text="0,00€" - android:textSize="18sp" + android:textColor="#000000" + android:textSize="23sp" + android:textStyle="bold" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintStart_toStartOf="parent" /> @@ -106,7 +111,7 @@ android:id="@+id/constraintLayout2" android:layout_width="379dp" android:layout_height="175dp" - android:layout_marginTop="24dp" + android:layout_marginTop="16dp" android:background="@drawable/cardview_background" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" @@ -119,7 +124,9 @@ android:layout_marginStart="36dp" android:layout_marginTop="36dp" android:text="Total Investido" - android:textSize="18sp" + android:textColor="#3A3A3A" + android:textSize="16sp" + android:textStyle="bold" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" /> @@ -130,7 +137,9 @@ android:layout_marginStart="36dp" android:layout_marginBottom="36dp" android:text="0,00€" - android:textSize="18sp" + android:textColor="#000000" + android:textSize="23sp" + android:textStyle="bold" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintStart_toStartOf="parent" /> @@ -140,7 +149,7 @@ android:id="@+id/constraintLayout3" android:layout_width="379dp" android:layout_height="175dp" - android:layout_marginTop="24dp" + android:layout_marginTop="16dp" android:background="@drawable/button_background" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" @@ -153,7 +162,9 @@ android:layout_marginStart="32dp" android:layout_marginTop="32dp" android:text="ROI Total" - android:textSize="18sp" + android:textColor="#3A3A3A" + android:textSize="16sp" + android:textStyle="bold" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" /> @@ -164,7 +175,9 @@ android:layout_marginStart="36dp" android:layout_marginBottom="36dp" android:text="0,00€" - android:textSize="18sp" + android:textColor="#000000" + android:textSize="23sp" + android:textStyle="bold" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintStart_toStartOf="parent" /> diff --git a/app/src/main/res/layout/fragment_home.xml b/app/src/main/res/layout/fragment_home.xml index e91be6d..327b26a 100644 --- a/app/src/main/res/layout/fragment_home.xml +++ b/app/src/main/res/layout/fragment_home.xml @@ -1,9 +1,296 @@ - - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_metas.xml b/app/src/main/res/layout/fragment_metas.xml index 466c643..30504dc 100644 --- a/app/src/main/res/layout/fragment_metas.xml +++ b/app/src/main/res/layout/fragment_metas.xml @@ -13,7 +13,7 @@ diff --git a/app/src/main/res/layout/fragment_transacoes.xml b/app/src/main/res/layout/fragment_transacoes.xml index 8a95e78..ebf57a6 100644 --- a/app/src/main/res/layout/fragment_transacoes.xml +++ b/app/src/main/res/layout/fragment_transacoes.xml @@ -3,7 +3,7 @@ xmlns:tools="http://schemas.android.com/tools" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" - android:layout_height="412dp" + android:layout_height="match_parent" tools:context=".menu.TransacoesFragment">