Entrance Events! Chat Gallery Search Everyone Wiki Login Register

Welcome, Guest. Please login or register. - Thinking of joining the forum??
May 14, 2025 - @968.95 (what is this?)
Activity rating: Three Stars Posts & Arts: 48/1k.beats Unread Topics | Unread Replies | My Stuff | Random Topic | Recent Posts Start New Topic  Submit Art
News: :ha: :pc: Hello Melonland! :pc: :happy: Super News: Upload a banner!

+  MelonLand Forum
|-+  World Wild Web
| |-+  ♺ ∙ Web Crafting Materials
| | |-+  using carrd icons in non-carrd sites!


« previous next »
Pages: [1] Print
Author Topic: using carrd icons in non-carrd sites!  (Read 395 times)
Bailey / Jay
Newbie ⚓︎
*


any prns

⛺︎ My Room
iMood: lockheartlove
Itch.io: My Games
RSS: RSS

View Profile WWW

Joined 2024!
« on: December 18, 2024 @67.15 »

Hello hello! I've been working on something that I want to share! :seal:

Most people who make websites are probably familiar with fontawesome, but before I knew it existed, I copy/pasted the inline SVG from a carrd and styled it to my liking. A bit convoluted and a bit clunky, but it worked, looked good, had brand icons that fontawesome didn't, and made me feel smart. I like the icons, and generally, I think they look good even when used in regular sites!



As mentioned, though, it was a bit convoluted and clunky to set up. I wanted to find a solution that would make the process easier to use, and I think I have!

Said solution can be found at carrd-icons.netlify.app, and while I would recommend taking a look since it has a list of the current icons I have set up, I'll explain how to use said solution here as well!

First, take a look at this! Yes, this is the same link from earlier, but it's got a list of all the icons! If it has the icons you're looking for, most of the current ones being brand icons, then you can continue!

Next, add this between the head tags of the page(s) you'll be needing icons on. If you want to download it instead, you can do that, too!
Code
<script id="allIcons" src="https://carrd-icons.netlify.app/icons.js"></script>

After that, you stick this in your CSS stylesheet, or in the style tags on the page(s) you're putting icons on, whichever you prefer! Tweak as needed, but only AFTER putting the icons in :'D
Code
svg.carrdicons{
    width: 1.5rem;
    margin: -67px 0px -69px;
    fill:white;
}

And that's pretty much the whole setup! then, wherever you need icons, put this, switching out "name" for the name of whatever icon you're using. The icons list is currently set up with this code snippet copy/paste-able.
Code
<svg class="carrdicons"><use xlink:href="#icon-name"></use></svg>

Sooooo yeah! I wanted to share this, since I've been working on it for a bit, and I'm pretty happy with it! It works well as far as I've tested, but if anyone has suggestions (either for specific carrd icons or for how to improve it), please let me know! I hope this can be helpful to somebody :D
« Last Edit: February 09, 2025 @41.30 by Bailey / Jay » Logged

sen.fish
Casual Poster ⚓︎
*


⛺︎ My Room
View Profile WWW
« Reply #1 on: February 09, 2025 @9.76 »

The icons look great, but using jquery, and a version from over 10 years ago, might not be the best way of going about doing this. 😅 My understanding at least is that jquery used to be very useful for browser cross-compatibility, but nowadays with improvements in how browsers work it's not really worth the cost of loading a 266kb library.
Logged

Bailey / Jay
Newbie ⚓︎
*


any prns

⛺︎ My Room
iMood: lockheartlove
Itch.io: My Games
RSS: RSS

View Profile WWW

Joined 2024!
« Reply #2 on: February 09, 2025 @36.71 »

The icons look great, but using jquery, and a version from over 10 years ago, might not be the best way of going about doing this. 😅 My understanding at least is that jquery used to be very useful for browser cross-compatibility, but nowadays with improvements in how browsers work it's not really worth the cost of loading a 266kb library.

Yeah, you're absolutely right on that 😭 I was using that version of jquery because I grabbed it off of some old stackoverflow question I found a couple years ago, and didn't know any better ways to do it 💀 but!! since posting this, I figured out how to do it more efficiently but I forgot to make some kind of update here :') ty though! /gen
Logged

Pages: [1] Print 
« previous next »
 

Vaguely similar topics! (3)

Pixel Art - Mini Contest - New message icons!

Started by MelooonBoard ☑︎ ∙ Events and Activities

Replies: 21
Views: 5823
Last post 18 Jul, 2024 17:20
by Zunne
POLL: How many personal sites have you built?

Started by xandraBoard ✁ ∙ Web Crafting

Replies: 41
Views: 7838
Last post 25 Apr, 2025 18:47
by boreal_cryptid
I am new to making sites and I want some tips to improve.

Started by Icey!Board ☔︎ ∙ I need Help!

Replies: 4
Views: 2701
Last post 14 Dec, 2021 20:29
by Icey!

Melonking.Net © Always and ever was! SMF 2.0.19 | SMF © 2021 | Privacy Notice | ~ Send Feedback ~ Forum Guide | Rules | RSS | WAP | Mobile


MelonLand Badges and Other Melon Sites!

MelonLand Project! Visit the MelonLand Forum! Support the Forum
Visit Melonking.Net! Visit the Gif Gallery! Pixel Sea TamaNOTchi