@odoo/o-spreadsheet 19.1.0-alpha.3 → 19.1.0-alpha.5

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.1.0-alpha.3
5
- @date 2025-09-23T12:38:47.420Z
6
- @hash ce2b07a
4
+ @version 19.1.0-alpha.5
5
+ @date 2025-10-16T06:40:46.498Z
6
+ @hash 1a0e3d5
7
7
  -->
8
8
  <odoo>
9
9
  <t t-name="o-spreadsheet-ValidationMessages">
@@ -361,7 +361,7 @@
361
361
  t-att-style="getStyle()">
362
362
  <t t-if="env.isDashboard()">
363
363
  <SpreadsheetDashboard getGridSize.bind="getGridSize"/>
364
- <FullScreenChart/>
364
+ <FullScreenFigure/>
365
365
  </t>
366
366
  <t t-else="">
367
367
  <div class="o-spreadsheet-topbar-wrapper o-two-columns">
@@ -398,9 +398,14 @@
398
398
  <RibbonMenu onClose="() => this.menuState.isOpen=false"/>
399
399
  </t>
400
400
  <t t-else="">
401
- <div class="o-small-composer px-2 py-2">
401
+ <div class="o-small-composer px-2 py-2 position-relative">
402
402
  <div class="w-100" t-ref="bottombarComposer">
403
403
  <Composer t-props="composerProps"/>
404
+ <span
405
+ t-if="showFxIcon"
406
+ class="position-absolute top-50 translate-middle-y ps-2 pe-none">
407
+ <t t-call="o-spreadsheet-Icon.FX_SVG"/>
408
+ </span>
404
409
  </div>
405
410
  <span
406
411
  class="align-items-center d-flex justify-content-center o-selection-button"
@@ -448,7 +453,10 @@
448
453
  </div>
449
454
  <span class="d-flex align-items-center" t-esc="state.title"/>
450
455
  </div>
451
- <div class="o-ribbon-menu-wrapper overflow-auto">
456
+ <div
457
+ class="o-ribbon-menu-wrapper overflow-auto"
458
+ t-ref="container"
459
+ t-on-scroll="updateShadows">
452
460
  <Menu t-props="menuProps"/>
453
461
  </div>
454
462
  </div>
@@ -5552,6 +5560,30 @@
5552
5560
  />
5553
5561
  </svg>
5554
5562
  </t>
