@trebco/treb 27.11.4 → 27.12.0

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/treb.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- /*! API v27.11. Copyright 2018-2023 trebco, llc. All rights reserved. LGPL: https://treb.app/license */
1
+ /*! API v27.12. Copyright 2018-2023 trebco, llc. All rights reserved. LGPL: https://treb.app/license */
2
2
 
3
3
  /**
4
4
  * add our tag to the map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trebco/treb",
3
- "version": "27.11.4",
3
+ "version": "27.12.0",
4
4
  "license": "LGPL-3.0-or-later",
5
5
  "homepage": "https://treb.app",
6
6
  "repository": {
@@ -828,6 +828,7 @@ export class EmbeddedSpreadsheet {
828
828
 
829
829
  case 'scale':
830
830
  this.RebuildAllAnnotations();
831
+ this.events.Publish({ type: 'view-change' });
831
832
  break;
832
833
 
833
834
  case 'annotation':
@@ -122,6 +122,20 @@ export enum LoadType {
122
122
  XLSX = 'xlsx',
123
123
  }
124
124
 
125
+ /**
126
+ * This event is sent when the view changes -- at the moment, that only
127
+ * means the view scale has been changed. We might use it in the future
128
+ * for other things.
129
+ *
130
+ * @privateRemarks
131
+ * not sure if this should be combined with resize -- the only reason it's
132
+ * not is because resize implies some structural/layout changes that require
133
+ * changing the document, but scale does not. open to suggestions though.
134
+ */
135
+ export interface ViewChangeEvent {
136
+ type: 'view-change';
137
+ }
138
+
125
139
  /**
126
140
  * This event is sent when a document is loaded, and also on undo. The
127
141
  * source field can help determine if it was triggered by an undo operation.