@odoo/o-spreadsheet 19.3.4 → 19.3.6

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.
@@ -1,9 +1,9 @@
1
1
  <!--
2
2
  This file is generated by o-spreadsheet build tools. Do not edit it.
3
3
  @see https://github.com/odoo/o-spreadsheet
4
- @version 19.3.4
5
- @date 2026-05-15T07:07:35.455Z
6
- @hash 1dc7b42
4
+ @version 19.3.6
5
+ @date 2026-06-06T06:24:23.733Z
6
+ @hash 0fe939b
7
7
  -->
8
8
  <odoo>
9
9
  <t t-name="o-spreadsheet-ValidationMessages">
@@ -5151,6 +5151,7 @@
5151
5151
  t-on-wheel.stop=""
5152
5152
  t-on-pointerdown.prevent=""
5153
5153
  t-on-click.stop="">
5154
+ <t t-set="shouldDisplayIcons" t-value="this.childrenHaveIcon"/>
5154
5155
  <t t-foreach="props.menuItems" t-as="menuItem" t-key="menuItem_index">
5155
5156
  <div t-if="menuItem === 'separator'" class="o-separator border-bottom"/>
5156
5157
  <t t-else="">
@@ -5170,7 +5171,7 @@
5170
5171
  t-att-style="getColor(menuItem)">
5171
5172
  <div class="d-flex w-100">
5172
5173
  <div
5173
- t-if="childrenHaveIcon"
5174
+ t-if="shouldDisplayIcons"
5174
5175
  class="o-menu-item-icon d-flex align-items-center flex-shrink-0"
5175
5176
  t-att-style="getIconColor(menuItem)">
5176
5177
  <t t-if="getIconName(menuItem)" t-call="{{getIconName(menuItem)}}"/>
@@ -1,4 +1,4 @@
1
- import { Registry } from "../registry";
1
+ import { Registry } from "../registries/registry";
2
2
  import { AddFunctionDescription, ComputeFunction, FunctionDescription } from "../types/functions";
3
3
  import { FunctionResultObject, Matrix } from "../types/misc";
