Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
isSidenoteEntityActive = () => {
return EditorUtils.hasEntity(this.props.getEditorState(), 'SIDENOTE');
}
render() {
const { theme, onRemoveLinkAtSelection } = this.props;
const hasLinkSelected = EditorUtils.hasEntity(
this.props.store.getEditorState(),
'LINK'
);
const className = hasLinkSelected
? clsx(theme.button, theme.active)
: theme.button;
return (
<div>
<button type="button"></button></div>
render() {
const { theme } = this.props;
const hasLinkSelected = EditorUtils.hasEntity(
this.props.getEditorState(),
'LINK'
);
const className = hasLinkSelected
? unionClassNames(theme.button, theme.active)
: theme.button;
return (
<div>
</div>
const isSidenoteSelected = (editorState) => {
return EditorUtils.hasEntity(editorState, 'SIDENOTE');
}
render() {
const { theme, onRemoveLinkAtSelection } = this.props;
const hasLinkSelected = EditorUtils.hasEntity(
this.props.store.getEditorState(),
'LINK',
);
const className = hasLinkSelected
? unionClassNames(theme.button, theme.active)
: theme.button;
return (
<div role="presentation">
</div>