diff --git a/public/index.html b/public/index.html
index b58ac6f..dff4a63 100644
--- a/public/index.html
+++ b/public/index.html
@@ -24,6 +24,7 @@
+
diff --git a/src/Share.js b/src/Share.js
index fb6c506..1373e8f 100644
--- a/src/Share.js
+++ b/src/Share.js
@@ -1,3 +1,4 @@
+/*global CryptoGoods:true*/
import React, { Component } from 'react';
import styled from 'styled-components';
@@ -77,6 +78,7 @@ class Share extends Component {
this.share('tweet', e)}>Tweet it
this.share('image', e)}>Get an image
+ this.share('cryptogoods', e)}>Buy at cryptogoods.co
)}
@@ -111,6 +113,28 @@ class Share extends Component {
'_blank',
);
break;
+ case 'cryptogoods':
+ CryptoGoods.open({
+ // [required] : The token to display (must be owned by calling user)
+ token_id: '127',
+ // [optional] : Add this line while testing. Delete this line for production.
+ test: true,
+ // [optional] : The product to display initially
+ product: 'mug',
+ // [optional] : Used to avoid collisions between token IDs between different contracts
+ contract_name: 'CryptoKitties',
+ // [optional] : Used to avoid collisions between token IDs between different contracts
+ contract_address: '0x06012c8cf97BEaD5deAe237070F9587f8E7A266d',
+ // [optional] : For tracking purchases to your website (format: http[s]://example.com)
+ referrer: "https://cryptopurr.co",
+ // [optional] : A CSS branding color for matching your websites branding within the cart
+ brand_color: "#85D40C",
+ // [optional] : Payload containing additional data
+ payload: {
+ image_url: ipfsUrl,
+ }
+ });
+ break;
default:
newWindow = window.open(ipfsUrl, '_blank');
}
diff --git a/src/ShowPage.js b/src/ShowPage.js
index 35e6494..e1a029d 100644
--- a/src/ShowPage.js
+++ b/src/ShowPage.js
@@ -1,3 +1,4 @@
+/*global CryptoGoods:true*/
import React, { Component } from 'react';
import styled from 'styled-components';
import { pageView } from './Analytics';
@@ -11,7 +12,7 @@ import {
ActiveEntityName
} from './Entity';
import Modal from './Modal';
-import { FacebookIcon, GithubIcon, TwitterIcon, InstagramIcon, socialColors } from './Icons';
+import { FacebookIcon, GithubIcon, TwitterIcon, InstagramIcon, ExternalLink, socialColors } from './Icons';
import { ConnectedLabelForm, ReplyForm, CommentForm, ConnectedWriteToForm, ConnectedCommentForm } from './CommentForm';
import { EntityIcon } from './entityApi';
import Link from './Link';
@@ -278,6 +279,26 @@ export class SocialBadges extends React.Component {
} />
+
+ {
+ CryptoGoods.open({
+ // [required] : The token to display (must be owned by calling user)
+ token_id: id,
+ // [optional] : Add this line while testing. Delete this line for production.
+ test: true,
+ // [optional] : The product to display initially
+ product: 'mug',
+ // [optional] : Used to avoid collisions between token IDs between different contracts
+ contract_name: 'CryptoKitties',
+ // [optional] : Used to avoid collisions between token IDs between different contracts
+ contract_address: '0x06012c8cf97BEaD5deAe237070F9587f8E7A266d',
+ // [optional] : For tracking purchases to your website (format: http[s]://example.com)
+ referrer: "https://cryptopurr.co",
+ // [optional] : A CSS branding color for matching your websites branding within the cart
+ brand_color: "#85D40C",
+ });
+ }} children={} />
+
{this.state.editing && (