@mediafly/js-ui 50.0.6-2 → 50.0.6-3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/auto-complete/auto-complete-match-renderer.component.d.ts +3 -3
- package/lib/auto-complete/auto-complete-match-renderer.component.js +59 -17
- package/lib/auto-complete/auto-complete-match-renderer.component.js.map +1 -1
- package/lib/auto-complete/auto-complete.component.d.ts +4 -4
- package/lib/auto-complete/auto-complete.component.js +62 -21
- package/lib/auto-complete/auto-complete.component.js.map +1 -1
- package/lib/auto-focus/auto-focus.js +2 -2
- package/lib/auto-focus/auto-focus.js.map +1 -1
- package/lib/auto-focus/index.d.ts +2 -1
- package/lib/auto-focus/index.js.map +1 -1
- package/lib/badge/badge.js.map +1 -1
- package/lib/color-utils/color-utils.service.js.map +1 -1
- package/lib/feedback/feedback.component.js +1 -1
- package/lib/feedback/feedback.component.js.map +1 -1
- package/lib/font-selector/font-selector.js.map +1 -1
- package/lib/icon/icon.service.js.map +1 -1
- package/lib/progress-circle/progress-circle.d.ts +10 -1
- package/lib/progress-circle/progress-circle.js +23 -14
- package/lib/progress-circle/progress-circle.js.map +1 -1
- package/lib/response-handlers/api-success-handlers.d.ts +1 -1
- package/lib/response-handlers/api-success-handlers.js.map +1 -1
- package/lib/response-handlers/error-response.service.js.map +1 -1
- package/lib/response-handlers/feedback-error-handler.d.ts +1 -1
- package/lib/response-handlers/feedback-error-handler.js.map +1 -1
- package/lib/response-handlers/log-error-handler.d.ts +1 -1
- package/lib/response-handlers/log-error-handler.js.map +1 -1
- package/lib/rich-text/rich-text.component.d.ts +3 -3
- package/lib/rich-text/rich-text.component.js +42 -15
- package/lib/rich-text/rich-text.component.js.map +1 -1
- package/lib/tabs/tab-html-title.js.map +1 -1
- package/lib/tabs/tab.js.map +1 -1
- package/lib/tag-input/tag-input.component.d.ts +7 -7
- package/lib/tag-input/tag-input.component.js +56 -20
- package/lib/tag-input/tag-input.component.js.map +1 -1
- package/lib/tsconfig.deploy.tsbuildinfo +61 -57
- package/lib/url-modification/url-modification.service.js.map +1 -1
- package/package.json +1 -1
- package/src/components/auto-complete/auto-complete-match-renderer.component.ts +19 -29
- package/src/components/auto-complete/auto-complete.component.ts +17 -30
- package/src/components/auto-focus/{auto-focus.js → auto-focus.ts} +5 -9
- package/src/components/badge/{badge.js → badge.ts} +2 -2
- package/src/components/color-utils/color-utils.service.ts +3 -4
- package/src/components/feedback/feedback.component.ts +1 -2
- package/src/components/font-selector/font-selector.ts +0 -1
- package/src/components/icon/icon.service.ts +2 -0
- package/src/components/progress-circle/{progress-circle.js → progress-circle.ts} +9 -15
- package/src/components/response-handlers/api-success-handlers.ts +1 -2
- package/src/components/response-handlers/error-response.service.ts +2 -2
- package/src/components/response-handlers/feedback-error-handler.ts +4 -4
- package/src/components/response-handlers/log-error-handler.ts +3 -3
- package/src/components/rich-text/rich-text.component.ts +18 -23
- package/src/components/tabs/tab-html-title.ts +0 -1
- package/src/components/tabs/tab.ts +0 -1
- package/src/components/tag-input/tag-input.component.ts +19 -30
- package/src/components/url-modification/url-modification.service.ts +1 -1
- /package/src/components/auto-focus/{index.js → index.ts} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import angular from 'angular'
|
|
2
1
|
import _ from 'lodash'
|
|
2
|
+
import { Component, Inject, Input, Output } from '../decorators'
|
|
3
3
|
|
|
4
4
|
export type AutoCompleteMatch = string | AutoCompleteMatchObject
|
|
5
5
|
|
|
@@ -24,20 +24,25 @@ export function isAutoCompleteMatchObject(x: AutoCompleteMatch): x is AutoComple
|
|
|
24
24
|
* handling so that the dropdown functionality can be implemented in other contexts
|
|
25
25
|
* than just an input field (e.g., tag component, comment @ lookups).
|
|
26
26
|
*/
|
|
27
|
+
@Component({
|
|
28
|
+
selector: 'autoCompleteMatchRenderer',
|
|
29
|
+
template: require('./auto-complete-match-renderer.component.html'),
|
|
30
|
+
})
|
|
27
31
|
export default class AutoCompleteMatchRendererComponentController implements ng.IComponentController {
|
|
28
32
|
|
|
29
|
-
delay!: number
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
@Input() delay!: number
|
|
34
|
+
@Input('@') keyEventElementId!: string // it must be an id to an HTMLInputElement
|
|
35
|
+
@Input() minLength!: number
|
|
36
|
+
@Input() testValue!: string | undefined
|
|
37
|
+
|
|
38
|
+
@Output() getMatches!: (params: { input: string, origin: string }) => AutoCompleteMatch[] | ng.IPromise<AutoCompleteMatch[]>
|
|
39
|
+
@Output() onDoneFetching!: () => void
|
|
40
|
+
@Output() onSelect!: (params: {
|
|
36
41
|
displayValue: string | undefined | null,
|
|
37
42
|
origin: string,
|
|
38
43
|
value: string | Record<string, unknown> | undefined | null,
|
|
39
44
|
}) => void
|
|
40
|
-
onStartedFetching!: () => void
|
|
45
|
+
@Output() onStartedFetching!: () => void
|
|
41
46
|
|
|
42
47
|
protected interactionMode: 'mouse' | 'keyboard' = 'mouse'
|
|
43
48
|
protected kbSelectedIndex = -1
|
|
@@ -50,11 +55,11 @@ export default class AutoCompleteMatchRendererComponentController implements ng.
|
|
|
50
55
|
private observer: MutationObserver
|
|
51
56
|
|
|
52
57
|
constructor(
|
|
53
|
-
protected $document: ng.IDocumentService,
|
|
54
|
-
protected $element: ng.IAugmentedJQuery,
|
|
55
|
-
protected $q: ng.IQService,
|
|
56
|
-
protected $scope: ng.IScope,
|
|
57
|
-
protected $timeout: ng.ITimeoutService,
|
|
58
|
+
@Inject('$document') protected $document: ng.IDocumentService,
|
|
59
|
+
@Inject('$element') protected $element: ng.IAugmentedJQuery,
|
|
60
|
+
@Inject('$q') protected $q: ng.IQService,
|
|
61
|
+
@Inject('$scope') protected $scope: ng.IScope,
|
|
62
|
+
@Inject('$timeout') protected $timeout: ng.ITimeoutService,
|
|
58
63
|
) {}
|
|
59
64
|
|
|
60
65
|
$onChanges(changes: { delay: ng.IChangesObject<number> }) {
|
|
@@ -233,18 +238,3 @@ export default class AutoCompleteMatchRendererComponentController implements ng.
|
|
|
233
238
|
}
|
|
234
239
|
}
|
|
235
240
|
}
|
|
236
|
-
|
|
237
|
-
angular.module('app').component('autoCompleteMatchRenderer', {
|
|
238
|
-
bindings: {
|
|
239
|
-
delay: '<',
|
|
240
|
-
getMatches: '&',
|
|
241
|
-
keyEventElementId: '@',
|
|
242
|
-
minLength: '<',
|
|
243
|
-
onDoneFetching: '&',
|
|
244
|
-
onSelect: '&',
|
|
245
|
-
onStartedFetching: '&',
|
|
246
|
-
testValue: '<',
|
|
247
|
-
},
|
|
248
|
-
controller: AutoCompleteMatchRendererComponentController,
|
|
249
|
-
template: require('./auto-complete-match-renderer.component.html')
|
|
250
|
-
})
|
|
@@ -1,19 +1,24 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { Component, Inject, Input, Output } from '../decorators'
|
|
2
2
|
import { AutoCompleteMatch } from './auto-complete-match-renderer.component'
|
|
3
3
|
|
|
4
4
|
|
|
5
|
+
@Component({
|
|
6
|
+
selector: 'autoComplete',
|
|
7
|
+
template: require('./auto-complete.component.html'),
|
|
8
|
+
})
|
|
5
9
|
export default class AutoCompleteComponentController implements ng.IComponentController {
|
|
6
10
|
|
|
7
|
-
clearAfterSelection?: boolean
|
|
8
|
-
delay?: number
|
|
9
|
-
displayClose?: boolean
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
11
|
+
@Input() clearAfterSelection?: boolean
|
|
12
|
+
@Input() delay?: number
|
|
13
|
+
@Input() displayClose?: boolean
|
|
14
|
+
@Input() isDisabled = false
|
|
15
|
+
@Input() isRequired = false
|
|
16
|
+
@Input('@') inputId: string
|
|
17
|
+
@Input() minLength?: number
|
|
18
|
+
@Input('@') placeholderText?: string
|
|
19
|
+
|
|
20
|
+
@Output() getMatches!: (params: { input: string }) => AutoCompleteMatch[] | ng.IPromise<AutoCompleteMatch[]>
|
|
21
|
+
@Output() onSelect?: (params: { value: AutoCompleteMatch | undefined }) => void
|
|
17
22
|
|
|
18
23
|
protected inputValue: string | undefined | null
|
|
19
24
|
protected isFetching: boolean
|
|
@@ -21,7 +26,7 @@ export default class AutoCompleteComponentController implements ng.IComponentCon
|
|
|
21
26
|
protected validationForm: ng.IFormController
|
|
22
27
|
|
|
23
28
|
constructor(
|
|
24
|
-
private translateFactory,
|
|
29
|
+
@Inject('translateFactory') private translateFactory,
|
|
25
30
|
) {}
|
|
26
31
|
|
|
27
32
|
$onInit() {
|
|
@@ -62,21 +67,3 @@ export default class AutoCompleteComponentController implements ng.IComponentCon
|
|
|
62
67
|
this.inputValue = displayValue
|
|
63
68
|
}
|
|
64
69
|
}
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
angular.module('app').component('autoComplete', {
|
|
68
|
-
bindings: {
|
|
69
|
-
clearAfterSelection: '<',
|
|
70
|
-
delay: '<',
|
|
71
|
-
displayClose: '<',
|
|
72
|
-
getMatches: '&',
|
|
73
|
-
isDisabled: '<',
|
|
74
|
-
isRequired: '<',
|
|
75
|
-
inputId: '@',
|
|
76
|
-
minLength: '<',
|
|
77
|
-
onSelect: '&',
|
|
78
|
-
placeholderText: '@',
|
|
79
|
-
},
|
|
80
|
-
controller: AutoCompleteComponentController,
|
|
81
|
-
template: require('./auto-complete.component.html')
|
|
82
|
-
})
|
|
@@ -1,17 +1,13 @@
|
|
|
1
1
|
import angular from 'angular'
|
|
2
2
|
|
|
3
|
-
angular.module('app').directive('mflyAutoFocus', function mflyAutoFocus (
|
|
3
|
+
angular.module('app').directive('mflyAutoFocus', function mflyAutoFocus () {
|
|
4
4
|
|
|
5
5
|
return {
|
|
6
|
-
|
|
7
6
|
restrict: 'A',
|
|
8
|
-
link
|
|
7
|
+
link($scope, element, attrs) {
|
|
9
8
|
if (attrs.mflyAutoFocus === 'true') {
|
|
10
|
-
|
|
11
|
-
element[0].focus();
|
|
12
|
-
|
|
9
|
+
element[0].focus()
|
|
13
10
|
}
|
|
14
11
|
}
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
});
|
|
12
|
+
}
|
|
13
|
+
})
|
|
@@ -3,13 +3,13 @@ import { RGB, RGBAStyles } from '../style-typings/styles'
|
|
|
3
3
|
import ThemeService from '../theme/theme.service'
|
|
4
4
|
import { ThemeTextColor } from '../theme/theme.typings'
|
|
5
5
|
|
|
6
|
-
@Injectable('colorUtilsService')
|
|
7
6
|
|
|
7
|
+
@Injectable('colorUtilsService')
|
|
8
8
|
export default class ColorUtilsService {
|
|
9
9
|
|
|
10
10
|
constructor(
|
|
11
|
-
@Inject('themeService') private themeService: ThemeService
|
|
12
|
-
) {
|
|
11
|
+
@Inject('themeService') private themeService: ThemeService,
|
|
12
|
+
) {}
|
|
13
13
|
|
|
14
14
|
hexToRgb(hex: string): RGB | undefined {
|
|
15
15
|
|
|
@@ -31,5 +31,4 @@ export default class ColorUtilsService {
|
|
|
31
31
|
color: colorRGBA ? `rgba(${colorRGBA.r}, ${colorRGBA.g}, ${colorRGBA.b}, ${opacity})` : undefined,
|
|
32
32
|
}
|
|
33
33
|
}
|
|
34
|
-
|
|
35
34
|
}
|
|
@@ -20,9 +20,8 @@ export interface FeedbackOptions {
|
|
|
20
20
|
|
|
21
21
|
@Component({
|
|
22
22
|
selector: 'feedbackManager',
|
|
23
|
-
template: require('./feedback.component.html')
|
|
23
|
+
template: require('./feedback.component.html'),
|
|
24
24
|
})
|
|
25
|
-
|
|
26
25
|
export default class FeedbackManager implements ng.IComponentController {
|
|
27
26
|
protected alerts: object[] = []
|
|
28
27
|
private timer: ng.IPromise<any> | undefined
|
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import template from './progress-circle.html'
|
|
1
|
+
import { Component, Input } from '../decorators'
|
|
3
2
|
|
|
4
3
|
|
|
5
|
-
|
|
4
|
+
@Component({
|
|
5
|
+
selector: 'mflyProgressCircle',
|
|
6
|
+
template: require('./progress-circle.html'),
|
|
7
|
+
})
|
|
8
|
+
export default class MflyProgressCircleController {
|
|
6
9
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
+
@Input() percent: number
|
|
11
|
+
|
|
12
|
+
protected rotationStyle = { transform: `rotate(0deg)` }
|
|
10
13
|
|
|
11
14
|
// Takes a number on 0-100 scale (will clamp outliers).
|
|
12
15
|
// Returns a style object containing a CSS rotation transform.
|
|
@@ -25,12 +28,3 @@ class MflyProgressCircleController {
|
|
|
25
28
|
}
|
|
26
29
|
}
|
|
27
30
|
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
angular.module('app').component('mflyProgressCircle', {
|
|
31
|
-
template,
|
|
32
|
-
bindings: {
|
|
33
|
-
percent: '<'
|
|
34
|
-
},
|
|
35
|
-
controller: MflyProgressCircleController
|
|
36
|
-
})
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { Injectable } from '../decorators'
|
|
2
2
|
|
|
3
3
|
@Injectable('apiSuccessHandler')
|
|
4
|
-
|
|
5
4
|
export default class ApiSuccessHandler {
|
|
6
5
|
|
|
7
|
-
response<T>(response: ng.
|
|
6
|
+
response<T>(response: ng.IHttpResponse<T>): T {
|
|
8
7
|
|
|
9
8
|
if (response.data === undefined) {
|
|
10
9
|
throw new Error('Response data is undefined.')
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { Inject, Injectable } from '../decorators'
|
|
2
2
|
|
|
3
|
-
@Injectable('errorResponseService')
|
|
4
3
|
|
|
4
|
+
@Injectable('errorResponseService')
|
|
5
5
|
export default class ErrorResponseService {
|
|
6
6
|
|
|
7
7
|
constructor(
|
|
8
8
|
@Inject('translateFactory') private translateFactory,
|
|
9
|
-
) {
|
|
9
|
+
) {}
|
|
10
10
|
|
|
11
11
|
getErrorMessage(response: { data?: { message?: string, Message?: string } }) {
|
|
12
12
|
|
|
@@ -2,17 +2,17 @@ import { Inject, Injectable } from '../decorators'
|
|
|
2
2
|
import FeedbackService from '../feedback/feedback.service'
|
|
3
3
|
import ErrorResponseService from './error-response.service'
|
|
4
4
|
|
|
5
|
-
@Injectable('feedbackErrorHandler')
|
|
6
5
|
|
|
6
|
+
@Injectable('feedbackErrorHandler')
|
|
7
7
|
export default class FeedbackErrorHandler {
|
|
8
8
|
|
|
9
9
|
constructor(
|
|
10
10
|
@Inject('$q') private $q: ng.IQService,
|
|
11
11
|
@Inject('errorResponseService') private errorResponseService: ErrorResponseService,
|
|
12
|
-
@Inject('feedbackService') private feedbackService: FeedbackService
|
|
13
|
-
) {
|
|
12
|
+
@Inject('feedbackService') private feedbackService: FeedbackService,
|
|
13
|
+
) {}
|
|
14
14
|
|
|
15
|
-
responseError(response: ng.
|
|
15
|
+
responseError(response: ng.IHttpResponse<{ message?: string }>) {
|
|
16
16
|
|
|
17
17
|
if (this.errorResponseService.shouldHandleError(response)) {
|
|
18
18
|
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { Inject, Injectable } from '../decorators'
|
|
2
2
|
|
|
3
|
-
@Injectable('logErrorHandler')
|
|
4
3
|
|
|
4
|
+
@Injectable('logErrorHandler')
|
|
5
5
|
export default class LogErrorHandler {
|
|
6
6
|
|
|
7
7
|
constructor(
|
|
8
8
|
@Inject('$log') private $log: ng.ILogService,
|
|
9
|
-
) {
|
|
9
|
+
) {}
|
|
10
10
|
|
|
11
|
-
responseError(response: ng.
|
|
11
|
+
responseError(response: ng.IHttpResponse<{ message?: string }>) {
|
|
12
12
|
|
|
13
13
|
this.$log.error(response)
|
|
14
14
|
}
|
|
@@ -3,20 +3,30 @@ import _ from 'lodash'
|
|
|
3
3
|
import Quill from 'quill'
|
|
4
4
|
import $ from 'jquery'
|
|
5
5
|
import { FontFamilyStyle } from '../font-selector/font-selector'
|
|
6
|
+
import { Component, Inject, Input } from '../decorators'
|
|
6
7
|
|
|
7
8
|
// text editor requires sanitization but also needs to allow for style attributes which are removed by default
|
|
8
9
|
angular.module('app').config(['$sanitizeProvider', ($sanitizeProvider: ng.sanitize.ISanitizeProvider) => {
|
|
9
10
|
$sanitizeProvider.addValidAttrs(['style'])
|
|
10
11
|
}])
|
|
11
12
|
|
|
13
|
+
|
|
14
|
+
@Component({
|
|
15
|
+
selector: 'richText',
|
|
16
|
+
require: {
|
|
17
|
+
ngModelCtrl: 'ngModel',
|
|
18
|
+
},
|
|
19
|
+
template: require('./rich-text.component.html'),
|
|
20
|
+
})
|
|
12
21
|
export default class RichTextComponentController implements ng.IComponentController {
|
|
13
22
|
|
|
14
|
-
|
|
15
|
-
|
|
23
|
+
@Input() allowColorSelection?: boolean
|
|
24
|
+
@Input() allowFontSelection?: boolean
|
|
25
|
+
@Input() isRequired: boolean
|
|
26
|
+
|
|
16
27
|
protected cachedSelection?: { index: number; length: number; }
|
|
17
28
|
protected fontStyle?: FontFamilyStyle
|
|
18
29
|
protected fontSelectorId: string
|
|
19
|
-
protected isRequired: boolean
|
|
20
30
|
protected requiredText: string
|
|
21
31
|
protected selectedColor: string
|
|
22
32
|
protected selectedFont: string
|
|
@@ -33,11 +43,11 @@ export default class RichTextComponentController implements ng.IComponentControl
|
|
|
33
43
|
private DEFAULT_SIZE = '14px'
|
|
34
44
|
|
|
35
45
|
constructor(
|
|
36
|
-
private $element: ng.IAugmentedJQuery,
|
|
37
|
-
private $rootScope: JSUIRootScope,
|
|
38
|
-
private $sanitize: sanitize.ISanitizeService,
|
|
39
|
-
private $timeout: ng.ITimeoutService,
|
|
40
|
-
private translateFactory
|
|
46
|
+
@Inject('$element') private $element: ng.IAugmentedJQuery,
|
|
47
|
+
@Inject('$rootScope') private $rootScope: JSUIRootScope,
|
|
48
|
+
@Inject('$sanitize') private $sanitize: sanitize.ISanitizeService,
|
|
49
|
+
@Inject('$timeout') private $timeout: ng.ITimeoutService,
|
|
50
|
+
@Inject('translateFactory') private translateFactory
|
|
41
51
|
) {}
|
|
42
52
|
|
|
43
53
|
$onChanges(changes: { isRequired?: ng.IChangesObject<boolean> }) {
|
|
@@ -258,18 +268,3 @@ export default class RichTextComponentController implements ng.IComponentControl
|
|
|
258
268
|
|
|
259
269
|
}
|
|
260
270
|
}
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
angular.module('app').component('richText', {
|
|
264
|
-
bindings: {
|
|
265
|
-
allowColorSelection: '<',
|
|
266
|
-
allowFontSelection: '<',
|
|
267
|
-
isRequired: '<',
|
|
268
|
-
ngModel: '<'
|
|
269
|
-
},
|
|
270
|
-
controller: RichTextComponentController,
|
|
271
|
-
require: {
|
|
272
|
-
ngModelCtrl: 'ngModel'
|
|
273
|
-
},
|
|
274
|
-
template: require('./rich-text.component.html')
|
|
275
|
-
})
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import angular from 'angular'
|
|
2
1
|
import _ from 'lodash'
|
|
2
|
+
import { Component, Inject, Input, Output } from '../decorators'
|
|
3
3
|
|
|
4
4
|
export interface DisplayableObject {
|
|
5
5
|
[key: string]: unknown
|
|
@@ -9,15 +9,23 @@ export interface DisplayableObject {
|
|
|
9
9
|
export type TagModel = string | DisplayableObject
|
|
10
10
|
|
|
11
11
|
|
|
12
|
+
@Component({
|
|
13
|
+
selector: 'mflyTagInput',
|
|
14
|
+
require: {
|
|
15
|
+
ngModelCtrl: 'ngModel',
|
|
16
|
+
},
|
|
17
|
+
template: require('./tag-input.html'),
|
|
18
|
+
})
|
|
12
19
|
export default class TagInputController implements ng.IComponentController {
|
|
13
20
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
+
@Input() externalInput!: boolean
|
|
22
|
+
@Input() isDisabled!: boolean
|
|
23
|
+
@Input() inlineTags!: boolean
|
|
24
|
+
@Input('@') inputId!: string
|
|
25
|
+
@Input() required!: boolean
|
|
26
|
+
|
|
27
|
+
@Output() onChange!: (v: { value: TagModel[] | undefined | null }) => void
|
|
28
|
+
@Output() onRemove!: (v: { value: TagModel }) => void
|
|
21
29
|
|
|
22
30
|
protected addText: string
|
|
23
31
|
protected inputValue: string
|
|
@@ -28,9 +36,9 @@ export default class TagInputController implements ng.IComponentController {
|
|
|
28
36
|
private ngModelCtrl: ng.INgModelController
|
|
29
37
|
|
|
30
38
|
constructor(
|
|
31
|
-
private $element: ng.IAugmentedJQuery,
|
|
32
|
-
private $timeout: ng.ITimeoutService,
|
|
33
|
-
private translateFactory
|
|
39
|
+
@Inject('$element') private $element: ng.IAugmentedJQuery,
|
|
40
|
+
@Inject('$timeout') private $timeout: ng.ITimeoutService,
|
|
41
|
+
@Inject('translateFactory') private translateFactory,
|
|
34
42
|
) {}
|
|
35
43
|
|
|
36
44
|
$onInit() {
|
|
@@ -125,22 +133,3 @@ export default class TagInputController implements ng.IComponentController {
|
|
|
125
133
|
})
|
|
126
134
|
}
|
|
127
135
|
}
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
angular.module('app').component('mflyTagInput', {
|
|
131
|
-
bindings: {
|
|
132
|
-
externalInput: '<',
|
|
133
|
-
isDisabled: '<',
|
|
134
|
-
inlineTags: '<',
|
|
135
|
-
inputId: '@',
|
|
136
|
-
ngModel: '<',
|
|
137
|
-
onChange: '&',
|
|
138
|
-
onRemove: '&',
|
|
139
|
-
required: '<',
|
|
140
|
-
},
|
|
141
|
-
controller: TagInputController,
|
|
142
|
-
require: {
|
|
143
|
-
ngModelCtrl: 'ngModel'
|
|
144
|
-
},
|
|
145
|
-
template: require('./tag-input.html')
|
|
146
|
-
})
|
|
File without changes
|