-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTooltip.html
27 lines (27 loc) · 1.08 KB
/
Tooltip.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Tooltip</title>
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<style>
body {
margin: 30px;
}
</style>
</head>
<body>
<!--
data-bs-title will display the correct result but it will fail the testdome test
-->
<a href="#" data-bs-toggle="tooltip" title="Nice!" data-bs-placement="right" >Hover over me!</a>
<script>
var tooltipTrigger = document.querySelector('[data-bs-toggle="tooltip"]');
if (tooltipTrigger) {
new bootstrap.Tooltip(tooltipTrigger);
}
</script>
</body>
</html>