4
4
  export declare class FunctionRegistry extends Registry<FunctionDescription> {
@@ -1,4 +1,4 @@
1
- import { Registry } from "../../../registry";
1
+ import { Registry } from "../../../registries/registry";
2
2
  import { GlobalChart } from "../../../types/chart/chartjs";
3
3
  export declare const chartJsExtensionRegistry: Registry<{
4
4
  register: (chart: GlobalChart) => void;
@@ -11,6 +11,10 @@ export declare function getFirstPivotFunction(compiledFormula: CompiledFormula,
11
11
  functionName: string;
12
12
  args: import("../..").AST[];
13
13
  };
14
+ export declare function getPivotFunctions(compiledFormula: CompiledFormula, getters: CoreGetters): {
15
+ functionName: string;
16
+ args: import("../..").AST[];
17
+ }[];
14
18
  /**
15
19
  * Parse a spreadsheet formula and detect the number of PIVOT functions that are
16
20
  * present in the given formula.
@@ -1,4 +1,4 @@
1
- import { Registry } from "../../registry";
1
+ import { Registry } from "../../registries/registry";
2
2
  import { CoreGetters } from "../../types/core_getters";
3
3
  import { Getters } from "../../types/getters";
4
4
  import { ApplyRangeChange, UID } from "../../types/misc";
@@ -134,11 +134,11 @@ export declare const registries: {
134
134
  colMenuRegistry: import("./registries/menu_items_registry").MenuItemRegistry;
135
135
  errorTypes: Set<string>;
136
136
  functionRegistry: import(".").FunctionRegistry;
137
- featurePluginRegistry: import("./registry").Registry<import("./plugins/ui_plugin").UIPluginConstructor>;
137
+ featurePluginRegistry: import(".").Registry<import("./plugins/ui_plugin").UIPluginConstructor>;
138
138
  iconsOnCellRegistry: import(".").Registry<(getters: import(".").Getters, position: import(".").CellPosition) => import("./registries/icons_on_cell_registry").GridIcon | undefined>;
139
- statefulUIPluginRegistry: import("./registry").Registry<import("./plugins/ui_plugin").UIPluginConstructor>;
140
- coreViewsPluginRegistry: import("./registry").Registry<import("./plugins/core_view_plugin").CoreViewPluginConstructor>;
141
- corePluginRegistry: import("./registry").Registry<import("./plugins/core_plugin").CorePluginConstructor>;
139
+ statefulUIPluginRegistry: import(".").Registry<import("./plugins/ui_plugin").UIPluginConstructor>;
140
+ coreViewsPluginRegistry: import(".").Registry<import("./plugins/core_view_plugin").CoreViewPluginConstructor>;
141
+ corePluginRegistry: import(".").Registry<import("./plugins/core_plugin").CorePluginConstructor>;
142
142
  rowMenuRegistry: import("./registries/menu_items_registry").MenuItemRegistry;
143
143
  sidePanelRegistry: import(".").Registry<import("./registries/side_panel_registry").SidePanelContent>;
144
144
  figureRegistry: import(".").Registry<import("./registries/figures_registry").FigureContent>;
@@ -178,14 +178,14 @@ export declare const registries: {
178
178
  figureHandlers: import(".").Registry<typeof import(".").AbstractFigureClipboardHandler>;
179
179
  cellHandlers: import(".").Registry<typeof import(".").AbstractCellClipboardHandler>;
180
180
  };
181
- pivotRegistry: import("./registry").Registry<import("./helpers/pivot/pivot_registry").PivotRegistryItem>;
181
+ pivotRegistry: import(".").Registry<import("./helpers/pivot/pivot_registry").PivotRegistryItem>;
182
182
  pivotTimeAdapterRegistry: import(".").Registry<import(".").PivotTimeAdapter<import(".").CellValue>>;
183
183
  pivotSidePanelRegistry: import(".").Registry<import("./helpers/pivot/pivot_side_panel_registry").PivotRegistryItem>;
184
184
  pivotNormalizationValueRegistry: import(".").Registry<(value: string, granularity?: import(".").Granularity | string) => import(".").CellValue>;
185
185
  supportedPivotPositionalFormulaRegistry: import(".").Registry<boolean>;
186
186
  pivotToFunctionValueRegistry: import(".").Registry<(value: import(".").CellValue, granularity?: string) => string>;
187
- migrationStepRegistry: import("./registry").Registry<import("./migrations/migration_steps").MigrationStep>;
188
- chartJsExtensionRegistry: import("./registry").Registry<{
187
+ migrationStepRegistry: import(".").Registry<import("./migrations/migration_steps").MigrationStep>;
188
+ chartJsExtensionRegistry: import(".").Registry<{
189
189
  register: (chart: import("./types/chart/chartjs").GlobalChart) => void;
190
190
  unregister: (chart: import("./types/chart/chartjs").GlobalChart) => void;
191
191
  }>;
@@ -1,4 +1,4 @@
1
- import { Registry } from "../registry";
1
+ import { Registry } from "../registries/registry";
2
2
  export interface MigrationStep {
3
3
  migrate: (data: any) => any;
4
4
  }
@@ -1,4 +1,4 @@
1
- import { Registry } from "../registry";
1
+ import { Registry } from "../registries/registry";
2
2
  import { CorePluginConstructor } from "./core_plugin";
3
3
  import { CoreViewPluginConstructor } from "./core_view_plugin";
4
4
  import { UIPluginConstructor } from "./ui_plugin";
@@ -1,12 +1,17 @@
1
1
  import { CompiledFormula } from "../../formulas/compiler";
2
+ import { CellValue } from "../../types/cells";
2
3
  import { Command } from "../../types/commands";
3
- import { CellPosition, SortDirection, UID } from "../../types/misc";
4
+ import { CellPosition, Matrix, SortDirection, UID } from "../../types/misc";
4
5
  import { PivotCoreMeasure, PivotStyle, PivotTableCell } from "../../types/pivot";
5
6
  import { Pivot } from "../../types/pivot_runtime";
6
7
  import { CoreViewPlugin, CoreViewPluginConfig } from "../core_view_plugin";
7
8
  export declare const UNDO_REDO_PIVOT_COMMANDS: string[];
9
+ interface PivotEvaluatedArgs {
10
+ functionName: string;
11
+ args: (CellValue | Matrix<CellValue> | undefined)[];
12
+ }
8
13
  export declare class PivotUIPlugin extends CoreViewPlugin {
9
- static getters: readonly ["getPivot", "getFirstPivotFunction", "getPivotCellSortDirection", "getPivotIdFromPosition", "getPivotCellFromPosition", "generateNewCalculatedMeasureName", "isPivotUnused", "isSpillPivotFormula", "getAllPivotArrayFormulas", "getPivotStyleAtPosition"];
14
+ static getters: readonly ["getPivot", "getFirstPivotFunction", "getPivotCellSortDirection", "getPivotIdFromPosition", "getPivotIdsFromPosition", "getPivotCellFromPosition", "generateNewCalculatedMeasureName", "isPivotUnused", "isSpillPivotFormula", "getAllPivotArrayFormulas", "getPivotStyleAtPosition"];
10
15
  private pivots;
11
16
  private unusedPivotsInFormulas?;
12
17
  private custom;
@@ -14,15 +19,18 @@ export declare class PivotUIPlugin extends CoreViewPlugin {
14
19
  beforeHandle(cmd: Command): void;
15
20
  handle(cmd: Command): void;
16
21
  /**
17
- * Get the id of the pivot at the given position. Returns undefined if there
22
+ * Get the id of the first pivot in the formula at the given position. Returns undefined if there
18
23
  * is no pivot at this position
19
24
  */
20
- getPivotIdFromPosition(position: CellPosition): "" | UID | undefined;
25
+ getPivotIdFromPosition(position: CellPosition): UID | undefined;
26
+ /**
27
+ * Get all of the ids of the pivot present in the formula at the given position.
28
+ */
29
+ getPivotIdsFromPosition(position: CellPosition): UID[];
30
+ private getPivotIdsFromFormula;
21
31
  isSpillPivotFormula(position: CellPosition): boolean;
22
- getFirstPivotFunction(sheetId: UID, compiledFormula: CompiledFormula): {
23
- functionName: string;
24
- args: (import("../..").CellValue | import("../..").Matrix<import("../..").CellValue> | undefined)[];
25
- } | undefined;
32
+ private getPivotFunctions;
33
+ getFirstPivotFunction(sheetId: UID, formula: CompiledFormula): PivotEvaluatedArgs | undefined;
26
34
  /**
27
35
  * Returns the domain args of a pivot formula from a position.
28
36
  * For all those formulas:
@@ -60,3 +68,4 @@ export declare class PivotUIPlugin extends CoreViewPlugin {
60
68
  } | undefined;
61
69
  private isMainFunctionPivotSpreadFunction;
62
70
  }
71
+ export {};
@@ -21,7 +21,7 @@ export declare class TableComputedStylePlugin extends UIPlugin {
21
21
  */
22
22
  private getTableMapping;
23
23
  }
24
- declare const invalidateTableStyleCommands: readonly ["HIDE_COLUMNS_ROWS", "UNHIDE_COLUMNS_ROWS", "UNFOLD_HEADER_GROUP", "UNGROUP_HEADERS", "FOLD_HEADER_GROUP", "FOLD_ALL_HEADER_GROUPS", "UNFOLD_ALL_HEADER_GROUPS", "FOLD_HEADER_GROUPS_IN_ZONE", "UNFOLD_HEADER_GROUPS_IN_ZONE", "CREATE_TABLE", "UPDATE_TABLE", "UPDATE_FILTER", "REMOVE_TABLE", "RESIZE_TABLE", "CREATE_TABLE_STYLE", "REMOVE_TABLE_STYLE"];
24
+ declare const invalidateTableStyleCommands: readonly ["HIDE_COLUMNS_ROWS", "UNHIDE_COLUMNS_ROWS", "UNFOLD_HEADER_GROUP", "UNGROUP_HEADERS", "FOLD_HEADER_GROUP", "FOLD_ALL_HEADER_GROUPS", "UNFOLD_ALL_HEADER_GROUPS", "FOLD_HEADER_GROUPS_IN_ZONE", "UNFOLD_HEADER_GROUPS_IN_ZONE", "CREATE_TABLE", "UPDATE_TABLE", "UPDATE_FILTER", "REMOVE_TABLE", "RESIZE_TABLE", "CREATE_TABLE_STYLE", "REMOVE_TABLE_STYLE", "DELETE_CONTENT"];
25
25
  export declare function doesCommandInvalidatesTableStyle(cmd: Command): cmd is {
26
26
  type: (typeof invalidateTableStyleCommands)[number];
27
27
  } & Command;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@odoo/o-spreadsheet",
3
- "version": "19.3.4",
3
+ "version": "19.3.6",
4
4
  "description": "A spreadsheet component",
5
5
  "type": "module",
6
6
  "main": "dist/o_spreadsheet.cjs",
@@ -1,10 +0,0 @@
1
- export declare class Registry<T> {
2
- content: Record<string, T>;
3
- add(key: string, value: T): this;
4
- replace(key: string, value: T): this;
5
- get(key: string): T;
6
- contains(key: string): boolean;
7
- getAll(): T[];
8
- getKeys(): string[];
9
- remove(key: string): void;
10
- }