Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Bootstrap
bootstrap
Commits
b15e24e3
Commit
b15e24e3
authored
13 years ago
by
Jacob Thornton
Browse files
Options
Download
Email Patches
Plain Diff
don't include data-content/data-title as specifications for options in twipsy/popover
parent
c3c700fd
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
docs/javascript.html
+1
-1
docs/javascript.html
js/bootstrap-popover.js
+5
-1
js/bootstrap-popover.js
js/bootstrap-twipsy.js
+11
-1
js/bootstrap-twipsy.js
with
17 additions
and
3 deletions
+17
-3
docs/javascript.html
+
1
-
1
View file @
b15e24e3
...
...
@@ -677,7 +677,7 @@ $('#.tabs').bind('change', function (e) {
<td>
content
</td>
<td>
string, function
</td>
<td>
'data-content'
</td>
<td>
a
s
tri
ng
or method for retrieving content text.
if none are provided, content will be sourced from a data-content attribute.
</td>
<td>
a
t
tri
bute
or method for retrieving content text.
</td>
</tr>
<tr>
<td>
trigger
</td>
...
...
This diff is collapsed.
Click to expand it.
js/bootstrap-popover.js
+
5
-
1
View file @
b15e24e3
...
...
@@ -51,10 +51,11 @@
,
o
=
this
.
options
if
(
typeof
this
.
options
.
content
==
'
string
'
)
{
content
=
this
.
options
.
content
content
=
$e
.
attr
(
this
.
options
.
content
)
}
else
if
(
typeof
this
.
options
.
content
==
'
function
'
)
{
content
=
this
.
options
.
content
.
call
(
this
.
$element
[
0
])
}
return
content
}
...
...
@@ -80,7 +81,10 @@
$
.
fn
.
popover
.
defaults
=
$
.
extend
({}
,
$
.
fn
.
twipsy
.
defaults
,
{
placement
:
'
right
'
,
content
:
'
data-content
'
,
template
:
'
<div class="arrow"></div><div class="inner"><h3 class="title"></h3><div class="content"><p></p></div></div>
'
})
$
.
fn
.
twipsy
.
rejectAttrOptions
.
push
(
'
content
'
)
}(
window
.
jQuery
||
window
.
ender
);
\ No newline at end of file
This diff is collapsed.
Click to expand it.
js/bootstrap-twipsy.js
+
11
-
1
View file @
b15e24e3
...
...
@@ -304,8 +304,18 @@
,
template
:
'
<div class="twipsy-arrow"></div><div class="twipsy-inner"></div>
'
}
$
.
fn
.
twipsy
.
rejectAttrOptions
=
[
'
title
'
]
$
.
fn
.
twipsy
.
elementOptions
=
function
(
ele
,
options
)
{
return
$
.
extend
({},
options
,
$
(
ele
).
data
())
var
data
=
$
(
ele
).
data
()
,
rejects
=
$
.
fn
.
twipsy
.
rejectAttrOptions
,
i
=
rejects
.
length
while
(
i
--
)
{
delete
data
[
rejects
[
i
]]
}
return
$
.
extend
({},
options
,
data
)
}
}(
window
.
jQuery
||
window
.
ender
);
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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
Menu
Explore
Projects
Groups
Snippets