Browse Source

feat: Expand-tree view fully-clickable

pull/7619/head
Ruslan Semak 2 months ago
parent
commit
428ca5265b
1 changed files with 22 additions and 2 deletions
  1. 24
      client/themes/default/components/nav-sidebar.vue

24
client/themes/default/components/nav-sidebar.vue

@ -70,8 +70,8 @@
v-icon(v-else-if="open") mdi-folder-open v-icon(v-else-if="open") mdi-folder-open
v-icon(v-else) mdi-folder v-icon(v-else) mdi-folder
template(v-slot:label="{ item }") template(v-slot:label="{ item }")
div(class='tree-item')
a(v-if="!item.children" :href="'/'+item.locale+'/'+item.path")
div(class='tree-item' :class="{ 'tree-item-link': !item.children }")
a(v-if="!item.children" :href="'/'+item.locale+'/'+item.path" class='tree-item-link')
span {{item.name}} span {{item.name}}
span(v-else) {{item.name}} span(v-else) {{item.name}}
@ -380,12 +380,32 @@ export default {
</script> </script>
<style lang="scss"> <style lang="scss">
.v-treeview{ .v-treeview{
.tree-item { .tree-item {
width: 100%;
padding: 8px 0;
font-weight: 500; font-weight: 500;
line-height: 1rem; line-height: 1rem;
font-size: 0.8rem; font-size: 0.8rem;
} }
.tree-item-link {
display: block;
width: 100%;
text-decoration: none;
color: inherit;
}
.tree-item-link a {
display: block;
width: 100%;
padding: 8px 16px;
margin: -8px 0;
text-decoration: none;
color: inherit;
}
a { a {
text-decoration: none; text-decoration: none;
} }

Loading…
Cancel
Save