@algenium/blocks 1.11.0 → 1.13.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.cjs +36 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +36 -8
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3689,7 +3689,23 @@ function TenantAvatar({
|
|
|
3689
3689
|
}
|
|
3690
3690
|
);
|
|
3691
3691
|
}
|
|
3692
|
-
function SwitcherSkeleton({
|
|
3692
|
+
function SwitcherSkeleton({
|
|
3693
|
+
className,
|
|
3694
|
+
collapsed = false
|
|
3695
|
+
}) {
|
|
3696
|
+
if (collapsed) {
|
|
3697
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3698
|
+
"div",
|
|
3699
|
+
{
|
|
3700
|
+
"data-testid": "org-switcher-skeleton",
|
|
3701
|
+
className: cn(
|
|
3702
|
+
"pointer-events-none flex size-8 items-center justify-center rounded-md",
|
|
3703
|
+
className
|
|
3704
|
+
),
|
|
3705
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "size-8 shrink-0 animate-pulse rounded-lg bg-muted" })
|
|
3706
|
+
}
|
|
3707
|
+
);
|
|
3708
|
+
}
|
|
3693
3709
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3694
3710
|
"div",
|
|
3695
3711
|
{
|
|
@@ -3710,6 +3726,7 @@ function SwitcherSkeleton({ className }) {
|
|
|
3710
3726
|
);
|
|
3711
3727
|
}
|
|
3712
3728
|
var triggerClassName = "flex h-12 min-h-12 w-full items-center gap-2 rounded-md px-2 text-left text-sm outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:ring-2 focus-visible:ring-ring data-[state=open]:bg-accent data-[state=open]:text-accent-foreground";
|
|
3729
|
+
var collapsedTriggerClassName = "size-8 min-h-0 h-8 w-8 justify-center gap-0 p-0 px-0";
|
|
3713
3730
|
function OrgSwitcher({
|
|
3714
3731
|
activeTenant,
|
|
3715
3732
|
tenants,
|
|
@@ -3725,7 +3742,7 @@ function OrgSwitcher({
|
|
|
3725
3742
|
}) {
|
|
3726
3743
|
const labels = { ...defaultLabels2, ...userLabels };
|
|
3727
3744
|
if (isLoading) {
|
|
3728
|
-
return /* @__PURE__ */ jsxRuntime.jsx(SwitcherSkeleton, { className });
|
|
3745
|
+
return /* @__PURE__ */ jsxRuntime.jsx(SwitcherSkeleton, { className, collapsed });
|
|
3729
3746
|
}
|
|
3730
3747
|
if (!activeTenant) {
|
|
3731
3748
|
if (createUrl) {
|
|
@@ -3734,10 +3751,15 @@ function OrgSwitcher({
|
|
|
3734
3751
|
{
|
|
3735
3752
|
href: createUrl,
|
|
3736
3753
|
"data-testid": "org-switcher-empty",
|
|
3737
|
-
className: cn(
|
|
3754
|
+
className: cn(
|
|
3755
|
+
triggerClassName,
|
|
3756
|
+
collapsed && collapsedTriggerClassName,
|
|
3757
|
+
className,
|
|
3758
|
+
triggerClassNameProp
|
|
3759
|
+
),
|
|
3738
3760
|
children: [
|
|
3739
3761
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex size-8 items-center justify-center rounded-lg bg-muted", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Building2, { className: "size-4 text-muted-foreground" }) }),
|
|
3740
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid min-w-0 flex-1 text-left leading-tight", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate font-medium", children: labels.empty }) })
|
|
3762
|
+
!collapsed ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid min-w-0 flex-1 text-left leading-tight", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate font-medium", children: labels.empty }) }) : null
|
|
3741
3763
|
]
|
|
3742
3764
|
}
|
|
3743
3765
|
);
|
|
@@ -3746,10 +3768,15 @@ function OrgSwitcher({
|
|
|
3746
3768
|
"div",
|
|
3747
3769
|
{
|
|
3748
3770
|
"data-testid": "org-switcher-empty",
|
|
3749
|
-
className: cn(
|
|
3771
|
+
className: cn(
|
|
3772
|
+
triggerClassName,
|
|
3773
|
+
"pointer-events-none",
|
|
3774
|
+
collapsed && collapsedTriggerClassName,
|
|
3775
|
+
className
|
|
3776
|
+
),
|
|
3750
3777
|
children: [
|
|
3751
3778
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex size-8 items-center justify-center rounded-lg bg-muted", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Building2, { className: "size-4 text-muted-foreground" }) }),
|
|
3752
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid min-w-0 flex-1 text-left leading-tight", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate font-medium text-muted-foreground", children: labels.empty }) })
|
|
3779
|
+
!collapsed ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid min-w-0 flex-1 text-left leading-tight", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate font-medium text-muted-foreground", children: labels.empty }) }) : null
|
|
3753
3780
|
]
|
|
3754
3781
|
}
|
|
3755
3782
|
);
|
|
@@ -3764,6 +3791,7 @@ function OrgSwitcher({
|
|
|
3764
3791
|
className: cn(
|
|
3765
3792
|
triggerClassName,
|
|
3766
3793
|
"h-auto justify-start font-normal",
|
|
3794
|
+
collapsed && collapsedTriggerClassName,
|
|
3767
3795
|
className,
|
|
3768
3796
|
triggerClassNameProp
|
|
3769
3797
|
),
|
|
@@ -8486,7 +8514,7 @@ var sizeClasses4 = {
|
|
|
8486
8514
|
padding: "px-2 py-0.5"
|
|
8487
8515
|
}
|
|
8488
8516
|
};
|
|
8489
|
-
function
|
|
8517
|
+
function VerifiedProfessionalBadge({
|
|
8490
8518
|
status,
|
|
8491
8519
|
size = "md",
|
|
8492
8520
|
showLabel = false,
|
|
@@ -8612,7 +8640,7 @@ exports.TooltipProvider = TooltipProvider;
|
|
|
8612
8640
|
exports.TooltipTrigger = TooltipTrigger;
|
|
8613
8641
|
exports.USAddressInput = USAddressInput;
|
|
8614
8642
|
exports.UpcomingEvents = UpcomingEvents;
|
|
8615
|
-
exports.
|
|
8643
|
+
exports.VerifiedProfessionalBadge = VerifiedProfessionalBadge;
|
|
8616
8644
|
exports.buttonVariants = buttonVariants;
|
|
8617
8645
|
exports.cn = cn;
|
|
8618
8646
|
exports.defaultLanguages = defaultLanguages;
|