style: removendo código desnecessário

This commit is contained in:
Ana Carolina Duarte Cavalcante 2022-11-23 07:45:25 -03:00
parent 94f3dedaec
commit c220698f84
9 changed files with 76 additions and 82 deletions

View File

@ -1,13 +1,13 @@
# EditorConfig is awesome: https://EditorConfig.org
# top-most EditorConfig file
# root = true
root = true
# [*]
# indent_style = space
# indent_size = 4
# end_of_line = lf
# charset = utf-8
# trim_trailing_whitespace = true
# insert_final_newline = true
# max_line_length = 100
[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
max_line_length = 100

View File

@ -1,3 +0,0 @@
<svg width="26" height="58" viewBox="0 0 26 58" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M4.25454e-06 28.8415L25.3707 58L26 53.3516L5.34947 28.8415L26 4.64845L25.3707 -3.2965e-08L4.25454e-06 28.8415Z" fill="#858585"/>
</svg>

Before

Width:  |  Height:  |  Size: 241 B

View File

@ -1,3 +0,0 @@
<svg width="27" height="59" viewBox="0 0 27 59" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M26.6445 29.631L1.27388 0.472534L0.64453 5.12098L21.295 29.631L0.644519 53.8241L1.27387 58.4725L26.6445 29.631Z" fill="#858585"/>
</svg>

Before

Width:  |  Height:  |  Size: 242 B

View File

@ -66,10 +66,10 @@ export class Form {
addItemToList(event) {
event.preventDefault();
const itemImage = this.imagePreview[0].children[0].src;
const itemImage = this.imagePreview[0].children[0].src;
const itemTitle = event.target["titleInput"].value;
const itemDescription = event.target["descriptionText"].value;
if (itemTitle !== "" && itemDescription !== "" && itemImage !== "") {
const item = {
src: itemImage,
@ -88,7 +88,7 @@ export class Form {
}
this.resetInputs();
}
}
renderListItems() {
@ -97,20 +97,24 @@ export class Form {
this.list.forEach(function (item) {
itemsSlider += `
<li class="slider-content" data-test="container-item-list">
<figure><img src="${item.src}" alt="" data-test="image-item-list"/></figure>
<h3 data-test="title-item-list">${item.title}</h3>
<figcaption data-test="description-item-list">${item.description}</figcaption>
<figure>
<img src="${item.src}" alt="" data-test="image-item-list"/>
<h3 data-test="title-item-list">${item.title}</h3>
<figcaption data-test="description-item-list">
${item.description}
</figcaption>
</figure>
</li>
`;
});
this.slider.innerHTML = itemsSlider;
}
addSlick () {
addSlick () {
$(".slider-list").slick({
infinite: true,
slidesToShow: 4,
slidesToScroll: 1,
slidesToScroll: 4,
variableWidth: true,
arrows: true,
dots: true,

View File

@ -6,21 +6,18 @@
margin: 40px auto;
}
$breakpoint-desk: 2500px;
@media (min-width: $breakpoint-desk) {
.container {
width: 89.533%;
}
}
$breakpoint-tablet: 1024px;
@media (max-width: $breakpoint-tablet) {
.container {
width: 96.87%;
}
}
$breakpoint-mobile: 375px;
@media (max-width: $breakpoint-mobile) {
.container {
width: 91.441%;

View File

@ -55,14 +55,15 @@ form {
z-index: 1;
opacity: 0;
}
& img {
object-fit: cover;
width: 100%;
height: 100%;
transition: opacity 0.25s ease-in-out;
opacity: 1;
&[src=""] {
opacity: 0;
& label {
& span {
& img {
object-fit: cover;
width: 100%;
height: 100%;
left: 0;
top: 0;
}
}
}
}
@ -111,7 +112,6 @@ form {
position: absolute;
}
$breakpoint-desk: 2500px;
@media (min-width: $breakpoint-desk) {
h1 {
font-size: 64px;
@ -174,7 +174,6 @@ $breakpoint-desk: 2500px;
}
}
$breakpoint-tablet: 1024px;
@media (max-width: $breakpoint-tablet) {
form {
width: 100%;
@ -223,7 +222,6 @@ $breakpoint-tablet: 1024px;
}
}
$breakpoint-mobile: 375px;
@media (max-width: $breakpoint-mobile) {
form {
height: 500.3px;

View File

@ -48,7 +48,7 @@ h2 {
}
}
& figcaption {
padding: 0 24px 0 24px;
margin: 0 24px 0 24px;
font-weight: 400;
font-size: 16px;
line-height: 24px;
@ -67,23 +67,32 @@ h2 {
}
}
.slick-prev,
.slick-next {
cursor: pointer;
}
.slick-prev {
background: url("svgs/right arrow.svg") no-repeat center center !important;
border: none;
left: -40.36px;
&:before {
content: url("svgs/right arrow.svg");
}
font-size: 0;
background-size: 13.64px 29.47px;
width: 13.64px;
height: 29.47px;
}
.slick-next {
background: url("svgs/left arrow.svg") no-repeat center center !important;
border: none;
font-size: 0;
background-size: 13.64px 29.47px;
right: -40.36px;
&:before {
content: url("svgs/left arrow.svg");
}
width: 13.64px;
height: 29.47px;
}
.slick-prev:before, .slick-next:before {
font-size: 0;
opacity: unset;
}
.slick-dots li {
@ -118,7 +127,6 @@ h2 {
opacity: unset;
}
$breakpoint-desk: 2500px;
@media (min-width: $breakpoint-desk) {
h2 {
font-size: 64px;
@ -155,18 +163,19 @@ $breakpoint-desk: 2500px;
.slick-prev {
left: -70px;
&:before {
content: url("svgs/left arrow big.svg");
}
width: 26px;
height: 58px;
background-size: 26px 58px !important;
}
.slick-next {
right: -70px;
&:before {
content: url("svgs/right arrow big.svg");
}
width: 26px;
height: 58px;
background-size: 26px 58px !important;
}
.slick-dots li button:before {
font-size: 20.01px;
}
@ -177,7 +186,6 @@ $breakpoint-desk: 2500px;
}
}
$breakpoint-tablet: 1024px;
@media (max-width: $breakpoint-tablet) {
.slider-container {
margin-top: 60px;
@ -213,7 +221,7 @@ $breakpoint-tablet: 1024px;
color: $title-item-list-color;
}
& figcaption {
padding: 0 24px 24px 24px;
margin: 0 24px 24px 24px;
&::-webkit-scrollbar {
display: none;
}
@ -226,33 +234,13 @@ $breakpoint-tablet: 1024px;
.slick-dots li button {
display: none;
}
.slick-track {
max-width: 100%;
margin-top: 0;
display: flex;
flex-direction: column;
transform: translate3d(0, 0, 0) !important;
}
.slick-list {
max-width: 100%;
width: 100%;
}
.slick-prev {
left: 0;
&:before {
display: none;
}
}
.slick-next {
right: 0;
&:before {
display: none;
}
}
}
$breakpoint-mobile: 375px;
@media (max-width: $breakpoint-mobile) {
.slider-container {
margin-top: 40.7px;
@ -269,7 +257,7 @@ $breakpoint-mobile: 375px;
color: $title-item-list-color;
}
& figcaption {
padding: 0 24px 24px 24px;
margin: 0 24px 24px 24px;
&::-webkit-scrollbar {
display: none;
}

View File

@ -13,3 +13,16 @@ $title-item-list-color: #333333;
$description-item-list-color: #858585;
$slider-ellipse-color: #858585;
$slider-content-shadow-color: #00000014;
// Breakpoint
$breakpoint-desk: 2500px;
$breakpoint-medium-desk: "@media (max-width: 2499) and (min-width: 1440px)";
$breakpoint-tablet: 1024px;
$breakpoint-mobile: 490px;
//tablet 1024px até 491px
// mobile 490px ate 280px
// desk 1025px até 2499px
// desk 4k > 2500px

View File

@ -18,12 +18,12 @@
<main>
<section class="container">
<h1 data-test="title-form">Adicionar um Ponto Turístico</h1>
<form class="form" runat="server">
<form class="form">
<div class="form-container">
<div class="form-inputs">
<div class="input-image-container" data-test="input-image">
<label for="filearea"><span class="image"></span></label>
<input type="file" accept="image/*" class="input-image-content" name="filearea" id="inputImage" />
<input type="file" accept="image/*" class="input-image-content" name="filearea" id="inputImage" />
</div>
<div class="form-input-descricao">
<input id="titleInput" type="text" placeholder="Título" data-test="input-titulo" class="input-titulo" name="item-title"/>
@ -38,7 +38,7 @@
<div class="slider-container">
<h2 data-test="title-list">Pontos Turísticos</h2>
<div class="slider">
<ul class="slider-list" id="slider-content">
<ul class="slider-list" id="slider-content">
</ul>
</div>
</div>