@0xsquid/ui 2.7.0 → 2.7.1-dex-beta.1

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.
Files changed (31) hide show
  1. package/dist/cjs/index.js +55 -17
  2. package/dist/cjs/types/components/badges/PriceChange.d.ts +3 -1
  3. package/dist/cjs/types/components/buttons/IconButton.d.ts +2 -0
  4. package/dist/cjs/types/components/charts/DexChart.d.ts +32 -0
  5. package/dist/cjs/types/components/charts/index.d.ts +1 -0
  6. package/dist/cjs/types/components/index.d.ts +1 -0
  7. package/dist/cjs/types/components/layout/TokenDetailsView.d.ts +6 -1
  8. package/dist/cjs/types/components/navigation/Tabs.d.ts +5 -2
  9. package/dist/cjs/types/stories/buttons/IconButon.stories.d.ts +1 -1
  10. package/dist/cjs/types/stories/charts/DexChart.stories.d.ts +10 -0
  11. package/dist/cjs/types/stories/controls/Input.stories.d.ts +1 -1
  12. package/dist/cjs/types/stories/controls/LargeNumericInput.stories.d.ts +6 -0
  13. package/dist/cjs/types/stories/layout/SwapConfiguration.stories.d.ts +2 -0
  14. package/dist/cjs/types/stories/navigation/Tabs.stories.d.ts +1 -0
  15. package/dist/esm/index.js +54 -18
  16. package/dist/esm/types/components/badges/PriceChange.d.ts +3 -1
  17. package/dist/esm/types/components/buttons/IconButton.d.ts +2 -0
  18. package/dist/esm/types/components/charts/DexChart.d.ts +32 -0
  19. package/dist/esm/types/components/charts/index.d.ts +1 -0
  20. package/dist/esm/types/components/index.d.ts +1 -0
  21. package/dist/esm/types/components/layout/TokenDetailsView.d.ts +6 -1
  22. package/dist/esm/types/components/navigation/Tabs.d.ts +5 -2
  23. package/dist/esm/types/stories/buttons/IconButon.stories.d.ts +1 -1
  24. package/dist/esm/types/stories/charts/DexChart.stories.d.ts +10 -0
  25. package/dist/esm/types/stories/controls/Input.stories.d.ts +1 -1
  26. package/dist/esm/types/stories/controls/LargeNumericInput.stories.d.ts +6 -0
  27. package/dist/esm/types/stories/layout/SwapConfiguration.stories.d.ts +2 -0
  28. package/dist/esm/types/stories/navigation/Tabs.stories.d.ts +1 -0
  29. package/dist/index.css +1 -1
  30. package/dist/index.d.ts +47 -5
  31. package/package.json +1 -1
package/dist/cjs/index.js CHANGED
@@ -4701,14 +4701,23 @@ const priceChangeSignToIconMap = {
4701
4701
  [PriceChangeSign.NEGATIVE]: (jsxRuntime.jsx(ArrowTriangle, { className: "tw-text-status-negative" })),
4702
4702
  [PriceChangeSign.NEUTRAL]: jsxRuntime.jsx(PauseIcon, {}),
4703
4703
  };
4704
- function PriceChange({ value: rawValue = 0, variant = "small", }) {
4704
+ const priceChangeSignToTextColorMap = {
4705
+ [PriceChangeSign.POSITIVE]: "tw-text-status-positive",
4706
+ [PriceChangeSign.NEGATIVE]: "tw-text-status-negative",
4707
+ [PriceChangeSign.NEUTRAL]: "tw-text-grey-500",
4708
+ };
4709
+ function PriceChange({ value: rawValue = 0, variant = "small", highlightText = false, triangleAsPrefix = false, }) {
4705
4710
  const valueFormatted = Math.abs(Number(rawValue)).toFixed(2);
4706
4711
  const sign = Number(rawValue) > 0
4707
4712
  ? PriceChangeSign.POSITIVE
4708
4713
  : Number(rawValue) < 0
4709
4714
  ? PriceChangeSign.NEGATIVE
4710
4715
  : PriceChangeSign.NEUTRAL;
4711
- return (jsxRuntime.jsx("div", { className: "tw-flex tw-h-squid-xs tw-items-center tw-justify-end tw-text-grey-500", children: jsxRuntime.jsxs("div", { className: "tw-flex tw-items-center tw-justify-center", children: [variant === "small" ? (jsxRuntime.jsx(CaptionText, { className: valueWrapperClassName, children: valueFormatted })) : (jsxRuntime.jsx(BodyText, { size: "small", className: valueWrapperClassName, children: valueFormatted })), jsxRuntime.jsx(CaptionText, { className: "!tw-leading-[10px] tw-text-grey-600", children: "%" }), priceChangeSignToIconMap[sign]] }) }));
4716
+ const textColorClass = highlightText
4717
+ ? priceChangeSignToTextColorMap[sign]
4718
+ : "tw-text-grey-500";
4719
+ const triangle = priceChangeSignToIconMap[sign];
4720
+ return (jsxRuntime.jsx("div", { className: cn("tw-flex tw-h-squid-xs tw-items-center tw-justify-end", textColorClass), children: jsxRuntime.jsxs("div", { className: "tw-flex tw-items-center tw-justify-center tw-gap-[2px]", children: [triangleAsPrefix && triangle, variant === "small" ? (jsxRuntime.jsx(CaptionText, { className: valueWrapperClassName, children: valueFormatted })) : (jsxRuntime.jsx(BodyText, { size: "small", className: valueWrapperClassName, children: valueFormatted })), variant === "small" ? (jsxRuntime.jsx(CaptionText, { className: cn("!tw-leading-[10px]", highlightText ? textColorClass : "tw-text-grey-600"), children: "%" })) : (jsxRuntime.jsx(BodyText, { size: "small", className: cn("!tw-leading-[10px]", highlightText ? textColorClass : "tw-text-grey-600"), children: "%" }))] }) }));
4712
4721
  }
4713
4722
 
4714
4723
  const statusBgClassMap$1 = {
@@ -4982,7 +4991,7 @@ function LargeNumericInput({ onChange, value }) {
4982
4991
  if (isValidAmount)
4983
4992
  onChange(value || "");
4984
4993
  }, [onChange]);
4985
- return (jsxRuntime.jsxs("section", { className: "tw-flex tw-flex-1 tw-flex-col tw-items-center tw-justify-center tw-self-stretch tw-px-squid-l tw-pb-squid-m", children: [jsxRuntime.jsxs("div", { className: "tw-relative tw-flex tw-w-full tw-flex-1 tw-items-center tw-justify-center tw-self-stretch tw-text-7xl tw-text-royal-500", children: [jsxRuntime.jsx("span", { ref: inputValueSpyRef, className: "tw-pointer-events-none tw-absolute tw-opacity-0", children: value || placeholder }), jsxRuntime.jsx("span", { children: "$" }), jsxRuntime.jsx("input", { inputMode: "decimal", pattern: "[0-9.,]*", ref: inputRef, value: value, onChange: handleInputChange, className: "tw-max-w-full tw-bg-transparent tw-placeholder-royal-500 tw-outline-none focus:tw-outline-none", placeholder: placeholder })] }), jsxRuntime.jsx("footer", { className: "tw-flex tw-h-squid-m tw-items-center tw-justify-center tw-gap-squid-xxs tw-self-stretch", children: suggestedAmounts.map((amount) => (jsxRuntime.jsx(Chip, { label: `$${amount}`, onClick: () => {
4994
+ return (jsxRuntime.jsxs("section", { className: "tw-flex tw-flex-1 tw-flex-col tw-items-center tw-justify-center tw-self-stretch tw-px-squid-l tw-pb-squid-m", children: [jsxRuntime.jsx("div", { className: "tw-relative tw-flex tw-w-full tw-flex-1 tw-items-center tw-justify-center tw-self-stretch tw-text-7xl tw-text-royal-500", children: jsxRuntime.jsxs("label", { className: "tw-flex tw-max-w-full tw-cursor-text tw-items-center tw-overflow-hidden tw-rounded-squid-l tw-px-squid-s tw-py-squid-xxs focus-within:tw-bg-material-light-thin hover:tw-bg-material-light-thin", children: [jsxRuntime.jsx("span", { ref: inputValueSpyRef, className: "tw-pointer-events-none tw-absolute tw-opacity-0", children: value || placeholder }), jsxRuntime.jsx("span", { children: "$" }), jsxRuntime.jsx("input", { inputMode: "decimal", pattern: "[0-9.,]*", ref: inputRef, value: value, onChange: handleInputChange, className: "tw-max-w-[calc(100%-3.125rem)] tw-bg-transparent tw-placeholder-royal-500 tw-outline-none focus:tw-outline-none", placeholder: placeholder })] }) }), jsxRuntime.jsx("footer", { className: "tw-flex tw-h-squid-m tw-items-center tw-justify-center tw-gap-squid-xxs tw-self-stretch", children: suggestedAmounts.map((amount) => (jsxRuntime.jsx(Chip, { label: `$${amount}`, onClick: () => {
4986
4995
  onChange(amount);
4987
4996
  } }, amount))) })] }));
4988
4997
  }
@@ -19421,7 +19430,7 @@ function ModalContentDivider() {
19421
19430
  }
19422
19431
 
19423
19432
  function ModalTitle({ title }) {
19424
- return (jsxRuntime.jsx("div", { className: "tw-flex tw-h-squid-xxl tw-items-center tw-justify-center tw-gap-squid-xs tw-self-stretch tw-px-squid-m tw-py-squid-xs", children: jsxRuntime.jsx(BodyText, { size: "small", children: title }) }));
19433
+ return (jsxRuntime.jsx("div", { className: "tw-flex tw-h-squid-xxl tw-min-h-squid-xxl tw-items-center tw-justify-center tw-gap-squid-xs tw-self-stretch tw-px-squid-m tw-py-squid-xs", children: jsxRuntime.jsx(BodyText, { size: "small", children: title }) }));
19425
19434
  }
19426
19435
 
19427
19436
  function NavigationBar(_a) {
@@ -19496,7 +19505,7 @@ function SwapConfiguration({ amount, tokenPrice = 0, isFetching: isFetchingProp
19496
19505
  ? walletButton === null || walletButton === void 0 ? void 0 : walletButton.address
19497
19506
  : walletButton === null || walletButton === void 0 ? void 0 : walletButton.emptyAddressLabel }), jsxRuntime.jsx(ChevronArrowIcon, { className: (walletButton === null || walletButton === void 0 ? void 0 : walletButton.address)
19498
19507
  ? "tw-text-grey-600"
19499
- : "tw-text-royal-500" })] })] }))] }) })) }), jsxRuntime.jsx("div", { className: "tw-px-squid-m mobile-lg:tw-px-squid-l", children: jsxRuntime.jsx(AssetsButton, Object.assign({}, assetsButton, { chain: chain, token: token, isLoading: isLoading })) }), isFetching && (jsxRuntime.jsx("div", { className: "tw-absolute tw-bottom-2 tw-left-squid-m tw-z-10 tw-overflow-hidden mobile-lg:tw-left-squid-l", children: jsxRuntime.jsx("div", { className: "tw-h-[94px] tw-w-[1260px] tw-animate-move-loading-cover-to-right tw-bg-dark-cover" }) })), jsxRuntime.jsx(NumericInput, { inputMode: "decimal", pattern: "[0-9.,]*", token: {
19508
+ : "tw-text-royal-500" })] })] }))] }) })) }), jsxRuntime.jsx("div", { className: "tw-px-squid-m mobile-lg:tw-px-squid-l", children: jsxRuntime.jsx(AssetsButton, Object.assign({}, assetsButton, { chain: chain, token: token, isLoading: isLoading })) }), jsxRuntime.jsx(NumericInput, { inputMode: "decimal", pattern: "[0-9.,]*", token: {
19500
19509
  decimals: (_a = token === null || token === void 0 ? void 0 : token.decimals) !== null && _a !== void 0 ? _a : 18,
19501
19510
  symbol: (_b = token === null || token === void 0 ? void 0 : token.symbol) !== null && _b !== void 0 ? _b : "",
19502
19511
  price: tokenPrice,
@@ -20493,8 +20502,8 @@ const TokenModalHeader = ({ token, chain, onLikeToken, onClose, isFavorite, }) =
20493
20502
  } }) }), jsxRuntime.jsxs("span", { className: "tw-absolute tw-right-squid-xs tw-top-squid-xs tw-flex tw-items-center tw-gap-squid-xxs", children: [jsxRuntime.jsx(IconButton, { className: "tw-group/token-detail-fav-icon tw-text-grey-300", onClick: onLikeToken, icon: isFavorite ? (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(FilledHeartIcon, { className: "tw-block group-hover/token-detail-fav-icon:tw-hidden" }), jsxRuntime.jsx(BrokenHeartIcon, { className: "tw-hidden group-hover/token-detail-fav-icon:tw-block" })] })) : (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(EmptyHeartIcon, { className: "tw-block group-hover/token-detail-fav-icon:tw-hidden" }), jsxRuntime.jsx(FilledHeartIcon, { className: "tw-hidden group-hover/token-detail-fav-icon:tw-block" })] })) }), jsxRuntime.jsx(IconButton, { className: "tw-text-grey-300", onClick: onClose, icon: jsxRuntime.jsx(CircleXFilledIcon, {}) })] })] }));
