Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

fa-checkbox

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fa-checkbox

  • 0.0.3
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

fa-checkbox

A simple Ruby On Rails gem to replace standard browser's checkboxes and radio buttons with Font Awesome icons.

Dependencies

This gem has a dependency to the font-awesome-rails gem and makes Font Awesome and font-awesome-rails available in your application implicitly.

Installation

Add this to your Gemfile:

gem 'fa-checkbox'

and run bundle install.

Usage

In your application.css, include the css file:

/*
*= require fa-checkbox
*/

to make it picked up by the asset pipline. Restart your webserver if it was running.

Disable in fa-checkbox for older browsers if needed

If you support some old browsers that make trouble with custom @font-face fonts, you can disable fa-checkbox by conditional inclusion of fa-checkbox-revert.css. You need to make it available to your application by pre-compiling it first. Add this line to confic/initializers/assets.rb or another your environment initialization file:

Rails.application.config.assets.precompile += %w(fa-checkbox-revert.css)

And included it to your application layout depending on your conditions. For example, for IE8 and below:

<!--[if lt IE 9]>
<%= stylesheet_link_tag 'fa-checkbox-revert', media: :all %>
<!--<![endif]-->

Caution

Make sure that all labels in your application are linked to their checkboxes and radio buttons with <label for='...'> attribute properly. Otherwise they will not react to you clicks.

FAQs

Package last updated on 08 Oct 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc