Add a new context menu action to copy link

This commit is contained in:
Thomas Ricouard 2023-02-22 18:49:32 +01:00
parent c8c7f2d29d
commit 4b40678931
18 changed files with 24 additions and 0 deletions

View file

@ -378,6 +378,7 @@
"status.action.boost" = "Павышэнне"; "status.action.boost" = "Павышэнне";
"status.action.boost-to-followers" = "Павысіць для падпісчыкаў"; "status.action.boost-to-followers" = "Павысіць для падпісчыкаў";
"status.action.copy-text" = "Капіяваць тэкст"; "status.action.copy-text" = "Капіяваць тэкст";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Выдаліць"; "status.action.delete" = "Выдаліць";
"status.action.delete.confirm.title" = "Пацвердзіць"; "status.action.delete.confirm.title" = "Пацвердзіць";
"status.action.delete.confirm.message" = "вы ўпэўнены, што жадаеце выдаліць гэты допіс?"; "status.action.delete.confirm.message" = "вы ўпэўнены, што жадаеце выдаліць гэты допіс?";

View file

@ -372,6 +372,7 @@
"status.action.boost" = "Impulsa"; "status.action.boost" = "Impulsa";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Copia el text"; "status.action.copy-text" = "Copia el text";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Elimina"; "status.action.delete" = "Elimina";
"status.action.delete.confirm.title" = "Confirm"; "status.action.delete.confirm.title" = "Confirm";
"status.action.delete.confirm.message" = "are you sure you want to delete this post?"; "status.action.delete.confirm.message" = "are you sure you want to delete this post?";

View file

@ -369,6 +369,7 @@
"status.action.boost" = "Boosten"; "status.action.boost" = "Boosten";
"status.action.boost-to-followers" = "An Follower boosten"; "status.action.boost-to-followers" = "An Follower boosten";
"status.action.copy-text" = "Text kopieren"; "status.action.copy-text" = "Text kopieren";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Löschen"; "status.action.delete" = "Löschen";
"status.action.delete.confirm.title" = "Bestätigen"; "status.action.delete.confirm.title" = "Bestätigen";
"status.action.delete.confirm.message" = "Bist du dir sicher, dass du diesen Beitrag löschen möchtest?"; "status.action.delete.confirm.message" = "Bist du dir sicher, dass du diesen Beitrag löschen möchtest?";

View file

@ -375,6 +375,7 @@
"status.action.boost" = "Boost"; "status.action.boost" = "Boost";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Copy Text"; "status.action.copy-text" = "Copy Text";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Delete"; "status.action.delete" = "Delete";
"status.action.delete.confirm.title" = "Confirm"; "status.action.delete.confirm.title" = "Confirm";
"status.action.delete.confirm.message" = "are you sure you want to delete this post?"; "status.action.delete.confirm.message" = "are you sure you want to delete this post?";

View file

@ -374,6 +374,7 @@
"status.action.boost" = "Boost"; "status.action.boost" = "Boost";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Copy Text"; "status.action.copy-text" = "Copy Text";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Delete"; "status.action.delete" = "Delete";
"status.action.delete.confirm.title" = "Confirm"; "status.action.delete.confirm.title" = "Confirm";
"status.action.delete.confirm.message" = "are you sure you want to delete this post?"; "status.action.delete.confirm.message" = "are you sure you want to delete this post?";

View file

@ -374,6 +374,7 @@
"status.action.boost" = "Retootear"; "status.action.boost" = "Retootear";
"status.action.boost-to-followers" = "Retootear a tus seguidores"; "status.action.boost-to-followers" = "Retootear a tus seguidores";
"status.action.copy-text" = "Copiar texto"; "status.action.copy-text" = "Copiar texto";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Borrar"; "status.action.delete" = "Borrar";
"status.action.delete.confirm.title" = "Confirmar"; "status.action.delete.confirm.title" = "Confirmar";
"status.action.delete.confirm.message" = "¿Estás seguro de querer borrar esta publicación?"; "status.action.delete.confirm.message" = "¿Estás seguro de querer borrar esta publicación?";

View file

