@skyux/tabs 5.5.0-alpha.0 → 5.6.0
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/bundles/skyux-tabs.umd.js +510 -510
- package/documentation.json +111 -111
- package/esm2015/lib/modules/sectioned-form/sectioned-form-section.component.js +2 -2
- package/esm2015/lib/modules/sectioned-form/sectioned-form-section.component.js.map +1 -1
- package/esm2015/lib/modules/sectioned-form/sectioned-form.component.js +3 -3
- package/esm2015/lib/modules/sectioned-form/sectioned-form.component.js.map +1 -1
- package/esm2015/lib/modules/sectioned-form/sectioned-form.module.js +4 -4
- package/esm2015/lib/modules/sectioned-form/sectioned-form.module.js.map +1 -1
- package/esm2015/lib/modules/shared/sky-tabs-resources.module.js +1 -1
- package/esm2015/lib/modules/shared/sky-tabs-resources.module.js.map +1 -1
- package/esm2015/lib/modules/tabs/tab.component.js.map +1 -1
- package/esm2015/lib/modules/tabs/tabs.module.js.map +1 -1
- package/esm2015/lib/modules/tabs/tabset-nav-button.component.js +4 -4
- package/esm2015/lib/modules/tabs/tabset-nav-button.component.js.map +1 -1
- package/esm2015/lib/modules/tabs/tabset-permalink.service.js.map +1 -1
- package/esm2015/lib/modules/tabs/tabset.component.js +1 -1
- package/esm2015/lib/modules/tabs/tabset.component.js.map +1 -1
- package/esm2015/lib/modules/tabs/tabset.service.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tab-media-query.service.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tab.component.js +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tab.component.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset-adapter.service.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset-group.component.js +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset-group.component.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset.component.js +3 -3
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset.component.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset.module.js +4 -4
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset.module.js.map +1 -1
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset.service.js +5 -5
- package/esm2015/lib/modules/vertical-tabset/vertical-tabset.service.js.map +1 -1
- package/esm2015/testing/tabs/tabset-fixture.js.map +1 -1
- package/fesm2015/skyux-tabs-testing.js.map +1 -1
- package/fesm2015/skyux-tabs.js +472 -472
- package/fesm2015/skyux-tabs.js.map +1 -1
- package/lib/modules/sectioned-form/sectioned-form-section.component.d.ts +2 -2
- package/lib/modules/sectioned-form/sectioned-form.component.d.ts +1 -1
- package/lib/modules/tabs/tabset.component.d.ts +2 -2
- package/lib/modules/vertical-tabset/vertical-tab.component.d.ts +1 -1
- package/lib/modules/vertical-tabset/vertical-tabset.component.d.ts +1 -1
- package/package.json +22 -8
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/
|
|
3
|
-
typeof define === 'function' && define.amd ? define('@skyux/tabs', ['exports', '@angular/
|
|
4
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.skyux = global.skyux || {}, global.skyux.tabs = {}), global.ng.
|
|
5
|
-
})(this, (function (exports,
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/common'), require('@angular/core'), require('@skyux/forms'), require('@skyux/theme'), require('@skyux/core'), require('@skyux/indicators'), require('@skyux/i18n'), require('rxjs'), require('rxjs/operators'), require('@skyux/animations'), require('@angular/animations'), require('@angular/router'), require('@skyux/popovers')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define('@skyux/tabs', ['exports', '@angular/common', '@angular/core', '@skyux/forms', '@skyux/theme', '@skyux/core', '@skyux/indicators', '@skyux/i18n', 'rxjs', 'rxjs/operators', '@skyux/animations', '@angular/animations', '@angular/router', '@skyux/popovers'], factory) :
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.skyux = global.skyux || {}, global.skyux.tabs = {}), global.ng.common, global.ng.core, global.forms, global.i8, global.i1, global.i4, global.i3, global.rxjs, global.rxjs.operators, global.animations, global.ng.animations, global.ng.router, global.i4$1));
|
|
5
|
+
})(this, (function (exports, i2, i0, forms, i8, i1, i4, i3, rxjs, operators, animations, animations$1, i1$1, i4$1) { 'use strict';
|
|
6
6
|
|
|
7
7
|
function _interopNamespace(e) {
|
|
8
8
|
if (e && e.__esModule) return e;
|
|
@@ -22,15 +22,189 @@
|
|
|
22
22
|
return Object.freeze(n);
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
|
|
26
25
|
var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
|
|
26
|
+
var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
|
|
27
|
+
var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
|
|
27
28
|
var i1__namespace = /*#__PURE__*/_interopNamespace(i1);
|
|
28
29
|
var i4__namespace = /*#__PURE__*/_interopNamespace(i4);
|
|
29
|
-
var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
|
|
30
30
|
var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
|
|
31
31
|
var i1__namespace$1 = /*#__PURE__*/_interopNamespace(i1$1);
|
|
32
32
|
var i4__namespace$1 = /*#__PURE__*/_interopNamespace(i4$1);
|
|
33
33
|
|
|
34
|
+
/**
|
|
35
|
+
* NOTICE: DO NOT MODIFY THIS FILE!
|
|
36
|
+
* The contents of this file were automatically generated by
|
|
37
|
+
* the 'ng generate @skyux/i18n:lib-resources-module modules/shared/sky-tabs' schematic.
|
|
38
|
+
* To update this file, simply rerun the command.
|
|
39
|
+
*/
|
|
40
|
+
var RESOURCES = {
|
|
41
|
+
'EN-US': {
|
|
42
|
+
skyux_tab_add: { message: 'Add tab' },
|
|
43
|
+
skyux_tab_close: { message: 'Close {0} tab' },
|
|
44
|
+
skyux_tabs_navigator_next: { message: 'Next' },
|
|
45
|
+
skyux_tabs_navigator_previous: { message: 'Previous' },
|
|
46
|
+
skyux_tab_open: { message: 'Open tab' },
|
|
47
|
+
skyux_vertical_tabs_show_tabs_text: { message: 'Tab list' },
|
|
48
|
+
},
|
|
49
|
+
};
|
|
50
|
+
var SkyTabsResourcesProvider = /** @class */ (function () {
|
|
51
|
+
function SkyTabsResourcesProvider() {
|
|
52
|
+
}
|
|
53
|
+
SkyTabsResourcesProvider.prototype.getString = function (localeInfo, name) {
|
|
54
|
+
return i3.getLibStringForLocale(RESOURCES, localeInfo.locale, name);
|
|
55
|
+
};
|
|
56
|
+
return SkyTabsResourcesProvider;
|
|
57
|
+
}());
|
|
58
|
+
/**
|
|
59
|
+
* Import into any component library module that needs to use resource strings.
|
|
60
|
+
*/
|
|
61
|
+
var SkyTabsResourcesModule = /** @class */ (function () {
|
|
62
|
+
function SkyTabsResourcesModule() {
|
|
63
|
+
}
|
|
64
|
+
return SkyTabsResourcesModule;
|
|
65
|
+
}());
|
|
66
|
+
SkyTabsResourcesModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
|
|
67
|
+
SkyTabsResourcesModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, exports: [i3.SkyI18nModule] });
|
|
68
|
+
SkyTabsResourcesModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, providers: [
|
|
69
|
+
{
|
|
70
|
+
provide: i3.SKY_LIB_RESOURCES_PROVIDERS,
|
|
71
|
+
useClass: SkyTabsResourcesProvider,
|
|
72
|
+
multi: true,
|
|
73
|
+
},
|
|
74
|
+
], imports: [i3.SkyI18nModule] });
|
|
75
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, decorators: [{
|
|
76
|
+
type: i0.NgModule,
|
|
77
|
+
args: [{
|
|
78
|
+
exports: [i3.SkyI18nModule],
|
|
79
|
+
providers: [
|
|
80
|
+
{
|
|
81
|
+
provide: i3.SKY_LIB_RESOURCES_PROVIDERS,
|
|
82
|
+
useClass: SkyTabsResourcesProvider,
|
|
83
|
+
multi: true,
|
|
84
|
+
},
|
|
85
|
+
],
|
|
86
|
+
}]
|
|
87
|
+
}] });
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* @internal
|
|
91
|
+
*/
|
|
92
|
+
var SkyVerticalTabMediaQueryService = /** @class */ (function () {
|
|
93
|
+
function SkyVerticalTabMediaQueryService() {
|
|
94
|
+
this.currentSubject = new rxjs.BehaviorSubject(this.current);
|
|
95
|
+
this._current = i1.SkyMediaBreakpoints.xs;
|
|
96
|
+
this.currentSubject.next(this._current);
|
|
97
|
+
}
|
|
98
|
+
Object.defineProperty(SkyVerticalTabMediaQueryService.prototype, "current", {
|
|
99
|
+
get: function () {
|
|
100
|
+
return this._current;
|
|
101
|
+
},
|
|
102
|
+
enumerable: false,
|
|
103
|
+
configurable: true
|
|
104
|
+
});
|
|
105
|
+
SkyVerticalTabMediaQueryService.prototype.subscribe = function (listener) {
|
|
106
|
+
return this.currentSubject.subscribe({
|
|
107
|
+
next: function (breakpoints) {
|
|
108
|
+
listener(breakpoints);
|
|
109
|
+
},
|
|
110
|
+
});
|
|
111
|
+
};
|
|
112
|
+
SkyVerticalTabMediaQueryService.prototype.setBreakpointForWidth = function (width) {
|
|
113
|
+
var breakpoint;
|
|
114
|
+
if (this.isWidthWithinBreakpiont(width, i1.SkyMediaBreakpoints.xs)) {
|
|
115
|
+
breakpoint = i1.SkyMediaBreakpoints.xs;
|
|
116
|
+
}
|
|
117
|
+
else if (this.isWidthWithinBreakpiont(width, i1.SkyMediaBreakpoints.sm)) {
|
|
118
|
+
breakpoint = i1.SkyMediaBreakpoints.sm;
|
|
119
|
+
}
|
|
120
|
+
else if (this.isWidthWithinBreakpiont(width, i1.SkyMediaBreakpoints.md)) {
|
|
121
|
+
breakpoint = i1.SkyMediaBreakpoints.md;
|
|
122
|
+
}
|
|
123
|
+
else {
|
|
124
|
+
breakpoint = i1.SkyMediaBreakpoints.lg;
|
|
125
|
+
}
|
|
126
|
+
this._current = breakpoint;
|
|
127
|
+
this.currentSubject.next(this._current);
|
|
128
|
+
};
|
|
129
|
+
SkyVerticalTabMediaQueryService.prototype.isWidthWithinBreakpiont = function (width, breakpoint) {
|
|
130
|
+
var xsBreakpointMaxPixels = 767;
|
|
131
|
+
var smBreakpointMinPixels = 768;
|
|
132
|
+
var smBreakpointMaxPixels = 991;
|
|
133
|
+
var mdBreakpointMinPixels = 992;
|
|
134
|
+
var mdBreakpointMaxPixels = 1199;
|
|
135
|
+
var lgBreakpointMinPixels = 1200;
|
|
136
|
+
switch (breakpoint) {
|
|
137
|
+
case i1.SkyMediaBreakpoints.xs: {
|
|
138
|
+
return width <= xsBreakpointMaxPixels;
|
|
139
|
+
}
|
|
140
|
+
case i1.SkyMediaBreakpoints.sm: {
|
|
141
|
+
return width >= smBreakpointMinPixels && width <= smBreakpointMaxPixels;
|
|
142
|
+
}
|
|
143
|
+
case i1.SkyMediaBreakpoints.md: {
|
|
144
|
+
return width >= mdBreakpointMinPixels && width <= mdBreakpointMaxPixels;
|
|
145
|
+
}
|
|
146
|
+
default: {
|
|
147
|
+
return width >= lgBreakpointMinPixels;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
};
|
|
151
|
+
SkyVerticalTabMediaQueryService.prototype.destroy = function () {
|
|
152
|
+
this.currentSubject.complete();
|
|
153
|
+
};
|
|
154
|
+
return SkyVerticalTabMediaQueryService;
|
|
155
|
+
}());
|
|
156
|
+
SkyVerticalTabMediaQueryService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabMediaQueryService, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
157
|
+
SkyVerticalTabMediaQueryService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabMediaQueryService });
|
|
158
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabMediaQueryService, decorators: [{
|
|
159
|
+
type: i0.Injectable
|
|
160
|
+
}], ctorParameters: function () { return []; } });
|
|
161
|
+
|
|
162
|
+
var SkyVerticalTabsetAdapterService = /** @class */ (function () {
|
|
163
|
+
function SkyVerticalTabsetAdapterService(rendererFactory) {
|
|
164
|
+
this.rendererFactory = rendererFactory;
|
|
165
|
+
this.renderer = this.rendererFactory.createRenderer(undefined, undefined);
|
|
166
|
+
}
|
|
167
|
+
SkyVerticalTabsetAdapterService.prototype.getWidth = function (elementRef) {
|
|
168
|
+
return elementRef.nativeElement.clientWidth;
|
|
169
|
+
};
|
|
170
|
+
SkyVerticalTabsetAdapterService.prototype.scrollToContentTop = function (element) {
|
|
171
|
+
element.nativeElement.scrollTop = 0;
|
|
172
|
+
};
|
|
173
|
+
SkyVerticalTabsetAdapterService.prototype.setResponsiveClass = function (element, breakpoint) {
|
|
174
|
+
var nativeEl = element.nativeElement;
|
|
175
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-xs');
|
|
176
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-sm');
|
|
177
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-md');
|
|
178
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-lg');
|
|
179
|
+
var newClass;
|
|
180
|
+
switch (breakpoint) {
|
|
181
|
+
case i1.SkyMediaBreakpoints.xs: {
|
|
182
|
+
newClass = 'sky-responsive-container-xs';
|
|
183
|
+
break;
|
|
184
|
+
}
|
|
185
|
+
case i1.SkyMediaBreakpoints.sm: {
|
|
186
|
+
newClass = 'sky-responsive-container-sm';
|
|
187
|
+
break;
|
|
188
|
+
}
|
|
189
|
+
case i1.SkyMediaBreakpoints.md: {
|
|
190
|
+
newClass = 'sky-responsive-container-md';
|
|
191
|
+
break;
|
|
192
|
+
}
|
|
193
|
+
default: {
|
|
194
|
+
newClass = 'sky-responsive-container-lg';
|
|
195
|
+
break;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
this.renderer.addClass(nativeEl, newClass);
|
|
199
|
+
};
|
|
200
|
+
return SkyVerticalTabsetAdapterService;
|
|
201
|
+
}());
|
|
202
|
+
SkyVerticalTabsetAdapterService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetAdapterService, deps: [{ token: i0__namespace.RendererFactory2 }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
203
|
+
SkyVerticalTabsetAdapterService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetAdapterService });
|
|
204
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetAdapterService, decorators: [{
|
|
205
|
+
type: i0.Injectable
|
|
206
|
+
}], ctorParameters: function () { return [{ type: i0__namespace.RendererFactory2 }]; } });
|
|
207
|
+
|
|
34
208
|
var VISIBLE_STATE = 'shown';
|
|
35
209
|
var HIDDEN_STATE = 'void';
|
|
36
210
|
/**
|
|
@@ -205,289 +379,56 @@
|
|
|
205
379
|
type: i0.Injectable
|
|
206
380
|
}], ctorParameters: function () { return [{ type: i1__namespace.SkyMediaQueryService }]; } });
|
|
207
381
|
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
function SkySectionedFormComponent(tabService, changeRef) {
|
|
213
|
-
this.tabService = tabService;
|
|
382
|
+
var nextId$2 = 0;
|
|
383
|
+
var SkyVerticalTabComponent = /** @class */ (function () {
|
|
384
|
+
function SkyVerticalTabComponent(adapterService, changeRef, tabsetService, verticalTabMediaQueryService) {
|
|
385
|
+
this.adapterService = adapterService;
|
|
214
386
|
this.changeRef = changeRef;
|
|
387
|
+
this.tabsetService = tabsetService;
|
|
388
|
+
this.verticalTabMediaQueryService = verticalTabMediaQueryService;
|
|
215
389
|
/**
|
|
216
|
-
* Indicates whether the
|
|
217
|
-
* displays content without moving around elements in the content container.
|
|
218
|
-
* @default false
|
|
390
|
+
* Indicates whether the tab is active when the tabset loads.
|
|
219
391
|
*/
|
|
220
|
-
this.
|
|
392
|
+
this.active = false;
|
|
221
393
|
/**
|
|
222
|
-
*
|
|
223
|
-
* section. The index is based on the section's position when the form loads.
|
|
394
|
+
* Indicates whether to disable the tab.
|
|
224
395
|
*/
|
|
225
|
-
this.
|
|
396
|
+
this.disabled = false;
|
|
397
|
+
/**
|
|
398
|
+
* Indicates whether to indicate that the tab has an error.
|
|
399
|
+
* @internal This is used for sectioned forms and is not currently a supported design for pure vertical tabs.
|
|
400
|
+
*/
|
|
401
|
+
this.errorIndicator = false;
|
|
402
|
+
/**
|
|
403
|
+
* Specifies an ID for the tab.
|
|
404
|
+
* @deprecated Now that the vertical tabs provide aria labels automatically, this input is no longer necessary.
|
|
405
|
+
*/
|
|
406
|
+
this.tabId = "sky-vertical-tab-" + ++nextId$2;
|
|
226
407
|
this.isMobile = false;
|
|
408
|
+
this._contentRendered = false;
|
|
409
|
+
this._mobileSubscription = new rxjs.Subject();
|
|
227
410
|
this._ngUnsubscribe = new rxjs.Subject();
|
|
411
|
+
this._showTabRightArrow = false;
|
|
228
412
|
}
|
|
229
|
-
Object.defineProperty(
|
|
413
|
+
Object.defineProperty(SkyVerticalTabComponent.prototype, "ariaRole", {
|
|
414
|
+
/**
|
|
415
|
+
* Specifies an ARIA role for the vertical tab
|
|
416
|
+
* [to support accessibility](https://developer.blackbaud.com/skyux/learn/accessibility)
|
|
417
|
+
* by indicating how the tab functions and what it controls. For information about how
|
|
418
|
+
* an ARIA role indicates what an item represents on a web page, see the
|
|
419
|
+
* [WAI-ARIA roles model](https://www.w3.org/WAI/PF/aria/roles).
|
|
420
|
+
* @default "tab"
|
|
421
|
+
* @deprecated Any other value than `tab` could lead to a poor user experience for users with assistive technology.
|
|
422
|
+
* In the next major version, this property will be automatically set to `tab`.
|
|
423
|
+
*/
|
|
230
424
|
get: function () {
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
this.tabService.maintainTabContent = this.maintainSectionContent;
|
|
239
|
-
this.tabService.indexChanged
|
|
240
|
-
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
241
|
-
.subscribe(function (index) {
|
|
242
|
-
_this.indexChanged.emit(index);
|
|
243
|
-
_this.changeRef.markForCheck();
|
|
244
|
-
});
|
|
245
|
-
this.tabService.switchingMobile
|
|
246
|
-
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
247
|
-
.subscribe(function (mobile) {
|
|
248
|
-
_this.isMobile = mobile;
|
|
249
|
-
_this.changeRef.markForCheck();
|
|
250
|
-
});
|
|
251
|
-
if (this.tabService.isMobile()) {
|
|
252
|
-
this.isMobile = true;
|
|
253
|
-
this.tabService.animationContentVisibleState = VISIBLE_STATE;
|
|
254
|
-
this.changeRef.markForCheck();
|
|
255
|
-
}
|
|
256
|
-
};
|
|
257
|
-
SkySectionedFormComponent.prototype.ngAfterViewChecked = function () {
|
|
258
|
-
this.tabService.content = this.content;
|
|
259
|
-
this.tabService.updateContent();
|
|
260
|
-
};
|
|
261
|
-
SkySectionedFormComponent.prototype.ngOnDestroy = function () {
|
|
262
|
-
this._ngUnsubscribe.next();
|
|
263
|
-
this._ngUnsubscribe.complete();
|
|
264
|
-
};
|
|
265
|
-
SkySectionedFormComponent.prototype.tabsVisible = function () {
|
|
266
|
-
this.changeRef.markForCheck();
|
|
267
|
-
return this.tabService.tabsVisible();
|
|
268
|
-
};
|
|
269
|
-
SkySectionedFormComponent.prototype.showTabs = function () {
|
|
270
|
-
this.tabService.showTabs();
|
|
271
|
-
this.changeRef.markForCheck();
|
|
272
|
-
};
|
|
273
|
-
return SkySectionedFormComponent;
|
|
274
|
-
}());
|
|
275
|
-
SkySectionedFormComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormComponent, deps: [{ token: SkyVerticalTabsetService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
276
|
-
SkySectionedFormComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SkySectionedFormComponent, selector: "sky-sectioned-form", inputs: { maintainSectionContent: "maintainSectionContent" }, outputs: { indexChanged: "indexChanged" }, providers: [SkyVerticalTabsetService], viewQueries: [{ propertyName: "content", first: true, predicate: ["skySectionSideContent"], descendants: true }], ngImport: i0__namespace, template: "<div\n aria-orientation=\"vertical\"\n class=\"sky-sectioned-form\"\n [attr.role]=\"ariaRole\"\n (window:resize)=\"tabService.updateContent()\"\n>\n <div\n *ngIf=\"maintainSectionContent || tabsVisible()\"\n class=\"sky-sectioned-form-tabs\"\n [ngClass]=\"{ 'sky-sectioned-form-tabs-hidden': !tabsVisible() }\"\n [@tabEnter]=\"tabService.animationTabsVisibleState\"\n >\n <ng-content></ng-content>\n </div>\n <div\n *ngIf=\"maintainSectionContent || tabService.contentVisible()\"\n class=\"sky-sectioned-form-content\"\n [ngClass]=\"{\n 'sky-sectioned-form-content-hidden': !tabService.contentVisible()\n }\"\n [@contentEnter]=\"tabService.animationContentVisibleState\"\n #skySectionSideContent\n ></div>\n</div>\n", styles: [":host .sky-sectioned-form{display:block;max-height:none}:host .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}:host-context(.sky-responsive-container-xs) .sky-sectioned-form,:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:block;max-height:none}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-content,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}@media (min-width: 768px){:host .sky-sectioned-form{display:flex;max-height:100%}:host .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}}:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:flex;max-height:100%}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}.sky-sectioned-form-tabs-hidden{display:none}.sky-sectioned-form-content-hidden{display:none}:host-context(.sky-theme-modern) .sky-sectioned-form-content{margin:15px}:host-context(.sky-theme-modern) .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){:host-context(.sky-theme-modern) :host .sky-sectioned-form-content{margin:20px 30px}}:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}.sky-theme-modern .sky-sectioned-form-content{margin:15px}.sky-theme-modern .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){.sky-theme-modern :host .sky-sectioned-form-content{margin:20px 30px}}.sky-theme-modern :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}\n"], directives: [{ type: i2__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], animations: [
|
|
277
|
-
animations.trigger('tabEnter', [
|
|
278
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
279
|
-
animations.style({ transform: 'translate(-100%)' }),
|
|
280
|
-
animations.animate('150ms ease-in'),
|
|
281
|
-
]),
|
|
282
|
-
]),
|
|
283
|
-
animations.trigger('contentEnter', [
|
|
284
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
285
|
-
animations.style({ transform: 'translate(100%)' }),
|
|
286
|
-
animations.animate('150ms ease-in'),
|
|
287
|
-
]),
|
|
288
|
-
]),
|
|
289
|
-
], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
290
|
-
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormComponent, decorators: [{
|
|
291
|
-
type: i0.Component,
|
|
292
|
-
args: [{
|
|
293
|
-
selector: 'sky-sectioned-form',
|
|
294
|
-
template: "<div\n aria-orientation=\"vertical\"\n class=\"sky-sectioned-form\"\n [attr.role]=\"ariaRole\"\n (window:resize)=\"tabService.updateContent()\"\n>\n <div\n *ngIf=\"maintainSectionContent || tabsVisible()\"\n class=\"sky-sectioned-form-tabs\"\n [ngClass]=\"{ 'sky-sectioned-form-tabs-hidden': !tabsVisible() }\"\n [@tabEnter]=\"tabService.animationTabsVisibleState\"\n >\n <ng-content></ng-content>\n </div>\n <div\n *ngIf=\"maintainSectionContent || tabService.contentVisible()\"\n class=\"sky-sectioned-form-content\"\n [ngClass]=\"{\n 'sky-sectioned-form-content-hidden': !tabService.contentVisible()\n }\"\n [@contentEnter]=\"tabService.animationContentVisibleState\"\n #skySectionSideContent\n ></div>\n</div>\n",
|
|
295
|
-
styles: [":host .sky-sectioned-form{display:block;max-height:none}:host .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}:host-context(.sky-responsive-container-xs) .sky-sectioned-form,:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:block;max-height:none}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-content,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}@media (min-width: 768px){:host .sky-sectioned-form{display:flex;max-height:100%}:host .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}}:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:flex;max-height:100%}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}.sky-sectioned-form-tabs-hidden{display:none}.sky-sectioned-form-content-hidden{display:none}:host-context(.sky-theme-modern) .sky-sectioned-form-content{margin:15px}:host-context(.sky-theme-modern) .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){:host-context(.sky-theme-modern) :host .sky-sectioned-form-content{margin:20px 30px}}:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}.sky-theme-modern .sky-sectioned-form-content{margin:15px}.sky-theme-modern .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){.sky-theme-modern :host .sky-sectioned-form-content{margin:20px 30px}}.sky-theme-modern :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}\n"],
|
|
296
|
-
providers: [SkyVerticalTabsetService],
|
|
297
|
-
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
298
|
-
animations: [
|
|
299
|
-
animations.trigger('tabEnter', [
|
|
300
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
301
|
-
animations.style({ transform: 'translate(-100%)' }),
|
|
302
|
-
animations.animate('150ms ease-in'),
|
|
303
|
-
]),
|
|
304
|
-
]),
|
|
305
|
-
animations.trigger('contentEnter', [
|
|
306
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
307
|
-
animations.style({ transform: 'translate(100%)' }),
|
|
308
|
-
animations.animate('150ms ease-in'),
|
|
309
|
-
]),
|
|
310
|
-
]),
|
|
311
|
-
],
|
|
312
|
-
}]
|
|
313
|
-
}], ctorParameters: function () { return [{ type: SkyVerticalTabsetService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { maintainSectionContent: [{
|
|
314
|
-
type: i0.Input
|
|
315
|
-
}], indexChanged: [{
|
|
316
|
-
type: i0.Output
|
|
317
|
-
}], content: [{
|
|
318
|
-
type: i0.ViewChild,
|
|
319
|
-
args: ['skySectionSideContent']
|
|
320
|
-
}] } });
|
|
321
|
-
|
|
322
|
-
/**
|
|
323
|
-
* @internal
|
|
324
|
-
*/
|
|
325
|
-
var SkyVerticalTabMediaQueryService = /** @class */ (function () {
|
|
326
|
-
function SkyVerticalTabMediaQueryService() {
|
|
327
|
-
this.currentSubject = new rxjs.BehaviorSubject(this.current);
|
|
328
|
-
this._current = i1.SkyMediaBreakpoints.xs;
|
|
329
|
-
this.currentSubject.next(this._current);
|
|
330
|
-
}
|
|
331
|
-
Object.defineProperty(SkyVerticalTabMediaQueryService.prototype, "current", {
|
|
332
|
-
get: function () {
|
|
333
|
-
return this._current;
|
|
334
|
-
},
|
|
335
|
-
enumerable: false,
|
|
336
|
-
configurable: true
|
|
337
|
-
});
|
|
338
|
-
SkyVerticalTabMediaQueryService.prototype.subscribe = function (listener) {
|
|
339
|
-
return this.currentSubject.subscribe({
|
|
340
|
-
next: function (breakpoints) {
|
|
341
|
-
listener(breakpoints);
|
|
342
|
-
},
|
|
343
|
-
});
|
|
344
|
-
};
|
|
345
|
-
SkyVerticalTabMediaQueryService.prototype.setBreakpointForWidth = function (width) {
|
|
346
|
-
var breakpoint;
|
|
347
|
-
if (this.isWidthWithinBreakpiont(width, i1.SkyMediaBreakpoints.xs)) {
|
|
348
|
-
breakpoint = i1.SkyMediaBreakpoints.xs;
|
|
349
|
-
}
|
|
350
|
-
else if (this.isWidthWithinBreakpiont(width, i1.SkyMediaBreakpoints.sm)) {
|
|
351
|
-
breakpoint = i1.SkyMediaBreakpoints.sm;
|
|
352
|
-
}
|
|
353
|
-
else if (this.isWidthWithinBreakpiont(width, i1.SkyMediaBreakpoints.md)) {
|
|
354
|
-
breakpoint = i1.SkyMediaBreakpoints.md;
|
|
355
|
-
}
|
|
356
|
-
else {
|
|
357
|
-
breakpoint = i1.SkyMediaBreakpoints.lg;
|
|
358
|
-
}
|
|
359
|
-
this._current = breakpoint;
|
|
360
|
-
this.currentSubject.next(this._current);
|
|
361
|
-
};
|
|
362
|
-
SkyVerticalTabMediaQueryService.prototype.isWidthWithinBreakpiont = function (width, breakpoint) {
|
|
363
|
-
var xsBreakpointMaxPixels = 767;
|
|
364
|
-
var smBreakpointMinPixels = 768;
|
|
365
|
-
var smBreakpointMaxPixels = 991;
|
|
366
|
-
var mdBreakpointMinPixels = 992;
|
|
367
|
-
var mdBreakpointMaxPixels = 1199;
|
|
368
|
-
var lgBreakpointMinPixels = 1200;
|
|
369
|
-
switch (breakpoint) {
|
|
370
|
-
case i1.SkyMediaBreakpoints.xs: {
|
|
371
|
-
return width <= xsBreakpointMaxPixels;
|
|
372
|
-
}
|
|
373
|
-
case i1.SkyMediaBreakpoints.sm: {
|
|
374
|
-
return width >= smBreakpointMinPixels && width <= smBreakpointMaxPixels;
|
|
375
|
-
}
|
|
376
|
-
case i1.SkyMediaBreakpoints.md: {
|
|
377
|
-
return width >= mdBreakpointMinPixels && width <= mdBreakpointMaxPixels;
|
|
378
|
-
}
|
|
379
|
-
default: {
|
|
380
|
-
return width >= lgBreakpointMinPixels;
|
|
381
|
-
}
|
|
382
|
-
}
|
|
383
|
-
};
|
|
384
|
-
SkyVerticalTabMediaQueryService.prototype.destroy = function () {
|
|
385
|
-
this.currentSubject.complete();
|
|
386
|
-
};
|
|
387
|
-
return SkyVerticalTabMediaQueryService;
|
|
388
|
-
}());
|
|
389
|
-
SkyVerticalTabMediaQueryService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabMediaQueryService, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
390
|
-
SkyVerticalTabMediaQueryService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabMediaQueryService });
|
|
391
|
-
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabMediaQueryService, decorators: [{
|
|
392
|
-
type: i0.Injectable
|
|
393
|
-
}], ctorParameters: function () { return []; } });
|
|
394
|
-
|
|
395
|
-
var SkyVerticalTabsetAdapterService = /** @class */ (function () {
|
|
396
|
-
function SkyVerticalTabsetAdapterService(rendererFactory) {
|
|
397
|
-
this.rendererFactory = rendererFactory;
|
|
398
|
-
this.renderer = this.rendererFactory.createRenderer(undefined, undefined);
|
|
399
|
-
}
|
|
400
|
-
SkyVerticalTabsetAdapterService.prototype.getWidth = function (elementRef) {
|
|
401
|
-
return elementRef.nativeElement.clientWidth;
|
|
402
|
-
};
|
|
403
|
-
SkyVerticalTabsetAdapterService.prototype.scrollToContentTop = function (element) {
|
|
404
|
-
element.nativeElement.scrollTop = 0;
|
|
405
|
-
};
|
|
406
|
-
SkyVerticalTabsetAdapterService.prototype.setResponsiveClass = function (element, breakpoint) {
|
|
407
|
-
var nativeEl = element.nativeElement;
|
|
408
|
-
this.renderer.removeClass(nativeEl, 'sky-responsive-container-xs');
|
|
409
|
-
this.renderer.removeClass(nativeEl, 'sky-responsive-container-sm');
|
|
410
|
-
this.renderer.removeClass(nativeEl, 'sky-responsive-container-md');
|
|
411
|
-
this.renderer.removeClass(nativeEl, 'sky-responsive-container-lg');
|
|
412
|
-
var newClass;
|
|
413
|
-
switch (breakpoint) {
|
|
414
|
-
case i1.SkyMediaBreakpoints.xs: {
|
|
415
|
-
newClass = 'sky-responsive-container-xs';
|
|
416
|
-
break;
|
|
417
|
-
}
|
|
418
|
-
case i1.SkyMediaBreakpoints.sm: {
|
|
419
|
-
newClass = 'sky-responsive-container-sm';
|
|
420
|
-
break;
|
|
421
|
-
}
|
|
422
|
-
case i1.SkyMediaBreakpoints.md: {
|
|
423
|
-
newClass = 'sky-responsive-container-md';
|
|
424
|
-
break;
|
|
425
|
-
}
|
|
426
|
-
default: {
|
|
427
|
-
newClass = 'sky-responsive-container-lg';
|
|
428
|
-
break;
|
|
429
|
-
}
|
|
430
|
-
}
|
|
431
|
-
this.renderer.addClass(nativeEl, newClass);
|
|
432
|
-
};
|
|
433
|
-
return SkyVerticalTabsetAdapterService;
|
|
434
|
-
}());
|
|
435
|
-
SkyVerticalTabsetAdapterService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetAdapterService, deps: [{ token: i0__namespace.RendererFactory2 }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
436
|
-
SkyVerticalTabsetAdapterService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetAdapterService });
|
|
437
|
-
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetAdapterService, decorators: [{
|
|
438
|
-
type: i0.Injectable
|
|
439
|
-
}], ctorParameters: function () { return [{ type: i0__namespace.RendererFactory2 }]; } });
|
|
440
|
-
|
|
441
|
-
var nextId$2 = 0;
|
|
442
|
-
var SkyVerticalTabComponent = /** @class */ (function () {
|
|
443
|
-
function SkyVerticalTabComponent(adapterService, changeRef, tabsetService, verticalTabMediaQueryService) {
|
|
444
|
-
this.adapterService = adapterService;
|
|
445
|
-
this.changeRef = changeRef;
|
|
446
|
-
this.tabsetService = tabsetService;
|
|
447
|
-
this.verticalTabMediaQueryService = verticalTabMediaQueryService;
|
|
448
|
-
/**
|
|
449
|
-
* Indicates whether the tab is active when the tabset loads.
|
|
450
|
-
*/
|
|
451
|
-
this.active = false;
|
|
452
|
-
/**
|
|
453
|
-
* Indicates whether to disable the tab.
|
|
454
|
-
*/
|
|
455
|
-
this.disabled = false;
|
|
456
|
-
/**
|
|
457
|
-
* Indicates whether to indicate that the tab has an error.
|
|
458
|
-
* @internal This is used for sectioned forms and is not currently a supported design for pure vertical tabs.
|
|
459
|
-
*/
|
|
460
|
-
this.errorIndicator = false;
|
|
461
|
-
/**
|
|
462
|
-
* Specifies an ID for the tab.
|
|
463
|
-
* @deprecated Now that the vertical tabs provide aria labels automatically, this input is no longer necessary.
|
|
464
|
-
*/
|
|
465
|
-
this.tabId = "sky-vertical-tab-" + ++nextId$2;
|
|
466
|
-
this.isMobile = false;
|
|
467
|
-
this._contentRendered = false;
|
|
468
|
-
this._mobileSubscription = new rxjs.Subject();
|
|
469
|
-
this._ngUnsubscribe = new rxjs.Subject();
|
|
470
|
-
this._showTabRightArrow = false;
|
|
471
|
-
}
|
|
472
|
-
Object.defineProperty(SkyVerticalTabComponent.prototype, "ariaRole", {
|
|
473
|
-
/**
|
|
474
|
-
* Specifies an ARIA role for the vertical tab
|
|
475
|
-
* [to support accessibility](https://developer.blackbaud.com/skyux/learn/accessibility)
|
|
476
|
-
* by indicating how the tab functions and what it controls. For information about how
|
|
477
|
-
* an ARIA role indicates what an item represents on a web page, see the
|
|
478
|
-
* [WAI-ARIA roles model](https://www.w3.org/WAI/PF/aria/roles).
|
|
479
|
-
* @default "tab"
|
|
480
|
-
* @deprecated Any other value than `tab` could lead to a poor user experience for users with assistive technology.
|
|
481
|
-
* In the next major version, this property will be automatically set to `tab`.
|
|
482
|
-
*/
|
|
483
|
-
get: function () {
|
|
484
|
-
if (this.isMobile) {
|
|
485
|
-
return undefined;
|
|
486
|
-
}
|
|
487
|
-
return this._ariaRole || 'tab';
|
|
488
|
-
},
|
|
489
|
-
set: function (value) {
|
|
490
|
-
this._ariaRole = value;
|
|
425
|
+
if (this.isMobile) {
|
|
426
|
+
return undefined;
|
|
427
|
+
}
|
|
428
|
+
return this._ariaRole || 'tab';
|
|
429
|
+
},
|
|
430
|
+
set: function (value) {
|
|
431
|
+
this._ariaRole = value;
|
|
491
432
|
},
|
|
492
433
|
enumerable: false,
|
|
493
434
|
configurable: true
|
|
@@ -642,152 +583,90 @@
|
|
|
642
583
|
args: ['window:resize']
|
|
643
584
|
}] } });
|
|
644
585
|
|
|
645
|
-
var
|
|
646
|
-
function
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
this.
|
|
586
|
+
var SkyVerticalTabsetGroupComponent = /** @class */ (function () {
|
|
587
|
+
function SkyVerticalTabsetGroupComponent(tabService, changeRef) {
|
|
588
|
+
var _this = this;
|
|
589
|
+
this.tabService = tabService;
|
|
590
|
+
this.changeRef = changeRef;
|
|
591
|
+
this.ngUnsubscribe = new rxjs.Subject();
|
|
592
|
+
this.openBeforeTabsHidden = false;
|
|
593
|
+
this._open = false;
|
|
594
|
+
this.tabClicked = function () {
|
|
595
|
+
_this.changeRef.markForCheck();
|
|
596
|
+
};
|
|
597
|
+
this.tabsHidden = function () {
|
|
598
|
+
// this fixes an animation bug with ngIf when the parent component goes from visible to hidden
|
|
599
|
+
_this.openBeforeTabsHidden = _this.open;
|
|
600
|
+
_this.open = false;
|
|
601
|
+
_this.changeRef.markForCheck();
|
|
602
|
+
};
|
|
603
|
+
this.tabsShown = function () {
|
|
604
|
+
_this.open = _this.openBeforeTabsHidden;
|
|
605
|
+
_this.changeRef.markForCheck();
|
|
606
|
+
};
|
|
607
|
+
}
|
|
608
|
+
Object.defineProperty(SkyVerticalTabsetGroupComponent.prototype, "open", {
|
|
609
|
+
get: function () {
|
|
610
|
+
return !this.disabled && this._open;
|
|
611
|
+
},
|
|
651
612
|
/**
|
|
652
|
-
*
|
|
613
|
+
* Indicates whether the collapsible group is expanded.
|
|
614
|
+
* @default false
|
|
653
615
|
*/
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
this.
|
|
616
|
+
set: function (value) {
|
|
617
|
+
this._open = value;
|
|
618
|
+
},
|
|
619
|
+
enumerable: false,
|
|
620
|
+
configurable: true
|
|
621
|
+
});
|
|
622
|
+
SkyVerticalTabsetGroupComponent.prototype.ngOnInit = function () {
|
|
623
|
+
this.tabService.hidingTabs
|
|
624
|
+
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
625
|
+
.subscribe(this.tabsHidden);
|
|
626
|
+
this.tabService.showingTabs
|
|
627
|
+
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
628
|
+
.subscribe(this.tabsShown);
|
|
629
|
+
this.tabService.tabClicked
|
|
630
|
+
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
631
|
+
.subscribe(this.tabClicked);
|
|
662
632
|
};
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
*/
|
|
667
|
-
SkySectionedFormService.prototype.requiredFieldChanged = function (isRequired) {
|
|
668
|
-
this.requiredChange.next(isRequired);
|
|
633
|
+
SkyVerticalTabsetGroupComponent.prototype.ngOnDestroy = function () {
|
|
634
|
+
this.ngUnsubscribe.next();
|
|
635
|
+
this.ngUnsubscribe.complete();
|
|
669
636
|
};
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
type: i0.Injectable
|
|
676
|
-
}] });
|
|
677
|
-
|
|
678
|
-
var nextId$1 = 0;
|
|
679
|
-
/**
|
|
680
|
-
* Creates an individual form to display as a section within the sectioned form.
|
|
681
|
-
*/
|
|
682
|
-
var SkySectionedFormSectionComponent = /** @class */ (function () {
|
|
683
|
-
function SkySectionedFormSectionComponent(sectionedFormService, tabsetService, changeRef) {
|
|
684
|
-
this.sectionedFormService = sectionedFormService;
|
|
685
|
-
this.tabsetService = tabsetService;
|
|
686
|
-
this.changeRef = changeRef;
|
|
687
|
-
this.sectionTabId = "sky-sectioned-form-tab-" + ++nextId$1;
|
|
688
|
-
this.sectionContentId = "sky-sectioned-form-section-" + ++nextId$1;
|
|
689
|
-
/**
|
|
690
|
-
* Indicates whether the section is active when the form loads.
|
|
691
|
-
* @default false
|
|
692
|
-
*/
|
|
693
|
-
this.active = false;
|
|
694
|
-
this._ngUnsubscribe = new rxjs.Subject();
|
|
695
|
-
}
|
|
696
|
-
SkySectionedFormSectionComponent.prototype.ngOnInit = function () {
|
|
697
|
-
var _this = this;
|
|
698
|
-
this.changeRef.detectChanges();
|
|
699
|
-
this.tabsetService.switchingMobile.subscribe(function (mobile) {
|
|
700
|
-
_this.changeRef.detectChanges();
|
|
701
|
-
});
|
|
702
|
-
this.sectionedFormService.requiredChange
|
|
703
|
-
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
704
|
-
.subscribe(function (required) { return (_this.fieldRequired = required); });
|
|
705
|
-
this.sectionedFormService.invalidChange
|
|
706
|
-
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
707
|
-
.subscribe(function (invalid) { return (_this.fieldInvalid = invalid); });
|
|
637
|
+
SkyVerticalTabsetGroupComponent.prototype.toggleMenuOpen = function () {
|
|
638
|
+
if (!this.disabled) {
|
|
639
|
+
this.open = !this.open;
|
|
640
|
+
}
|
|
641
|
+
this.changeRef.markForCheck();
|
|
708
642
|
};
|
|
709
|
-
|
|
710
|
-
this.
|
|
711
|
-
this._ngUnsubscribe.complete();
|
|
643
|
+
SkyVerticalTabsetGroupComponent.prototype.subMenuOpen = function () {
|
|
644
|
+
return this.tabs && this.tabs.find(function (t) { return t.active; }) !== undefined;
|
|
712
645
|
};
|
|
713
|
-
return
|
|
646
|
+
return SkyVerticalTabsetGroupComponent;
|
|
714
647
|
}());
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type:
|
|
648
|
+
SkyVerticalTabsetGroupComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetGroupComponent, deps: [{ token: SkyVerticalTabsetService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
649
|
+
SkyVerticalTabsetGroupComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SkyVerticalTabsetGroupComponent, selector: "sky-vertical-tabset-group", inputs: { disabled: "disabled", groupHeading: "groupHeading", open: "open" }, queries: [{ propertyName: "tabs", predicate: SkyVerticalTabComponent }], ngImport: i0__namespace, template: "<div class=\"sky-vertical-tabset-group\">\n <!-- [ngClass] includes font classes for both modern and default styles -->\n <div\n class=\"sky-vertical-tabset-group-header\"\n [ngClass]=\"{\n 'sky-vertical-tabset-group-header-sub-open sky-font-emphasized sky-emphasized':\n subMenuOpen(),\n 'sky-font-deemphasized': disabled,\n 'sky-deemphasized': disabled,\n 'sky-vertical-tabset-disabled': disabled\n }\"\n [tabIndex]=\"-1\"\n >\n <button\n class=\"sky-padding-even-default\"\n type=\"button\"\n skyId\n [attr.aria-controls]=\"groupContent.id\"\n [attr.aria-expanded]=\"open\"\n (click)=\"toggleMenuOpen()\"\n #groupHeadingButton\n >\n {{ groupHeading }}\n <sky-expansion-indicator\n class=\"sky-vertical-tabset-group-expansion-indicator\"\n [direction]=\"open ? 'up' : 'down'\"\n >\n </sky-expansion-indicator>\n </button>\n </div>\n <div\n class=\"sky-vertical-tabset-group-content\"\n role=\"region\"\n skyId\n [attr.labelledby]=\"groupHeadingButton.id\"\n [@skyAnimationSlide]=\"open ? 'down' : 'up'\"\n #groupContent\n >\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [".sky-vertical-tabset-group{border-bottom:1px solid #e2e3e4;margin:5px 0 5px 5px}.sky-vertical-tabset-group-header button{cursor:pointer;display:flex;justify-content:space-between;border:none;width:100%;text-align:left;background:none}.sky-vertical-tabset-group-content{overflow:hidden;border-top:1px solid #e2e3e4}:host ::ng-deep .sky-vertical-tabset-group-expansion-indicator>button{font-size:14px!important}.sky-vertical-tabset-disabled{cursor:not-allowed;pointer-events:none}:host-context(.sky-theme-modern) .sky-vertical-tabset-group{border:none;margin:10px 0}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-content{border:none;padding-left:25px}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-header{position:relative}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}.sky-theme-modern .sky-vertical-tabset-group{border:none;margin:10px 0}.sky-theme-modern .sky-vertical-tabset-group-content{border:none;padding-left:25px}.sky-theme-modern .sky-vertical-tabset-group-header{position:relative}.sky-theme-modern .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}\n"], components: [{ type: i4__namespace.λ15, selector: "sky-expansion-indicator", inputs: ["direction"] }], directives: [{ type: i2__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i1__namespace.λ2, selector: "[skyId]", exportAs: ["skyId"] }], animations: [animations.skyAnimationSlide], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
650
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetGroupComponent, decorators: [{
|
|
718
651
|
type: i0.Component,
|
|
719
652
|
args: [{
|
|
720
|
-
selector: 'sky-
|
|
721
|
-
template: "<sky-vertical-
|
|
722
|
-
|
|
723
|
-
|
|
653
|
+
selector: 'sky-vertical-tabset-group',
|
|
654
|
+
template: "<div class=\"sky-vertical-tabset-group\">\n <!-- [ngClass] includes font classes for both modern and default styles -->\n <div\n class=\"sky-vertical-tabset-group-header\"\n [ngClass]=\"{\n 'sky-vertical-tabset-group-header-sub-open sky-font-emphasized sky-emphasized':\n subMenuOpen(),\n 'sky-font-deemphasized': disabled,\n 'sky-deemphasized': disabled,\n 'sky-vertical-tabset-disabled': disabled\n }\"\n [tabIndex]=\"-1\"\n >\n <button\n class=\"sky-padding-even-default\"\n type=\"button\"\n skyId\n [attr.aria-controls]=\"groupContent.id\"\n [attr.aria-expanded]=\"open\"\n (click)=\"toggleMenuOpen()\"\n #groupHeadingButton\n >\n {{ groupHeading }}\n <sky-expansion-indicator\n class=\"sky-vertical-tabset-group-expansion-indicator\"\n [direction]=\"open ? 'up' : 'down'\"\n >\n </sky-expansion-indicator>\n </button>\n </div>\n <div\n class=\"sky-vertical-tabset-group-content\"\n role=\"region\"\n skyId\n [attr.labelledby]=\"groupHeadingButton.id\"\n [@skyAnimationSlide]=\"open ? 'down' : 'up'\"\n #groupContent\n >\n <ng-content></ng-content>\n </div>\n</div>\n",
|
|
655
|
+
styles: [".sky-vertical-tabset-group{border-bottom:1px solid #e2e3e4;margin:5px 0 5px 5px}.sky-vertical-tabset-group-header button{cursor:pointer;display:flex;justify-content:space-between;border:none;width:100%;text-align:left;background:none}.sky-vertical-tabset-group-content{overflow:hidden;border-top:1px solid #e2e3e4}:host ::ng-deep .sky-vertical-tabset-group-expansion-indicator>button{font-size:14px!important}.sky-vertical-tabset-disabled{cursor:not-allowed;pointer-events:none}:host-context(.sky-theme-modern) .sky-vertical-tabset-group{border:none;margin:10px 0}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-content{border:none;padding-left:25px}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-header{position:relative}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}.sky-theme-modern .sky-vertical-tabset-group{border:none;margin:10px 0}.sky-theme-modern .sky-vertical-tabset-group-content{border:none;padding-left:25px}.sky-theme-modern .sky-vertical-tabset-group-header{position:relative}.sky-theme-modern .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}\n"],
|
|
656
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
657
|
+
animations: [animations.skyAnimationSlide],
|
|
724
658
|
}]
|
|
725
|
-
}], ctorParameters: function () { return [{ type:
|
|
659
|
+
}], ctorParameters: function () { return [{ type: SkyVerticalTabsetService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { disabled: [{
|
|
726
660
|
type: i0.Input
|
|
727
|
-
}],
|
|
661
|
+
}], groupHeading: [{
|
|
728
662
|
type: i0.Input
|
|
729
|
-
}],
|
|
663
|
+
}], open: [{
|
|
730
664
|
type: i0.Input
|
|
731
|
-
}],
|
|
732
|
-
type: i0.
|
|
665
|
+
}], tabs: [{
|
|
666
|
+
type: i0.ContentChildren,
|
|
733
667
|
args: [SkyVerticalTabComponent]
|
|
734
668
|
}] } });
|
|
735
669
|
|
|
736
|
-
/**
|
|
737
|
-
* NOTICE: DO NOT MODIFY THIS FILE!
|
|
738
|
-
* The contents of this file were automatically generated by
|
|
739
|
-
* the 'ng generate @skyux/i18n:lib-resources-module modules/shared/sky-tabs' schematic.
|
|
740
|
-
* To update this file, simply rerun the command.
|
|
741
|
-
*/
|
|
742
|
-
var RESOURCES = {
|
|
743
|
-
'EN-US': {
|
|
744
|
-
skyux_tab_add: { message: 'Add tab' },
|
|
745
|
-
skyux_tab_close: { message: 'Close {0} tab' },
|
|
746
|
-
skyux_tabs_navigator_next: { message: 'Next' },
|
|
747
|
-
skyux_tabs_navigator_previous: { message: 'Previous' },
|
|
748
|
-
skyux_tab_open: { message: 'Open tab' },
|
|
749
|
-
skyux_vertical_tabs_show_tabs_text: { message: 'Tab list' },
|
|
750
|
-
},
|
|
751
|
-
};
|
|
752
|
-
var SkyTabsResourcesProvider = /** @class */ (function () {
|
|
753
|
-
function SkyTabsResourcesProvider() {
|
|
754
|
-
}
|
|
755
|
-
SkyTabsResourcesProvider.prototype.getString = function (localeInfo, name) {
|
|
756
|
-
return i3.getLibStringForLocale(RESOURCES, localeInfo.locale, name);
|
|
757
|
-
};
|
|
758
|
-
return SkyTabsResourcesProvider;
|
|
759
|
-
}());
|
|
760
|
-
/**
|
|
761
|
-
* Import into any component library module that needs to use resource strings.
|
|
762
|
-
*/
|
|
763
|
-
var SkyTabsResourcesModule = /** @class */ (function () {
|
|
764
|
-
function SkyTabsResourcesModule() {
|
|
765
|
-
}
|
|
766
|
-
return SkyTabsResourcesModule;
|
|
767
|
-
}());
|
|
768
|
-
SkyTabsResourcesModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
|
|
769
|
-
SkyTabsResourcesModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, exports: [i3.SkyI18nModule] });
|
|
770
|
-
SkyTabsResourcesModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, providers: [
|
|
771
|
-
{
|
|
772
|
-
provide: i3.SKY_LIB_RESOURCES_PROVIDERS,
|
|
773
|
-
useClass: SkyTabsResourcesProvider,
|
|
774
|
-
multi: true,
|
|
775
|
-
},
|
|
776
|
-
], imports: [i3.SkyI18nModule] });
|
|
777
|
-
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyTabsResourcesModule, decorators: [{
|
|
778
|
-
type: i0.NgModule,
|
|
779
|
-
args: [{
|
|
780
|
-
exports: [i3.SkyI18nModule],
|
|
781
|
-
providers: [
|
|
782
|
-
{
|
|
783
|
-
provide: i3.SKY_LIB_RESOURCES_PROVIDERS,
|
|
784
|
-
useClass: SkyTabsResourcesProvider,
|
|
785
|
-
multi: true,
|
|
786
|
-
},
|
|
787
|
-
],
|
|
788
|
-
}]
|
|
789
|
-
}] });
|
|
790
|
-
|
|
791
670
|
var SkyVerticalTabsetComponent = /** @class */ (function () {
|
|
792
671
|
function SkyVerticalTabsetComponent(adapterService, tabService, resources, changeRef) {
|
|
793
672
|
this.adapterService = adapterService;
|
|
@@ -879,16 +758,16 @@
|
|
|
879
758
|
}());
|
|
880
759
|
SkyVerticalTabsetComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetComponent, deps: [{ token: SkyVerticalTabsetAdapterService }, { token: SkyVerticalTabsetService }, { token: i3__namespace.SkyLibResourcesService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
881
760
|
SkyVerticalTabsetComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SkyVerticalTabsetComponent, selector: "sky-vertical-tabset", inputs: { showTabsText: "showTabsText", ariaLabel: "ariaLabel", ariaLabelledBy: "ariaLabelledBy", ariaRole: "ariaRole", maintainTabContent: "maintainTabContent" }, outputs: { activeChange: "activeChange" }, providers: [SkyVerticalTabsetService], viewQueries: [{ propertyName: "tabGroups", first: true, predicate: ["groupContainerWrapper"], descendants: true }, { propertyName: "content", first: true, predicate: ["skySideContent"], descendants: true }, { propertyName: "contentWrapper", first: true, predicate: ["contentContainerWrapper"], descendants: true }], ngImport: i0__namespace, template: "<div class=\"sky-vertical-tabset\" (window:resize)=\"tabService.updateContent()\">\n <div\n *ngIf=\"maintainTabContent || tabService.tabsVisible()\"\n aria-orientation=\"vertical\"\n class=\"sky-vertical-tabset-group-container\"\n [ngClass]=\"{ 'sky-vertical-tabset-hidden': !tabService.tabsVisible() }\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.role]=\"ariaRole\"\n [@tabGroupEnter]=\"tabService.animationTabsVisibleState\"\n #groupContainerWrapper\n >\n <ng-content></ng-content>\n </div>\n <div\n *ngIf=\"maintainTabContent || tabService.contentVisible()\"\n class=\"sky-vertical-tabset-content\"\n [ngClass]=\"{\n 'sky-vertical-tabset-content-hidden': !tabService.contentVisible()\n }\"\n [@contentEnter]=\"tabService.animationContentVisibleState\"\n #contentContainerWrapper\n >\n <div #skySideContent></div>\n <button\n *ngIf=\"!tabService.tabsVisible()\"\n (click)=\"tabService.showTabs()\"\n class=\"sky-btn sky-btn-primary sky-vertical-tabset-show-tabs-btn\"\n >\n <sky-icon icon=\"chevron-left\"></sky-icon>\n {{ showTabsText }}\n </button>\n </div>\n</div>\n", styles: [":host .sky-vertical-tabset{display:block;height:auto}:host .sky-vertical-tabset-group-container{border-right:none}:host-context(.sky-responsive-container-xs) .sky-vertical-tabset,:host-context(.sky-responsive-container-sm) .sky-vertical-tabset,:host-context(.sky-responsive-container-md) .sky-vertical-tabset,:host-context(.sky-responsive-container-lg) .sky-vertical-tabset{display:block;height:auto}:host-context(.sky-responsive-container-xs) .sky-vertical-tabset-group-container,:host-context(.sky-responsive-container-sm) .sky-vertical-tabset-group-container,:host-context(.sky-responsive-container-md) .sky-vertical-tabset-group-container,:host-context(.sky-responsive-container-lg) .sky-vertical-tabset-group-container{border-right:none}@media (min-width: 768px){:host .sky-vertical-tabset{display:flex;height:100%}:host .sky-vertical-tabset-group-container{border-right:1px solid #cdcfd2}}:host-context(.sky-responsive-container-sm) .sky-vertical-tabset,:host-context(.sky-responsive-container-md) .sky-vertical-tabset,:host-context(.sky-responsive-container-lg) .sky-vertical-tabset{display:flex;height:100%}:host-context(.sky-responsive-container-sm) .sky-vertical-tabset-group-container,:host-context(.sky-responsive-container-md) .sky-vertical-tabset-group-container,:host-context(.sky-responsive-container-lg) .sky-vertical-tabset-group-container{border-right:1px solid #cdcfd2}.sky-vertical-tabset-hidden{display:none}.sky-vertical-tabset-content{margin:10px 0 0 10px;flex-basis:75%;overflow-y:auto}.sky-vertical-tabset-content-hidden{display:none}.sky-vertical-tabset-show-tabs-btn{margin-top:10px}.sky-vertical-tabset-group-container{flex-basis:25%;overflow-y:auto}:host-context(sky-modal-content >) .sky-vertical-tabset{margin:-15px}:host-context(.sky-theme-modern) .sky-vertical-tabset-content{margin:15px}@media (min-width: 768px){:host-context(.sky-theme-modern) :host .sky-vertical-tabset-content{margin:20px 30px}:host-context(.sky-theme-modern) :host .sky-vertical-tabset-group-container{border-right:1px solid #d2d2d2}}:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-sm) .sky-vertical-tabset-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-md) .sky-vertical-tabset-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-lg) .sky-vertical-tabset-content{margin:20px 30px}:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-sm) .sky-vertical-tabset-group-container,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-md) .sky-vertical-tabset-group-container,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-lg) .sky-vertical-tabset-group-container{border-right:1px solid #d2d2d2}.sky-theme-modern .sky-vertical-tabset-content{margin:15px}@media (min-width: 768px){.sky-theme-modern :host .sky-vertical-tabset-content{margin:20px 30px}.sky-theme-modern :host .sky-vertical-tabset-group-container{border-right:1px solid #d2d2d2}}.sky-theme-modern :host-context(.sky-responsive-container-sm) .sky-vertical-tabset-content,.sky-theme-modern :host-context(.sky-responsive-container-md) .sky-vertical-tabset-content,.sky-theme-modern :host-context(.sky-responsive-container-lg) .sky-vertical-tabset-content{margin:20px 30px}.sky-theme-modern :host-context(.sky-responsive-container-sm) .sky-vertical-tabset-group-container,.sky-theme-modern :host-context(.sky-responsive-container-md) .sky-vertical-tabset-group-container,.sky-theme-modern :host-context(.sky-responsive-container-lg) .sky-vertical-tabset-group-container{border-right:1px solid #d2d2d2}\n"], components: [{ type: i4__namespace.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }], directives: [{ type: i2__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], animations: [
|
|
882
|
-
animations.trigger('tabGroupEnter', [
|
|
883
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
884
|
-
animations.style({ transform: 'translate(-100%)' }),
|
|
885
|
-
animations.animate('150ms ease-in'),
|
|
761
|
+
animations$1.trigger('tabGroupEnter', [
|
|
762
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
763
|
+
animations$1.style({ transform: 'translate(-100%)' }),
|
|
764
|
+
animations$1.animate('150ms ease-in'),
|
|
886
765
|
]),
|
|
887
766
|
]),
|
|
888
|
-
animations.trigger('contentEnter', [
|
|
889
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
890
|
-
animations.style({ transform: 'translate(100%)' }),
|
|
891
|
-
animations.animate('150ms ease-in'),
|
|
767
|
+
animations$1.trigger('contentEnter', [
|
|
768
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
769
|
+
animations$1.style({ transform: 'translate(100%)' }),
|
|
770
|
+
animations$1.animate('150ms ease-in'),
|
|
892
771
|
]),
|
|
893
772
|
]),
|
|
894
773
|
], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
@@ -901,16 +780,16 @@
|
|
|
901
780
|
providers: [SkyVerticalTabsetService],
|
|
902
781
|
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
903
782
|
animations: [
|
|
904
|
-
animations.trigger('tabGroupEnter', [
|
|
905
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
906
|
-
animations.style({ transform: 'translate(-100%)' }),
|
|
907
|
-
animations.animate('150ms ease-in'),
|
|
783
|
+
animations$1.trigger('tabGroupEnter', [
|
|
784
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
785
|
+
animations$1.style({ transform: 'translate(-100%)' }),
|
|
786
|
+
animations$1.animate('150ms ease-in'),
|
|
908
787
|
]),
|
|
909
788
|
]),
|
|
910
|
-
animations.trigger('contentEnter', [
|
|
911
|
-
animations.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
912
|
-
animations.style({ transform: 'translate(100%)' }),
|
|
913
|
-
animations.animate('150ms ease-in'),
|
|
789
|
+
animations$1.trigger('contentEnter', [
|
|
790
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
791
|
+
animations$1.style({ transform: 'translate(100%)' }),
|
|
792
|
+
animations$1.animate('150ms ease-in'),
|
|
914
793
|
]),
|
|
915
794
|
]),
|
|
916
795
|
],
|
|
@@ -938,90 +817,6 @@
|
|
|
938
817
|
args: ['contentContainerWrapper']
|
|
939
818
|
}] } });
|
|
940
819
|
|
|
941
|
-
var SkyVerticalTabsetGroupComponent = /** @class */ (function () {
|
|
942
|
-
function SkyVerticalTabsetGroupComponent(tabService, changeRef) {
|
|
943
|
-
var _this = this;
|
|
944
|
-
this.tabService = tabService;
|
|
945
|
-
this.changeRef = changeRef;
|
|
946
|
-
this.ngUnsubscribe = new rxjs.Subject();
|
|
947
|
-
this.openBeforeTabsHidden = false;
|
|
948
|
-
this._open = false;
|
|
949
|
-
this.tabClicked = function () {
|
|
950
|
-
_this.changeRef.markForCheck();
|
|
951
|
-
};
|
|
952
|
-
this.tabsHidden = function () {
|
|
953
|
-
// this fixes an animation bug with ngIf when the parent component goes from visible to hidden
|
|
954
|
-
_this.openBeforeTabsHidden = _this.open;
|
|
955
|
-
_this.open = false;
|
|
956
|
-
_this.changeRef.markForCheck();
|
|
957
|
-
};
|
|
958
|
-
this.tabsShown = function () {
|
|
959
|
-
_this.open = _this.openBeforeTabsHidden;
|
|
960
|
-
_this.changeRef.markForCheck();
|
|
961
|
-
};
|
|
962
|
-
}
|
|
963
|
-
Object.defineProperty(SkyVerticalTabsetGroupComponent.prototype, "open", {
|
|
964
|
-
get: function () {
|
|
965
|
-
return !this.disabled && this._open;
|
|
966
|
-
},
|
|
967
|
-
/**
|
|
968
|
-
* Indicates whether the collapsible group is expanded.
|
|
969
|
-
* @default false
|
|
970
|
-
*/
|
|
971
|
-
set: function (value) {
|
|
972
|
-
this._open = value;
|
|
973
|
-
},
|
|
974
|
-
enumerable: false,
|
|
975
|
-
configurable: true
|
|
976
|
-
});
|
|
977
|
-
SkyVerticalTabsetGroupComponent.prototype.ngOnInit = function () {
|
|
978
|
-
this.tabService.hidingTabs
|
|
979
|
-
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
980
|
-
.subscribe(this.tabsHidden);
|
|
981
|
-
this.tabService.showingTabs
|
|
982
|
-
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
983
|
-
.subscribe(this.tabsShown);
|
|
984
|
-
this.tabService.tabClicked
|
|
985
|
-
.pipe(operators.takeUntil(this.ngUnsubscribe))
|
|
986
|
-
.subscribe(this.tabClicked);
|
|
987
|
-
};
|
|
988
|
-
SkyVerticalTabsetGroupComponent.prototype.ngOnDestroy = function () {
|
|
989
|
-
this.ngUnsubscribe.next();
|
|
990
|
-
this.ngUnsubscribe.complete();
|
|
991
|
-
};
|
|
992
|
-
SkyVerticalTabsetGroupComponent.prototype.toggleMenuOpen = function () {
|
|
993
|
-
if (!this.disabled) {
|
|
994
|
-
this.open = !this.open;
|
|
995
|
-
}
|
|
996
|
-
this.changeRef.markForCheck();
|
|
997
|
-
};
|
|
998
|
-
SkyVerticalTabsetGroupComponent.prototype.subMenuOpen = function () {
|
|
999
|
-
return this.tabs && this.tabs.find(function (t) { return t.active; }) !== undefined;
|
|
1000
|
-
};
|
|
1001
|
-
return SkyVerticalTabsetGroupComponent;
|
|
1002
|
-
}());
|
|
1003
|
-
SkyVerticalTabsetGroupComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetGroupComponent, deps: [{ token: SkyVerticalTabsetService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
1004
|
-
SkyVerticalTabsetGroupComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SkyVerticalTabsetGroupComponent, selector: "sky-vertical-tabset-group", inputs: { disabled: "disabled", groupHeading: "groupHeading", open: "open" }, queries: [{ propertyName: "tabs", predicate: SkyVerticalTabComponent }], ngImport: i0__namespace, template: "<div class=\"sky-vertical-tabset-group\">\n <!-- [ngClass] includes font classes for both modern and default styles -->\n <div\n class=\"sky-vertical-tabset-group-header\"\n [ngClass]=\"{\n 'sky-vertical-tabset-group-header-sub-open sky-font-emphasized sky-emphasized':\n subMenuOpen(),\n 'sky-font-deemphasized': disabled,\n 'sky-deemphasized': disabled,\n 'sky-vertical-tabset-disabled': disabled\n }\"\n [tabIndex]=\"-1\"\n >\n <button\n class=\"sky-padding-even-default\"\n type=\"button\"\n skyId\n [attr.aria-controls]=\"groupContent.id\"\n [attr.aria-expanded]=\"open\"\n (click)=\"toggleMenuOpen()\"\n #groupHeadingButton\n >\n {{ groupHeading }}\n <sky-expansion-indicator\n class=\"sky-vertical-tabset-group-expansion-indicator\"\n [direction]=\"open ? 'up' : 'down'\"\n >\n </sky-expansion-indicator>\n </button>\n </div>\n <div\n class=\"sky-vertical-tabset-group-content\"\n role=\"region\"\n skyId\n [attr.labelledby]=\"groupHeadingButton.id\"\n [@skyAnimationSlide]=\"open ? 'down' : 'up'\"\n #groupContent\n >\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [".sky-vertical-tabset-group{border-bottom:1px solid #e2e3e4;margin:5px 0 5px 5px}.sky-vertical-tabset-group-header button{cursor:pointer;display:flex;justify-content:space-between;border:none;width:100%;text-align:left;background:none}.sky-vertical-tabset-group-content{overflow:hidden;border-top:1px solid #e2e3e4}:host ::ng-deep .sky-vertical-tabset-group-expansion-indicator>button{font-size:14px!important}.sky-vertical-tabset-disabled{cursor:not-allowed;pointer-events:none}:host-context(.sky-theme-modern) .sky-vertical-tabset-group{border:none;margin:10px 0}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-content{border:none;padding-left:25px}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-header{position:relative}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}.sky-theme-modern .sky-vertical-tabset-group{border:none;margin:10px 0}.sky-theme-modern .sky-vertical-tabset-group-content{border:none;padding-left:25px}.sky-theme-modern .sky-vertical-tabset-group-header{position:relative}.sky-theme-modern .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}\n"], components: [{ type: i4__namespace.λ15, selector: "sky-expansion-indicator", inputs: ["direction"] }], directives: [{ type: i2__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i1__namespace.λ2, selector: "[skyId]", exportAs: ["skyId"] }], animations: [animations$1.skyAnimationSlide], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
1005
|
-
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkyVerticalTabsetGroupComponent, decorators: [{
|
|
1006
|
-
type: i0.Component,
|
|
1007
|
-
args: [{
|
|
1008
|
-
selector: 'sky-vertical-tabset-group',
|
|
1009
|
-
template: "<div class=\"sky-vertical-tabset-group\">\n <!-- [ngClass] includes font classes for both modern and default styles -->\n <div\n class=\"sky-vertical-tabset-group-header\"\n [ngClass]=\"{\n 'sky-vertical-tabset-group-header-sub-open sky-font-emphasized sky-emphasized':\n subMenuOpen(),\n 'sky-font-deemphasized': disabled,\n 'sky-deemphasized': disabled,\n 'sky-vertical-tabset-disabled': disabled\n }\"\n [tabIndex]=\"-1\"\n >\n <button\n class=\"sky-padding-even-default\"\n type=\"button\"\n skyId\n [attr.aria-controls]=\"groupContent.id\"\n [attr.aria-expanded]=\"open\"\n (click)=\"toggleMenuOpen()\"\n #groupHeadingButton\n >\n {{ groupHeading }}\n <sky-expansion-indicator\n class=\"sky-vertical-tabset-group-expansion-indicator\"\n [direction]=\"open ? 'up' : 'down'\"\n >\n </sky-expansion-indicator>\n </button>\n </div>\n <div\n class=\"sky-vertical-tabset-group-content\"\n role=\"region\"\n skyId\n [attr.labelledby]=\"groupHeadingButton.id\"\n [@skyAnimationSlide]=\"open ? 'down' : 'up'\"\n #groupContent\n >\n <ng-content></ng-content>\n </div>\n</div>\n",
|
|
1010
|
-
styles: [".sky-vertical-tabset-group{border-bottom:1px solid #e2e3e4;margin:5px 0 5px 5px}.sky-vertical-tabset-group-header button{cursor:pointer;display:flex;justify-content:space-between;border:none;width:100%;text-align:left;background:none}.sky-vertical-tabset-group-content{overflow:hidden;border-top:1px solid #e2e3e4}:host ::ng-deep .sky-vertical-tabset-group-expansion-indicator>button{font-size:14px!important}.sky-vertical-tabset-disabled{cursor:not-allowed;pointer-events:none}:host-context(.sky-theme-modern) .sky-vertical-tabset-group{border:none;margin:10px 0}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-content{border:none;padding-left:25px}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-header{position:relative}:host-context(.sky-theme-modern) .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}.sky-theme-modern .sky-vertical-tabset-group{border:none;margin:10px 0}.sky-theme-modern .sky-vertical-tabset-group-content{border:none;padding-left:25px}.sky-theme-modern .sky-vertical-tabset-group-header{position:relative}.sky-theme-modern .sky-vertical-tabset-group-expansion-indicator{position:absolute;top:6px;right:5px}\n"],
|
|
1011
|
-
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
1012
|
-
animations: [animations$1.skyAnimationSlide],
|
|
1013
|
-
}]
|
|
1014
|
-
}], ctorParameters: function () { return [{ type: SkyVerticalTabsetService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { disabled: [{
|
|
1015
|
-
type: i0.Input
|
|
1016
|
-
}], groupHeading: [{
|
|
1017
|
-
type: i0.Input
|
|
1018
|
-
}], open: [{
|
|
1019
|
-
type: i0.Input
|
|
1020
|
-
}], tabs: [{
|
|
1021
|
-
type: i0.ContentChildren,
|
|
1022
|
-
args: [SkyVerticalTabComponent]
|
|
1023
|
-
}] } });
|
|
1024
|
-
|
|
1025
820
|
var SkyVerticalTabsetModule = /** @class */ (function () {
|
|
1026
821
|
function SkyVerticalTabsetModule() {
|
|
1027
822
|
}
|
|
@@ -1074,6 +869,211 @@
|
|
|
1074
869
|
}]
|
|
1075
870
|
}] });
|
|
1076
871
|
|
|
872
|
+
var SkySectionedFormService = /** @class */ (function () {
|
|
873
|
+
function SkySectionedFormService() {
|
|
874
|
+
/**
|
|
875
|
+
* @internal
|
|
876
|
+
*/
|
|
877
|
+
this.invalidChange = new rxjs.BehaviorSubject(undefined);
|
|
878
|
+
/**
|
|
879
|
+
* @internal
|
|
880
|
+
*/
|
|
881
|
+
this.requiredChange = new rxjs.BehaviorSubject(undefined);
|
|
882
|
+
}
|
|
883
|
+
/**
|
|
884
|
+
* Sets the current section's invalid state based on the `isInvalid` parameter.
|
|
885
|
+
* This method is used within a `sky-sectioned-form-section` element.
|
|
886
|
+
*/
|
|
887
|
+
SkySectionedFormService.prototype.invalidFieldChanged = function (isInvalid) {
|
|
888
|
+
this.invalidChange.next(isInvalid);
|
|
889
|
+
};
|
|
890
|
+
/**
|
|
891
|
+
* Sets the current section's required state based on the `isRequired` parameter.
|
|
892
|
+
* This method is used within a `sky-sectioned-form-section` element.
|
|
893
|
+
*/
|
|
894
|
+
SkySectionedFormService.prototype.requiredFieldChanged = function (isRequired) {
|
|
895
|
+
this.requiredChange.next(isRequired);
|
|
896
|
+
};
|
|
897
|
+
return SkySectionedFormService;
|
|
898
|
+
}());
|
|
899
|
+
SkySectionedFormService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormService, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
900
|
+
SkySectionedFormService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormService });
|
|
901
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormService, decorators: [{
|
|
902
|
+
type: i0.Injectable
|
|
903
|
+
}] });
|
|
904
|
+
|
|
905
|
+
var nextId$1 = 0;
|
|
906
|
+
/**
|
|
907
|
+
* Creates an individual form to display as a section within the sectioned form.
|
|
908
|
+
*/
|
|
909
|
+
var SkySectionedFormSectionComponent = /** @class */ (function () {
|
|
910
|
+
function SkySectionedFormSectionComponent(sectionedFormService, tabsetService, changeRef) {
|
|
911
|
+
this.sectionedFormService = sectionedFormService;
|
|
912
|
+
this.tabsetService = tabsetService;
|
|
913
|
+
this.changeRef = changeRef;
|
|
914
|
+
this.sectionTabId = "sky-sectioned-form-tab-" + ++nextId$1;
|
|
915
|
+
this.sectionContentId = "sky-sectioned-form-section-" + ++nextId$1;
|
|
916
|
+
/**
|
|
917
|
+
* Indicates whether the section is active when the form loads.
|
|
918
|
+
* @default false
|
|
919
|
+
*/
|
|
920
|
+
this.active = false;
|
|
921
|
+
this._ngUnsubscribe = new rxjs.Subject();
|
|
922
|
+
}
|
|
923
|
+
SkySectionedFormSectionComponent.prototype.ngOnInit = function () {
|
|
924
|
+
var _this = this;
|
|
925
|
+
this.changeRef.detectChanges();
|
|
926
|
+
this.tabsetService.switchingMobile.subscribe(function (mobile) {
|
|
927
|
+
_this.changeRef.detectChanges();
|
|
928
|
+
});
|
|
929
|
+
this.sectionedFormService.requiredChange
|
|
930
|
+
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
931
|
+
.subscribe(function (required) { return (_this.fieldRequired = required); });
|
|
932
|
+
this.sectionedFormService.invalidChange
|
|
933
|
+
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
934
|
+
.subscribe(function (invalid) { return (_this.fieldInvalid = invalid); });
|
|
935
|
+
};
|
|
936
|
+
SkySectionedFormSectionComponent.prototype.ngOnDestroy = function () {
|
|
937
|
+
this._ngUnsubscribe.next();
|
|
938
|
+
this._ngUnsubscribe.complete();
|
|
939
|
+
};
|
|
940
|
+
return SkySectionedFormSectionComponent;
|
|
941
|
+
}());
|
|
942
|
+
SkySectionedFormSectionComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormSectionComponent, deps: [{ token: SkySectionedFormService }, { token: SkyVerticalTabsetService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
943
|
+
SkySectionedFormSectionComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SkySectionedFormSectionComponent, selector: "sky-sectioned-form-section", inputs: { heading: "heading", itemCount: "itemCount", active: "active" }, providers: [SkySectionedFormService], viewQueries: [{ propertyName: "tab", first: true, predicate: SkyVerticalTabComponent, descendants: true }], ngImport: i0__namespace, template: "<sky-vertical-tab\n [active]=\"active\"\n [errorIndicator]=\"fieldInvalid\"\n [ngClass]=\"{\n 'sky-tab-field-required': fieldRequired\n }\"\n [showTabRightArrow]=\"true\"\n [tabHeaderCount]=\"itemCount\"\n [tabHeading]=\"heading\"\n [tabId]=\"sectionTabId\"\n>\n <ng-content></ng-content>\n</sky-vertical-tab>\n", styles: [":host .sky-tab-field-required ::ng-deep .sky-vertical-tab-heading:after{content:\"*\";color:#ef4044;padding-left:5px}\n"], components: [{ type: SkyVerticalTabComponent, selector: "sky-vertical-tab", inputs: ["active", "ariaControls", "ariaRole", "disabled", "errorIndicator", "tabHeaderCount", "tabHeading", "showTabRightArrow", "tabId"] }], directives: [{ type: i2__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
944
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormSectionComponent, decorators: [{
|
|
945
|
+
type: i0.Component,
|
|
946
|
+
args: [{
|
|
947
|
+
selector: 'sky-sectioned-form-section',
|
|
948
|
+
template: "<sky-vertical-tab\n [active]=\"active\"\n [errorIndicator]=\"fieldInvalid\"\n [ngClass]=\"{\n 'sky-tab-field-required': fieldRequired\n }\"\n [showTabRightArrow]=\"true\"\n [tabHeaderCount]=\"itemCount\"\n [tabHeading]=\"heading\"\n [tabId]=\"sectionTabId\"\n>\n <ng-content></ng-content>\n</sky-vertical-tab>\n",
|
|
949
|
+
providers: [SkySectionedFormService],
|
|
950
|
+
styles: [":host .sky-tab-field-required ::ng-deep .sky-vertical-tab-heading:after{content:\"*\";color:#ef4044;padding-left:5px}\n"],
|
|
951
|
+
}]
|
|
952
|
+
}], ctorParameters: function () { return [{ type: SkySectionedFormService }, { type: SkyVerticalTabsetService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { heading: [{
|
|
953
|
+
type: i0.Input
|
|
954
|
+
}], itemCount: [{
|
|
955
|
+
type: i0.Input
|
|
956
|
+
}], active: [{
|
|
957
|
+
type: i0.Input
|
|
958
|
+
}], tab: [{
|
|
959
|
+
type: i0.ViewChild,
|
|
960
|
+
args: [SkyVerticalTabComponent]
|
|
961
|
+
}] } });
|
|
962
|
+
|
|
963
|
+
/**
|
|
964
|
+
* Creates a container for the sectioned forms.
|
|
965
|
+
*/
|
|
966
|
+
var SkySectionedFormComponent = /** @class */ (function () {
|
|
967
|
+
function SkySectionedFormComponent(tabService, changeRef) {
|
|
968
|
+
this.tabService = tabService;
|
|
969
|
+
this.changeRef = changeRef;
|
|
970
|
+
/**
|
|
971
|
+
* Indicates whether the sectioned form loads section content during initialization so that it
|
|
972
|
+
* displays content without moving around elements in the content container.
|
|
973
|
+
* @default false
|
|
974
|
+
*/
|
|
975
|
+
this.maintainSectionContent = false;
|
|
976
|
+
/**
|
|
977
|
+
* Fires when the active tab changes and emits the index of the active
|
|
978
|
+
* section. The index is based on the section's position when the form loads.
|
|
979
|
+
*/
|
|
980
|
+
this.indexChanged = new i0.EventEmitter();
|
|
981
|
+
this.isMobile = false;
|
|
982
|
+
this._ngUnsubscribe = new rxjs.Subject();
|
|
983
|
+
}
|
|
984
|
+
Object.defineProperty(SkySectionedFormComponent.prototype, "ariaRole", {
|
|
985
|
+
get: function () {
|
|
986
|
+
return this.isMobile ? undefined : 'tablist';
|
|
987
|
+
},
|
|
988
|
+
enumerable: false,
|
|
989
|
+
configurable: true
|
|
990
|
+
});
|
|
991
|
+
SkySectionedFormComponent.prototype.ngOnInit = function () {
|
|
992
|
+
var _this = this;
|
|
993
|
+
this.tabService.maintainTabContent = this.maintainSectionContent;
|
|
994
|
+
this.tabService.indexChanged
|
|
995
|
+
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
996
|
+
.subscribe(function (index) {
|
|
997
|
+
_this.indexChanged.emit(index);
|
|
998
|
+
_this.changeRef.markForCheck();
|
|
999
|
+
});
|
|
1000
|
+
this.tabService.switchingMobile
|
|
1001
|
+
.pipe(operators.takeUntil(this._ngUnsubscribe))
|
|
1002
|
+
.subscribe(function (mobile) {
|
|
1003
|
+
_this.isMobile = mobile;
|
|
1004
|
+
_this.changeRef.markForCheck();
|
|
1005
|
+
});
|
|
1006
|
+
if (this.tabService.isMobile()) {
|
|
1007
|
+
this.isMobile = true;
|
|
1008
|
+
this.tabService.animationContentVisibleState = VISIBLE_STATE;
|
|
1009
|
+
this.changeRef.markForCheck();
|
|
1010
|
+
}
|
|
1011
|
+
};
|
|
1012
|
+
SkySectionedFormComponent.prototype.ngAfterViewChecked = function () {
|
|
1013
|
+
this.tabService.content = this.content;
|
|
1014
|
+
this.tabService.updateContent();
|
|
1015
|
+
};
|
|
1016
|
+
SkySectionedFormComponent.prototype.ngOnDestroy = function () {
|
|
1017
|
+
this._ngUnsubscribe.next();
|
|
1018
|
+
this._ngUnsubscribe.complete();
|
|
1019
|
+
};
|
|
1020
|
+
SkySectionedFormComponent.prototype.tabsVisible = function () {
|
|
1021
|
+
this.changeRef.markForCheck();
|
|
1022
|
+
return this.tabService.tabsVisible();
|
|
1023
|
+
};
|
|
1024
|
+
SkySectionedFormComponent.prototype.showTabs = function () {
|
|
1025
|
+
this.tabService.showTabs();
|
|
1026
|
+
this.changeRef.markForCheck();
|
|
1027
|
+
};
|
|
1028
|
+
return SkySectionedFormComponent;
|
|
1029
|
+
}());
|
|
1030
|
+
SkySectionedFormComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormComponent, deps: [{ token: SkyVerticalTabsetService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
1031
|
+
SkySectionedFormComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SkySectionedFormComponent, selector: "sky-sectioned-form", inputs: { maintainSectionContent: "maintainSectionContent" }, outputs: { indexChanged: "indexChanged" }, providers: [SkyVerticalTabsetService], viewQueries: [{ propertyName: "content", first: true, predicate: ["skySectionSideContent"], descendants: true }], ngImport: i0__namespace, template: "<div\n aria-orientation=\"vertical\"\n class=\"sky-sectioned-form\"\n [attr.role]=\"ariaRole\"\n (window:resize)=\"tabService.updateContent()\"\n>\n <div\n *ngIf=\"maintainSectionContent || tabsVisible()\"\n class=\"sky-sectioned-form-tabs\"\n [ngClass]=\"{ 'sky-sectioned-form-tabs-hidden': !tabsVisible() }\"\n [@tabEnter]=\"tabService.animationTabsVisibleState\"\n >\n <ng-content></ng-content>\n </div>\n <div\n *ngIf=\"maintainSectionContent || tabService.contentVisible()\"\n class=\"sky-sectioned-form-content\"\n [ngClass]=\"{\n 'sky-sectioned-form-content-hidden': !tabService.contentVisible()\n }\"\n [@contentEnter]=\"tabService.animationContentVisibleState\"\n #skySectionSideContent\n ></div>\n</div>\n", styles: [":host .sky-sectioned-form{display:block;max-height:none}:host .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}:host-context(.sky-responsive-container-xs) .sky-sectioned-form,:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:block;max-height:none}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-content,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}@media (min-width: 768px){:host .sky-sectioned-form{display:flex;max-height:100%}:host .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}}:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:flex;max-height:100%}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}.sky-sectioned-form-tabs-hidden{display:none}.sky-sectioned-form-content-hidden{display:none}:host-context(.sky-theme-modern) .sky-sectioned-form-content{margin:15px}:host-context(.sky-theme-modern) .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){:host-context(.sky-theme-modern) :host .sky-sectioned-form-content{margin:20px 30px}}:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}.sky-theme-modern .sky-sectioned-form-content{margin:15px}.sky-theme-modern .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){.sky-theme-modern :host .sky-sectioned-form-content{margin:20px 30px}}.sky-theme-modern :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}\n"], directives: [{ type: i2__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], animations: [
|
|
1032
|
+
animations$1.trigger('tabEnter', [
|
|
1033
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
1034
|
+
animations$1.style({ transform: 'translate(-100%)' }),
|
|
1035
|
+
animations$1.animate('150ms ease-in'),
|
|
1036
|
+
]),
|
|
1037
|
+
]),
|
|
1038
|
+
animations$1.trigger('contentEnter', [
|
|
1039
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
1040
|
+
animations$1.style({ transform: 'translate(100%)' }),
|
|
1041
|
+
animations$1.animate('150ms ease-in'),
|
|
1042
|
+
]),
|
|
1043
|
+
]),
|
|
1044
|
+
], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
1045
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: SkySectionedFormComponent, decorators: [{
|
|
1046
|
+
type: i0.Component,
|
|
1047
|
+
args: [{
|
|
1048
|
+
selector: 'sky-sectioned-form',
|
|
1049
|
+
template: "<div\n aria-orientation=\"vertical\"\n class=\"sky-sectioned-form\"\n [attr.role]=\"ariaRole\"\n (window:resize)=\"tabService.updateContent()\"\n>\n <div\n *ngIf=\"maintainSectionContent || tabsVisible()\"\n class=\"sky-sectioned-form-tabs\"\n [ngClass]=\"{ 'sky-sectioned-form-tabs-hidden': !tabsVisible() }\"\n [@tabEnter]=\"tabService.animationTabsVisibleState\"\n >\n <ng-content></ng-content>\n </div>\n <div\n *ngIf=\"maintainSectionContent || tabService.contentVisible()\"\n class=\"sky-sectioned-form-content\"\n [ngClass]=\"{\n 'sky-sectioned-form-content-hidden': !tabService.contentVisible()\n }\"\n [@contentEnter]=\"tabService.animationContentVisibleState\"\n #skySectionSideContent\n ></div>\n</div>\n",
|
|
1050
|
+
styles: [":host .sky-sectioned-form{display:block;max-height:none}:host .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}:host-context(.sky-responsive-container-xs) .sky-sectioned-form,:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:block;max-height:none}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-content,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:auto;overflow-y:visible}:host-context(.sky-responsive-container-xs) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:auto;overflow-y:visible;border-right:1px solid #e2e3e4}@media (min-width: 768px){:host .sky-sectioned-form{display:flex;max-height:100%}:host .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}}:host-context(.sky-responsive-container-sm) .sky-sectioned-form,:host-context(.sky-responsive-container-md) .sky-sectioned-form,:host-context(.sky-responsive-container-lg) .sky-sectioned-form{display:flex;max-height:100%}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{flex-basis:70%;margin:15px;overflow-y:auto}:host-context(.sky-responsive-container-sm) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-md) .sky-sectioned-form-tabs,:host-context(.sky-responsive-container-lg) .sky-sectioned-form-tabs{flex-basis:30%;overflow-y:auto}.sky-sectioned-form-tabs-hidden{display:none}.sky-sectioned-form-content-hidden{display:none}:host-context(.sky-theme-modern) .sky-sectioned-form-content{margin:15px}:host-context(.sky-theme-modern) .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){:host-context(.sky-theme-modern) :host .sky-sectioned-form-content{margin:20px 30px}}:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,:host-context(.sky-theme-modern) :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}.sky-theme-modern .sky-sectioned-form-content{margin:15px}.sky-theme-modern .sky-sectioned-form-tabs{border-right:1px solid #d2d2d2}@media (min-width: 768px){.sky-theme-modern :host .sky-sectioned-form-content{margin:20px 30px}}.sky-theme-modern :host-context(.sky-responsive-container-sm) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-md) .sky-sectioned-form-content,.sky-theme-modern :host-context(.sky-responsive-container-lg) .sky-sectioned-form-content{margin:20px 30px}\n"],
|
|
1051
|
+
providers: [SkyVerticalTabsetService],
|
|
1052
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
1053
|
+
animations: [
|
|
1054
|
+
animations$1.trigger('tabEnter', [
|
|
1055
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
1056
|
+
animations$1.style({ transform: 'translate(-100%)' }),
|
|
1057
|
+
animations$1.animate('150ms ease-in'),
|
|
1058
|
+
]),
|
|
1059
|
+
]),
|
|
1060
|
+
animations$1.trigger('contentEnter', [
|
|
1061
|
+
animations$1.transition(HIDDEN_STATE + " => " + VISIBLE_STATE, [
|
|
1062
|
+
animations$1.style({ transform: 'translate(100%)' }),
|
|
1063
|
+
animations$1.animate('150ms ease-in'),
|
|
1064
|
+
]),
|
|
1065
|
+
]),
|
|
1066
|
+
],
|
|
1067
|
+
}]
|
|
1068
|
+
}], ctorParameters: function () { return [{ type: SkyVerticalTabsetService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { maintainSectionContent: [{
|
|
1069
|
+
type: i0.Input
|
|
1070
|
+
}], indexChanged: [{
|
|
1071
|
+
type: i0.Output
|
|
1072
|
+
}], content: [{
|
|
1073
|
+
type: i0.ViewChild,
|
|
1074
|
+
args: ['skySectionSideContent']
|
|
1075
|
+
}] } });
|
|
1076
|
+
|
|
1077
1077
|
var SkySectionedFormModule = /** @class */ (function () {
|
|
1078
1078
|
function SkySectionedFormModule() {
|
|
1079
1079
|
}
|