mirror of
https://github.com/ascribe/onion.git
synced 2024-12-22 09:23:13 +01:00
remove Twitter
This commit is contained in:
parent
c28300d54d
commit
eb0aad0fe1
@ -7,8 +7,6 @@ import ProgressBar from 'react-bootstrap/lib/ProgressBar';
|
|||||||
|
|
||||||
import MediaPlayer from './../ascribe_media/media_player';
|
import MediaPlayer from './../ascribe_media/media_player';
|
||||||
|
|
||||||
import TwitterShareButton from '../ascribe_social_share/twitter_share_button';
|
|
||||||
|
|
||||||
import S3DownloadButton from '../ascribe_buttons/s3_download_button';
|
import S3DownloadButton from '../ascribe_buttons/s3_download_button';
|
||||||
|
|
||||||
import CollapsibleButton from './../ascribe_collapsible/collapsible_button';
|
import CollapsibleButton from './../ascribe_collapsible/collapsible_button';
|
||||||
@ -158,10 +156,6 @@ let MediaContainer = React.createClass({
|
|||||||
extraData={extraData}
|
extraData={extraData}
|
||||||
encodingMessage={this.getEncodingMessage()} />
|
encodingMessage={this.getEncodingMessage()} />
|
||||||
<p className="text-center hidden-print">
|
<p className="text-center hidden-print">
|
||||||
<span className="ascribe-social-button-list">
|
|
||||||
<TwitterShareButton
|
|
||||||
text={getLangText('Check out %s ascribed piece', didUserRegisterContent ? 'my latest' : 'this' )} />
|
|
||||||
</span>
|
|
||||||
<AclProxy
|
<AclProxy
|
||||||
show={['video', 'audio', 'image'].indexOf(mimetype) === -1 || content.acl.acl_download}
|
show={['video', 'audio', 'image'].indexOf(mimetype) === -1 || content.acl.acl_download}
|
||||||
aclObject={content.acl}
|
aclObject={content.acl}
|
||||||
|
@ -1,55 +0,0 @@
|
|||||||
'use strict';
|
|
||||||
|
|
||||||
import React from 'react';
|
|
||||||
|
|
||||||
import AppConstants from '../../constants/application_constants';
|
|
||||||
|
|
||||||
import { InjectInHeadUtils } from '../../utils/inject_utils';
|
|
||||||
|
|
||||||
let TwitterShareButton = React.createClass({
|
|
||||||
propTypes: {
|
|
||||||
count: React.PropTypes.string,
|
|
||||||
counturl: React.PropTypes.string,
|
|
||||||
hashtags: React.PropTypes.string,
|
|
||||||
size: React.PropTypes.string,
|
|
||||||
text: React.PropTypes.string,
|
|
||||||
url: React.PropTypes.string,
|
|
||||||
via: React.PropTypes.string
|
|
||||||
},
|
|
||||||
|
|
||||||
getDefaultProps() {
|
|
||||||
return {
|
|
||||||
count: 'none',
|
|
||||||
via: 'ascribeIO'
|
|
||||||
};
|
|
||||||
},
|
|
||||||
|
|
||||||
componentDidMount() {
|
|
||||||
InjectInHeadUtils.inject(AppConstants.twitter.sdkUrl).then(this.loadTwitterButton);
|
|
||||||
},
|
|
||||||
|
|
||||||
loadTwitterButton() {
|
|
||||||
const { count, counturl, hashtags, size, text, url, via } = this.props;
|
|
||||||
|
|
||||||
twttr.widgets.createShareButton(url, this.refs.twitterShareButton.getDOMNode(), {
|
|
||||||
count,
|
|
||||||
counturl,
|
|
||||||
hashtags,
|
|
||||||
size,
|
|
||||||
text,
|
|
||||||
via,
|
|
||||||
dnt: true // Do not track
|
|
||||||
});
|
|
||||||
},
|
|
||||||
|
|
||||||
render() {
|
|
||||||
return (
|
|
||||||
<span
|
|
||||||
ref="twitterShareButton"
|
|
||||||
className="btn btn-ascribe-social">
|
|
||||||
</span>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
export default TwitterShareButton;
|
|
@ -131,9 +131,6 @@ const constants = {
|
|||||||
'raven': {
|
'raven': {
|
||||||
'url': 'https://836bfb71c9c7418a967351d39ce547f0@app.getsentry.com/48351'
|
'url': 'https://836bfb71c9c7418a967351d39ce547f0@app.getsentry.com/48351'
|
||||||
},
|
},
|
||||||
'twitter': {
|
|
||||||
'sdkUrl': 'https://platform.twitter.com/widgets.js'
|
|
||||||
},
|
|
||||||
'cloudfrontDomain': 'd1qjsxua1o9x03.cloudfront.net',
|
'cloudfrontDomain': 'd1qjsxua1o9x03.cloudfront.net',
|
||||||
'errorMessagesToIgnore': [
|
'errorMessagesToIgnore': [
|
||||||
'Authentication credentials were not provided.',
|
'Authentication credentials were not provided.',
|
||||||
|
@ -22,7 +22,6 @@ gemini.suite('Work detail', (suite) => {
|
|||||||
actions.waitForElementToShow('.ascribe-app', TIMEOUTS.NORMAL);
|
actions.waitForElementToShow('.ascribe-app', TIMEOUTS.NORMAL);
|
||||||
|
|
||||||
// Wait for the social media buttons to appear
|
// Wait for the social media buttons to appear
|
||||||
actions.waitForElementToShow('.ascribe-social-button-list .twitter-share-button', TIMEOUTS.SUPER_DUPER_EXTRA_LONG);
|
|
||||||
actions.waitForElementToShow('.ascribe-media-player', TIMEOUTS.LONG);
|
actions.waitForElementToShow('.ascribe-media-player', TIMEOUTS.LONG);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user