/bootswatch

Bootswatch Bootstrap themes, all in one repo

Primary LanguageJavaScript

Bootswatch Bootstrap themes packaged for Meteor

Installation

Unless you have a specific reason to add this package (e.g. running inside an intranet without access to the Bootstrap CDN), you're probably better off just including the desired CSS file from the Bootstrap CDN in the <head> section of your Meteor HTML:

<link href="https://maxcdn.bootstrapcdn.com/bootswatch/latest/<theme-name>/bootstrap.min.css" rel="stylesheet">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/latest/js/bootstrap.min.js"></script>

Just replace <theme-name> with the actual theme name.

All themes load the Glyphicons Halflings font from MaxCDN.

If you do decide to add one of these themes into your app, run

meteor add bootswatch:<theme-name>

You don't need to add a Bootstrap package because the theme already contains the skinned Bootstrap CSS, and it includes the Bootstrap JavaScript and Glyphicons Halflings.

JavaScript components

Features requiring JavaScript (such as drop-downs) or custom jQuery plugins like Tooltip or Popover should work automatically. If they don't work in templates other than body, make sure to run the initialization code in Template.<yourtemplate>.rendered:

Template.foo.rendered = function () {
  this.$('[data-toggle="dropdown"]').dropdown();
  this.$('[data-toggle="tooltip"]').tooltip();
  this.$('[data-toggle="popover"]').popover();
}

For performance reasons, the Tooltip and Popover data-apis are opt-in. Above, we initialize them in the limited scope of the template DOM.

Theme names

  • cerulean
  • cosmo
  • cyborg
  • darkly
  • flatly
  • journal
  • lumen
  • paper - theme that looks closest to @fezVrasta's Material Design skin
  • readable
  • sandstone
  • simplex
  • slate
  • spacelab
  • superhero
  • united - looks like Ubuntu
  • yeti

If you need more detailed control on the files, or to use .less, see Nemo64's package.

Known issues

The themes load the Glyphicons Halflings font forcibly, and there's currently no way to skip loading the font, e.g. if you use Font Awesome.

License and author

Copyright (C) 2015 Dan Dascalescu (@dandv).

Bootstrap, Bootswatch, as well as this package, are published under the MIT license.