diff options
author | John Molakvoæ <skjnldsv@protonmail.com> | 2023-04-21 15:41:49 +0200 |
---|---|---|
committer | John Molakvoæ <skjnldsv@protonmail.com> | 2023-04-21 15:49:54 +0200 |
commit | ea9099a72f37b07ce689e25133ddca07f52cda64 (patch) | |
tree | 6b677e17dae423a3190335be086d9c1497bdac54 /apps/files/src/services | |
parent | cae00d2e965931efeb6ca5386d4dd2cff9f7dc62 (diff) | |
download | nextcloud-server-ea9099a72f37b07ce689e25133ddca07f52cda64.tar.gz nextcloud-server-ea9099a72f37b07ce689e25133ddca07f52cda64.zip |
feat(files): allow navigation entry removal
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'apps/files/src/services')
-rw-r--r-- | apps/files/src/services/Navigation.ts | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/apps/files/src/services/Navigation.ts b/apps/files/src/services/Navigation.ts index e86266013d7..b2ae3b0b973 100644 --- a/apps/files/src/services/Navigation.ts +++ b/apps/files/src/services/Navigation.ts @@ -126,6 +126,13 @@ export default class { this._views.push(view) } + remove(id: string) { + const index = this._views.findIndex(view => view.id === id) + if (index !== -1) { + this._views.splice(index, 1) + } + } + get views(): Navigation[] { return this._views } |