added style variables to reduce duplication
This commit is contained in:
parent
a0b1ed8d07
commit
71e1566f20
6 changed files with 30 additions and 7 deletions
|
|
@ -31,7 +31,12 @@
|
|||
],
|
||||
"styles": [
|
||||
"src/styles.scss"
|
||||
]
|
||||
],
|
||||
"stylePreprocessorOptions": {
|
||||
"includePaths": [
|
||||
"src/assets/styles"
|
||||
]
|
||||
}
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
@use "variables";
|
||||
|
||||
.expense-form-container {
|
||||
display: grid;
|
||||
|
||||
|
|
@ -6,14 +8,14 @@
|
|||
}
|
||||
}
|
||||
|
||||
@media (min-width: 550px) {
|
||||
@media (min-width: variables.$mid-screen) {
|
||||
.expense-form-container {
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 1rem;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 800px) {
|
||||
@media (min-width: variables.$wide-screen) {
|
||||
.expense-form-container {
|
||||
grid-template-columns: 1fr 1fr 1fr;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
@use "variables";
|
||||
|
||||
.expense-container {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
|
|
@ -5,7 +7,7 @@
|
|||
align-items: center;
|
||||
|
||||
mat-card {
|
||||
max-width: 800px;
|
||||
max-width: variables.$wide-screen;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
<div class="metadata-tab">
|
||||
<p>Categories</p>
|
||||
<div class="tab-text">Categories</div>
|
||||
<mat-icon class="example-tab-icon">ballot</mat-icon>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
|
@ -14,7 +14,7 @@
|
|||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
<div class="metadata-tab">
|
||||
<p>Merchants</p>
|
||||
<div class="tab-text">Merchants</div>
|
||||
<mat-icon class="example-tab-icon">shopping_cart</mat-icon>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
|
@ -25,7 +25,7 @@
|
|||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
<div class="metadata-tab">
|
||||
<p>Tags</p>
|
||||
<div class="tab-text">Tags</div>
|
||||
<mat-icon class="example-tab-icon">label</mat-icon>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
|
|
|||
|
|
@ -1,5 +1,17 @@
|
|||
@use "variables";
|
||||
|
||||
.metadata-tab {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.tab-text {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@media (min-width: variables.$mid-screen) {
|
||||
.tab-text {
|
||||
display: unset;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
2
src/assets/styles/variables.scss
Normal file
2
src/assets/styles/variables.scss
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
$mid-screen: 500px;
|
||||
$wide-screen: 800px;
|
||||
Loading…
Add table
Add a link
Reference in a new issue