Remove bundled sample env
Some checks failed
Build Windows App / build-windows (push) Failing after 5m46s
Some checks failed
Build Windows App / build-windows (push) Failing after 5m46s
This commit is contained in:
28
src/App.tsx
28
src/App.tsx
@@ -21,22 +21,6 @@ import type { EnvDefault } from "./env";
|
|||||||
type ThemeMode = "system" | "light" | "dark";
|
type ThemeMode = "system" | "light" | "dark";
|
||||||
type Language = "de" | "en" | "es" | "fr" | "nl";
|
type Language = "de" | "en" | "es" | "fr" | "nl";
|
||||||
|
|
||||||
const sampleEnv = `APP_IMAGE=git.wilkensxl.de/mrsphay/hilden-directory-gateway:latest
|
|
||||||
APP_PORT=3000
|
|
||||||
|
|
||||||
NODE_ENV=production
|
|
||||||
PUBLIC_BASE_URL=https://gateway.example.local
|
|
||||||
TRUSTED_IFRAME_ANCESTORS=https://www.hilden.de
|
|
||||||
|
|
||||||
DATABASE_URL=postgresql://hilden_app:CHANGE_ME_POSTGRES_PASSWORD@postgres:5432/hilden_directory
|
|
||||||
POSTGRES_PASSWORD=CHANGE_ME_POSTGRES_PASSWORD
|
|
||||||
|
|
||||||
SESSION_SECRET=CHANGE_ME_AT_LEAST_32_RANDOM_CHARACTERS
|
|
||||||
ENCRYPTION_KEY_BASE64=CHANGE_ME_32_RANDOM_BYTES_AS_BASE64
|
|
||||||
|
|
||||||
BOOTSTRAP_ADMIN_EMAIL=admin@example.local
|
|
||||||
BOOTSTRAP_ADMIN_PASSWORD=CHANGE_ME_LONG_INITIAL_ADMIN_PASSWORD`;
|
|
||||||
|
|
||||||
const initialDefaults: EnvDefault[] = [{ key: "BOOTSTRAP_ADMIN_EMAIL", value: "admin@example.local" }];
|
const initialDefaults: EnvDefault[] = [{ key: "BOOTSTRAP_ADMIN_EMAIL", value: "admin@example.local" }];
|
||||||
|
|
||||||
const languageNames: Record<Language, string> = {
|
const languageNames: Record<Language, string> = {
|
||||||
@@ -60,7 +44,6 @@ const translations = {
|
|||||||
copy: "Kopieren",
|
copy: "Kopieren",
|
||||||
copied: "Kopiert",
|
copied: "Kopiert",
|
||||||
regenerate: "Neu erzeugen",
|
regenerate: "Neu erzeugen",
|
||||||
sample: "Beispiel laden",
|
|
||||||
hits: "Fundstellen",
|
hits: "Fundstellen",
|
||||||
values: "Werte",
|
values: "Werte",
|
||||||
defaultsApplied: "Defaults",
|
defaultsApplied: "Defaults",
|
||||||
@@ -98,7 +81,6 @@ const translations = {
|
|||||||
copy: "Copy",
|
copy: "Copy",
|
||||||
copied: "Copied",
|
copied: "Copied",
|
||||||
regenerate: "Regenerate",
|
regenerate: "Regenerate",
|
||||||
sample: "Load sample",
|
|
||||||
hits: "Matches",
|
hits: "Matches",
|
||||||
values: "Values",
|
values: "Values",
|
||||||
defaultsApplied: "Defaults",
|
defaultsApplied: "Defaults",
|
||||||
@@ -136,7 +118,6 @@ const translations = {
|
|||||||
copy: "Copiar",
|
copy: "Copiar",
|
||||||
copied: "Copiado",
|
copied: "Copiado",
|
||||||
regenerate: "Regenerar",
|
regenerate: "Regenerar",
|
||||||
sample: "Cargar ejemplo",
|
|
||||||
hits: "Coincidencias",
|
hits: "Coincidencias",
|
||||||
values: "Valores",
|
values: "Valores",
|
||||||
defaultsApplied: "Defaults",
|
defaultsApplied: "Defaults",
|
||||||
@@ -174,7 +155,6 @@ const translations = {
|
|||||||
copy: "Copier",
|
copy: "Copier",
|
||||||
copied: "Copié",
|
copied: "Copié",
|
||||||
regenerate: "Régénérer",
|
regenerate: "Régénérer",
|
||||||
sample: "Charger exemple",
|
|
||||||
hits: "Occurrences",
|
hits: "Occurrences",
|
||||||
values: "Valeurs",
|
values: "Valeurs",
|
||||||
defaultsApplied: "Défauts",
|
defaultsApplied: "Défauts",
|
||||||
@@ -212,7 +192,6 @@ const translations = {
|
|||||||
copy: "Kopiëren",
|
copy: "Kopiëren",
|
||||||
copied: "Gekopieerd",
|
copied: "Gekopieerd",
|
||||||
regenerate: "Opnieuw maken",
|
regenerate: "Opnieuw maken",
|
||||||
sample: "Voorbeeld laden",
|
|
||||||
hits: "Treffers",
|
hits: "Treffers",
|
||||||
values: "Waarden",
|
values: "Waarden",
|
||||||
defaultsApplied: "Defaults",
|
defaultsApplied: "Defaults",
|
||||||
@@ -272,7 +251,7 @@ function readTheme(): ThemeMode {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export default function App() {
|
export default function App() {
|
||||||
const [input, setInput] = useState(sampleEnv);
|
const [input, setInput] = useState("");
|
||||||
const [loadedPath, setLoadedPath] = useState<string | null>(null);
|
const [loadedPath, setLoadedPath] = useState<string | null>(null);
|
||||||
const [copyLabel, setCopyLabel] = useState<"copy" | "copied">("copy");
|
const [copyLabel, setCopyLabel] = useState<"copy" | "copied">("copy");
|
||||||
const [generation, setGeneration] = useState(0);
|
const [generation, setGeneration] = useState(0);
|
||||||
@@ -372,11 +351,6 @@ export default function App() {
|
|||||||
|
|
||||||
<section className="workbench">
|
<section className="workbench">
|
||||||
<EditorPanel
|
<EditorPanel
|
||||||
actions={
|
|
||||||
<button className="iconButton" onClick={() => setInput(sampleEnv)} title={t.sample} type="button">
|
|
||||||
<RefreshCcw size={17} />
|
|
||||||
</button>
|
|
||||||
}
|
|
||||||
hint={loadedPath ?? t.inputHint}
|
hint={loadedPath ?? t.inputHint}
|
||||||
title={t.input}
|
title={t.input}
|
||||||
>
|
>
|
||||||
|
|||||||
Reference in New Issue
Block a user