@kodiak-finance/orderly-affiliate 2.9.1 → 2.9.2-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
@@ -550,7 +550,7 @@ var useReferralCodeFormScript = (options) => {
550
550
  const onEdit = async () => {
551
551
  const editReferralCodeParams = {
552
552
  current_referral_code: referralCode,
553
- new_referral_code: newCode
553
+ new_referral_code: newCode.toUpperCase().replace(/[^A-Z0-9]/g, "")
554
554
  };
555
555
  const updateRebateRateParams = {
556
556
  referee_rebate_rate: new orderlyUtils.Decimal(refereeRebatePercentage).div(100).toNumber(),
@@ -681,30 +681,77 @@ var GiftIcon = (props) => {
681
681
  }
682
682
  );
683
683
  };
684
+ var WarningBox = (props) => /* @__PURE__ */ jsxRuntime.jsxs(
685
+ orderlyUi.Flex,
686
+ {
687
+ className: "oui-bg-warning/10",
688
+ justify: "start",
689
+ itemAlign: "start",
690
+ gap: 1,
691
+ r: "lg",
692
+ p: 3,
693
+ children: [
694
+ /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.WarningIcon, { className: "oui-shrink-0 oui-text-warning" }),
695
+ typeof props.children === "string" ? /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { size: "2xs", intensity: 54, className: "oui-text-warning", children: props.children }) : props.children
696
+ ]
697
+ }
698
+ );
699
+ var ReferralCodeInput = (props) => {
700
+ const hasSetCursorToEnd = react.useRef(false);
701
+ return /* @__PURE__ */ jsxRuntime.jsx(
702
+ orderlyUi.TextField,
703
+ {
704
+ type: "text",
705
+ fullWidth: true,
706
+ label: props.label ?? "",
707
+ placeholder: props.placeholder,
708
+ value: props.value,
709
+ onChange: (e) => {
710
+ props.onChange(e.target.value);
711
+ },
712
+ onFocus: (e) => {
713
+ if (props.autoFocus && !hasSetCursorToEnd.current) {
714
+ hasSetCursorToEnd.current = true;
715
+ const input = e.target;
716
+ const len = input.value.length;
717
+ requestAnimationFrame(() => {
718
+ input.setSelectionRange(len, len);
719
+ });
720
+ }
721
+ },
722
+ formatters: [
723
+ orderlyUi.inputFormatter.createRegexInputFormatter((value) => {
724
+ return String(value).replace(
725
+ /[a-z]/g,
726
+ (char) => char.toUpperCase()
727
+ );
728
+ }),
729
+ orderlyUi.inputFormatter.createRegexInputFormatter(/[^A-Z0-9]/g)
730
+ ],
731
+ className: "oui-w-full",
732
+ classNames: {
733
+ label: "oui-text-base-contrast-54 oui-text-xs",
734
+ input: "placeholder:oui-text-base-contrast-20 placeholder:oui-text-sm"
735
+ },
736
+ helpText: props.helpText,
737
+ color: props.color,
738
+ maxLength: 10,
739
+ minLength: 4,
740
+ autoComplete: "off",
741
+ disabled: props.disabled,
742
+ autoFocus: props.autoFocus
743
+ }
744
+ );
745
+ };
684
746
  var ReferralCodeForm = (props) => {
685
747
  const { type, isReview } = props;
686
748
  const { t } = orderlyI18n.useTranslation();
687
- const isBind = type === "bind" /* Bind */;
688
749
  const isReset = type === "reset" /* Reset */;
689
750
  const hasBoundReferee = !!props.directInvites && props.directInvites > 0;
690
751
  const isEditingRefereeRebateRate = !!props.accountId;
691
752
  const noCommissionAvailable = props.maxRebateRate === 0;
692
753
  const { title, description, buttonText } = react.useMemo(() => {
693
754
  switch (type) {
694
- case "bind" /* Bind */:
695
- return {
696
- title: t("affiliate.referralCode.bind.modal.title"),
697
- description: /* @__PURE__ */ jsxRuntime.jsx(
698
- orderlyUi.Text,
699
- {
700
- size: "2xs",
701
- intensity: 54,
702
- className: "oui-leading-[18px] oui-text-warning-darken",
703
- children: t("affiliate.referralCode.bind.modal.description")
704
- }
705
- ),
706
- buttonText: t("common.confirm")
707
- };
708
755
  case "create" /* Create */:
709
756
  return {
710
757
  title: t("affiliate.referralCode.create.modal.title"),
@@ -750,19 +797,6 @@ var ReferralCodeForm = (props) => {
750
797
  }
751
798
  );
752
799
  const descriptionView = /* @__PURE__ */ jsxRuntime.jsx(WarningBox, { children: description });
753
- const bindCodeInvalid = isBind && !props.skipBinding && props.formattedBindCode.length >= 4 && !props.isBindCodeChecking && props.isBindCodeExist === false;
754
- const bindReferralCodeInput = /* @__PURE__ */ jsxRuntime.jsx(
755
- ReferralCodeInput,
756
- {
757
- value: props.bindCodeInput,
758
- onChange: props.setBindCodeInput,
759
- autoFocus: true,
760
- disabled: props.skipBinding,
761
- placeholder: t("affiliate.referralCode.bind.input.placeholder"),
762
- helpText: bindCodeInvalid ? t("affiliate.referralCode.notExist") : void 0,
763
- color: bindCodeInvalid ? "danger" : void 0
764
- }
765
- );
766
800
  const referralCodeInput = /* @__PURE__ */ jsxRuntime.jsx(
767
801
  ReferralCodeInput,
768
802
  {
@@ -773,30 +807,6 @@ var ReferralCodeForm = (props) => {
773
807
  label: t("affiliate.referralCode.editCodeModal.label")
774
808
  }
775
809
  );
776
- const bindCheckbox = isBind && /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Flex, { className: "oui-gap-[6px]", children: [
777
- /* @__PURE__ */ jsxRuntime.jsx(
778
- orderlyUi.Checkbox,
779
- {
780
- color: "white",
781
- id: "oui-checkbox-skipReferralBinding",
782
- checked: props.skipBinding,
783
- onCheckedChange: (checked) => {
784
- props.setSkipBinding(checked);
785
- if (checked) {
786
- props.setBindCodeInput("");
787
- }
788
- }
789
- }
790
- ),
791
- /* @__PURE__ */ jsxRuntime.jsx(
792
- "label",
793
- {
794
- htmlFor: "oui-checkbox-skipReferralBinding",
795
- className: "oui-text-2xs oui-font-normal oui-text-base-contrast-54",
796
- children: t("affiliate.referralCode.bind.skip")
797
- }
798
- )
799
- ] });
800
810
  const commissionConfiguration = /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
801
811
  /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { size: "2xs", intensity: 54, children: t("affiliate.commissionConfiguration") }),
802
812
  !isReview && /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Text, { size: "2xs", intensity: 54, children: [
@@ -859,12 +869,6 @@ var ReferralCodeForm = (props) => {
859
869
  ] });
860
870
  const renderContent = () => {
861
871
  switch (type) {
862
- case "bind" /* Bind */:
863
- return /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Flex, { width: "100%", direction: "column", itemAlign: "start", gap: 4, children: [
864
- bindReferralCodeInput,
865
- bindCheckbox,
866
- buttons
867
- ] });
868
872
  case "create" /* Create */:
869
873
  return /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Flex, { width: "100%", direction: "column", itemAlign: "start", gap: 2, children: [
870
874
  commissionConfiguration,
@@ -995,7 +999,7 @@ var RebateRateSlider = (props) => {
995
999
  /* @__PURE__ */ jsxRuntime.jsx(
996
1000
  orderlyUi.Text,
997
1001
  {
998
- size: "base",
1002
+ size: "sm",
999
1003
  intensity: 54,
1000
1004
  as: "span",
1001
1005
  className: "oui-inline-flex oui-items-center oui-gap-1 oui-tracking-[0.03em]",
@@ -1013,74 +1017,6 @@ var RebateRateSlider = (props) => {
1013
1017
  ] })
1014
1018
  ] });
1015
1019
  };
1016
- var ReferralCodeInput = (props) => {
1017
- const hasSetCursorToEnd = react.useRef(false);
1018
- return /* @__PURE__ */ jsxRuntime.jsx(
1019
- orderlyUi.TextField,
1020
- {
1021
- type: "text",
1022
- fullWidth: true,
1023
- label: props.label ?? "",
1024
- placeholder: props.placeholder,
1025
- value: props.value,
1026
- onChange: (e) => {
1027
- props.onChange(e.target.value);
1028
- },
1029
- onFocus: (e) => {
1030
- if (props.autoFocus && !hasSetCursorToEnd.current) {
1031
- hasSetCursorToEnd.current = true;
1032
- const input = e.target;
1033
- const len = input.value.length;
1034
- requestAnimationFrame(() => {
1035
- input.setSelectionRange(len, len);
1036
- });
1037
- }
1038
- },
1039
- formatters: [
1040
- orderlyUi.inputFormatter.createRegexInputFormatter((value) => {
1041
- return String(value).replace(
1042
- /[a-z]/g,
1043
- (char) => char.toUpperCase()
1044
- );
1045
- }),
1046
- orderlyUi.inputFormatter.createRegexInputFormatter(/[^A-Z0-9]/g)
1047
- ],
1048
- className: "oui-w-full",
1049
- classNames: {
1050
- label: "oui-text-base-contrast-54 oui-text-xs",
1051
- input: "placeholder:oui-text-base-contrast-20 placeholder:oui-text-sm"
1052
- },
1053
- helpText: props.helpText,
1054
- color: props.color,
1055
- maxLength: 10,
1056
- minLength: 4,
1057
- autoComplete: "off",
1058
- disabled: props.disabled,
1059
- autoFocus: props.autoFocus
1060
- }
1061
- );
1062
- };
1063
- var WarningBox = (props) => {
1064
- const { children } = props;
1065
- if (typeof children === "string") {
1066
- return /* @__PURE__ */ jsxRuntime.jsxs(
1067
- orderlyUi.Flex,
1068
- {
1069
- className: "oui-bg-warning/10",
1070
- justify: "start",
1071
- itemAlign: "start",
1072
- gap: 1,
1073
- r: "lg",
1074
- p: 3,
1075
- children: [
1076
- /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.WarningIcon, { className: "oui-shrink-0 oui-text-warning" }),
1077
- /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { size: "2xs", intensity: 54, className: "oui-text-warning", children })
1078
- ]
1079
- }
1080
- );
1081
- }
1082
- return children;
1083
- };
1084
1020
  var ReferralCodeFormWidget = (props) => {
1085
1021
  const state = useReferralCodeFormScript(props);
1086
1022
  return /* @__PURE__ */ jsxRuntime.jsx(ReferralCodeForm, { ...state, ...props });
@@ -4216,8 +4152,25 @@ var UnPinIcon = (props) => {
4216
4152
  }
4217
4153
  );
4218
4154
  };
