@loafmarkets/ui 0.1.72 → 0.1.73
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 +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +27 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +27 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -978,10 +978,12 @@ type OfferingProgressCardProps = {
|
|
|
978
978
|
raisedAmount?: number;
|
|
979
979
|
targetAmount?: number;
|
|
980
980
|
isPrivateClient?: boolean;
|
|
981
|
+
/** "default" = full card with header/countdown, "compact" = bar-only (demo style) */
|
|
982
|
+
variant?: 'default' | 'compact';
|
|
981
983
|
style?: React__default.CSSProperties;
|
|
982
984
|
className?: string;
|
|
983
985
|
};
|
|
984
|
-
declare function OfferingProgressCard({ ipoStarted, statusLabel, statusColor, ipoStatus, tokenPrice, offeringValuation, percentSold, totalSold, supplyToSell, opensAt, subscriberCount, raisedAmount, targetAmount, isPrivateClient, style, className, }: OfferingProgressCardProps): react_jsx_runtime.JSX.Element;
|
|
986
|
+
declare function OfferingProgressCard({ ipoStarted, statusLabel, statusColor, ipoStatus, tokenPrice, offeringValuation, percentSold, totalSold, supplyToSell, opensAt, subscriberCount, raisedAmount, targetAmount, isPrivateClient, variant, style, className, }: OfferingProgressCardProps): react_jsx_runtime.JSX.Element;
|
|
985
987
|
|
|
986
988
|
type OwnerBookingProps = {
|
|
987
989
|
propertyName?: string | null;
|
package/dist/index.d.ts
CHANGED
|
@@ -978,10 +978,12 @@ type OfferingProgressCardProps = {
|
|
|
978
978
|
raisedAmount?: number;
|
|
979
979
|
targetAmount?: number;
|
|
980
980
|
isPrivateClient?: boolean;
|
|
981
|
+
/** "default" = full card with header/countdown, "compact" = bar-only (demo style) */
|
|
982
|
+
variant?: 'default' | 'compact';
|
|
981
983
|
style?: React__default.CSSProperties;
|
|
982
984
|
className?: string;
|
|
983
985
|
};
|
|
984
|
-
declare function OfferingProgressCard({ ipoStarted, statusLabel, statusColor, ipoStatus, tokenPrice, offeringValuation, percentSold, totalSold, supplyToSell, opensAt, subscriberCount, raisedAmount, targetAmount, isPrivateClient, style, className, }: OfferingProgressCardProps): react_jsx_runtime.JSX.Element;
|
|
986
|
+
declare function OfferingProgressCard({ ipoStarted, statusLabel, statusColor, ipoStatus, tokenPrice, offeringValuation, percentSold, totalSold, supplyToSell, opensAt, subscriberCount, raisedAmount, targetAmount, isPrivateClient, variant, style, className, }: OfferingProgressCardProps): react_jsx_runtime.JSX.Element;
|
|
985
987
|
|
|
986
988
|
type OwnerBookingProps = {
|
|
987
989
|
propertyName?: string | null;
|
package/dist/index.js
CHANGED
|
@@ -2979,7 +2979,7 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2979
2979
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2980
2980
|
"div",
|
|
2981
2981
|
{
|
|
2982
|
-
className: "
|
|
2982
|
+
className: cn("flex flex-1 flex-col overflow-hidden", isHomeVariant ? "mt-2 gap-0" : "mt-4 gap-3"),
|
|
2983
2983
|
style: !isPurchaseVariant && !isHomeVariant ? { minHeight: `${ITEMS_PER_PAGE * 86}px` } : void 0,
|
|
2984
2984
|
children: isPurchaseVariant ? purchaseItems.length > 0 ? purchaseItems.slice(0, 7).map((purchase, index) => {
|
|
2985
2985
|
const maxAmount = 6e4;
|
|
@@ -9672,6 +9672,7 @@ function OfferingProgressCard({
|
|
|
9672
9672
|
raisedAmount,
|
|
9673
9673
|
targetAmount,
|
|
9674
9674
|
isPrivateClient = false,
|
|
9675
|
+
variant = "default",
|
|
9675
9676
|
style,
|
|
9676
9677
|
className
|
|
9677
9678
|
}) {
|
|
@@ -9703,6 +9704,24 @@ function OfferingProgressCard({
|
|
|
9703
9704
|
const interval = setInterval(() => setCountdown(calculateCountdown()), 1e3);
|
|
9704
9705
|
return () => clearInterval(interval);
|
|
9705
9706
|
}, [opensAt]);
|
|
9707
|
+
if (variant === "compact") {
|
|
9708
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(CompactContainer, { style, className, children: [
|
|
9709
|
+
/* @__PURE__ */ jsxRuntime.jsx(ProgressBarOuter, { children: /* @__PURE__ */ jsxRuntime.jsx(ProgressBarInner, { style: { width: `${Math.min(percentSold, 100)}%` } }) }),
|
|
9710
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ProgressInfo, { children: [
|
|
9711
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ProgressSubscribers, { children: [
|
|
9712
|
+
"Subscribers: ",
|
|
9713
|
+
subscriberCount.toLocaleString()
|
|
9714
|
+
] }),
|
|
9715
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ProgressAmounts, { children: [
|
|
9716
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "raised", children: formatCurrency3(computedRaised) }),
|
|
9717
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "target", children: [
|
|
9718
|
+
" / ",
|
|
9719
|
+
formatCurrency3(computedTarget)
|
|
9720
|
+
] })
|
|
9721
|
+
] })
|
|
9722
|
+
] })
|
|
9723
|
+
] });
|
|
9724
|
+
}
|
|
9706
9725
|
return /* @__PURE__ */ jsxRuntime.jsxs(Container, { style, className, children: [
|
|
9707
9726
|
/* @__PURE__ */ jsxRuntime.jsxs(Header2, { children: [
|
|
9708
9727
|
/* @__PURE__ */ jsxRuntime.jsxs("h3", { children: [
|
|
@@ -10004,6 +10023,13 @@ var ProgressAmounts = styled25__default.default.div`
|
|
|
10004
10023
|
.raised { color: #D4AF37; }
|
|
10005
10024
|
.target { color: rgba(255,255,255,0.3); }
|
|
10006
10025
|
`;
|
|
10026
|
+
var CompactContainer = styled25__default.default.div`
|
|
10027
|
+
width: 100%;
|
|
10028
|
+
margin: 1.5rem 0;
|
|
10029
|
+
display: flex;
|
|
10030
|
+
flex-direction: column;
|
|
10031
|
+
gap: 0.5rem;
|
|
10032
|
+
`;
|
|
10007
10033
|
var MAX_DISPLAY_AMOUNT = 6e4;
|
|
10008
10034
|
var formatCurrency4 = (amount) => {
|
|
10009
10035
|
if (amount >= 1e6) return `$${(amount / 1e6).toFixed(2)}M`;
|