@@ -30,16 +30,16 @@ import { styles as bootstrap } from '../styles/grid/themes/light/grid.bootstrap.
3030import { styles as fluent } from '../styles/grid/themes/light/grid.fluent.css.js' ;
3131import { styles as indigo } from '../styles/grid/themes/light/grid.indigo.css.js' ;
3232import { styles as material } from '../styles/grid/themes/light/grid.material.css.js' ;
33- import ApexGridCell from './cell.js' ;
34- import ApexFilterRow from './filter-row.js' ;
35- import ApexGridHeaderRow from './header-row.js' ;
36- import ApexGridRow from './row.js' ;
37- import ApexVirtualizer from './virtualizer.js' ;
33+ import IgcGridLiteCell from './cell.js' ;
34+ import IgcFilterRow from './filter-row.js' ;
35+ import IgcGridLiteHeaderRow from './header-row.js' ;
36+ import IgcGridLiteRow from './row.js' ;
37+ import IgcVirtualizer from './virtualizer.js' ;
3838
3939/**
4040 * Event object for the filtering event of the grid.
4141 */
42- export interface ApexFilteringEvent < T extends object > {
42+ export interface IgcFilteringEvent < T extends object > {
4343 /**
4444 * The target column for the filter operation.
4545 */
@@ -65,7 +65,7 @@ export interface ApexFilteringEvent<T extends object> {
6565/**
6666 * Event object for the filtered event of the grid.
6767 */
68- export interface ApexFilteredEvent < T extends object > {
68+ export interface IgcFilteredEvent < T extends object > {
6969 /**
7070 * The target column for the filter operation.
7171 */
@@ -80,7 +80,7 @@ export interface ApexFilteredEvent<T extends object> {
8080/**
8181 * Events for the igc-grid-lite.
8282 */
83- export interface ApexGridEventMap < T extends object > {
83+ export interface IgcGridLiteEventMap < T extends object > {
8484 /**
8585 * Emitted when sorting is initiated through the UI.
8686 * Returns the sort expression which will be used for the operation.
@@ -108,18 +108,18 @@ export interface ApexGridEventMap<T extends object> {
108108 *
109109 * @event
110110 */
111- filtering : CustomEvent < ApexFilteringEvent < T > > ;
111+ filtering : CustomEvent < IgcFilteringEvent < T > > ;
112112 /**
113113 * Emitted when a filter operation initiated through the UI has completed.
114114 * Returns the filter state for the affected column.
115115 *
116116 * @event
117117 */
118- filtered : CustomEvent < ApexFilteredEvent < T > > ;
118+ filtered : CustomEvent < IgcFilteredEvent < T > > ;
119119}
120120
121121/**
122- * Apex grid is a web component for displaying data in a tabular format quick and easy.
122+ * IgcGridLite is a web component for displaying data in a tabular format quick and easy.
123123 *
124124 * Out of the box it provides row virtualization, sort and filter operations (client and server side),
125125 * the ability to template cells and headers and column hiding.
@@ -132,7 +132,7 @@ export interface ApexGridEventMap<T extends object> {
132132 * @fires filtered - Emitted when a filter operation initiated through the UI has completed.
133133 *
134134 */
135- export class ApexGrid < T extends object > extends EventEmitterBase < ApexGridEventMap < T > > {
135+ export class IgcGridLite < T extends object > extends EventEmitterBase < IgcGridLiteEventMap < T > > {
136136 public static get tagName ( ) {
137137 return GRID_TAG ;
138138 }
@@ -141,11 +141,11 @@ export class ApexGrid<T extends object> extends EventEmitterBase<ApexGridEventMa
141141
142142 public static register ( ) {
143143 registerComponent (
144- ApexGrid ,
145- ApexVirtualizer ,
146- ApexGridRow ,
147- ApexGridHeaderRow ,
148- ApexFilterRow ,
144+ IgcGridLite ,
145+ IgcVirtualizer ,
146+ IgcGridLiteRow ,
147+ IgcGridLiteHeaderRow ,
148+ IgcFilterRow ,
149149 IgcButtonComponent ,
150150 IgcChipComponent ,
151151 IgcInputComponent ,
@@ -162,20 +162,20 @@ export class ApexGrid<T extends object> extends EventEmitterBase<ApexGridEventMa
162162 initialValue : this . stateController ,
163163 } ) ;
164164
165- @query ( ApexVirtualizer . tagName )
166- protected scrollContainer ! : ApexVirtualizer ;
165+ @query ( IgcVirtualizer . tagName )
166+ protected scrollContainer ! : IgcVirtualizer ;
167167
168- @query ( ApexGridHeaderRow . tagName )
169- protected headerRow ! : ApexGridHeaderRow < T > ;
168+ @query ( IgcGridLiteHeaderRow . tagName )
169+ protected headerRow ! : IgcGridLiteHeaderRow < T > ;
170170
171- @query ( ApexFilterRow . tagName )
172- protected filterRow ! : ApexFilterRow < T > ;
171+ @query ( IgcFilterRow . tagName )
172+ protected filterRow ! : IgcFilterRow < T > ;
173173
174174 @state ( )
175175 protected dataState : Array < T > = [ ] ;
176176
177- @queryAll ( ApexGridRow . tagName )
178- protected _rows ! : NodeListOf < ApexGridRow < T > > ;
177+ @queryAll ( IgcGridLiteRow . tagName )
178+ protected _rows ! : NodeListOf < IgcGridLiteRow < T > > ;
179179
180180 /** Column configuration for the grid. */
181181 @property ( { attribute : false } )
@@ -285,7 +285,7 @@ export class ApexGrid<T extends object> extends EventEmitterBase<ApexGridEventMa
285285 }
286286
287287 /**
288- * The total number of items in the {@link ApexGrid .dataView} collection.
288+ * The total number of items in the {@link IgcGridLite .dataView} collection.
289289 */
290290 public get totalItems ( ) {
291291 return this . dataState . length ;
@@ -387,7 +387,9 @@ export class ApexGrid<T extends object> extends EventEmitterBase<ApexGridEventMa
387387
388388 @eventOptions ( { capture : true } )
389389 protected bodyClickHandler ( event : MouseEvent ) {
390- const target = event . composedPath ( ) . find ( ( el ) => el instanceof ApexGridCell ) as ApexGridCell < T > ;
390+ const target = event
391+ . composedPath ( )
392+ . find ( ( el ) => el instanceof IgcGridLiteCell ) as IgcGridLiteCell < T > ;
391393 if ( target ) {
392394 this . stateController . active = {
393395 column : target . column . key ,
@@ -413,18 +415,18 @@ export class ApexGrid<T extends object> extends EventEmitterBase<ApexGridEventMa
413415
414416 protected renderBody ( ) {
415417 return html `
416- < apex -virtualizer
418+ < igc -virtualizer
417419 .items =${ this . dataState }
418420 .renderItem =${ this . DOM . rowRenderer }
419421 @click=${ this . bodyClickHandler }
420422 @keydown=${ this . bodyKeydownHandler }
421- > </ apex -virtualizer>
423+ > </ igc -virtualizer>
422424 ` ;
423425 }
424426
425427 protected renderFilterRow ( ) {
426428 return this . columns . some ( ( column ) => column . filter )
427- ? html `< apex -filter-row style =${ styleMap ( this . DOM . columnSizes ) } > </ apex -filter-row> `
429+ ? html `< igc -filter-row style =${ styleMap ( this . DOM . columnSizes ) } > </ igc -filter-row> `
428430 : nothing ;
429431 }
430432
@@ -440,6 +442,6 @@ export class ApexGrid<T extends object> extends EventEmitterBase<ApexGridEventMa
440442
441443declare global {
442444 interface HTMLElementTagNameMap {
443- [ ApexGrid . tagName ] : ApexGrid < object > ;
445+ [ IgcGridLite . tagName ] : IgcGridLite < object > ;
444446 }
445447}
0 commit comments