run linterFormatter
This commit is contained in:
parent
bf3b952f21
commit
f5937896d8
|
@ -53,7 +53,7 @@ export class KVKeysList extends Component<KVKeysListProps, KVKeysListState> {
|
||||||
|
|
||||||
async componentDidMount() {
|
async componentDidMount() {
|
||||||
this.setState({
|
this.setState({
|
||||||
searchQuery: ""
|
searchQuery: "",
|
||||||
});
|
});
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -98,7 +98,7 @@ export class KVKeysList extends Component<KVKeysListProps, KVKeysListState> {
|
||||||
) {
|
) {
|
||||||
this.setState({
|
this.setState({
|
||||||
dataLoaded: false,
|
dataLoaded: false,
|
||||||
searchQuery: ""
|
searchQuery: "",
|
||||||
});
|
});
|
||||||
void this.loadData();
|
void this.loadData();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,13 @@
|
||||||
import { Button } from "../../../elements/Button";
|
import { Button } from "../../../elements/Button";
|
||||||
import { CapabilitiesType } from "../../../../api/types/capabilities";
|
import { CapabilitiesType } from "../../../../api/types/capabilities";
|
||||||
import { Component, createRef, JSX } from "preact";
|
import { Component, JSX, createRef } from "preact";
|
||||||
import { CopyableInputBox } from "../../../elements/CopyableInputBox";
|
import { CopyableInputBox } from "../../../elements/CopyableInputBox";
|
||||||
import { DefaultPageProps } from "../../../../types/DefaultPageProps";
|
import { DefaultPageProps } from "../../../../types/DefaultPageProps";
|
||||||
import { Grid, GridSizes } from "../../../elements/Grid";
|
import { Grid, GridSizes } from "../../../elements/Grid";
|
||||||
|
import { Margin } from "../../../elements/Margin";
|
||||||
import { MarginInline } from "../../../elements/MarginInline";
|
import { MarginInline } from "../../../elements/MarginInline";
|
||||||
import { SecretTitleElement } from "../SecretTitleElement";
|
import { SecretTitleElement } from "../SecretTitleElement";
|
||||||
|
import { TextInput } from "../../../elements/forms/TextInput";
|
||||||
import {
|
import {
|
||||||
delSecretsEngineURL,
|
delSecretsEngineURL,
|
||||||
totpDeleteURL,
|
totpDeleteURL,
|
||||||
|
@ -14,9 +16,7 @@ import {
|
||||||
} from "../../pageLinks";
|
} from "../../pageLinks";
|
||||||
import { removeDoubleSlash } from "../../../../utils";
|
import { removeDoubleSlash } from "../../../../utils";
|
||||||
import { sendErrorNotification } from "../../../elements/ErrorMessage";
|
import { sendErrorNotification } from "../../../elements/ErrorMessage";
|
||||||
import i18next, { t } from "i18next";
|
import i18next from "i18next";
|
||||||
import { Margin } from "../../../elements/Margin";
|
|
||||||
import { TextInput } from "../../../elements/forms/TextInput";
|
|
||||||
|
|
||||||
type TOTPGridItemProps = DefaultPageProps & {
|
type TOTPGridItemProps = DefaultPageProps & {
|
||||||
baseMount: string;
|
baseMount: string;
|
||||||
|
@ -76,17 +76,17 @@ type TOTPItem = {
|
||||||
|
|
||||||
type TOTPListViewProps = DefaultPageProps & {
|
type TOTPListViewProps = DefaultPageProps & {
|
||||||
totpItems: TOTPItem[];
|
totpItems: TOTPItem[];
|
||||||
}
|
};
|
||||||
|
|
||||||
type TOTPListViewState = {
|
type TOTPListViewState = {
|
||||||
searchQuery: string;
|
searchQuery: string;
|
||||||
}
|
};
|
||||||
|
|
||||||
export class TOTPListView extends Component<TOTPListViewProps, TOTPListViewState> {
|
export class TOTPListView extends Component<TOTPListViewProps, TOTPListViewState> {
|
||||||
constructor() {
|
constructor() {
|
||||||
super();
|
super();
|
||||||
this.state = {
|
this.state = {
|
||||||
searchQuery: ""
|
searchQuery: "",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -94,13 +94,13 @@ export class TOTPListView extends Component<TOTPListViewProps, TOTPListViewState
|
||||||
|
|
||||||
componentDidMount(): void {
|
componentDidMount(): void {
|
||||||
this.setState({
|
this.setState({
|
||||||
searchQuery: ""
|
searchQuery: "",
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
if (this.props.totpItems.length == 0) {
|
if (this.props.totpItems.length == 0) {
|
||||||
return <p>{i18next.t("totp_list_empty")}</p>
|
return <p>{i18next.t("totp_list_empty")}</p>;
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -133,11 +133,10 @@ export class TOTPListView extends Component<TOTPListViewProps, TOTPListViewState
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
</>
|
</>
|
||||||
)
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
type TOTPListState = {
|
type TOTPListState = {
|
||||||
capabilities?: CapabilitiesType;
|
capabilities?: CapabilitiesType;
|
||||||
totpItems: TOTPItem[];
|
totpItems: TOTPItem[];
|
||||||
|
@ -149,7 +148,6 @@ export class TOTPList extends Component<DefaultPageProps, TOTPListState> {
|
||||||
this.state = { capabilities: null, totpItems: [] };
|
this.state = { capabilities: null, totpItems: [] };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
async doApiFetches() {
|
async doApiFetches() {
|
||||||
const api = this.props.api;
|
const api = this.props.api;
|
||||||
const baseMount = this.props.matches["baseMount"];
|
const baseMount = this.props.matches["baseMount"];
|
||||||
|
|
Loading…
Reference in a new issue