diff --git a/src/translations/en.js b/src/translations/en.js
index a1db8f6..7678908 100644
--- a/src/translations/en.js
+++ b/src/translations/en.js
@@ -189,11 +189,9 @@ module.exports = {
kv_view_none_here_text: "You seem to have no secrets here, would you like to create one?",
kv_view_search_input_text: "Search",
- // TOTP View Page
- totp_view_title: "TOTP",
- totp_view_loading: "Loading TOTP Codes..",
- totp_view_empty: "You seem to have no TOTP codes here, would you like to create one?",
- totp_view_loading_box: "Loading..",
+ // TOTP List Page
+ totp_list_empty: "You seem to have no TOTP codes here, would you like to create one?",
+ totp_list_search_input_text: "Search",
// New TOTP Key Page
totp_new_title: "New TOTP Key",
diff --git a/src/translations/ru.js b/src/translations/ru.js
index 62c09e4..96f19c2 100644
--- a/src/translations/ru.js
+++ b/src/translations/ru.js
@@ -163,11 +163,9 @@ module.exports = {
kv_view_none_here_text: "У вас на данный момент нет тайных данных. Хотите ли вы их создать?",
kv_view_search_input_text: "Поиск",
- // TOTP View Page
- totp_view_title: "TOTP",
- totp_view_loading: "Загрузка кодов TOTP..",
- totp_view_empty: "У вас на данный момент нет кодов TOTP. Хотите ли вы их создать?",
- totp_view_loading_box: "Загрузка..",
+ // TOTP New Page
+ totp_list_empty: "У вас на данный момент нет кодов TOTP. Хотите ли вы их создать?",
+ totp_list_search_input_text: "Поиск",
// New TOTP Key Page
totp_new_title: "Новый ключ TOTP",
diff --git a/src/ui/pages/Secrets/TOTP/TOTPList.tsx b/src/ui/pages/Secrets/TOTP/TOTPList.tsx
index da4b043..7977807 100644
--- a/src/ui/pages/Secrets/TOTP/TOTPList.tsx
+++ b/src/ui/pages/Secrets/TOTP/TOTPList.tsx
@@ -1,6 +1,6 @@
import { Button } from "../../../elements/Button";
import { CapabilitiesType } from "../../../../api/types/capabilities";
-import { Component, JSX } from "preact";
+import { Component, createRef, JSX } from "preact";
import { CopyableInputBox } from "../../../elements/CopyableInputBox";
import { DefaultPageProps } from "../../../../types/DefaultPageProps";
import { Grid, GridSizes } from "../../../elements/Grid";
@@ -14,7 +14,9 @@ import {
} from "../../pageLinks";
import { removeDoubleSlash } from "../../../../utils";
import { sendErrorNotification } from "../../../elements/ErrorMessage";
-import i18next from "i18next";
+import i18next, { t } from "i18next";
+import { Margin } from "../../../elements/Margin";
+import { TextInput } from "../../../elements/forms/TextInput";
type TOTPGridItemProps = DefaultPageProps & {
baseMount: string;
@@ -72,6 +74,70 @@ type TOTPItem = {
canDelete: boolean;
};
+type TOTPListViewProps = DefaultPageProps & {
+ totpItems: TOTPItem[];
+}
+
+type TOTPListViewState = {
+ searchQuery: string;
+}
+
+export class TOTPListView extends Component {i18next.t("totp_list_empty")}
{i18next.t("totp_view_empty")}
; - } else { - return this.state.totpItems.map((totpItem) => { - return ( -