npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@ellakcy/fa-checkbox

v2.0.1

Published

CSS and SASS lib that shows a shows beautifull checkboxed using fontawesome

Downloads

2

Readme

fa-checkbox

CSS and SASS library for Checkboxes and radio buttons that display fa-check icon from fontawesome.

NOTE: README Under constant update.

How to install

Step 1: Install

npm i @ellakcy/fa-checkbox

Step 2: Load Css

Built CSS is located at ./node_modules/dist/all.css in this package.

You can include it in you html like:

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.0/css/all.min.css">
<link rel="stylesheet" type="text/css" href="node_modules/dist/all.css">

Checkbox icons

Classes:

The library allows you to use the following classes from font awesome:

  • fa-check: https://fontawesome.com/icons/check?f=classic&s=solid
  • fa-square-check: https://fontawesome.com/icons/square-check?f=classic&s=regular

That display the appropriate icon as its value. For the solid version of them also use the fa-solid class.

For checkboxes:

As you can see place fa-check class to checkbox html input. Replace it with fa-square-check for the altenrate icon.

Normal

<input type="checkbox" class="fa-check" name="myRadioGroup">
<input type="checkbox" class="fa-square-check" name="myRadioGroup">

Solid

<input type="checkbox" class="fa-solid fa-check" name="myRadioGroup">
<input type="checkbox" class="fa-solid fa-square-check" name="myRadioGroup">

For radio buttons:

<input type="radio" class="fa-solid fa-check" name="myRadioGroup">
<input type="radio" class="fa-solid fa-square-check" name="myRadioGroup">

Same thing as checkboxes do apply in radio buttons as well.

For select html

Same thing does apply upon select and option:

Only multiple is supported. Class .solid is not supported.

using fa-square-check

<select class="fa-square-check" multiple>
            <option selected>Option 1</option>
            <option selected>Option 2</option>
            <option>Option 3</option>
        </select>

using fa-check

<select class="fa-check" multiple>
            <option selected>Option 1</option>
            <option selected>Option 2</option>
            <option>Option 3</option>
        </select>

Border and radius

Supported only fr checkboxes and radio buttons.

Setting 1px border:

Use border class:

At a checkbox:

<input type="checkbox" class="fa-check border" name="myRadioGroup">

At a radio button

<input type="radio" class="fa-check border" name="myRadioGroup">

Setting radius:

Use radius class:

At a checkbox:

<input type="checkbox" class="fa-check radius" name="myRadioGroup">

At a radio button

<input type="radio" class="fa-check radius" name="myRadioGroup">

Strikethrough

At a label section

Using radio

Approach 1

<input id="rs1" type="radio" class="fa-check" name="myRadioGroup">
<label for="rs1" class="strike">Milk</label>

Approach 2

<label class="strike">
    <input id="rs6" type="radio" class="fa-check" name="myRadioGroup"> 
    Bread
</label>

Using checkbox

Approach 1

<input id="rs1" type="checkbox" class="fa-check" name="myRadioGroup"><label for="rs1" class="strike">Milk</label>

Approach 2

<label class="strike">
    <input id="rs6" type="checkbox" class="fa-check" name="myRadioGroup"> 
    Bread
</label>

Using select multiple

Strikethroiush upon selected

At code bellow the Option1 and Option2 will have strikethrough as text styling

<select class="strike" multiple>
    <option selected>Option 1</option>
    <option selected>Option 2</option>
    <option>Option 3</option>
</select>

Strikethroiush upon unselected

At code bellow the Option3 will have strikethrough as text styling

<select class="strike-opposite" multiple>
    <option selected>Option 1</option>
    <option selected>Option 2</option>
    <option>Option 3</option>
</select>

Example

Look at index.html in this project.

LICENCE

Read LICENCE.md file