@xyo-network/react-gas-price 5.2.1 → 5.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -198,11 +198,11 @@ var GasFeeCard = /* @__PURE__ */ __name(({ gasPrice, speedPaperElevation, priori
198
198
  rowGap: 2
199
199
  }
200
200
  }, /* @__PURE__ */ React10.createElement(FlexGrowCol2, {
201
- bgcolor: theme.palette.secondary.dark,
201
+ bgcolor: theme.vars.palette.secondary.dark,
202
202
  alignItems: "start",
203
203
  p: 2,
204
204
  rowGap: 1.5,
205
- color: theme.palette.common.white
205
+ color: theme.vars.palette.common.white
206
206
  }, /* @__PURE__ */ React10.createElement(GasPriceBox, {
207
207
  gasPrice
208
208
  }), priorityFee ? /* @__PURE__ */ React10.createElement(PriorityFeeBox, {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/Avatar/EthereumGasPriceAvatar.tsx","../../src/components/CardHeader/CardHeader.tsx","../../src/components/HeaderComponents/Actions.tsx","../../src/components/HeaderComponents/Header/Header.tsx","../../src/components/HeaderComponents/Header/Heading.tsx","../../src/components/layout/Header.tsx","../../src/components/layout/StyledCardHeader.tsx","../../src/components/GasFees/Card.tsx","../../src/components/GasFees/components/GasPriceBox.tsx","../../src/components/GasFees/components/GweiLabelTypography.tsx","../../src/components/GasFees/components/PriorityFeeBox.tsx","../../src/components/GasFees/components/SpeedBox.tsx","../../src/components/HeaderBox.tsx","../../src/components/RawPayload/ToggleRawPayloadBox.tsx"],"sourcesContent":["import { LocalGasStationRounded as LocalGasStationRoundedIcon } from '@mui/icons-material'\nimport type { AvatarProps } from '@mui/material'\nimport { Avatar } from '@mui/material'\nimport React from 'react'\n\nexport const EthereumGasPriceAvatar: React.FC<AvatarProps> = ({ ...props }) => {\n return (\n <Avatar {...props}>\n <LocalGasStationRoundedIcon />\n </Avatar>\n )\n}\n","import type { CardProps } from '@mui/material'\nimport React from 'react'\n\nimport type { GasPriceWitnessUIBasePayload } from '../../types/index.ts'\nimport { GasPriceHeaderActionsBox, GasPriceHeaderTypography } from '../HeaderComponents/index.ts'\nimport { StyledCardHeader } from '../layout/index.ts'\n\nexport interface GasPriceCardHeaderProps extends CardProps {\n parsedPayload?: GasPriceWitnessUIBasePayload\n title?: string\n}\nexport const GasPriceWitnessCardHeader = ({\n ref, title, parsedPayload, ...props\n}: GasPriceCardHeaderProps) => (\n <StyledCardHeader\n title={<GasPriceHeaderTypography heading={title} />}\n action={(\n <GasPriceHeaderActionsBox\n timestamp={parsedPayload?.timestamp}\n baseFee={parsedPayload?.baseFee?.value}\n baseFeeLabel={parsedPayload?.baseFee?.label}\n blockNumber={parsedPayload?.blockNumber?.value}\n blockNumberLabel={parsedPayload?.blockNumber?.label}\n />\n )}\n ref={ref}\n {...props}\n />\n)\n\nGasPriceWitnessCardHeader.displayName = 'GasPriceWitnessCardHeader'\n","import { Chip } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport React from 'react'\n\nexport interface GasPriceEstimateActionsBoxProps extends FlexBoxProps {\n baseFee?: number\n baseFeeLabel?: string\n blockNumber?: number\n blockNumberLabel?: string\n timestamp?: number\n}\n\nexport const GasPriceHeaderActionsBox: React.FC<GasPriceEstimateActionsBoxProps> = ({\n baseFee,\n baseFeeLabel = 'Base Fee',\n blockNumber,\n blockNumberLabel = 'Block Number',\n timestamp,\n ...props\n}) => {\n return (\n <FlexRow columnGap={1} rowGap={1} flexWrap=\"wrap\" {...props}>\n {timestamp\n ? <Chip label={new Date(timestamp).toLocaleString()} />\n : null}\n {baseFee\n ? <Chip label={`${baseFeeLabel} - ${baseFee.toFixed(2)} GWEI`} />\n : null}\n {blockNumber\n ? <Chip label={`${blockNumberLabel} - ${blockNumber}`} />\n : null}\n </FlexRow>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { TypographyExProps } from '@xyo-network/react-shared'\nimport { getTokenData } from '@xyo-network/react-shared'\nimport type { PropsWithChildren } from 'react'\nimport React from 'react'\n\nimport { GasPriceHeadingTypography } from './Heading.tsx'\n\nexport interface GasPriceHeaderTypographyProps extends TypographyExProps, PropsWithChildren {\n heading?: string\n}\n\nexport const GasPriceHeaderTypography: React.FC<GasPriceHeaderTypographyProps> = ({\n heading, children, ...props\n}) => {\n const theme = useTheme()\n const [ethData] = getTokenData(['eth'])\n const networkIcon = <img height={theme.spacing(4)} src={ethData.icon} />\n\n return (\n <GasPriceHeadingTypography heading={heading} networkIcon={networkIcon} {...props}>\n {children}\n </GasPriceHeadingTypography>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { TypographyExProps } from '@xyo-network/react-shared'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport type { ReactNode } from 'react'\nimport React from 'react'\n\nexport interface GasPriceHeadingTypographyProps extends TypographyExProps {\n children?: ReactNode\n heading?: string\n networkIcon?: ReactNode\n}\n\nexport const GasPriceHeadingTypography: React.FC<GasPriceHeadingTypographyProps> = ({\n children, heading, networkIcon, ...props\n}) => {\n const theme = useTheme()\n return (\n <TypographyEx fontSize={theme.spacing(6)} lineHeight={1} {...props}>\n {heading}\n {' '}\n {networkIcon}\n {' '}\n {children}\n </TypographyEx>\n )\n}\n","import { styled } from '@mui/material'\nimport { FlexRow } from '@xylabs/react-flexbox'\n\nexport const StyledGasPriceHeaderBox = styled(FlexRow, { name: 'StyledGasPriceEstimateBox' })(({ theme }) => ({\n alignItems: 'end',\n columnGap: theme.spacing(2),\n flexWrap: 'wrap',\n justifyContent: 'space-between',\n justifyItems: 'space-between',\n rowGap: theme.spacing(2),\n width: '100%',\n}))\n","import { CardHeader, styled } from '@mui/material'\n\nexport const StyledCardHeader = styled(CardHeader, { name: 'StyledCardHeader' })(({ theme }) => ({\n flexWrap: 'wrap',\n rowGap: theme.spacing(2),\n}))\n","import type { CardProps } from '@mui/material'\nimport {\n Card, Paper, useTheme,\n} from '@mui/material'\nimport { FlexGrowCol } from '@xylabs/react-flexbox'\nimport { CardContentEx } from '@xyo-network/react-card'\nimport React from 'react'\n\nimport {\n GasPriceBox, PriorityFeeBox, SpeedBox,\n} from './components/index.ts'\n\nexport interface GasFeeCardProps extends CardProps {\n gasPrice?: number\n priorityFee?: number\n priorityFeeLabel?: string\n speed?: string\n speedPaperElevation?: number\n}\n\nexport const GasFeeCard: React.FC<GasFeeCardProps> = ({\n gasPrice, speedPaperElevation, priorityFee, priorityFeeLabel, speed = 'low', ...props\n}) => {\n const theme = useTheme()\n\n return (\n <Card sx={{ p: 0 }} {...props}>\n <CardContentEx\n removePadding\n sx={{\n flexDirection: 'column', flexGrow: 1, p: 0, rowGap: 2,\n }}\n >\n <FlexGrowCol bgcolor={theme.palette.secondary.dark} alignItems=\"start\" p={2} rowGap={1.5} color={theme.palette.common.white}>\n <GasPriceBox gasPrice={gasPrice} />\n {priorityFee\n ? <PriorityFeeBox priorityFee={priorityFee} priorityFeeLabel={priorityFeeLabel} />\n : null}\n </FlexGrowCol>\n <Paper elevation={speedPaperElevation} sx={{ borderRadius: `0 0 ${theme.shape.borderRadius}px ${theme.shape.borderRadius}px` }}>\n <SpeedBox speed={speed} />\n </Paper>\n </CardContentEx>\n </Card>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nimport { GweiLabelTypography } from './GweiLabelTypography.tsx'\n\nexport interface GasPriceBoxProps extends FlexBoxProps {\n gasPrice?: number\n}\n\nexport const GasPriceBox: React.FC<GasPriceBoxProps> = ({ gasPrice, ...props }) => {\n const theme = useTheme()\n return (\n <FlexRow columnGap={1.5} rowGap={1.5} alignItems=\"end\" {...props}>\n <TypographyEx lineHeight={1} fontWeight=\"200\" fontSize={theme.spacing(6)} title={gasPrice?.toString() ?? ''}>\n {gasPrice?.toFixed(2)}\n </TypographyEx>\n <GweiLabelTypography fontSize={theme.spacing(2)} />\n </FlexRow>\n )\n}\n","import type { TypographyExProps } from '@xyo-network/react-shared'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nexport const GweiLabelTypography: React.FC<TypographyExProps> = props => (\n <TypographyEx variant=\"caption\" {...props}>\n GWEI\n </TypographyEx>\n)\n","import { LocalGasStationRounded as LocalGasStationRoundedIcon } from '@mui/icons-material'\nimport { useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol, FlexGrowRow } from '@xylabs/react-flexbox'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nimport { GweiLabelTypography } from './GweiLabelTypography.tsx'\n\nexport interface PriorityFeeBoxProps extends FlexBoxProps {\n priorityFee?: number\n priorityFeeLabel?: string\n}\n\nexport const PriorityFeeBox: React.FC<PriorityFeeBoxProps> = ({\n priorityFee, priorityFeeLabel = 'Priority Fee', ...props\n}) => {\n const theme = useTheme()\n\n return (\n <FlexGrowRow width=\"100%\" justifyContent=\"space-between\" alignItems=\"end\" {...props}>\n <FlexCol alignItems=\"start\">\n <TypographyEx>{priorityFeeLabel}</TypographyEx>\n <TypographyEx title={priorityFee?.toString() ?? ''}>\n {priorityFee?.toFixed(2)}\n {' '}\n <GweiLabelTypography fontSize={theme.spacing(1)} />\n </TypographyEx>\n </FlexCol>\n <LocalGasStationRoundedIcon />\n </FlexGrowRow>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexGrowCol } from '@xylabs/react-flexbox'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nexport interface SpeedBoxProps extends FlexBoxProps {\n speed?: string\n}\n\nexport const SpeedBox: React.FC<SpeedBoxProps> = ({ speed, ...props }) => {\n const theme = useTheme()\n\n return speed\n ? (\n <FlexGrowCol {...props}>\n <TypographyEx fontSize={theme.spacing(3)} fontWeight=\"200\" p={1}>\n {speed}\n </TypographyEx>\n </FlexGrowCol>\n )\n : null\n}\n","import type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport React from 'react'\n\nimport type { GasPriceWitnessUIBasePayload } from '../types/index.ts'\nimport { GasPriceHeaderActionsBox, GasPriceHeaderTypography } from './HeaderComponents/index.ts'\nimport { StyledGasPriceHeaderBox } from './layout/index.ts'\n\nexport interface GasPriceWitnessHeaderBoxProps extends FlexBoxProps {\n heading?: string\n parsedPayload?: GasPriceWitnessUIBasePayload\n}\n\nexport const GasPriceWitnessHeaderBox: React.FC<GasPriceWitnessHeaderBoxProps> = ({\n heading, parsedPayload, ...props\n}) => {\n return (\n <StyledGasPriceHeaderBox {...props}>\n <GasPriceHeaderTypography heading={heading} />\n <GasPriceHeaderActionsBox\n timestamp={parsedPayload?.timestamp}\n baseFee={parsedPayload?.baseFee?.value}\n baseFeeLabel={parsedPayload?.baseFee?.label}\n blockNumber={parsedPayload?.blockNumber?.value}\n blockNumberLabel={parsedPayload?.blockNumber?.label}\n />\n </StyledGasPriceHeaderBox>\n )\n}\n","import {\n Button, Collapse, Paper,\n} from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol } from '@xylabs/react-flexbox'\nimport React, { useState } from 'react'\n\nexport interface ToggleRawPayloadBoxProps extends FlexBoxProps {\n gasPricePayload?: object\n}\n\nexport const ToggleRawPayloadBox: React.FC<ToggleRawPayloadBoxProps> = ({ gasPricePayload, ...props }) => {\n const [collapse, setCollapse] = useState(false)\n return gasPricePayload\n ? (\n <FlexCol rowGap={1} {...props}>\n <Button\n color=\"secondary\"\n sx={{ bgcolor: 'secondary.dark', color: 'white' }}\n variant=\"contained\"\n onClick={() => setCollapse(!collapse)}\n >\n Raw Payload\n </Button>\n <Collapse in={collapse}>\n <Paper elevation={4} sx={{ p: 2 }}>\n <pre>{JSON.stringify(gasPricePayload, null, 2)}</pre>\n </Paper>\n </Collapse>\n </FlexCol>\n )\n : null\n}\n"],"mappings":";;;;AAAA,SAASA,0BAA0BC,kC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":["LocalGasStationRounded","LocalGasStationRoundedIcon","Avatar","React","EthereumGasPriceAvatar","props","Avatar","LocalGasStationRoundedIcon","React","Chip","FlexRow","React","GasPriceHeaderActionsBox","baseFee","baseFeeLabel","blockNumber","blockNumberLabel","timestamp","props","React","FlexRow","columnGap","rowGap","flexWrap","Chip","label","Date","toLocaleString","toFixed","useTheme","getTokenData","React","useTheme","TypographyEx","React","GasPriceHeadingTypography","children","heading","networkIcon","props","theme","useTheme","React","TypographyEx","fontSize","spacing","lineHeight","GasPriceHeaderTypography","heading","children","props","theme","useTheme","ethData","getTokenData","networkIcon","React","img","height","spacing","src","icon","GasPriceHeadingTypography","styled","FlexRow","StyledGasPriceHeaderBox","name","theme","alignItems","columnGap","spacing","flexWrap","justifyContent","justifyItems","rowGap","width","CardHeader","styled","StyledCardHeader","name","theme","flexWrap","rowGap","spacing","GasPriceWitnessCardHeader","ref","title","parsedPayload","props","React","StyledCardHeader","GasPriceHeaderTypography","heading","action","GasPriceHeaderActionsBox","timestamp","baseFee","value","baseFeeLabel","label","blockNumber","blockNumberLabel","displayName","Card","Paper","useTheme","FlexGrowCol","CardContentEx","React","useTheme","FlexRow","TypographyEx","React","TypographyEx","React","GweiLabelTypography","props","React","TypographyEx","variant","GasPriceBox","gasPrice","props","theme","useTheme","React","FlexRow","columnGap","rowGap","alignItems","TypographyEx","lineHeight","fontWeight","fontSize","spacing","title","toString","toFixed","GweiLabelTypography","LocalGasStationRounded","LocalGasStationRoundedIcon","useTheme","FlexCol","FlexGrowRow","TypographyEx","React","PriorityFeeBox","priorityFee","priorityFeeLabel","props","theme","useTheme","React","FlexGrowRow","width","justifyContent","alignItems","FlexCol","TypographyEx","title","toString","toFixed","GweiLabelTypography","fontSize","spacing","LocalGasStationRoundedIcon","useTheme","FlexGrowCol","TypographyEx","React","SpeedBox","speed","props","theme","useTheme","React","FlexGrowCol","TypographyEx","fontSize","spacing","fontWeight","p","GasFeeCard","gasPrice","speedPaperElevation","priorityFee","priorityFeeLabel","speed","props","theme","useTheme","React","Card","sx","p","CardContentEx","removePadding","flexDirection","flexGrow","rowGap","FlexGrowCol","bgcolor","palette","secondary","dark","alignItems","color","common","white","GasPriceBox","PriorityFeeBox","Paper","elevation","borderRadius","shape","SpeedBox","React","GasPriceWitnessHeaderBox","heading","parsedPayload","props","React","StyledGasPriceHeaderBox","GasPriceHeaderTypography","GasPriceHeaderActionsBox","timestamp","baseFee","value","baseFeeLabel","label","blockNumber","blockNumberLabel","Button","Collapse","Paper","FlexCol","React","useState","ToggleRawPayloadBox","gasPricePayload","props","collapse","setCollapse","useState","React","FlexCol","rowGap","Button","color","sx","bgcolor","variant","onClick","Collapse","in","Paper","elevation","p","pre","JSON","stringify"]}
1
+ {"version":3,"sources":["../../src/components/Avatar/EthereumGasPriceAvatar.tsx","../../src/components/CardHeader/CardHeader.tsx","../../src/components/HeaderComponents/Actions.tsx","../../src/components/HeaderComponents/Header/Header.tsx","../../src/components/HeaderComponents/Header/Heading.tsx","../../src/components/layout/Header.tsx","../../src/components/layout/StyledCardHeader.tsx","../../src/components/GasFees/Card.tsx","../../src/components/GasFees/components/GasPriceBox.tsx","../../src/components/GasFees/components/GweiLabelTypography.tsx","../../src/components/GasFees/components/PriorityFeeBox.tsx","../../src/components/GasFees/components/SpeedBox.tsx","../../src/components/HeaderBox.tsx","../../src/components/RawPayload/ToggleRawPayloadBox.tsx"],"sourcesContent":["import { LocalGasStationRounded as LocalGasStationRoundedIcon } from '@mui/icons-material'\nimport type { AvatarProps } from '@mui/material'\nimport { Avatar } from '@mui/material'\nimport React from 'react'\n\nexport const EthereumGasPriceAvatar: React.FC<AvatarProps> = ({ ...props }) => {\n return (\n <Avatar {...props}>\n <LocalGasStationRoundedIcon />\n </Avatar>\n )\n}\n","import type { CardProps } from '@mui/material'\nimport React from 'react'\n\nimport type { GasPriceWitnessUIBasePayload } from '../../types/index.ts'\nimport { GasPriceHeaderActionsBox, GasPriceHeaderTypography } from '../HeaderComponents/index.ts'\nimport { StyledCardHeader } from '../layout/index.ts'\n\nexport interface GasPriceCardHeaderProps extends CardProps {\n parsedPayload?: GasPriceWitnessUIBasePayload\n title?: string\n}\nexport const GasPriceWitnessCardHeader = ({\n ref, title, parsedPayload, ...props\n}: GasPriceCardHeaderProps) => (\n <StyledCardHeader\n title={<GasPriceHeaderTypography heading={title} />}\n action={(\n <GasPriceHeaderActionsBox\n timestamp={parsedPayload?.timestamp}\n baseFee={parsedPayload?.baseFee?.value}\n baseFeeLabel={parsedPayload?.baseFee?.label}\n blockNumber={parsedPayload?.blockNumber?.value}\n blockNumberLabel={parsedPayload?.blockNumber?.label}\n />\n )}\n ref={ref}\n {...props}\n />\n)\n\nGasPriceWitnessCardHeader.displayName = 'GasPriceWitnessCardHeader'\n","import { Chip } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport React from 'react'\n\nexport interface GasPriceEstimateActionsBoxProps extends FlexBoxProps {\n baseFee?: number\n baseFeeLabel?: string\n blockNumber?: number\n blockNumberLabel?: string\n timestamp?: number\n}\n\nexport const GasPriceHeaderActionsBox: React.FC<GasPriceEstimateActionsBoxProps> = ({\n baseFee,\n baseFeeLabel = 'Base Fee',\n blockNumber,\n blockNumberLabel = 'Block Number',\n timestamp,\n ...props\n}) => {\n return (\n <FlexRow columnGap={1} rowGap={1} flexWrap=\"wrap\" {...props}>\n {timestamp\n ? <Chip label={new Date(timestamp).toLocaleString()} />\n : null}\n {baseFee\n ? <Chip label={`${baseFeeLabel} - ${baseFee.toFixed(2)} GWEI`} />\n : null}\n {blockNumber\n ? <Chip label={`${blockNumberLabel} - ${blockNumber}`} />\n : null}\n </FlexRow>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { TypographyExProps } from '@xyo-network/react-shared'\nimport { getTokenData } from '@xyo-network/react-shared'\nimport type { PropsWithChildren } from 'react'\nimport React from 'react'\n\nimport { GasPriceHeadingTypography } from './Heading.tsx'\n\nexport interface GasPriceHeaderTypographyProps extends TypographyExProps, PropsWithChildren {\n heading?: string\n}\n\nexport const GasPriceHeaderTypography: React.FC<GasPriceHeaderTypographyProps> = ({\n heading, children, ...props\n}) => {\n const theme = useTheme()\n const [ethData] = getTokenData(['eth'])\n const networkIcon = <img height={theme.spacing(4)} src={ethData.icon} />\n\n return (\n <GasPriceHeadingTypography heading={heading} networkIcon={networkIcon} {...props}>\n {children}\n </GasPriceHeadingTypography>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { TypographyExProps } from '@xyo-network/react-shared'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport type { ReactNode } from 'react'\nimport React from 'react'\n\nexport interface GasPriceHeadingTypographyProps extends TypographyExProps {\n children?: ReactNode\n heading?: string\n networkIcon?: ReactNode\n}\n\nexport const GasPriceHeadingTypography: React.FC<GasPriceHeadingTypographyProps> = ({\n children, heading, networkIcon, ...props\n}) => {\n const theme = useTheme()\n return (\n <TypographyEx fontSize={theme.spacing(6)} lineHeight={1} {...props}>\n {heading}\n {' '}\n {networkIcon}\n {' '}\n {children}\n </TypographyEx>\n )\n}\n","import { styled } from '@mui/material'\nimport { FlexRow } from '@xylabs/react-flexbox'\n\nexport const StyledGasPriceHeaderBox = styled(FlexRow, { name: 'StyledGasPriceEstimateBox' })(({ theme }) => ({\n alignItems: 'end',\n columnGap: theme.spacing(2),\n flexWrap: 'wrap',\n justifyContent: 'space-between',\n justifyItems: 'space-between',\n rowGap: theme.spacing(2),\n width: '100%',\n}))\n","import { CardHeader, styled } from '@mui/material'\n\nexport const StyledCardHeader = styled(CardHeader, { name: 'StyledCardHeader' })(({ theme }) => ({\n flexWrap: 'wrap',\n rowGap: theme.spacing(2),\n}))\n","import type { CardProps } from '@mui/material'\nimport {\n Card, Paper, useTheme,\n} from '@mui/material'\nimport { FlexGrowCol } from '@xylabs/react-flexbox'\nimport { CardContentEx } from '@xyo-network/react-card'\nimport React from 'react'\n\nimport {\n GasPriceBox, PriorityFeeBox, SpeedBox,\n} from './components/index.ts'\n\nexport interface GasFeeCardProps extends CardProps {\n gasPrice?: number\n priorityFee?: number\n priorityFeeLabel?: string\n speed?: string\n speedPaperElevation?: number\n}\n\nexport const GasFeeCard: React.FC<GasFeeCardProps> = ({\n gasPrice, speedPaperElevation, priorityFee, priorityFeeLabel, speed = 'low', ...props\n}) => {\n const theme = useTheme()\n\n return (\n <Card sx={{ p: 0 }} {...props}>\n <CardContentEx\n removePadding\n sx={{\n flexDirection: 'column', flexGrow: 1, p: 0, rowGap: 2,\n }}\n >\n <FlexGrowCol bgcolor={theme.vars.palette.secondary.dark} alignItems=\"start\" p={2} rowGap={1.5} color={theme.vars.palette.common.white}>\n <GasPriceBox gasPrice={gasPrice} />\n {priorityFee\n ? <PriorityFeeBox priorityFee={priorityFee} priorityFeeLabel={priorityFeeLabel} />\n : null}\n </FlexGrowCol>\n <Paper elevation={speedPaperElevation} sx={{ borderRadius: `0 0 ${theme.shape.borderRadius}px ${theme.shape.borderRadius}px` }}>\n <SpeedBox speed={speed} />\n </Paper>\n </CardContentEx>\n </Card>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nimport { GweiLabelTypography } from './GweiLabelTypography.tsx'\n\nexport interface GasPriceBoxProps extends FlexBoxProps {\n gasPrice?: number\n}\n\nexport const GasPriceBox: React.FC<GasPriceBoxProps> = ({ gasPrice, ...props }) => {\n const theme = useTheme()\n return (\n <FlexRow columnGap={1.5} rowGap={1.5} alignItems=\"end\" {...props}>\n <TypographyEx lineHeight={1} fontWeight=\"200\" fontSize={theme.spacing(6)} title={gasPrice?.toString() ?? ''}>\n {gasPrice?.toFixed(2)}\n </TypographyEx>\n <GweiLabelTypography fontSize={theme.spacing(2)} />\n </FlexRow>\n )\n}\n","import type { TypographyExProps } from '@xyo-network/react-shared'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nexport const GweiLabelTypography: React.FC<TypographyExProps> = props => (\n <TypographyEx variant=\"caption\" {...props}>\n GWEI\n </TypographyEx>\n)\n","import { LocalGasStationRounded as LocalGasStationRoundedIcon } from '@mui/icons-material'\nimport { useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol, FlexGrowRow } from '@xylabs/react-flexbox'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nimport { GweiLabelTypography } from './GweiLabelTypography.tsx'\n\nexport interface PriorityFeeBoxProps extends FlexBoxProps {\n priorityFee?: number\n priorityFeeLabel?: string\n}\n\nexport const PriorityFeeBox: React.FC<PriorityFeeBoxProps> = ({\n priorityFee, priorityFeeLabel = 'Priority Fee', ...props\n}) => {\n const theme = useTheme()\n\n return (\n <FlexGrowRow width=\"100%\" justifyContent=\"space-between\" alignItems=\"end\" {...props}>\n <FlexCol alignItems=\"start\">\n <TypographyEx>{priorityFeeLabel}</TypographyEx>\n <TypographyEx title={priorityFee?.toString() ?? ''}>\n {priorityFee?.toFixed(2)}\n {' '}\n <GweiLabelTypography fontSize={theme.spacing(1)} />\n </TypographyEx>\n </FlexCol>\n <LocalGasStationRoundedIcon />\n </FlexGrowRow>\n )\n}\n","import { useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexGrowCol } from '@xylabs/react-flexbox'\nimport { TypographyEx } from '@xyo-network/react-shared'\nimport React from 'react'\n\nexport interface SpeedBoxProps extends FlexBoxProps {\n speed?: string\n}\n\nexport const SpeedBox: React.FC<SpeedBoxProps> = ({ speed, ...props }) => {\n const theme = useTheme()\n\n return speed\n ? (\n <FlexGrowCol {...props}>\n <TypographyEx fontSize={theme.spacing(3)} fontWeight=\"200\" p={1}>\n {speed}\n </TypographyEx>\n </FlexGrowCol>\n )\n : null\n}\n","import type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport React from 'react'\n\nimport type { GasPriceWitnessUIBasePayload } from '../types/index.ts'\nimport { GasPriceHeaderActionsBox, GasPriceHeaderTypography } from './HeaderComponents/index.ts'\nimport { StyledGasPriceHeaderBox } from './layout/index.ts'\n\nexport interface GasPriceWitnessHeaderBoxProps extends FlexBoxProps {\n heading?: string\n parsedPayload?: GasPriceWitnessUIBasePayload\n}\n\nexport const GasPriceWitnessHeaderBox: React.FC<GasPriceWitnessHeaderBoxProps> = ({\n heading, parsedPayload, ...props\n}) => {\n return (\n <StyledGasPriceHeaderBox {...props}>\n <GasPriceHeaderTypography heading={heading} />\n <GasPriceHeaderActionsBox\n timestamp={parsedPayload?.timestamp}\n baseFee={parsedPayload?.baseFee?.value}\n baseFeeLabel={parsedPayload?.baseFee?.label}\n blockNumber={parsedPayload?.blockNumber?.value}\n blockNumberLabel={parsedPayload?.blockNumber?.label}\n />\n </StyledGasPriceHeaderBox>\n )\n}\n","import {\n Button, Collapse, Paper,\n} from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol } from '@xylabs/react-flexbox'\nimport React, { useState } from 'react'\n\nexport interface ToggleRawPayloadBoxProps extends FlexBoxProps {\n gasPricePayload?: object\n}\n\nexport const ToggleRawPayloadBox: React.FC<ToggleRawPayloadBoxProps> = ({ gasPricePayload, ...props }) => {\n const [collapse, setCollapse] = useState(false)\n return gasPricePayload\n ? (\n <FlexCol rowGap={1} {...props}>\n <Button\n color=\"secondary\"\n sx={{ bgcolor: 'secondary.dark', color: 'white' }}\n variant=\"contained\"\n onClick={() => setCollapse(!collapse)}\n >\n Raw Payload\n </Button>\n <Collapse in={collapse}>\n <Paper elevation={4} sx={{ p: 2 }}>\n <pre>{JSON.stringify(gasPricePayload, null, 2)}</pre>\n </Paper>\n </Collapse>\n </FlexCol>\n )\n : null\n}\n"],"mappings":";;;;AAAA,SAASA,0BAA0BC,kCAAkC;AAErE,SAASC,cAAc;AACvB,OAAOC,WAAW;AAEX,IAAMC,yBAAgD,wBAAC,EAAE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","props","Avatar","LocalGasStationRoundedIcon","React","Chip","FlexRow","React","GasPriceHeaderActionsBox","baseFee","baseFeeLabel","blockNumber","blockNumberLabel","timestamp","props","React","FlexRow","columnGap","rowGap","flexWrap","Chip","label","Date","toLocaleString","toFixed","useTheme","getTokenData","React","useTheme","TypographyEx","React","GasPriceHeadingTypography","children","heading","networkIcon","props","theme","useTheme","React","TypographyEx","fontSize","spacing","lineHeight","GasPriceHeaderTypography","heading","children","props","theme","useTheme","ethData","getTokenData","networkIcon","React","img","height","spacing","src","icon","GasPriceHeadingTypography","styled","FlexRow","StyledGasPriceHeaderBox","name","theme","alignItems","columnGap","spacing","flexWrap","justifyContent","justifyItems","rowGap","width","CardHeader","styled","StyledCardHeader","name","theme","flexWrap","rowGap","spacing","GasPriceWitnessCardHeader","ref","title","parsedPayload","props","React","StyledCardHeader","GasPriceHeaderTypography","heading","action","GasPriceHeaderActionsBox","timestamp","baseFee","value","baseFeeLabel","label","blockNumber","blockNumberLabel","displayName","Card","Paper","useTheme","FlexGrowCol","CardContentEx","React","useTheme","FlexRow","TypographyEx","React","TypographyEx","React","GweiLabelTypography","props","React","TypographyEx","variant","GasPriceBox","gasPrice","props","theme","useTheme","React","FlexRow","columnGap","rowGap","alignItems","TypographyEx","lineHeight","fontWeight","fontSize","spacing","title","toString","toFixed","GweiLabelTypography","LocalGasStationRounded","LocalGasStationRoundedIcon","useTheme","FlexCol","FlexGrowRow","TypographyEx","React","PriorityFeeBox","priorityFee","priorityFeeLabel","props","theme","useTheme","React","FlexGrowRow","width","justifyContent","alignItems","FlexCol","TypographyEx","title","toString","toFixed","GweiLabelTypography","fontSize","spacing","LocalGasStationRoundedIcon","useTheme","FlexGrowCol","TypographyEx","React","SpeedBox","speed","props","theme","useTheme","React","FlexGrowCol","TypographyEx","fontSize","spacing","fontWeight","p","GasFeeCard","gasPrice","speedPaperElevation","priorityFee","priorityFeeLabel","speed","props","theme","useTheme","React","Card","sx","p","CardContentEx","removePadding","flexDirection","flexGrow","rowGap","FlexGrowCol","bgcolor","vars","palette","secondary","dark","alignItems","color","common","white","GasPriceBox","PriorityFeeBox","Paper","elevation","borderRadius","shape","SpeedBox","React","GasPriceWitnessHeaderBox","heading","parsedPayload","props","React","StyledGasPriceHeaderBox","GasPriceHeaderTypography","GasPriceHeaderActionsBox","timestamp","baseFee","value","baseFeeLabel","label","blockNumber","blockNumberLabel","Button","Collapse","Paper","FlexCol","React","useState","ToggleRawPayloadBox","gasPricePayload","props","collapse","setCollapse","useState","React","FlexCol","rowGap","Button","color","sx","bgcolor","variant","onClick","Collapse","in","Paper","elevation","p","pre","JSON","stringify"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xyo-network/react-gas-price",
3
- "version": "5.2.1",
3
+ "version": "5.2.3",
4
4
  "description": "Common React library for all XYO projects that use React",
5
5
  "keywords": [
6
6
  "xyo",
@@ -39,17 +39,17 @@
39
39
  "module": "dist/browser/index.mjs",
40
40
  "types": "dist/types/index.d.ts",
41
41
  "dependencies": {
42
- "@xylabs/react-flexbox": "^6.2.1",
43
- "@xyo-network/react-card": "^5.2.1",
44
- "@xyo-network/react-shared": "^5.2.1"
42
+ "@xylabs/react-flexbox": "^6.2.8",
43
+ "@xyo-network/react-card": "^5.2.3",
44
+ "@xyo-network/react-shared": "^5.2.3"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@mui/icons-material": "^7.0.2",
48
48
  "@mui/material": "^7.0.2",
49
49
  "@storybook/react": "^8.6.12",
50
50
  "@types/react": "^19.1.2",
51
- "@xylabs/ts-scripts-yarn3": "^6.2.1",
52
- "@xylabs/tsconfig-react": "^6.2.1",
51
+ "@xylabs/ts-scripts-yarn3": "^6.3.5",
52
+ "@xylabs/tsconfig-react": "^6.3.5",
53
53
  "react": "^19.1.0",
54
54
  "react-dom": "^19.1.0",
55
55
  "storybook": "^8.6.12",
@@ -31,7 +31,7 @@ export const GasFeeCard: React.FC<GasFeeCardProps> = ({
31
31
  flexDirection: 'column', flexGrow: 1, p: 0, rowGap: 2,
32
32
  }}
33
33
  >
34
- <FlexGrowCol bgcolor={theme.palette.secondary.dark} alignItems="start" p={2} rowGap={1.5} color={theme.palette.common.white}>
34
+ <FlexGrowCol bgcolor={theme.vars.palette.secondary.dark} alignItems="start" p={2} rowGap={1.5} color={theme.vars.palette.common.white}>
35
35
  <GasPriceBox gasPrice={gasPrice} />
36
36
  {priorityFee
37
37
  ? <PriorityFeeBox priorityFee={priorityFee} priorityFeeLabel={priorityFeeLabel} />
@@ -0,0 +1 @@
1
+ import type {} from '@mui/material/themeCssVarsAugmentation'