@trebco/treb 23.4.0 → 23.5.1

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/treb.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- /*! API v23.4. Copyright 2018-2023 trebco, llc. All rights reserved. LGPL: https://treb.app/license */
1
+ /*! API v23.5. Copyright 2018-2023 trebco, llc. All rights reserved. LGPL: https://treb.app/license */
2
2
 
3
3
  /**
4
4
  * Global instance. In the base script, this object will be created as an
@@ -1001,6 +1001,12 @@ export interface InsertTableOptions {
1001
1001
  * show a sort button in table headers. defaults to true.
1002
1002
  */
1003
1003
  sortable?: boolean;
1004
+
1005
+ /**
1006
+ * base theme color, or a set of styles for the table. useful values for
1007
+ * theme color are accent colors 4 (the default), 5, 7 and 9.
1008
+ */
1009
+ theme?: number | TableTheme;
1004
1010
  }
1005
1011
  export interface ResizeEvent {
1006
1012
  type: 'resize';
@@ -1051,6 +1057,33 @@ export interface SelectionEvent {
1051
1057
  type: 'selection';
1052
1058
  }
1053
1059
 
1060
+ /**
1061
+ * composite styling for tables.
1062
+ *
1063
+ **/
1064
+ export interface TableTheme {
1065
+
1066
+ /** the first row in a table, showing column titles. */
1067
+ header?: Style.Properties;
1068
+
1069
+ /**
1070
+ * odd rows in the table. we count the title row as zero, so
1071
+ * the first row in the table containing data is 1, hence odd.
1072
+ */
1073
+ odd?: Style.Properties;
1074
+
1075
+ /**
1076
+ * even rows in the table.
1077
+ */
1078
+ even?: Style.Properties;
1079
+
1080
+ /**
1081
+ * styling for the totals row, if included. this will be the last
1082
+ * row in the table.
1083
+ */
1084
+ total?: Style.Properties;
1085
+ }
1086
+
1054
1087
  /**
1055
1088
  * options for exporting CSV/TSV
1056
1089
  */