-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #75 from unb-mds/bidding-list
Bidding list
- Loading branch information
Showing
18 changed files
with
337,768 additions
and
26 deletions.
There are no files selected for viewing
337,363 changes: 337,363 additions & 0 deletions
337,363
backend/data_collection/database/data_copy.json
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,62 @@ | ||
.cardWrapper { | ||
background-color: var(--texto); | ||
width: 450px; | ||
color: var(--brancoTexto); | ||
background-color: var(--cinza); | ||
gap: 16px; | ||
color: var(--branco); | ||
padding: 32px; | ||
text-align: center; | ||
transition: 100ms ease-in-out; | ||
box-shadow: -4px 4px 4px rgba(0, 0, 0, .25); | ||
|
||
flex: 1; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: space-between; | ||
} | ||
|
||
.cardTitle { | ||
text-transform: uppercase; | ||
font-size: 24px; | ||
} | ||
|
||
.cardSection { | ||
display: flex; | ||
align-items: center; | ||
justify-content: space-between; | ||
padding-bottom: 16px; | ||
margin-bottom: 16px; | ||
border-bottom: 1px solid var(--branco); | ||
} | ||
|
||
.licitacoesInfo { | ||
width: 100%; | ||
} | ||
|
||
.cardDescricao { | ||
overflow: hidden; | ||
text-overflow: ellipsis; | ||
display: -webkit-box; | ||
line-height: 1.4em; | ||
max-height: 7em; | ||
height: 7em; | ||
-webkit-line-clamp: 5; | ||
-webkit-box-orient: vertical; | ||
text-align: justify; | ||
} | ||
|
||
.cardButton { | ||
color: var(--texto); | ||
background-color: var(--branco); | ||
padding: 4px 72px; | ||
text-decoration: none; | ||
} | ||
|
||
.cardStatus{ | ||
width: 100%; | ||
display: flex; | ||
justify-content: space-between; | ||
flex-direction: row; | ||
} | ||
.cardStatusText{ | ||
font-weight: bold; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
import React from 'react'; | ||
import styles from './style.module.css'; | ||
|
||
export default function Filter() { | ||
return ( | ||
<section className={styles.filterSection}> | ||
<h2 className={styles.title}>Resultados obtidos de:</h2> | ||
<h3 className={styles.subtitle}>"Palavras-chave de busca"</h3> | ||
<span className={styles.description}>14 resultados obtidos</span> | ||
<h3 className={styles.sectionTitle}>Modalidade de compra</h3> | ||
<ul> | ||
<li className={styles.listItemStyle}> | ||
<input type='checkbox' name='licit1' /> | ||
<label htmlFor="licit1">Tipo de licitação</label> | ||
</li> | ||
<li className={styles.listItemStyle}> | ||
<input type='checkbox' name='licit1' /> | ||
<label htmlFor="licit1">Tipo de licitação</label> | ||
</li> | ||
<li className={styles.listItemStyle}> | ||
<input type='checkbox' name='licit1' /> | ||
<label htmlFor="licit1">Tipo de licitação</label> | ||
</li> | ||
</ul> | ||
<h3 className={styles.sectionTitle}>Órgão</h3> | ||
<ul> | ||
<li className={styles.listItemStyle}> | ||
<input type='checkbox' name='org1' /> | ||
<label htmlFor="org1">Órgão</label> | ||
</li> | ||
<li className={styles.listItemStyle}> | ||
<input type='checkbox' name='org1' /> | ||
<label htmlFor="org1">Órgão</label> | ||
</li> | ||
<li className={styles.listItemStyle}> | ||
<input type='checkbox' name='org1' /> | ||
<label htmlFor="org1">Órgão</label> | ||
</li> | ||
</ul> | ||
<h3 className={styles.sectionTitle}>Status</h3> | ||
<h3 className={styles.sectionTitle}>Preço</h3> | ||
<input type="range" /> | ||
<h3 className={styles.sectionTitle}>Período</h3> | ||
</section> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
.filterSection { | ||
width: 346px; | ||
background-color: var(--brancoTexto); | ||
border-radius: 16px; | ||
flex: 1; | ||
padding: 32px 16px; | ||
} | ||
|
||
.title{ | ||
font-weight: bold; | ||
font-size: 32px; | ||
} | ||
|
||
.subtitle{ | ||
font-size: 28px; | ||
font-weight: normal; | ||
} | ||
|
||
.description{ | ||
font-size: 18px; | ||
} | ||
|
||
.sectionTitle{ | ||
font-size: 24px; | ||
font-weight: bold; | ||
} | ||
|
||
.listItemStyle { | ||
list-style-type: none; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
import React, { useEffect, useState } from 'react' | ||
import Header from '../../components/header' | ||
import Filter from './filter' | ||
import CardLicitacoes from '../../components/card-licitacoes'; | ||
import search from '../../../assets/SearchDark.svg'; | ||
import styles from './style.module.css' | ||
import { getLicitacoes, pagLicitacoes } from '../../services/licitacoes.service'; | ||
|
||
|
||
export default function BiddingList() { | ||
|
||
const licitacoes = getLicitacoes(); | ||
const [listaLicitacoes, setListaLicitacoes] = useState([]); | ||
const [lengthBids, setLengthBids] = useState(10) | ||
|
||
|
||
const loadMoreBids = () => { | ||
(licitacoes.length - lengthBids < 10) ? setLengthBids(prevLength => prevLength += licitacoes.length - lengthBids) : setLengthBids(prevLength => prevLength += 10) | ||
} | ||
|
||
useEffect(() => { | ||
setListaLicitacoes(pagLicitacoes(licitacoes, lengthBids, 0)); | ||
}, [lengthBids]) | ||
return ( | ||
<> | ||
<Header /> | ||
<section className={styles.mainSection}> | ||
<div className={styles.campoPesquisaWrapper} > | ||
<div className={styles.campoPesquisa}> | ||
<img src={search} className={styles.searchIcon} alt="" /> | ||
<input type="text" placeholder='Busque por uma licitação' className={styles.inputStyle} /> | ||
</div> | ||
<div> | ||
<div> | ||
<a href="" className={styles.botaoBuscar}>Buscar</a> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<div className={styles.licitacoesSection}> | ||
<Filter /> | ||
<div className={styles.cardsWrapper}> | ||
{listaLicitacoes.map(item => { | ||
return ( | ||
<CardLicitacoes key={item["N�mero Processo"]} data={item}/> | ||
); | ||
})} | ||
|
||
{lengthBids >= licitacoes.length ? <></> : | ||
<button className={styles.botaoCarregarMais} type='button' onClick={loadMoreBids}>Carregar Mais</button> | ||
} | ||
</div> | ||
</div> | ||
</section> | ||
</> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
.campoPesquisaWrapper { | ||
display: flex; | ||
align-items: center; | ||
justify-content: space-between; | ||
width: 100%; | ||
gap: 80px; | ||
margin-bottom: 40px; | ||
} | ||
|
||
.campoPesquisa { | ||
display: flex; | ||
flex-direction: row; | ||
align-items: center; | ||
border-bottom: 3px solid var(--texto); | ||
padding-bottom: 12px; | ||
flex: 1; | ||
gap: 24px; | ||
} | ||
|
||
.searchIcon { | ||
width: 30px; | ||
} | ||
|
||
.inputStyle { | ||
background-color: var(--background); | ||
color: (--texto); | ||
font-style: 'IBM Plex Sans'; | ||
font-weight: 400; | ||
font-size: 23px; | ||
border: none; | ||
outline: none; | ||
width: 100%; | ||
} | ||
|
||
.inputStyle:focus { | ||
border: none; | ||
outline: none; | ||
} | ||
|
||
.botaoBuscar { | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
background-color: var(--texto); | ||
text-decoration: none; | ||
color: var(--brancoTexto); | ||
font-family: 'IBM Plex Sans', sans-serif; | ||
text-transform: uppercase; | ||
font-weight: 600; | ||
width: 222px; | ||
height: 32px; | ||
} | ||
|
||
.mainSection { | ||
display: flex; | ||
flex-direction: column; | ||
margin: 40px 128px; | ||
} | ||
|
||
.licitacoesSection { | ||
display: flex; | ||
gap: 32px; | ||
} | ||
|
||
.cardsWrapper { | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
gap: 40px; | ||
flex: 1; | ||
} | ||
|
||
.botaoCarregarMais { | ||
height: 2rem; | ||
width: 70%; | ||
background-color: var(--cinza); | ||
color: var(--brancoTexto); | ||
border: 0rem; | ||
font-family: 'IBM Plex Sans', sans-serif; | ||
box-shadow: -4px 4px 4px rgba(0, 0, 0, .25); | ||
font-size: 1rem; | ||
|
||
} |
Oops, something went wrong.