@odoo/o-spreadsheet 18.1.6 → 18.1.8

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.
@@ -1247,6 +1247,7 @@ declare class Session extends EventBus<CollaborativeEvent> {
1247
1247
  private onClientJoined;
1248
1248
  private onClientLeft;
1249
1249
  private sendUpdateMessage;
1250
+ private dropPendingRevision;
1250
1251
  /**
1251
1252
  * Send the next pending message
1252
1253
  */
@@ -1446,6 +1447,20 @@ declare function splitReference(ref: string): {
1446
1447
  declare function computeTextWidth(context: CanvasRenderingContext2D, text: string, style: Style, fontUnit?: "px" | "pt"): number;
1447
1448
 
1448
1449
  declare class UuidGenerator {
1450
+ /**
1451
+ * Generates a custom UUID using a simple 36^12 method (8-character alphanumeric string with lowercase letters)
1452
+ * This has a higher chance of collision than a UUIDv4, but not only faster to generate than an UUIDV4,
1453
+ * it also has a smaller size, which is preferable to alleviate the overall data size.
1454
+ *
1455
+ * This method is preferable when generating uuids for the core data (sheetId, figureId, etc)
1456
+ * as they will appear several times in the revisions and local history.
1457
+ *
1458
+ */
1459
+ smallUuid(): string;
1460
+ /**
1461
+ * Generates an UUIDV4, has astronomically low chance of collision, but is larger in size than the smallUuid.
1462
+ * This method should be used when you need to avoid collisions at all costs, like the id of a revision.
1463
+ */
1449
1464
  uuidv4(): string;
1450
1465
  }
1451
1466
 
@@ -2046,6 +2061,7 @@ declare class GridSelectionPlugin extends UIPlugin {
2046
2061
  private onAddElements;
2047
2062
  private onMoveElements;
2048
2063
  private isMoveElementAllowed;
2064
+ private fallbackToVisibleSheet;
2049
2065
  /**
2050
2066
  * Clip the selection if it spans outside the sheet
2051
2067
  */
@@ -9555,7 +9571,7 @@ interface DndPartialArgs {
9555
9571
  draggedItemId: UID;
9556
9572
  initialMousePosition: Pixel;
9557
9573
  items: DragAndDropItemsPartial[];
9558
- containerEl: HTMLElement;
9574
+ scrollableContainerEl: HTMLElement;
9559
9575
  onChange?: () => void;
9560
9576
  onCancel?: () => void;
9561
9577
  onDragEnd?: (itemId: UID, indexAtEnd: Pixel) => void;
@@ -10076,6 +10092,7 @@ interface Props$f {
10076
10092
  unusedGranularities: Record<string, Set<string>>;
10077
10093
  dateGranularities: string[];
10078
10094
  datetimeGranularities: string[];
10095
+ getScrollableContainerEl?: () => HTMLElement;
10079
10096
  pivotId: UID;
10080
10097
  }
10081
10098
  declare class PivotLayoutConfigurator extends Component<Props$f, SpreadsheetChildEnv> {
@@ -10096,6 +10113,10 @@ declare class PivotLayoutConfigurator extends Component<Props$f, SpreadsheetChil
10096
10113
  unusedGranularities: ObjectConstructor;
10097
10114
  dateGranularities: ArrayConstructor;
10098
10115
  datetimeGranularities: ArrayConstructor;
10116
+ getScrollableContainerEl: {
10117
+ type: FunctionConstructor;
10118
+ optional: boolean;
10119
+ };
10099
10120
  pivotId: StringConstructor;
10100
10121
  };
10101
10122
  private dimensionsRef;
@@ -12663,9 +12684,9 @@ declare const chartHelpers: {
12663
12684
  getGeoChartData(definition: GeoChartDefinition, dataSets: DataSet[], labelRange: Range | undefined, getters: Getters): GeoChartRuntimeGenerationArgs;
12664
12685
  getTrendDatasetForBarChart(config: TrendConfiguration, data: any[]): chart_js.Point[] | undefined;
12665
12686
  getTrendDatasetForLineChart(config: TrendConfiguration, data: any[], labels: string[], axisType: AxisType, locale: Locale): chart_js.Point[] | undefined;
12666
- canChartParseLabels(labelRange: Range | undefined, getters: Getters): boolean;
12687
+ canChartParseLabels(definition: GenericDefinition<LineChartDefinition>, dataSets: DataSet[], labelRange: Range | undefined, getters: Getters): boolean;
12667
12688
  getData(getters: Getters, ds: DataSet): (CellValue | undefined)[];
12668
- getChartLabelFormat(getters: Getters, range: Range | undefined): Format | undefined;
12689
+ getChartLabelFormat(getters: Getters, range: Range | undefined, shouldRemoveFirstLabel: boolean): Format | undefined;
12669
12690
  getBarChartDatasets(definition: GenericDefinition<BarChartDefinition>, args: ChartRuntimeGenerationArgs): chart_js.ChartDataset<"line" | "bar">[];
12670
12691
  getWaterfallDatasetAndLabels(definition: GenericDefinition<WaterfallChartDefinition>, args: ChartRuntimeGenerationArgs): {
12671
12692
  datasets: chart_js.ChartDataset[];