|
1 | 1 | <template> |
2 | 2 | <Fragment> |
3 | | - |
4 | | - <NcAppNavigationItem |
5 | | - :title="title" |
6 | | - class="app-navigation-noclose separator-below" |
7 | | - :class="{ 'category-header': selectedCategory !== null }" |
8 | | - :open.sync="open" |
9 | | - :menu-open.sync="menuOpen" |
10 | | - :allow-collapse="true" |
11 | | - @click.prevent.stop="onToggleCategories" |
12 | | - > |
13 | | - <template #menu-icon> |
14 | | - <AddIcon :size="20" @click="onToggleNewCategory" /> |
15 | | - </template> |
16 | | - <template #actions> |
17 | | - <NcActionText> |
18 | | - <template #icon> |
19 | | - <ErrorIcon v-if="createCategoryError" :size="20" /> |
20 | | - <AddIcon v-else-if="!createCategoryError" :size="20" /> |
21 | | - </template> |
22 | | - {{ createCategoryError ? createCategoryError : t('notes', 'Create a new category') }} |
23 | | - </NcActionText> |
24 | | - <NcActionInput |
25 | | - icon="" |
26 | | - :value="t('notes', 'Category name')" |
27 | | - @submit.prevent.stop="createNewCategory" |
28 | | - > |
29 | | - <template #icon> |
30 | | - <FolderIcon :size="20" /> |
31 | | - </template> |
32 | | - </NcActionInput> |
33 | | - </template> |
34 | | - |
35 | 3 | <FolderIcon slot="icon" :size="20" /> |
36 | 4 | <NcAppNavigationItem |
37 | 5 | :title="t('notes', 'All notes')" |
|
44 | 12 | </NcAppNavigationCounter> |
45 | 13 | </NcAppNavigationItem> |
46 | 14 |
|
47 | | - <NcAppNavigationCaption :title="t('notes', 'Categories')" /> |
| 15 | + <NcAppNavigationCaption :title="t('notes', 'Categories')"> |
| 16 | + <template #actionsTriggerIcon> |
| 17 | + <AddIcon slot="icon" :size="20" /> |
| 18 | + </template> |
| 19 | + <template #actions> |
| 20 | + <NcActionText> |
| 21 | + <template #icon> |
| 22 | + <ErrorIcon v-if="createCategoryError" :size="20" /> |
| 23 | + <AddIcon v-else-if="!createCategoryError" :size="20" /> |
| 24 | + </template> |
| 25 | + {{ createCategoryError ? createCategoryError : t('notes', 'Create a new category') }} |
| 26 | + </NcActionText> |
| 27 | + <NcActionInput |
| 28 | + icon="" |
| 29 | + :value="t('notes', 'Category name')" |
| 30 | + @submit.prevent.stop="createNewCategory" |
| 31 | + > |
| 32 | + <template #icon> |
| 33 | + <FolderIcon :size="20" /> |
| 34 | + </template> |
| 35 | + </NcActionInput> |
| 36 | + </template> |
| 37 | + </NcAppNavigationCaption> |
48 | 38 |
|
49 | 39 | <NcAppNavigationItem v-for="category in categories" |
50 | 40 | :key="category.name" |
|
0 commit comments