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
a238bd47
Commit
a238bd47
authored
Feb 29, 2016
by
Valentin Hervieu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update demo site
parent
66430654
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
74 additions
and
3 deletions
+74
-3
demo.js
demo.js
+29
-1
index.html
index.html
+21
-2
color_slider_pointer.js
snippets/color_slider_pointer.js
+15
-0
slider_rtl.js
snippets/slider_rtl.js
+9
-0
No files found.
demo.js
View file @
a238bd47
...
@@ -95,6 +95,22 @@ app.controller('MainCtrl', function($scope, $rootScope, $timeout, $modal) {
...
@@ -95,6 +95,22 @@ app.controller('MainCtrl', function($scope, $rootScope, $timeout, $modal) {
}
}
};
};
//Slider with selection bar
$scope
.
color_slider_pointer
=
{
value
:
12
,
options
:
{
getPointerColor
:
function
(
value
)
{
if
(
value
<=
3
)
return
'red'
;
if
(
value
<=
6
)
return
'orange'
;
if
(
value
<=
9
)
return
'yellow'
;
return
'#2AE02A'
;
}
}
};
//Slider config with floor, ceil and step
//Slider config with floor, ceil and step
$scope
.
slider_floor_ceil
=
{
$scope
.
slider_floor_ceil
=
{
value
:
12
,
value
:
12
,
...
@@ -105,6 +121,17 @@ app.controller('MainCtrl', function($scope, $rootScope, $timeout, $modal) {
...
@@ -105,6 +121,17 @@ app.controller('MainCtrl', function($scope, $rootScope, $timeout, $modal) {
}
}
};
};
//Slider config with rtl
$scope
.
slider_rtl
=
{
value
:
20
,
options
:
{
floor
:
10
,
ceil
:
100
,
step
:
5
,
rightToLeft
:
true
}
};
//Slider config with floating values
//Slider config with floating values
$scope
.
slider_float
=
{
$scope
.
slider_float
=
{
value
:
0.5
,
value
:
0.5
,
...
@@ -427,7 +454,8 @@ app.controller('MainCtrl', function($scope, $rootScope, $timeout, $modal) {
...
@@ -427,7 +454,8 @@ app.controller('MainCtrl', function($scope, $rootScope, $timeout, $modal) {
readOnly
:
false
,
readOnly
:
false
,
disabled
:
false
,
disabled
:
false
,
showTicks
:
false
,
showTicks
:
false
,
showTicksValues
:
false
showTicksValues
:
false
,
rightToLeft
:
false
}
}
};
};
$scope
.
toggleHighValue
=
function
()
{
$scope
.
toggleHighValue
=
function
()
{
...
...
index.html
View file @
a238bd47
...
@@ -109,7 +109,7 @@
...
@@ -109,7 +109,7 @@
</article>
</article>
<article>
<article>
<h2>
Slider with dynamic selection bar color
s
</h2>
<h2>
Slider with dynamic selection bar color
</h2>
<rzslider
<rzslider
rz-slider-model=
"color_slider_bar.value"
rz-slider-model=
"color_slider_bar.value"
rz-slider-options=
"color_slider_bar.options"
rz-slider-options=
"color_slider_bar.options"
...
@@ -117,6 +117,15 @@
...
@@ -117,6 +117,15 @@
<show-code
js-file=
"color_slider_bar"
html-file=
"singleSlider"
></show-code>
<show-code
js-file=
"color_slider_bar"
html-file=
"singleSlider"
></show-code>
</article>
</article>
<article>
<h2>
Slider with dynamic pointer color
</h2>
<rzslider
rz-slider-model=
"color_slider_pointer.value"
rz-slider-options=
"color_slider_pointer.options"
></rzslider>
<show-code
js-file=
"color_slider_pointer"
html-file=
"singleSlider"
></show-code>
</article>
<article>
<article>
<h2>
Slider with custom floor/ceil/step
</h2>
<h2>
Slider with custom floor/ceil/step
</h2>
<rzslider
<rzslider
...
@@ -126,6 +135,15 @@
...
@@ -126,6 +135,15 @@
<show-code
js-file=
"slider_floor_ceil"
html-file=
"singleSlider"
></show-code>
<show-code
js-file=
"slider_floor_ceil"
html-file=
"singleSlider"
></show-code>
</article>
</article>
<article>
<h2>
Right to left slider
</h2>
<rzslider
rz-slider-model=
"slider_rtl.value"
rz-slider-options=
"slider_rtl.options"
></rzslider>
<show-code
js-file=
"slider_rtl"
html-file=
"singleSlider"
></show-code>
</article>
<article>
<article>
<h2>
Slider with floating values
</h2>
<h2>
Slider with floating values
</h2>
<rzslider
<rzslider
...
@@ -361,7 +379,8 @@
...
@@ -361,7 +379,8 @@
<label>
Show ticks values
<input
type=
"checkbox"
<label>
Show ticks values
<input
type=
"checkbox"
ng-model=
"slider_all_options.options.showTicksValues"
></label><br/>
ng-model=
"slider_all_options.options.showTicksValues"
></label><br/>
<label>
Disabled
<input
type=
"checkbox"
ng-model=
"slider_all_options.options.disabled"
></label><br/>
<label>
Disabled
<input
type=
"checkbox"
ng-model=
"slider_all_options.options.disabled"
></label><br/>
<label>
Read-Only
<input
type=
"checkbox"
ng-model=
"slider_all_options.options.readOnly"
></label>
<label>
Read-Only
<input
type=
"checkbox"
ng-model=
"slider_all_options.options.readOnly"
></label><br/>
<label>
Right to left
<input
type=
"checkbox"
ng-model=
"slider_all_options.options.rightToLeft"
></label>
</div>
</div>
</div>
</div>
<rzslider
<rzslider
...
...
snippets/color_slider_pointer.js
0 → 100644
View file @
a238bd47
$scope
.
slider
=
{
value
:
12
,
options
:
{
showSelectionBar
:
true
,
getPointerColor
:
function
(
value
)
{
if
(
value
<=
3
)
return
'red'
;
if
(
value
<=
6
)
return
'orange'
;
if
(
value
<=
9
)
return
'yellow'
;
return
'#2AE02A'
;
}
}
};
snippets/slider_rtl.js
0 → 100644
View file @
a238bd47
$scope
.
slider
=
{
value
:
20
,
options
:
{
floor
:
10
,
ceil
:
100
,
step
:
5
,
rightToLeft
:
true
}
};
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