0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-21 09:22:50 +00:00

minor style changes & lint less file

This commit is contained in:
Víctor Losada Hernández
2024-06-13 01:04:39 +02:00
parent 1e080b30fd
commit cb0cb32860
2 changed files with 209 additions and 246 deletions

View File

@@ -265,18 +265,17 @@ const VaultPage = (props) => {
return (
<div className="paginationControls">
{page > 1 && (
<button
className="previousPage"
onClick={() => loadPage(page - 1, false)}
disabled={page === startPage}
>
&lt;&lt;
<i className="fa-solid fa-chevron-left"></i>
</button>
)}
<ol className="pages">
{startPage > 1 && (
<a
className="firstPage"
className="pageNumber firstPage"
onClick={() => loadPage(1, false)}
>
1 ...
@@ -285,21 +284,20 @@ const VaultPage = (props) => {
{pagesAroundCurrent}
{endPage < totalPages && (
<a
className="lastPage"
className="pageNumber lastPage"
onClick={() => loadPage(totalPages, false)}
>
... {totalPages}
</a>
)}
</ol>
{page < totalPages && (
<button
className="nextPage"
onClick={() => loadPage(page + 1, false)}
disabled={page === totalPages}
>
&gt;&gt;
<i className="fa-solid fa-chevron-right"></i>
</button>
)}
</div>
);
};

View File

@@ -1,41 +1,35 @@
body {
height : 100vh;
.content {
height: 100%;
}
.content { height : 100%; }
small {
font-size : 10pt;
color: #555;
color : #555555;
a {
color: #333;
}
a { color : #333333; }
}
code {
padding-inline : 5px;
background : lightgrey;
border-radius : 5px;
padding-inline: 5px
}
*:not(input) {
user-select: none;
}
*:not(input) { user-select : none; }
}
.vaultPage {
overflow-y: hidden;
height : 100%;
overflow-y : hidden;
background-color : #2C3E50;
h1,
h2,
h3 {
font-family : 'Open Sans';
color: white;
font-weight : 900;
color : white;
}
.content {
@@ -53,11 +47,11 @@ body {
padding : 50px;
.formTitle {
color: black;
font-size: 30px;
border-bottom: 2px solid;
margin : 20px 0;
font-size : 30px;
color : black;
text-align : center;
border-bottom : 2px solid;
}
.formContents {
@@ -65,47 +59,39 @@ body {
flex-direction : column;
}
label {
margin: 10px 0;
}
label { margin : 10px 0; }
input {
margin: 0 10px;
}
input { margin : 0 10px; }
#searchButton {
position : absolute;
right : 10px;
bottom : 20px;
i {
margin-left: 10px;
}
i { margin-left : 10px; }
}
}
&.resultsContainer {
display : flex;
flex-direction : column;
border-left: 2px solid;
height : 100%;
font-family: "BookInsanityRemake";
font-size: .34cm;
overflow-y : auto;
font-family : 'BookInsanityRemake';
font-size : 0.34cm;
border-left : 2px solid;
.foundBrews {
position : relative;
background-color: #2C3E50;
width : 100%;
max-height: 100%;
height : 100%;
max-height : 100%;
padding : 50px 50px 70px 50px;
overflow-y : scroll;
background-color : #2C3E50;
h3 {
font-size: 25px;
}
h3 { font-size : 25px; }
&.noBrews {
display : grid;
@@ -118,17 +104,15 @@ body {
place-items : center;
color : white;
h3 {
position: relative;
}
h3 { position : relative; }
h3.searchAnim::after {
content: "";
position : absolute;
top : 50%;
right : 0;
width : max-content;
height : 1em;
position: absolute;
right: 0;
top: 50%;
content : '';
translate : 100% -50%;
animation : trailingDots 2s ease infinite;
}
@@ -136,15 +120,15 @@ body {
.totalBrews {
position : fixed;
bottom: 0;
right : 17px;
bottom : 0;
z-index : 1000;
padding : 8px 10px;
font-family : 'Open Sans';
font-size : 11px;
font-weight : 800;
color : white;
background-color: #333;
padding: 8px 10px;
z-index: 1000;
font-family: 'Open Sans';
background-color : #333333;
.searchAnim {
position : relative;
@@ -154,37 +138,35 @@ body {
}
.searchAnim::after {
content: "";
position : absolute;
top : 50%;
right : 0;
width : max-content;
height : 1em;
position: absolute;
right: 0;
top: 50%;
content : '';
translate : -50% -50%;
animation : trailingDots 2s ease infinite;
}
}
.brewItem {
background-image: url('/assets/parchmentBackground.jpg');
width : 48%;
margin-right : 40px;
color : black;
background-image : url('/assets/parchmentBackground.jpg');
&:nth-child(even of .brewItem) {
margin-right: 0;
}
&:nth-child(even of .brewItem) { margin-right : 0; }
h2 {
font-family : 'MrEavesRemake';
font-size : 0.75cm;
line-height: 0.988em;
font-family: "MrEavesRemake";
font-weight : 800;
line-height : 0.988em;
color : var(--HB_Color_HeaderText);
}
.info {
font-family: ScalySansRemake;
font-family : "ScalySansRemake";
font-size : 1.2em;
>span {
@@ -197,28 +179,28 @@ body {
.paginationControls {
position : absolute;
left : 50%;
translate: -50%;
width: auto;
display : grid;
place-items: center;
grid-template-areas: "previousPage currentPage nextPage";
grid-template-areas : 'previousPage currentPage nextPage';
grid-template-columns : 50px 1fr 50px;
place-items : center;
width : auto;
translate : -50%;
.pages {
grid-area: currentPage;
height: 100%;
width: 100%;
display : flex;
grid-area : currentPage;
justify-content : space-evenly;
text-align: center;
width : 100%;
height : 100%;
padding : 5px 8px;
text-align : center;
.pageNumber {
color: white;
font-family: Open Sans;
font-weight: 900;
text-underline-position: under;
margin-inline : 10px;
font-family : "Open Sans";
font-weight : 900;
color : white;
text-underline-position : under;
cursor : pointer;
&.currentPage {
@@ -227,34 +209,23 @@ body {
pointer-events : none;
}
&.firstPage {
margin-right: -5px;
}
&.firstPage { margin-right : -5px; }
&.lastPage {
margin-left: -5px;
}
&.lastPage { margin-left : -5px; }
}
}
button {
width : max-content;
border-radius: 5px;
&.previousPage {
grid-area: previousPage;
}
&.previousPage { grid-area : previousPage; }
&.nextPage {
grid-area: nextPage;
}
&.nextPage { grid-area : nextPage; }
}
}
hr {
visibility: hidden;
}
hr { visibility : hidden; }
}
}
}
@@ -264,17 +235,11 @@ body {
@keyframes trailingDots {
0%,
32% {
content: '.';
}
32% { content : '.'; }
33%,
65% {
content: '..';
}
65% { content : '..'; }
66%,
100% {
content: '...';
}
100% { content : '...'; }
}