Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion public/sw.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/sw.js.map

Large diffs are not rendered by default.

25 changes: 0 additions & 25 deletions src/app/submit/_page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ import {
} from "./_hooks";
import { postBodySummary, proxifyImageSrc } from "@ecency/render-helper";
import useLocalStorage from "react-use/lib/useLocalStorage";
import useMount from "react-use/lib/useMount";
import { useUnmount } from "react-use";
import usePrevious from "react-use/lib/usePrevious";
import {
checkSvg,
Expand Down Expand Up @@ -46,7 +44,6 @@ import { Button } from "@ui/button";
import { Spinner } from "@ui/spinner";
import { FormControl } from "@ui/input";
import { IntroTour } from "@ui/intro-tour";
import { IntroStep } from "@ui/core";
import { PollsContext, PollsManager } from "@/app/submit/_hooks/polls-manager";
import { FullHeight } from "@/features/ui";
import {
Expand All @@ -70,7 +67,6 @@ import { useEntryPollExtractor } from "@/features/polls";
import { PREFIX } from "@/utils/local-storage";
import { useGlobalStore } from "@/core/global-store";
import { useRouter } from "next/navigation";
import { handleFloatingContainer } from "@/features/faq";
import { EcencyConfigManager } from "@/config";
import { SUBMIT_TOUR_ITEMS } from "@/app/submit/_consts";

Expand Down Expand Up @@ -211,16 +207,6 @@ function Submit({ path, draftId, username, permlink, searchParams }: Props) {
const { mutateAsync: publish, isPending: publishing } = usePublishApi(() => clear());
const { mutateAsync: update, isPending: updating } = useUpdateApi(() => clear());

useMount(() => {
window.addEventListener("resize", handleResize);
});

useUnmount(() => {
if (typeof window !== "undefined") {
window.removeEventListener("resize", handleResize);
}
});

useEffect(() => {
if (postPoll) {
setActivePoll(postPoll);
Expand Down Expand Up @@ -253,10 +239,6 @@ function Submit({ path, draftId, username, permlink, searchParams }: Props) {
setLocalDraft({ tags, title, body, description });
}, [tags, title, body, setLocalDraft, description]);

useEffect(() => {
handleFloatingContainer(showHelp);
}, [showHelp]);

useEffect(() => {
updatePreview();
}, [title, body, tags]);
Expand Down Expand Up @@ -291,13 +273,6 @@ function Submit({ path, draftId, username, permlink, searchParams }: Props) {
}, 50);
};

const handleResize = () => {
if (typeof window !== "undefined" && window.innerWidth < 992) {
setShowHelp(false);
handleFloatingContainer(false);
}
};

const clear = () => {
setTitle("");
setTags([]);
Expand Down
2 changes: 1 addition & 1 deletion src/features/ecency-center/center-content-layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export function CenterContentLayout({ show, setShow, children }: PropsWithChildr
height={48}
className="w-8 h-8 mb-4"
/>
<h3 className="font-bold">{i18next.t("floating-faq.welcome")}</h3>
<h3 className="font-bold">{i18next.t("floating-faq.center")}</h3>
<Button
className={classNameObject({
"absolute top-4 right-4 text-white hover:opacity-50 hover:text-white": true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,16 +138,6 @@
"path": "/proposals",
"suggestions": ["how-dhf-work", "how-vote-proposals"]
},
{
"path": "/@.+/",
"suggestions": [
"what-my-blog",
"what-information-profile",
"what-reputation",
"improve-reputation-score",
"why-score-going-down"
]
},
{
"path": "/@.+/(comments)",
"suggestions": [
Expand All @@ -170,6 +160,16 @@
{
"path": "/market",
"suggestions": ["how-market-works", "how-to-swap-header"]
},
{
"path": "/.*",
"suggestions": [
"what-my-blog",
"what-information-profile",
"what-reputation",
"improve-reputation-score",
"why-score-going-down"
]
}
]
}
2 changes: 1 addition & 1 deletion src/features/ecency-center/sections/center-faq.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { articleSvg } from "@/assets/img/svg";
import { FormControl } from "@ui/input";
import React, { useEffect, useState } from "react";
import { faqKeysGeneral } from "@/consts";
import data from "@/features/faq/floating-faq/path.json";
import data from "@/features/ecency-center/data/path.json";
import useMount from "react-use/lib/useMount";
import { usePathname } from "next/navigation";
import Link from "next/link";
Expand Down

This file was deleted.

Loading