Skip to content

An iOS style on/off toggle for checkboxes and radio inputs. Created with only css.

License

Notifications You must be signed in to change notification settings

DanielApt/simple-toggle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

simple-toggle

Style checkboxes and radio inputs as iOS style on/off toggles. No JavaScript needed. HTML5 Standards Compliant

Example of toggle in use

Getting Started

To get started, follow these steps:

  1. Run npm install in your terminal
  2. Run gulp in your terminal
  3. The stylesheet can be found in the /dist directory

Usage

To see simple-toggle in usage, view the example

Use the following markup

<div class="simple-toggle">
  <input type="checkbox" name="name" id="twitter">
  <label for="twitter">Twitter</label><!-- this label will be hidden by the css -->
</div>
<label for="twitter">Twitter</label><!-- this label is visible, and is optional -->

Browser Support

Chrome, Safari, FireFox, IE >= 9 (other browsers to be confirmed)

Contributing

Contributions are always welcome. Please send a pull request or flag any issues.

License

ISC © Daniel Apt

About

An iOS style on/off toggle for checkboxes and radio inputs. Created with only css.

Resources

License

Stars

Watchers

Forks

Packages

No packages published