From 679b65f643012651a3ed68a29d1b27491713773b Mon Sep 17 00:00:00 2001 From: Frank Noirot Date: Fri, 10 Jan 2025 17:04:09 -0500 Subject: [PATCH] Lints, fmt, tsc --- .env.development | 4 +++- interface.d.ts | 1 + src/components/OpenInDesktopAppHandler.test.tsx | 6 +----- src/components/ProjectsContextProvider.tsx | 1 - src/env.ts | 1 + 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.env.development b/.env.development index a718c4ea1d..cc36ee6333 100644 --- a/.env.development +++ b/.env.development @@ -7,4 +7,6 @@ VITE_KC_SITE_BASE_URL=https://dev.zoo.dev VITE_KC_SKIP_AUTH=false VITE_KC_CONNECTION_TIMEOUT_MS=5000 # ONLY add your token in .env.development.local if you want to skip auth, otherwise this token takes precedence! -#VITE_KC_DEV_TOKEN="your token from dev.zoo.dev should go in .env.development.local" \ No newline at end of file +#VITE_KC_DEV_TOKEN="your token from dev.zoo.dev should go in .env.development.local" +# Add a prod token if you want to use the share URL feature in local dev +#VITE_KC_PROD_TOKEN="your token from prod.zoo.dev should go in .env.development.local" \ No newline at end of file diff --git a/interface.d.ts b/interface.d.ts index 443918f285..9c032ec7b7 100644 --- a/interface.d.ts +++ b/interface.d.ts @@ -62,6 +62,7 @@ export interface IElectronAPI { TEST_SETTINGS_FILE_KEY: string IS_PLAYWRIGHT: string VITE_KC_DEV_TOKEN: string + VITE_KC_PROD_TOKEN: string VITE_KC_API_WS_MODELING_URL: string VITE_KC_API_BASE_URL: string VITE_KC_SITE_BASE_URL: string diff --git a/src/components/OpenInDesktopAppHandler.test.tsx b/src/components/OpenInDesktopAppHandler.test.tsx index 038fdf42c8..965befefe8 100644 --- a/src/components/OpenInDesktopAppHandler.test.tsx +++ b/src/components/OpenInDesktopAppHandler.test.tsx @@ -1,10 +1,6 @@ import { fireEvent, render, screen } from '@testing-library/react' -import { BrowserRouter, Route, Routes, useNavigate } from 'react-router-dom' -import { SettingsAuthProviderJest } from './SettingsAuthProvider' -import { CommandBarProvider } from './CommandBar/CommandBarProvider' +import { BrowserRouter, Route, Routes } from 'react-router-dom' import { OpenInDesktopAppHandler } from './OpenInDesktopAppHandler' -import { vi } from 'vitest' -import { useEffect, useState } from 'react' function TestWrap({ children, diff --git a/src/components/ProjectsContextProvider.tsx b/src/components/ProjectsContextProvider.tsx index 64e923a222..457fac4a4f 100644 --- a/src/components/ProjectsContextProvider.tsx +++ b/src/components/ProjectsContextProvider.tsx @@ -38,7 +38,6 @@ import { saveSettings, setSettingsAtLevel, } from 'lib/settings/settingsUtils' -import { Project } from 'lib/project' type MachineContext = { state?: StateFrom diff --git a/src/env.ts b/src/env.ts index 1522a17171..ff0c50c3de 100644 --- a/src/env.ts +++ b/src/env.ts @@ -14,6 +14,7 @@ export const VITE_KC_SKIP_AUTH = env.VITE_KC_SKIP_AUTH as string | undefined export const VITE_KC_CONNECTION_TIMEOUT_MS = env.VITE_KC_CONNECTION_TIMEOUT_MS as string | undefined export const VITE_KC_DEV_TOKEN = env.VITE_KC_DEV_TOKEN as string | undefined +export const VITE_KC_PROD_TOKEN = env.VITE_KC_PROD_TOKEN as string | undefined export const PROD = env.PROD as string | undefined export const TEST = env.TEST as string | undefined export const DEV = env.DEV as string | undefined