[UI] Fixed regex match for initSelectedPanel.

This commit is contained in:
Fabio Manganiello 2023-12-17 17:52:43 +01:00
parent 9d456281a6
commit b0feb8ed8f
Signed by untrusted user: blacklight
GPG key ID: D90FBA7F76362774

View file

@ -58,7 +58,7 @@ export default {
methods: { methods: {
initSelectedPanel() { initSelectedPanel() {
const match = this.$route.hash.match('#?([a-zA-Z0-9.]+)[?]?(.*)') const match = this.$route.hash.match(/^#?([a-zA-Z0-9_.]+)(\?(.+?))?/)
const plugin = match ? match[1] : 'entities' const plugin = match ? match[1] : 'entities'
if (plugin?.length) if (plugin?.length)
this.selectedPanel = plugin this.selectedPanel = plugin