diff --git a/src/components/Expericence/Experience.tsx b/src/components/Expericence/Experience.tsx index a20bc3e5e..cf75b0d6d 100644 --- a/src/components/Expericence/Experience.tsx +++ b/src/components/Expericence/Experience.tsx @@ -77,16 +77,15 @@ export const Experience: React.FC = props => { const isOwnExperience = userExperience.experience.user.id === user?.id; const experienceId = userExperience.experience.id; const userExperienceId = userExperience.id; - const link = publicRuntimeConfig.appAuthURL + `/experience/${experienceId}`; + const link = + publicRuntimeConfig.appAuthURL + `/type=experience&id=${experienceId}`; const { userExperiencesMeta } = useExperienceHook(); const totalOwnedExperience = userExperiencesMeta.additionalData?.totalOwnedExperience ?? 0; const handleClickExperience = () => { handleCloseSettings(); - - if (selectable && onSelect) { - onSelect(experienceId); - } + console.log(selectable); + onSelect(experienceId); }; const handleCloneExperience = () => { diff --git a/src/components/ExperienceList/ExperienceList.container.tsx b/src/components/ExperienceList/ExperienceList.container.tsx index 192df93f9..567840700 100644 --- a/src/components/ExperienceList/ExperienceList.container.tsx +++ b/src/components/ExperienceList/ExperienceList.container.tsx @@ -53,7 +53,6 @@ export const ExperienceListContainer: React.FC = enableClone, enableSubscribe, hasMore = false, - filterTimeline = false, loadNextPage, refreshExperience, noButton, @@ -87,17 +86,13 @@ export const ExperienceListContainer: React.FC = type: TimelineType, userExperience: WrappedExperience, ) => { - if (filterTimeline) { - router.push( - `/?type=experience&id=${userExperience.experience.id}`, - undefined, - { - shallow: true, - }, - ); - } else { - router.push(`/topic/experience?id=${userExperience.experience.id}`); - } + router.push( + `/?type=experience&id=${userExperience.experience.id}`, + undefined, + { + shallow: true, + }, + ); }; const handleRemoveExperience = (experienceId: string) => { diff --git a/src/components/PostCreate/PostCreate.tsx b/src/components/PostCreate/PostCreate.tsx index 7bc35f9ca..4ff44c6ef 100644 --- a/src/components/PostCreate/PostCreate.tsx +++ b/src/components/PostCreate/PostCreate.tsx @@ -67,7 +67,7 @@ export const PostCreate: React.FC = props => { const [activeTab, setActiveTab] = useState('create'); const [post, setPost] = useState>(initialPost); - const [loading, setLoading] = useState(false); + const [editorValue, setEditorValue] = useState(''); const content = useRef(''); const [importUrl, setImport] = useState(); @@ -250,12 +250,14 @@ export const PostCreate: React.FC = props => { setImport(undefined); setShowExclusive(false); setExclusiveContent(null); - + setEditorValue(''); onClose(); }; - const handleContentChange = (data, loading) => { - setLoading(loading); + const handleContentChange = data => { + if (data[0].children[0].text !== '') { + setEditorValue(data[0].children[0].text); + } content.current = data; }; @@ -431,7 +433,7 @@ export const PostCreate: React.FC = props => {