mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-26 18:29:51 +00:00
Preventing the opening of an empty floating aside (#7447)
Signed-off-by: Alexander Platov <alexander.platov@hardcoreeng.com>
This commit is contained in:
parent
2e8148595b
commit
088c37fa20
plugins/workbench-resources/src
@ -664,6 +664,15 @@
|
||||
oldNavVisible = $deviceInfo.navigator.visible
|
||||
oldASideVisible = $deviceInfo.aside.visible
|
||||
}
|
||||
$: if (
|
||||
$deviceInfo.aside.float &&
|
||||
$deviceInfo.aside.visible &&
|
||||
$sidebarStore.variant === SidebarVariant.MINI &&
|
||||
$sidebarStore.widgetsState.size > 0
|
||||
) {
|
||||
$sidebarStore.variant = SidebarVariant.EXPANDED
|
||||
$sidebarStore.widget = Array.from($sidebarStore.widgetsState.keys())[0]
|
||||
}
|
||||
$: $deviceInfo.navigator.direction = $deviceInfo.isMobile && $deviceInfo.isPortrait ? 'horizontal' : 'vertical'
|
||||
let appsMini: boolean
|
||||
$: appsMini =
|
||||
|
@ -339,7 +339,7 @@ export function minimizeSidebar (closedByUser = false): void {
|
||||
|
||||
sidebarStore.set({ ...state, ...widgetsState, widget: undefined, variant: SidebarVariant.MINI })
|
||||
const devInfo = get(deviceInfo)
|
||||
if (devInfo.navigator.float && devInfo.aside.visible) {
|
||||
if (devInfo.aside.float && devInfo.aside.visible) {
|
||||
deviceInfo.set({ ...devInfo, aside: { visible: false, float: true } })
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user