mirror of
https://github.com/bitwarden/clients.git
synced 2026-07-07 21:10:55 +08:00
* Removed type counts and just calculated counts off the sends * Fixing key spec test case
19 lines
562 B
TypeScript
19 lines
562 B
TypeScript
import { SendView } from "@bitwarden/common/tools/send/models/view/send.view";
|
|
import { DeepJsonify } from "@bitwarden/common/types/deep-jsonify";
|
|
|
|
import { BrowserComponentState } from "./browserComponentState";
|
|
|
|
export class BrowserSendComponentState extends BrowserComponentState {
|
|
sends: SendView[];
|
|
|
|
static fromJSON(json: DeepJsonify<BrowserSendComponentState>) {
|
|
if (json == null) {
|
|
return null;
|
|
}
|
|
|
|
return Object.assign(new BrowserSendComponentState(), json, {
|
|
sends: json.sends?.map((s) => SendView.fromJSON(s)),
|
|
});
|
|
}
|
|
}
|