From 59dbc796560bd2e57d08ca61af70cd00b7a633d2 Mon Sep 17 00:00:00 2001 From: shamoon <4887959+shamoon@users.noreply.github.com> Date: Wed, 4 Oct 2023 23:55:03 -0700 Subject: [PATCH] Remove deprecated notification --- .github/workflows/docker-publish.yml | 1 - Dockerfile | 3 +-- src/pages/index.jsx | 32 ---------------------------- 3 files changed, 1 insertion(+), 35 deletions(-) diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index 305734851..2647b3fdf 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -105,7 +105,6 @@ jobs: BUILDTIME=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.created'] }} VERSION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.version'] }} REVISION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.revision'] }} - DEPRECATED_REPO=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.source'] == 'https://github.com/gethomepage/homepage' }} # https://github.com/docker/setup-qemu-action#about # platforms: linux/amd64,linux/arm64,linux/riscv64,linux/ppc64le,linux/s390x,linux/386,linux/mips64le,linux/mips64,linux/arm/v7,linux/arm/v6 platforms: linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v6 diff --git a/Dockerfile b/Dockerfile index 9600cc11c..3e6de7568 100644 --- a/Dockerfile +++ b/Dockerfile @@ -23,7 +23,6 @@ WORKDIR /app ARG BUILDTIME ARG VERSION ARG REVISION -ARG DEPRECATED_REPO COPY --link --from=deps /app/node_modules ./node_modules/ COPY . . @@ -31,7 +30,7 @@ COPY . . SHELL ["/bin/ash", "-xeo", "pipefail", "-c"] RUN npm run telemetry \ && mkdir config \ - && NEXT_PUBLIC_BUILDTIME=$BUILDTIME NEXT_PUBLIC_VERSION=$VERSION NEXT_PUBLIC_REVISION=$REVISION NEXT_PUBLIC_DEPRECATED_REPO=$DEPRECATED_REPO npm run build + && NEXT_PUBLIC_BUILDTIME=$BUILDTIME NEXT_PUBLIC_VERSION=$VERSION NEXT_PUBLIC_REVISION=$REVISION npm run build # Production image, copy all the files and run next FROM docker.io/node:18-alpine AS runner diff --git a/src/pages/index.jsx b/src/pages/index.jsx index 0d9c6a7bf..9367e8b4d 100644 --- a/src/pages/index.jsx +++ b/src/pages/index.jsx @@ -27,7 +27,6 @@ import ErrorBoundary from "components/errorboundry"; import themes from "utils/styles/themes"; import QuickLaunch from "components/quicklaunch"; import { getStoredProvider, searchProviders } from "components/widgets/search/search"; -import ResolvedIcon from "components/resolvedicon"; const ThemeToggle = dynamic(() => import("components/toggles/theme"), { ssr: false, @@ -168,17 +167,6 @@ const headerStyles = { boxedWidgets: "m-6 mb-0 sm:m-9 sm:mb-0 sm:mt-1", }; -const deprecatedNotificationDismissedStorageKey = "deprecated-notification-dismissed"; - -const getNotificationDismissed = () => { - if (typeof window !== "undefined" && window.localStorage) { - const dismissed = window.localStorage.getItem(deprecatedNotificationDismissedStorageKey); - return dismissed; - } - - return false; -}; - function Home({ initialSettings }) { const { i18n } = useTranslation(); const { theme, setTheme } = useContext(ThemeContext); @@ -187,9 +175,6 @@ function Home({ initialSettings }) { const { activeTab, setActiveTab } = useContext(TabContext); const { asPath } = useRouter(); - const isDeprecatedRepo = process.env.NEXT_PUBLIC_DEPRECATED_REPO; - const [notificationDismissed, setNotificationDismissed] = useState(getNotificationDismissed); - useEffect(() => { setSettings(initialSettings); }, [initialSettings, setSettings]); @@ -435,23 +420,6 @@ function Home({ initialSettings }) {