Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[full-ci] Wording: Rename Quicklink to link #8898

Merged
merged 8 commits into from
Apr 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions changelog/unreleased/enhancement-rename-quicklink-to-link
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Enhancement: Rename "Quicklink" to "link"

We've renamed "Quicklink" to "link" in the UI

https://github.com/owncloud/web/pull/8898
https://github.com/owncloud/web/issues/7891
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div class="oc-mb-s oc-width-1-1 oc-mb-l">
<h4
class="oc-text-truncate oc-text-normal oc-files-file-link-name oc-my-rm"
v-text="$gettext('Quick link')"
v-text="$gettext('Link')"
/>
<div class="oc-flex oc-flex-middle oc-flex-between oc-width-1-1 oc-p-xs link-name-container">
<div class="oc-flex oc-flex-middle oc-text-truncate">
Expand All @@ -13,10 +13,11 @@
/>
</div>
<oc-button
v-oc-tooltip="$gettext('Create quick link')"
class="oc-ml-s"
size="small"
:aria-label="$gettext('Create quick link')"
v-oc-tooltip="$gettext('Create link')"
appearance="raw"
:aria-label="$gettext('Create link')"
@click="createQuickLink"
>
<span v-text="$gettext('Create link')" />
Expand Down Expand Up @@ -70,7 +71,7 @@ export default defineComponent({
: unref(capabilitiesRoleName) || linkRoleViewerFolder.name
const emitData = {
link: {
name: $gettext('Quicklink'),
name: $gettext('Link'),
permissions: LinkShareRoles.getByName(
roleName,
unref(resource).isFolder,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export default defineComponent({
copy(props.link.url)
store.dispatch('showMessage', {
title: props.link.quicklink
? $gettext('The quicklink has been copied to your clipboard.')
? $gettext('The link has been copied to your clipboard.')
: $gettext('The link "%{linkName}" has been copied to your clipboard.', {
linkName: props.link.name
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export const useFileActionsCreateQuickLink = ({ store }: { store?: Store<any> }
name: 'create-quicklink',
icon: quickActions.quicklink.icon,
iconFillType: quickActions.quicklink.iconFillType,
label: () => $gettext('Copy quicklink'),
label: () => $gettext('Copy link'),
handler,
isEnabled: ({ resources }) => {
if (resources.length !== 1) {
Expand Down
9 changes: 0 additions & 9 deletions packages/web-app-files/src/helpers/contextualHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,6 @@ export const shareViaLinkHelp = (options: ContextualHelperOptions) =>
text: $gettext(
'No login required. Everyone with the link can access. If you share this link with people from the list "Invited people", they need to login so that their individual assigned permissions can take effect. If they are not logged-in, the permissions of the link take effect.'
)
},
{
text: $gettext('Quicklink'),
headline: true
},
{
text: $gettext(
'The quicklink is the default link that is copied when you select "Get link” from the context menu.'
)
}
],
readMoreLink: 'https://doc.owncloud.com/webui/next/owncloud_web/web_for_users.html#sharing'
Expand Down
4 changes: 2 additions & 2 deletions packages/web-app-files/src/helpers/share/link.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const createQuicklink = async (args: CreateQuicklink): Promise<Share> =>
alias
).bitmask(allowResharing)
const params: { [key: string]: unknown } = {
name: $gettext('Quicklink'),
name: $gettext('Link'),
permissions: permissions.toString(),
quicklink: true
}
Expand Down Expand Up @@ -79,7 +79,7 @@ export const createQuicklink = async (args: CreateQuicklink): Promise<Share> =>
copy(link.url)

await store.dispatch('showMessage', {
title: $gettext('The quicklink has been copied to your clipboard.')
title: $gettext('The link has been copied to your clipboard.')
})

return link
Expand Down
2 changes: 1 addition & 1 deletion packages/web-app-files/src/quickActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export default {
},
quicklink: {
id: 'quicklink',
label: ($gettext) => $gettext('Copy quicklink'),
label: ($gettext) => $gettext('Copy link'),
icon: 'link',
iconFillType: undefined,
handler: async ({ ability, clientService, item, language, store }: QuickLinkContext) => {
Expand Down
2 changes: 1 addition & 1 deletion packages/web-app-files/src/views/trash/Overview.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@
<oc-button
class="oc-display-block"
appearance="raw"
v-text="getSpaceName(item)"
v-bind="getSpaceAttributes(item)"
v-text="getSpaceName(item)"
/>
</template>
<template #footer>
Expand Down
8 changes: 4 additions & 4 deletions packages/web-app-files/tests/unit/helpers/share/link.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ describe('createQuicklink', () => {
path: mockResource.path,
client: clientService.owncloudSdk,
params: {
name: 'Quicklink',
name: 'Link',
permissions: '1', // viewer
quicklink: true,
password: args.password,
Expand All @@ -82,7 +82,7 @@ describe('createQuicklink', () => {
})

expect(mockStore.dispatch).toHaveBeenCalledWith('showMessage', {
title: 'The quicklink has been copied to your clipboard.'
title: 'The link has been copied to your clipboard.'
})
})

Expand Down Expand Up @@ -112,7 +112,7 @@ describe('createQuicklink', () => {
path: mockResource.path,
client: clientService.owncloudSdk,
params: {
name: 'Quicklink',
name: 'Link',
permissions: role === 'viewer' ? '1' : '0',
quicklink: true,
expireDate: DateTime.now().plus({ days: 5 }).endOf('day').toISO(),
Expand All @@ -122,7 +122,7 @@ describe('createQuicklink', () => {
})

expect(mockStore.dispatch).toHaveBeenCalledWith('showMessage', {
title: 'The quicklink has been copied to your clipboard.'
title: 'The link has been copied to your clipboard.'
})
}
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ Feature: Create public link shares
| uid_owner | Alice |
| permissions | read |
| path | /simple-folder |
| name | Quicklink |
| name | Link |
And the following success message should be displayed on the webUI
Comment on lines +175 to 176
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

due to this change the test is failing with latest ocis #8929. The then step asserts from an api call. So if I understand this correctly. The naming from QuickLink to link is just on the UI level and API stills responds with Quicklink?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that was just a UI change.

"""
The quicklink has been copied to your clipboard.
The link has been copied to your clipboard.
"""

# This test is skipped in OCIS as the sharing jail has been implemented
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/cucumber/features/smoke/link.feature
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ Feature: link
And "Alice" logs in
And "Alice" opens the "files" app
When "Alice" copies quick link of the resource "folderPublic" from the context menu
And "Anonymous" opens the public link "Quicklink"
And "Anonymous" opens the public link "Link"
And "Anonymous" downloads the following public link resources using the sidebar panel
| resource | type |
| lorem.txt | file |
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/support/objects/app-files/share/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ export const hasPermissionToShare = async (
export const copyQuickLink = async (args: copyLinkArgs): Promise<string> => {
const { page, resource, via } = args
let url = ''
const linkName = 'Quicklink'
const linkName = 'Link'

if (via === 'CONTEXT_MENU') {
await clickActionInContextMenu({ page, resource }, 'create-quicklink')
Expand Down