@odoo/o-spreadsheet 18.5.0-alpha.1 → 18.5.0-alpha.3

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 18.5.0-alpha.1
5
- @date 2025-06-27T09:13:39.263Z
6
- @hash 756e75b
4
+ @version 18.5.0-alpha.3
5
+ @date 2025-07-28T13:43:55.612Z
6
+ @hash 53dfee8
7
7
  -->
8
8
  <odoo>
9
9
  <t t-name="o-spreadsheet-ValidationMessages">
@@ -2682,7 +2682,7 @@
2682
2682
  </Section>
2683
2683
  <PieHoleSize
2684
2684
  t-if="props.definition.isDoughnut"
2685
- value="props.definition.pieHolePercentage ?? 50"
2685
+ value="props.definition.pieHolePercentage ?? this.defaultHoleSize"
2686
2686
  onValueChange.bind="onPieHoleSizeChange"
2687
2687
  />
2688
2688
  </t>
@@ -2690,46 +2690,48 @@
2690
2690
  </t>
2691
2691
 
2692
2692
  <t t-name="o-spreadsheet-ChartPanel">
2693
- <div class="o-chart" t-if="figureId">
2693
+ <div class="o-chart d-flex flex-column h-100" t-if="figureId">
2694
2694
  <div class="o-panel">
2695
2695
  <div
2696
2696
  class="o-panel-element o-panel-configuration"
2697
2697
  t-att-class="store.panel !== 'configuration' ? 'inactive' : ''"
2698
- t-on-click="() => this.store.activatePanel('configuration')">
2698
+ t-on-click="switchPanel.bind(this, 'configuration')">
2699
2699
  <i class="fa fa-sliders"/>
2700
2700
  Configuration
2701
2701
  </div>
2702
2702
  <div
2703
2703
  class="o-panel-element o-panel-design"
2704
2704
  t-att-class="store.panel !== 'design' ? 'inactive' : ''"
2705
- t-on-click="() => this.store.activatePanel('design')">
2705
+ t-on-click="switchPanel.bind(this, 'design')">
2706
2706
  <i class="fa fa-paint-brush"/>
2707
2707
  Design
2708
2708
  </div>
2709
2709
  </div>
2710
2710
 
2711
2711
  <t t-set="definition" t-value="getChartDefinition(this.figureId)"/>
2712
- <t t-if="store.panel === 'configuration'">
2713
- <ChartTypePicker figureId="props.figureId" chartPanelStore="store"/>
2714
- <t
2715
- t-component="chartPanel.configuration"
2716
- definition="definition"
2717
- figureId="figureId"
2718
- updateChart.bind="updateChart"
2719
- canUpdateChart.bind="canUpdateChart"
2720
- t-key="figureId + definition.type"
2721
- />
2722
- </t>
2723
- <t t-else="">
2724
- <t
2725
- t-component="chartPanel.design"
2726
- definition="definition"
2727
- figureId="figureId"
2728
- updateChart.bind="updateChart"
2729
- canUpdateChart.bind="canUpdateChart"
2730
- t-key="figureId + definition.type"
2731
- />
2732
- </t>
2712
+ <div class="o-panel-content overflow-y-auto" t-ref="panelContent">
2713
+ <div t-att-class="store.panel !== 'configuration' ? 'd-none' : ''">
2714
+ <ChartTypePicker figureId="props.figureId" chartPanelStore="store"/>
2715
+ <t
2716
+ t-component="chartPanel.configuration"
2717
+ definition="definition"
2718
+ figureId="figureId"
2719
+ updateChart.bind="updateChart"
2720
+ canUpdateChart.bind="canUpdateChart"
2721
+ t-key="figureId + definition.type"
2722
+ />
2723
+ </div>
2724
+ <div t-att-class="store.panel !== 'design' ? 'd-none' : ''">
2725
+ <t
2726
+ t-component="chartPanel.design"
2727
+ definition="definition"
2728
+ figureId="figureId"
2729
+ updateChart.bind="updateChart"
2730
+ canUpdateChart.bind="canUpdateChart"
2731
+ t-key="figureId + definition.type"
2732
+ />
2733
+ </div>
2734
+ </div>
2733
2735
  </div>
2734
2736
  </t>
2735
2737
 
@@ -6321,13 +6323,14 @@
6321
6323
  <t t-name="o-spreadsheet-Composer">
6322
6324
  <div class="o-composer-container w-100 h-100">
6323
6325
  <t t-set="autoCompleteProposals" t-value="props.composerStore.autoCompleteProposals"/>
6326
+ <t t-set="canBeToggled" t-value="props.composerStore.canBeToggled"/>
6324
6327
  <t
6325
6328
  t-set="assistantIsAvailable"
6326
6329
  t-value="props.showAssistant and (autoCompleteProposals.length or functionDescriptionState.showDescription)"
6327
6330
  />
6328
6331
  <div class="d-flex flex-row position-relative">
6329
6332
  <span
6330
- t-if="props.focus !== 'inactive' and assistantIsAvailable and assistant.forcedClosed"
6333
+ t-if="props.focus !== 'inactive' and assistantIsAvailable and canBeToggled and assistant.forcedClosed"
6331
6334
  role="button"
6332
6335
  title="Show formula help"
6333
6336
  t-on-click="openAssistant"
@@ -6344,7 +6347,7 @@
6344
6347
  t-att-style="props.inputStyle"
6345
6348
  t-ref="o_composer"
6346
6349
  tabindex="1"
6347
- t-att-contenteditable="env.model.getters.isReadonly() ? 'false' : 'true'"
6350
+ t-att-contenteditable="env.model.getters.isReadonly() ? 'false' : 'plaintext-only'"
6348
6351
  t-att-placeHolder="props.placeholder"
6349
6352
  t-att-inputmode="props.inputMode"
6350
6353
  spellcheck="false"
@@ -6367,12 +6370,13 @@
6367
6370
  <div
6368
6371
  class="o-composer-assistant-container shadow position-absolute z-1"
6369
6372
  t-att-style="assistantContainerStyle"
6370
- t-if="props.focus !== 'inactive' and !assistant.forcedClosed and assistantIsAvailable"
6373
+ t-if="props.focus !== 'inactive' and assistantIsAvailable and !(canBeToggled and assistant.forcedClosed)"
6371
6374
  t-on-wheel.stop=""
6372
6375
  t-on-pointerdown.prevent.stop=""
6373
6376
  t-on-pointerup.prevent.stop=""
6374
6377
  t-on-click.prevent.stop="">
6375
6378
  <span
6379
+ t-if="canBeToggled and !assistant.forcedClosed"
6376
6380
  role="button"
6377
6381
  t-on-click="closeAssistant"
6378
6382
  class="fa-stack position-absolute top-0 start-100 translate-middle fs-4">
@@ -6693,7 +6697,7 @@
6693
6697
  t-on-dblclick="() => this.onDblClick()"
6694
6698
  t-on-focusout="() => this.onFocusOut()"
6695
6699
  t-on-keydown="(ev) => this.onKeyDown(ev)"
6696
- t-att-contenteditable="state.isEditing ? 'true': 'false'"
6700
+ t-att-contenteditable="state.isEditing ? 'plaintext-only': 'false'"
6697
6701
  />
6698
6702
  <span
6699
6703
  class="o-sheet-icon ms-1"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@odoo/o-spreadsheet",
3
- "version": "18.5.0-alpha.1",
3
+ "version": "18.5.0-alpha.3",
4
4
  "description": "A spreadsheet component",
5
5
  "type": "module",
6
6
  "main": "dist/o-spreadsheet.cjs.js",