iguazio.dashboard-controls 0.37.7 → 0.37.11
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/dist/i18n/en/functions.json +2 -1
- package/dist/js/iguazio.dashboard-controls.js +3085 -3126
- package/dist/less/iguazio.dashboard-controls.less +2115 -2137
- package/package.json +1 -1
- package/src/i18n/en/functions.json +2 -1
- package/src/igz_controls/components/element-loading-status/element-loading-status.component.js +18 -69
- package/src/igz_controls/components/element-loading-status/element-loading-status.less +3 -26
- package/src/igz_controls/components/element-loading-status/element-loading-status.tpl.html +2 -0
- package/src/igz_controls/components/size/size.component.js +1 -1
- package/src/igz_controls/directives/resizable-table-column.directive.js +6 -2
- package/src/igz_controls/services/element-loading-status.service.js +4 -4
- package/src/igz_controls/services/element-loading-status.service.spec.js +33 -33
- package/src/igz_controls/services/validation.service.js +19 -10
- package/src/nuclio/functions/version/version-configuration/tabs/version-configuration-annotations/version-configuration-annotations.component.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iguazio.dashboard-controls",
|
|
3
|
-
"version": "0.37.
|
|
3
|
+
"version": "0.37.11",
|
|
4
4
|
"main": "dist/js/iguazio.dashboard-controls.js",
|
|
5
5
|
"description": "Collection of resources (such as CSS styles, fonts and images) and AngularJs 1.x components and services to share among different Iguazio repos.",
|
|
6
6
|
"repository": {
|
|
@@ -182,7 +182,8 @@
|
|
|
182
182
|
"NO_LOGS_HAVE_BEEN_FOUND": "No logs have been found...",
|
|
183
183
|
"NODE_SELECTORS": "Node selector",
|
|
184
184
|
"NORMAL": "Normal",
|
|
185
|
-
"
|
|
185
|
+
"NOT_START_WITH_FORBIDDEN_WORDS_ANNOTATION": "Must not start with 'kubernetes.io', 'k8s.io'",
|
|
186
|
+
"NOT_START_WITH_FORBIDDEN_WORDS_LABEL": "Must not start with 'kubernetes.io', 'k8s.io' or 'nuclio.io'",
|
|
186
187
|
"NOT_YET_DEPLOYED": "Not yet deployed",
|
|
187
188
|
"OAUTH2": "OAuth2",
|
|
188
189
|
"ONBUILD_IMAGE": "Onbuild image",
|
package/src/igz_controls/components/element-loading-status/element-loading-status.component.js
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
loadingStatusSize: '@?',
|
|
9
9
|
name: '@',
|
|
10
10
|
refresh: '<?',
|
|
11
|
+
textStatus: '<?',
|
|
11
12
|
title: '@?',
|
|
12
13
|
tooltipLabel: '@?'
|
|
13
14
|
},
|
|
@@ -16,9 +17,8 @@
|
|
|
16
17
|
transclude: true
|
|
17
18
|
});
|
|
18
19
|
|
|
19
|
-
function IgzElementLoadingStatusController($element, $scope, $state, $
|
|
20
|
+
function IgzElementLoadingStatusController($element, $scope, $state, $i18next, i18next, lodash) {
|
|
20
21
|
var ctrl = this;
|
|
21
|
-
var defaultHeight = 0;
|
|
22
22
|
var lng = i18next.language;
|
|
23
23
|
|
|
24
24
|
ctrl.isShowSpinner = true;
|
|
@@ -26,12 +26,10 @@
|
|
|
26
26
|
ctrl.isShowError = false;
|
|
27
27
|
|
|
28
28
|
ctrl.$onInit = onInit;
|
|
29
|
-
ctrl.$postLink = postLink;
|
|
30
29
|
ctrl.$onChanges = onChanges;
|
|
31
30
|
|
|
32
31
|
ctrl.checkSize = checkSize;
|
|
33
32
|
ctrl.refreshPage = refreshPage;
|
|
34
|
-
ctrl.setWrapperHeight = setWrapperHeight;
|
|
35
33
|
|
|
36
34
|
//
|
|
37
35
|
// Hook methods
|
|
@@ -41,18 +39,11 @@
|
|
|
41
39
|
* Initialization method
|
|
42
40
|
*/
|
|
43
41
|
function onInit() {
|
|
44
|
-
$scope.$on('element-loading-status_show-
|
|
45
|
-
$scope.$on('element-loading-status_hide-
|
|
42
|
+
$scope.$on('element-loading-status_show-spinner_' + ctrl.name, showSpinner);
|
|
43
|
+
$scope.$on('element-loading-status_hide-spinner_' + ctrl.name, hideSpinner);
|
|
46
44
|
|
|
47
|
-
$scope.$on('element-loading-status_show-
|
|
48
|
-
$scope.$on('element-loading-status_hide-
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
/**
|
|
52
|
-
* Post linking method
|
|
53
|
-
*/
|
|
54
|
-
function postLink() {
|
|
55
|
-
setWrapperHeight();
|
|
45
|
+
$scope.$on('element-loading-status_show-error_' + ctrl.name, showError);
|
|
46
|
+
$scope.$on('element-loading-status_hide-error_' + ctrl.name, hideError);
|
|
56
47
|
}
|
|
57
48
|
|
|
58
49
|
/**
|
|
@@ -73,8 +64,6 @@
|
|
|
73
64
|
refresh: true
|
|
74
65
|
});
|
|
75
66
|
}
|
|
76
|
-
|
|
77
|
-
defaultHeight = ctrl.loadingStatusSize === 'small' ? 20 : 40;
|
|
78
67
|
}
|
|
79
68
|
|
|
80
69
|
//
|
|
@@ -101,80 +90,40 @@
|
|
|
101
90
|
$state.go($state.current, {}, {reload: true});
|
|
102
91
|
}
|
|
103
92
|
|
|
104
|
-
/**
|
|
105
|
-
* Set height of spinner wrapper
|
|
106
|
-
*/
|
|
107
|
-
function setWrapperHeight() {
|
|
108
|
-
$timeout(function () {
|
|
109
|
-
var elementHeight = $element.height() > 0 ? $element.height() : defaultHeight;
|
|
110
|
-
var elementParentHeight = $element.parent().height() > 0 ? $element.parent().height() : defaultHeight;
|
|
111
|
-
|
|
112
|
-
if (ctrl.isShowSpinner) {
|
|
113
|
-
$element.find('.loader-wrapper').height(elementParentHeight || elementHeight);
|
|
114
|
-
$element.find('.loader-wrapper').addClass('appeared');
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
if (ctrl.isShowError) {
|
|
118
|
-
$element.find('.loading-error').height(elementHeight || elementParentHeight);
|
|
119
|
-
$element.find('.loading-error').addClass('appeared');
|
|
120
|
-
}
|
|
121
|
-
});
|
|
122
|
-
}
|
|
123
|
-
|
|
124
93
|
//
|
|
125
94
|
// Private methods
|
|
126
95
|
//
|
|
127
96
|
|
|
128
97
|
/**
|
|
129
98
|
* Show given loading spinner
|
|
130
|
-
* @param {Object} ev - angular event object
|
|
131
|
-
* @param {Object} args - arguments passed from $broadcast
|
|
132
99
|
*/
|
|
133
|
-
function showSpinner(
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
ctrl.isShowSpinner = true;
|
|
138
|
-
ctrl.setWrapperHeight();
|
|
139
|
-
}
|
|
100
|
+
function showSpinner() {
|
|
101
|
+
ctrl.isShowError = false;
|
|
102
|
+
ctrl.isShowContent = false;
|
|
103
|
+
ctrl.isShowSpinner = true;
|
|
140
104
|
}
|
|
141
105
|
|
|
142
106
|
/**
|
|
143
107
|
* Hide given loading spinner
|
|
144
|
-
* @param {Object} ev - angular event object
|
|
145
|
-
* @param {Object} args - arguments passed from $broadcast
|
|
146
108
|
*/
|
|
147
|
-
function hideSpinner(
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
$timeout(function () {
|
|
151
|
-
ctrl.isShowContent = true;
|
|
152
|
-
}, 2);
|
|
153
|
-
}
|
|
109
|
+
function hideSpinner() {
|
|
110
|
+
ctrl.isShowSpinner = false;
|
|
111
|
+
ctrl.isShowContent = true;
|
|
154
112
|
}
|
|
155
113
|
|
|
156
114
|
/**
|
|
157
115
|
* Show given loading error
|
|
158
|
-
* @param {Object} ev - angular event object
|
|
159
|
-
* @param {Object} args - arguments passed from $broadcast
|
|
160
116
|
*/
|
|
161
|
-
function showError(
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
ctrl.isShowSpinner = false;
|
|
165
|
-
ctrl.setWrapperHeight();
|
|
166
|
-
}
|
|
117
|
+
function showError() {
|
|
118
|
+
ctrl.isShowError = true;
|
|
119
|
+
ctrl.isShowSpinner = false;
|
|
167
120
|
}
|
|
168
121
|
|
|
169
122
|
/**
|
|
170
123
|
* Hide given loading error
|
|
171
|
-
* @param {Object} ev - angular event object
|
|
172
|
-
* @param {Object} args - arguments passed from $broadcast
|
|
173
124
|
*/
|
|
174
|
-
function hideError(
|
|
175
|
-
|
|
176
|
-
ctrl.isShowError = false;
|
|
177
|
-
}
|
|
125
|
+
function hideError() {
|
|
126
|
+
ctrl.isShowError = false;
|
|
178
127
|
}
|
|
179
128
|
}
|
|
180
129
|
}());
|
|
@@ -9,20 +9,9 @@
|
|
|
9
9
|
height: 100%;
|
|
10
10
|
width: 100%;
|
|
11
11
|
position: relative;
|
|
12
|
-
opacity: 0;
|
|
13
|
-
transition: opacity .2s;
|
|
14
12
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
transition: opacity .5s;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
// Overcome ngAnimate delay (hide this ng-if block immediately)
|
|
21
|
-
&.ng-leave {
|
|
22
|
-
transition: initial;
|
|
23
|
-
display: none;
|
|
24
|
-
height: 0;
|
|
25
|
-
width: 0;
|
|
13
|
+
.loader-text {
|
|
14
|
+
color: @loading-text-color;
|
|
26
15
|
}
|
|
27
16
|
}
|
|
28
17
|
|
|
@@ -32,18 +21,6 @@
|
|
|
32
21
|
width: 100%;
|
|
33
22
|
height: 100%;
|
|
34
23
|
position: relative;
|
|
35
|
-
opacity: 0;
|
|
36
|
-
transition: opacity .2s;
|
|
37
|
-
|
|
38
|
-
&.appeared {
|
|
39
|
-
opacity: 1;
|
|
40
|
-
transition: opacity .5s;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
// Overcome ngAnimate delay (hide this ng-if block immediately)
|
|
44
|
-
&.ng-leave {
|
|
45
|
-
display: none;
|
|
46
|
-
}
|
|
47
24
|
|
|
48
25
|
.sad-icon {
|
|
49
26
|
position: absolute;
|
|
@@ -95,4 +72,4 @@
|
|
|
95
72
|
}
|
|
96
73
|
}
|
|
97
74
|
}
|
|
98
|
-
}
|
|
75
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
<div class="element-loading-status" data-ng-class="'loading-status-' + $ctrl.loadingStatusSize">
|
|
2
2
|
<div class="loader-wrapper" data-ng-if="$ctrl.isShowSpinner">
|
|
3
3
|
<div class="loader-fading-circle"
|
|
4
|
+
data-ng-if="!$ctrl.textStatus"
|
|
4
5
|
data-uib-tooltip="{{$ctrl.tooltipLabel}}"
|
|
5
6
|
data-tooltip-placement="top"
|
|
6
7
|
data-tooltip-popup-delay="100"
|
|
@@ -18,6 +19,7 @@
|
|
|
18
19
|
<div class="loader-circle11 loader-circle"></div>
|
|
19
20
|
<div class="loader-circle12 loader-circle"></div>
|
|
20
21
|
</div>
|
|
22
|
+
<div data-ng-if="$ctrl.textStatus" class="loader-text">{{ 'common:LOADING_CAPITALIZE_ELLIPSIS' | i18next }}</div>
|
|
21
23
|
</div>
|
|
22
24
|
|
|
23
25
|
<div data-ng-if="$ctrl.isShowContent && !$ctrl.isShowError">
|
|
@@ -43,7 +43,11 @@
|
|
|
43
43
|
$timeout(initColumnsWidths);
|
|
44
44
|
$timeout(initElements);
|
|
45
45
|
|
|
46
|
-
angular.element($window).on('resize',
|
|
46
|
+
angular.element($window).on('resize', function () {
|
|
47
|
+
$timeout(function () {
|
|
48
|
+
reloadColumns()
|
|
49
|
+
}, 200)
|
|
50
|
+
});
|
|
47
51
|
$scope.$on('reload-columns', reloadColumns);
|
|
48
52
|
$scope.$on('resizable-table-column_reset-data', resetData);
|
|
49
53
|
$scope.$on('$destroy', onDestroy);
|
|
@@ -243,7 +247,7 @@
|
|
|
243
247
|
columnWidth: ctrl.columnHeadWidth + 'px',
|
|
244
248
|
nextColumnWidth: ctrl.nextBlockWidth + 'px'
|
|
245
249
|
});
|
|
246
|
-
}
|
|
250
|
+
});
|
|
247
251
|
}
|
|
248
252
|
}
|
|
249
253
|
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
* @param {string} name - spinner name
|
|
23
23
|
*/
|
|
24
24
|
function showSpinner(name) {
|
|
25
|
-
$rootScope.$broadcast('element-loading-status_show-
|
|
25
|
+
$rootScope.$broadcast('element-loading-status_show-spinner_' + name);
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
/**
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
* @param {string} name - spinner name
|
|
31
31
|
*/
|
|
32
32
|
function hideSpinner(name) {
|
|
33
|
-
$rootScope.$broadcast('element-loading-status_hide-
|
|
33
|
+
$rootScope.$broadcast('element-loading-status_hide-spinner_' + name);
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/**
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
* @param {string} name - spinner name
|
|
55
55
|
*/
|
|
56
56
|
function showLoadingError(name) {
|
|
57
|
-
$rootScope.$broadcast('element-loading-status_show-
|
|
57
|
+
$rootScope.$broadcast('element-loading-status_show-error_' + name);
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
/**
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
* @param {string} name - spinner name
|
|
63
63
|
*/
|
|
64
64
|
function hideLoadingError(name) {
|
|
65
|
-
$rootScope.$broadcast('element-loading-status_hide-
|
|
65
|
+
$rootScope.$broadcast('element-loading-status_hide-error_' + name);
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
/**
|
|
@@ -20,81 +20,81 @@ describe('ElementLoadingStatusService: ', function () {
|
|
|
20
20
|
|
|
21
21
|
describe('loading spinners: ', function () {
|
|
22
22
|
it('showSpinner() ', function () {
|
|
23
|
-
ElementLoadingStatusService.showSpinner('show
|
|
24
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner'
|
|
23
|
+
ElementLoadingStatusService.showSpinner('show-spinner');
|
|
24
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner_show-spinner' );
|
|
25
25
|
});
|
|
26
26
|
|
|
27
27
|
it('hideSpinner() ', function () {
|
|
28
|
-
ElementLoadingStatusService.hideSpinner('hide
|
|
29
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner'
|
|
28
|
+
ElementLoadingStatusService.hideSpinner('hide-spinner');
|
|
29
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner_hide-spinner');
|
|
30
30
|
});
|
|
31
31
|
|
|
32
32
|
it('showSpinnerGroup() ', function () {
|
|
33
33
|
var names = [
|
|
34
|
-
'
|
|
35
|
-
'
|
|
36
|
-
'
|
|
34
|
+
'first-spinner',
|
|
35
|
+
'second-spinner',
|
|
36
|
+
'third-spinner'
|
|
37
37
|
];
|
|
38
38
|
|
|
39
39
|
ElementLoadingStatusService.showSpinnerGroup(names);
|
|
40
40
|
|
|
41
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner'
|
|
42
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner'
|
|
43
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner'
|
|
41
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner_first-spinner');
|
|
42
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner_second-spinner');
|
|
43
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-spinner_third-spinner');
|
|
44
44
|
});
|
|
45
45
|
|
|
46
46
|
it('hideSpinnerGroup() ', function () {
|
|
47
47
|
var names = [
|
|
48
|
-
'
|
|
49
|
-
'
|
|
50
|
-
'
|
|
48
|
+
'first-spinner',
|
|
49
|
+
'second-spinner',
|
|
50
|
+
'third-spinner'
|
|
51
51
|
];
|
|
52
52
|
|
|
53
53
|
ElementLoadingStatusService.hideSpinnerGroup(names);
|
|
54
54
|
|
|
55
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner'
|
|
56
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner'
|
|
57
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner'
|
|
55
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner_first-spinner');
|
|
56
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner_second-spinner');
|
|
57
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-spinner_third-spinner');
|
|
58
58
|
});
|
|
59
59
|
});
|
|
60
60
|
|
|
61
61
|
describe('loading errors: ', function () {
|
|
62
62
|
it('showLoadingError() ', function () {
|
|
63
|
-
ElementLoadingStatusService.showLoadingError('show
|
|
64
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error'
|
|
63
|
+
ElementLoadingStatusService.showLoadingError('show-error');
|
|
64
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error_show-error');
|
|
65
65
|
});
|
|
66
66
|
|
|
67
67
|
it('hideLoadingError() ', function () {
|
|
68
|
-
ElementLoadingStatusService.hideLoadingError('hide
|
|
69
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error'
|
|
68
|
+
ElementLoadingStatusService.hideLoadingError('hide-error');
|
|
69
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error_hide-error');
|
|
70
70
|
});
|
|
71
71
|
|
|
72
72
|
it('showLoadingErrorGroup() ', function () {
|
|
73
73
|
var names = [
|
|
74
|
-
'
|
|
75
|
-
'
|
|
76
|
-
'
|
|
74
|
+
'first-error',
|
|
75
|
+
'second-error',
|
|
76
|
+
'third-error'
|
|
77
77
|
];
|
|
78
78
|
|
|
79
79
|
ElementLoadingStatusService.showLoadingErrorGroup(names);
|
|
80
80
|
|
|
81
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error'
|
|
82
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error'
|
|
83
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error'
|
|
81
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error_first-error');
|
|
82
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error_second-error');
|
|
83
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_show-error_third-error');
|
|
84
84
|
});
|
|
85
85
|
|
|
86
86
|
it('hideLoadingErrorGroup() ', function () {
|
|
87
87
|
var names = [
|
|
88
|
-
'
|
|
89
|
-
'
|
|
90
|
-
'
|
|
88
|
+
'first-error',
|
|
89
|
+
'second-error',
|
|
90
|
+
'third-error'
|
|
91
91
|
];
|
|
92
92
|
|
|
93
93
|
ElementLoadingStatusService.hideLoadingErrorGroup(names);
|
|
94
94
|
|
|
95
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error'
|
|
96
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error'
|
|
97
|
-
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error'
|
|
95
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error_first-error');
|
|
96
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error_second-error');
|
|
97
|
+
expect($rootScope.$broadcast).toHaveBeenCalledWith('element-loading-status_hide-error_third-error');
|
|
98
98
|
});
|
|
99
99
|
});
|
|
100
|
-
});
|
|
100
|
+
});
|
|
@@ -294,12 +294,6 @@
|
|
|
294
294
|
$i18next.t('common:BEGIN_END_WITH', { lng: lng }) + ': a–z, 0–9',
|
|
295
295
|
pattern: /^([a-z0-9]([^/]*[a-z0-9])?\/)?[^/]+$/
|
|
296
296
|
},
|
|
297
|
-
{
|
|
298
|
-
name: 'prefixNotStart',
|
|
299
|
-
label: '[' + $i18next.t('functions:PREFIX', { lng: lng }) + '] ' +
|
|
300
|
-
$i18next.t('functions:NOT_START_WITH_FORBIDDEN_WORDS', { lng: lng }),
|
|
301
|
-
pattern: /^(?!kubernetes\.io\/)(?!k8s\.io\/)(?!nuclio\.io\/)/
|
|
302
|
-
},
|
|
303
297
|
{
|
|
304
298
|
name: 'prefixMaxLength',
|
|
305
299
|
label: '[' + $i18next.t('functions:PREFIX', { lng: lng }) + '] ' +
|
|
@@ -330,7 +324,6 @@
|
|
|
330
324
|
generateRule.validCharacters('a-z A-Z 0-9 - _ .'),
|
|
331
325
|
generateRule.beginNotWith('0-9 .')
|
|
332
326
|
],
|
|
333
|
-
prefixedQualifiedName: commonRules.prefixedQualifiedName,
|
|
334
327
|
qualifiedName: [
|
|
335
328
|
generateRule.validCharacters('a-z A-Z 0-9 - _ .'),
|
|
336
329
|
generateRule.beginEndWith('a-z A-Z 0-9'),
|
|
@@ -358,9 +351,25 @@
|
|
|
358
351
|
generateRule.length({ max: lengths.function.name })
|
|
359
352
|
),
|
|
360
353
|
label: {
|
|
361
|
-
key: commonRules.prefixedQualifiedName.concat(
|
|
362
|
-
|
|
363
|
-
|
|
354
|
+
key: commonRules.prefixedQualifiedName.concat(
|
|
355
|
+
{
|
|
356
|
+
name: 'prefixNotStart',
|
|
357
|
+
label: '[' + $i18next.t('functions:PREFIX', {lng: lng}) + '] ' +
|
|
358
|
+
$i18next.t('functions:NOT_START_WITH_FORBIDDEN_WORDS_LABEL', {lng: lng}),
|
|
359
|
+
pattern: /^(?!kubernetes\.io\/)(?!k8s\.io\/)(?!nuclio\.io\/)/
|
|
360
|
+
},
|
|
361
|
+
generateRule.length({
|
|
362
|
+
max: lengths.function.label.key
|
|
363
|
+
}))
|
|
364
|
+
},
|
|
365
|
+
annotation: {
|
|
366
|
+
key: commonRules.prefixedQualifiedName.concat(
|
|
367
|
+
{
|
|
368
|
+
name: 'prefixNotStart',
|
|
369
|
+
label: '[' + $i18next.t('functions:PREFIX', {lng: lng}) + '] ' +
|
|
370
|
+
$i18next.t('functions:NOT_START_WITH_FORBIDDEN_WORDS_ANNOTATION', {lng: lng}),
|
|
371
|
+
pattern: /^(?!kubernetes\.io\/)(?!k8s\.io\/)/
|
|
372
|
+
})
|
|
364
373
|
},
|
|
365
374
|
itemPath: [generateRule.length({ max: lengths.function.itemPath })],
|
|
366
375
|
subscriptionQoS: [
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
name: $i18next.t('functions:TOOLTIP.ANNOTATION', { lng: lng })
|
|
39
39
|
});
|
|
40
40
|
ctrl.validationRules = {
|
|
41
|
-
key: ValidationService.getValidationRules('
|
|
41
|
+
key: ValidationService.getValidationRules('function.annotation.key', [
|
|
42
42
|
{
|
|
43
43
|
name: 'uniqueness',
|
|
44
44
|
label: $i18next.t('functions:UNIQUENESS', { lng: lng }),
|