20494
20503
  const TokenInfo = ({ token, tokenPrice, priceChange, loading, }) => (jsxRuntime.jsxs("div", { children: [jsxRuntime.jsx(BodyText, { size: "large", loading: { isLoading: loading, width: "100px" }, children: tokenPrice.toLocaleString() }), jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-row tw-items-center tw-justify-between", children: [jsxRuntime.jsx(BodyText, { size: "small", children: token.name }), jsxRuntime.jsx(PriceChange, { value: priceChange, variant: "large" })] })] }));
20495
20504
  const BalanceInfo = ({ balance, balanceUSD, token, loading, }) => (jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-col", children: [jsxRuntime.jsx(CaptionText, { className: "tw-text-grey-500", children: "Balance" }), jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-row tw-justify-between", children: [jsxRuntime.jsxs("span", { className: "tw-flex tw-flex-row tw-items-center tw-gap-squid-xxs", children: [jsxRuntime.jsx("img", { src: token.image, alt: token.name, className: "tw-h-squid-m tw-w-squid-m tw-rounded-full" }), jsxRuntime.jsxs(BodyText, { size: "small", loading: { isLoading: loading, width: "80px" }, children: [balance, " ", token.symbol] })] }), jsxRuntime.jsxs(CaptionText, { className: "tw-text-grey-500", loading: { isLoading: loading, width: "60px" }, children: [jsxRuntime.jsx("span", { className: "tw-opacity-66", children: "$" }), balanceUSD] })] })] }));
