Skip to content

Commit ff2ef8d

Browse files
JuliaKirschenheuterShGKme
authored andcommitted
Replace ActionLink with ActionButton on sharing tab
Signed-off-by: julia.kirschenheuter <julia.kirschenheuter@nextcloud.com> So-authored-by: Grigorii K. Shartsev <me@shgk.me>
1 parent 8c24a32 commit ff2ef8d

File tree

9 files changed

+13
-18
lines changed

9 files changed

+13
-18
lines changed

apps/files_sharing/src/components/SharingEntryInternal.vue

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,27 +8,25 @@
88
<div class="avatar-external icon-external-white" />
99
</template>
1010

11-
<NcActionLink :href="internalLink"
11+
<NcActionButton :title="copyLinkTooltip"
1212
:aria-label="copyLinkTooltip"
13-
:title="copyLinkTooltip"
14-
target="_blank"
1513
:icon="copied && copySuccess ? 'icon-checkmark-color' : 'icon-clippy'"
16-
@click.prevent="copyLink" />
14+
@click="copyLink" />
1715
</SharingEntrySimple>
1816
</ul>
1917
</template>
2018

2119
<script>
2220
import { generateUrl } from '@nextcloud/router'
2321
import { showSuccess } from '@nextcloud/dialogs'
24-
import NcActionLink from '@nextcloud/vue/dist/Components/NcActionLink.js'
22+
import NcActionButton from '@nextcloud/vue/dist/Components/NcActionButton.js'
2523
import SharingEntrySimple from './SharingEntrySimple.vue'
2624
2725
export default {
2826
name: 'SharingEntryInternal',
2927
3028
components: {
31-
NcActionLink,
29+
NcActionButton,
3230
SharingEntrySimple,
3331
},
3432
@@ -85,7 +83,6 @@ export default {
8583
try {
8684
await navigator.clipboard.writeText(this.internalLink)
8785
showSuccess(t('files_sharing', 'Link copied'))
88-
// focus and show the tooltip (note: cannot set ref on NcActionLink)
8986
this.$refs.shareEntrySimple.$refs.actionsComponent.$el.focus()
9087
this.copySuccess = true
9188
this.copied = true

apps/files_sharing/src/components/SharingEntryLink.vue

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,10 @@
4343

4444
<!-- clipboard -->
4545
<NcActions v-if="share && !isEmailShareType && share.token" ref="copyButton" class="sharing-entry__copy">
46-
<NcActionLink :href="shareLink"
47-
target="_blank"
48-
:title="copyLinkTooltip"
46+
<NcActionButton :title="copyLinkTooltip"
4947
:aria-label="copyLinkTooltip"
5048
:icon="copied && copySuccess ? 'icon-checkmark-color' : 'icon-clippy'"
51-
@click.stop.prevent="copyLink" />
49+
@click.prevent="copyLink" />
5250
</NcActions>
5351
</div>
5452

dist/486-486.js

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/486-486.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/4997-4997.js

Lines changed: 0 additions & 3 deletions
This file was deleted.

dist/4997-4997.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

dist/files_sharing-files_sharing_tab.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/files_sharing-files_sharing_tab.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)