Skip to content

Commit

Permalink
Default on/off, update readme with defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilya Radchenko committed Oct 14, 2014
1 parent 15daa92 commit 6e4f947
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@ you will use.
ENV['ember-cli-toggle'] = {
includedThemes: ['light', 'default', 'flip'],
excludedThemes: ['flip'],
defaultTheme: 'light' // defaults to 'default'
defaultTheme: 'light', // defaults to 'default'
defaultSize: 'small', // defaults to 'medium'
defaultOff: 'False', // defaults to 'Off'
defaultOn: 'True' // defaults to 'On'
};
```

Expand Down
4 changes: 2 additions & 2 deletions app/components/x-toggle.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ var config = ENV['ember-cli-toggle'];
export default Ember.Component.extend({
tagName: 'span',
theme: config.defaultTheme || 'default',
off: 'Off',
on: 'On',
off: config.defaultOff || 'Off',
on: config.defaultOn || 'On',
size: config.defaultSize || 'medium',
toggled: false,

Expand Down

0 comments on commit 6e4f947

Please sign in to comment.