forked from akveo/blur-admin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(demo): updated demo for switcher component
- Loading branch information
Showing
3 changed files
with
33 additions
and
8 deletions.
There are no files selected for viewing
24 changes: 24 additions & 0 deletions
24
src/app/pages/form/inputs/widgets/switch/SwitchPanelCtrl.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/** | ||
* @author v.lugovsky | ||
* created on 07.06.2016 | ||
*/ | ||
(function () { | ||
'use strict'; | ||
|
||
angular.module('BlurAdmin.pages.form') | ||
.controller('SwitchPanelCtrl', SwitchPanelCtrl); | ||
|
||
/** @ngInject */ | ||
function SwitchPanelCtrl() { | ||
var vm = this; | ||
|
||
vm.switcherValues = { | ||
primary: true, | ||
warning: true, | ||
danger: true, | ||
info: true, | ||
success: true | ||
}; | ||
} | ||
|
||
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
<div ng-init="switches = [ true, true, true, true, true, true ]" class="switches clearfix"> | ||
<switch color="primary" ng-model="switches[5]"></switch> | ||
<switch color="warning" ng-model="switches[1]"></switch> | ||
<switch color="danger" ng-model="switches[2]"></switch> | ||
<switch color="info" ng-model="switches[3]"></switch> | ||
<switch color="success" ng-model="switches[0]"></switch> | ||
<div ng-controller="SwitchPanelCtrl as switchPanelVm" class="switches clearfix"> | ||
<switch color="primary" ng-model="switchPanelVm.switcherValues.primary"></switch> | ||
<switch color="warning" ng-model="switchPanelVm.switcherValues.warning"></switch> | ||
<switch color="danger" ng-model="switchPanelVm.switcherValues.danger"></switch> | ||
<switch color="info" ng-model="switchPanelVm.switcherValues.info"></switch> | ||
<switch color="success" ng-model="switchPanelVm.switcherValues.success"></switch> | ||
</div> |