fix(governance): fixes settlement oracle display in governance (#4534)
This commit is contained in:
parent
5ed1befc53
commit
bf4fb29fe6
@ -9,6 +9,7 @@ NX_VEGA_NETWORKS='{"DEVNET":"https://dev.governance.vega.xyz","STAGNET1":"https:
|
|||||||
NX_GITHUB_FEEDBACK_URL=https://github.com/vegaprotocol/feedback/discussions
|
NX_GITHUB_FEEDBACK_URL=https://github.com/vegaprotocol/feedback/discussions
|
||||||
NX_VEGA_WALLET_URL=http://localhost:1789
|
NX_VEGA_WALLET_URL=http://localhost:1789
|
||||||
NX_VEGA_EXPLORER_URL=https://explorer.stagnet1.vega.rocks
|
NX_VEGA_EXPLORER_URL=https://explorer.stagnet1.vega.rocks
|
||||||
|
NX_ORACLE_PROOFS_URL=https://raw.githubusercontent.com/vegaprotocol/well-known/main/__generated__/oracle-proofs.json
|
||||||
|
|
||||||
NX_HOSTED_WALLET_URL=https://wallet.testnet.vega.xyz
|
NX_HOSTED_WALLET_URL=https://wallet.testnet.vega.xyz
|
||||||
NX_VEGA_DOCS_URL=https://docs.vega.xyz/testnet
|
NX_VEGA_DOCS_URL=https://docs.vega.xyz/testnet
|
||||||
|
@ -25,7 +25,7 @@ import {
|
|||||||
} from '@vegaprotocol/ui-toolkit';
|
} from '@vegaprotocol/ui-toolkit';
|
||||||
import { SubHeading } from '../../../../components/heading';
|
import { SubHeading } from '../../../../components/heading';
|
||||||
import { CollapsibleToggle } from '../../../../components/collapsible-toggle';
|
import { CollapsibleToggle } from '../../../../components/collapsible-toggle';
|
||||||
import type { MarketInfoWithData } from '@vegaprotocol/markets';
|
import type { MarketInfo } from '@vegaprotocol/markets';
|
||||||
import type { DataSourceDefinition } from '@vegaprotocol/types';
|
import type { DataSourceDefinition } from '@vegaprotocol/types';
|
||||||
import { create } from 'zustand';
|
import { create } from 'zustand';
|
||||||
|
|
||||||
@ -47,8 +47,8 @@ export const ProposalMarketData = ({
|
|||||||
marketData,
|
marketData,
|
||||||
parentMarketData,
|
parentMarketData,
|
||||||
}: {
|
}: {
|
||||||
marketData: MarketInfoWithData;
|
marketData: MarketInfo;
|
||||||
parentMarketData?: MarketInfoWithData;
|
parentMarketData?: MarketInfo;
|
||||||
}) => {
|
}) => {
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
const { isOpen, open, close } = useMarketDataDialogStore();
|
const { isOpen, open, close } = useMarketDataDialogStore();
|
||||||
|
@ -13,7 +13,7 @@ import Routes from '../../../routes';
|
|||||||
import { ProposalMarketData } from '../proposal-market-data';
|
import { ProposalMarketData } from '../proposal-market-data';
|
||||||
import type { ProposalFieldsFragment } from '../../proposals/__generated__/Proposals';
|
import type { ProposalFieldsFragment } from '../../proposals/__generated__/Proposals';
|
||||||
import type { ProposalQuery } from '../../proposal/__generated__/Proposal';
|
import type { ProposalQuery } from '../../proposal/__generated__/Proposal';
|
||||||
import type { MarketInfoWithData } from '@vegaprotocol/markets';
|
import type { MarketInfo } from '@vegaprotocol/markets';
|
||||||
import type { AssetQuery } from '@vegaprotocol/assets';
|
import type { AssetQuery } from '@vegaprotocol/assets';
|
||||||
import { removePaginationWrapper } from '@vegaprotocol/utils';
|
import { removePaginationWrapper } from '@vegaprotocol/utils';
|
||||||
import { ProposalState } from '@vegaprotocol/types';
|
import { ProposalState } from '@vegaprotocol/types';
|
||||||
@ -31,8 +31,8 @@ export enum ProposalType {
|
|||||||
export interface ProposalProps {
|
export interface ProposalProps {
|
||||||
proposal: ProposalFieldsFragment | ProposalQuery['proposal'];
|
proposal: ProposalFieldsFragment | ProposalQuery['proposal'];
|
||||||
networkParams: Partial<NetworkParamsResult>;
|
networkParams: Partial<NetworkParamsResult>;
|
||||||
newMarketData?: MarketInfoWithData | null;
|
newMarketData?: MarketInfo | null;
|
||||||
parentMarketData?: MarketInfoWithData | null;
|
parentMarketData?: MarketInfo | null;
|
||||||
assetData?: AssetQuery | null;
|
assetData?: AssetQuery | null;
|
||||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||||
restData: any;
|
restData: any;
|
||||||
|
@ -8,7 +8,7 @@ import { useProposalQuery } from './__generated__/Proposal';
|
|||||||
import { useFetch } from '@vegaprotocol/react-helpers';
|
import { useFetch } from '@vegaprotocol/react-helpers';
|
||||||
import { ENV } from '../../../config';
|
import { ENV } from '../../../config';
|
||||||
import { useDataProvider } from '@vegaprotocol/data-provider';
|
import { useDataProvider } from '@vegaprotocol/data-provider';
|
||||||
import { marketInfoWithDataProvider } from '@vegaprotocol/markets';
|
import { marketInfoProvider } from '@vegaprotocol/markets';
|
||||||
import { useAssetQuery } from '@vegaprotocol/assets';
|
import { useAssetQuery } from '@vegaprotocol/assets';
|
||||||
import {
|
import {
|
||||||
NetworkParams,
|
NetworkParams,
|
||||||
@ -95,7 +95,7 @@ export const ProposalContainer = () => {
|
|||||||
loading: newMarketLoading,
|
loading: newMarketLoading,
|
||||||
error: newMarketError,
|
error: newMarketError,
|
||||||
} = useDataProvider({
|
} = useDataProvider({
|
||||||
dataProvider: marketInfoWithDataProvider,
|
dataProvider: marketInfoProvider,
|
||||||
skipUpdates: true,
|
skipUpdates: true,
|
||||||
variables: {
|
variables: {
|
||||||
marketId: data?.proposal?.id || '',
|
marketId: data?.proposal?.id || '',
|
||||||
@ -109,12 +109,9 @@ export const ProposalContainer = () => {
|
|||||||
error: parentMarketIdError,
|
error: parentMarketIdError,
|
||||||
} = useParentMarketIdQuery({
|
} = useParentMarketIdQuery({
|
||||||
variables: {
|
variables: {
|
||||||
marketId: newMarketData?.data?.market?.id || '',
|
marketId: newMarketData?.id || '',
|
||||||
},
|
},
|
||||||
skip:
|
skip: !FLAGS.SUCCESSOR_MARKETS || !isSuccessor || !newMarketData?.id,
|
||||||
!FLAGS.SUCCESSOR_MARKETS ||
|
|
||||||
!isSuccessor ||
|
|
||||||
!newMarketData?.data?.market?.id,
|
|
||||||
});
|
});
|
||||||
|
|
||||||
const {
|
const {
|
||||||
@ -122,7 +119,7 @@ export const ProposalContainer = () => {
|
|||||||
loading: parentMarketLoading,
|
loading: parentMarketLoading,
|
||||||
error: parentMarketError,
|
error: parentMarketError,
|
||||||
} = useDataProvider({
|
} = useDataProvider({
|
||||||
dataProvider: marketInfoWithDataProvider,
|
dataProvider: marketInfoProvider,
|
||||||
skipUpdates: true,
|
skipUpdates: true,
|
||||||
variables: {
|
variables: {
|
||||||
marketId: parentMarketId?.market?.parentMarketID || '',
|
marketId: parentMarketId?.market?.parentMarketID || '',
|
||||||
|
Loading…
Reference in New Issue
Block a user