Ghost/ghost/admin/app/components/modal-post-preview/browser.js
Kevin Ansfield 7f7d2cafc6 Added share/send preview footers to post preview modal
refs https://github.com/TryGhost/Team/issues/451

- disabled email tab when previewing a page (pages can't be emailed)
- added share preview url footer to browser tab
- added send preview footer to email tab
- added first pass at social tab contents
2021-02-02 16:08:05 +00:00

13 lines
438 B
JavaScript

import Component from '@glimmer/component';
import copyTextToClipboard from 'ghost-admin/utils/copy-text-to-clipboard';
import {task} from 'ember-concurrency-decorators';
import {timeout} from 'ember-concurrency';
export default class ModalPostPreviewBrowserComponent extends Component {
@task
*copyPreviewUrl() {
copyTextToClipboard(this.args.post.previewUrl);
yield timeout(this.isTesting ? 50 : 3000);
}
}