8484 }"
8585 >
8686 <text-editor
87- class =" markdown-container-content w-full [ & _#text-editor-preview-component]:!bg-transparent "
87+ class =" markdown-container-content w-full"
8888 is-read-only
8989 :current-content =" markdownContent"
9090 />
91- <div v-if =" isEditReadmeVisible" class =" markdown-container-edit ml-2" >
92- <oc-button
93- type =" router-link"
94- size =" small"
95- :aria-label =" $gettext('Edit description')"
96- appearance =" raw"
97- class =" p-1"
98- :to =" editReadMeContentLink"
99- >
100- <oc-icon name =" pencil" size =" small" fill-type =" line" />
101- </oc-button >
102- </div >
10391 </div >
10492 <div
10593 v-if =" showMarkdownCollapse && markdownContent"
@@ -123,11 +111,9 @@ import {
123111 SideBarEventTopics ,
124112 TextEditor ,
125113 useClientService ,
126- useFileActions ,
127114 useLoadPreview ,
128115 useResourcesStore ,
129116 useSharesStore ,
130- useSpaceActionsEditReadmeContent ,
131117 useSpacesStore
132118} from ' @opencloud-eu/web-pkg'
133119import SpaceContextActions from ' ./SpaceContextActions.vue'
@@ -147,16 +133,10 @@ const { $gettext, $ngettext } = language
147133const clientService = useClientService ()
148134const { getFileContents, getFileInfo } = clientService .webdav
149135const resourcesStore = useResourcesStore ()
150- const { getDefaultAction } = useFileActions ()
151136const { loadPreview } = useLoadPreview ()
152137const spacesStore = useSpacesStore ()
153138const sharesStore = useSharesStore ()
154139const { imagesLoading, readmesLoading } = storeToRefs (spacesStore )
155- const { actions : editReadmeContentActions } = useSpaceActionsEditReadmeContent ()
156-
157- const isEditReadmeVisible = computed (() =>
158- unref (editReadmeContentActions )[0 ].isVisible ({ resources: [space ] })
159- )
160140
161141const isMobileWidth = inject <Ref <boolean >>(' isMobileWidth' )
162142
@@ -280,15 +260,6 @@ watch(
280260const imageContent = ref <string >(null )
281261const imageExpanded = ref (false )
282262
283- const editReadMeContentLink = computed (() => {
284- const action = getDefaultAction ({ resources: [unref (markdownResource )], space })
285-
286- if (! action .route ) {
287- return null
288- }
289-
290- return action .route ({ space , resources: [unref (markdownResource )] })
291- })
292263const toggleImageExpanded = () => {
293264 imageExpanded .value = ! unref (imageExpanded )
294265}
0 commit comments