From 8e60532f96147276b025b52e6d2bb51ff7b81a2c Mon Sep 17 00:00:00 2001 From: Jan-Hendrik Willms <tleilax+studip@gmail.com> Date: Tue, 26 Sep 2023 10:07:39 +0000 Subject: [PATCH] fixes #3230 Closes #3230 Merge request studip/studip!2191 --- resources/vue/components/SearchWidget.vue | 2 +- .../vue/components/tree/StudipTreeList.vue | 18 +++++++++++------- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/resources/vue/components/SearchWidget.vue b/resources/vue/components/SearchWidget.vue index d590b009244..4b17820b0bb 100644 --- a/resources/vue/components/SearchWidget.vue +++ b/resources/vue/components/SearchWidget.vue @@ -9,7 +9,7 @@ :placeholder="$gettext('Veranstaltung suchen')" :aria-label="$gettext('Veranstaltung suchen')"> <a v-if="isActive" @click.prevent="cancelSearch" class="reset-search"> - <studip-icon shape="decline" size="20"></studip-icon> + <studip-icon shape="decline" :size="20"></studip-icon> </a> <button type="submit" class="submit-search" :title="$gettext('Suchen')" @click.prevent="doSearch"> diff --git a/resources/vue/components/tree/StudipTreeList.vue b/resources/vue/components/tree/StudipTreeList.vue index d773f433f89..0ba4b550224 100644 --- a/resources/vue/components/tree/StudipTreeList.vue +++ b/resources/vue/components/tree/StudipTreeList.vue @@ -11,12 +11,14 @@ <section v-else> <h1> {{ currentNode.attributes.name }} - <a v-if="isEditable && currentNode.attributes.id !== 'root'" + + <a v-if="editable && currentNode.attributes.id !== 'root'" :href="editUrl + '/' + currentNode.attributes.id" @click.prevent="editNode(editUrl, currentNode.id)" data-dialog="size=medium" :title="$gettextInterpolate($gettext('%{name} bearbeiten'), {name: currentNode.attributes.name})"> <studip-icon shape="edit" :size="20"></studip-icon> </a> + </h1> <p v-if="currentNode.attributes.description?.trim() !== ''" class="studip-tree-node-info" v-html="currentNode.attributes['description-formatted']"> @@ -51,20 +53,17 @@ {{ $gettext('Auf dieser Ebene sind keine Veranstaltungen zugeordnet.')}} </section> - <section v-if="thisLevelCourses + subLevelsCourses > 0"> + <section v-if="thisLevelCourses + subLevelsCourses > 0" class="levels-actions"> <span v-if="withCourses && showingAllCourses"> <button type="button" @click="showAllCourses(false)" :title="$gettext('Veranstaltungen auf dieser Ebene anzeigen')"> - Veranstaltungen auf dieser Ebene anzeigen + {{ $gettext('Veranstaltungen auf dieser Ebene anzeigen') }} </button> </span> - <template v-if="thisLevelCourses > 0 && subLevelsCourses > 0"> - | - </template> <span v-if="withCourses && subLevelsCourses > 0 && !showingAllCourses"> <button type="button" @click="showAllCourses(true)" :title="$gettext('Veranstaltungen auf allen Unterebenen anzeigen')"> - Veranstaltungen auf allen Unterebenen anzeigen + {{ $gettext('Veranstaltungen auf allen Unterebenen anzeigen') }} </button> </span> </section> @@ -357,3 +356,8 @@ export default { } } </script> +<style scoped> +.levels-actions > span:not(:first-child)::before { + content: ' | '; +} +</style> -- GitLab