import InsertLinkIcon from '@mui/icons-material/InsertLink'; import LanguageIcon from '@mui/icons-material/Language'; import ShareIcon from '@mui/icons-material/Share'; import { MuiButton as Button, MuiInputBase as InputBase, MuiPaper as Paper, MuiSnackbar as Snackbar, MuiSwitch as Switch, Popover, } from '@toeverything/components/ui'; import { copyToClipboard } from '@toeverything/utils'; import { useState } from 'react'; import style9 from 'style9'; const styles = style9.create({ pageShareBox: { width: '500px', padding: '30px 20px 50px 20px', }, btnPageShare: { width: '24px', height: '24px', }, pageShareBoxIcon: { position: 'absolute', left: '5px', top: '10px', color: 'var(--color-gray-400)', }, pageShareBoxForWeb: { position: 'relative', paddingLeft: '40px', borderBottom: '1px solid var(--color-gray-400))', marginBottom: '15px', }, pageShareBoxSwitch: { position: 'absolute', right: '5px', top: '10px', }, pageShareBoxForWebP1: { fontWeight: 'bold', marginBottom: '5px', }, pageShareBoxForWebP2: { color: 'var(--color-gray-400)', }, copyLinkBtn: { marginTop: '15px', float: 'right', cursor: 'pointer', }, copyLinkcon: { verticalAlign: 'middle', }, }); const MESSAGES = { COPY_LINK: ' Copy Link', INVITE: 'Add people,emails, or groups', SHARE_TO_WEB: 'Share to web', SHARE_TO_ANYONE: 'Publish and share link with any one', COPY_LINK_SUCCESS: 'Copyed link to clipboard', }; function PageSharePortal() { const [alertOpen, setAlertOpen] = useState(false); const handleCopy = () => { copyToClipboard(window.location.href); setAlertOpen(true); }; const handleAlertClose = () => { setAlertOpen(false); }; return (

{MESSAGES.SHARE_TO_WEB}

{MESSAGES.SHARE_TO_ANYONE}

{MESSAGES.COPY_LINK}
} > ); } export { PageSharePortal };