Debian Codegraph @

pkg/storaged/crypto/locked-encrypted-data.jsx

raw
1 /*
2 * Copyright (C) 2023 Red Hat, Inc.
3 * SPDX-License-Identifier: LGPL-2.1-or-later
4 */
5
6 import cockpit from "cockpit";
7
8 import { StorageCard, new_card } from "../pages.jsx";
9 import { std_format_action } from "../block/actions.jsx";
10 import { unlock } from "./actions.jsx";
11
12 const _ = cockpit.gettext;
13
14 export function make_locked_encrypted_data_card(next, block) {
15 return new_card({
16 title: _("Locked data"),
17 next,
18 page_block: block,
19 component: StorageCard,
20 props: { block },
21 actions: [
22 { title: _("Unlock"), action: () => unlock(block) },
23 std_format_action(block, null),
24 ]
25 });
26 }