mirror of
https://github.com/overleaf/overleaf.git
synced 2025-02-23 14:01:52 +00:00
Don't reload editor with file tree or PDF viewer hidden
This commit is contained in:
parent
fde7efbb9f
commit
ff7632d6c7
3 changed files with 14 additions and 3 deletions
|
@ -53,7 +53,13 @@ block content
|
||||||
|
|
||||||
include ./editor/share
|
include ./editor/share
|
||||||
|
|
||||||
#ide-body(ng-cloak, layout="main", ng-hide="state.loading", resize-on="layout:chat:resize")
|
#ide-body(
|
||||||
|
ng-cloak,
|
||||||
|
layout="main",
|
||||||
|
ng-hide="state.loading",
|
||||||
|
resize-on="layout:chat:resize",
|
||||||
|
minimum-restore-size-west="130"
|
||||||
|
)
|
||||||
.ui-layout-west
|
.ui-layout-west
|
||||||
include ./editor/file-tree
|
include ./editor/file-tree
|
||||||
|
|
||||||
|
|
|
@ -6,6 +6,7 @@ div.full-size(
|
||||||
resize-on="layout:main:resize"
|
resize-on="layout:main:resize"
|
||||||
resize-proportionally="true"
|
resize-proportionally="true"
|
||||||
initial-size-east="'50%'"
|
initial-size-east="'50%'"
|
||||||
|
minimum-restore-size-east="300"
|
||||||
)
|
)
|
||||||
.ui-layout-center
|
.ui-layout-center
|
||||||
.loading-panel(ng-show="!editor.sharejs_doc || editor.opening")
|
.loading-panel(ng-show="!editor.sharejs_doc || editor.opening")
|
||||||
|
|
|
@ -37,8 +37,12 @@ define [
|
||||||
|
|
||||||
# Restore previously recorded state
|
# Restore previously recorded state
|
||||||
if (state = ide.localStorage("layout.#{name}"))?
|
if (state = ide.localStorage("layout.#{name}"))?
|
||||||
options.west = state.west
|
if state.east?
|
||||||
options.east = state.east
|
if !attrs.minimumRestoreSizeEast? or (state.east.size >= attrs.minimumRestoreSizeEast and !state.east.initClosed)
|
||||||
|
options.east = state.east
|
||||||
|
if state.west?
|
||||||
|
if !attrs.minimumRestoreSizeWest? or (state.west.size >= attrs.minimumRestoreSizeWest and !state.west.initClosed)
|
||||||
|
options.west = state.west
|
||||||
|
|
||||||
repositionControls = () ->
|
repositionControls = () ->
|
||||||
state = element.layout().readState()
|
state = element.layout().readState()
|
||||||
|
|
Loading…
Reference in a new issue