Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[stable32] chore: Update@nextcloud/dialogs to v7.0.0#57129

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
backportbot wants to merge9 commits intostable32
base:stable32
Choose a base branch
Loading
frombackport/55726/stable32
Open
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions.github/workflows/cypress.yml
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -102,8 +102,8 @@ jobs:
matrix:
# Run multiple copies of the current job in parallel
# Please increase the number or runners as your tests suite grows (0 based index for e2e tests)
containers:['component', 'setup', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
# Hack as strategy.job-total includes thecomponent and GitHub does not allow math expressions
containers:['setup', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
# Hack as strategy.job-total includes the"setup" and GitHub does not allow math expressions
# Always align this number with the total of e2e runners (max. index + 1)
total-containers:[10]

Expand Down
1 change: 1 addition & 0 deletions__tests__/setup-global.js
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -2,6 +2,7 @@
* SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: CC0-1.0
*/

exportfunctionsetup(){
process.env.TZ='UTC'
}
1 change: 1 addition & 0 deletions__tests__/setup-testing-library.js
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -2,5 +2,6 @@
* SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: CC0-1.0
*/

import'@testing-library/jest-dom/vitest'
import'core-js/stable/index.js'
15 changes: 6 additions & 9 deletionsapps/federatedfilesharing/src/components/AdminSettings.vue
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -65,11 +65,11 @@
</template>

<script>
import axios from '@nextcloud/axios'
import { DialogBuilder, showError } from '@nextcloud/dialogs'
import { loadState } from '@nextcloud/initial-state'
import { DialogBuilder, DialogSeverity, showError } from '@nextcloud/dialogs'
import { generateOcsUrl } from '@nextcloud/router'
import { confirmPassword } from '@nextcloud/password-confirmation'
import axios from '@nextcloud/axios'
import NcCheckboxRadioSwitch from '@nextcloud/vue/components/NcCheckboxRadioSwitch'
import NcSettingsSection from '@nextcloud/vue/components/NcSettingsSection'

Expand DownExpand Up@@ -114,10 +114,8 @@ export default {

const dialog = new DialogBuilder(t('federatedfilesharing', 'Confirm data upload to lookup server'))
await dialog
.setSeverity(DialogSeverity.Warning)
.setText(
t('federatedfilesharing', 'When enabled, all account properties (e.g. email address) with scope visibility set to "published", will be automatically synced and transmitted to an external system and made available in a public, global address book.'),
)
.setSeverity('warning')
.setText(t('federatedfilesharing', 'When enabled, all account properties (e.g. email address) with scope visibility set to "published", will be automatically synced and transmitted to an external system and made available in a public, global address book.'))
.addButton({
callback: () => this.setLookupServerUploadEnabled(false),
label: t('federatedfilesharing', 'Disable upload'),
Expand DownExpand Up@@ -147,9 +145,8 @@ export default {

const dialog = new DialogBuilder(t('federatedfilesharing', 'Confirm querying lookup server'))
await dialog
.setSeverity(DialogSeverity.Warning)
.setText(
t('federatedfilesharing', 'When enabled, the search input when creating shares will be sent to an external system that provides a public and global address book.')
.setSeverity('warning')
.setText(t('federatedfilesharing', 'When enabled, the search input when creating shares will be sent to an external system that provides a public and global address book.')
+ t('federatedfilesharing', 'This is used to retrieve the federated cloud ID to make federated sharing easier.')
+ t('federatedfilesharing', 'Moreover, email addresses of users might be sent to that system in order to verify them.'),
)
Expand Down
123 changes: 0 additions & 123 deletionsapps/federatedfilesharing/src/components/RemoteShareDialog.cy.ts
View file
Open in desktop

This file was deleted.

115 changes: 115 additions & 0 deletionsapps/federatedfilesharing/src/components/RemoteShareDialog.spec.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
/**
* SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

import { cleanup, fireEvent, render } from '@testing-library/vue'
import { beforeEach, describe, expect, it, vi } from 'vitest'
import RemoteShareDialog from './RemoteShareDialog.vue'

describe('RemoteShareDialog', () => {
beforeEach(cleanup)

it('can be mounted', async () => {
const component = render(RemoteShareDialog, {
props: {
owner: 'user123',
name: 'my-photos',
remote: 'nextcloud.local',
passwordRequired: false,
},
})

await expect(component.findByRole('dialog', { name: 'Remote share' })).resolves.not.toThrow()
expect(component.getByRole('dialog').innerText).toContain(/my-photos from user123@nextcloud.local/)
await expect(component.findByRole('button', { name: 'Cancel' })).resolves.not.toThrow()
await expect(component.findByRole('button', { name: /Add remote share/ })).resolves.not.toThrow()
})

it('does not show password input if not enabled', async () => {
const component = render(RemoteShareDialog, {
props: {
owner: 'user123',
name: 'my-photos',
remote: 'nextcloud.local',
passwordRequired: false,
},
})

await expect(component.findByLabelText('Remote share password')).rejects.toThrow()
})

it('emits true when accepted', () => {
const onClose = vi.fn()

const component = render(RemoteShareDialog, {
listeners: {
close: onClose,
},
props: {
owner: 'user123',
name: 'my-photos',
remote: 'nextcloud.local',
passwordRequired: false,
},
})

component.getByRole('button', { name: 'Cancel' }).click()
expect(onClose).toHaveBeenCalledWith(false)
})

it('show password input if needed', async () => {
const component = render(RemoteShareDialog, {
props: {
owner: 'admin',
name: 'secret-data',
remote: 'nextcloud.local',
passwordRequired: true,
},
})

await expect(component.findByLabelText('Remote share password')).resolves.not.toThrow()
})

it('emits the submitted password', async () => {
const onClose = vi.fn()

const component = render(RemoteShareDialog, {
listeners: {
close: onClose,
},
props: {
owner: 'admin',
name: 'secret-data',
remote: 'nextcloud.local',
passwordRequired: true,
},
})

const input = component.getByLabelText('Remote share password')
await fireEvent.update(input, 'my password')
component.getByRole('button', { name: 'Add remote share' }).click()
expect(onClose).toHaveBeenCalledWith(true, 'my password')
})

it('emits no password if cancelled', async () => {
const onClose = vi.fn()

const component = render(RemoteShareDialog, {
listeners: {
close: onClose,
},
props: {
owner: 'admin',
name: 'secret-data',
remote: 'nextcloud.local',
passwordRequired: true,
},
})

const input = component.getByLabelText('Remote share password')
await fireEvent.update(input, 'my password')
component.getByRole('button', { name: 'Cancel' }).click()
expect(onClose).toHaveBeenCalledWith(false)
})
})
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -35,8 +35,8 @@ const buttons = computed(() => [
},
{
label:t('federatedfilesharing','Add remote share'),
nativeType:props.passwordRequired?'submit':undefined,
type:'primary',
type:props.passwordRequired?'submit':undefined,
variant:'primary',
callback: ()=>emit('close',true,password.value),
},
])
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -3,7 +3,7 @@
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

import { spawnDialog } from '@nextcloud/dialogs'
import { spawnDialog } from '@nextcloud/vue/functions/dialog'
import RemoteShareDialog from '../components/RemoteShareDialog.vue'

/**
Expand Down
56 changes: 0 additions & 56 deletionsapps/files/src/composables/useFileListWidth.cy.ts
View file
Open in desktop

This file was deleted.

Loading
Loading

[8]ページ先頭

©2009-2025 Movatter.jp