Directory lock button label is sometimes incorrect
Summary
When using the directory/file tree without refreshing the page the "Lock"/"Unlock" button will sometimes read incorrectly.
Steps to reproduce
Create two directories (temp1
and temp2
). Navigate to temp1
and click the "Lock" button. Click the two dots to move up one directory and then click temp2
. The button will say "Unlock" even though this directory isn't locked.
What is the current bug behavior?
"Lock"/"Unlock" button doesn't sync with current directory
What is the expected correct behavior?
"Lock"/"Unlock" button should stay in sync with current directory
Relevant logs and/or screenshots
Screen_Recording_2021-03-04_at_4.18.56_PM
Possible fixes
This is tricky to fix because the "Lock"/"Unlock" button is in HAML and the directory/file tree is in Vue. We need to somehow fetch the lock status of the current directory when navigating between directories. It may make sense to move these buttons into the Vue app. There is &5531 (closed) which is tracking a similar effort.