2018-02-10 15:18:01 +00:00
|
|
|
import ngModule from '../../module';
|
2018-11-08 08:20:06 +00:00
|
|
|
import ButtonMenu from '../button-menu/button-menu';
|
2017-06-15 09:22:47 +00:00
|
|
|
import './style.scss';
|
2017-06-13 11:08:06 +00:00
|
|
|
|
2018-11-08 08:20:06 +00:00
|
|
|
export default class IconMenu extends ButtonMenu {
|
2018-05-08 07:28:25 +00:00
|
|
|
constructor($element, $scope, $transclude) {
|
|
|
|
super($element, $scope);
|
|
|
|
this.$transclude = $transclude;
|
2018-11-08 08:20:06 +00:00
|
|
|
this.input = this.element.querySelector('.button');
|
2017-06-15 05:45:01 +00:00
|
|
|
}
|
2017-06-13 11:08:06 +00:00
|
|
|
}
|
2018-05-08 07:28:25 +00:00
|
|
|
IconMenu.$inject = ['$element', '$scope', '$transclude'];
|
2017-06-13 11:08:06 +00:00
|
|
|
|
2018-02-10 15:18:01 +00:00
|
|
|
ngModule.component('vnIconMenu', {
|
2017-06-13 11:08:06 +00:00
|
|
|
template: require('./icon-menu.html'),
|
|
|
|
bindings: {
|
2018-10-18 07:24:20 +00:00
|
|
|
label: '@',
|
2018-05-08 07:28:25 +00:00
|
|
|
showField: '@?',
|
2018-10-18 07:24:20 +00:00
|
|
|
selection: '<?',
|
2018-05-08 07:28:25 +00:00
|
|
|
valueField: '@?',
|
|
|
|
selectFields: '<?',
|
|
|
|
disabled: '<?',
|
|
|
|
initialData: '<?',
|
2018-10-18 07:24:20 +00:00
|
|
|
showFilter: '<?',
|
2018-05-08 07:28:25 +00:00
|
|
|
field: '=?',
|
2018-10-18 07:24:20 +00:00
|
|
|
url: '@?',
|
|
|
|
data: '<?',
|
|
|
|
where: '@?',
|
|
|
|
order: '@?',
|
2018-05-08 07:28:25 +00:00
|
|
|
limit: '<?',
|
|
|
|
multiple: '<?',
|
|
|
|
onChange: '&?',
|
2018-06-25 14:55:19 +00:00
|
|
|
icon: '@?',
|
2018-07-02 11:17:01 +00:00
|
|
|
translateFields: '<?',
|
|
|
|
onOpen: '&?'
|
2018-05-08 07:28:25 +00:00
|
|
|
},
|
|
|
|
transclude: {
|
|
|
|
tplItem: '?tplItem'
|
2017-06-13 11:08:06 +00:00
|
|
|
},
|
2017-06-15 13:00:43 +00:00
|
|
|
controller: IconMenu
|
2017-06-13 11:08:06 +00:00
|
|
|
});
|