@ -367,6 +367,7 @@
"status.action.boost" = "Bultzatu"; "status.action.boost" = "Bultzatu";
"status.action.boost-to-followers" = "Bultzatu jarraitzaileek ikus dezaten"; "status.action.boost-to-followers" = "Bultzatu jarraitzaileek ikus dezaten";
"status.action.copy-text" = "Kopiatu testua"; "status.action.copy-text" = "Kopiatu testua";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Ezabatu"; "status.action.delete" = "Ezabatu";
"status.action.delete.confirm.title" = "Baieztatu"; "status.action.delete.confirm.title" = "Baieztatu";
"status.action.delete.confirm.message" = "Ziur zaude bidalketa ezabatu nahi duzula?"; "status.action.delete.confirm.message" = "Ziur zaude bidalketa ezabatu nahi duzula?";

View file

@ -369,6 +369,7 @@
"status.action.boost" = "Promouvoir"; "status.action.boost" = "Promouvoir";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Copier le texte"; "status.action.copy-text" = "Copier le texte";
"status.action.copy-link" = "Copier le lien";
"status.action.delete" = "Supprimer"; "status.action.delete" = "Supprimer";
"status.action.delete.confirm.title" = "Confirmer"; "status.action.delete.confirm.title" = "Confirmer";
"status.action.delete.confirm.message" = "êtes vous sûr de vouloir supprimer ce message ?"; "status.action.delete.confirm.message" = "êtes vous sûr de vouloir supprimer ce message ?";

View file

@ -374,6 +374,7 @@
"status.action.boost" = "Condividi"; "status.action.boost" = "Condividi";
"status.action.boost-to-followers" = "Condividi con i follower"; "status.action.boost-to-followers" = "Condividi con i follower";
"status.action.copy-text" = "Copia il testo"; "status.action.copy-text" = "Copia il testo";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Elimina"; "status.action.delete" = "Elimina";
"status.action.delete.confirm.title" = "Richiesta di conferma"; "status.action.delete.confirm.title" = "Richiesta di conferma";
"status.action.delete.confirm.message" = "Sei sicuro di voler cancellare questo post?"; "status.action.delete.confirm.message" = "Sei sicuro di voler cancellare questo post?";

View file

@ -373,6 +373,7 @@
"status.action.boost" = "ブースト"; "status.action.boost" = "ブースト";
"status.action.boost-to-followers" = "フォロワーにブースト"; "status.action.boost-to-followers" = "フォロワーにブースト";
"status.action.copy-text" = "テキストをコピー"; "status.action.copy-text" = "テキストをコピー";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "削除"; "status.action.delete" = "削除";
"status.action.delete.confirm.title" = "確認"; "status.action.delete.confirm.title" = "確認";
"status.action.delete.confirm.message" = "本当に投稿を削除しますか?"; "status.action.delete.confirm.message" = "本当に投稿を削除しますか?";

View file

@ -375,6 +375,7 @@
"status.action.boost" = "부스트"; "status.action.boost" = "부스트";
"status.action.boost-to-followers" = "팔로워에게만 부스트"; "status.action.boost-to-followers" = "팔로워에게만 부스트";
"status.action.copy-text" = "복사"; "status.action.copy-text" = "복사";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "삭제"; "status.action.delete" = "삭제";
"status.action.delete.confirm.title" = "삭제 확인"; "status.action.delete.confirm.title" = "삭제 확인";
"status.action.delete.confirm.message" = "이 글을 정말 삭제하시겠습니까?"; "status.action.delete.confirm.message" = "이 글을 정말 삭제하시겠습니까?";

View file

@ -373,6 +373,7 @@
"status.action.boost" = "Forsterk"; "status.action.boost" = "Forsterk";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Kopier tekst"; "status.action.copy-text" = "Kopier tekst";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Slett"; "status.action.delete" = "Slett";
"status.action.delete.confirm.title" = "Confirm"; "status.action.delete.confirm.title" = "Confirm";
"status.action.delete.confirm.message" = "are you sure you want to delete this post?"; "status.action.delete.confirm.message" = "are you sure you want to delete this post?";

View file

@ -368,6 +368,7 @@
"status.action.boost" = "Boost"; "status.action.boost" = "Boost";
"status.action.boost-to-followers" = "Boost aan volgers"; "status.action.boost-to-followers" = "Boost aan volgers";
"status.action.copy-text" = "Kopieer tekst"; "status.action.copy-text" = "Kopieer tekst";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Verwijder"; "status.action.delete" = "Verwijder";
"status.action.delete.confirm.title" = "Bevestigen"; "status.action.delete.confirm.title" = "Bevestigen";
"status.action.delete.confirm.message" = "Weet je zeker dat je deze post wilt verwijderen?"; "status.action.delete.confirm.message" = "Weet je zeker dat je deze post wilt verwijderen?";

