HTML Custom Bullets & Icons: HTML में Custom Bullets और Icons कैसे Use करें? Emoji, Images, और CSS के साथ
HTML में default bullets को हटाकर custom emojis, images, या icons से list को visually बेहतर बनाया जा सकता है। इस लेख में जानिए <ul>
को CSS, ::before
, और images के ज़रिए custom bullets देने के तरीके – हिंदी में पूरी जानकारी।
🔷 Custom Bullets क्या हैं?
HTML में ul
list by default ● (disc) के साथ आती है। लेकिन CSS और अन्य तकनीकों से आप उसे:
- ✅ Checkmark
- 🔴 Emoji
- 🖼️ Custom Image
- ➤ SVG Icon
या किसी भी symbol में बदल सकते हैं।
🔶 Step-by-Step तरीके:
✅ 1. list-style-type
से default हटाना
<style>
ul {
list-style-type: none;
padding-left: 0;
}
</style>
📌 अब default bullets हट जाएंगे और आप custom bullet जोड़ सकते हैं।
✅ 2. Emoji Bullet with ::before
<style>
ul.custom-bullets li::before {
content: "✔️";
color: green;
margin-right: 8px;
}
</style>
<ul class="custom-bullets">
<li>Fast</li>
<li>Secure</li>
</ul>
📌 यह checkmark को हर item से पहले add करेगा।
✅ 3. Unicode Symbols
<style>
ul.symbol-list li::before {
content: "\2022"; /* Bullet symbol */
color: red;
font-size: 18px;
margin-right: 10px;
}
</style>
<ul class="symbol-list">
<li>HTML</li>
<li>CSS</li>
</ul>
📌 आप कोई भी Unicode symbol (★, ➤, •) use कर सकते हैं।
✅ 4. Image Icon Bullet (list-style-image
)
<style>
ul.image-bullet {
list-style-image: url('check-icon.png');
}
</style>
<ul class="image-bullet">
<li>Feature A</li>
<li>Feature B</li>
</ul>
📌 यह हर bullet के लिए custom PNG या SVG image दिखाएगा।
✅ 5. SVG Icon via ::before
<style>
ul.svg-bullets li::before {
content: '';
display: inline-block;
background-image: url('arrow.svg');
background-size: 12px 12px;
width: 12px;
height: 12px;
margin-right: 8px;
}
</style>
<ul class="svg-bullets">
<li>Speed</li>
<li>Scalability</li>
</ul>
📌 SVG lightweight होती हैं और scalable रहती हैं।
✅ 6. Font Awesome या Icon Library का उपयोग
<!-- Font Awesome CDN -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
<style>
ul.icon-list li::before {
content: "\f00c"; /* Font Awesome check */
font-family: "Font Awesome 6 Free";
font-weight: 900;
margin-right: 10px;
color: green;
}
</style>
<ul class="icon-list">
<li>Responsive</li>
<li>SEO Friendly</li>
</ul>
📌 Font Awesome, Bootstrap Icons, Remix Icons आदि भी use किए जा सकते हैं।
🎯 कब Custom Bullets का उपयोग करें?
उपयोग | लाभ |
---|---|
Features / Benefits list | Attention grab करता है |
Navigation menu | Branding match करता है |
Pricing list | Professional look देता है |
Comparison table | Content को visually अलग करता है |
✅ Practice Task
- Emoji bullets से checklist बनाइए।
- PNG image से bullets बनाईए (जैसे green tick)।
- SVG icon से responsive bullet बनाइए।
- Font Awesome का check icon जोड़िए।
❗ आम गलतियाँ
गलती | समाधान |
---|---|
list-style: none; भूलना | पहले default bullets हटाना जरूरी है |
::before पर space नहीं | margin-right जरूर दें ताकि spacing ठीक रहे |
Images resize नहीं हो रहीं | background-size या width /height सेट करें |
🧠 SEO & UX Tips
- Custom bullets visually attractive होते हैं, जिससे bounce rate कम होता है
- Ensure करें कि bullets text से align हों (vertical center)
- SVG और fonts fast load होते हैं — performance पर असर नहीं पड़ता
🔚 Conclusion
- HTML list को custom bullets और icons के ज़रिए प्रोफेशनल बनाया जा सकता है
- Emoji, Unicode, images, SVG, और icon libraries सभी powerful तरीके हैं
- Design consistency और readability के अनुसार method चुनें