legacy-table.mjs 38 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534
  1. import * as i0 from '@angular/core';
  2. import { Directive, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, NgModule } from '@angular/core';
  3. import * as i1 from '@angular/cdk/table';
  4. import { CdkTable, CDK_TABLE, _COALESCED_STYLE_SCHEDULER, _CoalescedStyleScheduler, STICKY_POSITIONING_LISTENER, CDK_TABLE_TEMPLATE, CdkCellDef, CdkHeaderCellDef, CdkFooterCellDef, CdkColumnDef, CdkHeaderCell, CdkFooterCell, CdkCell, CdkHeaderRowDef, CdkFooterRowDef, CdkRowDef, CdkHeaderRow, CDK_ROW_TEMPLATE, CdkFooterRow, CdkRow, CdkNoDataRow, CdkTextColumn, CdkTableModule } from '@angular/cdk/table';
  5. import { _VIEW_REPEATER_STRATEGY, _RecycleViewRepeaterStrategy, _DisposeViewRepeaterStrategy } from '@angular/cdk/collections';
  6. import { MatCommonModule } from '@angular/material/core';
  7. import { _MatTableDataSource } from '@angular/material/table';
  8. export { _MatTableDataSource as _MatLegacyTableDataSource } from '@angular/material/table';
  9. /**
  10. * Enables the recycle view repeater strategy, which reduces rendering latency. Not compatible with
  11. * tables that animate rows.
  12. * @deprecated Use `MatRecycleRows` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  13. * @breaking-change 17.0.0
  14. */
  15. class MatLegacyRecycleRows {
  16. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyRecycleRows, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
  17. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyRecycleRows, selector: "mat-table[recycleRows], table[mat-table][recycleRows]", providers: [{ provide: _VIEW_REPEATER_STRATEGY, useClass: _RecycleViewRepeaterStrategy }], ngImport: i0 }); }
  18. }
  19. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyRecycleRows, decorators: [{
  20. type: Directive,
  21. args: [{
  22. selector: 'mat-table[recycleRows], table[mat-table][recycleRows]',
  23. providers: [{ provide: _VIEW_REPEATER_STRATEGY, useClass: _RecycleViewRepeaterStrategy }],
  24. }]
  25. }] });
  26. /**
  27. * Wrapper for the CdkTable with Material design styles.
  28. * @deprecated Use `MatTable` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  29. * @breaking-change 17.0.0
  30. */
  31. class MatLegacyTable extends CdkTable {
  32. constructor() {
  33. super(...arguments);
  34. /** Overrides the sticky CSS class set by the `CdkTable`. */
  35. this.stickyCssClass = 'mat-table-sticky';
  36. /** Overrides the need to add position: sticky on every sticky cell element in `CdkTable`. */
  37. this.needsPositionStickyOnElement = false;
  38. }
  39. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTable, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
  40. static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyTable, selector: "mat-table, table[mat-table]", host: { attributes: { "ngSkipHydration": "" }, properties: { "class.mat-table-fixed-layout": "fixedLayout" }, classAttribute: "mat-table" }, providers: [
  41. // TODO(michaeljamesparsons) Abstract the view repeater strategy to a directive API so this code
  42. // is only included in the build if used.
  43. { provide: _VIEW_REPEATER_STRATEGY, useClass: _DisposeViewRepeaterStrategy },
  44. { provide: CdkTable, useExisting: MatLegacyTable },
  45. { provide: CDK_TABLE, useExisting: MatLegacyTable },
  46. { provide: _COALESCED_STYLE_SCHEDULER, useClass: _CoalescedStyleScheduler },
  47. // Prevent nested tables from seeing this table's StickyPositioningListener.
  48. { provide: STICKY_POSITIONING_LISTENER, useValue: null },
  49. ], exportAs: ["matTable"], usesInheritance: true, ngImport: i0, template: "\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", isInline: true, styles: ["mat-table{display:block}mat-header-row{min-height:56px}mat-row,mat-footer-row{min-height:48px}mat-row,mat-header-row,mat-footer-row{display:flex;border-width:0;border-bottom-width:1px;border-style:solid;align-items:center;box-sizing:border-box}mat-cell:first-of-type,mat-header-cell:first-of-type,mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] mat-cell:first-of-type:not(:only-of-type),[dir=rtl] mat-header-cell:first-of-type:not(:only-of-type),[dir=rtl] mat-footer-cell:first-of-type:not(:only-of-type){padding-left:0;padding-right:24px}mat-cell:last-of-type,mat-header-cell:last-of-type,mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] mat-cell:last-of-type:not(:only-of-type),[dir=rtl] mat-header-cell:last-of-type:not(:only-of-type),[dir=rtl] mat-footer-cell:last-of-type:not(:only-of-type){padding-right:0;padding-left:24px}mat-cell,mat-header-cell,mat-footer-cell{flex:1;display:flex;align-items:center;overflow:hidden;word-wrap:break-word;min-height:inherit}table.mat-table{border-spacing:0}tr.mat-header-row{height:56px}tr.mat-row,tr.mat-footer-row{height:48px}th.mat-header-cell{text-align:left}[dir=rtl] th.mat-header-cell{text-align:right}th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:0;border-bottom-width:1px;border-bottom-style:solid}th.mat-header-cell:first-of-type,td.mat-cell:first-of-type,td.mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] th.mat-header-cell:first-of-type:not(:only-of-type),[dir=rtl] td.mat-cell:first-of-type:not(:only-of-type),[dir=rtl] td.mat-footer-cell:first-of-type:not(:only-of-type){padding-left:0;padding-right:24px}th.mat-header-cell:last-of-type,td.mat-cell:last-of-type,td.mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] th.mat-header-cell:last-of-type:not(:only-of-type),[dir=rtl] td.mat-cell:last-of-type:not(:only-of-type),[dir=rtl] td.mat-footer-cell:last-of-type:not(:only-of-type){padding-right:0;padding-left:24px}.mat-table-sticky{position:sticky !important}.mat-table-fixed-layout{table-layout:fixed}"], dependencies: [{ kind: "directive", type: i1.DataRowOutlet, selector: "[rowOutlet]" }, { kind: "directive", type: i1.HeaderRowOutlet, selector: "[headerRowOutlet]" }, { kind: "directive", type: i1.FooterRowOutlet, selector: "[footerRowOutlet]" }, { kind: "directive", type: i1.NoDataRowOutlet, selector: "[noDataRowOutlet]" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
  50. }
  51. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTable, decorators: [{
  52. type: Component,
  53. args: [{ selector: 'mat-table, table[mat-table]', exportAs: 'matTable', template: CDK_TABLE_TEMPLATE, host: {
  54. 'class': 'mat-table',
  55. '[class.mat-table-fixed-layout]': 'fixedLayout',
  56. 'ngSkipHydration': '',
  57. }, providers: [
  58. // TODO(michaeljamesparsons) Abstract the view repeater strategy to a directive API so this code
  59. // is only included in the build if used.
  60. { provide: _VIEW_REPEATER_STRATEGY, useClass: _DisposeViewRepeaterStrategy },
  61. { provide: CdkTable, useExisting: MatLegacyTable },
  62. { provide: CDK_TABLE, useExisting: MatLegacyTable },
  63. { provide: _COALESCED_STYLE_SCHEDULER, useClass: _CoalescedStyleScheduler },
  64. // Prevent nested tables from seeing this table's StickyPositioningListener.
  65. { provide: STICKY_POSITIONING_LISTENER, useValue: null },
  66. ], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.Default, styles: ["mat-table{display:block}mat-header-row{min-height:56px}mat-row,mat-footer-row{min-height:48px}mat-row,mat-header-row,mat-footer-row{display:flex;border-width:0;border-bottom-width:1px;border-style:solid;align-items:center;box-sizing:border-box}mat-cell:first-of-type,mat-header-cell:first-of-type,mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] mat-cell:first-of-type:not(:only-of-type),[dir=rtl] mat-header-cell:first-of-type:not(:only-of-type),[dir=rtl] mat-footer-cell:first-of-type:not(:only-of-type){padding-left:0;padding-right:24px}mat-cell:last-of-type,mat-header-cell:last-of-type,mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] mat-cell:last-of-type:not(:only-of-type),[dir=rtl] mat-header-cell:last-of-type:not(:only-of-type),[dir=rtl] mat-footer-cell:last-of-type:not(:only-of-type){padding-right:0;padding-left:24px}mat-cell,mat-header-cell,mat-footer-cell{flex:1;display:flex;align-items:center;overflow:hidden;word-wrap:break-word;min-height:inherit}table.mat-table{border-spacing:0}tr.mat-header-row{height:56px}tr.mat-row,tr.mat-footer-row{height:48px}th.mat-header-cell{text-align:left}[dir=rtl] th.mat-header-cell{text-align:right}th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:0;border-bottom-width:1px;border-bottom-style:solid}th.mat-header-cell:first-of-type,td.mat-cell:first-of-type,td.mat-footer-cell:first-of-type{padding-left:24px}[dir=rtl] th.mat-header-cell:first-of-type:not(:only-of-type),[dir=rtl] td.mat-cell:first-of-type:not(:only-of-type),[dir=rtl] td.mat-footer-cell:first-of-type:not(:only-of-type){padding-left:0;padding-right:24px}th.mat-header-cell:last-of-type,td.mat-cell:last-of-type,td.mat-footer-cell:last-of-type{padding-right:24px}[dir=rtl] th.mat-header-cell:last-of-type:not(:only-of-type),[dir=rtl] td.mat-cell:last-of-type:not(:only-of-type),[dir=rtl] td.mat-footer-cell:last-of-type:not(:only-of-type){padding-right:0;padding-left:24px}.mat-table-sticky{position:sticky !important}.mat-table-fixed-layout{table-layout:fixed}"] }]
  67. }] });
  68. /**
  69. * Cell definition for the mat-table.
  70. * Captures the template of a column's data row cell as well as cell-specific properties.
  71. * @deprecated Use `MatCellDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  72. * @breaking-change 17.0.0
  73. */
  74. class MatLegacyCellDef extends CdkCellDef {
  75. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyCellDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  76. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyCellDef, selector: "[matCellDef]", providers: [{ provide: CdkCellDef, useExisting: MatLegacyCellDef }], usesInheritance: true, ngImport: i0 }); }
  77. }
  78. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyCellDef, decorators: [{
  79. type: Directive,
  80. args: [{
  81. selector: '[matCellDef]',
  82. providers: [{ provide: CdkCellDef, useExisting: MatLegacyCellDef }],
  83. }]
  84. }] });
  85. /**
  86. * Header cell definition for the mat-table.
  87. * Captures the template of a column's header cell and as well as cell-specific properties.
  88. * @deprecated Use `MatHeaderCellDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  89. * @breaking-change 17.0.0
  90. */
  91. class MatLegacyHeaderCellDef extends CdkHeaderCellDef {
  92. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderCellDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  93. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyHeaderCellDef, selector: "[matHeaderCellDef]", providers: [{ provide: CdkHeaderCellDef, useExisting: MatLegacyHeaderCellDef }], usesInheritance: true, ngImport: i0 }); }
  94. }
  95. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderCellDef, decorators: [{
  96. type: Directive,
  97. args: [{
  98. selector: '[matHeaderCellDef]',
  99. providers: [{ provide: CdkHeaderCellDef, useExisting: MatLegacyHeaderCellDef }],
  100. }]
  101. }] });
  102. /**
  103. * Footer cell definition for the mat-table.
  104. * Captures the template of a column's footer cell and as well as cell-specific properties.
  105. * @deprecated Use `MatFooterCellDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  106. * @breaking-change 17.0.0
  107. */
  108. class MatLegacyFooterCellDef extends CdkFooterCellDef {
  109. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterCellDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  110. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyFooterCellDef, selector: "[matFooterCellDef]", providers: [{ provide: CdkFooterCellDef, useExisting: MatLegacyFooterCellDef }], usesInheritance: true, ngImport: i0 }); }
  111. }
  112. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterCellDef, decorators: [{
  113. type: Directive,
  114. args: [{
  115. selector: '[matFooterCellDef]',
  116. providers: [{ provide: CdkFooterCellDef, useExisting: MatLegacyFooterCellDef }],
  117. }]
  118. }] });
  119. /**
  120. * Column definition for the mat-table.
  121. * Defines a set of cells available for a table column.
  122. * @deprecated Use `MatColumnDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  123. * @breaking-change 17.0.0
  124. */
  125. class MatLegacyColumnDef extends CdkColumnDef {
  126. /** Unique name for this column. */
  127. get name() {
  128. return this._name;
  129. }
  130. set name(name) {
  131. this._setNameInput(name);
  132. }
  133. /**
  134. * Add "mat-column-" prefix in addition to "cdk-column-" prefix.
  135. * In the future, this will only add "mat-column-" and columnCssClassName
  136. * will change from type string[] to string.
  137. * @docs-private
  138. */
  139. _updateColumnCssClassName() {
  140. super._updateColumnCssClassName();
  141. this._columnCssClassName.push(`mat-column-${this.cssClassFriendlyName}`);
  142. }
  143. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyColumnDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  144. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyColumnDef, selector: "[matColumnDef]", inputs: { sticky: "sticky", name: ["matColumnDef", "name"] }, providers: [
  145. { provide: CdkColumnDef, useExisting: MatLegacyColumnDef },
  146. { provide: 'MAT_SORT_HEADER_COLUMN_DEF', useExisting: MatLegacyColumnDef },
  147. ], usesInheritance: true, ngImport: i0 }); }
  148. }
  149. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyColumnDef, decorators: [{
  150. type: Directive,
  151. args: [{
  152. selector: '[matColumnDef]',
  153. inputs: ['sticky'],
  154. providers: [
  155. { provide: CdkColumnDef, useExisting: MatLegacyColumnDef },
  156. { provide: 'MAT_SORT_HEADER_COLUMN_DEF', useExisting: MatLegacyColumnDef },
  157. ],
  158. }]
  159. }], propDecorators: { name: [{
  160. type: Input,
  161. args: ['matColumnDef']
  162. }] } });
  163. /**
  164. * Header cell template container that adds the right classes and role.
  165. * @deprecated Use `MatHeaderCell` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  166. * @breaking-change 17.0.0
  167. */
  168. class MatLegacyHeaderCell extends CdkHeaderCell {
  169. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderCell, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  170. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyHeaderCell, selector: "mat-header-cell, th[mat-header-cell]", host: { attributes: { "role": "columnheader" }, classAttribute: "mat-header-cell" }, usesInheritance: true, ngImport: i0 }); }
  171. }
  172. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderCell, decorators: [{
  173. type: Directive,
  174. args: [{
  175. selector: 'mat-header-cell, th[mat-header-cell]',
  176. host: {
  177. 'class': 'mat-header-cell',
  178. 'role': 'columnheader',
  179. },
  180. }]
  181. }] });
  182. /**
  183. * Footer cell template container that adds the right classes and role.
  184. * @deprecated Use `MatFooterCell` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  185. * @breaking-change 17.0.0
  186. */
  187. class MatLegacyFooterCell extends CdkFooterCell {
  188. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterCell, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  189. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyFooterCell, selector: "mat-footer-cell, td[mat-footer-cell]", host: { attributes: { "role": "gridcell" }, classAttribute: "mat-footer-cell" }, usesInheritance: true, ngImport: i0 }); }
  190. }
  191. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterCell, decorators: [{
  192. type: Directive,
  193. args: [{
  194. selector: 'mat-footer-cell, td[mat-footer-cell]',
  195. host: {
  196. 'class': 'mat-footer-cell',
  197. 'role': 'gridcell',
  198. },
  199. }]
  200. }] });
  201. /**
  202. * Cell template container that adds the right classes and role.
  203. * @deprecated Use `MatCell` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  204. * @breaking-change 17.0.0
  205. */
  206. class MatLegacyCell extends CdkCell {
  207. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyCell, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  208. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyCell, selector: "mat-cell, td[mat-cell]", host: { attributes: { "role": "gridcell" }, classAttribute: "mat-cell" }, usesInheritance: true, ngImport: i0 }); }
  209. }
  210. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyCell, decorators: [{
  211. type: Directive,
  212. args: [{
  213. selector: 'mat-cell, td[mat-cell]',
  214. host: {
  215. 'class': 'mat-cell',
  216. 'role': 'gridcell',
  217. },
  218. }]
  219. }] });
  220. /**
  221. * Header row definition for the mat-table.
  222. * Captures the header row's template and other header properties such as the columns to display.
  223. * @deprecated Use `MatHeaderRowDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  224. * @breaking-change 17.0.0
  225. */
  226. class MatLegacyHeaderRowDef extends CdkHeaderRowDef {
  227. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderRowDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  228. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyHeaderRowDef, selector: "[matHeaderRowDef]", inputs: { columns: ["matHeaderRowDef", "columns"], sticky: ["matHeaderRowDefSticky", "sticky"] }, providers: [{ provide: CdkHeaderRowDef, useExisting: MatLegacyHeaderRowDef }], usesInheritance: true, ngImport: i0 }); }
  229. }
  230. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderRowDef, decorators: [{
  231. type: Directive,
  232. args: [{
  233. selector: '[matHeaderRowDef]',
  234. providers: [{ provide: CdkHeaderRowDef, useExisting: MatLegacyHeaderRowDef }],
  235. inputs: ['columns: matHeaderRowDef', 'sticky: matHeaderRowDefSticky'],
  236. }]
  237. }] });
  238. /**
  239. * Footer row definition for the mat-table.
  240. * Captures the footer row's template and other footer properties such as the columns to display.
  241. * @deprecated Use `MatFooterRowDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  242. * @breaking-change 17.0.0
  243. */
  244. class MatLegacyFooterRowDef extends CdkFooterRowDef {
  245. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterRowDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  246. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyFooterRowDef, selector: "[matFooterRowDef]", inputs: { columns: ["matFooterRowDef", "columns"], sticky: ["matFooterRowDefSticky", "sticky"] }, providers: [{ provide: CdkFooterRowDef, useExisting: MatLegacyFooterRowDef }], usesInheritance: true, ngImport: i0 }); }
  247. }
  248. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterRowDef, decorators: [{
  249. type: Directive,
  250. args: [{
  251. selector: '[matFooterRowDef]',
  252. providers: [{ provide: CdkFooterRowDef, useExisting: MatLegacyFooterRowDef }],
  253. inputs: ['columns: matFooterRowDef', 'sticky: matFooterRowDefSticky'],
  254. }]
  255. }] });
  256. /**
  257. * Data row definition for the mat-table.
  258. * Captures the data row's template and other properties such as the columns to display and
  259. * a when predicate that describes when this row should be used.
  260. * @deprecated Use `MatRowDef` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  261. * @breaking-change 17.0.0
  262. */
  263. class MatLegacyRowDef extends CdkRowDef {
  264. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyRowDef, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  265. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyRowDef, selector: "[matRowDef]", inputs: { columns: ["matRowDefColumns", "columns"], when: ["matRowDefWhen", "when"] }, providers: [{ provide: CdkRowDef, useExisting: MatLegacyRowDef }], usesInheritance: true, ngImport: i0 }); }
  266. }
  267. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyRowDef, decorators: [{
  268. type: Directive,
  269. args: [{
  270. selector: '[matRowDef]',
  271. providers: [{ provide: CdkRowDef, useExisting: MatLegacyRowDef }],
  272. inputs: ['columns: matRowDefColumns', 'when: matRowDefWhen'],
  273. }]
  274. }] });
  275. /**
  276. * Header template container that contains the cell outlet. Adds the right class and role.
  277. * @deprecated Use `MatHeaderRow` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  278. * @breaking-change 17.0.0
  279. */
  280. class MatLegacyHeaderRow extends CdkHeaderRow {
  281. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderRow, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
  282. static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyHeaderRow, selector: "mat-header-row, tr[mat-header-row]", host: { attributes: { "role": "row" }, classAttribute: "mat-header-row" }, providers: [{ provide: CdkHeaderRow, useExisting: MatLegacyHeaderRow }], exportAs: ["matHeaderRow"], usesInheritance: true, ngImport: i0, template: "<ng-container cdkCellOutlet></ng-container>", isInline: true, dependencies: [{ kind: "directive", type: i1.CdkCellOutlet, selector: "[cdkCellOutlet]" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
  283. }
  284. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyHeaderRow, decorators: [{
  285. type: Component,
  286. args: [{
  287. selector: 'mat-header-row, tr[mat-header-row]',
  288. template: CDK_ROW_TEMPLATE,
  289. host: {
  290. 'class': 'mat-header-row',
  291. 'role': 'row',
  292. },
  293. // See note on CdkTable for explanation on why this uses the default change detection strategy.
  294. // tslint:disable-next-line:validate-decorators
  295. changeDetection: ChangeDetectionStrategy.Default,
  296. encapsulation: ViewEncapsulation.None,
  297. exportAs: 'matHeaderRow',
  298. providers: [{ provide: CdkHeaderRow, useExisting: MatLegacyHeaderRow }],
  299. }]
  300. }] });
  301. /**
  302. * Footer template container that contains the cell outlet. Adds the right class and role.
  303. * @deprecated Use `MatFooterRow` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  304. * @breaking-change 17.0.0
  305. */
  306. class MatLegacyFooterRow extends CdkFooterRow {
  307. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterRow, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
  308. static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyFooterRow, selector: "mat-footer-row, tr[mat-footer-row]", host: { attributes: { "role": "row" }, classAttribute: "mat-footer-row" }, providers: [{ provide: CdkFooterRow, useExisting: MatLegacyFooterRow }], exportAs: ["matFooterRow"], usesInheritance: true, ngImport: i0, template: "<ng-container cdkCellOutlet></ng-container>", isInline: true, dependencies: [{ kind: "directive", type: i1.CdkCellOutlet, selector: "[cdkCellOutlet]" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
  309. }
  310. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyFooterRow, decorators: [{
  311. type: Component,
  312. args: [{
  313. selector: 'mat-footer-row, tr[mat-footer-row]',
  314. template: CDK_ROW_TEMPLATE,
  315. host: {
  316. 'class': 'mat-footer-row',
  317. 'role': 'row',
  318. },
  319. // See note on CdkTable for explanation on why this uses the default change detection strategy.
  320. // tslint:disable-next-line:validate-decorators
  321. changeDetection: ChangeDetectionStrategy.Default,
  322. encapsulation: ViewEncapsulation.None,
  323. exportAs: 'matFooterRow',
  324. providers: [{ provide: CdkFooterRow, useExisting: MatLegacyFooterRow }],
  325. }]
  326. }] });
  327. /**
  328. * Data row template container that contains the cell outlet. Adds the right class and role.
  329. * @deprecated Use `MatRow` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  330. * @breaking-change 17.0.0
  331. */
  332. class MatLegacyRow extends CdkRow {
  333. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyRow, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
  334. static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyRow, selector: "mat-row, tr[mat-row]", host: { attributes: { "role": "row" }, classAttribute: "mat-row" }, providers: [{ provide: CdkRow, useExisting: MatLegacyRow }], exportAs: ["matRow"], usesInheritance: true, ngImport: i0, template: "<ng-container cdkCellOutlet></ng-container>", isInline: true, dependencies: [{ kind: "directive", type: i1.CdkCellOutlet, selector: "[cdkCellOutlet]" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
  335. }
  336. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyRow, decorators: [{
  337. type: Component,
  338. args: [{
  339. selector: 'mat-row, tr[mat-row]',
  340. template: CDK_ROW_TEMPLATE,
  341. host: {
  342. 'class': 'mat-row',
  343. 'role': 'row',
  344. },
  345. // See note on CdkTable for explanation on why this uses the default change detection strategy.
  346. // tslint:disable-next-line:validate-decorators
  347. changeDetection: ChangeDetectionStrategy.Default,
  348. encapsulation: ViewEncapsulation.None,
  349. exportAs: 'matRow',
  350. providers: [{ provide: CdkRow, useExisting: MatLegacyRow }],
  351. }]
  352. }] });
  353. /**
  354. * Row that can be used to display a message when no data is shown in the table.
  355. * @deprecated Use `MatNoDataRow` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  356. * @breaking-change 17.0.0
  357. */
  358. class MatLegacyNoDataRow extends CdkNoDataRow {
  359. constructor() {
  360. super(...arguments);
  361. this._contentClassName = 'mat-no-data-row';
  362. }
  363. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyNoDataRow, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
  364. static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyNoDataRow, selector: "ng-template[matNoDataRow]", providers: [{ provide: CdkNoDataRow, useExisting: MatLegacyNoDataRow }], usesInheritance: true, ngImport: i0 }); }
  365. }
  366. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyNoDataRow, decorators: [{
  367. type: Directive,
  368. args: [{
  369. selector: 'ng-template[matNoDataRow]',
  370. providers: [{ provide: CdkNoDataRow, useExisting: MatLegacyNoDataRow }],
  371. }]
  372. }] });
  373. /**
  374. * Column that simply shows text content for the header and row cells. Assumes that the table
  375. * is using the native table implementation (`<table>`).
  376. *
  377. * By default, the name of this column will be the header text and data property accessor.
  378. * The header text can be overridden with the `headerText` input. Cell values can be overridden with
  379. * the `dataAccessor` input. Change the text justification to the start or end using the `justify`
  380. * input.
  381. *
  382. * @deprecated Use `MatTextColumn` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  383. * @breaking-change 17.0.0
  384. */
  385. class MatLegacyTextColumn extends CdkTextColumn {
  386. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTextColumn, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
  387. static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: MatLegacyTextColumn, selector: "mat-text-column", usesInheritance: true, ngImport: i0, template: `
  388. <ng-container matColumnDef>
  389. <th mat-header-cell *matHeaderCellDef [style.text-align]="justify">
  390. {{headerText}}
  391. </th>
  392. <td mat-cell *matCellDef="let data" [style.text-align]="justify">
  393. {{dataAccessor(data, name)}}
  394. </td>
  395. </ng-container>
  396. `, isInline: true, dependencies: [{ kind: "directive", type: MatLegacyHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: MatLegacyColumnDef, selector: "[matColumnDef]", inputs: ["sticky", "matColumnDef"] }, { kind: "directive", type: MatLegacyCellDef, selector: "[matCellDef]" }, { kind: "directive", type: MatLegacyHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: MatLegacyCell, selector: "mat-cell, td[mat-cell]" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
  397. }
  398. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTextColumn, decorators: [{
  399. type: Component,
  400. args: [{
  401. selector: 'mat-text-column',
  402. template: `
  403. <ng-container matColumnDef>
  404. <th mat-header-cell *matHeaderCellDef [style.text-align]="justify">
  405. {{headerText}}
  406. </th>
  407. <td mat-cell *matCellDef="let data" [style.text-align]="justify">
  408. {{dataAccessor(data, name)}}
  409. </td>
  410. </ng-container>
  411. `,
  412. encapsulation: ViewEncapsulation.None,
  413. // Change detection is intentionally not set to OnPush. This component's template will be provided
  414. // to the table to be inserted into its view. This is problematic when change detection runs since
  415. // the bindings in this template will be evaluated _after_ the table's view is evaluated, which
  416. // mean's the template in the table's view will not have the updated value (and in fact will cause
  417. // an ExpressionChangedAfterItHasBeenCheckedError).
  418. // tslint:disable-next-line:validate-decorators
  419. changeDetection: ChangeDetectionStrategy.Default,
  420. }]
  421. }] });
  422. const EXPORTED_DECLARATIONS = [
  423. // Table
  424. MatLegacyTable,
  425. MatLegacyRecycleRows,
  426. // Template defs
  427. MatLegacyHeaderCellDef,
  428. MatLegacyHeaderRowDef,
  429. MatLegacyColumnDef,
  430. MatLegacyCellDef,
  431. MatLegacyRowDef,
  432. MatLegacyFooterCellDef,
  433. MatLegacyFooterRowDef,
  434. // Cell directives
  435. MatLegacyHeaderCell,
  436. MatLegacyCell,
  437. MatLegacyFooterCell,
  438. // Row directives
  439. MatLegacyHeaderRow,
  440. MatLegacyRow,
  441. MatLegacyFooterRow,
  442. MatLegacyNoDataRow,
  443. MatLegacyTextColumn,
  444. ];
  445. /**
  446. * @deprecated Use `MatTableModule` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  447. * @breaking-change 17.0.0
  448. */
  449. class MatLegacyTableModule {
  450. static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTableModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
  451. static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTableModule, declarations: [
  452. // Table
  453. MatLegacyTable,
  454. MatLegacyRecycleRows,
  455. // Template defs
  456. MatLegacyHeaderCellDef,
  457. MatLegacyHeaderRowDef,
  458. MatLegacyColumnDef,
  459. MatLegacyCellDef,
  460. MatLegacyRowDef,
  461. MatLegacyFooterCellDef,
  462. MatLegacyFooterRowDef,
  463. // Cell directives
  464. MatLegacyHeaderCell,
  465. MatLegacyCell,
  466. MatLegacyFooterCell,
  467. // Row directives
  468. MatLegacyHeaderRow,
  469. MatLegacyRow,
  470. MatLegacyFooterRow,
  471. MatLegacyNoDataRow,
  472. MatLegacyTextColumn], imports: [CdkTableModule, MatCommonModule], exports: [MatCommonModule,
  473. // Table
  474. MatLegacyTable,
  475. MatLegacyRecycleRows,
  476. // Template defs
  477. MatLegacyHeaderCellDef,
  478. MatLegacyHeaderRowDef,
  479. MatLegacyColumnDef,
  480. MatLegacyCellDef,
  481. MatLegacyRowDef,
  482. MatLegacyFooterCellDef,
  483. MatLegacyFooterRowDef,
  484. // Cell directives
  485. MatLegacyHeaderCell,
  486. MatLegacyCell,
  487. MatLegacyFooterCell,
  488. // Row directives
  489. MatLegacyHeaderRow,
  490. MatLegacyRow,
  491. MatLegacyFooterRow,
  492. MatLegacyNoDataRow,
  493. MatLegacyTextColumn] }); }
  494. static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTableModule, imports: [CdkTableModule, MatCommonModule, MatCommonModule] }); }
  495. }
  496. i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: MatLegacyTableModule, decorators: [{
  497. type: NgModule,
  498. args: [{
  499. imports: [CdkTableModule, MatCommonModule],
  500. exports: [MatCommonModule, EXPORTED_DECLARATIONS],
  501. declarations: EXPORTED_DECLARATIONS,
  502. }]
  503. }] });
  504. /**
  505. * Data source that accepts a client-side data array and includes native support of filtering,
  506. * sorting (using MatSort), and pagination (using paginator).
  507. *
  508. * Allows for sort customization by overriding sortingDataAccessor, which defines how data
  509. * properties are accessed. Also allows for filter customization by overriding filterPredicate,
  510. * which defines how row data is converted to a string for filter matching.
  511. *
  512. * **Note:** This class is meant to be a simple data source to help you get started. As such
  513. * it isn't equipped to handle some more advanced cases like robust i18n support or server-side
  514. * interactions. If your app needs to support more advanced use cases, consider implementing your
  515. * own `DataSource`.
  516. *
  517. * @deprecated Use `MatTableDataSource` from `@angular/material/table` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
  518. * @breaking-change 17.0.0
  519. */
  520. class MatLegacyTableDataSource extends _MatTableDataSource {
  521. }
  522. /**
  523. * Generated bundle index. Do not edit.
  524. */
  525. export { MatLegacyCell, MatLegacyCellDef, MatLegacyColumnDef, MatLegacyFooterCell, MatLegacyFooterCellDef, MatLegacyFooterRow, MatLegacyFooterRowDef, MatLegacyHeaderCell, MatLegacyHeaderCellDef, MatLegacyHeaderRow, MatLegacyHeaderRowDef, MatLegacyNoDataRow, MatLegacyRecycleRows, MatLegacyRow, MatLegacyRowDef, MatLegacyTable, MatLegacyTableDataSource, MatLegacyTableModule, MatLegacyTextColumn };
  526. //# sourceMappingURL=legacy-table.mjs.map