28 lines
789 B
JavaScript
28 lines
789 B
JavaScript
|
import ngModule from '../../module';
|
||
|
import './style.scss';
|
||
|
|
||
|
export default class Chip {
|
||
|
constructor($element, $scope, $transclude) {
|
||
|
$transclude($scope.$parent, clone => {
|
||
|
angular.element($element[0].querySelector('div')).append(clone);
|
||
|
});
|
||
|
/* this.mdlElement = this.element.querySelector('.mdl-slider');
|
||
|
componentHandler.upgradeElement(this.mdlElement); */
|
||
|
/* this.mdlElement.addEventListener('change', () => {
|
||
|
this._value = this.input.value;
|
||
|
this.$.$applyAsync();
|
||
|
}); */
|
||
|
}
|
||
|
}
|
||
|
|
||
|
Chip.$inject = ['$element', '$scope', '$transclude'];
|
||
|
|
||
|
ngModule.component('vnChip', {
|
||
|
template: require('./index.html'),
|
||
|
controller: Chip,
|
||
|
transclude: true,
|
||
|
bindings: {
|
||
|
disabled: '<?'
|
||
|
}
|
||
|
});
|