1
0
mirror of https://github.com/bitwarden/browser synced 2026-02-21 11:54:02 +00:00

Adding enums for additional event logs for secrets

This commit is contained in:
cd-bitwarden
2025-06-20 16:29:30 -04:00
parent 1ede507f3d
commit fb2d255105
3 changed files with 43 additions and 1 deletions

View File

@@ -470,6 +470,18 @@ export class EventService {
msg = this.i18nService.t("accessedSecret", this.formatSecretId(ev));
humanReadableMsg = this.i18nService.t("accessedSecret", this.getShortId(ev.secretId));
break;
case EventType.Secret_Created:
msg = this.i18nService.t("createdSecret", this.formatSecretId(ev));
humanReadableMsg = this.i18nService.t("createdSecret", this.getShortId(ev.secretId));
break;
case EventType.Secret_Deleted:
msg = this.i18nService.t("deletedSecret", this.formatSecretId(ev));
humanReadableMsg = this.i18nService.t("deletedSecret", this.getShortId(ev.secretId));
break;
case EventType.Secret_Edited:
msg = this.i18nService.t("editedSecret", this.formatSecretId(ev));
humanReadableMsg = this.i18nService.t("editedSecret", this.getShortId(ev.secretId));
break;
default:
break;
}

View File

@@ -8205,7 +8205,34 @@
"message": "An error occurred when trying to read the import file"
},
"accessedSecret": {
"message": "Accessed secret $SECRET_ID$.",
"message": "Accessed secret with identifier: $SECRET_ID$",
"placeholders": {
"secret_id": {
"content": "$1",
"example": "4d34e8a8"
}
}
},
"editedSecret": {
"message": "Edited a secret with identifier: $SECRET_ID$",
"placeholders": {
"secret_id": {
"content": "$1",
"example": "4d34e8a8"
}
}
},
"deletedSecret": {
"message": "Deleted a secret with identifier: $SECRET_ID$",
"placeholders": {
"secret_id": {
"content": "$1",
"example": "4d34e8a8"
}
}
},
"createdSecret": {
"message": "Created a new secret with identifier: $SECRET_ID$",
"placeholders": {
"secret_id": {
"content": "$1",

View File

@@ -90,4 +90,7 @@ export enum EventType {
OrganizationDomain_NotVerified = 2003,
Secret_Retrieved = 2100,
Secret_Created = 2101,
Secret_Edited = 2102,
Secret_Deleted = 2103,
}