Skip to content
This repository was archived by the owner on Oct 8, 2021. It is now read-only.

Commit 2ca372d

Browse files
author
Gabriel Schulhof
committed
Slider tooltip: Converting back to extension.
1 parent 7faa9ef commit 2ca372d

File tree

7 files changed

+36
-18
lines changed

7 files changed

+36
-18
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
.ui-slider-popup {
2+
position: absolute !important;
3+
text-align: center;
4+
z-index: 100;
5+
}

css/structure/jquery.mobile.structure.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
@import url( "jquery.mobile.forms.rangeslider.css" );
2626
@import url( "jquery.mobile.listview.css" );
2727
@import url( "jquery.mobile.forms.slider.css" );
28+
@import url( "jquery.mobile.forms.slider.tooltip.css" );
2829
@import url( "jquery.mobile.table.css" );
2930
@import url( "jquery.mobile.table.columntoggle.css" );
3031
@import url( "jquery.mobile.table.reflow.css" );

css/themes/default/jquery.mobile.theme.css

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1155,6 +1155,22 @@ a.ui-link-inherit {
11551155
outline-style: auto;
11561156
}
11571157

1158+
/* slider tooltip
1159+
-----------------------------------------------------------------------------------------------------------*/
1160+
1161+
.ui-slider .ui-btn-inner {
1162+
padding: 5px 0 0 0 !important;
1163+
font-size:.8em;
1164+
}
1165+
1166+
.ui-slider-popup {
1167+
width: 64px;
1168+
height: 64px;
1169+
font-size: 36px;
1170+
padding-top: 14px;
1171+
opacity: 0.8;
1172+
}
1173+
11581174
/* Dimensions related to the popup arrow
11591175
-----------------------------------------------------------------------------------------------------------*/
11601176
/* desired triangle height: 10px */

docs/examples/slider/slider.tooltip.css

Lines changed: 0 additions & 15 deletions
This file was deleted.

docs/examples/slider/tooltip.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,9 @@
88
<link rel="stylesheet" href="../../_assets/css/jqm-demos.css">
99
<link rel="shortcut icon" href="../../favicon.ico">
1010
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Open+Sans:300,400,700">
11-
<link rel="stylesheet" href="slider.tooltip.css" id="tooltipStyle">
1211
<script src="../../../js/jquery.js"></script>
1312
<script src="../../_assets/js/"></script>
1413
<script src="../../../js/"></script>
15-
<script src="slider.tooltip.js" id="tooltipCode"></script>
1614
</head>
1715
<body>
1816
<div data-role="page" class="jqm-demos">
@@ -27,7 +25,7 @@
2725

2826
<h1>Slider tooltip extension</h1>
2927

30-
<div data-demo-html="true" data-demo-js="#tooltipCode" data-demo-css="#tooltipStyle">
28+
<div data-demo-html="true">
3129
<form>
3230
<label for="slider-1">Slider with tooltip:</label>
3331
<input type="range" name="slider-1" id="slider-1" min="0" max="100" value="50" data-popup-enabled="true">

js/index.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
'widgets/forms/checkboxradio.js',
5353
'widgets/forms/button.js',
5454
'widgets/forms/slider.js',
55+
'widgets/forms/slider.tooltip.js',
5556
'widgets/forms/rangeslider.js',
5657
'widgets/forms/textinput.js',
5758
'widgets/forms/select.custom.js',
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
2+
//>>description: Slider tooltip extension
3+
//>>label: Slidertooltip
4+
//>>group: Forms
5+
//>>css.theme: ../css/themes/default/jquery.mobile.theme.css
6+
//>>css.structure: ../css/structure/jquery.mobile.slider.tooltip.css
7+
8+
define( [ "jquery", "./slider" ], function( $ ) {
9+
//>>excludeEnd("jqmBuildExclude");
110
(function( $, undefined ) {
211

312
$.widget( "mobile.slider", $.mobile.slider, {
@@ -109,3 +118,6 @@ $.widget( "mobile.slider", $.mobile.slider, {
109118
});
110119

111120
})( jQuery );
121+
//>>excludeStart("jqmBuildExclude", pragmas.jqmBuildExclude);
122+
});
123+
//>>excludeEnd("jqmBuildExclude");

0 commit comments

Comments
 (0)