Skip to content

Commit d7aa0d1

Browse files
authored
Merge pull request #6312 from nextcloud/backport/6291/stable30
[stable30] fix: Correctly set "new"-menu entry for folder description
2 parents f673048 + 6ec26c1 commit d7aa0d1

2 files changed

Lines changed: 8 additions & 9 deletions

File tree

.eslintrc.cjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
module.exports = {
77
root: true,
88
extends: [
9-
'@nextcloud',
109
'@nextcloud/eslint-config/typescript',
1110
],
1211
rules: {
1312
'@typescript-eslint/no-unused-vars': ['off'],
14-
}
13+
'import/no-unresolved': [1, { ignore: ['\\.svg\\?raw$'] }],
14+
},
1515
}

src/helpers/files.js

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,20 @@
33
* SPDX-License-Identifier: AGPL-3.0-or-later
44
*/
55

6+
import { getCurrentUser } from '@nextcloud/auth'
7+
import { showSuccess, showError } from '@nextcloud/dialogs'
68
import { emit } from '@nextcloud/event-bus'
79
import { Header, addNewFileMenuEntry, Permission, File, NewMenuEntryCategory } from '@nextcloud/files'
8-
import { imagePath } from '@nextcloud/router'
910
import { loadState } from '@nextcloud/initial-state'
11+
import { imagePath } from '@nextcloud/router'
12+
import { dirname } from 'path'
1013

1114
import { getSharingToken } from './token.js'
1215
import { openMimetypes } from './mime.js'
1316
import store from '../store/index.js'
14-
import { getCurrentUser } from '@nextcloud/auth'
15-
import { showSuccess, showError } from '@nextcloud/dialogs'
1617
import axios from '@nextcloud/axios'
17-
import { dirname } from 'path'
1818

19-
import TextSvg from '@mdi/svg/svg/text.svg'
19+
import TextSvg from '@mdi/svg/svg/text.svg?raw'
2020

2121
const FILE_ACTION_IDENTIFIER = 'Edit with text app'
2222

@@ -118,8 +118,7 @@ export const addMenuRichWorkspace = () => {
118118
addNewFileMenuEntry({
119119
id: 'rich-workspace-init',
120120
displayName: t('text', 'Add folder description'),
121-
// FIXME Move back to other once https://github.com/nextcloud-libraries/nextcloud-upload/pull/1269 is available in server
122-
category: NewMenuEntryCategory.CreateNew,
121+
category: NewMenuEntryCategory.Other,
123122
enabled(context) {
124123
if (Number(context.attributes['rich-workspace-file'])) {
125124
return false

0 commit comments

Comments
 (0)