Use eslint on ui/lib and ui/features code

This commit is contained in:
gconsidine
2017-09-15 17:40:59 -04:00
parent 6b7126ab6b
commit cec9507504
53 changed files with 525 additions and 562 deletions

View File

@@ -1,15 +1,15 @@
const templateUrl = require('@components/truncate/truncate.partial.html');
const templateUrl = require('~components/truncate/truncate.partial.html');
function atTruncateLink (scope, el, attr, ctrl) {
let truncateController = ctrl;
let string = attr.string;
let maxlength = attr.maxlength;
const truncateController = ctrl;
const { string } = attr;
const { maxlength } = attr;
truncateController.init(el, string, maxlength);
}
function AtTruncateController (strings) {
let vm = this;
const vm = this;
let el;
let string;
let maxlength;
@@ -29,14 +29,14 @@ function AtTruncateController (strings) {
position: 'top',
icon: 'fa fa-clone',
resetOnExit: true,
click: copyToClipboard
click: vm.copyToClipboard
}
};
function copyToClipboard() {
vm.copyToClipboard = () => {
vm.tooltip.popover.text = vm.strings.get('truncate.COPIED');
let textarea = el[0].getElementsByClassName('at-Truncate-textarea')[0];
const textarea = el[0].getElementsByClassName('at-Truncate-textarea')[0];
textarea.value = string;
textarea.select();
@@ -46,7 +46,7 @@ function AtTruncateController (strings) {
AtTruncateController.$inject = ['ComponentsStrings'];
function atTruncate() {
function atTruncate () {
return {
restrict: 'E',
replace: true,
@@ -60,7 +60,7 @@ function atTruncate() {
maxLength: '@',
string: '@'
}
}
};
}
export default atTruncate;