4155
+ var EditIcon2 = (props) => {
4156
+ const { className, ...rest } = props;
4157
+ return /* @__PURE__ */ jsxRuntime.jsx(
4158
+ "svg",
4159
+ {
4160
+ width: "12",
4161
+ height: "13",
4162
+ viewBox: "0 0 12 13",
4163
+ xmlns: "http://www.w3.org/2000/svg",
4164
+ fill: "white",
4165
+ fillOpacity: "0.36",
4166
+ className,
4167
+ ...rest,
4168
+ children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8.49773 1.47656C8.36523 1.47656 8.23223 1.52357 8.13823 1.61707C7.86023 1.89507 6.85973 2.89558 6.63773 3.11808L2.13523 7.62059L1.63473 8.12059C1.56523 8.19059 1.52923 8.28958 1.50973 8.38658L1.00973 10.8881C0.939727 11.2381 1.23773 11.5361 1.58773 11.4666C1.90073 11.4036 3.77673 11.0286 4.08923 10.9661C4.18623 10.9466 4.28523 10.9106 4.35523 10.8411L4.85523 10.3406L9.35773 5.83808C9.58023 5.61608 10.5807 4.61506 10.8587 4.33756C10.9522 4.24356 10.9992 4.11056 10.9992 3.97806C10.9992 3.15956 10.7907 2.57456 10.3582 2.13306C9.92173 1.68756 9.33873 1.47656 8.49773 1.47656ZM8.69473 2.48606C9.14623 2.51256 9.43873 2.61608 9.63923 2.82108C9.84423 3.03008 9.97373 3.32008 10.0017 3.76258C9.72773 4.03608 9.32673 4.43106 8.99823 4.75956C8.60173 4.36306 8.11273 3.87407 7.71623 3.47757C8.04523 3.14907 8.42123 2.75956 8.69473 2.48606ZM6.99723 4.19657L8.27923 5.47858L4.49573 9.26207L3.21373 7.98009L6.99723 4.19657ZM2.49473 8.69908L3.77673 9.98107L3.72973 10.0281C3.39973 10.0941 2.73323 10.2336 2.11923 10.3566L2.44773 8.74608L2.49473 8.69908Z" })
4169
+ }
4170
+ );
4171
+ };
4219
4172
  var ReferralCodes = (props) => {
4220
- const isTablet = orderlyHooks.useMediaQuery("(max-width: 767px)");
4173
+ const { isMobile } = orderlyUi.useScreen();
4221
4174
  return /* @__PURE__ */ jsxRuntime.jsxs(
4222
4175
  orderlyUi.Flex,
4223
4176
  {
@@ -4231,7 +4184,7 @@ var ReferralCodes = (props) => {
4231
4184
  /* @__PURE__ */ jsxRuntime.jsx(Title4, { ...props }),
4232
4185
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "oui-flex oui-w-full oui-flex-col 2xl:oui-h-full", children: [
4233
4186
  /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Divider, {}),
4234
- isTablet ? /* @__PURE__ */ jsxRuntime.jsx(MobileLayout, { ...props }) : /* @__PURE__ */ jsxRuntime.jsx(DesktopLayout, { ...props })
4187
+ isMobile ? /* @__PURE__ */ jsxRuntime.jsx(MobileLayout, { ...props }) : /* @__PURE__ */ jsxRuntime.jsx(DesktopLayout, { ...props })
4235
4188
  ] })
4236
4189
  ]
