Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 21 additions & 4 deletions src/components/mint/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,15 +46,20 @@ class MintNFT extends React.Component {
const { ethereum } = window;
if (ethereum) {

if(location.protocol !== 'https:') {
// https://ethereum.stackexchange.com/a/62217/620
const alert = document.querySelector("#alert-error-https");
alert.style.display = "block";
document.querySelector("#btn-connect").setAttribute("disabled", "disabled")
return;
}

const providerOptions = {
// binancechainwallet: {
// package: binancechainwallet
// },
walletconnect: {
package: WalletConnectProvider,
options: {
infuraId: "0bbb45846bdf44d1bcbe6275327619ad"
}
},
walletlink: {
package: WalletLink,
Expand All @@ -69,7 +74,19 @@ const providerOptions = {
}
},
};

fortmatic: {
package: Fortmatic,
options: {
// Mikko's TESTNET api key
key: "pk_test_391E26A3B43A3350"
}
}
};
web3Modal = new Web3Modal({
cacheProvider: false, // optional
providerOptions, // required
disableInjectedProvider: false, // optional. For MetaMask / Brave / Opera.
});



Expand Down