diff options
Diffstat (limited to 'apps/federatedfilesharing/src')
-rw-r--r-- | apps/federatedfilesharing/src/components/PersonalSettings.vue | 18 | ||||
-rw-r--r-- | apps/federatedfilesharing/src/external.js | 3 |
2 files changed, 16 insertions, 5 deletions
diff --git a/apps/federatedfilesharing/src/components/PersonalSettings.vue b/apps/federatedfilesharing/src/components/PersonalSettings.vue index 9b402a0ac31..7906d4c31d8 100644 --- a/apps/federatedfilesharing/src/components/PersonalSettings.vue +++ b/apps/federatedfilesharing/src/components/PersonalSettings.vue @@ -23,25 +23,31 @@ <p class="social-button"> {{ t('federatedfilesharing', 'Share it so your friends can share files with you:') }}<br> - <NcButton @click="goTo(shareFacebookUrl)"> + <NcButton :href="shareFacebookUrl"> {{ t('federatedfilesharing', 'Facebook') }} <template #icon> <img class="social-button__icon social-button__icon--bright" :src="urlFacebookIcon"> </template> </NcButton> <NcButton :aria-label="t('federatedfilesharing', 'X (formerly Twitter)')" - @click="goTo(shareXUrl)"> + :href="shareXUrl"> {{ t('federatedfilesharing', 'formerly Twitter') }} <template #icon> <img class="social-button__icon" :src="urlXIcon"> </template> </NcButton> - <NcButton @click="goTo(shareMastodonUrl)"> + <NcButton :href="shareMastodonUrl"> {{ t('federatedfilesharing', 'Mastodon') }} <template #icon> <img class="social-button__icon" :src="urlMastodonIcon"> </template> </NcButton> + <NcButton :href="shareBlueSkyUrl"> + {{ t('federatedfilesharing', 'Bluesky') }} + <template #icon> + <img class="social-button__icon" :src="urlBlueSkyIcon"> + </template> + </NcButton> <NcButton class="social-button__website-button" @click="showHtml = !showHtml"> <template #icon> @@ -101,6 +107,7 @@ export default { reference: loadState<string>('federatedfilesharing', 'reference'), urlFacebookIcon: imagePath('core', 'facebook'), urlMastodonIcon: imagePath('core', 'mastodon'), + urlBlueSkyIcon: imagePath('core', 'bluesky'), urlXIcon: imagePath('core', 'x'), } }, @@ -130,6 +137,9 @@ export default { shareFacebookUrl() { return `https://www.facebook.com/sharer/sharer.php?u=${encodeURIComponent(this.reference)}` }, + shareBlueSkyUrl() { + return `https://bsky.app/intent/compose?text=${encodeURIComponent(this.messageWithURL)}` + }, logoPathAbsolute() { return window.location.protocol + '//' + window.location.host + this.logoPath }, @@ -176,7 +186,7 @@ export default { .social-button { margin-top: 0.5rem; - button { + button, a { display: inline-flex; margin-inline-start: 0.5rem; margin-top: 1rem; diff --git a/apps/federatedfilesharing/src/external.js b/apps/federatedfilesharing/src/external.js index 68cc958b7b5..3581a24e95a 100644 --- a/apps/federatedfilesharing/src/external.js +++ b/apps/federatedfilesharing/src/external.js @@ -35,7 +35,8 @@ window.OCA.Sharing.showAddExternalDialog = function(share, passwordProtected, ca .replace(/\/$/, '') // remove trailing slash showRemoteShareDialog(name, owner, remote, passwordProtected) - .then((result, password) => callback(result, { ...share, password })) + // eslint-disable-next-line n/no-callback-literal + .then((password) => callback(true, { ...share, password })) // eslint-disable-next-line n/no-callback-literal .catch(() => callback(false, share)) } |