View file

@ -369,6 +369,7 @@
"status.action.boost" = "Podbij"; "status.action.boost" = "Podbij";
"status.action.boost-to-followers" = "Podbij do obserwujących"; "status.action.boost-to-followers" = "Podbij do obserwujących";
"status.action.copy-text" = "Kopiuj tekst"; "status.action.copy-text" = "Kopiuj tekst";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Usuń"; "status.action.delete" = "Usuń";
"status.action.delete.confirm.title" = "Potwierdź"; "status.action.delete.confirm.title" = "Potwierdź";
"status.action.delete.confirm.message" = "czy na pewno chcesz usunąć ten post?"; "status.action.delete.confirm.message" = "czy na pewno chcesz usunąć ten post?";

View file

@ -373,6 +373,7 @@
"status.action.boost" = "Boost"; "status.action.boost" = "Boost";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Copiar Texto"; "status.action.copy-text" = "Copiar Texto";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Deletar"; "status.action.delete" = "Deletar";
"status.action.delete.confirm.title" = "Confirm"; "status.action.delete.confirm.title" = "Confirm";
"status.action.delete.confirm.message" = "are you sure you want to delete this post?"; "status.action.delete.confirm.message" = "are you sure you want to delete this post?";

View file

@ -369,6 +369,7 @@
"status.action.boost" = "Yükselt"; "status.action.boost" = "Yükselt";
"status.action.boost-to-followers" = "Boost to Followers"; "status.action.boost-to-followers" = "Boost to Followers";
"status.action.copy-text" = "Yazıyı Kopyala"; "status.action.copy-text" = "Yazıyı Kopyala";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "Sil"; "status.action.delete" = "Sil";
"status.action.delete.confirm.title" = "Confirm"; "status.action.delete.confirm.title" = "Confirm";
"status.action.delete.confirm.message" = "are you sure you want to delete this post?"; "status.action.delete.confirm.message" = "are you sure you want to delete this post?";

View file

@ -372,6 +372,7 @@
"status.action.boost" = "转发"; "status.action.boost" = "转发";
"status.action.boost-to-followers" = "转发给粉丝"; "status.action.boost-to-followers" = "转发给粉丝";
"status.action.copy-text" = "拷贝文本"; "status.action.copy-text" = "拷贝文本";
"status.action.copy-link" = "Copy Link";
"status.action.delete" = "删除"; "status.action.delete" = "删除";
"status.action.delete.confirm.title" = "确认删除"; "status.action.delete.confirm.title" = "确认删除";
"status.action.delete.confirm.message" = "你确认要删除此嘟文吗?"; "status.action.delete.confirm.message" = "你确认要删除此嘟文吗?";

View file

@ -107,6 +107,7 @@ struct StatusRowContextMenu: View {
.foregroundColor(Theme.shared.labelColor) .foregroundColor(Theme.shared.labelColor)
.background(Theme.shared.primaryBackgroundColor) .background(Theme.shared.primaryBackgroundColor)
.frame(width: sceneDelegate.windowWidth - 12) .frame(width: sceneDelegate.windowWidth - 12)
.tint(Theme.shared.tintColor)
let renderer = ImageRenderer(content: view) let renderer = ImageRenderer(content: view)
renderer.scale = displayScale renderer.scale = displayScale
renderer.isOpaque = false renderer.isOpaque = false
@ -131,6 +132,12 @@ struct StatusRowContextMenu: View {
Label("status.action.copy-text", systemImage: "doc.on.doc") Label("status.action.copy-text", systemImage: "doc.on.doc")
} }
Button {
UIPasteboard.general.string = viewModel.status.reblog?.url ?? viewModel.status.url
} label: {
Label("status.action.copy-link", systemImage: "link")
}
if let lang = preferences.serverPreferences?.postLanguage ?? Locale.current.language.languageCode?.identifier if let lang = preferences.serverPreferences?.postLanguage ?? Locale.current.language.languageCode?.identifier
{ {
Button { Button {