@niicojs/excel 0.3.0 → 0.3.2

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/dist/index.d.cts CHANGED
@@ -265,6 +265,16 @@ interface SheetToJsonConfig {
265
265
  * How to serialize Date values. Defaults to 'jsDate'.
266
266
  */
267
267
  dateHandling?: DateHandling;
268
+ /**
269
+ * If true, return formatted text (as displayed in Excel) instead of raw values.
270
+ * All values will be returned as strings. Defaults to false.
271
+ */
272
+ asText?: boolean;
273
+ /**
274
+ * Locale to use for formatting when asText is true.
275
+ * Defaults to the workbook locale.
276
+ */
277
+ locale?: string;
268
278
  }
269
279
 
270
280
  /**
@@ -317,6 +327,10 @@ declare class Cell {
317
327
  * Get the formatted text (as displayed in Excel)
318
328
  */
319
329
  get text(): string;
330
+ /**
331
+ * Get the formatted text using a specific locale
332
+ */
333
+ textWithLocale(locale?: string): string;
320
334
  /**
321
335
  * Get the style index
322
336
  */
@@ -1066,6 +1080,7 @@ declare class Workbook {
1066
1080
  private _nextCacheFileIndex;
1067
1081
  private _nextTableId;
1068
1082
  private _dateHandling;
1083
+ private _locale;
1069
1084
  private constructor();
1070
1085
  /**
1071
1086
  * Load a workbook from a file path
@@ -1103,6 +1118,14 @@ declare class Workbook {
1103
1118
  * Set the workbook date handling strategy.
1104
1119
  */
1105
1120
  set dateHandling(value: DateHandling);
1121
+ /**
1122
+ * Get the workbook locale for formatting.
1123
+ */
1124
+ get locale(): string;
1125
+ /**
1126
+ * Set the workbook locale for formatting.
1127
+ */
1128
+ set locale(value: string);
1106
1129
  /**
1107
1130
  * Get the next unique table ID for this workbook.
1108
1131
  * Table IDs must be unique across all worksheets.