@loafmarkets/ui 0.1.332 → 0.1.334
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.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +79 -24
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +79 -24
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -13207,6 +13207,20 @@ var ChecklistDesc = styled9.div`
|
|
|
13207
13207
|
color: rgba(255, 255, 255, 0.4);
|
|
13208
13208
|
margin-top: 1px;
|
|
13209
13209
|
`;
|
|
13210
|
+
var SKIP_IPO_CONFIRM_KEY = "loaf:skip-ipo-confirm";
|
|
13211
|
+
function getSkipIpoConfirm() {
|
|
13212
|
+
try {
|
|
13213
|
+
return localStorage.getItem(SKIP_IPO_CONFIRM_KEY) === "1";
|
|
13214
|
+
} catch {
|
|
13215
|
+
return false;
|
|
13216
|
+
}
|
|
13217
|
+
}
|
|
13218
|
+
function setSkipIpoConfirm(skip) {
|
|
13219
|
+
try {
|
|
13220
|
+
if (skip) localStorage.setItem(SKIP_IPO_CONFIRM_KEY, "1");
|
|
13221
|
+
} catch {
|
|
13222
|
+
}
|
|
13223
|
+
}
|
|
13210
13224
|
function OrderConfirmationModal({
|
|
13211
13225
|
open,
|
|
13212
13226
|
onClose,
|
|
@@ -13222,6 +13236,7 @@ function OrderConfirmationModal({
|
|
|
13222
13236
|
isPlacing = false,
|
|
13223
13237
|
placingLabel = "Placing order\u2026"
|
|
13224
13238
|
}) {
|
|
13239
|
+
const [dontShowAgain, setDontShowAgain] = useState(false);
|
|
13225
13240
|
if (!open) return null;
|
|
13226
13241
|
const handleOverlayClose = () => {
|
|
13227
13242
|
if (isPlacing) return;
|
|
@@ -13281,30 +13296,47 @@ function OrderConfirmationModal({
|
|
|
13281
13296
|
] }),
|
|
13282
13297
|
"."
|
|
13283
13298
|
] }),
|
|
13284
|
-
/* @__PURE__ */ jsxs(
|
|
13285
|
-
/* @__PURE__ */
|
|
13286
|
-
|
|
13287
|
-
|
|
13288
|
-
|
|
13289
|
-
|
|
13290
|
-
|
|
13291
|
-
|
|
13292
|
-
|
|
13293
|
-
|
|
13294
|
-
|
|
13295
|
-
|
|
13296
|
-
|
|
13297
|
-
|
|
13298
|
-
|
|
13299
|
-
|
|
13300
|
-
|
|
13301
|
-
|
|
13302
|
-
|
|
13303
|
-
|
|
13304
|
-
|
|
13305
|
-
|
|
13306
|
-
|
|
13307
|
-
|
|
13299
|
+
/* @__PURE__ */ jsxs(ModalFooter, { children: [
|
|
13300
|
+
/* @__PURE__ */ jsxs(DontShowLabel, { children: [
|
|
13301
|
+
/* @__PURE__ */ jsx(
|
|
13302
|
+
"input",
|
|
13303
|
+
{
|
|
13304
|
+
type: "checkbox",
|
|
13305
|
+
checked: dontShowAgain,
|
|
13306
|
+
onChange: (e) => setDontShowAgain(e.target.checked),
|
|
13307
|
+
style: { accentColor: "#0ecb81" }
|
|
13308
|
+
}
|
|
13309
|
+
),
|
|
13310
|
+
"Don't show again"
|
|
13311
|
+
] }),
|
|
13312
|
+
/* @__PURE__ */ jsxs(ButtonRow2, { children: [
|
|
13313
|
+
/* @__PURE__ */ jsx(
|
|
13314
|
+
"button",
|
|
13315
|
+
{
|
|
13316
|
+
type: "button",
|
|
13317
|
+
onClick: onClose,
|
|
13318
|
+
className: "secondary",
|
|
13319
|
+
disabled: isPlacing,
|
|
13320
|
+
children: "Cancel"
|
|
13321
|
+
}
|
|
13322
|
+
),
|
|
13323
|
+
!hasInsufficientFunds && /* @__PURE__ */ jsx(
|
|
13324
|
+
"button",
|
|
13325
|
+
{
|
|
13326
|
+
type: "button",
|
|
13327
|
+
onClick: () => {
|
|
13328
|
+
if (dontShowAgain) setSkipIpoConfirm(true);
|
|
13329
|
+
onConfirm();
|
|
13330
|
+
},
|
|
13331
|
+
className: "primary",
|
|
13332
|
+
disabled: isPlacing,
|
|
13333
|
+
children: isPlacing ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
13334
|
+
/* @__PURE__ */ jsx(Spinner, { "aria-hidden": true }),
|
|
13335
|
+
/* @__PURE__ */ jsx("span", { children: placingLabel })
|
|
13336
|
+
] }) : "Place Order"
|
|
13337
|
+
}
|
|
13338
|
+
)
|
|
13339
|
+
] })
|
|
13308
13340
|
] })
|
|
13309
13341
|
] }) });
|
|
13310
13342
|
}
|
|
@@ -13429,6 +13461,23 @@ var Spinner = styled9.span`
|
|
|
13429
13461
|
margin-right: 0.5rem;
|
|
13430
13462
|
vertical-align: -2px;
|
|
13431
13463
|
`;
|
|
13464
|
+
var ModalFooter = styled9.div`
|
|
13465
|
+
display: flex;
|
|
13466
|
+
align-items: center;
|
|
13467
|
+
justify-content: space-between;
|
|
13468
|
+
gap: 1rem;
|
|
13469
|
+
`;
|
|
13470
|
+
var DontShowLabel = styled9.label`
|
|
13471
|
+
display: flex;
|
|
13472
|
+
align-items: center;
|
|
13473
|
+
gap: 0.4rem;
|
|
13474
|
+
font-size: 0.78rem;
|
|
13475
|
+
color: rgba(255, 255, 255, 0.5);
|
|
13476
|
+
cursor: pointer;
|
|
13477
|
+
user-select: none;
|
|
13478
|
+
white-space: nowrap;
|
|
13479
|
+
&:hover { color: rgba(255, 255, 255, 0.7); }
|
|
13480
|
+
`;
|
|
13432
13481
|
var ButtonRow2 = styled9.div`
|
|
13433
13482
|
display: flex;
|
|
13434
13483
|
gap: 1rem;
|
|
@@ -13558,6 +13607,7 @@ function PortfolioActivityPanel({
|
|
|
13558
13607
|
cancellingOrderId = null,
|
|
13559
13608
|
compactPositions = false,
|
|
13560
13609
|
defaultTab,
|
|
13610
|
+
onTabChange,
|
|
13561
13611
|
pageSize = ACTIVITY_PAGE_SIZE_DEFAULT,
|
|
13562
13612
|
blockExplorerBaseUrl: _blockExplorerBaseUrl = "https://sepolia.basescan.org/tx",
|
|
13563
13613
|
className,
|
|
@@ -13687,6 +13737,7 @@ function PortfolioActivityPanel({
|
|
|
13687
13737
|
const handleTabChange = (tab) => {
|
|
13688
13738
|
setActiveTab(tab);
|
|
13689
13739
|
setCurrentPage(0);
|
|
13740
|
+
onTabChange?.(tab);
|
|
13690
13741
|
};
|
|
13691
13742
|
const activeDataLength = (() => {
|
|
13692
13743
|
switch (activeTab) {
|
|
@@ -14943,6 +14994,10 @@ function PropertyBuy({
|
|
|
14943
14994
|
if (!ipoStarted || tokenQuantity === 0) {
|
|
14944
14995
|
return;
|
|
14945
14996
|
}
|
|
14997
|
+
if (getSkipIpoConfirm()) {
|
|
14998
|
+
void confirmOrder();
|
|
14999
|
+
return;
|
|
15000
|
+
}
|
|
14946
15001
|
setShowOrderConfirmModal(true);
|
|
14947
15002
|
};
|
|
14948
15003
|
useEffect(() => {
|