5563
+ <t t-name="o-spreadsheet-Icon.FX_SVG">
5564
+ <svg class="o-icon fx-icon" viewBox="0 0 121.8 122.9">
5565
+ <path
5566
+ fill="currentColor"
5567
+ d='m28 34-4 5v2h10l-6 40c-4 22-6 28-7 30-2 2-3 3-5 3-3 0-7-2-9-4H4c-2 2-4 4-4 7s4 6 8 6 9-2 15-8c8-7 13-17 18-39l7-35 13-1 3-6H49c4-23 7-27 11-27 2 0 5 2 8 6h4c1-1 4-4 4-7 0-2-3-6-9-6-5 0-13 4-20 10-6 7-9 14-11 24h-8zm41 16c4-5 7-7 8-7s2 1 5 9l3 12c-7 11-12 17-16 17l-3-1-2-1c-3 0-6 3-6 7s3 7 7 7c6 0 12-6 22-23l3 10c3 9 6 13 10 13 5 0 11-4 18-15l-3-4c-4 6-7 8-8 8-2 0-4-3-6-10l-5-15 8-10 6-4 3 1 3 2c2 0 6-3 6-7s-2-7-6-7c-6 0-11 5-21 20l-2-6c-3-9-5-14-9-14-5 0-12 6-18 15l3 3z'
5568
+ />
5569
+ </svg>
5570
+ </t>
5571
+ <t t-name="o-spreadsheet-Icon.COLLAPSE">
5572
+ <svg class="o-icon" viewBox="0 0 18 18">
5573
+ <path
5574
+ d="M12.124 2.576a.6.6 0 0 1 0 .848l-2.7 2.7a.6.6 0 0 1-.848 0l-2.7-2.7a.6.6 0 0 1 .848-.848L8.4 4.2V.9a.6.6 0 0 1 1.2 0v3.3l1.676-1.624a.6.6 0 0 1 .848 0M5.876 15.424a.6.6 0 0 1 0-.848l2.7-2.7a.6.6 0 0 1 .848 0l2.7 2.7a.6.6 0 0 1-.848.848L9.6 13.8v3.3a.6.6 0 0 1-1.2 0v-3.3l-1.676 1.624a.6.6 0 0 1-.848 0M2 7a.5.5 0 0 0 0 1h14a.5.5 0 0 0 0-1M2 10a.5.5 0 0 0 0 1h14a.5.5 0 0 0 0-1"
5575
+ fill="currentColor"
5576
+ />
5577
+ </svg>
5578
+ </t>
5579
+ <t t-name="o-spreadsheet-Icon.EXPAND">
5580
+ <svg class="o-icon" viewBox="0 0 18 18">
5581
+ <path
5582
+ d="M5.876 14.076a.6.6 0 0 0 0 .848l2.7 2.7a.6.6 0 0 0 .848 0l2.7-2.7a.6.6 0 0 0-.848-.848L9.6 15.7v-3.3a.6.6 0 0 0-1.2 0v3.3l-1.676-1.624a.6.6 0 0 0-.848 0m6.248-10.152a.6.6 0 0 0 0-.848l-2.7-2.7a.6.6 0 0 0-.848 0l-2.7 2.7a.6.6 0 0 0 .848.848L8.4 2.3v3.3a.6.6 0 0 0 1.2 0V2.3l1.676 1.624a.6.6 0 0 0 .848 0M2 10a.5.5 0 0 0 0 1h14a.5.5 0 0 0 0-1M2 7a.5.5 0 0 0 0 1h14a.5.5 0 0 0 0-1"
5583
+ fill="currentColor"
5584
+ />
5585
+ </svg>
5586
+ </t>
5555
5587
 
5556
5588
  <t t-name="o-spreadsheet-IconPicker">
5557
5589
  <div class="o-icon-picker">
@@ -6029,8 +6061,8 @@
6029
6061
  </div>
6030
6062
  </t>
6031
6063
 
6032
- <t t-name="o-spreadsheet-FullScreenChart">
6033
- <div class="position-absolute o-fullscreen-chart-overlay w-100 h-100 d-flex" t-if="chartId">
6064
+ <t t-name="o-spreadsheet-FullScreenFigure">
6065
+ <div class="position-absolute o-fullscreen-figure-overlay w-100 h-100 d-flex" t-if="figureUI">
6034
6066
  <div
6035
6067
  class="position-absolute top-0 start-0 end-0 bottom-0"
6036
6068
  t-on-click="exitFullScreen"
@@ -6043,15 +6075,20 @@
6043
6075
  </button>
6044
6076
  <div class="flex-fill">
6045
6077
  <div
6046
- class="o-fullscreen-chart o-figure position-relative border rounded shadow"
6078
+ class="o-fullscreen-figure o-figure position-relative border rounded shadow"
6047
6079
  tabindex="1"
6048
- t-ref="fullScreenChart"
6080
+ t-ref="fullScreenFigure"
6049
6081
  t-on-click.stop=""
6050
6082
  t-on-keydown="(ev) => this.onKeyDown(ev)">
6051
- <t t-component="chartComponent" chartId="chartId" isFullScreen="true" t-key="chartId"/>
6052
- <div class="position-absolute top-0 end-0">
6053
- <ChartDashboardMenu chartId="chartId"/>
6054
- </div>
6083
+ <t>
6084
+ <t
6085
+ t-component="figureComponent"
6086
+ figureUI="figureUI"
6087
+ isFullScreen="true"
6088
+ onFigureDeleted="() => {}"
6089
+ t-key="figureUI.id"
6090
+ />
6091
+ </t>
6055
6092
  </div>
6056
6093
  </div>
6057
6094
  </div>
