Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
ecommerce-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
ecommerce-ui
Commits
f1887d4f
Commit
f1887d4f
authored
Apr 13, 2014
by
Sven Franck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libs: JQM/extensions, carousel bugfixes
parent
719d051e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
12 deletions
+19
-12
ext/libs/jquery-mobile/extensions.css
ext/libs/jquery-mobile/extensions.css
+3
-2
ext/libs/jquery-mobile/extensions.js
ext/libs/jquery-mobile/extensions.js
+16
-10
No files found.
ext/libs/jquery-mobile/extensions.css
View file @
f1887d4f
...
...
@@ -42,13 +42,14 @@
border-radius
:
inherit
;
}
/* Transition positioning
(1-3 images only at the moment)
*/
/* Transition positioning */
.ui-carousel
li
:not
(
.ui-carousel-active
)
{
right
:
-200%
;
}
.ui-carousel
li
.ui-carousel-active
:nth-child
(
1
)
:nth-last-child
(
3
)
{
right
:
0%
;
}
,
}
.ui-carousel
li
.ui-carousel-active
:nth-child
(
2
)
:nth-last-child
(
1
),
.ui-carousel
li
.ui-carousel-active
:nth-child
(
1
)
:nth-last-child
(
3
)
~
li
{
right
:
100%
;
}
...
...
ext/libs/jquery-mobile/extensions.js
View file @
f1887d4f
...
...
@@ -23,22 +23,34 @@ $.widget( "mobile.carousel", $.extend( {
},
refresh
:
function
(
create
)
{
var
el
=
this
.
element
,
var
$inputs
,
$items
,
i
,
el
=
this
.
element
,
o
=
this
.
options
;
if
(
!
o
.
thumbnails
)
{
if
(
!
o
.
enhanced
)
{
// clear barrel on refesh
if
(
!
create
)
{
$
(
"
#ui-carousel-barrel-
"
+
this
.
uuid
).
remove
();
}
// generate UI and barrel and append to DOM
this
.
_enhance
(
el
,
o
);
el
.
parent
()[
o
.
bulletsPos
===
"
top
"
?
"
prepend
"
:
"
append
"
](
this
.
_barrel
);
}
else
{
this
.
_barrel
=
$
(
"
#
"
+
o
.
barrel
);
}
this
.
_on
(
this
.
_barrel
.
find
(
"
input
"
),
{
$inputs
=
this
.
_barrel
.
find
(
"
input
"
);
$items
=
this
.
_items
=
this
.
_getItems
(
"
li
"
);
this
.
_len
=
$items
.
length
;
this
.
_direction
=
""
;
// set reference on radio buttons
for
(
i
=
0
;
i
<
this
.
_len
;
i
+=
1
)
{
$inputs
.
eq
(
i
).
data
(
"
reference
"
,
$items
.
eq
(
i
)
);
}
this
.
_on
(
$inputs
,
{
"
click
"
:
"
_change
"
});
...
...
@@ -58,10 +70,6 @@ $.widget( "mobile.carousel", $.extend( {
}
});
}
this
.
_items
=
this
.
_getItems
(
"
li
"
);
this
.
_len
=
this
.
_items
.
length
;
this
.
_direction
=
""
;
},
_onKeyPress
:
function
(
e
)
{
...
...
@@ -195,9 +203,7 @@ $.widget( "mobile.carousel", $.mobile.carousel, {
if
(
o
.
bullets
)
{
label
=
$
(
"
<label data-
"
+
$
.
mobile
.
ns
+
"
iconpos='notext'></label>
"
);
radio
=
$
(
"
<input type='radio' name='
"
+
prefix
+
"
' id='
"
+
prefix
+
"
-
"
+
i
+
"
' value='
"
+
i
+
"
'/>
"
)
// set item as reference
.
data
(
"
reference
"
,
$
(
item
)
);
prefix
+
"
-
"
+
i
+
"
' value='
"
+
i
+
"
'/>
"
);
if
(
i
===
0
)
{
radio
.
attr
(
"
checked
"
,
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