@orderly.network/markets 3.1.0 → 3.1.1-alpha.0

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.
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var React6 = require('react');
3
+ var React7 = require('react');
4
4
  var jsxRuntime = require('react/jsx-runtime');
5
5
  var hooks = require('@orderly.network/hooks');
6
6
  var i18n = require('@orderly.network/i18n');
@@ -11,7 +11,7 @@ var uiScaffold = require('@orderly.network/ui-scaffold');
11
11
 
12
12
  function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
13
13
 
14
- var React6__default = /*#__PURE__*/_interopDefault(React6);
14
+ var React7__default = /*#__PURE__*/_interopDefault(React7);
15
15
 
16
16
  var __defProp = Object.defineProperty;
17
17
  var __getOwnPropNames = Object.getOwnPropertyNames;
@@ -25,14 +25,14 @@ var __export = (target, all) => {
25
25
  var MarketsContext; exports.MarketsProvider = void 0; var useMarketsContext;
26
26
  var init_marketsProvider = __esm({
27
27
  "src/components/marketsProvider/index.tsx"() {
28
- MarketsContext = React6.createContext({});
28
+ MarketsContext = React7.createContext({});
29
29
  exports.MarketsProvider = (props) => {
30
30
  const { symbol, comparisonProps, children, onSymbolChange, tabs } = props;
31
- const [searchValue, setSearchValue] = React6.useState("");
32
- const clearSearchValue = React6.useCallback(() => {
31
+ const [searchValue, setSearchValue] = React7.useState("");
32
+ const clearSearchValue = React7.useCallback(() => {
33
33
  setSearchValue("");
34
34
  }, []);
35
- const memoizedValue = React6.useMemo(() => {
35
+ const memoizedValue = React7.useMemo(() => {
36
36
  return {
37
37
  searchValue,
38
38
  onSearchValueChange: setSearchValue,
@@ -53,7 +53,7 @@ var init_marketsProvider = __esm({
53
53
  return /* @__PURE__ */ jsxRuntime.jsx(MarketsContext.Provider, { value: memoizedValue, children });
54
54
  };
55
55
  useMarketsContext = () => {
56
- return React6.useContext(MarketsContext);
56
+ return React7.useContext(MarketsContext);
57
57
  };
58
58
  }
59
59
  });
@@ -62,9 +62,12 @@ var init_rwaDotTooltip = __esm({
62
62
  "src/components/rwaDotTooltip.tsx"() {
63
63
  RwaDotTooltip = ({ record }) => {
64
64
  const { t } = i18n.useTranslation();
65
- const isInTradingHours = hooks.isCurrentlyTrading(
65
+ const { open: computedOpen } = hooks.useGetRwaSymbolOpenStatus(record.symbol);
66
+ const open = computedOpen ?? hooks.isCurrentlyTrading(
66
67
  record.rwaNextClose,
67
- record.rwaStatus
68
+ record.rwaStatus,
69
+ void 0,
70
+ record.rwaNextOpen
68
71
  );
69
72
  if (!record.isRwa) {
70
73
  return null;
@@ -74,7 +77,7 @@ var init_rwaDotTooltip = __esm({
74
77
  {
75
78
  className: "oui-pointer-events-none",
76
79
  disableHoverableContent: true,
77
- content: /* @__PURE__ */ jsxRuntime.jsx(ui.Text, { color: isInTradingHours ? "success" : "danger", children: isInTradingHours ? t("trading.rwa.marketHours") : t("trading.rwa.outsideMarketHours") }),
80
+ content: /* @__PURE__ */ jsxRuntime.jsx(ui.Text, { color: open ? "success" : "danger", children: open ? t("trading.rwa.marketHours") : t("trading.rwa.outsideMarketHours") }),
78
81
  children: /* @__PURE__ */ jsxRuntime.jsx(
79
82
  ui.Box,
80
83
  {
@@ -89,7 +92,7 @@ var init_rwaDotTooltip = __esm({
89
92
  width: 4,
90
93
  height: 4,
91
94
  r: "full",
92
- className: isInTradingHours ? "oui-bg-success" : "oui-bg-danger"
95
+ className: open ? "oui-bg-success" : "oui-bg-danger"
93
96
  }
94
97
  )
95
98
  }
@@ -107,7 +110,10 @@ var init_symbolBadge = __esm({
107
110
  props.symbol
108
111
  );
109
112
  const badge = brokerName ?? brokerId ?? void 0;
110
- return /* @__PURE__ */ jsxRuntime.jsx(ui.SymbolBadge, { badge, fullName: brokerNameRaw });
113
+ if (!badge) {
114
+ return null;
115
+ }
116
+ return /* @__PURE__ */ jsxRuntime.jsx(ui.Flex, { as: "span", display: "inlineFlex", className: props.className, children: /* @__PURE__ */ jsxRuntime.jsx(ui.SymbolBadge, { badge, fullName: brokerNameRaw }) });
111
117
  };
112
118
  SymbolBadge = BrokerIdBadge;
113
119
  }
@@ -117,11 +123,12 @@ var init_symbolDisplay = __esm({
117
123
  "src/components/symbolDisplay.tsx"() {
118
124
  init_rwaDotTooltip();
119
125
  init_symbolBadge();
120
- exports.SymbolDisplay = React6.memo((props) => {
126
+ exports.SymbolDisplay = React7.memo((props) => {
121
127
  const { children, size = "xs", showBadge = true, record, ...rest } = props;
122
128
  const symbol = children;
123
129
  const symbolsInfo = hooks.useSymbolsInfo();
124
- const displayName = symbolsInfo[symbol]("displayName");
130
+ const info = symbolsInfo[symbol];
131
+ const displayName = info("display_symbol_name")?.trim?.();
125
132
  const suffix = record?.isRwa || showBadge ? /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { as: "span", display: "inlineFlex", gapX: 0, itemAlign: "center", children: [
126
133
  record?.isRwa && /* @__PURE__ */ jsxRuntime.jsx(RwaDotTooltip, { record }),
127
134
  showBadge && /* @__PURE__ */ jsxRuntime.jsx(SymbolBadge, { symbol })
@@ -580,7 +587,7 @@ var init_marketsHeader_ui = __esm({
580
587
  BlockList = (props) => {
581
588
  const { total24Amount, totalOpenInterest, tvl } = props;
582
589
  const { t } = i18n.useTranslation();
583
- const list = React6.useMemo(() => {
590
+ const list = React7.useMemo(() => {
584
591
  return [
585
592
  {
586
593
  label: /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, children: [
@@ -747,8 +754,8 @@ function sortList(list, sort) {
747
754
  return sortedList;
748
755
  }
749
756
  function useSort(initialSort, onSortChange) {
750
- const [sort, setSort] = React6.useState(initialSort);
751
- const onSort = React6.useCallback((options) => {
757
+ const [sort, setSort] = React7.useState(initialSort);
758
+ const onSort = React7.useCallback((options) => {
752
759
  const nextSort = options ? {
753
760
  sortKey: options.sortKey,
754
761
  sortOrder: options.sort
@@ -756,7 +763,7 @@ function useSort(initialSort, onSortChange) {
756
763
  setSort(nextSort);
757
764
  onSortChange?.(nextSort);
758
765
  }, []);
759
- const getSortedList = React6.useCallback(
766
+ const getSortedList = React7.useCallback(
760
767
  (list) => sortList(list, sort),
761
768
  [sort]
762
769
  );
@@ -778,7 +785,7 @@ function searchBySymbol(list, searchValue = "", formatString) {
778
785
  list?.forEach((item) => {
779
786
  const formattedSymbol = utils.formatSymbol(item.symbol, formatString);
780
787
  const symbolLower = formattedSymbol.toLowerCase();
781
- const displayName = item.displayName;
788
+ const displayName = item.display_symbol_name;
782
789
  const displayNameLower = displayName ? String(displayName).toLowerCase() : null;
783
790
  const matchesSymbol = reg.test(formattedSymbol);
784
791
  const matchesDisplayName = displayNameLower ? reg.test(displayNameLower) : false;
@@ -794,8 +801,8 @@ function searchBySymbol(list, searchValue = "", formatString) {
794
801
  }
795
802
  });
796
803
  const compareSymbols = (a, b) => {
797
- const textA = a.displayName || utils.formatSymbol(a.symbol, formatString);
798
- const textB = b.displayName || utils.formatSymbol(b.symbol, formatString);
804
+ const textA = a.display_symbol_name || utils.formatSymbol(a.symbol, formatString);
805
+ const textB = b.display_symbol_name || utils.formatSymbol(b.symbol, formatString);
799
806
  if (textA < textB) return -1;
800
807
  if (textA > textB) return 1;
801
808
  return 0;
@@ -805,9 +812,9 @@ function searchBySymbol(list, searchValue = "", formatString) {
805
812
  return [...exactMatches, ...startsWithMatches, ...otherMatches];
806
813
  }
807
814
  function useSize() {
808
- const [width, setWidth] = React6.useState(0);
809
- const [height, setHeight] = React6.useState(0);
810
- React6.useEffect(() => {
815
+ const [width, setWidth] = React7.useState(0);
816
+ const [height, setHeight] = React7.useState(0);
817
+ React7.useEffect(() => {
811
818
  setWidth(window.innerWidth);
812
819
  setHeight(window.innerHeight);
813
820
  const handleResize = () => {
@@ -861,34 +868,34 @@ var init_utils = __esm({
861
868
  function useDataSource() {
862
869
  const [markets, favorite] = hooks.useMarkets(hooks.MarketsType.ALL);
863
870
  const { data: balance } = hooks.useQuery("/v1/public/balance/stats");
864
- const news = React6.useMemo(
871
+ const news = React7.useMemo(
865
872
  () => sortList(markets, { sortKey: "created_time", sortOrder: "desc" }).slice(
866
873
  0,
867
874
  5
868
875
  ),
869
876
  [markets]
870
877
  );
871
- const gainers = React6.useMemo(
878
+ const gainers = React7.useMemo(
872
879
  () => sortList(markets, { sortKey: "change", sortOrder: "desc" }).slice(0, 5),
873
880
  [markets]
874
881
  );
875
- const losers = React6.useMemo(
882
+ const losers = React7.useMemo(
876
883
  () => sortList(markets, { sortKey: "change", sortOrder: "asc" }).slice(0, 5),
877
884
  [markets]
878
885
  );
879
- const total24Amount = React6.useMemo(
886
+ const total24Amount = React7.useMemo(
880
887
  () => markets?.reduce((prevValue, curValue) => {
881
888
  return prevValue.add(curValue["24h_amount"] || 0);
882
889
  }, new utils.Decimal(0)) || new utils.Decimal(0),
883
890
  [markets]
884
891
  );
885
- const totalOpenInterest = React6.useMemo(
892
+ const totalOpenInterest = React7.useMemo(
886
893
  () => markets?.reduce((prevValue, curValue) => {
887
894
  return prevValue.add(curValue["openInterest"] || 0);
888
895
  }, new utils.Decimal(0)) || new utils.Decimal(0),
889
896
  [markets]
890
897
  );
891
- const tvl = React6.useMemo(() => {
898
+ const tvl = React7.useMemo(() => {
892
899
  if (!balance) return 0;
893
900
  const { total_holding = 0 } = balance;
894
901
  return new utils.Decimal(total_holding).toNumber();
@@ -909,7 +916,7 @@ var init_marketsHeader_script = __esm({
909
916
  "src/pages/home/marketsHeader/marketsHeader.script.tsx"() {
910
917
  init_utils();
911
918
  exports.useMarketsHeaderScript = () => {
912
- const [scrollIndex, setScrollIndex] = React6.useState(0);
919
+ const [scrollIndex, setScrollIndex] = React7.useState(0);
913
920
  const data = useDataSource();
914
921
  const { width } = useSize();
915
922
  const [emblaRef, emblaApi] = ui.useEmblaCarousel({
@@ -917,7 +924,7 @@ var init_marketsHeader_script = __esm({
917
924
  // duration: 25,
918
925
  slidesToScroll: "auto"
919
926
  });
920
- React6.useEffect(() => {
927
+ React7.useEffect(() => {
921
928
  emblaApi?.on("select", () => {
922
929
  setScrollIndex(emblaApi?.selectedScrollSnap());
923
930
  });
@@ -949,7 +956,7 @@ var init_marketsHeader_mobile_ui = __esm({
949
956
  tvl,
950
957
  favorite
951
958
  } = props;
952
- const [activeTab, setActiveTab] = React6.useState("newListings");
959
+ const [activeTab, setActiveTab] = React7.useState("newListings");
953
960
  const { onSymbolChange } = useMarketsContext();
954
961
  const { t } = i18n.useTranslation();
955
962
  const onSymbol = (item) => {
@@ -1006,7 +1013,7 @@ var init_marketsHeader_mobile_ui = __esm({
1006
1013
  BlockList2 = (props) => {
1007
1014
  const { total24Amount, totalOpenInterest, tvl } = props;
1008
1015
  const { t } = i18n.useTranslation();
1009
- const list = React6.useMemo(() => {
1016
+ const list = React7.useMemo(() => {
1010
1017
  return [
1011
1018
  {
1012
1019
  label: /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, children: [
@@ -1155,9 +1162,9 @@ function useCommunityTabs() {
1155
1162
  const brokerId = hooks.useConfig("brokerId");
1156
1163
  const [brokers] = hooks.useAllBrokers();
1157
1164
  const [allMarkets] = hooks.useMarkets(hooks.MarketsType.ALL);
1158
- const lastSignatureRef = React6.useRef("");
1159
- const lastValueRef = React6.useRef([]);
1160
- return React6.useMemo(() => {
1165
+ const lastSignatureRef = React7.useRef("");
1166
+ const lastValueRef = React7.useRef([]);
1167
+ return React7.useMemo(() => {
1161
1168
  const brokerIdSet = /* @__PURE__ */ new Set();
1162
1169
  for (const m of allMarkets ?? []) {
1163
1170
  const id = m?.broker_id;
@@ -1571,10 +1578,10 @@ function useFavoritesDropdownMenuScript(options) {
1571
1578
  updateFavoriteTabs,
1572
1579
  updateSymbolFavoriteState
1573
1580
  } = options.favorite;
1574
- const [open, setOpen] = React6.useState(false);
1575
- const [inputVisible, setInputVisible] = React6.useState(false);
1576
- const [value, setValue] = React6.useState("");
1577
- const [selectedTabs, setSelectedTabs] = React6.useState([]);
1581
+ const [open, setOpen] = React7.useState(false);
1582
+ const [inputVisible, setInputVisible] = React7.useState(false);
1583
+ const [value, setValue] = React7.useState("");
1584
+ const [selectedTabs, setSelectedTabs] = React7.useState([]);
1578
1585
  const hide = () => {
1579
1586
  setOpen(false);
1580
1587
  };
@@ -1609,7 +1616,7 @@ function useFavoritesDropdownMenuScript(options) {
1609
1616
  updateSymbolFavoriteState(options.row, selectedTabs, false);
1610
1617
  setOpen(false);
1611
1618
  };
1612
- React6.useEffect(() => {
1619
+ React7.useEffect(() => {
1613
1620
  if (!open) {
1614
1621
  return;
1615
1622
  }
@@ -1618,7 +1625,7 @@ function useFavoritesDropdownMenuScript(options) {
1618
1625
  setSelectedTabs(find?.tabs);
1619
1626
  }
1620
1627
  }, [open, favorites, favoriteTabs, symbol]);
1621
- React6.useEffect(() => {
1628
+ React7.useEffect(() => {
1622
1629
  if (!open) {
1623
1630
  clearState();
1624
1631
  }
@@ -1674,7 +1681,7 @@ function getSymbolColumn(favorite, isFavoriteList = false, options) {
1674
1681
  return {
1675
1682
  title: i18n.i18n.t("common.symbol"),
1676
1683
  dataIndex: "symbol",
1677
- width: 150,
1684
+ width: options?.symbolColumnWidth ?? 150,
1678
1685
  className: "oui-z-10",
1679
1686
  onSort: true,
1680
1687
  render: (value, record) => {
@@ -1693,6 +1700,9 @@ function getSymbolColumn(favorite, isFavoriteList = false, options) {
1693
1700
  ) });
1694
1701
  }
1695
1702
  const stackLeverageInSecondRow = options?.stackLeverageInSecondRow;
1703
+ const hasLeverage = typeof record.leverage === "number";
1704
+ const showSymbolBadgeInLeverageRow = stackLeverageInSecondRow && Boolean(record.broker_id);
1705
+ const showSecondRow = hasLeverage || showSymbolBadgeInLeverageRow;
1696
1706
  return /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, itemAlign: "center", children: [
1697
1707
  favoritesIcon,
1698
1708
  /* @__PURE__ */ jsxRuntime.jsxs(
@@ -1705,9 +1715,24 @@ function getSymbolColumn(favorite, isFavoriteList = false, options) {
1705
1715
  children: [
1706
1716
  /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, itemAlign: "center", children: [
1707
1717
  /* @__PURE__ */ jsxRuntime.jsx(ui.TokenIcon, { symbol: value, className: "oui-size-[18px]" }),
1708
- /* @__PURE__ */ jsxRuntime.jsx(exports.SymbolDisplay, { formatString: "base", size: "2xs", record, children: value })
1718
+ /* @__PURE__ */ jsxRuntime.jsx(
1719
+ exports.SymbolDisplay,
1720
+ {
1721
+ formatString: "base",
1722
+ size: "2xs",
1723
+ record,
1724
+ showBadge: !stackLeverageInSecondRow,
1725
+ children: value
1726
+ }
1727
+ )
1709
1728
  ] }),
1710
- typeof record.leverage === "number" && /* @__PURE__ */ jsxRuntime.jsxs(ui.Badge, { size: "xs", color: "primary", children: [
1729
+ stackLeverageInSecondRow ? showSecondRow && /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, itemAlign: "center", children: [
1730
+ showSymbolBadgeInLeverageRow && /* @__PURE__ */ jsxRuntime.jsx(SymbolBadge, { symbol: value }),
1731
+ hasLeverage && /* @__PURE__ */ jsxRuntime.jsxs(ui.Badge, { size: "xs", color: "primary", children: [
1732
+ record.leverage,
1733
+ "x"
1734
+ ] })
1735
+ ] }) : hasLeverage && /* @__PURE__ */ jsxRuntime.jsxs(ui.Badge, { size: "xs", color: "primary", children: [
1711
1736
  record.leverage,
1712
1737
  "x"
1713
1738
  ] })
@@ -1876,6 +1901,7 @@ var init_column = __esm({
1876
1901
  init_icons();
1877
1902
  init_icons();
1878
1903
  init_favoritesDropdownMenu();
1904
+ init_symbolBadge();
1879
1905
  init_symbolDisplay();
1880
1906
  }
1881
1907
  });
@@ -1980,6 +2006,7 @@ var init_type = __esm({
1980
2006
  MarketsTabName2["Recent"] = "recent";
1981
2007
  MarketsTabName2["All"] = "all";
1982
2008
  MarketsTabName2["Rwa"] = "rwa";
2009
+ MarketsTabName2["PreTge"] = "preTge";
1983
2010
  MarketsTabName2["NewListing"] = "newListing";
1984
2011
  MarketsTabName2["Community"] = "community";
1985
2012
  return MarketsTabName2;
@@ -2007,12 +2034,13 @@ var init_marketsList_script = __esm({
2007
2034
  ["all" /* All */]: hooks.MarketsType.ALL,
2008
2035
  ["community" /* Community */]: hooks.MarketsType.COMMUNITY,
2009
2036
  ["rwa" /* Rwa */]: hooks.MarketsType.RWA,
2037
+ ["preTge" /* PreTge */]: hooks.MarketsType.PRE_TGE,
2010
2038
  ["favorites" /* Favorites */]: hooks.MarketsType.FAVORITES,
2011
2039
  ["recent" /* Recent */]: hooks.MarketsType.RECENT,
2012
2040
  ["newListing" /* NewListing */]: hooks.MarketsType.NEW_LISTING
2013
2041
  };
2014
2042
  exports.useMarketsListScript = (options) => {
2015
- const [loading, setLoading] = React6.useState(true);
2043
+ const [loading, setLoading] = React7.useState(true);
2016
2044
  const [data, favorite] = hooks.useMarkets(
2017
2045
  MarketsTypeMap[options.type] || hooks.MarketsType.ALL
2018
2046
  );
@@ -2022,7 +2050,7 @@ var init_marketsList_script = __esm({
2022
2050
  options.initialSort,
2023
2051
  options.onSort
2024
2052
  );
2025
- const dataSource = React6.useMemo(() => {
2053
+ const dataSource = React7.useMemo(() => {
2026
2054
  const filterList = typeof options.dataFilter === "function" ? options.dataFilter(data, { favorites, selectedFavoriteTab }) : data;
2027
2055
  const searchResults = searchBySymbol(filterList, searchValue, "base");
2028
2056
  return getSortedList(searchResults);
@@ -2034,7 +2062,7 @@ var init_marketsList_script = __esm({
2034
2062
  favorites,
2035
2063
  selectedFavoriteTab
2036
2064
  ]);
2037
- React6.useEffect(() => {
2065
+ React7.useEffect(() => {
2038
2066
  setLoading(false);
2039
2067
  }, [data]);
2040
2068
  const isFavoritesList = options.type === "favorites" /* Favorites */;
@@ -2086,6 +2114,104 @@ var init_marketsList = __esm({
2086
2114
  init_marketsList_widget();
2087
2115
  }
2088
2116
  });
2117
+ function createRwaSubcategoryFilter(subcategory, rwaSymbolsInfo) {
2118
+ return (data) => {
2119
+ const targetSession = RWA_SUBCATEGORY_SESSION_MAP[subcategory];
2120
+ if (!targetSession) {
2121
+ return data;
2122
+ }
2123
+ return data.filter((item) => {
2124
+ const marketSession = item?.market_session ?? rwaSymbolsInfo?.[item?.symbol]?.market_session;
2125
+ return marketSession === targetSession;
2126
+ });
2127
+ };
2128
+ }
2129
+ var RWA_SUBCATEGORY_CONFIGS, RWA_SUBCATEGORY_SESSION_MAP, RwaSubcategoryTabs;
2130
+ var init_rwaSubcategoryTabs_ui = __esm({
2131
+ "src/components/rwaSubcategoryTabs/rwaSubcategoryTabs.ui.tsx"() {
2132
+ RWA_SUBCATEGORY_CONFIGS = [
2133
+ // US_STOCK and US_STOCK_EXT intentionally remain available only under All.
2134
+ { value: "all", title: "All" },
2135
+ { value: "fx", title: "FX", marketSession: "FX" },
2136
+ { value: "hk", title: "HK", marketSession: "HK_STOCK" },
2137
+ { value: "kr", title: "KR", marketSession: "KR_STOCK" },
2138
+ { value: "cn", title: "CN", marketSession: "CN_STOCK" }
2139
+ ];
2140
+ RWA_SUBCATEGORY_SESSION_MAP = RWA_SUBCATEGORY_CONFIGS.reduce((acc, item) => {
2141
+ if (item.marketSession) {
2142
+ acc[item.value] = item.marketSession;
2143
+ }
2144
+ return acc;
2145
+ }, {});
2146
+ RwaSubcategoryTabs = (props) => {
2147
+ const {
2148
+ storageKey,
2149
+ className,
2150
+ classNames,
2151
+ variant = "contained",
2152
+ size = "sm",
2153
+ showScrollIndicator,
2154
+ renderPanel
2155
+ } = props;
2156
+ const { t } = i18n.useTranslation();
2157
+ const [subcategory, setSubcategory] = hooks.useLocalStorage(
2158
+ storageKey,
2159
+ "all"
2160
+ );
2161
+ const rwaSymbolsInfo = hooks.useRwaSymbolsInfoStore();
2162
+ const [rwaMarkets] = hooks.useMarkets(hooks.MarketsType.RWA);
2163
+ const visibleTabs = React7.useMemo(() => {
2164
+ const sessions = new Set(
2165
+ rwaMarkets.map(
2166
+ (item) => item.market_session ?? rwaSymbolsInfo?.[item.symbol]?.market_session
2167
+ ).filter(Boolean)
2168
+ );
2169
+ return RWA_SUBCATEGORY_CONFIGS.filter((tab) => {
2170
+ if (!tab.marketSession) {
2171
+ return true;
2172
+ }
2173
+ return sessions.has(tab.marketSession);
2174
+ });
2175
+ }, [rwaMarkets, rwaSymbolsInfo]);
2176
+ React7.useEffect(() => {
2177
+ if (!visibleTabs.some((tab) => tab.value === subcategory)) {
2178
+ setSubcategory("all");
2179
+ }
2180
+ }, [subcategory, setSubcategory, visibleTabs]);
2181
+ return /* @__PURE__ */ jsxRuntime.jsx(
2182
+ ui.Tabs,
2183
+ {
2184
+ variant,
2185
+ size,
2186
+ value: subcategory,
2187
+ onValueChange: (value) => setSubcategory(value),
2188
+ classNames,
2189
+ className,
2190
+ showScrollIndicator,
2191
+ children: visibleTabs.map((tab) => /* @__PURE__ */ jsxRuntime.jsx(
2192
+ ui.TabPanel,
2193
+ {
2194
+ title: tab.value === "all" ? t("common.all") : tab.title,
2195
+ value: tab.value,
2196
+ children: renderPanel(
2197
+ tab.value,
2198
+ createRwaSubcategoryFilter(tab.value, rwaSymbolsInfo)
2199
+ )
2200
+ },
2201
+ tab.value
2202
+ ))
2203
+ }
2204
+ );
2205
+ };
2206
+ }
2207
+ });
2208
+
2209
+ // src/components/rwaSubcategoryTabs/index.ts
2210
+ var init_rwaSubcategoryTabs = __esm({
2211
+ "src/components/rwaSubcategoryTabs/index.ts"() {
2212
+ init_rwaSubcategoryTabs_ui();
2213
+ }
2214
+ });
2089
2215
  var RwaIconTab, RwaTab;
2090
2216
  var init_rwaTab = __esm({
2091
2217
  "src/components/rwaTab.tsx"() {
@@ -2100,12 +2226,12 @@ var init_rwaTab = __esm({
2100
2226
  className: "group-data-[state=active]:oui-text-base-contrast group-data-[state=inactive]:oui-text-base-contrast-36"
2101
2227
  }
2102
2228
  ),
2103
- /* @__PURE__ */ jsxRuntime.jsx(ui.Text, { children: t("common.rwa") })
2229
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Text, { children: t("markets.tradFi") })
2104
2230
  ] });
2105
2231
  };
2106
2232
  RwaTab = () => {
2107
2233
  const { t } = i18n.useTranslation();
2108
- return /* @__PURE__ */ jsxRuntime.jsx(ui.Flex, { gap: 1, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Text, { children: t("common.rwa") }) });
2234
+ return /* @__PURE__ */ jsxRuntime.jsx(ui.Flex, { gap: 1, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Text, { children: t("markets.tradFi") }) });
2109
2235
  };
2110
2236
  }
2111
2237
  });
@@ -2122,13 +2248,13 @@ var init_searchInput = __esm({
2122
2248
  init_marketsProvider();
2123
2249
  SearchInput = (props) => {
2124
2250
  const { classNames, suffix } = props;
2125
- const isComposingRef = React6.useRef(false);
2251
+ const isComposingRef = React7.useRef(false);
2126
2252
  const { t } = i18n.useTranslation();
2127
2253
  const { searchValue, onSearchValueChange, clearSearchValue } = useMarketsContext();
2128
- const handleCompositionStart = React6.useCallback(() => {
2254
+ const handleCompositionStart = React7.useCallback(() => {
2129
2255
  isComposingRef.current = true;
2130
2256
  }, []);
2131
- const handleCompositionEnd = React6.useCallback(
2257
+ const handleCompositionEnd = React7.useCallback(
2132
2258
  (event) => {
2133
2259
  isComposingRef.current = false;
2134
2260
  onSearchValueChange?.(event.currentTarget.value);
@@ -2485,14 +2611,14 @@ function useFavoritesTabScript(options) {
2485
2611
  updateSelectedFavoriteTab,
2486
2612
  updateFavorites
2487
2613
  } = favorite;
2488
- const [open, setOpen] = React6.useState(false);
2489
- const [editing, setEditing] = React6.useState(false);
2490
- const [value, setValue] = React6.useState("");
2491
- const [scrollable, setScrollable] = React6.useState(false);
2492
- const scrollView = React6.useRef(null);
2493
- const inputRef = React6.useRef(null);
2494
- const spanRef = React6.useRef(null);
2495
- const [inputWidth, setInputWidth] = React6.useState(50);
2614
+ const [open, setOpen] = React7.useState(false);
2615
+ const [editing, setEditing] = React7.useState(false);
2616
+ const [value, setValue] = React7.useState("");
2617
+ const [scrollable, setScrollable] = React7.useState(false);
2618
+ const scrollView = React7.useRef(null);
2619
+ const inputRef = React7.useRef(null);
2620
+ const spanRef = React7.useRef(null);
2621
+ const [inputWidth, setInputWidth] = React7.useState(50);
2496
2622
  const updateScrollLayout = () => {
2497
2623
  setTimeout(() => {
2498
2624
  const { scrollWidth, clientWidth } = scrollView.current || {};
@@ -2555,14 +2681,14 @@ function useFavoritesTabScript(options) {
2555
2681
  updateSelectedFavoriteTab(tab);
2556
2682
  }, 0);
2557
2683
  };
2558
- React6.useEffect(() => {
2684
+ React7.useEffect(() => {
2559
2685
  if (value) {
2560
2686
  const rect = spanRef.current?.getBoundingClientRect();
2561
2687
  const offset = size === "sm" ? 0 : 14;
2562
2688
  setInputWidth(Math.max((rect?.width || 0) + offset, 50));
2563
2689
  }
2564
2690
  }, [value]);
2565
- React6.useEffect(() => {
2691
+ React7.useEffect(() => {
2566
2692
  updateScrollLayout();
2567
2693
  }, []);
2568
2694
  return {
@@ -2612,10 +2738,10 @@ var init_favoritesTabs = __esm({
2612
2738
  });
2613
2739
  function useFavoritesProps() {
2614
2740
  const { searchValue } = useMarketsContext();
2615
- const renderHeader = React6.useCallback((favorite) => {
2741
+ const renderHeader = React7.useCallback((favorite) => {
2616
2742
  return /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { px: 3, className: "oui-my-[6px]", children: /* @__PURE__ */ jsxRuntime.jsx(exports.FavoritesTabWidget, { favorite, size: "sm" }) });
2617
2743
  }, []);
2618
- const dataFilter = React6.useCallback(
2744
+ const dataFilter = React7.useCallback(
2619
2745
  (data, options) => {
2620
2746
  const { favorites, selectedFavoriteTab } = options;
2621
2747
  return favorites?.filter(
@@ -2630,7 +2756,7 @@ function useFavoritesProps() {
2630
2756
  },
2631
2757
  []
2632
2758
  );
2633
- const getFavoritesProps = React6.useCallback(
2759
+ const getFavoritesProps = React7.useCallback(
2634
2760
  (type) => {
2635
2761
  if (type === "favorites" /* Favorites */) {
2636
2762
  return { renderHeader, dataFilter };
@@ -2639,7 +2765,7 @@ function useFavoritesProps() {
2639
2765
  },
2640
2766
  [renderHeader, dataFilter]
2641
2767
  );
2642
- const renderEmptyView = React6.useCallback(
2768
+ const renderEmptyView = React7.useCallback(
2643
2769
  (options) => {
2644
2770
  if (options.type === "favorites" /* Favorites */ && !searchValue) {
2645
2771
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -2680,7 +2806,7 @@ function tabKey(tab, index) {
2680
2806
  }
2681
2807
  function resolveIcon(icon) {
2682
2808
  if (typeof icon === "string") {
2683
- return React6.createElement("img", {
2809
+ return React7.createElement("img", {
2684
2810
  src: icon,
2685
2811
  alt: "",
2686
2812
  style: { width: 16, height: 16 }
@@ -2724,7 +2850,7 @@ function composeTabTitle(label, options) {
2724
2850
  }
2725
2851
  function resolveTabTriggerIcon(tab, fallbackIcon) {
2726
2852
  const resolvedIcon = typeof tab.icon !== "undefined" ? resolveIcon(tab.icon) : fallbackIcon;
2727
- return React6.isValidElement(resolvedIcon) ? resolvedIcon : void 0;
2853
+ return React7.isValidElement(resolvedIcon) ? resolvedIcon : void 0;
2728
2854
  }
2729
2855
  function resolveTabTitle(tab, titleOverrides, rwaTitle) {
2730
2856
  if (isBuiltInMarketTab(tab) && tab.type === "favorites") {
@@ -2743,7 +2869,7 @@ function resolveTabTitle(tab, titleOverrides, rwaTitle) {
2743
2869
  }
2744
2870
  function useBuiltInTitles() {
2745
2871
  const { t } = i18n.useTranslation();
2746
- return React6.useMemo(
2872
+ return React7.useMemo(
2747
2873
  () => Object.fromEntries(
2748
2874
  Object.entries(BUILT_IN_TITLE_MAP).map(([key, i18nKey]) => [
2749
2875
  key,
@@ -2758,7 +2884,7 @@ function getCustomTabDataFilter(tab) {
2758
2884
  return (data) => data.filter((item) => tab.match(item));
2759
2885
  }
2760
2886
  function useCustomTabDataFilters(tabs) {
2761
- return React6.useMemo(() => {
2887
+ return React7.useMemo(() => {
2762
2888
  if (!tabs) return {};
2763
2889
  const result = {};
2764
2890
  tabs.forEach((tab, i) => {
@@ -2776,17 +2902,19 @@ var init_tabUtils = __esm({
2776
2902
  BUILT_IN_TITLE_MAP = {
2777
2903
  community: "markets.community",
2778
2904
  all: "common.all",
2905
+ preTge: "markets.preTge",
2779
2906
  newListing: "markets.newListings",
2780
2907
  recent: "markets.recent"
2781
2908
  };
2782
2909
  }
2783
2910
  });
2784
- var MobileMarketsDataList;
2911
+ var TWO_LINE_MARKET_ROW_CLASS, MobileMarketsDataList;
2785
2912
  var init_marketsDataList_mobile_ui = __esm({
2786
2913
  "src/pages/home/marketsDataList/marketsDataList.mobile.ui.tsx"() {
2787
2914
  init_communityBrokerTabs();
2788
2915
  init_marketsList();
2789
2916
  init_marketsProvider();
2917
+ init_rwaSubcategoryTabs();
2790
2918
  init_rwaTab();
2791
2919
  init_searchInput();
2792
2920
  init_column();
@@ -2795,12 +2923,13 @@ var init_marketsDataList_mobile_ui = __esm({
2795
2923
  init_useCommunityTabs();
2796
2924
  init_icons();
2797
2925
  init_type();
2926
+ TWO_LINE_MARKET_ROW_CLASS = "!oui-h-[54px]";
2798
2927
  MobileMarketsDataList = (props) => {
2799
2928
  const { activeTab, onTabChange, tabSort, onTabSort } = props;
2800
2929
  const { t } = i18n.useTranslation();
2801
2930
  const { tabs } = useMarketsContext();
2802
2931
  const tabDataFilters = useCustomTabDataFilters(tabs);
2803
- const getColumns = React6.useCallback(
2932
+ const getColumns = React7.useCallback(
2804
2933
  (favorite, isFavoriteList = false) => {
2805
2934
  return [
2806
2935
  getSymbolColumn(favorite, isFavoriteList, {
@@ -2813,7 +2942,7 @@ var init_marketsDataList_mobile_ui = __esm({
2813
2942
  [t]
2814
2943
  );
2815
2944
  const { getFavoritesProps } = useFavoritesProps();
2816
- const builtInMeta = React6.useMemo(
2945
+ const builtInMeta = React7.useMemo(
2817
2946
  () => ({
2818
2947
  favorites: {
2819
2948
  title: /* @__PURE__ */ jsxRuntime.jsx(FavoritesIcon, {}),
@@ -2835,6 +2964,11 @@ var init_marketsDataList_mobile_ui = __esm({
2835
2964
  value: "rwa",
2836
2965
  tabName: "rwa" /* Rwa */
2837
2966
  },
2967
+ preTge: {
2968
+ title: t("markets.preTge"),
2969
+ value: "preTge",
2970
+ tabName: "preTge" /* PreTge */
2971
+ },
2838
2972
  newListing: {
2839
2973
  title: t("markets.newListings"),
2840
2974
  icon: /* @__PURE__ */ jsxRuntime.jsx(NewListingsIcon, {}),
@@ -2845,29 +2979,54 @@ var init_marketsDataList_mobile_ui = __esm({
2845
2979
  [t]
2846
2980
  );
2847
2981
  const renderTab = (type) => {
2982
+ const list = /* @__PURE__ */ jsxRuntime.jsx(
2983
+ exports.MarketsListWidget,
2984
+ {
2985
+ type,
2986
+ initialSort: tabSort[type],
2987
+ onSort: onTabSort(type),
2988
+ getColumns,
2989
+ rowClassName: TWO_LINE_MARKET_ROW_CLASS,
2990
+ ...getFavoritesProps(type)
2991
+ }
2992
+ );
2848
2993
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
2849
2994
  /* @__PURE__ */ jsxRuntime.jsx(
2850
2995
  SearchInput,
2851
2996
  {
2852
2997
  classNames: {
2853
2998
  root: ui.cn(
2854
- "oui-mx-3 oui-mb-4 oui-mt-5",
2855
- activeTab !== "favorites" /* Favorites */ && "oui-mb-2"
2999
+ "oui-mx-3 oui-mt-5",
3000
+ activeTab === "favorites" /* Favorites */ ? "oui-mb-4" : "oui-mb-2"
2856
3001
  )
2857
3002
  }
2858
3003
  }
2859
3004
  ),
2860
- /* @__PURE__ */ jsxRuntime.jsx(
2861
- exports.MarketsListWidget,
3005
+ type === "rwa" /* Rwa */ ? /* @__PURE__ */ jsxRuntime.jsx(
3006
+ RwaSubcategoryTabs,
2862
3007
  {
2863
- type,
2864
- initialSort: tabSort[type],
2865
- onSort: onTabSort(type),
2866
- getColumns,
2867
- rowClassName: "!oui-h-[34px]",
2868
- ...getFavoritesProps(type)
3008
+ storageKey: "orderly_mobile_markets_datalist_rwa_sel_sub_tab",
3009
+ size: "md",
3010
+ classNames: {
3011
+ tabsList: "oui-px-3 oui-pt-1 oui-pb-2",
3012
+ tabsContent: "oui-h-full",
3013
+ scrollIndicator: "oui-mx-3"
3014
+ },
3015
+ className: "oui-mobileMarketsDataList-rwa-tabs",
3016
+ showScrollIndicator: true,
3017
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx(
3018
+ exports.MarketsListWidget,
3019
+ {
3020
+ type,
3021
+ dataFilter,
3022
+ initialSort: tabSort[type],
3023
+ onSort: onTabSort(type),
3024
+ getColumns,
3025
+ rowClassName: TWO_LINE_MARKET_ROW_CLASS
3026
+ }
3027
+ )
2869
3028
  }
2870
- )
3029
+ ) : list
2871
3030
  ] });
2872
3031
  };
2873
3032
  const renderCommunityList = (selected) => {
@@ -2878,7 +3037,7 @@ var init_marketsDataList_mobile_ui = __esm({
2878
3037
  initialSort: tabSort["community" /* Community */],
2879
3038
  onSort: onTabSort("community" /* Community */),
2880
3039
  getColumns,
2881
- rowClassName: "!oui-h-[34px]",
3040
+ rowClassName: TWO_LINE_MARKET_ROW_CLASS,
2882
3041
  dataFilter: createCommunityBrokerFilter(selected)
2883
3042
  }
2884
3043
  );
@@ -2916,7 +3075,7 @@ var init_marketsDataList_mobile_ui = __esm({
2916
3075
  SearchInput,
2917
3076
  {
2918
3077
  classNames: {
2919
- root: ui.cn("oui-mx-3 oui-mb-4 oui-mt-5", "oui-mb-2")
3078
+ root: "oui-mx-3 oui-mb-2 oui-mt-5"
2920
3079
  }
2921
3080
  }
2922
3081
  ),
@@ -2953,7 +3112,7 @@ var init_marketsDataList_mobile_ui = __esm({
2953
3112
  SearchInput,
2954
3113
  {
2955
3114
  classNames: {
2956
- root: ui.cn("oui-mx-3 oui-mb-4 oui-mt-5", "oui-mb-2")
3115
+ root: "oui-mx-3 oui-mb-2 oui-mt-5"
2957
3116
  }
2958
3117
  }
2959
3118
  ),
@@ -2965,7 +3124,7 @@ var init_marketsDataList_mobile_ui = __esm({
2965
3124
  initialSort: tabSort[key],
2966
3125
  onSort: onTabSort(key),
2967
3126
  getColumns,
2968
- rowClassName: "!oui-h-[34px]"
3127
+ rowClassName: TWO_LINE_MARKET_ROW_CLASS
2969
3128
  }
2970
3129
  )
2971
3130
  ]
@@ -2985,7 +3144,7 @@ function useTabSort(options) {
2985
3144
  sortOrder: "desc"
2986
3145
  }
2987
3146
  });
2988
- const onTabSort = React6.useCallback(
3147
+ const onTabSort = React7.useCallback(
2989
3148
  (type) => (sort) => {
2990
3149
  setTabSort({ ...tabSort, [type]: sort });
2991
3150
  },
@@ -3002,14 +3161,14 @@ var init_useTabSort = __esm({
3002
3161
  }
3003
3162
  });
3004
3163
  function useMarketsDataListScript() {
3005
- const [activeTab, setActiveTab] = React6.useState(
3164
+ const [activeTab, setActiveTab] = React7.useState(
3006
3165
  "all" /* All */
3007
3166
  );
3008
3167
  const { clearSearchValue, searchValue } = useMarketsContext();
3009
3168
  const { tabSort, onTabSort } = useTabSort({
3010
3169
  storageKey: MOBILE_MARKETS_TAB_SORT_STORAGE_KEY
3011
3170
  });
3012
- React6.useEffect(() => {
3171
+ React7.useEffect(() => {
3013
3172
  clearSearchValue?.();
3014
3173
  }, [activeTab]);
3015
3174
  return {
@@ -3037,7 +3196,7 @@ var init_column3 = __esm({
3037
3196
  init_symbolDisplay();
3038
3197
  useMarketsListFullColumns = (favorite, isFavoriteList = false) => {
3039
3198
  const { t } = i18n.useTranslation();
3040
- const columns = React6.useMemo(() => {
3199
+ const columns = React7.useMemo(() => {
3041
3200
  return [
3042
3201
  {
3043
3202
  title: /* @__PURE__ */ jsxRuntime.jsx(UnFavoritesIcon, { className: "oui-mt-1" }),
@@ -3079,7 +3238,7 @@ var init_column3 = __esm({
3079
3238
  onSort: true,
3080
3239
  render: (value, record) => {
3081
3240
  return /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, itemAlign: "center", children: [
3082
- /* @__PURE__ */ jsxRuntime.jsx(exports.SymbolDisplay, { formatString: "base", showIcon: true, children: value }),
3241
+ /* @__PURE__ */ jsxRuntime.jsx(exports.SymbolDisplay, { formatString: "base", showIcon: true, record, children: value }),
3083
3242
  typeof record.leverage === "number" && /* @__PURE__ */ jsxRuntime.jsxs(ui.Badge, { size: "xs", color: "primary", children: [
3084
3243
  record.leverage,
3085
3244
  "x"
@@ -3266,11 +3425,11 @@ var init_favoritesListFull_script = __esm({
3266
3425
  pageSize: 10
3267
3426
  });
3268
3427
  const [data, favorite] = hooks.useMarkets(hooks.MarketsType.FAVORITES);
3269
- const [loading, setLoading] = React6.useState(true);
3428
+ const [loading, setLoading] = React7.useState(true);
3270
3429
  const { favorites, selectedFavoriteTab } = favorite;
3271
3430
  const { searchValue } = useMarketsContext();
3272
3431
  const { onSort, getSortedList } = useSort();
3273
- const filterData = React6.useMemo(() => {
3432
+ const filterData = React7.useMemo(() => {
3274
3433
  const filterList = favorites?.filter(
3275
3434
  (item) => item.tabs?.findIndex((tab) => tab.id === selectedFavoriteTab.id) !== -1
3276
3435
  )?.map((fav) => {
@@ -3282,14 +3441,14 @@ var init_favoritesListFull_script = __esm({
3282
3441
  })?.filter((item) => !!item);
3283
3442
  return searchBySymbol(filterList, searchValue, "base-type");
3284
3443
  }, [data, selectedFavoriteTab, favorites, searchValue]);
3285
- const dataSource = React6.useMemo(
3444
+ const dataSource = React7.useMemo(
3286
3445
  () => getSortedList(filterData),
3287
3446
  [filterData, getSortedList]
3288
3447
  );
3289
- React6.useEffect(() => {
3448
+ React7.useEffect(() => {
3290
3449
  setLoading(false);
3291
3450
  }, [favorites]);
3292
- React6.useEffect(() => {
3451
+ React7.useEffect(() => {
3293
3452
  setPage(1);
3294
3453
  }, [searchValue]);
3295
3454
  return {
@@ -3359,7 +3518,7 @@ var init_marketsListFull_ui = __esm({
3359
3518
  onSymbolChange?.(record);
3360
3519
  favorite.addToHistory(record);
3361
3520
  },
3362
- "data-testid": `oui-testid-markets-${type === "new" ? "newListing" : type === "rwa" ? "rwa" : "all"}-tr-${record.symbol}`
3521
+ "data-testid": `oui-testid-markets-${type === "new" ? "newListing" : type === "rwa" ? "rwa" : type === "preTge" ? "preTge" : "all"}-tr-${record.symbol}`
3363
3522
  };
3364
3523
  },
3365
3524
  generatedRowKey: (record) => record.symbol,
@@ -3384,34 +3543,35 @@ var init_marketsListFull_script = __esm({
3384
3543
  MarketsTypeMap2 = {
3385
3544
  all: hooks.MarketsType.ALL,
3386
3545
  new: hooks.MarketsType.NEW_LISTING,
3387
- rwa: hooks.MarketsType.RWA
3546
+ rwa: hooks.MarketsType.RWA,
3547
+ preTge: hooks.MarketsType.PRE_TGE
3388
3548
  };
3389
3549
  exports.useMarketsListFullScript = (options) => {
3390
3550
  const { type = "all", dataFilter } = options;
3391
- const [loading, setLoading] = React6.useState(true);
3551
+ const [loading, setLoading] = React7.useState(true);
3392
3552
  const { setPage, pagination } = ui.usePagination({
3393
3553
  pageSize: 100
3394
3554
  });
3395
3555
  const [data, favorite] = hooks.useMarkets(MarketsTypeMap2[type]);
3396
3556
  const { searchValue } = useMarketsContext();
3397
3557
  const { onSort, getSortedList, sort } = useSort(options.initialSort);
3398
- const dataSource = React6.useMemo(() => {
3558
+ const dataSource = React7.useMemo(() => {
3399
3559
  const filtered = typeof dataFilter === "function" ? dataFilter(data) : data;
3400
3560
  const searchList = searchBySymbol(filtered, searchValue, "base-type");
3401
3561
  return getSortedList(searchList);
3402
3562
  }, [data, dataFilter, getSortedList, searchValue]);
3403
- React6.useEffect(() => {
3563
+ React7.useEffect(() => {
3404
3564
  setLoading(false);
3405
3565
  }, [data]);
3406
- React6.useEffect(() => {
3566
+ React7.useEffect(() => {
3407
3567
  setPage(1);
3408
3568
  }, [searchValue]);
3409
- React6.useEffect(() => {
3569
+ React7.useEffect(() => {
3410
3570
  if (type === "all") {
3411
3571
  favorite.updateTabsSortState("all", sort?.sortKey, sort?.sortOrder);
3412
3572
  }
3413
3573
  }, [sort, type]);
3414
- const initialSort = React6.useMemo(() => {
3574
+ const initialSort = React7.useMemo(() => {
3415
3575
  const sortStore = type === "all" ? favorite.tabSort?.all : void 0;
3416
3576
  return {
3417
3577
  sortKey: sortStore?.sortKey || options?.initialSort?.sortKey,
@@ -3461,22 +3621,23 @@ var init_marketsDataList_ui = __esm({
3461
3621
  init_communityBrokerTabs();
3462
3622
  init_favoritesEmpty();
3463
3623
  init_marketsProvider();
3624
+ init_rwaSubcategoryTabs();
3464
3625
  init_rwaTab();
3465
3626
  init_tabUtils();
3466
3627
  init_useCommunityTabs();
3467
3628
  init_icons();
3468
3629
  init_type();
3469
- LazySearchInput = React6__default.default.lazy(
3630
+ LazySearchInput = React7__default.default.lazy(
3470
3631
  () => Promise.resolve().then(() => (init_searchInput(), searchInput_exports)).then((mod) => {
3471
3632
  return { default: mod.SearchInput };
3472
3633
  })
3473
3634
  );
3474
- LazyFavoritesListFullWidget = React6__default.default.lazy(
3635
+ LazyFavoritesListFullWidget = React7__default.default.lazy(
3475
3636
  () => Promise.resolve().then(() => (init_favoritesListFull(), favoritesListFull_exports)).then((mod) => {
3476
3637
  return { default: mod.FavoritesListFullWidget };
3477
3638
  })
3478
3639
  );
3479
- LazyMarketsListFullWidget = React6__default.default.lazy(
3640
+ LazyMarketsListFullWidget = React7__default.default.lazy(
3480
3641
  () => Promise.resolve().then(() => (init_marketsListFull(), marketsListFull_exports)).then((mod) => {
3481
3642
  return { default: mod.MarketsListFullWidget };
3482
3643
  })
@@ -3487,7 +3648,7 @@ var init_marketsDataList_ui = __esm({
3487
3648
  const { t } = i18n.useTranslation();
3488
3649
  const { tabs } = useMarketsContext();
3489
3650
  const tabDataFilters = useCustomTabDataFilters(tabs);
3490
- const builtInMeta = React6.useMemo(
3651
+ const builtInMeta = React7.useMemo(
3491
3652
  () => ({
3492
3653
  favorites: {
3493
3654
  title: /* @__PURE__ */ jsxRuntime.jsx(FavoritesIcon, {}),
@@ -3516,6 +3677,13 @@ var init_marketsDataList_ui = __esm({
3516
3677
  listType: "rwa",
3517
3678
  initialSort: DEFAULT_SORT
3518
3679
  },
3680
+ preTge: {
3681
+ title: t("markets.preTge"),
3682
+ value: "preTge",
3683
+ testid: "oui-testid-markets-preTge-tab",
3684
+ listType: "preTge",
3685
+ initialSort: DEFAULT_SORT
3686
+ },
3519
3687
  newListing: {
3520
3688
  title: t("markets.newListings"),
3521
3689
  icon: /* @__PURE__ */ jsxRuntime.jsx(NewListingsIcon, {}),
@@ -3534,7 +3702,7 @@ var init_marketsDataList_ui = __esm({
3534
3702
  size: "xl",
3535
3703
  value: activeTab,
3536
3704
  onValueChange: onTabChange,
3537
- trailing: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySearchInput, { classNames: { root: "oui-my-1 oui-w-[240px]" } }) }),
3705
+ trailing: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySearchInput, { classNames: { root: "oui-my-1 oui-w-[240px]" } }) }),
3538
3706
  classNames: {
3539
3707
  tabsList: "oui-tabs-markets-list",
3540
3708
  tabsContent: "oui-tabs-markets-content",
@@ -3564,7 +3732,7 @@ var init_marketsDataList_ui = __esm({
3564
3732
  icon: tab.type === "favorites" || tab.type === "rwa" ? void 0 : resolveTabTriggerIcon(tab, meta.icon),
3565
3733
  value: meta.value,
3566
3734
  testid: meta.testid,
3567
- children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: tab.type === "favorites" ? /* @__PURE__ */ jsxRuntime.jsx(
3735
+ children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: tab.type === "favorites" ? /* @__PURE__ */ jsxRuntime.jsx(
3568
3736
  LazyFavoritesListFullWidget,
3569
3737
  {
3570
3738
  emptyView: !searchValue && /* @__PURE__ */ jsxRuntime.jsx(
@@ -3585,7 +3753,7 @@ var init_marketsDataList_ui = __esm({
3585
3753
  },
3586
3754
  className: "oui-marketsDataList-community-tabs",
3587
3755
  showScrollIndicator: true,
3588
- renderPanel: (selected) => /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3756
+ renderPanel: (selected) => /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3589
3757
  LazyMarketsListFullWidget,
3590
3758
  {
3591
3759
  type: "all",
@@ -3594,6 +3762,26 @@ var init_marketsDataList_ui = __esm({
3594
3762
  }
3595
3763
  ) })
3596
3764
  }
3765
+ ) : tab.type === "rwa" ? /* @__PURE__ */ jsxRuntime.jsx(
3766
+ RwaSubcategoryTabs,
3767
+ {
3768
+ storageKey: "orderly_markets_datalist_rwa_sel_sub_tab",
3769
+ size: "md",
3770
+ classNames: {
3771
+ tabsList: "oui-px-3 oui-pt-1 oui-pb-2",
3772
+ tabsContent: "oui-h-full"
3773
+ },
3774
+ className: "oui-marketsDataList-rwa-tabs",
3775
+ showScrollIndicator: true,
3776
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3777
+ LazyMarketsListFullWidget,
3778
+ {
3779
+ type: "rwa",
3780
+ initialSort: meta.initialSort,
3781
+ dataFilter
3782
+ }
3783
+ ) })
3784
+ }
3597
3785
  ) : /* @__PURE__ */ jsxRuntime.jsx(
3598
3786
  LazyMarketsListFullWidget,
3599
3787
  {
@@ -3617,7 +3805,7 @@ var init_marketsDataList_ui = __esm({
3617
3805
  suffix: tab.suffix
3618
3806
  }),
3619
3807
  value: key,
3620
- children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3808
+ children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3621
3809
  LazyMarketsListFullWidget,
3622
3810
  {
3623
3811
  type: "all",
@@ -3669,15 +3857,16 @@ var init_expandMarkets_ui = __esm({
3669
3857
  init_type();
3670
3858
  init_communityBrokerTabs();
3671
3859
  init_marketsProvider();
3860
+ init_rwaSubcategoryTabs();
3672
3861
  init_rwaTab();
3673
3862
  init_useFavoritesExtraProps();
3674
3863
  init_tabUtils();
3675
- LazySearchInput2 = React6__default.default.lazy(
3864
+ LazySearchInput2 = React7__default.default.lazy(
3676
3865
  () => Promise.resolve().then(() => (init_searchInput(), searchInput_exports)).then((mod) => {
3677
3866
  return { default: mod.SearchInput };
3678
3867
  })
3679
3868
  );
3680
- LazyMarketsListWidget = React6__default.default.lazy(
3869
+ LazyMarketsListWidget = React7__default.default.lazy(
3681
3870
  () => Promise.resolve().then(() => (init_marketsList(), marketsList_exports)).then((mod) => {
3682
3871
  return { default: mod.MarketsListWidget };
3683
3872
  })
@@ -3701,7 +3890,42 @@ var init_expandMarkets_ui = __esm({
3701
3890
  const tabDataFilters = useCustomTabDataFilters(tabs);
3702
3891
  const renderBuiltInContent = (type) => {
3703
3892
  const tabType = type;
3704
- return /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3893
+ if (tabType === "rwa" /* Rwa */) {
3894
+ return /* @__PURE__ */ jsxRuntime.jsx(
3895
+ RwaSubcategoryTabs,
3896
+ {
3897
+ storageKey: "orderly_expand_markets_rwa_sel_sub_tab",
3898
+ classNames: {
3899
+ tabsList: "oui-px-3 oui-pt-1 oui-pb-2",
3900
+ tabsListContainer: "oui-shrink-0",
3901
+ tabsContent: "oui-min-h-0 oui-min-w-0 oui-w-full oui-flex-1 oui-overflow-hidden"
3902
+ },
3903
+ className: ui.cn(
3904
+ "oui-expandMarkets-rwa-tabs",
3905
+ "oui-flex oui-size-full oui-min-h-0 oui-min-w-0 oui-flex-col"
3906
+ ),
3907
+ showScrollIndicator: true,
3908
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3909
+ LazyMarketsListWidget,
3910
+ {
3911
+ type: tabType,
3912
+ dataFilter,
3913
+ initialSort: tabSort[type],
3914
+ onSort: onTabSort(tabType),
3915
+ tableClassNames: {
3916
+ root: expandListTableClassNames.root,
3917
+ scroll: ui.cn(
3918
+ expandListTableClassNames.scroll,
3919
+ "oui-px-1",
3920
+ "oui-pb-2"
3921
+ )
3922
+ }
3923
+ }
3924
+ ) }) })
3925
+ }
3926
+ );
3927
+ }
3928
+ return /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3705
3929
  LazyMarketsListWidget,
3706
3930
  {
3707
3931
  type: tabType,
@@ -3740,7 +3964,7 @@ var init_expandMarkets_ui = __esm({
3740
3964
  "oui-flex oui-size-full oui-min-h-0 oui-min-w-0 oui-flex-col"
3741
3965
  ),
3742
3966
  showScrollIndicator: true,
3743
- renderPanel: (selected) => /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3967
+ renderPanel: (selected) => /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3744
3968
  LazyMarketsListWidget,
3745
3969
  {
3746
3970
  type: "all" /* All */,
@@ -3761,7 +3985,7 @@ var init_expandMarkets_ui = __esm({
3761
3985
  );
3762
3986
  };
3763
3987
  const renderCustomContent = (key) => {
3764
- return /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3988
+ return /* @__PURE__ */ jsxRuntime.jsx(ExpandMarketsListPanel, { children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3765
3989
  LazyMarketsListWidget,
3766
3990
  {
3767
3991
  type: "all" /* All */,
@@ -3789,7 +4013,7 @@ var init_expandMarkets_ui = __esm({
3789
4013
  ),
3790
4014
  height: "100%",
3791
4015
  children: [
3792
- /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "oui-expandMarkets-header", px: 3, pb: 2, children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
4016
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "oui-expandMarkets-header", px: 3, pb: 2, children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
3793
4017
  LazySearchInput2,
3794
4018
  {
3795
4019
  classNames: { root: "oui-expandMarkets-search-input" }
@@ -3851,14 +4075,14 @@ var init_constant = __esm({
3851
4075
  }
3852
4076
  });
3853
4077
  function useExpandMarketsScript(options) {
3854
- const [activeTab, setActiveTab] = React6.useState(
4078
+ const [activeTab, setActiveTab] = React7.useState(
3855
4079
  options.activeTab
3856
4080
  );
3857
4081
  const { tabSort, onTabSort } = useTabSort({
3858
4082
  storageKey: SIDE_MARKETS_TAB_SORT_STORAGE_KEY
3859
4083
  });
3860
4084
  const { clearSearchValue } = useMarketsContext();
3861
- const onTabChange = React6.useCallback(
4085
+ const onTabChange = React7.useCallback(
3862
4086
  (value) => {
3863
4087
  if (typeof options?.onTabChange === "function") {
3864
4088
  options.onTabChange(value);
@@ -3868,10 +4092,10 @@ function useExpandMarketsScript(options) {
3868
4092
  },
3869
4093
  [options?.onTabChange]
3870
4094
  );
3871
- React6.useEffect(() => {
4095
+ React7.useEffect(() => {
3872
4096
  setActiveTab(options?.activeTab || "favorites" /* Favorites */);
3873
4097
  }, [options?.activeTab]);
3874
- React6.useEffect(() => {
4098
+ React7.useEffect(() => {
3875
4099
  clearSearchValue?.();
3876
4100
  }, [activeTab]);
3877
4101
  return {
@@ -3904,6 +4128,14 @@ var init_builtInTabRegistry = __esm({
3904
4128
  },
3905
4129
  all: { type: "all" },
3906
4130
  rwa: { type: "rwa" },
4131
+ preTge: {
4132
+ type: "preTge",
4133
+ isVisible: (symbolList, { symbolsInfo }) => {
4134
+ return symbolList.some(
4135
+ (m) => Boolean(m?.is_pretge ?? symbolsInfo?.[m.symbol]?.("is_pretge"))
4136
+ );
4137
+ }
4138
+ },
3907
4139
  newListing: { type: "newListing" },
3908
4140
  recent: { type: "recent" }
3909
4141
  };
@@ -3912,7 +4144,8 @@ var init_builtInTabRegistry = __esm({
3912
4144
  { type: "favorites" },
3913
4145
  { type: "all" },
3914
4146
  { type: "rwa" },
3915
- { ...exports.builtInTabs.community }
4147
+ { ...exports.builtInTabs.community },
4148
+ { ...exports.builtInTabs.preTge }
3916
4149
  ],
3917
4150
  expandMarkets: [
3918
4151
  { type: "favorites" },
@@ -3920,7 +4153,8 @@ var init_builtInTabRegistry = __esm({
3920
4153
  { type: "rwa" },
3921
4154
  { ...exports.builtInTabs.community },
3922
4155
  { type: "newListing" },
3923
- { type: "recent" }
4156
+ { type: "recent" },
4157
+ { ...exports.builtInTabs.preTge }
3924
4158
  ],
3925
4159
  dropDownMarkets: [
3926
4160
  { type: "favorites" },
@@ -3928,7 +4162,8 @@ var init_builtInTabRegistry = __esm({
3928
4162
  { type: "rwa" },
3929
4163
  { ...exports.builtInTabs.community },
3930
4164
  { type: "newListing" },
3931
- { type: "recent" }
4165
+ { type: "recent" },
4166
+ { ...exports.builtInTabs.preTge }
3932
4167
  ],
3933
4168
  subMenuMarkets: [
3934
4169
  { type: "favorites" },
@@ -3936,14 +4171,16 @@ var init_builtInTabRegistry = __esm({
3936
4171
  { type: "rwa" },
3937
4172
  { ...exports.builtInTabs.community },
3938
4173
  { type: "newListing" },
3939
- { type: "recent" }
4174
+ { type: "recent" },
4175
+ { ...exports.builtInTabs.preTge }
3940
4176
  ],
3941
4177
  marketsDataList: [
3942
4178
  { type: "favorites" },
3943
4179
  { type: "all" },
3944
4180
  { type: "rwa" },
3945
4181
  { ...exports.builtInTabs.community },
3946
- { type: "newListing" }
4182
+ { type: "newListing" },
4183
+ { ...exports.builtInTabs.preTge }
3947
4184
  ],
3948
4185
  horizontalMarkets: [
3949
4186
  { type: "all" },
@@ -3959,13 +4196,21 @@ function useMarketCategories(componentKey) {
3959
4196
  const { i18n: i18n2 } = i18n.useTranslation();
3960
4197
  const symbolList = hooks.useMarketList();
3961
4198
  const rwaSymbolsInfo = hooks.useRwaSymbolsInfo();
3962
- return React6.useMemo(() => {
4199
+ const symbolsInfo = hooks.useSymbolsInfo();
4200
+ return React7.useMemo(() => {
3963
4201
  const original = componentDefaultTabs[componentKey];
3964
4202
  const resolved = marketTabs ? marketTabs(original, { componentKey, builtIn: exports.builtInTabs }) : original;
3965
4203
  return resolved.filter(
3966
- (tab) => tab.isVisible?.(symbolList, { rwaSymbolsInfo }) ?? true
4204
+ (tab) => tab.isVisible?.(symbolList, { rwaSymbolsInfo, symbolsInfo }) ?? true
3967
4205
  );
3968
- }, [marketTabs, componentKey, i18n2.language, symbolList, rwaSymbolsInfo]);
4206
+ }, [
4207
+ marketTabs,
4208
+ componentKey,
4209
+ i18n2.language,
4210
+ symbolList,
4211
+ rwaSymbolsInfo,
4212
+ symbolsInfo
4213
+ ]);
3969
4214
  }
3970
4215
  var init_useMarketCategories = __esm({
3971
4216
  "src/components/shared/hooks/useMarketCategories.ts"() {
@@ -4029,7 +4274,7 @@ var init_columns = __esm({
4029
4274
  useFundingOverviewColumns = (selectedPeriod, setSelectedPeriod) => {
4030
4275
  const { t } = i18n.useTranslation();
4031
4276
  const { isMobile } = ui.useScreen();
4032
- return React6.useMemo(() => {
4277
+ return React7.useMemo(() => {
4033
4278
  return [
4034
4279
  {
4035
4280
  title: t("markets.column.market"),
@@ -4152,7 +4397,7 @@ var init_columns = __esm({
4152
4397
  FundingPeriodSelect = (props) => {
4153
4398
  const { t } = i18n.useTranslation();
4154
4399
  const { isMobile } = ui.useScreen();
4155
- const options = React6.useMemo(() => {
4400
+ const options = React7.useMemo(() => {
4156
4401
  return [
4157
4402
  {
4158
4403
  label: t("common.select.1d"),
@@ -4209,7 +4454,7 @@ var init_fundingOverview_ui = __esm({
4209
4454
  init_columns();
4210
4455
  exports.FundingOverview = (props) => {
4211
4456
  const { dataSource, isLoading, pagination, onSort } = props;
4212
- const [selectedPeriod, setSelectedPeriod] = React6.useState("1dPositive");
4457
+ const [selectedPeriod, setSelectedPeriod] = React7.useState("1dPositive");
4213
4458
  const columns = useFundingOverviewColumns(selectedPeriod, setSelectedPeriod);
4214
4459
  return /* @__PURE__ */ jsxRuntime.jsx(
4215
4460
  ui.DataTable,
@@ -4256,7 +4501,7 @@ var init_fundingOverview_script = __esm({
4256
4501
  const fundingRates = hooks.useFundingRates();
4257
4502
  const { onSort, getSortedList } = useSort();
4258
4503
  const { searchValue } = useMarketsContext();
4259
- const processedData = React6.useMemo(() => {
4504
+ const processedData = React7.useMemo(() => {
4260
4505
  if (!marketData?.length) {
4261
4506
  return [];
4262
4507
  }
@@ -4297,10 +4542,10 @@ var init_fundingOverview_script = __esm({
4297
4542
  };
4298
4543
  });
4299
4544
  }, [marketData, fundingHistory, fundingRates, getPositiveRates]);
4300
- const filteredData = React6.useMemo(() => {
4545
+ const filteredData = React7.useMemo(() => {
4301
4546
  return searchBySymbol(processedData, searchValue, "base-type");
4302
4547
  }, [processedData, searchValue, pagination]);
4303
- const dataSource = React6.useMemo(
4548
+ const dataSource = React7.useMemo(
4304
4549
  () => getSortedList(filteredData),
4305
4550
  [filteredData, getSortedList]
4306
4551
  );
@@ -4314,7 +4559,7 @@ var init_fundingOverview_mobile_ui = __esm({
4314
4559
  init_columns();
4315
4560
  MobileFundingOverview = (props) => {
4316
4561
  const { dataSource, isLoading, onSort } = props;
4317
- const [selectedPeriod, setSelectedPeriod] = React6.useState("1dPositive");
4562
+ const [selectedPeriod, setSelectedPeriod] = React7.useState("1dPositive");
4318
4563
  const columns = useFundingOverviewColumns(selectedPeriod, setSelectedPeriod);
4319
4564
  return /* @__PURE__ */ jsxRuntime.jsx(
4320
4565
  ui.DataTable,
@@ -4375,7 +4620,7 @@ var init_useEXchanges = __esm({
4375
4620
  const { comparisonProps } = useMarketsContext();
4376
4621
  const brokerName = comparisonProps?.exchangesName || "Orderly";
4377
4622
  const brokerIconSrc = comparisonProps?.exchangesIconSrc || "https://oss.orderly.network/static/exchange_logo/orderly.png";
4378
- const exchanges = React6.useMemo(() => {
4623
+ const exchanges = React7.useMemo(() => {
4379
4624
  return [
4380
4625
  brokerName,
4381
4626
  "Binance",
@@ -4411,7 +4656,7 @@ var init_columns2 = __esm({
4411
4656
  const { t } = i18n.useTranslation();
4412
4657
  const { isMobile } = ui.useScreen();
4413
4658
  const { exchanges, brokerName, brokerIconSrc } = useEXchanges();
4414
- const getImgSrc = React6.useCallback(
4659
+ const getImgSrc = React7.useCallback(
4415
4660
  (val) => {
4416
4661
  if (val === brokerName) {
4417
4662
  return brokerIconSrc;
@@ -4420,7 +4665,7 @@ var init_columns2 = __esm({
4420
4665
  },
4421
4666
  [brokerName, brokerIconSrc]
4422
4667
  );
4423
- return React6.useMemo(() => {
4668
+ return React7.useMemo(() => {
4424
4669
  return [
4425
4670
  {
4426
4671
  title: t("markets.column.market"),
@@ -4555,7 +4800,7 @@ var init_fundingComparison_script = __esm({
4555
4800
  const [markets] = hooks.useMarkets(hooks.MarketsType.ALL);
4556
4801
  const { data, isLoading } = hooks.useQuery("/v1/public/market_info/funding_comparison");
4557
4802
  const { data: futures } = hooks.useMarketsStream();
4558
- const processedData = React6.useMemo(() => {
4803
+ const processedData = React7.useMemo(() => {
4559
4804
  if (!Array.isArray(data) || !data.length) {
4560
4805
  return [];
4561
4806
  }
@@ -4600,10 +4845,10 @@ var init_fundingComparison_script = __esm({
4600
4845
  return result;
4601
4846
  });
4602
4847
  }, [data, futures, markets, fundingRates, exchanges, brokerName]);
4603
- const filteredData = React6.useMemo(() => {
4848
+ const filteredData = React7.useMemo(() => {
4604
4849
  return searchBySymbol(processedData, searchValue, "base-type");
4605
4850
  }, [processedData, searchValue, pagination]);
4606
- const dataSource = React6.useMemo(
4851
+ const dataSource = React7.useMemo(
4607
4852
  () => getSortedList(filteredData),
4608
4853
  [getSortedList, filteredData]
4609
4854
  );
@@ -4681,9 +4926,11 @@ __export(sideMarkets_ui_exports, {
4681
4926
  exports.SideMarkets = void 0;
4682
4927
  var init_sideMarkets_ui = __esm({
4683
4928
  "src/components/sideMarkets/sideMarkets.ui.tsx"() {
4929
+ init_type();
4684
4930
  init_expandMarkets();
4685
4931
  init_marketsList();
4686
4932
  init_marketsProvider();
4933
+ init_rwaSubcategoryTabs();
4687
4934
  init_useFavoritesExtraProps();
4688
4935
  exports.SideMarkets = (props) => {
4689
4936
  const { activeTab, onTabChange, className, tabSort, panelSize } = props;
@@ -4701,6 +4948,30 @@ var init_sideMarkets_ui = __esm({
4701
4948
  }
4702
4949
  );
4703
4950
  }
4951
+ if (activeTab === "rwa" /* Rwa */) {
4952
+ return /* @__PURE__ */ jsxRuntime.jsx(
4953
+ RwaSubcategoryTabs,
4954
+ {
4955
+ storageKey: "orderly_side_markets_rwa_sel_sub_tab",
4956
+ classNames: {
4957
+ tabsList: "oui-px-1 oui-pt-1 oui-pb-2",
4958
+ tabsContent: "oui-h-full",
4959
+ scrollIndicator: "oui-mx-1"
4960
+ },
4961
+ className: "oui-sideMarkets-rwa-tabs oui-h-full",
4962
+ showScrollIndicator: true,
4963
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx(
4964
+ exports.MarketsListWidget,
4965
+ {
4966
+ type: activeTab,
4967
+ dataFilter,
4968
+ initialSort: tabSort[activeTab],
4969
+ panelSize: "middle"
4970
+ }
4971
+ )
4972
+ }
4973
+ );
4974
+ }
4704
4975
  return /* @__PURE__ */ jsxRuntime.jsx(
4705
4976
  exports.MarketsListWidget,
4706
4977
  {
@@ -4730,10 +5001,12 @@ var init_column4 = __esm({
4730
5001
  init_column();
4731
5002
  exports.useDropDownMarketsColumns = () => {
4732
5003
  const { t } = i18n.useTranslation();
4733
- return React6.useCallback(
5004
+ return React7.useCallback(
4734
5005
  (favorite, isFavoriteList = false) => {
4735
5006
  return [
4736
- getSymbolColumn(favorite, isFavoriteList),
5007
+ getSymbolColumn(favorite, isFavoriteList, {
5008
+ symbolColumnWidth: 190
5009
+ }),
4737
5010
  getLastColumn(),
4738
5011
  get24hPercentageColumn(),
4739
5012
  {
@@ -4827,6 +5100,7 @@ var init_dropDownMarkets_ui = __esm({
4827
5100
  init_communityBrokerTabs();
4828
5101
  init_marketsList();
4829
5102
  init_marketsProvider();
5103
+ init_rwaSubcategoryTabs();
4830
5104
  init_rwaTab();
4831
5105
  init_searchInput();
4832
5106
  init_useFavoritesExtraProps();
@@ -4880,6 +5154,35 @@ var init_dropDownMarkets_ui = __esm({
4880
5154
  const { tabs } = useMarketsContext();
4881
5155
  const tabDataFilters = useCustomTabDataFilters(tabs);
4882
5156
  const renderBuiltInContent = (tabType) => {
5157
+ if (tabType === "rwa" /* Rwa */) {
5158
+ return /* @__PURE__ */ jsxRuntime.jsx(
5159
+ RwaSubcategoryTabs,
5160
+ {
5161
+ storageKey: "orderly_dropdown_markets_rwa_sel_sub_tab",
5162
+ classNames: {
5163
+ tabsList: "oui-px-3 oui-pt-1 oui-pb-2",
5164
+ tabsContent: "oui-h-full"
5165
+ },
5166
+ className: ui.cn("oui-dropDownMarkets-rwa-tabs", cls2),
5167
+ showScrollIndicator: true,
5168
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cls2, children: /* @__PURE__ */ jsxRuntime.jsx(
5169
+ exports.MarketsListWidget,
5170
+ {
5171
+ type: "rwa" /* Rwa */,
5172
+ initialSort: tabSort[tabType],
5173
+ onSort: onTabSort(tabType),
5174
+ getColumns,
5175
+ tableClassNames: {
5176
+ root: ui.cn("oui-dropDownMarkets-list", "!oui-bg-base-8"),
5177
+ scroll: "oui-pb-5 oui-px-1"
5178
+ },
5179
+ rowClassName: "!oui-h-[34px]",
5180
+ dataFilter
5181
+ }
5182
+ ) })
5183
+ }
5184
+ );
5185
+ }
4883
5186
  return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cls2, children: /* @__PURE__ */ jsxRuntime.jsx(
4884
5187
  exports.MarketsListWidget,
4885
5188
  {
@@ -5001,7 +5304,7 @@ var init_dropDownMarkets_ui = __esm({
5001
5304
  }
5002
5305
  });
5003
5306
  function useDropDownMarketsScript() {
5004
- const [open, setOpen] = React6.useState(false);
5307
+ const [open, setOpen] = React7.useState(false);
5005
5308
  const [activeTab, setActiveTab] = hooks.useLocalStorage(
5006
5309
  DROPDOWN_MARKETS_SEL_TAB_KEY,
5007
5310
  "all" /* All */
@@ -5013,7 +5316,7 @@ function useDropDownMarketsScript() {
5013
5316
  const hide = () => {
5014
5317
  setOpen(false);
5015
5318
  };
5016
- React6.useEffect(() => {
5319
+ React7.useEffect(() => {
5017
5320
  clearSearchValue?.();
5018
5321
  }, [activeTab]);
5019
5322
  return {
@@ -5133,7 +5436,7 @@ var init_marketItem_ui = __esm({
5133
5436
  init_symbolDisplay();
5134
5437
  MarketItemComponent = (props) => {
5135
5438
  const { symbol, tickerData, isActive, onSymbolClick } = props;
5136
- const handleClick = React6__default.default.useCallback(() => {
5439
+ const handleClick = React7__default.default.useCallback(() => {
5137
5440
  onSymbolClick(symbol);
5138
5441
  }, [symbol, onSymbolClick]);
5139
5442
  return /* @__PURE__ */ jsxRuntime.jsxs(
@@ -5183,7 +5486,7 @@ var init_marketItem_ui = __esm({
5183
5486
  }
5184
5487
  );
5185
5488
  };
5186
- exports.MarketItem = React6__default.default.memo(
5489
+ exports.MarketItem = React7__default.default.memo(
5187
5490
  MarketItemComponent,
5188
5491
  (prevProps, nextProps) => {
5189
5492
  return prevProps.symbol === nextProps.symbol && prevProps.isActive === nextProps.isActive && prevProps.tickerData["24h_close"] === nextProps.tickerData["24h_close"] && prevProps.tickerData.change === nextProps.tickerData.change && prevProps.tickerData.quote_dp === nextProps.tickerData.quote_dp && prevProps.onSymbolClick === nextProps.onSymbolClick;
@@ -5206,34 +5509,36 @@ var init_marketTypeFilter_ui = __esm({
5206
5509
  tabs
5207
5510
  } = props;
5208
5511
  const { t } = i18n.useTranslation();
5209
- const orderedOptions = React6__default.default.useMemo(() => {
5512
+ const orderedOptions = React7__default.default.useMemo(() => {
5210
5513
  if (!tabs) return [];
5211
5514
  return tabs.filter(
5212
5515
  (tab) => isCustomMarketTab(tab) || isBuiltInMarketTab(tab) && tab.type !== "favorites"
5213
5516
  );
5214
5517
  }, [tabs]);
5215
- const hasFavoritesTab = React6__default.default.useMemo(() => {
5518
+ const hasFavoritesTab = React7__default.default.useMemo(() => {
5216
5519
  return tabs?.some(
5217
5520
  (tab) => isBuiltInMarketTab(tab) && tab.type === "favorites"
5218
5521
  );
5219
5522
  }, [tabs]);
5220
- const [isOpen, setIsOpen] = React6.useState(false);
5221
- const dropdownRef = React6.useRef(null);
5523
+ const [isOpen, setIsOpen] = React7.useState(false);
5524
+ const dropdownRef = React7.useRef(null);
5222
5525
  const [, favorite] = hooks.useMarkets(hooks.MarketsType.FAVORITES);
5223
5526
  const hasFavorites = (favorite?.favorites?.length || 0) > 0;
5224
- const titleOverrides = React6__default.default.useMemo(
5527
+ const titleOverrides = React7__default.default.useMemo(
5225
5528
  () => ({
5226
5529
  all: t("markets.allMarkets"),
5227
5530
  newListing: t("markets.newListings"),
5228
- recent: t("markets.recent")
5531
+ recent: t("markets.recent"),
5532
+ rwa: t("markets.tradFi"),
5533
+ preTge: t("markets.preTge")
5229
5534
  }),
5230
5535
  [t]
5231
5536
  );
5232
- const getOptionLabel = React6.useCallback(
5233
- (tab) => resolveTabTitle(tab, titleOverrides, t("common.rwa")),
5234
- [t, titleOverrides]
5537
+ const getOptionLabel = React7.useCallback(
5538
+ (tab) => resolveTabTitle(tab, titleOverrides, titleOverrides.rwa),
5539
+ [titleOverrides]
5235
5540
  );
5236
- React6.useEffect(() => {
5541
+ React7.useEffect(() => {
5237
5542
  const handleClickOutside = (event) => {
5238
5543
  if (dropdownRef.current && !dropdownRef.current.contains(event.target)) {
5239
5544
  setIsOpen(false);
@@ -5246,10 +5551,10 @@ var init_marketTypeFilter_ui = __esm({
5246
5551
  document.removeEventListener("mousedown", handleClickOutside);
5247
5552
  };
5248
5553
  }, [isOpen]);
5249
- const handleFilterClick = React6.useCallback(() => {
5554
+ const handleFilterClick = React7.useCallback(() => {
5250
5555
  setIsOpen((prev) => !prev);
5251
5556
  }, []);
5252
- const handleOptionClick = React6.useCallback(
5557
+ const handleOptionClick = React7.useCallback(
5253
5558
  (marketType) => {
5254
5559
  onMarketTypeChange(marketType);
5255
5560
  setIsOpen(false);
@@ -5419,7 +5724,7 @@ var init_horizontalMarkets_ui = __esm({
5419
5724
  init_marketsProvider();
5420
5725
  init_marketItem_ui();
5421
5726
  init_marketTypeFilter_ui();
5422
- exports.HorizontalMarkets = React6__default.default.memo((props) => {
5727
+ exports.HorizontalMarkets = React7__default.default.memo((props) => {
5423
5728
  const {
5424
5729
  symbols,
5425
5730
  tickerData,
@@ -5431,7 +5736,7 @@ var init_horizontalMarkets_ui = __esm({
5431
5736
  dropdownPos
5432
5737
  } = props;
5433
5738
  const { tabs } = useMarketsContext();
5434
- const renderMarketItem = React6__default.default.useCallback(
5739
+ const renderMarketItem = React7__default.default.useCallback(
5435
5740
  (symbol, index) => {
5436
5741
  const data = tickerData[symbol];
5437
5742
  const isActive = currentSymbol === symbol;
@@ -5451,7 +5756,7 @@ var init_horizontalMarkets_ui = __esm({
5451
5756
  },
5452
5757
  [tickerData, currentSymbol, onSymbolClick]
5453
5758
  );
5454
- const carouselOptions = React6__default.default.useMemo(
5759
+ const carouselOptions = React7__default.default.useMemo(
5455
5760
  () => ({
5456
5761
  loop: true,
5457
5762
  align: "start",
@@ -5459,7 +5764,7 @@ var init_horizontalMarkets_ui = __esm({
5459
5764
  }),
5460
5765
  []
5461
5766
  );
5462
- const autoScrollOptions = React6__default.default.useMemo(
5767
+ const autoScrollOptions = React7__default.default.useMemo(
5463
5768
  () => ({
5464
5769
  speed: 1,
5465
5770
  direction: "forward",
@@ -5589,7 +5894,7 @@ var init_funding_mobile_ui = __esm({
5589
5894
  }
5590
5895
  });
5591
5896
  function useFundingScript() {
5592
- const [activeTab, setActiveTab] = React6.useState(
5897
+ const [activeTab, setActiveTab] = React7.useState(
5593
5898
  "overview" /* Overview */
5594
5899
  );
5595
5900
  return {
@@ -5605,17 +5910,17 @@ var init_funding_script = __esm({
5605
5910
  var LazySearchInput4, LazyFundingOverviewWidget, LazyFundingComparisonWidget, Funding;
5606
5911
  var init_funding_ui = __esm({
5607
5912
  "src/pages/home/funding/funding.ui.tsx"() {
5608
- LazySearchInput4 = React6__default.default.lazy(
5913
+ LazySearchInput4 = React7__default.default.lazy(
5609
5914
  () => Promise.resolve().then(() => (init_searchInput(), searchInput_exports)).then((mod) => {
5610
5915
  return { default: mod.SearchInput };
5611
5916
  })
5612
5917
  );
5613
- LazyFundingOverviewWidget = React6__default.default.lazy(
5918
+ LazyFundingOverviewWidget = React7__default.default.lazy(
5614
5919
  () => Promise.resolve().then(() => (init_fundingOverview(), fundingOverview_exports)).then((mod) => {
5615
5920
  return { default: mod.FundingOverviewWidget };
5616
5921
  })
5617
5922
  );
5618
- LazyFundingComparisonWidget = React6__default.default.lazy(
5923
+ LazyFundingComparisonWidget = React7__default.default.lazy(
5619
5924
  () => Promise.resolve().then(() => (init_fundingComparison(), fundingComparison_exports)).then((mod) => {
5620
5925
  return { default: mod.FundingComparisonWidget };
5621
5926
  })
@@ -5637,7 +5942,7 @@ var init_funding_ui = __esm({
5637
5942
  size: "lg",
5638
5943
  value: props.activeTab,
5639
5944
  onValueChange: props.onTabChange,
5640
- trailing: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySearchInput4, { classNames: { root: "oui-my-1 oui-w-[240px]" } }) }),
5945
+ trailing: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySearchInput4, { classNames: { root: "oui-my-1 oui-w-[240px]" } }) }),
5641
5946
  children: [
5642
5947
  /* @__PURE__ */ jsxRuntime.jsx(
5643
5948
  ui.TabPanel,
@@ -5649,7 +5954,7 @@ var init_funding_ui = __esm({
5649
5954
  title: t("common.overview"),
5650
5955
  value: "overview",
5651
5956
  testid: "oui-testid-funding-overview-tab",
5652
- children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingOverviewWidget, {}) })
5957
+ children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingOverviewWidget, {}) })
5653
5958
  }
5654
5959
  ),
5655
5960
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -5662,7 +5967,7 @@ var init_funding_ui = __esm({
5662
5967
  title: t("markets.funding.comparison"),
5663
5968
  value: "comparison",
5664
5969
  testid: "oui-testid-funding-comparison-tab",
5665
- children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingComparisonWidget, {}) })
5970
+ children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingComparisonWidget, {}) })
5666
5971
  }
5667
5972
  )
5668
5973
  ]
@@ -5713,6 +6018,7 @@ init_communityBrokerTabs();
5713
6018
  init_favoritesTabs();
5714
6019
  init_marketsList();
5715
6020
  init_marketsProvider();
6021
+ init_rwaSubcategoryTabs();
5716
6022
  init_rwaTab();
5717
6023
  init_useFavoritesExtraProps();
5718
6024
  init_tabUtils();
@@ -5722,7 +6028,7 @@ var TABLE_CLASSNAMES = {
5722
6028
  scroll: "oui-px-0",
5723
6029
  header: "oui-hidden oui-h-0 oui-p-0"
5724
6030
  };
5725
- var LazySearchInput3 = React6__default.default.lazy(
6031
+ var LazySearchInput3 = React7__default.default.lazy(
5726
6032
  () => Promise.resolve().then(() => (init_searchInput(), searchInput_exports)).then((mod) => ({ default: mod.SearchInput }))
5727
6033
  );
5728
6034
  var cls = "oui-h-[calc(100%_-_36px)]";
@@ -5776,6 +6082,31 @@ var SubMenuMarkets = (props) => {
5776
6082
  ];
5777
6083
  };
5778
6084
  const renderBuiltInContent = (tabType) => {
6085
+ if (tabType === "rwa" /* Rwa */) {
6086
+ return /* @__PURE__ */ jsxRuntime.jsx(
6087
+ RwaSubcategoryTabs,
6088
+ {
6089
+ storageKey: "orderly_submenu_markets_rwa_sel_sub_tab",
6090
+ classNames: {
6091
+ tabsList: "oui-px-1 oui-pt-1 oui-pb-2",
6092
+ tabsContent: "oui-h-full",
6093
+ scrollIndicator: "oui-mx-1"
6094
+ },
6095
+ className: ui.cn("oui-subMenuMarkets-rwa-tabs", cls),
6096
+ showScrollIndicator: true,
6097
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx(
6098
+ MarketTabPanel,
6099
+ {
6100
+ type: tabType,
6101
+ getColumns,
6102
+ dataFilter,
6103
+ initialSort: tabSort[tabType],
6104
+ onSort: onTabSort(tabType)
6105
+ }
6106
+ )
6107
+ }
6108
+ );
6109
+ }
5779
6110
  if (tabType === "favorites" /* Favorites */) {
5780
6111
  const favProps = getFavoritesProps("favorites" /* Favorites */);
5781
6112
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -5849,7 +6180,7 @@ var SubMenuMarkets = (props) => {
5849
6180
  ),
5850
6181
  height: "100%",
5851
6182
  children: [
5852
- /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "oui-p-1", children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySearchInput3, {}) }) }),
6183
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "oui-p-1", children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySearchInput3, {}) }) }),
5853
6184
  /* @__PURE__ */ jsxRuntime.jsx(
5854
6185
  ui.Tabs,
5855
6186
  {
@@ -5899,14 +6230,14 @@ init_type();
5899
6230
  init_marketsProvider();
5900
6231
  init_useTabSort();
5901
6232
  function useSubMenuMarketsScript(options) {
5902
- const [activeTab, setActiveTab] = React6.useState(
6233
+ const [activeTab, setActiveTab] = React7.useState(
5903
6234
  options?.activeTab ?? "all" /* All */
5904
6235
  );
5905
6236
  const { clearSearchValue } = useMarketsContext();
5906
6237
  const { tabSort, onTabSort } = useTabSort({
5907
6238
  storageKey: SIDE_MARKETS_TAB_SORT_STORAGE_KEY
5908
6239
  });
5909
- const onTabChange = React6.useCallback(
6240
+ const onTabChange = React7.useCallback(
5910
6241
  (value) => {
5911
6242
  if (typeof options?.onTabChange === "function") {
5912
6243
  options.onTabChange(value);
@@ -5916,12 +6247,12 @@ function useSubMenuMarketsScript(options) {
5916
6247
  },
5917
6248
  [options?.onTabChange]
5918
6249
  );
5919
- React6.useEffect(() => {
6250
+ React7.useEffect(() => {
5920
6251
  if (options?.activeTab !== void 0) {
5921
6252
  setActiveTab(options.activeTab);
5922
6253
  }
5923
6254
  }, [options?.activeTab]);
5924
- React6.useEffect(() => {
6255
+ React7.useEffect(() => {
5925
6256
  clearSearchValue?.();
5926
6257
  }, [activeTab]);
5927
6258
  return {
@@ -5979,13 +6310,13 @@ var useSideMarketsScript = (options) => {
5979
6310
  const { tabSort } = useTabSort({
5980
6311
  storageKey: SIDE_MARKETS_TAB_SORT_STORAGE_KEY
5981
6312
  });
5982
- const panelSize = React6.useMemo(() => {
6313
+ const panelSize = React7.useMemo(() => {
5983
6314
  if (options?.collapsed) {
5984
6315
  return "small";
5985
6316
  }
5986
6317
  return options?.panelSize || "large";
5987
6318
  }, [options?.collapsed, options?.panelSize]);
5988
- React6.useCallback(
6319
+ React7.useCallback(
5989
6320
  (size) => {
5990
6321
  if (typeof options?.onPanelSizeChange === "function") {
5991
6322
  options.onPanelSizeChange(size);
@@ -6003,14 +6334,14 @@ var useSideMarketsScript = (options) => {
6003
6334
 
6004
6335
  // src/components/sideMarkets/sideMarkets.widget.tsx
6005
6336
  init_marketsProvider();
6006
- var LazySideMarkets = React6__default.default.lazy(
6337
+ var LazySideMarkets = React7__default.default.lazy(
6007
6338
  () => Promise.resolve().then(() => (init_sideMarkets_ui(), sideMarkets_ui_exports)).then((mod) => {
6008
6339
  return { default: mod.SideMarkets };
6009
6340
  })
6010
6341
  );
6011
6342
  var SideMarketsWidget = (props) => {
6012
6343
  const state = useSideMarketsScript(props);
6013
- return /* @__PURE__ */ jsxRuntime.jsx(exports.MarketsProvider, { ...ramda.pick(["symbol", "onSymbolChange"], props), children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySideMarkets, { ...state, className: props.className }) }) });
6344
+ return /* @__PURE__ */ jsxRuntime.jsx(exports.MarketsProvider, { ...ramda.pick(["symbol", "onSymbolChange"], props), children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazySideMarkets, { ...state, className: props.className }) }) });
6014
6345
  };
6015
6346
 
6016
6347
  // src/index.ts
@@ -6022,6 +6353,7 @@ init_type();
6022
6353
  init_communityBrokerTabs();
6023
6354
  init_marketsList();
6024
6355
  init_marketsProvider();
6356
+ init_rwaSubcategoryTabs();
6025
6357
  init_rwaTab();
6026
6358
  init_searchInput();
6027
6359
  init_useFavoritesExtraProps();
@@ -6047,6 +6379,40 @@ var MarketsSheet = (props) => {
6047
6379
  const tabDataFilters = useCustomTabDataFilters(tabs);
6048
6380
  const renderBuiltInContent = (tabType) => {
6049
6381
  const isFavorites = tabType === "favorites" /* Favorites */;
6382
+ if (tabType === "rwa" /* Rwa */) {
6383
+ return /* @__PURE__ */ jsxRuntime.jsx(
6384
+ RwaSubcategoryTabs,
6385
+ {
6386
+ storageKey: "orderly_markets_sheet_rwa_sel_sub_tab",
6387
+ classNames: {
6388
+ tabsList: "oui-px-3 oui-pt-1 oui-pb-2",
6389
+ tabsContent: "oui-h-full"
6390
+ },
6391
+ className: ui.cn(
6392
+ "oui-marketsSheet-rwa-tabs",
6393
+ "oui-h-[calc(100%_-_36px)]"
6394
+ ),
6395
+ showScrollIndicator: true,
6396
+ renderPanel: (_, dataFilter) => /* @__PURE__ */ jsxRuntime.jsx(
6397
+ exports.MarketsListWidget,
6398
+ {
6399
+ type: tabType,
6400
+ dataFilter,
6401
+ initialSort: tabSort[tabType],
6402
+ onSort: onTabSort(tabType),
6403
+ getColumns: getMarketsSheetColumns,
6404
+ tableClassNames: {
6405
+ root: ui.cn("oui-marketsSheet-list", "!oui-bg-base-8"),
6406
+ scroll: ui.cn(
6407
+ "oui-pb-[env(safe-area-inset-bottom,_20px)]",
6408
+ "oui-h-[calc(100%_-_40px)]"
6409
+ )
6410
+ }
6411
+ }
6412
+ )
6413
+ }
6414
+ );
6415
+ }
6050
6416
  return /* @__PURE__ */ jsxRuntime.jsx(
6051
6417
  exports.MarketsListWidget,
6052
6418
  {
@@ -6224,9 +6590,9 @@ var RwaTooltip = (props) => {
6224
6590
  const { isRwa, open, closeTimeInterval, openTimeInterval } = props;
6225
6591
  const { isMobile } = ui.useScreen();
6226
6592
  const { t } = i18n.useTranslation();
6227
- const [isOpen, setIsOpen] = React6.useState(false);
6593
+ const [isOpen, setIsOpen] = React7.useState(false);
6228
6594
  const timeInterval = open ? closeTimeInterval : openTimeInterval;
6229
- const tooltipContent = React6.useMemo(() => {
6595
+ const tooltipContent = React7.useMemo(() => {
6230
6596
  return /* @__PURE__ */ jsxRuntime.jsx(Content, { open, timeInterval });
6231
6597
  }, [open, t, timeInterval]);
6232
6598
  const triggerView = /* @__PURE__ */ jsxRuntime.jsx(
@@ -6282,11 +6648,11 @@ var AlertContent = ({
6282
6648
  open,
6283
6649
  timeInterval
6284
6650
  }) => {
6285
- const [innerTimeInterval, setInnerTimeInterval] = React6.useState(timeInterval);
6286
- React6.useEffect(() => {
6651
+ const [innerTimeInterval, setInnerTimeInterval] = React7.useState(timeInterval);
6652
+ React7.useEffect(() => {
6287
6653
  setInnerTimeInterval(timeInterval);
6288
6654
  }, [timeInterval]);
6289
- React6.useEffect(() => {
6655
+ React7.useEffect(() => {
6290
6656
  if (!innerTimeInterval || innerTimeInterval <= 0) {
6291
6657
  return;
6292
6658
  }
@@ -6439,7 +6805,7 @@ function useSymbolInfoBarScript(options) {
6439
6805
  const { isRwa, open, closeTimeInterval, openTimeInterval } = hooks.useGetRwaSymbolInfo(symbol);
6440
6806
  const data = hooks.useTickerStream(symbol);
6441
6807
  const symbolsInfo = hooks.useSymbolsInfo();
6442
- const leverage = React6.useMemo(() => {
6808
+ const leverage = React7.useMemo(() => {
6443
6809
  const info = symbolsInfo[symbol];
6444
6810
  const baseImr = info("base_imr");
6445
6811
  return getLeverage(baseImr);
@@ -6534,31 +6900,31 @@ var useFundingRateHintScript = (symbol) => {
6534
6900
  } = hooks.useFundingRateBySymbol(symbol) ?? {};
6535
6901
  const [{ aggregated, rows }] = hooks.usePositionStream(symbol);
6536
6902
  const { notional } = aggregated ?? {};
6537
- const fundingPeriod = React6.useMemo(() => {
6903
+ const fundingPeriod = React7.useMemo(() => {
6538
6904
  if (!fundingDetails || isFundingLoading) {
6539
6905
  return "-";
6540
6906
  }
6541
6907
  return `${fundingDetails.funding_period}h`;
6542
6908
  }, [fundingDetails, isFundingLoading]);
6543
- const capFunding = React6.useMemo(() => {
6909
+ const capFunding = React7.useMemo(() => {
6544
6910
  if (!fundingDetails || isFundingLoading) {
6545
6911
  return "-";
6546
6912
  }
6547
6913
  return `${new utils.Decimal(fundingDetails.cap_funding).mul(100).toNumber()}%`;
6548
6914
  }, [fundingDetails, isFundingLoading]);
6549
- const floorFunding = React6.useMemo(() => {
6915
+ const floorFunding = React7.useMemo(() => {
6550
6916
  if (!fundingDetails || isFundingLoading) {
6551
6917
  return "-";
6552
6918
  }
6553
6919
  return `${new utils.Decimal(fundingDetails.floor_funding).mul(100).toNumber()}%`;
6554
6920
  }, [fundingDetails, isFundingLoading]);
6555
- const lastFundingRate = React6.useMemo(() => {
6921
+ const lastFundingRate = React7.useMemo(() => {
6556
6922
  if (!last_funding_rate) {
6557
6923
  return void 0;
6558
6924
  }
6559
6925
  return `${new utils.Decimal(last_funding_rate).mul(100).toNumber()}%`;
6560
6926
  }, [last_funding_rate]);
6561
- const estFundingFee = React6.useMemo(() => {
6927
+ const estFundingFee = React7.useMemo(() => {
6562
6928
  if (!est_funding_rate || !notional || rows.length === 0) {
6563
6929
  return "--";
6564
6930
  }
@@ -6569,7 +6935,7 @@ var useFundingRateHintScript = (symbol) => {
6569
6935
  const annualizedRate = new utils.Decimal(rate).mul(24).div(intervalHours).mul(365);
6570
6936
  return annualizedRate.todp(2, utils.Decimal.ROUND_DOWN).toNumber();
6571
6937
  };
6572
- const lastFundingRateAnnualized = React6.useMemo(() => {
6938
+ const lastFundingRateAnnualized = React7.useMemo(() => {
6573
6939
  if (!last_funding_rate || !fundingDetails?.funding_period) {
6574
6940
  return void 0;
6575
6941
  }
@@ -6580,12 +6946,12 @@ var useFundingRateHintScript = (symbol) => {
6580
6946
  );
6581
6947
  return annualized ? `${annualized}%` : void 0;
6582
6948
  }, [last_funding_rate, fundingDetails?.funding_period]);
6583
- const settlementIntervalHours = React6.useMemo(() => {
6949
+ const settlementIntervalHours = React7.useMemo(() => {
6584
6950
  if (!next_funding_time || !last_funding_rate_timestamp) return 8;
6585
6951
  const diff = next_funding_time - last_funding_rate_timestamp;
6586
6952
  return diff / 36e5;
6587
6953
  }, [next_funding_time, last_funding_rate_timestamp]);
6588
- const estFundingRateByTimeframe = React6.useMemo(() => {
6954
+ const estFundingRateByTimeframe = React7.useMemo(() => {
6589
6955
  if (est_funding_rate === void 0 || est_funding_rate === null || settlementIntervalHours <= 0) {
6590
6956
  return [];
6591
6957
  }
@@ -6596,7 +6962,7 @@ var useFundingRateHintScript = (symbol) => {
6596
6962
  return { timeframe: key, value: `${trimmed}%` };
6597
6963
  });
6598
6964
  }, [est_funding_rate, settlementIntervalHours]);
6599
- return React6.useMemo(() => {
6965
+ return React7.useMemo(() => {
6600
6966
  return {
6601
6967
  fundingPeriod,
6602
6968
  capFunding,
@@ -6625,25 +6991,33 @@ var FundingRateHintWidget = (props) => {
6625
6991
  // src/components/symbolInfoBarFull/symbolInfoBarFull.ui.tsx
6626
6992
  init_symbolBadge();
6627
6993
  init_symbolDisplay();
6628
- var LazyDropDownMarketsWidget = React6__default.default.lazy(
6994
+ var LazyDropDownMarketsWidget = React7__default.default.lazy(
6629
6995
  () => Promise.resolve().then(() => (init_dropDownMarkets(), dropDownMarkets_exports)).then((mod) => {
6630
6996
  return { default: mod.DropDownMarketsWidget };
6631
6997
  })
6632
6998
  );
6633
- var LazyFavoritesDropdownMenuWidget = React6__default.default.lazy(
6999
+ var LazyFavoritesDropdownMenuWidget = React7__default.default.lazy(
6634
7000
  () => Promise.resolve().then(() => (init_favoritesDropdownMenu(), favoritesDropdownMenu_exports)).then((mod) => {
6635
7001
  return { default: mod.FavoritesDropdownMenuWidget };
6636
7002
  })
6637
7003
  );
6638
- var LazyDataItem = React6__default.default.lazy(
7004
+ var LazyDataItem = React7__default.default.lazy(
6639
7005
  () => Promise.resolve().then(() => (init_dataItem_ui(), dataItem_ui_exports)).then((mod) => {
6640
7006
  return { default: mod.DataItem };
6641
7007
  })
6642
7008
  );
6643
- var RISK_NOTICE_LEARN_MORE_URL = "https://orderly.network";
6644
- var SymbolInfoBarRiskNotice = ({ className, visible, symbolWithBroker, brokerName, autoHeight }) => {
7009
+ var RISK_NOTICE_LEARN_MORE_URL = "https://orderly.network/docs/introduction/trade-on-orderly/permissionless-listing";
7010
+ var SymbolInfoBarRiskNotice = ({
7011
+ className,
7012
+ visible,
7013
+ symbolWithBroker,
7014
+ brokerName,
7015
+ isPreTge,
7016
+ autoHeight
7017
+ }) => {
6645
7018
  const { t } = i18n.useTranslation();
6646
7019
  if (!visible) return null;
7020
+ const contentKey = isPreTge ? "markets.symbolInfoBar.riskNotice.preLaunch.content" : "markets.symbolInfoBar.riskNotice.content";
6647
7021
  return /* @__PURE__ */ jsxRuntime.jsx(
6648
7022
  "a",
6649
7023
  {
@@ -6663,7 +7037,7 @@ var SymbolInfoBarRiskNotice = ({ className, visible, symbolWithBroker, brokerNam
6663
7037
  children: [
6664
7038
  /* @__PURE__ */ jsxRuntime.jsx(ui.WarningIcon, { className: "oui-shrink-0 oui-size-4 oui-text-warning-darken" }),
6665
7039
  /* @__PURE__ */ jsxRuntime.jsxs(ui.Text, { size: "xs", className: "oui-text-warning-darken oui-flex-1", children: [
6666
- t("markets.symbolInfoBar.riskNotice.content", {
7040
+ t(contentKey, {
6667
7041
  symbolWithBroker,
6668
7042
  brokerName
6669
7043
  }),
@@ -6750,11 +7124,13 @@ var SymbolInfoBarFull = (props) => {
6750
7124
  showCountdown
6751
7125
  } = props;
6752
7126
  const { t } = i18n.useTranslation();
6753
- const { brokerId, brokerName, brokerNameRaw, displayName } = hooks.useBadgeBySymbol(symbol);
7127
+ const symbolsInfo = hooks.useSymbolsInfo();
7128
+ const { brokerId, brokerName, brokerNameRaw, displaySymbolName } = hooks.useBadgeBySymbol(symbol);
7129
+ const isPreTge = Boolean(symbolsInfo[symbol]?.("is_pretge"));
6754
7130
  const isCommunityListed = Boolean(brokerId ?? brokerName);
6755
7131
  const baseFromSymbol = symbol?.split("_")[1] ?? symbol;
6756
- const symbolWithBroker = brokerName != null ? `${baseFromSymbol}-${brokerNameRaw}` : displayName ?? symbol;
6757
- const favoriteIcon = /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFavoritesDropdownMenuWidget, { row: { symbol }, favorite, children: /* @__PURE__ */ jsxRuntime.jsx(
7132
+ const symbolWithBroker = brokerName != null ? `${baseFromSymbol}-${brokerNameRaw}` : displaySymbolName ?? symbol;
7133
+ const favoriteIcon = /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFavoritesDropdownMenuWidget, { row: { symbol }, favorite, children: /* @__PURE__ */ jsxRuntime.jsx(
6758
7134
  ui.Flex,
6759
7135
  {
6760
7136
  width: 12,
@@ -6765,7 +7141,7 @@ var SymbolInfoBarFull = (props) => {
6765
7141
  children: isFavorite ? /* @__PURE__ */ jsxRuntime.jsx(FavoritesIcon2, { className: "oui-size-3 oui-text-warning-darken" }) : /* @__PURE__ */ jsxRuntime.jsx(UnFavoritesIcon2, { className: "oui-size-3 oui-text-base-contrast-36 hover:oui-text-warning-darken" })
6766
7142
  }
6767
7143
  ) }) });
6768
- const symbolView = /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsxs(
7144
+ const symbolView = /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsxs(
6769
7145
  ui.Flex,
6770
7146
  {
6771
7147
  direction: "column",
@@ -6775,7 +7151,7 @@ var SymbolInfoBarFull = (props) => {
6775
7151
  /* @__PURE__ */ jsxRuntime.jsx(
6776
7152
  LazyDropDownMarketsWidget,
6777
7153
  {
6778
- contentClassName: "oui-w-[580px] oui-h-[496px]",
7154
+ contentClassName: "oui-w-[620px] oui-h-[496px]",
6779
7155
  symbol: props.symbol,
6780
7156
  onSymbolChange: props.onSymbolChange,
6781
7157
  children: /* @__PURE__ */ jsxRuntime.jsx(ui.Flex, { direction: "column", gap: 1, children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 1, className: "oui-cursor-pointer", children: [
@@ -6847,8 +7223,8 @@ var SymbolInfoBarFull = (props) => {
6847
7223
  }
6848
7224
  );
6849
7225
  const scrollableContent = /* @__PURE__ */ jsxRuntime.jsxs(ui.Flex, { gapX: 8, height: "100%", children: [
6850
- /* @__PURE__ */ jsxRuntime.jsx("div", { ref: leadingElementRef, children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyDataItem, { label: t("markets.column.24hChange"), value: change }) }) }),
6851
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7226
+ /* @__PURE__ */ jsxRuntime.jsx("div", { ref: leadingElementRef, children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyDataItem, { label: t("markets.column.24hChange"), value: change }) }) }),
7227
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
6852
7228
  LazyDataItem,
6853
7229
  {
6854
7230
  label: t("markets.symbolInfoBar.Mark"),
@@ -6863,7 +7239,7 @@ var SymbolInfoBarFull = (props) => {
6863
7239
  hint: t("markets.symbolInfoBar.Mark.tooltip")
6864
7240
  }
6865
7241
  ) }),
6866
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7242
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
6867
7243
  LazyDataItem,
6868
7244
  {
6869
7245
  label: t("markets.symbolInfoBar.Index"),
@@ -6871,7 +7247,7 @@ var SymbolInfoBarFull = (props) => {
6871
7247
  hint: t("markets.symbolInfoBar.Index.tooltip")
6872
7248
  }
6873
7249
  ) }),
6874
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7250
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
6875
7251
  LazyDataItem,
6876
7252
  {
6877
7253
  label: t("markets.symbolInfoBar.24hVolume"),
@@ -6879,7 +7255,7 @@ var SymbolInfoBarFull = (props) => {
6879
7255
  hint: t("markets.symbolInfoBar.24hVolume.tooltip")
6880
7256
  }
6881
7257
  ) }),
6882
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7258
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
6883
7259
  LazyDataItem,
6884
7260
  {
6885
7261
  label: t("markets.symbolInfoBar.predFundingRate"),
@@ -6887,7 +7263,7 @@ var SymbolInfoBarFull = (props) => {
6887
7263
  hint: /* @__PURE__ */ jsxRuntime.jsx(FundingRateHintWidget, { symbol })
6888
7264
  }
6889
7265
  ) }),
6890
- /* @__PURE__ */ jsxRuntime.jsx("div", { ref: tailingElementRef, children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7266
+ /* @__PURE__ */ jsxRuntime.jsx("div", { ref: tailingElementRef, children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
6891
7267
  LazyDataItem,
6892
7268
  {
6893
7269
  label: t("markets.openInterest"),
@@ -6906,6 +7282,7 @@ var SymbolInfoBarFull = (props) => {
6906
7282
  visible: isCommunityListed,
6907
7283
  symbolWithBroker,
6908
7284
  brokerName: brokerNameRaw ?? brokerName ?? "",
7285
+ isPreTge,
6909
7286
  autoHeight: true
6910
7287
  }
6911
7288
  ),
@@ -7027,19 +7404,19 @@ function useSymbolInfoBarFullScript(options) {
7027
7404
  const favorite = hooks.useMarketsStore();
7028
7405
  const { isRwa, open, closeTimeInterval, openTimeInterval } = hooks.useGetRwaSymbolInfo(symbol);
7029
7406
  const { data: fundingDetails, isLoading: isFundingLoading } = hooks.useFundingDetails(symbol);
7030
- const fundingPeriod = React6.useMemo(() => {
7407
+ const fundingPeriod = React7.useMemo(() => {
7031
7408
  if (!fundingDetails || isFundingLoading) {
7032
7409
  return "-";
7033
7410
  }
7034
7411
  return `${fundingDetails.funding_period}h`;
7035
7412
  }, [fundingDetails, isFundingLoading]);
7036
- const capFunding = React6.useMemo(() => {
7413
+ const capFunding = React7.useMemo(() => {
7037
7414
  if (!fundingDetails || isFundingLoading) {
7038
7415
  return "-";
7039
7416
  }
7040
7417
  return `${new utils.Decimal(fundingDetails.cap_funding).mul(100).toNumber()}%`;
7041
7418
  }, [fundingDetails, isFundingLoading]);
7042
- const floorFunding = React6.useMemo(() => {
7419
+ const floorFunding = React7.useMemo(() => {
7043
7420
  if (!fundingDetails || isFundingLoading) {
7044
7421
  return "-";
7045
7422
  }
@@ -7047,20 +7424,20 @@ function useSymbolInfoBarFullScript(options) {
7047
7424
  }, [fundingDetails, isFundingLoading]);
7048
7425
  const info = hooks.useSymbolsInfo();
7049
7426
  const quotoDp = info[symbol]("quote_dp");
7050
- const [leadingVisible, setLeadingVisible] = React6.useState(false);
7051
- const [tailingVisible, setTailingVisible] = React6.useState(false);
7052
- const containerRef = React6.useRef(null);
7053
- const leadingElementRef = React6.useRef(null);
7054
- const tailingElementRef = React6.useRef(null);
7055
- const isFavorite = React6.useMemo(
7427
+ const [leadingVisible, setLeadingVisible] = React7.useState(false);
7428
+ const [tailingVisible, setTailingVisible] = React7.useState(false);
7429
+ const containerRef = React7.useRef(null);
7430
+ const leadingElementRef = React7.useRef(null);
7431
+ const tailingElementRef = React7.useRef(null);
7432
+ const isFavorite = React7.useMemo(
7056
7433
  () => !!favorite.favorites.find((item) => item.name === symbol),
7057
7434
  [favorite.favorites, symbol]
7058
7435
  );
7059
- const openInterest = React6.useMemo(
7436
+ const openInterest = React7.useMemo(
7060
7437
  () => new utils.Decimal(data?.open_interest ?? 0).mul(data?.index_price ?? 0).toDecimalPlaces(2).valueOf(),
7061
7438
  [data]
7062
7439
  );
7063
- React6.useEffect(() => {
7440
+ React7.useEffect(() => {
7064
7441
  const intersectionObserver = new IntersectionObserver((entries) => {
7065
7442
  for (let index = 0; index < entries.length; index++) {
7066
7443
  const item = entries[index];
@@ -7144,7 +7521,7 @@ var useHorizontalMarketsScript = (options) => {
7144
7521
  SIDE_MARKETS_SEL_TAB_KEY,
7145
7522
  defaultMarketType || "all"
7146
7523
  );
7147
- const availableMarketTypes = React6.useMemo(
7524
+ const availableMarketTypes = React7.useMemo(
7148
7525
  () => tabs?.map((tab, index) => tabKey(tab, index)) ?? ["all"],
7149
7526
  [tabs]
7150
7527
  );
@@ -7152,19 +7529,21 @@ var useHorizontalMarketsScript = (options) => {
7152
7529
  all: hooks.MarketsType.ALL,
7153
7530
  recent: hooks.MarketsType.RECENT,
7154
7531
  newListing: hooks.MarketsType.NEW_LISTING,
7155
- favorites: hooks.MarketsType.FAVORITES
7532
+ favorites: hooks.MarketsType.FAVORITES,
7533
+ rwa: hooks.MarketsType.RWA,
7534
+ preTge: hooks.MarketsType.PRE_TGE
7156
7535
  };
7157
7536
  const isCustomCategory = typeof selectedMarketType === "string" && !MarketsTypeMap3[selectedMarketType];
7158
7537
  const marketTypeKey = isCustomCategory ? "all" : selectedMarketType || "all";
7159
7538
  const [markets, favorite] = hooks.useMarkets(
7160
7539
  MarketsTypeMap3[marketTypeKey] || hooks.MarketsType.ALL
7161
7540
  );
7162
- React6.useEffect(() => {
7541
+ React7.useEffect(() => {
7163
7542
  if (!availableMarketTypes.includes(selectedMarketType)) {
7164
7543
  setSelectedMarketType(availableMarketTypes[0] ?? "all");
7165
7544
  }
7166
7545
  }, [availableMarketTypes, selectedMarketType, setSelectedMarketType]);
7167
- const customCategoryFilter = React6.useMemo(() => {
7546
+ const customCategoryFilter = React7.useMemo(() => {
7168
7547
  if (!isCustomCategory || !tabs) return null;
7169
7548
  const customTabs = tabs.filter(isCustomMarketTab);
7170
7549
  const tab = customTabs.find(
@@ -7172,7 +7551,7 @@ var useHorizontalMarketsScript = (options) => {
7172
7551
  );
7173
7552
  return tab ? getCustomTabDataFilter(tab) ?? null : null;
7174
7553
  }, [isCustomCategory, tabs, selectedMarketType]);
7175
- const filteredMarkets = React6.useMemo(() => {
7554
+ const filteredMarkets = React7.useMemo(() => {
7176
7555
  if (isCustomCategory && customCategoryFilter) {
7177
7556
  return customCategoryFilter(markets);
7178
7557
  }
@@ -7204,11 +7583,11 @@ var useHorizontalMarketsScript = (options) => {
7204
7583
  const { tabSort } = useTabSort({
7205
7584
  storageKey: SIDE_MARKETS_TAB_SORT_STORAGE_KEY
7206
7585
  });
7207
- const sortedMarkets = React6.useMemo(() => {
7586
+ const sortedMarkets = React7.useMemo(() => {
7208
7587
  const sort = tabSort?.[selectedMarketType];
7209
7588
  return sort ? sortList(filteredMarkets, sort) : filteredMarkets;
7210
7589
  }, [filteredMarkets, tabSort, selectedMarketType]);
7211
- const symbols = React6.useMemo(() => {
7590
+ const symbols = React7.useMemo(() => {
7212
7591
  const list = optionSymbols ? optionSymbols : sortedMarkets.map((m) => m.symbol);
7213
7592
  const max = optionMaxItems;
7214
7593
  if (typeof max === "number") {
@@ -7217,7 +7596,7 @@ var useHorizontalMarketsScript = (options) => {
7217
7596
  }
7218
7597
  return list;
7219
7598
  }, [sortedMarkets, optionSymbols, optionMaxItems]);
7220
- const tickerData = React6.useMemo(() => {
7599
+ const tickerData = React7.useMemo(() => {
7221
7600
  return sortedMarkets.reduce((acc, item) => {
7222
7601
  acc[item.symbol] = {
7223
7602
  "24h_close": item["24h_close"],
@@ -7227,7 +7606,7 @@ var useHorizontalMarketsScript = (options) => {
7227
7606
  return acc;
7228
7607
  }, {});
7229
7608
  }, [sortedMarkets]);
7230
- const onSymbolClick = React6.useCallback(
7609
+ const onSymbolClick = React7.useCallback(
7231
7610
  (symbol) => {
7232
7611
  const record = sortedMarkets.find((m) => m.symbol === symbol);
7233
7612
  if (record) {
@@ -7239,7 +7618,7 @@ var useHorizontalMarketsScript = (options) => {
7239
7618
  },
7240
7619
  [sortedMarkets, favorite, onSymbolChange]
7241
7620
  );
7242
- const onMarketTypeChange = React6.useCallback(
7621
+ const onMarketTypeChange = React7.useCallback(
7243
7622
  (marketType) => {
7244
7623
  setSelectedMarketType(marketType);
7245
7624
  },
@@ -7254,7 +7633,7 @@ var useHorizontalMarketsScript = (options) => {
7254
7633
  onMarketTypeChange
7255
7634
  };
7256
7635
  };
7257
- var LazyHorizontalMarkets = React6__default.default.lazy(
7636
+ var LazyHorizontalMarkets = React7__default.default.lazy(
7258
7637
  () => Promise.resolve().then(() => (init_horizontalMarkets_ui(), horizontalMarkets_ui_exports)).then((mod) => {
7259
7638
  return { default: mod.HorizontalMarkets };
7260
7639
  })
@@ -7266,7 +7645,7 @@ var HorizontalMarketsInner = (props) => {
7266
7645
  maxItems,
7267
7646
  defaultMarketType
7268
7647
  });
7269
- return /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7648
+ return /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(
7270
7649
  LazyHorizontalMarkets,
7271
7650
  {
7272
7651
  ...state,
@@ -7348,14 +7727,14 @@ init_marketsProvider();
7348
7727
  init_utils();
7349
7728
  var useNewListingListScript = () => {
7350
7729
  const [data, favorite] = hooks.useMarkets(hooks.MarketsType.NEW_LISTING);
7351
- const [loading, setLoading] = React6.useState(true);
7730
+ const [loading, setLoading] = React7.useState(true);
7352
7731
  const { searchValue } = useMarketsContext();
7353
7732
  const { onSort, getSortedList } = useSort();
7354
- const dataSource = React6.useMemo(() => {
7733
+ const dataSource = React7.useMemo(() => {
7355
7734
  const searchResults = searchBySymbol(data, searchValue, "base");
7356
7735
  return getSortedList(searchResults);
7357
7736
  }, [data, searchValue, getSortedList]);
7358
- React6.useEffect(() => {
7737
+ React7.useEffect(() => {
7359
7738
  setLoading(false);
7360
7739
  }, [data]);
7361
7740
  return {
@@ -7420,11 +7799,11 @@ init_marketsProvider();
7420
7799
  init_utils();
7421
7800
  var useFavoritesListScript = () => {
7422
7801
  const [data, favorite] = hooks.useMarkets(hooks.MarketsType.FAVORITES);
7423
- const [loading, setLoading] = React6.useState(true);
7802
+ const [loading, setLoading] = React7.useState(true);
7424
7803
  const { favorites, selectedFavoriteTab } = favorite;
7425
7804
  const { searchValue } = useMarketsContext();
7426
7805
  const { onSort, getSortedList } = useSort();
7427
- const dataSource = React6.useMemo(() => {
7806
+ const dataSource = React7.useMemo(() => {
7428
7807
  const filterList = favorites?.filter(
7429
7808
  (item) => item.tabs?.findIndex((tab) => tab.id === selectedFavoriteTab.id) !== -1
7430
7809
  )?.map((fav) => {
@@ -7437,7 +7816,7 @@ var useFavoritesListScript = () => {
7437
7816
  const searchResults = searchBySymbol(filterList, searchValue, "base");
7438
7817
  return getSortedList(searchResults);
7439
7818
  }, [data, selectedFavoriteTab, favorites, searchValue, getSortedList]);
7440
- React6.useEffect(() => {
7819
+ React7.useEffect(() => {
7441
7820
  setLoading(false);
7442
7821
  }, [data]);
7443
7822
  return {
@@ -7498,14 +7877,14 @@ init_marketsProvider();
7498
7877
  init_utils();
7499
7878
  var useRecentListScript = () => {
7500
7879
  const [data, favorite] = hooks.useMarkets(hooks.MarketsType.RECENT);
7501
- const [loading, setLoading] = React6.useState(true);
7880
+ const [loading, setLoading] = React7.useState(true);
7502
7881
  const { searchValue } = useMarketsContext();
7503
7882
  const { onSort, getSortedList } = useSort();
7504
- const dataSource = React6.useMemo(() => {
7883
+ const dataSource = React7.useMemo(() => {
7505
7884
  const searchResults = searchBySymbol(data, searchValue, "base");
7506
7885
  return getSortedList(searchResults);
7507
7886
  }, [data, searchValue, getSortedList]);
7508
- React6.useEffect(() => {
7887
+ React7.useEffect(() => {
7509
7888
  setLoading(false);
7510
7889
  }, [data]);
7511
7890
  return {
@@ -7527,24 +7906,24 @@ init_type();
7527
7906
  init_marketsProvider();
7528
7907
  init_useMarketCategories();
7529
7908
  init_type();
7530
- var LazyMarketsHeaderWidget = React6__default.default.lazy(
7909
+ var LazyMarketsHeaderWidget = React7__default.default.lazy(
7531
7910
  () => Promise.resolve().then(() => (init_marketsHeader_widget(), marketsHeader_widget_exports)).then((mod) => {
7532
7911
  return { default: mod.MarketsHeaderWidget };
7533
7912
  })
7534
7913
  );
7535
- var LazyMarketsDataListWidget = React6__default.default.lazy(
7914
+ var LazyMarketsDataListWidget = React7__default.default.lazy(
7536
7915
  () => Promise.resolve().then(() => (init_marketsDataList(), marketsDataList_exports)).then((mod) => {
7537
7916
  return { default: mod.MarketsDataListWidget };
7538
7917
  })
7539
7918
  );
7540
- var LazyFundingWidget = React6__default.default.lazy(
7919
+ var LazyFundingWidget = React7__default.default.lazy(
7541
7920
  () => Promise.resolve().then(() => (init_funding_widget(), funding_widget_exports)).then((mod) => {
7542
7921
  return { default: mod.FundingWidget };
7543
7922
  })
7544
7923
  );
7545
7924
  var MarketsHomePage = (props) => {
7546
7925
  const { isMobile } = ui.useScreen();
7547
- const [activeTab, setActiveTab] = React6.useState(
7926
+ const [activeTab, setActiveTab] = React7.useState(
7548
7927
  "markets" /* Markets */
7549
7928
  );
7550
7929
  const tabs = useMarketCategories("marketsDataList");
@@ -7600,8 +7979,8 @@ var MarketsDesktopContent = (props) => {
7600
7979
  value: "markets" /* Markets */,
7601
7980
  testid: "oui-testid-markets-tab",
7602
7981
  children: [
7603
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsHeaderWidget, { className: "oui-mt-4" }) }),
7604
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsDataListWidget, {}) })
7982
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsHeaderWidget, { className: "oui-mt-4" }) }),
7983
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsDataListWidget, {}) })
7605
7984
  ]
7606
7985
  }
7607
7986
  ),
@@ -7615,7 +7994,7 @@ var MarketsDesktopContent = (props) => {
7615
7994
  title: t("common.funding"),
7616
7995
  value: "funding" /* Funding */,
7617
7996
  testid: "oui-testid-funding-tab",
7618
- children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingWidget, {}) })
7997
+ children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingWidget, {}) })
7619
7998
  }
7620
7999
  )
7621
8000
  ]
@@ -7657,8 +8036,8 @@ var MarketsMobileContent = (props) => {
7657
8036
  value: "markets",
7658
8037
  testid: "oui-testid-markets-tab",
7659
8038
  children: [
7660
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsHeaderWidget, { className: "oui-mt-2" }) }),
7661
- /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsDataListWidget, {}) })
8039
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsHeaderWidget, { className: "oui-mt-2" }) }),
8040
+ /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyMarketsDataListWidget, {}) })
7662
8041
  ]
7663
8042
  }
7664
8043
  ),
@@ -7668,7 +8047,7 @@ var MarketsMobileContent = (props) => {
7668
8047
  title: t("common.funding"),
7669
8048
  value: "funding",
7670
8049
  testid: "oui-testid-funding-tab",
7671
- children: /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingWidget, {}) })
8050
+ children: /* @__PURE__ */ jsxRuntime.jsx(React7__default.default.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(LazyFundingWidget, {}) })
7672
8051
  }
7673
8052
  )
7674
8053
  ]