mirror of
https://github.com/portainer/portainer.git
synced 2025-08-05 13:55:21 +02:00
feat(UX): replace tables with datatables (#1460)
This commit is contained in:
parent
7922ecc4a1
commit
bdb23a8dd2
121 changed files with 4123 additions and 2701 deletions
3
app/directives/ui/slider/slider.html
Normal file
3
app/directives/ui/slider/slider.html
Normal file
|
@ -0,0 +1,3 @@
|
|||
<div>
|
||||
<rzslider rz-slider-options="$ctrl.options" rz-slider-model="$ctrl.model"></rzslider>
|
||||
</div>
|
12
app/directives/ui/slider/slider.js
Normal file
12
app/directives/ui/slider/slider.js
Normal file
|
@ -0,0 +1,12 @@
|
|||
angular.module('ui').component('slider', {
|
||||
templateUrl: 'app/directives/ui/slider/slider.html',
|
||||
controller: 'SliderController',
|
||||
bindings: {
|
||||
model: '=',
|
||||
onChange: '&',
|
||||
floor: '<',
|
||||
ceil: '<',
|
||||
step: '<',
|
||||
precision: '<'
|
||||
}
|
||||
});
|
22
app/directives/ui/slider/sliderController.js
Normal file
22
app/directives/ui/slider/sliderController.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
angular.module('ui')
|
||||
.controller('SliderController', function () {
|
||||
var ctrl = this;
|
||||
|
||||
ctrl.options = {
|
||||
floor: ctrl.floor,
|
||||
ceil: ctrl.ceil,
|
||||
step: ctrl.step,
|
||||
precision: ctrl.precision,
|
||||
showSelectionBar: true,
|
||||
enforceStep: false,
|
||||
translate: function(value, sliderId, label) {
|
||||
if (label === 'floor' || value === 0) {
|
||||
return 'unlimited';
|
||||
}
|
||||
return value;
|
||||
},
|
||||
onChange: function() {
|
||||
ctrl.onChange();
|
||||
}
|
||||
};
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue