@odoo/o-spreadsheet 16.3.22 → 16.3.25

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.
@@ -268,7 +268,7 @@
268
268
  t-on-dblclick="() => this.onDblClick()"
269
269
  t-on-focusout="() => this.onFocusOut()"
270
270
  t-on-keydown="(ev) => this.onKeyDown(ev)"
271
- t-att-contenteditable="state.isEditing.toString()"
271
+ t-att-contenteditable="state.isEditing ? 'plaintext-only': 'false'"
272
272
  />
273
273
  <span class="o-sheet-icon ms-1" t-on-click.stop="(ev) => this.onIconClick(ev)">
274
274
  <t t-call="o-spreadsheet-Icon.TRIANGLE_DOWN"/>
@@ -437,7 +437,7 @@
437
437
  t-on-keyup="onKeyup"
438
438
  t-on-click="onClick"
439
439
  t-on-blur="onBlur"
440
- t-on-paste.stop=""
440
+ t-on-paste="onPaste"
441
441
  t-on-compositionstart="onCompositionStart"
442
442
  t-on-compositionend="onCompositionEnd"
443
443
  />
@@ -532,14 +532,7 @@
532
532
  t-esc="cellReference"
533
533
  />
534
534
  <div class="o-grid-composer" t-att-style="containerStyle" t-ref="gridComposer">
535
- <Composer
536
- focus="props.focus"
537
- inputStyle="composerStyle"
538
- rect="composerState.rect"
539
- delimitation="composerState.delimitation"
540
- onComposerUnmounted="props.onComposerUnmounted"
541
- onComposerContentFocused="props.onComposerContentFocused"
542
- />
535
+ <Composer t-props="composerProps"/>
543
536
  </div>
544
537
  </t>
545
538
 
@@ -910,9 +903,10 @@
910
903
  class="o-grid"
911
904
  tabindex="-1"
912
905
  t-att-class="{'o-two-columns': !props.sidePanelIsOpen}"
913
- t-on-click="focus"
906
+ t-on-click="focusDefaultElement"
914
907
  t-on-keydown="onKeydown"
915
908
  t-on-wheel="onMouseWheel"
909
+ t-on-contextmenu="onInputContextMenu"
916
910
  t-ref="grid">
917
911
  <GridOverlay
918
912
  onCellClicked.bind="onCellClicked"
@@ -922,27 +916,15 @@
922
916
  onGridResized.bind="onGridResized"
923
917
  onGridMoved.bind="moveCanvas"
924
918
  gridOverlayDimensions="gridOverlayDimensions"
925
- onFigureDeleted.bind="focus"
919
+ onFigureDeleted.bind="focusDefaultElement"
926
920
  />
927
921
  <HeadersOverlay onOpenContextMenu="(type, x, y) => this.toggleContextMenu(type, x, y)"/>
928
-
929
- <t t-if="env.model.getters.getEditionMode() !== 'inactive'">
930
- <GridComposer
931
- onComposerUnmounted="() => this.focus()"
932
- onComposerContentFocused="props.onComposerContentFocused"
933
- focus="props.focusComposer"
934
- gridDims="env.model.getters.getSheetViewDimensionWithHeaders()"
935
- />
936
- </t>
937
- <t else="1">
938
- <input
939
- class="position-absolute"
940
- style="z-index:-1000;"
941
- t-on-input="onInput"
942
- t-on-contextmenu="onInputContextMenu"
943
- t-ref="hiddenInput"
944
- />
945
- </t>
922
+ <GridComposer
923
+ focus="props.focusComposer"
924
+ onComposerContentFocused="props.onComposerContentFocused"
925
+ onComposerCellFocused="props.onGridComposerCellFocused"
926
+ gridDims="env.model.getters.getSheetViewDimensionWithHeaders()"
927
+ />
946
928
  <canvas t-ref="canvas"/>
947
929
  <t
948
930
  t-foreach="env.model.getters.getClientsToDisplay()"
@@ -993,7 +975,7 @@
993
975
  t-att-style="props.gridOverlayDimensions"
994
976
  t-on-mousedown="onMouseDown"
995
977
  t-on-dblclick.self="onDoubleClick"
996
- t-on-contextmenu="onContextMenu">
978
+ t-on-contextmenu.stop.prevent="onContextMenu">
997
979
  <FiguresContainer onFigureDeleted="props.onFigureDeleted"/>
998
980
  </div>
999
981
  </t>
@@ -1370,7 +1352,7 @@
1370
1352
  <svg class="o-icon">
1371
1353
  <path
1372
1354
  fill="currentColor"
1373
- d="M16 .5A1.5 1.5 0 0 1 17.5 2v14a1.5 1.5 0 0 1-1.5 1.5H2A1.5 1.5 0 0 1 .5 16V2A1.5 1.5 0 0 1 2 .5h14V2h-3.5v14H16V2H7v14h4V2H2v14h3.5V2M6 1l5 4v2L6 3m0 2 5 4v2L6 7m0 2 5 4v2l-5-4m0 2 5 4H"
1355
+ d="M16 .5A1.5 1.5 0 0 1 17.5 2v14a1.5 1.5 0 0 1-1.5 1.5H2A1.5 1.5 0 0 1 .5 16V2A1.5 1.5 0 0 1 2 .5h14V2h-3.5v14H16V2H7v14h4V2H2v14h3.5V2M6 1l5 4v2L6 3m0 2 5 4v2L6 7m0 2 5 4v2l-5-4"
1374
1356
  />
1375
1357
  </svg>
1376
1358
  </t>
@@ -3875,7 +3857,7 @@ https://fontawesome.com/license -->
3875
3857
  </t>
3876
3858
  </odoo>
3877
3859
  <!--
3878
- __info__.version = '16.3.22';
3879
- __info__.date = '2024-01-17T10:24:33.352Z';
3880
- __info__.hash = '2c1b136';
3860
+ __info__.version = '16.3.25';
3861
+ __info__.date = '2024-02-09T13:07:31.674Z';
3862
+ __info__.hash = 'b53bf1b';
3881
3863
  -->
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@odoo/o-spreadsheet",
3
- "version": "16.3.22",
3
+ "version": "16.3.25",
4
4
  "description": "A spreadsheet component",
5
5
  "main": "dist/o-spreadsheet.cjs.js",
6
6
  "browser": "dist/o-spreadsheet.iife.js",