4237
4190
  }
@@ -4295,7 +4248,7 @@ var MobileCellItem = (props) => {
4295
4248
  }
4296
4249
  ),
4297
4250
  editRate && /* @__PURE__ */ jsxRuntime.jsx(
4298
- EditIcon,
4251
+ EditIcon2,
4299
4252
  {
4300
4253
  className: "oui-mt-px oui-cursor-pointer oui-fill-base-contrast-36 hover:oui-fill-base-contrast-80",
4301
4254
  fillOpacity: 1,
@@ -4420,7 +4373,7 @@ var MobileCell2 = (props) => {
4420
4373
  };
4421
4374
  var DesktopLayout = (props) => {
4422
4375
  const { t } = orderlyI18n.useTranslation();
4423
- const moreColumn = orderlyHooks.useMediaQuery("(min-width: 1024px)");
4376
+ const { isDesktop: moreColumn } = orderlyUi.useScreen();
4424
4377
  const columns = react.useMemo(() => {
4425
4378
  const cols = [
4426
4379
  {
@@ -4474,7 +4427,7 @@ var DesktopLayout = (props) => {
4474
4427
  return /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Flex, { direction: "row", itemAlign: "center", gap: 1, children: [
4475
4428
  getRate(data),
4476
4429
  /* @__PURE__ */ jsxRuntime.jsx(
4477
- EditIcon,
4430
+ EditIcon2,
4478
4431
  {
4479
4432
  className: "oui-mt-[6px] oui-cursor-pointer oui-fill-base-contrast-36 hover:oui-fill-base-contrast-80",
4480
4433
  fillOpacity: 1,
@@ -4961,7 +4914,7 @@ var MobileCellItem2 = (props) => {
4961
4914
  };
4962
4915
  var CommissionList = (props) => {
4963
4916
  const { t } = orderlyI18n.useTranslation();
4964
- const isLG = orderlyHooks.useMediaQuery("(max-width: 767px)");
4917
+ const { isMobile } = orderlyUi.useScreen();
4965
4918
  const columns = react.useMemo(() => {
4966
4919
  const cols = [
4967
4920
  {
@@ -5002,7 +4955,7 @@ var CommissionList = (props) => {
5002
4955
  return cols;
5003
4956
  }, [t]);
5004
4957
  const body = react.useMemo(() => {
5005
- if (isLG) {
4958
+ if (isMobile) {
5006
4959
  return /* @__PURE__ */ jsxRuntime.jsx(
5007
4960
  orderlyUi.ListView,
5008
4961
  {
@@ -5077,7 +5030,7 @@ var CommissionList = (props) => {
5077
5030
  }
5078
5031
  }
5079
5032
  );
5080
- }, [isLG, props.commission]);
5033
+ }, [isMobile, props.commission]);
5081
5034
  return /* @__PURE__ */ jsxRuntime.jsxs(
5082
5035
  orderlyUi.Flex,
5083
5036
  {
@@ -5100,7 +5053,7 @@ var CommissionList = (props) => {
5100
5053
  };
5101
5054
  var RefereesList = (props) => {
5102
5055
  const { t } = orderlyI18n.useTranslation();
5103
- const isLG = orderlyHooks.useMediaQuery("(max-width: 767px)");
5056
+ const { isMobile } = orderlyUi.useScreen();
5104
5057
  const columns = react.useMemo(() => {
5105
5058
  const cols = [
5106
5059
  {
@@ -5144,7 +5097,7 @@ var RefereesList = (props) => {
5144
5097
  return cols;
5145
5098
  }, [t]);
5146
5099
  const body = react.useMemo(() => {
5147
- if (isLG) {
5100
+ if (isMobile) {
5148
5101
  return /* @__PURE__ */ jsxRuntime.jsx(
5149
5102
  orderlyUi.ListView,
5150
5103
  {
@@ -5239,7 +5192,7 @@ var RefereesList = (props) => {
5239
5192
  }
5240
5193
  }
5241
5194
  );
5242
- }, [isLG, props.referees]);
5195
+ }, [isMobile, props.referees]);
5243
5196
  return /* @__PURE__ */ jsxRuntime.jsx(
5244
5197
  orderlyUi.Flex,
5245
5198
  {
@@ -5282,13 +5235,13 @@ var useCommissionDataScript = () => {
5282
5235
  to: dateFns.subDays(/* @__PURE__ */ new Date(), 1)
5283
5236
  }
5284
5237
  );
5285
- const isLG = orderlyHooks.useMediaQuery("(max-width: 767px)");
5238
+ const { isMobile } = orderlyUi.useScreen();
5286
5239
  const { page, pageSize, setPage, parsePagination } = orderlyUi.usePagination();
5287
5240
  const [commissionData, { refresh, isLoading, loadMore, meta }] = orderlyHooks.useReferralRebateSummary({
5288
5241
  startDate: commissionRange?.from !== void 0 ? dateFns.format(commissionRange.from, "yyyy-MM-dd") : void 0,
5289
5242
  endDate: commissionRange?.to !== void 0 ? dateFns.format(commissionRange.to, "yyyy-MM-dd") : void 0,
5290
5243
  size: pageSize,
5291
- page: !isLG ? page : void 0
5244
+ page: !isMobile ? page : void 0
5292
5245
  });
5293
5246
  react.useEffect(() => {
5294
5247
  refresh();
@@ -5316,13 +5269,13 @@ var useRefereesDataScript = () => {
5316
5269
  to: dateFns.subDays(/* @__PURE__ */ new Date(), 1)
5317
5270
  }
5318
5271
  );
5319
- const isLG = orderlyHooks.useMediaQuery("(max-width: 767px)");
5272
+ const { isMobile } = orderlyUi.useScreen();
5320
5273
  const { page, pageSize, setPage, parsePagination } = orderlyUi.usePagination();
5321
5274
  const [commissionData, { refresh, isLoading, loadMore, meta }] = orderlyHooks.useRefereeInfo({
5322
5275
  startDate: commissionRange?.from !== void 0 ? dateFns.format(commissionRange.from, "yyyy-MM-dd") : void 0,
5323
5276
  endDate: commissionRange?.to !== void 0 ? dateFns.format(commissionRange.to, "yyyy-MM-dd") : void 0,
5324
5277
  size: pageSize,
5325
- page: !isLG ? page : void 0,
5278
+ page: !isMobile ? page : void 0,
5326
5279
  sort: "descending_code_binding_time"
5327
5280
  });
5328
5281
  react.useEffect(() => {
@@ -5439,7 +5392,7 @@ var BecomeAffiliate = (props) => {
5439
5392
  width: "100%",
5440
5393
  children: [
5441
5394
  /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { children: t("affiliate.process.title") }),
5442
- /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Flex, { className: "oui-flex oui-flex-col oui-gap-3 lg:oui-w-full lg:oui-flex-row lg:oui-items-stretch", children: [
5395
+ /* @__PURE__ */ jsxRuntime.jsxs(orderlyUi.Flex, { className: "oui-flex oui-flex-col oui-gap-3 xl:oui-w-full xl:oui-flex-row xl:oui-items-stretch", children: [
5443
5396
  /* @__PURE__ */ jsxRuntime.jsx(
5444
5397
  Item,
5445
5398
  {
@@ -5448,7 +5401,7 @@ var BecomeAffiliate = (props) => {
5448
5401
  content: applyText.desc
5449
5402
  }
5450
5403
  ),
5451
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "oui-shrink lg:oui-flex lg:-oui-rotate-90 lg:oui-flex-row lg:oui-items-center lg:oui-justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ArrowDownIcon, {}) }),
5404
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "oui-shrink xl:oui-flex xl:-oui-rotate-90 xl:oui-flex-row xl:oui-items-center xl:oui-justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ArrowDownIcon, {}) }),
5452
5405
  /* @__PURE__ */ jsxRuntime.jsx(
5453
5406
  Item,
5454
5407
  {
@@ -5457,7 +5410,7 @@ var BecomeAffiliate = (props) => {
5457
5410
  content: t("affiliate.process.step2.description")
5458
5411
  }
5459
5412
  ),
5460
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "oui-shrink lg:oui-flex lg:-oui-rotate-90 lg:oui-flex-row lg:oui-items-center lg:oui-justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ArrowDownIcon, {}) }),
5413
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "oui-shrink xl:oui-flex xl:-oui-rotate-90 xl:oui-flex-row xl:oui-items-center xl:oui-justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(ArrowDownIcon, {}) }),
5461
5414
  /* @__PURE__ */ jsxRuntime.jsx(
5462
5415
  Item,
5463
5416
  {
@@ -5477,7 +5430,7 @@ var Item = (props) => {
5477
5430
  {
5478
5431
  className: orderlyUi.cn(
5479
5432
  "oui-flex oui-flex-row oui-gap-3",
5480
- "lg:oui-flex-1 lg:oui-flex-col lg:oui-gap-[6px]"
5433
+ "xl:oui-flex-1 xl:oui-flex-col xl:oui-gap-[6px]"
5481
5434
  ),
5482
5435
  width: "100%",
5483
5436
  children: [
@@ -5488,11 +5441,11 @@ var Item = (props) => {
5488
5441
  className: orderlyUi.cn(
5489
5442
  "oui-flex oui-flex-col oui-items-start oui-h-full oui-justify-between",
5490
5443
  // lg
5491
- "lg:oui-items-center lg:oui-justify-start"
5444
+ "xl:oui-items-center xl:oui-justify-start"
5492
5445
  ),
5493
5446
  children: [
5494
- /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { className: "oui-text-sm md:oui-text-base 2xl:oui-text-lg lg:oui-text-center", children: props.title }),
5495
- /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { className: "oui-text-2xs oui-text-base-contrast-36 lg:oui-text-center", children: props.content })
5447
+ /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { className: "oui-text-sm md:oui-text-base 2xl:oui-text-lg xl:oui-text-center", children: props.title }),
5448
+ /* @__PURE__ */ jsxRuntime.jsx(orderlyUi.Text, { className: "oui-text-2xs oui-text-base-contrast-36 xl:oui-text-center", children: props.content })
5496
5449
  ]
5497
5450
  }
5498
5451
  )
@@ -5509,7 +5462,7 @@ var ApplyIcon = () => {
5509
5462
  viewBox: "0 0 48 48",
5510
5463
  fill: "none",
5511
5464
  xmlns: "http://www.w3.org/2000/svg",
5512
- className: "lg:oui-w-[64px] lg:oui-h-[64px] 2xl:oui-w-[80px] 2xl:oui-h-[80px]",
5465
+ className: "xl:oui-w-[64px] xl:oui-h-[64px] 2xl:oui-w-[80px] 2xl:oui-h-[80px]",
5513
5466
  children: [
5514
5467
  /* @__PURE__ */ jsxRuntime.jsx(
5515
5468
  "path",
@@ -5577,7 +5530,7 @@ var ShareIcon = () => {
5577
5530
  viewBox: "0 0 48 48",
5578
5531
  fill: "none",
5579
5532
  xmlns: "http://www.w3.org/2000/svg",
5580
- className: "lg:oui-w-[64px] lg:oui-h-[64px] 2xl:oui-w-[80px] 2xl:oui-h-[80px]",
5533
+ className: "xl:oui-w-[64px] xl:oui-h-[64px] 2xl:oui-w-[80px] 2xl:oui-h-[80px]",
5581
5534
  children: [
5582
5535
  /* @__PURE__ */ jsxRuntime.jsx(
5583
5536
  "path",
@@ -5619,7 +5572,7 @@ var EarnIcon = () => {
5619
5572
  viewBox: "0 0 48 48",
5620
5573
  fill: "none",
5621
5574
  xmlns: "http://www.w3.org/2000/svg",
5622
- className: "lg:oui-w-[64px] lg:oui-h-[64px] 2xl:oui-w-[80px] 2xl:oui-h-[80px]",
5575
+ className: "xl:oui-w-[64px] xl:oui-h-[64px] 2xl:oui-w-[80px] 2xl:oui-h-[80px]",
5623
5576
  children: [
5624
5577
  /* @__PURE__ */ jsxRuntime.jsx(
5625
5578
  "path",
@@ -6768,7 +6721,7 @@ var Title8 = (props) => {
6768
6721
  };
6769
6722
  var List = (props) => {
6770
6723
  const { t } = orderlyI18n.useTranslation();
6771
- const layout767 = orderlyHooks.useMediaQuery("(max-width: 767px)");
6724
+ const { isMobile } = orderlyUi.useScreen();
6772
6725
  const columns = [
6773
6726
  {
6774
6727
  title: `${t("affiliate.trader.rebates")} (USDC)`,
@@ -6799,7 +6752,7 @@ var List = (props) => {
6799
6752
  width: 127
6800
6753
  }
6801
6754
  ];
6802
- if (layout767) {
6755
+ if (isMobile) {
6803
6756
  return /* @__PURE__ */ jsxRuntime.jsx(
6804
6757
  orderlyUi.ListView,
6805
6758
  {