Skip to content

Commit 0bebeda

Browse files
fix: showing RichWorkspace for non-English language
Signed-off-by: Luka Trovic <luka@nextcloud.com>
1 parent 1ae0a84 commit 0bebeda

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/views/RichWorkspace.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,12 @@ import { subscribe, unsubscribe } from '@nextcloud/event-bus'
3232
import { getSharingToken, isPublicShare } from '@nextcloud/sharing/public'
3333
import getEditorInstance from '../components/Editor.singleton.js'
3434
import RichTextReader from '../components/RichTextReader.vue'
35+
import { loadState } from '@nextcloud/initial-state'
3536
3637
const IS_PUBLIC = isPublicShare()
3738
const WORKSPACE_URL = generateOcsUrl('apps/text' + (IS_PUBLIC ? '/public' : '') + '/workspace', 2)
38-
const SUPPORTED_STATIC_FILENAMES = ['Readme.md', 'README.md', 'readme.md']
39+
const descriptionFile = t('text', 'Readme') + '.' + loadState('text', 'default_file_extension')
40+
const SUPPORTED_STATIC_FILENAMES = [descriptionFile, 'Readme.md', 'README.md', 'readme.md']
3941
4042
export default {
4143
name: 'RichWorkspace',

0 commit comments

Comments
 (0)