@@ -6136,7 +6173,7 @@
6136
6173
  </div>
6137
6174
  <div
6138
6175
  t-if="state.displayedValues.length === 0"
6139
- class="o-filter-menu-no-values d-flex align-items-center justify-content-center w-100 h-100 ">
6176
+ class="o-filter-menu-no-values d-flex align-items-center justify-content-center w-100 h-100 text-muted fst-italic">
6140
6177
  No results
6141
6178
  </div>
6142
6179
  </div>
@@ -6278,7 +6315,12 @@
6278
6315
 
6279
6316
  <t t-name="o-spreadsheet-ChartFigure">
6280
6317
  <div class="o-chart-container w-100 h-100" t-on-dblclick="onDoubleClick">
6281
- <t t-component="chartComponent" chartId="chartId" t-key="chartId"/>
6318
+ <t
6319
+ t-component="chartComponent"
6320
+ chartId="chartId"
6321
+ t-key="chartId"
6322
+ isFullScreen="props.isFullScreen"
6323
+ />
6282
6324
  </div>
6283
6325
  <div t-if="env.isDashboard()" class="position-absolute top-0 end-0">
6284
6326
  <ChartDashboardMenu chartId="chartId"/>
@@ -6302,7 +6344,7 @@
6302
6344
  t-att-style="titleStyle"
6303
6345
  />
6304
6346
  <div class="o-carousel-tabs d-flex flex-fill justify-content-end" t-ref="carouselTabs">
6305
- <t t-foreach="carousel.items" t-as="item" t-key="item_index">
6347
+ <t t-foreach="visibleCarouselItems" t-as="item" t-key="item_index">
6306
6348
  <div
6307
6349
  class="o-carousel-tab text-truncate px-2 mt-1 flex-shrink-0"
6308
6350
  t-att-class="{ 'selected': isItemSelected(item) }"
@@ -6312,7 +6354,7 @@
6312
6354
  </t>
6313
6355
  </div>
6314
6356
  <div
6315
- class="o-carousel-tabs-dropdown flex-shrink-0 rounded"
6357
+ class="o-carousel-tabs-dropdown o-carousel-button flex-shrink-0 rounded p-1"
6316
6358
  t-att-class="{'active': menuState.isOpen}"
6317
6359
  t-ref="carouselTabsDropdown"
6318
6360
  t-on-click="toggleMenu">
@@ -6326,6 +6368,22 @@
6326
6368
  popoverPositioning="'bottom-left'"
6327
6369
  />
6328
6370
  </div>
6371
+ <div
6372
+ t-if="env.isDashboard()"
6373
+ t-att-title="fullScreenButtonTitle"
6374
+ class="o-carousel-full-screen-button fa o-carousel-button rounded p-1 ms-1"
6375
+ t-att-class="{
6376
+ 'fa-compress': props.isFullScreen,
6377
+ 'fa-expand': !props.isFullScreen,
6378
+ 'invisible': selectedCarouselItem?.type !== 'chart',
6379
+ }"
6380
+ t-on-click="toggleFullScreen"
6381
+ />
6382
+ <div
6383
+ t-if="!env.isDashboard()"
6384
+ class="o-carousel-menu-button o-carousel-button fa fa-ellipsis-v rounded ms-1"
6385
+ t-on-click="openContextMenu"
6386
+ />
6329
6387
  </div>
6330
6388
  <div
6331
6389
  t-if="!selectedItem"
@@ -6339,12 +6397,14 @@
6339
6397
  <t
6340
6398
  t-component="chartComponent"
6341
6399
  chartId="selectedItem.chartId"
6400
+ isFullScreen="props.isFullScreen"
6342
6401
  t-key="selectedItem.chartId"
6343
6402
  />
6344
6403
  </div>
6345
6404
  <ChartDashboardMenu
6346
6405
  t-if="env.isDashboard()"
6347
6406
  chartId="selectedItem.chartId"
6407
+ hasFullScreenButton="false"
6348
6408
  t-key="selectedItem.chartId"
6349
6409
  />
6350
6410
  </div>
