Skip to content

Commit

Permalink
Merge pull request #5695 from nextcloud-libraries/feat/NcAppSidebar--…
Browse files Browse the repository at this point in the history
…toggleAttrs

feat(NcAppSidebar): add `toggleAttrs` prop to pass attributes on the toggle button
  • Loading branch information
ShGKme authored Jun 13, 2024
2 parents f3ed94e + a3de592 commit 42ad156
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/components/NcAppSidebar/NcAppSidebar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -443,6 +443,7 @@ export default {
:aria-label="t('Open sidebar')"
class="app-sidebar__toggle"
:class="toggleClasses"
v-bind="toggleAttrs"
type="tertiary"
@click="$emit('update:open', true)">
<template #icon>
Expand Down Expand Up @@ -773,13 +774,21 @@ export default {
},
/**
* Custom classes to assign to the sidebar toggle button
* Custom classes to assign to the sidebar toggle button.
* If needed this can be used to assign styles to the button using `:deep()` selector.
*/
toggleClasses: {
type: [String, Array, Object],
default: '',
},
/**
* Custom attrs to assign to the sidebar toggle button.
*/
toggleAttrs: {
type: Object,
default: undefined,
},
},
emits: [
Expand Down

0 comments on commit 42ad156

Please sign in to comment.