Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bootstrap
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
bootstrap
Commits
6f2f947a
Commit
6f2f947a
authored
Jan 11, 2012
by
Jacob Thornton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add build tool for js + rename twipsy to tooltip + lots of little doc cleanup
parent
51e4e770
Changes
17
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
297 additions
and
172 deletions
+297
-172
Makefile
Makefile
+1
-1
bootstrap.css
bootstrap.css
+16
-13
bootstrap.min.css
bootstrap.min.css
+13
-13
docs/assets/css/docs.css
docs/assets/css/docs.css
+8
-1
docs/assets/js/application.js
docs/assets/js/application.js
+79
-4
docs/components.html
docs/components.html
+9
-9
docs/javascript.html
docs/javascript.html
+98
-61
docs/scaffolding.html
docs/scaffolding.html
+9
-9
js/bootstrap-popover.js
js/bootstrap-popover.js
+4
-4
js/bootstrap-tooltip.js
js/bootstrap-tooltip.js
+19
-19
js/bootstrap-typeahead.js
js/bootstrap-typeahead.js
+2
-0
js/tests/index.html
js/tests/index.html
+2
-2
js/tests/unit/bootstrap-twipsy.js
js/tests/unit/bootstrap-twipsy.js
+24
-24
lib/bootstrap.less
lib/bootstrap.less
+1
-1
lib/button-groups.less
lib/button-groups.less
+1
-0
lib/tooltip.less
lib/tooltip.less
+10
-10
lib/variables.less
lib/variables.less
+1
-1
No files found.
Makefile
View file @
6f2f947a
...
...
@@ -31,7 +31,7 @@ uglify:
uglifyjs
-o
js/min/bootstrap-scrollspy.js js/bootstrap-scrollspy.js
;
\
uglifyjs
-o
js/min/bootstrap-tabs.js js/bootstrap-tab.js
;
\
uglifyjs
-o
js/min/bootstrap-transitions.js js/bootstrap-transition.js
;
\
uglifyjs
-o
js/min/bootstrap-t
wipsy.js js/bootstrap-twipsy
.js
;
\
uglifyjs
-o
js/min/bootstrap-t
ooltip.js js/bootstrap-tooltip
.js
;
\
else
\
echo
"You must have the UGLIFYJS minifier installed in order to minify Bootstrap's js."
;
\
echo
"You can install it by running: npm install uglify-js -g"
;
\
...
...
bootstrap.css
View file @
6f2f947a
...
...
@@ -6,7 +6,7 @@
* http://www.apache.org/licenses/LICENSE-2.0
*
* Designed and built with all the love in the world @twitter by @mdo and @fat.
* Date:
Mon Jan 9 09:15:32
PST 2012
* Date:
Wed Jan 11 20:37:24
PST 2012
*/
html
,
body
{
margin
:
0
;
...
...
@@ -2208,7 +2208,7 @@ i {
float
:
right
;
margin-left
:
5px
;
}
.t
wipsy
{
.t
ooltip
{
position
:
absolute
;
z-index
:
1020
;
display
:
block
;
...
...
@@ -2219,24 +2219,24 @@ i {
-moz-opacity
:
0
;
opacity
:
0
;
}
.t
wipsy
.in
{
.t
ooltip
.in
{
filter
:
alpha
(
opacity
=
80
);
-moz-opacity
:
0.8
;
opacity
:
0.8
;
}
.t
wipsy
.top
{
.t
ooltip
.top
{
margin-top
:
-2px
;
}
.t
wipsy
.right
{
.t
ooltip
.right
{
margin-left
:
2px
;
}
.t
wipsy
.bottom
{
.t
ooltip
.bottom
{
margin-top
:
2px
;
}
.t
wipsy
.left
{
.t
ooltip
.left
{
margin-left
:
-2px
;
}
.t
wipsy.top
.twipsy
-arrow
{
.t
ooltip.top
.tooltip
-arrow
{
bottom
:
0
;
left
:
50%
;
margin-left
:
-5px
;
...
...
@@ -2244,7 +2244,7 @@ i {
border-right
:
5px
solid
transparent
;
border-top
:
5px
solid
#000000
;
}
.t
wipsy.left
.twipsy
-arrow
{
.t
ooltip.left
.tooltip
-arrow
{
top
:
50%
;
right
:
0
;
margin-top
:
-5px
;
...
...
@@ -2252,7 +2252,7 @@ i {
border-bottom
:
5px
solid
transparent
;
border-left
:
5px
solid
#000000
;
}
.t
wipsy.bottom
.twipsy
-arrow
{
.t
ooltip.bottom
.tooltip
-arrow
{
top
:
0
;
left
:
50%
;
margin-left
:
-5px
;
...
...
@@ -2260,7 +2260,7 @@ i {
border-right
:
5px
solid
transparent
;
border-bottom
:
5px
solid
#000000
;
}
.t
wipsy.right
.twipsy
-arrow
{
.t
ooltip.right
.tooltip
-arrow
{
top
:
50%
;
left
:
0
;
margin-top
:
-5px
;
...
...
@@ -2268,7 +2268,7 @@ i {
border-bottom
:
5px
solid
transparent
;
border-right
:
5px
solid
#000000
;
}
.t
wipsy
-inner
{
.t
ooltip
-inner
{
max-width
:
200px
;
padding
:
3px
8px
;
color
:
white
;
...
...
@@ -2279,7 +2279,7 @@ i {
-moz-border-radius
:
4px
;
border-radius
:
4px
;
}
.t
wipsy
-arrow
{
.t
ooltip
-arrow
{
position
:
absolute
;
width
:
0
;
height
:
0
;
...
...
@@ -2619,6 +2619,9 @@ button.btn::-moz-focus-inner, input[type=submit].btn::-moz-focus-inner {
-moz-border-radius
:
5px
;
border-radius
:
5px
;
}
.btn-group.open
.dropdown-menu.large
{
top
:
40px
;
}
.btn-group.open
.dropdown-toggle
{
background-image
:
none
;
-webkit-box-shadow
:
inset
0
1px
6px
rgba
(
0
,
0
,
0
,
0.15
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);
...
...
bootstrap.min.css
View file @
6f2f947a
...
...
@@ -412,17 +412,17 @@ i{background-image:url(docs/assets/img/glyphicons-halflings-sprite.png);backgrou
.modal-footer
{
padding
:
14px
15px
15px
;
margin-bottom
:
0
;
background-color
:
#f5f5f5
;
border-top
:
1px
solid
#ddd
;
-webkit-border-radius
:
0
0
6px
6px
;
-moz-border-radius
:
0
0
6px
6px
;
border-radius
:
0
0
6px
6px
;
-webkit-box-shadow
:
inset
0
1px
0
#ffffff
;
-moz-box-shadow
:
inset
0
1px
0
#ffffff
;
box-shadow
:
inset
0
1px
0
#ffffff
;
zoom
:
1
;}
.modal-footer
:before
,
.modal-footer
:after
{
display
:
table
;
*
display
:
inline
;
content
:
""
;
zoom
:
1
;}
.modal-footer
:after
{
clear
:
both
;}
.modal-footer
.btn
{
float
:
right
;
margin-left
:
5px
;}
.t
wipsy
{
position
:
absolute
;
z-index
:
1020
;
display
:
block
;
visibility
:
visible
;
padding
:
5px
;
font-size
:
11px
;
filter
:
alpha
(
opacity
=
0
);
-moz-opacity
:
0
;
opacity
:
0
;}
.twipsy
.in
{
filter
:
alpha
(
opacity
=
80
);
-moz-opacity
:
0.8
;
opacity
:
0.8
;}
.t
wipsy
.top
{
margin-top
:
-2px
;}
.t
wipsy
.right
{
margin-left
:
2px
;}
.t
wipsy
.bottom
{
margin-top
:
2px
;}
.t
wipsy
.left
{
margin-left
:
-2px
;}
.t
wipsy.top
.twipsy
-arrow
{
bottom
:
0
;
left
:
50%
;
margin-left
:
-5px
;
border-left
:
5px
solid
transparent
;
border-right
:
5px
solid
transparent
;
border-top
:
5px
solid
#000000
;}
.t
wipsy.left
.twipsy
-arrow
{
top
:
50%
;
right
:
0
;
margin-top
:
-5px
;
border-top
:
5px
solid
transparent
;
border-bottom
:
5px
solid
transparent
;
border-left
:
5px
solid
#000000
;}
.t
wipsy.bottom
.twipsy
-arrow
{
top
:
0
;
left
:
50%
;
margin-left
:
-5px
;
border-left
:
5px
solid
transparent
;
border-right
:
5px
solid
transparent
;
border-bottom
:
5px
solid
#000000
;}
.t
wipsy.right
.twipsy
-arrow
{
top
:
50%
;
left
:
0
;
margin-top
:
-5px
;
border-top
:
5px
solid
transparent
;
border-bottom
:
5px
solid
transparent
;
border-right
:
5px
solid
#000000
;}
.t
wipsy
-inner
{
max-width
:
200px
;
padding
:
3px
8px
;
color
:
white
;
text-align
:
center
;
text-decoration
:
none
;
background-color
:
#000000
;
-webkit-border-radius
:
4px
;
-moz-border-radius
:
4px
;
border-radius
:
4px
;}
.t
wipsy
-arrow
{
position
:
absolute
;
width
:
0
;
height
:
0
;}
.t
ooltip
{
position
:
absolute
;
z-index
:
1020
;
display
:
block
;
visibility
:
visible
;
padding
:
5px
;
font-size
:
11px
;
filter
:
alpha
(
opacity
=
0
);
-moz-opacity
:
0
;
opacity
:
0
;}
.tooltip
.in
{
filter
:
alpha
(
opacity
=
80
);
-moz-opacity
:
0.8
;
opacity
:
0.8
;}
.t
ooltip
.top
{
margin-top
:
-2px
;}
.t
ooltip
.right
{
margin-left
:
2px
;}
.t
ooltip
.bottom
{
margin-top
:
2px
;}
.t
ooltip
.left
{
margin-left
:
-2px
;}
.t
ooltip.top
.tooltip
-arrow
{
bottom
:
0
;
left
:
50%
;
margin-left
:
-5px
;
border-left
:
5px
solid
transparent
;
border-right
:
5px
solid
transparent
;
border-top
:
5px
solid
#000000
;}
.t
ooltip.left
.tooltip
-arrow
{
top
:
50%
;
right
:
0
;
margin-top
:
-5px
;
border-top
:
5px
solid
transparent
;
border-bottom
:
5px
solid
transparent
;
border-left
:
5px
solid
#000000
;}
.t
ooltip.bottom
.tooltip
-arrow
{
top
:
0
;
left
:
50%
;
margin-left
:
-5px
;
border-left
:
5px
solid
transparent
;
border-right
:
5px
solid
transparent
;
border-bottom
:
5px
solid
#000000
;}
.t
ooltip.right
.tooltip
-arrow
{
top
:
50%
;
left
:
0
;
margin-top
:
-5px
;
border-top
:
5px
solid
transparent
;
border-bottom
:
5px
solid
transparent
;
border-right
:
5px
solid
#000000
;}
.t
ooltip
-inner
{
max-width
:
200px
;
padding
:
3px
8px
;
color
:
white
;
text-align
:
center
;
text-decoration
:
none
;
background-color
:
#000000
;
-webkit-border-radius
:
4px
;
-moz-border-radius
:
4px
;
border-radius
:
4px
;}
.t
ooltip
-arrow
{
position
:
absolute
;
width
:
0
;
height
:
0
;}
.popover
{
position
:
absolute
;
top
:
0
;
left
:
0
;
z-index
:
1010
;
display
:
none
;
padding
:
5px
;}
.popover.top
{
margin-top
:
-5px
;}
.popover.right
{
margin-left
:
5px
;}
.popover.bottom
{
margin-top
:
5px
;}
...
...
@@ -460,7 +460,7 @@ button.btn::-moz-focus-inner,input[type=submit].btn::-moz-focus-inner{padding:0;
.btn-group
.btn.large
:last-child
,
.btn-group
.large.dropdown-toggle
{
-webkit-border-top-right-radius
:
6px
;
-moz-border-radius-topright
:
6px
;
border-top-right-radius
:
6px
;
-webkit-border-bottom-right-radius
:
6px
;
-moz-border-radius-bottomright
:
6px
;
border-bottom-right-radius
:
6px
;}
.btn-group
.btn
:hover
,
.btn-group
.btn
:focus
,
.btn-group
.btn
:active
{
z-index
:
2
;}
.btn-group
.dropdown-toggle
{
padding-left
:
8px
;
padding-right
:
8px
;
-webkit-box-shadow
:
inset
1px
0
0
rgba
(
255
,
255
,
255
,
0.125
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);
-moz-box-shadow
:
inset
1px
0
0
rgba
(
255
,
255
,
255
,
0.125
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);
box-shadow
:
inset
1px
0
0
rgba
(
255
,
255
,
255
,
0.125
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);}
.btn-group.open
.dropdown-menu
{
display
:
block
;
top
:
30px
;
-webkit-border-radius
:
5px
;
-moz-border-radius
:
5px
;
border-radius
:
5px
;}
.btn-group.open
.dropdown-menu
{
display
:
block
;
top
:
30px
;
-webkit-border-radius
:
5px
;
-moz-border-radius
:
5px
;
border-radius
:
5px
;}
.btn-group.open
.dropdown-menu.large
{
top
:
40px
;}
.btn-group.open
.dropdown-toggle
{
background-image
:
none
;
-webkit-box-shadow
:
inset
0
1px
6px
rgba
(
0
,
0
,
0
,
0.15
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);
-moz-box-shadow
:
inset
0
1px
6px
rgba
(
0
,
0
,
0
,
0.15
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);
box-shadow
:
inset
0
1px
6px
rgba
(
0
,
0
,
0
,
0.15
),
0
1px
2px
rgba
(
0
,
0
,
0
,
0.05
);}
.btn
.caret
{
margin-top
:
6px
;
margin-left
:
0
;}
.primary
.caret
,
.danger
.caret
,
.info
.caret
,
.success
.caret
{
border-top-color
:
#fff
;
filter
:
alpha
(
opacity
=
75
);
-moz-opacity
:
0.75
;
opacity
:
0.75
;}
...
...
@@ -518,4 +518,4 @@ a.thumbnail:hover{border-color:#0088cc;-webkit-box-shadow:0 1px 4px rgba(0, 105,
.show
{
display
:
block
;}
.invisible
{
visibility
:
hidden
;}
.hidden
{
display
:
none
;
visibility
:
hidden
;}
@media
(
max-width
:
480px
){
.navbar
.nav
{
position
:
absolute
;
top
:
0
;
left
:
0
;
width
:
180px
;
padding-top
:
40px
;
list-style
:
none
;}
.navbar
.nav
,
.navbar
.nav
>
li
:last-child
a
{
-webkit-border-radius
:
0
0
4px
0
;
-moz-border-radius
:
0
0
4px
0
;
border-radius
:
0
0
4px
0
;}
.navbar
.nav
>
li
{
float
:
none
;
display
:
none
;}
.navbar
.nav
>
li
>
a
{
float
:
none
;
background-color
:
#222
;}
.navbar
.nav
>
.active
{
display
:
block
;
position
:
absolute
;
top
:
0
;
left
:
0
;}
.navbar
.nav
>
.active
>
a
{
background-color
:
transparent
;}
.navbar
.nav
>
.active
>
a
:hover
{
background-color
:
#333
;}
.navbar
.nav
>
.active
>
a
:after
{
display
:
inline-block
;
width
:
0
;
height
:
0
;
margin-top
:
8px
;
margin-left
:
6px
;
text-indent
:
-99999px
;
vertical-align
:
top
;
border-left
:
4px
solid
transparent
;
border-right
:
4px
solid
transparent
;
border-top
:
4px
solid
#ffffff
;
filter
:
alpha
(
opacity
=
100
);
-moz-opacity
:
1
;
opacity
:
1
;
content
:
"↓"
;}
.navbar
.nav
:hover
>
li
{
display
:
block
;}
.navbar
.nav
:hover
>
li
>
a
:hover
{
background-color
:
#333
;}
.horizontal-form
.control-group
>
label
{
float
:
none
;
width
:
auto
;
padding-top
:
0
;
text-align
:
left
;}
.horizontal-form
.controls
{
margin-left
:
0
;}
.horizontal-form
.control-list
{
padding-top
:
0
;}
.horizontal-form
.form-actions
{
padding-left
:
0
;}
.modal
{
position
:
fixed
;
top
:
20px
;
left
:
20px
;
right
:
20px
;
width
:
auto
;}
.modal.fade.in
{
top
:
auto
;}
.modal-header
.close
{
padding
:
10px
;}}
@media
(
max-width
:
768px
){
.navbar-fixed
{
position
:
absolute
;}
.navbar-fixed
.nav
{
float
:
none
;}
.container
{
width
:
auto
;
padding
:
0
20px
;}
.row
{
margin-left
:
0
;}
.row
>[
class
*=
"span"
]
{
float
:
none
;
display
:
block
;
width
:
auto
;
margin
:
0
;}}
@media
(
min-width
:
768px
)
and
(
max-width
:
940px
){
.container
{
width
:
748px
;}
.span1
{
width
:
44px
;}
.span2
{
width
:
108px
;}
.span3
{
width
:
172px
;}
.span4
{
width
:
236px
;}
.span5
{
width
:
300px
;}
.span6
{
width
:
364px
;}
.span7
{
width
:
428px
;}
.span8
{
width
:
492px
;}
.span9
{
width
:
556px
;}
.span10
{
width
:
620px
;}
.span11
{
width
:
684px
;}
.span12
{
width
:
748px
;}
.offset1
{
margin-left
:
64px
;}
.offset2
{
margin-left
:
128px
;}
.offset3
{
margin-left
:
192px
;}
.offset4
{
margin-left
:
256px
;}
.offset5
{
margin-left
:
320px
;}
.offset6
{
margin-left
:
384px
;}
.offset7
{
margin-left
:
448px
;}
.offset8
{
margin-left
:
512px
;}
.offset9
{
margin-left
:
576px
;}
.offset10
{
margin-left
:
640px
;}
.offset11
{
margin-left
:
704px
;}
.offset12
{
margin-left
:
768px
;}}
@media
(
max-width
:
480px
){
.navbar
.nav
{
position
:
absolute
;
top
:
0
;
left
:
0
;
width
:
180px
;
padding-top
:
40px
;
list-style
:
none
;}
.navbar
.nav
,
.navbar
.nav
>
li
:last-child
a
{
-webkit-border-radius
:
0
0
4px
0
;
-moz-border-radius
:
0
0
4px
0
;
border-radius
:
0
0
4px
0
;}
.navbar
.nav
>
li
{
float
:
none
;
display
:
none
;}
.navbar
.nav
>
li
>
a
{
float
:
none
;
background-color
:
#222
;}
.navbar
.nav
>
.active
{
display
:
block
;
position
:
absolute
;
top
:
0
;
left
:
0
;}
.navbar
.nav
>
.active
>
a
{
background-color
:
transparent
;}
.navbar
.nav
>
.active
>
a
:hover
{
background-color
:
#333
;}
.navbar
.nav
>
.active
>
a
:after
{
display
:
inline-block
;
width
:
0
;
height
:
0
;
margin-top
:
8px
;
margin-left
:
6px
;
text-indent
:
-99999px
;
vertical-align
:
top
;
border-left
:
4px
solid
transparent
;
border-right
:
4px
solid
transparent
;
border-top
:
4px
solid
#ffffff
;
filter
:
alpha
(
opacity
=
100
);
-moz-opacity
:
1
;
opacity
:
1
;
content
:
"↓"
;}
.navbar
.nav
:hover
>
li
{
display
:
block
;}
.navbar
.nav
:hover
>
li
>
a
:hover
{
background-color
:
#333
;}
.horizontal-form
.control-group
>
label
{
float
:
none
;
width
:
auto
;
padding-top
:
0
;
text-align
:
left
;}
.horizontal-form
.controls
{
margin-left
:
0
;}
.horizontal-form
.control-list
{
padding-top
:
0
;}
.horizontal-form
.form-actions
{
padding-left
:
0
;}
.modal
{
position
:
fixed
;
top
:
20px
;
left
:
20px
;
right
:
20px
;
width
:
auto
;}
.modal.fade.in
{
top
:
auto
;}
.modal-header
.close
{
padding
:
10px
;}}
@media
(
max-width
:
768px
){
.navbar-fixed
{
position
:
absolute
;}
.navbar-fixed
.nav
{
float
:
none
;}
.container
{
width
:
auto
;
padding
:
0
20px
;}
.row
{
margin-left
:
0
;}
.row
>[
class
*=
"span"
]
{
float
:
none
;
display
:
block
;
width
:
auto
;
margin
:
0
;}}
@media
(
min-width
:
768px
)
and
(
max-width
:
940px
){
.container
{
width
:
748px
;}
.span1
{
width
:
44px
;}
.span2
{
width
:
108px
;}
.span3
{
width
:
172px
;}
.span4
{
width
:
236px
;}
.span5
{
width
:
300px
;}
.span6
{
width
:
364px
;}
.span7
{
width
:
428px
;}
.span8
{
width
:
492px
;}
.span9
{
width
:
556px
;}
.span10
{
width
:
620px
;}
.span11
{
width
:
684px
;}
.span12
{
width
:
748px
;}
.offset1
{
margin-left
:
64px
;}
.offset2
{
margin-left
:
128px
;}
.offset3
{
margin-left
:
192px
;}
.offset4
{
margin-left
:
256px
;}
.offset5
{
margin-left
:
320px
;}
.offset6
{
margin-left
:
384px
;}
.offset7
{
margin-left
:
448px
;}
.offset8
{
margin-left
:
512px
;}
.offset9
{
margin-left
:
576px
;}
.offset10
{
margin-left
:
640px
;}
.offset11
{
margin-left
:
704px
;}
.offset12
{
margin-left
:
768px
;}}
docs/assets/css/docs.css
View file @
6f2f947a
...
...
@@ -481,6 +481,13 @@ form.well {
width
:
100px
;
}
#javascript
input
[
type
=
'checkbox'
]
{
display
:
inline
;
margin-left
:
6px
;
position
:
relative
;
top
:
-1px
;
}
/* Responsive Docs
-------------------------------------------------- */
...
...
docs/assets/js/application.js
View file @
6f2f947a
...
...
@@ -48,18 +48,18 @@ $(function(){
setTimeout
(
function
()
{
$
(
el
).
select
()
},
0
)
})
if
(
$
.
fn
.
t
wipsy
)
{
if
(
$
.
fn
.
t
ooltip
)
{
// position static twipsies for components page
if
(
$
(
"
.twipsies a
"
).
length
)
{
$
(
window
).
on
(
'
load resize
'
,
function
()
{
$
(
"
.twipsies a
"
).
each
(
function
()
{
$
(
this
)
.
t
wipsy
({
.
t
ooltip
({
placement
:
$
(
this
).
attr
(
'
title
'
)
,
trigger
:
'
manual
'
})
.
t
wipsy
(
'
show
'
)
.
t
ooltip
(
'
show
'
)
})
})
}
...
...
@@ -67,7 +67,7 @@ $(function(){
// add tipsies to grid for scaffolding
if
(
$
(
'
#grid-system
'
).
length
)
{
$
(
'
#grid-system
'
).
t
wipsy
({
$
(
'
#grid-system
'
).
t
ooltip
({
selector
:
'
.show-grid > div
'
,
title
:
function
()
{
return
$
(
this
).
width
()
+
'
px
'
}
})
...
...
@@ -75,4 +75,79 @@ $(function(){
}
}
// javascript build logic
var
inputs
=
$
(
"
#javascript input
"
)
// toggle all plugin checkboxes
$
(
'
#selectAll
'
).
on
(
'
click
'
,
function
(
e
)
{
e
.
preventDefault
()
inputs
.
attr
(
'
checked
'
,
!
inputs
.
is
(
'
:checked
'
))
})
// handle build button dropdown
var
buildTypes
=
$
(
'
#javascriptBuilder .dropdown-menu li
'
).
on
(
'
click
'
,
function
()
{
buildTypes
.
removeClass
(
'
active
'
)
$
(
this
).
addClass
(
'
active
'
)
})
// request built javascript
$
(
'
#javascriptBuild
'
).
on
(
'
click
'
,
function
()
{
var
names
=
$
(
"
#javascript input:checked
"
)
.
map
(
function
()
{
return
this
.
value
})
.
toArray
()
if
(
names
[
names
.
length
-
1
]
==
'
bootstrap-transition.js
'
)
{
names
.
unshift
(
names
.
pop
())
}
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
jsonpi
'
,
params
:
{
branch
:
'
2.0-wip
'
,
dir
:
'
js
'
,
filenames
:
names
,
compress
:
buildTypes
.
first
().
hasClass
(
'
active
'
)
}
,
url
:
"
http://bootstrap.herokuapp.com
"
})
})
})
// Modified from the original jsonpi https://github.com/benvinegar/jquery-jsonpi
// by the talented Ben Vinegar
!
function
(
$
)
{
$
.
ajaxTransport
(
'
jsonpi
'
,
function
(
opts
,
originalOptions
,
jqXHR
)
{
var
url
=
opts
.
url
;
return
{
send
:
function
(
_
,
completeCallback
)
{
var
name
=
'
jQuery_iframe_
'
+
jQuery
.
now
(),
iframe
,
form
;
iframe
=
$
(
'
<iframe>
'
)
.
attr
(
'
name
'
,
name
)
.
appendTo
(
'
head
'
);
form
=
$
(
'
<form>
'
)
.
attr
(
'
method
'
,
opts
.
type
)
// GET or POST
.
attr
(
'
action
'
,
url
)
.
attr
(
'
target
'
,
name
);
$
.
each
(
opts
.
params
,
function
(
k
,
v
)
{
$
(
'
<input>
'
)
.
attr
(
'
type
'
,
'
hidden
'
)
.
attr
(
'
name
'
,
k
)
.
attr
(
'
value
'
,
v
)
.
appendTo
(
form
);
});
form
.
appendTo
(
'
body
'
).
submit
();
}
};
});
}(
jQuery
);
\ No newline at end of file
docs/components.html
View file @
6f2f947a
...
...
@@ -1195,7 +1195,7 @@
<script
src=
"../js/bootstrap-dropdown.js"
></script>
<script
src=
"../js/bootstrap-tab.js"
></script>
<script
src=
"../js/bootstrap-scrollspy.js"
></script>
<script
src=
"../js/bootstrap-t
wipsy
.js"
></script>
<script
src=
"../js/bootstrap-t
ooltip
.js"
></script>
<script
src=
"assets/js/application.js"
></script>
</body>
</html>
docs/javascript.html
View file @
6f2f947a
This diff is collapsed.
Click to expand it.
docs/scaffolding.html
View file @
6f2f947a
...
...
@@ -399,15 +399,15 @@
</dl>
<dl
class=
"span2"
>
<dt>
Javascript plugins
</dt>
<dd><a
href=
"./javascript.html#transition
s"
>
Transitions
</a></dd>
<dd><a
href=
"./javascript.html#modal
s"
>
Modals
</a></dd>
<dd><a
href=
"./javascript.html#dropdown
s"
>
Dropdowns
</a></dd>
<dd><a
href=
"./javascript.html#transition
"
>
Transition
</a></dd>
<dd><a
href=
"./javascript.html#modal
"
>
Modal
</a></dd>
<dd><a
href=
"./javascript.html#dropdown
"
>
Dropdown
</a></dd>
<dd><a
href=
"./javascript.html#scrollspy"
>
Scrollspy
</a></dd>
<dd><a
href=
"./javascript.html#tab
s"
>
Tabs
</a></dd>
<dd><a
href=
"./javascript.html#t
wipsy"
>
Twipsy tooltips
</a></dd>
<dd><a
href=
"./javascript.html#popover
s"
>
Popovers
</a></dd>
<dd><a
href=
"./javascript.html#alerts"
>
Alert
s
</a></dd>
<dd><a
href=
"./javascript.html#buttons"
>
Button
s
</a></dd>
<dd><a
href=
"./javascript.html#tab
"
>
Tab
</a></dd>
<dd><a
href=
"./javascript.html#t
ooltip"
>
Tooltip
</a></dd>
<dd><a
href=
"./javascript.html#popover
"
>
Popover
</a></dd>
<dd><a
href=
"./javascript.html#alerts"
>
Alert
</a></dd>
<dd><a
href=
"./javascript.html#buttons"
>
Button
</a></dd>
<dd><a
href=
"./javascript.html#collapse"
>
Collapse
</a></dd>
<dd><a
href=
"./javascript.html#carousel"
>
Carousel
</a></dd>
<dd><a
href=
"./javascript.html#typeahead"
>
Typeahead
</a></dd>
...
...
@@ -433,7 +433,7 @@
<script
src=
"http://code.jquery.com/jquery-1.7.min.js"
></script>
<script
src=
"assets/js/google-code-prettify/prettify.js"
></script>
<script
src=
"../js/bootstrap-transition.js"
></script>
<script
src=
"../js/bootstrap-t
wipsy
.js"
></script>
<script
src=
"../js/bootstrap-t
ooltip
.js"
></script>
<script
src=
"assets/js/application.js"
></script>
</body>
...
...
js/bootstrap-popover.js
View file @
6f2f947a
...
...
@@ -26,10 +26,10 @@
this
.
init
(
'
popover
'
,
element
,
options
)
}
/* NOTE: POPOVER EXTENDS BOOTSTRAP-T
WIPSY
.js
========================================= */
/* NOTE: POPOVER EXTENDS BOOTSTRAP-T
OOLTIP
.js
=========================================
=
*/
Popover
.
prototype
=
$
.
extend
({},
$
.
fn
.
t
wipsy
.
Constructor
.
prototype
,
{
Popover
.
prototype
=
$
.
extend
({},
$
.
fn
.
t
ooltip
.
Constructor
.
prototype
,
{
constructor
:
Popover
...
...
@@ -86,7 +86,7 @@
$
.
fn
.
popover
.
Constructor
=
Popover
$
.
fn
.
popover
.
defaults
=
$
.
extend
({}
,
$
.
fn
.
t
wipsy
.
defaults
,
{
$
.
fn
.
popover
.
defaults
=
$
.
extend
({}
,
$
.
fn
.
t
ooltip
.
defaults
,
{
placement
:
'
right
'
,
content
:
''
,
template
:
'
<div class="popover"><div class="arrow"></div><div class="inner"><h3 class="title"></h3><div class="content"><p></p></div></div></div>
'
...
...
js/bootstrap-t
wipsy
.js
→
js/bootstrap-t
ooltip
.js
View file @
6f2f947a
/* ==========================================================
* bootstrap-t
wipsy
.js v2.0.0
* http://twitter.github.com/bootstrap/javascript.html#t
wipsy
/* ==========================================================
=
* bootstrap-t
ooltip
.js v2.0.0
* http://twitter.github.com/bootstrap/javascript.html#t
ooltip
* Inspired by the original jQuery.tipsy by Jason Frame
* ==========================================================
* ==========================================================
=
* Copyright 2011 Twitter, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
...
...
@@ -22,16 +22,16 @@
"
use strict
"
/* T
WIPSY
PUBLIC CLASS DEFINITION
* ============================== */
/* T
OOLTIP
PUBLIC CLASS DEFINITION
* ==============================
=
*/
var
T
wipsy
=
function
(
element
,
options
)
{
this
.
init
(
'
t
wipsy
'
,
element
,
options
)
var
T
ooltip
=
function
(
element
,
options
)
{
this
.
init
(
'
t
ooltip
'
,
element
,
options
)
}
T
wipsy
.
prototype
=
{
T
ooltip
.
prototype
=
{
constructor
:
T
wipsy
constructor
:
T
ooltip
,
init
:
function
(
type
,
element
,
options
)
{
var
eventIn
...
...
@@ -154,7 +154,7 @@
,
setContent
:
function
()
{
var
$tip
=
this
.
tip
()
$tip
.
find
(
'
.t
wipsy
-inner
'
).
html
(
this
.
getTitle
())
$tip
.
find
(
'
.t
ooltip
-inner
'
).
html
(
this
.
getTitle
())
$tip
.
removeClass
(
'
fade in top bottom left right
'
)
}
...
...
@@ -242,29 +242,29 @@
}
/* T
WIPSY
PLUGIN DEFINITION
* ======================== */
/* T
OOLTIP
PLUGIN DEFINITION
* ========================
=
*/
$
.
fn
.
t
wipsy
=
function
(
option
)
{
$
.
fn
.
t
ooltip
=
function
(
option
)
{
return
this
.
each
(
function
()
{
var
$this
=
$
(
this
)
,
data
=
$this
.
data
(
'
t
wipsy
'
)
,
data
=
$this
.
data
(
'
t
ooltip
'
)
,
options
=
typeof
option
==
'
object
'
&&
option
if
(
!
data
)
$this
.
data
(
'
t
wipsy
'
,
(
data
=
new
Twipsy
(
this
,
options
)))
if
(
!
data
)
$this
.
data
(
'
t
ooltip
'
,
(
data
=
new
Tooltip
(
this
,
options
)))
if
(
typeof
option
==
'
string
'
)
data
[
option
]()
})
}
$
.
fn
.
t
wipsy
.
Constructor
=
Twipsy
$
.
fn
.
t
ooltip
.
Constructor
=
Tooltip
$
.
fn
.
t
wipsy
.
defaults
=
{
$
.
fn
.
t
ooltip
.
defaults
=
{
animation
:
true
,
delay
:
0
,
selector
:
false
,
placement
:
'
top
'
,
trigger
:
'
hover
'
,
title
:
''
,
template
:
'
<div class="t
wipsy"><div class="twipsy-arrow"></div><div class="twipsy
-inner"></div></div>
'
,
template
:
'
<div class="t
ooltip"><div class="tooltip-arrow"></div><div class="tooltip
-inner"></div></div>
'
}
}(
window
.
jQuery
)
\ No newline at end of file
js/bootstrap-typeahead.js
View file @
6f2f947a
...
...
@@ -156,11 +156,13 @@
break
case
38
:
// up arrow
if
(
!
this
.
shown
)
return
e
.
preventDefault
()
this
.
prev
()
break
case
40
:
// down arrow
if
(
!
this
.
shown
)
return
e
.
preventDefault
()
this
.
next
()
break
...
...
js/tests/index.html
View file @
6f2f947a
...
...
@@ -20,7 +20,7 @@
<script
src=
"../../js/bootstrap-modal.js"
></script>
<script
src=
"../../js/bootstrap-scrollspy.js"
></script>
<script
src=
"../../js/bootstrap-tab.js"
></script>
<script
src=
"../../js/bootstrap-t
wipsy
.js"
></script>
<script
src=
"../../js/bootstrap-t
ooltip
.js"
></script>
<script
src=
"../../js/bootstrap-popover.js"
></script>
<script
src=
"../../js/bootstrap-typeahead.js"
></script>
...
...
@@ -33,7 +33,7 @@
<script
src=
"unit/bootstrap-modal.js"
></script>
<script
src=
"unit/bootstrap-scrollspy.js"
></script>
<script
src=
"unit/bootstrap-tab.js"
></script>
<script
src=
"unit/bootstrap-t
wipsy
.js"
></script>
<script
src=
"unit/bootstrap-t
ooltip
.js"
></script>
<script
src=
"unit/bootstrap-popover.js"
></script>
<script
src=
"unit/bootstrap-typeahead.js"
></script>
...
...
js/tests/unit/bootstrap-twipsy.js
View file @
6f2f947a
$
(
function
()
{
module
(
"
bootstrap-t
wipsy
"
)
module
(
"
bootstrap-t
ooltip
"
)
test
(
"
should be defined on jquery object
"
,
function
()
{
var
div
=
$
(
"
<div></div>
"
)
ok
(
div
.
t
wipsy
,
'
popover method is defined
'
)
ok
(
div
.
t
ooltip
,
'
popover method is defined
'
)
})
test
(
"
should return element
"
,
function
()
{
var
div
=
$
(
"
<div></div>
"
)
ok
(
div
.
t
wipsy
()
==
div
,
'
document.body returned
'
)
ok
(
div
.
t
ooltip
()
==
div
,
'
document.body returned
'
)
})
test
(
"
should expose default settings
"
,
function
()
{
ok
(
!!
$
.
fn
.
t
wipsy
.
defaults
,
'
defaults is defined
'
)
ok
(
!!
$
.
fn
.
t
ooltip
.
defaults
,
'
defaults is defined
'
)
})
test
(
"
should remove title attribute
"
,
function
()
{
var
t
wipsy
=
$
(
'
<a href="#" rel="twipsy" title="Another twipsy"></a>
'
).
twipsy
()
ok
(
!
t
wipsy
.
attr
(
'
title
'
),
'
title tag was removed
'
)
var
t
ooltip
=
$
(
'
<a href="#" rel="tooltip" title="Another tooltip"></a>
'
).
tooltip
()
ok
(
!
t
ooltip
.
attr
(
'
title
'
),
'
title tag was removed
'
)
})
test
(
"
should add data attribute for referencing original title
"
,
function
()
{
var
t
wipsy
=
$
(
'
<a href="#" rel="twipsy" title="Another twipsy"></a>
'
).
twipsy
()
equals
(
t
wipsy
.
attr
(
'
data-original-title
'
),
'
Another twipsy
'
,
'
original title preserved in data attribute
'
)
var
t
ooltip
=
$
(
'
<a href="#" rel="tooltip" title="Another tooltip"></a>
'
).
tooltip
()
equals
(
t
ooltip
.
attr
(
'
data-original-title
'
),
'
Another tooltip
'
,
'
original title preserved in data attribute
'
)
})
test
(
"
should place tooltips relative to placement option
"
,
function
()
{
$
.
support
.
transition
=
false
var
t
wipsy
=
$
(
'
<a href="#" rel="twipsy" title="Another twipsy
"></a>
'
)
var
t
ooltip
=
$
(
'
<a href="#" rel="tooltip" title="Another tooltip
"></a>
'
)
.
appendTo
(
'
#qunit-fixture
'
)
.
t
wipsy
({
placement
:
'
bottom
'
})
.
t
wipsy
(
'
show
'
)
.
t
ooltip
({
placement
:
'
bottom
'
})
.
t
ooltip
(
'
show
'
)
ok
(
$
(
"
.t
wipsy
"
).
hasClass
(
'
fade bottom in
'
),
'
has correct classes applied
'
)
t
wipsy
.
twipsy
(
'
hide
'
)
ok
(
$
(
"
.t
ooltip
"
).
hasClass
(
'
fade bottom in
'
),
'
has correct classes applied
'
)
t
ooltip
.
tooltip
(
'
hide
'
)
})
test
(
"
should always allow html entities
"
,
function
()
{
$
.
support
.
transition
=
false
var
t
wipsy
=
$
(
'
<a href="#" rel="twipsy
" title="<b>@fat</b>"></a>
'
)
var
t
ooltip
=
$
(
'
<a href="#" rel="tooltip
" title="<b>@fat</b>"></a>
'
)
.
appendTo
(
'
#qunit-fixture
'
)
.
t
wipsy
(
'
show
'
)
.
t
ooltip
(
'
show
'
)
ok
(
$
(
'
.t
wipsy
b
'
).
length
,
'
b tag was inserted
'
)
t
wipsy
.
twipsy
(
'
hide
'
)
ok
(
!
$
(
"
.t
wipsy
"
).
length
,
'
twipsy
removed
'
)
ok
(
$
(
'
.t
ooltip
b
'
).
length
,
'
b tag was inserted
'
)
t
ooltip
.
tooltip
(
'
hide
'
)
ok
(
!
$
(
"
.t
ooltip
"
).
length
,
'
tooltip
removed
'
)
})
test
(
"
should respect custom classes
"
,
function
()
{
var
t
wipsy
=
$
(
'
<a href="#" rel="twipsy" title="Another twipsy
"></a>
'
)
var
t
ooltip
=
$
(
'
<a href="#" rel="tooltip" title="Another tooltip
"></a>
'
)
.
appendTo
(
'
#qunit-fixture
'
)
.
t
wipsy
({
template
:
'
<div class="twipsy some-class"><div class="twipsy-arrow"/><div class="twipsy
-inner"/></div>
'
})
.
t
wipsy
(
'
show
'
)
.
t
ooltip
({
template
:
'
<div class="tooltip some-class"><div class="tooltip-arrow"/><div class="tooltip
-inner"/></div>
'
})
.
t
ooltip
(
'
show
'
)
ok
(
$
(
'
.t
wipsy
'
).
hasClass
(
'
some-class
'
),
'
custom class is present
'
)
t
wipsy
.
twipsy
(
'
hide
'
)
ok
(
!
$
(
"
.t
wipsy
"
).
length
,
'
twipsy
removed
'
)
ok
(
$
(
'
.t
ooltip
'
).
hasClass
(
'
some-class
'
),
'
custom class is present
'
)
t
ooltip
.
tooltip
(
'
hide
'
)
ok
(
!
$
(
"
.t
ooltip
"
).
length
,
'
tooltip
removed
'
)
})
})
\ No newline at end of file
lib/bootstrap.less
View file @
6f2f947a
...
...
@@ -39,7 +39,7 @@
// Components: Popovers
@import "modals.less";
@import "t
wipsy
.less";
@import "t
ooltip
.less";
@import "popovers.less";
// Components: Buttons & Alerts
...
...
lib/button-groups.less
View file @
6f2f947a
...
...
@@ -90,6 +90,7 @@
display: block;
top: 30px;
.border-radius(5px);
&.large { top: 40px; }
}
.btn-group.open .dropdown-toggle {
background-image: none;
...
...
lib/t
wipsy
.less
→
lib/t
ooltip
.less
View file @
6f2f947a
// T
WIPSY
// ------
// T
OOLTIP
// ------
=
.t
wipsy
{
.t
ooltip
{
position: absolute;
z-index: @zindexT
wipsy
;
z-index: @zindexT
ooltip
;
display: block;
visibility: visible;
padding: 5px;
...
...
@@ -14,12 +14,12 @@
&.right { margin-left: 2px; }
&.bottom { margin-top: 2px; }
&.left { margin-left: -2px; }
&.top .t
wipsy
-arrow { #popoverArrow > .top(); }
&.left .t
wipsy
-arrow { #popoverArrow > .left(); }
&.bottom .t
wipsy
-arrow { #popoverArrow > .bottom(); }
&.right .t
wipsy
-arrow { #popoverArrow > .right(); }
&.top .t
ooltip
-arrow { #popoverArrow > .top(); }
&.left .t
ooltip
-arrow { #popoverArrow > .left(); }
&.bottom .t
ooltip
-arrow { #popoverArrow > .bottom(); }
&.right .t
ooltip
-arrow { #popoverArrow > .right(); }
}
.t
wipsy
-inner {
.t
ooltip
-inner {
max-width: 200px;
padding: 3px 8px;
color: white;
...
...
@@ -28,7 +28,7 @@
background-color: @black;
.border-radius(4px);
}
.t
wipsy
-arrow {
.t
ooltip
-arrow {
position: absolute;
width: 0;
height: 0;
...
...
lib/variables.less
View file @
6f2f947a
...
...
@@ -52,7 +52,7 @@
@zindexDropdown: 1000;
@zindexPopover: 1010;
@zindexT
wipsy:
1020;
@zindexT
ooltip:
1020;
@zindexFixedNavbar: 1030;
@zindexModalBackdrop: 1040;
@zindexModal: 1050;
...
...
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