fix(simple-editor): sticky Step Library panel for long recipes
Reported 2026-05-20: on a 40+ step recipe (e.g. ENP-STEEL-BASIC), scrolling down into the Selected steps pane scrolled the Step Library off the top of the screen. Authors had to scroll back up to grab a step, then scroll down to drop it. Fix: position: sticky on .o_fp_library_panel, pinned to top: 1rem (matches the editor's padding) inside the .o_fp_simple_editor overflow container. align-items: start on the grid so the library column doesn't stretch to match the recipe column's height (prerequisite for sticky to behave). The library itself can have 30+ entries (curated step kinds + shop-defined library templates). max-height: calc(100vh - 8rem) + overflow-y: auto keeps it from blowing past the viewport — it grows its own internal scrollbar instead. Mobile (≤900px) reverts to static positioning so the stacked layout stays sensible. Module: fusion_plating 19.0.20.6.1 → 19.0.20.6.2. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
{
|
||||
'name': 'Fusion Plating',
|
||||
'version': '19.0.20.6.1',
|
||||
'version': '19.0.20.6.2',
|
||||
'category': 'Manufacturing/Plating',
|
||||
'summary': 'Core plating / metal finishing ERP: facilities, processes, tanks, baths, jobs, operators.',
|
||||
'description': """
|
||||
|
||||
@@ -116,6 +116,10 @@ $fp-se-drop: var(--fp-drop-bg, #{$_fp_se_drop_hex});
|
||||
display: grid;
|
||||
grid-template-columns: 2fr 1fr;
|
||||
gap: 1rem;
|
||||
// align-items: start so the library panel can be shorter than
|
||||
// the recipe-step column without stretching to match its height
|
||||
// — required for sticky positioning to behave.
|
||||
align-items: start;
|
||||
|
||||
@media (max-width: 900px) {
|
||||
grid-template-columns: 1fr;
|
||||
@@ -137,6 +141,33 @@ $fp-se-drop: var(--fp-drop-bg, #{$_fp_se_drop_hex});
|
||||
}
|
||||
}
|
||||
|
||||
// Step Library — pin to the top of the scroll container so authors
|
||||
// can drag from it into the recipe without scrolling back up.
|
||||
// Recipes can be 40+ steps long; before this, the library scrolled
|
||||
// off with the page and you had to scroll to the top, grab a step,
|
||||
// scroll back down, drop. Bug reported 2026-05-20.
|
||||
//
|
||||
// Sticky inside the editor's overflow:auto container. max-height +
|
||||
// internal overflow-y so the library's OWN content (could be 30+
|
||||
// entries) doesn't blow past the viewport — it grows a scrollbar
|
||||
// instead.
|
||||
.o_fp_library_panel {
|
||||
position: sticky;
|
||||
top: 1rem; // matches the editor's padding
|
||||
max-height: calc(100vh - 8rem); // leave room for headers + footer
|
||||
overflow-y: auto;
|
||||
// Keep a faint shadow on the sticky edge so it reads as a
|
||||
// floating sidebar, not glued onto the recipe column.
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
||||
|
||||
@media (max-width: 900px) {
|
||||
// Stacked layout — no sticky, behaves like a normal block.
|
||||
position: static;
|
||||
max-height: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
}
|
||||
|
||||
// ===================================================== Drop simulator
|
||||
//
|
||||
// Thin reservation line between rows that activates only when the
|
||||
|
||||
Reference in New Issue
Block a user