1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-18 09:13:33 +00:00

finalize send list container

This commit is contained in:
jaasen-livefront
2024-07-19 10:24:08 -07:00
parent a18d509409
commit 0d726fd8f0
5 changed files with 14 additions and 28 deletions

View File

@@ -9,7 +9,7 @@
<bit-item *ngFor="let send of sends">
<button
bit-item-content
[appA11yTitle]="'editSendTitle' | i18n: (send.name | i18n)"
appA11yTitle="{{ 'edit' | i18n }} - {{ send.name }}"
appStopClick
type="button"
class="tw-pb-1"
@@ -32,7 +32,8 @@
<bit-item-action>
<button
type="button"
appA11yTitle="{{ 'copySendTitle' | i18n }}: {{ send.name | i18n }}"
(click)="copySendLink(send)"
appA11yTitle="{{ 'copyLink' | i18n }} - {{ send.name }}"
>
<i class="bwi tw-text-lg bwi-clone"></i>
</button>
@@ -40,7 +41,8 @@
<bit-item-action>
<button
type="button"
appA11yTitle="{{ 'deleteSendTitle' | i18n }}: {{ send.name | i18n }}"
(click)="deleteSend(send)"
appA11yTitle="{{ 'delete' | i18n }} - {{ send.name }}"
>
<i class="bwi tw-text-lg bwi-trash"></i>
</button>

View File

@@ -69,6 +69,8 @@ export class SendListItemsContainerComponent {
return false;
}
await this.sendApiService.delete(s.id);
try {
this.toastService.showToast({
variant: "success",
@@ -80,7 +82,7 @@ export class SendListItemsContainerComponent {
}
}
async copy(s: SendView) {
async copySendLink(s: SendView) {
const env = await firstValueFrom(this.environmentService.environment$);
const link = env.getSendUrl() + s.accessId + "/" + s.urlB64Key;
this.platformUtilsService.copyToClipboard(link);