@cellaware/utils 8.11.5 → 8.11.7

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.
@@ -196,12 +196,13 @@ export declare function createTeamsTableRow(columnNames: string[], values: any[]
196
196
  }[];
197
197
  }[];
198
198
  };
199
- export declare function createTeamsTransposeColumnSet(row: {
199
+ export declare function createTeamsTransposeTableRow(row: {
200
200
  key: string;
201
201
  value: any;
202
202
  }, columnStyle: TeamsColumnStyle): {
203
203
  type: string;
204
- columns: any[];
204
+ separator: boolean;
205
+ cells: any[];
205
206
  };
206
207
  /**
207
208
  * **Important:** `html` and `teamsRows` output will be limited to **1,000 rows/24 rows** and **8 columns**, respectively.
@@ -1143,7 +1143,7 @@ function createTeamsTableCellText(value, columnStyle) {
1143
1143
  isSubtle
1144
1144
  };
1145
1145
  }
1146
- function createTeamsTransposeColumnText(value, key, columnStyle) {
1146
+ function createTeamsTransposeTableCellText(value, key, columnStyle) {
1147
1147
  // Same as ^^^, just a couple minor tweaks.
1148
1148
  let color = undefined;
1149
1149
  let weight = undefined;
@@ -1198,10 +1198,10 @@ export function createTeamsTableRow(columnNames, values, rowStyles, columnStyles
1198
1198
  })
1199
1199
  };
1200
1200
  }
1201
- export function createTeamsTransposeColumnSet(row, columnStyle) {
1202
- const keyColumn = {
1203
- type: "Column",
1204
- items: [createTeamsTransposeColumnText(row.key, true, {
1201
+ export function createTeamsTransposeTableRow(row, columnStyle) {
1202
+ const keyCell = {
1203
+ type: "TableCell",
1204
+ items: [createTeamsTransposeTableCellText(row.key, true, {
1205
1205
  columnName: 'key',
1206
1206
  styles: [{ weight: 'Bolder' }]
1207
1207
  })]
@@ -1212,14 +1212,15 @@ export function createTeamsTransposeColumnSet(row, columnStyle) {
1212
1212
  style = styles.style;
1213
1213
  }
1214
1214
  }
1215
- const valueColumn = {
1216
- type: "Column",
1215
+ const valueCell = {
1216
+ type: "TableCell",
1217
1217
  style,
1218
- items: [createTeamsTransposeColumnText(row.value, false, columnStyle)]
1218
+ items: [createTeamsTransposeTableCellText(row.value, false, columnStyle)]
1219
1219
  };
1220
1220
  return {
1221
- type: "ColumnSet",
1222
- columns: [keyColumn, valueColumn]
1221
+ type: "TableRow",
1222
+ separator: true,
1223
+ cells: [keyCell, valueCell]
1223
1224
  };
1224
1225
  }
1225
1226
  /**
@@ -1324,7 +1325,7 @@ export function transformDatagrid(rows, datagridState, locale, condition) {
1324
1325
  }));
1325
1326
  for (let i = 0; i < transposedRows.length; i++) {
1326
1327
  htmlTransposeBuf += buildHtmlTransposeRow(transposedRows[i], htmlTransposeColumnStyles[i]);
1327
- teamsTranspose.push(createTeamsTransposeColumnSet(transposedRows[i], mapTeamsTransposeStyles(htmlTransposeColumnStyles[i])));
1328
+ teamsTranspose.push(createTeamsTransposeTableRow(transposedRows[i], mapTeamsTransposeStyles(htmlTransposeColumnStyles[i])));
1328
1329
  }
1329
1330
  }
1330
1331
  rowIdx++;
@@ -1383,7 +1384,7 @@ export function transformDatagrid(rows, datagridState, locale, condition) {
1383
1384
  }));
1384
1385
  for (let i = 0; i < transposedRows.length; i++) {
1385
1386
  htmlTransposeBuf += buildHtmlTransposeRow(transposedRows[i], htmlTransposeColumnStyles[i]);
1386
- teamsTranspose.push(createTeamsTransposeColumnSet(transposedRows[i], mapTeamsTransposeStyles(htmlTransposeColumnStyles[i])));
1387
+ teamsTranspose.push(createTeamsTransposeTableRow(transposedRows[i], mapTeamsTransposeStyles(htmlTransposeColumnStyles[i])));
1387
1388
  }
1388
1389
  }
1389
1390
  rowIdx++;
@@ -118,7 +118,7 @@ export declare function createTeamsReportValueCard(lineTitle: string, columnName
118
118
  }[];
119
119
  })[];
120
120
  };
121
- export declare function createTeamsReportRowCard(lineTitle: string, columnSets: any[], summary: string, reportTitle: string): {
121
+ export declare function createTeamsReportRowCard(lineTitle: string, table: any[], summary: string, reportTitle: string): {
122
122
  type: string;
123
123
  version: string;
124
124
  msteams: {
@@ -138,8 +138,12 @@ export declare function createTeamsReportRowCard(lineTitle: string, columnSets:
138
138
  wrap: boolean;
139
139
  } | {
140
140
  type: string;
141
+ showGridLines: boolean;
141
142
  roundedCorners: boolean;
142
- items: any[];
143
+ columns: {
144
+ width: number;
145
+ }[];
146
+ rows: any[];
143
147
  })[];
144
148
  };
145
149
  export declare function createTeamsReportChartCard(lineTitle: string, png: string, summary: string, reportTitle: string): {
@@ -136,7 +136,7 @@ export function createTeamsReportValueCard(lineTitle, columnName, value, styles,
136
136
  ]
137
137
  };
138
138
  }
139
- export function createTeamsReportRowCard(lineTitle, columnSets, summary, reportTitle) {
139
+ export function createTeamsReportRowCard(lineTitle, table, summary, reportTitle) {
140
140
  return {
141
141
  type: "AdaptiveCard",
142
142
  version: "1.5",
@@ -144,9 +144,11 @@ export function createTeamsReportRowCard(lineTitle, columnSets, summary, reportT
144
144
  body: [
145
145
  createTeamsTitleItem(reportTitle, lineTitle),
146
146
  {
147
- type: "Container",
147
+ type: "Table",
148
+ showGridLines: false,
148
149
  roundedCorners: true,
149
- items: columnSets
150
+ columns: [{ width: 1 }, { width: 2 }],
151
+ rows: table
150
152
  },
151
153
  createTeamsSummaryItem(summary)
152
154
  ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cellaware/utils",
3
- "version": "8.11.5",
3
+ "version": "8.11.7",
4
4
  "description": "Cellaware Utilities for Node.js",
5
5
  "author": "Cellaware Technologies",
6
6
  "type": "module",