@orderly.network/ui-orders 2.8.13-rc.0 → 2.8.13

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.mjs CHANGED
@@ -5527,7 +5527,16 @@ var init_orderList_script = __esm({
5527
5527
  });
5528
5528
  }, [type, t, props.symbol]);
5529
5529
  const formattedData = useFormatOrderHistory(data ?? []);
5530
- const dataSource = useDataTap(type !== "tp_sl" /* tp_sl */ ? formattedData : data, {
5530
+ const filteredData = useMemo(() => {
5531
+ const rawData = type !== "tp_sl" /* tp_sl */ ? formattedData : data;
5532
+ if (!props.symbol || !rawData) {
5533
+ return rawData;
5534
+ }
5535
+ return rawData.filter(
5536
+ (order) => order.symbol === props.symbol
5537
+ );
5538
+ }, [type, formattedData, data, props.symbol]);
5539
+ const dataSource = useDataTap(filteredData, {
5531
5540
  fallbackData: []
5532
5541
  }) ?? void 0;
5533
5542
  const _pagination = useMemo(() => {