Skip to content

Commit

Permalink
fix: fixed the display bug switching pages and did some finalizations…
Browse files Browse the repository at this point in the history
… in styles
  • Loading branch information
danieljstri committed Dec 19, 2024
1 parent 23c7754 commit fc25dbb
Show file tree
Hide file tree
Showing 12 changed files with 149 additions and 59 deletions.
Binary file modified assets/loginImagem.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/login_antiga.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 6 additions & 3 deletions frontend/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const toggleSidebar = () => {
<style lang="scss">
:root {
--sidebar-width: 240px;
--sidebar-width-col: 32px;
--sidebar-width-col: 7%;
}
* {
Expand Down Expand Up @@ -64,14 +64,17 @@ button {
padding: 0.5rem 2rem 0.5rem 0.5rem;
@media (max-width: 1024px) {
padding-left: 6rem;
padding-left: 2rem;
}
}
}
.main {
flex: 1;
// margin-left: var(--sidebar-width-col);
margin-left: var(--sidebar-width-col);
}
.isSidebarExpanded + .with-sidebar{
margin-left: var(--sidebar-width);
}
@media (max-width: 1024px) {
.main {
Expand Down
3 changes: 1 addition & 2 deletions frontend/src/components/CardModel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export default {
<style scoped>
.card-model {
height: fit-content;
width: 33%;
width: 32%;
padding: 20px;
border-radius: 16px;
background: linear-gradient(135deg, #ffffff 0%, #f3f4f6 100%);
Expand Down Expand Up @@ -151,7 +151,6 @@ export default {
/* Estilos responsivos */
@media (max-width: 768px) {
.card-model {
display: block;
max-width: 767px;
width: 90%;
height: fit-content;
Expand Down
48 changes: 32 additions & 16 deletions frontend/src/components/SideBar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -76,17 +76,9 @@
<span class="material-icons">bar_chart</span>
<span class="text">SERVIÇOS</span>
</router-link>

<!-- div para o botão relacionado ao Lucro Geral
<router-link to="/economia" class="button" :class="{ active: selectedButton === 'economy-chart' }"
@click="setActiveButton('economy-chart')">
<span class="material-icons">bar_chart</span>
<span class="text">GRÁFICO DE ECONOMIA</span>
</router-link> -->
</div>

<div class="frameInferior">

<!--div para o botão de Configurações-->
<router-link to="/settings" class="button" :class="{ active: selectedButton === 'settings' }"
@click="setActiveButton('settings')">
Expand All @@ -95,8 +87,8 @@
</router-link>

<!--Condicional para o botão Sair-->
<button @click="setActiveButton('logout'); handlesignOut()"
v-if="isLoggedIn" class="button"
<button class="btnLogOut" @click="setActiveButton('logout'); handlesignOut()"
v-if="isLoggedIn"
:class="{ active: selectedButton === 'logout' }" >
<span class="material-icons">logout</span>
<span class="text">SAIR</span>
Expand Down Expand Up @@ -125,10 +117,9 @@ aside {
height: 100vh;
padding: 1rem;
transition: width 0.2s ease-in-out;
// position: fixed;
top: 0;
left: 0;
position: fixed;
z-index: 1;
/*Parametros globais para os botões da sidebar*/
.button .text {
Expand All @@ -150,7 +141,7 @@ aside {
display: flex;
align-items: center;
height: 45px;
padding: 0.2rem 0;
padding: 0.2rem 0.2rem;
text-decoration: none;
transition: all 0.2s ease-in-out;
Expand Down Expand Up @@ -181,7 +172,7 @@ aside {
justify-content: flex-start;
margin-bottom: 3rem;
margin-top: 0rem;
padding-left: 0.2rem;
button {
padding: 1.2vh 0 0 0;
}
Expand Down Expand Up @@ -219,7 +210,7 @@ aside {
position: relative;
align-items: center;
height: 40px;
padding: 0.2rem 0;
padding: 0.2rem 0.2rem;
text-decoration: none;
transition: all 0.2s ease-in-out;
Expand All @@ -242,6 +233,31 @@ aside {
}
}
.btnLogOut {
display: flex;
position: relative;
align-items: center;
height: 40px;
padding: 0.2rem 0.3rem;
text-decoration: none;
transition: all 0.2s ease-in-out;
.material-icons {
color: #CCDEE7;
margin-right: 1rem;
transition: margin 0.2s ease-in-out;
}
.text {
color: #CCDEE7;
font-size: 13px;
line-height: 15px;
opacity: 0;
transition: opacity 0.2s ease-in-out;
white-space: nowrap;
letter-spacing: 0.05em;
}
}
}
.button {
Expand Down
23 changes: 0 additions & 23 deletions frontend/src/components/home_page/EconomicChart.vue

This file was deleted.

3 changes: 2 additions & 1 deletion frontend/src/components/home_page/GeneralChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ ChartJS.register(Title, Tooltip, Legend, LineElement, PointElement, LinearScale,
border-radius: 16px;
background: linear-gradient(135deg, #ffffff 0%, #f3f4f6 100%);
box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
}
h3 {
text-align: center;
Expand All @@ -140,7 +141,7 @@ ChartJS.register(Title, Tooltip, Legend, LineElement, PointElement, LinearScale,
#chart-canva {
width: 100%;
height: fit-content;
height: 100%;
padding: 20px;
}
Expand Down
77 changes: 77 additions & 0 deletions frontend/src/components/home_page/MedUpMerchan.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
<template>
<div
class="container"
ref="container"
@mousemove="updateMousePosition"
@mouseenter="showEffect"
@mouseleave="hideEffect"
>
<h1>Cuidamos de tudo para você. Gaste seu tempo no que importa: seus pacientes e sua carreira!</h1>
<div
v-if="isHovered"
class="distortion"
:style="{ transform: `translate(${mouseX - 25}px, ${mouseY - 30}px)` }"
></div>
</div>
</template>

<script>
export default {
name: "DistortionEffect",
data() {
return {
mouseX: 0,
mouseY: 0,
isHovered: false, // Controla a visibilidade do efeito
};
},
methods: {
updateMousePosition(event) {
const container = this.$refs.container;
const rect = container.getBoundingClientRect();
// Calcula as coordenadas relativas ao contêiner
this.mouseX = event.clientX - rect.left;
this.mouseY = event.clientY - rect.top;
},
showEffect() {
this.isHovered = true; // Exibe o efeito quando o mouse entra
},
hideEffect() {
this.isHovered = false; // Esconde o efeito quando o mouse sai
},
},
};
</script>

<style scoped>
.container {
display:flex;
align-items: center;
width: 100%;
height: 100%;
border-radius: 16px;
background:
linear-gradient(135deg,
rgba(71, 164, 206, 0.1) 0%,
rgba(71, 164, 206, 0) 100%);
overflow: hidden;
position: relative;
padding: 20px;
}
.distortion {
width: 50px;
height: 50px;
border-radius: 100%;
background: radial-gradient(circle, #000000 50%, #bdc8c1 100%);
position: absolute;
pointer-events: none;
filter: blur(2px) brightness(1.5);
mix-blend-mode: overlay;
top: 0;
left: 0;
z-index: 1;
}
</style>
2 changes: 1 addition & 1 deletion frontend/src/components/home_page/Valuable-ProductCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export default {
display: flex;
justify-content: center;
align-items: center;
height: 100%;
height: 30%;
padding: 20px;
border-radius: 16px;
background: linear-gradient(135deg, #ffffff 0%, #f3f4f6 100%);
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/views/EconomicsView.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script>
import EconomicChart from '@/components/home_page/EconomicChart.vue';
import EconomicChart from '@/components/home_page/MedUpMerchan.vue';
export default {
components: {
Expand Down
37 changes: 27 additions & 10 deletions frontend/src/views/HomeView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import ExpensesCard from '@/components/home_page/ExpensesCard.vue';
import RevenueCard from '@/components/home_page/RevenueCard.vue';
import ProfitChart from '@/components/home_page/GeneralChart.vue';
import EconomicChart from '@/components/home_page/EconomicChart.vue';
import MedUpMerchan from '@/components/home_page/MedUpMerchan.vue';
import ValuableProductCard from '@/components/home_page/Valuable-ProductCard.vue';
import EconomicBar from '@/components/home_page/EconomicBar.vue';
import TaxSavingsCard from '@/components/home_page/TaxSavingsCard.vue';
Expand Down Expand Up @@ -36,7 +36,7 @@
ExpensesCard,
RevenueCard,
ProfitChart,
EconomicChart,
MedUpMerchan,
ValuableProductCard,
EconomicBar,
TaxSavingsCard
Expand Down Expand Up @@ -96,7 +96,7 @@
<ProfitChart :selectedMonth="selectedMonth" id="general-chart"/>
</section>
<section class="control-data">
<EconomicChart :selectedMonth="selectedMonth" id="economic-chart"/>
<MedUpMerchan id="MerchanMedUp"/>
<ValuableProductCard :selectedMonth="selectedMonth"/>
</section>
<TaxSavingsCard/>
Expand All @@ -112,10 +112,8 @@
}
body {
background-size: cover;
background-position: center;
background-repeat: no-repeat;
main {
flex: 1;
}
.header {
display: flex;
Expand Down Expand Up @@ -163,20 +161,26 @@
height: 70%;
}
.cards {
display: flex;
display: inline-flex;
flex-direction: row;
gap: 16px;
flex-wrap: wrap;
min-width: 100%;
width: 100%;
margin-bottom: 16px;
gap: 16px;
justify-content: space-between;
}
.control-data {
margin: 0;
margin: 0;
display: flex;
flex-direction: column;
width: 18.5%;
gap: 16px;
}
#MerchanMedUp {
height: 100%;
}
.date-selectors {
display: flex;
Expand All @@ -194,4 +198,17 @@
color: #245368;
}
@media (max-width: 1024px) {
.cash-data {
width: 100%;
}
.cards {
justify-content: center;
}
.control-data {
width: 100%;
}
}
</style>
4 changes: 2 additions & 2 deletions frontend/src/views/ServicosView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import servicesDetails from '@/components/services_page/servicesDetails.vue';
<div class="content-container">
<servicesDetails id="services-component"/>
<section class="strategic-headlight">
<div class="cards">
<div class="cards-services">
<strategicAnesthesiaCard />
<strategicConsultationCard />
<strategicAnesthesiaCard />
Expand Down Expand Up @@ -79,7 +79,7 @@ import servicesDetails from '@/components/services_page/servicesDetails.vue';
background: linear-gradient(180deg, rgba(71, 164, 206, 0.01) 0%, rgba(71, 164, 206, 0.05) 10%, rgba(132, 122, 164, 0.05) 44%, rgba(233, 51, 95, 0.05) 100%);
}
.cards {
.cards-services {
display: flex;
flex-direction: column;
justify-content: space-between;
Expand Down

0 comments on commit fc25dbb

Please sign in to comment.