@odoo/o-spreadsheet 16.0.41 → 16.0.42

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.
@@ -32471,7 +32471,7 @@ class ClipboardPlugin extends UIPlugin {
32471
32471
  return 0 /* CommandResult.Success */;
32472
32472
  }
32473
32473
  handle(cmd) {
32474
- var _a, _b;
32474
+ var _a, _b, _c, _d;
32475
32475
  switch (cmd.type) {
32476
32476
  case "COPY":
32477
32477
  case "CUT":
@@ -32512,7 +32512,7 @@ class ClipboardPlugin extends UIPlugin {
32512
32512
  case "ADD_COLUMNS_ROWS": {
32513
32513
  this.status = "invisible";
32514
32514
  // If we add a col/row inside or before the cut area, we invalidate the clipboard
32515
- if (((_a = this.state) === null || _a === void 0 ? void 0 : _a.operation) !== "CUT") {
32515
+ if (((_a = this.state) === null || _a === void 0 ? void 0 : _a.operation) !== "CUT" || cmd.sheetId !== ((_b = this.state) === null || _b === void 0 ? void 0 : _b.sheetId)) {
32516
32516
  return;
32517
32517
  }
32518
32518
  const isClipboardDirty = this.state.isColRowDirtyingClipboard(cmd.position === "before" ? cmd.base : cmd.base + 1, cmd.dimension);
@@ -32524,7 +32524,7 @@ class ClipboardPlugin extends UIPlugin {
32524
32524
  case "REMOVE_COLUMNS_ROWS": {
32525
32525
  this.status = "invisible";
32526
32526
  // If we remove a col/row inside or before the cut area, we invalidate the clipboard
32527
- if (((_b = this.state) === null || _b === void 0 ? void 0 : _b.operation) !== "CUT") {
32527
+ if (((_c = this.state) === null || _c === void 0 ? void 0 : _c.operation) !== "CUT" || cmd.sheetId !== ((_d = this.state) === null || _d === void 0 ? void 0 : _d.sheetId)) {
32528
32528
  return;
32529
32529
  }
32530
32530
  for (let el of cmd.elements) {
@@ -39302,6 +39302,10 @@ class Spreadsheet extends owl.Component {
39302
39302
  });
39303
39303
  owl.useExternalListener(window, "resize", () => this.render(true));
39304
39304
  owl.useExternalListener(window, "beforeunload", this.unbindModelEvents.bind(this));
39305
+ // For some reason, the wheel event is not properly registered inside templates
39306
+ // in Chromium-based browsers based on chromium 125
39307
+ // This hack ensures the event declared in the template is properly registered/working
39308
+ owl.useExternalListener(document.body, "wheel", () => { });
39305
39309
  this.bindModelEvents();
39306
39310
  owl.onMounted(() => {
39307
39311
  this.checkViewportSize();
@@ -43323,6 +43327,6 @@ exports.setTranslationMethod = setTranslationMethod;
43323
43327
  exports.tokenize = tokenize;
43324
43328
 
43325
43329
 
43326
- __info__.version = '16.0.41';
43327
- __info__.date = '2024-05-15T09:15:13.021Z';
43328
- __info__.hash = '3b3f648';
43330
+ __info__.version = '16.0.42';
43331
+ __info__.date = '2024-05-24T11:24:56.581Z';
43332
+ __info__.hash = 'fd11d19';
@@ -32467,7 +32467,7 @@ class ClipboardPlugin extends UIPlugin {
32467
32467
  return 0 /* CommandResult.Success */;
32468
32468
  }
32469
32469
  handle(cmd) {
32470
- var _a, _b;
32470
+ var _a, _b, _c, _d;
32471
32471
  switch (cmd.type) {
32472
32472
  case "COPY":
32473
32473
  case "CUT":
@@ -32508,7 +32508,7 @@ class ClipboardPlugin extends UIPlugin {
32508
32508
  case "ADD_COLUMNS_ROWS": {
32509
32509
  this.status = "invisible";
32510
32510
  // If we add a col/row inside or before the cut area, we invalidate the clipboard
32511
- if (((_a = this.state) === null || _a === void 0 ? void 0 : _a.operation) !== "CUT") {
32511
+ if (((_a = this.state) === null || _a === void 0 ? void 0 : _a.operation) !== "CUT" || cmd.sheetId !== ((_b = this.state) === null || _b === void 0 ? void 0 : _b.sheetId)) {
32512
32512
  return;
32513
32513
  }
32514
32514
  const isClipboardDirty = this.state.isColRowDirtyingClipboard(cmd.position === "before" ? cmd.base : cmd.base + 1, cmd.dimension);
@@ -32520,7 +32520,7 @@ class ClipboardPlugin extends UIPlugin {
32520
32520
  case "REMOVE_COLUMNS_ROWS": {
32521
32521
  this.status = "invisible";
32522
32522
  // If we remove a col/row inside or before the cut area, we invalidate the clipboard
32523
- if (((_b = this.state) === null || _b === void 0 ? void 0 : _b.operation) !== "CUT") {
32523
+ if (((_c = this.state) === null || _c === void 0 ? void 0 : _c.operation) !== "CUT" || cmd.sheetId !== ((_d = this.state) === null || _d === void 0 ? void 0 : _d.sheetId)) {
32524
32524
  return;
32525
32525
  }
32526
32526
  for (let el of cmd.elements) {
@@ -39298,6 +39298,10 @@ class Spreadsheet extends Component {
39298
39298
  });
39299
39299
  useExternalListener(window, "resize", () => this.render(true));
39300
39300
  useExternalListener(window, "beforeunload", this.unbindModelEvents.bind(this));
39301
+ // For some reason, the wheel event is not properly registered inside templates
39302
+ // in Chromium-based browsers based on chromium 125
39303
+ // This hack ensures the event declared in the template is properly registered/working
39304
+ useExternalListener(document.body, "wheel", () => { });
39301
39305
  this.bindModelEvents();
39302
39306
  onMounted(() => {
39303
39307
  this.checkViewportSize();
@@ -43291,6 +43295,6 @@ function addFunction(functionName, functionDescription) {
43291
43295
  export { AbstractChart, CommandResult, CorePlugin, DATETIME_FORMAT, DispatchResult, EvaluationError, Model, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, UIPlugin, __info__, addFunction, astToFormula, cellTypes, compile, components, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, invalidateEvaluationCommands, load, parse, readonlyAllowedCommands, registries, setTranslationMethod, tokenize };
43292
43296
 
43293
43297
 
43294
- __info__.version = '16.0.41';
43295
- __info__.date = '2024-05-15T09:15:13.021Z';
43296
- __info__.hash = '3b3f648';
43298
+ __info__.version = '16.0.42';
43299
+ __info__.date = '2024-05-24T11:24:56.581Z';
43300
+ __info__.hash = 'fd11d19';
@@ -32468,7 +32468,7 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
32468
32468
  return 0 /* CommandResult.Success */;
32469
32469
  }
32470
32470
  handle(cmd) {
32471
- var _a, _b;
32471
+ var _a, _b, _c, _d;
32472
32472
  switch (cmd.type) {
32473
32473
  case "COPY":
32474
32474
  case "CUT":
@@ -32509,7 +32509,7 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
32509
32509
  case "ADD_COLUMNS_ROWS": {
32510
32510
  this.status = "invisible";
32511
32511
  // If we add a col/row inside or before the cut area, we invalidate the clipboard
32512
- if (((_a = this.state) === null || _a === void 0 ? void 0 : _a.operation) !== "CUT") {
32512
+ if (((_a = this.state) === null || _a === void 0 ? void 0 : _a.operation) !== "CUT" || cmd.sheetId !== ((_b = this.state) === null || _b === void 0 ? void 0 : _b.sheetId)) {
32513
32513
  return;
32514
32514
  }
32515
32515
  const isClipboardDirty = this.state.isColRowDirtyingClipboard(cmd.position === "before" ? cmd.base : cmd.base + 1, cmd.dimension);
@@ -32521,7 +32521,7 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
32521
32521
  case "REMOVE_COLUMNS_ROWS": {
32522
32522
  this.status = "invisible";
32523
32523
  // If we remove a col/row inside or before the cut area, we invalidate the clipboard
32524
- if (((_b = this.state) === null || _b === void 0 ? void 0 : _b.operation) !== "CUT") {
32524
+ if (((_c = this.state) === null || _c === void 0 ? void 0 : _c.operation) !== "CUT" || cmd.sheetId !== ((_d = this.state) === null || _d === void 0 ? void 0 : _d.sheetId)) {
32525
32525
  return;
32526
32526
  }
32527
32527
  for (let el of cmd.elements) {
@@ -39299,6 +39299,10 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
39299
39299
  });
39300
39300
  owl.useExternalListener(window, "resize", () => this.render(true));
39301
39301
  owl.useExternalListener(window, "beforeunload", this.unbindModelEvents.bind(this));
39302
+ // For some reason, the wheel event is not properly registered inside templates
39303
+ // in Chromium-based browsers based on chromium 125
39304
+ // This hack ensures the event declared in the template is properly registered/working
39305
+ owl.useExternalListener(document.body, "wheel", () => { });
39302
39306
  this.bindModelEvents();
39303
39307
  owl.onMounted(() => {
39304
39308
  this.checkViewportSize();
@@ -43322,9 +43326,9 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
43322
43326
  Object.defineProperty(exports, '__esModule', { value: true });
43323
43327
 
43324
43328
 
43325
- __info__.version = '16.0.41';
43326
- __info__.date = '2024-05-15T09:15:13.021Z';
43327
- __info__.hash = '3b3f648';
43329
+ __info__.version = '16.0.42';
43330
+ __info__.date = '2024-05-24T11:24:56.581Z';
43331
+ __info__.hash = 'fd11d19';
43328
43332
 
43329
43333
 
43330
43334
  })(this.o_spreadsheet = this.o_spreadsheet || {}, owl);