Computer >> कंप्यूटर ट्यूटोरियल >  >> प्रोग्रामिंग >> CSS

CSS से टूलटिप में ऐरो जोड़ें


CSS से, आप :after स्यूडो-एलिमेंट का उपयोग करके टूलटिप में एक छोटा ऐरो जोड़ सकते हैं। इसके साथ content प्रॉपर्टी का भी उपयोग करें।

टूलटिप में ऐरो जोड़ने के लिए निम्न कोड चलाकर देखें:

उदाहरण

<!DOCTYPE html> <html>    <style>       .mytooltip .mytext {          visibility: hidden;          width: 140px;          background-color: blue;          color: #fff;          z-index: 1;          bottom: 100%;          left: 60%;          margin-left: -90px;          text-align: center;          border-radius: 6px;          padding: 5px 0;          position: absolute;       }       .mytooltip {          position: relative;          display: inline-block;          margin-top: 50px;       }       .mytooltip .mytext:after {          content: "";          position: absolute;          top: 100%;          left: 50%;          margin-left: -10px;          border-width: 7px;          border-style: solid;          border-color: blue transparent transparent transparent;       }       .mytooltip:hover .mytext {          visibility: visible;       }    </style>    <body>       <div class = "mytooltip">Keep mouse cursor over me          <span class = "mytext"> My Tooltip text</span>       </div>    </body> </html>

  1. CSS से इमेज पर बटन कैसे जोड़ें? CSS से इमेज पर बटन कैसे जोड़ें?

    CSS से इमेज पर बटन जोड़ने का कोड निम्नलिखित है:उदाहरण<!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style> img{    width: 100%; } div {    position: relative;    width

  1. CSS से टूलटिप कैसे बनाएं (एडवांस वर्जन)? CSS से टूलटिप कैसे बनाएं (एडवांस वर्जन)?

    एडवांस टूलटिप में फेड-इन एनिमेशन (opacity + transition), तीर (::after बॉर्डर ट्रिक), केंद्रित संरेखण (left: 50%; margin-left: -60px), और पैरेंट के ऊपर स्थित होता है। उदाहरण <!DOCTYPE html> <html> <style> body { text-align: center; font-family: Segoe UI, Tahoma, Geneva, Verdana,

  1. CSS से होवर पर ट्रांज़िशन कैसे जोड़ें? CSS से होवर पर ट्रांज़िशन कैसे जोड़ें?

    CSS से होवर पर ट्रांज़िशन जोड़ने के लिए, कोड निम्नानुसार है -उदाहरण<!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1" /> <style>    body {       font-family: "Segoe UI"