diff options
Diffstat (limited to 'packages')
-rw-r--r-- | packages/instant/public/index.html | 2 | ||||
-rw-r--r-- | packages/instant/src/components/zero_ex_instant.tsx | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/packages/instant/public/index.html b/packages/instant/public/index.html index 0ee144a28..9f1dfdb64 100644 --- a/packages/instant/public/index.html +++ b/packages/instant/public/index.html @@ -62,7 +62,7 @@ const renderOptionsOverrides = { liquiditySource: liquiditySourceOverride === 'provided' ? [providedOrder] : liquiditySourceOverride, assetData: queryParams.getQueryParamValue('assetData'), - network: +queryParams.getQueryParamValue('network') || undefined, + networkId: +queryParams.getQueryParamValue('networkId') || undefined, defaultAssetBuyAmount: +queryParams.getQueryParamValue('defaultAssetBuyAmount') || undefined, } const renderOptions = Object.assign({}, renderOptionsDefaults, removeUndefined(renderOptionsOverrides)); diff --git a/packages/instant/src/components/zero_ex_instant.tsx b/packages/instant/src/components/zero_ex_instant.tsx index bf7cc9de5..8454de43c 100644 --- a/packages/instant/src/components/zero_ex_instant.tsx +++ b/packages/instant/src/components/zero_ex_instant.tsx @@ -31,17 +31,17 @@ export interface ZeroExInstantRequiredProps { export interface ZeroExInstantOptionalProps { defaultAssetBuyAmount?: number; additionalAssetMetaDataMap: ObjectMap<AssetMetaData>; - network: Network; + networkId: Network; } export class ZeroExInstant extends React.Component<ZeroExInstantProps> { private readonly _store: Store; private static _mergeInitialStateWithProps(props: ZeroExInstantProps, state: State = INITIAL_STATE): State { - const network = props.network || state.network; + const networkId = props.networkId || state.network; // TODO: Provider needs to not be hard-coded to injected web3. const provider = getProvider(); const assetBuyerOptions = { - networkId: network, + networkId, }; let assetBuyer; if (_.isString(props.liquiditySource)) { @@ -60,8 +60,8 @@ export class ZeroExInstant extends React.Component<ZeroExInstantProps> { const storeStateFromProps: State = { ...state, assetBuyer, - network, - selectedAsset: assetUtils.createAssetFromAssetData(props.assetData, completeAssetMetaDataMap, network), + network: networkId, + selectedAsset: assetUtils.createAssetFromAssetData(props.assetData, completeAssetMetaDataMap, networkId), selectedAssetAmount: _.isUndefined(props.defaultAssetBuyAmount) ? state.selectedAssetAmount : new BigNumber(props.defaultAssetBuyAmount), |