20496
- const MarketDataItem = ({ label, value, showDollar, loading, }) => (jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-col", children: [jsxRuntime.jsx(CaptionText, { className: "tw-text-grey-500", children: label }), jsxRuntime.jsxs(CaptionText, { loading: { isLoading: loading, width: "60px" }, children: [showDollar && jsxRuntime.jsx("span", { className: "tw-text-grey-500", children: "$" }), value] })] }));
20497
- const TokenMarketData = ({ volume24h, marketCap, totalSupply, loading, }) => (jsxRuntime.jsxs("div", { className: "tw-mb-squid-xs tw-flex tw-h-full tw-w-full tw-flex-row tw-items-center tw-justify-between", children: [jsxRuntime.jsx(MarketDataItem, { label: "24h volume", value: volume24h, showDollar: true, loading: loading }), jsxRuntime.jsx(MarketDataItem, { label: "Market cap", value: marketCap, showDollar: true, loading: loading }), jsxRuntime.jsx(MarketDataItem, { label: "Total supply", value: totalSupply, loading: loading })] }));
20505
+ const MarketDataItem$1 = ({ label, value, showDollar, loading, }) => (jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-col", children: [jsxRuntime.jsx(CaptionText, { className: "tw-text-grey-500", children: label }), jsxRuntime.jsxs(CaptionText, { loading: { isLoading: loading, width: "60px" }, children: [showDollar && jsxRuntime.jsx("span", { className: "tw-text-grey-500", children: "$" }), value] })] }));
20506
+ const TokenMarketData = ({ volume24h, marketCap, totalSupply, loading, }) => (jsxRuntime.jsxs("div", { className: "tw-mb-squid-xs tw-flex tw-h-full tw-w-full tw-flex-row tw-items-center tw-justify-between", children: [jsxRuntime.jsx(MarketDataItem$1, { label: "24h volume", value: volume24h, showDollar: true, loading: loading }), jsxRuntime.jsx(MarketDataItem$1, { label: "Market cap", value: marketCap, showDollar: true, loading: loading }), jsxRuntime.jsx(MarketDataItem$1, { label: "Total supply", value: totalSupply, loading: loading })] }));
20498
20507
  const FooterButton = (_a) => {
20499
20508
  var { icon, label } = _a, props = __rest$1(_a, ["icon", "label"]);
20500
20509
  return (jsxRuntime.jsx("div", { className: "tw-flex tw-h-full tw-w-full tw-flex-1 tw-flex-col tw-items-center tw-justify-center tw-gap-squid-xs tw-p-squid-xxs", children: jsxRuntime.jsxs("button", Object.assign({}, props, { className: cn("tw-flex tw-h-full tw-w-full tw-flex-col tw-items-center tw-justify-center tw-gap-squid-xs tw-rounded-squid-m", !props.disabled && "hover:tw-bg-material-light-thin"), children: [jsxRuntime.jsx("span", { className: "tw-flex tw-h-squid-xl tw-w-squid-xl tw-items-center tw-justify-center tw-rounded-full tw-border tw-border-material-light-thin tw-text-grey-900 tw-shadow-elevation-light-1", style: props.disabled
@@ -27935,9 +27944,9 @@ function NumericInput(_a) {
27935
27944
  }, [userInputType, balance, token.price]);
27936
27945
  const containerClassname = "tw-px-squid-xs !tw-h-full tw-pt-squid-xxs mobile-xs-height:tw-pb-squid-s tw-text-heading-small tw-font-regular mobile-lg:tw-px-squid-m tw-relative tw-h-[65px] mobile-sm-height:tw-h-[75px]";
27937
27946
  const inputRef = React$1.useRef(null);
27938
- return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [isInteractive && !isLoading ? (jsxRuntime.jsxs("form", { className: containerClassname, onSubmit: (e) => {
27947
+ return (jsxRuntime.jsxs("div", { className: "tw-relative tw-flex tw-w-full tw-flex-col", children: [isLoading && (jsxRuntime.jsx("div", { className: "tw-pointer-events-none tw-absolute tw-inset-0 tw-top-squid-xxs tw-z-10 tw-overflow-hidden", children: jsxRuntime.jsx("div", { className: "tw-h-full tw-w-[78.75rem] tw-animate-move-loading-cover-to-right tw-bg-dark-cover" }) })), isInteractive && !isLoading ? (jsxRuntime.jsxs("form", { className: containerClassname, onSubmit: (e) => {
27939
27948
  e.preventDefault();
27940
- }, children: [userInputType === UserInputType.USD && (jsxRuntime.jsx("span", { className: "tw-absolute tw-left-5 tw-top-[11px] tw-leading-[43px] tw-text-grey-600 mobile-lg:tw-left-[30px]", children: "$" })), jsxRuntime.jsx("input", Object.assign({ ref: inputRef, type: "text", value: inputValue, onChange: handleInputChange, placeholder: "0", className: cn("tw-h-[55px] tw-w-full tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-grey-300 placeholder:tw-text-grey-600 hover:tw-bg-material-light-thin focus:tw-bg-material-light-thin focus:tw-text-royal-500 focus:tw-outline-none", userInputType === UserInputType.USD && "tw-pl-[33px]") }, props))] })) : (jsxRuntime.jsx("div", { className: cn(containerClassname, (isLoading || Number(inputValue || 0) === 0) && loadingClassName), children: jsxRuntime.jsx("div", { className: "tw-font-regular tw-flex tw-h-[55px] tw-w-full tw-items-center tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-heading-small tw-text-grey-300", children: jsxRuntime.jsx("span", { children: inputValue || 0 }) }) })), !showDetails ? null : (jsxRuntime.jsxs("footer", { className: cn("tw-flex tw-h-squid-m tw-max-h-squid-m tw-items-center tw-justify-between tw-gap-2 tw-px-squid-xs tw-text-grey-500 mobile-lg:tw-px-squid-m", isLoading && loadingClassName), children: [error ? (jsxRuntime.jsx("div", { className: "tw-px-squid-xs", children: jsxRuntime.jsx(ErrorMessage, { message: error.message }) })) : (jsxRuntime.jsx(Tooltip, Object.assign({}, (isLoading
27949
+ }, children: [userInputType === UserInputType.USD && (jsxRuntime.jsx("span", { className: "tw-absolute tw-left-5 tw-top-[11px] tw-leading-[43px] tw-text-grey-600 mobile-lg:tw-left-[30px]", children: "$" })), jsxRuntime.jsx("input", Object.assign({ ref: inputRef, type: "text", value: inputValue, onChange: handleInputChange, placeholder: "0", className: cn("tw-h-[55px] tw-w-full tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-grey-300 placeholder:tw-text-grey-600 hover:tw-bg-material-light-thin focus:tw-bg-material-light-thin focus:tw-text-royal-500 focus:tw-outline-none", userInputType === UserInputType.USD && "tw-pl-[33px]") }, props))] })) : (jsxRuntime.jsx("div", { className: cn(containerClassname, (isLoading || Number(inputValue || 0) === 0) && loadingClassName), children: jsxRuntime.jsx("div", { className: "tw-font-regular tw-flex tw-h-[55px] tw-w-full tw-cursor-default tw-items-center tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-heading-small tw-text-grey-300", children: jsxRuntime.jsx("span", { children: inputValue || 0 }) }) })), !showDetails ? null : (jsxRuntime.jsxs("footer", { className: cn("tw-flex tw-h-squid-m tw-max-h-squid-m tw-items-center tw-justify-between tw-gap-2 tw-px-squid-xs tw-text-grey-500 mobile-lg:tw-px-squid-m", isLoading && loadingClassName), children: [error ? (jsxRuntime.jsx("div", { className: "tw-px-squid-xs", children: jsxRuntime.jsx(ErrorMessage, { message: error.message }) })) : (jsxRuntime.jsx(Tooltip, Object.assign({}, (isLoading
27941
27950
  ? undefined
27942
27951
  : userInputType === UserInputType.TOKEN
27943
27952
  ? inputModeButton === null || inputModeButton === void 0 ? void 0 : inputModeButton.tokenModeTooltip
@@ -28302,8 +28311,11 @@ function FilterButton({ selected, numApplied = 0, onClick, }) {
28302
28311
  }
28303
28312
 
28304
28313
  const IconButton = React$1.forwardRef((_a, ref) => {
28305
- var { icon, disabled = false } = _a, props = __rest$1(_a, ["icon", "disabled"]);
28306
- return (jsxRuntime.jsx("button", Object.assign({}, props, { ref: ref, disabled: disabled, className: cn("tw-flex tw-h-8 tw-w-8 tw-min-w-8 tw-items-center tw-justify-center tw-rounded-squid-xs hover:tw-bg-material-light-thin", disabled ? "tw-text-grey-600" : "tw-text-grey-300", props.className), children: icon })));
28314
+ var { icon, disabled = false, size = 32, variant = "rounded" } = _a, props = __rest$1(_a, ["icon", "disabled", "size", "variant"]);
28315
+ return (jsxRuntime.jsx("button", Object.assign({}, props, { ref: ref, disabled: disabled, className: cn("tw-flex tw-items-center tw-justify-center hover:tw-bg-material-light-thin", {
28316
+ "tw-rounded-squid-xs": variant === "rounded",
28317
+ "tw-rounded-full": variant === "circle",
28318
+ }, disabled ? "tw-text-grey-600" : "tw-text-grey-300", props.className), style: Object.assign({ height: size, width: size, minWidth: size }, props.style), children: icon })));
28307
28319
  });
28308
28320
  IconButton.displayName = "IconButton";
28309
28321
 
@@ -28313,7 +28325,7 @@ function SettingsButton({ label, isSelected = false, onClick, }) {
28313
28325
 
28314
28326
  const DEFAULT_TIMING_FUNCTION = "ease-out";
28315
28327
  const DEFAULT_ANIMATION_DURATION = 0.3;
28316
- function Tabs({ tabs, size = "large", onTabChange, activeTab, }) {
28328
+ function Tabs({ tabs, size = "large", onTabChange, activeTab, isDisabled = false, }) {
28317
28329
  const [activeTabInfo, setActiveTabInfo] = React$1.useState({
28318
28330
  translateX: 0,
28319
28331
  width: 0,
@@ -28348,7 +28360,7 @@ function Tabs({ tabs, size = "large", onTabChange, activeTab, }) {
28348
28360
  return (jsxRuntime.jsxs("nav", { ref: navRef, className: "tw-relative tw-flex tw-items-center tw-gap-squid-m", children: [tabs.map((tab, index) => (React$1.createElement(Tab, Object.assign({}, tab, { key: index, size: size, onClick: (event) => {
28349
28361
  handleTabClick(event);
28350
28362
  onTabChange === null || onTabChange === void 0 ? void 0 : onTabChange(index);
28351
- }, isActive: activeTab === index })))), jsxRuntime.jsx(motion.div, { className: "tw-absolute tw-bottom-0 tw-h-0.5 tw-rounded-[1px] tw-bg-royal-500", animate: {
28363
+ }, isActive: activeTab === index, isDisabled: !!tab.isDisabled || !!isDisabled })))), !isDisabled && (jsxRuntime.jsx(motion.div, { className: "tw-absolute tw-bottom-0 tw-h-0.5 tw-rounded-[1px] tw-bg-royal-500", animate: {
28352
28364
  transform: `translateX(${activeTabInfo.translateX}px)`,
28353
28365
  width: activeTabInfo.width,
28354
28366
  animationTimingFunction: DEFAULT_TIMING_FUNCTION,
@@ -28357,14 +28369,14 @@ function Tabs({ tabs, size = "large", onTabChange, activeTab, }) {
28357
28369
  stiffness: 300,
28358
28370
  damping: 30,
28359
28371
  duration: DEFAULT_ANIMATION_DURATION,
28360
- } })] }));
28372
+ } }))] }));
28361
28373
  }
28362
28374
  function Tab(_a) {
28363
- var { label, isActive, size } = _a, props = __rest$1(_a, ["label", "isActive", "size"]);
28364
- return (jsxRuntime.jsxs("button", Object.assign({}, props, { "aria-current": isActive ? "true" : undefined, className: cn("tw-group/tab-button tw-relative tw-flex tw-w-fit tw-items-center tw-justify-center tw-self-stretch", isActive ? "tw-text-grey-300" : "tw-text-grey-600", size === "small" ? "tw-h-[50px]" : "tw-h-squid-xxl", props.className), style: {
28375
+ var { label, isActive, size, isDisabled } = _a, props = __rest$1(_a, ["label", "isActive", "size", "isDisabled"]);
28376
+ return (jsxRuntime.jsxs("button", Object.assign({}, props, { disabled: isDisabled, "aria-current": isActive ? "true" : undefined, className: cn("tw-group/tab-button tw-relative tw-flex tw-w-fit tw-items-center tw-justify-center tw-self-stretch", isActive ? "tw-text-grey-300" : "tw-text-grey-600", size === "small" ? "tw-h-[50px]" : "tw-h-squid-xxl", props.className), style: {
28365
28377
  transition: `color ${DEFAULT_ANIMATION_DURATION}s`,
28366
28378
  transitionTimingFunction: DEFAULT_TIMING_FUNCTION,
28367
- }, children: [jsxRuntime.jsx(BodyText, { size: size, children: label }), !props.disabled && (jsxRuntime.jsx("span", { className: cn("tw-absolute tw-w-[calc(100%+20px)] tw-rounded-squid-s tw-p-squid-xs group-hover/tab-button:tw-bg-material-light-thin", size === "small" ? "tw-h-squid-l" : "tw-h-squid-xl") }))] })));
28379
+ }, children: [jsxRuntime.jsx(BodyText, { size: size, children: label }), !props.disabled && (jsxRuntime.jsx("span", { className: cn("tw-absolute tw-w-[calc(100%+20px)] tw-rounded-squid-s tw-p-squid-xs", size === "small" ? "tw-h-squid-l" : "tw-h-squid-xl", !isDisabled && "group-hover/tab-button:tw-bg-material-light-thin") }))] })));
28368
28380
  }
28369
28381
 
28370
28382
  function useCountdown(initialSeconds) {
@@ -69963,6 +69975,30 @@ function TransactionView({ type, props }) {
69963
69975
  return jsxRuntime.jsx(Component, Object.assign({}, props));
69964
69976
  }
69965
69977
 
69978
+ function MarketHeader({ price, priceChange, selectedTimeSpan, onTimeSpanChange, menuItems, onMenuItemClick, onSettingsOpen, isMenuOpen, menuRef, dropdownRef, openDropdownButtonRef, isLoading, timeSpanOptions: customTimeSpanOptions, }) {
69979
+ const defaultTimeSpanOptions = ["15M", "1H", "4H", "1D", "1W"];
69980
+ const timeSpanOptions = customTimeSpanOptions !== null && customTimeSpanOptions !== void 0 ? customTimeSpanOptions : defaultTimeSpanOptions;
69981
+ return (jsxRuntime.jsxs("div", { className: "tw-flex tw-h-[80px] tw-flex-row tw-items-start tw-justify-between tw-gap-squid-xs tw-p-squid-xs", children: [jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-col tw-items-start tw-justify-between tw-gap-squid-xs tw-self-stretch tw-p-squid-xs", children: [jsxRuntime.jsx(BodyText, { tight: true, size: "large", className: "tw-text-grey-100", loading: { isLoading }, children: price }), isLoading ? (jsxRuntime.jsx(TextSkeleton, { width: "60px", className: "tw-h-5", isLoading: true })) : (jsxRuntime.jsx(PriceChange, { value: priceChange, variant: "small", highlightText: true, triangleAsPrefix: true }))] }), jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-row tw-items-center tw-justify-center", children: [timeSpanOptions.map((timeSpan) => (jsxRuntime.jsx(TimeframeChip, { label: timeSpan, isSelected: selectedTimeSpan === timeSpan, onClick: () => {
69982
+ onTimeSpanChange(timeSpan);
69983
+ } }, timeSpan))), jsxRuntime.jsx("div", { className: "tw-w-squid-xxs" }), menuItems && menuItems.length > 0 && (jsxRuntime.jsxs("div", { className: "tw-relative", children: [jsxRuntime.jsx(IconButton, { ref: openDropdownButtonRef, icon: jsxRuntime.jsx(DotGrid1x3HorizontalIcon, { size: "15" }), size: 20, variant: "circle", className: "tw-bg-grey-300 tw-text-grey-900", onClick: onSettingsOpen, "aria-label": "Open chart settings" }), isMenuOpen && (jsxRuntime.jsx(DropdownMenu, { menuRef: menuRef, dropdownRef: dropdownRef, className: "tw-absolute tw-z-50", children: menuItems.map((item) => (jsxRuntime.jsx(DropdownMenuItem, { icon: item.icon, label: item.label, onClick: () => onMenuItemClick === null || onMenuItemClick === void 0 ? void 0 : onMenuItemClick(item.id) }, item.id))) }))] }))] })] }));
69984
+ }
69985
+ function MarketChart({ children, isLoading, }) {
69986
+ if (isLoading) {
69987
+ return (jsxRuntime.jsx("div", { className: "tw-flex tw-h-full tw-items-center tw-justify-center", children: jsxRuntime.jsx(Loader, { className: "tw-text-grey-500", size: "48" }) }));
69988
+ }
69989
+ if (children) {
69990
+ return jsxRuntime.jsx("div", { className: "tw-h-full tw-w-full", children: children });
69991
+ }
69992
+ return (jsxRuntime.jsx("div", { className: "tw-flex tw-w-full tw-items-center tw-justify-center", children: jsxRuntime.jsx(BodyText, { size: "medium", className: "tw-px-squid-l tw-text-grey-500", children: "Chart placeholder - Will be implemented with a third-party library" }) }));
69993
+ }
69994
+ const MarketDataItem = ({ label, value, isLoading, }) => (jsxRuntime.jsxs("div", { className: "tw-flex tw-flex-1 tw-flex-col tw-items-start tw-justify-end tw-gap-squid-xs tw-px-squid-xs tw-py-squid-s", children: [jsxRuntime.jsx(CaptionText, { tight: true, className: "tw-text-grey-500", loading: { isLoading }, children: label }), jsxRuntime.jsx(BodyText, { tight: true, size: "small", className: "tw-text-grey-300", loading: { isLoading }, children: value })] }));
69995
+ function MarketStats({ stats, isLoading, }) {
69996
+ return (jsxRuntime.jsx("div", { className: "tw-flex tw-items-end tw-justify-start tw-border-t tw-border-material-light-thin tw-px-squid-xs tw-py-squid-xxs", children: stats.map((stat, index) => (jsxRuntime.jsx(MarketDataItem, { label: stat.label, value: stat.value, isLoading: isLoading }, index))) }));
69997
+ }
69998
+ function DexChart({ price, priceChange, selectedTimeSpan, onTimeSpanChange, menuItems, onMenuItemClick, onSettingsOpen, isMenuOpen, menuRef, dropdownRef, openDropdownButtonRef, stats, children, isLoading, className, timeSpanOptions, }) {
69999
+ return (jsxRuntime.jsxs("div", { className: cn("tw-relative tw-min-h-[300px] tw-w-full tw-min-w-[200px] tw-max-w-[1200px] tw-rounded-squid-l tw-shadow-elevation-dark-2", className), children: [jsxRuntime.jsx(MarketHeader, { price: price, priceChange: priceChange, selectedTimeSpan: selectedTimeSpan, onTimeSpanChange: onTimeSpanChange, menuItems: menuItems, onMenuItemClick: onMenuItemClick, onSettingsOpen: onSettingsOpen, isMenuOpen: isMenuOpen, menuRef: menuRef, dropdownRef: dropdownRef, openDropdownButtonRef: openDropdownButtonRef, isLoading: isLoading, timeSpanOptions: timeSpanOptions }), jsxRuntime.jsx(MarketChart, { isLoading: isLoading, children: children }), jsxRuntime.jsx(MarketStats, { stats: stats, isLoading: isLoading })] }));
70000
+ }
70001
+
69966
70002
  function ThemeProvider(_a) {
69967
70003
  var { theme = lightTheme, children, themeType = "light", settings } = _a, props = __rest$1(_a, ["theme", "children", "themeType", "settings"]);
69968
70004
  const parsedStyle = parseSquidTheme(theme, themeType);
@@ -70075,6 +70111,7 @@ exports.DashboardFast = DashboardFast;
70075
70111
  exports.DepositAddressView = DepositAddressView;
70076
70112
  exports.DescriptionBlocks = DescriptionBlocks;
70077
70113
  exports.DetailsToolbar = DetailsToolbar;
70114
+ exports.DexChart = DexChart;
70078
70115
  exports.DiscordIcon = DiscordIcon;
70079
70116
  exports.DockIconAnalytics = DockIconAnalytics;
70080
70117
  exports.DockIconCheckout = DockIconCheckout;
@@ -70250,6 +70287,7 @@ exports.ThemeProvider = ThemeProvider;
70250
70287
  exports.ThumbsUp = ThumbsUp;
70251
70288
  exports.Tick = Tick;
70252
70289
  exports.TimeFliesIcon = TimeFliesIcon;
70290
+ exports.TimeframeChip = TimeframeChip;
70253
70291
  exports.Timeline = Timeline;
70254
70292
  exports.Timestamp = Timestamp;
70255
70293
  exports.Toast = Toast;
@@ -1,6 +1,8 @@
1
1
  interface PriceChangeProps {
2
2
  variant?: "small" | "large";
3
3
  value: string | number;
4
+ highlightText?: boolean;
5
+ triangleAsPrefix?: boolean;
4
6
  }
5
- export declare function PriceChange({ value: rawValue, variant, }: PriceChangeProps): import("react/jsx-runtime").JSX.Element;
7
+ export declare function PriceChange({ value: rawValue, variant, highlightText, triangleAsPrefix, }: PriceChangeProps): import("react/jsx-runtime").JSX.Element;
6
8
  export {};
@@ -1,5 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  export interface IconButtonProps extends React.ComponentProps<"button"> {
3
3
  icon: React.ReactNode;
4
+ size?: number;
5
+ variant?: "rounded" | "circle";
4
6
  }
5
7
  export declare const IconButton: import("react").ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1,32 @@
1
+ /// <reference types="react" />
2
+ import { type Timeframe } from "../layout/TokenDetailsView";
3
+ interface MarketStat {
4
+ label: string;
5
+ value: string;
6
+ }
7
+ export interface ChartMenuItem {
8
+ id: string;
9
+ label: string;
10
+ icon?: React.ReactNode;
11
+ }
12
+ export interface DexChartProps {
13
+ price: string;
14
+ priceChange: string | number;
15
+ isPositive?: boolean;
16
+ selectedTimeSpan: Timeframe;
17
+ onTimeSpanChange: (timeSpan: Timeframe) => void;
18
+ menuItems?: ChartMenuItem[];
19
+ onMenuItemClick?: (itemId: string) => void;
20
+ onSettingsOpen?: () => void;
21
+ isMenuOpen?: boolean;
22
+ menuRef?: React.RefObject<HTMLDivElement>;
23
+ dropdownRef?: React.RefObject<HTMLDivElement>;
24
+ openDropdownButtonRef?: React.RefObject<HTMLButtonElement>;
25
+ stats: MarketStat[];
26
+ children?: React.ReactNode;
27
+ isLoading?: boolean;
28
+ className?: string;
29
+ timeSpanOptions?: Timeframe[];
30
+ }
31
+ export declare function DexChart({ price, priceChange, selectedTimeSpan, onTimeSpanChange, menuItems, onMenuItemClick, onSettingsOpen, isMenuOpen, menuRef, dropdownRef, openDropdownButtonRef, stats, children, isLoading, className, timeSpanOptions, }: DexChartProps): import("react/jsx-runtime").JSX.Element;
32
+ export {};
@@ -0,0 +1 @@
1
+ export * from "./DexChart";
@@ -7,3 +7,4 @@ export * from "./lists";
7
7
  export * from "./navigation";
8
8
  export * from "./typography";
9
9
  export * from "./views";
10
+ export * from "./charts";
@@ -10,7 +10,7 @@ interface Chain {
10
10
  name: string;
11
11
  image: string;
12
12
  }
13
- export type Timeframe = "1H" | "1D" | "1W" | "1Y";
13
+ export type Timeframe = "15M" | "1H" | "4H" | "1D" | "1W" | "1M" | "1Y";
14
14
  interface TokenDetailsViewProps {
15
15
  isOpen: boolean;
16
16
  onClose: () => void;
@@ -42,5 +42,10 @@ interface FooterButtonProps extends React.ComponentProps<"button"> {
42
42
  label: string;
43
43
  icon: React.ReactNode;
44
44
  }
45
+ export declare const TimeframeChip: ({ label, isSelected, onClick, }: {
46
+ label: Timeframe;
47
+ isSelected: boolean;
48
+ onClick: () => void;
49
+ }) => import("react/jsx-runtime").JSX.Element;
45
50
  export declare const TokenDetailsView: ({ isOpen, onClose, token, chain, tokenPrice, priceChange, balance, balanceUSD, volume24h, marketCap, totalSupply, loading, onLikeToken, isFavorite, Chart, initialTimeframe, onTimeframeChange, footerButtons, backdropStyle, colors, }: TokenDetailsViewProps) => import("react/jsx-runtime").JSX.Element;
46
51
  export {};
@@ -3,16 +3,19 @@ type TabSize = "small" | "large";
3
3
  interface TabsProps {
4
4
  tabs: Array<{
5
5
  label: string;
6
+ isDisabled?: boolean;
6
7
  }>;
7
8
  size?: TabSize;
8
9
  activeTab?: number;
9
10
  onTabChange?: (tabIndex: number) => void;
11
+ isDisabled?: boolean;
10
12
  }
11
- export declare function Tabs({ tabs, size, onTabChange, activeTab, }: TabsProps): import("react/jsx-runtime").JSX.Element;
13
+ export declare function Tabs({ tabs, size, onTabChange, activeTab, isDisabled, }: TabsProps): import("react/jsx-runtime").JSX.Element;
12
14
  interface TabProps extends React.ComponentProps<"button"> {
13
15
  label: string;
14
16
  size: TabSize;
15
17
  isActive?: boolean;
18
+ isDisabled?: boolean;
16
19
  }
17
- export declare function Tab({ label, isActive, size, ...props }: TabProps): import("react/jsx-runtime").JSX.Element;
20
+ export declare function Tab({ label, isActive, size, isDisabled, ...props }: TabProps): import("react/jsx-runtime").JSX.Element;
18
21
  export {};
@@ -1,4 +1,4 @@
1
- import { Meta, StoryObj } from "@storybook/react";
1
+ import { type Meta, type StoryObj } from "@storybook/react";
2
2
  import { IconButton } from "../../components/buttons/IconButton";
3
3
  declare const meta: Meta<typeof IconButton>;
4
4
  export default meta;
@@ -0,0 +1,10 @@
1
+ import { type Meta, type StoryObj } from "@storybook/react";
2
+ import { DexChart } from "../../components/charts/DexChart";
3
+ declare const meta: Meta<typeof DexChart>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof DexChart>;
6
+ export declare const Default: Story;
7
+ export declare const Negative: Story;
8
+ export declare const WithoutMenu: Story;
9
+ export declare const Loading: Story;
10
+ export declare const MinimalTimeSpans: Story;
@@ -1,4 +1,4 @@
1
- import { Meta, StoryObj } from "@storybook/react";
1
+ import { type Meta, type StoryObj } from "@storybook/react";
2
2
  import { Input } from "../../components/controls/Input";
3
3
  declare const meta: Meta<typeof Input>;
4
4
  export default meta;
@@ -0,0 +1,6 @@
1
+ import { type Meta, type StoryObj } from "@storybook/react";
2
+ import { LargeNumericInput } from "../../components/controls/LargeNumericInput";
3
+ declare const meta: Meta<typeof LargeNumericInput>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof meta>;
6
+ export declare const Default: Story;
@@ -4,7 +4,9 @@ declare const meta: Meta<typeof SwapConfiguration>;
4
4
  export default meta;
5
5
  type Story = StoryObj<typeof meta>;
6
6
  export declare const EmptyVariantPrimary: Story;
7
+ export declare const EmptyVariantPrimaryLoading: Story;
7
8
  export declare const EmptyVariantWithoutNumericInputDetails: Story;
9
+ export declare const WithoutNumericInputDetailsLoading: Story;
8
10
  export declare const EmptyVariantAccent: Story;
9
11
  export declare const Loading: Story;
10
12
  export declare const LoadingWithAllProps: Story;
@@ -5,3 +5,4 @@ export default meta;
5
5
  type Story = StoryObj<typeof meta>;
6
6
  export declare const Small: Story;
7
7
  export declare const Large: Story;
8
+ export declare const Disabled: Story;
package/dist/esm/index.js CHANGED
@@ -4681,14 +4681,23 @@ const priceChangeSignToIconMap = {
4681
4681
  [PriceChangeSign.NEGATIVE]: (jsx(ArrowTriangle, { className: "tw-text-status-negative" })),
4682
4682
  [PriceChangeSign.NEUTRAL]: jsx(PauseIcon, {}),
4683
4683
  };
4684
- function PriceChange({ value: rawValue = 0, variant = "small", }) {
4684
+ const priceChangeSignToTextColorMap = {
4685
+ [PriceChangeSign.POSITIVE]: "tw-text-status-positive",
4686
+ [PriceChangeSign.NEGATIVE]: "tw-text-status-negative",
4687
+ [PriceChangeSign.NEUTRAL]: "tw-text-grey-500",
4688
+ };
4689
+ function PriceChange({ value: rawValue = 0, variant = "small", highlightText = false, triangleAsPrefix = false, }) {
4685
4690
  const valueFormatted = Math.abs(Number(rawValue)).toFixed(2);
4686
4691
  const sign = Number(rawValue) > 0
4687
4692
  ? PriceChangeSign.POSITIVE
4688
4693
  : Number(rawValue) < 0
4689
4694
  ? PriceChangeSign.NEGATIVE
4690
4695
  : PriceChangeSign.NEUTRAL;
4691
- return (jsx("div", { className: "tw-flex tw-h-squid-xs tw-items-center tw-justify-end tw-text-grey-500", children: jsxs("div", { className: "tw-flex tw-items-center tw-justify-center", children: [variant === "small" ? (jsx(CaptionText, { className: valueWrapperClassName, children: valueFormatted })) : (jsx(BodyText, { size: "small", className: valueWrapperClassName, children: valueFormatted })), jsx(CaptionText, { className: "!tw-leading-[10px] tw-text-grey-600", children: "%" }), priceChangeSignToIconMap[sign]] }) }));
4696
+ const textColorClass = highlightText
4697
+ ? priceChangeSignToTextColorMap[sign]
4698
+ : "tw-text-grey-500";
4699
+ const triangle = priceChangeSignToIconMap[sign];
4700
+ return (jsx("div", { className: cn("tw-flex tw-h-squid-xs tw-items-center tw-justify-end", textColorClass), children: jsxs("div", { className: "tw-flex tw-items-center tw-justify-center tw-gap-[2px]", children: [triangleAsPrefix && triangle, variant === "small" ? (jsx(CaptionText, { className: valueWrapperClassName, children: valueFormatted })) : (jsx(BodyText, { size: "small", className: valueWrapperClassName, children: valueFormatted })), variant === "small" ? (jsx(CaptionText, { className: cn("!tw-leading-[10px]", highlightText ? textColorClass : "tw-text-grey-600"), children: "%" })) : (jsx(BodyText, { size: "small", className: cn("!tw-leading-[10px]", highlightText ? textColorClass : "tw-text-grey-600"), children: "%" }))] }) }));
4692
4701
  }
4693
4702
 
4694
4703
  const statusBgClassMap$1 = {
@@ -4962,7 +4971,7 @@ function LargeNumericInput({ onChange, value }) {
4962
4971
  if (isValidAmount)
4963
4972
  onChange(value || "");
4964
4973
  }, [onChange]);
4965
- return (jsxs("section", { className: "tw-flex tw-flex-1 tw-flex-col tw-items-center tw-justify-center tw-self-stretch tw-px-squid-l tw-pb-squid-m", children: [jsxs("div", { className: "tw-relative tw-flex tw-w-full tw-flex-1 tw-items-center tw-justify-center tw-self-stretch tw-text-7xl tw-text-royal-500", children: [jsx("span", { ref: inputValueSpyRef, className: "tw-pointer-events-none tw-absolute tw-opacity-0", children: value || placeholder }), jsx("span", { children: "$" }), jsx("input", { inputMode: "decimal", pattern: "[0-9.,]*", ref: inputRef, value: value, onChange: handleInputChange, className: "tw-max-w-full tw-bg-transparent tw-placeholder-royal-500 tw-outline-none focus:tw-outline-none", placeholder: placeholder })] }), jsx("footer", { className: "tw-flex tw-h-squid-m tw-items-center tw-justify-center tw-gap-squid-xxs tw-self-stretch", children: suggestedAmounts.map((amount) => (jsx(Chip, { label: `$${amount}`, onClick: () => {
4974
+ return (jsxs("section", { className: "tw-flex tw-flex-1 tw-flex-col tw-items-center tw-justify-center tw-self-stretch tw-px-squid-l tw-pb-squid-m", children: [jsx("div", { className: "tw-relative tw-flex tw-w-full tw-flex-1 tw-items-center tw-justify-center tw-self-stretch tw-text-7xl tw-text-royal-500", children: jsxs("label", { className: "tw-flex tw-max-w-full tw-cursor-text tw-items-center tw-overflow-hidden tw-rounded-squid-l tw-px-squid-s tw-py-squid-xxs focus-within:tw-bg-material-light-thin hover:tw-bg-material-light-thin", children: [jsx("span", { ref: inputValueSpyRef, className: "tw-pointer-events-none tw-absolute tw-opacity-0", children: value || placeholder }), jsx("span", { children: "$" }), jsx("input", { inputMode: "decimal", pattern: "[0-9.,]*", ref: inputRef, value: value, onChange: handleInputChange, className: "tw-max-w-[calc(100%-3.125rem)] tw-bg-transparent tw-placeholder-royal-500 tw-outline-none focus:tw-outline-none", placeholder: placeholder })] }) }), jsx("footer", { className: "tw-flex tw-h-squid-m tw-items-center tw-justify-center tw-gap-squid-xxs tw-self-stretch", children: suggestedAmounts.map((amount) => (jsx(Chip, { label: `$${amount}`, onClick: () => {
4966
4975
  onChange(amount);
4967
4976
  } }, amount))) })] }));
4968
4977
  }
@@ -19401,7 +19410,7 @@ function ModalContentDivider() {
19401
19410
  }
19402
19411
 
19403
19412
  function ModalTitle({ title }) {
19404
- return (jsx("div", { className: "tw-flex tw-h-squid-xxl tw-items-center tw-justify-center tw-gap-squid-xs tw-self-stretch tw-px-squid-m tw-py-squid-xs", children: jsx(BodyText, { size: "small", children: title }) }));
19413
+ return (jsx("div", { className: "tw-flex tw-h-squid-xxl tw-min-h-squid-xxl tw-items-center tw-justify-center tw-gap-squid-xs tw-self-stretch tw-px-squid-m tw-py-squid-xs", children: jsx(BodyText, { size: "small", children: title }) }));
19405
19414
  }
19406
19415
 
19407
19416
  function NavigationBar(_a) {
@@ -19476,7 +19485,7 @@ function SwapConfiguration({ amount, tokenPrice = 0, isFetching: isFetchingProp
19476
19485
  ? walletButton === null || walletButton === void 0 ? void 0 : walletButton.address
19477
19486
  : walletButton === null || walletButton === void 0 ? void 0 : walletButton.emptyAddressLabel }), jsx(ChevronArrowIcon, { className: (walletButton === null || walletButton === void 0 ? void 0 : walletButton.address)
19478
19487
  ? "tw-text-grey-600"
19479
- : "tw-text-royal-500" })] })] }))] }) })) }), jsx("div", { className: "tw-px-squid-m mobile-lg:tw-px-squid-l", children: jsx(AssetsButton, Object.assign({}, assetsButton, { chain: chain, token: token, isLoading: isLoading })) }), isFetching && (jsx("div", { className: "tw-absolute tw-bottom-2 tw-left-squid-m tw-z-10 tw-overflow-hidden mobile-lg:tw-left-squid-l", children: jsx("div", { className: "tw-h-[94px] tw-w-[1260px] tw-animate-move-loading-cover-to-right tw-bg-dark-cover" }) })), jsx(NumericInput, { inputMode: "decimal", pattern: "[0-9.,]*", token: {
19488
+ : "tw-text-royal-500" })] })] }))] }) })) }), jsx("div", { className: "tw-px-squid-m mobile-lg:tw-px-squid-l", children: jsx(AssetsButton, Object.assign({}, assetsButton, { chain: chain, token: token, isLoading: isLoading })) }), jsx(NumericInput, { inputMode: "decimal", pattern: "[0-9.,]*", token: {
19480
19489
  decimals: (_a = token === null || token === void 0 ? void 0 : token.decimals) !== null && _a !== void 0 ? _a : 18,
19481
19490
  symbol: (_b = token === null || token === void 0 ? void 0 : token.symbol) !== null && _b !== void 0 ? _b : "",
19482
19491
  price: tokenPrice,
@@ -20473,8 +20482,8 @@ const TokenModalHeader = ({ token, chain, onLikeToken, onClose, isFavorite, }) =
20473
20482
  } }) }), jsxs("span", { className: "tw-absolute tw-right-squid-xs tw-top-squid-xs tw-flex tw-items-center tw-gap-squid-xxs", children: [jsx(IconButton, { className: "tw-group/token-detail-fav-icon tw-text-grey-300", onClick: onLikeToken, icon: isFavorite ? (jsxs(Fragment, { children: [jsx(FilledHeartIcon, { className: "tw-block group-hover/token-detail-fav-icon:tw-hidden" }), jsx(BrokenHeartIcon, { className: "tw-hidden group-hover/token-detail-fav-icon:tw-block" })] })) : (jsxs(Fragment, { children: [jsx(EmptyHeartIcon, { className: "tw-block group-hover/token-detail-fav-icon:tw-hidden" }), jsx(FilledHeartIcon, { className: "tw-hidden group-hover/token-detail-fav-icon:tw-block" })] })) }), jsx(IconButton, { className: "tw-text-grey-300", onClick: onClose, icon: jsx(CircleXFilledIcon, {}) })] })] }));
20474
20483
  const TokenInfo = ({ token, tokenPrice, priceChange, loading, }) => (jsxs("div", { children: [jsx(BodyText, { size: "large", loading: { isLoading: loading, width: "100px" }, children: tokenPrice.toLocaleString() }), jsxs("div", { className: "tw-flex tw-flex-row tw-items-center tw-justify-between", children: [jsx(BodyText, { size: "small", children: token.name }), jsx(PriceChange, { value: priceChange, variant: "large" })] })] }));
20475
20484
  const BalanceInfo = ({ balance, balanceUSD, token, loading, }) => (jsxs("div", { className: "tw-flex tw-flex-col", children: [jsx(CaptionText, { className: "tw-text-grey-500", children: "Balance" }), jsxs("div", { className: "tw-flex tw-flex-row tw-justify-between", children: [jsxs("span", { className: "tw-flex tw-flex-row tw-items-center tw-gap-squid-xxs", children: [jsx("img", { src: token.image, alt: token.name, className: "tw-h-squid-m tw-w-squid-m tw-rounded-full" }), jsxs(BodyText, { size: "small", loading: { isLoading: loading, width: "80px" }, children: [balance, " ", token.symbol] })] }), jsxs(CaptionText, { className: "tw-text-grey-500", loading: { isLoading: loading, width: "60px" }, children: [jsx("span", { className: "tw-opacity-66", children: "$" }), balanceUSD] })] })] }));
20476
- const MarketDataItem = ({ label, value, showDollar, loading, }) => (jsxs("div", { className: "tw-flex tw-flex-col", children: [jsx(CaptionText, { className: "tw-text-grey-500", children: label }), jsxs(CaptionText, { loading: { isLoading: loading, width: "60px" }, children: [showDollar && jsx("span", { className: "tw-text-grey-500", children: "$" }), value] })] }));
20477
- const TokenMarketData = ({ volume24h, marketCap, totalSupply, loading, }) => (jsxs("div", { className: "tw-mb-squid-xs tw-flex tw-h-full tw-w-full tw-flex-row tw-items-center tw-justify-between", children: [jsx(MarketDataItem, { label: "24h volume", value: volume24h, showDollar: true, loading: loading }), jsx(MarketDataItem, { label: "Market cap", value: marketCap, showDollar: true, loading: loading }), jsx(MarketDataItem, { label: "Total supply", value: totalSupply, loading: loading })] }));
20485
+ const MarketDataItem$1 = ({ label, value, showDollar, loading, }) => (jsxs("div", { className: "tw-flex tw-flex-col", children: [jsx(CaptionText, { className: "tw-text-grey-500", children: label }), jsxs(CaptionText, { loading: { isLoading: loading, width: "60px" }, children: [showDollar && jsx("span", { className: "tw-text-grey-500", children: "$" }), value] })] }));
20486
+ const TokenMarketData = ({ volume24h, marketCap, totalSupply, loading, }) => (jsxs("div", { className: "tw-mb-squid-xs tw-flex tw-h-full tw-w-full tw-flex-row tw-items-center tw-justify-between", children: [jsx(MarketDataItem$1, { label: "24h volume", value: volume24h, showDollar: true, loading: loading }), jsx(MarketDataItem$1, { label: "Market cap", value: marketCap, showDollar: true, loading: loading }), jsx(MarketDataItem$1, { label: "Total supply", value: totalSupply, loading: loading })] }));
20478
20487
  const FooterButton = (_a) => {
20479
20488
  var { icon, label } = _a, props = __rest$1(_a, ["icon", "label"]);
20480
20489
  return (jsx("div", { className: "tw-flex tw-h-full tw-w-full tw-flex-1 tw-flex-col tw-items-center tw-justify-center tw-gap-squid-xs tw-p-squid-xxs", children: jsxs("button", Object.assign({}, props, { className: cn("tw-flex tw-h-full tw-w-full tw-flex-col tw-items-center tw-justify-center tw-gap-squid-xs tw-rounded-squid-m", !props.disabled && "hover:tw-bg-material-light-thin"), children: [jsx("span", { className: "tw-flex tw-h-squid-xl tw-w-squid-xl tw-items-center tw-justify-center tw-rounded-full tw-border tw-border-material-light-thin tw-text-grey-900 tw-shadow-elevation-light-1", style: props.disabled
@@ -27915,9 +27924,9 @@ function NumericInput(_a) {
27915
27924
  }, [userInputType, balance, token.price]);
27916
27925
  const containerClassname = "tw-px-squid-xs !tw-h-full tw-pt-squid-xxs mobile-xs-height:tw-pb-squid-s tw-text-heading-small tw-font-regular mobile-lg:tw-px-squid-m tw-relative tw-h-[65px] mobile-sm-height:tw-h-[75px]";
27917
27926
  const inputRef = useRef(null);
27918
- return (jsxs(Fragment, { children: [isInteractive && !isLoading ? (jsxs("form", { className: containerClassname, onSubmit: (e) => {
27927
+ return (jsxs("div", { className: "tw-relative tw-flex tw-w-full tw-flex-col", children: [isLoading && (jsx("div", { className: "tw-pointer-events-none tw-absolute tw-inset-0 tw-top-squid-xxs tw-z-10 tw-overflow-hidden", children: jsx("div", { className: "tw-h-full tw-w-[78.75rem] tw-animate-move-loading-cover-to-right tw-bg-dark-cover" }) })), isInteractive && !isLoading ? (jsxs("form", { className: containerClassname, onSubmit: (e) => {
27919
27928
  e.preventDefault();
27920
- }, children: [userInputType === UserInputType.USD && (jsx("span", { className: "tw-absolute tw-left-5 tw-top-[11px] tw-leading-[43px] tw-text-grey-600 mobile-lg:tw-left-[30px]", children: "$" })), jsx("input", Object.assign({ ref: inputRef, type: "text", value: inputValue, onChange: handleInputChange, placeholder: "0", className: cn("tw-h-[55px] tw-w-full tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-grey-300 placeholder:tw-text-grey-600 hover:tw-bg-material-light-thin focus:tw-bg-material-light-thin focus:tw-text-royal-500 focus:tw-outline-none", userInputType === UserInputType.USD && "tw-pl-[33px]") }, props))] })) : (jsx("div", { className: cn(containerClassname, (isLoading || Number(inputValue || 0) === 0) && loadingClassName), children: jsx("div", { className: "tw-font-regular tw-flex tw-h-[55px] tw-w-full tw-items-center tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-heading-small tw-text-grey-300", children: jsx("span", { children: inputValue || 0 }) }) })), !showDetails ? null : (jsxs("footer", { className: cn("tw-flex tw-h-squid-m tw-max-h-squid-m tw-items-center tw-justify-between tw-gap-2 tw-px-squid-xs tw-text-grey-500 mobile-lg:tw-px-squid-m", isLoading && loadingClassName), children: [error ? (jsx("div", { className: "tw-px-squid-xs", children: jsx(ErrorMessage, { message: error.message }) })) : (jsx(Tooltip, Object.assign({}, (isLoading
27929
+ }, children: [userInputType === UserInputType.USD && (jsx("span", { className: "tw-absolute tw-left-5 tw-top-[11px] tw-leading-[43px] tw-text-grey-600 mobile-lg:tw-left-[30px]", children: "$" })), jsx("input", Object.assign({ ref: inputRef, type: "text", value: inputValue, onChange: handleInputChange, placeholder: "0", className: cn("tw-h-[55px] tw-w-full tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-grey-300 placeholder:tw-text-grey-600 hover:tw-bg-material-light-thin focus:tw-bg-material-light-thin focus:tw-text-royal-500 focus:tw-outline-none", userInputType === UserInputType.USD && "tw-pl-[33px]") }, props))] })) : (jsx("div", { className: cn(containerClassname, (isLoading || Number(inputValue || 0) === 0) && loadingClassName), children: jsx("div", { className: "tw-font-regular tw-flex tw-h-[55px] tw-w-full tw-cursor-default tw-items-center tw-rounded-squid-s tw-bg-transparent tw-px-squid-xs tw-py-squid-s tw-text-heading-small tw-text-grey-300", children: jsx("span", { children: inputValue || 0 }) }) })), !showDetails ? null : (jsxs("footer", { className: cn("tw-flex tw-h-squid-m tw-max-h-squid-m tw-items-center tw-justify-between tw-gap-2 tw-px-squid-xs tw-text-grey-500 mobile-lg:tw-px-squid-m", isLoading && loadingClassName), children: [error ? (jsx("div", { className: "tw-px-squid-xs", children: jsx(ErrorMessage, { message: error.message }) })) : (jsx(Tooltip, Object.assign({}, (isLoading
27921
27930
  ? undefined
27922
27931
  : userInputType === UserInputType.TOKEN
27923
27932
  ? inputModeButton === null || inputModeButton === void 0 ? void 0 : inputModeButton.tokenModeTooltip
@@ -28282,8 +28291,11 @@ function FilterButton({ selected, numApplied = 0, onClick, }) {
28282
28291
  }
28283
28292
 
28284
28293
  const IconButton = forwardRef((_a, ref) => {
28285
- var { icon, disabled = false } = _a, props = __rest$1(_a, ["icon", "disabled"]);
28286
- return (jsx("button", Object.assign({}, props, { ref: ref, disabled: disabled, className: cn("tw-flex tw-h-8 tw-w-8 tw-min-w-8 tw-items-center tw-justify-center tw-rounded-squid-xs hover:tw-bg-material-light-thin", disabled ? "tw-text-grey-600" : "tw-text-grey-300", props.className), children: icon })));
28294
+ var { icon, disabled = false, size = 32, variant = "rounded" } = _a, props = __rest$1(_a, ["icon", "disabled", "size", "variant"]);
28295
+ return (jsx("button", Object.assign({}, props, { ref: ref, disabled: disabled, className: cn("tw-flex tw-items-center tw-justify-center hover:tw-bg-material-light-thin", {
28296
+ "tw-rounded-squid-xs": variant === "rounded",
28297
+ "tw-rounded-full": variant === "circle",
28298
+ }, disabled ? "tw-text-grey-600" : "tw-text-grey-300", props.className), style: Object.assign({ height: size, width: size, minWidth: size }, props.style), children: icon })));
28287
28299
  });
28288
28300
  IconButton.displayName = "IconButton";
28289
28301
 
@@ -28293,7 +28305,7 @@ function SettingsButton({ label, isSelected = false, onClick, }) {
28293
28305
 
28294
28306
  const DEFAULT_TIMING_FUNCTION = "ease-out";
28295
28307
  const DEFAULT_ANIMATION_DURATION = 0.3;
28296
- function Tabs({ tabs, size = "large", onTabChange, activeTab, }) {
28308
+ function Tabs({ tabs, size = "large", onTabChange, activeTab, isDisabled = false, }) {
28297
28309
  const [activeTabInfo, setActiveTabInfo] = useState({
28298
28310
  translateX: 0,
28299
28311
  width: 0,
@@ -28328,7 +28340,7 @@ function Tabs({ tabs, size = "large", onTabChange, activeTab, }) {
28328
28340
  return (jsxs("nav", { ref: navRef, className: "tw-relative tw-flex tw-items-center tw-gap-squid-m", children: [tabs.map((tab, index) => (createElement(Tab, Object.assign({}, tab, { key: index, size: size, onClick: (event) => {
28329
28341
  handleTabClick(event);
28330
28342
  onTabChange === null || onTabChange === void 0 ? void 0 : onTabChange(index);
28331
- }, isActive: activeTab === index })))), jsx(motion.div, { className: "tw-absolute tw-bottom-0 tw-h-0.5 tw-rounded-[1px] tw-bg-royal-500", animate: {
28343
+ }, isActive: activeTab === index, isDisabled: !!tab.isDisabled || !!isDisabled })))), !isDisabled && (jsx(motion.div, { className: "tw-absolute tw-bottom-0 tw-h-0.5 tw-rounded-[1px] tw-bg-royal-500", animate: {
28332
28344
  transform: `translateX(${activeTabInfo.translateX}px)`,
28333
28345
  width: activeTabInfo.width,
28334
28346
  animationTimingFunction: DEFAULT_TIMING_FUNCTION,
@@ -28337,14 +28349,14 @@ function Tabs({ tabs, size = "large", onTabChange, activeTab, }) {
28337
28349
  stiffness: 300,
28338
28350
  damping: 30,
28339
28351
  duration: DEFAULT_ANIMATION_DURATION,
28340
- } })] }));
28352
+ } }))] }));
28341
28353
  }
28342
28354
  function Tab(_a) {
28343
- var { label, isActive, size } = _a, props = __rest$1(_a, ["label", "isActive", "size"]);
28344
- return (jsxs("button", Object.assign({}, props, { "aria-current": isActive ? "true" : undefined, className: cn("tw-group/tab-button tw-relative tw-flex tw-w-fit tw-items-center tw-justify-center tw-self-stretch", isActive ? "tw-text-grey-300" : "tw-text-grey-600", size === "small" ? "tw-h-[50px]" : "tw-h-squid-xxl", props.className), style: {
28355
+ var { label, isActive, size, isDisabled } = _a, props = __rest$1(_a, ["label", "isActive", "size", "isDisabled"]);
28356
+ return (jsxs("button", Object.assign({}, props, { disabled: isDisabled, "aria-current": isActive ? "true" : undefined, className: cn("tw-group/tab-button tw-relative tw-flex tw-w-fit tw-items-center tw-justify-center tw-self-stretch", isActive ? "tw-text-grey-300" : "tw-text-grey-600", size === "small" ? "tw-h-[50px]" : "tw-h-squid-xxl", props.className), style: {
28345
28357
  transition: `color ${DEFAULT_ANIMATION_DURATION}s`,
28346
28358
  transitionTimingFunction: DEFAULT_TIMING_FUNCTION,
28347
- }, children: [jsx(BodyText, { size: size, children: label }), !props.disabled && (jsx("span", { className: cn("tw-absolute tw-w-[calc(100%+20px)] tw-rounded-squid-s tw-p-squid-xs group-hover/tab-button:tw-bg-material-light-thin", size === "small" ? "tw-h-squid-l" : "tw-h-squid-xl") }))] })));
28359
+ }, children: [jsx(BodyText, { size: size, children: label }), !props.disabled && (jsx("span", { className: cn("tw-absolute tw-w-[calc(100%+20px)] tw-rounded-squid-s tw-p-squid-xs", size === "small" ? "tw-h-squid-l" : "tw-h-squid-xl", !isDisabled && "group-hover/tab-button:tw-bg-material-light-thin") }))] })));
28348
28360
  }
28349
28361
 
28350
28362
  function useCountdown(initialSeconds) {
@@ -69943,6 +69955,30 @@ function TransactionView({ type, props }) {
69943
69955
  return jsx(Component, Object.assign({}, props));
69944
69956
  }
69945
69957
 
69958
+ function MarketHeader({ price, priceChange, selectedTimeSpan, onTimeSpanChange, menuItems, onMenuItemClick, onSettingsOpen, isMenuOpen, menuRef, dropdownRef, openDropdownButtonRef, isLoading, timeSpanOptions: customTimeSpanOptions, }) {
69959
+ const defaultTimeSpanOptions = ["15M", "1H", "4H", "1D", "1W"];
69960
+ const timeSpanOptions = customTimeSpanOptions !== null && customTimeSpanOptions !== void 0 ? customTimeSpanOptions : defaultTimeSpanOptions;
69961
+ return (jsxs("div", { className: "tw-flex tw-h-[80px] tw-flex-row tw-items-start tw-justify-between tw-gap-squid-xs tw-p-squid-xs", children: [jsxs("div", { className: "tw-flex tw-flex-col tw-items-start tw-justify-between tw-gap-squid-xs tw-self-stretch tw-p-squid-xs", children: [jsx(BodyText, { tight: true, size: "large", className: "tw-text-grey-100", loading: { isLoading }, children: price }), isLoading ? (jsx(TextSkeleton, { width: "60px", className: "tw-h-5", isLoading: true })) : (jsx(PriceChange, { value: priceChange, variant: "small", highlightText: true, triangleAsPrefix: true }))] }), jsxs("div", { className: "tw-flex tw-flex-row tw-items-center tw-justify-center", children: [timeSpanOptions.map((timeSpan) => (jsx(TimeframeChip, { label: timeSpan, isSelected: selectedTimeSpan === timeSpan, onClick: () => {
69962
+ onTimeSpanChange(timeSpan);
69963
+ } }, timeSpan))), jsx("div", { className: "tw-w-squid-xxs" }), menuItems && menuItems.length > 0 && (jsxs("div", { className: "tw-relative", children: [jsx(IconButton, { ref: openDropdownButtonRef, icon: jsx(DotGrid1x3HorizontalIcon, { size: "15" }), size: 20, variant: "circle", className: "tw-bg-grey-300 tw-text-grey-900", onClick: onSettingsOpen, "aria-label": "Open chart settings" }), isMenuOpen && (jsx(DropdownMenu, { menuRef: menuRef, dropdownRef: dropdownRef, className: "tw-absolute tw-z-50", children: menuItems.map((item) => (jsx(DropdownMenuItem, { icon: item.icon, label: item.label, onClick: () => onMenuItemClick === null || onMenuItemClick === void 0 ? void 0 : onMenuItemClick(item.id) }, item.id))) }))] }))] })] }));
69964
+ }
69965
+ function MarketChart({ children, isLoading, }) {
69966
+ if (isLoading) {
69967
+ return (jsx("div", { className: "tw-flex tw-h-full tw-items-center tw-justify-center", children: jsx(Loader, { className: "tw-text-grey-500", size: "48" }) }));
69968
+ }
69969
+ if (children) {
69970
+ return jsx("div", { className: "tw-h-full tw-w-full", children: children });
69971
+ }
69972
+ return (jsx("div", { className: "tw-flex tw-w-full tw-items-center tw-justify-center", children: jsx(BodyText, { size: "medium", className: "tw-px-squid-l tw-text-grey-500", children: "Chart placeholder - Will be implemented with a third-party library" }) }));
69973
+ }
69974
+ const MarketDataItem = ({ label, value, isLoading, }) => (jsxs("div", { className: "tw-flex tw-flex-1 tw-flex-col tw-items-start tw-justify-end tw-gap-squid-xs tw-px-squid-xs tw-py-squid-s", children: [jsx(CaptionText, { tight: true, className: "tw-text-grey-500", loading: { isLoading }, children: label }), jsx(BodyText, { tight: true, size: "small", className: "tw-text-grey-300", loading: { isLoading }, children: value })] }));
69975
+ function MarketStats({ stats, isLoading, }) {
69976
+ return (jsx("div", { className: "tw-flex tw-items-end tw-justify-start tw-border-t tw-border-material-light-thin tw-px-squid-xs tw-py-squid-xxs", children: stats.map((stat, index) => (jsx(MarketDataItem, { label: stat.label, value: stat.value, isLoading: isLoading }, index))) }));
69977
+ }
69978
+ function DexChart({ price, priceChange, selectedTimeSpan, onTimeSpanChange, menuItems, onMenuItemClick, onSettingsOpen, isMenuOpen, menuRef, dropdownRef, openDropdownButtonRef, stats, children, isLoading, className, timeSpanOptions, }) {
69979
+ return (jsxs("div", { className: cn("tw-relative tw-min-h-[300px] tw-w-full tw-min-w-[200px] tw-max-w-[1200px] tw-rounded-squid-l tw-shadow-elevation-dark-2", className), children: [jsx(MarketHeader, { price: price, priceChange: priceChange, selectedTimeSpan: selectedTimeSpan, onTimeSpanChange: onTimeSpanChange, menuItems: menuItems, onMenuItemClick: onMenuItemClick, onSettingsOpen: onSettingsOpen, isMenuOpen: isMenuOpen, menuRef: menuRef, dropdownRef: dropdownRef, openDropdownButtonRef: openDropdownButtonRef, isLoading: isLoading, timeSpanOptions: timeSpanOptions }), jsx(MarketChart, { isLoading: isLoading, children: children }), jsx(MarketStats, { stats: stats, isLoading: isLoading })] }));
69980
+ }
69981
+
69946
69982
  function ThemeProvider(_a) {
69947
69983
  var { theme = lightTheme, children, themeType = "light", settings } = _a, props = __rest$1(_a, ["theme", "children", "themeType", "settings"]);
69948
69984
  const parsedStyle = parseSquidTheme(theme, themeType);
@@ -69954,4 +69990,4 @@ function ThemeProvider(_a) {
69954
69990
  return (jsx("div", Object.assign({}, props, { style: Object.assign(Object.assign({}, props.style), parsedStyle), "data-squid-theme-type": themeType, className: cn("tw-group tw-relative tw-flex tw-font-squid-main tw-h-d-screen mobile-lg:tw-h-auto", props.className), children: children })));
69955
69991
  }
69956
69992
 
69957
- export { ANIMATION_DURATIONS, AccountListItem, AccountsButton, ActionLayout, ActionLineOutRow, ActionProperties, ActionRow, ActionStatusRow, ActionWrapper, AddressButton, AnimationCard, AnimationWrapper, Announcement, AppContainer, Approve, ApproveAction, ArrowBottomTopIcon, ArrowButton, ArrowCornerDownLeftIcon, ArrowCornerDownRightIcon, ArrowDownIcon, ArrowExpandIcon, ArrowLeftIcon, ArrowOutOfBoxIcon, ArrowRightDownCircleIcon, ArrowRightDownIcon, ArrowRightIcon, ArrowRightUpCircleIcon, ArrowRightUpIcon, ArrowRotate, ArrowSplit, ArrowTriangle, ArrowUpIcon, ArrowWallDownIcon, ArrowsSwapIcon, AssetsButton, AtomIcon, BackpackIcon, BadgeImage, BankIcon, BellAlarmIcon, BlockSkeleton, BodyText, Boost, BoostBadge, BoostButton, BorderedContainer, Breadcrumb, BridgeAction, BridgeHeader, BridgeProperties, BrokenHeartIcon, BubblesIcon, Button$1 as Button, BuyNFTHeader, BuyNFTProperties, BuyNFTTransactionView, CSS_VARS, Calendar, CaptionText, CatSquareIcon, CelebrateIcon, ChainLink, Checkmark1Icon, Checkmark2Icon, ChevronArrowIcon, ChevronDownSmallIcon, ChevronGrabberVerticalIcon, ChevronLargeDownIcon, ChevronLargeRightIcon, ChevronRightSmallIcon, ChevronTopIcon, ChevronTopSmallIcon, Chip, CircleCheckIcon, CircleMinusIcon, CirclePlusIcon, CircleX, CircleXFilledIcon, ClockOutlineIcon, ClockSolidIcon, CodeBracketsIcon, CodeSolidSquareIcon, CoinsAddIcon, CoinsIcon, CoinsOutlinedIcon, Collapse, CollapsibleMenu, CollectionIcon, ColorPaletteIcon, CommandIcon, CompassRoundOutlinedIcon, CompassRoundSolidIcon, ConsoleIcon, Copy2Icon, CopyOutlinedIcon, CrossedOutSunSolidIcon, DashboardFast, DepositAddressView, DescriptionBlocks, DetailsToolbar, DiscordIcon, DockIconAnalytics, DockIconCheckout, DockIconHelp, DockIconProfile, DockIconScan, DockIconSwap, DockSwapIcon, DollarOutlinedIcon, DollarSolidIcon, DotGrid1x3HorizontalIcon, DropdownMenu, DropdownMenuItem, DropdownMenuSeparator, DropdownMenuTitle, EmojiMeh, EmojiSadIcon, EmptyHeartIcon, ErrorMessage, EscKeyIcon, EthereumIcon, ExplosionIcon, EyeOpenIcon, FarcasterIcon, FavouriteFilterIcon, FeeButton, FeesAction, FeesLines, FeesTotal, FileDownloadIcon, FilledHeartIcon, FilterAscendingIcon, FilterButton, FilterIcon, FilterTimelineIcon, FireIcon, GasIcon, GhostIcon, GithubIcon, HashLink, HeadingText, HeartSmallIcon, HelpIcon, HighestPriceRangeIcon, HistoryItem, HomeIcon, IconButton, IconLabel, Image$1 as Image, ImageGroup, ImageIcon, ImageSparkle, ImageStack, ImageState, IncompleteAction, InfinityIcon, InfoBox, Inline, Input, InteractionHeader, InteractionProperties, InteractionTransactionView, Join, LaptopIcon, LargeNumericInput, LightningIcon, LimitIcon, LinkIcon, ListItem, ListItemActionsButton, Loader, LoadingProvider, LoadingSkeleton, MEDIA_QUERIES, MarketCapIcon, MaxIcon, Menu, MenuItem, MenuSwapIcon, MirrorIcon, Modal, ModalContent, ModalContentDivider, ModalTitle, MoneyBagIcon, MoneyBagSolidIcon, MoonIcon, NavigationBar, NewsIcon, NewspaperIcon, NotAllowedIcon, NumericInput, PathSquareIcon, PauseIcon, PercentIcon, PhoneIcon, PieChartIcon, PipeSeparator, PluginIcon, PlusIcon, PoopIcon, PowerIcon, PriceChange, ProductCard, ProfileHeader, ProfileHeaderBackground, PropertiesLayout, PropertyListItem, PunkIcon, QrCodeIcon, RangeInput, ReceiptBillIcon, ReceiveNFTAction, ReceiveTokensAction, RefreshIcon, ReorderIcon, RouteStep, STEP_ITEM_HEIGHT, SearchIcon, SearchMenuIcon, SectionTitle, SendTokensAction, SettingsButton, SettingsGearIcon, SettingsItem, SettingsSlider, SettingsSliderIcon, ShoppingBagIcon, SizeTransition, SmileFilledIcon, SmileIcon, SnapIcon, SortIcon, SparkleIcon, SparklesIcon, SquareArrowCenter, SquareArrowTopLeftIcon, SquareArrowTopRight2Icon, SquidLogo, SquidVector, StakeAction, StarFilledIcon, StarLinesIcon, StarOutlinedIcon, StartAction, StocksIcon, SuccessAction, SunIcon, SunOutlinedIcon, SunriseIcon, SunriseSmallIcon, SwapAction, SwapConfiguration, SwapErrorIcon, SwapHeader, SwapIcon, SwapInputsIcon, SwapProgressView, SwapProperties, SwapStepItem, SwapStepSeparator, SwapStepsCollapsed, SwapSuccessIcon, SwapTransactionView, SwapWarningIcon, Switch, Tab, Tabs, TagIcon, TagIconFilled, TelegramIcon, TextSkeleton, ThemePreference, ThemeProvider, ThumbsUp, Tick, TimeFliesIcon, Timeline, Timestamp, Toast, TokenDetailsView, TokenGroup, TokenGroups, TokenPair, Tooltip, TradingViewStepsIcon, TransactionAction, TransactionFilters, TransactionHeader, TransactionHeaderLayout, TransactionItem, TransactionProperties, TransactionSearch, TransactionState, TransactionView, TransactionViewLayout, Transfer, TranslateIcon, TriangleExclamation, TrophyIcon, TxProgressViewHeader, UnsupportedPairNotice, UsdAmount, WalletIcon, WalletLink, WalletOutlinedIcon, WrapAction, XSocialIcon, adjustColorForContrast, baseTailwindConfig, blendColors, buttonRoundedClassMap, cn, darkTheme, getColorBrightness, getContrastColor, getHexColorFromOpacityPercentage, getWalletCardBackground, hexToRgb, isValidHexColor, lightTheme, linkActionTimelineProps, parseColor, parseSquidTheme, pxToRem, remToPx, rgbToHex, spacing$1 as spacing, statusTextClassMap, themeKeysToCssVariables, transactionErrorPauseAnimation, transactionFailureAnimation, transactionHalfSuccessAnimation, transactionPendingAnimation, transactionProcessingAnimation, transactionRejectedAnimation, transactionSuccessAnimation, useCollapsibleMenu, useDropdownMenu, useMediaQuery, useOnResize, useRect, useTimer, useUserTheme, useVersion };
69993
+ export { ANIMATION_DURATIONS, AccountListItem, AccountsButton, ActionLayout, ActionLineOutRow, ActionProperties, ActionRow, ActionStatusRow, ActionWrapper, AddressButton, AnimationCard, AnimationWrapper, Announcement, AppContainer, Approve, ApproveAction, ArrowBottomTopIcon, ArrowButton, ArrowCornerDownLeftIcon, ArrowCornerDownRightIcon, ArrowDownIcon, ArrowExpandIcon, ArrowLeftIcon, ArrowOutOfBoxIcon, ArrowRightDownCircleIcon, ArrowRightDownIcon, ArrowRightIcon, ArrowRightUpCircleIcon, ArrowRightUpIcon, ArrowRotate, ArrowSplit, ArrowTriangle, ArrowUpIcon, ArrowWallDownIcon, ArrowsSwapIcon, AssetsButton, AtomIcon, BackpackIcon, BadgeImage, BankIcon, BellAlarmIcon, BlockSkeleton, BodyText, Boost, BoostBadge, BoostButton, BorderedContainer, Breadcrumb, BridgeAction, BridgeHeader, BridgeProperties, BrokenHeartIcon, BubblesIcon, Button$1 as Button, BuyNFTHeader, BuyNFTProperties, BuyNFTTransactionView, CSS_VARS, Calendar, CaptionText, CatSquareIcon, CelebrateIcon, ChainLink, Checkmark1Icon, Checkmark2Icon, ChevronArrowIcon, ChevronDownSmallIcon, ChevronGrabberVerticalIcon, ChevronLargeDownIcon, ChevronLargeRightIcon, ChevronRightSmallIcon, ChevronTopIcon, ChevronTopSmallIcon, Chip, CircleCheckIcon, CircleMinusIcon, CirclePlusIcon, CircleX, CircleXFilledIcon, ClockOutlineIcon, ClockSolidIcon, CodeBracketsIcon, CodeSolidSquareIcon, CoinsAddIcon, CoinsIcon, CoinsOutlinedIcon, Collapse, CollapsibleMenu, CollectionIcon, ColorPaletteIcon, CommandIcon, CompassRoundOutlinedIcon, CompassRoundSolidIcon, ConsoleIcon, Copy2Icon, CopyOutlinedIcon, CrossedOutSunSolidIcon, DashboardFast, DepositAddressView, DescriptionBlocks, DetailsToolbar, DexChart, DiscordIcon, DockIconAnalytics, DockIconCheckout, DockIconHelp, DockIconProfile, DockIconScan, DockIconSwap, DockSwapIcon, DollarOutlinedIcon, DollarSolidIcon, DotGrid1x3HorizontalIcon, DropdownMenu, DropdownMenuItem, DropdownMenuSeparator, DropdownMenuTitle, EmojiMeh, EmojiSadIcon, EmptyHeartIcon, ErrorMessage, EscKeyIcon, EthereumIcon, ExplosionIcon, EyeOpenIcon, FarcasterIcon, FavouriteFilterIcon, FeeButton, FeesAction, FeesLines, FeesTotal, FileDownloadIcon, FilledHeartIcon, FilterAscendingIcon, FilterButton, FilterIcon, FilterTimelineIcon, FireIcon, GasIcon, GhostIcon, GithubIcon, HashLink, HeadingText, HeartSmallIcon, HelpIcon, HighestPriceRangeIcon, HistoryItem, HomeIcon, IconButton, IconLabel, Image$1 as Image, ImageGroup, ImageIcon, ImageSparkle, ImageStack, ImageState, IncompleteAction, InfinityIcon, InfoBox, Inline, Input, InteractionHeader, InteractionProperties, InteractionTransactionView, Join, LaptopIcon, LargeNumericInput, LightningIcon, LimitIcon, LinkIcon, ListItem, ListItemActionsButton, Loader, LoadingProvider, LoadingSkeleton, MEDIA_QUERIES, MarketCapIcon, MaxIcon, Menu, MenuItem, MenuSwapIcon, MirrorIcon, Modal, ModalContent, ModalContentDivider, ModalTitle, MoneyBagIcon, MoneyBagSolidIcon, MoonIcon, NavigationBar, NewsIcon, NewspaperIcon, NotAllowedIcon, NumericInput, PathSquareIcon, PauseIcon, PercentIcon, PhoneIcon, PieChartIcon, PipeSeparator, PluginIcon, PlusIcon, PoopIcon, PowerIcon, PriceChange, ProductCard, ProfileHeader, ProfileHeaderBackground, PropertiesLayout, PropertyListItem, PunkIcon, QrCodeIcon, RangeInput, ReceiptBillIcon, ReceiveNFTAction, ReceiveTokensAction, RefreshIcon, ReorderIcon, RouteStep, STEP_ITEM_HEIGHT, SearchIcon, SearchMenuIcon, SectionTitle, SendTokensAction, SettingsButton, SettingsGearIcon, SettingsItem, SettingsSlider, SettingsSliderIcon, ShoppingBagIcon, SizeTransition, SmileFilledIcon, SmileIcon, SnapIcon, SortIcon, SparkleIcon, SparklesIcon, SquareArrowCenter, SquareArrowTopLeftIcon, SquareArrowTopRight2Icon, SquidLogo, SquidVector, StakeAction, StarFilledIcon, StarLinesIcon, StarOutlinedIcon, StartAction, StocksIcon, SuccessAction, SunIcon, SunOutlinedIcon, SunriseIcon, SunriseSmallIcon, SwapAction, SwapConfiguration, SwapErrorIcon, SwapHeader, SwapIcon, SwapInputsIcon, SwapProgressView, SwapProperties, SwapStepItem, SwapStepSeparator, SwapStepsCollapsed, SwapSuccessIcon, SwapTransactionView, SwapWarningIcon, Switch, Tab, Tabs, TagIcon, TagIconFilled, TelegramIcon, TextSkeleton, ThemePreference, ThemeProvider, ThumbsUp, Tick, TimeFliesIcon, TimeframeChip, Timeline, Timestamp, Toast, TokenDetailsView, TokenGroup, TokenGroups, TokenPair, Tooltip, TradingViewStepsIcon, TransactionAction, TransactionFilters, TransactionHeader, TransactionHeaderLayout, TransactionItem, TransactionProperties, TransactionSearch, TransactionState, TransactionView, TransactionViewLayout, Transfer, TranslateIcon, TriangleExclamation, TrophyIcon, TxProgressViewHeader, UnsupportedPairNotice, UsdAmount, WalletIcon, WalletLink, WalletOutlinedIcon, WrapAction, XSocialIcon, adjustColorForContrast, baseTailwindConfig, blendColors, buttonRoundedClassMap, cn, darkTheme, getColorBrightness, getContrastColor, getHexColorFromOpacityPercentage, getWalletCardBackground, hexToRgb, isValidHexColor, lightTheme, linkActionTimelineProps, parseColor, parseSquidTheme, pxToRem, remToPx, rgbToHex, spacing$1 as spacing, statusTextClassMap, themeKeysToCssVariables, transactionErrorPauseAnimation, transactionFailureAnimation, transactionHalfSuccessAnimation, transactionPendingAnimation, transactionProcessingAnimation, transactionRejectedAnimation, transactionSuccessAnimation, useCollapsibleMenu, useDropdownMenu, useMediaQuery, useOnResize, useRect, useTimer, useUserTheme, useVersion };
@@ -1,6 +1,8 @@
1
1
  interface PriceChangeProps {
2
2
  variant?: "small" | "large";
3
3
  value: string | number;
4
+ highlightText?: boolean;
5
+ triangleAsPrefix?: boolean;
4
6
  }
5
- export declare function PriceChange({ value: rawValue, variant, }: PriceChangeProps): import("react/jsx-runtime").JSX.Element;
7
+ export declare function PriceChange({ value: rawValue, variant, highlightText, triangleAsPrefix, }: PriceChangeProps): import("react/jsx-runtime").JSX.Element;
6
8
  export {};
@@ -1,5 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  export interface IconButtonProps extends React.ComponentProps<"button"> {
3
3
  icon: React.ReactNode;
4
+ size?: number;
5
+ variant?: "rounded" | "circle";
4
6
  }
5
7
  export declare const IconButton: import("react").ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;