blob: f0cbedf313e4e6051466d3bfcf060a701d7ee7e3 [file] [log] [blame]
{"version":3,"sources":["src/cdk/cdk-table.umd.js"],"names":["global","factory","exports","module","require","define","amd","self","ng","cdk","table","bidi","coercion","collections","platform","scrolling","common","core","rxjs","operators","this","extendStatics","d","b","Object","setPrototypeOf","__proto__","Array","p","prototype","hasOwnProperty","call","__extends","TypeError","String","__","constructor","create","__values","o","s","Symbol","iterator","m","i","length","next","value","done","__read","n","r","e","ar","push","error","__spread","arguments","concat","mixinHasStickyInput","base","_super","class_1","args","_i","_this","apply","_sticky","_hasStickyChanged","defineProperty","get","set","v","prevValue","coerceBooleanProperty","enumerable","configurable","hasStickyChanged","resetStickyChanged","CdkCellDef","CdkHeaderCellDef","CdkFooterCellDef","CDK_TABLE","InjectionToken","TEXT_COLUMN_OPTIONS","template","decorators","type","Directive","selector","ctorParameters","TemplateRef","CdkColumnDef","_table","_stickyEnd","_name","name","_setNameInput","_updateColumnCssClassName","_columnCssClassName","cssClassFriendlyName","replace","CdkColumnDefBase","inputs","providers","provide","useExisting","undefined","Inject","Optional","propDecorators","Input","stickyEnd","cell","ContentChild","headerCell","footerCell","BaseCdkCell","CdkHeaderCell","columnDef","elementRef","e_1","_a","classList","nativeElement","_b","_c","add","e_1_1","return","host","class","role","ElementRef","CdkFooterCell","CdkCell","_Schedule","tasks","endTasks","_COALESCED_STYLE_SCHEDULER","_CoalescedStyleScheduler","_ngZone","_currentSchedule","_destroyed","Subject","schedule","task","_createScheduleIfNeeded","scheduleEnd","ngOnDestroy","complete","_getScheduleObservable","pipe","takeUntil","subscribe","e_2","_d","_e","_f","e_2_1","isStable","from","Promise","resolve","onStable","take","Injectable","NgZone","CDK_ROW_TEMPLATE","BaseRowDef","_differs","ngOnChanges","changes","_columnsDiffer","columns","currentValue","find","diff","getColumnsDiff","extractCellTemplate","column","CdkHeaderRowDef","CdkFooterRowDef","IterableDiffers","CdkHeaderRowDefBase","CdkFooterRowDefBase","CdkRowDef","CdkHeaderRow","CdkFooterRow","CdkRow","CdkNoDataRow","CdkCellOutlet","_viewContainer","mostRecentCellOutlet","ViewContainerRef","Component","changeDetection","ChangeDetectionStrategy","Default","encapsulation","ViewEncapsulation","None","templateRef","DataRowOutlet","HeaderRowOutlet","FooterRowOutlet","NoDataRowOutlet","STICKY_DIRECTIONS","StickyStyler","_isNativeHtmlTable","_stickCellCss","direction","_coalescedStyleScheduler","_isBrowser","_needsPositionStickyOnElement","_positionListener","_cachedCellWidths","_borderCellCss","top","bottom","left","right","clearStickyPositioning","rows","stickyDirections","elementsToClear","rows_1","rows_1_1","row","nodeType","ELEMENT_NODE","children","_scheduleStyleChanges","elementsToClear_1","elementsToClear_1_1","_removeStickyStyle","updateStickyColumns","stickyStartStates","stickyEndStates","recalculateCellWidths","some","state","firstRow","numCells","cellWidths","_getCellWidths","startPositions","_getStickyStartColumnPositions","endPositions","_getStickyEndColumnPositions","lastStickyStart","lastIndexOf","firstStickyEnd","indexOf","e_3","isRtl","start","end","rows_2","rows_2_1","_addStickyStyle","e_3_1","stickyColumnsUpdated","sizes","slice","map","width","index","stickyEndColumnsUpdated","reverse","stickRows","rowsToStick","stickyStates","position","states","stickyOffsets","stickyCellHeights","elementsToStick","rowIndex","stickyOffset","height","getBoundingClientRect","borderedRowIndex","e_4","offset","isBorderedRowIndex","e_4_1","stickyHeaderRowsUpdated","elements","stickyFooterRowsUpdated","updateStickyFooterContainer","tableElement","tfoot","querySelector","element","e_5","stickyDirections_1","stickyDirections_1_1","dir","style","remove","e_5_1","zIndex","_getCalculatedZIndex","dirValue","isBorderElement","cssText","e_6","zIndexIncrements","STICKY_DIRECTIONS_1","STICKY_DIRECTIONS_1_1","e_6_1","firstRowCells","widths","positions","nextPosition","STICKY_POSITIONING_LISTENER","viewContainer","CDK_TABLE_TEMPLATE","CdkTable","RowViewRef","EmbeddedViewRef","_changeDetectorRef","_elementRef","_dir","_document","_platform","_viewRepeater","_stickyPositioningListener","_viewportRuler","_onDestroy","_columnDefsByName","Map","_customColumnDefs","Set","_customRowDefs","_customHeaderRowDefs","_customFooterRowDefs","_headerRowDefChanged","_footerRowDefChanged","_stickyColumnStylesNeedReset","_forceRecalculateCellWidths","_cachedRenderRowsMap","stickyCssClass","needsPositionStickyOnElement","_isShowingNoDataRow","_multiTemplateDataRows","_fixedLayout","viewChange","BehaviorSubject","Number","MAX_VALUE","setAttribute","nodeName","_trackByFn","fn","_dataSource","dataSource","_switchDataSource","_rowOutlet","_forceRenderDataRows","updateStickyColumnStyles","ngOnInit","_setupStickyStyler","_applyNativeTableSections","_dataDiffer","dataRow","trackBy","dataIndex","data","change","ngAfterContentChecked","_cacheRowDefs","_cacheColumnDefs","rowDefsChanged","_renderUpdatedColumns","_forceRenderHeaderRows","_forceRenderFooterRows","_rowDefs","_renderChangeSubscription","_observeRenderChanges","_checkStickyStates","clear","_noDataRowOutlet","_headerRowOutlet","_footerRowOutlet","isDataSource","disconnect","renderRows","_renderRows","_getAllRenderRows","applyChanges","record","_adjustedPreviousIndex","currentIndex","_getEmbeddedViewArgs","item","operation","context","_renderCellTemplateForItem","rowDef","forEachOperation","prevIndex","previousIndex","renderRow","_renderRow","$implicit","view","move","_updateRowIndexContext","forEachIdentityChange","_updateNoDataRow","addColumnDef","removeColumnDef","delete","addRowDef","removeRowDef","addHeaderRowDef","headerRowDef","removeHeaderRowDef","addFooterRowDef","footerRowDef","removeFooterRowDef","setNoDataRow","noDataRow","_customNoDataRow","updateStickyHeaderRowStyles","headerRows","_getRenderedRows","thead","display","_headerRowDefs","def","sticky","_stickyStyler","forEach","updateStickyFooterRowStyles","footerRows","_footerRowDefs","dataRows","headerRow","_addStickyColumnStyles","footerRow","values","prevCachedRenderRows","_data","renderRowsForData","_getRenderRowsForData","has","WeakMap","j","cache","_getRowDefs","cachedRenderRows","shift","mergeArrayAndSet","_getOwnDefs","_contentColumnDefs","_contentHeaderRowDefs","_contentFooterRowDefs","_contentRowDefs","defaultRowDefs","filter","when","_defaultRowDef","columnsDiffReducer","acc","dataColumnsChanged","reduce","headerColumnsChanged","footerColumnsChanged","unsubscribe","dataStream","connect","isObservable","isArray","of","columnDefs","columnName","rowOutlet","renderedRows","viewRef","rootNodes","rowDefs","multiTemplateDataRows","outlet","createEmbeddedView","_getCellTemplates","markForCheck","renderIndex","count","first","last","even","odd","columnId","documentFragment","createDocumentFragment","sections","tag","outlets","sections_1","sections_1_1","section","createElement","appendChild","stickyCheckReducer","isBrowser","items","_noDataRow","shouldShow","container","array","exportAs","[class.cdk-table-fixed-layout]","_VIEW_REPEATER_STRATEGY","useClass","_DisposeViewRepeaterStrategy","useValue","styles","ChangeDetectorRef","Attribute","Directionality","DOCUMENT","Platform","SkipSelf","ViewportRuler","fixedLayout","ViewChild","static","ContentChildren","descendants","CdkTextColumn","_options","justify","_syncColumnDefName","headerText","_createDefaultHeaderText","dataAccessor","defaultDataAccessor","defaultHeaderTextTransform","toUpperCase","CdkTableModule","EXPORTED_DECLARATIONS","NgModule","declarations","imports","ScrollingModule","DataSource"],"mappings":"CAAC,SAAUA,EAAQC,GACI,iBAAZC,SAA0C,oBAAXC,OAAyBF,EAAQC,QAASE,QAAQ,qBAAsBA,QAAQ,yBAA0BA,QAAQ,4BAA6BA,QAAQ,yBAA0BA,QAAQ,0BAA2BA,QAAQ,mBAAoBA,QAAQ,iBAAkBA,QAAQ,QAASA,QAAQ,mBACvT,mBAAXC,QAAyBA,OAAOC,IAAMD,OAAO,qBAAsB,CAAC,UAAW,oBAAqB,wBAAyB,2BAA4B,wBAAyB,yBAA0B,kBAAmB,gBAAiB,OAAQ,kBAAmBJ,GACxPA,IAAzBD,EAASA,GAAUO,MAAsBC,GAAKR,EAAOQ,IAAM,GAAIR,EAAOQ,GAAGC,IAAMT,EAAOQ,GAAGC,KAAO,GAAIT,EAAOQ,GAAGC,IAAIC,MAAQ,IAAKV,EAAOQ,GAAGC,IAAIE,KAAMX,EAAOQ,GAAGC,IAAIG,SAAUZ,EAAOQ,GAAGC,IAAII,YAAab,EAAOQ,GA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ACpBtI,EAAQyD,oBAAsBA,EAE9BnC,OAAO6C,eAAenE,EAAS,aAAc,CAAE6C,OAAO","sourcesContent":["(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/cdk/bidi'), require('@angular/cdk/coercion'), require('@angular/cdk/collections'), require('@angular/cdk/platform'), require('@angular/cdk/scrolling'), require('@angular/common'), require('@angular/core'), require('rxjs'), require('rxjs/operators')) :\n typeof define === 'function' && define.amd ? define('@angular/cdk/table', ['exports', '@angular/cdk/bidi', '@angular/cdk/coercion', '@angular/cdk/collections', '@angular/cdk/platform', '@angular/cdk/scrolling', '@angular/common', '@angular/core', 'rxjs', 'rxjs/operators'], factory) :\n (global = global || self, factory((global.ng = global.ng || {}, global.ng.cdk = global.ng.cdk || {}, global.ng.cdk.table = {}), global.ng.cdk.bidi, global.ng.cdk.coercion, global.ng.cdk.collections, global.ng.cdk.platform, global.ng.cdk.scrolling, global.ng.common, global.ng.core, global.rxjs, global.rxjs.operators));\n}(this, (function (exports, bidi, coercion, collections, platform, scrolling, common, core, rxjs, operators) { 'use strict';\n\n /*! *****************************************************************************\n Copyright (c) Microsoft Corporation.\n\n Permission to use, copy, modify, and/or distribute this software for any\n purpose with or without fee is hereby granted.\n\n THE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\n REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\n AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\n INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\n LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\n OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\n PERFORMANCE OF THIS SOFTWARE.\n ***************************************************************************** */\n /* global Reflect, Promise */\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b)\n if (Object.prototype.hasOwnProperty.call(b, p))\n d[p] = b[p]; };\n return extendStatics(d, b);\n };\n function __extends(d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n }\n var __assign = function () {\n __assign = Object.assign || function __assign(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s)\n if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n };\n function __rest(s, e) {\n var t = {};\n for (var p in s)\n if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\n t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\n t[p[i]] = s[p[i]];\n }\n return t;\n }\n function __decorate(decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\")\n r = Reflect.decorate(decorators, target, key, desc);\n else\n for (var i = decorators.length - 1; i >= 0; i--)\n if (d = decorators[i])\n r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n }\n function __param(paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); };\n }\n function __metadata(metadataKey, metadataValue) {\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\")\n return Reflect.metadata(metadataKey, metadataValue);\n }\n function __awaiter(thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try {\n step(generator.next(value));\n }\n catch (e) {\n reject(e);\n } }\n function rejected(value) { try {\n step(generator[\"throw\"](value));\n }\n catch (e) {\n reject(e);\n } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n }\n function __generator(thisArg, body) {\n var _ = { label: 0, sent: function () { if (t[0] & 1)\n throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function () { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f)\n throw new TypeError(\"Generator is already executing.\");\n while (_)\n try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)\n return t;\n if (y = 0, t)\n op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0:\n case 1:\n t = op;\n break;\n case 4:\n _.label++;\n return { value: op[1], done: false };\n case 5:\n _.label++;\n y = op[1];\n op = [0];\n continue;\n case 7:\n op = _.ops.pop();\n _.trys.pop();\n continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {\n _ = 0;\n continue;\n }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {\n _.label = op[1];\n break;\n }\n if (op[0] === 6 && _.label < t[1]) {\n _.label = t[1];\n t = op;\n break;\n }\n if (t && _.label < t[2]) {\n _.label = t[2];\n _.ops.push(op);\n break;\n }\n if (t[2])\n _.ops.pop();\n _.trys.pop();\n continue;\n }\n op = body.call(thisArg, _);\n }\n catch (e) {\n op = [6, e];\n y = 0;\n }\n finally {\n f = t = 0;\n }\n if (op[0] & 5)\n throw op[1];\n return { value: op[0] ? op[1] : void 0, done: true };\n }\n }\n var __createBinding = Object.create ? (function (o, m, k, k2) {\n if (k2 === undefined)\n k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function () { return m[k]; } });\n }) : (function (o, m, k, k2) {\n if (k2 === undefined)\n k2 = k;\n o[k2] = m[k];\n });\n function __exportStar(m, o) {\n for (var p in m)\n if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p))\n __createBinding(o, m, p);\n }\n function __values(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m)\n return m.call(o);\n if (o && typeof o.length === \"number\")\n return {\n next: function () {\n if (o && i >= o.length)\n o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n }\n function __read(o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m)\n return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done)\n ar.push(r.value);\n }\n catch (error) {\n e = { error: error };\n }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"]))\n m.call(i);\n }\n finally {\n if (e)\n throw e.error;\n }\n }\n return ar;\n }\n /** @deprecated */\n function __spread() {\n for (var ar = [], i = 0; i < arguments.length; i++)\n ar = ar.concat(__read(arguments[i]));\n return ar;\n }\n /** @deprecated */\n function __spreadArrays() {\n for (var s = 0, i = 0, il = arguments.length; i < il; i++)\n s += arguments[i].length;\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\n r[k] = a[j];\n return r;\n }\n function __spreadArray(to, from) {\n for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)\n to[j] = from[i];\n return to;\n }\n function __await(v) {\n return this instanceof __await ? (this.v = v, this) : new __await(v);\n }\n function __asyncGenerator(thisArg, _arguments, generator) {\n if (!Symbol.asyncIterator)\n throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\n function verb(n) { if (g[n])\n i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\n function resume(n, v) { try {\n step(g[n](v));\n }\n catch (e) {\n settle(q[0][3], e);\n } }\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\n function fulfill(value) { resume(\"next\", value); }\n function reject(value) { resume(\"throw\", value); }\n function settle(f, v) { if (f(v), q.shift(), q.length)\n resume(q[0][0], q[0][1]); }\n }\n function __asyncDelegator(o) {\n var i, p;\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\n }\n function __asyncValues(o) {\n if (!Symbol.asyncIterator)\n throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var m = o[Symbol.asyncIterator], i;\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }\n }\n function __makeTemplateObject(cooked, raw) {\n if (Object.defineProperty) {\n Object.defineProperty(cooked, \"raw\", { value: raw });\n }\n else {\n cooked.raw = raw;\n }\n return cooked;\n }\n ;\n var __setModuleDefault = Object.create ? (function (o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n }) : function (o, v) {\n o[\"default\"] = v;\n };\n function __importStar(mod) {\n if (mod && mod.__esModule)\n return mod;\n var result = {};\n if (mod != null)\n for (var k in mod)\n if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k))\n __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n }\n function __importDefault(mod) {\n return (mod && mod.__esModule) ? mod : { default: mod };\n }\n function __classPrivateFieldGet(receiver, privateMap) {\n if (!privateMap.has(receiver)) {\n throw new TypeError(\"attempted to get private field on non-instance\");\n }\n return privateMap.get(receiver);\n }\n function __classPrivateFieldSet(receiver, privateMap, value) {\n if (!privateMap.has(receiver)) {\n throw new TypeError(\"attempted to set private field on non-instance\");\n }\n privateMap.set(receiver, value);\n return value;\n }\n\n /**\n * Mixin to provide a directive with a function that checks if the sticky input has been\n * changed since the last time the function was called. Essentially adds a dirty-check to the\n * sticky value.\n * @docs-private\n */\n function mixinHasStickyInput(base) {\n return /** @class */ (function (_super) {\n __extends(class_1, _super);\n function class_1() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var _this = _super.apply(this, __spread(args)) || this;\n _this._sticky = false;\n /** Whether the sticky input has changed since it was last checked. */\n _this._hasStickyChanged = false;\n return _this;\n }\n Object.defineProperty(class_1.prototype, \"sticky\", {\n /** Whether sticky positioning should be applied. */\n get: function () { return this._sticky; },\n set: function (v) {\n var prevValue = this._sticky;\n this._sticky = coercion.coerceBooleanProperty(v);\n this._hasStickyChanged = prevValue !== this._sticky;\n },\n enumerable: false,\n configurable: true\n });\n /** Whether the sticky value has changed since this was last called. */\n class_1.prototype.hasStickyChanged = function () {\n var hasStickyChanged = this._hasStickyChanged;\n this._hasStickyChanged = false;\n return hasStickyChanged;\n };\n /** Resets the dirty check for cases where the sticky state has been used without checking. */\n class_1.prototype.resetStickyChanged = function () {\n this._hasStickyChanged = false;\n };\n return class_1;\n }(base));\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 /**\n * Used to provide a table to some of the sub-components without causing a circular dependency.\n * @docs-private\n */\n var CDK_TABLE = new core.InjectionToken('CDK_TABLE');\n /** Injection token that can be used to specify the text column options. */\n var TEXT_COLUMN_OPTIONS = new core.InjectionToken('text-column-options');\n\n /**\n * Cell definition for a CDK table.\n * Captures the template of a column's data row cell as well as cell-specific properties.\n */\n var CdkCellDef = /** @class */ (function () {\n function CdkCellDef(/** @docs-private */ template) {\n this.template = template;\n }\n return CdkCellDef;\n }());\n CdkCellDef.decorators = [\n { type: core.Directive, args: [{ selector: '[cdkCellDef]' },] }\n ];\n CdkCellDef.ctorParameters = function () { return [\n { type: core.TemplateRef }\n ]; };\n /**\n * Header cell definition for a CDK table.\n * Captures the template of a column's header cell and as well as cell-specific properties.\n */\n var CdkHeaderCellDef = /** @class */ (function () {\n function CdkHeaderCellDef(/** @docs-private */ template) {\n this.template = template;\n }\n return CdkHeaderCellDef;\n }());\n CdkHeaderCellDef.decorators = [\n { type: core.Directive, args: [{ selector: '[cdkHeaderCellDef]' },] }\n ];\n CdkHeaderCellDef.ctorParameters = function () { return [\n { type: core.TemplateRef }\n ]; };\n /**\n * Footer cell definition for a CDK table.\n * Captures the template of a column's footer cell and as well as cell-specific properties.\n */\n var CdkFooterCellDef = /** @class */ (function () {\n function CdkFooterCellDef(/** @docs-private */ template) {\n this.template = template;\n }\n return CdkFooterCellDef;\n }());\n CdkFooterCellDef.decorators = [\n { type: core.Directive, args: [{ selector: '[cdkFooterCellDef]' },] }\n ];\n CdkFooterCellDef.ctorParameters = function () { return [\n { type: core.TemplateRef }\n ]; };\n // Boilerplate for applying mixins to CdkColumnDef.\n /** @docs-private */\n var CdkColumnDefBase = /** @class */ (function () {\n function CdkColumnDefBase() {\n }\n return CdkColumnDefBase;\n }());\n var _CdkColumnDefBase = mixinHasStickyInput(CdkColumnDefBase);\n /**\n * Column definition for the CDK table.\n * Defines a set of cells available for a table column.\n */\n var CdkColumnDef = /** @class */ (function (_super) {\n __extends(CdkColumnDef, _super);\n function CdkColumnDef(_table) {\n var _this = _super.call(this) || this;\n _this._table = _table;\n _this._stickyEnd = false;\n return _this;\n }\n Object.defineProperty(CdkColumnDef.prototype, \"name\", {\n /** Unique name for this column. */\n get: function () { return this._name; },\n set: function (name) { this._setNameInput(name); },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(CdkColumnDef.prototype, \"stickyEnd\", {\n /**\n * Whether this column should be sticky positioned on the end of the row. Should make sure\n * that it mimics the `CanStick` mixin such that `_hasStickyChanged` is set to true if the value\n * has been changed.\n */\n get: function () {\n return this._stickyEnd;\n },\n set: function (v) {\n var prevValue = this._stickyEnd;\n this._stickyEnd = coercion.coerceBooleanProperty(v);\n this._hasStickyChanged = prevValue !== this._stickyEnd;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Overridable method that sets the css classes that will be added to every cell in this\n * column.\n * In the future, columnCssClassName will change from type string[] to string and this\n * will set a single string value.\n * @docs-private\n */\n CdkColumnDef.prototype._updateColumnCssClassName = function () {\n this._columnCssClassName = [\"cdk-column-\" + this.cssClassFriendlyName];\n };\n /**\n * This has been extracted to a util because of TS 4 and VE.\n * View Engine doesn't support property rename inheritance.\n * TS 4.0 doesn't allow properties to override accessors or vice-versa.\n * @docs-private\n */\n CdkColumnDef.prototype._setNameInput = function (value) {\n // If the directive is set without a name (updated programmatically), then this setter will\n // trigger with an empty string and should not overwrite the programmatically set value.\n if (value) {\n this._name = value;\n this.cssClassFriendlyName = value.replace(/[^a-z0-9_-]/ig, '-');\n this._updateColumnCssClassName();\n }\n };\n return CdkColumnDef;\n }(_CdkColumnDefBase));\n CdkColumnDef.decorators = [\n { type: core.Directive, args: [{\n selector: '[cdkColumnDef]',\n inputs: ['sticky'],\n providers: [{ provide: 'MAT_SORT_HEADER_COLUMN_DEF', useExisting: CdkColumnDef }],\n },] }\n ];\n CdkColumnDef.ctorParameters = function () { return [\n { type: undefined, decorators: [{ type: core.Inject, args: [CDK_TABLE,] }, { type: core.Optional }] }\n ]; };\n CdkColumnDef.propDecorators = {\n name: [{ type: core.Input, args: ['cdkColumnDef',] }],\n stickyEnd: [{ type: core.Input, args: ['stickyEnd',] }],\n cell: [{ type: core.ContentChild, args: [CdkCellDef,] }],\n headerCell: [{ type: core.ContentChild, args: [CdkHeaderCellDef,] }],\n footerCell: [{ type: core.ContentChild, args: [CdkFooterCellDef,] }]\n };\n /** Base class for the cells. Adds a CSS classname that identifies the column it renders in. */\n var BaseCdkCell = /** @class */ (function () {\n function BaseCdkCell(columnDef, elementRef) {\n var e_1, _a;\n // If IE 11 is dropped before we switch to setting a single class name, change to multi param\n // with destructuring.\n var classList = elementRef.nativeElement.classList;\n try {\n for (var _b = __values(columnDef._columnCssClassName), _c = _b.next(); !_c.done; _c = _b.next()) {\n var className = _c.value;\n classList.add(className);\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (_c && !_c.done && (_a = _b.return)) _a.call(_b);\n }\n finally { if (e_1) throw e_1.error; }\n }\n }\n return BaseCdkCell;\n }());\n /** Header cell template container that adds the right classes and role. */\n var CdkHeaderCell = /** @class */ (function (_super) {\n __extends(CdkHeaderCell, _super);\n function CdkHeaderCell(columnDef, elementRef) {\n return _super.call(this, columnDef, elementRef) || this;\n }\n return CdkHeaderCell;\n }(BaseCdkCell));\n CdkHeaderCell.decorators = [\n { type: core.Directive, args: [{\n selector: 'cdk-header-cell, th[cdk-header-cell]',\n host: {\n 'class': 'cdk-header-cell',\n 'role': 'columnheader',\n },\n },] }\n ];\n CdkHeaderCell.ctorParameters = function () { return [\n { type: CdkColumnDef },\n { type: core.ElementRef }\n ]; };\n /** Footer cell template container that adds the right classes and role. */\n var CdkFooterCell = /** @class */ (function (_super) {\n __extends(CdkFooterCell, _super);\n function CdkFooterCell(columnDef, elementRef) {\n return _super.call(this, columnDef, elementRef) || this;\n }\n return CdkFooterCell;\n }(BaseCdkCell));\n CdkFooterCell.decorators = [\n { type: core.Directive, args: [{\n selector: 'cdk-footer-cell, td[cdk-footer-cell]',\n host: {\n 'class': 'cdk-footer-cell',\n 'role': 'gridcell',\n },\n },] }\n ];\n CdkFooterCell.ctorParameters = function () { return [\n { type: CdkColumnDef },\n { type: core.ElementRef }\n ]; };\n /** Cell template container that adds the right classes and role. */\n var CdkCell = /** @class */ (function (_super) {\n __extends(CdkCell, _super);\n function CdkCell(columnDef, elementRef) {\n return _super.call(this, columnDef, elementRef) || this;\n }\n return CdkCell;\n }(BaseCdkCell));\n CdkCell.decorators = [\n { type: core.Directive, args: [{\n selector: 'cdk-cell, td[cdk-cell]',\n host: {\n 'class': 'cdk-cell',\n 'role': 'gridcell',\n },\n },] }\n ];\n CdkCell.ctorParameters = function () { return [\n { type: CdkColumnDef },\n { type: core.ElementRef }\n ]; };\n\n /**\n * @docs-private\n */\n var _Schedule = /** @class */ (function () {\n function _Schedule() {\n this.tasks = [];\n this.endTasks = [];\n }\n return _Schedule;\n }());\n /** Injection token used to provide a coalesced style scheduler. */\n var _COALESCED_STYLE_SCHEDULER = new core.InjectionToken('_COALESCED_STYLE_SCHEDULER');\n /**\n * Allows grouping up CSSDom mutations after the current execution context.\n * This can significantly improve performance when separate consecutive functions are\n * reading from the CSSDom and then mutating it.\n *\n * @docs-private\n */\n var _CoalescedStyleScheduler = /** @class */ (function () {\n function _CoalescedStyleScheduler(_ngZone) {\n this._ngZone = _ngZone;\n this._currentSchedule = null;\n this._destroyed = new rxjs.Subject();\n }\n /**\n * Schedules the specified task to run at the end of the current VM turn.\n */\n _CoalescedStyleScheduler.prototype.schedule = function (task) {\n this._createScheduleIfNeeded();\n this._currentSchedule.tasks.push(task);\n };\n /**\n * Schedules the specified task to run after other scheduled tasks at the end of the current\n * VM turn.\n */\n _CoalescedStyleScheduler.prototype.scheduleEnd = function (task) {\n this._createScheduleIfNeeded();\n this._currentSchedule.endTasks.push(task);\n };\n /** Prevent any further tasks from running. */\n _CoalescedStyleScheduler.prototype.ngOnDestroy = function () {\n this._destroyed.next();\n this._destroyed.complete();\n };\n _CoalescedStyleScheduler.prototype._createScheduleIfNeeded = function () {\n var _this = this;\n if (this._currentSchedule) {\n return;\n }\n this._currentSchedule = new _Schedule();\n this._getScheduleObservable().pipe(operators.takeUntil(this._destroyed)).subscribe(function () {\n var e_1, _a, e_2, _b;\n while (_this._currentSchedule.tasks.length || _this._currentSchedule.endTasks.length) {\n var schedule = _this._currentSchedule;\n // Capture new tasks scheduled by the current set of tasks.\n _this._currentSchedule = new _Schedule();\n try {\n for (var _c = (e_1 = void 0, __values(schedule.tasks)), _d = _c.next(); !_d.done; _d = _c.next()) {\n var task = _d.value;\n task();\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (_d && !_d.done && (_a = _c.return)) _a.call(_c);\n }\n finally { if (e_1) throw e_1.error; }\n }\n try {\n for (var _e = (e_2 = void 0, __values(schedule.endTasks)), _f = _e.next(); !_f.done; _f = _e.next()) {\n var task = _f.value;\n task();\n }\n }\n catch (e_2_1) { e_2 = { error: e_2_1 }; }\n finally {\n try {\n if (_f && !_f.done && (_b = _e.return)) _b.call(_e);\n }\n finally { if (e_2) throw e_2.error; }\n }\n }\n _this._currentSchedule = null;\n });\n };\n _CoalescedStyleScheduler.prototype._getScheduleObservable = function () {\n // Use onStable when in the context of an ongoing change detection cycle so that we\n // do not accidentally trigger additional cycles.\n return this._ngZone.isStable ?\n rxjs.from(Promise.resolve(undefined)) :\n this._ngZone.onStable.pipe(operators.take(1));\n };\n return _CoalescedStyleScheduler;\n }());\n _CoalescedStyleScheduler.decorators = [\n { type: core.Injectable }\n ];\n _CoalescedStyleScheduler.ctorParameters = function () { return [\n { type: core.NgZone }\n ]; };\n\n /**\n * The row template that can be used by the mat-table. Should not be used outside of the\n * material library.\n */\n var CDK_ROW_TEMPLATE = \"<ng-container cdkCellOutlet></ng-container>\";\n /**\n * Base class for the CdkHeaderRowDef and CdkRowDef that handles checking their columns inputs\n * for changes and notifying the table.\n */\n var BaseRowDef = /** @class */ (function () {\n function BaseRowDef(\n /** @docs-private */ template, _differs) {\n this.template = template;\n this._differs = _differs;\n }\n BaseRowDef.prototype.ngOnChanges = function (changes) {\n // Create a new columns differ if one does not yet exist. Initialize it based on initial value\n // of the columns property or an empty array if none is provided.\n if (!this._columnsDiffer) {\n var columns = (changes['columns'] && changes['columns'].currentValue) || [];\n this._columnsDiffer = this._differs.find(columns).create();\n this._columnsDiffer.diff(columns);\n }\n };\n /**\n * Returns the difference between the current columns and the columns from the last diff, or null\n * if there is no difference.\n */\n BaseRowDef.prototype.getColumnsDiff = function () {\n return this._columnsDiffer.diff(this.columns);\n };\n /** Gets this row def's relevant cell template from the provided column def. */\n BaseRowDef.prototype.extractCellTemplate = function (column) {\n if (this instanceof CdkHeaderRowDef) {\n return column.headerCell.template;\n }\n if (this instanceof CdkFooterRowDef) {\n return column.footerCell.template;\n }\n else {\n return column.cell.template;\n }\n };\n return BaseRowDef;\n }());\n BaseRowDef.decorators = [\n { type: core.Directive }\n ];\n BaseRowDef.ctorParameters = function () { return [\n { type: core.TemplateRef },\n { type: core.IterableDiffers }\n ]; };\n // Boilerplate for applying mixins to CdkHeaderRowDef.\n /** @docs-private */\n var CdkHeaderRowDefBase = /** @class */ (function (_super) {\n __extends(CdkHeaderRowDefBase, _super);\n function CdkHeaderRowDefBase() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n return CdkHeaderRowDefBase;\n }(BaseRowDef));\n var _CdkHeaderRowDefBase = mixinHasStickyInput(CdkHeaderRowDefBase);\n /**\n * Header row definition for the CDK table.\n * Captures the header row's template and other header properties such as the columns to display.\n */\n var CdkHeaderRowDef = /** @class */ (function (_super) {\n __extends(CdkHeaderRowDef, _super);\n function CdkHeaderRowDef(template, _differs, _table) {\n var _this = _super.call(this, template, _differs) || this;\n _this._table = _table;\n return _this;\n }\n // Prerender fails to recognize that ngOnChanges in a part of this class through inheritance.\n // Explicitly define it so that the method is called as part of the Angular lifecycle.\n CdkHeaderRowDef.prototype.ngOnChanges = function (changes) {\n _super.prototype.ngOnChanges.call(this, changes);\n };\n return CdkHeaderRowDef;\n }(_CdkHeaderRowDefBase));\n CdkHeaderRowDef.decorators = [\n { type: core.Directive, args: [{\n selector: '[cdkHeaderRowDef]',\n inputs: ['columns: cdkHeaderRowDef', 'sticky: cdkHeaderRowDefSticky'],\n },] }\n ];\n CdkHeaderRowDef.ctorParameters = function () { return [\n { type: core.TemplateRef },\n { type: core.IterableDiffers },\n { type: undefined, decorators: [{ type: core.Inject, args: [CDK_TABLE,] }, { type: core.Optional }] }\n ]; };\n // Boilerplate for applying mixins to CdkFooterRowDef.\n /** @docs-private */\n var CdkFooterRowDefBase = /** @class */ (function (_super) {\n __extends(CdkFooterRowDefBase, _super);\n function CdkFooterRowDefBase() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n return CdkFooterRowDefBase;\n }(BaseRowDef));\n var _CdkFooterRowDefBase = mixinHasStickyInput(CdkFooterRowDefBase);\n /**\n * Footer row definition for the CDK table.\n * Captures the footer row's template and other footer properties such as the columns to display.\n */\n var CdkFooterRowDef = /** @class */ (function (_super) {\n __extends(CdkFooterRowDef, _super);\n function CdkFooterRowDef(template, _differs, _table) {\n var _this = _super.call(this, template, _differs) || this;\n _this._table = _table;\n return _this;\n }\n // Prerender fails to recognize that ngOnChanges in a part of this class through inheritance.\n // Explicitly define it so that the method is called as part of the Angular lifecycle.\n CdkFooterRowDef.prototype.ngOnChanges = function (changes) {\n _super.prototype.ngOnChanges.call(this, changes);\n };\n return CdkFooterRowDef;\n }(_CdkFooterRowDefBase));\n CdkFooterRowDef.decorators = [\n { type: core.Directive, args: [{\n selector: '[cdkFooterRowDef]',\n inputs: ['columns: cdkFooterRowDef', 'sticky: cdkFooterRowDefSticky'],\n },] }\n ];\n CdkFooterRowDef.ctorParameters = function () { return [\n { type: core.TemplateRef },\n { type: core.IterableDiffers },\n { type: undefined, decorators: [{ type: core.Inject, args: [CDK_TABLE,] }, { type: core.Optional }] }\n ]; };\n /**\n * Data row definition for the CDK table.\n * Captures the header row's template and other row properties such as the columns to display and\n * a when predicate that describes when this row should be used.\n */\n var CdkRowDef = /** @class */ (function (_super) {\n __extends(CdkRowDef, _super);\n // TODO(andrewseguin): Add an input for providing a switch function to determine\n // if this template should be used.\n function CdkRowDef(template, _differs, _table) {\n var _this = _super.call(this, template, _differs) || this;\n _this._table = _table;\n return _this;\n }\n return CdkRowDef;\n }(BaseRowDef));\n CdkRowDef.decorators = [\n { type: core.Directive, args: [{\n selector: '[cdkRowDef]',\n inputs: ['columns: cdkRowDefColumns', 'when: cdkRowDefWhen'],\n },] }\n ];\n CdkRowDef.ctorParameters = function () { return [\n { type: core.TemplateRef },\n { type: core.IterableDiffers },\n { type: undefined, decorators: [{ type: core.Inject, args: [CDK_TABLE,] }, { type: core.Optional }] }\n ]; };\n /**\n * Outlet for rendering cells inside of a row or header row.\n * @docs-private\n */\n var CdkCellOutlet = /** @class */ (function () {\n function CdkCellOutlet(_viewContainer) {\n this._viewContainer = _viewContainer;\n CdkCellOutlet.mostRecentCellOutlet = this;\n }\n CdkCellOutlet.prototype.ngOnDestroy = function () {\n // If this was the last outlet being rendered in the view, remove the reference\n // from the static property after it has been destroyed to avoid leaking memory.\n if (CdkCellOutlet.mostRecentCellOutlet === this) {\n CdkCellOutlet.mostRecentCellOutlet = null;\n }\n };\n return CdkCellOutlet;\n }());\n /**\n * Static property containing the latest constructed instance of this class.\n * Used by the CDK table when each CdkHeaderRow and CdkRow component is created using\n * createEmbeddedView. After one of these components are created, this property will provide\n * a handle to provide that component's cells and context. After init, the CdkCellOutlet will\n * construct the cells with the provided context.\n */\n CdkCellOutlet.mostRecentCellOutlet = null;\n CdkCellOutlet.decorators = [\n { type: core.Directive, args: [{ selector: '[cdkCellOutlet]' },] }\n ];\n CdkCellOutlet.ctorParameters = function () { return [\n { type: core.ViewContainerRef }\n ]; };\n /** Header template container that contains the cell outlet. Adds the right class and role. */\n var CdkHeaderRow = /** @class */ (function () {\n function CdkHeaderRow() {\n }\n return CdkHeaderRow;\n }());\n CdkHeaderRow.decorators = [\n { type: core.Component, args: [{\n selector: 'cdk-header-row, tr[cdk-header-row]',\n template: CDK_ROW_TEMPLATE,\n host: {\n 'class': 'cdk-header-row',\n 'role': 'row',\n },\n // See note on CdkTable for explanation on why this uses the default change detection strategy.\n // tslint:disable-next-line:validate-decorators\n changeDetection: core.ChangeDetectionStrategy.Default,\n encapsulation: core.ViewEncapsulation.None\n },] }\n ];\n /** Footer template container that contains the cell outlet. Adds the right class and role. */\n var CdkFooterRow = /** @class */ (function () {\n function CdkFooterRow() {\n }\n return CdkFooterRow;\n }());\n CdkFooterRow.decorators = [\n { type: core.Component, args: [{\n selector: 'cdk-footer-row, tr[cdk-footer-row]',\n template: CDK_ROW_TEMPLATE,\n host: {\n 'class': 'cdk-footer-row',\n 'role': 'row',\n },\n // See note on CdkTable for explanation on why this uses the default change detection strategy.\n // tslint:disable-next-line:validate-decorators\n changeDetection: core.ChangeDetectionStrategy.Default,\n encapsulation: core.ViewEncapsulation.None\n },] }\n ];\n /** Data row template container that contains the cell outlet. Adds the right class and role. */\n var CdkRow = /** @class */ (function () {\n function CdkRow() {\n }\n return CdkRow;\n }());\n CdkRow.decorators = [\n { type: core.Component, args: [{\n selector: 'cdk-row, tr[cdk-row]',\n template: CDK_ROW_TEMPLATE,\n host: {\n 'class': 'cdk-row',\n 'role': 'row',\n },\n // See note on CdkTable for explanation on why this uses the default change detection strategy.\n // tslint:disable-next-line:validate-decorators\n changeDetection: core.ChangeDetectionStrategy.Default,\n encapsulation: core.ViewEncapsulation.None\n },] }\n ];\n /** Row that can be used to display a message when no data is shown in the table. */\n var CdkNoDataRow = /** @class */ (function () {\n function CdkNoDataRow(templateRef) {\n this.templateRef = templateRef;\n }\n return CdkNoDataRow;\n }());\n CdkNoDataRow.decorators = [\n { type: core.Directive, args: [{\n selector: 'ng-template[cdkNoDataRow]'\n },] }\n ];\n CdkNoDataRow.ctorParameters = function () { return [\n { type: core.TemplateRef }\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 /**\n * List of all possible directions that can be used for sticky positioning.\n * @docs-private\n */\n var STICKY_DIRECTIONS = ['top', 'bottom', 'left', 'right'];\n /**\n * Applies and removes sticky positioning styles to the `CdkTable` rows and columns cells.\n * @docs-private\n */\n var StickyStyler = /** @class */ (function () {\n /**\n * @param _isNativeHtmlTable Whether the sticky logic should be based on a table\n * that uses the native `<table>` element.\n * @param _stickCellCss The CSS class that will be applied to every row/cell that has\n * sticky positioning applied.\n * @param direction The directionality context of the table (ltr/rtl); affects column positioning\n * by reversing left/right positions.\n * @param _isBrowser Whether the table is currently being rendered on the server or the client.\n * @param _needsPositionStickyOnElement Whether we need to specify position: sticky on cells\n * using inline styles. If false, it is assumed that position: sticky is included in\n * the component stylesheet for _stickCellCss.\n * @param _positionListener A listener that is notified of changes to sticky rows/columns\n * and their dimensions.\n */\n function StickyStyler(_isNativeHtmlTable, _stickCellCss, direction, \n /**\n * @deprecated `_coalescedStyleScheduler` parameter to become required.\n * @breaking-change 11.0.0\n */\n _coalescedStyleScheduler, _isBrowser, _needsPositionStickyOnElement, _positionListener) {\n if (_isBrowser === void 0) { _isBrowser = true; }\n if (_needsPositionStickyOnElement === void 0) { _needsPositionStickyOnElement = true; }\n this._isNativeHtmlTable = _isNativeHtmlTable;\n this._stickCellCss = _stickCellCss;\n this.direction = direction;\n this._coalescedStyleScheduler = _coalescedStyleScheduler;\n this._isBrowser = _isBrowser;\n this._needsPositionStickyOnElement = _needsPositionStickyOnElement;\n this._positionListener = _positionListener;\n this._cachedCellWidths = [];\n this._borderCellCss = {\n 'top': _stickCellCss + \"-border-elem-top\",\n 'bottom': _stickCellCss + \"-border-elem-bottom\",\n 'left': _stickCellCss + \"-border-elem-left\",\n 'right': _stickCellCss + \"-border-elem-right\",\n };\n }\n /**\n * Clears the sticky positioning styles from the row and its cells by resetting the `position`\n * style, setting the zIndex to 0, and unsetting each provided sticky direction.\n * @param rows The list of rows that should be cleared from sticking in the provided directions\n * @param stickyDirections The directions that should no longer be set as sticky on the rows.\n */\n StickyStyler.prototype.clearStickyPositioning = function (rows, stickyDirections) {\n var e_1, _c;\n var _this = this;\n var elementsToClear = [];\n try {\n for (var rows_1 = __values(rows), rows_1_1 = rows_1.next(); !rows_1_1.done; rows_1_1 = rows_1.next()) {\n var row = rows_1_1.value;\n // If the row isn't an element (e.g. if it's an `ng-container`),\n // it won't have inline styles or `children` so we skip it.\n if (row.nodeType !== row.ELEMENT_NODE) {\n continue;\n }\n elementsToClear.push(row);\n for (var i = 0; i < row.children.length; i++) {\n elementsToClear.push(row.children[i]);\n }\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (rows_1_1 && !rows_1_1.done && (_c = rows_1.return)) _c.call(rows_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n // Coalesce with sticky row/column updates (and potentially other changes like column resize).\n this._scheduleStyleChanges(function () {\n var e_2, _c;\n try {\n for (var elementsToClear_1 = __values(elementsToClear), elementsToClear_1_1 = elementsToClear_1.next(); !elementsToClear_1_1.done; elementsToClear_1_1 = elementsToClear_1.next()) {\n var element = elementsToClear_1_1.value;\n _this._removeStickyStyle(element, stickyDirections);\n }\n }\n catch (e_2_1) { e_2 = { error: e_2_1 }; }\n finally {\n try {\n if (elementsToClear_1_1 && !elementsToClear_1_1.done && (_c = elementsToClear_1.return)) _c.call(elementsToClear_1);\n }\n finally { if (e_2) throw e_2.error; }\n }\n });\n };\n /**\n * Applies sticky left and right positions to the cells of each row according to the sticky\n * states of the rendered column definitions.\n * @param rows The rows that should have its set of cells stuck according to the sticky states.\n * @param stickyStartStates A list of boolean states where each state represents whether the cell\n * in this index position should be stuck to the start of the row.\n * @param stickyEndStates A list of boolean states where each state represents whether the cell\n * in this index position should be stuck to the end of the row.\n * @param recalculateCellWidths Whether the sticky styler should recalculate the width of each\n * column cell. If `false` cached widths will be used instead.\n */\n StickyStyler.prototype.updateStickyColumns = function (rows, stickyStartStates, stickyEndStates, recalculateCellWidths) {\n var _this = this;\n if (recalculateCellWidths === void 0) { recalculateCellWidths = true; }\n if (!rows.length || !this._isBrowser || !(stickyStartStates.some(function (state) { return state; }) ||\n stickyEndStates.some(function (state) { return state; }))) {\n if (this._positionListener) {\n this._positionListener.stickyColumnsUpdated({ sizes: [] });\n this._positionListener.stickyEndColumnsUpdated({ sizes: [] });\n }\n return;\n }\n var firstRow = rows[0];\n var numCells = firstRow.children.length;\n var cellWidths = this._getCellWidths(firstRow, recalculateCellWidths);\n var startPositions = this._getStickyStartColumnPositions(cellWidths, stickyStartStates);\n var endPositions = this._getStickyEndColumnPositions(cellWidths, stickyEndStates);\n var lastStickyStart = stickyStartStates.lastIndexOf(true);\n var firstStickyEnd = stickyEndStates.indexOf(true);\n // Coalesce with sticky row updates (and potentially other changes like column resize).\n this._scheduleStyleChanges(function () {\n var e_3, _c;\n var isRtl = _this.direction === 'rtl';\n var start = isRtl ? 'right' : 'left';\n var end = isRtl ? 'left' : 'right';\n try {\n for (var rows_2 = __values(rows), rows_2_1 = rows_2.next(); !rows_2_1.done; rows_2_1 = rows_2.next()) {\n var row = rows_2_1.value;\n for (var i = 0; i < numCells; i++) {\n var cell = row.children[i];\n if (stickyStartStates[i]) {\n _this._addStickyStyle(cell, start, startPositions[i], i === lastStickyStart);\n }\n if (stickyEndStates[i]) {\n _this._addStickyStyle(cell, end, endPositions[i], i === firstStickyEnd);\n }\n }\n }\n }\n catch (e_3_1) { e_3 = { error: e_3_1 }; }\n finally {\n try {\n if (rows_2_1 && !rows_2_1.done && (_c = rows_2.return)) _c.call(rows_2);\n }\n finally { if (e_3) throw e_3.error; }\n }\n if (_this._positionListener) {\n _this._positionListener.stickyColumnsUpdated({\n sizes: lastStickyStart === -1 ?\n [] :\n cellWidths\n .slice(0, lastStickyStart + 1)\n .map(function (width, index) { return stickyStartStates[index] ? width : null; })\n });\n _this._positionListener.stickyEndColumnsUpdated({\n sizes: firstStickyEnd === -1 ?\n [] :\n cellWidths\n .slice(firstStickyEnd)\n .map(function (width, index) { return stickyEndStates[index + firstStickyEnd] ? width : null; })\n .reverse()\n });\n }\n });\n };\n /**\n * Applies sticky positioning to the row's cells if using the native table layout, and to the\n * row itself otherwise.\n * @param rowsToStick The list of rows that should be stuck according to their corresponding\n * sticky state and to the provided top or bottom position.\n * @param stickyStates A list of boolean states where each state represents whether the row\n * should be stuck in the particular top or bottom position.\n * @param position The position direction in which the row should be stuck if that row should be\n * sticky.\n *\n */\n StickyStyler.prototype.stickRows = function (rowsToStick, stickyStates, position) {\n var _this = this;\n // Since we can't measure the rows on the server, we can't stick the rows properly.\n if (!this._isBrowser) {\n return;\n }\n // If positioning the rows to the bottom, reverse their order when evaluating the sticky\n // position such that the last row stuck will be \"bottom: 0px\" and so on. Note that the\n // sticky states need to be reversed as well.\n var rows = position === 'bottom' ? rowsToStick.slice().reverse() : rowsToStick;\n var states = position === 'bottom' ? stickyStates.slice().reverse() : stickyStates;\n // Measure row heights all at once before adding sticky styles to reduce layout thrashing.\n var stickyOffsets = [];\n var stickyCellHeights = [];\n var elementsToStick = [];\n for (var rowIndex = 0, stickyOffset = 0; rowIndex < rows.length; rowIndex++) {\n stickyOffsets[rowIndex] = stickyOffset;\n if (!states[rowIndex]) {\n continue;\n }\n var row = rows[rowIndex];\n elementsToStick[rowIndex] = this._isNativeHtmlTable ?\n Array.from(row.children) : [row];\n var height = row.getBoundingClientRect().height;\n stickyOffset += height;\n stickyCellHeights[rowIndex] = height;\n }\n var borderedRowIndex = states.lastIndexOf(true);\n // Coalesce with other sticky row updates (top/bottom), sticky columns updates\n // (and potentially other changes like column resize).\n this._scheduleStyleChanges(function () {\n var e_4, _c;\n var _a, _b;\n for (var rowIndex = 0; rowIndex < rows.length; rowIndex++) {\n if (!states[rowIndex]) {\n continue;\n }\n var offset = stickyOffsets[rowIndex];\n var isBorderedRowIndex = rowIndex === borderedRowIndex;\n try {\n for (var _d = (e_4 = void 0, __values(elementsToStick[rowIndex])), _e = _d.next(); !_e.done; _e = _d.next()) {\n var element = _e.value;\n _this._addStickyStyle(element, position, offset, isBorderedRowIndex);\n }\n }\n catch (e_4_1) { e_4 = { error: e_4_1 }; }\n finally {\n try {\n if (_e && !_e.done && (_c = _d.return)) _c.call(_d);\n }\n finally { if (e_4) throw e_4.error; }\n }\n }\n if (position === 'top') {\n (_a = _this._positionListener) === null || _a === void 0 ? void 0 : _a.stickyHeaderRowsUpdated({ sizes: stickyCellHeights, elements: elementsToStick });\n }\n else {\n (_b = _this._positionListener) === null || _b === void 0 ? void 0 : _b.stickyFooterRowsUpdated({ sizes: stickyCellHeights, elements: elementsToStick });\n }\n });\n };\n /**\n * When using the native table in Safari, sticky footer cells do not stick. The only way to stick\n * footer rows is to apply sticky styling to the tfoot container. This should only be done if\n * all footer rows are sticky. If not all footer rows are sticky, remove sticky positioning from\n * the tfoot element.\n */\n StickyStyler.prototype.updateStickyFooterContainer = function (tableElement, stickyStates) {\n var _this = this;\n if (!this._isNativeHtmlTable) {\n return;\n }\n var tfoot = tableElement.querySelector('tfoot');\n // Coalesce with other sticky updates (and potentially other changes like column resize).\n this._scheduleStyleChanges(function () {\n if (stickyStates.some(function (state) { return !state; })) {\n _this._removeStickyStyle(tfoot, ['bottom']);\n }\n else {\n _this._addStickyStyle(tfoot, 'bottom', 0, false);\n }\n });\n };\n /**\n * Removes the sticky style on the element by removing the sticky cell CSS class, re-evaluating\n * the zIndex, removing each of the provided sticky directions, and removing the\n * sticky position if there are no more directions.\n */\n StickyStyler.prototype._removeStickyStyle = function (element, stickyDirections) {\n var e_5, _c;\n try {\n for (var stickyDirections_1 = __values(stickyDirections), stickyDirections_1_1 = stickyDirections_1.next(); !stickyDirections_1_1.done; stickyDirections_1_1 = stickyDirections_1.next()) {\n var dir = stickyDirections_1_1.value;\n element.style[dir] = '';\n element.classList.remove(this._borderCellCss[dir]);\n }\n }\n catch (e_5_1) { e_5 = { error: e_5_1 }; }\n finally {\n try {\n if (stickyDirections_1_1 && !stickyDirections_1_1.done && (_c = stickyDirections_1.return)) _c.call(stickyDirections_1);\n }\n finally { if (e_5) throw e_5.error; }\n }\n // If the element no longer has any more sticky directions, remove sticky positioning and\n // the sticky CSS class.\n // Short-circuit checking element.style[dir] for stickyDirections as they\n // were already removed above.\n var hasDirection = STICKY_DIRECTIONS.some(function (dir) { return stickyDirections.indexOf(dir) === -1 && element.style[dir]; });\n if (hasDirection) {\n element.style.zIndex = this._getCalculatedZIndex(element);\n }\n else {\n // When not hasDirection, _getCalculatedZIndex will always return ''.\n element.style.zIndex = '';\n if (this._needsPositionStickyOnElement) {\n element.style.position = '';\n }\n element.classList.remove(this._stickCellCss);\n }\n };\n /**\n * Adds the sticky styling to the element by adding the sticky style class, changing position\n * to be sticky (and -webkit-sticky), setting the appropriate zIndex, and adding a sticky\n * direction and value.\n */\n StickyStyler.prototype._addStickyStyle = function (element, dir, dirValue, isBorderElement) {\n element.classList.add(this._stickCellCss);\n if (isBorderElement) {\n element.classList.add(this._borderCellCss[dir]);\n }\n element.style[dir] = dirValue + \"px\";\n element.style.zIndex = this._getCalculatedZIndex(element);\n if (this._needsPositionStickyOnElement) {\n element.style.cssText += 'position: -webkit-sticky; position: sticky; ';\n }\n };\n /**\n * Calculate what the z-index should be for the element, depending on what directions (top,\n * bottom, left, right) have been set. It should be true that elements with a top direction\n * should have the highest index since these are elements like a table header. If any of those\n * elements are also sticky in another direction, then they should appear above other elements\n * that are only sticky top (e.g. a sticky column on a sticky header). Bottom-sticky elements\n * (e.g. footer rows) should then be next in the ordering such that they are below the header\n * but above any non-sticky elements. Finally, left/right sticky elements (e.g. sticky columns)\n * should minimally increment so that they are above non-sticky elements but below top and bottom\n * elements.\n */\n StickyStyler.prototype._getCalculatedZIndex = function (element) {\n var e_6, _c;\n var zIndexIncrements = {\n top: 100,\n bottom: 10,\n left: 1,\n right: 1,\n };\n var zIndex = 0;\n try {\n // Use `Iterable` instead of `Array` because TypeScript, as of 3.6.3,\n // loses the array generic type in the `for of`. But we *also* have to use `Array` because\n // typescript won't iterate over an `Iterable` unless you compile with `--downlevelIteration`\n for (var STICKY_DIRECTIONS_1 = __values(STICKY_DIRECTIONS), STICKY_DIRECTIONS_1_1 = STICKY_DIRECTIONS_1.next(); !STICKY_DIRECTIONS_1_1.done; STICKY_DIRECTIONS_1_1 = STICKY_DIRECTIONS_1.next()) {\n var dir = STICKY_DIRECTIONS_1_1.value;\n if (element.style[dir]) {\n zIndex += zIndexIncrements[dir];\n }\n }\n }\n catch (e_6_1) { e_6 = { error: e_6_1 }; }\n finally {\n try {\n if (STICKY_DIRECTIONS_1_1 && !STICKY_DIRECTIONS_1_1.done && (_c = STICKY_DIRECTIONS_1.return)) _c.call(STICKY_DIRECTIONS_1);\n }\n finally { if (e_6) throw e_6.error; }\n }\n return zIndex ? \"\" + zIndex : '';\n };\n /** Gets the widths for each cell in the provided row. */\n StickyStyler.prototype._getCellWidths = function (row, recalculateCellWidths) {\n if (recalculateCellWidths === void 0) { recalculateCellWidths = true; }\n if (!recalculateCellWidths && this._cachedCellWidths.length) {\n return this._cachedCellWidths;\n }\n var cellWidths = [];\n var firstRowCells = row.children;\n for (var i = 0; i < firstRowCells.length; i++) {\n var cell = firstRowCells[i];\n cellWidths.push(cell.getBoundingClientRect().width);\n }\n this._cachedCellWidths = cellWidths;\n return cellWidths;\n };\n /**\n * Determines the left and right positions of each sticky column cell, which will be the\n * accumulation of all sticky column cell widths to the left and right, respectively.\n * Non-sticky cells do not need to have a value set since their positions will not be applied.\n */\n StickyStyler.prototype._getStickyStartColumnPositions = function (widths, stickyStates) {\n var positions = [];\n var nextPosition = 0;\n for (var i = 0; i < widths.length; i++) {\n if (stickyStates[i]) {\n positions[i] = nextPosition;\n nextPosition += widths[i];\n }\n }\n return positions;\n };\n /**\n * Determines the left and right positions of each sticky column cell, which will be the\n * accumulation of all sticky column cell widths to the left and right, respectively.\n * Non-sticky cells do not need to have a value set since their positions will not be applied.\n */\n StickyStyler.prototype._getStickyEndColumnPositions = function (widths, stickyStates) {\n var positions = [];\n var nextPosition = 0;\n for (var i = widths.length; i > 0; i--) {\n if (stickyStates[i]) {\n positions[i] = nextPosition;\n nextPosition += widths[i];\n }\n }\n return positions;\n };\n /**\n * Schedules styles to be applied when the style scheduler deems appropriate.\n * @breaking-change 11.0.0 This method can be removed in favor of calling\n * `CoalescedStyleScheduler.schedule` directly once the scheduler is a required parameter.\n */\n StickyStyler.prototype._scheduleStyleChanges = function (changes) {\n if (this._coalescedStyleScheduler) {\n this._coalescedStyleScheduler.schedule(changes);\n }\n else {\n changes();\n }\n };\n return StickyStyler;\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 /**\n * Returns an error to be thrown when attempting to find an unexisting column.\n * @param id Id whose lookup failed.\n * @docs-private\n */\n function getTableUnknownColumnError(id) {\n return Error(\"Could not find column with id \\\"\" + id + \"\\\".\");\n }\n /**\n * Returns an error to be thrown when two column definitions have the same name.\n * @docs-private\n */\n function getTableDuplicateColumnNameError(name) {\n return Error(\"Duplicate column definition name provided: \\\"\" + name + \"\\\".\");\n }\n /**\n * Returns an error to be thrown when there are multiple rows that are missing a when function.\n * @docs-private\n */\n function getTableMultipleDefaultRowDefsError() {\n return Error(\"There can only be one default row without a when predicate function.\");\n }\n /**\n * Returns an error to be thrown when there are no matching row defs for a particular set of data.\n * @docs-private\n */\n function getTableMissingMatchingRowDefError(data) {\n return Error(\"Could not find a matching row definition for the\" +\n (\"provided row data: \" + JSON.stringify(data)));\n }\n /**\n * Returns an error to be thrown when there is no row definitions present in the content.\n * @docs-private\n */\n function getTableMissingRowDefsError() {\n return Error('Missing definitions for header, footer, and row; ' +\n 'cannot determine which columns should be rendered.');\n }\n /**\n * Returns an error to be thrown when the data source does not match the compatible types.\n * @docs-private\n */\n function getTableUnknownDataSourceError() {\n return Error(\"Provided data source did not match an array, Observable, or DataSource\");\n }\n /**\n * Returns an error to be thrown when the text column cannot find a parent table to inject.\n * @docs-private\n */\n function getTableTextColumnMissingParentTableError() {\n return Error(\"Text column could not find a parent table for registration.\");\n }\n /**\n * Returns an error to be thrown when a table text column doesn't have a name.\n * @docs-private\n */\n function getTableTextColumnMissingNameError() {\n return Error(\"Table text column must have a name.\");\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 /** The injection token used to specify the StickyPositioningListener. */\n var STICKY_POSITIONING_LISTENER = new core.InjectionToken('CDK_SPL');\n\n /**\n * Provides a handle for the table to grab the view container's ng-container to insert data rows.\n * @docs-private\n */\n var DataRowOutlet = /** @class */ (function () {\n function DataRowOutlet(viewContainer, elementRef) {\n this.viewContainer = viewContainer;\n this.elementRef = elementRef;\n }\n return DataRowOutlet;\n }());\n DataRowOutlet.decorators = [\n { type: core.Directive, args: [{ selector: '[rowOutlet]' },] }\n ];\n DataRowOutlet.ctorParameters = function () { return [\n { type: core.ViewContainerRef },\n { type: core.ElementRef }\n ]; };\n /**\n * Provides a handle for the table to grab the view container's ng-container to insert the header.\n * @docs-private\n */\n var HeaderRowOutlet = /** @class */ (function () {\n function HeaderRowOutlet(viewContainer, elementRef) {\n this.viewContainer = viewContainer;\n this.elementRef = elementRef;\n }\n return HeaderRowOutlet;\n }());\n HeaderRowOutlet.decorators = [\n { type: core.Directive, args: [{ selector: '[headerRowOutlet]' },] }\n ];\n HeaderRowOutlet.ctorParameters = function () { return [\n { type: core.ViewContainerRef },\n { type: core.ElementRef }\n ]; };\n /**\n * Provides a handle for the table to grab the view container's ng-container to insert the footer.\n * @docs-private\n */\n var FooterRowOutlet = /** @class */ (function () {\n function FooterRowOutlet(viewContainer, elementRef) {\n this.viewContainer = viewContainer;\n this.elementRef = elementRef;\n }\n return FooterRowOutlet;\n }());\n FooterRowOutlet.decorators = [\n { type: core.Directive, args: [{ selector: '[footerRowOutlet]' },] }\n ];\n FooterRowOutlet.ctorParameters = function () { return [\n { type: core.ViewContainerRef },\n { type: core.ElementRef }\n ]; };\n /**\n * Provides a handle for the table to grab the view\n * container's ng-container to insert the no data row.\n * @docs-private\n */\n var NoDataRowOutlet = /** @class */ (function () {\n function NoDataRowOutlet(viewContainer, elementRef) {\n this.viewContainer = viewContainer;\n this.elementRef = elementRef;\n }\n return NoDataRowOutlet;\n }());\n NoDataRowOutlet.decorators = [\n { type: core.Directive, args: [{ selector: '[noDataRowOutlet]' },] }\n ];\n NoDataRowOutlet.ctorParameters = function () { return [\n { type: core.ViewContainerRef },\n { type: core.ElementRef }\n ]; };\n /**\n * The table template that can be used by the mat-table. Should not be used outside of the\n * material library.\n * @docs-private\n */\n var CDK_TABLE_TEMPLATE = \n // Note that according to MDN, the `caption` element has to be projected as the **first**\n // element in the table. See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/caption\n \"\\n <ng-content select=\\\"caption\\\"></ng-content>\\n <ng-content select=\\\"colgroup, col\\\"></ng-content>\\n <ng-container headerRowOutlet></ng-container>\\n <ng-container rowOutlet></ng-container>\\n <ng-container noDataRowOutlet></ng-container>\\n <ng-container footerRowOutlet></ng-container>\\n\";\n /**\n * Class used to conveniently type the embedded view ref for rows with a context.\n * @docs-private\n */\n var RowViewRef = /** @class */ (function (_super) {\n __extends(RowViewRef, _super);\n function RowViewRef() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n return RowViewRef;\n }(core.EmbeddedViewRef));\n /**\n * A data table that can render a header row, data rows, and a footer row.\n * Uses the dataSource input to determine the data to be rendered. The data can be provided either\n * as a data array, an Observable stream that emits the data array to render, or a DataSource with a\n * connect function that will return an Observable stream that emits the data array to render.\n */\n var CdkTable = /** @class */ (function () {\n function CdkTable(_differs, _changeDetectorRef, _elementRef, role, _dir, _document, _platform, \n /**\n * @deprecated `_coalescedStyleScheduler`, `_viewRepeater` and `_viewportRuler`\n * parameters to become required.\n * @breaking-change 11.0.0\n */\n _viewRepeater, _coalescedStyleScheduler, _stickyPositioningListener, \n // Optional for backwards compatibility. The viewport ruler is provided in root. Therefore,\n // this property will never be null.\n // tslint:disable-next-line: lightweight-tokens\n _viewportRuler) {\n this._differs = _differs;\n this._changeDetectorRef = _changeDetectorRef;\n this._elementRef = _elementRef;\n this._dir = _dir;\n this._platform = _platform;\n this._viewRepeater = _viewRepeater;\n this._coalescedStyleScheduler = _coalescedStyleScheduler;\n this._stickyPositioningListener = _stickyPositioningListener;\n this._viewportRuler = _viewportRuler;\n /** Subject that emits when the component has been destroyed. */\n this._onDestroy = new rxjs.Subject();\n /**\n * Map of all the user's defined columns (header, data, and footer cell template) identified by\n * name. Collection populated by the column definitions gathered by `ContentChildren` as well as\n * any custom column definitions added to `_customColumnDefs`.\n */\n this._columnDefsByName = new Map();\n /**\n * Column definitions that were defined outside of the direct content children of the table.\n * These will be defined when, e.g., creating a wrapper around the cdkTable that has\n * column definitions as *its* content child.\n */\n this._customColumnDefs = new Set();\n /**\n * Data row definitions that were defined outside of the direct content children of the table.\n * These will be defined when, e.g., creating a wrapper around the cdkTable that has\n * built-in data rows as *its* content child.\n */\n this._customRowDefs = new Set();\n /**\n * Header row definitions that were defined outside of the direct content children of the table.\n * These will be defined when, e.g., creating a wrapper around the cdkTable that has\n * built-in header rows as *its* content child.\n */\n this._customHeaderRowDefs = new Set();\n /**\n * Footer row definitions that were defined outside of the direct content children of the table.\n * These will be defined when, e.g., creating a wrapper around the cdkTable that has a\n * built-in footer row as *its* content child.\n */\n this._customFooterRowDefs = new Set();\n /**\n * Whether the header row definition has been changed. Triggers an update to the header row after\n * content is checked. Initialized as true so that the table renders the initial set of rows.\n */\n this._headerRowDefChanged = true;\n /**\n * Whether the footer row definition has been changed. Triggers an update to the footer row after\n * content is checked. Initialized as true so that the table renders the initial set of rows.\n */\n this._footerRowDefChanged = true;\n /**\n * Whether the sticky column styles need to be updated. Set to `true` when the visible columns\n * change.\n */\n this._stickyColumnStylesNeedReset = true;\n /**\n * Whether the sticky styler should recalculate cell widths when applying sticky styles. If\n * `false`, cached values will be used instead. This is only applicable to tables with\n * {@link fixedLayout} enabled. For other tables, cell widths will always be recalculated.\n */\n this._forceRecalculateCellWidths = true;\n /**\n * Cache of the latest rendered `RenderRow` objects as a map for easy retrieval when constructing\n * a new list of `RenderRow` objects for rendering rows. Since the new list is constructed with\n * the cached `RenderRow` objects when possible, the row identity is preserved when the data\n * and row template matches, which allows the `IterableDiffer` to check rows by reference\n * and understand which rows are added/moved/removed.\n *\n * Implemented as a map of maps where the first key is the `data: T` object and the second is the\n * `CdkRowDef<T>` object. With the two keys, the cache points to a `RenderRow<T>` object that\n * contains an array of created pairs. The array is necessary to handle cases where the data\n * array contains multiple duplicate data objects and each instantiated `RenderRow` must be\n * stored.\n */\n this._cachedRenderRowsMap = new Map();\n /**\n * CSS class added to any row or cell that has sticky positioning applied. May be overriden by\n * table subclasses.\n */\n this.stickyCssClass = 'cdk-table-sticky';\n /**\n * Whether to manually add positon: sticky to all sticky cell elements. Not needed if\n * the position is set in a selector associated with the value of stickyCssClass. May be\n * overridden by table subclasses\n */\n this.needsPositionStickyOnElement = true;\n /** Whether the no data row is currently showing anything. */\n this._isShowingNoDataRow = false;\n this._multiTemplateDataRows = false;\n this._fixedLayout = false;\n // TODO(andrewseguin): Remove max value as the end index\n // and instead calculate the view on init and scroll.\n /**\n * Stream containing the latest information on what rows are being displayed on screen.\n * Can be used by the data source to as a heuristic of what data should be provided.\n *\n * @docs-private\n */\n this.viewChange = new rxjs.BehaviorSubject({ start: 0, end: Number.MAX_VALUE });\n if (!role) {\n this._elementRef.nativeElement.setAttribute('role', 'grid');\n }\n this._document = _document;\n this._isNativeHtmlTable = this._elementRef.nativeElement.nodeName === 'TABLE';\n }\n Object.defineProperty(CdkTable.prototype, \"trackBy\", {\n /**\n * Tracking function that will be used to check the differences in data changes. Used similarly\n * to `ngFor` `trackBy` function. Optimize row operations by identifying a row based on its data\n * relative to the function to know if a row should be added/removed/moved.\n * Accepts a function that takes two parameters, `index` and `item`.\n */\n get: function () {\n return this._trackByFn;\n },\n set: function (fn) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && fn != null && typeof fn !== 'function') {\n console.warn(\"trackBy must be a function, but received \" + JSON.stringify(fn) + \".\");\n }\n this._trackByFn = fn;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(CdkTable.prototype, \"dataSource\", {\n /**\n * The table's source of data, which can be provided in three ways (in order of complexity):\n * - Simple data array (each object represents one table row)\n * - Stream that emits a data array each time the array changes\n * - `DataSource` object that implements the connect/disconnect interface.\n *\n * If a data array is provided, the table must be notified when the array's objects are\n * added, removed, or moved. This can be done by calling the `renderRows()` function which will\n * render the diff since the last table render. If the data array reference is changed, the table\n * will automatically trigger an update to the rows.\n *\n * When providing an Observable stream, the table will trigger an update automatically when the\n * stream emits a new array of data.\n *\n * Finally, when providing a `DataSource` object, the table will use the Observable stream\n * provided by the connect function and trigger updates when that stream emits new data array\n * values. During the table's ngOnDestroy or when the data source is removed from the table, the\n * table will call the DataSource's `disconnect` function (may be useful for cleaning up any\n * subscriptions registered during the connect process).\n */\n get: function () {\n return this._dataSource;\n },\n set: function (dataSource) {\n if (this._dataSource !== dataSource) {\n this._switchDataSource(dataSource);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(CdkTable.prototype, \"multiTemplateDataRows\", {\n /**\n * Whether to allow multiple rows per data object by evaluating which rows evaluate their 'when'\n * predicate to true. If `multiTemplateDataRows` is false, which is the default value, then each\n * dataobject will render the first row that evaluates its when predicate to true, in the order\n * defined in the table, or otherwise the default row which does not have a when predicate.\n */\n get: function () {\n return this._multiTemplateDataRows;\n },\n set: function (v) {\n this._multiTemplateDataRows = coercion.coerceBooleanProperty(v);\n // In Ivy if this value is set via a static attribute (e.g. <table multiTemplateDataRows>),\n // this setter will be invoked before the row outlet has been defined hence the null check.\n if (this._rowOutlet && this._rowOutlet.viewContainer.length) {\n this._forceRenderDataRows();\n this.updateStickyColumnStyles();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(CdkTable.prototype, \"fixedLayout\", {\n /**\n * Whether to use a fixed table layout. Enabling this option will enforce consistent column widths\n * and optimize rendering sticky styles for native tables. No-op for flex tables.\n */\n get: function () {\n return this._fixedLayout;\n },\n set: function (v) {\n this._fixedLayout = coercion.coerceBooleanProperty(v);\n // Toggling `fixedLayout` may change column widths. Sticky column styles should be recalculated.\n this._forceRecalculateCellWidths = true;\n this._stickyColumnStylesNeedReset = true;\n },\n enumerable: false,\n configurable: true\n });\n CdkTable.prototype.ngOnInit = function () {\n var _this = this;\n this._setupStickyStyler();\n if (this._isNativeHtmlTable) {\n this._applyNativeTableSections();\n }\n // Set up the trackBy function so that it uses the `RenderRow` as its identity by default. If\n // the user has provided a custom trackBy, return the result of that function as evaluated\n // with the values of the `RenderRow`'s data and index.\n this._dataDiffer = this._differs.find([]).create(function (_i, dataRow) {\n return _this.trackBy ? _this.trackBy(dataRow.dataIndex, dataRow.data) : dataRow;\n });\n // Table cell dimensions may change after resizing the window. Signal the sticky styler to\n // refresh its cache of cell widths the next time sticky styles are updated.\n // @breaking-change 11.0.0 Remove null check for _viewportRuler once it's a required parameter.\n if (this._viewportRuler) {\n this._viewportRuler.change().pipe(operators.takeUntil(this._onDestroy)).subscribe(function () {\n _this._forceRecalculateCellWidths = true;\n });\n }\n };\n CdkTable.prototype.ngAfterContentChecked = function () {\n // Cache the row and column definitions gathered by ContentChildren and programmatic injection.\n this._cacheRowDefs();\n this._cacheColumnDefs();\n // Make sure that the user has at least added header, footer, or data row def.\n if (!this._headerRowDefs.length && !this._footerRowDefs.length && !this._rowDefs.length &&\n (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableMissingRowDefsError();\n }\n // Render updates if the list of columns have been changed for the header, row, or footer defs.\n var columnsChanged = this._renderUpdatedColumns();\n var rowDefsChanged = columnsChanged || this._headerRowDefChanged || this._footerRowDefChanged;\n // Ensure sticky column styles are reset if set to `true` elsewhere.\n this._stickyColumnStylesNeedReset = this._stickyColumnStylesNeedReset || rowDefsChanged;\n this._forceRecalculateCellWidths = rowDefsChanged;\n // If the header row definition has been changed, trigger a render to the header row.\n if (this._headerRowDefChanged) {\n this._forceRenderHeaderRows();\n this._headerRowDefChanged = false;\n }\n // If the footer row definition has been changed, trigger a render to the footer row.\n if (this._footerRowDefChanged) {\n this._forceRenderFooterRows();\n this._footerRowDefChanged = false;\n }\n // If there is a data source and row definitions, connect to the data source unless a\n // connection has already been made.\n if (this.dataSource && this._rowDefs.length > 0 && !this._renderChangeSubscription) {\n this._observeRenderChanges();\n }\n else if (this._stickyColumnStylesNeedReset) {\n // In the above case, _observeRenderChanges will result in updateStickyColumnStyles being\n // called when it row data arrives. Otherwise, we need to call it proactively.\n this.updateStickyColumnStyles();\n }\n this._checkStickyStates();\n };\n CdkTable.prototype.ngOnDestroy = function () {\n this._rowOutlet.viewContainer.clear();\n this._noDataRowOutlet.viewContainer.clear();\n this._headerRowOutlet.viewContainer.clear();\n this._footerRowOutlet.viewContainer.clear();\n this._cachedRenderRowsMap.clear();\n this._onDestroy.next();\n this._onDestroy.complete();\n if (collections.isDataSource(this.dataSource)) {\n this.dataSource.disconnect(this);\n }\n };\n /**\n * Renders rows based on the table's latest set of data, which was either provided directly as an\n * input or retrieved through an Observable stream (directly or from a DataSource).\n * Checks for differences in the data since the last diff to perform only the necessary\n * changes (add/remove/move rows).\n *\n * If the table's data source is a DataSource or Observable, this will be invoked automatically\n * each time the provided Observable stream emits a new data array. Otherwise if your data is\n * an array, this function will need to be called to render any changes.\n */\n CdkTable.prototype.renderRows = function () {\n var _this = this;\n this._renderRows = this._getAllRenderRows();\n var changes = this._dataDiffer.diff(this._renderRows);\n if (!changes) {\n this._updateNoDataRow();\n return;\n }\n var viewContainer = this._rowOutlet.viewContainer;\n // @breaking-change 11.0.0 Remove null check for `_viewRepeater` and the\n // `else` clause once `_viewRepeater` is turned into a required parameter.\n if (this._viewRepeater) {\n this._viewRepeater.applyChanges(changes, viewContainer, function (record, _adjustedPreviousIndex, currentIndex) { return _this._getEmbeddedViewArgs(record.item, currentIndex); }, function (record) { return record.item.data; }, function (change) {\n if (change.operation === 1 /* INSERTED */ && change.context) {\n _this._renderCellTemplateForItem(change.record.item.rowDef, change.context);\n }\n });\n }\n else {\n changes.forEachOperation(function (record, prevIndex, currentIndex) {\n if (record.previousIndex == null) {\n var renderRow = record.item;\n var rowDef = renderRow.rowDef;\n var context = { $implicit: renderRow.data };\n _this._renderRow(_this._rowOutlet, rowDef, currentIndex, context);\n }\n else if (currentIndex == null) {\n viewContainer.remove(prevIndex);\n }\n else {\n var view = viewContainer.get(prevIndex);\n viewContainer.move(view, currentIndex);\n }\n });\n }\n // Update the meta context of a row's context data (index, count, first, last, ...)\n this._updateRowIndexContext();\n // Update rows that did not get added/removed/moved but may have had their identity changed,\n // e.g. if trackBy matched data on some property but the actual data reference changed.\n changes.forEachIdentityChange(function (record) {\n var rowView = viewContainer.get(record.currentIndex);\n rowView.context.$implicit = record.item.data;\n });\n this._updateNoDataRow();\n this.updateStickyColumnStyles();\n };\n /** Adds a column definition that was not included as part of the content children. */\n CdkTable.prototype.addColumnDef = function (columnDef) {\n this._customColumnDefs.add(columnDef);\n };\n /** Removes a column definition that was not included as part of the content children. */\n CdkTable.prototype.removeColumnDef = function (columnDef) {\n this._customColumnDefs.delete(columnDef);\n };\n /** Adds a row definition that was not included as part of the content children. */\n CdkTable.prototype.addRowDef = function (rowDef) {\n this._customRowDefs.add(rowDef);\n };\n /** Removes a row definition that was not included as part of the content children. */\n CdkTable.prototype.removeRowDef = function (rowDef) {\n this._customRowDefs.delete(rowDef);\n };\n /** Adds a header row definition that was not included as part of the content children. */\n CdkTable.prototype.addHeaderRowDef = function (headerRowDef) {\n this._customHeaderRowDefs.add(headerRowDef);\n this._headerRowDefChanged = true;\n };\n /** Removes a header row definition that was not included as part of the content children. */\n CdkTable.prototype.removeHeaderRowDef = function (headerRowDef) {\n this._customHeaderRowDefs.delete(headerRowDef);\n this._headerRowDefChanged = true;\n };\n /** Adds a footer row definition that was not included as part of the content children. */\n CdkTable.prototype.addFooterRowDef = function (footerRowDef) {\n this._customFooterRowDefs.add(footerRowDef);\n this._footerRowDefChanged = true;\n };\n /** Removes a footer row definition that was not included as part of the content children. */\n CdkTable.prototype.removeFooterRowDef = function (footerRowDef) {\n this._customFooterRowDefs.delete(footerRowDef);\n this._footerRowDefChanged = true;\n };\n /** Sets a no data row definition that was not included as a part of the content children. */\n CdkTable.prototype.setNoDataRow = function (noDataRow) {\n this._customNoDataRow = noDataRow;\n };\n /**\n * Updates the header sticky styles. First resets all applied styles with respect to the cells\n * sticking to the top. Then, evaluating which cells need to be stuck to the top. This is\n * automatically called when the header row changes its displayed set of columns, or if its\n * sticky input changes. May be called manually for cases where the cell content changes outside\n * of these events.\n */\n CdkTable.prototype.updateStickyHeaderRowStyles = function () {\n var headerRows = this._getRenderedRows(this._headerRowOutlet);\n var tableElement = this._elementRef.nativeElement;\n // Hide the thead element if there are no header rows. This is necessary to satisfy\n // overzealous a11y checkers that fail because the `rowgroup` element does not contain\n // required child `row`.\n var thead = tableElement.querySelector('thead');\n if (thead) {\n thead.style.display = headerRows.length ? '' : 'none';\n }\n var stickyStates = this._headerRowDefs.map(function (def) { return def.sticky; });\n this._stickyStyler.clearStickyPositioning(headerRows, ['top']);\n this._stickyStyler.stickRows(headerRows, stickyStates, 'top');\n // Reset the dirty state of the sticky input change since it has been used.\n this._headerRowDefs.forEach(function (def) { return def.resetStickyChanged(); });\n };\n /**\n * Updates the footer sticky styles. First resets all applied styles with respect to the cells\n * sticking to the bottom. Then, evaluating which cells need to be stuck to the bottom. This is\n * automatically called when the footer row changes its displayed set of columns, or if its\n * sticky input changes. May be called manually for cases where the cell content changes outside\n * of these events.\n */\n CdkTable.prototype.updateStickyFooterRowStyles = function () {\n var footerRows = this._getRenderedRows(this._footerRowOutlet);\n var tableElement = this._elementRef.nativeElement;\n // Hide the tfoot element if there are no footer rows. This is necessary to satisfy\n // overzealous a11y checkers that fail because the `rowgroup` element does not contain\n // required child `row`.\n var tfoot = tableElement.querySelector('tfoot');\n if (tfoot) {\n tfoot.style.display = footerRows.length ? '' : 'none';\n }\n var stickyStates = this._footerRowDefs.map(function (def) { return def.sticky; });\n this._stickyStyler.clearStickyPositioning(footerRows, ['bottom']);\n this._stickyStyler.stickRows(footerRows, stickyStates, 'bottom');\n this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement, stickyStates);\n // Reset the dirty state of the sticky input change since it has been used.\n this._footerRowDefs.forEach(function (def) { return def.resetStickyChanged(); });\n };\n /**\n * Updates the column sticky styles. First resets all applied styles with respect to the cells\n * sticking to the left and right. Then sticky styles are added for the left and right according\n * to the column definitions for each cell in each row. This is automatically called when\n * the data source provides a new set of data or when a column definition changes its sticky\n * input. May be called manually for cases where the cell content changes outside of these events.\n */\n CdkTable.prototype.updateStickyColumnStyles = function () {\n var _this = this;\n var headerRows = this._getRenderedRows(this._headerRowOutlet);\n var dataRows = this._getRenderedRows(this._rowOutlet);\n var footerRows = this._getRenderedRows(this._footerRowOutlet);\n // For tables not using a fixed layout, the column widths may change when new rows are rendered.\n // In a table using a fixed layout, row content won't affect column width, so sticky styles\n // don't need to be cleared unless either the sticky column config changes or one of the row\n // defs change.\n if ((this._isNativeHtmlTable && !this._fixedLayout)\n || this._stickyColumnStylesNeedReset) {\n // Clear the left and right positioning from all columns in the table across all rows since\n // sticky columns span across all table sections (header, data, footer)\n this._stickyStyler.clearStickyPositioning(__spread(headerRows, dataRows, footerRows), ['left', 'right']);\n this._stickyColumnStylesNeedReset = false;\n }\n // Update the sticky styles for each header row depending on the def's sticky state\n headerRows.forEach(function (headerRow, i) {\n _this._addStickyColumnStyles([headerRow], _this._headerRowDefs[i]);\n });\n // Update the sticky styles for each data row depending on its def's sticky state\n this._rowDefs.forEach(function (rowDef) {\n // Collect all the rows rendered with this row definition.\n var rows = [];\n for (var i = 0; i < dataRows.length; i++) {\n if (_this._renderRows[i].rowDef === rowDef) {\n rows.push(dataRows[i]);\n }\n }\n _this._addStickyColumnStyles(rows, rowDef);\n });\n // Update the sticky styles for each footer row depending on the def's sticky state\n footerRows.forEach(function (footerRow, i) {\n _this._addStickyColumnStyles([footerRow], _this._footerRowDefs[i]);\n });\n // Reset the dirty state of the sticky input change since it has been used.\n Array.from(this._columnDefsByName.values()).forEach(function (def) { return def.resetStickyChanged(); });\n };\n /**\n * Get the list of RenderRow objects to render according to the current list of data and defined\n * row definitions. If the previous list already contained a particular pair, it should be reused\n * so that the differ equates their references.\n */\n CdkTable.prototype._getAllRenderRows = function () {\n var renderRows = [];\n // Store the cache and create a new one. Any re-used RenderRow objects will be moved into the\n // new cache while unused ones can be picked up by garbage collection.\n var prevCachedRenderRows = this._cachedRenderRowsMap;\n this._cachedRenderRowsMap = new Map();\n // For each data object, get the list of rows that should be rendered, represented by the\n // respective `RenderRow` object which is the pair of `data` and `CdkRowDef`.\n for (var i = 0; i < this._data.length; i++) {\n var data = this._data[i];\n var renderRowsForData = this._getRenderRowsForData(data, i, prevCachedRenderRows.get(data));\n if (!this._cachedRenderRowsMap.has(data)) {\n this._cachedRenderRowsMap.set(data, new WeakMap());\n }\n for (var j = 0; j < renderRowsForData.length; j++) {\n var renderRow = renderRowsForData[j];\n var cache = this._cachedRenderRowsMap.get(renderRow.data);\n if (cache.has(renderRow.rowDef)) {\n cache.get(renderRow.rowDef).push(renderRow);\n }\n else {\n cache.set(renderRow.rowDef, [renderRow]);\n }\n renderRows.push(renderRow);\n }\n }\n return renderRows;\n };\n /**\n * Gets a list of `RenderRow<T>` for the provided data object and any `CdkRowDef` objects that\n * should be rendered for this data. Reuses the cached RenderRow objects if they match the same\n * `(T, CdkRowDef)` pair.\n */\n CdkTable.prototype._getRenderRowsForData = function (data, dataIndex, cache) {\n var rowDefs = this._getRowDefs(data, dataIndex);\n return rowDefs.map(function (rowDef) {\n var cachedRenderRows = (cache && cache.has(rowDef)) ? cache.get(rowDef) : [];\n if (cachedRenderRows.length) {\n var dataRow = cachedRenderRows.shift();\n dataRow.dataIndex = dataIndex;\n return dataRow;\n }\n else {\n return { data: data, rowDef: rowDef, dataIndex: dataIndex };\n }\n });\n };\n /** Update the map containing the content's column definitions. */\n CdkTable.prototype._cacheColumnDefs = function () {\n var _this = this;\n this._columnDefsByName.clear();\n var columnDefs = mergeArrayAndSet(this._getOwnDefs(this._contentColumnDefs), this._customColumnDefs);\n columnDefs.forEach(function (columnDef) {\n if (_this._columnDefsByName.has(columnDef.name) &&\n (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableDuplicateColumnNameError(columnDef.name);\n }\n _this._columnDefsByName.set(columnDef.name, columnDef);\n });\n };\n /** Update the list of all available row definitions that can be used. */\n CdkTable.prototype._cacheRowDefs = function () {\n this._headerRowDefs = mergeArrayAndSet(this._getOwnDefs(this._contentHeaderRowDefs), this._customHeaderRowDefs);\n this._footerRowDefs = mergeArrayAndSet(this._getOwnDefs(this._contentFooterRowDefs), this._customFooterRowDefs);\n this._rowDefs = mergeArrayAndSet(this._getOwnDefs(this._contentRowDefs), this._customRowDefs);\n // After all row definitions are determined, find the row definition to be considered default.\n var defaultRowDefs = this._rowDefs.filter(function (def) { return !def.when; });\n if (!this.multiTemplateDataRows && defaultRowDefs.length > 1 &&\n (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableMultipleDefaultRowDefsError();\n }\n this._defaultRowDef = defaultRowDefs[0];\n };\n /**\n * Check if the header, data, or footer rows have changed what columns they want to display or\n * whether the sticky states have changed for the header or footer. If there is a diff, then\n * re-render that section.\n */\n CdkTable.prototype._renderUpdatedColumns = function () {\n var columnsDiffReducer = function (acc, def) { return acc || !!def.getColumnsDiff(); };\n // Force re-render data rows if the list of column definitions have changed.\n var dataColumnsChanged = this._rowDefs.reduce(columnsDiffReducer, false);\n if (dataColumnsChanged) {\n this._forceRenderDataRows();\n }\n // Force re-render header/footer rows if the list of column definitions have changed.\n var headerColumnsChanged = this._headerRowDefs.reduce(columnsDiffReducer, false);\n if (headerColumnsChanged) {\n this._forceRenderHeaderRows();\n }\n var footerColumnsChanged = this._footerRowDefs.reduce(columnsDiffReducer, false);\n if (footerColumnsChanged) {\n this._forceRenderFooterRows();\n }\n return dataColumnsChanged || headerColumnsChanged || footerColumnsChanged;\n };\n /**\n * Switch to the provided data source by resetting the data and unsubscribing from the current\n * render change subscription if one exists. If the data source is null, interpret this by\n * clearing the row outlet. Otherwise start listening for new data.\n */\n CdkTable.prototype._switchDataSource = function (dataSource) {\n this._data = [];\n if (collections.isDataSource(this.dataSource)) {\n this.dataSource.disconnect(this);\n }\n // Stop listening for data from the previous data source.\n if (this._renderChangeSubscription) {\n this._renderChangeSubscription.unsubscribe();\n this._renderChangeSubscription = null;\n }\n if (!dataSource) {\n if (this._dataDiffer) {\n this._dataDiffer.diff([]);\n }\n this._rowOutlet.viewContainer.clear();\n }\n this._dataSource = dataSource;\n };\n /** Set up a subscription for the data provided by the data source. */\n CdkTable.prototype._observeRenderChanges = function () {\n var _this = this;\n // If no data source has been set, there is nothing to observe for changes.\n if (!this.dataSource) {\n return;\n }\n var dataStream;\n if (collections.isDataSource(this.dataSource)) {\n dataStream = this.dataSource.connect(this);\n }\n else if (rxjs.isObservable(this.dataSource)) {\n dataStream = this.dataSource;\n }\n else if (Array.isArray(this.dataSource)) {\n dataStream = rxjs.of(this.dataSource);\n }\n if (dataStream === undefined && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableUnknownDataSourceError();\n }\n this._renderChangeSubscription = dataStream.pipe(operators.takeUntil(this._onDestroy))\n .subscribe(function (data) {\n _this._data = data || [];\n _this.renderRows();\n });\n };\n /**\n * Clears any existing content in the header row outlet and creates a new embedded view\n * in the outlet using the header row definition.\n */\n CdkTable.prototype._forceRenderHeaderRows = function () {\n var _this = this;\n // Clear the header row outlet if any content exists.\n if (this._headerRowOutlet.viewContainer.length > 0) {\n this._headerRowOutlet.viewContainer.clear();\n }\n this._headerRowDefs.forEach(function (def, i) { return _this._renderRow(_this._headerRowOutlet, def, i); });\n this.updateStickyHeaderRowStyles();\n };\n /**\n * Clears any existing content in the footer row outlet and creates a new embedded view\n * in the outlet using the footer row definition.\n */\n CdkTable.prototype._forceRenderFooterRows = function () {\n var _this = this;\n // Clear the footer row outlet if any content exists.\n if (this._footerRowOutlet.viewContainer.length > 0) {\n this._footerRowOutlet.viewContainer.clear();\n }\n this._footerRowDefs.forEach(function (def, i) { return _this._renderRow(_this._footerRowOutlet, def, i); });\n this.updateStickyFooterRowStyles();\n };\n /** Adds the sticky column styles for the rows according to the columns' stick states. */\n CdkTable.prototype._addStickyColumnStyles = function (rows, rowDef) {\n var _this = this;\n var columnDefs = Array.from(rowDef.columns || []).map(function (columnName) {\n var columnDef = _this._columnDefsByName.get(columnName);\n if (!columnDef && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableUnknownColumnError(columnName);\n }\n return columnDef;\n });\n var stickyStartStates = columnDefs.map(function (columnDef) { return columnDef.sticky; });\n var stickyEndStates = columnDefs.map(function (columnDef) { return columnDef.stickyEnd; });\n this._stickyStyler.updateStickyColumns(rows, stickyStartStates, stickyEndStates, !this._fixedLayout || this._forceRecalculateCellWidths);\n };\n /** Gets the list of rows that have been rendered in the row outlet. */\n CdkTable.prototype._getRenderedRows = function (rowOutlet) {\n var renderedRows = [];\n for (var i = 0; i < rowOutlet.viewContainer.length; i++) {\n var viewRef = rowOutlet.viewContainer.get(i);\n renderedRows.push(viewRef.rootNodes[0]);\n }\n return renderedRows;\n };\n /**\n * Get the matching row definitions that should be used for this row data. If there is only\n * one row definition, it is returned. Otherwise, find the row definitions that has a when\n * predicate that returns true with the data. If none return true, return the default row\n * definition.\n */\n CdkTable.prototype._getRowDefs = function (data, dataIndex) {\n if (this._rowDefs.length == 1) {\n return [this._rowDefs[0]];\n }\n var rowDefs = [];\n if (this.multiTemplateDataRows) {\n rowDefs = this._rowDefs.filter(function (def) { return !def.when || def.when(dataIndex, data); });\n }\n else {\n var rowDef = this._rowDefs.find(function (def) { return def.when && def.when(dataIndex, data); }) || this._defaultRowDef;\n if (rowDef) {\n rowDefs.push(rowDef);\n }\n }\n if (!rowDefs.length && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableMissingMatchingRowDefError(data);\n }\n return rowDefs;\n };\n CdkTable.prototype._getEmbeddedViewArgs = function (renderRow, index) {\n var rowDef = renderRow.rowDef;\n var context = { $implicit: renderRow.data };\n return {\n templateRef: rowDef.template,\n context: context,\n index: index,\n };\n };\n /**\n * Creates a new row template in the outlet and fills it with the set of cell templates.\n * Optionally takes a context to provide to the row and cells, as well as an optional index\n * of where to place the new row template in the outlet.\n */\n CdkTable.prototype._renderRow = function (outlet, rowDef, index, context) {\n if (context === void 0) { context = {}; }\n // TODO(andrewseguin): enforce that one outlet was instantiated from createEmbeddedView\n var view = outlet.viewContainer.createEmbeddedView(rowDef.template, context, index);\n this._renderCellTemplateForItem(rowDef, context);\n return view;\n };\n CdkTable.prototype._renderCellTemplateForItem = function (rowDef, context) {\n var e_1, _a;\n try {\n for (var _b = __values(this._getCellTemplates(rowDef)), _c = _b.next(); !_c.done; _c = _b.next()) {\n var cellTemplate = _c.value;\n if (CdkCellOutlet.mostRecentCellOutlet) {\n CdkCellOutlet.mostRecentCellOutlet._viewContainer.createEmbeddedView(cellTemplate, context);\n }\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (_c && !_c.done && (_a = _b.return)) _a.call(_b);\n }\n finally { if (e_1) throw e_1.error; }\n }\n this._changeDetectorRef.markForCheck();\n };\n /**\n * Updates the index-related context for each row to reflect any changes in the index of the rows,\n * e.g. first/last/even/odd.\n */\n CdkTable.prototype._updateRowIndexContext = function () {\n var viewContainer = this._rowOutlet.viewContainer;\n for (var renderIndex = 0, count = viewContainer.length; renderIndex < count; renderIndex++) {\n var viewRef = viewContainer.get(renderIndex);\n var context = viewRef.context;\n context.count = count;\n context.first = renderIndex === 0;\n context.last = renderIndex === count - 1;\n context.even = renderIndex % 2 === 0;\n context.odd = !context.even;\n if (this.multiTemplateDataRows) {\n context.dataIndex = this._renderRows[renderIndex].dataIndex;\n context.renderIndex = renderIndex;\n }\n else {\n context.index = this._renderRows[renderIndex].dataIndex;\n }\n }\n };\n /** Gets the column definitions for the provided row def. */\n CdkTable.prototype._getCellTemplates = function (rowDef) {\n var _this = this;\n if (!rowDef || !rowDef.columns) {\n return [];\n }\n return Array.from(rowDef.columns, function (columnId) {\n var column = _this._columnDefsByName.get(columnId);\n if (!column && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableUnknownColumnError(columnId);\n }\n return rowDef.extractCellTemplate(column);\n });\n };\n /** Adds native table sections (e.g. tbody) and moves the row outlets into them. */\n CdkTable.prototype._applyNativeTableSections = function () {\n var e_2, _a, e_3, _b;\n var documentFragment = this._document.createDocumentFragment();\n var sections = [\n { tag: 'thead', outlets: [this._headerRowOutlet] },\n { tag: 'tbody', outlets: [this._rowOutlet, this._noDataRowOutlet] },\n { tag: 'tfoot', outlets: [this._footerRowOutlet] },\n ];\n try {\n for (var sections_1 = __values(sections), sections_1_1 = sections_1.next(); !sections_1_1.done; sections_1_1 = sections_1.next()) {\n var section = sections_1_1.value;\n var element = this._document.createElement(section.tag);\n element.setAttribute('role', 'rowgroup');\n try {\n for (var _c = (e_3 = void 0, __values(section.outlets)), _d = _c.next(); !_d.done; _d = _c.next()) {\n var outlet = _d.value;\n element.appendChild(outlet.elementRef.nativeElement);\n }\n }\n catch (e_3_1) { e_3 = { error: e_3_1 }; }\n finally {\n try {\n if (_d && !_d.done && (_b = _c.return)) _b.call(_c);\n }\n finally { if (e_3) throw e_3.error; }\n }\n documentFragment.appendChild(element);\n }\n }\n catch (e_2_1) { e_2 = { error: e_2_1 }; }\n finally {\n try {\n if (sections_1_1 && !sections_1_1.done && (_a = sections_1.return)) _a.call(sections_1);\n }\n finally { if (e_2) throw e_2.error; }\n }\n // Use a DocumentFragment so we don't hit the DOM on each iteration.\n this._elementRef.nativeElement.appendChild(documentFragment);\n };\n /**\n * Forces a re-render of the data rows. Should be called in cases where there has been an input\n * change that affects the evaluation of which rows should be rendered, e.g. toggling\n * `multiTemplateDataRows` or adding/removing row definitions.\n */\n CdkTable.prototype._forceRenderDataRows = function () {\n this._dataDiffer.diff([]);\n this._rowOutlet.viewContainer.clear();\n this.renderRows();\n };\n /**\n * Checks if there has been a change in sticky states since last check and applies the correct\n * sticky styles. Since checking resets the \"dirty\" state, this should only be performed once\n * during a change detection and after the inputs are settled (after content check).\n */\n CdkTable.prototype._checkStickyStates = function () {\n var stickyCheckReducer = function (acc, d) {\n return acc || d.hasStickyChanged();\n };\n // Note that the check needs to occur for every definition since it notifies the definition\n // that it can reset its dirty state. Using another operator like `some` may short-circuit\n // remaining definitions and leave them in an unchecked state.\n if (this._headerRowDefs.reduce(stickyCheckReducer, false)) {\n this.updateStickyHeaderRowStyles();\n }\n if (this._footerRowDefs.reduce(stickyCheckReducer, false)) {\n this.updateStickyFooterRowStyles();\n }\n if (Array.from(this._columnDefsByName.values()).reduce(stickyCheckReducer, false)) {\n this._stickyColumnStylesNeedReset = true;\n this.updateStickyColumnStyles();\n }\n };\n /**\n * Creates the sticky styler that will be used for sticky rows and columns. Listens\n * for directionality changes and provides the latest direction to the styler. Re-applies column\n * stickiness when directionality changes.\n */\n CdkTable.prototype._setupStickyStyler = function () {\n var _this = this;\n var direction = this._dir ? this._dir.value : 'ltr';\n this._stickyStyler = new StickyStyler(this._isNativeHtmlTable, this.stickyCssClass, direction, this._coalescedStyleScheduler, this._platform.isBrowser, this.needsPositionStickyOnElement, this._stickyPositioningListener);\n (this._dir ? this._dir.change : rxjs.of())\n .pipe(operators.takeUntil(this._onDestroy))\n .subscribe(function (value) {\n _this._stickyStyler.direction = value;\n _this.updateStickyColumnStyles();\n });\n };\n /** Filters definitions that belong to this table from a QueryList. */\n CdkTable.prototype._getOwnDefs = function (items) {\n var _this = this;\n return items.filter(function (item) { return !item._table || item._table === _this; });\n };\n /** Creates or removes the no data row, depending on whether any data is being shown. */\n CdkTable.prototype._updateNoDataRow = function () {\n var noDataRow = this._customNoDataRow || this._noDataRow;\n if (noDataRow) {\n var shouldShow = this._rowOutlet.viewContainer.length === 0;\n if (shouldShow !== this._isShowingNoDataRow) {\n var container = this._noDataRowOutlet.viewContainer;\n shouldShow ? container.createEmbeddedView(noDataRow.templateRef) : container.clear();\n this._isShowingNoDataRow = shouldShow;\n }\n }\n };\n return CdkTable;\n }());\n CdkTable.decorators = [\n { type: core.Component, args: [{\n selector: 'cdk-table, table[cdk-table]',\n exportAs: 'cdkTable',\n template: CDK_TABLE_TEMPLATE,\n host: {\n 'class': 'cdk-table',\n '[class.cdk-table-fixed-layout]': 'fixedLayout',\n },\n encapsulation: core.ViewEncapsulation.None,\n // The \"OnPush\" status for the `MatTable` component is effectively a noop, so we are removing it.\n // The view for `MatTable` consists entirely of templates declared in other views. As they are\n // declared elsewhere, they are checked when their declaration points are checked.\n // tslint:disable-next-line:validate-decorators\n changeDetection: core.ChangeDetectionStrategy.Default,\n providers: [\n { provide: CDK_TABLE, useExisting: CdkTable },\n { provide: collections._VIEW_REPEATER_STRATEGY, useClass: collections._DisposeViewRepeaterStrategy },\n { provide: _COALESCED_STYLE_SCHEDULER, useClass: _CoalescedStyleScheduler },\n // Prevent nested tables from seeing this table's StickyPositioningListener.\n { provide: STICKY_POSITIONING_LISTENER, useValue: null },\n ],\n styles: [\".cdk-table-fixed-layout{table-layout:fixed}\\n\"]\n },] }\n ];\n CdkTable.ctorParameters = function () { return [\n { type: core.IterableDiffers },\n { type: core.ChangeDetectorRef },\n { type: core.ElementRef },\n { type: String, decorators: [{ type: core.Attribute, args: ['role',] }] },\n { type: bidi.Directionality, decorators: [{ type: core.Optional }] },\n { type: undefined, decorators: [{ type: core.Inject, args: [common.DOCUMENT,] }] },\n { type: platform.Platform },\n { type: undefined, decorators: [{ type: core.Optional }, { type: core.Inject, args: [collections._VIEW_REPEATER_STRATEGY,] }] },\n { type: _CoalescedStyleScheduler, decorators: [{ type: core.Optional }, { type: core.Inject, args: [_COALESCED_STYLE_SCHEDULER,] }] },\n { type: undefined, decorators: [{ type: core.Optional }, { type: core.SkipSelf }, { type: core.Inject, args: [STICKY_POSITIONING_LISTENER,] }] },\n { type: scrolling.ViewportRuler, decorators: [{ type: core.Optional }] }\n ]; };\n CdkTable.propDecorators = {\n trackBy: [{ type: core.Input }],\n dataSource: [{ type: core.Input }],\n multiTemplateDataRows: [{ type: core.Input }],\n fixedLayout: [{ type: core.Input }],\n _rowOutlet: [{ type: core.ViewChild, args: [DataRowOutlet, { static: true },] }],\n _headerRowOutlet: [{ type: core.ViewChild, args: [HeaderRowOutlet, { static: true },] }],\n _footerRowOutlet: [{ type: core.ViewChild, args: [FooterRowOutlet, { static: true },] }],\n _noDataRowOutlet: [{ type: core.ViewChild, args: [NoDataRowOutlet, { static: true },] }],\n _contentColumnDefs: [{ type: core.ContentChildren, args: [CdkColumnDef, { descendants: true },] }],\n _contentRowDefs: [{ type: core.ContentChildren, args: [CdkRowDef, { descendants: true },] }],\n _contentHeaderRowDefs: [{ type: core.ContentChildren, args: [CdkHeaderRowDef, {\n descendants: true\n },] }],\n _contentFooterRowDefs: [{ type: core.ContentChildren, args: [CdkFooterRowDef, {\n descendants: true\n },] }],\n _noDataRow: [{ type: core.ContentChild, args: [CdkNoDataRow,] }]\n };\n /** Utility function that gets a merged list of the entries in an array and values of a Set. */\n function mergeArrayAndSet(array, set) {\n return array.concat(Array.from(set));\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 /**\n * Column that simply shows text content for the header and row cells. Assumes that the table\n * is using the native table implementation (`<table>`).\n *\n * By default, the name of this column will be the header text and data property accessor.\n * The header text can be overridden with the `headerText` input. Cell values can be overridden with\n * the `dataAccessor` input. Change the text justification to the start or end using the `justify`\n * input.\n */\n var CdkTextColumn = /** @class */ (function () {\n function CdkTextColumn(\n // `CdkTextColumn` is always requiring a table, but we just assert it manually\n // for better error reporting.\n // tslint:disable-next-line: lightweight-tokens\n _table, _options) {\n this._table = _table;\n this._options = _options;\n /** Alignment of the cell values. */\n this.justify = 'start';\n this._options = _options || {};\n }\n Object.defineProperty(CdkTextColumn.prototype, \"name\", {\n /** Column name that should be used to reference this column. */\n get: function () {\n return this._name;\n },\n set: function (name) {\n this._name = name;\n // With Ivy, inputs can be initialized before static query results are\n // available. In that case, we defer the synchronization until \"ngOnInit\" fires.\n this._syncColumnDefName();\n },\n enumerable: false,\n configurable: true\n });\n CdkTextColumn.prototype.ngOnInit = function () {\n this._syncColumnDefName();\n if (this.headerText === undefined) {\n this.headerText = this._createDefaultHeaderText();\n }\n if (!this.dataAccessor) {\n this.dataAccessor =\n this._options.defaultDataAccessor || (function (data, name) { return data[name]; });\n }\n if (this._table) {\n // Provide the cell and headerCell directly to the table with the static `ViewChild` query,\n // since the columnDef will not pick up its content by the time the table finishes checking\n // its content and initializing the rows.\n this.columnDef.cell = this.cell;\n this.columnDef.headerCell = this.headerCell;\n this._table.addColumnDef(this.columnDef);\n }\n else if (typeof ngDevMode === 'undefined' || ngDevMode) {\n throw getTableTextColumnMissingParentTableError();\n }\n };\n CdkTextColumn.prototype.ngOnDestroy = function () {\n if (this._table) {\n this._table.removeColumnDef(this.columnDef);\n }\n };\n /**\n * Creates a default header text. Use the options' header text transformation function if one\n * has been provided. Otherwise simply capitalize the column name.\n */\n CdkTextColumn.prototype._createDefaultHeaderText = function () {\n var name = this.name;\n if (!name && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getTableTextColumnMissingNameError();\n }\n if (this._options && this._options.defaultHeaderTextTransform) {\n return this._options.defaultHeaderTextTransform(name);\n }\n return name[0].toUpperCase() + name.slice(1);\n };\n /** Synchronizes the column definition name with the text column name. */\n CdkTextColumn.prototype._syncColumnDefName = function () {\n if (this.columnDef) {\n this.columnDef.name = this.name;\n }\n };\n return CdkTextColumn;\n }());\n CdkTextColumn.decorators = [\n { type: core.Component, args: [{\n selector: 'cdk-text-column',\n template: \"\\n <ng-container cdkColumnDef>\\n <th cdk-header-cell *cdkHeaderCellDef [style.text-align]=\\\"justify\\\">\\n {{headerText}}\\n </th>\\n <td cdk-cell *cdkCellDef=\\\"let data\\\" [style.text-align]=\\\"justify\\\">\\n {{dataAccessor(data, name)}}\\n </td>\\n </ng-container>\\n \",\n encapsulation: core.ViewEncapsulation.None,\n // Change detection is intentionally not set to OnPush. This component's template will be provided\n // to the table to be inserted into its view. This is problematic when change detection runs since\n // the bindings in this template will be evaluated _after_ the table's view is evaluated, which\n // mean's the template in the table's view will not have the updated value (and in fact will cause\n // an ExpressionChangedAfterItHasBeenCheckedError).\n // tslint:disable-next-line:validate-decorators\n changeDetection: core.ChangeDetectionStrategy.Default\n },] }\n ];\n CdkTextColumn.ctorParameters = function () { return [\n { type: CdkTable, decorators: [{ type: core.Optional }] },\n { type: undefined, decorators: [{ type: core.Optional }, { type: core.Inject, args: [TEXT_COLUMN_OPTIONS,] }] }\n ]; };\n CdkTextColumn.propDecorators = {\n name: [{ type: core.Input }],\n headerText: [{ type: core.Input }],\n dataAccessor: [{ type: core.Input }],\n justify: [{ type: core.Input }],\n columnDef: [{ type: core.ViewChild, args: [CdkColumnDef, { static: true },] }],\n cell: [{ type: core.ViewChild, args: [CdkCellDef, { static: true },] }],\n headerCell: [{ type: core.ViewChild, args: [CdkHeaderCellDef, { static: true },] }]\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 var EXPORTED_DECLARATIONS = [\n CdkTable,\n CdkRowDef,\n CdkCellDef,\n CdkCellOutlet,\n CdkHeaderCellDef,\n CdkFooterCellDef,\n CdkColumnDef,\n CdkCell,\n CdkRow,\n CdkHeaderCell,\n CdkFooterCell,\n CdkHeaderRow,\n CdkHeaderRowDef,\n CdkFooterRow,\n CdkFooterRowDef,\n DataRowOutlet,\n HeaderRowOutlet,\n FooterRowOutlet,\n CdkTextColumn,\n CdkNoDataRow,\n NoDataRowOutlet,\n ];\n var CdkTableModule = /** @class */ (function () {\n function CdkTableModule() {\n }\n return CdkTableModule;\n }());\n CdkTableModule.decorators = [\n { type: core.NgModule, args: [{\n exports: EXPORTED_DECLARATIONS,\n declarations: EXPORTED_DECLARATIONS,\n imports: [scrolling.ScrollingModule]\n },] }\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\n /**\n * Generated bundle index. Do not edit.\n */\n\n Object.defineProperty(exports, 'DataSource', {\n enumerable: true,\n get: function () {\n return collections.DataSource;\n }\n });\n exports.BaseCdkCell = BaseCdkCell;\n exports.BaseRowDef = BaseRowDef;\n exports.CDK_ROW_TEMPLATE = CDK_ROW_TEMPLATE;\n exports.CDK_TABLE = CDK_TABLE;\n exports.CDK_TABLE_TEMPLATE = CDK_TABLE_TEMPLATE;\n exports.CdkCell = CdkCell;\n exports.CdkCellDef = CdkCellDef;\n exports.CdkCellOutlet = CdkCellOutlet;\n exports.CdkColumnDef = CdkColumnDef;\n exports.CdkFooterCell = CdkFooterCell;\n exports.CdkFooterCellDef = CdkFooterCellDef;\n exports.CdkFooterRow = CdkFooterRow;\n exports.CdkFooterRowDef = CdkFooterRowDef;\n exports.CdkHeaderCell = CdkHeaderCell;\n exports.CdkHeaderCellDef = CdkHeaderCellDef;\n exports.CdkHeaderRow = CdkHeaderRow;\n exports.CdkHeaderRowDef = CdkHeaderRowDef;\n exports.CdkNoDataRow = CdkNoDataRow;\n exports.CdkRow = CdkRow;\n exports.CdkRowDef = CdkRowDef;\n exports.CdkTable = CdkTable;\n exports.CdkTableModule = CdkTableModule;\n exports.CdkTextColumn = CdkTextColumn;\n exports.DataRowOutlet = DataRowOutlet;\n exports.FooterRowOutlet = FooterRowOutlet;\n exports.HeaderRowOutlet = HeaderRowOutlet;\n exports.NoDataRowOutlet = NoDataRowOutlet;\n exports.STICKY_DIRECTIONS = STICKY_DIRECTIONS;\n exports.STICKY_POSITIONING_LISTENER = STICKY_POSITIONING_LISTENER;\n exports.StickyStyler = StickyStyler;\n exports.TEXT_COLUMN_OPTIONS = TEXT_COLUMN_OPTIONS;\n exports._COALESCED_STYLE_SCHEDULER = _COALESCED_STYLE_SCHEDULER;\n exports._CoalescedStyleScheduler = _CoalescedStyleScheduler;\n exports._Schedule = _Schedule;\n exports.mixinHasStickyInput = mixinHasStickyInput;\n\n Object.defineProperty(exports, '__esModule', { value: true });\n\n})));\n//# sourceMappingURL=cdk-table.umd.js.map\n"]}