Skip to content

Commit 0392fc9

Browse files
MC-876: Pagebuilder - Tabs Advanced Border Displays Differently On Stage & Storefront
1 parent 4986a1a commit 0392fc9

File tree

2 files changed

+9
-8
lines changed
  • app/code/Magento/PageBuilder/view/adminhtml/web

2 files changed

+9
-8
lines changed

app/code/Magento/PageBuilder/view/adminhtml/web/css/source/content-type/tabs/_default.less

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -130,11 +130,6 @@
130130
}
131131
}
132132

133-
// Keeps the options showing while the user clicks. Otherwise the focus is lost and the options hide.
134-
.pagebuilder-options:hover {
135-
.pagebuilder-options-visible;
136-
}
137-
138133
&.focused {
139134
a.tab-title .tab-drag-handle {
140135
opacity: 1;

app/code/Magento/PageBuilder/view/adminhtml/web/template/content-type/tabs/default/preview.html

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,21 @@
66
-->
77

88
<div class="pagebuilder-content-type pagebuilder-tabs children-min-height" attr="data.main.attributes" ko-style="data.main.style" css="data.main.css" event="{ mouseover: onMouseOver, mouseout: onMouseOut }, mouseoverBubble: false">
9-
<render args="getOptions().template" />
9+
<div visible="focusedTab() === null">
10+
<render args="getOptions().template" />
11+
</div>
1012
<div class="tabs-container" afterRender="function (element) { onContainerRender.call($data, element); }">
1113
<ul role="tablist" class="tabs-navigation" each="parent.getChildren()" attr="data.navigation.attributes" ko-style="data.navigation.style" css="data.navigation.css" data-bind="sortableChildren: getSortableOptions()">
1214
<with args="preview">
13-
<li role="tab" class="tab-header" css="{focused: parent.parent.preview.focusedTab() === $index()}" click="function (context, event) { parent.parent.preview.onTabClick($index(), event); }" ko-style="parent.parent.preview.getTabHeaderStyles()">
15+
<li role="tab" class="tab-header"
16+
css="{focused: parent.parent.preview.focusedTab() === $index()}"
17+
click="function (context, event) { parent.parent.preview.onTabClick($index(), event); }"
18+
ko-style="parent.parent.preview.getTabHeaderStyles()"
19+
event="{ focusin: function () { parent.parent.preview.setFocusedTab($index(), true) }, focusout: function () { window.getSelection().removeAllRanges(); parent.parent.preview.setFocusedTab(null); } }">
1420
<a href="#no-tab" class="tab-title focus-options" attr="{ href: '#' + parent.id }">
1521
<render args="getOptions().template" />
1622
<span class="tab-drag-handle" css="{disabled: parent.parent.children().length <= 1}"></span>
17-
<span class="tab-title tab-name" data-tab-title="true" data-bind="liveEdit: { field: 'tab_name', placeholder: $t('...') }, hasFocusNoScroll: parent.parent.preview.focusedTab() === $index()" event="{ focusin: function () { parent.parent.preview.setFocusedTab($index(), true) }, focusout: function () { window.getSelection().removeAllRanges(); parent.parent.preview.setFocusedTab(null); } }"></span>
23+
<span class="tab-title tab-name" data-tab-title="true" data-bind="liveEdit: { field: 'tab_name', placeholder: $t('...') }, hasFocusNoScroll: parent.parent.preview.focusedTab() === $index()"></span>
1824
</a>
1925
</li>
2026
</with>

0 commit comments

Comments
 (0)