angular-boolean-translator
v1.1.1
Published
Translates a boolean value into text to be displayed
Downloads
1
Maintainers
Readme
angular-booleanTranslator
Simple directive that can be bound to a condition and used to show static text or to collect a boolean value using radio buttons.
Usage
boolean-translator
angular.module('testModule', ['angular-booleanTranslator']);
angular.module('testController', function($scope) {
$scope.testCondition = true;
});
<div ng-controller="testControler">
<boolean-translator condition="testCondition"></boolean-translator>
</div>
boolean-input
<boolean-input ng-model="testInput" name="myInput"></boolean-input>
This will render in a top down format.
To render in a spread format:
<boolean-input ng-model="testInput" name="myInput" layout="spread"></boolean-input>
Alternatively, you can provide true-text and false-text to override the default values which are Yes/No.