Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
bobcat-su_full
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Sergey
bobcat-su_full
Commits
8d27fa05
Commit
8d27fa05
authored
Dec 03, 2018
by
Sergey
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add filte slider
parent
4637de2c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
154 additions
and
3 deletions
+154
-3
filter-slider.js
src/js/filter-slider.js
+19
-0
catalog-filter-main.scss
src/scss/catalog-filter/catalog-filter-main.scss
+87
-0
index.html
src/template/catalog-filter/index.html
+48
-3
No files found.
src/js/filter-slider.js
0 → 100644
View file @
8d27fa05
'use strict'
;
(
function
()
{
var
listFilter
=
document
.
querySelectorAll
(
'.filter__slider'
);
if
(
listFilter
)
{
listFilter
.
forEach
(
function
(
itemSlider
)
{
var
bodySlider
=
itemSlider
.
querySelector
(
'.filter__slider-body'
);
noUiSlider
.
create
(
bodySlider
,
{
start
:
[
10
,
30
],
connect
:
true
,
range
:
{
'min'
:
-
20
,
'max'
:
40
}
})
});
}
})();
\ No newline at end of file
src/scss/catalog-filter/catalog-filter-main.scss
0 → 100644
View file @
8d27fa05
@import
"../settings/color"
;
.filter
{
background
:
$about-bg
;
}
.filter__wrapper
{
}
.filter__list
{
display
:
flex
;
list-style-type
:
none
;
padding-left
:
0
;
flex-wrap
:
wrap
;
align-items
:
flex-start
;
margin
:
0
;
}
.filter__item
{
width
:
25%
;
padding
:
20px
0
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
}
.filter__slider
{
width
:
100%
;
padding
:
0
30px
;
position
:
relative
;
&
:after
{
content
:
""
;
display
:
inline-block
;
width
:
1px
;
height
:
100%
;
background
:
$white-text
;
position
:
absolute
;
top
:
50%
;
right
:
0
;
transform
:
translateY
(
-50%
);
}
}
.filter__slider-title
{
text-align
:
center
;
padding-bottom
:
20px
;
}
.filter-slider__main-head
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
flex-start
;
padding-top
:
10px
;
}
.filter-slider__input
{
input
{
width
:
70px
;
border-radius
:
50px
;
border
:
none
;
}
p
{
margin
:
0
;
text-align
:
center
;
font-size
:
12px
;
color
:
rgba
(
$grey-text
,
.5
);
}
}
.filter__slider-body
{
border-radius
:
50px
;
.noUi-connect
{
background
:
$red-color
;
}
.noUi-handle
{
width
:
16px
;
height
:
16px
;
border-radius
:
50%
;
border
:
2px
solid
$red-color
;
top
:
0
;
right
:
-8px
!
important
;
&
:after
,
&
:before
{
display
:
none
;
}
}
}
\ No newline at end of file
src/template/catalog-filter/index.html
View file @
8d27fa05
<div
class=
"filter"
>
<div
class=
"filter"
>
<div
class=
"wrapper filter__wrapper"
>
<div
class=
"wrapper filter__wrapper"
>
<ul
class=
"filter__list"
>
<ul
class=
"filter__list"
>
<li
class=
"filter__item"
></li>
<li
class=
"filter__item"
>
<li
class=
"filter__item"
></li>
<div
class=
"filter__slider"
>
<li
class=
"filter__item"
></li>
<div
class=
"filter__slider-title"
>
Грузоподъемность, кг
</div>
<div
class=
"filter__slider-body"
></div>
<div
class=
"filter-slider__main-head"
>
<div
class=
"filter-slider__input"
>
<input
type=
"text"
class=
"filter__slider-min"
>
<p>
min 10
</p>
</div>
<div
class=
"filter-slider__input"
>
<input
type=
"text"
class=
"filter__slider-max"
>
<p>
max 100
</p>
</div>
</div>
</div>
</li>
<li
class=
"filter__item"
>
<div
class=
"filter__slider"
>
<div
class=
"filter__slider-title"
>
Грузоподъемность, кг
</div>
<div
class=
"filter__slider-body"
></div>
<div
class=
"filter-slider__main-head"
>
<div
class=
"filter-slider__input"
>
<input
type=
"text"
class=
"filter__slider-min"
>
<p>
min 10
</p>
</div>
<div
class=
"filter-slider__input"
>
<input
type=
"text"
class=
"filter__slider-max"
>
<p>
max 100
</p>
</div>
</div>
</div>
</li>
<li
class=
"filter__item"
>
<div
class=
"filter__slider"
>
<div
class=
"filter__slider-title"
>
Грузоподъемность, кг
</div>
<div
class=
"filter__slider-body"
></div>
<div
class=
"filter-slider__main-head"
>
<div
class=
"filter-slider__input"
>
<input
type=
"text"
class=
"filter__slider-min"
>
<p>
min 10
</p>
</div>
<div
class=
"filter-slider__input"
>
<input
type=
"text"
class=
"filter__slider-max"
>
<p>
max 100
</p>
</div>
</div>
</div>
</li>
<li
class=
"filter__item"
></li>
<li
class=
"filter__item"
></li>
</ul>
</ul>
</div>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment