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
3664d149
Commit
3664d149
authored
7 years ago
by
Johann-S
Committed by
XhmikosR
6 years ago
Browse files
Options
Download
Email Patches
Plain Diff
fix declaration of alert jquery plugin only if jquery is available
parent
4aef395e
5 merge requests
!31948
Examples/Floating-labels: fix bad behavior with autofill
,
!30064
test
,
!29779
Responsive sizing
,
!28882
fix custom-select-indicator in IE10
,
!28721
Hot test
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
js/src/alert.js
+5
-5
js/src/alert.js
with
5 additions
and
5 deletions
+5
-5
js/src/alert.js
+
5
-
5
View file @
3664d149
...
@@ -21,7 +21,6 @@ const VERSION = '4.3.1'
...
@@ -21,7 +21,6 @@ const VERSION = '4.3.1'
const
DATA_KEY
=
'
bs.alert
'
const
DATA_KEY
=
'
bs.alert
'
const
EVENT_KEY
=
`.
${
DATA_KEY
}
`
const
EVENT_KEY
=
`.
${
DATA_KEY
}
`
const
DATA_API_KEY
=
'
.data-api
'
const
DATA_API_KEY
=
'
.data-api
'
const
JQUERY_NO_CONFLICT
=
$
.
fn
[
NAME
]
const
Selector
=
{
const
Selector
=
{
DISMISS
:
'
[data-dismiss="alert"]
'
DISMISS
:
'
[data-dismiss="alert"]
'
...
@@ -152,10 +151,11 @@ EventHandler.on(document, Event.CLICK_DATA_API, Selector.DISMISS, Alert._handleD
...
@@ -152,10 +151,11 @@ EventHandler.on(document, Event.CLICK_DATA_API, Selector.DISMISS, Alert._handleD
*/
*/
if
(
typeof
window
.
$
!==
'
undefined
'
||
typeof
window
.
jQuery
!==
'
undefined
'
)
{
if
(
typeof
window
.
$
!==
'
undefined
'
||
typeof
window
.
jQuery
!==
'
undefined
'
)
{
const
$
=
window
.
$
||
window
.
jQuery
const
$
=
window
.
$
||
window
.
jQuery
$
.
fn
[
NAME
]
=
Alert
.
_jQueryInterface
const
JQUERY_NO_CONFLICT
=
$
.
fn
[
NAME
]
$
.
fn
[
NAME
].
Constructor
=
Alert
$
.
fn
[
NAME
]
=
Alert
.
_jQueryInterface
$
.
fn
[
NAME
].
noConflict
=
()
=>
{
$
.
fn
[
NAME
].
Constructor
=
Alert
$
.
fn
[
NAME
].
noConflict
=
()
=>
{
$
.
fn
[
NAME
]
=
JQUERY_NO_CONFLICT
$
.
fn
[
NAME
]
=
JQUERY_NO_CONFLICT
return
Alert
.
_jQueryInterface
return
Alert
.
_jQueryInterface
}
}
...
...
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