Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
I
i20rzslider
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
jedife
i20rzslider
Commits
78d2b2ed
Commit
78d2b2ed
authored
Oct 22, 2016
by
Valentin Hervieu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update with new examples for 5.8 release
parent
01026c94
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
3 deletions
+48
-3
demo.js
demo.js
+22
-2
index.html
index.html
+11
-1
slider_dates.js
snippets/slider_dates.js
+15
-0
No files found.
demo.js
View file @
78d2b2ed
...
...
@@ -419,6 +419,22 @@ app.controller('MainCtrl', function ($scope, $rootScope, $timeout, $modal) {
}
};
var
dates
=
[];
for
(
var
i
=
1
;
i
<=
31
;
i
++
)
{
dates
.
push
(
new
Date
(
2016
,
7
,
i
));
}
$scope
.
slider_dates
=
{
value
:
new
Date
(
2016
,
7
,
10
),
options
:
{
stepsArray
:
dates
,
translate
:
function
(
date
)
{
if
(
date
!=
null
)
return
date
.
toDateString
();
return
''
;
}
}
};
//Slider with draggable range
$scope
.
slider_draggable_range
=
{
minValue
:
1
,
...
...
@@ -513,11 +529,15 @@ app.controller('MainCtrl', function ($scope, $rootScope, $timeout, $modal) {
//Disabled slider
$scope
.
disabled_slider
=
{
value
:
50
,
minValue
:
20
,
maxValue
:
80
,
options
:
{
floor
:
0
,
ceil
:
100
,
disabled
:
true
step
:
10
,
disabled
:
true
,
showTicks
:
true
,
// just to show the disabled style
draggableRange
:
true
// just to show the disabled style
}
};
...
...
index.html
View file @
78d2b2ed
...
...
@@ -360,6 +360,15 @@
</tabset>
</article>
<article>
<h2>
Slider with Date values
</h2>
<rzslider
rz-slider-model=
"slider_dates.value"
rz-slider-options=
"slider_dates.options"
></rzslider>
<show-code
js-file=
"slider_dates"
html-file=
"singleSlider"
></show-code>
</article>
<article>
<h2>
Slider with draggable range
</h2>
<rzslider
...
...
@@ -415,7 +424,8 @@
<h2>
Disabled slider
</h2>
<label>
Disabled
<input
type=
"checkbox"
ng-model=
"disabled_slider.options.disabled"
></label>
<rzslider
rz-slider-model=
"disabled_slider.value"
rz-slider-model=
"disabled_slider.minValue"
rz-slider-high=
"disabled_slider.maxValue"
rz-slider-options=
"disabled_slider.options"
></rzslider>
<show-code
js-file=
"disabled_slider"
html-file=
"disabled_slider"
></show-code>
...
...
snippets/slider_dates.js
0 → 100644
View file @
78d2b2ed
var
dates
=
[];
for
(
var
i
=
1
;
i
<=
31
;
i
++
)
{
dates
.
push
(
new
Date
(
2016
,
7
,
i
));
}
$scope
.
slider
=
{
value
:
dates
[
0
],
// or new Date(2016, 7, 10) is you want to use different instances
options
:
{
stepsArray
:
dates
,
translate
:
function
(
date
)
{
if
(
date
!=
null
)
return
date
.
toDateString
();
return
''
;
}
}
};
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