@loafmarkets/ui 0.1.263 → 0.1.265
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 +323 -24
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +323 -24
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -900,13 +900,14 @@ type PortfolioActivityPanelProps = {
|
|
|
900
900
|
price?: number;
|
|
901
901
|
}) => Promise<void>;
|
|
902
902
|
cancellingOrderId?: number | null;
|
|
903
|
+
compactPositions?: boolean;
|
|
903
904
|
defaultTab?: ActivityTabId;
|
|
904
905
|
pageSize?: number;
|
|
905
906
|
blockExplorerBaseUrl?: string;
|
|
906
907
|
className?: string;
|
|
907
908
|
style?: React.CSSProperties;
|
|
908
909
|
};
|
|
909
|
-
declare function PortfolioActivityPanel({ positions, showPositionsTab, onPositionClick, onClosePosition, offeringOrders, openOrders, orderHistory, tradeHistory, transfers, onCancelOrder, onCancelAllOrders, onAmendOrder, cancellingOrderId, defaultTab, pageSize, blockExplorerBaseUrl, className, style, }: PortfolioActivityPanelProps): react_jsx_runtime.JSX.Element;
|
|
910
|
+
declare function PortfolioActivityPanel({ positions, showPositionsTab, onPositionClick, onClosePosition, offeringOrders, openOrders, orderHistory, tradeHistory, transfers, onCancelOrder, onCancelAllOrders, onAmendOrder, cancellingOrderId, compactPositions, defaultTab, pageSize, blockExplorerBaseUrl, className, style, }: PortfolioActivityPanelProps): react_jsx_runtime.JSX.Element;
|
|
910
911
|
|
|
911
912
|
type SelectorItem = {
|
|
912
913
|
readonly tokenName: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -900,13 +900,14 @@ type PortfolioActivityPanelProps = {
|
|
|
900
900
|
price?: number;
|
|
901
901
|
}) => Promise<void>;
|
|
902
902
|
cancellingOrderId?: number | null;
|
|
903
|
+
compactPositions?: boolean;
|
|
903
904
|
defaultTab?: ActivityTabId;
|
|
904
905
|
pageSize?: number;
|
|
905
906
|
blockExplorerBaseUrl?: string;
|
|
906
907
|
className?: string;
|
|
907
908
|
style?: React.CSSProperties;
|
|
908
909
|
};
|
|
909
|
-
declare function PortfolioActivityPanel({ positions, showPositionsTab, onPositionClick, onClosePosition, offeringOrders, openOrders, orderHistory, tradeHistory, transfers, onCancelOrder, onCancelAllOrders, onAmendOrder, cancellingOrderId, defaultTab, pageSize, blockExplorerBaseUrl, className, style, }: PortfolioActivityPanelProps): react_jsx_runtime.JSX.Element;
|
|
910
|
+
declare function PortfolioActivityPanel({ positions, showPositionsTab, onPositionClick, onClosePosition, offeringOrders, openOrders, orderHistory, tradeHistory, transfers, onCancelOrder, onCancelAllOrders, onAmendOrder, cancellingOrderId, compactPositions, defaultTab, pageSize, blockExplorerBaseUrl, className, style, }: PortfolioActivityPanelProps): react_jsx_runtime.JSX.Element;
|
|
910
911
|
|
|
911
912
|
type SelectorItem = {
|
|
912
913
|
readonly tokenName: string;
|
package/dist/index.js
CHANGED
|
@@ -13639,6 +13639,7 @@ function PortfolioActivityPanel({
|
|
|
13639
13639
|
onCancelAllOrders,
|
|
13640
13640
|
onAmendOrder,
|
|
13641
13641
|
cancellingOrderId = null,
|
|
13642
|
+
compactPositions = false,
|
|
13642
13643
|
defaultTab,
|
|
13643
13644
|
pageSize = ACTIVITY_PAGE_SIZE_DEFAULT,
|
|
13644
13645
|
blockExplorerBaseUrl = "https://sepolia.basescan.org/tx",
|
|
@@ -13663,6 +13664,36 @@ function PortfolioActivityPanel({
|
|
|
13663
13664
|
setPosSortAsc(key === "asset");
|
|
13664
13665
|
}
|
|
13665
13666
|
};
|
|
13667
|
+
const [expandedPositions, setExpandedPositions] = React5.useState(/* @__PURE__ */ new Set());
|
|
13668
|
+
const [allExpanded, setAllExpanded] = React5.useState(false);
|
|
13669
|
+
const [sortDropdownOpen, setSortDropdownOpen] = React5.useState(false);
|
|
13670
|
+
const togglePosition = (tokenName) => {
|
|
13671
|
+
setExpandedPositions((prev) => {
|
|
13672
|
+
const next = new Set(prev);
|
|
13673
|
+
if (next.has(tokenName)) next.delete(tokenName);
|
|
13674
|
+
else next.add(tokenName);
|
|
13675
|
+
return next;
|
|
13676
|
+
});
|
|
13677
|
+
};
|
|
13678
|
+
const sortKeyLabel = (key) => {
|
|
13679
|
+
switch (key) {
|
|
13680
|
+
case "asset":
|
|
13681
|
+
return "Asset";
|
|
13682
|
+
case "units":
|
|
13683
|
+
return "Units";
|
|
13684
|
+
case "value":
|
|
13685
|
+
return "Value";
|
|
13686
|
+
case "avgPrice":
|
|
13687
|
+
return "Avg Price";
|
|
13688
|
+
case "currentPrice":
|
|
13689
|
+
return "Price";
|
|
13690
|
+
case "pnl":
|
|
13691
|
+
return "PNL";
|
|
13692
|
+
default:
|
|
13693
|
+
return "Asset";
|
|
13694
|
+
}
|
|
13695
|
+
};
|
|
13696
|
+
const sortKeys = ["asset", "units", "value", "avgPrice", "currentPrice", "pnl"];
|
|
13666
13697
|
const sortedPositions = React5.useMemo(() => {
|
|
13667
13698
|
const arr = [...positions];
|
|
13668
13699
|
const dir = posSortAsc ? 1 : -1;
|
|
@@ -13689,6 +13720,15 @@ function PortfolioActivityPanel({
|
|
|
13689
13720
|
});
|
|
13690
13721
|
return arr;
|
|
13691
13722
|
}, [positions, posSortKey, posSortAsc]);
|
|
13723
|
+
const toggleExpandAll = () => {
|
|
13724
|
+
if (allExpanded) {
|
|
13725
|
+
setExpandedPositions(/* @__PURE__ */ new Set());
|
|
13726
|
+
setAllExpanded(false);
|
|
13727
|
+
} else {
|
|
13728
|
+
setExpandedPositions(new Set(sortedPositions.map((p) => p.tokenName)));
|
|
13729
|
+
setAllExpanded(true);
|
|
13730
|
+
}
|
|
13731
|
+
};
|
|
13692
13732
|
const activeTabTotal = React5.useMemo(() => {
|
|
13693
13733
|
switch (activeTab) {
|
|
13694
13734
|
case "positions":
|
|
@@ -13769,7 +13809,90 @@ function PortfolioActivityPanel({
|
|
|
13769
13809
|
] }),
|
|
13770
13810
|
activeTab === "positions" && showPositionsTab && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
13771
13811
|
positions.length === 0 && /* @__PURE__ */ jsxRuntime.jsx(EmptyState, { children: "No positions yet. Subscribe to an offering or buy on the secondary market." }),
|
|
13772
|
-
positions.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
13812
|
+
positions.length > 0 && compactPositions && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
13813
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CToolbar, { children: [
|
|
13814
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CSortWrap, { children: [
|
|
13815
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CSortBtn, { onClick: () => setSortDropdownOpen((v) => !v), children: [
|
|
13816
|
+
"Sort by: ",
|
|
13817
|
+
sortKeyLabel(posSortKey),
|
|
13818
|
+
" \u25BE"
|
|
13819
|
+
] }),
|
|
13820
|
+
sortDropdownOpen && /* @__PURE__ */ jsxRuntime.jsx(CSortDropdown, { children: sortKeys.map((k) => /* @__PURE__ */ jsxRuntime.jsx(CSortOption, { $active: posSortKey === k, onClick: () => {
|
|
13821
|
+
setPosSortKey(k);
|
|
13822
|
+
setPosSortAsc(true);
|
|
13823
|
+
setSortDropdownOpen(false);
|
|
13824
|
+
}, children: sortKeyLabel(k) }, k)) })
|
|
13825
|
+
] }),
|
|
13826
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CToolbarActions, { children: [
|
|
13827
|
+
/* @__PURE__ */ jsxRuntime.jsx(CToolbarLink, { onClick: toggleExpandAll, children: allExpanded ? "Collapse All" : "Expand All" }),
|
|
13828
|
+
onClosePosition && /* @__PURE__ */ jsxRuntime.jsx(CToolbarLink, { onClick: () => setCloseAllOpen(true), children: "Sell All" })
|
|
13829
|
+
] })
|
|
13830
|
+
] }),
|
|
13831
|
+
pageSlice(sortedPositions).map((pos) => {
|
|
13832
|
+
const currentValue = pos.quantity * pos.marketPrice;
|
|
13833
|
+
const costBasis = pos.quantity * pos.averageEntryPrice;
|
|
13834
|
+
const pnl = pos.propertyPnl ?? currentValue - costBasis;
|
|
13835
|
+
const pnlPercent = pos.propertyPnlPercent ?? pos.percentChange ?? 0;
|
|
13836
|
+
const isPositive = pnl >= 0;
|
|
13837
|
+
const posExpanded = expandedPositions.has(pos.tokenName) || allExpanded;
|
|
13838
|
+
const ticker = pos.tokenName.toUpperCase().slice(0, 7);
|
|
13839
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
13840
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CRow, { $expanded: posExpanded, onClick: () => togglePosition(pos.tokenName), children: [
|
|
13841
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CAssetCell, { onClick: (e) => {
|
|
13842
|
+
e.stopPropagation();
|
|
13843
|
+
onPositionClick?.(pos.tokenName, pos.isIpoAllocation);
|
|
13844
|
+
}, children: [
|
|
13845
|
+
/* @__PURE__ */ jsxRuntime.jsx(CCellLabel, { children: "Asset" }),
|
|
13846
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CAssetName, { children: [
|
|
13847
|
+
pos.imageUrl && /* @__PURE__ */ jsxRuntime.jsx(CAssetLogo, { src: pos.imageUrl, alt: "" }),
|
|
13848
|
+
pos.tokenName
|
|
13849
|
+
] })
|
|
13850
|
+
] }),
|
|
13851
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CUnitsCell, { children: [
|
|
13852
|
+
/* @__PURE__ */ jsxRuntime.jsx(CCellLabel, { children: "Units" }),
|
|
13853
|
+
formatNumber2(pos.quantity, pos.quantity >= 100 ? 0 : 2),
|
|
13854
|
+
" ",
|
|
13855
|
+
ticker
|
|
13856
|
+
] }),
|
|
13857
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CPnlCell, { children: [
|
|
13858
|
+
/* @__PURE__ */ jsxRuntime.jsx(CCellLabel, { children: "PNL (%)" }),
|
|
13859
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CPnlValue, { $positive: isPositive, children: [
|
|
13860
|
+
isPositive ? "+" : "-",
|
|
13861
|
+
formatCurrency4(Math.abs(pnl))
|
|
13862
|
+
] }),
|
|
13863
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CPnlPct, { $positive: isPositive, children: [
|
|
13864
|
+
"(",
|
|
13865
|
+
isPositive ? "+" : "",
|
|
13866
|
+
pnlPercent.toFixed(1),
|
|
13867
|
+
"%)"
|
|
13868
|
+
] })
|
|
13869
|
+
] }),
|
|
13870
|
+
/* @__PURE__ */ jsxRuntime.jsx(CChevronWrap, { $open: posExpanded, children: /* @__PURE__ */ jsxRuntime.jsx("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "rgba(255,255,255,0.5)", strokeWidth: "2.5", strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ jsxRuntime.jsx("polyline", { points: "6 9 12 15 18 9" }) }) })
|
|
13871
|
+
] }),
|
|
13872
|
+
posExpanded && /* @__PURE__ */ jsxRuntime.jsxs(CExpandedWrap, { children: [
|
|
13873
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CDetailGrid, { children: [
|
|
13874
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CDetailItem, { children: [
|
|
13875
|
+
/* @__PURE__ */ jsxRuntime.jsx(CDLabel, { children: "Position Value" }),
|
|
13876
|
+
/* @__PURE__ */ jsxRuntime.jsx(CDValue, { children: formatCurrency4(currentValue, { minimumFractionDigits: 0, maximumFractionDigits: 0 }) })
|
|
13877
|
+
] }),
|
|
13878
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CDetailItem, { children: [
|
|
13879
|
+
/* @__PURE__ */ jsxRuntime.jsx(CDLabel, { children: "Avg Price" }),
|
|
13880
|
+
/* @__PURE__ */ jsxRuntime.jsx(CDValue, { children: formatCurrency4(pos.averageEntryPrice) })
|
|
13881
|
+
] }),
|
|
13882
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CDetailItem, { children: [
|
|
13883
|
+
/* @__PURE__ */ jsxRuntime.jsx(CDLabel, { children: "Current Price" }),
|
|
13884
|
+
/* @__PURE__ */ jsxRuntime.jsx(CDValue, { children: formatCurrency4(pos.marketPrice) })
|
|
13885
|
+
] })
|
|
13886
|
+
] }),
|
|
13887
|
+
onClosePosition && /* @__PURE__ */ jsxRuntime.jsxs(CActionRow, { children: [
|
|
13888
|
+
/* @__PURE__ */ jsxRuntime.jsx(CCloseBtn, { onClick: () => onClosePosition(pos.tokenName, "market", pos.quantity, pos.marketPrice), children: "Market Sell" }),
|
|
13889
|
+
/* @__PURE__ */ jsxRuntime.jsx(CCloseBtn, { onClick: () => onClosePosition(pos.tokenName, "limit", pos.quantity, pos.marketPrice), children: "Limit Sell" })
|
|
13890
|
+
] })
|
|
13891
|
+
] })
|
|
13892
|
+
] }, pos.tokenName);
|
|
13893
|
+
})
|
|
13894
|
+
] }),
|
|
13895
|
+
positions.length > 0 && !compactPositions && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
13773
13896
|
/* @__PURE__ */ jsxRuntime.jsxs(PositionsHeader, { $hasClose: !!onClosePosition, children: [
|
|
13774
13897
|
/* @__PURE__ */ jsxRuntime.jsxs(SortableHeaderCell, { $active: posSortKey === "asset", onClick: () => handlePosSort("asset"), children: [
|
|
13775
13898
|
"Asset ",
|
|
@@ -13839,29 +13962,29 @@ function PortfolioActivityPanel({
|
|
|
13839
13962
|
}, children: "Limit Sell" })
|
|
13840
13963
|
] }) })
|
|
13841
13964
|
] }, pos.tokenName);
|
|
13842
|
-
})
|
|
13843
|
-
|
|
13844
|
-
|
|
13845
|
-
|
|
13846
|
-
|
|
13847
|
-
|
|
13848
|
-
|
|
13849
|
-
|
|
13850
|
-
|
|
13851
|
-
|
|
13852
|
-
|
|
13853
|
-
|
|
13854
|
-
|
|
13855
|
-
|
|
13856
|
-
|
|
13857
|
-
|
|
13858
|
-
|
|
13859
|
-
|
|
13860
|
-
|
|
13861
|
-
|
|
13862
|
-
|
|
13863
|
-
] })
|
|
13864
|
-
] })
|
|
13965
|
+
})
|
|
13966
|
+
] }),
|
|
13967
|
+
positions.length > 0 && closeAllOpen && onClosePosition && /* @__PURE__ */ jsxRuntime.jsx(CloseAllOverlay, { onClick: () => setCloseAllOpen(false), children: /* @__PURE__ */ jsxRuntime.jsxs(CloseAllModal, { onClick: (e) => e.stopPropagation(), children: [
|
|
13968
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseAllModalX, { onClick: () => setCloseAllOpen(false), children: "\xD7" }),
|
|
13969
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseAllTitle, { children: "Confirm Sell All" }),
|
|
13970
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseAllDesc, { children: "This will sell all your positions and cancel their associated TP/SL orders." }),
|
|
13971
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CloseAllOption, { onClick: () => setCloseAllType("market"), children: [
|
|
13972
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseAllRadio, { $selected: closeAllType === "market" }),
|
|
13973
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { children: "Market Sell" })
|
|
13974
|
+
] }),
|
|
13975
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CloseAllOption, { onClick: () => setCloseAllType("limit"), children: [
|
|
13976
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseAllRadio, { $selected: closeAllType === "limit" }),
|
|
13977
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { children: "Limit Sell at Mid Price" })
|
|
13978
|
+
] }),
|
|
13979
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CloseAllConfirmBtn, { onClick: () => {
|
|
13980
|
+
positions.forEach((pos) => onClosePosition(pos.tokenName, closeAllType, pos.quantity, pos.marketPrice));
|
|
13981
|
+
setCloseAllOpen(false);
|
|
13982
|
+
}, children: [
|
|
13983
|
+
"Confirm ",
|
|
13984
|
+
closeAllType === "market" ? "Market" : "Limit",
|
|
13985
|
+
" Sell"
|
|
13986
|
+
] })
|
|
13987
|
+
] }) })
|
|
13865
13988
|
] }),
|
|
13866
13989
|
activeTab === "subscriptions" && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
13867
13990
|
offeringOrders.length === 0 && /* @__PURE__ */ jsxRuntime.jsx(EmptyState, { children: "IPO allocations will appear here once you subscribe." }),
|
|
@@ -14664,6 +14787,182 @@ var CloseAllConfirmBtn = styled9__default.default.button`
|
|
|
14664
14787
|
background: rgba(246, 70, 93, 0.25);
|
|
14665
14788
|
}
|
|
14666
14789
|
`;
|
|
14790
|
+
var CToolbar = styled9__default.default.div`
|
|
14791
|
+
display: flex;
|
|
14792
|
+
align-items: center;
|
|
14793
|
+
justify-content: space-between;
|
|
14794
|
+
padding: 0.3rem 0.6rem;
|
|
14795
|
+
border-bottom: 1px solid rgba(255, 255, 255, 0.04);
|
|
14796
|
+
`;
|
|
14797
|
+
var CSortWrap = styled9__default.default.div`
|
|
14798
|
+
position: relative;
|
|
14799
|
+
`;
|
|
14800
|
+
var CSortBtn = styled9__default.default.button`
|
|
14801
|
+
font-size: 0.6rem;
|
|
14802
|
+
color: rgba(255, 255, 255, 0.45);
|
|
14803
|
+
background: none;
|
|
14804
|
+
border: none;
|
|
14805
|
+
cursor: pointer;
|
|
14806
|
+
display: flex;
|
|
14807
|
+
align-items: center;
|
|
14808
|
+
gap: 0.2rem;
|
|
14809
|
+
&:hover { color: rgba(255, 255, 255, 0.7); }
|
|
14810
|
+
`;
|
|
14811
|
+
var CSortDropdown = styled9__default.default.div`
|
|
14812
|
+
position: absolute;
|
|
14813
|
+
top: 100%;
|
|
14814
|
+
left: 0;
|
|
14815
|
+
z-index: 10;
|
|
14816
|
+
margin-top: 2px;
|
|
14817
|
+
background: #1a1c24;
|
|
14818
|
+
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
14819
|
+
border-radius: 6px;
|
|
14820
|
+
overflow: hidden;
|
|
14821
|
+
min-width: 120px;
|
|
14822
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
|
|
14823
|
+
`;
|
|
14824
|
+
var CSortOption = styled9__default.default.button`
|
|
14825
|
+
display: block;
|
|
14826
|
+
width: 100%;
|
|
14827
|
+
padding: 0.4rem 0.6rem;
|
|
14828
|
+
font-size: 0.6rem;
|
|
14829
|
+
font-weight: ${(p) => p.$active ? 600 : 400};
|
|
14830
|
+
color: ${(p) => p.$active ? "#E6C87E" : "rgba(255, 255, 255, 0.6)"};
|
|
14831
|
+
background: ${(p) => p.$active ? "rgba(230, 200, 126, 0.06)" : "none"};
|
|
14832
|
+
border: none;
|
|
14833
|
+
text-align: left;
|
|
14834
|
+
cursor: pointer;
|
|
14835
|
+
&:hover { background: rgba(255, 255, 255, 0.05); }
|
|
14836
|
+
`;
|
|
14837
|
+
var CToolbarActions = styled9__default.default.div`
|
|
14838
|
+
display: flex;
|
|
14839
|
+
gap: 0.5rem;
|
|
14840
|
+
`;
|
|
14841
|
+
var CToolbarLink = styled9__default.default.button`
|
|
14842
|
+
font-size: 0.58rem;
|
|
14843
|
+
font-weight: 500;
|
|
14844
|
+
color: rgba(255, 255, 255, 0.45);
|
|
14845
|
+
background: none;
|
|
14846
|
+
border: none;
|
|
14847
|
+
cursor: pointer;
|
|
14848
|
+
text-decoration: underline;
|
|
14849
|
+
text-decoration-color: rgba(255, 255, 255, 0.15);
|
|
14850
|
+
&:hover { color: rgba(255, 255, 255, 0.7); }
|
|
14851
|
+
`;
|
|
14852
|
+
var CRow = styled9__default.default.button`
|
|
14853
|
+
display: grid;
|
|
14854
|
+
grid-template-columns: 1fr 1fr 1fr 24px;
|
|
14855
|
+
align-items: center;
|
|
14856
|
+
width: calc(100% - 1rem);
|
|
14857
|
+
margin: 0.25rem 0.5rem;
|
|
14858
|
+
margin-bottom: ${(p) => p.$expanded ? "0" : "0.25rem"};
|
|
14859
|
+
padding: 0.55rem 0.65rem;
|
|
14860
|
+
background: rgba(255, 255, 255, 0.035);
|
|
14861
|
+
border: 1px solid rgba(255, 255, 255, 0.06);
|
|
14862
|
+
border-bottom: ${(p) => p.$expanded ? "none" : "1px solid rgba(255, 255, 255, 0.06)"};
|
|
14863
|
+
border-radius: ${(p) => p.$expanded ? "8px 8px 0 0" : "8px"};
|
|
14864
|
+
cursor: pointer;
|
|
14865
|
+
text-align: left;
|
|
14866
|
+
transition: background 0.15s;
|
|
14867
|
+
outline: none;
|
|
14868
|
+
&:active { background: rgba(255, 255, 255, 0.06); }
|
|
14869
|
+
&:focus { outline: none; }
|
|
14870
|
+
&:focus-visible { outline: none; }
|
|
14871
|
+
`;
|
|
14872
|
+
var CCellLabel = styled9__default.default.div`
|
|
14873
|
+
font-size: 0.6rem;
|
|
14874
|
+
font-weight: 500;
|
|
14875
|
+
color: rgba(255, 255, 255, 0.3);
|
|
14876
|
+
margin-bottom: 1px;
|
|
14877
|
+
`;
|
|
14878
|
+
var CAssetCell = styled9__default.default.div``;
|
|
14879
|
+
var CAssetName = styled9__default.default.div`
|
|
14880
|
+
font-size: 0.85rem;
|
|
14881
|
+
font-weight: 600;
|
|
14882
|
+
color: #fff;
|
|
14883
|
+
display: flex;
|
|
14884
|
+
align-items: center;
|
|
14885
|
+
gap: 0.3rem;
|
|
14886
|
+
`;
|
|
14887
|
+
var CAssetLogo = styled9__default.default.img`
|
|
14888
|
+
width: 22px;
|
|
14889
|
+
height: 22px;
|
|
14890
|
+
border-radius: 4px;
|
|
14891
|
+
object-fit: cover;
|
|
14892
|
+
flex-shrink: 0;
|
|
14893
|
+
`;
|
|
14894
|
+
var CUnitsCell = styled9__default.default.div`
|
|
14895
|
+
font-size: 0.78rem;
|
|
14896
|
+
color: rgba(255, 255, 255, 0.8);
|
|
14897
|
+
font-variant-numeric: tabular-nums;
|
|
14898
|
+
`;
|
|
14899
|
+
var CPnlCell = styled9__default.default.div``;
|
|
14900
|
+
var CPnlValue = styled9__default.default.div`
|
|
14901
|
+
font-size: 0.78rem;
|
|
14902
|
+
font-weight: 600;
|
|
14903
|
+
color: ${(p) => p.$positive ? "#0ecb81" : "#f6465d"};
|
|
14904
|
+
font-variant-numeric: tabular-nums;
|
|
14905
|
+
`;
|
|
14906
|
+
var CPnlPct = styled9__default.default.div`
|
|
14907
|
+
font-size: 0.62rem;
|
|
14908
|
+
color: ${(p) => p.$positive ? "rgba(14, 203, 129, 0.65)" : "rgba(246, 70, 93, 0.65)"};
|
|
14909
|
+
margin-top: 1px;
|
|
14910
|
+
`;
|
|
14911
|
+
var CChevronWrap = styled9__default.default.span`
|
|
14912
|
+
display: flex;
|
|
14913
|
+
align-items: center;
|
|
14914
|
+
justify-content: center;
|
|
14915
|
+
transition: transform 0.2s;
|
|
14916
|
+
transform: rotate(${(p) => p.$open ? "180deg" : "0deg"});
|
|
14917
|
+
`;
|
|
14918
|
+
var CExpandedWrap = styled9__default.default.div`
|
|
14919
|
+
margin: 0 0.5rem 0.25rem;
|
|
14920
|
+
padding: 0.4rem 0.65rem 0.5rem;
|
|
14921
|
+
background: rgba(255, 255, 255, 0.035);
|
|
14922
|
+
border: 1px solid rgba(255, 255, 255, 0.06);
|
|
14923
|
+
border-top: none;
|
|
14924
|
+
border-radius: 0 0 8px 8px;
|
|
14925
|
+
`;
|
|
14926
|
+
var CDetailGrid = styled9__default.default.div`
|
|
14927
|
+
display: grid;
|
|
14928
|
+
grid-template-columns: 1fr 1fr 1fr 24px;
|
|
14929
|
+
gap: 0.45rem 0;
|
|
14930
|
+
`;
|
|
14931
|
+
var CDetailItem = styled9__default.default.div``;
|
|
14932
|
+
var CDLabel = styled9__default.default.div`
|
|
14933
|
+
font-size: 0.6rem;
|
|
14934
|
+
color: rgba(255, 255, 255, 0.3);
|
|
14935
|
+
margin-bottom: 1px;
|
|
14936
|
+
`;
|
|
14937
|
+
var CDValue = styled9__default.default.div`
|
|
14938
|
+
font-size: 0.78rem;
|
|
14939
|
+
font-weight: 500;
|
|
14940
|
+
color: rgba(255, 255, 255, 0.85);
|
|
14941
|
+
font-variant-numeric: tabular-nums;
|
|
14942
|
+
`;
|
|
14943
|
+
var CActionRow = styled9__default.default.div`
|
|
14944
|
+
display: grid;
|
|
14945
|
+
grid-template-columns: 1fr 1fr;
|
|
14946
|
+
gap: 0.5rem;
|
|
14947
|
+
margin-top: 0.5rem;
|
|
14948
|
+
`;
|
|
14949
|
+
var CCloseBtn = styled9__default.default.button`
|
|
14950
|
+
background: transparent;
|
|
14951
|
+
border: 1px solid rgba(230, 200, 126, 0.25);
|
|
14952
|
+
border-radius: 6px;
|
|
14953
|
+
padding: 0.45rem 0.6rem;
|
|
14954
|
+
font-size: 0.72rem;
|
|
14955
|
+
font-weight: 600;
|
|
14956
|
+
color: #E6C87E;
|
|
14957
|
+
cursor: pointer;
|
|
14958
|
+
white-space: nowrap;
|
|
14959
|
+
text-align: center;
|
|
14960
|
+
transition: all 0.15s ease;
|
|
14961
|
+
&:hover {
|
|
14962
|
+
background: rgba(230, 200, 126, 0.1);
|
|
14963
|
+
border-color: rgba(230, 200, 126, 0.5);
|
|
14964
|
+
}
|
|
14965
|
+
`;
|
|
14667
14966
|
function PropertyBuy({
|
|
14668
14967
|
propertyName = "Loaf Property",
|
|
14669
14968
|
propertyLocation: propertyLocationLabel = "Sydney, NSW",
|