@angular/cdk 7.1.1 → 7.3.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/LICENSE +1 -1
- package/_a11y.scss +1 -1
- package/a11y/typings/focus-monitor/focus-monitor.d.ts +0 -1
- package/a11y/typings/focus-trap/focus-trap.d.ts +2 -0
- package/a11y/typings/index.metadata.json +1 -1
- package/bundles/cdk-a11y.umd.js +30 -24
- package/bundles/cdk-a11y.umd.js.map +1 -1
- package/bundles/cdk-a11y.umd.min.js +1 -1
- package/bundles/cdk-a11y.umd.min.js.map +1 -1
- package/bundles/cdk-coercion.umd.js +20 -4
- package/bundles/cdk-coercion.umd.js.map +1 -1
- package/bundles/cdk-coercion.umd.min.js +1 -1
- package/bundles/cdk-coercion.umd.min.js.map +1 -1
- package/bundles/cdk-drag-drop.umd.js +3246 -1894
- package/bundles/cdk-drag-drop.umd.js.map +1 -1
- package/bundles/cdk-drag-drop.umd.min.js +2 -1
- package/bundles/cdk-drag-drop.umd.min.js.map +1 -1
- package/bundles/cdk-observers.umd.js +2 -2
- package/bundles/cdk-observers.umd.js.map +1 -1
- package/bundles/cdk-observers.umd.min.js +1 -1
- package/bundles/cdk-observers.umd.min.js.map +1 -1
- package/bundles/cdk-overlay.umd.js +107 -45
- package/bundles/cdk-overlay.umd.js.map +1 -1
- package/bundles/cdk-overlay.umd.min.js +2 -2
- package/bundles/cdk-overlay.umd.min.js.map +1 -1
- package/bundles/cdk-portal.umd.js +3 -3
- package/bundles/cdk-portal.umd.js.map +1 -1
- package/bundles/cdk-portal.umd.min.js.map +1 -1
- package/bundles/cdk-scrolling.umd.js +9 -6
- package/bundles/cdk-scrolling.umd.js.map +1 -1
- package/bundles/cdk-scrolling.umd.min.js +1 -1
- package/bundles/cdk-scrolling.umd.min.js.map +1 -1
- package/bundles/cdk-stepper.umd.js +36 -16
- package/bundles/cdk-stepper.umd.js.map +1 -1
- package/bundles/cdk-stepper.umd.min.js +1 -1
- package/bundles/cdk-stepper.umd.min.js.map +1 -1
- package/bundles/cdk-table.umd.js +8 -4
- package/bundles/cdk-table.umd.js.map +1 -1
- package/bundles/cdk-table.umd.min.js +1 -1
- package/bundles/cdk-table.umd.min.js.map +1 -1
- package/bundles/cdk-text-field.umd.js +47 -22
- package/bundles/cdk-text-field.umd.js.map +1 -1
- package/bundles/cdk-text-field.umd.min.js +1 -1
- package/bundles/cdk-text-field.umd.min.js.map +1 -1
- package/bundles/cdk-tree.umd.js +1 -1
- package/bundles/cdk-tree.umd.js.map +1 -1
- package/bundles/cdk-tree.umd.min.js +1 -1
- package/bundles/cdk-tree.umd.min.js.map +1 -1
- package/bundles/cdk.umd.js +1 -1
- package/bundles/cdk.umd.js.map +1 -1
- package/bundles/cdk.umd.min.js +1 -1
- package/bundles/cdk.umd.min.js.map +1 -1
- package/coercion/typings/element.d.ts +13 -0
- package/coercion/typings/index.metadata.json +1 -1
- package/coercion/typings/public-api.d.ts +1 -0
- package/drag-drop/typings/{drag-handle.d.ts → directives/drag-handle.d.ts} +6 -2
- package/drag-drop/typings/{drag-placeholder.d.ts → directives/drag-placeholder.d.ts} +0 -0
- package/drag-drop/typings/{drag-preview.d.ts → directives/drag-preview.d.ts} +0 -0
- package/drag-drop/typings/directives/drag.d.ts +114 -0
- package/{typings/esm5/drag-drop → drag-drop/typings/directives}/drop-list-group.d.ts +3 -0
- package/drag-drop/typings/{drop-list.d.ts → directives/drop-list.d.ts} +44 -70
- package/drag-drop/typings/drag-drop-registry.d.ts +8 -3
- package/drag-drop/typings/drag-drop.d.ts +33 -0
- package/drag-drop/typings/drag-events.d.ts +14 -7
- package/{typings/esm5/drag-drop/drag.d.ts → drag-drop/typings/drag-ref.d.ts} +162 -86
- package/drag-drop/typings/drop-list-container.d.ts +19 -3
- package/drag-drop/typings/drop-list-ref.d.ts +238 -0
- package/drag-drop/typings/index.d.ts +2 -1
- package/drag-drop/typings/index.metadata.json +1 -1
- package/drag-drop/typings/public-api.d.ts +16 -6
- package/esm2015/a11y.js +30 -20
- package/esm2015/a11y.js.map +1 -1
- package/esm2015/cdk.js +1 -1
- package/esm2015/cdk.js.map +1 -1
- package/esm2015/coercion.js +18 -1
- package/esm2015/coercion.js.map +1 -1
- package/esm2015/drag-drop.js +2281 -1289
- package/esm2015/drag-drop.js.map +1 -1
- package/esm2015/observers.js +3 -3
- package/esm2015/observers.js.map +1 -1
- package/esm2015/overlay.js +75 -31
- package/esm2015/overlay.js.map +1 -1
- package/esm2015/portal.js +1 -1
- package/esm2015/portal.js.map +1 -1
- package/esm2015/scrolling.js +9 -6
- package/esm2015/scrolling.js.map +1 -1
- package/esm2015/stepper.js +30 -16
- package/esm2015/stepper.js.map +1 -1
- package/esm2015/table.js +8 -4
- package/esm2015/table.js.map +1 -1
- package/esm2015/text-field.js +31 -19
- package/esm2015/text-field.js.map +1 -1
- package/esm2015/tree.js +2 -2
- package/esm2015/tree.js.map +1 -1
- package/esm5/a11y.es5.js +31 -25
- package/esm5/a11y.es5.js.map +1 -1
- package/esm5/cdk.es5.js +1 -1
- package/esm5/cdk.es5.js.map +1 -1
- package/esm5/coercion.es5.js +18 -1
- package/esm5/coercion.es5.js.map +1 -1
- package/esm5/drag-drop.es5.js +3247 -1899
- package/esm5/drag-drop.es5.js.map +1 -1
- package/esm5/observers.es5.js +3 -3
- package/esm5/observers.es5.js.map +1 -1
- package/esm5/overlay.es5.js +107 -45
- package/esm5/overlay.es5.js.map +1 -1
- package/esm5/portal.es5.js +3 -3
- package/esm5/portal.es5.js.map +1 -1
- package/esm5/scrolling.es5.js +9 -6
- package/esm5/scrolling.es5.js.map +1 -1
- package/esm5/stepper.es5.js +36 -17
- package/esm5/stepper.es5.js.map +1 -1
- package/esm5/table.es5.js +8 -4
- package/esm5/table.es5.js.map +1 -1
- package/esm5/text-field.es5.js +44 -19
- package/esm5/text-field.es5.js.map +1 -1
- package/esm5/tree.es5.js +2 -2
- package/esm5/tree.es5.js.map +1 -1
- package/overlay/typings/index.metadata.json +1 -1
- package/overlay/typings/overlay-directives.d.ts +0 -2
- package/overlay/typings/overlay-ref.d.ts +5 -1
- package/overlay/typings/position/flexible-connected-position-strategy.d.ts +17 -4
- package/overlay/typings/position/overlay-position-builder.d.ts +3 -3
- package/package.json +4 -4
- package/portal/typings/portal.d.ts +1 -1
- package/schematics/migration.json +5 -0
- package/schematics/ng-generate/drag-drop/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +2 -2
- package/schematics/ng-update/index.d.ts +2 -0
- package/schematics/ng-update/index.js +5 -0
- package/schematics/ng-update/index.js.map +1 -1
- package/schematics/ng-update/target-version.d.ts +7 -1
- package/schematics/ng-update/target-version.js +10 -0
- package/schematics/ng-update/target-version.js.map +1 -1
- package/schematics/ng-update/upgrade-data.js +2 -1
- package/schematics/ng-update/upgrade-data.js.map +1 -1
- package/schematics/ng-update/upgrade-rules/index.js +3 -2
- package/schematics/ng-update/upgrade-rules/index.js.map +1 -1
- package/schematics/utils/ast/ng-module-imports.d.ts +1 -1
- package/schematics/utils/ast/ng-module-imports.js +25 -13
- package/schematics/utils/ast/ng-module-imports.js.map +1 -1
- package/schematics/utils/get-project.js +2 -1
- package/schematics/utils/get-project.js.map +1 -1
- package/schematics/utils/parse5-element.js +3 -2
- package/schematics/utils/parse5-element.js.map +1 -1
- package/schematics/utils/project-targets.js +2 -1
- package/schematics/utils/project-targets.js.map +1 -1
- package/schematics/utils/version-agnostic-typescript.js +3 -2
- package/schematics/utils/version-agnostic-typescript.js.map +1 -1
- package/stepper/typings/index.metadata.json +1 -1
- package/stepper/typings/stepper.d.ts +14 -2
- package/text-field/typings/autosize.d.ts +6 -0
- package/text-field/typings/index.metadata.json +1 -1
- package/tree/typings/control/base-tree-control.d.ts +1 -1
- package/tree/typings/control/nested-tree-control.d.ts +2 -2
- package/tree/typings/control/tree-control.d.ts +1 -1
- package/typings/a11y/focus-monitor/focus-monitor.d.ts +0 -1
- package/typings/a11y/focus-trap/focus-trap.d.ts +2 -0
- package/typings/a11y/index.metadata.json +1 -1
- package/typings/coercion/element.d.ts +13 -0
- package/typings/coercion/index.metadata.json +1 -1
- package/typings/coercion/public-api.d.ts +1 -0
- package/typings/drag-drop/{drag-handle.d.ts → directives/drag-handle.d.ts} +6 -2
- package/typings/drag-drop/{drag-placeholder.d.ts → directives/drag-placeholder.d.ts} +0 -0
- package/typings/drag-drop/{drag-preview.d.ts → directives/drag-preview.d.ts} +0 -0
- package/typings/drag-drop/directives/drag.d.ts +114 -0
- package/typings/drag-drop/{drop-list-group.d.ts → directives/drop-list-group.d.ts} +3 -0
- package/typings/{esm5/drag-drop → drag-drop/directives}/drop-list.d.ts +44 -70
- package/typings/drag-drop/drag-drop-registry.d.ts +8 -3
- package/typings/drag-drop/drag-drop.d.ts +33 -0
- package/typings/drag-drop/drag-events.d.ts +14 -7
- package/typings/drag-drop/{drag.d.ts → drag-ref.d.ts} +162 -86
- package/typings/drag-drop/drop-list-container.d.ts +19 -3
- package/typings/drag-drop/drop-list-ref.d.ts +238 -0
- package/typings/drag-drop/index.d.ts +2 -1
- package/typings/drag-drop/index.metadata.json +1 -1
- package/typings/drag-drop/public-api.d.ts +16 -6
- package/typings/esm5/a11y/focus-monitor/focus-monitor.d.ts +0 -1
- package/typings/esm5/a11y/focus-trap/focus-trap.d.ts +2 -0
- package/typings/esm5/a11y/index.metadata.json +1 -1
- package/typings/esm5/coercion/element.d.ts +13 -0
- package/typings/esm5/coercion/index.metadata.json +1 -1
- package/typings/esm5/coercion/public-api.d.ts +1 -0
- package/typings/esm5/drag-drop/{drag-handle.d.ts → directives/drag-handle.d.ts} +6 -2
- package/typings/esm5/drag-drop/{drag-placeholder.d.ts → directives/drag-placeholder.d.ts} +0 -0
- package/typings/esm5/drag-drop/{drag-preview.d.ts → directives/drag-preview.d.ts} +0 -0
- package/typings/esm5/drag-drop/directives/drag.d.ts +114 -0
- package/{drag-drop/typings → typings/esm5/drag-drop/directives}/drop-list-group.d.ts +3 -0
- package/typings/{drag-drop → esm5/drag-drop/directives}/drop-list.d.ts +44 -70
- package/typings/esm5/drag-drop/drag-drop-registry.d.ts +8 -3
- package/typings/esm5/drag-drop/drag-drop.d.ts +33 -0
- package/typings/esm5/drag-drop/drag-events.d.ts +14 -7
- package/{drag-drop/typings/drag.d.ts → typings/esm5/drag-drop/drag-ref.d.ts} +162 -86
- package/typings/esm5/drag-drop/drop-list-container.d.ts +19 -3
- package/typings/esm5/drag-drop/drop-list-ref.d.ts +238 -0
- package/typings/esm5/drag-drop/index.d.ts +2 -1
- package/typings/esm5/drag-drop/index.metadata.json +1 -1
- package/typings/esm5/drag-drop/public-api.d.ts +16 -6
- package/typings/esm5/index.metadata.json +1 -1
- package/typings/esm5/overlay/index.metadata.json +1 -1
- package/typings/esm5/overlay/overlay-directives.d.ts +0 -2
- package/typings/esm5/overlay/overlay-ref.d.ts +5 -1
- package/typings/esm5/overlay/position/flexible-connected-position-strategy.d.ts +17 -4
- package/typings/esm5/overlay/position/overlay-position-builder.d.ts +3 -3
- package/typings/esm5/portal/portal.d.ts +1 -1
- package/typings/esm5/stepper/index.metadata.json +1 -1
- package/typings/esm5/stepper/stepper.d.ts +14 -2
- package/typings/esm5/text-field/autosize.d.ts +6 -0
- package/typings/esm5/text-field/index.metadata.json +1 -1
- package/typings/esm5/tree/control/base-tree-control.d.ts +1 -1
- package/typings/esm5/tree/control/nested-tree-control.d.ts +2 -2
- package/typings/esm5/tree/control/tree-control.d.ts +1 -1
- package/typings/index.metadata.json +1 -1
- package/typings/overlay/index.metadata.json +1 -1
- package/typings/overlay/overlay-directives.d.ts +0 -2
- package/typings/overlay/overlay-ref.d.ts +5 -1
- package/typings/overlay/position/flexible-connected-position-strategy.d.ts +17 -4
- package/typings/overlay/position/overlay-position-builder.d.ts +3 -3
- package/typings/portal/portal.d.ts +1 -1
- package/typings/schematics/ng-update/index.d.ts +2 -0
- package/typings/schematics/ng-update/target-version.d.ts +7 -1
- package/typings/schematics/utils/ast/ng-module-imports.d.ts +1 -1
- package/typings/stepper/index.metadata.json +1 -1
- package/typings/stepper/stepper.d.ts +14 -2
- package/typings/text-field/autosize.d.ts +6 -0
- package/typings/text-field/index.metadata.json +1 -1
- package/typings/tree/control/base-tree-control.d.ts +1 -1
- package/typings/tree/control/nested-tree-control.d.ts +2 -2
- package/typings/tree/control/tree-control.d.ts +1 -1
package/esm5/stepper.es5.js
CHANGED
|
@@ -104,7 +104,14 @@ var STEP_STATE = {
|
|
|
104
104
|
* InjectionToken that can be used to specify the global stepper options.
|
|
105
105
|
* @type {?}
|
|
106
106
|
*/
|
|
107
|
-
var
|
|
107
|
+
var STEPPER_GLOBAL_OPTIONS = new InjectionToken('STEPPER_GLOBAL_OPTIONS');
|
|
108
|
+
/**
|
|
109
|
+
* InjectionToken that can be used to specify the global stepper options.
|
|
110
|
+
* @deprecated Use `STEPPER_GLOBAL_OPTIONS` instead.
|
|
111
|
+
* \@breaking-change 8.0.0.
|
|
112
|
+
* @type {?}
|
|
113
|
+
*/
|
|
114
|
+
var MAT_STEPPER_GLOBAL_OPTIONS = STEPPER_GLOBAL_OPTIONS;
|
|
108
115
|
var CdkStep = /** @class */ (function () {
|
|
109
116
|
/** @breaking-change 8.0.0 remove the `?` after `stepperOptions` */
|
|
110
117
|
function CdkStep(_stepper, stepperOptions) {
|
|
@@ -122,9 +129,9 @@ var CdkStep = /** @class */ (function () {
|
|
|
122
129
|
this._showError = !!this._stepperOptions.showError;
|
|
123
130
|
}
|
|
124
131
|
Object.defineProperty(CdkStep.prototype, "editable", {
|
|
125
|
-
/** Whether the user can return to this step once it has been marked as
|
|
132
|
+
/** Whether the user can return to this step once it has been marked as completed. */
|
|
126
133
|
get: /**
|
|
127
|
-
* Whether the user can return to this step once it has been marked as
|
|
134
|
+
* Whether the user can return to this step once it has been marked as completed.
|
|
128
135
|
* @return {?}
|
|
129
136
|
*/
|
|
130
137
|
function () { return this._editable; },
|
|
@@ -192,7 +199,7 @@ var CdkStep = /** @class */ (function () {
|
|
|
192
199
|
* @return {?}
|
|
193
200
|
*/
|
|
194
201
|
function () {
|
|
195
|
-
return this._customError
|
|
202
|
+
return this._customError == null ? this._getDefaultError() : this._customError;
|
|
196
203
|
},
|
|
197
204
|
set: /**
|
|
198
205
|
* @param {?} value
|
|
@@ -270,7 +277,7 @@ var CdkStep = /** @class */ (function () {
|
|
|
270
277
|
/** @nocollapse */
|
|
271
278
|
CdkStep.ctorParameters = function () { return [
|
|
272
279
|
{ type: CdkStepper, decorators: [{ type: Inject, args: [forwardRef(function () { return CdkStepper; }),] }] },
|
|
273
|
-
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [
|
|
280
|
+
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [STEPPER_GLOBAL_OPTIONS,] }] }
|
|
274
281
|
]; };
|
|
275
282
|
CdkStep.propDecorators = {
|
|
276
283
|
stepLabel: [{ type: ContentChild, args: [CdkStepLabel,] }],
|
|
@@ -307,6 +314,18 @@ var CdkStepper = /** @class */ (function () {
|
|
|
307
314
|
this._groupId = nextId++;
|
|
308
315
|
this._document = _document;
|
|
309
316
|
}
|
|
317
|
+
Object.defineProperty(CdkStepper.prototype, "steps", {
|
|
318
|
+
/** The list of step components that the stepper is holding. */
|
|
319
|
+
get: /**
|
|
320
|
+
* The list of step components that the stepper is holding.
|
|
321
|
+
* @return {?}
|
|
322
|
+
*/
|
|
323
|
+
function () {
|
|
324
|
+
return this._steps;
|
|
325
|
+
},
|
|
326
|
+
enumerable: true,
|
|
327
|
+
configurable: true
|
|
328
|
+
});
|
|
310
329
|
Object.defineProperty(CdkStepper.prototype, "linear", {
|
|
311
330
|
/** Whether the validity of previous steps should be checked or not. */
|
|
312
331
|
get: /**
|
|
@@ -334,14 +353,14 @@ var CdkStepper = /** @class */ (function () {
|
|
|
334
353
|
* @return {?}
|
|
335
354
|
*/
|
|
336
355
|
function (index) {
|
|
337
|
-
if (this.
|
|
356
|
+
if (this.steps) {
|
|
338
357
|
// Ensure that the index can't be out of bounds.
|
|
339
|
-
if (index < 0 || index > this.
|
|
358
|
+
if (index < 0 || index > this.steps.length - 1) {
|
|
340
359
|
throw Error('cdkStepper: Cannot assign out-of-bounds value to `selectedIndex`.');
|
|
341
360
|
}
|
|
342
361
|
if (this._selectedIndex != index &&
|
|
343
362
|
!this._anyControlsInvalidOrPending(index) &&
|
|
344
|
-
(index >= this._selectedIndex || this.
|
|
363
|
+
(index >= this._selectedIndex || this.steps.toArray()[index].editable)) {
|
|
345
364
|
this._updateSelectedItemIndex(index);
|
|
346
365
|
}
|
|
347
366
|
}
|
|
@@ -360,14 +379,14 @@ var CdkStepper = /** @class */ (function () {
|
|
|
360
379
|
*/
|
|
361
380
|
function () {
|
|
362
381
|
// @breaking-change 8.0.0 Change return type to `CdkStep | undefined`.
|
|
363
|
-
return this.
|
|
382
|
+
return this.steps ? this.steps.toArray()[this.selectedIndex] : (/** @type {?} */ (undefined));
|
|
364
383
|
},
|
|
365
384
|
set: /**
|
|
366
385
|
* @param {?} step
|
|
367
386
|
* @return {?}
|
|
368
387
|
*/
|
|
369
388
|
function (step) {
|
|
370
|
-
this.selectedIndex = this.
|
|
389
|
+
this.selectedIndex = this.steps ? this.steps.toArray().indexOf(step) : -1;
|
|
371
390
|
},
|
|
372
391
|
enumerable: true,
|
|
373
392
|
configurable: true
|
|
@@ -390,7 +409,7 @@ var CdkStepper = /** @class */ (function () {
|
|
|
390
409
|
.pipe(startWith(this._layoutDirection()), takeUntil(this._destroyed))
|
|
391
410
|
.subscribe(function (direction) { return _this._keyManager.withHorizontalOrientation(direction); });
|
|
392
411
|
this._keyManager.updateActiveItemIndex(this._selectedIndex);
|
|
393
|
-
this.
|
|
412
|
+
this.steps.changes.pipe(takeUntil(this._destroyed)).subscribe(function () {
|
|
394
413
|
if (!_this.selected) {
|
|
395
414
|
_this._selectedIndex = Math.max(_this._selectedIndex - 1, 0);
|
|
396
415
|
}
|
|
@@ -416,7 +435,7 @@ var CdkStepper = /** @class */ (function () {
|
|
|
416
435
|
* @return {?}
|
|
417
436
|
*/
|
|
418
437
|
function () {
|
|
419
|
-
this.selectedIndex = Math.min(this._selectedIndex + 1, this.
|
|
438
|
+
this.selectedIndex = Math.min(this._selectedIndex + 1, this.steps.length - 1);
|
|
420
439
|
};
|
|
421
440
|
/** Selects and focuses the previous step in list. */
|
|
422
441
|
/**
|
|
@@ -441,7 +460,7 @@ var CdkStepper = /** @class */ (function () {
|
|
|
441
460
|
*/
|
|
442
461
|
function () {
|
|
443
462
|
this._updateSelectedItemIndex(0);
|
|
444
|
-
this.
|
|
463
|
+
this.steps.forEach(function (step) { return step.reset(); });
|
|
445
464
|
this._stateChanged();
|
|
446
465
|
};
|
|
447
466
|
/** Returns a unique id for each step label element. */
|
|
@@ -522,7 +541,7 @@ var CdkStepper = /** @class */ (function () {
|
|
|
522
541
|
function (index, state) {
|
|
523
542
|
if (state === void 0) { state = STEP_STATE.NUMBER; }
|
|
524
543
|
/** @type {?} */
|
|
525
|
-
var step = this.
|
|
544
|
+
var step = this.steps.toArray()[index];
|
|
526
545
|
/** @type {?} */
|
|
527
546
|
var isCurrentStep = this._isCurrentStep(index);
|
|
528
547
|
return step._displayDefaultIndicatorType
|
|
@@ -621,7 +640,7 @@ var CdkStepper = /** @class */ (function () {
|
|
|
621
640
|
*/
|
|
622
641
|
function (newIndex) {
|
|
623
642
|
/** @type {?} */
|
|
624
|
-
var stepsArray = this.
|
|
643
|
+
var stepsArray = this.steps.toArray();
|
|
625
644
|
this.selectionChange.emit({
|
|
626
645
|
selectedIndex: newIndex,
|
|
627
646
|
previouslySelectedIndex: this._selectedIndex,
|
|
@@ -681,7 +700,7 @@ var CdkStepper = /** @class */ (function () {
|
|
|
681
700
|
*/
|
|
682
701
|
function (index) {
|
|
683
702
|
/** @type {?} */
|
|
684
|
-
var steps = this.
|
|
703
|
+
var steps = this.steps.toArray();
|
|
685
704
|
steps[this._selectedIndex].interacted = true;
|
|
686
705
|
if (this._linear && index >= 0) {
|
|
687
706
|
return steps.slice(0, index).some(function (step) {
|
|
@@ -856,5 +875,5 @@ var CdkStepperModule = /** @class */ (function () {
|
|
|
856
875
|
* @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
857
876
|
*/
|
|
858
877
|
|
|
859
|
-
export { StepperSelectionEvent, STEP_STATE, MAT_STEPPER_GLOBAL_OPTIONS, CdkStep, CdkStepper, CdkStepLabel, CdkStepperNext, CdkStepperPrevious, CdkStepperModule, CdkStepHeader };
|
|
878
|
+
export { StepperSelectionEvent, STEP_STATE, STEPPER_GLOBAL_OPTIONS, MAT_STEPPER_GLOBAL_OPTIONS, CdkStep, CdkStepper, CdkStepLabel, CdkStepperNext, CdkStepperPrevious, CdkStepperModule, CdkStepHeader };
|
|
860
879
|
//# sourceMappingURL=stepper.es5.js.map
|
package/esm5/stepper.es5.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stepper.es5.js","sources":["../../../src/cdk/stepper/stepper-module.ts","../../../src/cdk/stepper/stepper-button.ts","../../../src/cdk/stepper/stepper.ts","../../../src/cdk/stepper/step-header.ts","../../../src/cdk/stepper/step-label.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {NgModule} from '@angular/core';\nimport {CdkStepper, CdkStep} from './stepper';\nimport {CommonModule} from '@angular/common';\nimport {CdkStepLabel} from './step-label';\nimport {CdkStepperNext, CdkStepperPrevious} from './stepper-button';\nimport {CdkStepHeader} from './step-header';\nimport {BidiModule} from '@angular/cdk/bidi';\n\n@NgModule({\n imports: [BidiModule, CommonModule],\n exports: [\n CdkStep,\n CdkStepper,\n CdkStepHeader,\n CdkStepLabel,\n CdkStepperNext,\n CdkStepperPrevious,\n ],\n declarations: [\n CdkStep,\n CdkStepper,\n CdkStepHeader,\n CdkStepLabel,\n CdkStepperNext,\n CdkStepperPrevious,\n ]\n})\nexport class CdkStepperModule {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directive, Input} from '@angular/core';\nimport {CdkStepper} from './stepper';\n\n/** Button that moves to the next step in a stepper workflow. */\n@Directive({\n selector: 'button[cdkStepperNext]',\n host: {\n '(click)': '_stepper.next()',\n '[type]': 'type',\n }\n})\nexport class CdkStepperNext {\n /** Type of the next button. Defaults to \"submit\" if not specified. */\n @Input() type: string = 'submit';\n\n constructor(public _stepper: CdkStepper) {}\n}\n\n/** Button that moves to the previous step in a stepper workflow. */\n@Directive({\n selector: 'button[cdkStepperPrevious]',\n host: {\n '(click)': '_stepper.previous()',\n '[type]': 'type',\n }\n})\nexport class CdkStepperPrevious {\n /** Type of the previous button. Defaults to \"button\" if not specified. */\n @Input() type: string = 'button';\n\n constructor(public _stepper: CdkStepper) {}\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {FocusableOption, FocusKeyManager} from '@angular/cdk/a11y';\nimport {Direction, Directionality} from '@angular/cdk/bidi';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {END, ENTER, HOME, SPACE, hasModifierKey} from '@angular/cdk/keycodes';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ContentChildren,\n Directive,\n EventEmitter,\n ElementRef,\n forwardRef,\n Inject,\n Input,\n OnChanges,\n OnDestroy,\n Optional,\n Output,\n QueryList,\n TemplateRef,\n ViewChild,\n ViewEncapsulation,\n InjectionToken,\n} from '@angular/core';\nimport {DOCUMENT} from '@angular/common';\nimport {AbstractControl} from '@angular/forms';\nimport {CdkStepLabel} from './step-label';\nimport {Observable, Subject, of as obaservableOf} from 'rxjs';\nimport {startWith, takeUntil} from 'rxjs/operators';\nimport {CdkStepHeader} from './step-header';\n\n/** Used to generate unique ID for each stepper component. */\nlet nextId = 0;\n\n/**\n * Position state of the content of each step in stepper that is used for transitioning\n * the content into correct position upon step selection change.\n */\nexport type StepContentPositionState = 'previous' | 'current' | 'next';\n\n/** Possible orientation of a stepper. */\nexport type StepperOrientation = 'horizontal' | 'vertical';\n\n/** Change event emitted on selection changes. */\nexport class StepperSelectionEvent {\n /** Index of the step now selected. */\n selectedIndex: number;\n\n /** Index of the step previously selected. */\n previouslySelectedIndex: number;\n\n /** The step instance now selected. */\n selectedStep: CdkStep;\n\n /** The step instance previously selected. */\n previouslySelectedStep: CdkStep;\n}\n\n/** The state of each step. */\nexport type StepState = 'number' | 'edit' | 'done' | 'error' | string;\n\n/** Enum to represent the different states of the steps. */\nexport const STEP_STATE = {\n NUMBER: 'number',\n EDIT: 'edit',\n DONE: 'done',\n ERROR: 'error'\n};\n\n/** InjectionToken that can be used to specify the global stepper options. */\nexport const MAT_STEPPER_GLOBAL_OPTIONS =\n new InjectionToken<StepperOptions>('mat-stepper-global-options');\n\n/** Configurable options for stepper. */\nexport interface StepperOptions {\n /**\n * Whether the stepper should display an error state or not.\n * Default behavior is assumed to be false.\n */\n showError?: boolean;\n\n /**\n * Whether the stepper should display the default indicator type\n * or not.\n * Default behavior is assumed to be true.\n */\n displayDefaultIndicatorType?: boolean;\n}\n\n@Component({\n moduleId: module.id,\n selector: 'cdk-step',\n exportAs: 'cdkStep',\n template: '<ng-template><ng-content></ng-content></ng-template>',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class CdkStep implements OnChanges {\n private _stepperOptions: StepperOptions;\n _showError: boolean;\n _displayDefaultIndicatorType: boolean;\n\n /** Template for step label if it exists. */\n @ContentChild(CdkStepLabel) stepLabel: CdkStepLabel;\n\n /** Template for step content. */\n @ViewChild(TemplateRef) content: TemplateRef<any>;\n\n /** The top level abstract control of the step. */\n @Input() stepControl: AbstractControl;\n\n /** Whether user has seen the expanded step content or not. */\n interacted = false;\n\n /** Plain text label of the step. */\n @Input() label: string;\n\n /** Error message to display when there's an error. */\n @Input() errorMessage: string;\n\n /** Aria label for the tab. */\n @Input('aria-label') ariaLabel: string;\n\n /**\n * Reference to the element that the tab is labelled by.\n * Will be cleared if `aria-label` is set at the same time.\n */\n @Input('aria-labelledby') ariaLabelledby: string;\n\n /** State of the step. */\n @Input() state: StepState;\n\n /** Whether the user can return to this step once it has been marked as complted. */\n @Input()\n get editable(): boolean { return this._editable; }\n set editable(value: boolean) {\n this._editable = coerceBooleanProperty(value);\n }\n private _editable = true;\n\n /** Whether the completion of step is optional. */\n @Input()\n get optional(): boolean { return this._optional; }\n set optional(value: boolean) {\n this._optional = coerceBooleanProperty(value);\n }\n private _optional = false;\n\n /** Whether step is marked as completed. */\n @Input()\n get completed(): boolean {\n return this._customCompleted == null ? this._getDefaultCompleted() : this._customCompleted;\n }\n set completed(value: boolean) {\n this._customCompleted = coerceBooleanProperty(value);\n }\n private _customCompleted: boolean | null = null;\n\n private _getDefaultCompleted() {\n return this.stepControl ? this.stepControl.valid && this.interacted : this.interacted;\n }\n\n /** Whether step has an error. */\n @Input()\n get hasError(): boolean {\n return this._customError || this._getDefaultError();\n }\n set hasError(value: boolean) {\n this._customError = coerceBooleanProperty(value);\n }\n private _customError: boolean | null = null;\n\n private _getDefaultError() {\n return this.stepControl && this.stepControl.invalid && this.interacted;\n }\n\n /** @breaking-change 8.0.0 remove the `?` after `stepperOptions` */\n constructor(\n @Inject(forwardRef(() => CdkStepper)) private _stepper: CdkStepper,\n @Optional() @Inject(MAT_STEPPER_GLOBAL_OPTIONS) stepperOptions?: StepperOptions) {\n this._stepperOptions = stepperOptions ? stepperOptions : {};\n this._displayDefaultIndicatorType = this._stepperOptions.displayDefaultIndicatorType !== false;\n this._showError = !!this._stepperOptions.showError;\n }\n\n /** Selects this step component. */\n select(): void {\n this._stepper.selected = this;\n }\n\n /** Resets the step to its initial state. Note that this includes resetting form data. */\n reset(): void {\n this.interacted = false;\n\n if (this._customCompleted != null) {\n this._customCompleted = false;\n }\n\n if (this._customError != null) {\n this._customError = false;\n }\n\n if (this.stepControl) {\n this.stepControl.reset();\n }\n }\n\n ngOnChanges() {\n // Since basically all inputs of the MatStep get proxied through the view down to the\n // underlying MatStepHeader, we have to make sure that change detection runs correctly.\n this._stepper._stateChanged();\n }\n}\n\n@Directive({\n selector: '[cdkStepper]',\n exportAs: 'cdkStepper',\n})\nexport class CdkStepper implements AfterViewInit, OnDestroy {\n /** Emits when the component is destroyed. */\n protected _destroyed = new Subject<void>();\n\n /** Used for managing keyboard focus. */\n private _keyManager: FocusKeyManager<FocusableOption>;\n\n /**\n * @breaking-change 8.0.0 Remove `| undefined` once the `_document`\n * constructor param is required.\n */\n private _document: Document | undefined;\n\n /** The list of step components that the stepper is holding. */\n @ContentChildren(CdkStep) _steps: QueryList<CdkStep>;\n\n /**\n * The list of step headers of the steps in the stepper.\n * @deprecated Type to be changed to `QueryList<CdkStepHeader>`.\n * @breaking-change 8.0.0\n */\n @ContentChildren(CdkStepHeader) _stepHeader: QueryList<FocusableOption>;\n\n /** Whether the validity of previous steps should be checked or not. */\n @Input()\n get linear(): boolean { return this._linear; }\n set linear(value: boolean) { this._linear = coerceBooleanProperty(value); }\n private _linear = false;\n\n /** The index of the selected step. */\n @Input()\n get selectedIndex() { return this._selectedIndex; }\n set selectedIndex(index: number) {\n if (this._steps) {\n // Ensure that the index can't be out of bounds.\n if (index < 0 || index > this._steps.length - 1) {\n throw Error('cdkStepper: Cannot assign out-of-bounds value to `selectedIndex`.');\n }\n\n if (this._selectedIndex != index &&\n !this._anyControlsInvalidOrPending(index) &&\n (index >= this._selectedIndex || this._steps.toArray()[index].editable)) {\n this._updateSelectedItemIndex(index);\n }\n } else {\n this._selectedIndex = index;\n }\n }\n private _selectedIndex = 0;\n\n /** The step that is selected. */\n @Input()\n get selected(): CdkStep {\n // @breaking-change 8.0.0 Change return type to `CdkStep | undefined`.\n return this._steps ? this._steps.toArray()[this.selectedIndex] : undefined!;\n }\n set selected(step: CdkStep) {\n this.selectedIndex = this._steps ? this._steps.toArray().indexOf(step) : -1;\n }\n\n /** Event emitted when the selected step has changed. */\n @Output() selectionChange: EventEmitter<StepperSelectionEvent>\n = new EventEmitter<StepperSelectionEvent>();\n\n /** Used to track unique ID for each stepper component. */\n _groupId: number;\n\n protected _orientation: StepperOrientation = 'horizontal';\n\n constructor(\n @Optional() private _dir: Directionality,\n private _changeDetectorRef: ChangeDetectorRef,\n // @breaking-change 8.0.0 `_elementRef` and `_document` parameters to become required.\n private _elementRef?: ElementRef<HTMLElement>,\n @Inject(DOCUMENT) _document?: any) {\n this._groupId = nextId++;\n this._document = _document;\n }\n\n ngAfterViewInit() {\n // Note that while the step headers are content children by default, any components that\n // extend this one might have them as view chidren. We initialize the keyboard handling in\n // AfterViewInit so we're guaranteed for both view and content children to be defined.\n this._keyManager = new FocusKeyManager<FocusableOption>(this._stepHeader)\n .withWrap()\n .withVerticalOrientation(this._orientation === 'vertical');\n\n (this._dir ? this._dir.change as Observable<Direction> : obaservableOf<Direction>())\n .pipe(startWith(this._layoutDirection()), takeUntil(this._destroyed))\n .subscribe(direction => this._keyManager.withHorizontalOrientation(direction));\n\n this._keyManager.updateActiveItemIndex(this._selectedIndex);\n\n this._steps.changes.pipe(takeUntil(this._destroyed)).subscribe(() => {\n if (!this.selected) {\n this._selectedIndex = Math.max(this._selectedIndex - 1, 0);\n }\n });\n }\n\n ngOnDestroy() {\n this._destroyed.next();\n this._destroyed.complete();\n }\n\n /** Selects and focuses the next step in list. */\n next(): void {\n this.selectedIndex = Math.min(this._selectedIndex + 1, this._steps.length - 1);\n }\n\n /** Selects and focuses the previous step in list. */\n previous(): void {\n this.selectedIndex = Math.max(this._selectedIndex - 1, 0);\n }\n\n /** Resets the stepper to its initial state. Note that this includes clearing form data. */\n reset(): void {\n this._updateSelectedItemIndex(0);\n this._steps.forEach(step => step.reset());\n this._stateChanged();\n }\n\n /** Returns a unique id for each step label element. */\n _getStepLabelId(i: number): string {\n return `cdk-step-label-${this._groupId}-${i}`;\n }\n\n /** Returns unique id for each step content element. */\n _getStepContentId(i: number): string {\n return `cdk-step-content-${this._groupId}-${i}`;\n }\n\n /** Marks the component to be change detected. */\n _stateChanged() {\n this._changeDetectorRef.markForCheck();\n }\n\n /** Returns position state of the step with the given index. */\n _getAnimationDirection(index: number): StepContentPositionState {\n const position = index - this._selectedIndex;\n if (position < 0) {\n return this._layoutDirection() === 'rtl' ? 'next' : 'previous';\n } else if (position > 0) {\n return this._layoutDirection() === 'rtl' ? 'previous' : 'next';\n }\n return 'current';\n }\n\n /** Returns the type of icon to be displayed. */\n _getIndicatorType(index: number, state: StepState = STEP_STATE.NUMBER): StepState {\n const step = this._steps.toArray()[index];\n const isCurrentStep = this._isCurrentStep(index);\n\n return step._displayDefaultIndicatorType\n ? this._getDefaultIndicatorLogic(step, isCurrentStep)\n : this._getGuidelineLogic(step, isCurrentStep, state);\n }\n\n private _getDefaultIndicatorLogic(step: CdkStep, isCurrentStep: boolean): StepState {\n if (step._showError && step.hasError && !isCurrentStep) {\n return STEP_STATE.ERROR;\n } else if (!step.completed || isCurrentStep) {\n return STEP_STATE.NUMBER;\n } else {\n return step.editable ? STEP_STATE.EDIT : STEP_STATE.DONE;\n }\n }\n\n private _getGuidelineLogic(\n step: CdkStep,\n isCurrentStep: boolean,\n state: StepState = STEP_STATE.NUMBER): StepState {\n if (step._showError && step.hasError && !isCurrentStep) {\n return STEP_STATE.ERROR;\n } else if (step.completed && !isCurrentStep) {\n return STEP_STATE.DONE;\n } else if (step.completed && isCurrentStep) {\n return state;\n } else if (step.editable && isCurrentStep) {\n return STEP_STATE.EDIT;\n } else {\n return state;\n }\n }\n\n private _isCurrentStep(index: number) {\n return this._selectedIndex === index;\n }\n\n /** Returns the index of the currently-focused step header. */\n _getFocusIndex() {\n return this._keyManager ? this._keyManager.activeItemIndex : this._selectedIndex;\n }\n\n private _updateSelectedItemIndex(newIndex: number): void {\n const stepsArray = this._steps.toArray();\n this.selectionChange.emit({\n selectedIndex: newIndex,\n previouslySelectedIndex: this._selectedIndex,\n selectedStep: stepsArray[newIndex],\n previouslySelectedStep: stepsArray[this._selectedIndex],\n });\n\n // If focus is inside the stepper, move it to the next header, otherwise it may become\n // lost when the active step content is hidden. We can't be more granular with the check\n // (e.g. checking whether focus is inside the active step), because we don't have a\n // reference to the elements that are rendering out the content.\n this._containsFocus() ? this._keyManager.setActiveItem(newIndex) :\n this._keyManager.updateActiveItemIndex(newIndex);\n\n this._selectedIndex = newIndex;\n this._stateChanged();\n }\n\n _onKeydown(event: KeyboardEvent) {\n const hasModifier = hasModifierKey(event);\n const keyCode = event.keyCode;\n const manager = this._keyManager;\n\n if (manager.activeItemIndex != null && !hasModifier &&\n (keyCode === SPACE || keyCode === ENTER)) {\n this.selectedIndex = manager.activeItemIndex;\n event.preventDefault();\n } else if (keyCode === HOME) {\n manager.setFirstItemActive();\n event.preventDefault();\n } else if (keyCode === END) {\n manager.setLastItemActive();\n event.preventDefault();\n } else {\n manager.onKeydown(event);\n }\n }\n\n private _anyControlsInvalidOrPending(index: number): boolean {\n const steps = this._steps.toArray();\n\n steps[this._selectedIndex].interacted = true;\n\n if (this._linear && index >= 0) {\n return steps.slice(0, index).some(step => {\n const control = step.stepControl;\n const isIncomplete = control ?\n (control.invalid || control.pending || !step.interacted) :\n !step.completed;\n return isIncomplete && !step.optional;\n });\n }\n\n return false;\n }\n\n private _layoutDirection(): Direction {\n return this._dir && this._dir.value === 'rtl' ? 'rtl' : 'ltr';\n }\n\n /** Checks whether the stepper contains the focused element. */\n private _containsFocus(): boolean {\n if (!this._document || !this._elementRef) {\n return false;\n }\n\n const stepperElement = this._elementRef.nativeElement;\n const focusedElement = this._document.activeElement;\n return stepperElement === focusedElement || stepperElement.contains(focusedElement);\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directive, ElementRef} from '@angular/core';\nimport {FocusableOption} from '@angular/cdk/a11y';\n\n\n@Directive({\n selector: '[cdkStepHeader]',\n host: {\n 'role': 'tab',\n },\n})\nexport class CdkStepHeader implements FocusableOption {\n constructor(protected _elementRef: ElementRef<HTMLElement>) {}\n\n /** Focuses the step header. */\n focus() {\n this._elementRef.nativeElement.focus();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directive, TemplateRef} from '@angular/core';\n\n@Directive({\n selector: '[cdkStepLabel]',\n})\nexport class CdkStepLabel {\n constructor(/** @docs-private */ public template: TemplateRef<any>) { }\n}\n"],"names":["obaservableOf"],"mappings":";;;;;;;;;;;;;;;;;;;;;AIUA,IAAA,YAAA,kBAAA,YAAA;IAIE,SAAF,YAAA,sBAA0C,QAA0B,EAApE;QAA0C,IAA1C,CAAA,QAAkD,GAAR,QAAQ,CAAkB;KAAK;;QAJzE,EAAA,IAAA,EAAC,SAAS,EAAV,IAAA,EAAA,CAAW;oBACT,QAAQ,EAAE,gBAAgB;iBAC3B,EAAD,EAAA;;;;QAJA,EAAA,IAAA,EAAmB,WAAW,EAA9B;;IAOA,OAAA,YAAC,CAAD;CAAC,EAAD,CAAA;;;;;;ADHA,IAAA,aAAA,kBAAA,YAAA;IAOE,SAAF,aAAA,CAAwB,WAAoC,EAA5D;QAAwB,IAAxB,CAAA,WAAmC,GAAX,WAAW,CAAyB;KAAI;;;;;;IAG9D,aAAF,CAAA,SAAA,CAAA,KAAO;;;;IAAL,YAAF;QACI,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,KAAK,EAAE,CAAC;KACxC,CAAH;;QAZA,EAAA,IAAA,EAAC,SAAS,EAAV,IAAA,EAAA,CAAW;oBACT,QAAQ,EAAE,iBAAiB;oBAC3B,IAAI,EAAE;wBACJ,MAAM,EAAE,KAAK;qBACd;iBACF,EAAD,EAAA;;;;QATA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AAF,kBAAA,CAAqB,QAAoB,EAAzC;QAAqB,IAArB,CAAA,QAA6B,GAAR,QAAQ,CAAY;;;;QAF9B,IAAX,CAAA,IAAe,GAAW,QAAQ,CAAC;KAEU;;QAX7C,EAAA,IAAA,EAAC,SAAS,EAAV,IAAA,EAAA,CAAW;oBACT,QAAQ,EAAE,4BAA4B;oBACtC,IAAI,EAAE;wBACJ,SAAS,EAAE,qBAAqB;wBAChC,QAAQ,EAAE,MAAM;qBACjB;iBACF,EAAD,EAAA;;;;QAxBA,EAAA,IAAA,EAAQ,UAAU,EAAlB;;;QA2BA,IAAA,EAAA,CAAA,EAAA,IAAA,EAAG,KAAK,EAAR,CAAA;;IAGA,OAAA,kBAAC,CAAD;CAAC,EAAD,CAAA;;;;;;ADvBA,IAAA,gBAAA,kBAAA,YAAA;IAAA,SAAA,gBAAA,GAAA;KAmBgC;;QAnBhC,EAAA,IAAA,EAAC,QAAQ,EAAT,IAAA,EAAA,CAAU;oBACR,OAAO,EAAE,CAAC,UAAU,EAAE,YAAY,CAAC;oBACnC,OAAO,EAAE;wBACP,OAAO;wBACP,UAAU;wBACV,aAAa;wBACb,YAAY;wBACZ,cAAc;wBACd,kBAAkB;qBACnB;oBACD,YAAY,EAAE;wBACZ,OAAO;wBACP,UAAU;wBACV,aAAa;wBACb,YAAY;wBACZ,cAAc;wBACd,kBAAkB;qBACnB;iBACF,EAAD,EAAA;;IAC+B,OAA/B,gBAAgC,CAAhC;CAAgC,EAAhC,CAAA;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"stepper.es5.js","sources":["../../../src/cdk/stepper/stepper-module.ts","../../../src/cdk/stepper/stepper-button.ts","../../../src/cdk/stepper/stepper.ts","../../../src/cdk/stepper/step-header.ts","../../../src/cdk/stepper/step-label.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {NgModule} from '@angular/core';\nimport {CdkStepper, CdkStep} from './stepper';\nimport {CommonModule} from '@angular/common';\nimport {CdkStepLabel} from './step-label';\nimport {CdkStepperNext, CdkStepperPrevious} from './stepper-button';\nimport {CdkStepHeader} from './step-header';\nimport {BidiModule} from '@angular/cdk/bidi';\n\n@NgModule({\n imports: [BidiModule, CommonModule],\n exports: [\n CdkStep,\n CdkStepper,\n CdkStepHeader,\n CdkStepLabel,\n CdkStepperNext,\n CdkStepperPrevious,\n ],\n declarations: [\n CdkStep,\n CdkStepper,\n CdkStepHeader,\n CdkStepLabel,\n CdkStepperNext,\n CdkStepperPrevious,\n ]\n})\nexport class CdkStepperModule {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directive, Input} from '@angular/core';\nimport {CdkStepper} from './stepper';\n\n/** Button that moves to the next step in a stepper workflow. */\n@Directive({\n selector: 'button[cdkStepperNext]',\n host: {\n '(click)': '_stepper.next()',\n '[type]': 'type',\n }\n})\nexport class CdkStepperNext {\n /** Type of the next button. Defaults to \"submit\" if not specified. */\n @Input() type: string = 'submit';\n\n constructor(public _stepper: CdkStepper) {}\n}\n\n/** Button that moves to the previous step in a stepper workflow. */\n@Directive({\n selector: 'button[cdkStepperPrevious]',\n host: {\n '(click)': '_stepper.previous()',\n '[type]': 'type',\n }\n})\nexport class CdkStepperPrevious {\n /** Type of the previous button. Defaults to \"button\" if not specified. */\n @Input() type: string = 'button';\n\n constructor(public _stepper: CdkStepper) {}\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {FocusableOption, FocusKeyManager} from '@angular/cdk/a11y';\nimport {Direction, Directionality} from '@angular/cdk/bidi';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {END, ENTER, HOME, SPACE, hasModifierKey} from '@angular/cdk/keycodes';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ContentChildren,\n Directive,\n EventEmitter,\n ElementRef,\n forwardRef,\n Inject,\n Input,\n OnChanges,\n OnDestroy,\n Optional,\n Output,\n QueryList,\n TemplateRef,\n ViewChild,\n ViewEncapsulation,\n InjectionToken,\n} from '@angular/core';\nimport {DOCUMENT} from '@angular/common';\nimport {AbstractControl} from '@angular/forms';\nimport {CdkStepLabel} from './step-label';\nimport {Observable, Subject, of as obaservableOf} from 'rxjs';\nimport {startWith, takeUntil} from 'rxjs/operators';\nimport {CdkStepHeader} from './step-header';\n\n/** Used to generate unique ID for each stepper component. */\nlet nextId = 0;\n\n/**\n * Position state of the content of each step in stepper that is used for transitioning\n * the content into correct position upon step selection change.\n */\nexport type StepContentPositionState = 'previous' | 'current' | 'next';\n\n/** Possible orientation of a stepper. */\nexport type StepperOrientation = 'horizontal' | 'vertical';\n\n/** Change event emitted on selection changes. */\nexport class StepperSelectionEvent {\n /** Index of the step now selected. */\n selectedIndex: number;\n\n /** Index of the step previously selected. */\n previouslySelectedIndex: number;\n\n /** The step instance now selected. */\n selectedStep: CdkStep;\n\n /** The step instance previously selected. */\n previouslySelectedStep: CdkStep;\n}\n\n/** The state of each step. */\nexport type StepState = 'number' | 'edit' | 'done' | 'error' | string;\n\n/** Enum to represent the different states of the steps. */\nexport const STEP_STATE = {\n NUMBER: 'number',\n EDIT: 'edit',\n DONE: 'done',\n ERROR: 'error'\n};\n\n/** InjectionToken that can be used to specify the global stepper options. */\nexport const STEPPER_GLOBAL_OPTIONS =\n new InjectionToken<StepperOptions>('STEPPER_GLOBAL_OPTIONS');\n\n/**\n * InjectionToken that can be used to specify the global stepper options.\n * @deprecated Use `STEPPER_GLOBAL_OPTIONS` instead.\n * @breaking-change 8.0.0.\n */\nexport const MAT_STEPPER_GLOBAL_OPTIONS = STEPPER_GLOBAL_OPTIONS;\n\n/** Configurable options for stepper. */\nexport interface StepperOptions {\n /**\n * Whether the stepper should display an error state or not.\n * Default behavior is assumed to be false.\n */\n showError?: boolean;\n\n /**\n * Whether the stepper should display the default indicator type\n * or not.\n * Default behavior is assumed to be true.\n */\n displayDefaultIndicatorType?: boolean;\n}\n\n@Component({\n moduleId: module.id,\n selector: 'cdk-step',\n exportAs: 'cdkStep',\n template: '<ng-template><ng-content></ng-content></ng-template>',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class CdkStep implements OnChanges {\n private _stepperOptions: StepperOptions;\n _showError: boolean;\n _displayDefaultIndicatorType: boolean;\n\n /** Template for step label if it exists. */\n @ContentChild(CdkStepLabel) stepLabel: CdkStepLabel;\n\n /** Template for step content. */\n @ViewChild(TemplateRef) content: TemplateRef<any>;\n\n /** The top level abstract control of the step. */\n @Input() stepControl: AbstractControl;\n\n /** Whether user has seen the expanded step content or not. */\n interacted = false;\n\n /** Plain text label of the step. */\n @Input() label: string;\n\n /** Error message to display when there's an error. */\n @Input() errorMessage: string;\n\n /** Aria label for the tab. */\n @Input('aria-label') ariaLabel: string;\n\n /**\n * Reference to the element that the tab is labelled by.\n * Will be cleared if `aria-label` is set at the same time.\n */\n @Input('aria-labelledby') ariaLabelledby: string;\n\n /** State of the step. */\n @Input() state: StepState;\n\n /** Whether the user can return to this step once it has been marked as completed. */\n @Input()\n get editable(): boolean { return this._editable; }\n set editable(value: boolean) {\n this._editable = coerceBooleanProperty(value);\n }\n private _editable = true;\n\n /** Whether the completion of step is optional. */\n @Input()\n get optional(): boolean { return this._optional; }\n set optional(value: boolean) {\n this._optional = coerceBooleanProperty(value);\n }\n private _optional = false;\n\n /** Whether step is marked as completed. */\n @Input()\n get completed(): boolean {\n return this._customCompleted == null ? this._getDefaultCompleted() : this._customCompleted;\n }\n set completed(value: boolean) {\n this._customCompleted = coerceBooleanProperty(value);\n }\n private _customCompleted: boolean | null = null;\n\n private _getDefaultCompleted() {\n return this.stepControl ? this.stepControl.valid && this.interacted : this.interacted;\n }\n\n /** Whether step has an error. */\n @Input()\n get hasError(): boolean {\n return this._customError == null ? this._getDefaultError() : this._customError;\n }\n set hasError(value: boolean) {\n this._customError = coerceBooleanProperty(value);\n }\n private _customError: boolean | null = null;\n\n private _getDefaultError() {\n return this.stepControl && this.stepControl.invalid && this.interacted;\n }\n\n /** @breaking-change 8.0.0 remove the `?` after `stepperOptions` */\n constructor(\n @Inject(forwardRef(() => CdkStepper)) private _stepper: CdkStepper,\n @Optional() @Inject(STEPPER_GLOBAL_OPTIONS) stepperOptions?: StepperOptions) {\n this._stepperOptions = stepperOptions ? stepperOptions : {};\n this._displayDefaultIndicatorType = this._stepperOptions.displayDefaultIndicatorType !== false;\n this._showError = !!this._stepperOptions.showError;\n }\n\n /** Selects this step component. */\n select(): void {\n this._stepper.selected = this;\n }\n\n /** Resets the step to its initial state. Note that this includes resetting form data. */\n reset(): void {\n this.interacted = false;\n\n if (this._customCompleted != null) {\n this._customCompleted = false;\n }\n\n if (this._customError != null) {\n this._customError = false;\n }\n\n if (this.stepControl) {\n this.stepControl.reset();\n }\n }\n\n ngOnChanges() {\n // Since basically all inputs of the MatStep get proxied through the view down to the\n // underlying MatStepHeader, we have to make sure that change detection runs correctly.\n this._stepper._stateChanged();\n }\n}\n\n@Directive({\n selector: '[cdkStepper]',\n exportAs: 'cdkStepper',\n})\nexport class CdkStepper implements AfterViewInit, OnDestroy {\n /** Emits when the component is destroyed. */\n protected _destroyed = new Subject<void>();\n\n /** Used for managing keyboard focus. */\n private _keyManager: FocusKeyManager<FocusableOption>;\n\n /**\n * @breaking-change 8.0.0 Remove `| undefined` once the `_document`\n * constructor param is required.\n */\n private _document: Document | undefined;\n\n /**\n * The list of step components that the stepper is holding.\n * @deprecated use `steps` instead\n * @breaking-change 9.0.0 remove this property\n */\n @ContentChildren(CdkStep) _steps: QueryList<CdkStep>;\n\n /** The list of step components that the stepper is holding. */\n get steps(): QueryList<CdkStep> {\n return this._steps;\n }\n\n /**\n * The list of step headers of the steps in the stepper.\n * @deprecated Type to be changed to `QueryList<CdkStepHeader>`.\n * @breaking-change 8.0.0\n */\n @ContentChildren(CdkStepHeader) _stepHeader: QueryList<FocusableOption>;\n\n /** Whether the validity of previous steps should be checked or not. */\n @Input()\n get linear(): boolean { return this._linear; }\n set linear(value: boolean) { this._linear = coerceBooleanProperty(value); }\n private _linear = false;\n\n /** The index of the selected step. */\n @Input()\n get selectedIndex() { return this._selectedIndex; }\n set selectedIndex(index: number) {\n if (this.steps) {\n // Ensure that the index can't be out of bounds.\n if (index < 0 || index > this.steps.length - 1) {\n throw Error('cdkStepper: Cannot assign out-of-bounds value to `selectedIndex`.');\n }\n\n if (this._selectedIndex != index &&\n !this._anyControlsInvalidOrPending(index) &&\n (index >= this._selectedIndex || this.steps.toArray()[index].editable)) {\n this._updateSelectedItemIndex(index);\n }\n } else {\n this._selectedIndex = index;\n }\n }\n private _selectedIndex = 0;\n\n /** The step that is selected. */\n @Input()\n get selected(): CdkStep {\n // @breaking-change 8.0.0 Change return type to `CdkStep | undefined`.\n return this.steps ? this.steps.toArray()[this.selectedIndex] : undefined!;\n }\n set selected(step: CdkStep) {\n this.selectedIndex = this.steps ? this.steps.toArray().indexOf(step) : -1;\n }\n\n /** Event emitted when the selected step has changed. */\n @Output() selectionChange: EventEmitter<StepperSelectionEvent>\n = new EventEmitter<StepperSelectionEvent>();\n\n /** Used to track unique ID for each stepper component. */\n _groupId: number;\n\n protected _orientation: StepperOrientation = 'horizontal';\n\n constructor(\n @Optional() private _dir: Directionality,\n private _changeDetectorRef: ChangeDetectorRef,\n // @breaking-change 8.0.0 `_elementRef` and `_document` parameters to become required.\n private _elementRef?: ElementRef<HTMLElement>,\n @Inject(DOCUMENT) _document?: any) {\n this._groupId = nextId++;\n this._document = _document;\n }\n\n ngAfterViewInit() {\n // Note that while the step headers are content children by default, any components that\n // extend this one might have them as view chidren. We initialize the keyboard handling in\n // AfterViewInit so we're guaranteed for both view and content children to be defined.\n this._keyManager = new FocusKeyManager<FocusableOption>(this._stepHeader)\n .withWrap()\n .withVerticalOrientation(this._orientation === 'vertical');\n\n (this._dir ? this._dir.change as Observable<Direction> : obaservableOf<Direction>())\n .pipe(startWith(this._layoutDirection()), takeUntil(this._destroyed))\n .subscribe(direction => this._keyManager.withHorizontalOrientation(direction));\n\n this._keyManager.updateActiveItemIndex(this._selectedIndex);\n\n this.steps.changes.pipe(takeUntil(this._destroyed)).subscribe(() => {\n if (!this.selected) {\n this._selectedIndex = Math.max(this._selectedIndex - 1, 0);\n }\n });\n }\n\n ngOnDestroy() {\n this._destroyed.next();\n this._destroyed.complete();\n }\n\n /** Selects and focuses the next step in list. */\n next(): void {\n this.selectedIndex = Math.min(this._selectedIndex + 1, this.steps.length - 1);\n }\n\n /** Selects and focuses the previous step in list. */\n previous(): void {\n this.selectedIndex = Math.max(this._selectedIndex - 1, 0);\n }\n\n /** Resets the stepper to its initial state. Note that this includes clearing form data. */\n reset(): void {\n this._updateSelectedItemIndex(0);\n this.steps.forEach(step => step.reset());\n this._stateChanged();\n }\n\n /** Returns a unique id for each step label element. */\n _getStepLabelId(i: number): string {\n return `cdk-step-label-${this._groupId}-${i}`;\n }\n\n /** Returns unique id for each step content element. */\n _getStepContentId(i: number): string {\n return `cdk-step-content-${this._groupId}-${i}`;\n }\n\n /** Marks the component to be change detected. */\n _stateChanged() {\n this._changeDetectorRef.markForCheck();\n }\n\n /** Returns position state of the step with the given index. */\n _getAnimationDirection(index: number): StepContentPositionState {\n const position = index - this._selectedIndex;\n if (position < 0) {\n return this._layoutDirection() === 'rtl' ? 'next' : 'previous';\n } else if (position > 0) {\n return this._layoutDirection() === 'rtl' ? 'previous' : 'next';\n }\n return 'current';\n }\n\n /** Returns the type of icon to be displayed. */\n _getIndicatorType(index: number, state: StepState = STEP_STATE.NUMBER): StepState {\n const step = this.steps.toArray()[index];\n const isCurrentStep = this._isCurrentStep(index);\n\n return step._displayDefaultIndicatorType\n ? this._getDefaultIndicatorLogic(step, isCurrentStep)\n : this._getGuidelineLogic(step, isCurrentStep, state);\n }\n\n private _getDefaultIndicatorLogic(step: CdkStep, isCurrentStep: boolean): StepState {\n if (step._showError && step.hasError && !isCurrentStep) {\n return STEP_STATE.ERROR;\n } else if (!step.completed || isCurrentStep) {\n return STEP_STATE.NUMBER;\n } else {\n return step.editable ? STEP_STATE.EDIT : STEP_STATE.DONE;\n }\n }\n\n private _getGuidelineLogic(\n step: CdkStep,\n isCurrentStep: boolean,\n state: StepState = STEP_STATE.NUMBER): StepState {\n if (step._showError && step.hasError && !isCurrentStep) {\n return STEP_STATE.ERROR;\n } else if (step.completed && !isCurrentStep) {\n return STEP_STATE.DONE;\n } else if (step.completed && isCurrentStep) {\n return state;\n } else if (step.editable && isCurrentStep) {\n return STEP_STATE.EDIT;\n } else {\n return state;\n }\n }\n\n private _isCurrentStep(index: number) {\n return this._selectedIndex === index;\n }\n\n /** Returns the index of the currently-focused step header. */\n _getFocusIndex() {\n return this._keyManager ? this._keyManager.activeItemIndex : this._selectedIndex;\n }\n\n private _updateSelectedItemIndex(newIndex: number): void {\n const stepsArray = this.steps.toArray();\n this.selectionChange.emit({\n selectedIndex: newIndex,\n previouslySelectedIndex: this._selectedIndex,\n selectedStep: stepsArray[newIndex],\n previouslySelectedStep: stepsArray[this._selectedIndex],\n });\n\n // If focus is inside the stepper, move it to the next header, otherwise it may become\n // lost when the active step content is hidden. We can't be more granular with the check\n // (e.g. checking whether focus is inside the active step), because we don't have a\n // reference to the elements that are rendering out the content.\n this._containsFocus() ? this._keyManager.setActiveItem(newIndex) :\n this._keyManager.updateActiveItemIndex(newIndex);\n\n this._selectedIndex = newIndex;\n this._stateChanged();\n }\n\n _onKeydown(event: KeyboardEvent) {\n const hasModifier = hasModifierKey(event);\n const keyCode = event.keyCode;\n const manager = this._keyManager;\n\n if (manager.activeItemIndex != null && !hasModifier &&\n (keyCode === SPACE || keyCode === ENTER)) {\n this.selectedIndex = manager.activeItemIndex;\n event.preventDefault();\n } else if (keyCode === HOME) {\n manager.setFirstItemActive();\n event.preventDefault();\n } else if (keyCode === END) {\n manager.setLastItemActive();\n event.preventDefault();\n } else {\n manager.onKeydown(event);\n }\n }\n\n private _anyControlsInvalidOrPending(index: number): boolean {\n const steps = this.steps.toArray();\n\n steps[this._selectedIndex].interacted = true;\n\n if (this._linear && index >= 0) {\n return steps.slice(0, index).some(step => {\n const control = step.stepControl;\n const isIncomplete = control ?\n (control.invalid || control.pending || !step.interacted) :\n !step.completed;\n return isIncomplete && !step.optional;\n });\n }\n\n return false;\n }\n\n private _layoutDirection(): Direction {\n return this._dir && this._dir.value === 'rtl' ? 'rtl' : 'ltr';\n }\n\n /** Checks whether the stepper contains the focused element. */\n private _containsFocus(): boolean {\n if (!this._document || !this._elementRef) {\n return false;\n }\n\n const stepperElement = this._elementRef.nativeElement;\n const focusedElement = this._document.activeElement;\n return stepperElement === focusedElement || stepperElement.contains(focusedElement);\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directive, ElementRef} from '@angular/core';\nimport {FocusableOption} from '@angular/cdk/a11y';\n\n\n@Directive({\n selector: '[cdkStepHeader]',\n host: {\n 'role': 'tab',\n },\n})\nexport class CdkStepHeader implements FocusableOption {\n constructor(protected _elementRef: ElementRef<HTMLElement>) {}\n\n /** Focuses the step header. */\n focus() {\n this._elementRef.nativeElement.focus();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directive, TemplateRef} from '@angular/core';\n\n@Directive({\n selector: '[cdkStepLabel]',\n})\nexport class CdkStepLabel {\n constructor(/** @docs-private */ public template: TemplateRef<any>) { }\n}\n"],"names":["obaservableOf"],"mappings":";;;;;;;;;;;;;;;;;;;;;AIUA,IAAA,YAAA,kBAAA,YAAA;IAIE,SAAF,YAAA,sBA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AA,EAAA,IAAA,EAAG,KAAK,EAAR,CAAA;;IAGA,OAAA,kBAAC,CAAD;CAAC,EAAD,CAAA;;;;;;ADvBA,IAAA,gBAAA,kBAAA,YAAA;IAAA,SAAA,gBAAA,GAAA;KAmBgC;;QAnBhC,EAAA,IAAA,EAAC,QAAQ,EAAT,IAAA,EAAA,CAAU;oBACR,OAAO,EAAE,CAAC,UAAU,EAAE,YAAY,CAAC;oBACnC,OAAO,EAAE;wBACP,OAAO;wBACP,UAAU;wBACV,aAAa;wBACb,YAAY;wBACZ,cAAc;wBACd,kBAAkB;qBACnB;oBACD,YAAY,EAAE;wBACZ,OAAO;wBACP,UAAU;wBACV,aAAa;wBACb,YAAY;wBACZ,cAAc;wBACd,kBAAkB;qBACnB;iBACF,EAAD,EAAA;;IAC+B,OAA/B,gBAAgC,CAAhC;CAAgC,EAAhC,CAAA;;;;;;;;;;;;;;"}
|
package/esm5/table.es5.js
CHANGED
|
@@ -2451,6 +2451,11 @@ var CdkTable = /** @class */ (function () {
|
|
|
2451
2451
|
* @return {?}
|
|
2452
2452
|
*/
|
|
2453
2453
|
function () {
|
|
2454
|
+
// @breaking-change 8.0.0 remove the `|| document` once the `_document` is a required param.
|
|
2455
|
+
/** @type {?} */
|
|
2456
|
+
var documentRef = this._document || document;
|
|
2457
|
+
/** @type {?} */
|
|
2458
|
+
var documentFragment = documentRef.createDocumentFragment();
|
|
2454
2459
|
/** @type {?} */
|
|
2455
2460
|
var sections = [
|
|
2456
2461
|
{ tag: 'thead', outlet: this._headerRowOutlet },
|
|
@@ -2459,14 +2464,13 @@ var CdkTable = /** @class */ (function () {
|
|
|
2459
2464
|
];
|
|
2460
2465
|
for (var _a = 0, sections_1 = sections; _a < sections_1.length; _a++) {
|
|
2461
2466
|
var section = sections_1[_a];
|
|
2462
|
-
// @breaking-change 8.0.0 remove the `|| document` once the `_document` is a required param.
|
|
2463
|
-
/** @type {?} */
|
|
2464
|
-
var documentRef = this._document || document;
|
|
2465
2467
|
/** @type {?} */
|
|
2466
2468
|
var element = documentRef.createElement(section.tag);
|
|
2467
2469
|
element.appendChild(section.outlet.elementRef.nativeElement);
|
|
2468
|
-
|
|
2470
|
+
documentFragment.appendChild(element);
|
|
2469
2471
|
}
|
|
2472
|
+
// Use a DocumentFragment so we don't hit the DOM on each iteration.
|
|
2473
|
+
this._elementRef.nativeElement.appendChild(documentFragment);
|
|
2470
2474
|
};
|
|
2471
2475
|
/**
|
|
2472
2476
|
* Forces a re-render of the data rows. Should be called in cases where there has been an input
|