mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
feat: add "Hello from the otter side" easter eggs
Custom 404 pages for landing and docs sites, otter greeting on the first-login sidebar, and a one-time welcome toast after password change.
This commit is contained in:
+10
-1
@@ -1,7 +1,7 @@
|
||||
import { APP_VERSION, en, shouldShowConsent } from "@snapotter/shared";
|
||||
import { Component, type ErrorInfo, lazy, type ReactNode, Suspense, useEffect } from "react";
|
||||
import { BrowserRouter, Navigate, Route, Routes, useLocation } from "react-router-dom";
|
||||
import { Toaster } from "sonner";
|
||||
import { Toaster, toast } from "sonner";
|
||||
import { ConnectionMonitor } from "./components/common/connection-monitor";
|
||||
import { KeyboardShortcutProvider } from "./components/common/keyboard-shortcut-provider";
|
||||
import { I18nProvider } from "./contexts/i18n-context";
|
||||
@@ -186,6 +186,15 @@ export function App() {
|
||||
fetchAnalyticsConfig();
|
||||
}, [fetchAnalyticsConfig]);
|
||||
|
||||
useEffect(() => {
|
||||
if (localStorage.getItem("snapotter-welcome") === "1") {
|
||||
localStorage.removeItem("snapotter-welcome");
|
||||
toast("Hello from the otter side! 🦦", {
|
||||
duration: 5000,
|
||||
});
|
||||
}
|
||||
}, []);
|
||||
|
||||
useEffect(() => {
|
||||
if (
|
||||
!analyticsConfigLoaded ||
|
||||
|
||||
Reference in New Issue
Block a user