import { Card } from '@automattic/components'; import { ToggleControl } from '@wordpress/components'; import { get } from 'lodash'; import { Component } from 'react'; import { connect } from 'react-redux'; import PostShare from 'calypso/blocks/post-share'; import QueryPosts from 'calypso/components/data/query-posts'; import QuerySitePlans from 'calypso/components/data/query-site-plans'; import QuerySites from 'calypso/components/data/query-sites'; import Notice from 'calypso/components/notice'; import { getCurrentUser } from 'calypso/state/current-user/selectors'; import { getSitePosts } from 'calypso/state/posts/selectors'; import { getSite, getSitePlanSlug } from 'calypso/state/sites/selectors'; class PostShareExample extends Component { state = { isEnabled: false, }; toggleEnable = () => this.setState( { isEnabled: ! this.state.isEnabled } ); render() { const { planSlug, post, site, siteId } = this.props; return (
Site: { site.name } ({ siteId })
Plan: { planSlug }
Post: { post.title }