|
2 | 2 | <t t-name="o-spreadsheet-ConditionalFormatPreview"> |
3 | 3 | <t t-set="cf" t-value="props.conditionalFormat"/> |
4 | 4 | <div |
5 | | - class="o-cf-preview w-100" |
| 5 | + class="o-cf-preview w-100 d-flex align-items-center" |
6 | 6 | t-ref="cfPreview" |
7 | 7 | t-att-class="props.class" |
8 | 8 | t-att-data-id="cf.id" |
9 | 9 | t-on-click="props.onPreviewClick" |
10 | 10 | t-on-pointerdown="(ev) => this.onMouseDown(ev)"> |
11 | | - <div class="position-relative h-100 w-100 d-flex align-items-center"> |
| 11 | + <div class="o-cf-drag-handle h-100 position-absolute d-flex align-items-center o-button-icon"> |
| 12 | + <t t-call="o-spreadsheet-Icon.THIN_DRAG_HANDLE"/> |
| 13 | + </div> |
| 14 | + <t t-if="cf.rule.type==='IconSetRule'"> |
| 15 | + <div class="o-cf-preview-icon d-flex justify-content-around align-items-center me-3"> |
| 16 | + <t t-call="o-spreadsheet-Icon.{{icons[cf.rule.icons.upper].template}}"/> |
| 17 | + <t t-call="o-spreadsheet-Icon.{{icons[cf.rule.icons.middle].template}}"/> |
| 18 | + <t t-call="o-spreadsheet-Icon.{{icons[cf.rule.icons.lower].template}}"/> |
| 19 | + </div> |
| 20 | + </t> |
| 21 | + <t t-else=""> |
12 | 22 | <div |
13 | | - class="o-cf-drag-handle h-100 position-absolute d-flex align-items-center o-button-icon"> |
14 | | - <t t-call="o-spreadsheet-Icon.THIN_DRAG_HANDLE"/> |
| 23 | + t-att-style="getPreviewImageStyle(cf.rule)" |
| 24 | + class="o-cf-preview-icon d-flex justify-content-around align-items-center me-3 flex-shrink-0"> |
| 25 | + 123 |
15 | 26 | </div> |
16 | | - <t t-if="cf.rule.type==='IconSetRule'"> |
17 | | - <div class="o-cf-preview-icon d-flex justify-content-around align-items-center me-2"> |
18 | | - <t t-call="o-spreadsheet-Icon.{{icons[cf.rule.icons.upper].template}}"/> |
19 | | - <t t-call="o-spreadsheet-Icon.{{icons[cf.rule.icons.middle].template}}"/> |
20 | | - <t t-call="o-spreadsheet-Icon.{{icons[cf.rule.icons.lower].template}}"/> |
21 | | - </div> |
22 | | - </t> |
23 | | - <t t-else=""> |
24 | | - <div |
25 | | - t-att-style="getPreviewImageStyle(cf.rule)" |
26 | | - class="o-cf-preview-icon d-flex justify-content-around align-items-center me-2"> |
27 | | - 123 |
28 | | - </div> |
29 | | - </t> |
30 | | - <div class="o-cf-preview-description"> |
31 | | - <div class="o-cf-preview-ruletype"> |
32 | | - <div class="o-cf-preview-description-rule o-fw-bold text-truncate"> |
33 | | - <t t-esc="getDescription(cf)"/> |
34 | | - </div> |
| 27 | + </t> |
| 28 | + <div class="o-cf-preview-description me-3 overflow-auto"> |
| 29 | + <div class="o-cf-preview-ruletype"> |
| 30 | + <div class="o-cf-preview-description-rule o-fw-bold text-truncate"> |
| 31 | + <t t-esc="getDescription(cf)"/> |
35 | 32 | </div> |
36 | | - <div class="o-cf-preview-range text-truncate" t-esc="cf.ranges"/> |
37 | 33 | </div> |
38 | | - <div class="o-cf-delete"> |
39 | | - <div |
40 | | - class="o-cf-delete-button o-button-icon" |
41 | | - t-on-click.stop="(ev) => this.deleteConditionalFormat(cf, ev)" |
42 | | - title="Remove rule"> |
43 | | - <t t-call="o-spreadsheet-Icon.TRASH_FILLED"/> |
44 | | - </div> |
| 34 | + <div class="o-cf-preview-range text-truncate" t-esc="cf.ranges"/> |
| 35 | + </div> |
| 36 | + <div class="o-cf-delete ms-auto"> |
| 37 | + <div |
| 38 | + class="o-cf-delete-button o-button-icon" |
| 39 | + t-on-click.stop="(ev) => this.deleteConditionalFormat(cf, ev)" |
| 40 | + title="Remove rule"> |
| 41 | + <t t-call="o-spreadsheet-Icon.TRASH_FILLED"/> |
45 | 42 | </div> |
46 | 43 | </div> |
47 | 44 | </div> |
|
0 commit comments