import styles from './FeedArticlePopup.module.scss' import type { PopupProps } from '../_shared/Popup' import { Popup } from '../_shared/Popup' import { useLocalize } from '../../context/localize' import { createEffect, createSignal, Show } from 'solid-js' type FeedArticlePopupProps = { title: string shareUrl?: string imageUrl: string isOwner: boolean description: string isVisible?: (value: boolean) => void } & Omit export const FeedArticlePopup = (props: FeedArticlePopupProps) => { const { t } = useLocalize() const [isVisible, setIsVisible] = createSignal(false) createEffect(() => { if (props.isVisible) { props.isVisible(isVisible()) } }) return ( setIsVisible(value)} popupCssClass={styles.feedArticlePopup} > ) }