@carlonicora/nextjs-jsonapi 1.36.1 → 1.38.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/{BlockNoteEditor-4MDHRUS2.js → BlockNoteEditor-3S2B36O3.js} +15 -15
- package/dist/{BlockNoteEditor-4MDHRUS2.js.map → BlockNoteEditor-3S2B36O3.js.map} +1 -1
- package/dist/{BlockNoteEditor-SZWO3MDO.mjs → BlockNoteEditor-WQUJTVJL.mjs} +5 -5
- package/dist/BlockNoteEditor-WQUJTVJL.mjs.map +1 -0
- package/dist/billing/index.d.mts +15 -5
- package/dist/billing/index.d.ts +15 -5
- package/dist/billing/index.js +750 -520
- package/dist/billing/index.js.map +1 -1
- package/dist/billing/index.mjs +665 -435
- package/dist/billing/index.mjs.map +1 -1
- package/dist/{chunk-53IPQJVH.js → chunk-3EZX4G2E.js} +147 -23
- package/dist/chunk-3EZX4G2E.js.map +1 -0
- package/dist/{chunk-I7DFEJFF.mjs → chunk-4PHADEKA.mjs} +738 -1418
- package/dist/chunk-4PHADEKA.mjs.map +1 -0
- package/dist/{chunk-E6PQQTWF.js → chunk-T2JCZYWK.js} +999 -1679
- package/dist/chunk-T2JCZYWK.js.map +1 -0
- package/dist/{chunk-P7R2DPD6.mjs → chunk-TQ5GRRTM.mjs} +125 -1
- package/dist/chunk-TQ5GRRTM.mjs.map +1 -0
- package/dist/client/index.js +3 -3
- package/dist/client/index.mjs +2 -2
- package/dist/components/index.d.mts +23 -8
- package/dist/components/index.d.ts +23 -8
- package/dist/components/index.js +3 -3
- package/dist/components/index.mjs +2 -2
- package/dist/contexts/index.d.mts +1 -1
- package/dist/contexts/index.d.ts +1 -1
- package/dist/contexts/index.js +3 -3
- package/dist/contexts/index.mjs +2 -2
- package/dist/core/index.d.mts +47 -3
- package/dist/core/index.d.ts +47 -3
- package/dist/core/index.js +8 -2
- package/dist/core/index.js.map +1 -1
- package/dist/core/index.mjs +7 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +8 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -1
- package/dist/server/index.js +3 -3
- package/dist/server/index.mjs +1 -1
- package/dist/{stripe-subscription.interface-DK7BJaNd.d.ts → stripe-promotion-code.interface-BcJty0rv.d.ts} +18 -1
- package/dist/{stripe-subscription.interface-C8uhCYIZ.d.mts → stripe-promotion-code.interface-Dnm2DJKQ.d.mts} +18 -1
- package/dist/testing/index.js.map +1 -1
- package/dist/testing/index.mjs.map +1 -1
- package/package.json +2 -2
- package/src/billing/index.ts +1 -0
- package/src/client/context/JsonApiProvider.tsx +1 -5
- package/src/client/hooks/__tests__/useJsonApiGet.test.tsx +9 -9
- package/src/client/hooks/__tests__/useJsonApiMutation.test.tsx +11 -11
- package/src/client/hooks/__tests__/useRehydration.test.ts +13 -34
- package/src/components/editors/BlockNoteEditor.tsx +2 -2
- package/src/components/forms/CommonEditorTrigger.tsx +1 -1
- package/src/components/forms/FormCheckbox.tsx +2 -12
- package/src/components/forms/FormDate.tsx +1 -6
- package/src/components/forms/FormInput.tsx +1 -1
- package/src/components/forms/FormPassword.tsx +1 -7
- package/src/components/forms/FormSelect.tsx +2 -8
- package/src/components/forms/FormSlider.tsx +1 -5
- package/src/components/forms/FormSwitch.tsx +1 -5
- package/src/components/forms/GdprConsentCheckbox.tsx +2 -8
- package/src/components/forms/PasswordInput.tsx +28 -26
- package/src/components/forms/__tests__/FormCheckbox.test.tsx +16 -18
- package/src/components/forms/__tests__/FormDate.test.tsx +14 -30
- package/src/components/forms/__tests__/FormInput.test.tsx +21 -37
- package/src/components/forms/__tests__/FormSelect.test.tsx +15 -21
- package/src/components/tables/ContentListTable.tsx +1 -1
- package/src/components/tables/__tests__/ContentListTable.test.tsx +17 -89
- package/src/components/tables/cells/cell.component.tsx +1 -1
- package/src/contexts/HeaderChildrenContext.tsx +3 -1
- package/src/core/endpoint/__tests__/EndpointCreator.test.ts +2 -7
- package/src/core/factories/__tests__/JsonApiDataFactory.test.ts +3 -3
- package/src/core/factories/__tests__/RehydrationFactory.test.ts +4 -6
- package/src/core/index.ts +1 -0
- package/src/core/registry/ModuleRegistry.ts +1 -0
- package/src/core/registry/__tests__/DataClassRegistry.test.ts +5 -15
- package/src/core/registry/__tests__/ModuleRegistrar.test.ts +5 -15
- package/src/features/auth/components/GdprConsentSection.tsx +1 -6
- package/src/features/auth/components/details/LandingComponent.tsx +6 -1
- package/src/features/auth/components/forms/AcceptInvitation.tsx +1 -1
- package/src/features/auth/components/forms/ResetPassword.tsx +1 -1
- package/src/features/billing/components/cards/PaymentMethodSummaryCard.tsx +13 -18
- package/src/features/billing/components/cards/SubscriptionSummaryCard.tsx +12 -17
- package/src/features/billing/components/modals/BillingDetailModal.tsx +2 -13
- package/src/features/billing/stripe-customer/components/details/PaymentMethodCard.tsx +8 -1
- package/src/features/billing/stripe-customer/components/forms/PaymentMethodEditor.tsx +2 -13
- package/src/features/billing/stripe-customer/components/forms/PaymentMethodForm.tsx +2 -12
- package/src/features/billing/stripe-invoice/components/details/InvoiceDetails.tsx +6 -1
- package/src/features/billing/stripe-invoice/data/stripe-invoice.interface.ts +1 -0
- package/src/features/billing/stripe-price/components/lists/PricesList.tsx +13 -5
- package/src/features/billing/stripe-product/components/lists/ProductsList.tsx +5 -5
- package/src/features/billing/stripe-promotion-code/components/PromoCodeInput.tsx +108 -0
- package/src/features/billing/stripe-promotion-code/components/index.ts +1 -0
- package/src/features/billing/stripe-promotion-code/data/index.ts +3 -0
- package/src/features/billing/stripe-promotion-code/data/stripe-promotion-code.interface.ts +14 -0
- package/src/features/billing/stripe-promotion-code/data/stripe-promotion-code.service.ts +64 -0
- package/src/features/billing/stripe-promotion-code/data/stripe-promotion-code.ts +66 -0
- package/src/features/billing/stripe-promotion-code/index.ts +2 -0
- package/src/features/billing/stripe-promotion-code/stripe-promotion-code.module.ts +9 -0
- package/src/features/billing/stripe-subscription/components/containers/SubscriptionsContainer.tsx +1 -3
- package/src/features/billing/stripe-subscription/components/details/SubscriptionDetails.tsx +4 -1
- package/src/features/billing/stripe-subscription/components/forms/CancelSubscriptionDialog.tsx +1 -1
- package/src/features/billing/stripe-subscription/components/lists/SubscriptionsList.tsx +24 -4
- package/src/features/billing/stripe-subscription/components/widgets/PricingCard.tsx +9 -2
- package/src/features/billing/stripe-subscription/components/widgets/SubscriptionStatusBadge.tsx +3 -1
- package/src/features/billing/stripe-subscription/components/wizards/SubscriptionWizard.tsx +7 -7
- package/src/features/billing/stripe-subscription/components/wizards/WizardProgressIndicator.tsx +2 -10
- package/src/features/billing/stripe-subscription/components/wizards/WizardStepPaymentMethod.tsx +3 -13
- package/src/features/billing/stripe-subscription/components/wizards/WizardStepReview.tsx +134 -23
- package/src/features/billing/stripe-subscription/data/stripe-subscription.interface.ts +2 -0
- package/src/features/billing/stripe-subscription/data/stripe-subscription.ts +8 -0
- package/src/features/billing/stripe-subscription/hooks/useSubscriptionWizard.ts +93 -7
- package/src/features/billing/stripe-usage/components/details/UsageSummaryCard.tsx +1 -1
- package/src/features/billing/stripe-usage/components/lists/UsageHistoryTable.tsx +1 -1
- package/src/features/company/components/details/CompanyDetails.tsx +2 -2
- package/src/features/company/components/forms/CompanyConfigurationSecurityForm.tsx +1 -1
- package/src/features/index.ts +1 -0
- package/src/features/notification/components/containers/NotificationsListContainer.tsx +1 -1
- package/src/features/notification/components/modals/NotificationModal.tsx +6 -2
- package/src/features/notification/contexts/NotificationContext.tsx +1 -3
- package/src/features/oauth/components/OAuthClientCard.tsx +15 -17
- package/src/features/oauth/components/OAuthClientDetail.tsx +7 -19
- package/src/features/oauth/components/OAuthClientForm.tsx +4 -13
- package/src/features/oauth/components/OAuthClientSecretDisplay.tsx +4 -20
- package/src/features/oauth/components/OAuthRedirectUriInput.tsx +5 -12
- package/src/features/oauth/components/OAuthScopeSelector.tsx +17 -23
- package/src/features/oauth/components/consent/OAuthConsentActions.tsx +3 -16
- package/src/features/oauth/components/consent/OAuthConsentHeader.tsx +3 -12
- package/src/features/oauth/components/consent/OAuthConsentScreen.tsx +5 -20
- package/src/features/oauth/components/consent/OAuthScopeList.tsx +3 -18
- package/src/features/onboarding/contexts/OnboardingContext.tsx +3 -3
- package/src/features/role/components/forms/FormRoles.tsx +1 -7
- package/src/features/user/components/containers/UserContainer.tsx +1 -1
- package/src/features/user/components/details/UserDetails.tsx +1 -1
- package/src/features/user/components/forms/UserDeleter.tsx +1 -1
- package/src/features/user/components/forms/UserEditor.tsx +1 -1
- package/src/features/user/components/forms/UserMultiSelect.tsx +7 -7
- package/src/features/user/components/lists/UserListInAdd.tsx +2 -2
- package/src/features/user/components/lists/UsersList.tsx +7 -1
- package/src/features/user/contexts/CurrentUserContext.tsx +36 -33
- package/src/hooks/__tests__/useDataListRetriever.test.ts +15 -21
- package/src/hooks/__tests__/useDebounce.test.ts +2 -7
- package/src/hooks/useCustomD3Graph.tsx +2 -2
- package/src/shadcnui/custom/multi-select.tsx +28 -2
- package/src/shadcnui/ui/accordion.tsx +21 -23
- package/src/shadcnui/ui/alert-dialog.tsx +45 -62
- package/src/shadcnui/ui/alert.tsx +25 -41
- package/src/shadcnui/ui/avatar.tsx +23 -36
- package/src/shadcnui/ui/badge.tsx +13 -11
- package/src/shadcnui/ui/breadcrumb.tsx +21 -55
- package/src/shadcnui/ui/button.tsx +17 -18
- package/src/shadcnui/ui/calendar.tsx +44 -93
- package/src/shadcnui/ui/carousel.tsx +72 -100
- package/src/shadcnui/ui/chart.tsx +102 -161
- package/src/shadcnui/ui/checkbox.tsx +8 -9
- package/src/shadcnui/ui/combobox.tsx +52 -83
- package/src/shadcnui/ui/command.tsx +43 -77
- package/src/shadcnui/ui/context-menu.tsx +47 -86
- package/src/shadcnui/ui/dialog.tsx +34 -60
- package/src/shadcnui/ui/drawer.tsx +32 -53
- package/src/shadcnui/ui/dropdown-menu.tsx +48 -65
- package/src/shadcnui/ui/field.tsx +39 -48
- package/src/shadcnui/ui/hover-card.tsx +9 -14
- package/src/shadcnui/ui/input-group.tsx +44 -55
- package/src/shadcnui/ui/input-otp.tsx +22 -26
- package/src/shadcnui/ui/input.tsx +6 -6
- package/src/shadcnui/ui/label.tsx +6 -6
- package/src/shadcnui/ui/navigation-menu.tsx +36 -60
- package/src/shadcnui/ui/popover.tsx +15 -38
- package/src/shadcnui/ui/progress.tsx +12 -29
- package/src/shadcnui/ui/radio-group.tsx +9 -15
- package/src/shadcnui/ui/resizable.tsx +14 -24
- package/src/shadcnui/ui/scroll-area.tsx +12 -27
- package/src/shadcnui/ui/select.tsx +41 -65
- package/src/shadcnui/ui/separator.tsx +7 -11
- package/src/shadcnui/ui/sheet.tsx +30 -55
- package/src/shadcnui/ui/sidebar.tsx +141 -189
- package/src/shadcnui/ui/skeleton.tsx +3 -9
- package/src/shadcnui/ui/slider.tsx +11 -23
- package/src/shadcnui/ui/switch.tsx +8 -8
- package/src/shadcnui/ui/tabs.tsx +14 -21
- package/src/shadcnui/ui/textarea.tsx +5 -5
- package/src/shadcnui/ui/toggle.tsx +8 -14
- package/src/shadcnui/ui/tooltip.tsx +11 -23
- package/src/testing/providers/MockJsonApiProvider.tsx +1 -5
- package/src/testing/utils/renderWithProviders.tsx +6 -10
- package/dist/BlockNoteEditor-SZWO3MDO.mjs.map +0 -1
- package/dist/chunk-53IPQJVH.js.map +0 -1
- package/dist/chunk-E6PQQTWF.js.map +0 -1
- package/dist/chunk-I7DFEJFF.mjs.map +0 -1
- package/dist/chunk-P7R2DPD6.mjs.map +0 -1
|
@@ -41,7 +41,7 @@ import {
|
|
|
41
41
|
showToast,
|
|
42
42
|
useComposedRefs,
|
|
43
43
|
useIsMobile
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-TQ5GRRTM.mjs";
|
|
45
45
|
import {
|
|
46
46
|
JsonApiContext
|
|
47
47
|
} from "./chunk-VOXD3ZLY.mjs";
|
|
@@ -66,7 +66,7 @@ function useHeaderChildren() {
|
|
|
66
66
|
__name(useHeaderChildren, "useHeaderChildren");
|
|
67
67
|
|
|
68
68
|
// src/components/navigations/Breadcrumb.tsx
|
|
69
|
-
import { useTranslations as
|
|
69
|
+
import { useTranslations as useTranslations38 } from "next-intl";
|
|
70
70
|
import { Fragment as Fragment12, useState as useState34 } from "react";
|
|
71
71
|
|
|
72
72
|
// src/hooks/TableGeneratorRegistry.ts
|
|
@@ -645,7 +645,7 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, loadingNode
|
|
|
645
645
|
childNode.y = height / 2 + childDistanceFromRoot * Math.sin(angle);
|
|
646
646
|
}
|
|
647
647
|
});
|
|
648
|
-
for (const [
|
|
648
|
+
for (const [_nodeId, node2] of nodeHierarchy.entries()) {
|
|
649
649
|
if (node2.depth === 1 && node2.angle !== void 0 && node2.x !== void 0 && node2.y !== void 0) {
|
|
650
650
|
const childAngle = node2.angle;
|
|
651
651
|
const childX = node2.x;
|
|
@@ -781,7 +781,7 @@ function useCustomD3Graph(nodes, links, onNodeClick, visibleNodeIds, loadingNode
|
|
|
781
781
|
if (d.icon) {
|
|
782
782
|
const Icon = d.icon;
|
|
783
783
|
const iconSvg = renderToStaticMarkup(/* @__PURE__ */ jsx2(Icon, { size: nodeRadius / 2, color: "white" }));
|
|
784
|
-
const
|
|
784
|
+
const _iconGroup = d3.select(this).append("g").html(iconSvg).attr("transform", `translate(${-nodeRadius / 4}, ${-nodeRadius / 4})`).style("pointer-events", "all").on("click", (event) => {
|
|
785
785
|
event.stopPropagation();
|
|
786
786
|
onNodeClick(d.id);
|
|
787
787
|
});
|
|
@@ -886,7 +886,7 @@ __name(useCustomD3Graph, "useCustomD3Graph");
|
|
|
886
886
|
import { useEffect as useEffect24 } from "react";
|
|
887
887
|
|
|
888
888
|
// src/features/company/contexts/CompanyContext.tsx
|
|
889
|
-
import { useTranslations as
|
|
889
|
+
import { useTranslations as useTranslations33 } from "next-intl";
|
|
890
890
|
import { createContext as createContext10, useContext as useContext11, useState as useState28 } from "react";
|
|
891
891
|
|
|
892
892
|
// src/features/user/contexts/CurrentUserContext.tsx
|
|
@@ -951,7 +951,7 @@ var CurrentUserProvider = /* @__PURE__ */ __name(({ children }) => {
|
|
|
951
951
|
const token = getCookie("token");
|
|
952
952
|
if (!token && dehydratedUser) setDehydratedUser(null);
|
|
953
953
|
}, [dehydratedUser, setDehydratedUser]);
|
|
954
|
-
const matchUrlToModule = /* @__PURE__ */ __name((
|
|
954
|
+
const matchUrlToModule = /* @__PURE__ */ __name((_params) => {
|
|
955
955
|
const moduleKeys = Object.getOwnPropertyNames(Modules).filter(
|
|
956
956
|
(key) => key !== "prototype" && key !== "_factory" && key !== "length" && key !== "name"
|
|
957
957
|
);
|
|
@@ -1004,36 +1004,39 @@ var CurrentUserProvider = /* @__PURE__ */ __name(({ children }) => {
|
|
|
1004
1004
|
}
|
|
1005
1005
|
__name(hasPermissionToPath, "hasPermissionToPath");
|
|
1006
1006
|
const [isRefreshing, setIsRefreshing] = useState2(false);
|
|
1007
|
-
const refreshUser = useCallback5(
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1007
|
+
const refreshUser = useCallback5(
|
|
1008
|
+
async (options) => {
|
|
1009
|
+
if (isRefreshing) {
|
|
1010
|
+
return;
|
|
1011
|
+
}
|
|
1012
|
+
setIsRefreshing(true);
|
|
1013
|
+
try {
|
|
1014
|
+
const fullUser = await UserService.findFullUser();
|
|
1015
|
+
if (fullUser) {
|
|
1016
|
+
const dehydrated = fullUser.dehydrate();
|
|
1017
|
+
setDehydratedUser(dehydrated);
|
|
1018
|
+
setUser(fullUser);
|
|
1019
|
+
if (!options?.skipCookieUpdate) {
|
|
1020
|
+
await getTokenHandler()?.updateToken({
|
|
1021
|
+
userId: fullUser.id,
|
|
1022
|
+
companyId: fullUser.company?.id,
|
|
1023
|
+
roles: fullUser.roles.map((role) => role.id),
|
|
1024
|
+
features: fullUser.company?.features?.map((feature) => feature.id) ?? [],
|
|
1025
|
+
modules: fullUser.modules.map((module) => ({
|
|
1026
|
+
id: module.id,
|
|
1027
|
+
permissions: module.permissions
|
|
1028
|
+
}))
|
|
1029
|
+
});
|
|
1030
|
+
}
|
|
1029
1031
|
}
|
|
1032
|
+
} catch (error) {
|
|
1033
|
+
console.error("Failed to refresh user data:", error);
|
|
1034
|
+
} finally {
|
|
1035
|
+
setIsRefreshing(false);
|
|
1030
1036
|
}
|
|
1031
|
-
}
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
setIsRefreshing(false);
|
|
1035
|
-
}
|
|
1036
|
-
}, [isRefreshing, setDehydratedUser]);
|
|
1037
|
+
},
|
|
1038
|
+
[isRefreshing, setDehydratedUser]
|
|
1039
|
+
);
|
|
1037
1040
|
const { socket, isConnected } = useSocketContext();
|
|
1038
1041
|
const refreshUserRef = useRef4(refreshUser);
|
|
1039
1042
|
refreshUserRef.current = refreshUser;
|
|
@@ -1087,7 +1090,7 @@ function useCurrentUserContext() {
|
|
|
1087
1090
|
__name(useCurrentUserContext, "useCurrentUserContext");
|
|
1088
1091
|
|
|
1089
1092
|
// src/features/user/contexts/UserContext.tsx
|
|
1090
|
-
import { useTranslations as
|
|
1093
|
+
import { useTranslations as useTranslations16 } from "next-intl";
|
|
1091
1094
|
import { createContext as createContext9, useContext as useContext10, useState as useState24 } from "react";
|
|
1092
1095
|
|
|
1093
1096
|
// src/features/user/components/forms/RoleUserAdd.tsx
|
|
@@ -1196,11 +1199,7 @@ function AccordionItem({ className, ...props }) {
|
|
|
1196
1199
|
);
|
|
1197
1200
|
}
|
|
1198
1201
|
__name(AccordionItem, "AccordionItem");
|
|
1199
|
-
function AccordionTrigger({
|
|
1200
|
-
className,
|
|
1201
|
-
children,
|
|
1202
|
-
...props
|
|
1203
|
-
}) {
|
|
1202
|
+
function AccordionTrigger({ className, children, ...props }) {
|
|
1204
1203
|
return /* @__PURE__ */ jsx6(AccordionPrimitive.Header, { className: "flex", children: /* @__PURE__ */ jsxs2(
|
|
1205
1204
|
AccordionPrimitive.Trigger,
|
|
1206
1205
|
{
|
|
@@ -1212,18 +1211,26 @@ function AccordionTrigger({
|
|
|
1212
1211
|
...props,
|
|
1213
1212
|
children: [
|
|
1214
1213
|
children,
|
|
1215
|
-
/* @__PURE__ */ jsx6(
|
|
1216
|
-
|
|
1214
|
+
/* @__PURE__ */ jsx6(
|
|
1215
|
+
ChevronDownIcon,
|
|
1216
|
+
{
|
|
1217
|
+
"data-slot": "accordion-trigger-icon",
|
|
1218
|
+
className: "pointer-events-none shrink-0 group-aria-expanded/accordion-trigger:hidden"
|
|
1219
|
+
}
|
|
1220
|
+
),
|
|
1221
|
+
/* @__PURE__ */ jsx6(
|
|
1222
|
+
ChevronUpIcon,
|
|
1223
|
+
{
|
|
1224
|
+
"data-slot": "accordion-trigger-icon",
|
|
1225
|
+
className: "pointer-events-none hidden shrink-0 group-aria-expanded/accordion-trigger:inline"
|
|
1226
|
+
}
|
|
1227
|
+
)
|
|
1217
1228
|
]
|
|
1218
1229
|
}
|
|
1219
1230
|
) });
|
|
1220
1231
|
}
|
|
1221
1232
|
__name(AccordionTrigger, "AccordionTrigger");
|
|
1222
|
-
function AccordionContent({
|
|
1223
|
-
className,
|
|
1224
|
-
children,
|
|
1225
|
-
...props
|
|
1226
|
-
}) {
|
|
1233
|
+
function AccordionContent({ className, children, ...props }) {
|
|
1227
1234
|
return /* @__PURE__ */ jsx6(
|
|
1228
1235
|
AccordionPrimitive.Panel,
|
|
1229
1236
|
{
|
|
@@ -1248,31 +1255,22 @@ __name(AccordionContent, "AccordionContent");
|
|
|
1248
1255
|
// src/shadcnui/ui/alert.tsx
|
|
1249
1256
|
import { cva } from "class-variance-authority";
|
|
1250
1257
|
import { jsx as jsx7 } from "react/jsx-runtime";
|
|
1251
|
-
var alertVariants = cva(
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1258
|
+
var alertVariants = cva(
|
|
1259
|
+
"grid gap-0.5 rounded-lg border px-2 py-1.5 text-left text-xs/relaxed has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-1.5 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-3.5 w-full relative group/alert",
|
|
1260
|
+
{
|
|
1261
|
+
variants: {
|
|
1262
|
+
variant: {
|
|
1263
|
+
default: "bg-card text-card-foreground",
|
|
1264
|
+
destructive: "text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
|
|
1265
|
+
}
|
|
1266
|
+
},
|
|
1267
|
+
defaultVariants: {
|
|
1268
|
+
variant: "default"
|
|
1256
1269
|
}
|
|
1257
|
-
},
|
|
1258
|
-
defaultVariants: {
|
|
1259
|
-
variant: "default"
|
|
1260
1270
|
}
|
|
1261
|
-
|
|
1262
|
-
function Alert({
|
|
1263
|
-
className,
|
|
1264
|
-
variant,
|
|
1265
|
-
...props
|
|
1266
|
-
}) {
|
|
1267
|
-
return /* @__PURE__ */ jsx7(
|
|
1268
|
-
"div",
|
|
1269
|
-
{
|
|
1270
|
-
"data-slot": "alert",
|
|
1271
|
-
role: "alert",
|
|
1272
|
-
className: cn(alertVariants({ variant }), className),
|
|
1273
|
-
...props
|
|
1274
|
-
}
|
|
1275
|
-
);
|
|
1271
|
+
);
|
|
1272
|
+
function Alert({ className, variant, ...props }) {
|
|
1273
|
+
return /* @__PURE__ */ jsx7("div", { "data-slot": "alert", role: "alert", className: cn(alertVariants({ variant }), className), ...props });
|
|
1276
1274
|
}
|
|
1277
1275
|
__name(Alert, "Alert");
|
|
1278
1276
|
function AlertTitle({ className, ...props }) {
|
|
@@ -1289,10 +1287,7 @@ function AlertTitle({ className, ...props }) {
|
|
|
1289
1287
|
);
|
|
1290
1288
|
}
|
|
1291
1289
|
__name(AlertTitle, "AlertTitle");
|
|
1292
|
-
function AlertDescription({
|
|
1293
|
-
className,
|
|
1294
|
-
...props
|
|
1295
|
-
}) {
|
|
1290
|
+
function AlertDescription({ className, ...props }) {
|
|
1296
1291
|
return /* @__PURE__ */ jsx7(
|
|
1297
1292
|
"div",
|
|
1298
1293
|
{
|
|
@@ -1307,14 +1302,7 @@ function AlertDescription({
|
|
|
1307
1302
|
}
|
|
1308
1303
|
__name(AlertDescription, "AlertDescription");
|
|
1309
1304
|
function AlertAction({ className, ...props }) {
|
|
1310
|
-
return /* @__PURE__ */ jsx7(
|
|
1311
|
-
"div",
|
|
1312
|
-
{
|
|
1313
|
-
"data-slot": "alert-action",
|
|
1314
|
-
className: cn("absolute top-1.5 right-2", className),
|
|
1315
|
-
...props
|
|
1316
|
-
}
|
|
1317
|
-
);
|
|
1305
|
+
return /* @__PURE__ */ jsx7("div", { "data-slot": "alert-action", className: cn("absolute top-1.5 right-2", className), ...props });
|
|
1318
1306
|
}
|
|
1319
1307
|
__name(AlertAction, "AlertAction");
|
|
1320
1308
|
|
|
@@ -1360,14 +1348,7 @@ function Button({
|
|
|
1360
1348
|
size = "default",
|
|
1361
1349
|
...props
|
|
1362
1350
|
}) {
|
|
1363
|
-
return /* @__PURE__ */ jsx8(
|
|
1364
|
-
ButtonPrimitive,
|
|
1365
|
-
{
|
|
1366
|
-
"data-slot": "button",
|
|
1367
|
-
className: cn(buttonVariants({ variant, size, className })),
|
|
1368
|
-
...props
|
|
1369
|
-
}
|
|
1370
|
-
);
|
|
1351
|
+
return /* @__PURE__ */ jsx8(ButtonPrimitive, { "data-slot": "button", className: cn(buttonVariants({ variant, size, className })), ...props });
|
|
1371
1352
|
}
|
|
1372
1353
|
__name(Button, "Button");
|
|
1373
1354
|
|
|
@@ -1385,10 +1366,7 @@ function AlertDialogPortal({ ...props }) {
|
|
|
1385
1366
|
return /* @__PURE__ */ jsx9(AlertDialogPrimitive.Portal, { "data-slot": "alert-dialog-portal", ...props });
|
|
1386
1367
|
}
|
|
1387
1368
|
__name(AlertDialogPortal, "AlertDialogPortal");
|
|
1388
|
-
function AlertDialogOverlay({
|
|
1389
|
-
className,
|
|
1390
|
-
...props
|
|
1391
|
-
}) {
|
|
1369
|
+
function AlertDialogOverlay({ className, ...props }) {
|
|
1392
1370
|
return /* @__PURE__ */ jsx9(
|
|
1393
1371
|
AlertDialogPrimitive.Backdrop,
|
|
1394
1372
|
{
|
|
@@ -1424,24 +1402,21 @@ function AlertDialogContent({
|
|
|
1424
1402
|
] });
|
|
1425
1403
|
}
|
|
1426
1404
|
__name(AlertDialogContent, "AlertDialogContent");
|
|
1427
|
-
function AlertDialogHeader({
|
|
1428
|
-
className,
|
|
1429
|
-
...props
|
|
1430
|
-
}) {
|
|
1405
|
+
function AlertDialogHeader({ className, ...props }) {
|
|
1431
1406
|
return /* @__PURE__ */ jsx9(
|
|
1432
1407
|
"div",
|
|
1433
1408
|
{
|
|
1434
1409
|
"data-slot": "alert-dialog-header",
|
|
1435
|
-
className: cn(
|
|
1410
|
+
className: cn(
|
|
1411
|
+
"grid grid-rows-[auto_1fr] place-items-center gap-1 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]",
|
|
1412
|
+
className
|
|
1413
|
+
),
|
|
1436
1414
|
...props
|
|
1437
1415
|
}
|
|
1438
1416
|
);
|
|
1439
1417
|
}
|
|
1440
1418
|
__name(AlertDialogHeader, "AlertDialogHeader");
|
|
1441
|
-
function AlertDialogFooter({
|
|
1442
|
-
className,
|
|
1443
|
-
...props
|
|
1444
|
-
}) {
|
|
1419
|
+
function AlertDialogFooter({ className, ...props }) {
|
|
1445
1420
|
return /* @__PURE__ */ jsx9(
|
|
1446
1421
|
"div",
|
|
1447
1422
|
{
|
|
@@ -1455,29 +1430,29 @@ function AlertDialogFooter({
|
|
|
1455
1430
|
);
|
|
1456
1431
|
}
|
|
1457
1432
|
__name(AlertDialogFooter, "AlertDialogFooter");
|
|
1458
|
-
function AlertDialogMedia({
|
|
1459
|
-
className,
|
|
1460
|
-
...props
|
|
1461
|
-
}) {
|
|
1433
|
+
function AlertDialogMedia({ className, ...props }) {
|
|
1462
1434
|
return /* @__PURE__ */ jsx9(
|
|
1463
1435
|
"div",
|
|
1464
1436
|
{
|
|
1465
1437
|
"data-slot": "alert-dialog-media",
|
|
1466
|
-
className: cn(
|
|
1438
|
+
className: cn(
|
|
1439
|
+
"bg-muted mb-2 inline-flex size-8 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-4",
|
|
1440
|
+
className
|
|
1441
|
+
),
|
|
1467
1442
|
...props
|
|
1468
1443
|
}
|
|
1469
1444
|
);
|
|
1470
1445
|
}
|
|
1471
1446
|
__name(AlertDialogMedia, "AlertDialogMedia");
|
|
1472
|
-
function AlertDialogTitle({
|
|
1473
|
-
className,
|
|
1474
|
-
...props
|
|
1475
|
-
}) {
|
|
1447
|
+
function AlertDialogTitle({ className, ...props }) {
|
|
1476
1448
|
return /* @__PURE__ */ jsx9(
|
|
1477
1449
|
AlertDialogPrimitive.Title,
|
|
1478
1450
|
{
|
|
1479
1451
|
"data-slot": "alert-dialog-title",
|
|
1480
|
-
className: cn(
|
|
1452
|
+
className: cn(
|
|
1453
|
+
"text-sm font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2",
|
|
1454
|
+
className
|
|
1455
|
+
),
|
|
1481
1456
|
...props
|
|
1482
1457
|
}
|
|
1483
1458
|
);
|
|
@@ -1491,24 +1466,17 @@ function AlertDialogDescription({
|
|
|
1491
1466
|
AlertDialogPrimitive.Description,
|
|
1492
1467
|
{
|
|
1493
1468
|
"data-slot": "alert-dialog-description",
|
|
1494
|
-
className: cn(
|
|
1469
|
+
className: cn(
|
|
1470
|
+
"text-muted-foreground *:[a]:hover:text-foreground text-xs/relaxed text-balance md:text-pretty *:[a]:underline *:[a]:underline-offset-3",
|
|
1471
|
+
className
|
|
1472
|
+
),
|
|
1495
1473
|
...props
|
|
1496
1474
|
}
|
|
1497
1475
|
);
|
|
1498
1476
|
}
|
|
1499
1477
|
__name(AlertDialogDescription, "AlertDialogDescription");
|
|
1500
|
-
function AlertDialogAction({
|
|
1501
|
-
className,
|
|
1502
|
-
...props
|
|
1503
|
-
}) {
|
|
1504
|
-
return /* @__PURE__ */ jsx9(
|
|
1505
|
-
Button,
|
|
1506
|
-
{
|
|
1507
|
-
"data-slot": "alert-dialog-action",
|
|
1508
|
-
className: cn(className),
|
|
1509
|
-
...props
|
|
1510
|
-
}
|
|
1511
|
-
);
|
|
1478
|
+
function AlertDialogAction({ className, ...props }) {
|
|
1479
|
+
return /* @__PURE__ */ jsx9(Button, { "data-slot": "alert-dialog-action", className: cn(className), ...props });
|
|
1512
1480
|
}
|
|
1513
1481
|
__name(AlertDialogAction, "AlertDialogAction");
|
|
1514
1482
|
function AlertDialogCancel({
|
|
@@ -1556,19 +1524,13 @@ function AvatarImage({ className, ...props }) {
|
|
|
1556
1524
|
AvatarPrimitive.Image,
|
|
1557
1525
|
{
|
|
1558
1526
|
"data-slot": "avatar-image",
|
|
1559
|
-
className: cn(
|
|
1560
|
-
"rounded-full aspect-square size-full object-cover",
|
|
1561
|
-
className
|
|
1562
|
-
),
|
|
1527
|
+
className: cn("rounded-full aspect-square size-full object-cover", className),
|
|
1563
1528
|
...props
|
|
1564
1529
|
}
|
|
1565
1530
|
);
|
|
1566
1531
|
}
|
|
1567
1532
|
__name(AvatarImage, "AvatarImage");
|
|
1568
|
-
function AvatarFallback({
|
|
1569
|
-
className,
|
|
1570
|
-
...props
|
|
1571
|
-
}) {
|
|
1533
|
+
function AvatarFallback({ className, ...props }) {
|
|
1572
1534
|
return /* @__PURE__ */ jsx10(
|
|
1573
1535
|
AvatarPrimitive.Fallback,
|
|
1574
1536
|
{
|
|
@@ -1613,15 +1575,15 @@ function AvatarGroup({ className, ...props }) {
|
|
|
1613
1575
|
);
|
|
1614
1576
|
}
|
|
1615
1577
|
__name(AvatarGroup, "AvatarGroup");
|
|
1616
|
-
function AvatarGroupCount({
|
|
1617
|
-
className,
|
|
1618
|
-
...props
|
|
1619
|
-
}) {
|
|
1578
|
+
function AvatarGroupCount({ className, ...props }) {
|
|
1620
1579
|
return /* @__PURE__ */ jsx10(
|
|
1621
1580
|
"div",
|
|
1622
1581
|
{
|
|
1623
1582
|
"data-slot": "avatar-group-count",
|
|
1624
|
-
className: cn(
|
|
1583
|
+
className: cn(
|
|
1584
|
+
"bg-muted text-muted-foreground size-8 rounded-full text-xs/relaxed group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3 ring-background relative flex shrink-0 items-center justify-center ring-2",
|
|
1585
|
+
className
|
|
1586
|
+
),
|
|
1625
1587
|
...props
|
|
1626
1588
|
}
|
|
1627
1589
|
);
|
|
@@ -1679,15 +1641,7 @@ import { useRender as useRender2 } from "@base-ui/react/use-render";
|
|
|
1679
1641
|
import { ChevronRightIcon, MoreHorizontalIcon } from "lucide-react";
|
|
1680
1642
|
import { jsx as jsx11, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
1681
1643
|
function Breadcrumb({ className, ...props }) {
|
|
1682
|
-
return /* @__PURE__ */ jsx11(
|
|
1683
|
-
"nav",
|
|
1684
|
-
{
|
|
1685
|
-
"aria-label": "breadcrumb",
|
|
1686
|
-
"data-slot": "breadcrumb",
|
|
1687
|
-
className: cn(className),
|
|
1688
|
-
...props
|
|
1689
|
-
}
|
|
1690
|
-
);
|
|
1644
|
+
return /* @__PURE__ */ jsx11("nav", { "aria-label": "breadcrumb", "data-slot": "breadcrumb", className: cn(className), ...props });
|
|
1691
1645
|
}
|
|
1692
1646
|
__name(Breadcrumb, "Breadcrumb");
|
|
1693
1647
|
function BreadcrumbList({ className, ...props }) {
|
|
@@ -1695,31 +1649,17 @@ function BreadcrumbList({ className, ...props }) {
|
|
|
1695
1649
|
"ol",
|
|
1696
1650
|
{
|
|
1697
1651
|
"data-slot": "breadcrumb-list",
|
|
1698
|
-
className: cn(
|
|
1699
|
-
"text-muted-foreground gap-1.5 text-xs/relaxed flex flex-wrap items-center break-words",
|
|
1700
|
-
className
|
|
1701
|
-
),
|
|
1652
|
+
className: cn("text-muted-foreground gap-1.5 text-xs/relaxed flex flex-wrap items-center break-words", className),
|
|
1702
1653
|
...props
|
|
1703
1654
|
}
|
|
1704
1655
|
);
|
|
1705
1656
|
}
|
|
1706
1657
|
__name(BreadcrumbList, "BreadcrumbList");
|
|
1707
1658
|
function BreadcrumbItem({ className, ...props }) {
|
|
1708
|
-
return /* @__PURE__ */ jsx11(
|
|
1709
|
-
"li",
|
|
1710
|
-
{
|
|
1711
|
-
"data-slot": "breadcrumb-item",
|
|
1712
|
-
className: cn("gap-1 inline-flex items-center", className),
|
|
1713
|
-
...props
|
|
1714
|
-
}
|
|
1715
|
-
);
|
|
1659
|
+
return /* @__PURE__ */ jsx11("li", { "data-slot": "breadcrumb-item", className: cn("gap-1 inline-flex items-center", className), ...props });
|
|
1716
1660
|
}
|
|
1717
1661
|
__name(BreadcrumbItem, "BreadcrumbItem");
|
|
1718
|
-
function BreadcrumbLink({
|
|
1719
|
-
className,
|
|
1720
|
-
render,
|
|
1721
|
-
...props
|
|
1722
|
-
}) {
|
|
1662
|
+
function BreadcrumbLink({ className, render, ...props }) {
|
|
1723
1663
|
return useRender2({
|
|
1724
1664
|
defaultTagName: "a",
|
|
1725
1665
|
props: mergeProps2(
|
|
@@ -1749,11 +1689,7 @@ function BreadcrumbPage({ className, ...props }) {
|
|
|
1749
1689
|
);
|
|
1750
1690
|
}
|
|
1751
1691
|
__name(BreadcrumbPage, "BreadcrumbPage");
|
|
1752
|
-
function BreadcrumbSeparator({
|
|
1753
|
-
children,
|
|
1754
|
-
className,
|
|
1755
|
-
...props
|
|
1756
|
-
}) {
|
|
1692
|
+
function BreadcrumbSeparator({ children, className, ...props }) {
|
|
1757
1693
|
return /* @__PURE__ */ jsx11(
|
|
1758
1694
|
"li",
|
|
1759
1695
|
{
|
|
@@ -1762,34 +1698,22 @@ function BreadcrumbSeparator({
|
|
|
1762
1698
|
"aria-hidden": "true",
|
|
1763
1699
|
className: cn("[&>svg]:size-3.5", className),
|
|
1764
1700
|
...props,
|
|
1765
|
-
children: children ?? /* @__PURE__ */ jsx11(
|
|
1766
|
-
ChevronRightIcon,
|
|
1767
|
-
{}
|
|
1768
|
-
)
|
|
1701
|
+
children: children ?? /* @__PURE__ */ jsx11(ChevronRightIcon, {})
|
|
1769
1702
|
}
|
|
1770
1703
|
);
|
|
1771
1704
|
}
|
|
1772
1705
|
__name(BreadcrumbSeparator, "BreadcrumbSeparator");
|
|
1773
|
-
function BreadcrumbEllipsis({
|
|
1774
|
-
className,
|
|
1775
|
-
...props
|
|
1776
|
-
}) {
|
|
1706
|
+
function BreadcrumbEllipsis({ className, ...props }) {
|
|
1777
1707
|
return /* @__PURE__ */ jsxs4(
|
|
1778
1708
|
"span",
|
|
1779
1709
|
{
|
|
1780
1710
|
"data-slot": "breadcrumb-ellipsis",
|
|
1781
1711
|
role: "presentation",
|
|
1782
1712
|
"aria-hidden": "true",
|
|
1783
|
-
className: cn(
|
|
1784
|
-
"size-4 [&>svg]:size-3.5 flex items-center justify-center",
|
|
1785
|
-
className
|
|
1786
|
-
),
|
|
1713
|
+
className: cn("size-4 [&>svg]:size-3.5 flex items-center justify-center", className),
|
|
1787
1714
|
...props,
|
|
1788
1715
|
children: [
|
|
1789
|
-
/* @__PURE__ */ jsx11(
|
|
1790
|
-
MoreHorizontalIcon,
|
|
1791
|
-
{}
|
|
1792
|
-
),
|
|
1716
|
+
/* @__PURE__ */ jsx11(MoreHorizontalIcon, {}),
|
|
1793
1717
|
/* @__PURE__ */ jsx11("span", { className: "sr-only", children: "More" })
|
|
1794
1718
|
]
|
|
1795
1719
|
}
|
|
@@ -1799,10 +1723,7 @@ __name(BreadcrumbEllipsis, "BreadcrumbEllipsis");
|
|
|
1799
1723
|
|
|
1800
1724
|
// src/shadcnui/ui/calendar.tsx
|
|
1801
1725
|
import * as React3 from "react";
|
|
1802
|
-
import {
|
|
1803
|
-
DayPicker,
|
|
1804
|
-
getDefaultClassNames
|
|
1805
|
-
} from "react-day-picker";
|
|
1726
|
+
import { DayPicker, getDefaultClassNames } from "react-day-picker";
|
|
1806
1727
|
import { ChevronLeftIcon, ChevronRightIcon as ChevronRightIcon2, ChevronDownIcon as ChevronDownIcon2 } from "lucide-react";
|
|
1807
1728
|
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
1808
1729
|
function Calendar({
|
|
@@ -1833,15 +1754,9 @@ function Calendar({
|
|
|
1833
1754
|
},
|
|
1834
1755
|
classNames: {
|
|
1835
1756
|
root: cn("w-fit", defaultClassNames.root),
|
|
1836
|
-
months: cn(
|
|
1837
|
-
"flex gap-4 flex-col md:flex-row relative",
|
|
1838
|
-
defaultClassNames.months
|
|
1839
|
-
),
|
|
1757
|
+
months: cn("flex gap-4 flex-col md:flex-row relative", defaultClassNames.months),
|
|
1840
1758
|
month: cn("flex flex-col w-full gap-4", defaultClassNames.month),
|
|
1841
|
-
nav: cn(
|
|
1842
|
-
"flex items-center gap-1 w-full absolute top-0 inset-x-0 justify-between",
|
|
1843
|
-
defaultClassNames.nav
|
|
1844
|
-
),
|
|
1759
|
+
nav: cn("flex items-center gap-1 w-full absolute top-0 inset-x-0 justify-between", defaultClassNames.nav),
|
|
1845
1760
|
button_previous: cn(
|
|
1846
1761
|
buttonVariants({ variant: buttonVariant }),
|
|
1847
1762
|
"size-(--cell-size) aria-disabled:opacity-50 p-0 select-none",
|
|
@@ -1864,10 +1779,7 @@ function Calendar({
|
|
|
1864
1779
|
"relative cn-calendar-dropdown-root rounded-(--cell-radius)",
|
|
1865
1780
|
defaultClassNames.dropdown_root
|
|
1866
1781
|
),
|
|
1867
|
-
dropdown: cn(
|
|
1868
|
-
"absolute bg-popover inset-0 opacity-0",
|
|
1869
|
-
defaultClassNames.dropdown
|
|
1870
|
-
),
|
|
1782
|
+
dropdown: cn("absolute bg-popover inset-0 opacity-0", defaultClassNames.dropdown),
|
|
1871
1783
|
caption_label: cn(
|
|
1872
1784
|
"select-none font-medium",
|
|
1873
1785
|
captionLayout === "label" ? "text-sm" : "cn-calendar-caption-label rounded-(--cell-radius) flex items-center gap-1 text-sm [&>svg]:text-muted-foreground [&>svg]:size-3.5",
|
|
@@ -1880,14 +1792,8 @@ function Calendar({
|
|
|
1880
1792
|
defaultClassNames.weekday
|
|
1881
1793
|
),
|
|
1882
1794
|
week: cn("flex w-full mt-2", defaultClassNames.week),
|
|
1883
|
-
week_number_header: cn(
|
|
1884
|
-
|
|
1885
|
-
defaultClassNames.week_number_header
|
|
1886
|
-
),
|
|
1887
|
-
week_number: cn(
|
|
1888
|
-
"text-[0.8rem] select-none text-muted-foreground",
|
|
1889
|
-
defaultClassNames.week_number
|
|
1890
|
-
),
|
|
1795
|
+
week_number_header: cn("select-none w-(--cell-size)", defaultClassNames.week_number_header),
|
|
1796
|
+
week_number: cn("text-[0.8rem] select-none text-muted-foreground", defaultClassNames.week_number),
|
|
1891
1797
|
day: cn(
|
|
1892
1798
|
"relative w-full rounded-(--cell-radius) h-full p-0 text-center [&:last-child[data-selected=true]_button]:rounded-r-(--cell-radius) group/day aspect-square select-none",
|
|
1893
1799
|
props.showWeekNumber ? "[&:nth-child(2)[data-selected=true]_button]:rounded-l-(--cell-radius)" : "[&:first-child[data-selected=true]_button]:rounded-l-(--cell-radius)",
|
|
@@ -1906,28 +1812,14 @@ function Calendar({
|
|
|
1906
1812
|
"bg-muted text-foreground rounded-(--cell-radius) data-[selected=true]:rounded-none",
|
|
1907
1813
|
defaultClassNames.today
|
|
1908
1814
|
),
|
|
1909
|
-
outside: cn(
|
|
1910
|
-
|
|
1911
|
-
defaultClassNames.outside
|
|
1912
|
-
),
|
|
1913
|
-
disabled: cn(
|
|
1914
|
-
"text-muted-foreground opacity-50",
|
|
1915
|
-
defaultClassNames.disabled
|
|
1916
|
-
),
|
|
1815
|
+
outside: cn("text-muted-foreground aria-selected:text-muted-foreground", defaultClassNames.outside),
|
|
1816
|
+
disabled: cn("text-muted-foreground opacity-50", defaultClassNames.disabled),
|
|
1917
1817
|
hidden: cn("invisible", defaultClassNames.hidden),
|
|
1918
1818
|
...classNames
|
|
1919
1819
|
},
|
|
1920
1820
|
components: {
|
|
1921
1821
|
Root: /* @__PURE__ */ __name(({ className: className2, rootRef, ...props2 }) => {
|
|
1922
|
-
return /* @__PURE__ */ jsx12(
|
|
1923
|
-
"div",
|
|
1924
|
-
{
|
|
1925
|
-
"data-slot": "calendar",
|
|
1926
|
-
ref: rootRef,
|
|
1927
|
-
className: cn(className2),
|
|
1928
|
-
...props2
|
|
1929
|
-
}
|
|
1930
|
-
);
|
|
1822
|
+
return /* @__PURE__ */ jsx12("div", { "data-slot": "calendar", ref: rootRef, className: cn(className2), ...props2 });
|
|
1931
1823
|
}, "Root"),
|
|
1932
1824
|
Chevron: /* @__PURE__ */ __name(({ className: className2, orientation, ...props2 }) => {
|
|
1933
1825
|
if (orientation === "left") {
|
|
@@ -1949,12 +1841,7 @@ function Calendar({
|
|
|
1949
1841
|
);
|
|
1950
1842
|
}
|
|
1951
1843
|
__name(Calendar, "Calendar");
|
|
1952
|
-
function CalendarDayButton({
|
|
1953
|
-
className,
|
|
1954
|
-
day,
|
|
1955
|
-
modifiers,
|
|
1956
|
-
...props
|
|
1957
|
-
}) {
|
|
1844
|
+
function CalendarDayButton({ className, day, modifiers, ...props }) {
|
|
1958
1845
|
const defaultClassNames = getDefaultClassNames();
|
|
1959
1846
|
const ref = React3.useRef(null);
|
|
1960
1847
|
React3.useEffect(() => {
|
|
@@ -2149,25 +2036,7 @@ function Carousel({
|
|
|
2149
2036
|
__name(Carousel, "Carousel");
|
|
2150
2037
|
function CarouselContent({ className, ...props }) {
|
|
2151
2038
|
const { carouselRef, orientation } = useCarousel();
|
|
2152
|
-
return /* @__PURE__ */ jsx14(
|
|
2153
|
-
"div",
|
|
2154
|
-
{
|
|
2155
|
-
ref: carouselRef,
|
|
2156
|
-
className: "overflow-hidden",
|
|
2157
|
-
"data-slot": "carousel-content",
|
|
2158
|
-
children: /* @__PURE__ */ jsx14(
|
|
2159
|
-
"div",
|
|
2160
|
-
{
|
|
2161
|
-
className: cn(
|
|
2162
|
-
"flex",
|
|
2163
|
-
orientation === "horizontal" ? "-ml-4" : "-mt-4 flex-col",
|
|
2164
|
-
className
|
|
2165
|
-
),
|
|
2166
|
-
...props
|
|
2167
|
-
}
|
|
2168
|
-
)
|
|
2169
|
-
}
|
|
2170
|
-
);
|
|
2039
|
+
return /* @__PURE__ */ jsx14("div", { ref: carouselRef, className: "overflow-hidden", "data-slot": "carousel-content", children: /* @__PURE__ */ jsx14("div", { className: cn("flex", orientation === "horizontal" ? "-ml-4" : "-mt-4 flex-col", className), ...props }) });
|
|
2171
2040
|
}
|
|
2172
2041
|
__name(CarouselContent, "CarouselContent");
|
|
2173
2042
|
function CarouselItem({ className, ...props }) {
|
|
@@ -2178,11 +2047,7 @@ function CarouselItem({ className, ...props }) {
|
|
|
2178
2047
|
role: "group",
|
|
2179
2048
|
"aria-roledescription": "slide",
|
|
2180
2049
|
"data-slot": "carousel-item",
|
|
2181
|
-
className: cn(
|
|
2182
|
-
"min-w-0 shrink-0 grow-0 basis-full",
|
|
2183
|
-
orientation === "horizontal" ? "pl-4" : "pt-4",
|
|
2184
|
-
className
|
|
2185
|
-
),
|
|
2050
|
+
className: cn("min-w-0 shrink-0 grow-0 basis-full", orientation === "horizontal" ? "pl-4" : "pt-4", className),
|
|
2186
2051
|
...props
|
|
2187
2052
|
}
|
|
2188
2053
|
);
|
|
@@ -2210,10 +2075,7 @@ function CarouselPrevious({
|
|
|
2210
2075
|
onClick: scrollPrev,
|
|
2211
2076
|
...props,
|
|
2212
2077
|
children: [
|
|
2213
|
-
/* @__PURE__ */ jsx14(
|
|
2214
|
-
ChevronLeftIcon2,
|
|
2215
|
-
{}
|
|
2216
|
-
),
|
|
2078
|
+
/* @__PURE__ */ jsx14(ChevronLeftIcon2, {}),
|
|
2217
2079
|
/* @__PURE__ */ jsx14("span", { className: "sr-only", children: "Previous slide" })
|
|
2218
2080
|
]
|
|
2219
2081
|
}
|
|
@@ -2242,10 +2104,7 @@ function CarouselNext({
|
|
|
2242
2104
|
onClick: scrollNext,
|
|
2243
2105
|
...props,
|
|
2244
2106
|
children: [
|
|
2245
|
-
/* @__PURE__ */ jsx14(
|
|
2246
|
-
ChevronRightIcon3,
|
|
2247
|
-
{}
|
|
2248
|
-
),
|
|
2107
|
+
/* @__PURE__ */ jsx14(ChevronRightIcon3, {}),
|
|
2249
2108
|
/* @__PURE__ */ jsx14("span", { className: "sr-only", children: "Next slide" })
|
|
2250
2109
|
]
|
|
2251
2110
|
}
|
|
@@ -2295,9 +2154,7 @@ function ChartContainer({
|
|
|
2295
2154
|
}
|
|
2296
2155
|
__name(ChartContainer, "ChartContainer");
|
|
2297
2156
|
var ChartStyle = /* @__PURE__ */ __name(({ id, config }) => {
|
|
2298
|
-
const colorConfig = Object.entries(config).filter(
|
|
2299
|
-
([, config2]) => config2.theme || config2.color
|
|
2300
|
-
);
|
|
2157
|
+
const colorConfig = Object.entries(config).filter(([, config2]) => config2.theme || config2.color);
|
|
2301
2158
|
if (!colorConfig.length) {
|
|
2302
2159
|
return null;
|
|
2303
2160
|
}
|
|
@@ -2351,15 +2208,7 @@ function ChartTooltipContent({
|
|
|
2351
2208
|
return null;
|
|
2352
2209
|
}
|
|
2353
2210
|
return /* @__PURE__ */ jsx15("div", { className: cn("font-medium", labelClassName), children: value });
|
|
2354
|
-
}, [
|
|
2355
|
-
label,
|
|
2356
|
-
labelFormatter,
|
|
2357
|
-
payload,
|
|
2358
|
-
hideLabel,
|
|
2359
|
-
labelClassName,
|
|
2360
|
-
config,
|
|
2361
|
-
labelKey
|
|
2362
|
-
]);
|
|
2211
|
+
}, [label, labelFormatter, payload, hideLabel, labelClassName, config, labelKey]);
|
|
2363
2212
|
if (!active || !payload?.length) {
|
|
2364
2213
|
return null;
|
|
2365
2214
|
}
|
|
@@ -2388,15 +2237,12 @@ function ChartTooltipContent({
|
|
|
2388
2237
|
itemConfig?.icon ? /* @__PURE__ */ jsx15(itemConfig.icon, {}) : !hideIndicator && /* @__PURE__ */ jsx15(
|
|
2389
2238
|
"div",
|
|
2390
2239
|
{
|
|
2391
|
-
className: cn(
|
|
2392
|
-
"
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
"my-0.5": nestLabel && indicator === "dashed"
|
|
2398
|
-
}
|
|
2399
|
-
),
|
|
2240
|
+
className: cn("shrink-0 rounded-[2px] border-(--color-border) bg-(--color-bg)", {
|
|
2241
|
+
"h-2.5 w-2.5": indicator === "dot",
|
|
2242
|
+
"w-1": indicator === "line",
|
|
2243
|
+
"w-0 border-[1.5px] border-dashed bg-transparent": indicator === "dashed",
|
|
2244
|
+
"my-0.5": nestLabel && indicator === "dashed"
|
|
2245
|
+
}),
|
|
2400
2246
|
style: {
|
|
2401
2247
|
"--color-bg": indicatorColor,
|
|
2402
2248
|
"--color-border": indicatorColor
|
|
@@ -2441,41 +2287,29 @@ function ChartLegendContent({
|
|
|
2441
2287
|
if (!payload?.length) {
|
|
2442
2288
|
return null;
|
|
2443
2289
|
}
|
|
2444
|
-
return /* @__PURE__ */ jsx15(
|
|
2445
|
-
"
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
className
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2467
|
-
backgroundColor: item.color
|
|
2468
|
-
}
|
|
2469
|
-
}
|
|
2470
|
-
),
|
|
2471
|
-
itemConfig?.label
|
|
2472
|
-
]
|
|
2473
|
-
},
|
|
2474
|
-
item.value
|
|
2475
|
-
);
|
|
2476
|
-
})
|
|
2477
|
-
}
|
|
2478
|
-
);
|
|
2290
|
+
return /* @__PURE__ */ jsx15("div", { className: cn("flex items-center justify-center gap-4", verticalAlign === "top" ? "pb-3" : "pt-3", className), children: payload.filter((item) => item.type !== "none").map((item) => {
|
|
2291
|
+
const key = `${nameKey || item.dataKey || "value"}`;
|
|
2292
|
+
const itemConfig = getPayloadConfigFromPayload(config, item, key);
|
|
2293
|
+
return /* @__PURE__ */ jsxs6(
|
|
2294
|
+
"div",
|
|
2295
|
+
{
|
|
2296
|
+
className: cn("[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3"),
|
|
2297
|
+
children: [
|
|
2298
|
+
itemConfig?.icon && !hideIcon ? /* @__PURE__ */ jsx15(itemConfig.icon, {}) : /* @__PURE__ */ jsx15(
|
|
2299
|
+
"div",
|
|
2300
|
+
{
|
|
2301
|
+
className: "h-2 w-2 shrink-0 rounded-[2px]",
|
|
2302
|
+
style: {
|
|
2303
|
+
backgroundColor: item.color
|
|
2304
|
+
}
|
|
2305
|
+
}
|
|
2306
|
+
),
|
|
2307
|
+
itemConfig?.label
|
|
2308
|
+
]
|
|
2309
|
+
},
|
|
2310
|
+
item.value
|
|
2311
|
+
);
|
|
2312
|
+
}) });
|
|
2479
2313
|
}
|
|
2480
2314
|
__name(ChartLegendContent, "ChartLegendContent");
|
|
2481
2315
|
function getPayloadConfigFromPayload(config, payload, key) {
|
|
@@ -2512,10 +2346,7 @@ function Checkbox({ className, ...props }) {
|
|
|
2512
2346
|
{
|
|
2513
2347
|
"data-slot": "checkbox-indicator",
|
|
2514
2348
|
className: "[&>svg]:size-3.5 grid place-content-center text-current transition-none",
|
|
2515
|
-
children: /* @__PURE__ */ jsx16(
|
|
2516
|
-
CheckIcon,
|
|
2517
|
-
{}
|
|
2518
|
-
)
|
|
2349
|
+
children: /* @__PURE__ */ jsx16(CheckIcon, {})
|
|
2519
2350
|
}
|
|
2520
2351
|
)
|
|
2521
2352
|
}
|
|
@@ -2562,15 +2393,15 @@ function DialogClose({ ...props }) {
|
|
|
2562
2393
|
return /* @__PURE__ */ jsx18(DialogPrimitive.Close, { "data-slot": "dialog-close", ...props });
|
|
2563
2394
|
}
|
|
2564
2395
|
__name(DialogClose, "DialogClose");
|
|
2565
|
-
function DialogOverlay({
|
|
2566
|
-
className,
|
|
2567
|
-
...props
|
|
2568
|
-
}) {
|
|
2396
|
+
function DialogOverlay({ className, ...props }) {
|
|
2569
2397
|
return /* @__PURE__ */ jsx18(
|
|
2570
2398
|
DialogPrimitive.Backdrop,
|
|
2571
2399
|
{
|
|
2572
2400
|
"data-slot": "dialog-overlay",
|
|
2573
|
-
className: cn(
|
|
2401
|
+
className: cn(
|
|
2402
|
+
"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/80 duration-100 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 isolate z-50",
|
|
2403
|
+
className
|
|
2404
|
+
),
|
|
2574
2405
|
...props
|
|
2575
2406
|
}
|
|
2576
2407
|
);
|
|
@@ -2599,19 +2430,9 @@ function DialogContent({
|
|
|
2599
2430
|
DialogPrimitive.Close,
|
|
2600
2431
|
{
|
|
2601
2432
|
"data-slot": "dialog-close",
|
|
2602
|
-
render: /* @__PURE__ */ jsx18(
|
|
2603
|
-
Button,
|
|
2604
|
-
{
|
|
2605
|
-
variant: "ghost",
|
|
2606
|
-
className: "absolute top-2 right-2",
|
|
2607
|
-
size: "icon-sm"
|
|
2608
|
-
}
|
|
2609
|
-
),
|
|
2433
|
+
render: /* @__PURE__ */ jsx18(Button, { variant: "ghost", className: "absolute top-2 right-2", size: "icon-sm" }),
|
|
2610
2434
|
children: [
|
|
2611
|
-
/* @__PURE__ */ jsx18(
|
|
2612
|
-
XIcon,
|
|
2613
|
-
{}
|
|
2614
|
-
),
|
|
2435
|
+
/* @__PURE__ */ jsx18(XIcon, {}),
|
|
2615
2436
|
/* @__PURE__ */ jsx18("span", { className: "sr-only", children: "Close" })
|
|
2616
2437
|
]
|
|
2617
2438
|
}
|
|
@@ -2623,14 +2444,7 @@ function DialogContent({
|
|
|
2623
2444
|
}
|
|
2624
2445
|
__name(DialogContent, "DialogContent");
|
|
2625
2446
|
function DialogHeader({ className, ...props }) {
|
|
2626
|
-
return /* @__PURE__ */ jsx18(
|
|
2627
|
-
"div",
|
|
2628
|
-
{
|
|
2629
|
-
"data-slot": "dialog-header",
|
|
2630
|
-
className: cn("gap-1 flex flex-col", className),
|
|
2631
|
-
...props
|
|
2632
|
-
}
|
|
2633
|
-
);
|
|
2447
|
+
return /* @__PURE__ */ jsx18("div", { "data-slot": "dialog-header", className: cn("gap-1 flex flex-col", className), ...props });
|
|
2634
2448
|
}
|
|
2635
2449
|
__name(DialogHeader, "DialogHeader");
|
|
2636
2450
|
function DialogFooter({
|
|
@@ -2643,10 +2457,7 @@ function DialogFooter({
|
|
|
2643
2457
|
"div",
|
|
2644
2458
|
{
|
|
2645
2459
|
"data-slot": "dialog-footer",
|
|
2646
|
-
className: cn(
|
|
2647
|
-
"gap-2 flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",
|
|
2648
|
-
className
|
|
2649
|
-
),
|
|
2460
|
+
className: cn("gap-2 flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className),
|
|
2650
2461
|
...props,
|
|
2651
2462
|
children: [
|
|
2652
2463
|
children,
|
|
@@ -2657,25 +2468,18 @@ function DialogFooter({
|
|
|
2657
2468
|
}
|
|
2658
2469
|
__name(DialogFooter, "DialogFooter");
|
|
2659
2470
|
function DialogTitle({ className, ...props }) {
|
|
2660
|
-
return /* @__PURE__ */ jsx18(
|
|
2661
|
-
DialogPrimitive.Title,
|
|
2662
|
-
{
|
|
2663
|
-
"data-slot": "dialog-title",
|
|
2664
|
-
className: cn("text-sm font-medium", className),
|
|
2665
|
-
...props
|
|
2666
|
-
}
|
|
2667
|
-
);
|
|
2471
|
+
return /* @__PURE__ */ jsx18(DialogPrimitive.Title, { "data-slot": "dialog-title", className: cn("text-sm font-medium", className), ...props });
|
|
2668
2472
|
}
|
|
2669
2473
|
__name(DialogTitle, "DialogTitle");
|
|
2670
|
-
function DialogDescription({
|
|
2671
|
-
className,
|
|
2672
|
-
...props
|
|
2673
|
-
}) {
|
|
2474
|
+
function DialogDescription({ className, ...props }) {
|
|
2674
2475
|
return /* @__PURE__ */ jsx18(
|
|
2675
2476
|
DialogPrimitive.Description,
|
|
2676
2477
|
{
|
|
2677
2478
|
"data-slot": "dialog-description",
|
|
2678
|
-
className: cn(
|
|
2479
|
+
className: cn(
|
|
2480
|
+
"text-muted-foreground *:[a]:hover:text-foreground text-xs/relaxed *:[a]:underline *:[a]:underline-offset-3",
|
|
2481
|
+
className
|
|
2482
|
+
),
|
|
2679
2483
|
...props
|
|
2680
2484
|
}
|
|
2681
2485
|
);
|
|
@@ -2777,22 +2581,19 @@ function InputGroupAddon({
|
|
|
2777
2581
|
);
|
|
2778
2582
|
}
|
|
2779
2583
|
__name(InputGroupAddon, "InputGroupAddon");
|
|
2780
|
-
var inputGroupButtonVariants = cva4(
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
"icon-xs": "size-6 p-0 has-[>svg]:p-0",
|
|
2788
|
-
"icon-sm": "size-8 p-0 has-[>svg]:p-0"
|
|
2789
|
-
}
|
|
2790
|
-
},
|
|
2791
|
-
defaultVariants: {
|
|
2792
|
-
size: "xs"
|
|
2584
|
+
var inputGroupButtonVariants = cva4("gap-2 rounded-md text-xs/relaxed shadow-none flex items-center", {
|
|
2585
|
+
variants: {
|
|
2586
|
+
size: {
|
|
2587
|
+
xs: "h-5 gap-1 rounded-[calc(var(--radius-sm)-2px)] px-1 [&>svg:not([class*='size-'])]:size-3",
|
|
2588
|
+
sm: "",
|
|
2589
|
+
"icon-xs": "size-6 p-0 has-[>svg]:p-0",
|
|
2590
|
+
"icon-sm": "size-8 p-0 has-[>svg]:p-0"
|
|
2793
2591
|
}
|
|
2592
|
+
},
|
|
2593
|
+
defaultVariants: {
|
|
2594
|
+
size: "xs"
|
|
2794
2595
|
}
|
|
2795
|
-
);
|
|
2596
|
+
});
|
|
2796
2597
|
function InputGroupButton({
|
|
2797
2598
|
className,
|
|
2798
2599
|
type = "button",
|
|
@@ -2825,29 +2626,29 @@ function InputGroupText({ className, ...props }) {
|
|
|
2825
2626
|
);
|
|
2826
2627
|
}
|
|
2827
2628
|
__name(InputGroupText, "InputGroupText");
|
|
2828
|
-
function InputGroupInput({
|
|
2829
|
-
className,
|
|
2830
|
-
...props
|
|
2831
|
-
}) {
|
|
2629
|
+
function InputGroupInput({ className, ...props }) {
|
|
2832
2630
|
return /* @__PURE__ */ jsx21(
|
|
2833
2631
|
Input,
|
|
2834
2632
|
{
|
|
2835
2633
|
"data-slot": "input-group-control",
|
|
2836
|
-
className: cn(
|
|
2634
|
+
className: cn(
|
|
2635
|
+
"rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 aria-invalid:ring-0 dark:bg-transparent flex-1",
|
|
2636
|
+
className
|
|
2637
|
+
),
|
|
2837
2638
|
...props
|
|
2838
2639
|
}
|
|
2839
2640
|
);
|
|
2840
2641
|
}
|
|
2841
2642
|
__name(InputGroupInput, "InputGroupInput");
|
|
2842
|
-
function InputGroupTextarea({
|
|
2843
|
-
className,
|
|
2844
|
-
...props
|
|
2845
|
-
}) {
|
|
2643
|
+
function InputGroupTextarea({ className, ...props }) {
|
|
2846
2644
|
return /* @__PURE__ */ jsx21(
|
|
2847
2645
|
Textarea,
|
|
2848
2646
|
{
|
|
2849
2647
|
"data-slot": "input-group-control",
|
|
2850
|
-
className: cn(
|
|
2648
|
+
className: cn(
|
|
2649
|
+
"rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 aria-invalid:ring-0 dark:bg-transparent flex-1 resize-none",
|
|
2650
|
+
className
|
|
2651
|
+
),
|
|
2851
2652
|
...props
|
|
2852
2653
|
}
|
|
2853
2654
|
);
|
|
@@ -2857,10 +2658,7 @@ __name(InputGroupTextarea, "InputGroupTextarea");
|
|
|
2857
2658
|
// src/shadcnui/ui/command.tsx
|
|
2858
2659
|
import { SearchIcon, CheckIcon as CheckIcon2 } from "lucide-react";
|
|
2859
2660
|
import { jsx as jsx22, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
2860
|
-
function Command({
|
|
2861
|
-
className,
|
|
2862
|
-
...props
|
|
2863
|
-
}) {
|
|
2661
|
+
function Command({ className, ...props }) {
|
|
2864
2662
|
return /* @__PURE__ */ jsx22(
|
|
2865
2663
|
CommandPrimitive,
|
|
2866
2664
|
{
|
|
@@ -2887,21 +2685,11 @@ function CommandDialog({
|
|
|
2887
2685
|
/* @__PURE__ */ jsx22(DialogTitle, { children: title }),
|
|
2888
2686
|
/* @__PURE__ */ jsx22(DialogDescription, { children: description })
|
|
2889
2687
|
] }),
|
|
2890
|
-
/* @__PURE__ */ jsx22(
|
|
2891
|
-
DialogContent,
|
|
2892
|
-
{
|
|
2893
|
-
className: cn("rounded-xl! p-0 overflow-hidden p-0", className),
|
|
2894
|
-
showCloseButton,
|
|
2895
|
-
children
|
|
2896
|
-
}
|
|
2897
|
-
)
|
|
2688
|
+
/* @__PURE__ */ jsx22(DialogContent, { className: cn("rounded-xl! p-0 overflow-hidden p-0", className), showCloseButton, children })
|
|
2898
2689
|
] });
|
|
2899
2690
|
}
|
|
2900
2691
|
__name(CommandDialog, "CommandDialog");
|
|
2901
|
-
function CommandInput({
|
|
2902
|
-
className,
|
|
2903
|
-
...props
|
|
2904
|
-
}) {
|
|
2692
|
+
function CommandInput({ className, ...props }) {
|
|
2905
2693
|
return /* @__PURE__ */ jsx22("div", { "data-slot": "command-input-wrapper", className: "p-1 pb-0", children: /* @__PURE__ */ jsxs8(InputGroup, { className: "bg-input/20 dark:bg-input/30 h-8!", children: [
|
|
2906
2694
|
/* @__PURE__ */ jsx22(
|
|
2907
2695
|
CommandPrimitive.Input,
|
|
@@ -2918,27 +2706,18 @@ function CommandInput({
|
|
|
2918
2706
|
] }) });
|
|
2919
2707
|
}
|
|
2920
2708
|
__name(CommandInput, "CommandInput");
|
|
2921
|
-
function CommandList({
|
|
2922
|
-
className,
|
|
2923
|
-
...props
|
|
2924
|
-
}) {
|
|
2709
|
+
function CommandList({ className, ...props }) {
|
|
2925
2710
|
return /* @__PURE__ */ jsx22(
|
|
2926
2711
|
CommandPrimitive.List,
|
|
2927
2712
|
{
|
|
2928
2713
|
"data-slot": "command-list",
|
|
2929
|
-
className: cn(
|
|
2930
|
-
"no-scrollbar max-h-72 scroll-py-1 outline-none overflow-x-hidden overflow-y-auto",
|
|
2931
|
-
className
|
|
2932
|
-
),
|
|
2714
|
+
className: cn("no-scrollbar max-h-72 scroll-py-1 outline-none overflow-x-hidden overflow-y-auto", className),
|
|
2933
2715
|
...props
|
|
2934
2716
|
}
|
|
2935
2717
|
);
|
|
2936
2718
|
}
|
|
2937
2719
|
__name(CommandList, "CommandList");
|
|
2938
|
-
function CommandEmpty({
|
|
2939
|
-
className,
|
|
2940
|
-
...props
|
|
2941
|
-
}) {
|
|
2720
|
+
function CommandEmpty({ className, ...props }) {
|
|
2942
2721
|
return /* @__PURE__ */ jsx22(
|
|
2943
2722
|
CommandPrimitive.Empty,
|
|
2944
2723
|
{
|
|
@@ -2949,24 +2728,21 @@ function CommandEmpty({
|
|
|
2949
2728
|
);
|
|
2950
2729
|
}
|
|
2951
2730
|
__name(CommandEmpty, "CommandEmpty");
|
|
2952
|
-
function CommandGroup({
|
|
2953
|
-
className,
|
|
2954
|
-
...props
|
|
2955
|
-
}) {
|
|
2731
|
+
function CommandGroup({ className, ...props }) {
|
|
2956
2732
|
return /* @__PURE__ */ jsx22(
|
|
2957
2733
|
CommandPrimitive.Group,
|
|
2958
2734
|
{
|
|
2959
2735
|
"data-slot": "command-group",
|
|
2960
|
-
className: cn(
|
|
2736
|
+
className: cn(
|
|
2737
|
+
"text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2.5 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",
|
|
2738
|
+
className
|
|
2739
|
+
),
|
|
2961
2740
|
...props
|
|
2962
2741
|
}
|
|
2963
2742
|
);
|
|
2964
2743
|
}
|
|
2965
2744
|
__name(CommandGroup, "CommandGroup");
|
|
2966
|
-
function CommandSeparator({
|
|
2967
|
-
className,
|
|
2968
|
-
...props
|
|
2969
|
-
}) {
|
|
2745
|
+
function CommandSeparator({ className, ...props }) {
|
|
2970
2746
|
return /* @__PURE__ */ jsx22(
|
|
2971
2747
|
CommandPrimitive.Separator,
|
|
2972
2748
|
{
|
|
@@ -2977,11 +2753,7 @@ function CommandSeparator({
|
|
|
2977
2753
|
);
|
|
2978
2754
|
}
|
|
2979
2755
|
__name(CommandSeparator, "CommandSeparator");
|
|
2980
|
-
function CommandItem({
|
|
2981
|
-
className,
|
|
2982
|
-
children,
|
|
2983
|
-
...props
|
|
2984
|
-
}) {
|
|
2756
|
+
function CommandItem({ className, children, ...props }) {
|
|
2985
2757
|
return /* @__PURE__ */ jsxs8(
|
|
2986
2758
|
CommandPrimitive.Item,
|
|
2987
2759
|
{
|
|
@@ -2999,15 +2771,15 @@ function CommandItem({
|
|
|
2999
2771
|
);
|
|
3000
2772
|
}
|
|
3001
2773
|
__name(CommandItem, "CommandItem");
|
|
3002
|
-
function CommandShortcut({
|
|
3003
|
-
className,
|
|
3004
|
-
...props
|
|
3005
|
-
}) {
|
|
2774
|
+
function CommandShortcut({ className, ...props }) {
|
|
3006
2775
|
return /* @__PURE__ */ jsx22(
|
|
3007
2776
|
"span",
|
|
3008
2777
|
{
|
|
3009
2778
|
"data-slot": "command-shortcut",
|
|
3010
|
-
className: cn(
|
|
2779
|
+
className: cn(
|
|
2780
|
+
"text-muted-foreground group-data-selected/command-item:text-foreground ml-auto text-[0.625rem] tracking-widest",
|
|
2781
|
+
className
|
|
2782
|
+
),
|
|
3011
2783
|
...props
|
|
3012
2784
|
}
|
|
3013
2785
|
);
|
|
@@ -3026,10 +2798,7 @@ function ContextMenuPortal({ ...props }) {
|
|
|
3026
2798
|
return /* @__PURE__ */ jsx23(ContextMenuPrimitive.Portal, { "data-slot": "context-menu-portal", ...props });
|
|
3027
2799
|
}
|
|
3028
2800
|
__name(ContextMenuPortal, "ContextMenuPortal");
|
|
3029
|
-
function ContextMenuTrigger({
|
|
3030
|
-
className,
|
|
3031
|
-
...props
|
|
3032
|
-
}) {
|
|
2801
|
+
function ContextMenuTrigger({ className, ...props }) {
|
|
3033
2802
|
return /* @__PURE__ */ jsx23(
|
|
3034
2803
|
ContextMenuPrimitive.Trigger,
|
|
3035
2804
|
{
|
|
@@ -3060,7 +2829,10 @@ function ContextMenuContent({
|
|
|
3060
2829
|
ContextMenuPrimitive.Popup,
|
|
3061
2830
|
{
|
|
3062
2831
|
"data-slot": "context-menu-content",
|
|
3063
|
-
className: cn(
|
|
2832
|
+
className: cn(
|
|
2833
|
+
"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 bg-popover text-popover-foreground min-w-32 rounded-lg p-1 shadow-md ring-1 duration-100 z-50 max-h-(--available-height) origin-(--transform-origin) overflow-x-hidden overflow-y-auto outline-none",
|
|
2834
|
+
className
|
|
2835
|
+
),
|
|
3064
2836
|
...props
|
|
3065
2837
|
}
|
|
3066
2838
|
)
|
|
@@ -3137,26 +2909,11 @@ function ContextMenuSubTrigger({
|
|
|
3137
2909
|
);
|
|
3138
2910
|
}
|
|
3139
2911
|
__name(ContextMenuSubTrigger, "ContextMenuSubTrigger");
|
|
3140
|
-
function ContextMenuSubContent({
|
|
3141
|
-
...props
|
|
3142
|
-
}) {
|
|
3143
|
-
return /* @__PURE__ */ jsx23(
|
|
3144
|
-
ContextMenuContent,
|
|
3145
|
-
{
|
|
3146
|
-
"data-slot": "context-menu-sub-content",
|
|
3147
|
-
className: "shadow-lg",
|
|
3148
|
-
side: "right",
|
|
3149
|
-
...props
|
|
3150
|
-
}
|
|
3151
|
-
);
|
|
2912
|
+
function ContextMenuSubContent({ ...props }) {
|
|
2913
|
+
return /* @__PURE__ */ jsx23(ContextMenuContent, { "data-slot": "context-menu-sub-content", className: "shadow-lg", side: "right", ...props });
|
|
3152
2914
|
}
|
|
3153
2915
|
__name(ContextMenuSubContent, "ContextMenuSubContent");
|
|
3154
|
-
function ContextMenuCheckboxItem({
|
|
3155
|
-
className,
|
|
3156
|
-
children,
|
|
3157
|
-
checked,
|
|
3158
|
-
...props
|
|
3159
|
-
}) {
|
|
2916
|
+
function ContextMenuCheckboxItem({ className, children, checked, ...props }) {
|
|
3160
2917
|
return /* @__PURE__ */ jsxs9(
|
|
3161
2918
|
ContextMenuPrimitive.CheckboxItem,
|
|
3162
2919
|
{
|
|
@@ -3168,33 +2925,18 @@ function ContextMenuCheckboxItem({
|
|
|
3168
2925
|
checked,
|
|
3169
2926
|
...props,
|
|
3170
2927
|
children: [
|
|
3171
|
-
/* @__PURE__ */ jsx23("span", { className: "pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none", children: /* @__PURE__ */ jsx23(ContextMenuPrimitive.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx23(
|
|
3172
|
-
CheckIcon3,
|
|
3173
|
-
{}
|
|
3174
|
-
) }) }),
|
|
2928
|
+
/* @__PURE__ */ jsx23("span", { className: "pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none", children: /* @__PURE__ */ jsx23(ContextMenuPrimitive.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx23(CheckIcon3, {}) }) }),
|
|
3175
2929
|
children
|
|
3176
2930
|
]
|
|
3177
2931
|
}
|
|
3178
2932
|
);
|
|
3179
2933
|
}
|
|
3180
2934
|
__name(ContextMenuCheckboxItem, "ContextMenuCheckboxItem");
|
|
3181
|
-
function ContextMenuRadioGroup({
|
|
3182
|
-
...props
|
|
3183
|
-
}) {
|
|
3184
|
-
return /* @__PURE__ */ jsx23(
|
|
3185
|
-
ContextMenuPrimitive.RadioGroup,
|
|
3186
|
-
{
|
|
3187
|
-
"data-slot": "context-menu-radio-group",
|
|
3188
|
-
...props
|
|
3189
|
-
}
|
|
3190
|
-
);
|
|
2935
|
+
function ContextMenuRadioGroup({ ...props }) {
|
|
2936
|
+
return /* @__PURE__ */ jsx23(ContextMenuPrimitive.RadioGroup, { "data-slot": "context-menu-radio-group", ...props });
|
|
3191
2937
|
}
|
|
3192
2938
|
__name(ContextMenuRadioGroup, "ContextMenuRadioGroup");
|
|
3193
|
-
function ContextMenuRadioItem({
|
|
3194
|
-
className,
|
|
3195
|
-
children,
|
|
3196
|
-
...props
|
|
3197
|
-
}) {
|
|
2939
|
+
function ContextMenuRadioItem({ className, children, ...props }) {
|
|
3198
2940
|
return /* @__PURE__ */ jsxs9(
|
|
3199
2941
|
ContextMenuPrimitive.RadioItem,
|
|
3200
2942
|
{
|
|
@@ -3205,20 +2947,14 @@ function ContextMenuRadioItem({
|
|
|
3205
2947
|
),
|
|
3206
2948
|
...props,
|
|
3207
2949
|
children: [
|
|
3208
|
-
/* @__PURE__ */ jsx23("span", { className: "pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none", children: /* @__PURE__ */ jsx23(ContextMenuPrimitive.RadioItemIndicator, { children: /* @__PURE__ */ jsx23(
|
|
3209
|
-
CheckIcon3,
|
|
3210
|
-
{}
|
|
3211
|
-
) }) }),
|
|
2950
|
+
/* @__PURE__ */ jsx23("span", { className: "pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none", children: /* @__PURE__ */ jsx23(ContextMenuPrimitive.RadioItemIndicator, { children: /* @__PURE__ */ jsx23(CheckIcon3, {}) }) }),
|
|
3212
2951
|
children
|
|
3213
2952
|
]
|
|
3214
2953
|
}
|
|
3215
2954
|
);
|
|
3216
2955
|
}
|
|
3217
2956
|
__name(ContextMenuRadioItem, "ContextMenuRadioItem");
|
|
3218
|
-
function ContextMenuSeparator({
|
|
3219
|
-
className,
|
|
3220
|
-
...props
|
|
3221
|
-
}) {
|
|
2957
|
+
function ContextMenuSeparator({ className, ...props }) {
|
|
3222
2958
|
return /* @__PURE__ */ jsx23(
|
|
3223
2959
|
ContextMenuPrimitive.Separator,
|
|
3224
2960
|
{
|
|
@@ -3229,15 +2965,15 @@ function ContextMenuSeparator({
|
|
|
3229
2965
|
);
|
|
3230
2966
|
}
|
|
3231
2967
|
__name(ContextMenuSeparator, "ContextMenuSeparator");
|
|
3232
|
-
function ContextMenuShortcut({
|
|
3233
|
-
className,
|
|
3234
|
-
...props
|
|
3235
|
-
}) {
|
|
2968
|
+
function ContextMenuShortcut({ className, ...props }) {
|
|
3236
2969
|
return /* @__PURE__ */ jsx23(
|
|
3237
2970
|
"span",
|
|
3238
2971
|
{
|
|
3239
2972
|
"data-slot": "context-menu-shortcut",
|
|
3240
|
-
className: cn(
|
|
2973
|
+
className: cn(
|
|
2974
|
+
"text-muted-foreground group-focus/context-menu-item:text-accent-foreground ml-auto text-[0.625rem] tracking-widest",
|
|
2975
|
+
className
|
|
2976
|
+
),
|
|
3241
2977
|
...props
|
|
3242
2978
|
}
|
|
3243
2979
|
);
|
|
@@ -3247,49 +2983,37 @@ __name(ContextMenuShortcut, "ContextMenuShortcut");
|
|
|
3247
2983
|
// src/shadcnui/ui/drawer.tsx
|
|
3248
2984
|
import { Drawer as DrawerPrimitive } from "vaul";
|
|
3249
2985
|
import { jsx as jsx24, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
3250
|
-
function Drawer({
|
|
3251
|
-
...props
|
|
3252
|
-
}) {
|
|
2986
|
+
function Drawer({ ...props }) {
|
|
3253
2987
|
return /* @__PURE__ */ jsx24(DrawerPrimitive.Root, { "data-slot": "drawer", ...props });
|
|
3254
2988
|
}
|
|
3255
2989
|
__name(Drawer, "Drawer");
|
|
3256
|
-
function DrawerTrigger({
|
|
3257
|
-
...props
|
|
3258
|
-
}) {
|
|
2990
|
+
function DrawerTrigger({ ...props }) {
|
|
3259
2991
|
return /* @__PURE__ */ jsx24(DrawerPrimitive.Trigger, { "data-slot": "drawer-trigger", ...props });
|
|
3260
2992
|
}
|
|
3261
2993
|
__name(DrawerTrigger, "DrawerTrigger");
|
|
3262
|
-
function DrawerPortal({
|
|
3263
|
-
...props
|
|
3264
|
-
}) {
|
|
2994
|
+
function DrawerPortal({ ...props }) {
|
|
3265
2995
|
return /* @__PURE__ */ jsx24(DrawerPrimitive.Portal, { "data-slot": "drawer-portal", ...props });
|
|
3266
2996
|
}
|
|
3267
2997
|
__name(DrawerPortal, "DrawerPortal");
|
|
3268
|
-
function DrawerClose({
|
|
3269
|
-
...props
|
|
3270
|
-
}) {
|
|
2998
|
+
function DrawerClose({ ...props }) {
|
|
3271
2999
|
return /* @__PURE__ */ jsx24(DrawerPrimitive.Close, { "data-slot": "drawer-close", ...props });
|
|
3272
3000
|
}
|
|
3273
3001
|
__name(DrawerClose, "DrawerClose");
|
|
3274
|
-
function DrawerOverlay({
|
|
3275
|
-
className,
|
|
3276
|
-
...props
|
|
3277
|
-
}) {
|
|
3002
|
+
function DrawerOverlay({ className, ...props }) {
|
|
3278
3003
|
return /* @__PURE__ */ jsx24(
|
|
3279
3004
|
DrawerPrimitive.Overlay,
|
|
3280
3005
|
{
|
|
3281
3006
|
"data-slot": "drawer-overlay",
|
|
3282
|
-
className: cn(
|
|
3007
|
+
className: cn(
|
|
3008
|
+
"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/80 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50",
|
|
3009
|
+
className
|
|
3010
|
+
),
|
|
3283
3011
|
...props
|
|
3284
3012
|
}
|
|
3285
3013
|
);
|
|
3286
3014
|
}
|
|
3287
3015
|
__name(DrawerOverlay, "DrawerOverlay");
|
|
3288
|
-
function DrawerContent({
|
|
3289
|
-
className,
|
|
3290
|
-
children,
|
|
3291
|
-
...props
|
|
3292
|
-
}) {
|
|
3016
|
+
function DrawerContent({ className, children, ...props }) {
|
|
3293
3017
|
return /* @__PURE__ */ jsxs10(DrawerPortal, { "data-slot": "drawer-portal", children: [
|
|
3294
3018
|
/* @__PURE__ */ jsx24(DrawerOverlay, {}),
|
|
3295
3019
|
/* @__PURE__ */ jsxs10(
|
|
@@ -3315,27 +3039,20 @@ function DrawerHeader({ className, ...props }) {
|
|
|
3315
3039
|
"div",
|
|
3316
3040
|
{
|
|
3317
3041
|
"data-slot": "drawer-header",
|
|
3318
|
-
className: cn(
|
|
3042
|
+
className: cn(
|
|
3043
|
+
"gap-1 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:text-left flex flex-col",
|
|
3044
|
+
className
|
|
3045
|
+
),
|
|
3319
3046
|
...props
|
|
3320
3047
|
}
|
|
3321
3048
|
);
|
|
3322
3049
|
}
|
|
3323
3050
|
__name(DrawerHeader, "DrawerHeader");
|
|
3324
3051
|
function DrawerFooter({ className, ...props }) {
|
|
3325
|
-
return /* @__PURE__ */ jsx24(
|
|
3326
|
-
"div",
|
|
3327
|
-
{
|
|
3328
|
-
"data-slot": "drawer-footer",
|
|
3329
|
-
className: cn("gap-2 p-4 mt-auto flex flex-col", className),
|
|
3330
|
-
...props
|
|
3331
|
-
}
|
|
3332
|
-
);
|
|
3052
|
+
return /* @__PURE__ */ jsx24("div", { "data-slot": "drawer-footer", className: cn("gap-2 p-4 mt-auto flex flex-col", className), ...props });
|
|
3333
3053
|
}
|
|
3334
3054
|
__name(DrawerFooter, "DrawerFooter");
|
|
3335
|
-
function DrawerTitle({
|
|
3336
|
-
className,
|
|
3337
|
-
...props
|
|
3338
|
-
}) {
|
|
3055
|
+
function DrawerTitle({ className, ...props }) {
|
|
3339
3056
|
return /* @__PURE__ */ jsx24(
|
|
3340
3057
|
DrawerPrimitive.Title,
|
|
3341
3058
|
{
|
|
@@ -3346,10 +3063,7 @@ function DrawerTitle({
|
|
|
3346
3063
|
);
|
|
3347
3064
|
}
|
|
3348
3065
|
__name(DrawerTitle, "DrawerTitle");
|
|
3349
|
-
function DrawerDescription({
|
|
3350
|
-
className,
|
|
3351
|
-
...props
|
|
3352
|
-
}) {
|
|
3066
|
+
function DrawerDescription({ className, ...props }) {
|
|
3353
3067
|
return /* @__PURE__ */ jsx24(
|
|
3354
3068
|
DrawerPrimitive.Description,
|
|
3355
3069
|
{
|
|
@@ -3397,7 +3111,10 @@ function DropdownMenuContent({
|
|
|
3397
3111
|
MenuPrimitive.Popup,
|
|
3398
3112
|
{
|
|
3399
3113
|
"data-slot": "dropdown-menu-content",
|
|
3400
|
-
className: cn(
|
|
3114
|
+
className: cn(
|
|
3115
|
+
"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 bg-popover text-popover-foreground min-w-32 rounded-lg p-1 shadow-md ring-1 duration-100 z-50 max-h-(--available-height) w-(--anchor-width) origin-(--transform-origin) overflow-x-hidden overflow-y-auto outline-none data-closed:overflow-hidden",
|
|
3116
|
+
className
|
|
3117
|
+
),
|
|
3401
3118
|
...props
|
|
3402
3119
|
}
|
|
3403
3120
|
)
|
|
@@ -3486,7 +3203,10 @@ function DropdownMenuSubContent({
|
|
|
3486
3203
|
DropdownMenuContent,
|
|
3487
3204
|
{
|
|
3488
3205
|
"data-slot": "dropdown-menu-sub-content",
|
|
3489
|
-
className: cn(
|
|
3206
|
+
className: cn(
|
|
3207
|
+
"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 bg-popover text-popover-foreground min-w-32 rounded-lg p-1 shadow-md ring-1 duration-100 w-auto",
|
|
3208
|
+
className
|
|
3209
|
+
),
|
|
3490
3210
|
align,
|
|
3491
3211
|
alignOffset,
|
|
3492
3212
|
side,
|
|
@@ -3496,12 +3216,7 @@ function DropdownMenuSubContent({
|
|
|
3496
3216
|
);
|
|
3497
3217
|
}
|
|
3498
3218
|
__name(DropdownMenuSubContent, "DropdownMenuSubContent");
|
|
3499
|
-
function DropdownMenuCheckboxItem({
|
|
3500
|
-
className,
|
|
3501
|
-
children,
|
|
3502
|
-
checked,
|
|
3503
|
-
...props
|
|
3504
|
-
}) {
|
|
3219
|
+
function DropdownMenuCheckboxItem({ className, children, checked, ...props }) {
|
|
3505
3220
|
return /* @__PURE__ */ jsxs11(
|
|
3506
3221
|
MenuPrimitive.CheckboxItem,
|
|
3507
3222
|
{
|
|
@@ -3518,10 +3233,7 @@ function DropdownMenuCheckboxItem({
|
|
|
3518
3233
|
{
|
|
3519
3234
|
className: "pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none",
|
|
3520
3235
|
"data-slot": "dropdown-menu-checkbox-item-indicator",
|
|
3521
|
-
children: /* @__PURE__ */ jsx25(MenuPrimitive.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx25(
|
|
3522
|
-
CheckIcon4,
|
|
3523
|
-
{}
|
|
3524
|
-
) })
|
|
3236
|
+
children: /* @__PURE__ */ jsx25(MenuPrimitive.CheckboxItemIndicator, { children: /* @__PURE__ */ jsx25(CheckIcon4, {}) })
|
|
3525
3237
|
}
|
|
3526
3238
|
),
|
|
3527
3239
|
children
|
|
@@ -3531,20 +3243,10 @@ function DropdownMenuCheckboxItem({
|
|
|
3531
3243
|
}
|
|
3532
3244
|
__name(DropdownMenuCheckboxItem, "DropdownMenuCheckboxItem");
|
|
3533
3245
|
function DropdownMenuRadioGroup({ ...props }) {
|
|
3534
|
-
return /* @__PURE__ */ jsx25(
|
|
3535
|
-
MenuPrimitive.RadioGroup,
|
|
3536
|
-
{
|
|
3537
|
-
"data-slot": "dropdown-menu-radio-group",
|
|
3538
|
-
...props
|
|
3539
|
-
}
|
|
3540
|
-
);
|
|
3246
|
+
return /* @__PURE__ */ jsx25(MenuPrimitive.RadioGroup, { "data-slot": "dropdown-menu-radio-group", ...props });
|
|
3541
3247
|
}
|
|
3542
3248
|
__name(DropdownMenuRadioGroup, "DropdownMenuRadioGroup");
|
|
3543
|
-
function DropdownMenuRadioItem({
|
|
3544
|
-
className,
|
|
3545
|
-
children,
|
|
3546
|
-
...props
|
|
3547
|
-
}) {
|
|
3249
|
+
function DropdownMenuRadioItem({ className, children, ...props }) {
|
|
3548
3250
|
return /* @__PURE__ */ jsxs11(
|
|
3549
3251
|
MenuPrimitive.RadioItem,
|
|
3550
3252
|
{
|
|
@@ -3560,10 +3262,7 @@ function DropdownMenuRadioItem({
|
|
|
3560
3262
|
{
|
|
3561
3263
|
className: "pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none",
|
|
3562
3264
|
"data-slot": "dropdown-menu-radio-item-indicator",
|
|
3563
|
-
children: /* @__PURE__ */ jsx25(MenuPrimitive.RadioItemIndicator, { children: /* @__PURE__ */ jsx25(
|
|
3564
|
-
CheckIcon4,
|
|
3565
|
-
{}
|
|
3566
|
-
) })
|
|
3265
|
+
children: /* @__PURE__ */ jsx25(MenuPrimitive.RadioItemIndicator, { children: /* @__PURE__ */ jsx25(CheckIcon4, {}) })
|
|
3567
3266
|
}
|
|
3568
3267
|
),
|
|
3569
3268
|
children
|
|
@@ -3572,10 +3271,7 @@ function DropdownMenuRadioItem({
|
|
|
3572
3271
|
);
|
|
3573
3272
|
}
|
|
3574
3273
|
__name(DropdownMenuRadioItem, "DropdownMenuRadioItem");
|
|
3575
|
-
function DropdownMenuSeparator({
|
|
3576
|
-
className,
|
|
3577
|
-
...props
|
|
3578
|
-
}) {
|
|
3274
|
+
function DropdownMenuSeparator({ className, ...props }) {
|
|
3579
3275
|
return /* @__PURE__ */ jsx25(
|
|
3580
3276
|
MenuPrimitive.Separator,
|
|
3581
3277
|
{
|
|
@@ -3586,15 +3282,15 @@ function DropdownMenuSeparator({
|
|
|
3586
3282
|
);
|
|
3587
3283
|
}
|
|
3588
3284
|
__name(DropdownMenuSeparator, "DropdownMenuSeparator");
|
|
3589
|
-
function DropdownMenuShortcut({
|
|
3590
|
-
className,
|
|
3591
|
-
...props
|
|
3592
|
-
}) {
|
|
3285
|
+
function DropdownMenuShortcut({ className, ...props }) {
|
|
3593
3286
|
return /* @__PURE__ */ jsx25(
|
|
3594
3287
|
"span",
|
|
3595
3288
|
{
|
|
3596
3289
|
"data-slot": "dropdown-menu-shortcut",
|
|
3597
|
-
className: cn(
|
|
3290
|
+
className: cn(
|
|
3291
|
+
"text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground ml-auto text-[0.625rem] tracking-widest",
|
|
3292
|
+
className
|
|
3293
|
+
),
|
|
3598
3294
|
...props
|
|
3599
3295
|
}
|
|
3600
3296
|
);
|
|
@@ -3625,11 +3321,7 @@ __name(Label, "Label");
|
|
|
3625
3321
|
// src/shadcnui/ui/separator.tsx
|
|
3626
3322
|
import { Separator as SeparatorPrimitive } from "@base-ui/react/separator";
|
|
3627
3323
|
import { jsx as jsx27 } from "react/jsx-runtime";
|
|
3628
|
-
function Separator({
|
|
3629
|
-
className,
|
|
3630
|
-
orientation = "horizontal",
|
|
3631
|
-
...props
|
|
3632
|
-
}) {
|
|
3324
|
+
function Separator({ className, orientation = "horizontal", ...props }) {
|
|
3633
3325
|
return /* @__PURE__ */ jsx27(
|
|
3634
3326
|
SeparatorPrimitive,
|
|
3635
3327
|
{
|
|
@@ -3652,7 +3344,10 @@ function FieldSet({ className, ...props }) {
|
|
|
3652
3344
|
"fieldset",
|
|
3653
3345
|
{
|
|
3654
3346
|
"data-slot": "field-set",
|
|
3655
|
-
className: cn(
|
|
3347
|
+
className: cn(
|
|
3348
|
+
"gap-4 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3 flex flex-col",
|
|
3349
|
+
className
|
|
3350
|
+
),
|
|
3656
3351
|
...props
|
|
3657
3352
|
}
|
|
3658
3353
|
);
|
|
@@ -3722,19 +3417,13 @@ function FieldContent({ className, ...props }) {
|
|
|
3722
3417
|
"div",
|
|
3723
3418
|
{
|
|
3724
3419
|
"data-slot": "field-content",
|
|
3725
|
-
className: cn(
|
|
3726
|
-
"gap-0.5 group/field-content flex flex-1 flex-col leading-snug",
|
|
3727
|
-
className
|
|
3728
|
-
),
|
|
3420
|
+
className: cn("gap-0.5 group/field-content flex flex-1 flex-col leading-snug", className),
|
|
3729
3421
|
...props
|
|
3730
3422
|
}
|
|
3731
3423
|
);
|
|
3732
3424
|
}
|
|
3733
3425
|
__name(FieldContent, "FieldContent");
|
|
3734
|
-
function FieldLabel({
|
|
3735
|
-
className,
|
|
3736
|
-
...props
|
|
3737
|
-
}) {
|
|
3426
|
+
function FieldLabel({ className, ...props }) {
|
|
3738
3427
|
return /* @__PURE__ */ jsx28(
|
|
3739
3428
|
Label,
|
|
3740
3429
|
{
|
|
@@ -3819,15 +3508,11 @@ function FieldError({
|
|
|
3819
3508
|
if (!errors?.length) {
|
|
3820
3509
|
return null;
|
|
3821
3510
|
}
|
|
3822
|
-
const uniqueErrors = [
|
|
3823
|
-
...new Map(errors.map((error) => [error?.message, error])).values()
|
|
3824
|
-
];
|
|
3511
|
+
const uniqueErrors = [...new Map(errors.map((error) => [error?.message, error])).values()];
|
|
3825
3512
|
if (uniqueErrors?.length == 1) {
|
|
3826
3513
|
return uniqueErrors[0]?.message;
|
|
3827
3514
|
}
|
|
3828
|
-
return /* @__PURE__ */ jsx28("ul", { className: "ml-4 flex list-disc flex-col gap-1", children: uniqueErrors.map(
|
|
3829
|
-
(error, index) => error?.message && /* @__PURE__ */ jsx28("li", { children: error.message }, index)
|
|
3830
|
-
) });
|
|
3515
|
+
return /* @__PURE__ */ jsx28("ul", { className: "ml-4 flex list-disc flex-col gap-1", children: uniqueErrors.map((error, index) => error?.message && /* @__PURE__ */ jsx28("li", { children: error.message }, index)) });
|
|
3831
3516
|
}, [children, errors]);
|
|
3832
3517
|
if (!content) {
|
|
3833
3518
|
return null;
|
|
@@ -3906,15 +3591,9 @@ function InputOTP({
|
|
|
3906
3591
|
OTPInput,
|
|
3907
3592
|
{
|
|
3908
3593
|
"data-slot": "input-otp",
|
|
3909
|
-
containerClassName: cn(
|
|
3910
|
-
"cn-input-otp flex items-center has-disabled:opacity-50",
|
|
3911
|
-
containerClassName
|
|
3912
|
-
),
|
|
3594
|
+
containerClassName: cn("cn-input-otp flex items-center has-disabled:opacity-50", containerClassName),
|
|
3913
3595
|
spellCheck: false,
|
|
3914
|
-
className: cn(
|
|
3915
|
-
"disabled:cursor-not-allowed",
|
|
3916
|
-
className
|
|
3917
|
-
),
|
|
3596
|
+
className: cn("disabled:cursor-not-allowed", className),
|
|
3918
3597
|
...props
|
|
3919
3598
|
}
|
|
3920
3599
|
);
|
|
@@ -3925,7 +3604,10 @@ function InputOTPGroup({ className, ...props }) {
|
|
|
3925
3604
|
"div",
|
|
3926
3605
|
{
|
|
3927
3606
|
"data-slot": "input-otp-group",
|
|
3928
|
-
className: cn(
|
|
3607
|
+
className: cn(
|
|
3608
|
+
"has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40 has-aria-invalid:border-destructive rounded-md has-aria-invalid:ring-[2px] flex items-center",
|
|
3609
|
+
className
|
|
3610
|
+
),
|
|
3929
3611
|
...props
|
|
3930
3612
|
}
|
|
3931
3613
|
);
|
|
@@ -3964,10 +3646,7 @@ function InputOTPSeparator({ ...props }) {
|
|
|
3964
3646
|
className: "[&_svg:not([class*='size-'])]:size-4 flex items-center",
|
|
3965
3647
|
role: "separator",
|
|
3966
3648
|
...props,
|
|
3967
|
-
children: /* @__PURE__ */ jsx30(
|
|
3968
|
-
MinusIcon,
|
|
3969
|
-
{}
|
|
3970
|
-
)
|
|
3649
|
+
children: /* @__PURE__ */ jsx30(MinusIcon, {})
|
|
3971
3650
|
}
|
|
3972
3651
|
);
|
|
3973
3652
|
}
|
|
@@ -3978,11 +3657,7 @@ import { NavigationMenu as NavigationMenuPrimitive } from "@base-ui/react/naviga
|
|
|
3978
3657
|
import { cva as cva6 } from "class-variance-authority";
|
|
3979
3658
|
import { ChevronDownIcon as ChevronDownIcon3 } from "lucide-react";
|
|
3980
3659
|
import { jsx as jsx31, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
3981
|
-
function NavigationMenu({
|
|
3982
|
-
className,
|
|
3983
|
-
children,
|
|
3984
|
-
...props
|
|
3985
|
-
}) {
|
|
3660
|
+
function NavigationMenu({ className, children, ...props }) {
|
|
3986
3661
|
return /* @__PURE__ */ jsxs14(
|
|
3987
3662
|
NavigationMenuPrimitive.Root,
|
|
3988
3663
|
{
|
|
@@ -4000,45 +3675,25 @@ function NavigationMenu({
|
|
|
4000
3675
|
);
|
|
4001
3676
|
}
|
|
4002
3677
|
__name(NavigationMenu, "NavigationMenu");
|
|
4003
|
-
function NavigationMenuList({
|
|
4004
|
-
className,
|
|
4005
|
-
...props
|
|
4006
|
-
}) {
|
|
3678
|
+
function NavigationMenuList({ className, ...props }) {
|
|
4007
3679
|
return /* @__PURE__ */ jsx31(
|
|
4008
3680
|
NavigationMenuPrimitive.List,
|
|
4009
3681
|
{
|
|
4010
3682
|
"data-slot": "navigation-menu-list",
|
|
4011
|
-
className: cn(
|
|
4012
|
-
"gap-0 group flex flex-1 list-none items-center justify-center",
|
|
4013
|
-
className
|
|
4014
|
-
),
|
|
3683
|
+
className: cn("gap-0 group flex flex-1 list-none items-center justify-center", className),
|
|
4015
3684
|
...props
|
|
4016
3685
|
}
|
|
4017
3686
|
);
|
|
4018
3687
|
}
|
|
4019
3688
|
__name(NavigationMenuList, "NavigationMenuList");
|
|
4020
|
-
function NavigationMenuItem({
|
|
4021
|
-
className,
|
|
4022
|
-
...props
|
|
4023
|
-
}) {
|
|
4024
|
-
return /* @__PURE__ */ jsx31(
|
|
4025
|
-
NavigationMenuPrimitive.Item,
|
|
4026
|
-
{
|
|
4027
|
-
"data-slot": "navigation-menu-item",
|
|
4028
|
-
className: cn("relative", className),
|
|
4029
|
-
...props
|
|
4030
|
-
}
|
|
4031
|
-
);
|
|
3689
|
+
function NavigationMenuItem({ className, ...props }) {
|
|
3690
|
+
return /* @__PURE__ */ jsx31(NavigationMenuPrimitive.Item, { "data-slot": "navigation-menu-item", className: cn("relative", className), ...props });
|
|
4032
3691
|
}
|
|
4033
3692
|
__name(NavigationMenuItem, "NavigationMenuItem");
|
|
4034
3693
|
var navigationMenuTriggerStyle = cva6(
|
|
4035
3694
|
"bg-background hover:bg-muted focus:bg-muted data-open:hover:bg-muted data-open:focus:bg-muted data-open:bg-muted/50 focus-visible:ring-ring/30 data-popup-open:bg-muted/50 data-popup-open:hover:bg-muted rounded-md px-2.5 py-1.5 text-xs/relaxed font-medium transition-all focus-visible:ring-[2px] focus-visible:outline-1 disabled:opacity-50 group/navigation-menu-trigger inline-flex h-9 w-max items-center justify-center disabled:pointer-events-none outline-none"
|
|
4036
3695
|
);
|
|
4037
|
-
function NavigationMenuTrigger({
|
|
4038
|
-
className,
|
|
4039
|
-
children,
|
|
4040
|
-
...props
|
|
4041
|
-
}) {
|
|
3696
|
+
function NavigationMenuTrigger({ className, children, ...props }) {
|
|
4042
3697
|
return /* @__PURE__ */ jsxs14(
|
|
4043
3698
|
NavigationMenuPrimitive.Trigger,
|
|
4044
3699
|
{
|
|
@@ -4048,16 +3703,19 @@ function NavigationMenuTrigger({
|
|
|
4048
3703
|
children: [
|
|
4049
3704
|
children,
|
|
4050
3705
|
" ",
|
|
4051
|
-
/* @__PURE__ */ jsx31(
|
|
3706
|
+
/* @__PURE__ */ jsx31(
|
|
3707
|
+
ChevronDownIcon3,
|
|
3708
|
+
{
|
|
3709
|
+
className: "relative top-[1px] ml-1 size-3 transition duration-300 group-data-open/navigation-menu-trigger:rotate-180 group-data-popup-open/navigation-menu-trigger:rotate-180",
|
|
3710
|
+
"aria-hidden": "true"
|
|
3711
|
+
}
|
|
3712
|
+
)
|
|
4052
3713
|
]
|
|
4053
3714
|
}
|
|
4054
3715
|
);
|
|
4055
3716
|
}
|
|
4056
3717
|
__name(NavigationMenuTrigger, "NavigationMenuTrigger");
|
|
4057
|
-
function NavigationMenuContent({
|
|
4058
|
-
className,
|
|
4059
|
-
...props
|
|
4060
|
-
}) {
|
|
3718
|
+
function NavigationMenuContent({ className, ...props }) {
|
|
4061
3719
|
return /* @__PURE__ */ jsx31(
|
|
4062
3720
|
NavigationMenuPrimitive.Content,
|
|
4063
3721
|
{
|
|
@@ -4096,24 +3754,21 @@ function NavigationMenuPositioner({
|
|
|
4096
3754
|
) });
|
|
4097
3755
|
}
|
|
4098
3756
|
__name(NavigationMenuPositioner, "NavigationMenuPositioner");
|
|
4099
|
-
function NavigationMenuLink({
|
|
4100
|
-
className,
|
|
4101
|
-
...props
|
|
4102
|
-
}) {
|
|
3757
|
+
function NavigationMenuLink({ className, ...props }) {
|
|
4103
3758
|
return /* @__PURE__ */ jsx31(
|
|
4104
3759
|
NavigationMenuPrimitive.Link,
|
|
4105
3760
|
{
|
|
4106
3761
|
"data-slot": "navigation-menu-link",
|
|
4107
|
-
className: cn(
|
|
3762
|
+
className: cn(
|
|
3763
|
+
"data-[active=true]:focus:bg-muted data-[active=true]:hover:bg-muted data-[active=true]:bg-muted/50 focus-visible:ring-ring/30 hover:bg-muted focus:bg-muted flex items-center gap-1.5 rounded-lg p-2 text-xs/relaxed transition-all outline-none focus-visible:ring-[2px] focus-visible:outline-1 [&_svg:not([class*='size-'])]:size-4",
|
|
3764
|
+
className
|
|
3765
|
+
),
|
|
4108
3766
|
...props
|
|
4109
3767
|
}
|
|
4110
3768
|
);
|
|
4111
3769
|
}
|
|
4112
3770
|
__name(NavigationMenuLink, "NavigationMenuLink");
|
|
4113
|
-
function NavigationMenuIndicator({
|
|
4114
|
-
className,
|
|
4115
|
-
...props
|
|
4116
|
-
}) {
|
|
3771
|
+
function NavigationMenuIndicator({ className, ...props }) {
|
|
4117
3772
|
return /* @__PURE__ */ jsx31(
|
|
4118
3773
|
NavigationMenuPrimitive.Icon,
|
|
4119
3774
|
{
|
|
@@ -4172,31 +3827,14 @@ function PopoverContent({
|
|
|
4172
3827
|
}
|
|
4173
3828
|
__name(PopoverContent, "PopoverContent");
|
|
4174
3829
|
function PopoverHeader({ className, ...props }) {
|
|
4175
|
-
return /* @__PURE__ */ jsx32(
|
|
4176
|
-
"div",
|
|
4177
|
-
{
|
|
4178
|
-
"data-slot": "popover-header",
|
|
4179
|
-
className: cn("flex flex-col gap-1 text-xs", className),
|
|
4180
|
-
...props
|
|
4181
|
-
}
|
|
4182
|
-
);
|
|
3830
|
+
return /* @__PURE__ */ jsx32("div", { "data-slot": "popover-header", className: cn("flex flex-col gap-1 text-xs", className), ...props });
|
|
4183
3831
|
}
|
|
4184
3832
|
__name(PopoverHeader, "PopoverHeader");
|
|
4185
3833
|
function PopoverTitle({ className, ...props }) {
|
|
4186
|
-
return /* @__PURE__ */ jsx32(
|
|
4187
|
-
PopoverPrimitive.Title,
|
|
4188
|
-
{
|
|
4189
|
-
"data-slot": "popover-title",
|
|
4190
|
-
className: cn("text-sm font-medium", className),
|
|
4191
|
-
...props
|
|
4192
|
-
}
|
|
4193
|
-
);
|
|
3834
|
+
return /* @__PURE__ */ jsx32(PopoverPrimitive.Title, { "data-slot": "popover-title", className: cn("text-sm font-medium", className), ...props });
|
|
4194
3835
|
}
|
|
4195
3836
|
__name(PopoverTitle, "PopoverTitle");
|
|
4196
|
-
function PopoverDescription({
|
|
4197
|
-
className,
|
|
4198
|
-
...props
|
|
4199
|
-
}) {
|
|
3837
|
+
function PopoverDescription({ className, ...props }) {
|
|
4200
3838
|
return /* @__PURE__ */ jsx32(
|
|
4201
3839
|
PopoverPrimitive.Description,
|
|
4202
3840
|
{
|
|
@@ -4211,12 +3849,7 @@ __name(PopoverDescription, "PopoverDescription");
|
|
|
4211
3849
|
// src/shadcnui/ui/progress.tsx
|
|
4212
3850
|
import { Progress as ProgressPrimitive } from "@base-ui/react/progress";
|
|
4213
3851
|
import { jsx as jsx33, jsxs as jsxs15 } from "react/jsx-runtime";
|
|
4214
|
-
function Progress({
|
|
4215
|
-
className,
|
|
4216
|
-
children,
|
|
4217
|
-
value,
|
|
4218
|
-
...props
|
|
4219
|
-
}) {
|
|
3852
|
+
function Progress({ className, children, value, ...props }) {
|
|
4220
3853
|
return /* @__PURE__ */ jsxs15(
|
|
4221
3854
|
ProgressPrimitive.Root,
|
|
4222
3855
|
{
|
|
@@ -4236,20 +3869,14 @@ function ProgressTrack({ className, ...props }) {
|
|
|
4236
3869
|
return /* @__PURE__ */ jsx33(
|
|
4237
3870
|
ProgressPrimitive.Track,
|
|
4238
3871
|
{
|
|
4239
|
-
className: cn(
|
|
4240
|
-
"bg-muted h-1 rounded-md relative flex w-full items-center overflow-x-hidden",
|
|
4241
|
-
className
|
|
4242
|
-
),
|
|
3872
|
+
className: cn("bg-muted h-1 rounded-md relative flex w-full items-center overflow-x-hidden", className),
|
|
4243
3873
|
"data-slot": "progress-track",
|
|
4244
3874
|
...props
|
|
4245
3875
|
}
|
|
4246
3876
|
);
|
|
4247
3877
|
}
|
|
4248
3878
|
__name(ProgressTrack, "ProgressTrack");
|
|
4249
|
-
function ProgressIndicator({
|
|
4250
|
-
className,
|
|
4251
|
-
...props
|
|
4252
|
-
}) {
|
|
3879
|
+
function ProgressIndicator({ className, ...props }) {
|
|
4253
3880
|
return /* @__PURE__ */ jsx33(
|
|
4254
3881
|
ProgressPrimitive.Indicator,
|
|
4255
3882
|
{
|
|
@@ -4289,14 +3916,7 @@ import { RadioGroup as RadioGroupPrimitive } from "@base-ui/react/radio-group";
|
|
|
4289
3916
|
import { CircleIcon } from "lucide-react";
|
|
4290
3917
|
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
4291
3918
|
function RadioGroup({ className, ...props }) {
|
|
4292
|
-
return /* @__PURE__ */ jsx34(
|
|
4293
|
-
RadioGroupPrimitive,
|
|
4294
|
-
{
|
|
4295
|
-
"data-slot": "radio-group",
|
|
4296
|
-
className: cn("grid gap-3 w-full", className),
|
|
4297
|
-
...props
|
|
4298
|
-
}
|
|
4299
|
-
);
|
|
3919
|
+
return /* @__PURE__ */ jsx34(RadioGroupPrimitive, { "data-slot": "radio-group", className: cn("grid gap-3 w-full", className), ...props });
|
|
4300
3920
|
}
|
|
4301
3921
|
__name(RadioGroup, "RadioGroup");
|
|
4302
3922
|
function RadioGroupItem({ className, ...props }) {
|
|
@@ -4325,26 +3945,18 @@ __name(RadioGroupItem, "RadioGroupItem");
|
|
|
4325
3945
|
// src/shadcnui/ui/resizable.tsx
|
|
4326
3946
|
import * as ResizablePrimitive from "react-resizable-panels";
|
|
4327
3947
|
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
4328
|
-
function ResizablePanelGroup({
|
|
4329
|
-
className,
|
|
4330
|
-
...props
|
|
4331
|
-
}) {
|
|
3948
|
+
function ResizablePanelGroup({ className, ...props }) {
|
|
4332
3949
|
return /* @__PURE__ */ jsx35(
|
|
4333
3950
|
ResizablePrimitive.PanelGroup,
|
|
4334
3951
|
{
|
|
4335
3952
|
"data-slot": "resizable-panel-group",
|
|
4336
|
-
className: cn(
|
|
4337
|
-
"flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
|
|
4338
|
-
className
|
|
4339
|
-
),
|
|
3953
|
+
className: cn("flex h-full w-full data-[panel-group-direction=vertical]:flex-col", className),
|
|
4340
3954
|
...props
|
|
4341
3955
|
}
|
|
4342
3956
|
);
|
|
4343
3957
|
}
|
|
4344
3958
|
__name(ResizablePanelGroup, "ResizablePanelGroup");
|
|
4345
|
-
function ResizablePanel({
|
|
4346
|
-
...props
|
|
4347
|
-
}) {
|
|
3959
|
+
function ResizablePanel({ ...props }) {
|
|
4348
3960
|
return /* @__PURE__ */ jsx35(ResizablePrimitive.Panel, { "data-slot": "resizable-panel", ...props });
|
|
4349
3961
|
}
|
|
4350
3962
|
__name(ResizablePanel, "ResizablePanel");
|
|
@@ -4371,38 +3983,22 @@ __name(ResizableHandle, "ResizableHandle");
|
|
|
4371
3983
|
// src/shadcnui/ui/scroll-area.tsx
|
|
4372
3984
|
import { ScrollArea as ScrollAreaPrimitive } from "@base-ui/react/scroll-area";
|
|
4373
3985
|
import { jsx as jsx36, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
4374
|
-
function ScrollArea({
|
|
4375
|
-
className,
|
|
4376
|
-
|
|
4377
|
-
|
|
4378
|
-
|
|
4379
|
-
|
|
4380
|
-
|
|
4381
|
-
|
|
4382
|
-
|
|
4383
|
-
|
|
4384
|
-
|
|
4385
|
-
|
|
4386
|
-
|
|
4387
|
-
ScrollAreaPrimitive.Viewport,
|
|
4388
|
-
{
|
|
4389
|
-
"data-slot": "scroll-area-viewport",
|
|
4390
|
-
className: "focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",
|
|
4391
|
-
children
|
|
4392
|
-
}
|
|
4393
|
-
),
|
|
4394
|
-
/* @__PURE__ */ jsx36(ScrollBar, {}),
|
|
4395
|
-
/* @__PURE__ */ jsx36(ScrollAreaPrimitive.Corner, {})
|
|
4396
|
-
]
|
|
4397
|
-
}
|
|
4398
|
-
);
|
|
3986
|
+
function ScrollArea({ className, children, ...props }) {
|
|
3987
|
+
return /* @__PURE__ */ jsxs16(ScrollAreaPrimitive.Root, { "data-slot": "scroll-area", className: cn("relative", className), ...props, children: [
|
|
3988
|
+
/* @__PURE__ */ jsx36(
|
|
3989
|
+
ScrollAreaPrimitive.Viewport,
|
|
3990
|
+
{
|
|
3991
|
+
"data-slot": "scroll-area-viewport",
|
|
3992
|
+
className: "focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",
|
|
3993
|
+
children
|
|
3994
|
+
}
|
|
3995
|
+
),
|
|
3996
|
+
/* @__PURE__ */ jsx36(ScrollBar, {}),
|
|
3997
|
+
/* @__PURE__ */ jsx36(ScrollAreaPrimitive.Corner, {})
|
|
3998
|
+
] });
|
|
4399
3999
|
}
|
|
4400
4000
|
__name(ScrollArea, "ScrollArea");
|
|
4401
|
-
function ScrollBar({
|
|
4402
|
-
className,
|
|
4403
|
-
orientation = "vertical",
|
|
4404
|
-
...props
|
|
4405
|
-
}) {
|
|
4001
|
+
function ScrollBar({ className, orientation = "vertical", ...props }) {
|
|
4406
4002
|
return /* @__PURE__ */ jsx36(
|
|
4407
4003
|
ScrollAreaPrimitive.Scrollbar,
|
|
4408
4004
|
{
|
|
@@ -4414,13 +4010,7 @@ function ScrollBar({
|
|
|
4414
4010
|
className
|
|
4415
4011
|
),
|
|
4416
4012
|
...props,
|
|
4417
|
-
children: /* @__PURE__ */ jsx36(
|
|
4418
|
-
ScrollAreaPrimitive.Thumb,
|
|
4419
|
-
{
|
|
4420
|
-
"data-slot": "scroll-area-thumb",
|
|
4421
|
-
className: "rounded-full bg-border relative flex-1"
|
|
4422
|
-
}
|
|
4423
|
-
)
|
|
4013
|
+
children: /* @__PURE__ */ jsx36(ScrollAreaPrimitive.Thumb, { "data-slot": "scroll-area-thumb", className: "rounded-full bg-border relative flex-1" })
|
|
4424
4014
|
}
|
|
4425
4015
|
);
|
|
4426
4016
|
}
|
|
@@ -4432,25 +4022,11 @@ import { ChevronDownIcon as ChevronDownIcon4, CheckIcon as CheckIcon5, ChevronUp
|
|
|
4432
4022
|
import { jsx as jsx37, jsxs as jsxs17 } from "react/jsx-runtime";
|
|
4433
4023
|
var Select = SelectPrimitive.Root;
|
|
4434
4024
|
function SelectGroup({ className, ...props }) {
|
|
4435
|
-
return /* @__PURE__ */ jsx37(
|
|
4436
|
-
SelectPrimitive.Group,
|
|
4437
|
-
{
|
|
4438
|
-
"data-slot": "select-group",
|
|
4439
|
-
className: cn("scroll-my-1 p-1", className),
|
|
4440
|
-
...props
|
|
4441
|
-
}
|
|
4442
|
-
);
|
|
4025
|
+
return /* @__PURE__ */ jsx37(SelectPrimitive.Group, { "data-slot": "select-group", className: cn("scroll-my-1 p-1", className), ...props });
|
|
4443
4026
|
}
|
|
4444
4027
|
__name(SelectGroup, "SelectGroup");
|
|
4445
4028
|
function SelectValue({ className, ...props }) {
|
|
4446
|
-
return /* @__PURE__ */ jsx37(
|
|
4447
|
-
SelectPrimitive.Value,
|
|
4448
|
-
{
|
|
4449
|
-
"data-slot": "select-value",
|
|
4450
|
-
className: cn("flex flex-1 text-left", className),
|
|
4451
|
-
...props
|
|
4452
|
-
}
|
|
4453
|
-
);
|
|
4029
|
+
return /* @__PURE__ */ jsx37(SelectPrimitive.Value, { "data-slot": "select-value", className: cn("flex flex-1 text-left", className), ...props });
|
|
4454
4030
|
}
|
|
4455
4031
|
__name(SelectValue, "SelectValue");
|
|
4456
4032
|
function SelectTrigger({
|
|
@@ -4505,7 +4081,10 @@ function SelectContent({
|
|
|
4505
4081
|
SelectPrimitive.Popup,
|
|
4506
4082
|
{
|
|
4507
4083
|
"data-slot": "select-content",
|
|
4508
|
-
className: cn(
|
|
4084
|
+
className: cn(
|
|
4085
|
+
"bg-popover text-popover-foreground data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 min-w-32 rounded-lg shadow-md ring-1 duration-100 relative isolate z-50 max-h-(--available-height) w-(--anchor-width) origin-(--transform-origin) overflow-x-hidden overflow-y-auto",
|
|
4086
|
+
className
|
|
4087
|
+
),
|
|
4509
4088
|
...props,
|
|
4510
4089
|
children: [
|
|
4511
4090
|
/* @__PURE__ */ jsx37(SelectScrollUpButton, {}),
|
|
@@ -4518,10 +4097,7 @@ function SelectContent({
|
|
|
4518
4097
|
) });
|
|
4519
4098
|
}
|
|
4520
4099
|
__name(SelectContent, "SelectContent");
|
|
4521
|
-
function SelectLabel({
|
|
4522
|
-
className,
|
|
4523
|
-
...props
|
|
4524
|
-
}) {
|
|
4100
|
+
function SelectLabel({ className, ...props }) {
|
|
4525
4101
|
return /* @__PURE__ */ jsx37(
|
|
4526
4102
|
SelectPrimitive.GroupLabel,
|
|
4527
4103
|
{
|
|
@@ -4532,11 +4108,7 @@ function SelectLabel({
|
|
|
4532
4108
|
);
|
|
4533
4109
|
}
|
|
4534
4110
|
__name(SelectLabel, "SelectLabel");
|
|
4535
|
-
function SelectItem({
|
|
4536
|
-
className,
|
|
4537
|
-
children,
|
|
4538
|
-
...props
|
|
4539
|
-
}) {
|
|
4111
|
+
function SelectItem({ className, children, ...props }) {
|
|
4540
4112
|
return /* @__PURE__ */ jsxs17(
|
|
4541
4113
|
SelectPrimitive.Item,
|
|
4542
4114
|
{
|
|
@@ -4560,10 +4132,7 @@ function SelectItem({
|
|
|
4560
4132
|
);
|
|
4561
4133
|
}
|
|
4562
4134
|
__name(SelectItem, "SelectItem");
|
|
4563
|
-
function SelectSeparator({
|
|
4564
|
-
className,
|
|
4565
|
-
...props
|
|
4566
|
-
}) {
|
|
4135
|
+
function SelectSeparator({ className, ...props }) {
|
|
4567
4136
|
return /* @__PURE__ */ jsx37(
|
|
4568
4137
|
SelectPrimitive.Separator,
|
|
4569
4138
|
{
|
|
@@ -4574,38 +4143,32 @@ function SelectSeparator({
|
|
|
4574
4143
|
);
|
|
4575
4144
|
}
|
|
4576
4145
|
__name(SelectSeparator, "SelectSeparator");
|
|
4577
|
-
function SelectScrollUpButton({
|
|
4578
|
-
className,
|
|
4579
|
-
...props
|
|
4580
|
-
}) {
|
|
4146
|
+
function SelectScrollUpButton({ className, ...props }) {
|
|
4581
4147
|
return /* @__PURE__ */ jsx37(
|
|
4582
4148
|
SelectPrimitive.ScrollUpArrow,
|
|
4583
4149
|
{
|
|
4584
4150
|
"data-slot": "select-scroll-up-button",
|
|
4585
|
-
className: cn(
|
|
4151
|
+
className: cn(
|
|
4152
|
+
"bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-3.5 top-0 w-full",
|
|
4153
|
+
className
|
|
4154
|
+
),
|
|
4586
4155
|
...props,
|
|
4587
|
-
children: /* @__PURE__ */ jsx37(
|
|
4588
|
-
ChevronUpIcon2,
|
|
4589
|
-
{}
|
|
4590
|
-
)
|
|
4156
|
+
children: /* @__PURE__ */ jsx37(ChevronUpIcon2, {})
|
|
4591
4157
|
}
|
|
4592
4158
|
);
|
|
4593
4159
|
}
|
|
4594
4160
|
__name(SelectScrollUpButton, "SelectScrollUpButton");
|
|
4595
|
-
function SelectScrollDownButton({
|
|
4596
|
-
className,
|
|
4597
|
-
...props
|
|
4598
|
-
}) {
|
|
4161
|
+
function SelectScrollDownButton({ className, ...props }) {
|
|
4599
4162
|
return /* @__PURE__ */ jsx37(
|
|
4600
4163
|
SelectPrimitive.ScrollDownArrow,
|
|
4601
4164
|
{
|
|
4602
4165
|
"data-slot": "select-scroll-down-button",
|
|
4603
|
-
className: cn(
|
|
4166
|
+
className: cn(
|
|
4167
|
+
"bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-3.5 bottom-0 w-full",
|
|
4168
|
+
className
|
|
4169
|
+
),
|
|
4604
4170
|
...props,
|
|
4605
|
-
children: /* @__PURE__ */ jsx37(
|
|
4606
|
-
ChevronDownIcon4,
|
|
4607
|
-
{}
|
|
4608
|
-
)
|
|
4171
|
+
children: /* @__PURE__ */ jsx37(ChevronDownIcon4, {})
|
|
4609
4172
|
}
|
|
4610
4173
|
);
|
|
4611
4174
|
}
|
|
@@ -4636,7 +4199,10 @@ function SheetOverlay({ className, ...props }) {
|
|
|
4636
4199
|
SheetPrimitive.Backdrop,
|
|
4637
4200
|
{
|
|
4638
4201
|
"data-slot": "sheet-overlay",
|
|
4639
|
-
className: cn(
|
|
4202
|
+
className: cn(
|
|
4203
|
+
"data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/80 duration-100 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50",
|
|
4204
|
+
className
|
|
4205
|
+
),
|
|
4640
4206
|
...props
|
|
4641
4207
|
}
|
|
4642
4208
|
);
|
|
@@ -4656,7 +4222,10 @@ function SheetContent({
|
|
|
4656
4222
|
{
|
|
4657
4223
|
"data-slot": "sheet-content",
|
|
4658
4224
|
"data-side": side,
|
|
4659
|
-
className: cn(
|
|
4225
|
+
className: cn(
|
|
4226
|
+
"bg-background data-open:animate-in data-closed:animate-out data-[side=right]:data-closed:slide-out-to-right-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=top]:data-closed:slide-out-to-top-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:fade-out-0 data-open:fade-in-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=bottom]:data-open:slide-in-from-bottom-10 fixed z-50 flex flex-col bg-clip-padding text-xs/relaxed shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm",
|
|
4227
|
+
className
|
|
4228
|
+
),
|
|
4660
4229
|
...props,
|
|
4661
4230
|
children: [
|
|
4662
4231
|
children,
|
|
@@ -4664,19 +4233,9 @@ function SheetContent({
|
|
|
4664
4233
|
SheetPrimitive.Close,
|
|
4665
4234
|
{
|
|
4666
4235
|
"data-slot": "sheet-close",
|
|
4667
|
-
render: /* @__PURE__ */ jsx38(
|
|
4668
|
-
Button,
|
|
4669
|
-
{
|
|
4670
|
-
variant: "ghost",
|
|
4671
|
-
className: "absolute top-4 right-4",
|
|
4672
|
-
size: "icon-sm"
|
|
4673
|
-
}
|
|
4674
|
-
),
|
|
4236
|
+
render: /* @__PURE__ */ jsx38(Button, { variant: "ghost", className: "absolute top-4 right-4", size: "icon-sm" }),
|
|
4675
4237
|
children: [
|
|
4676
|
-
/* @__PURE__ */ jsx38(
|
|
4677
|
-
XIcon2,
|
|
4678
|
-
{}
|
|
4679
|
-
),
|
|
4238
|
+
/* @__PURE__ */ jsx38(XIcon2, {}),
|
|
4680
4239
|
/* @__PURE__ */ jsx38("span", { className: "sr-only", children: "Close" })
|
|
4681
4240
|
]
|
|
4682
4241
|
}
|
|
@@ -4688,25 +4247,11 @@ function SheetContent({
|
|
|
4688
4247
|
}
|
|
4689
4248
|
__name(SheetContent, "SheetContent");
|
|
4690
4249
|
function SheetHeader({ className, ...props }) {
|
|
4691
|
-
return /* @__PURE__ */ jsx38(
|
|
4692
|
-
"div",
|
|
4693
|
-
{
|
|
4694
|
-
"data-slot": "sheet-header",
|
|
4695
|
-
className: cn("gap-1.5 p-6 flex flex-col", className),
|
|
4696
|
-
...props
|
|
4697
|
-
}
|
|
4698
|
-
);
|
|
4250
|
+
return /* @__PURE__ */ jsx38("div", { "data-slot": "sheet-header", className: cn("gap-1.5 p-6 flex flex-col", className), ...props });
|
|
4699
4251
|
}
|
|
4700
4252
|
__name(SheetHeader, "SheetHeader");
|
|
4701
4253
|
function SheetFooter({ className, ...props }) {
|
|
4702
|
-
return /* @__PURE__ */ jsx38(
|
|
4703
|
-
"div",
|
|
4704
|
-
{
|
|
4705
|
-
"data-slot": "sheet-footer",
|
|
4706
|
-
className: cn("gap-2 p-6 mt-auto flex flex-col", className),
|
|
4707
|
-
...props
|
|
4708
|
-
}
|
|
4709
|
-
);
|
|
4254
|
+
return /* @__PURE__ */ jsx38("div", { "data-slot": "sheet-footer", className: cn("gap-2 p-6 mt-auto flex flex-col", className), ...props });
|
|
4710
4255
|
}
|
|
4711
4256
|
__name(SheetFooter, "SheetFooter");
|
|
4712
4257
|
function SheetTitle({ className, ...props }) {
|
|
@@ -4718,12 +4263,9 @@ function SheetTitle({ className, ...props }) {
|
|
|
4718
4263
|
...props
|
|
4719
4264
|
}
|
|
4720
4265
|
);
|
|
4721
|
-
}
|
|
4722
|
-
__name(SheetTitle, "SheetTitle");
|
|
4723
|
-
function SheetDescription({
|
|
4724
|
-
className,
|
|
4725
|
-
...props
|
|
4726
|
-
}) {
|
|
4266
|
+
}
|
|
4267
|
+
__name(SheetTitle, "SheetTitle");
|
|
4268
|
+
function SheetDescription({ className, ...props }) {
|
|
4727
4269
|
return /* @__PURE__ */ jsx38(
|
|
4728
4270
|
SheetPrimitive.Description,
|
|
4729
4271
|
{
|
|
@@ -4744,32 +4286,15 @@ import { cva as cva7 } from "class-variance-authority";
|
|
|
4744
4286
|
// src/shadcnui/ui/skeleton.tsx
|
|
4745
4287
|
import { jsx as jsx39 } from "react/jsx-runtime";
|
|
4746
4288
|
function Skeleton({ className, ...props }) {
|
|
4747
|
-
return /* @__PURE__ */ jsx39(
|
|
4748
|
-
"div",
|
|
4749
|
-
{
|
|
4750
|
-
"data-slot": "skeleton",
|
|
4751
|
-
className: cn("bg-muted rounded-md animate-pulse", className),
|
|
4752
|
-
...props
|
|
4753
|
-
}
|
|
4754
|
-
);
|
|
4289
|
+
return /* @__PURE__ */ jsx39("div", { "data-slot": "skeleton", className: cn("bg-muted rounded-md animate-pulse", className), ...props });
|
|
4755
4290
|
}
|
|
4756
4291
|
__name(Skeleton, "Skeleton");
|
|
4757
4292
|
|
|
4758
4293
|
// src/shadcnui/ui/tooltip.tsx
|
|
4759
4294
|
import { Tooltip as TooltipPrimitive } from "@base-ui/react/tooltip";
|
|
4760
4295
|
import { jsx as jsx40, jsxs as jsxs19 } from "react/jsx-runtime";
|
|
4761
|
-
function TooltipProvider({
|
|
4762
|
-
delay
|
|
4763
|
-
...props
|
|
4764
|
-
}) {
|
|
4765
|
-
return /* @__PURE__ */ jsx40(
|
|
4766
|
-
TooltipPrimitive.Provider,
|
|
4767
|
-
{
|
|
4768
|
-
"data-slot": "tooltip-provider",
|
|
4769
|
-
delay,
|
|
4770
|
-
...props
|
|
4771
|
-
}
|
|
4772
|
-
);
|
|
4296
|
+
function TooltipProvider({ delay = 0, ...props }) {
|
|
4297
|
+
return /* @__PURE__ */ jsx40(TooltipPrimitive.Provider, { "data-slot": "tooltip-provider", delay, ...props });
|
|
4773
4298
|
}
|
|
4774
4299
|
__name(TooltipProvider, "TooltipProvider");
|
|
4775
4300
|
function Tooltip2({ ...props }) {
|
|
@@ -4895,10 +4420,7 @@ function SidebarProvider({
|
|
|
4895
4420
|
"--sidebar-width-icon": SIDEBAR_WIDTH_ICON,
|
|
4896
4421
|
...style
|
|
4897
4422
|
},
|
|
4898
|
-
className: cn(
|
|
4899
|
-
"group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",
|
|
4900
|
-
className
|
|
4901
|
-
),
|
|
4423
|
+
className: cn("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full", className),
|
|
4902
4424
|
...props,
|
|
4903
4425
|
children
|
|
4904
4426
|
}
|
|
@@ -4919,10 +4441,7 @@ function Sidebar({
|
|
|
4919
4441
|
"div",
|
|
4920
4442
|
{
|
|
4921
4443
|
"data-slot": "sidebar",
|
|
4922
|
-
className: cn(
|
|
4923
|
-
"bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",
|
|
4924
|
-
className
|
|
4925
|
-
),
|
|
4444
|
+
className: cn("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col", className),
|
|
4926
4445
|
...props,
|
|
4927
4446
|
children
|
|
4928
4447
|
}
|
|
@@ -5000,11 +4519,7 @@ function Sidebar({
|
|
|
5000
4519
|
);
|
|
5001
4520
|
}
|
|
5002
4521
|
__name(Sidebar, "Sidebar");
|
|
5003
|
-
function SidebarTrigger({
|
|
5004
|
-
className,
|
|
5005
|
-
onClick,
|
|
5006
|
-
...props
|
|
5007
|
-
}) {
|
|
4522
|
+
function SidebarTrigger({ className, onClick, ...props }) {
|
|
5008
4523
|
const { toggleSidebar } = useSidebar();
|
|
5009
4524
|
return /* @__PURE__ */ jsxs20(
|
|
5010
4525
|
Button,
|
|
@@ -5020,10 +4535,7 @@ function SidebarTrigger({
|
|
|
5020
4535
|
},
|
|
5021
4536
|
...props,
|
|
5022
4537
|
children: [
|
|
5023
|
-
/* @__PURE__ */ jsx41(
|
|
5024
|
-
PanelLeftIcon,
|
|
5025
|
-
{}
|
|
5026
|
-
),
|
|
4538
|
+
/* @__PURE__ */ jsx41(PanelLeftIcon, {}),
|
|
5027
4539
|
/* @__PURE__ */ jsx41("span", { className: "sr-only", children: "Toggle Sidebar" })
|
|
5028
4540
|
]
|
|
5029
4541
|
}
|
|
@@ -5069,10 +4581,7 @@ function SidebarInset({ className, ...props }) {
|
|
|
5069
4581
|
);
|
|
5070
4582
|
}
|
|
5071
4583
|
__name(SidebarInset, "SidebarInset");
|
|
5072
|
-
function SidebarInput({
|
|
5073
|
-
className,
|
|
5074
|
-
...props
|
|
5075
|
-
}) {
|
|
4584
|
+
function SidebarInput({ className, ...props }) {
|
|
5076
4585
|
return /* @__PURE__ */ jsx41(
|
|
5077
4586
|
Input,
|
|
5078
4587
|
{
|
|
@@ -5108,10 +4617,7 @@ function SidebarFooter({ className, ...props }) {
|
|
|
5108
4617
|
);
|
|
5109
4618
|
}
|
|
5110
4619
|
__name(SidebarFooter, "SidebarFooter");
|
|
5111
|
-
function SidebarSeparator({
|
|
5112
|
-
className,
|
|
5113
|
-
...props
|
|
5114
|
-
}) {
|
|
4620
|
+
function SidebarSeparator({ className, ...props }) {
|
|
5115
4621
|
return /* @__PURE__ */ jsx41(
|
|
5116
4622
|
Separator,
|
|
5117
4623
|
{
|
|
@@ -5144,10 +4650,7 @@ function SidebarGroup({ className, ...props }) {
|
|
|
5144
4650
|
{
|
|
5145
4651
|
"data-slot": "sidebar-group",
|
|
5146
4652
|
"data-sidebar": "group",
|
|
5147
|
-
className: cn(
|
|
5148
|
-
"px-2 py-1 relative flex w-full min-w-0 flex-col",
|
|
5149
|
-
className
|
|
5150
|
-
),
|
|
4653
|
+
className: cn("px-2 py-1 relative flex w-full min-w-0 flex-col", className),
|
|
5151
4654
|
...props
|
|
5152
4655
|
}
|
|
5153
4656
|
);
|
|
@@ -5201,10 +4704,7 @@ function SidebarGroupAction({
|
|
|
5201
4704
|
});
|
|
5202
4705
|
}
|
|
5203
4706
|
__name(SidebarGroupAction, "SidebarGroupAction");
|
|
5204
|
-
function SidebarGroupContent({
|
|
5205
|
-
className,
|
|
5206
|
-
...props
|
|
5207
|
-
}) {
|
|
4707
|
+
function SidebarGroupContent({ className, ...props }) {
|
|
5208
4708
|
return /* @__PURE__ */ jsx41(
|
|
5209
4709
|
"div",
|
|
5210
4710
|
{
|
|
@@ -5296,15 +4796,7 @@ function SidebarMenuButton({
|
|
|
5296
4796
|
}
|
|
5297
4797
|
return /* @__PURE__ */ jsxs20(Tooltip2, { children: [
|
|
5298
4798
|
comp,
|
|
5299
|
-
/* @__PURE__ */ jsx41(
|
|
5300
|
-
TooltipContent,
|
|
5301
|
-
{
|
|
5302
|
-
side: "right",
|
|
5303
|
-
align: "center",
|
|
5304
|
-
hidden: state !== "collapsed" || isMobile,
|
|
5305
|
-
...tooltip
|
|
5306
|
-
}
|
|
5307
|
-
)
|
|
4799
|
+
/* @__PURE__ */ jsx41(TooltipContent, { side: "right", align: "center", hidden: state !== "collapsed" || isMobile, ...tooltip })
|
|
5308
4800
|
] });
|
|
5309
4801
|
}
|
|
5310
4802
|
__name(SidebarMenuButton, "SidebarMenuButton");
|
|
@@ -5334,10 +4826,7 @@ function SidebarMenuAction({
|
|
|
5334
4826
|
});
|
|
5335
4827
|
}
|
|
5336
4828
|
__name(SidebarMenuAction, "SidebarMenuAction");
|
|
5337
|
-
function SidebarMenuBadge({
|
|
5338
|
-
className,
|
|
5339
|
-
...props
|
|
5340
|
-
}) {
|
|
4829
|
+
function SidebarMenuBadge({ className, ...props }) {
|
|
5341
4830
|
return /* @__PURE__ */ jsx41(
|
|
5342
4831
|
"div",
|
|
5343
4832
|
{
|
|
@@ -5368,13 +4857,7 @@ function SidebarMenuSkeleton({
|
|
|
5368
4857
|
className: cn("h-8 gap-2 rounded-md px-2 flex items-center", className),
|
|
5369
4858
|
...props,
|
|
5370
4859
|
children: [
|
|
5371
|
-
showIcon && /* @__PURE__ */ jsx41(
|
|
5372
|
-
Skeleton,
|
|
5373
|
-
{
|
|
5374
|
-
className: "size-4 rounded-md",
|
|
5375
|
-
"data-sidebar": "menu-skeleton-icon"
|
|
5376
|
-
}
|
|
5377
|
-
),
|
|
4860
|
+
showIcon && /* @__PURE__ */ jsx41(Skeleton, { className: "size-4 rounded-md", "data-sidebar": "menu-skeleton-icon" }),
|
|
5378
4861
|
/* @__PURE__ */ jsx41(
|
|
5379
4862
|
Skeleton,
|
|
5380
4863
|
{
|
|
@@ -5396,16 +4879,16 @@ function SidebarMenuSub({ className, ...props }) {
|
|
|
5396
4879
|
{
|
|
5397
4880
|
"data-slot": "sidebar-menu-sub",
|
|
5398
4881
|
"data-sidebar": "menu-sub",
|
|
5399
|
-
className: cn(
|
|
4882
|
+
className: cn(
|
|
4883
|
+
"border-sidebar-border mx-3.5 translate-x-px gap-1 border-l px-2.5 py-0.5 group-data-[collapsible=icon]:hidden flex min-w-0 flex-col",
|
|
4884
|
+
className
|
|
4885
|
+
),
|
|
5400
4886
|
...props
|
|
5401
4887
|
}
|
|
5402
4888
|
);
|
|
5403
4889
|
}
|
|
5404
4890
|
__name(SidebarMenuSub, "SidebarMenuSub");
|
|
5405
|
-
function SidebarMenuSubItem({
|
|
5406
|
-
className,
|
|
5407
|
-
...props
|
|
5408
|
-
}) {
|
|
4891
|
+
function SidebarMenuSubItem({ className, ...props }) {
|
|
5409
4892
|
return /* @__PURE__ */ jsx41(
|
|
5410
4893
|
"li",
|
|
5411
4894
|
{
|
|
@@ -5450,14 +4933,7 @@ __name(SidebarMenuSubButton, "SidebarMenuSubButton");
|
|
|
5450
4933
|
import * as React8 from "react";
|
|
5451
4934
|
import { Slider as SliderPrimitive } from "@base-ui/react/slider";
|
|
5452
4935
|
import { jsx as jsx42, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
5453
|
-
function Slider({
|
|
5454
|
-
className,
|
|
5455
|
-
defaultValue,
|
|
5456
|
-
value,
|
|
5457
|
-
min = 0,
|
|
5458
|
-
max = 100,
|
|
5459
|
-
...props
|
|
5460
|
-
}) {
|
|
4936
|
+
function Slider({ className, defaultValue, value, min = 0, max = 100, ...props }) {
|
|
5461
4937
|
const _values = React8.useMemo(
|
|
5462
4938
|
() => Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [min, max],
|
|
5463
4939
|
[value, defaultValue, min, max]
|
|
@@ -5651,20 +5127,13 @@ __name(TableCaption, "TableCaption");
|
|
|
5651
5127
|
import { Tabs as TabsPrimitive } from "@base-ui/react/tabs";
|
|
5652
5128
|
import { cva as cva8 } from "class-variance-authority";
|
|
5653
5129
|
import { jsx as jsx46 } from "react/jsx-runtime";
|
|
5654
|
-
function Tabs({
|
|
5655
|
-
className,
|
|
5656
|
-
orientation = "horizontal",
|
|
5657
|
-
...props
|
|
5658
|
-
}) {
|
|
5130
|
+
function Tabs({ className, orientation = "horizontal", ...props }) {
|
|
5659
5131
|
return /* @__PURE__ */ jsx46(
|
|
5660
5132
|
TabsPrimitive.Root,
|
|
5661
5133
|
{
|
|
5662
5134
|
"data-slot": "tabs",
|
|
5663
5135
|
"data-orientation": orientation,
|
|
5664
|
-
className: cn(
|
|
5665
|
-
"gap-2 group/tabs flex data-[orientation=horizontal]:flex-col",
|
|
5666
|
-
className
|
|
5667
|
-
),
|
|
5136
|
+
className: cn("gap-2 group/tabs flex data-[orientation=horizontal]:flex-col", className),
|
|
5668
5137
|
...props
|
|
5669
5138
|
}
|
|
5670
5139
|
);
|
|
@@ -5759,14 +5228,7 @@ function Toggle({
|
|
|
5759
5228
|
size = "default",
|
|
5760
5229
|
...props
|
|
5761
5230
|
}) {
|
|
5762
|
-
return /* @__PURE__ */ jsx47(
|
|
5763
|
-
TogglePrimitive,
|
|
5764
|
-
{
|
|
5765
|
-
"data-slot": "toggle",
|
|
5766
|
-
className: cn(toggleVariants({ variant, size, className })),
|
|
5767
|
-
...props
|
|
5768
|
-
}
|
|
5769
|
-
);
|
|
5231
|
+
return /* @__PURE__ */ jsx47(TogglePrimitive, { "data-slot": "toggle", className: cn(toggleVariants({ variant, size, className })), ...props });
|
|
5770
5232
|
}
|
|
5771
5233
|
__name(Toggle, "Toggle");
|
|
5772
5234
|
|
|
@@ -6523,7 +5985,7 @@ Link.displayName = "Link";
|
|
|
6523
5985
|
|
|
6524
5986
|
// src/shadcnui/custom/multi-select.tsx
|
|
6525
5987
|
import { cva as cva10 } from "class-variance-authority";
|
|
6526
|
-
import { CheckIcon as CheckIcon6, ChevronDown, WandSparkles, XCircle, XIcon as XIcon3 } from "lucide-react";
|
|
5988
|
+
import { CheckIcon as CheckIcon6, ChevronDown, Loader2 as Loader22, WandSparkles, XCircle, XIcon as XIcon3 } from "lucide-react";
|
|
6527
5989
|
import * as React11 from "react";
|
|
6528
5990
|
import { Fragment as Fragment3, jsx as jsx50, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
6529
5991
|
var multiSelectVariants = cva10(
|
|
@@ -6555,6 +6017,9 @@ var MultiSelect = React11.forwardRef(
|
|
|
6555
6017
|
modalPopover = false,
|
|
6556
6018
|
className,
|
|
6557
6019
|
onSearchChange,
|
|
6020
|
+
loading = false,
|
|
6021
|
+
loadingText = "Searching...",
|
|
6022
|
+
emptyText = "No results found.",
|
|
6558
6023
|
...props
|
|
6559
6024
|
}, _ref) => {
|
|
6560
6025
|
const [internalSelectedValues, setInternalSelectedValues] = React11.useState(defaultValue);
|
|
@@ -6701,8 +6166,9 @@ var MultiSelect = React11.forwardRef(
|
|
|
6701
6166
|
onValueChange: onSearchChange
|
|
6702
6167
|
}
|
|
6703
6168
|
),
|
|
6169
|
+
loading && /* @__PURE__ */ jsx50("div", { className: "flex items-center justify-center py-2", children: /* @__PURE__ */ jsx50(Loader22, { className: "text-muted-foreground h-4 w-4 animate-spin" }) }),
|
|
6704
6170
|
/* @__PURE__ */ jsxs22(CommandList, { children: [
|
|
6705
|
-
/* @__PURE__ */ jsx50(CommandEmpty, { children:
|
|
6171
|
+
/* @__PURE__ */ jsx50(CommandEmpty, { children: loading ? loadingText : emptyText }),
|
|
6706
6172
|
/* @__PURE__ */ jsxs22(CommandGroup, { children: [
|
|
6707
6173
|
/* @__PURE__ */ jsxs22(
|
|
6708
6174
|
CommandItem,
|
|
@@ -6847,7 +6313,7 @@ function UserDeleterInternal({ user, onDeleted, companyId }) {
|
|
|
6847
6313
|
const { currentUser, company } = useCurrentUserContext();
|
|
6848
6314
|
const generateUrl = usePageUrlGenerator();
|
|
6849
6315
|
const router = useI18nRouter();
|
|
6850
|
-
const
|
|
6316
|
+
const _t = useTranslations3();
|
|
6851
6317
|
let cId;
|
|
6852
6318
|
if (currentUser?.roles.find((role) => role.id === getRoleId().Administrator) && companyId) {
|
|
6853
6319
|
cId = companyId;
|
|
@@ -6941,7 +6407,7 @@ function UserEditorInternal({ user, propagateChanges, adminCreated, trigger, onR
|
|
|
6941
6407
|
errorToast({ title: t(`user.errors.email_exists`), error: "" });
|
|
6942
6408
|
return;
|
|
6943
6409
|
}
|
|
6944
|
-
} catch (
|
|
6410
|
+
} catch (_error) {
|
|
6945
6411
|
}
|
|
6946
6412
|
}
|
|
6947
6413
|
if (values.avatar && contentType) {
|
|
@@ -7136,6 +6602,7 @@ function UserEditor(props) {
|
|
|
7136
6602
|
__name(UserEditor, "UserEditor");
|
|
7137
6603
|
|
|
7138
6604
|
// src/features/user/components/forms/UserMultiSelect.tsx
|
|
6605
|
+
import { useTranslations as useTranslations12 } from "next-intl";
|
|
7139
6606
|
import { useCallback as useCallback11, useEffect as useEffect16, useRef as useRef10, useState as useState20 } from "react";
|
|
7140
6607
|
import { useWatch as useWatch2 } from "react-hook-form";
|
|
7141
6608
|
|
|
@@ -7402,7 +6869,7 @@ __name(CommonEditorHeader, "CommonEditorHeader");
|
|
|
7402
6869
|
import { PencilIcon } from "lucide-react";
|
|
7403
6870
|
import { useTranslations as useTranslations8 } from "next-intl";
|
|
7404
6871
|
import { jsx as jsx59 } from "react/jsx-runtime";
|
|
7405
|
-
function CommonEditorTrigger({ isEdit, edit, create }) {
|
|
6872
|
+
function CommonEditorTrigger({ isEdit, edit: _edit, create }) {
|
|
7406
6873
|
const t = useTranslations8();
|
|
7407
6874
|
return /* @__PURE__ */ jsx59(DialogTrigger, { children: isEdit ? /* @__PURE__ */ jsx59(Button, { render: /* @__PURE__ */ jsx59("div", {}), nativeButton: false, size: "sm", variant: `ghost`, className: "text-muted-foreground", children: /* @__PURE__ */ jsx59(PencilIcon, {}) }) : /* @__PURE__ */ jsx59(Button, { render: /* @__PURE__ */ jsx59("div", {}), nativeButton: false, size: "sm", variant: `outline`, children: create ? create : t(`ui.buttons.create`) }) });
|
|
7408
6875
|
}
|
|
@@ -7970,21 +7437,13 @@ function FormCheckbox({ form, id, name, labelBefore, description, isRequired })
|
|
|
7970
7437
|
/* @__PURE__ */ jsx64(TooltipContent, { children: description })
|
|
7971
7438
|
] });
|
|
7972
7439
|
}, "label");
|
|
7973
|
-
return /* @__PURE__ */ jsx64("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx64(
|
|
7974
|
-
|
|
7975
|
-
{
|
|
7976
|
-
|
|
7977
|
-
|
|
7978
|
-
|
|
7979
|
-
|
|
7980
|
-
labelBefore && label(),
|
|
7981
|
-
labelBefore && isRequired && /* @__PURE__ */ jsx64("span", { className: "text-destructive ml-2 font-semibold", children: "*" }),
|
|
7982
|
-
/* @__PURE__ */ jsx64(Checkbox, { id, defaultChecked: field.value, onCheckedChange: field.onChange }),
|
|
7983
|
-
!labelBefore && label(),
|
|
7984
|
-
!labelBefore && isRequired && /* @__PURE__ */ jsx64("span", { className: "text-destructive ml-2 font-semibold", children: "*" })
|
|
7985
|
-
] })
|
|
7986
|
-
}
|
|
7987
|
-
) });
|
|
7440
|
+
return /* @__PURE__ */ jsx64("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx64(FormFieldWrapper, { form, name: id, orientation: "horizontal", children: (field) => /* @__PURE__ */ jsxs34("div", { className: "flex gap-x-4", children: [
|
|
7441
|
+
labelBefore && label(),
|
|
7442
|
+
labelBefore && isRequired && /* @__PURE__ */ jsx64("span", { className: "text-destructive ml-2 font-semibold", children: "*" }),
|
|
7443
|
+
/* @__PURE__ */ jsx64(Checkbox, { id, defaultChecked: field.value, onCheckedChange: field.onChange }),
|
|
7444
|
+
!labelBefore && label(),
|
|
7445
|
+
!labelBefore && isRequired && /* @__PURE__ */ jsx64("span", { className: "text-destructive ml-2 font-semibold", children: "*" })
|
|
7446
|
+
] }) }) });
|
|
7988
7447
|
}
|
|
7989
7448
|
__name(FormCheckbox, "FormCheckbox");
|
|
7990
7449
|
|
|
@@ -8066,95 +7525,86 @@ function FormDate({
|
|
|
8066
7525
|
}
|
|
8067
7526
|
if (onChange) onChange(selectedDate);
|
|
8068
7527
|
}, "handleCalendarSelect");
|
|
8069
|
-
return /* @__PURE__ */ jsx65("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx65(
|
|
8070
|
-
|
|
8071
|
-
|
|
8072
|
-
|
|
8073
|
-
|
|
8074
|
-
|
|
8075
|
-
|
|
8076
|
-
|
|
8077
|
-
|
|
8078
|
-
|
|
8079
|
-
|
|
8080
|
-
|
|
8081
|
-
|
|
8082
|
-
|
|
8083
|
-
|
|
8084
|
-
|
|
8085
|
-
|
|
8086
|
-
|
|
8087
|
-
|
|
8088
|
-
|
|
8089
|
-
|
|
8090
|
-
|
|
8091
|
-
|
|
8092
|
-
|
|
8093
|
-
|
|
8094
|
-
field.onChange(void 0);
|
|
8095
|
-
setInputValue("");
|
|
8096
|
-
if (onChange) onChange(void 0);
|
|
8097
|
-
},
|
|
8098
|
-
children: /* @__PURE__ */ jsx65(CircleXIcon2, { className: "h-4 w-4 opacity-50 hover:opacity-100" })
|
|
8099
|
-
}
|
|
8100
|
-
)
|
|
8101
|
-
] })
|
|
8102
|
-
] }),
|
|
8103
|
-
/* @__PURE__ */ jsx65(PopoverContent, { className: "w-auto p-0", align: "start", children: /* @__PURE__ */ jsxs35("div", { className: "p-3", children: [
|
|
8104
|
-
/* @__PURE__ */ jsxs35("div", { className: "mb-3 flex gap-2", children: [
|
|
8105
|
-
/* @__PURE__ */ jsxs35(
|
|
8106
|
-
Select,
|
|
8107
|
-
{
|
|
8108
|
-
value: displayMonth.getMonth().toString(),
|
|
8109
|
-
onValueChange: (value) => {
|
|
8110
|
-
if (!value) return;
|
|
8111
|
-
const newMonth = parseInt(value);
|
|
8112
|
-
const newDate = new Date(displayMonth.getFullYear(), newMonth, 1);
|
|
8113
|
-
setDisplayMonth(newDate);
|
|
8114
|
-
},
|
|
8115
|
-
children: [
|
|
8116
|
-
/* @__PURE__ */ jsx65(SelectTrigger, { className: "w-[130px]", children: /* @__PURE__ */ jsx65(SelectValue, {}) }),
|
|
8117
|
-
/* @__PURE__ */ jsx65(SelectContent, { children: monthNames.map((month, index) => /* @__PURE__ */ jsx65(SelectItem, { value: index.toString(), children: month }, index)) })
|
|
8118
|
-
]
|
|
8119
|
-
}
|
|
8120
|
-
),
|
|
8121
|
-
/* @__PURE__ */ jsxs35(
|
|
8122
|
-
Select,
|
|
8123
|
-
{
|
|
8124
|
-
value: displayMonth.getFullYear().toString(),
|
|
8125
|
-
onValueChange: (value) => {
|
|
8126
|
-
if (!value) return;
|
|
8127
|
-
const newYear = parseInt(value);
|
|
8128
|
-
const newDate = new Date(newYear, displayMonth.getMonth(), 1);
|
|
8129
|
-
setDisplayMonth(newDate);
|
|
8130
|
-
},
|
|
8131
|
-
children: [
|
|
8132
|
-
/* @__PURE__ */ jsx65(SelectTrigger, { className: "w-[80px]", children: /* @__PURE__ */ jsx65(SelectValue, {}) }),
|
|
8133
|
-
/* @__PURE__ */ jsx65(SelectContent, { children: yearOptions.reverse().map((year) => /* @__PURE__ */ jsx65(SelectItem, { value: year.toString(), children: year }, year)) })
|
|
8134
|
-
]
|
|
8135
|
-
}
|
|
8136
|
-
)
|
|
8137
|
-
] }),
|
|
8138
|
-
/* @__PURE__ */ jsx65(
|
|
8139
|
-
Calendar,
|
|
8140
|
-
{
|
|
8141
|
-
mode: "single",
|
|
8142
|
-
selected: field.value,
|
|
8143
|
-
onSelect: (e) => {
|
|
8144
|
-
handleCalendarSelect(e, field);
|
|
8145
|
-
setOpen(false);
|
|
8146
|
-
},
|
|
8147
|
-
disabled: (date) => minDate && date < minDate ? true : false,
|
|
8148
|
-
locale: dateFnsLocale,
|
|
8149
|
-
weekStartsOn: 1,
|
|
8150
|
-
month: displayMonth,
|
|
8151
|
-
onMonthChange: setDisplayMonth
|
|
8152
|
-
}
|
|
8153
|
-
)
|
|
8154
|
-
] }) })
|
|
7528
|
+
return /* @__PURE__ */ jsx65("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx65(FormFieldWrapper, { form, name: id, label: name, isRequired, children: (field) => /* @__PURE__ */ jsxs35(Popover, { open, onOpenChange: setOpen, modal: true, children: [
|
|
7529
|
+
/* @__PURE__ */ jsxs35(InputGroup, { children: [
|
|
7530
|
+
/* @__PURE__ */ jsx65(
|
|
7531
|
+
InputGroupInput,
|
|
7532
|
+
{
|
|
7533
|
+
value: inputValue,
|
|
7534
|
+
onChange: (e) => handleInputChange(e.target.value, field),
|
|
7535
|
+
placeholder: datePlaceholder
|
|
7536
|
+
}
|
|
7537
|
+
),
|
|
7538
|
+
/* @__PURE__ */ jsxs35(InputGroupAddon, { align: "inline-end", children: [
|
|
7539
|
+
/* @__PURE__ */ jsx65(PopoverTrigger, { render: /* @__PURE__ */ jsx65("div", {}), nativeButton: false, children: /* @__PURE__ */ jsx65(InputGroupButton, { variant: "ghost", size: "icon-xs", children: /* @__PURE__ */ jsx65(CalendarIcon3, { className: "h-4 w-4 opacity-50" }) }) }),
|
|
7540
|
+
field.value && /* @__PURE__ */ jsx65(
|
|
7541
|
+
InputGroupButton,
|
|
7542
|
+
{
|
|
7543
|
+
variant: "ghost",
|
|
7544
|
+
size: "icon-xs",
|
|
7545
|
+
onClick: () => {
|
|
7546
|
+
field.onChange(void 0);
|
|
7547
|
+
setInputValue("");
|
|
7548
|
+
if (onChange) onChange(void 0);
|
|
7549
|
+
},
|
|
7550
|
+
children: /* @__PURE__ */ jsx65(CircleXIcon2, { className: "h-4 w-4 opacity-50 hover:opacity-100" })
|
|
7551
|
+
}
|
|
7552
|
+
)
|
|
8155
7553
|
] })
|
|
8156
|
-
}
|
|
8157
|
-
|
|
7554
|
+
] }),
|
|
7555
|
+
/* @__PURE__ */ jsx65(PopoverContent, { className: "w-auto p-0", align: "start", children: /* @__PURE__ */ jsxs35("div", { className: "p-3", children: [
|
|
7556
|
+
/* @__PURE__ */ jsxs35("div", { className: "mb-3 flex gap-2", children: [
|
|
7557
|
+
/* @__PURE__ */ jsxs35(
|
|
7558
|
+
Select,
|
|
7559
|
+
{
|
|
7560
|
+
value: displayMonth.getMonth().toString(),
|
|
7561
|
+
onValueChange: (value) => {
|
|
7562
|
+
if (!value) return;
|
|
7563
|
+
const newMonth = parseInt(value);
|
|
7564
|
+
const newDate = new Date(displayMonth.getFullYear(), newMonth, 1);
|
|
7565
|
+
setDisplayMonth(newDate);
|
|
7566
|
+
},
|
|
7567
|
+
children: [
|
|
7568
|
+
/* @__PURE__ */ jsx65(SelectTrigger, { className: "w-[130px]", children: /* @__PURE__ */ jsx65(SelectValue, {}) }),
|
|
7569
|
+
/* @__PURE__ */ jsx65(SelectContent, { children: monthNames.map((month, index) => /* @__PURE__ */ jsx65(SelectItem, { value: index.toString(), children: month }, index)) })
|
|
7570
|
+
]
|
|
7571
|
+
}
|
|
7572
|
+
),
|
|
7573
|
+
/* @__PURE__ */ jsxs35(
|
|
7574
|
+
Select,
|
|
7575
|
+
{
|
|
7576
|
+
value: displayMonth.getFullYear().toString(),
|
|
7577
|
+
onValueChange: (value) => {
|
|
7578
|
+
if (!value) return;
|
|
7579
|
+
const newYear = parseInt(value);
|
|
7580
|
+
const newDate = new Date(newYear, displayMonth.getMonth(), 1);
|
|
7581
|
+
setDisplayMonth(newDate);
|
|
7582
|
+
},
|
|
7583
|
+
children: [
|
|
7584
|
+
/* @__PURE__ */ jsx65(SelectTrigger, { className: "w-[80px]", children: /* @__PURE__ */ jsx65(SelectValue, {}) }),
|
|
7585
|
+
/* @__PURE__ */ jsx65(SelectContent, { children: yearOptions.reverse().map((year) => /* @__PURE__ */ jsx65(SelectItem, { value: year.toString(), children: year }, year)) })
|
|
7586
|
+
]
|
|
7587
|
+
}
|
|
7588
|
+
)
|
|
7589
|
+
] }),
|
|
7590
|
+
/* @__PURE__ */ jsx65(
|
|
7591
|
+
Calendar,
|
|
7592
|
+
{
|
|
7593
|
+
mode: "single",
|
|
7594
|
+
selected: field.value,
|
|
7595
|
+
onSelect: (e) => {
|
|
7596
|
+
handleCalendarSelect(e, field);
|
|
7597
|
+
setOpen(false);
|
|
7598
|
+
},
|
|
7599
|
+
disabled: (date) => minDate && date < minDate ? true : false,
|
|
7600
|
+
locale: dateFnsLocale,
|
|
7601
|
+
weekStartsOn: 1,
|
|
7602
|
+
month: displayMonth,
|
|
7603
|
+
onMonthChange: setDisplayMonth
|
|
7604
|
+
}
|
|
7605
|
+
)
|
|
7606
|
+
] }) })
|
|
7607
|
+
] }) }) });
|
|
8158
7608
|
}
|
|
8159
7609
|
__name(FormDate, "FormDate");
|
|
8160
7610
|
|
|
@@ -8359,7 +7809,7 @@ function FormInput({
|
|
|
8359
7809
|
try {
|
|
8360
7810
|
new URL(value);
|
|
8361
7811
|
form.clearErrors(id);
|
|
8362
|
-
} catch (
|
|
7812
|
+
} catch (_error) {
|
|
8363
7813
|
form.setError(id, {
|
|
8364
7814
|
type: "validate",
|
|
8365
7815
|
message: t(`common.errors.valid_url`)
|
|
@@ -8407,28 +7857,29 @@ import * as React12 from "react";
|
|
|
8407
7857
|
import { EyeIcon, EyeOffIcon } from "lucide-react";
|
|
8408
7858
|
import { useTranslations as useTranslations11 } from "next-intl";
|
|
8409
7859
|
import { jsx as jsx68, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
8410
|
-
var PasswordInput = React12.forwardRef(
|
|
8411
|
-
|
|
8412
|
-
|
|
8413
|
-
|
|
8414
|
-
|
|
8415
|
-
/* @__PURE__ */
|
|
8416
|
-
|
|
8417
|
-
|
|
8418
|
-
|
|
8419
|
-
|
|
8420
|
-
|
|
8421
|
-
|
|
8422
|
-
|
|
8423
|
-
|
|
8424
|
-
|
|
8425
|
-
|
|
8426
|
-
|
|
8427
|
-
|
|
8428
|
-
|
|
8429
|
-
|
|
8430
|
-
|
|
8431
|
-
|
|
7860
|
+
var PasswordInput = React12.forwardRef(
|
|
7861
|
+
({ className, type: _type, ...props }, ref) => {
|
|
7862
|
+
const [showPassword, setShowPassword] = React12.useState(false);
|
|
7863
|
+
const disabled = props.value === "" || props.value === void 0 || props.disabled;
|
|
7864
|
+
const t = useTranslations11();
|
|
7865
|
+
return /* @__PURE__ */ jsxs38("div", { className: "relative", children: [
|
|
7866
|
+
/* @__PURE__ */ jsx68(Input, { type: showPassword ? "text" : "password", className: cn("", className), ref, ...props }),
|
|
7867
|
+
/* @__PURE__ */ jsxs38(
|
|
7868
|
+
Button,
|
|
7869
|
+
{
|
|
7870
|
+
type: "button",
|
|
7871
|
+
variant: "ghost",
|
|
7872
|
+
size: "sm",
|
|
7873
|
+
className: "absolute right-0 top-0 h-full px-3 py-2 hover:bg-transparent",
|
|
7874
|
+
onClick: () => setShowPassword((prev) => !prev),
|
|
7875
|
+
disabled,
|
|
7876
|
+
children: [
|
|
7877
|
+
showPassword && !disabled ? /* @__PURE__ */ jsx68(EyeIcon, { className: "h-4 w-4", "aria-hidden": "true" }) : /* @__PURE__ */ jsx68(EyeOffIcon, { className: "h-4 w-4", "aria-hidden": "true" }),
|
|
7878
|
+
/* @__PURE__ */ jsx68("span", { className: "sr-only", children: showPassword ? t(`common.hide_password`) : t(`common.show_password`) })
|
|
7879
|
+
]
|
|
7880
|
+
}
|
|
7881
|
+
),
|
|
7882
|
+
/* @__PURE__ */ jsx68("style", { children: `
|
|
8432
7883
|
.hide-password-toggle::-ms-reveal,
|
|
8433
7884
|
.hide-password-toggle::-ms-clear {
|
|
8434
7885
|
visibility: hidden;
|
|
@@ -8436,8 +7887,9 @@ var PasswordInput = React12.forwardRef(({ className, type, ...props }, ref) => {
|
|
|
8436
7887
|
display: none;
|
|
8437
7888
|
}
|
|
8438
7889
|
` })
|
|
8439
|
-
|
|
8440
|
-
}
|
|
7890
|
+
] });
|
|
7891
|
+
}
|
|
7892
|
+
);
|
|
8441
7893
|
PasswordInput.displayName = "PasswordInput";
|
|
8442
7894
|
|
|
8443
7895
|
// src/components/forms/FormPassword.tsx
|
|
@@ -8452,27 +7904,17 @@ function FormPassword({
|
|
|
8452
7904
|
testId,
|
|
8453
7905
|
isRequired
|
|
8454
7906
|
}) {
|
|
8455
|
-
return /* @__PURE__ */ jsx69("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx69(
|
|
8456
|
-
|
|
7907
|
+
return /* @__PURE__ */ jsx69("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx69(FormFieldWrapper, { form, name: id, label: name, isRequired, testId, children: (field) => /* @__PURE__ */ jsx69(
|
|
7908
|
+
PasswordInput,
|
|
8457
7909
|
{
|
|
8458
|
-
|
|
8459
|
-
|
|
8460
|
-
|
|
8461
|
-
|
|
8462
|
-
|
|
8463
|
-
|
|
8464
|
-
PasswordInput,
|
|
8465
|
-
{
|
|
8466
|
-
...field,
|
|
8467
|
-
className: "w-full",
|
|
8468
|
-
disabled: disabled === true || form.formState.isSubmitting,
|
|
8469
|
-
placeholder: placeholder ? placeholder : "",
|
|
8470
|
-
onBlur,
|
|
8471
|
-
"data-testid": testId
|
|
8472
|
-
}
|
|
8473
|
-
)
|
|
7910
|
+
...field,
|
|
7911
|
+
className: "w-full",
|
|
7912
|
+
disabled: disabled === true || form.formState.isSubmitting,
|
|
7913
|
+
placeholder: placeholder ? placeholder : "",
|
|
7914
|
+
onBlur,
|
|
7915
|
+
"data-testid": testId
|
|
8474
7916
|
}
|
|
8475
|
-
) });
|
|
7917
|
+
) }) });
|
|
8476
7918
|
}
|
|
8477
7919
|
__name(FormPassword, "FormPassword");
|
|
8478
7920
|
|
|
@@ -8651,7 +8093,7 @@ function FormSelect({
|
|
|
8651
8093
|
form,
|
|
8652
8094
|
id,
|
|
8653
8095
|
name,
|
|
8654
|
-
placeholder,
|
|
8096
|
+
placeholder: _placeholder,
|
|
8655
8097
|
disabled,
|
|
8656
8098
|
values,
|
|
8657
8099
|
onChange,
|
|
@@ -8698,48 +8140,32 @@ function FormSlider({
|
|
|
8698
8140
|
showPercentage
|
|
8699
8141
|
}) {
|
|
8700
8142
|
const value = useWatch({ control: form.control, name: id });
|
|
8701
|
-
return /* @__PURE__ */ jsx72("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx72(
|
|
8702
|
-
|
|
8703
|
-
|
|
8704
|
-
|
|
8705
|
-
|
|
8706
|
-
|
|
8707
|
-
|
|
8708
|
-
|
|
8709
|
-
|
|
8710
|
-
|
|
8711
|
-
|
|
8712
|
-
|
|
8713
|
-
|
|
8714
|
-
|
|
8715
|
-
|
|
8716
|
-
|
|
8717
|
-
max: 100,
|
|
8718
|
-
step: 5,
|
|
8719
|
-
disabled: disabled === true || form.formState.isSubmitting
|
|
8720
|
-
}
|
|
8721
|
-
)
|
|
8722
|
-
] })
|
|
8723
|
-
}
|
|
8724
|
-
) });
|
|
8143
|
+
return /* @__PURE__ */ jsx72("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx72(FormFieldWrapper, { form, name: id, label: name, children: () => /* @__PURE__ */ jsxs41("div", { children: [
|
|
8144
|
+
showPercentage && /* @__PURE__ */ jsx72("div", { className: "text-muted-foreground mb-2 flex w-full justify-center text-xs", children: `${value}%` }),
|
|
8145
|
+
/* @__PURE__ */ jsx72(
|
|
8146
|
+
Slider,
|
|
8147
|
+
{
|
|
8148
|
+
onValueChange: (val) => {
|
|
8149
|
+
const newValue = Array.isArray(val) ? val[0] : val;
|
|
8150
|
+
form.setValue(id, newValue);
|
|
8151
|
+
},
|
|
8152
|
+
value: [value],
|
|
8153
|
+
max: 100,
|
|
8154
|
+
step: 5,
|
|
8155
|
+
disabled: disabled === true || form.formState.isSubmitting
|
|
8156
|
+
}
|
|
8157
|
+
)
|
|
8158
|
+
] }) }) });
|
|
8725
8159
|
}
|
|
8726
8160
|
__name(FormSlider, "FormSlider");
|
|
8727
8161
|
|
|
8728
8162
|
// src/components/forms/FormSwitch.tsx
|
|
8729
8163
|
import { jsx as jsx73, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
8730
8164
|
function FormSwitch({ form, id, name, disabled }) {
|
|
8731
|
-
return /* @__PURE__ */ jsx73("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx73(
|
|
8732
|
-
|
|
8733
|
-
{
|
|
8734
|
-
|
|
8735
|
-
name: id,
|
|
8736
|
-
orientation: "horizontal",
|
|
8737
|
-
children: (field) => /* @__PURE__ */ jsxs42("div", { className: "flex flex-row gap-x-4", children: [
|
|
8738
|
-
/* @__PURE__ */ jsx73(Switch, { checked: field.value, onCheckedChange: field.onChange, disabled }),
|
|
8739
|
-
name && /* @__PURE__ */ jsx73(FieldLabel, { children: name })
|
|
8740
|
-
] })
|
|
8741
|
-
}
|
|
8742
|
-
) });
|
|
8165
|
+
return /* @__PURE__ */ jsx73("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx73(FormFieldWrapper, { form, name: id, orientation: "horizontal", children: (field) => /* @__PURE__ */ jsxs42("div", { className: "flex flex-row gap-x-4", children: [
|
|
8166
|
+
/* @__PURE__ */ jsx73(Switch, { checked: field.value, onCheckedChange: field.onChange, disabled }),
|
|
8167
|
+
name && /* @__PURE__ */ jsx73(FieldLabel, { children: name })
|
|
8168
|
+
] }) }) });
|
|
8743
8169
|
}
|
|
8744
8170
|
__name(FormSwitch, "FormSwitch");
|
|
8745
8171
|
|
|
@@ -8776,14 +8202,7 @@ function GdprConsentCheckbox({
|
|
|
8776
8202
|
required
|
|
8777
8203
|
}) {
|
|
8778
8204
|
return /* @__PURE__ */ jsx75(FormFieldWrapper, { form, name: id, orientation: "horizontal", children: (field) => /* @__PURE__ */ jsxs43("div", { className: "flex flex-row items-start space-x-3 space-y-0", children: [
|
|
8779
|
-
/* @__PURE__ */ jsx75(
|
|
8780
|
-
Checkbox,
|
|
8781
|
-
{
|
|
8782
|
-
checked: field.value,
|
|
8783
|
-
onCheckedChange: field.onChange,
|
|
8784
|
-
"aria-required": required
|
|
8785
|
-
}
|
|
8786
|
-
),
|
|
8205
|
+
/* @__PURE__ */ jsx75(Checkbox, { checked: field.value, onCheckedChange: field.onChange, "aria-required": required }),
|
|
8787
8206
|
/* @__PURE__ */ jsxs43("div", { className: "space-y-1 leading-none", children: [
|
|
8788
8207
|
/* @__PURE__ */ jsxs43("span", { className: "text-sm font-normal", children: [
|
|
8789
8208
|
label,
|
|
@@ -8863,9 +8282,10 @@ function UserMultiSelect({
|
|
|
8863
8282
|
maxCount = 3,
|
|
8864
8283
|
isRequired = false
|
|
8865
8284
|
}) {
|
|
8285
|
+
const t = useTranslations12();
|
|
8866
8286
|
const { company } = useCurrentUserContext();
|
|
8867
8287
|
const searchTermRef = useRef10("");
|
|
8868
|
-
const [searchTerm,
|
|
8288
|
+
const [searchTerm, _setSearchTerm] = useState20("");
|
|
8869
8289
|
const [isSearching, setIsSearching] = useState20(false);
|
|
8870
8290
|
const [userOptions, setUserOptions] = useState20([]);
|
|
8871
8291
|
const selectedUsers = useWatch2({ control: form.control, name: id }) || [];
|
|
@@ -8956,7 +8376,10 @@ function UserMultiSelect({
|
|
|
8956
8376
|
defaultValue: selectedUserIds,
|
|
8957
8377
|
placeholder,
|
|
8958
8378
|
maxCount,
|
|
8959
|
-
animation: 0
|
|
8379
|
+
animation: 0,
|
|
8380
|
+
loading: isSearching,
|
|
8381
|
+
loadingText: t("ui.search.button"),
|
|
8382
|
+
emptyText: t("ui.search.no_results", { type: t("entities.users", { count: 2 }) })
|
|
8960
8383
|
}
|
|
8961
8384
|
) }) });
|
|
8962
8385
|
}
|
|
@@ -8964,12 +8387,12 @@ __name(UserMultiSelect, "UserMultiSelect");
|
|
|
8964
8387
|
|
|
8965
8388
|
// src/features/user/components/forms/UserReactivator.tsx
|
|
8966
8389
|
import { UserCheckIcon } from "lucide-react";
|
|
8967
|
-
import { useTranslations as
|
|
8390
|
+
import { useTranslations as useTranslations13 } from "next-intl";
|
|
8968
8391
|
import { useState as useState21 } from "react";
|
|
8969
8392
|
import { jsx as jsx79, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
8970
8393
|
function UserReactivatorInterface({ user, propagateChanges }) {
|
|
8971
8394
|
const [open, setOpen] = useState21(false);
|
|
8972
|
-
const t =
|
|
8395
|
+
const t = useTranslations13();
|
|
8973
8396
|
const reactivateUser = /* @__PURE__ */ __name(async () => {
|
|
8974
8397
|
try {
|
|
8975
8398
|
const updatedUser = await UserService.reactivate({ userId: user.id });
|
|
@@ -9017,12 +8440,12 @@ __name(UserReactivator, "UserReactivator");
|
|
|
9017
8440
|
|
|
9018
8441
|
// src/features/user/components/forms/UserResentInvitationEmail.tsx
|
|
9019
8442
|
import { MailIcon } from "lucide-react";
|
|
9020
|
-
import { useTranslations as
|
|
8443
|
+
import { useTranslations as useTranslations14 } from "next-intl";
|
|
9021
8444
|
import { useState as useState22 } from "react";
|
|
9022
8445
|
import { jsx as jsx80, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
9023
8446
|
function UserResentInvitationEmailInternal({ user }) {
|
|
9024
8447
|
const [open, setOpen] = useState22(false);
|
|
9025
|
-
const t =
|
|
8448
|
+
const t = useTranslations14();
|
|
9026
8449
|
const sendInvitationEmail = /* @__PURE__ */ __name(async () => {
|
|
9027
8450
|
try {
|
|
9028
8451
|
await UserService.sendInvitation({ userId: user.id, companyId: user.company.id });
|
|
@@ -9072,7 +8495,7 @@ __name(UserResentInvitationEmail, "UserResentInvitationEmail");
|
|
|
9072
8495
|
|
|
9073
8496
|
// src/features/user/components/forms/UserSelector.tsx
|
|
9074
8497
|
import { CircleX, RefreshCwIcon, SearchIcon as SearchIcon2, XIcon as XIcon5 } from "lucide-react";
|
|
9075
|
-
import { useTranslations as
|
|
8498
|
+
import { useTranslations as useTranslations15 } from "next-intl";
|
|
9076
8499
|
import { useCallback as useCallback12, useEffect as useEffect17, useRef as useRef11, useState as useState23 } from "react";
|
|
9077
8500
|
|
|
9078
8501
|
// src/features/user/components/widgets/UserAvatar.tsx
|
|
@@ -9125,7 +8548,7 @@ __name(UserAvatar, "UserAvatar");
|
|
|
9125
8548
|
// src/features/user/components/forms/UserSelector.tsx
|
|
9126
8549
|
import { Fragment as Fragment6, jsx as jsx82, jsxs as jsxs50 } from "react/jsx-runtime";
|
|
9127
8550
|
function UserSelector({ id, form, label, placeholder, onChange, isRequired = false }) {
|
|
9128
|
-
const t =
|
|
8551
|
+
const t = useTranslations15();
|
|
9129
8552
|
const [open, setOpen] = useState23(false);
|
|
9130
8553
|
const searchTermRef = useRef11("");
|
|
9131
8554
|
const [searchTerm, setSearchTerm] = useState23("");
|
|
@@ -9232,7 +8655,7 @@ var UserContext = createContext9(void 0);
|
|
|
9232
8655
|
var UserProvider = /* @__PURE__ */ __name(({ children, dehydratedUser }) => {
|
|
9233
8656
|
const generateUrl = usePageUrlGenerator();
|
|
9234
8657
|
const { hasPermissionToModule } = useCurrentUserContext();
|
|
9235
|
-
const t =
|
|
8658
|
+
const t = useTranslations16();
|
|
9236
8659
|
const [user, setUser] = useState24(
|
|
9237
8660
|
dehydratedUser ? rehydrate(Modules.User, dehydratedUser) : void 0
|
|
9238
8661
|
);
|
|
@@ -9294,19 +8717,19 @@ var useUserContext = /* @__PURE__ */ __name(() => {
|
|
|
9294
8717
|
}, "useUserContext");
|
|
9295
8718
|
|
|
9296
8719
|
// src/features/user/components/containers/UserContainer.tsx
|
|
9297
|
-
import { useTranslations as
|
|
8720
|
+
import { useTranslations as useTranslations18 } from "next-intl";
|
|
9298
8721
|
|
|
9299
8722
|
// src/features/user/components/details/UserDetails.tsx
|
|
9300
|
-
import { useTranslations as
|
|
8723
|
+
import { useTranslations as useTranslations17 } from "next-intl";
|
|
9301
8724
|
import Image4 from "next/image";
|
|
9302
8725
|
import { Fragment as Fragment7, jsx as jsx84, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
9303
8726
|
function UserDetails({ user }) {
|
|
9304
8727
|
const generateUrl = usePageUrlGenerator();
|
|
9305
|
-
const t =
|
|
8728
|
+
const t = useTranslations17();
|
|
9306
8729
|
const { title } = useSharedContext();
|
|
9307
8730
|
let roles = /* @__PURE__ */ jsx84(Fragment7, {});
|
|
9308
8731
|
if (user.roles && user.roles.length > 0) {
|
|
9309
|
-
roles = /* @__PURE__ */ jsx84("div", { className: "mb-4 w-full", children: /* @__PURE__ */ jsx84("div", { className: "flex flex-wrap gap-2", children: user.roles.map((role,
|
|
8732
|
+
roles = /* @__PURE__ */ jsx84("div", { className: "mb-4 w-full", children: /* @__PURE__ */ jsx84("div", { className: "flex flex-wrap gap-2", children: user.roles.map((role, _index) => /* @__PURE__ */ jsx84(Link, { href: generateUrl({ page: Modules.Role, id: role.id }), children: /* @__PURE__ */ jsx84(Badge, { className: "mr-2", variant: `default`, children: t(`role.roles`, { role: role.id.replaceAll(`-`, ``) }) }) }, role.id)) }) });
|
|
9310
8733
|
}
|
|
9311
8734
|
return /* @__PURE__ */ jsxs51("div", { className: "flex w-full flex-col gap-y-2", children: [
|
|
9312
8735
|
user.avatar && /* @__PURE__ */ jsx84("div", { className: "relative aspect-auto w-full max-w-md overflow-hidden rounded-lg", children: /* @__PURE__ */ jsx84(
|
|
@@ -9350,7 +8773,7 @@ import { jsx as jsx86, jsxs as jsxs53 } from "react/jsx-runtime";
|
|
|
9350
8773
|
function UserContainer() {
|
|
9351
8774
|
const { user } = useUserContext();
|
|
9352
8775
|
if (!user) return null;
|
|
9353
|
-
const
|
|
8776
|
+
const _t = useTranslations18();
|
|
9354
8777
|
return /* @__PURE__ */ jsxs53("div", { className: "flex w-full gap-x-4", children: [
|
|
9355
8778
|
/* @__PURE__ */ jsx86("div", { className: "w-2xl flex h-[calc(100vh-theme(spacing.20))] flex-col justify-between border-r pr-4", children: /* @__PURE__ */ jsx86("div", { className: "flex h-full overflow-y-auto", children: /* @__PURE__ */ jsx86(UserDetails, { user }) }) }),
|
|
9356
8779
|
/* @__PURE__ */ jsx86("div", { className: "flex w-full flex-col gap-y-4" })
|
|
@@ -9368,11 +8791,11 @@ function UserIndexContainer() {
|
|
|
9368
8791
|
__name(UserIndexContainer, "UserIndexContainer");
|
|
9369
8792
|
|
|
9370
8793
|
// src/features/user/components/containers/UsersListContainer.tsx
|
|
9371
|
-
import { useTranslations as
|
|
8794
|
+
import { useTranslations as useTranslations19 } from "next-intl";
|
|
9372
8795
|
import { jsx as jsx88 } from "react/jsx-runtime";
|
|
9373
8796
|
function UsersListContainerInternal() {
|
|
9374
8797
|
const { hasPermissionToModule } = useCurrentUserContext();
|
|
9375
|
-
const t =
|
|
8798
|
+
const t = useTranslations19();
|
|
9376
8799
|
if (!hasPermissionToModule({ module: Modules.User, action: "delete" /* Delete */ })) return /* @__PURE__ */ jsx88(CompanyUsersList, {});
|
|
9377
8800
|
const tabs = [
|
|
9378
8801
|
{
|
|
@@ -9397,10 +8820,10 @@ function UsersListContainer() {
|
|
|
9397
8820
|
__name(UsersListContainer, "UsersListContainer");
|
|
9398
8821
|
|
|
9399
8822
|
// src/features/user/components/lists/AdminUsersList.tsx
|
|
9400
|
-
import { useTranslations as
|
|
8823
|
+
import { useTranslations as useTranslations20 } from "next-intl";
|
|
9401
8824
|
import { jsx as jsx89 } from "react/jsx-runtime";
|
|
9402
8825
|
function AdminUsersListInternal({ company }) {
|
|
9403
|
-
const t =
|
|
8826
|
+
const t = useTranslations20();
|
|
9404
8827
|
const data = useDataListRetriever({
|
|
9405
8828
|
retriever: /* @__PURE__ */ __name((params) => UserService.findManyForAmin(params), "retriever"),
|
|
9406
8829
|
retrieverParams: { companyId: company.id },
|
|
@@ -9426,12 +8849,12 @@ function AdminUsersList() {
|
|
|
9426
8849
|
__name(AdminUsersList, "AdminUsersList");
|
|
9427
8850
|
|
|
9428
8851
|
// src/features/user/components/lists/CompanyUsersList.tsx
|
|
9429
|
-
import { useTranslations as
|
|
8852
|
+
import { useTranslations as useTranslations21 } from "next-intl";
|
|
9430
8853
|
import { useEffect as useEffect18 } from "react";
|
|
9431
8854
|
import { jsx as jsx90 } from "react/jsx-runtime";
|
|
9432
8855
|
function CompanyUsersList({ isDeleted }) {
|
|
9433
8856
|
const { company } = useCurrentUserContext();
|
|
9434
|
-
const t =
|
|
8857
|
+
const t = useTranslations21();
|
|
9435
8858
|
const data = useDataListRetriever({
|
|
9436
8859
|
ready: !!company,
|
|
9437
8860
|
retriever: /* @__PURE__ */ __name((params) => UserService.findAllUsers(params), "retriever"),
|
|
@@ -9485,10 +8908,10 @@ function ContributorsList({ content }) {
|
|
|
9485
8908
|
__name(ContributorsList, "ContributorsList");
|
|
9486
8909
|
|
|
9487
8910
|
// src/features/user/components/lists/RelevantUsersList.tsx
|
|
9488
|
-
import { useTranslations as
|
|
8911
|
+
import { useTranslations as useTranslations22 } from "next-intl";
|
|
9489
8912
|
import { jsx as jsx92 } from "react/jsx-runtime";
|
|
9490
8913
|
function RelevantUsersList({ id }) {
|
|
9491
|
-
const t =
|
|
8914
|
+
const t = useTranslations22();
|
|
9492
8915
|
const data = useDataListRetriever({
|
|
9493
8916
|
module: Modules.User,
|
|
9494
8917
|
retriever: /* @__PURE__ */ __name((params) => UserService.findRelevant(params), "retriever"),
|
|
@@ -9507,10 +8930,10 @@ function RelevantUsersList({ id }) {
|
|
|
9507
8930
|
__name(RelevantUsersList, "RelevantUsersList");
|
|
9508
8931
|
|
|
9509
8932
|
// src/features/user/components/lists/RoleUsersList.tsx
|
|
9510
|
-
import { useTranslations as
|
|
8933
|
+
import { useTranslations as useTranslations23 } from "next-intl";
|
|
9511
8934
|
import { jsx as jsx93 } from "react/jsx-runtime";
|
|
9512
8935
|
function RoleUsersList({ role }) {
|
|
9513
|
-
const t =
|
|
8936
|
+
const t = useTranslations23();
|
|
9514
8937
|
const data = useDataListRetriever({
|
|
9515
8938
|
retriever: /* @__PURE__ */ __name((params) => UserService.findAllUsersByRole(params), "retriever"),
|
|
9516
8939
|
retrieverParams: { roleId: role.id },
|
|
@@ -9539,11 +8962,11 @@ function UserListInAdd({ data, existingUsers, setSelectedUser, setLevelOpen }) {
|
|
|
9539
8962
|
CommandItem,
|
|
9540
8963
|
{
|
|
9541
8964
|
className: "cursor-pointer hover:bg-muted data-selected:hover:bg-muted bg-transparent data-selected:bg-transparent",
|
|
9542
|
-
onClick: (
|
|
8965
|
+
onClick: (_e) => {
|
|
9543
8966
|
setSelectedUser(user);
|
|
9544
8967
|
setLevelOpen?.(true);
|
|
9545
8968
|
},
|
|
9546
|
-
onSelect: (
|
|
8969
|
+
onSelect: (_e) => {
|
|
9547
8970
|
setSelectedUser(user);
|
|
9548
8971
|
setLevelOpen?.(true);
|
|
9549
8972
|
},
|
|
@@ -9562,10 +8985,16 @@ function UserListInAdd({ data, existingUsers, setSelectedUser, setLevelOpen }) {
|
|
|
9562
8985
|
__name(UserListInAdd, "UserListInAdd");
|
|
9563
8986
|
|
|
9564
8987
|
// src/features/user/components/lists/UsersList.tsx
|
|
9565
|
-
import { useTranslations as
|
|
8988
|
+
import { useTranslations as useTranslations24 } from "next-intl";
|
|
9566
8989
|
import { jsx as jsx95 } from "react/jsx-runtime";
|
|
9567
|
-
function UsersList({
|
|
9568
|
-
|
|
8990
|
+
function UsersList({
|
|
8991
|
+
data,
|
|
8992
|
+
optionComponents: _optionComponents,
|
|
8993
|
+
removeFunction: _removeFunction,
|
|
8994
|
+
hideOptions: _hideOptions,
|
|
8995
|
+
showRelevance: _showRelevance
|
|
8996
|
+
}) {
|
|
8997
|
+
const t = useTranslations24();
|
|
9569
8998
|
return /* @__PURE__ */ jsx95(
|
|
9570
8999
|
ContentListTable,
|
|
9571
9000
|
{
|
|
@@ -9579,10 +9008,10 @@ function UsersList({ data, optionComponents, removeFunction, hideOptions, showRe
|
|
|
9579
9008
|
__name(UsersList, "UsersList");
|
|
9580
9009
|
|
|
9581
9010
|
// src/features/user/components/lists/UsersListByContentIds.tsx
|
|
9582
|
-
import { useTranslations as
|
|
9011
|
+
import { useTranslations as useTranslations25 } from "next-intl";
|
|
9583
9012
|
import { jsx as jsx96 } from "react/jsx-runtime";
|
|
9584
9013
|
function UsersListByContentIds({ contentIds }) {
|
|
9585
|
-
const t =
|
|
9014
|
+
const t = useTranslations25();
|
|
9586
9015
|
const data = useDataListRetriever({
|
|
9587
9016
|
module: Modules.User,
|
|
9588
9017
|
retriever: /* @__PURE__ */ __name((params) => UserService.findManyByContentIds(params), "retriever"),
|
|
@@ -9601,13 +9030,13 @@ function UsersListByContentIds({ contentIds }) {
|
|
|
9601
9030
|
__name(UsersListByContentIds, "UsersListByContentIds");
|
|
9602
9031
|
|
|
9603
9032
|
// src/features/company/components/details/CompanyDetails.tsx
|
|
9604
|
-
import { useTranslations as
|
|
9033
|
+
import { useTranslations as useTranslations26 } from "next-intl";
|
|
9605
9034
|
import Image5 from "next/image";
|
|
9606
9035
|
import { jsx as jsx97, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
9607
9036
|
function CompanyDetails() {
|
|
9608
|
-
const
|
|
9037
|
+
const _t = useTranslations26();
|
|
9609
9038
|
const { title } = useSharedContext();
|
|
9610
|
-
const
|
|
9039
|
+
const _generateUrl = usePageUrlGenerator();
|
|
9611
9040
|
const { company } = useCompanyContext();
|
|
9612
9041
|
if (!company) return null;
|
|
9613
9042
|
return /* @__PURE__ */ jsxs56("div", { className: "flex w-full flex-col gap-y-2", children: [
|
|
@@ -9646,11 +9075,11 @@ __name(CompanyContainer, "CompanyContainer");
|
|
|
9646
9075
|
// src/features/company/components/details/TokenStatusIndicator.tsx
|
|
9647
9076
|
import { Battery, BatteryFull, BatteryLow, BatteryMedium, PlusCircle } from "lucide-react";
|
|
9648
9077
|
import Link2 from "next/link";
|
|
9649
|
-
import { useTranslations as
|
|
9078
|
+
import { useTranslations as useTranslations27 } from "next-intl";
|
|
9650
9079
|
import { jsx as jsx100, jsxs as jsxs58 } from "react/jsx-runtime";
|
|
9651
9080
|
function TokenStatusIndicator({ className, size = "md", showExtraPages = true }) {
|
|
9652
9081
|
const { company } = useCurrentUserContext();
|
|
9653
|
-
const t =
|
|
9082
|
+
const t = useTranslations27();
|
|
9654
9083
|
if (!company) return null;
|
|
9655
9084
|
const monthlyTokens = company.monthlyTokens;
|
|
9656
9085
|
const availableMonthlyTokens = company.availableMonthlyTokens;
|
|
@@ -9754,20 +9183,20 @@ __name(TokenStatusIndicator, "TokenStatusIndicator");
|
|
|
9754
9183
|
// src/features/company/components/forms/CompanyConfigurationEditor.tsx
|
|
9755
9184
|
import { zodResolver as zodResolver2 } from "@hookform/resolvers/zod";
|
|
9756
9185
|
import { Settings2Icon } from "lucide-react";
|
|
9757
|
-
import { useTranslations as
|
|
9186
|
+
import { useTranslations as useTranslations29 } from "next-intl";
|
|
9758
9187
|
import { useEffect as useEffect19, useMemo as useMemo11, useState as useState25 } from "react";
|
|
9759
9188
|
import { useForm as useForm2 } from "react-hook-form";
|
|
9760
9189
|
import z2 from "zod";
|
|
9761
9190
|
|
|
9762
9191
|
// src/features/company/components/forms/CompanyConfigurationSecurityForm.tsx
|
|
9763
|
-
import { useTranslations as
|
|
9192
|
+
import { useTranslations as useTranslations28 } from "next-intl";
|
|
9764
9193
|
import { jsx as jsx101 } from "react/jsx-runtime";
|
|
9765
9194
|
var providerConfig = {
|
|
9766
9195
|
fields: ["isManagedKnowledge", "allowPublicBot"],
|
|
9767
9196
|
defaults: {}
|
|
9768
9197
|
};
|
|
9769
9198
|
function CompanyConfigurationSecurityForm({ form }) {
|
|
9770
|
-
const
|
|
9199
|
+
const _t = useTranslations28();
|
|
9771
9200
|
const renderProviderFields = /* @__PURE__ */ __name(() => {
|
|
9772
9201
|
const config = providerConfig;
|
|
9773
9202
|
if (!config) return null;
|
|
@@ -9820,7 +9249,7 @@ __name(CompanyConfigurationSecurityForm, "CompanyConfigurationSecurityForm");
|
|
|
9820
9249
|
import { jsx as jsx102, jsxs as jsxs59 } from "react/jsx-runtime";
|
|
9821
9250
|
function CompanyConfigurationEditorInternal({ company }) {
|
|
9822
9251
|
const [open, setOpen] = useState25(false);
|
|
9823
|
-
const t =
|
|
9252
|
+
const t = useTranslations29();
|
|
9824
9253
|
const { setUser } = useCurrentUserContext();
|
|
9825
9254
|
const defaultValues = useMemo11(() => {
|
|
9826
9255
|
return {
|
|
@@ -9902,11 +9331,11 @@ __name(CompanyConfigurationEditor, "CompanyConfigurationEditor");
|
|
|
9902
9331
|
|
|
9903
9332
|
// src/features/company/components/forms/CompanyDeleter.tsx
|
|
9904
9333
|
import { LoaderCircleIcon as LoaderCircleIcon2, Trash2Icon as Trash2Icon2 } from "lucide-react";
|
|
9905
|
-
import { useTranslations as
|
|
9334
|
+
import { useTranslations as useTranslations30 } from "next-intl";
|
|
9906
9335
|
import { useState as useState26 } from "react";
|
|
9907
9336
|
import { Fragment as Fragment10, jsx as jsx103, jsxs as jsxs60 } from "react/jsx-runtime";
|
|
9908
9337
|
function CompanyDeleterInternal({ company, isAdministrator: isAdministrator2 }) {
|
|
9909
|
-
const t =
|
|
9338
|
+
const t = useTranslations30();
|
|
9910
9339
|
const generateUrl = usePageUrlGenerator();
|
|
9911
9340
|
const [open, setOpen] = useState26(false);
|
|
9912
9341
|
const [finalWarningOpen, setFinalWarningOpen] = useState26(false);
|
|
@@ -10043,7 +9472,7 @@ __name(CompanyDeleter, "CompanyDeleter");
|
|
|
10043
9472
|
import { zodResolver as zodResolver3 } from "@hookform/resolvers/zod";
|
|
10044
9473
|
import { setCookie } from "cookies-next";
|
|
10045
9474
|
import { UploadIcon as UploadIcon3 } from "lucide-react";
|
|
10046
|
-
import { useTranslations as
|
|
9475
|
+
import { useTranslations as useTranslations31 } from "next-intl";
|
|
10047
9476
|
import Image6 from "next/image";
|
|
10048
9477
|
import { useEffect as useEffect20, useState as useState27 } from "react";
|
|
10049
9478
|
import { useForm as useForm3 } from "react-hook-form";
|
|
@@ -10058,7 +9487,7 @@ function CompanyEditorInternal({ company, propagateChanges, onRevalidate }) {
|
|
|
10058
9487
|
const [file, setFile] = useState27(null);
|
|
10059
9488
|
const [files, setFiles] = useState27(null);
|
|
10060
9489
|
const [contentType, setContentType] = useState27(null);
|
|
10061
|
-
const t =
|
|
9490
|
+
const t = useTranslations31();
|
|
10062
9491
|
const generateUrl = usePageUrlGenerator();
|
|
10063
9492
|
const formSchema = z3.object({
|
|
10064
9493
|
id: z3.uuidv4(),
|
|
@@ -10211,10 +9640,10 @@ function CompanyEditor(props) {
|
|
|
10211
9640
|
__name(CompanyEditor, "CompanyEditor");
|
|
10212
9641
|
|
|
10213
9642
|
// src/features/company/components/lists/CompaniesList.tsx
|
|
10214
|
-
import { useTranslations as
|
|
9643
|
+
import { useTranslations as useTranslations32 } from "next-intl";
|
|
10215
9644
|
import { jsx as jsx105 } from "react/jsx-runtime";
|
|
10216
9645
|
function CompaniesList() {
|
|
10217
|
-
const t =
|
|
9646
|
+
const t = useTranslations32();
|
|
10218
9647
|
const data = useDataListRetriever({
|
|
10219
9648
|
retriever: /* @__PURE__ */ __name((params) => CompanyService.findMany(params), "retriever"),
|
|
10220
9649
|
retrieverParams: {},
|
|
@@ -10244,7 +9673,7 @@ var defaultContextValue2 = {
|
|
|
10244
9673
|
};
|
|
10245
9674
|
var CompanyProvider = /* @__PURE__ */ __name(({ children, dehydratedCompany }) => {
|
|
10246
9675
|
const generateUrl = usePageUrlGenerator();
|
|
10247
|
-
const t =
|
|
9676
|
+
const t = useTranslations33();
|
|
10248
9677
|
const { hasPermissionToModule, hasRole } = useCurrentUserContext();
|
|
10249
9678
|
const [company, setCompany] = useState28(
|
|
10250
9679
|
dehydratedCompany ? rehydrate(Modules.Company, dehydratedCompany) : void 0
|
|
@@ -10288,11 +9717,11 @@ var useCompanyContext = /* @__PURE__ */ __name(() => {
|
|
|
10288
9717
|
}, "useCompanyContext");
|
|
10289
9718
|
|
|
10290
9719
|
// src/features/notification/contexts/NotificationContext.tsx
|
|
10291
|
-
import { useTranslations as
|
|
9720
|
+
import { useTranslations as useTranslations35 } from "next-intl";
|
|
10292
9721
|
import { createContext as createContext11, useCallback as useCallback13, useContext as useContext12, useEffect as useEffect22, useState as useState30 } from "react";
|
|
10293
9722
|
|
|
10294
9723
|
// src/features/notification/components/notifications/Notification.tsx
|
|
10295
|
-
import { useTranslations as
|
|
9724
|
+
import { useTranslations as useTranslations34 } from "next-intl";
|
|
10296
9725
|
import { useEffect as useEffect21, useState as useState29 } from "react";
|
|
10297
9726
|
import { jsx as jsx107, jsxs as jsxs62 } from "react/jsx-runtime";
|
|
10298
9727
|
var generateNotificationData = /* @__PURE__ */ __name((params) => {
|
|
@@ -10331,7 +9760,7 @@ __name(NotificationToast, "NotificationToast");
|
|
|
10331
9760
|
function NotificationMenuItem({ notification, closePopover }) {
|
|
10332
9761
|
const generateUrl = usePageUrlGenerator();
|
|
10333
9762
|
const [isRead, setIsRead] = useState29(false);
|
|
10334
|
-
const t =
|
|
9763
|
+
const t = useTranslations34();
|
|
10335
9764
|
useEffect21(() => {
|
|
10336
9765
|
setIsRead(notification.isRead);
|
|
10337
9766
|
}, []);
|
|
@@ -10357,7 +9786,7 @@ __name(NotificationMenuItem, "NotificationMenuItem");
|
|
|
10357
9786
|
import { jsx as jsx108 } from "react/jsx-runtime";
|
|
10358
9787
|
var NotificationContext = createContext11(void 0);
|
|
10359
9788
|
var NotificationContextProvider = /* @__PURE__ */ __name(({ children }) => {
|
|
10360
|
-
const t =
|
|
9789
|
+
const t = useTranslations35();
|
|
10361
9790
|
const router = useI18nRouter();
|
|
10362
9791
|
const [notifications, setNotifications] = useState30([]);
|
|
10363
9792
|
const [isLoading, setIsLoading] = useState30(false);
|
|
@@ -10398,9 +9827,7 @@ var NotificationContextProvider = /* @__PURE__ */ __name(({ children }) => {
|
|
|
10398
9827
|
useEffect22(() => {
|
|
10399
9828
|
if (hasInitiallyLoaded || !currentUser) return;
|
|
10400
9829
|
if (isRolesConfigured()) {
|
|
10401
|
-
const isAdmin = currentUser.roles?.some(
|
|
10402
|
-
(role) => role.id === getRoleId().Administrator
|
|
10403
|
-
);
|
|
9830
|
+
const isAdmin = currentUser.roles?.some((role) => role.id === getRoleId().Administrator);
|
|
10404
9831
|
if (isAdmin) {
|
|
10405
9832
|
setHasInitiallyLoaded(true);
|
|
10406
9833
|
return;
|
|
@@ -10547,10 +9974,10 @@ var OnboardingContext = createContext12(null);
|
|
|
10547
9974
|
function OnboardingProvider({
|
|
10548
9975
|
children,
|
|
10549
9976
|
tours = [],
|
|
10550
|
-
tourPaths = {},
|
|
9977
|
+
tourPaths: _tourPaths = {},
|
|
10551
9978
|
labels = DEFAULT_ONBOARDING_LABELS,
|
|
10552
9979
|
renderCard,
|
|
10553
|
-
zIndex = 9999
|
|
9980
|
+
zIndex: _zIndex = 9999
|
|
10554
9981
|
}) {
|
|
10555
9982
|
const [isTourActive, setIsTourActive] = useState31(false);
|
|
10556
9983
|
const [activeTourId, setActiveTourId] = useState31(null);
|
|
@@ -10562,7 +9989,7 @@ function OnboardingProvider({
|
|
|
10562
9989
|
rootsRef.current.forEach((root) => {
|
|
10563
9990
|
try {
|
|
10564
9991
|
root.unmount();
|
|
10565
|
-
} catch (
|
|
9992
|
+
} catch (_e) {
|
|
10566
9993
|
}
|
|
10567
9994
|
});
|
|
10568
9995
|
rootsRef.current.clear();
|
|
@@ -10715,13 +10142,13 @@ function useOnboarding() {
|
|
|
10715
10142
|
__name(useOnboarding, "useOnboarding");
|
|
10716
10143
|
|
|
10717
10144
|
// src/features/role/contexts/RoleContext.tsx
|
|
10718
|
-
import { useTranslations as
|
|
10145
|
+
import { useTranslations as useTranslations36 } from "next-intl";
|
|
10719
10146
|
import { createContext as createContext13, useContext as useContext14, useState as useState32 } from "react";
|
|
10720
10147
|
import { jsx as jsx111 } from "react/jsx-runtime";
|
|
10721
10148
|
var RoleContext = createContext13(void 0);
|
|
10722
10149
|
var RoleProvider = /* @__PURE__ */ __name(({ children, dehydratedRole }) => {
|
|
10723
10150
|
const generateUrl = usePageUrlGenerator();
|
|
10724
|
-
const t =
|
|
10151
|
+
const t = useTranslations36();
|
|
10725
10152
|
const [role, setRole] = useState32(
|
|
10726
10153
|
dehydratedRole ? rehydrate(Modules.Role, dehydratedRole) : void 0
|
|
10727
10154
|
);
|
|
@@ -10769,7 +10196,7 @@ var useRoleContext = /* @__PURE__ */ __name(() => {
|
|
|
10769
10196
|
}, "useRoleContext");
|
|
10770
10197
|
|
|
10771
10198
|
// src/contexts/CommonContext.tsx
|
|
10772
|
-
import { useTranslations as
|
|
10199
|
+
import { useTranslations as useTranslations37 } from "next-intl";
|
|
10773
10200
|
import { createContext as createContext15, useContext as useContext16 } from "react";
|
|
10774
10201
|
|
|
10775
10202
|
// src/contexts/SharedContext.tsx
|
|
@@ -10792,7 +10219,7 @@ import { jsx as jsx113 } from "react/jsx-runtime";
|
|
|
10792
10219
|
var CommonContext = createContext15(void 0);
|
|
10793
10220
|
var CommonProvider = /* @__PURE__ */ __name(({ children }) => {
|
|
10794
10221
|
const { company } = useCurrentUserContext();
|
|
10795
|
-
const t =
|
|
10222
|
+
const t = useTranslations37();
|
|
10796
10223
|
const breadcrumb = /* @__PURE__ */ __name(() => {
|
|
10797
10224
|
const response = [];
|
|
10798
10225
|
return response;
|
|
@@ -11087,7 +10514,7 @@ import { Fragment as Fragment13, jsx as jsx114, jsxs as jsxs64 } from "react/jsx
|
|
|
11087
10514
|
var ITEMS_TO_DISPLAY = 3;
|
|
11088
10515
|
function BreadcrumbNavigation({ items }) {
|
|
11089
10516
|
const generateUrl = usePageUrlGenerator();
|
|
11090
|
-
const t =
|
|
10517
|
+
const t = useTranslations38();
|
|
11091
10518
|
const [open, setOpen] = useState34(false);
|
|
11092
10519
|
return /* @__PURE__ */ jsx114(Breadcrumb, { children: /* @__PURE__ */ jsxs64(BreadcrumbList, { children: [
|
|
11093
10520
|
/* @__PURE__ */ jsx114(BreadcrumbItem, { children: /* @__PURE__ */ jsx114(Link, { href: generateUrl({ page: `/` }), children: t(`common.home`) }) }),
|
|
@@ -11212,11 +10639,11 @@ __name(PageSection, "PageSection");
|
|
|
11212
10639
|
// src/components/navigations/RecentPagesNavigator.tsx
|
|
11213
10640
|
import { useAtomValue } from "jotai";
|
|
11214
10641
|
import { HistoryIcon } from "lucide-react";
|
|
11215
|
-
import { useTranslations as
|
|
10642
|
+
import { useTranslations as useTranslations39 } from "next-intl";
|
|
11216
10643
|
import { jsx as jsx119, jsxs as jsxs68 } from "react/jsx-runtime";
|
|
11217
10644
|
function RecentPagesNavigator() {
|
|
11218
10645
|
const recentPages = useAtomValue(recentPagesAtom);
|
|
11219
|
-
const t =
|
|
10646
|
+
const t = useTranslations39();
|
|
11220
10647
|
const { state } = useSidebar();
|
|
11221
10648
|
if (recentPages.length === 0) {
|
|
11222
10649
|
return null;
|
|
@@ -11248,7 +10675,7 @@ __name(PageContainer, "PageContainer");
|
|
|
11248
10675
|
|
|
11249
10676
|
// src/components/containers/ReactMarkdownContainer.tsx
|
|
11250
10677
|
import { ChevronDown as ChevronDown2, ChevronUp } from "lucide-react";
|
|
11251
|
-
import { useTranslations as
|
|
10678
|
+
import { useTranslations as useTranslations40 } from "next-intl";
|
|
11252
10679
|
import { useEffect as useEffect30, useRef as useRef14, useState as useState37 } from "react";
|
|
11253
10680
|
import ReactMarkdown from "react-markdown";
|
|
11254
10681
|
import remarkGfm from "remark-gfm";
|
|
@@ -11259,7 +10686,7 @@ function ReactMarkdownContainer({
|
|
|
11259
10686
|
initialLines = 4,
|
|
11260
10687
|
size = "normal"
|
|
11261
10688
|
}) {
|
|
11262
|
-
const t =
|
|
10689
|
+
const t = useTranslations40("ui.buttons");
|
|
11263
10690
|
const [isExpanded, setIsExpanded] = useState37(false);
|
|
11264
10691
|
const [showExpandButton, setShowExpandButton] = useState37(false);
|
|
11265
10692
|
const contentRef = useRef14(null);
|
|
@@ -11386,10 +10813,10 @@ function AttributeElement({ inline, title, value, className }) {
|
|
|
11386
10813
|
__name(AttributeElement, "AttributeElement");
|
|
11387
10814
|
|
|
11388
10815
|
// src/components/details/AllowedUsersDetails.tsx
|
|
11389
|
-
import { useTranslations as
|
|
10816
|
+
import { useTranslations as useTranslations41 } from "next-intl";
|
|
11390
10817
|
import { jsx as jsx124, jsxs as jsxs73 } from "react/jsx-runtime";
|
|
11391
10818
|
function AllowedUsersDetails({ showTitle, content }) {
|
|
11392
|
-
const t =
|
|
10819
|
+
const t = useTranslations41();
|
|
11393
10820
|
return /* @__PURE__ */ jsxs73("div", { className: "mb-2 flex w-full flex-col gap-y-2", children: [
|
|
11394
10821
|
showTitle && /* @__PURE__ */ jsx124("h3", { className: "text-xs font-semibold", children: t("common.permissions") }),
|
|
11395
10822
|
/* @__PURE__ */ jsx124("div", { className: "flex w-full items-center justify-start gap-x-4", children: /* @__PURE__ */ jsx124(ContributorsList, { content }) })
|
|
@@ -11401,7 +10828,7 @@ __name(AllowedUsersDetails, "AllowedUsersDetails");
|
|
|
11401
10828
|
import dynamic from "next/dynamic";
|
|
11402
10829
|
import React15 from "react";
|
|
11403
10830
|
import { jsx as jsx125 } from "react/jsx-runtime";
|
|
11404
|
-
var BlockNoteEditor = dynamic(() => import("./BlockNoteEditor-
|
|
10831
|
+
var BlockNoteEditor = dynamic(() => import("./BlockNoteEditor-WQUJTVJL.mjs"), {
|
|
11405
10832
|
ssr: false
|
|
11406
10833
|
});
|
|
11407
10834
|
var BlockNoteEditorContainer = React15.memo(/* @__PURE__ */ __name(function EditorContainer(props) {
|
|
@@ -11497,7 +10924,7 @@ var cellComponent = /* @__PURE__ */ __name((params) => {
|
|
|
11497
10924
|
id: params.name,
|
|
11498
10925
|
accessorKey: params.name,
|
|
11499
10926
|
header: params.title,
|
|
11500
|
-
cell: /* @__PURE__ */ __name(({ row }) => params.component, "cell"),
|
|
10927
|
+
cell: /* @__PURE__ */ __name(({ row: _row }) => params.component, "cell"),
|
|
11501
10928
|
enableSorting: false,
|
|
11502
10929
|
enableHiding: false
|
|
11503
10930
|
};
|
|
@@ -11797,11 +11224,11 @@ function useRehydrationList(classKey, data) {
|
|
|
11797
11224
|
__name(useRehydrationList, "useRehydrationList");
|
|
11798
11225
|
|
|
11799
11226
|
// src/features/company/hooks/useCompanyTableStructure.tsx
|
|
11800
|
-
import { useTranslations as
|
|
11227
|
+
import { useTranslations as useTranslations42 } from "next-intl";
|
|
11801
11228
|
import { useMemo as useMemo14 } from "react";
|
|
11802
11229
|
import { jsx as jsx133 } from "react/jsx-runtime";
|
|
11803
11230
|
var useCompanyTableStructure = /* @__PURE__ */ __name((params) => {
|
|
11804
|
-
const t =
|
|
11231
|
+
const t = useTranslations42();
|
|
11805
11232
|
const generateUrl = usePageUrlGenerator();
|
|
11806
11233
|
const { hasRole } = useCurrentUserContext();
|
|
11807
11234
|
const tableData = useMemo14(() => {
|
|
@@ -11920,11 +11347,11 @@ function useSubscriptionStatus() {
|
|
|
11920
11347
|
__name(useSubscriptionStatus, "useSubscriptionStatus");
|
|
11921
11348
|
|
|
11922
11349
|
// src/features/role/hooks/useRoleTableStructure.tsx
|
|
11923
|
-
import { useTranslations as
|
|
11350
|
+
import { useTranslations as useTranslations43 } from "next-intl";
|
|
11924
11351
|
import { useMemo as useMemo16 } from "react";
|
|
11925
11352
|
import { Fragment as Fragment15, jsx as jsx134 } from "react/jsx-runtime";
|
|
11926
11353
|
var useRoleTableStructure = /* @__PURE__ */ __name((params) => {
|
|
11927
|
-
const t =
|
|
11354
|
+
const t = useTranslations43();
|
|
11928
11355
|
const generateUrl = usePageUrlGenerator();
|
|
11929
11356
|
const tableData = useMemo16(() => {
|
|
11930
11357
|
return params.data.map((role) => {
|
|
@@ -12020,11 +11447,11 @@ var useUserSearch = /* @__PURE__ */ __name(() => {
|
|
|
12020
11447
|
}, "useUserSearch");
|
|
12021
11448
|
|
|
12022
11449
|
// src/features/user/hooks/useUserTableStructure.tsx
|
|
12023
|
-
import { useTranslations as
|
|
11450
|
+
import { useTranslations as useTranslations44 } from "next-intl";
|
|
12024
11451
|
import { useMemo as useMemo17 } from "react";
|
|
12025
11452
|
import { Fragment as Fragment16, jsx as jsx135, jsxs as jsxs76 } from "react/jsx-runtime";
|
|
12026
11453
|
var useUserTableStructure = /* @__PURE__ */ __name((params) => {
|
|
12027
|
-
const t =
|
|
11454
|
+
const t = useTranslations44();
|
|
12028
11455
|
const generateUrl = usePageUrlGenerator();
|
|
12029
11456
|
const tableData = useMemo17(() => {
|
|
12030
11457
|
return params.data.map((user) => {
|
|
@@ -12118,11 +11545,11 @@ var useUserTableStructure = /* @__PURE__ */ __name((params) => {
|
|
|
12118
11545
|
}, "useUserTableStructure");
|
|
12119
11546
|
|
|
12120
11547
|
// src/features/content/hooks/useContentTableStructure.tsx
|
|
12121
|
-
import { useTranslations as
|
|
11548
|
+
import { useTranslations as useTranslations45 } from "next-intl";
|
|
12122
11549
|
import { useMemo as useMemo18 } from "react";
|
|
12123
11550
|
import { Fragment as Fragment17, jsx as jsx136, jsxs as jsxs77 } from "react/jsx-runtime";
|
|
12124
11551
|
var useContentTableStructure = /* @__PURE__ */ __name((params) => {
|
|
12125
|
-
const t =
|
|
11552
|
+
const t = useTranslations45();
|
|
12126
11553
|
const generateUrl = usePageUrlGenerator();
|
|
12127
11554
|
const tableData = useMemo18(() => {
|
|
12128
11555
|
return params.data.map((content) => {
|
|
@@ -12521,11 +11948,11 @@ import { memo, useMemo as useMemo19 } from "react";
|
|
|
12521
11948
|
|
|
12522
11949
|
// src/components/tables/ContentTableSearch.tsx
|
|
12523
11950
|
import { RefreshCw, Search, X as X2 } from "lucide-react";
|
|
12524
|
-
import { useTranslations as
|
|
11951
|
+
import { useTranslations as useTranslations46 } from "next-intl";
|
|
12525
11952
|
import { useCallback as useCallback21, useEffect as useEffect39, useRef as useRef18, useState as useState45 } from "react";
|
|
12526
11953
|
import { jsx as jsx137, jsxs as jsxs78 } from "react/jsx-runtime";
|
|
12527
11954
|
function ContentTableSearch({ data }) {
|
|
12528
|
-
const t =
|
|
11955
|
+
const t = useTranslations46();
|
|
12529
11956
|
const searchTermRef = useRef18("");
|
|
12530
11957
|
const inputRef = useRef18(null);
|
|
12531
11958
|
const [searchTerm, setSearchTerm] = useState45("");
|
|
@@ -12613,7 +12040,7 @@ __name(ContentTableSearch, "ContentTableSearch");
|
|
|
12613
12040
|
import { Fragment as Fragment18, jsx as jsx138, jsxs as jsxs79 } from "react/jsx-runtime";
|
|
12614
12041
|
var EMPTY_ARRAY = [];
|
|
12615
12042
|
var ContentListTable = memo(/* @__PURE__ */ __name(function ContentListTable2(props) {
|
|
12616
|
-
const { data, fields, checkedIds, toggleId, allowSearch, filters } = props;
|
|
12043
|
+
const { data, fields, checkedIds, toggleId, allowSearch, filters: _filters } = props;
|
|
12617
12044
|
const { data: tableData, columns: tableColumns } = useTableGenerator(props.tableGeneratorType, {
|
|
12618
12045
|
data: data?.data ?? EMPTY_ARRAY,
|
|
12619
12046
|
fields,
|
|
@@ -12697,7 +12124,7 @@ import { createContext as createContext16, useContext as useContext17, useMemo a
|
|
|
12697
12124
|
|
|
12698
12125
|
// src/features/auth/components/forms/Register.tsx
|
|
12699
12126
|
import { zodResolver as zodResolver4 } from "@hookform/resolvers/zod";
|
|
12700
|
-
import { useTranslations as
|
|
12127
|
+
import { useTranslations as useTranslations48 } from "next-intl";
|
|
12701
12128
|
import Image7 from "next/image";
|
|
12702
12129
|
import { useState as useState46 } from "react";
|
|
12703
12130
|
import { useForm as useForm4 } from "react-hook-form";
|
|
@@ -12705,14 +12132,14 @@ import { v4 as v44 } from "uuid";
|
|
|
12705
12132
|
import { z as z4 } from "zod";
|
|
12706
12133
|
|
|
12707
12134
|
// src/features/auth/components/GdprConsentSection.tsx
|
|
12708
|
-
import { useTranslations as
|
|
12135
|
+
import { useTranslations as useTranslations47 } from "next-intl";
|
|
12709
12136
|
import { Fragment as Fragment19, jsx as jsx139, jsxs as jsxs80 } from "react/jsx-runtime";
|
|
12710
12137
|
function GdprConsentSection({
|
|
12711
12138
|
form,
|
|
12712
12139
|
termsCheckboxId = "termsAccepted",
|
|
12713
12140
|
marketingCheckboxId = "marketingConsent"
|
|
12714
12141
|
}) {
|
|
12715
|
-
const t =
|
|
12142
|
+
const t = useTranslations47("auth.gdpr");
|
|
12716
12143
|
const termsLabel = /* @__PURE__ */ jsxs80(Fragment19, { children: [
|
|
12717
12144
|
t("terms_prefix"),
|
|
12718
12145
|
" ",
|
|
@@ -12723,15 +12150,7 @@ function GdprConsentSection({
|
|
|
12723
12150
|
/* @__PURE__ */ jsx139(Link, { href: "/privacy", target: "_blank", rel: "noopener", className: "underline", children: t("privacy_policy") })
|
|
12724
12151
|
] });
|
|
12725
12152
|
return /* @__PURE__ */ jsxs80("div", { className: "space-y-4 py-4", children: [
|
|
12726
|
-
/* @__PURE__ */ jsx139(
|
|
12727
|
-
GdprConsentCheckbox,
|
|
12728
|
-
{
|
|
12729
|
-
form,
|
|
12730
|
-
id: termsCheckboxId,
|
|
12731
|
-
label: termsLabel,
|
|
12732
|
-
required: true
|
|
12733
|
-
}
|
|
12734
|
-
),
|
|
12153
|
+
/* @__PURE__ */ jsx139(GdprConsentCheckbox, { form, id: termsCheckboxId, label: termsLabel, required: true }),
|
|
12735
12154
|
/* @__PURE__ */ jsx139(
|
|
12736
12155
|
GdprConsentCheckbox,
|
|
12737
12156
|
{
|
|
@@ -12748,7 +12167,7 @@ __name(GdprConsentSection, "GdprConsentSection");
|
|
|
12748
12167
|
// src/features/auth/components/forms/Register.tsx
|
|
12749
12168
|
import { Fragment as Fragment20, jsx as jsx140, jsxs as jsxs81 } from "react/jsx-runtime";
|
|
12750
12169
|
function Register() {
|
|
12751
|
-
const t =
|
|
12170
|
+
const t = useTranslations48();
|
|
12752
12171
|
const { setComponentType } = useAuthContext();
|
|
12753
12172
|
const [showConfirmation, setShowConfirmation] = useState46(false);
|
|
12754
12173
|
const formSchema = z4.object({
|
|
@@ -12941,7 +12360,7 @@ function InnerAuthContainer() {
|
|
|
12941
12360
|
__name(InnerAuthContainer, "InnerAuthContainer");
|
|
12942
12361
|
|
|
12943
12362
|
// src/features/auth/components/details/LandingComponent.tsx
|
|
12944
|
-
import { useTranslations as
|
|
12363
|
+
import { useTranslations as useTranslations49 } from "next-intl";
|
|
12945
12364
|
import Image9 from "next/image";
|
|
12946
12365
|
|
|
12947
12366
|
// src/features/auth/components/buttons/GoogleSignInButton.tsx
|
|
@@ -12997,7 +12416,7 @@ __name(GoogleSignInButton, "GoogleSignInButton");
|
|
|
12997
12416
|
// src/features/auth/components/details/LandingComponent.tsx
|
|
12998
12417
|
import { Fragment as Fragment21, jsx as jsx144, jsxs as jsxs83 } from "react/jsx-runtime";
|
|
12999
12418
|
function LandingComponent() {
|
|
13000
|
-
const t =
|
|
12419
|
+
const t = useTranslations49();
|
|
13001
12420
|
const { setComponentType } = useAuthContext();
|
|
13002
12421
|
return /* @__PURE__ */ jsxs83(Fragment21, { children: [
|
|
13003
12422
|
/* @__PURE__ */ jsxs83(CardHeader, { className: "mb-4", "data-testid": "page-pre-login-container", children: [
|
|
@@ -13029,7 +12448,7 @@ __name(LandingComponent, "LandingComponent");
|
|
|
13029
12448
|
|
|
13030
12449
|
// src/features/auth/components/forms/AcceptInvitation.tsx
|
|
13031
12450
|
import { zodResolver as zodResolver5 } from "@hookform/resolvers/zod";
|
|
13032
|
-
import { useTranslations as
|
|
12451
|
+
import { useTranslations as useTranslations50 } from "next-intl";
|
|
13033
12452
|
import Image10 from "next/image";
|
|
13034
12453
|
import { useEffect as useEffect40, useState as useState48 } from "react";
|
|
13035
12454
|
import { useForm as useForm5 } from "react-hook-form";
|
|
@@ -13039,7 +12458,7 @@ function AcceptInvitation() {
|
|
|
13039
12458
|
const { setComponentType, params, setParams } = useAuthContext();
|
|
13040
12459
|
const [showConfirmation, setShowConfirmation] = useState48(false);
|
|
13041
12460
|
const [error, setError] = useState48(void 0);
|
|
13042
|
-
const t =
|
|
12461
|
+
const t = useTranslations50();
|
|
13043
12462
|
useEffect40(() => {
|
|
13044
12463
|
async function validateCode(code) {
|
|
13045
12464
|
try {
|
|
@@ -13093,7 +12512,7 @@ function AcceptInvitation() {
|
|
|
13093
12512
|
setComponentType(0 /* Login */);
|
|
13094
12513
|
setParams(void 0);
|
|
13095
12514
|
}, 2e3);
|
|
13096
|
-
} catch (
|
|
12515
|
+
} catch (_e) {
|
|
13097
12516
|
errorToast({ title: t(`common.errors.error`), error });
|
|
13098
12517
|
}
|
|
13099
12518
|
}, "onSubmit");
|
|
@@ -13131,7 +12550,7 @@ function AcceptInvitation() {
|
|
|
13131
12550
|
__name(AcceptInvitation, "AcceptInvitation");
|
|
13132
12551
|
|
|
13133
12552
|
// src/features/auth/components/forms/ActivateAccount.tsx
|
|
13134
|
-
import { useTranslations as
|
|
12553
|
+
import { useTranslations as useTranslations51 } from "next-intl";
|
|
13135
12554
|
import Image11 from "next/image";
|
|
13136
12555
|
import { useEffect as useEffect41, useState as useState49 } from "react";
|
|
13137
12556
|
import { Fragment as Fragment23, jsx as jsx146, jsxs as jsxs85 } from "react/jsx-runtime";
|
|
@@ -13139,7 +12558,7 @@ function ActivateAccount() {
|
|
|
13139
12558
|
const { setComponentType, params, setParams } = useAuthContext();
|
|
13140
12559
|
const [showConfirmation, setShowConfirmation] = useState49(false);
|
|
13141
12560
|
const [error, setError] = useState49(void 0);
|
|
13142
|
-
const t =
|
|
12561
|
+
const t = useTranslations51();
|
|
13143
12562
|
useEffect41(() => {
|
|
13144
12563
|
async function ActivateAccount2(code) {
|
|
13145
12564
|
try {
|
|
@@ -13207,14 +12626,14 @@ __name(Cookies, "Cookies");
|
|
|
13207
12626
|
|
|
13208
12627
|
// src/features/auth/components/forms/ForgotPassword.tsx
|
|
13209
12628
|
import { zodResolver as zodResolver6 } from "@hookform/resolvers/zod";
|
|
13210
|
-
import { useTranslations as
|
|
12629
|
+
import { useTranslations as useTranslations52 } from "next-intl";
|
|
13211
12630
|
import Image12 from "next/image";
|
|
13212
12631
|
import { useState as useState51 } from "react";
|
|
13213
12632
|
import { useForm as useForm6 } from "react-hook-form";
|
|
13214
12633
|
import { z as z6 } from "zod";
|
|
13215
12634
|
import { Fragment as Fragment24, jsx as jsx147, jsxs as jsxs86 } from "react/jsx-runtime";
|
|
13216
12635
|
function ForgotPassword() {
|
|
13217
|
-
const t =
|
|
12636
|
+
const t = useTranslations52();
|
|
13218
12637
|
const { setComponentType } = useAuthContext();
|
|
13219
12638
|
const [showConfirmation, setShowConfirmation] = useState51(false);
|
|
13220
12639
|
const formSchema = z6.object({
|
|
@@ -13278,13 +12697,13 @@ __name(ForgotPassword, "ForgotPassword");
|
|
|
13278
12697
|
|
|
13279
12698
|
// src/features/auth/components/forms/Login.tsx
|
|
13280
12699
|
import { zodResolver as zodResolver7 } from "@hookform/resolvers/zod";
|
|
13281
|
-
import { useTranslations as
|
|
12700
|
+
import { useTranslations as useTranslations53 } from "next-intl";
|
|
13282
12701
|
import Image13 from "next/image";
|
|
13283
12702
|
import { useForm as useForm7 } from "react-hook-form";
|
|
13284
12703
|
import { z as z7 } from "zod";
|
|
13285
12704
|
import { Fragment as Fragment25, jsx as jsx148, jsxs as jsxs87 } from "react/jsx-runtime";
|
|
13286
12705
|
function Login() {
|
|
13287
|
-
const t =
|
|
12706
|
+
const t = useTranslations53();
|
|
13288
12707
|
const { setUser } = useCurrentUserContext();
|
|
13289
12708
|
const { setComponentType } = useAuthContext();
|
|
13290
12709
|
const generateUrl = usePageUrlGenerator();
|
|
@@ -13428,7 +12847,7 @@ __name(RefreshUser, "RefreshUser");
|
|
|
13428
12847
|
|
|
13429
12848
|
// src/features/auth/components/forms/ResetPassword.tsx
|
|
13430
12849
|
import { zodResolver as zodResolver8 } from "@hookform/resolvers/zod";
|
|
13431
|
-
import { useTranslations as
|
|
12850
|
+
import { useTranslations as useTranslations54 } from "next-intl";
|
|
13432
12851
|
import Image14 from "next/image";
|
|
13433
12852
|
import { useEffect as useEffect45, useState as useState52 } from "react";
|
|
13434
12853
|
import { useForm as useForm8 } from "react-hook-form";
|
|
@@ -13438,7 +12857,7 @@ function ResetPassword() {
|
|
|
13438
12857
|
const { setComponentType, params, setParams } = useAuthContext();
|
|
13439
12858
|
const [showConfirmation, setShowConfirmation] = useState52(false);
|
|
13440
12859
|
const [error, setError] = useState52(void 0);
|
|
13441
|
-
const t =
|
|
12860
|
+
const t = useTranslations54();
|
|
13442
12861
|
useEffect45(() => {
|
|
13443
12862
|
async function validateResetPasswordCode(code) {
|
|
13444
12863
|
try {
|
|
@@ -13492,7 +12911,7 @@ function ResetPassword() {
|
|
|
13492
12911
|
setComponentType(0 /* Login */);
|
|
13493
12912
|
setParams(void 0);
|
|
13494
12913
|
}, 2e3);
|
|
13495
|
-
} catch (
|
|
12914
|
+
} catch (_e) {
|
|
13496
12915
|
errorToast({ title: t(`common.errors.error`), error });
|
|
13497
12916
|
}
|
|
13498
12917
|
}, "onSubmit");
|
|
@@ -13514,10 +12933,10 @@ function ResetPassword() {
|
|
|
13514
12933
|
__name(ResetPassword, "ResetPassword");
|
|
13515
12934
|
|
|
13516
12935
|
// src/features/content/components/lists/ContentsList.tsx
|
|
13517
|
-
import { useTranslations as
|
|
12936
|
+
import { useTranslations as useTranslations55 } from "next-intl";
|
|
13518
12937
|
import { jsx as jsx151, jsxs as jsxs89 } from "react/jsx-runtime";
|
|
13519
12938
|
function ContentsList({ contentList }) {
|
|
13520
|
-
const t =
|
|
12939
|
+
const t = useTranslations55();
|
|
13521
12940
|
return /* @__PURE__ */ jsxs89("div", { className: "flex min-h-0 w-full flex-col overflow-y-auto", children: [
|
|
13522
12941
|
/* @__PURE__ */ jsx151("h2", { className: "text-xl font-semibold", children: t(`content.news`) }),
|
|
13523
12942
|
/* @__PURE__ */ jsx151("div", { className: "flex flex-col", children: contentList.map((content) => /* @__PURE__ */ jsx151(ContentsListElement, { content }, content.id)) })
|
|
@@ -13545,10 +12964,10 @@ function ContentsListElement({ content }) {
|
|
|
13545
12964
|
__name(ContentsListElement, "ContentsListElement");
|
|
13546
12965
|
|
|
13547
12966
|
// src/features/content/components/lists/ContentsListById.tsx
|
|
13548
|
-
import { useTranslations as
|
|
12967
|
+
import { useTranslations as useTranslations56 } from "next-intl";
|
|
13549
12968
|
import { jsx as jsx152 } from "react/jsx-runtime";
|
|
13550
12969
|
function ContentsListById({ contentIds }) {
|
|
13551
|
-
const t =
|
|
12970
|
+
const t = useTranslations56();
|
|
13552
12971
|
const data = useDataListRetriever({
|
|
13553
12972
|
module: Modules.Content,
|
|
13554
12973
|
retriever: /* @__PURE__ */ __name((params) => ContentService.findMany(params), "retriever"),
|
|
@@ -13567,10 +12986,10 @@ function ContentsListById({ contentIds }) {
|
|
|
13567
12986
|
__name(ContentsListById, "ContentsListById");
|
|
13568
12987
|
|
|
13569
12988
|
// src/features/content/components/lists/RelevantContentsList.tsx
|
|
13570
|
-
import { useTranslations as
|
|
12989
|
+
import { useTranslations as useTranslations57 } from "next-intl";
|
|
13571
12990
|
import { jsx as jsx153 } from "react/jsx-runtime";
|
|
13572
12991
|
function RelevantContentsList({ id }) {
|
|
13573
|
-
const t =
|
|
12992
|
+
const t = useTranslations57();
|
|
13574
12993
|
const data = useDataListRetriever({
|
|
13575
12994
|
module: Modules.Content,
|
|
13576
12995
|
retriever: /* @__PURE__ */ __name((params) => ContentService.findRelevant(params), "retriever"),
|
|
@@ -13624,14 +13043,14 @@ var NotificationErrorBoundary = class extends Component {
|
|
|
13624
13043
|
};
|
|
13625
13044
|
|
|
13626
13045
|
// src/features/notification/components/containers/NotificationsListContainer.tsx
|
|
13627
|
-
import { useTranslations as
|
|
13046
|
+
import { useTranslations as useTranslations59 } from "next-intl";
|
|
13628
13047
|
|
|
13629
13048
|
// src/features/notification/components/lists/NotificationsList.tsx
|
|
13630
13049
|
import { ArchiveIcon } from "lucide-react";
|
|
13631
|
-
import { useTranslations as
|
|
13050
|
+
import { useTranslations as useTranslations58 } from "next-intl";
|
|
13632
13051
|
import { Fragment as Fragment28, jsx as jsx155, jsxs as jsxs91 } from "react/jsx-runtime";
|
|
13633
13052
|
function NotificationsList({ archived }) {
|
|
13634
|
-
const t =
|
|
13053
|
+
const t = useTranslations58();
|
|
13635
13054
|
const generateUrl = usePageUrlGenerator();
|
|
13636
13055
|
const data = useDataListRetriever({
|
|
13637
13056
|
retriever: /* @__PURE__ */ __name((params) => NotificationService.findMany(params), "retriever"),
|
|
@@ -13689,8 +13108,8 @@ __name(NotificationsList, "NotificationsList");
|
|
|
13689
13108
|
// src/features/notification/components/containers/NotificationsListContainer.tsx
|
|
13690
13109
|
import { jsx as jsx156, jsxs as jsxs92 } from "react/jsx-runtime";
|
|
13691
13110
|
function NotificationsListContainerContent() {
|
|
13692
|
-
const t =
|
|
13693
|
-
const { notifications, isLoading, error } = useNotificationContext();
|
|
13111
|
+
const t = useTranslations59();
|
|
13112
|
+
const { notifications: _notifications, isLoading: _isLoading, error } = useNotificationContext();
|
|
13694
13113
|
if (error) {
|
|
13695
13114
|
return /* @__PURE__ */ jsx156("div", { className: "flex items-center justify-center p-8 text-center", children: /* @__PURE__ */ jsxs92("div", { className: "text-destructive text-sm", children: [
|
|
13696
13115
|
/* @__PURE__ */ jsxs92("p", { children: [
|
|
@@ -13720,11 +13139,11 @@ __name(NotificationsListContainer, "NotificationsListContainer");
|
|
|
13720
13139
|
|
|
13721
13140
|
// src/features/notification/components/modals/NotificationModal.tsx
|
|
13722
13141
|
import { BellIcon } from "lucide-react";
|
|
13723
|
-
import { useTranslations as
|
|
13142
|
+
import { useTranslations as useTranslations60 } from "next-intl";
|
|
13724
13143
|
import { Fragment as Fragment29, useCallback as useCallback22, useEffect as useEffect46, useMemo as useMemo21, useRef as useRef19, useState as useState53 } from "react";
|
|
13725
13144
|
import { jsx as jsx157, jsxs as jsxs93 } from "react/jsx-runtime";
|
|
13726
13145
|
function NotificationModalContent({ isOpen, setIsOpen }) {
|
|
13727
|
-
const
|
|
13146
|
+
const _instanceId = useRef19(Math.random().toString(36).substr(2, 9));
|
|
13728
13147
|
const {
|
|
13729
13148
|
notifications,
|
|
13730
13149
|
addNotification,
|
|
@@ -13737,8 +13156,12 @@ function NotificationModalContent({ isOpen, setIsOpen }) {
|
|
|
13737
13156
|
shouldRefresh,
|
|
13738
13157
|
lastLoaded
|
|
13739
13158
|
} = useNotificationContext();
|
|
13740
|
-
const {
|
|
13741
|
-
|
|
13159
|
+
const {
|
|
13160
|
+
socketNotifications,
|
|
13161
|
+
removeSocketNotification: _removeSocketNotification,
|
|
13162
|
+
clearSocketNotifications
|
|
13163
|
+
} = useSocketContext();
|
|
13164
|
+
const t = useTranslations60();
|
|
13742
13165
|
const generateUrl = usePageUrlGenerator();
|
|
13743
13166
|
const [newNotifications, setNewNotifications] = useState53(false);
|
|
13744
13167
|
const preventAutoClose = useRef19(false);
|
|
@@ -13891,11 +13314,11 @@ function PushNotificationProvider({ children }) {
|
|
|
13891
13314
|
__name(PushNotificationProvider, "PushNotificationProvider");
|
|
13892
13315
|
|
|
13893
13316
|
// src/features/role/components/details/RoleDetails.tsx
|
|
13894
|
-
import { useTranslations as
|
|
13317
|
+
import { useTranslations as useTranslations61 } from "next-intl";
|
|
13895
13318
|
import { jsx as jsx159 } from "react/jsx-runtime";
|
|
13896
13319
|
function RoleDetails() {
|
|
13897
13320
|
const { role } = useRoleContext();
|
|
13898
|
-
const t =
|
|
13321
|
+
const t = useTranslations61();
|
|
13899
13322
|
if (!role) return null;
|
|
13900
13323
|
return /* @__PURE__ */ jsx159(Card, { className: "w-full", children: /* @__PURE__ */ jsx159(CardContent, { className: "p-4", children: /* @__PURE__ */ jsx159(AttributeElement, { title: t(`role.fields.description.label`), value: role.description }) }) });
|
|
13901
13324
|
}
|
|
@@ -13914,10 +13337,10 @@ function RoleContainer() {
|
|
|
13914
13337
|
__name(RoleContainer, "RoleContainer");
|
|
13915
13338
|
|
|
13916
13339
|
// src/features/role/components/forms/FormRoles.tsx
|
|
13917
|
-
import { useTranslations as
|
|
13340
|
+
import { useTranslations as useTranslations62 } from "next-intl";
|
|
13918
13341
|
import { jsx as jsx161, jsxs as jsxs95 } from "react/jsx-runtime";
|
|
13919
13342
|
function FormRoles({ form, id, name, roles }) {
|
|
13920
|
-
const t =
|
|
13343
|
+
const t = useTranslations62();
|
|
13921
13344
|
const { hasAccesToFeature } = useCurrentUserContext();
|
|
13922
13345
|
return /* @__PURE__ */ jsx161("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsx161(FormFieldWrapper, { form, name: id, label: name, children: (field) => /* @__PURE__ */ jsx161("div", { children: roles.filter((role) => role.isSelectable).sort((a, b) => a.name.localeCompare(b.name)).map((role) => {
|
|
13923
13346
|
if (role.requiredFeature && !hasAccesToFeature(role.requiredFeature.id)) return null;
|
|
@@ -13948,13 +13371,13 @@ function FormRoles({ form, id, name, roles }) {
|
|
|
13948
13371
|
__name(FormRoles, "FormRoles");
|
|
13949
13372
|
|
|
13950
13373
|
// src/features/role/components/forms/RemoveUserFromRole.tsx
|
|
13951
|
-
import { useTranslations as
|
|
13374
|
+
import { useTranslations as useTranslations63 } from "next-intl";
|
|
13952
13375
|
import { useEffect as useEffect47, useState as useState54 } from "react";
|
|
13953
13376
|
import { Fragment as Fragment32, jsx as jsx162, jsxs as jsxs96 } from "react/jsx-runtime";
|
|
13954
13377
|
function RemoveUserFromRole({ role, user, refresh }) {
|
|
13955
13378
|
const [open, setOpen] = useState54(false);
|
|
13956
13379
|
const [canRemove, setCanRemove] = useState54(false);
|
|
13957
|
-
const t =
|
|
13380
|
+
const t = useTranslations63();
|
|
13958
13381
|
useEffect47(() => {
|
|
13959
13382
|
async function checkCompanyAdminDeletability() {
|
|
13960
13383
|
const roleUsers = await UserService.findAllUsersByRole({
|
|
@@ -14024,7 +13447,7 @@ __name(RemoveUserFromRole, "RemoveUserFromRole");
|
|
|
14024
13447
|
|
|
14025
13448
|
// src/features/role/components/forms/UserRoleAdd.tsx
|
|
14026
13449
|
import { PlusCircle as PlusCircle2 } from "lucide-react";
|
|
14027
|
-
import { useTranslations as
|
|
13450
|
+
import { useTranslations as useTranslations64 } from "next-intl";
|
|
14028
13451
|
import { useCallback as useCallback23, useEffect as useEffect48, useRef as useRef20, useState as useState55 } from "react";
|
|
14029
13452
|
import { Fragment as Fragment33, jsx as jsx163, jsxs as jsxs97 } from "react/jsx-runtime";
|
|
14030
13453
|
function UserRoleAdd({ user, refresh }) {
|
|
@@ -14032,7 +13455,7 @@ function UserRoleAdd({ user, refresh }) {
|
|
|
14032
13455
|
const inputRef = useRef20(null);
|
|
14033
13456
|
const [searchTerm, setSearchTerm] = useState55("");
|
|
14034
13457
|
const [roles, setRoles] = useState55([]);
|
|
14035
|
-
const t =
|
|
13458
|
+
const t = useTranslations64();
|
|
14036
13459
|
const addUserToRole = /* @__PURE__ */ __name(async (role) => {
|
|
14037
13460
|
await RoleService.addUserToRole({
|
|
14038
13461
|
roleId: role.id,
|
|
@@ -14121,10 +13544,10 @@ function UserRoleAdd({ user, refresh }) {
|
|
|
14121
13544
|
__name(UserRoleAdd, "UserRoleAdd");
|
|
14122
13545
|
|
|
14123
13546
|
// src/features/role/components/lists/RolesList.tsx
|
|
14124
|
-
import { useTranslations as
|
|
13547
|
+
import { useTranslations as useTranslations65 } from "next-intl";
|
|
14125
13548
|
import { jsx as jsx164 } from "react/jsx-runtime";
|
|
14126
13549
|
function RolesList() {
|
|
14127
|
-
const t =
|
|
13550
|
+
const t = useTranslations65();
|
|
14128
13551
|
const data = useDataListRetriever({
|
|
14129
13552
|
retriever: /* @__PURE__ */ __name((params) => RoleService.findAllRoles(params), "retriever"),
|
|
14130
13553
|
retrieverParams: {},
|
|
@@ -14143,10 +13566,10 @@ function RolesList() {
|
|
|
14143
13566
|
__name(RolesList, "RolesList");
|
|
14144
13567
|
|
|
14145
13568
|
// src/features/role/components/lists/UserRolesList.tsx
|
|
14146
|
-
import { useTranslations as
|
|
13569
|
+
import { useTranslations as useTranslations66 } from "next-intl";
|
|
14147
13570
|
import { jsx as jsx165 } from "react/jsx-runtime";
|
|
14148
13571
|
function UserRolesList({ user }) {
|
|
14149
|
-
const t =
|
|
13572
|
+
const t = useTranslations66();
|
|
14150
13573
|
const data = useDataListRetriever({
|
|
14151
13574
|
retriever: /* @__PURE__ */ __name((params) => RoleService.findAllRolesByUser(params), "retriever"),
|
|
14152
13575
|
retrieverParams: { userId: user.id },
|
|
@@ -14249,21 +13672,10 @@ function OAuthRedirectUriInput({
|
|
|
14249
13672
|
)
|
|
14250
13673
|
] }, index);
|
|
14251
13674
|
}) }),
|
|
14252
|
-
/* @__PURE__ */ jsxs98(
|
|
14253
|
-
|
|
14254
|
-
|
|
14255
|
-
|
|
14256
|
-
variant: "outline",
|
|
14257
|
-
size: "sm",
|
|
14258
|
-
onClick: handleAdd,
|
|
14259
|
-
disabled,
|
|
14260
|
-
className: "mt-2",
|
|
14261
|
-
children: [
|
|
14262
|
-
/* @__PURE__ */ jsx166(Plus, { className: "h-4 w-4 mr-2" }),
|
|
14263
|
-
"Add Redirect URI"
|
|
14264
|
-
]
|
|
14265
|
-
}
|
|
14266
|
-
),
|
|
13675
|
+
/* @__PURE__ */ jsxs98(Button, { type: "button", variant: "outline", size: "sm", onClick: handleAdd, disabled, className: "mt-2", children: [
|
|
13676
|
+
/* @__PURE__ */ jsx166(Plus, { className: "h-4 w-4 mr-2" }),
|
|
13677
|
+
"Add Redirect URI"
|
|
13678
|
+
] }),
|
|
14267
13679
|
error && /* @__PURE__ */ jsx166("p", { className: "text-sm text-destructive", children: error })
|
|
14268
13680
|
] });
|
|
14269
13681
|
}
|
|
@@ -14290,15 +13702,18 @@ function OAuthScopeSelector({
|
|
|
14290
13702
|
},
|
|
14291
13703
|
[value, onChange]
|
|
14292
13704
|
);
|
|
14293
|
-
const groupedScopes = availableScopes.reduce(
|
|
14294
|
-
|
|
14295
|
-
|
|
14296
|
-
|
|
14297
|
-
acc[groupName]
|
|
14298
|
-
|
|
14299
|
-
|
|
14300
|
-
|
|
14301
|
-
|
|
13705
|
+
const groupedScopes = availableScopes.reduce(
|
|
13706
|
+
(acc, scope) => {
|
|
13707
|
+
const [category] = scope.scope.split(":");
|
|
13708
|
+
const groupName = category === scope.scope ? "General" : category;
|
|
13709
|
+
if (!acc[groupName]) {
|
|
13710
|
+
acc[groupName] = [];
|
|
13711
|
+
}
|
|
13712
|
+
acc[groupName].push(scope);
|
|
13713
|
+
return acc;
|
|
13714
|
+
},
|
|
13715
|
+
{}
|
|
13716
|
+
);
|
|
14302
13717
|
return /* @__PURE__ */ jsxs99("div", { className: "space-y-4", children: [
|
|
14303
13718
|
/* @__PURE__ */ jsxs99("div", { children: [
|
|
14304
13719
|
/* @__PURE__ */ jsxs99(Label, { children: [
|
|
@@ -14327,17 +13742,10 @@ function OAuthScopeSelector({
|
|
|
14327
13742
|
}
|
|
14328
13743
|
),
|
|
14329
13744
|
/* @__PURE__ */ jsxs99("div", { className: "flex-1", children: [
|
|
14330
|
-
/* @__PURE__ */ jsxs99(
|
|
14331
|
-
|
|
14332
|
-
{
|
|
14333
|
-
|
|
14334
|
-
className: "text-sm font-medium cursor-pointer",
|
|
14335
|
-
children: [
|
|
14336
|
-
scopeInfo.name,
|
|
14337
|
-
isAdmin && /* @__PURE__ */ jsx167("span", { className: "ml-2 text-xs text-destructive", children: "(Dangerous)" })
|
|
14338
|
-
]
|
|
14339
|
-
}
|
|
14340
|
-
),
|
|
13745
|
+
/* @__PURE__ */ jsxs99(Label, { htmlFor: `scope-${scopeInfo.scope}`, className: "text-sm font-medium cursor-pointer", children: [
|
|
13746
|
+
scopeInfo.name,
|
|
13747
|
+
isAdmin && /* @__PURE__ */ jsx167("span", { className: "ml-2 text-xs text-destructive", children: "(Dangerous)" })
|
|
13748
|
+
] }),
|
|
14341
13749
|
/* @__PURE__ */ jsx167("p", { className: "text-xs text-muted-foreground", children: scopeInfo.description })
|
|
14342
13750
|
] })
|
|
14343
13751
|
]
|
|
@@ -14355,12 +13763,7 @@ __name(OAuthScopeSelector, "OAuthScopeSelector");
|
|
|
14355
13763
|
import { useState as useState56, useCallback as useCallback26 } from "react";
|
|
14356
13764
|
import { Copy, Check, AlertTriangle } from "lucide-react";
|
|
14357
13765
|
import { jsx as jsx168, jsxs as jsxs100 } from "react/jsx-runtime";
|
|
14358
|
-
function OAuthClientSecretDisplay({
|
|
14359
|
-
secret,
|
|
14360
|
-
onDismiss,
|
|
14361
|
-
open,
|
|
14362
|
-
clientName
|
|
14363
|
-
}) {
|
|
13766
|
+
function OAuthClientSecretDisplay({ secret, onDismiss, open, clientName }) {
|
|
14364
13767
|
const [copied, setCopied] = useState56(false);
|
|
14365
13768
|
const handleCopy = useCallback26(async () => {
|
|
14366
13769
|
try {
|
|
@@ -14392,15 +13795,7 @@ function OAuthClientSecretDisplay({
|
|
|
14392
13795
|
] })
|
|
14393
13796
|
] }),
|
|
14394
13797
|
/* @__PURE__ */ jsxs100("div", { className: "flex items-center space-x-2", children: [
|
|
14395
|
-
/* @__PURE__ */ jsx168("div", { className: "flex-1", children: /* @__PURE__ */ jsx168(
|
|
14396
|
-
Input,
|
|
14397
|
-
{
|
|
14398
|
-
value: secret,
|
|
14399
|
-
readOnly: true,
|
|
14400
|
-
className: "font-mono text-sm",
|
|
14401
|
-
onClick: (e) => e.currentTarget.select()
|
|
14402
|
-
}
|
|
14403
|
-
) }),
|
|
13798
|
+
/* @__PURE__ */ jsx168("div", { className: "flex-1", children: /* @__PURE__ */ jsx168(Input, { value: secret, readOnly: true, className: "font-mono text-sm", onClick: (e) => e.currentTarget.select() }) }),
|
|
14404
13799
|
/* @__PURE__ */ jsx168(
|
|
14405
13800
|
Button,
|
|
14406
13801
|
{
|
|
@@ -14423,12 +13818,7 @@ __name(OAuthClientSecretDisplay, "OAuthClientSecretDisplay");
|
|
|
14423
13818
|
import { formatDistanceToNow } from "date-fns";
|
|
14424
13819
|
import { Key, MoreVertical, Pencil, Trash2 as Trash22 } from "lucide-react";
|
|
14425
13820
|
import { jsx as jsx169, jsxs as jsxs101 } from "react/jsx-runtime";
|
|
14426
|
-
function OAuthClientCard({
|
|
14427
|
-
client,
|
|
14428
|
-
onClick,
|
|
14429
|
-
onEdit,
|
|
14430
|
-
onDelete
|
|
14431
|
-
}) {
|
|
13821
|
+
function OAuthClientCard({ client, onClick, onEdit, onDelete }) {
|
|
14432
13822
|
const truncatedId = client.clientId.length > 12 ? `${client.clientId.slice(0, 8)}...${client.clientId.slice(-4)}` : client.clientId;
|
|
14433
13823
|
const createdAgo = client.createdAt ? formatDistanceToNow(new Date(client.createdAt), { addSuffix: true }) : "Unknown";
|
|
14434
13824
|
return /* @__PURE__ */ jsxs101(
|
|
@@ -14448,13 +13838,19 @@ function OAuthClientCard({
|
|
|
14448
13838
|
(onEdit || onDelete) && /* @__PURE__ */ jsxs101(DropdownMenu, { children: [
|
|
14449
13839
|
/* @__PURE__ */ jsx169(DropdownMenuTrigger, { onClick: (e) => e.stopPropagation(), children: /* @__PURE__ */ jsx169(Button, { render: /* @__PURE__ */ jsx169("div", {}), nativeButton: false, variant: "ghost", size: "icon", className: "h-8 w-8", children: /* @__PURE__ */ jsx169(MoreVertical, { className: "h-4 w-4" }) }) }),
|
|
14450
13840
|
/* @__PURE__ */ jsxs101(DropdownMenuContent, { align: "end", children: [
|
|
14451
|
-
onEdit && /* @__PURE__ */ jsxs101(
|
|
14452
|
-
|
|
14453
|
-
|
|
14454
|
-
|
|
14455
|
-
|
|
14456
|
-
|
|
14457
|
-
|
|
13841
|
+
onEdit && /* @__PURE__ */ jsxs101(
|
|
13842
|
+
DropdownMenuItem,
|
|
13843
|
+
{
|
|
13844
|
+
onClick: (e) => {
|
|
13845
|
+
e.stopPropagation();
|
|
13846
|
+
onEdit();
|
|
13847
|
+
},
|
|
13848
|
+
children: [
|
|
13849
|
+
/* @__PURE__ */ jsx169(Pencil, { className: "h-4 w-4 mr-2" }),
|
|
13850
|
+
"Edit"
|
|
13851
|
+
]
|
|
13852
|
+
}
|
|
13853
|
+
),
|
|
14458
13854
|
onDelete && /* @__PURE__ */ jsxs101(
|
|
14459
13855
|
DropdownMenuItem,
|
|
14460
13856
|
{
|
|
@@ -14563,12 +13959,7 @@ __name(OAuthClientList, "OAuthClientList");
|
|
|
14563
13959
|
// src/features/oauth/components/OAuthClientForm.tsx
|
|
14564
13960
|
import { useState as useState57, useCallback as useCallback27 } from "react";
|
|
14565
13961
|
import { jsx as jsx171, jsxs as jsxs103 } from "react/jsx-runtime";
|
|
14566
|
-
function OAuthClientForm({
|
|
14567
|
-
client,
|
|
14568
|
-
onSubmit,
|
|
14569
|
-
onCancel,
|
|
14570
|
-
isLoading = false
|
|
14571
|
-
}) {
|
|
13962
|
+
function OAuthClientForm({ client, onSubmit, onCancel, isLoading = false }) {
|
|
14572
13963
|
const isEditMode = !!client;
|
|
14573
13964
|
const [formState, setFormState] = useState57({
|
|
14574
13965
|
name: client?.name || "",
|
|
@@ -14819,18 +14210,10 @@ function OAuthClientDetail({
|
|
|
14819
14210
|
/* @__PURE__ */ jsx172(Pencil2, { className: "h-4 w-4 mr-2" }),
|
|
14820
14211
|
"Edit"
|
|
14821
14212
|
] }),
|
|
14822
|
-
onDelete && /* @__PURE__ */ jsxs104(
|
|
14823
|
-
|
|
14824
|
-
|
|
14825
|
-
|
|
14826
|
-
onClick: () => setShowDeleteConfirm(true),
|
|
14827
|
-
disabled: isLoading,
|
|
14828
|
-
children: [
|
|
14829
|
-
/* @__PURE__ */ jsx172(Trash23, { className: "h-4 w-4 mr-2" }),
|
|
14830
|
-
"Delete"
|
|
14831
|
-
]
|
|
14832
|
-
}
|
|
14833
|
-
)
|
|
14213
|
+
onDelete && /* @__PURE__ */ jsxs104(Button, { variant: "destructive", onClick: () => setShowDeleteConfirm(true), disabled: isLoading, children: [
|
|
14214
|
+
/* @__PURE__ */ jsx172(Trash23, { className: "h-4 w-4 mr-2" }),
|
|
14215
|
+
"Delete"
|
|
14216
|
+
] })
|
|
14834
14217
|
] })
|
|
14835
14218
|
] })
|
|
14836
14219
|
] }),
|
|
@@ -14873,20 +14256,9 @@ __name(OAuthClientDetail, "OAuthClientDetail");
|
|
|
14873
14256
|
// src/features/oauth/components/consent/OAuthConsentHeader.tsx
|
|
14874
14257
|
import { Shield } from "lucide-react";
|
|
14875
14258
|
import { jsx as jsx173, jsxs as jsxs105 } from "react/jsx-runtime";
|
|
14876
|
-
function OAuthConsentHeader({
|
|
14877
|
-
client,
|
|
14878
|
-
logoUrl,
|
|
14879
|
-
appName = "Only35"
|
|
14880
|
-
}) {
|
|
14259
|
+
function OAuthConsentHeader({ client, logoUrl, appName = "Only35" }) {
|
|
14881
14260
|
return /* @__PURE__ */ jsxs105("div", { className: "text-center space-y-4", children: [
|
|
14882
|
-
/* @__PURE__ */ jsx173("div", { className: "flex justify-center", children: logoUrl ? /* @__PURE__ */ jsx173(
|
|
14883
|
-
"img",
|
|
14884
|
-
{
|
|
14885
|
-
src: logoUrl,
|
|
14886
|
-
alt: appName,
|
|
14887
|
-
className: "h-12 w-auto"
|
|
14888
|
-
}
|
|
14889
|
-
) : /* @__PURE__ */ jsx173("div", { className: "h-12 w-12 rounded-full bg-primary flex items-center justify-center", children: /* @__PURE__ */ jsx173(Shield, { className: "h-6 w-6 text-primary-foreground" }) }) }),
|
|
14261
|
+
/* @__PURE__ */ jsx173("div", { className: "flex justify-center", children: logoUrl ? /* @__PURE__ */ jsx173("img", { src: logoUrl, alt: appName, className: "h-12 w-auto" }) : /* @__PURE__ */ jsx173("div", { className: "h-12 w-12 rounded-full bg-primary flex items-center justify-center", children: /* @__PURE__ */ jsx173(Shield, { className: "h-6 w-6 text-primary-foreground" }) }) }),
|
|
14890
14262
|
/* @__PURE__ */ jsxs105("div", { className: "space-y-2", children: [
|
|
14891
14263
|
/* @__PURE__ */ jsxs105("h1", { className: "text-2xl font-bold", children: [
|
|
14892
14264
|
"Authorize ",
|
|
@@ -14894,8 +14266,7 @@ function OAuthConsentHeader({
|
|
|
14894
14266
|
] }),
|
|
14895
14267
|
/* @__PURE__ */ jsxs105("p", { className: "text-muted-foreground", children: [
|
|
14896
14268
|
/* @__PURE__ */ jsx173("span", { className: "font-medium text-foreground", children: client.name }),
|
|
14897
|
-
" ",
|
|
14898
|
-
"wants to access your ",
|
|
14269
|
+
" wants to access your ",
|
|
14899
14270
|
appName,
|
|
14900
14271
|
" account"
|
|
14901
14272
|
] })
|
|
@@ -14905,16 +14276,7 @@ function OAuthConsentHeader({
|
|
|
14905
14276
|
__name(OAuthConsentHeader, "OAuthConsentHeader");
|
|
14906
14277
|
|
|
14907
14278
|
// src/features/oauth/components/consent/OAuthScopeList.tsx
|
|
14908
|
-
import {
|
|
14909
|
-
Eye,
|
|
14910
|
-
Pencil as Pencil3,
|
|
14911
|
-
Image as Image15,
|
|
14912
|
-
Upload,
|
|
14913
|
-
Film,
|
|
14914
|
-
FolderPlus,
|
|
14915
|
-
User,
|
|
14916
|
-
Shield as Shield2
|
|
14917
|
-
} from "lucide-react";
|
|
14279
|
+
import { Eye, Pencil as Pencil3, Image as Image15, Upload, Film, FolderPlus, User, Shield as Shield2 } from "lucide-react";
|
|
14918
14280
|
import { jsx as jsx174, jsxs as jsxs106 } from "react/jsx-runtime";
|
|
14919
14281
|
var SCOPE_ICONS = {
|
|
14920
14282
|
eye: Eye,
|
|
@@ -14934,20 +14296,13 @@ function OAuthScopeList({ scopes }) {
|
|
|
14934
14296
|
/* @__PURE__ */ jsx174("h2", { className: "text-sm font-medium text-muted-foreground uppercase tracking-wide", children: "This will allow the application to:" }),
|
|
14935
14297
|
/* @__PURE__ */ jsx174("ul", { className: "space-y-3", children: scopes.map((scope) => {
|
|
14936
14298
|
const IconComponent = scope.icon ? SCOPE_ICONS[scope.icon] : Eye;
|
|
14937
|
-
return /* @__PURE__ */ jsxs106(
|
|
14938
|
-
"
|
|
14939
|
-
{
|
|
14940
|
-
|
|
14941
|
-
children:
|
|
14942
|
-
|
|
14943
|
-
|
|
14944
|
-
/* @__PURE__ */ jsx174("p", { className: "font-medium", children: scope.name }),
|
|
14945
|
-
/* @__PURE__ */ jsx174("p", { className: "text-sm text-muted-foreground", children: scope.description })
|
|
14946
|
-
] })
|
|
14947
|
-
]
|
|
14948
|
-
},
|
|
14949
|
-
scope.scope
|
|
14950
|
-
);
|
|
14299
|
+
return /* @__PURE__ */ jsxs106("li", { className: "flex items-start gap-3 p-3 rounded-lg bg-muted/50", children: [
|
|
14300
|
+
/* @__PURE__ */ jsx174("div", { className: "flex-shrink-0 mt-0.5", children: /* @__PURE__ */ jsx174("div", { className: "h-8 w-8 rounded-full bg-primary/10 flex items-center justify-center", children: IconComponent && /* @__PURE__ */ jsx174(IconComponent, { className: "h-4 w-4 text-primary" }) }) }),
|
|
14301
|
+
/* @__PURE__ */ jsxs106("div", { className: "flex-1", children: [
|
|
14302
|
+
/* @__PURE__ */ jsx174("p", { className: "font-medium", children: scope.name }),
|
|
14303
|
+
/* @__PURE__ */ jsx174("p", { className: "text-sm text-muted-foreground", children: scope.description })
|
|
14304
|
+
] })
|
|
14305
|
+
] }, scope.scope);
|
|
14951
14306
|
}) })
|
|
14952
14307
|
] });
|
|
14953
14308
|
}
|
|
@@ -14955,37 +14310,16 @@ __name(OAuthScopeList, "OAuthScopeList");
|
|
|
14955
14310
|
|
|
14956
14311
|
// src/features/oauth/components/consent/OAuthConsentActions.tsx
|
|
14957
14312
|
import { jsx as jsx175, jsxs as jsxs107 } from "react/jsx-runtime";
|
|
14958
|
-
function OAuthConsentActions({
|
|
14959
|
-
onApprove,
|
|
14960
|
-
onDeny,
|
|
14961
|
-
isLoading = false
|
|
14962
|
-
}) {
|
|
14313
|
+
function OAuthConsentActions({ onApprove, onDeny, isLoading = false }) {
|
|
14963
14314
|
return /* @__PURE__ */ jsxs107("div", { className: "flex flex-col sm:flex-row gap-3", children: [
|
|
14964
|
-
/* @__PURE__ */ jsx175(
|
|
14965
|
-
|
|
14966
|
-
{
|
|
14967
|
-
variant: "outline",
|
|
14968
|
-
onClick: onDeny,
|
|
14969
|
-
disabled: isLoading,
|
|
14970
|
-
className: "flex-1",
|
|
14971
|
-
children: "Deny"
|
|
14972
|
-
}
|
|
14973
|
-
),
|
|
14974
|
-
/* @__PURE__ */ jsx175(
|
|
14975
|
-
Button,
|
|
14976
|
-
{
|
|
14977
|
-
onClick: onApprove,
|
|
14978
|
-
disabled: isLoading,
|
|
14979
|
-
className: "flex-1",
|
|
14980
|
-
children: isLoading ? "Authorizing..." : "Authorize"
|
|
14981
|
-
}
|
|
14982
|
-
)
|
|
14315
|
+
/* @__PURE__ */ jsx175(Button, { variant: "outline", onClick: onDeny, disabled: isLoading, className: "flex-1", children: "Deny" }),
|
|
14316
|
+
/* @__PURE__ */ jsx175(Button, { onClick: onApprove, disabled: isLoading, className: "flex-1", children: isLoading ? "Authorizing..." : "Authorize" })
|
|
14983
14317
|
] });
|
|
14984
14318
|
}
|
|
14985
14319
|
__name(OAuthConsentActions, "OAuthConsentActions");
|
|
14986
14320
|
|
|
14987
14321
|
// src/features/oauth/components/consent/OAuthConsentScreen.tsx
|
|
14988
|
-
import { ExternalLink as ExternalLink2, AlertTriangle as AlertTriangle2, Loader2 as
|
|
14322
|
+
import { ExternalLink as ExternalLink2, AlertTriangle as AlertTriangle2, Loader2 as Loader23 } from "lucide-react";
|
|
14989
14323
|
import { jsx as jsx176, jsxs as jsxs108 } from "react/jsx-runtime";
|
|
14990
14324
|
function OAuthConsentScreen({
|
|
14991
14325
|
params,
|
|
@@ -14997,7 +14331,7 @@ function OAuthConsentScreen({
|
|
|
14997
14331
|
const { clientInfo, isLoading, error, approve, deny, isSubmitting } = useOAuthConsent(params);
|
|
14998
14332
|
if (isLoading) {
|
|
14999
14333
|
return /* @__PURE__ */ jsx176("div", { className: "min-h-screen flex items-center justify-center p-4", children: /* @__PURE__ */ jsx176(Card, { className: "w-full max-w-md", children: /* @__PURE__ */ jsxs108(CardContent, { className: "flex flex-col items-center justify-center py-12", children: [
|
|
15000
|
-
/* @__PURE__ */ jsx176(
|
|
14334
|
+
/* @__PURE__ */ jsx176(Loader23, { className: "h-8 w-8 animate-spin text-muted-foreground" }),
|
|
15001
14335
|
/* @__PURE__ */ jsx176("p", { className: "mt-4 text-muted-foreground", children: "Loading authorization request..." })
|
|
15002
14336
|
] }) }) });
|
|
15003
14337
|
}
|
|
@@ -15010,14 +14344,7 @@ function OAuthConsentScreen({
|
|
|
15010
14344
|
const { client, scopes } = clientInfo;
|
|
15011
14345
|
return /* @__PURE__ */ jsx176("div", { className: "min-h-screen flex items-center justify-center p-4 bg-muted/30", children: /* @__PURE__ */ jsxs108(Card, { className: "w-full max-w-md", children: [
|
|
15012
14346
|
/* @__PURE__ */ jsxs108(CardContent, { className: "pt-6 space-y-6", children: [
|
|
15013
|
-
/* @__PURE__ */ jsx176(
|
|
15014
|
-
OAuthConsentHeader,
|
|
15015
|
-
{
|
|
15016
|
-
client,
|
|
15017
|
-
logoUrl,
|
|
15018
|
-
appName
|
|
15019
|
-
}
|
|
15020
|
-
),
|
|
14347
|
+
/* @__PURE__ */ jsx176(OAuthConsentHeader, { client, logoUrl, appName }),
|
|
15021
14348
|
/* @__PURE__ */ jsx176(Separator, {}),
|
|
15022
14349
|
/* @__PURE__ */ jsx176(OAuthScopeList, { scopes }),
|
|
15023
14350
|
/* @__PURE__ */ jsx176(Separator, {}),
|
|
@@ -15028,14 +14355,7 @@ function OAuthConsentScreen({
|
|
|
15028
14355
|
/* @__PURE__ */ jsx176("p", { className: "font-mono text-xs mt-1 break-all", children: params.redirectUri })
|
|
15029
14356
|
] })
|
|
15030
14357
|
] }),
|
|
15031
|
-
/* @__PURE__ */ jsx176(
|
|
15032
|
-
OAuthConsentActions,
|
|
15033
|
-
{
|
|
15034
|
-
onApprove: approve,
|
|
15035
|
-
onDeny: deny,
|
|
15036
|
-
isLoading: isSubmitting
|
|
15037
|
-
}
|
|
15038
|
-
)
|
|
14358
|
+
/* @__PURE__ */ jsx176(OAuthConsentActions, { onApprove: approve, onDeny: deny, isLoading: isSubmitting })
|
|
15039
14359
|
] }),
|
|
15040
14360
|
/* @__PURE__ */ jsx176(CardFooter, { className: "justify-center", children: /* @__PURE__ */ jsxs108("p", { className: "text-xs text-center text-muted-foreground", children: [
|
|
15041
14361
|
"By authorizing, you agree to the app's",
|
|
@@ -15474,4 +14794,4 @@ export {
|
|
|
15474
14794
|
useOAuthClients,
|
|
15475
14795
|
useOAuthClient
|
|
15476
14796
|
};
|
|
15477
|
-
//# sourceMappingURL=chunk-
|
|
14797
|
+
//# sourceMappingURL=chunk-4PHADEKA.mjs.map
|