@@ -6375,6 +6435,7 @@
6375
6435
  onFigureDeleted="props.onFigureDeleted"
6376
6436
  figureUI="props.figureUI"
6377
6437
  editFigureStyle.bind="editWrapperStyle"
6438
+ openContextMenu.bind="openContextMenu"
6378
6439
  />
6379
6440
  <div class="o-figure-menu position-absolute m-2" t-if="!env.isDashboard()">
6380
6441
  <div
@@ -6395,18 +6456,22 @@
6395
6456
  <div t-if="!env.isDashboard()" class="position-absolute top-0 start-0 pe-none w-100 h-100">
6396
6457
  <div
6397
6458
  class="o-figure-border pe-auto w-100 h-0 position-absolute pb-2"
6459
+ t-att-class="{'o-selected': isSelected}"
6398
6460
  t-att-style="getBorderStyle('top')"
6399
6461
  />
6400
6462
  <div
6401
6463
  class="o-figure-border pe-auto h-100 position-absolute start-0 ps-2"
6464
+ t-att-class="{'o-selected': isSelected}"
6402
6465
  t-att-style="getBorderStyle('left')"
6403
6466
  />
6404
6467
  <div
6405
6468
  class="o-figure-border pe-auto w-100 position-absolute bottom-0 pt-2"
6469
+ t-att-class="{'o-selected': isSelected}"
6406
6470
  t-att-style="getBorderStyle('bottom')"
6407
6471
  />
6408
6472
  <div
6409
6473
  class="o-figure-border pe-auto h-100 position-absolute end-0 pe-2"
6474
+ t-att-class="{'o-selected': isSelected}"
6410
6475
  t-att-style="getBorderStyle('right')"
6411
6476
  />
6412
6477
  </div>
@@ -6609,6 +6674,9 @@
6609
6674
  composerStore="composerStore"
6610
6675
  placeholder="composerStore.placeholder"
6611
6676
  />
6677
+ <span t-if="showFxIcon" class="position-absolute top-50 translate-middle-y ps-2 pe-none">
6678
+ <t t-call="o-spreadsheet-Icon.FX_SVG"/>
6679
+ </span>
6612
6680
  </div>
6613
6681
  </div>
6614
6682
  </t>
@@ -7087,6 +7155,7 @@
7087
7155
  t-ref="sheetNameSpan"
7088
7156
  t-esc="sheetName"
7089
7157
  t-on-pointerdown="(ev) => this.onMouseEventSheetName(ev)"
7158
+ t-on-click="(ev) => this.onMouseEventSheetName(ev)"
7090
7159
  t-on-dblclick="() => this.onDblClick()"
7091
7160
  t-on-focusout="() => this.onFocusOut()"
7092
7161
  t-on-keydown="(ev) => this.onKeyDown(ev)"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@odoo/o-spreadsheet",
3
- "version": "19.1.0-alpha.3",
3
+ "version": "19.1.0-alpha.5",
4
4
  "description": "A spreadsheet component",
5
5
  "type": "module",
6
6
  "main": "dist/o-spreadsheet.cjs.js",
@@ -12,6 +12,9 @@
12
12
  "dist/*.d.ts",
13
13
  "dist/*.xml"
14
14
  ],
15
+ "engines": {
16
+ "node": ">=22.0.0"
17
+ },
15
18
  "scripts": {
16
19
  "serve-static": "live-server --open=demo --watch=build/o_spreadsheet.iife.js,build/o_spreadsheet.xml,build/o_spreadsheet.css,main.css,demo",
17
20
  "dev": "npm-run-all --print-label bundle:dev --parallel server serve-static watch",
@@ -85,7 +88,7 @@
85
88
  "jszip": "^3.6.0",
86
89
  "lint-staged": "^12.1.2",
87
90
  "live-server": "^1.2.1",
88
- "luxon": "^3.5.0",
91
+ "luxon": "^3.7.2",
89
92
  "minimist": "^1.2.8",
90
93
  "mockdate": "^3.0.2",
91
94
  "node-watch": "^0.7.3",