Ich versuche, einen Tooltip mit Schaltflächen (zum Beispiel wie LinkedIn) zu erstellen.Tooltip mit Schaltflächen und Bild
Das ist, was ich bisher versucht habe: (aber von hier stecken)
.tooltip{
display: inline;
color:black;
position: relative;
top:200px;
}
.tooltip:hover:after{
background: grey;
border-radius: 5px;
color: #fff;
content: attr(title);
left: 20%;
padding: 5px 15px;
position: absolute;
top: -53px;
width: 163px;
}
.tooltip:hover:before{
border:solid;
border-color: #333 transparent;
border-width: 6px 6px 0px 6px;
bottom: 20px;
content: "";
left: 50%;
position: absolute;
z-index: 99;
}
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>repl.it</title>
<script src="index.js"></script>
<link href="index.css" rel="stylesheet" type="text/css" />
</head>
<body>
<a href="#" title="This is some information for our tooltip." class="tooltip"><span title="More">Linkedin Profile</span></a>
</body>
</html>
Ausgabe:
Aber ich Ich bin nicht in der Lage zu rechnen heraus, wie man
<buttons>
und auch Bild zum Tooltip hinzufügen?Wie formuliert die Lösung nur für HTML/CSS/JS und HTML/CSS?
Erwartete Ausgabe:
Danke
Ich schlage vor, zu verwenden, »Pop über "statt" tooltip "http://www.w3schools.com/bootstrap/bootstrap_popover.asp – Merlin