@webilix/ngx-table-m3 0.0.21 → 0.0.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.d.ts CHANGED
@@ -166,13 +166,15 @@ interface INgxTable<T> {
166
166
  readonly type: string;
167
167
  readonly columns: NgxTableColumn<T>[];
168
168
  readonly rows?: {
169
- readonly icon?: (data: T) => string | {
169
+ readonly icon?: (data: T, index: number) => string | {
170
170
  icon: string;
171
171
  color: string | null | undefined;
172
+ } | {
173
+ emoji: string;
172
174
  };
173
- readonly color?: (data: T) => string | null | undefined;
174
- readonly description?: (data: T) => string | null | undefined;
175
- readonly isDeactive?: (data: T) => boolean;
175
+ readonly color?: (data: T, index: number) => string | null | undefined;
176
+ readonly description?: (data: T, index: number) => string | null | undefined;
177
+ readonly isDeactive?: (data: T, index: number) => boolean;
176
178
  };
177
179
  readonly actions?: NgxTableAction<T>[];
178
180
  readonly mobileView?: boolean;
@@ -234,6 +236,7 @@ declare class ViewService {
234
236
  icon: string;
235
237
  color?: string;
236
238
  }[];
239
+ getEmojis<T>(ngxTable: INgxTable<T>, data: T[]): string[];
237
240
  getColors<T>(ngxTable: INgxTable<T>, data: T[]): string[];
238
241
  getDescriptions<T>(ngxTable: INgxTable<T>, data: T[]): (string | undefined)[];
239
242
  getDeactives<T>(ngxTable: INgxTable<T>, data: T[]): number[];
@@ -245,6 +248,7 @@ declare class ViewService {
245
248
  interface IViewConfig {
246
249
  readonly alternateRows: boolean;
247
250
  readonly iconSize: string;
251
+ readonly emojiSize: string;
248
252
  readonly actionMenuTitle: string;
249
253
  readonly stickyView?: {
250
254
  readonly top?: {
@@ -270,6 +274,7 @@ interface INgxTableConfig {
270
274
  readonly mobileWidth: number;
271
275
  readonly alternateRows: boolean;
272
276
  readonly iconSize: number;
277
+ readonly emojiSize: number;
273
278
  readonly actionMenuTitle?: string;
274
279
  readonly stickyView: {
275
280
  readonly top?: string | {
package/ngx-table-m3.css CHANGED
@@ -356,6 +356,10 @@
356
356
  padding-left: 0;
357
357
  }
358
358
 
359
+ td.emoji {
360
+ padding-top: 1rem;
361
+ }
362
+
359
363
  td.action {
360
364
  padding: 0.25rem 0 0 0;
361
365
  }
@@ -412,6 +416,10 @@
412
416
  padding: 0.5rem 0;
413
417
  }
414
418
 
419
+ .emoji {
420
+ padding: 0.5rem 0;
421
+ }
422
+
415
423
  .title {
416
424
  flex: 1;
417
425
  padding: 0.5rem 0;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webilix/ngx-table-m3",
3
- "version": "0.0.21",
3
+ "version": "0.0.22",
4
4
  "author": "Ali Amirnezhad",
5
5
  "description": "Responsive table view component for Angular and Material 3",
6
6
  "repository": {