@xframework-ca-test/cli 1.0.32 → 1.0.34
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/ui/assets/AIVision-0025192f.js +4 -0
- package/dist/ui/assets/AccountDetails-42610e44.js +1 -0
- package/dist/ui/assets/AccountDetails-5b4cd3f7.js +1 -0
- package/dist/ui/assets/AccountServices-f68f471d.js +1 -0
- package/dist/ui/assets/AccountsList-262479cf.js +1 -0
- package/dist/ui/assets/ActionLink-9db8b1c2.js +1 -0
- package/dist/ui/assets/AdaptableCard-3d1e1f96.js +1 -0
- package/dist/ui/assets/AddAccount-2cd72664.js +1 -0
- package/dist/ui/assets/AddEditFile-6ae10d57.js +1 -0
- package/dist/ui/assets/AddEditTranslation-3812ff0f.js +1 -0
- package/dist/ui/assets/AiApiLogList-1eac39b7.js +1 -0
- package/dist/ui/assets/AiCa-2e90495f.js +1 -0
- package/dist/ui/assets/Alert-59d09a99.js +1 -0
- package/dist/ui/assets/ApiService-df126758.js +1 -0
- package/dist/ui/assets/AppLandingPage-afcea727.js +4 -0
- package/dist/ui/assets/AuditLogsList-ea37686b.js +1 -0
- package/dist/ui/assets/Auth0Callback-00729568.js +1 -0
- package/dist/ui/assets/BarCodes-4ff49536.js +1 -0
- package/dist/ui/assets/BlankLayout-7085ab88.js +1 -0
- package/dist/ui/assets/{BrainServices-a4bb698e.js → BrainServices-4cb93af5.js} +1 -1
- package/dist/ui/assets/CalendarList-689ed66a.js +2 -0
- package/dist/ui/assets/CalendarList-f4a9aa21.css +8 -0
- package/dist/ui/assets/CategoryList-a6d01041.js +1 -0
- package/dist/ui/assets/CategoryList-c03f4259.js +1 -0
- package/dist/ui/assets/ChatContainer-fec7b84d.js +1 -0
- package/dist/ui/assets/ChatsList-4b3194e4.js +1 -0
- package/dist/ui/assets/Check-af681a30.js +1 -0
- package/dist/ui/assets/CheckInVideo-aa9f50b2.js +6 -0
- package/dist/ui/assets/ClassicLayout-a9866742.js +2 -0
- package/dist/ui/assets/CompanyList-94119d71.js +1 -0
- package/dist/ui/assets/{CompanyService-1bf7c3c8.js → CompanyService-491a9cc1.js} +1 -1
- package/dist/ui/assets/{Component-59e4c14b.js → Component-566d01e0.js} +1 -1
- package/dist/ui/assets/ConfirmDialog-2838a642.js +1 -0
- package/dist/ui/assets/ContactDetails-c9dc0ed1.js +1 -0
- package/dist/ui/assets/{ContactService-92281a90.js → ContactService-8afcaeb7.js} +1 -1
- package/dist/ui/assets/ContactsList-5b06c9b8.js +1 -0
- package/dist/ui/assets/CountiesList-18b23cf7.js +1 -0
- package/dist/ui/assets/CountyDetails-ea024f14.js +1 -0
- package/dist/ui/assets/CourseDetails-8a5f8d63.js +1 -0
- package/dist/ui/assets/CourseList-3564fec3.js +1 -0
- package/dist/ui/assets/{CourseService-f0dc3bf1.js → CourseService-29ad460c.js} +1 -1
- package/dist/ui/assets/CreateSignature-c22e4a71.js +7 -0
- package/dist/ui/assets/{CustomerInfoField-fff65ace.js → CustomerInfoField-4bf880e2.js} +1 -1
- package/dist/ui/assets/DeckedLayout-610fe851.js +1 -0
- package/dist/ui/assets/DensitySelector-5d2e901f.js +1 -0
- package/dist/ui/assets/{DepartmentServices-3d56a9e7.js → DepartmentServices-a53e998b.js} +1 -1
- package/dist/ui/assets/{DigitalSignature-fff42e33.js → DigitalSignature-69eaf80c.js} +1 -1
- package/dist/ui/assets/{DocumemtManagementService-6501a5c1.js → DocumemtManagementService-85cde51a.js} +1 -1
- package/dist/ui/assets/DocumentActivity-bc938c61.js +1 -0
- package/dist/ui/assets/DocumentLayout-a12982d7.js +1 -0
- package/dist/ui/assets/DocumentList2-9c8c6284.js +23 -0
- package/dist/ui/assets/DocumentLists-1cdaae06.js +1 -0
- package/dist/ui/assets/DocumentUserSigned-f7371fc5.js +7 -0
- package/dist/ui/assets/DocumentsList-3b25907c.js +1 -0
- package/dist/ui/assets/DoubleSidedImage-b4bd3915.js +1 -0
- package/dist/ui/assets/{Drawer-949c18c6.js → Drawer-4f97e662.js} +1 -1
- package/dist/ui/assets/DynamicDashboard-0a41d287.js +1 -0
- package/dist/ui/assets/{DynamicTablesService-963fe77b.js → DynamicTablesService-6aa57f52.js} +1 -1
- package/dist/ui/assets/EditAccount-e42d66af.js +1 -0
- package/dist/ui/assets/EditLead-c8c9760a.js +1 -0
- package/dist/ui/assets/FaqItems-25d66543.js +6 -0
- package/dist/ui/assets/{FileManagementServices-25fd64c5.js → FileManagementServices-19b47568.js} +1 -1
- package/dist/ui/assets/{FolderOpen-88bfcc74.js → FolderOpen-7b0e2ac0.js} +1 -1
- package/dist/ui/assets/FormContainer-9a52b9e8.js +1 -0
- package/dist/ui/assets/{GeneralSettings-a7f805e8.js → GeneralSettings-c8c2f051.js} +5 -5
- package/dist/ui/assets/GenericPage-81e41302.js +1 -0
- package/dist/ui/assets/GridMapDetails-38f50b3c.js +1 -0
- package/dist/ui/assets/HorizontalMenuContent-fd559f4d.js +1 -0
- package/dist/ui/assets/{ImportFile-3f60d715.js → ImportFile-026b1771.js} +1 -1
- package/dist/ui/assets/{InlineSignaturePad-09c06619.js → InlineSignaturePad-f5630151.js} +1 -1
- package/dist/ui/assets/InvoicesList-9723bc5a.js +1 -0
- package/dist/ui/assets/{KeyVaultService-874d83fe.js → KeyVaultService-9608f0ff.js} +1 -1
- package/dist/ui/assets/LeadDetails-8cdaae0e.js +1 -0
- package/dist/ui/assets/{LeadSourceService-e46fa85e.js → LeadSourceService-cf71ea64.js} +1 -1
- package/dist/ui/assets/LeadsList-1ec20a77.js +1 -0
- package/dist/ui/assets/Logo-dd6f7656.js +1 -0
- package/dist/ui/assets/MapView-dcab88b3.js +1 -0
- package/dist/ui/assets/MarketingPage-998d10b0.js +4 -0
- package/dist/ui/assets/MenuNew-79fc95f3.js +1 -0
- package/dist/ui/assets/{MenuTable-c2c65021.js → MenuTable-f69e0fe4.js} +1 -1
- package/dist/ui/assets/MessageInput-07fcc5cb.js +21 -0
- package/dist/ui/assets/MessagesList-21d2b034.js +1 -0
- package/dist/ui/assets/ModernLayout-05af7cf7.js +1 -0
- package/dist/ui/assets/{NoData-8c485a3a.js → NoData-4cc4af03.js} +1 -1
- package/dist/ui/assets/Notify-8fb74d48.js +1 -0
- package/dist/ui/assets/OpportunitiesList-2f96958f.js +1 -0
- package/dist/ui/assets/OpportunityDetails-aaec3200.js +1 -0
- package/dist/ui/assets/{OpportunityServices-fa4fabfd.js → OpportunityServices-c4510dd2.js} +1 -1
- package/dist/ui/assets/OpportunityStatus-ea3b5ee2.js +1 -0
- package/dist/ui/assets/PageBreadcrumb-cf54a6e9.js +1 -0
- package/dist/ui/assets/{Password-d9294711.js → Password-21414dc6.js} +1 -1
- package/dist/ui/assets/PasswordInput-333c82ca.js +1 -0
- package/dist/ui/assets/{PreferenceService-75bf9db6.js → PreferenceService-d2b3e003.js} +1 -1
- package/dist/ui/assets/Profile-8c9fd2fc.js +1 -0
- package/dist/ui/assets/{ReportEditor-8880f57e.js → ReportEditor-4e4f6d53.js} +3 -3
- package/dist/ui/assets/{ReportViewer-9f1080f7.js → ReportViewer-616d3cfc.js} +30 -30
- package/dist/ui/assets/RoleEdit-a076ea85.js +1 -0
- package/dist/ui/assets/RoleForm-47691f91.js +1 -0
- package/dist/ui/assets/{RoleNew-49fadb16.js → RoleNew-e86a1513.js} +1 -1
- package/dist/ui/assets/{RoleService-7008da2c.js → RoleService-2f9ed883.js} +1 -1
- package/dist/ui/assets/ScheduleCycle-0ae23631.js +1 -0
- package/dist/ui/assets/{ScheduleService-7228f0a3.js → ScheduleService-41a88c41.js} +1 -1
- package/dist/ui/assets/ScreenList-8f58150b.js +1 -0
- package/dist/ui/assets/Settings-fc91c9d2.js +2 -0
- package/dist/ui/assets/{SetupWizard-4172e377.js → SetupWizard-d1363582.js} +1 -1
- package/dist/ui/assets/SimpleLayout-77cfb778.js +1 -0
- package/dist/ui/assets/StackedSideLayout-2f1ee9d1.js +1 -0
- package/dist/ui/assets/StickyFooter-3e569b80.js +1 -0
- package/dist/ui/assets/SupportRequets-0ecd4ab8.js +1 -0
- package/dist/ui/assets/{Switcher-c8648037.js → Switcher-e2fba588.js} +1 -1
- package/dist/ui/assets/TimeLogApprovalDataList-7b49a432.js +1 -0
- package/dist/ui/assets/TimeLogApprovalList-78cab2b6.js +1 -0
- package/dist/ui/assets/TimeLogList-592b29aa.js +1 -0
- package/dist/ui/assets/{TimeLogService-cd7b2f61.js → TimeLogService-83166cbc.js} +1 -1
- package/dist/ui/assets/TimesheetsList-d1520efb.js +1 -0
- package/dist/ui/assets/TranslationList-88d7d5d7.js +1 -0
- package/dist/ui/assets/TweaksPanel-bc10bc47.js +112 -0
- package/dist/ui/assets/{Upload-fb34ce03.js → Upload-be937eb6.js} +4 -4
- package/dist/ui/assets/UserEdit-1f8208f3.js +1 -0
- package/dist/ui/assets/UserForm-e9b56aff.js +1 -0
- package/dist/ui/assets/{UserNew-b36c342c.js → UserNew-31fa258f.js} +1 -1
- package/dist/ui/assets/{UserService-047aef51.js → UserService-1b93ceb0.js} +1 -1
- package/dist/ui/assets/ViewTimeLogForApproval-ae077050.js +1 -0
- package/dist/ui/assets/Views-1359da48.js +1 -0
- package/dist/ui/assets/WelcomeList-dc8666ec.js +9 -0
- package/dist/ui/assets/WidgetLayoutsService-49730609.js +1 -0
- package/dist/ui/assets/{WrapperCell-a7981b07.js → WrapperCell-3d5592cf.js} +1 -1
- package/dist/ui/assets/actioncell-6b5ebd6c.js +1 -0
- package/dist/ui/assets/{ar-3c9c213e.js → ar-fb4f0ea8.js} +1 -1
- package/dist/ui/assets/calendarList-ac838a86.js +2 -0
- package/dist/ui/assets/{cjs-162261df.js → cjs-998de55c.js} +1 -1
- package/dist/ui/assets/createSvgIcon-aba65987.js +1 -0
- package/dist/ui/assets/documentsList-4e2e061e.js +1 -0
- package/dist/ui/assets/{es-be649ede.js → es-cd58d3ad.js} +1 -1
- package/dist/ui/assets/{esm-f306d015.js → esm-c40433f8.js} +1 -1
- package/dist/ui/assets/gridList-e1571c87.js +1 -0
- package/dist/ui/assets/gridMapTable-d95f9c70.js +1 -0
- package/dist/ui/assets/{index-f6be0390.js → index-00a8eb64.js} +1 -1
- package/dist/ui/assets/index-04438b6b.js +22 -0
- package/dist/ui/assets/index-058738bc.js +1 -0
- package/dist/ui/assets/{index-e4c6057f.js → index-0b08ce18.js} +1 -1
- package/dist/ui/assets/index-0d730815.js +4 -0
- package/dist/ui/assets/index-0efcf53a.js +1 -0
- package/dist/ui/assets/index-0f432250.js +1 -0
- package/dist/ui/assets/{index-cebd880b.js → index-0fd6e996.js} +1 -1
- package/dist/ui/assets/{index-49a94e54.js → index-11297f4a.js} +1 -1
- package/dist/ui/assets/index-14c1c1d7.js +1 -0
- package/dist/ui/assets/index-15e1f4be.js +1 -0
- package/dist/ui/assets/index-16586c21.js +1 -0
- package/dist/ui/assets/index-19346c14.js +1 -0
- package/dist/ui/assets/{index-16bb10a6.js → index-1dc2b9d2.js} +1 -1
- package/dist/ui/assets/index-211fbe21.js +1 -0
- package/dist/ui/assets/index-23e16bff.js +1 -0
- package/dist/ui/assets/index-27aef8b5.js +1 -0
- package/dist/ui/assets/{index-36228db5.js → index-289b3fd9.js} +1 -1
- package/dist/ui/assets/{index-a22a3546.js → index-2dae59b1.js} +1 -1
- package/dist/ui/assets/index-353fd6dd.js +1 -0
- package/dist/ui/assets/{index-ea125a16.js → index-359d245d.js} +1 -1
- package/dist/ui/assets/{index-c62ac197.js → index-3b5ce20a.js} +70 -62
- package/dist/ui/assets/index-3b929ba4.js +34 -0
- package/dist/ui/assets/index-42e3a337.js +1 -0
- package/dist/ui/assets/index-44b6de3a.js +1 -0
- package/dist/ui/assets/index-46d3ca9a.js +7 -0
- package/dist/ui/assets/{index-e3cc723f.js → index-49016ad0.js} +1 -1
- package/dist/ui/assets/index-51132258.js +1 -0
- package/dist/ui/assets/{index-dc103f22.js → index-52963879.js} +1 -1
- package/dist/ui/assets/{index-fcc1c999.js → index-533fd007.js} +1 -1
- package/dist/ui/assets/index-59ec468b.js +13 -0
- package/dist/ui/assets/index-5e2d5279.js +1 -0
- package/dist/ui/assets/{index-d17da176.js → index-62f95885.js} +1 -1
- package/dist/ui/assets/index-659c6412.js +1 -0
- package/dist/ui/assets/index-6873dfc3.js +1 -0
- package/dist/ui/assets/index-69a68d9e.js +1 -0
- package/dist/ui/assets/index-6a6902c7.js +1 -0
- package/dist/ui/assets/index-7596c6bb.js +1 -0
- package/dist/ui/assets/{index-47dcc43a.js → index-8045c5f0.js} +1 -1
- package/dist/ui/assets/{index-b028e652.js → index-8677acd1.js} +1 -1
- package/dist/ui/assets/{index-42e65911.js → index-88c52b97.js} +1 -1
- package/dist/ui/assets/index-89cfefab.js +1 -0
- package/dist/ui/assets/{index-bea4c3dc.js → index-8c0643fd.js} +1 -1
- package/dist/ui/assets/index-8d5b6a1f.js +1 -0
- package/dist/ui/assets/index-8d5d70f9.js +1 -0
- package/dist/ui/assets/{index-9b41371d.js → index-91505016.js} +1 -1
- package/dist/ui/assets/{index-ffc00dbb.js → index-92314073.js} +1 -1
- package/dist/ui/assets/index-985cf3f6.js +1 -0
- package/dist/ui/assets/index-a14e51de.js +1 -0
- package/dist/ui/assets/index-a733f80b.js +1 -0
- package/dist/ui/assets/index-a84d5808.js +1 -0
- package/dist/ui/assets/index-acac6006.js +1 -0
- package/dist/ui/assets/index-b0ef7ac3.js +1 -0
- package/dist/ui/assets/index-b6ef5984.js +1 -0
- package/dist/ui/assets/{index-fc9071e0.js → index-bd4edda3.js} +1 -1
- package/dist/ui/assets/{index-0ec72c4b.js → index-c29b8474.js} +1 -1
- package/dist/ui/assets/index-c88c7790.js +19 -0
- package/dist/ui/assets/index-ce89a95e.css +7 -0
- package/dist/ui/assets/index-d221d69e.js +1 -0
- package/dist/ui/assets/{index-f1576468.js → index-d33facae.js} +1 -1
- package/dist/ui/assets/index-e46c57a5.js +1 -0
- package/dist/ui/assets/index-e863817c.js +1 -0
- package/dist/ui/assets/index-f4af2342.js +1 -0
- package/dist/ui/assets/{index-77e820d0.js → index-fc9f8c4b.js} +1 -1
- package/dist/ui/assets/{index-ec2010d2.js → index-ff23edc5.js} +1 -1
- package/dist/ui/assets/{index.esm-70ab539c.js → index.esm-b2d342b5.js} +1 -1
- package/dist/ui/assets/liveLocation-8e0bb2f3.js +1 -0
- package/dist/ui/assets/{mapView-ab35acaa.js → mapView-c8063ed6.js} +1 -1
- package/dist/ui/assets/modeuls-setup-4b06843c.js +1 -0
- package/dist/ui/assets/{permissionHoc-6f787658.js → permissionHoc-0818bfb0.js} +1 -1
- package/dist/ui/assets/{react-21134174.js → react-12ddbe48.js} +1 -1
- package/dist/ui/assets/{react-4d5dc208.js → react-61e0b284.js} +1 -1
- package/dist/ui/assets/{strongPassword-bbec776a.js → strongPassword-6bc8786f.js} +1 -1
- package/dist/ui/assets/{styles-0608350c.js → styles-b7ae7bf6.js} +1 -1
- package/dist/ui/assets/{tableV2-4d1c9fd2.js → tableV2-99c808c0.js} +1 -1
- package/dist/ui/assets/tableV3-24eed052.js +1 -0
- package/dist/ui/assets/ticketRequestDetails-8b299fbd.js +1 -0
- package/dist/ui/assets/{useDidUpdate-25c4d4ed.js → useDidUpdate-de319a18.js} +1 -1
- package/dist/ui/assets/{useDrop-02b0e5d7.js → useDrop-8f0d11a7.js} +1 -1
- package/dist/ui/assets/useFilteredData-e8fad668.js +1 -0
- package/dist/ui/assets/{usePermission-d94b4984.js → usePermission-4689548c.js} +1 -1
- package/dist/ui/assets/{vendor-charts-eccea5d1.js → vendor-charts-4be0b5ab.js} +1 -1
- package/dist/ui/assets/{vendor-codemirror-c8203b49.js → vendor-codemirror-1a1216c9.js} +11 -11
- package/dist/ui/assets/{vendor-devex-33a39e11.js → vendor-devex-4076ffeb.js} +2 -2
- package/dist/ui/assets/{vendor-excel-ee8fc4e5.js → vendor-excel-3b3553df.js} +1 -1
- package/dist/ui/assets/{vendor-i18n-2fcb1983.js → vendor-i18n-b89304ef.js} +1 -1
- package/dist/ui/assets/vendor-mui-98daa63f.js +185 -0
- package/dist/ui/assets/{vendor-pdf-b2a5d8b1.js → vendor-pdf-3c29882d.js} +1 -1
- package/dist/ui/assets/withHeaderItem-df2cc5d9.js +1 -0
- package/dist/ui/assets/{zh-cn-1881e930.js → zh-cn-13c6c696.js} +1 -1
- package/dist/ui/config.js +16 -20
- package/dist/ui/index.html +9 -9
- package/dist/ui/manifest.json +2 -2
- package/index.bundle.js +23 -9
- package/package.json +1 -1
- package/dist/ui/assets/AIVision-4f515575.js +0 -4
- package/dist/ui/assets/AccountDetails-2b42d262.js +0 -1
- package/dist/ui/assets/AccountDetails-492dee8f.js +0 -1
- package/dist/ui/assets/AccountServices-62599aae.js +0 -1
- package/dist/ui/assets/AccountsList-fe7cb5f9.js +0 -1
- package/dist/ui/assets/ActionLink-33e476e1.js +0 -1
- package/dist/ui/assets/AdaptableCard-df7695d6.js +0 -1
- package/dist/ui/assets/AddAccount-a05910e8.js +0 -1
- package/dist/ui/assets/AddEditFile-063c229b.js +0 -1
- package/dist/ui/assets/AddEditTranslation-43beae49.js +0 -1
- package/dist/ui/assets/AiApiLogList-a488921d.js +0 -1
- package/dist/ui/assets/AiCa-9c1b25b2.js +0 -1
- package/dist/ui/assets/Alert-7dfbd254.js +0 -1
- package/dist/ui/assets/ApiService-2b99757f.js +0 -1
- package/dist/ui/assets/AppLandingPage-3956cf0c.js +0 -4
- package/dist/ui/assets/AuditLogsList-7a2ce37d.js +0 -1
- package/dist/ui/assets/Auth0Callback-b943f19f.js +0 -1
- package/dist/ui/assets/BarCodes-17ed5da4.js +0 -1
- package/dist/ui/assets/BlankLayout-2f6e1153.js +0 -1
- package/dist/ui/assets/CalendarList-25834ddb.css +0 -11
- package/dist/ui/assets/CalendarList-72739043.js +0 -2
- package/dist/ui/assets/CategoryList-9f82e9a3.js +0 -1
- package/dist/ui/assets/CategoryList-c97891e7.js +0 -1
- package/dist/ui/assets/ChatContainer-4a38b179.js +0 -1
- package/dist/ui/assets/ChatsList-6c2c3e2f.js +0 -1
- package/dist/ui/assets/Check-71f21a49.js +0 -1
- package/dist/ui/assets/CheckInVideo-cb5fa9a2.js +0 -6
- package/dist/ui/assets/ClassicLayout-7d09e5ac.js +0 -1
- package/dist/ui/assets/CompanyList-9532f511.js +0 -1
- package/dist/ui/assets/ConfirmDialog-3202eb3d.js +0 -1
- package/dist/ui/assets/ContactDetails-3b70919b.js +0 -1
- package/dist/ui/assets/ContactsList-e9ac0fa3.js +0 -1
- package/dist/ui/assets/CountiesList-6ad338a5.js +0 -1
- package/dist/ui/assets/CountyDetails-22d4bc89.js +0 -1
- package/dist/ui/assets/CourseDetails-18040b49.js +0 -1
- package/dist/ui/assets/CourseList-e502f89d.js +0 -1
- package/dist/ui/assets/CreateSignature-375d191b.js +0 -7
- package/dist/ui/assets/DeckedLayout-909ac220.js +0 -1
- package/dist/ui/assets/DensitySelector-a2c1c68f.js +0 -1
- package/dist/ui/assets/DocumentActivity-d63dacec.js +0 -1
- package/dist/ui/assets/DocumentLayout-637075fd.js +0 -1
- package/dist/ui/assets/DocumentList2-518d2fa4.js +0 -23
- package/dist/ui/assets/DocumentLists-2da9ff88.js +0 -1
- package/dist/ui/assets/DocumentUserSigned-27bfa6e6.js +0 -7
- package/dist/ui/assets/DocumentsList-9f56db71.js +0 -1
- package/dist/ui/assets/DoubleSidedImage-ae98733b.js +0 -1
- package/dist/ui/assets/DynamicDashboard-6f177244.js +0 -1
- package/dist/ui/assets/EditAccount-1c1a8318.js +0 -1
- package/dist/ui/assets/EditLead-cc38d2a2.js +0 -1
- package/dist/ui/assets/FaqItems-c1c85af7.js +0 -6
- package/dist/ui/assets/FormContainer-91c2b0e4.js +0 -1
- package/dist/ui/assets/GenericPage-25a5d92a.js +0 -1
- package/dist/ui/assets/GridMapDetails-851a5781.js +0 -1
- package/dist/ui/assets/HorizontalMenuContent-96da38e1.js +0 -1
- package/dist/ui/assets/InvoicesList-8e66a112.js +0 -1
- package/dist/ui/assets/LeadDetails-ad63b3df.js +0 -1
- package/dist/ui/assets/LeadsList-bd7d9804.js +0 -1
- package/dist/ui/assets/Logo-3f3c9ee6.js +0 -1
- package/dist/ui/assets/MapView-afd1c913.js +0 -1
- package/dist/ui/assets/MarketingPage-89a860b1.js +0 -4
- package/dist/ui/assets/MenuEdit-d6e0d64c.js +0 -1
- package/dist/ui/assets/MessageInput-6dc83761.js +0 -21
- package/dist/ui/assets/MessagesList-966b69c5.js +0 -1
- package/dist/ui/assets/ModernLayout-03f30574.js +0 -1
- package/dist/ui/assets/Notify-bb3ce372.js +0 -1
- package/dist/ui/assets/OpportunitiesList-62eb34f6.js +0 -1
- package/dist/ui/assets/OpportunityDetails-356a8580.js +0 -1
- package/dist/ui/assets/OpportunityStatus-fa8108ea.js +0 -1
- package/dist/ui/assets/PasswordInput-8619a9df.js +0 -1
- package/dist/ui/assets/Profile-9104808b.js +0 -1
- package/dist/ui/assets/RoleEdit-98a6410b.js +0 -1
- package/dist/ui/assets/RoleForm-cc251eba.js +0 -1
- package/dist/ui/assets/ScheduleCycle-22c8e809.js +0 -1
- package/dist/ui/assets/ScreenList-9f7afa1c.js +0 -1
- package/dist/ui/assets/SidePanelContent-6b13836f.js +0 -1
- package/dist/ui/assets/SimpleLayout-d5445c0d.js +0 -2
- package/dist/ui/assets/StackedSideLayout-51127dc5.js +0 -1
- package/dist/ui/assets/StickyFooter-5b934274.js +0 -1
- package/dist/ui/assets/SupportRequets-be6542a9.js +0 -1
- package/dist/ui/assets/TimeLogApprovalDataList-c16d8bae.js +0 -1
- package/dist/ui/assets/TimeLogApprovalList-f6a75a20.js +0 -1
- package/dist/ui/assets/TimeLogList-ea288cce.js +0 -1
- package/dist/ui/assets/TimesheetsList-4a20e96c.js +0 -1
- package/dist/ui/assets/TranslationList-7a989333.js +0 -1
- package/dist/ui/assets/UserEdit-87262ea5.js +0 -1
- package/dist/ui/assets/UserForm-31fdd3b3.js +0 -1
- package/dist/ui/assets/ViewTimeLogForApproval-43b24a1a.js +0 -1
- package/dist/ui/assets/Views-74429e81.js +0 -1
- package/dist/ui/assets/WelcomeList-6c693eae.js +0 -9
- package/dist/ui/assets/actioncell-17e12e21.js +0 -1
- package/dist/ui/assets/calendarList-511b4d8f.js +0 -2
- package/dist/ui/assets/createSvgIcon-c5fc0d04.js +0 -1
- package/dist/ui/assets/documentsList-ac2c91ec.js +0 -1
- package/dist/ui/assets/dxicons-4c1b2089.ttf +0 -0
- package/dist/ui/assets/dxicons-ade3c9ed.woff2 +0 -0
- package/dist/ui/assets/dxicons-b4cd1226.woff +0 -0
- package/dist/ui/assets/gridList-cb9a14b1.js +0 -1
- package/dist/ui/assets/gridMapTable-c19770a8.js +0 -1
- package/dist/ui/assets/index-1d60e514.js +0 -1
- package/dist/ui/assets/index-26466d9d.js +0 -1
- package/dist/ui/assets/index-289cfedb.js +0 -1
- package/dist/ui/assets/index-2ce5b358.js +0 -1
- package/dist/ui/assets/index-307ce6d7.js +0 -1
- package/dist/ui/assets/index-36ba4ea7.js +0 -1
- package/dist/ui/assets/index-3f02e05a.js +0 -1
- package/dist/ui/assets/index-44662933.js +0 -13
- package/dist/ui/assets/index-51ee35f9.js +0 -1
- package/dist/ui/assets/index-54372d82.js +0 -1
- package/dist/ui/assets/index-569a9d2c.js +0 -1
- package/dist/ui/assets/index-62de659f.js +0 -13
- package/dist/ui/assets/index-6589dd2d.js +0 -1
- package/dist/ui/assets/index-6b6d0f06.js +0 -1
- package/dist/ui/assets/index-6c618440.js +0 -1
- package/dist/ui/assets/index-785ad361.js +0 -1
- package/dist/ui/assets/index-7df8779c.js +0 -1
- package/dist/ui/assets/index-82c9477e.js +0 -1
- package/dist/ui/assets/index-8ab45286.js +0 -1
- package/dist/ui/assets/index-8c229076.css +0 -7
- package/dist/ui/assets/index-a205cfed.js +0 -34
- package/dist/ui/assets/index-a23f9c87.js +0 -1
- package/dist/ui/assets/index-a455424a.js +0 -1
- package/dist/ui/assets/index-a4f78ee1.js +0 -1
- package/dist/ui/assets/index-aaad94c2.js +0 -1
- package/dist/ui/assets/index-b1b6b0f6.js +0 -1
- package/dist/ui/assets/index-c1f92742.js +0 -4
- package/dist/ui/assets/index-c2088808.js +0 -1
- package/dist/ui/assets/index-cbc29fa8.js +0 -1
- package/dist/ui/assets/index-cd2b7d32.js +0 -1
- package/dist/ui/assets/index-cf3804f1.js +0 -19
- package/dist/ui/assets/index-d0ef2cc2.js +0 -1
- package/dist/ui/assets/index-d1145737.js +0 -7
- package/dist/ui/assets/index-d58fb185.js +0 -1
- package/dist/ui/assets/index-d5b5a7e1.js +0 -1
- package/dist/ui/assets/index-daeff047.js +0 -1
- package/dist/ui/assets/index-ded3b055.js +0 -1
- package/dist/ui/assets/index-ede23a2b.js +0 -1
- package/dist/ui/assets/index-f8144346.js +0 -1
- package/dist/ui/assets/index-fd68b510.js +0 -1
- package/dist/ui/assets/index-fe3409ae.js +0 -1
- package/dist/ui/assets/liveLocation-646eef95.js +0 -1
- package/dist/ui/assets/modeuls-setup-402f891e.js +0 -1
- package/dist/ui/assets/tableV3-3d2f4952.js +0 -1
- package/dist/ui/assets/ticketRequestDetails-f78147f7.js +0 -1
- package/dist/ui/assets/vendor-mui-69397583.js +0 -185
- package/dist/ui/menudata/menus.json +0 -606
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./vendor-mui-69397583.js";import{A as r}from"./AdaptableCard-df7695d6.js";import{f as j,r as n}from"./vendor-react-ece1c85f.js";import{T as x}from"./index-36228db5.js";import{I as l,W as t,cJ as f,B as i,V as h,cZ as v,bJ as b,bh as N,aU as w}from"./index-c62ac197.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import"./index-c2088808.js";import{D as g}from"./Drawer-949c18c6.js";import"./FormContainer-91c2b0e4.js";import"./Switcher-c8648037.js";import"./Upload-fb34ce03.js";import"./useControllableState-d0909575.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";import"./useDidUpdate-25c4d4ed.js";const y=s=>{j(),n.useState(!1);const a=[{value:"ocean",label:"Ocean",color:"#00B8D9"},{value:"blue",label:"Blue",color:"#0052CC"},{value:"purple",label:"Purple",color:"#5243AA"},{value:"red",label:"Red",color:"#FF5630"},{value:"orange",label:"Orange",color:"#FF8B00"},{value:"yellow",label:"Yellow",color:"#FFC400"},{value:"green",label:"Green",color:"#36B37E"},{value:"forest",label:"Forest",color:"#00875A"},{value:"slate",label:"Slate",color:"#253858"},{value:"silver",label:"Silver",color:"#666666"}];return e.jsx(e.Fragment,{children:e.jsxs("div",{children:[e.jsxs("div",{className:"pb-2",children:[e.jsx("div",{className:"font-bold",children:"Account Name"}),e.jsx(l,{placeholder:""})]}),e.jsxs("div",{className:"pb-2",children:[e.jsx("div",{className:"font-bold",children:"Parent Account"}),e.jsx(t,{placeholder:"Please Select",options:a})]}),e.jsxs("div",{className:"pb-2",children:[e.jsx("div",{className:"font-bold",children:"Address"}),e.jsx(l,{placeholder:"",textArea:!0})]}),e.jsxs("div",{className:"lg:flex md:flex-none sm:flex-none pb-2",children:[e.jsxs("div",{className:"lg:w-1/3 md:w-full sm:w-full pr-4",children:[e.jsx("div",{className:"font-bold",children:"City"}),e.jsx(l,{placeholder:""})]}),e.jsxs("div",{className:"lg:w-1/3 md:w-full sm:w-full pr-4",children:[e.jsx("div",{className:"font-bold",children:"State"}),e.jsx(t,{placeholder:"Please Select",options:a})]}),e.jsxs("div",{className:"lg:w-1/3 md:w-full sm:w-full",children:[e.jsx("div",{className:"font-bold",children:"Zipcode"}),e.jsx(l,{placeholder:""})]})]}),e.jsxs("div",{className:"pb-2",children:[e.jsx("div",{className:"font-bold",children:"Primary Contact"}),e.jsx(l,{placeholder:""})]}),e.jsxs("div",{className:"pb-2",children:[e.jsx("div",{className:"font-bold",children:"Billing Contact"}),e.jsx(t,{placeholder:"Please Select",options:a})]}),e.jsxs("div",{className:"pb-2",children:[e.jsx("div",{className:"font-bold",children:"Notes"}),e.jsx(l,{placeholder:"",textArea:!0})]})]})})},q=()=>{const{TabNav:s,TabList:a,TabContent:c}=x;n.useState(!1),n.useState(!1);const[u,d]=n.useState(!1),m=()=>{d(!0)},o=C=>{d(!1)},p=e.jsxs("div",{className:"md:flex items-center justify-between w-full",children:[e.jsx(i,{size:"sm",className:"mr-2",onClick:()=>o(),children:"Cancel"}),e.jsx(i,{size:"sm",className:"mr-2",children:"Create and Add Another"}),e.jsx(i,{size:"sm",variant:"solid",onClick:()=>o(),children:"Add Account"})]});return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"topbar py-4 px-6 border-gray-200 border-b",children:e.jsxs("div",{className:"lg:flex items-center justify-between",children:[e.jsx("h3",{className:"mb-4 lg:mb-0",children:"Invoices"}),e.jsxs("div",{className:"flex flex-col lg:flex-row lg:items-center",children:[e.jsx(l,{size:"sm",className:"mr-2",placeholder:"Search",prefix:e.jsx(f,{className:"text-lg"})}),e.jsx(i,{onClick:()=>m(),block:!0,variant:"solid",size:"sm",icon:e.jsx(h,{}),children:"Add Invoice"}),e.jsx(g,{title:"Add Invoice",isOpen:u,onClose:o,onRequestClose:o,portalClassName:"w30",footer:p,children:e.jsx(y,{})})]})]})}),e.jsx(r,{className:"m-6 h-full py-4 px-6 bg-transparent",bodyClass:"h-full",children:e.jsxs(x,{className:"billing-tabs h-full",defaultValue:"all",variant:"pill",children:[e.jsxs(a,{children:[e.jsx(s,{icon:e.jsx(v,{}),value:"all",children:"All Invoices"}),e.jsx(s,{icon:e.jsx(b,{}),value:"overdue",children:"Overdue"}),e.jsx(s,{icon:e.jsx(N,{}),value:"upcoming",children:"Upcoming"}),e.jsx(s,{icon:e.jsx(w,{}),value:"paid",children:"Paid"})]}),e.jsxs("div",{className:"py-4 h-full",children:[e.jsx(c,{value:"all",children:e.jsxs(r,{className:"invoices h-full py-4 px-6",bodyClass:"h-full",children:[e.jsx("div",{className:"lg:flex md:flex-none sm:flex-none py-20 px-20",children:e.jsxs("div",{className:"lg:w-full md:w-full sm:w-full text-center",children:[e.jsx("h3",{children:"Professional Invoicing"}),e.jsx("h5",{children:`It's more than just saying "Pay me"`}),e.jsx("div",{className:"py-8",children:e.jsxs("p",{children:["The care and detail you put into invoicing can do wonders for your brand and future business.",e.jsx("br",{}),"Take these steps below to show customers the best you have to offer."]})})]})}),e.jsxs("div",{className:"lg:flex md:flex-none sm:flex-none py-20 w-3/6 container mx-auto",children:[e.jsxs("div",{className:"lg:w-1/3 md:w-full sm:w-full text-center px-4",children:[e.jsx("div",{className:"circle",children:"01"}),e.jsx("h4",{className:"my-2",children:"Create and Invoice"}),e.jsx("p",{className:"text-xs",children:"Enter your customers email, add services with amount and you are ready to send."})]}),e.jsxs("div",{className:"lg:w-1/3 md:w-full sm:w-full text-center px-4 border-l-2 border-r-2",children:[e.jsx("div",{className:"circle",children:"02"}),e.jsx("h4",{className:"my-2",children:"Send in Seconds"}),e.jsx("p",{className:"text-xs",children:"Share the invoice over email with a click."})]}),e.jsxs("div",{className:"lg:w-1/3 md:w-full sm:w-full text-center px-4 ",children:[e.jsx("div",{className:"circle",children:"03"}),e.jsx("h4",{className:"my-2",children:"Record the Payment"}),e.jsx("p",{className:"text-xs",children:"Record payments made with ease and keep a track of the due and paid amounts."})]})]}),e.jsx("div",{className:"container text-center mx-auto py-20",children:e.jsx(i,{onClick:()=>m(),variant:"solid",size:"sm",icon:e.jsx(h,{}),children:"Create Invoice"})})]})}),e.jsx(c,{value:"overdue",children:e.jsx(r,{className:"h-full py-4 px-6",bodyClass:"h-full",children:e.jsx("p",{children:"If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization. (Gerald Weinberg)"})})}),e.jsx(c,{value:"upcoming",children:e.jsx(r,{className:"h-full py-4 px-6",bodyClass:"h-full",children:e.jsx("p",{children:"If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization. (Gerald Weinberg)"})})}),e.jsx(c,{value:"paid",children:e.jsx(r,{className:"h-full py-4 px-6",bodyClass:"h-full",children:e.jsx("p",{children:"If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization. (Gerald Weinberg)"})})})]})]})})]})};export{q as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{w as P,x as re,y as M,j as e,z as oe,B as le,C as ce,D as de}from"./vendor-mui-69397583.js";import{Y as X,l as D,I as E,Z as L,W as A,B as I,O as v,Q as S,ag as pe,bh as me}from"./index-c62ac197.js";import{r as y,j as ue}from"./vendor-react-ece1c85f.js";import{i as fe,j as q,u as z,k as he,l as R,d as V,r as xe}from"./index-9b41371d.js";import{A as C}from"./AdaptableCard-df7695d6.js";import{d as je}from"./Check-71f21a49.js";import{P as ge}from"./permissionHoc-6f787658.js";import{C as F}from"./CustomerInfoField-fff65ace.js";import{T as Y}from"./index-36228db5.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import{a as ye,T as Q}from"./index-c2088808.js";import{D as O}from"./Drawer-949c18c6.js";import{a as N,F as ee}from"./FormContainer-91c2b0e4.js";import{S as ve}from"./Switcher-c8648037.js";import"./Upload-fb34ce03.js";import{h as te}from"./index-36ba4ea7.js";import{S as se}from"./StickyFooter-5b934274.js";import{d as w,c as $,a as T,i as Se,F as ae,b as ie}from"./index.esm-70ab539c.js";import{r as be,u as Ne,g as we}from"./index-0ec72c4b.js";import{a as ne}from"./index-e4c6057f.js";import{b as Te}from"./ScheduleService-7228f0a3.js";import Ce from"./OpportunitiesList-62eb34f6.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";import"./LeadSourceService-e46fa85e.js";import"./ContactService-92281a90.js";import"./createSvgIcon-c5fc0d04.js";import"./useControllableState-d0909575.js";import"./useDidUpdate-25c4d4ed.js";import"./index-dc103f22.js";import"./OpportunityServices-fa4fabfd.js";import"./actioncell-17e12e21.js";import"./EditLead-cc38d2a2.js";import"./DoubleSidedImage-ae98733b.js";import"./ConfirmDialog-3202eb3d.js";import"./AddAccount-a05910e8.js";import"./index-cebd880b.js";import"./AccountServices-62599aae.js";import"./index-49a94e54.js";import"./DepartmentServices-3d56a9e7.js";import"./validationPatterns-77446c46.js";import"./CourseService-f0dc3bf1.js";import"./ApiService-2b99757f.js";import"./index-6589dd2d.js";import"./UserService-047aef51.js";import"./tableV3-3d2f4952.js";import"./FileSaver.min-20f3f13a.js";import"./mapView-ab35acaa.js";import"./esm-f306d015.js";import"./lodash-306e3f66.js";import"./DensitySelector-a2c1c68f.js";import"./NoData-8c485a3a.js";import"./usePermission-d94b4984.js";import"./WrapperCell-a7981b07.js";const Le=P(re)(({theme:s})=>({[`&.${M.alternativeLabel}`]:{top:10,left:"calc(-50% + 16px)",right:"calc(50% + 16px)"},[`&.${M.active}`]:{[`& .${M.line}`]:{borderColor:"var(--custom-600)"}},[`&.${M.completed}`]:{[`& .${M.line}`]:{borderColor:"var(--custom-600)"}},[`& .${M.line}`]:{borderColor:"#eaeaf0",borderTopWidth:3,borderRadius:1,...s.applyStyles("dark",{borderColor:s.palette.grey[800]})}})),ke=P("div")(({theme:s})=>({color:"#eaeaf0",display:"flex",height:22,alignItems:"center","& .QontoStepIcon-completedIcon":{color:"var(--custom-600)",zIndex:1,fontSize:18},"& .QontoStepIcon-circle":{width:8,height:8,borderRadius:"50%",color:"var(--custom-600)",backgroundColor:"var(--custom-600)"},...s.applyStyles("dark",{color:s.palette.grey[700]}),variants:[{props:({ownerState:a})=>a.active,style:{color:"var(--custom-600)"}}]}));function Me(s){const{active:a,completed:n,className:c}=s;return e.jsx(ke,{ownerState:{active:a},className:c,children:n?e.jsx(je,{className:"QontoStepIcon-completedIcon"}):e.jsx("div",{className:"QontoStepIcon-circle"})})}P("div")(({theme:s})=>({backgroundColor:"#ccc",zIndex:1,color:"#fff",width:50,height:50,display:"flex",borderRadius:"50%",justifyContent:"center",alignItems:"center",...s.applyStyles("dark",{backgroundColor:s.palette.grey[700]}),variants:[{props:({ownerState:a})=>a.active,style:{backgroundImage:"linear-gradient( 136deg, rgb(242,113,33) 0%, rgb(233,64,87) 50%, rgb(138,35,135) 100%)",boxShadow:"0 4px 10px 0 rgba(0,0,0,.25)"}},{props:({ownerState:a})=>a.completed,style:{backgroundImage:"linear-gradient( 136deg, rgb(242,113,33) 0%, rgb(233,64,87) 50%, rgb(138,35,135) 100%)"}}]}));const Ie=["Contact","Meeting","Outcome"];function De(s){return e.jsx(oe,{sx:{width:"100%"},spacing:4,children:e.jsx(le,{alternativeLabel:!0,activeStep:s.activeStep,connector:e.jsx(Le,{}),children:Ie.map(a=>e.jsx(ce,{children:e.jsx(de,{StepIconComponent:Me,children:a})},a))})})}X("calendar",be);const Fe=s=>{const a=D(),{allContacts:n}=Ne(l=>l.calendar.data),{touched:c,errors:r,type:j}=s,t=[{value:"4ae1cc43-1c19-474a-ac0c-3f8653bf5c2c",label:"Lead"}];return y.useEffect(()=>{a(we({}))},[]),e.jsxs(C,{className:"mb-4",children:[e.jsx(N,{asterisk:!0,label:"Event Name",invalid:r.eventName&&c.eventName,errorMessage:r.eventName,children:e.jsx(w,{type:"text",autoComplete:"off",name:"eventName",placeholder:"Event Name",component:E})}),e.jsx(N,{asterisk:!0,label:"Event Date",invalid:r.eventDate&&c.eventDate,errorMessage:r.eventDate,children:e.jsx(w,{name:"eventDate",children:({field:l,form:o})=>{var p,i;return e.jsx(e.Fragment,{children:e.jsx(ye,{name:"eventDate",placeholder:"Event Date",field:l,value:(p=o==null?void 0:o.values)!=null&&p.eventDate?new Date((i=o==null?void 0:o.values)==null?void 0:i.eventDate):void 0,onChange:f=>{f&&o.setFieldValue("eventDate",f)}})})}})}),e.jsx(N,{asterisk:!0,label:"From Time",invalid:r.fromTime&&c.fromTime,errorMessage:r.fromTime,children:e.jsx(w,{name:"fromTime",placeholder:"fromTime",children:({field:l,form:o})=>e.jsx(Q,{name:"fromTime",id:"fromTime",field:l,format:"12",defaultValue:o.values.fromTime?new Date(o.values.fromTime):void 0,clearable:!1,onChange:p=>{const i=L(p).format("HH:mm:ss");o.setFieldValue("fromTime",i)}})})}),e.jsx(N,{asterisk:!0,label:"To Time",invalid:r.toTime&&c.toTime,errorMessage:r.toTime,children:e.jsx(w,{name:"toTime",placeholder:"toTime",children:({field:l,form:o})=>e.jsx(Q,{name:"toTime",id:"toTime",field:l,format:"12",defaultValue:o.values.toTime?new Date(o.values.toTime):void 0,clearable:!1,onChange:p=>{const i=L(p).format("HH:mm:ss");console.log("toTime",p,"formattedTime",i),o.setFieldValue("toTime",i)}})})}),e.jsx(N,{asterisk:!0,label:"Invite Contact(s)",invalid:!!(r.participants&&c.participants),errorMessage:r.participants,children:e.jsx(w,{name:"participants",children:({field:l,form:o})=>{var f,h;const p=((h=(f=o==null?void 0:o.values)==null?void 0:f.participants)==null?void 0:h.map(g=>({label:g.email,value:g.participantId,email:g.email,participantId:g.participantId})))||[],i=n.map(g=>({label:g.email,value:g.id,email:g.email,id:g.id}));return e.jsx(A,{isMulti:!0,className:"rounded-md",options:i,value:p,onChange:g=>o.setFieldValue("participants",g.map(u=>({email:u.email,participantId:u.value})))})}})}),e.jsx(N,{asterisk:!0,label:"Type",invalid:r.eventType&&c.eventType,errorMessage:r.eventType,children:e.jsx(w,{name:"eventType",children:({field:l,form:o})=>e.jsx(A,{field:l,form:o,options:t,name:"eventType",onChange:p=>{o.setFieldValue(l.name,p)}})})}),e.jsx(N,{asterisk:!0,label:"Link",invalid:r.link&&c.link,errorMessage:r.link,children:e.jsx(w,{type:"text",autoComplete:"off",name:"link",placeholder:"Link",component:E})}),e.jsx(N,{label:"Notes",invalid:r.notes&&c.notes,errorMessage:r.notes,children:e.jsx(w,{textArea:!0,type:"text",autoComplete:"off",name:"notes",placeholder:"Notes",component:E})}),e.jsx(N,{label:"SendNotification",invalid:r.sendNotification&&c.sendNotification,errorMessage:r.sendNotification,children:e.jsx("div",{children:e.jsx(w,{name:"sendNotification",component:ve})})})]})},{useUniqueId:$e}=te,W=$().shape({eventName:T().required("Event name Required"),eventDate:T().required("Event date Required"),fromTime:T().required("From time Required"),toTime:T().required("Totime Required"),participants:Se().of($()).min(1,"At least one participant is required").required("Participants Required"),eventType:$().required("Event type Required"),link:T().required("Link Required"),notes:T()}),H=y.forwardRef((s,a)=>{const{type:n,footerWidth:c,initialData:r={id:"",eventName:"",eventDate:null,fromTime:null,toTime:null,participants:[],eventType:"",link:"",notes:"",sendNotification:!1},onFormSubmit:j,onDiscard:t,onDelete:l}=s,o=$e("LeadMeeting-");return e.jsx(e.Fragment,{children:e.jsx(ae,{innerRef:a,initialValues:{...r},validationSchema:W,onSubmit:(p,{setSubmitting:i})=>{const f=p;n==="new"&&(f.id=o),j==null||j(f,i)},children:({values:p,touched:i,errors:f,isSubmitting:h})=>e.jsx(ie,{children:e.jsxs(ee,{children:[e.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-1 gap-4",children:e.jsx("div",{className:"lg:col-span-2 pb-8",children:e.jsx(Fe,{type:n,touched:i,errors:f})})}),e.jsx(se,{className:`px-8 flex items-center justify-between py-4 ${c}`,stickyClass:"bg-white dark:bg-gray-800 border-gray-200 dark:border-gray-700",children:e.jsxs("div",{className:"md:flex items-center justify-between w-full",children:[e.jsx(I,{size:"sm",className:"ltr:mr-3 rtl:ml-3",type:"button",onClick:()=>t==null?void 0:t(),children:"Discard"}),e.jsx(I,{size:"sm",variant:"solid",loading:h,icon:e.jsx(ne,{}),type:"submit",children:"Save"})]})})]})})})})});H.displayName="LeadMeetingForm";function B(s){const a=String(s).trim();return/^\d+$/.test(a)?`${parseInt(a,10).toString().padStart(2,"0")}:00:00`:/^\d{2}:\d{2}:\d{2}$/.test(a)?a:" "}const Ee=s=>{const{onDrawerClose:a,leadId:n,footerWidth:c}=s,r=D(),j=()=>{r(q({id:n}))},t=async(l,o)=>{var i,f,h,g;o(!0);const p={eventName:l.eventName??"",eventDate:L(l.eventDate).format("YYYY-MM-DD"),endDate:L(l.eventDate).format("YYYY-MM-DD"),fromTime:B(l.fromTime??""),toTime:B(l.toTime??""),participants:l.participants??"",participantIds:(i=l==null?void 0:l.participants)==null?void 0:i.map(u=>u.participantId??u.id),eventCategoryId:((f=l.eventType)==null?void 0:f.value)??"",link:l.link??"",notes:l.notes??"",sendNotification:l.sendNotification??"",entityId:n};try{(await fe(p)).success&&(v.push(e.jsx(S,{title:"Success",type:"success",duration:2500,children:"Lead meeting Successfully Added"}),{placement:"top-center"}),j(),a())}catch(u){o(!1),v.push(e.jsx(S,{title:"Error",type:"danger",duration:2500,children:(g=(h=u==null?void 0:u.response)==null?void 0:h.data)==null?void 0:g.message}),{placement:"top-center"})}};return e.jsx(H,{type:"new",footerWidth:c,onFormSubmit:t,onDiscard:a})},Z=s=>{if(!s)return"";if(s.includes("T")){const n=s.split("T")[1];return J(n)}const a=new Date(s);if(!isNaN(a.getTime())){const n=a.getHours().toString().padStart(2,"0"),c=a.getMinutes().toString().padStart(2,"0"),r=a.getSeconds().toString().padStart(2,"0");return`${n}:${c}:${r}`}return J(s)},J=s=>{if(!s)return"00:00:00";if(/^\d{2}:\d{2}:\d{2}$/.test(s))return s;const a=s.replace(/\D/g,"");return a.length===1||a.length===2?a.padStart(2,"0")+":00:00":a.length===3?a.slice(-2).padStart(2,"0")+":00:00":a.length===4?a.slice(0,2)+":"+a.slice(2,4)+":00":a.length===6?a.slice(0,2)+":"+a.slice(2,4)+":"+a.slice(4,6):"00:00:00"};function Oe(s){const[a,n]=s.split(":").map(Number),c=a>=12?"PM":"AM",r=a%12||12,j=String(r).padStart(2,"0"),t=String(n).padStart(2,"0");return`${j}:${t} ${c}`}function _(s,a="Asia/Kolkata"){var c,r;return`${L((c=s==null?void 0:s.split("T"))==null?void 0:c[0]).format("MMM DD, YYYY")}, ${Oe((r=s==null?void 0:s.split("T"))==null?void 0:r[1])}`}const qe=({leadId:s,meetingId:a,onDrawerClose:n,footerWidth:c})=>{const r=D(),j=z(i=>{var f,h;return(h=(f=i.LeadsData)==null?void 0:f.data)==null?void 0:h.leadMeetingList}),[t,l]=y.useState(null);y.useEffect(()=>{var f;const i=j==null?void 0:j.find(h=>h.id===a);i?l({id:(i==null?void 0:i.id)||"",eventName:i.eventName??"",eventDate:i.eventDate,fromTime:_(`${i.startDateTime}Z`),toTime:_(`${i.endDateTime}Z`),participants:((f=i==null?void 0:i.participants)==null?void 0:f.map(h=>({email:h==null?void 0:h.email,participantId:h==null?void 0:h.participantId})))??[],eventType:{label:"Lead",value:i.eventType},link:i.link,notes:i.notes,sendNotification:i.sendNotification??!1}):(v.push(e.jsx(S,{title:"Error",type:"danger",duration:2500,children:"Meeting not found in state"}),{placement:"top-center"}),n())},[a]);const o=async(i,f)=>{var g,u,m,d;f(!0);const h={id:i.id,eventName:i.eventName??"",eventDate:L(i.eventDate).format("YYYY-MM-DD")??"",fromTime:Z(i.fromTime)??"",toTime:Z(i.toTime)??"",participants:i.participants??"",participantIds:(g=i==null?void 0:i.participants)==null?void 0:g.map(x=>x.participantId),eventType:((u=i.eventType)==null?void 0:u.value)??"",link:i.link??"",notes:i.notes??"",sendNotification:i.sendNotification??"",entityId:s};try{(await Te(h.id,h)).success&&(v.push(e.jsx(S,{title:"Success",type:"success",duration:2500,children:"Lead meeting successfully updated"}),{placement:"top-center"}),r(q({id:s})),n())}catch(x){const b=((d=(m=x.response)==null?void 0:m.data)==null?void 0:d.message)||"Something went wrong";v.push(e.jsx(S,{title:"Error",type:"danger",duration:2500,children:b}),{placement:"top-center"})}finally{f(!1)}},p=()=>n();return t?e.jsx(H,{type:"edit",initialData:t,footerWidth:c,onFormSubmit:o,onDiscard:p}):e.jsx("div",{className:"p-4",children:"Loading..."})},Ae=s=>{D();const{touched:a,errors:n,type:c}=s,r=[{value:2,label:"Qualified"},{value:3,label:"UnQualified"}];return e.jsxs(C,{className:"mb-4",children:[e.jsx(N,{asterisk:!0,label:"Lead Status",invalid:n.leadStatus&&a.leadStatus,errorMessage:n.leadStatus,children:e.jsx(w,{name:"leadStatus",children:({field:j,form:t})=>e.jsx(A,{field:j,form:t,options:r,name:"leadStatus",onChange:l=>{t.setFieldValue(j.name,l)}})})}),e.jsx(N,{label:"Notes",invalid:n.notes&&a.notes,errorMessage:n.notes,children:e.jsx(w,{type:"text",autoComplete:"off",name:"notes",placeholder:"Notes",component:E,textArea:!0})})]})},{useUniqueId:Re}=te,Ye=$().shape({leadStatus:$().required("Status Required"),notes:T()}),U=y.forwardRef((s,a)=>{const{type:n,footerWidth:c,initialData:r={id:"",leadStatus:"",notes:""},onFormSubmit:j,onDiscard:t}=s,l=Re("LeadStatus-");return e.jsx(ae,{innerRef:a,initialValues:{...r},validationSchema:Ye,onSubmit:(o,{setSubmitting:p})=>{const i={...o};n==="new"&&(i.id=l),j==null||j(i,p)},children:({touched:o,errors:p,isSubmitting:i})=>e.jsx(ie,{children:e.jsxs(ee,{children:[e.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-1 gap-4",children:e.jsx("div",{className:"lg:col-span-2 pb-8",children:e.jsx(Ae,{type:n,touched:o,errors:p})})}),e.jsx(se,{className:`px-8 flex items-center justify-between py-4 ${c}`,stickyClass:"bg-white dark:bg-gray-800 border-gray-200 dark:border-gray-700",children:e.jsxs("div",{className:"md:flex items-center justify-between w-full",children:[e.jsx(I,{size:"sm",className:"ltr:mr-3 rtl:ml-3",type:"button",onClick:()=>t==null?void 0:t(),children:"Discard"}),e.jsx(I,{size:"sm",variant:"solid",loading:i,icon:e.jsx(ne,{}),type:"submit",children:"Save"})]})})]})})})});U.displayName="LeadStatusForm";const Pe=({leadId:s})=>{var g;const a=D(),n=z(u=>{var m,d;return(d=(m=u.LeadsData)==null?void 0:m.data)==null?void 0:d.leadMeetingList}),[c,r]=y.useState(!1),[j,t]=y.useState(!1),[l,o]=y.useState(!1),p=()=>{a(q({id:s}))},i=()=>{var d;const u=(d=n==null?void 0:n[0])==null?void 0:d.link;if(!u)return;const m=window.open(u,"_blank","noopener,noreferrer");m&&(m.opener=null)},f=async()=>{var u,m;try{(await he(n[0].id)).success&&(v.push(e.jsx(S,{title:"Success",type:"success",children:"Meeting cancelled successfully"}),{placement:"top-center"}),p())}catch(d){v.push(e.jsx(S,{title:"Error",type:"danger",children:(m=(u=d.response)==null?void 0:u.data)==null?void 0:m.message}),{placement:"top-center"})}},h=async u=>{var m,d,x;try{const b={LeadStatus:(m=u.leadStatus)==null?void 0:m.value,Notes:u.notes??""};(await R(s,b)).success&&(v.push(e.jsx(S,{title:"Success",type:"success",children:"Lead status successfully updated"}),{placement:"top-center"}),o(!1))}catch(b){v.push(e.jsx(S,{title:"Error",type:"danger",children:(x=(d=b.response)==null?void 0:d.data)==null?void 0:x.message}),{placement:"top-center"})}};return e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex flex-col sm:flex-row justify-between mt-5 gap-4",children:[e.jsxs("div",{children:[e.jsx("h3",{children:"Upcoming Meetings"}),(n==null?void 0:n.length)===0&&e.jsx("p",{children:"No meetings have been scheduled at this time. Please establish contact with the client to arrange a suitable appointment"})]}),(n==null?void 0:n.length)===0&&e.jsx(I,{variant:"solid",onClick:()=>r(!0),children:"Schedule a Meeting"})]}),e.jsx(O,{title:"Schedule a Meeting",isOpen:c,onClose:()=>r(!1),portalClassName:"w30",children:e.jsx(Ee,{footerWidth:"w30",leadId:s,onDrawerClose:()=>{r(!1),p()}})}),e.jsx(O,{title:"Edit Meeting",isOpen:j,onClose:()=>t(!1),portalClassName:"w30",children:e.jsx(qe,{footerWidth:"w30",leadId:s,meetingId:(g=n==null?void 0:n[0])==null?void 0:g.id,onDrawerClose:()=>{t(!1),p()}})}),e.jsx(O,{title:"Lead Status",isOpen:l,onClose:()=>o(!1),portalClassName:"w30",children:e.jsx(U,{footerWidth:"w30",type:"new",onFormSubmit:h,onDiscard:()=>o(!1)})}),(n==null?void 0:n.length)>0&&e.jsxs("div",{className:"flex flex-col sm:flex-row justify-between mt-5 px-5 gap-4",children:[e.jsxs("div",{children:[e.jsx("h4",{children:n[0].eventName}),e.jsxs("p",{children:[L(n[0].eventDate).format("D MMM")," | ",n[0].fromTime," - ",n[0].toTime]})]}),e.jsxs("div",{className:"flex gap-4",children:[e.jsx("a",{className:"font-bold text-primary cursor-pointer",onClick:i,children:"Join"}),e.jsx("a",{className:"cursor-pointer",onClick:()=>t(!0),children:"Edit Meeting"}),e.jsx("a",{className:"cursor-pointer",onClick:f,children:"Cancel Meeting"})]})]})]})},ze=({leadId:s,leadData:a})=>e.jsx("div",{children:e.jsx(Ce,{leadId:s,accountId:null,leadData:a})}),{TabNav:K,TabList:He,TabContent:G}=Y,Ue=({currentTab:s,setCurrentTab:a,leadId:n,leadData:c})=>e.jsxs(Y,{className:"opportunity-tabs",variant:"pill",value:s,onChange:a,children:[e.jsx(Y,{className:"opportunity-tabs",variant:"pill",value:s,onChange:a,children:e.jsx(C,{className:"p-2 my-2",children:e.jsxs(He,{className:"flex flex-col sm:flex-row flex-wrap gap-2",children:[e.jsx(K,{icon:e.jsx(pe,{}),className:"w-full sm:w-auto text-center",value:"Opportunities",children:" Opportunity "}),e.jsx(K,{icon:e.jsx(me,{}),className:"w-full sm:w-auto text-center",value:"Meetings",children:" Meeting "})]})})}),e.jsx(C,{className:"my-2",children:e.jsxs("div",{className:"p-3",children:[e.jsx(G,{value:"Meetings",children:e.jsx(Pe,{leadId:n})}),e.jsx(G,{value:"Opportunities",children:e.jsx(ze,{leadId:n,leadData:c})})]})})]});X("LeadsData",xe);const Ve=()=>{var u;const{id:s}=ue(),a=D(),[n,c]=y.useState(!1),[r,j]=y.useState(0);y.useEffect(()=>{if(s){const m={id:s};a(V(m)),a(q(m))}},[s]);const t=z(m=>{var d,x;return(x=(d=m.LeadsData)==null?void 0:d.data)==null?void 0:x.lead});y.useEffect(()=>{t&&j(t.leadStatusId===1||t.leadStatusId===6?0:t.leadStatusId===5?1:2)},[t]);const l=()=>{a(V({id:s}))},o=async m=>await R(s,m),p=()=>{r===0?o({LeadStatus:5,Notes:""}).then(d=>{d.success&&(v.push(e.jsx(S,{title:"Success",type:"success",duration:2500,children:"Lead status successfully updated"}),{placement:"top-center"}),l())}).catch(d=>{var x,b;v.push(e.jsx(S,{title:"Error",type:"danger",duration:2500,children:(b=(x=d==null?void 0:d.response)==null?void 0:x.data)==null?void 0:b.message}),{placement:"top-center"})}):c(!0)},i=async m=>{var d,x,b;try{const k={LeadStatus:(d=m.leadStatus)==null?void 0:d.value,Notes:m.notes??""};(await R(s,k)).success&&(v.push(e.jsx(S,{title:"Success",type:"success",duration:2500,children:"Lead status successfully updated"}),{placement:"top-center"}),c(!1),l())}catch(k){v.push(e.jsx(S,{title:"Error",type:"danger",duration:2500,children:(b=(x=k==null?void 0:k.response)==null?void 0:x.data)==null?void 0:b.message}),{placement:"top-center"})}},[f,h]=y.useState("Opportunities"),g=m=>{const d=m.length;let x=m;return d>0&&(x="("+x),d>3&&(x=x.slice(0,4)+") "+x.slice(4,11)),d>6&&(x=x.slice(0,9)+"-"+x.slice(9)),x};return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"topbar py-4 px-6 border-gray-200 border-b",children:e.jsx("div",{className:"lg:flex items-center justify-between",children:e.jsx("h3",{className:"mb-4 lg:mb-0",children:" Lead Details "})})}),e.jsx(C,{className:"m-6 py-4 px-6 bg-transparent",bodyClass:"h-full",children:e.jsxs(C,{className:"borderless",children:[e.jsxs("div",{className:"flex flex-col md:flex-row md:justify-between pb-4 border-b border-gray-200",children:[e.jsx("div",{className:"w-full flex md:flex-1 pt-4 justify-center md:justify-start md:space-between",children:e.jsxs("div",{className:"flex flex-col md:flex-row gap-4 text-center md:text-left w-full md:gap-8",children:[e.jsxs("div",{className:"w-full md:w-1/2",children:[e.jsxs("p",{children:[e.jsx("strong",{children:"Owner:"})," ",t==null?void 0:t.leadName]}),e.jsxs("p",{children:[e.jsx("strong",{children:"Source:"})," ",t==null?void 0:t.leadSource]})]}),e.jsxs("div",{className:"w-full md:w-1/2",children:[e.jsxs("p",{children:[e.jsx("strong",{children:"Company:"})," ",t==null?void 0:t.accountName]}),e.jsxs("p",{children:[e.jsx("strong",{children:"Designation:"})," ",(u=t==null?void 0:t.contactPosistion)==null?void 0:u.positionName]})]})]})}),e.jsx("div",{className:"w-full md:flex-1 mt-5 md:mt-0 flex justify-center md:justify-between",children:e.jsx("div",{className:"w-[400px] md:w-full",children:e.jsxs("div",{className:"flex flex-col sm:flex-row justify-between mt-5 gap-4",children:[e.jsx(De,{activeStep:r}),e.jsx(I,{variant:"solid",size:"md",onClick:p,children:r===0?e.jsx("span",{children:"Mark Status Complete"}):e.jsx("span",{children:"Update Status"})})]})})})]}),e.jsx("div",{className:"flex justify-center lg:justify-start",children:e.jsx("div",{className:"flex pt-4 pb-2 flex-col lg:flex-row items-center lg:items-start gap-8 w-full lg:w-auto",children:e.jsxs("div",{className:"flex flex-col sm:flex-row sm:flex-wrap gap-4 sm:gap-8 justify-center",children:[e.jsx(F,{title:"Email",value:(t==null?void 0:t.contactEmail)||"--"}),e.jsx(F,{title:"Phone",value:t!=null&&t.contactNumber?g(t==null?void 0:t.contactNumber):"--"}),e.jsx(F,{title:"Address",value:`${(t==null?void 0:t.address)||""}, ${(t==null?void 0:t.state)||""}, ${(t==null?void 0:t.city)||""}, ${(t==null?void 0:t.zip)||""}`}),e.jsx(F,{title:"Industry",value:(t==null?void 0:t.industry)||"--"}),e.jsx(F,{title:"No. Of Employees",value:(t==null?void 0:t.noOfEmployees)||"--"})]})})})]})}),e.jsx(C,{className:"mt-0 ml-6 mr-6 mb-6 p-4 bg-transparent",bodyClass:"h-full",children:e.jsx(Ue,{currentTab:f,setCurrentTab:h,leadId:s,leadData:t})}),e.jsx(O,{title:"Lead Status",isOpen:n,onClose:()=>c(!1),portalClassName:"w30",children:e.jsx(U,{footerWidth:"w30",type:"new",onFormSubmit:i,onDiscard:()=>c(!1)})})]})},Kt=ge(Ve,"Leads");export{Kt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e,l as be}from"./vendor-mui-69397583.js";import{A as ne}from"./AdaptableCard-df7695d6.js";import{r as d,f as ve,L as Ce}from"./vendor-react-ece1c85f.js";import{u as r,t as q,f as Le,a as re,b as Se,g as Ne,s as I,r as we,h as ce}from"./index-9b41371d.js";import{l as Q,cC as Ie,O as Fe,Q as De,W as z,B as A,Y as U,f as ke,V as Ae,n as N,a5 as w,cD as ye,cE as Ee,cF as Pe,aD as Oe,a8 as Re}from"./index-c62ac197.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import{C as M}from"./index-c2088808.js";import{D as T}from"./Drawer-949c18c6.js";import"./FormContainer-91c2b0e4.js";import"./Switcher-c8648037.js";import"./index-36228db5.js";import"./Upload-fb34ce03.js";import{A as ze,E as Me}from"./EditLead-cc38d2a2.js";import{A as $e,T as $}from"./actioncell-17e12e21.js";import{D as qe}from"./tableV2-4d1c9fd2.js";import{C as Te}from"./ConfirmDialog-3202eb3d.js";import{r as Qe}from"./index-49a94e54.js";import{r as Ue}from"./index-cebd880b.js";import{u as Ve}from"./usePermission-d94b4984.js";import"./vendor-redux-a1f00e6b.js";import"./LeadSourceService-e46fa85e.js";import"./ContactService-92281a90.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";import"./useControllableState-d0909575.js";import"./useDidUpdate-25c4d4ed.js";import"./DoubleSidedImage-ae98733b.js";import"./index-36ba4ea7.js";import"./StickyFooter-5b934274.js";import"./index.esm-70ab539c.js";import"./AddAccount-a05910e8.js";import"./AccountServices-62599aae.js";import"./DepartmentServices-3d56a9e7.js";import"./Check-71f21a49.js";import"./createSvgIcon-c5fc0d04.js";import"./index-e4c6057f.js";import"./validationPatterns-77446c46.js";import"./CourseService-f0dc3bf1.js";import"./ApiService-2b99757f.js";import"./FileSaver.min-20f3f13a.js";import"./DensitySelector-a2c1c68f.js";import"./NoData-8c485a3a.js";const Be=()=>{const n=Q(),u=r(i=>i.LeadsData.data.deleteConfirmation),h=r(i=>i.LeadsData.data.selectedRowData),f=r(i=>i.LeadsData.data.tableData),t=()=>{n(q(!1))},j=async()=>{n(q(!1)),await Le(h.id)&&(Ie(),n(re(f)),Fe.push(e.jsx(De,{title:"Deleted",type:"success",duration:2500,children:"Lead Successfully Deleted"}),{placement:"top-center"}))};return e.jsx(Te,{isOpen:u,type:"danger",title:"Delete Lead",confirmButtonColor:"red-600",onClose:t,onRequestClose:t,onCancel:t,onConfirm:j,children:e.jsx("p",{children:"Are you sure you want to delete this Lead? This action cannot be undone."})})},We=({onSaveClick:n,onCancel:u,onClearFilers:h})=>e.jsxs("div",{className:"text-right w-full",children:[e.jsx(A,{size:"sm",className:"mr-2",onClick:h,children:"Clear All"}),e.jsx(A,{size:"sm",className:"mr-2",onClick:u,children:"Cancel"}),e.jsx(A,{size:"sm",variant:"solid",onClick:n,children:"Query"})]}),Ge=n=>{const u=Q(),[h,f]=d.useState(!1),t=r(s=>s.LeadsData.data.filterData),[j,i]=d.useState(t==null?void 0:t.contactId),[F,v]=d.useState(t==null?void 0:t.leadSourceId),[D,g]=d.useState(t==null?void 0:t.leadStatus),b=[{value:1,label:"New"},{value:2,label:"Qualified"},{value:3,label:"UnQualified"},{value:5,label:"Meeting"}],C=()=>{f(!1),n.onClose()},y=()=>{u(Ne({}))};d.useEffect(()=>{E(),y()},[]);const E=()=>{u(Se({}))},P=r(s=>{var c,m,l;return(l=(m=(c=s.LeadsData)==null?void 0:c.data)==null?void 0:m.leadSourceList)==null?void 0:l.map(o=>({value:o.id,label:o.leadSourceName}))}),k=r(s=>{var c,m,l;return(l=(m=(c=s.LeadsData)==null?void 0:c.data)==null?void 0:m.contactList)==null?void 0:l.map(o=>({value:o.id,label:o.contactName}))}),O=()=>{u(I({leadStatus:"",leadSourceId:"",contactId:""})),i(""),g(""),v("")},x=()=>{n.onClose(),f(!1),u(I({leadStatus:D,leadSourceId:F,contactId:j}))};return d.useEffect(()=>{n.isOpen&&f(!0)},[n.isOpen]),d.useEffect(()=>{var s,c,m;(s=t==null?void 0:t.contactId)!=null&&s.value||i(""),(c=t==null?void 0:t.leadSourceId)!=null&&c.value||v(""),(m=t==null?void 0:t.leadStatus)!=null&&m.value||g("")},[t]),e.jsx(e.Fragment,{children:e.jsxs(T,{title:"Advanced Filter Selection Page",isOpen:h,portalClassName:"w30",footer:e.jsx(We,{onCancel:C,onSaveClick:x,onClearFilers:O}),onClose:C,onRequestClose:C,children:[e.jsxs("div",{className:"mb-5",children:[e.jsx("div",{className:"lg:flex md:flex-none sm:flex-none mb-4",children:e.jsx("h5",{children:"Lead Source"})}),e.jsx(z,{size:"sm",className:"mb-4 rounded-xl",placeholder:"Please Select",isMulti:!1,isClearable:!0,value:F,onChange:s=>v(s),options:P})]}),e.jsxs("div",{className:"mb-5",children:[e.jsx("div",{className:"lg:flex md:flex-none sm:flex-none mb-4",children:e.jsx("h5",{children:"Contact"})}),e.jsx(z,{size:"sm",className:"mb-4 rounded-xl",placeholder:"Please Select",isMulti:!1,isClearable:!0,value:j,onChange:s=>i(s),options:k})]}),e.jsxs("div",{className:"mb-5",children:[e.jsx("div",{className:"lg:flex md:flex-none sm:flex-none mb-4",children:e.jsx("h5",{children:"Status"})}),e.jsx(z,{size:"sm",className:"mb-4 rounded-xl",placeholder:"Please Select",isMulti:!1,value:D,onChange:s=>g(s),options:b})]})]})})};U("LeadsData",we);U("ContactsData",Qe);U("AccountsData",Ue);const qs=()=>{var H,Y,_,J,K,X,Z,ee,se,ae,te,le,de,oe;const n="Leads",[u,h]=d.useState([]),[f,t]=d.useState(!1),[j,i]=d.useState(!1),[F,v]=d.useState(),[D,g]=d.useState(!1),b=Ve(n),C={edit:b.isEdit,delete:b.isDelete,view:b.isView},y=()=>{g(!0)},E=()=>{g(!1)},P=()=>{t(!0)},k=()=>{t(!1)},O=ve(),x=Q(),s=r(a=>a.LeadsData.data.filterData),c=r(a=>a.LeadsData.data.loading),m=r(a=>a.LeadsData.data.leadList),{metrics:l}=r(a=>a.LeadsData.data),[o,L]=d.useState(null),{textTheme:ue}=ke(),{pageIndex:V,pageSize:B,sort:W,query:me}=r(a=>a.LeadsData.data.tableData);d.useEffect(()=>{xe()},[V,B,W,s,o]);const xe=()=>{var a,p,ie;x(re({pageIndex:V,pageSize:B,sort:W,query:me,...o!==null&&{leadStatus:o},...((a=s==null?void 0:s.leadSourceId)==null?void 0:a.value)&&{leadSourceId:s.leadSourceId.value},...((p=s==null?void 0:s.contactId)==null?void 0:p.value)&&{contactId:s.contactId.value},...((ie=s==null?void 0:s.leadStatus)==null?void 0:ie.value)&&{leadStatus:s.leadStatus.value}}))},S=({type:a})=>{switch(a){case"allLeads":return e.jsx(w,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Re,{})});case"newLeads":return e.jsx(w,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Oe,{})});case"qualifiedLeads":return e.jsx(w,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Pe,{})});case"unqualifiedLeads":return e.jsx(w,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Ee,{})});case"inprogressLeads":return e.jsx(w,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(ye,{})});default:return e.jsx("div",{})}},pe=a=>{O("/app/crm/lead-details/"+a.id)},[he,fe]=d.useState({pageSize:"",pageIndex:""}),je=(a,p)=>{p===$.view&&pe(a),p===$.edit&&(v(a.id),x(ce(a)),i(!0)),p===$.delete&&(x(q(!0)),x(ce(a)))},G=()=>{i(!1)},ge=[{dataField:"Action",caption:"Action",width:"75",cellRender:a=>e.jsx("div",{id:"mAction","data-cname":"Action",children:e.jsx($e,{row:a==null?void 0:a.data,actions:C,buttonClick:je})})},{dataField:"leadName",caption:"Lead Name",width:"180",cellRender:a=>{var p;return e.jsx("div",{"data-cname":"Lead Name",children:e.jsx(Ce,{to:`/app/crm/lead-details/${(p=a==null?void 0:a.data)==null?void 0:p.id}`,className:`${ue} ml-2 rtl:mr-2`,children:a.value})})}},{dataField:"leadSource",caption:"Lead Source",width:"200"},{dataField:"accountName",caption:"Company",width:"200"},{dataField:"contactEmail",caption:"Email",width:"150"},{dataField:"contactNumber",caption:"Phone",width:"150"},{dataField:"completeAddress",caption:"Address",width:"300"},{dataField:"createdDate",caption:"Created On",width:"180",dataType:"date",format:"MM/dd/yyyy"},{dataField:"leadStatus",caption:"Status",width:"180"}],R=a=>{a==="leadSourceId"&&x(I({...s,leadSourceId:""})),a==="contactId"&&x(I({...s,contactId:""})),a==="leadStatus"&&x(I({...s,leadStatus:""}))};return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"topbar py-4 px-6 border-gray-200 border-b",children:e.jsxs("div",{className:"lg:flex items-center justify-between",children:[e.jsx("h3",{className:"mb-4 lg:mb-0",children:"Leads"}),e.jsxs("div",{className:"flex flex-col lg:flex-row lg:items-center",children:[b.isEdit&&e.jsx(A,{onClick:()=>P(),block:!0,variant:"solid",size:"sm",icon:e.jsx(Ae,{}),children:"Add Lead"}),e.jsx(T,{title:"Add Lead",isOpen:f,onClose:k,portalClassName:"w30",children:e.jsx(ze,{footerWidth:"w30",onDrawerClose:k})}),e.jsx(T,{title:"Edit Lead",isOpen:j,onClose:G,portalClassName:"w30",children:e.jsx(Me,{footerWidth:"w30",id:F,onDrawerClose:G})})]})]})}),e.jsxs(ne,{className:"h-full py-4 px-6 m-6 bg-transparent",bodyClass:"h-full",children:[e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-5 xl:grid-cols-5 gap-4 mb-5",children:[e.jsx(N,{onClick:()=>L(null),className:`crm-card crm-stat-card ${o==null?"is-selected":""}`,children:e.jsxs("div",{className:"flex items-center gap-4 flex-wrap",children:[e.jsx(S,{type:"allLeads"}),e.jsx("div",{children:e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none",children:(l==null?void 0:l.totalLeads)||0}),e.jsx("p",{className:"font-semibold",children:"All Leads"})]})})]})}),e.jsx(N,{onClick:()=>L(1),className:`crm-card crm-stat-card ${o===1?"is-selected":""}`,children:e.jsxs("div",{className:"flex items-center gap-4 flex-wrap",children:[e.jsx(S,{type:"newLeads"}),e.jsx("div",{children:e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none",children:(Y=(H=l==null?void 0:l.statusCounts)==null?void 0:H.$values.find(a=>a.status==="New"))==null?void 0:Y.count}),e.jsx("p",{className:"font-semibold",children:"New Leads"})]})})]})}),e.jsx(N,{onClick:()=>L(2),className:`crm-card crm-stat-card ${o===2?"is-selected":""}`,children:e.jsxs("div",{className:"flex items-center gap-4 flex-wrap",children:[e.jsx(S,{type:"qualifiedLeads"}),e.jsx("div",{children:e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none",children:(J=(_=l==null?void 0:l.statusCounts)==null?void 0:_.$values.find(a=>a.status==="Qualified"))==null?void 0:J.count}),e.jsx("p",{className:"font-semibold",children:"Qualified Leads"})]})})]})}),e.jsx(N,{onClick:()=>L(3),className:`crm-card crm-stat-card ${o===3?"is-selected":""}`,children:e.jsxs("div",{className:"flex items-center gap-4 flex-wrap",children:[e.jsx(S,{type:"unqualifiedLeads"}),e.jsx("div",{children:e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none",children:(X=(K=l==null?void 0:l.statusCounts)==null?void 0:K.$values.find(a=>a.status==="UnQualified"))==null?void 0:X.count}),e.jsx("p",{className:"font-semibold",children:"Unqualified Leads"})]})})]})}),e.jsx(N,{onClick:()=>L(5),className:`crm-card crm-stat-card ${o===5?"is-selected":""}`,children:e.jsxs("div",{className:"flex items-center gap-4 flex-wrap",children:[e.jsx(S,{type:"inprogressLeads"}),e.jsx("div",{children:e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none",children:(ee=(Z=l==null?void 0:l.statusCounts)==null?void 0:Z.$values.find(a=>a.status==="Meeting"))==null?void 0:ee.count}),e.jsx("p",{className:"font-semibold",children:"Meeting"})]})})]})})]}),c&&e.jsx(be,{sx:{backgroundColor:"rgba(0, 0, 0, 0.1)","& .MuiLinearProgress-bar":{backgroundColor:"var(--custom-600)"}}}),e.jsxs(ne,{className:"borderless",children:[e.jsxs("div",{className:"text-right mb-3",children:[((se=s==null?void 0:s.leadSourceId)==null?void 0:se.value)&&e.jsx(M,{title:"Source",value:(ae=s==null?void 0:s.leadSourceId)==null?void 0:ae.label,onRemovefilter:R,tagId:"leadSourceId"}),((te=s==null?void 0:s.contactId)==null?void 0:te.value)&&e.jsx(M,{title:"Contact",value:(le=s==null?void 0:s.contactId)==null?void 0:le.label,onRemovefilter:R,tagId:"contactId"}),((de=s==null?void 0:s.leadStatus)==null?void 0:de.value)&&e.jsx(M,{title:"Status",value:(oe=s==null?void 0:s.leadStatus)==null?void 0:oe.label,onRemovefilter:R,tagId:"leadStatus"})]}),e.jsx(qe,{columns:ge,tableName:"Lead-List",data:m||[],height:"calc(100vh - 400px)",defaultHiddenColumn:[],fetchData:()=>{},id_label:"$id",selectedRowId:u,setSelectedRowId:h,setFilterValues:()=>{},filterValues:[],identity:"Lead-Listing",setInLineFilters:()=>{},inLineFilter:[],inLineFilterMobileView:[],setInLineFiltersMobileView:()=>{},setColSorting:()=>{},ImpColumnName:"DocumentId",idName:"Lead-Listing-table",handleSearch:()=>{},isColumnResizing:!0,pager:he,setPager:fe,openFilter:y,isPaginationReq:!0,isFilterReq:!0,isSelectionReq:!1,isLoading:c})]})]}),e.jsx(Be,{}),e.jsx(Ge,{isOpen:D,onClose:E})]})};export{qs as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as m}from"./vendor-mui-69397583.js";import{h as _,d as I,A as $}from"./index-c62ac197.js";import{r as L}from"./vendor-react-ece1c85f.js";function M(t,o){if(!o)return"/img/logo/";const s=o.replace(/\\/g,"/").split("/").map(encodeURIComponent).join("/");return`${t}/${s}`}const P="/img/logo/",y=t=>{const{type:o="full",mode:l="light",className:s,imgClass:d,style:p,logoWidth:h="auto"}=t,{logoIconLightMode:i,fullLogoIconLightMode:r,logoIconDarkMode:a,fullLogoIconDarkMode:c}=_(e=>e==null?void 0:e.theme),g=L.useMemo(()=>{const e={streamline_light:i,full_light:r,streamline_dark:a,full_dark:c},u=`${o}_${l}`,n=e[u],f=(n==null?void 0:n.settingFilePath)||"";return M(window.RUNTIME_CONFIG.VITE_API_BASE_URL,f)},[o,l,i,r,a,c]);return m.jsx("div",{className:I("logo",s),style:{...p,width:h},children:m.jsx("img",{style:{fill:`${l}`},className:d,src:g==="/img/logo/"?`${P}logo-${l}-${o}.png`:g,alt:`${$} logo`})})};export{y as L};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./vendor-mui-69397583.js";import{A as l}from"./AdaptableCard-df7695d6.js";import{M as m}from"./mapView-ab35acaa.js";import{r as i}from"./vendor-react-ece1c85f.js";import{a as p}from"./KeyVaultService-874d83fe.js";import{d0 as u}from"./index-c62ac197.js";import"./esm-f306d015.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import"./useControllableState-d0909575.js";import"./index-c2088808.js";import"./useDidUpdate-25c4d4ed.js";import"./Drawer-949c18c6.js";import"./FormContainer-91c2b0e4.js";import"./Switcher-c8648037.js";import"./index-36228db5.js";import"./Upload-fb34ce03.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";const b="EncryptKeyVaultD",y=[{id:"2f3a5b24-bacf-4f29-9a4e-1f2b3a6e5d23",leadName:"Alice Johnson",leadSource:"Referral",accountName:"Acme Corp",website:"https://acme.com",contactPosistion:{positionName:"Sales Manager"},contactEmail:"alice.johnson@acme.com",contactNumber:"123-456-7890",address:"123 Main St",city:"Houston",state:"TX",zip:"77002",industry:"Technology",noOfEmployees:150,latitude:29.749907,longitude:-95.358421,hoveredRowKey:878888},{id:"6cb7f33e-1254-4d2a-b9a4-fef9a0840a41",leadName:"Bob Smith",leadSource:"Website",accountName:"Beta Ltd",website:"https://beta.com",contactPosistion:{positionName:"CTO"},contactEmail:"bob.smith@beta.com",contactNumber:"987-654-3210",address:"456 Market St",city:"Austin",state:"TX",zip:"73301",industry:"Finance",noOfEmployees:80,latitude:30.267153,longitude:-97.743057,hoveredRowKey:878888},{id:"891c9bbf-f8e9-4e1b-9b6b-5d2bbf81c24f",leadName:"Charlie Brown",leadSource:"LinkedIn",accountName:"Gamma Inc",website:"https://gamma.com",contactPosistion:{positionName:"Marketing Head"},contactEmail:"charlie.brown@gamma.com",contactNumber:"555-123-4567",address:"789 Elm St",city:"Dallas",state:"TX",zip:"75201",industry:"Retail",noOfEmployees:50,latitude:32.7767,longitude:-96.797,hoveredRowKey:878888},{id:"c3ed3344-76f3-4e9d-bae9-82d324c8e7ff",leadName:"Diana Prince",leadSource:"Email Campaign",accountName:"Delta LLC",website:"https://delta.com",contactPosistion:{positionName:"CEO"},contactEmail:"diana.prince@delta.com",contactNumber:"321-654-9870",address:"1600 Pennsylvania Ave NW",city:"Washington",state:"DC",zip:"20500",industry:"Government",noOfEmployees:1e3,latitude:38.8977,longitude:-77.0365,hoveredRowKey:878888},{id:"45a2e6de-9cb7-4d5a-9121-3e93d7bfa234",leadName:"Ethan Hunt",leadSource:"Cold Call",accountName:"Impossible Missions Force",website:"https://imf.gov",contactPosistion:{positionName:"Agent"},contactEmail:"ethan.hunt@imf.gov",contactNumber:"222-333-4444",address:"1 Mission Blvd",city:"San Diego",state:"CA",zip:"92101",industry:"Defense",noOfEmployees:500,latitude:32.7157,longitude:-117.1611,hoveredRowKey:878888},{id:"37f70c93-2899-4a4e-85e2-785d9b3e3c8e",leadName:"Fiona Gallagher",leadSource:"Inbound Call",accountName:"Shameless Inc",website:"https://shameless.com",contactPosistion:{positionName:"Operations Lead"},contactEmail:"fiona.gallagher@shameless.com",contactNumber:"777-888-9999",address:"742 Evergreen Terrace",city:"Springfield",state:"IL",zip:"62704",industry:"Hospitality",noOfEmployees:120,latitude:39.7817,longitude:-89.6501,hoveredRowKey:878888},{id:"1c94a0f3-bf83-4ab1-a95e-e1116c21b0ee",leadName:"George Costanza",leadSource:"Conference",accountName:"Vandelay Industries",website:"https://vandelay.com",contactPosistion:{positionName:"Importer/Exporter"},contactEmail:"george.costanza@vandelay.com",contactNumber:"444-555-6666",address:"129 W 81st St",city:"New York",state:"NY",zip:"10024",industry:"Import/Export",noOfEmployees:40,latitude:40.7812,longitude:-73.9665,hoveredRowKey:878888},{id:"9b3b2ad9-e0bc-40d0-9ab2-1609c9a97927",leadName:"Hannah Baker",leadSource:"Webinar",accountName:"Liberty High",website:"https://libertyhigh.edu",contactPosistion:{positionName:"Counselor"},contactEmail:"hannah.baker@libertyhigh.edu",contactNumber:"333-222-1111",address:"12 River Rd",city:"Portland",state:"OR",zip:"97201",industry:"Education",noOfEmployees:200,latitude:45.5051,longitude:-122.675,hoveredRowKey:878888},{id:"ae5e52dc-dcb0-4a76-a12c-3ebd9b31a168",leadName:"Ian Malcolm",leadSource:"Trade Show",accountName:"Jurassic Systems",website:"https://jurassic.tech",contactPosistion:{positionName:"Mathematician"},contactEmail:"ian.malcolm@jurassic.tech",contactNumber:"111-222-3333",address:"100 Jurassic Park Rd",city:"Honolulu",state:"HI",zip:"96801",industry:"Science",noOfEmployees:10,latitude:45.3451,longitude:-122.2355,hoveredRowKey:878888},{id:"e2e68d5f-51f4-4dc2-ae76-b121789ae2fd",leadName:"Jane Eyre",leadSource:"Newsletter",accountName:"Thornfield Hall",website:"https://thornfield.com",contactPosistion:{positionName:"Governess"},contactEmail:"jane.eyre@thornfield.com",contactNumber:"123-321-1234",address:"44 Bronte St",city:"Rochester",state:"NY",zip:"14604",industry:"Literature",noOfEmployees:5,latitude:43.1566,longitude:-77.6088,hoveredRowKey:878888}],T=()=>{const[t,s]=i.useState(""),n=async()=>{try{const o=(await p({})).data.$values.find(d=>d.key==="Google Maps");if(!o){console.error("Google Maps key not found");return}const c=o.value,r=await u(c,b);s(r)}catch(a){console.error("Error fetching data:",a)}};return i.useEffect(()=>{n()},[]),e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"topbar py-4 px-6 border-gray-200 border-b",children:e.jsx("div",{className:"lg:flex items-center justify-between",children:e.jsx("h3",{className:"mb-4 lg:mb-0",children:"Map View"})})}),e.jsx(l,{className:"m-6 h-full py-4 px-6 bg-transparent",bodyClass:"h-full",children:t!=""&&e.jsx(m,{decryptValue:t,isDashboard:!0,properties:y})})]})};export{b as DECRYPTION_KEY,T as default};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./vendor-mui-69397583.js";import{f as j,r as f}from"./vendor-react-ece1c85f.js";import{L as v}from"./Logo-3f3c9ee6.js";import"./index-c62ac197.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";const d=({name:r,size:s=18,stroke:i=1.8})=>{const a={width:s,height:s,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:i,strokeLinecap:"round",strokeLinejoin:"round"};switch(r){case"arrow":return e.jsx("svg",{...a,children:e.jsx("path",{d:"M5 12h14M13 6l6 6-6 6"})});case"play":return e.jsx("svg",{...a,children:e.jsx("polygon",{points:"5,3 19,12 5,21",fill:"currentColor",stroke:"none"})});case"code":return e.jsxs("svg",{...a,children:[e.jsx("polyline",{points:"16 18 22 12 16 6"}),e.jsx("polyline",{points:"8 6 2 12 8 18"})]});case"layers":return e.jsxs("svg",{...a,children:[e.jsx("path",{d:"M12 2 2 7l10 5 10-5-10-5z"}),e.jsx("path",{d:"M2 17l10 5 10-5"}),e.jsx("path",{d:"M2 12l10 5 10-5"})]});case"grid":return e.jsxs("svg",{...a,children:[e.jsx("rect",{x:"3",y:"3",width:"7",height:"7"}),e.jsx("rect",{x:"14",y:"3",width:"7",height:"7"}),e.jsx("rect",{x:"3",y:"14",width:"7",height:"7"}),e.jsx("rect",{x:"14",y:"14",width:"7",height:"7"})]});case"sliders":return e.jsxs("svg",{...a,children:[e.jsx("line",{x1:"4",y1:"21",x2:"4",y2:"14"}),e.jsx("line",{x1:"4",y1:"10",x2:"4",y2:"3"}),e.jsx("line",{x1:"12",y1:"21",x2:"12",y2:"12"}),e.jsx("line",{x1:"12",y1:"8",x2:"12",y2:"3"}),e.jsx("line",{x1:"20",y1:"21",x2:"20",y2:"16"}),e.jsx("line",{x1:"20",y1:"12",x2:"20",y2:"3"}),e.jsx("line",{x1:"1",y1:"14",x2:"7",y2:"14"}),e.jsx("line",{x1:"9",y1:"8",x2:"15",y2:"8"}),e.jsx("line",{x1:"17",y1:"16",x2:"23",y2:"16"})]});case"plug":return e.jsxs("svg",{...a,children:[e.jsx("path",{d:"M9 2v6"}),e.jsx("path",{d:"M15 2v6"}),e.jsx("path",{d:"M5 8h14v3a7 7 0 0 1-14 0z"}),e.jsx("path",{d:"M12 18v4"})]});case"rocket":return e.jsxs("svg",{...a,children:[e.jsx("path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09z"}),e.jsx("path",{d:"M12 15l-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z"}),e.jsx("path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0"}),e.jsx("path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5"})]});case"shield":return e.jsx("svg",{...a,children:e.jsx("path",{d:"M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"})});case"users":return e.jsxs("svg",{...a,children:[e.jsx("path",{d:"M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"}),e.jsx("circle",{cx:"9",cy:"7",r:"4"}),e.jsx("path",{d:"M23 21v-2a4 4 0 0 0-3-3.87"}),e.jsx("path",{d:"M16 3.13a4 4 0 0 1 0 7.75"})]});case"check":return e.jsx("svg",{...a,children:e.jsx("polyline",{points:"20 6 9 17 4 12"})});case"git":return e.jsxs("svg",{...a,children:[e.jsx("circle",{cx:"18",cy:"18",r:"3"}),e.jsx("circle",{cx:"6",cy:"6",r:"3"}),e.jsx("path",{d:"M6 21V9a9 9 0 0 0 9 9"})]});case"spark":return e.jsx("svg",{...a,children:e.jsx("path",{d:"M12 2l2.4 7.4H22l-6 4.4 2.3 7.2-6.3-4.6-6.3 4.6L8 13.8 2 9.4h7.6z"})});case"table":return e.jsxs("svg",{...a,children:[e.jsx("rect",{x:"3",y:"3",width:"18",height:"18",rx:"2"}),e.jsx("line",{x1:"3",y1:"9",x2:"21",y2:"9"}),e.jsx("line",{x1:"3",y1:"15",x2:"21",y2:"15"}),e.jsx("line",{x1:"9",y1:"3",x2:"9",y2:"21"})]});case"chart":return e.jsxs("svg",{...a,children:[e.jsx("line",{x1:"18",y1:"20",x2:"18",y2:"10"}),e.jsx("line",{x1:"12",y1:"20",x2:"12",y2:"4"}),e.jsx("line",{x1:"6",y1:"20",x2:"6",y2:"14"})]});case"form":return e.jsxs("svg",{...a,children:[e.jsx("rect",{x:"3",y:"3",width:"18",height:"18",rx:"2"}),e.jsx("path",{d:"M8 8h8M8 12h8M8 16h5"})]});case"kpi":return e.jsxs("svg",{...a,children:[e.jsx("path",{d:"M3 3v18h18"}),e.jsx("path",{d:"M7 14l4-4 4 4 5-5"})]});case"lock":return e.jsxs("svg",{...a,children:[e.jsx("rect",{x:"3",y:"11",width:"18",height:"11",rx:"2"}),e.jsx("path",{d:"M7 11V7a5 5 0 0 1 10 0v4"})]});default:return null}},t={ink:"#1B1B1B",orange:"#F15A22",muted:"#646464",line:"#E9E9E9",soft:"#F6F4F1",cream:"#FBF2EA",green:"#16A34A"},k=()=>e.jsxs("div",{className:"relative",style:{height:520},children:[e.jsxs("div",{className:"absolute inset-0 rounded-[18px] bg-white overflow-hidden border border-ca-slate-100",style:{boxShadow:"0 30px 80px rgba(20,20,20,0.12), 0 4px 12px rgba(20,20,20,0.06)"},children:[e.jsxs("div",{className:"flex items-center gap-1.5 h-9 px-3.5 border-b border-ca-slate-100",style:{background:t.soft},children:[e.jsx("span",{className:"w-2.5 h-2.5 rounded-full",style:{background:"#FC6058"}}),e.jsx("span",{className:"w-2.5 h-2.5 rounded-full",style:{background:"#FDBC40"}}),e.jsx("span",{className:"w-2.5 h-2.5 rounded-full",style:{background:"#34C949"}}),e.jsx("span",{className:"ml-3 text-[11px] text-ca-slate-500 font-ibm-mono bg-white px-3 py-1 rounded-full border border-ca-slate-100",children:"app.acme.com / fleet · operations"})]}),e.jsxs("div",{className:"p-6 grid grid-cols-2 gap-3.5",children:[e.jsxs("div",{className:"rounded-[12px] p-3.5 border border-black/[.04]",style:{background:t.cream},children:[e.jsx("div",{className:"text-[11px] font-bold uppercase tracking-[0.06em] text-ca-slate-500",children:"On-time rate"}),e.jsx("div",{className:"text-[28px] font-black text-ca-ink mt-1.5 leading-none tracking-[-0.02em]",children:"94.6%"}),e.jsx("div",{className:"text-[12px] font-bold mt-1",style:{color:t.green},children:"▲ 2.4 vs. last week"})]}),e.jsxs("div",{className:"rounded-[12px] p-3.5 border border-black/[.04]",style:{background:t.cream},children:[e.jsx("div",{className:"text-[11px] font-bold uppercase tracking-[0.06em] text-ca-slate-500",children:"Loads in transit"}),e.jsx("div",{className:"text-[28px] font-black text-ca-ink mt-1.5 leading-none tracking-[-0.02em]",children:"1,284"}),e.jsx("div",{className:"text-[12px] font-bold mt-1",style:{color:t.green},children:"▲ 118 since 9am"})]}),e.jsxs("div",{className:"col-span-2 bg-white border border-ca-slate-100 rounded-[12px] p-3.5",style:{height:200,display:"flex",flexDirection:"column"},children:[e.jsxs("div",{className:"flex justify-between items-center",children:[e.jsx("div",{className:"text-[12px] font-bold text-ca-ink",children:"Throughput · last 12 weeks"}),e.jsxs("div",{className:"flex gap-2.5 text-[10px] text-ca-slate-500",children:[e.jsxs("span",{children:[e.jsx("i",{className:"inline-block w-2 h-2 rounded-[2px] mr-1 align-middle bg-ca-orange-500"}),"This year"]}),e.jsxs("span",{children:[e.jsx("i",{className:"inline-block w-2 h-2 rounded-[2px] mr-1 align-middle bg-ca-slate-200"}),"Last year"]})]})]}),e.jsxs("svg",{viewBox:"0 0 320 110",preserveAspectRatio:"none",style:{flex:1,width:"100%"},children:[e.jsx("defs",{children:e.jsxs("linearGradient",{id:"hg",x1:"0",x2:"0",y1:"0",y2:"1",children:[e.jsx("stop",{offset:"0",stopColor:t.orange,stopOpacity:"0.32"}),e.jsx("stop",{offset:"1",stopColor:t.orange,stopOpacity:"0"})]})}),e.jsx("path",{d:"M0 78 L26 70 L52 75 L78 60 L104 65 L130 50 L156 55 L182 38 L208 42 L234 30 L260 22 L286 18 L320 10 L320 110 L0 110 Z",fill:"url(#hg)"}),e.jsx("path",{d:"M0 78 L26 70 L52 75 L78 60 L104 65 L130 50 L156 55 L182 38 L208 42 L234 30 L260 22 L286 18 L320 10",fill:"none",stroke:t.orange,strokeWidth:"2.4"}),e.jsx("path",{d:"M0 88 L26 86 L52 80 L78 84 L104 76 L130 78 L156 70 L182 72 L208 64 L234 66 L260 58 L286 60 L320 50",fill:"none",stroke:"#D9D9D9",strokeWidth:"1.6",strokeDasharray:"3 4"})]})]})]})]}),e.jsxs("div",{className:"absolute flex items-center gap-2.5 bg-white rounded-[12px] px-3.5 py-3 border border-ca-slate-100 text-[13px]",style:{bottom:24,left:-40,boxShadow:"0 20px 50px rgba(20,20,20,0.18)",animation:"mpFloatA 4s ease-in-out infinite"},children:[e.jsx("div",{className:"w-[30px] h-[30px] rounded-[8px] bg-ca-orange-500 text-white grid place-items-center flex-shrink-0",children:e.jsx(d,{name:"rocket",size:16})}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-ca-ink text-[12px]",children:"Deployed in 3.2s"}),e.jsx("div",{className:"text-[11px] text-ca-slate-500",children:"production · v0.41.2"})]})]}),e.jsxs("div",{className:"absolute flex items-center gap-2.5 bg-white rounded-[12px] px-3.5 py-3 border border-ca-slate-100 text-[13px]",style:{top:50,right:-30,boxShadow:"0 20px 50px rgba(20,20,20,0.18)",animation:"mpFloatB 5s ease-in-out infinite"},children:[e.jsx("div",{className:"w-[30px] h-[30px] rounded-[8px] grid place-items-center flex-shrink-0 text-white bg-ca-ink",children:e.jsx(d,{name:"code",size:16})}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-ca-ink text-[12px]",children:"~ 240 lines saved"}),e.jsx("div",{className:"text-[11px] text-ca-slate-500",children:"vs hand-rolled"})]})]})]}),w=({onCta:r})=>e.jsxs("section",{className:"relative pt-[90px] px-10 overflow-hidden",children:[e.jsx("div",{className:"absolute pointer-events-none",style:{top:-120,right:-160,width:540,height:540,background:"radial-gradient(circle, rgba(241,90,34,0.18), transparent 70%)"}}),e.jsxs("div",{className:"max-w-[1320px] mx-auto grid gap-16 items-center",style:{gridTemplateColumns:"1.05fr 1fr"},children:[e.jsxs("div",{children:[e.jsxs("div",{className:"inline-flex items-center gap-2.5 text-[13px] font-bold text-ca-ink bg-white border border-ca-slate-100 rounded-full px-3.5 py-1.5 mb-7",children:[e.jsx("span",{className:"bg-ca-orange-500 text-white text-[11px] px-2.5 py-[3px] rounded-full uppercase tracking-[0.04em]",children:"v2.0 · Sonoma"}),"AI-assisted layout suggestions are live",e.jsx(d,{name:"arrow",size:12,stroke:2.4})]}),e.jsxs("h1",{className:"font-lato font-black text-ca-ink mb-7 leading-[0.98] tracking-[-0.035em]",style:{fontSize:76},children:["The framework devs use to ship"," ",e.jsx("em",{className:"not-italic",style:{background:`linear-gradient(120deg, ${t.orange} 0%, #F49A5C 100%)`,WebkitBackgroundClip:"text",backgroundClip:"text",color:"transparent",display:"inline-block"},children:"internal apps in hours."})]}),e.jsx("p",{className:"text-[19px] leading-relaxed text-ca-slate-500 font-light max-w-[540px] mb-10",children:"xFramework is a low-code runtime for software teams. Drop in components, connect your data, theme it to your brand — and get a production app with auth, perms and audit baked in. No more “internal tool tax.”"}),e.jsxs("div",{className:"flex items-center gap-3.5 flex-wrap",children:[e.jsxs("button",{className:"inline-flex items-center gap-2.5 font-lato font-bold text-[16px] px-7 py-4 rounded-full border-0 cursor-pointer text-white bg-ca-ink transition-all duration-200 active:scale-[0.98]",onClick:r,children:["Start building free ",e.jsx(d,{name:"arrow",size:16,stroke:2.4})]}),e.jsxs("a",{href:"#mp-tour",className:"inline-flex items-center gap-2.5 font-lato font-bold text-[16px] px-7 py-4 rounded-full border border-ca-slate-100 text-ca-ink no-underline hover:border-ca-ink transition-all duration-200",children:[e.jsx(d,{name:"play",size:14})," Take the tour"]})]}),e.jsxs("div",{className:"flex items-center gap-4 mt-6 text-[13px] text-ca-slate-500",children:[e.jsxs("span",{children:[e.jsx("span",{className:"inline-grid place-items-center w-4 h-4 rounded-full mr-1 font-black text-[10px]",style:{background:"#DBF1E1",color:t.green},children:"✓"})," No credit card"]}),e.jsxs("span",{children:[e.jsx("span",{className:"inline-grid place-items-center w-4 h-4 rounded-full mr-1 font-black text-[10px]",style:{background:"#DBF1E1",color:t.green},children:"✓"})," SOC 2 Type II"]}),e.jsxs("span",{children:[e.jsx("span",{className:"inline-grid place-items-center w-4 h-4 rounded-full mr-1 font-black text-[10px]",style:{background:"#DBF1E1",color:t.green},children:"✓"})," Self-host or cloud"]})]})]}),e.jsx(k,{})]})]}),S=()=>e.jsx("section",{className:"mt-[110px] py-[30px] px-10 border-t border-b border-ca-slate-100",children:e.jsxs("div",{className:"max-w-[1320px] mx-auto flex items-center gap-[60px] flex-wrap",children:[e.jsx("div",{className:"text-[12px] font-bold uppercase tracking-[0.14em] text-ca-slate-500 flex-shrink-0",children:"Trusted by software teams at"}),e.jsx("div",{className:"flex-1 flex gap-[50px] flex-wrap items-center",children:["CARGOWAVE","Lumenly","Northstar.io","MHX Logistics","Foundry42","Hyperloop"].map(r=>e.jsx("span",{className:"font-lato font-black text-[19px] tracking-[-0.01em]",style:{color:"#999",opacity:.75},children:r},r))})]})}),N=[{icon:"code",title:"For developers",body:"Stop writing the same CRUD screen for the fourth time this quarter. Compose pages from typed components, override anything in code.",items:["TypeScript SDK + REST & GraphQL adapters","Drop into Next, Remix, or any React app","Custom components with full hot reload"]},{icon:"layers",title:"For software companies",body:"Turn your back-office tools into a product surface. White-label themes, multi-tenant orgs, audit logs — all in the box.",items:["Theme to your brand in < 5 minutes","RBAC, SSO (SAML, OIDC), SCIM provisioning","Per-customer subdomains & data scoping"]},{icon:"rocket",title:"For shipping fast",body:"Click build, configure, ship. Roles, permissions and audit are wired automatically — you never touch a migration just to add a column.",items:["One-click deploy to xFramework Cloud","Self-host with Docker or Helm in 10 minutes","Versioned releases with rollback"]}],L=()=>e.jsx("section",{className:"pt-[110px] px-10",id:"mp-why",children:e.jsxs("div",{className:"max-w-[1320px] mx-auto",children:[e.jsxs("div",{className:"grid gap-[60px] mb-[60px] items-end",style:{gridTemplateColumns:"1fr 1fr"},children:[e.jsxs("div",{children:[e.jsx("div",{className:"text-[12px] font-bold tracking-[0.14em] uppercase text-ca-orange-500 mb-5",children:"Why xFramework"}),e.jsx("h2",{className:"font-lato font-black text-ca-ink m-0 leading-[1.02] tracking-[-0.03em]",style:{fontSize:56},children:"Built for the people who get pinged on Slack at midnight."})]}),e.jsx("p",{className:"text-[18px] text-ca-slate-500 font-light leading-relaxed max-w-[480px] m-0",children:"A framework that respects your stack. Use it as a full app, embed it inside your product, or call it like a library — your call."})]}),e.jsx("div",{className:"grid grid-cols-3 gap-[18px]",children:N.map(r=>e.jsxs("article",{className:"bg-white border border-ca-slate-100 rounded-[18px] p-8 transition-all duration-200 hover:-translate-y-0.5",onMouseEnter:s=>{s.currentTarget.style.borderColor=t.ink,s.currentTarget.style.boxShadow="0 12px 30px rgba(20,20,20,0.06)"},onMouseLeave:s=>{s.currentTarget.style.borderColor="",s.currentTarget.style.boxShadow=""},children:[e.jsx("div",{className:"w-11 h-11 rounded-[10px] grid place-items-center text-ca-orange-500 mb-5",style:{background:t.cream},children:e.jsx(d,{name:r.icon,size:22})}),e.jsx("h3",{className:"font-lato font-black text-[22px] text-ca-ink tracking-[-0.01em] mb-3 mt-0",children:r.title}),e.jsx("p",{className:"text-[15px] leading-relaxed text-ca-slate-500 font-light mb-4 mt-0",children:r.body}),e.jsx("ul",{className:"list-none p-0 m-0 flex flex-col gap-2",children:r.items.map(s=>e.jsxs("li",{className:"flex gap-2.5 text-[14px] text-ca-slate-700",children:[e.jsx("span",{className:"inline-grid place-items-center w-4 h-4 rounded-full bg-ca-orange-500 flex-shrink-0 mt-0.5 text-[9px] font-black text-white",children:"✓"}),s]},s))})]},r.title))})]})}),T=()=>e.jsxs("div",{style:{display:"flex",flexDirection:"column",height:"100%"},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:8,padding:"8px 0 14px",borderBottom:`1px solid ${t.line}`,marginBottom:18},children:[["Build","Templates","Recents"].map((r,s)=>e.jsx("span",{style:{fontSize:12,fontWeight:700,padding:"6px 12px",borderRadius:999,background:s===0?t.ink:t.soft,color:s===0?"#fff":t.muted},children:r},r)),e.jsx("span",{style:{flex:1}}),e.jsx("span",{style:{display:"inline-flex",alignItems:"center",gap:6,fontSize:11,fontWeight:700,background:t.cream,color:t.orange,padding:"4px 10px",borderRadius:999},children:"⌘B"})]}),e.jsxs("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:14},children:[e.jsxs("div",{style:{border:`1.5px solid ${t.orange}`,borderRadius:14,padding:22,background:`linear-gradient(180deg, ${t.cream}, #fff)`,position:"relative"},children:[e.jsx("div",{style:{position:"absolute",top:14,right:14,fontSize:10,fontWeight:700,background:t.orange,color:"#fff",padding:"3px 10px",borderRadius:999},children:"Most used"}),e.jsx("div",{style:{width:40,height:40,borderRadius:10,background:t.orange,color:"#fff",display:"grid",placeItems:"center",marginBottom:16},children:e.jsx(d,{name:"layers",size:20})}),e.jsx("h4",{style:{fontWeight:900,fontSize:18,margin:"0 0 6px",color:t.ink},children:"Page"}),e.jsx("p",{style:{fontSize:13,color:t.muted,margin:"0 0 14px",lineHeight:1.5},children:"A focused screen — table, form, detail or workflow."}),e.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6},children:["Driver list","Create order","Invoice detail"].map(r=>e.jsx("span",{style:{fontSize:10,padding:"3px 8px",borderRadius:999,background:t.soft,color:"#333",fontWeight:700},children:r},r))})]}),e.jsxs("div",{style:{border:`1.5px solid ${t.line}`,borderRadius:14,padding:22,background:"#fff"},children:[e.jsx("div",{style:{width:40,height:40,borderRadius:10,background:t.ink,color:t.orange,display:"grid",placeItems:"center",marginBottom:16},children:e.jsx(d,{name:"grid",size:20})}),e.jsx("h4",{style:{fontWeight:900,fontSize:18,margin:"0 0 6px",color:t.ink},children:"Dashboard"}),e.jsx("p",{style:{fontSize:13,color:t.muted,margin:"0 0 14px",lineHeight:1.5},children:"Live grid of widgets that auto-refresh."}),e.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6},children:["Ops overview","Sales pipeline","Site health"].map(r=>e.jsx("span",{style:{fontSize:10,padding:"3px 8px",borderRadius:999,background:t.soft,color:"#333",fontWeight:700},children:r},r))})]})]}),e.jsxs("div",{style:{marginTop:18,background:t.soft,borderRadius:12,padding:"14px 16px"},children:[e.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:10},children:[e.jsx("span",{style:{fontSize:12,fontWeight:700,color:t.ink},children:"Continue where you left off"}),e.jsx("span",{style:{fontSize:11,color:t.orange,fontWeight:700},children:"View all →"})]}),[["kpi","Executive Overview","Analytics / Executive overview","2h ago"],["table","Driver Performance","Operations / Fleet","Yesterday"],["form","Ticket Intake Form","Support / Tickets","3d ago"]].map(([r,s,i,a])=>e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"8px 0",borderTop:`1px solid ${t.line}`},children:[e.jsx("div",{style:{width:26,height:26,borderRadius:6,background:"#fff",display:"grid",placeItems:"center",color:t.orange},children:e.jsx(d,{name:r,size:14})}),e.jsxs("div",{style:{flex:1},children:[e.jsx("div",{style:{fontSize:12,fontWeight:700,color:t.ink},children:s}),e.jsx("div",{style:{fontSize:10,color:t.muted},children:i})]}),e.jsx("div",{style:{fontSize:10,color:t.muted},children:a})]},s))]})]}),R=()=>e.jsxs("div",{style:{display:"grid",gridTemplateColumns:"200px 1fr",height:"100%",gap:14},children:[e.jsx("div",{style:{background:t.soft,borderRadius:12,padding:14,display:"flex",flexDirection:"column",gap:4},children:[{grp:"Data",items:[["table","Data Table",!0],["kpi","KPI Stats"],["form","Form"]]},{grp:"Visualize",items:[["chart","Graph"],["grid","Donut"]]},{grp:"Layout",items:[["layers","Header"]]}].map(({grp:r,items:s})=>e.jsxs("div",{children:[e.jsx("div",{style:{fontSize:10,fontWeight:700,color:t.muted,textTransform:"uppercase",letterSpacing:"0.08em",padding:"8px 10px 4px"},children:r}),s.map(([i,a,l])=>e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"8px 10px",borderRadius:8,fontSize:12,color:l?t.ink:"#333",fontWeight:l?700:500,background:l?"#fff":"transparent",boxShadow:l?"0 1px 2px rgba(0,0,0,0.04)":"none"},children:[e.jsx("div",{style:{width:22,height:22,borderRadius:5,background:l?t.orange:"#fff",display:"grid",placeItems:"center",color:l?"#fff":t.orange},children:e.jsx(d,{name:i,size:12})}),a]},a))]},r))}),e.jsxs("div",{style:{background:"#fff",border:`2px dashed ${t.line}`,borderRadius:12,padding:16,display:"flex",flexDirection:"column",gap:10},children:[e.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[e.jsx("span",{style:{fontSize:13,fontWeight:900,color:t.ink},children:"Driver Performance · canvas"}),e.jsx("span",{style:{fontSize:11,color:t.muted,fontWeight:700},children:"auto-pack: ON"})]}),e.jsx("div",{style:{background:t.cream,border:"1px solid rgba(241,90,34,0.2)",borderRadius:10,padding:14,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:10},children:[["On-time","94.6%","▲ 2.4"],["Avg idle","18m","▼ 6m"],["Routes","142","▲ 8"]].map(([r,s,i])=>e.jsxs("div",{children:[e.jsx("div",{style:{fontSize:9,color:t.muted,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.06em"},children:r}),e.jsx("div",{style:{fontSize:22,fontWeight:900,color:t.ink,marginTop:2,lineHeight:1},children:s}),e.jsx("div",{style:{fontSize:10,color:t.green,fontWeight:700},children:i})]},r))}),e.jsxs("div",{style:{background:"#fff",border:`1px solid ${t.line}`,borderRadius:10,padding:12},children:[e.jsx("div",{style:{fontSize:11,fontWeight:700,color:t.ink,marginBottom:8},children:"Driver list"}),["M. Reyes","T. Okafor","B. Andrade","S. Han"].map((r,s)=>e.jsxs("div",{style:{display:"grid",gridTemplateColumns:"1fr 60px 60px 50px",alignItems:"center",fontSize:11,gap:8,padding:"5px 0",borderTop:s===0?"0":`1px solid ${t.line}`},children:[e.jsx("span",{style:{fontWeight:700,color:t.ink},children:r}),e.jsxs("span",{style:{color:t.muted},children:["R-0",s+1]}),e.jsx("span",{style:{color:s===2?"#E8A33A":t.green,fontWeight:700},children:s===2?"Idle":"On route"}),e.jsxs("span",{style:{textAlign:"right",fontWeight:700,color:t.ink},children:[[98,95,82,99][s],"%"]})]},r))]}),e.jsx("div",{style:{border:`2px dashed ${t.orange}`,background:t.cream,color:t.orange,fontWeight:700,textAlign:"center",padding:28,fontSize:13,borderRadius:10},children:"+ Drop 'Graph' here"})]})]}),z=()=>e.jsxs("div",{style:{display:"grid",gridTemplateColumns:"1.1fr 1fr",height:"100%",gap:14},children:[e.jsx("div",{style:{background:t.soft,borderRadius:12,padding:18,overflow:"hidden"},children:[{label:"Widget title",type:"input",value:"Throughput · last 12 months"},{label:"Chart type",type:"seg",opts:["Bar","Line","Area","Stack"],active:"Bar"},{label:"Series",type:"chips",opts:["This year","Last year","Forecast","Target"],active:["This year","Last year"]},{label:"Refresh",type:"seg",opts:["Off","1m","5m","15m"],active:"5m"},{label:"Width",type:"seg",opts:["¼","½","Full"],active:"Full"}].map(r=>e.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:6,marginBottom:14},children:[e.jsx("label",{style:{fontSize:11,fontWeight:700,color:t.muted,textTransform:"uppercase",letterSpacing:"0.06em"},children:r.label}),r.type==="input"&&e.jsx("div",{style:{background:"#fff",border:`1px solid ${t.orange}`,borderRadius:8,padding:"8px 12px",fontSize:13,color:t.ink,fontWeight:500,display:"flex",alignItems:"center",boxShadow:"0 0 0 3px rgba(241,90,34,0.15)"},children:r.value}),r.type==="seg"&&e.jsx("div",{style:{display:"flex",background:"#fff",border:`1px solid ${t.line}`,borderRadius:8,padding:3},children:(r.opts??[]).map(s=>e.jsx("button",{style:{flex:1,fontSize:11,fontWeight:700,padding:"6px 8px",background:s===r.active?t.ink:"transparent",border:0,borderRadius:6,color:s===r.active?"#fff":t.muted,cursor:"pointer"},children:s},s))}),r.type==="chips"&&e.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6},children:(r.opts??[]).map(s=>{var i,a,l;return e.jsx("span",{style:{fontSize:11,fontWeight:700,padding:"4px 10px",borderRadius:999,background:(i=r.active)!=null&&i.includes(s)?t.orange:"#fff",border:`1px solid ${(a=r.active)!=null&&a.includes(s)?t.orange:t.line}`,color:(l=r.active)!=null&&l.includes(s)?"#fff":"#333"},children:s},s)})})]},r.label))}),e.jsxs("div",{style:{background:"#fff",border:`1px solid ${t.line}`,borderRadius:12,padding:16,display:"flex",flexDirection:"column"},children:[e.jsxs("div",{style:{fontSize:10,fontWeight:700,color:t.muted,textTransform:"uppercase",letterSpacing:"0.08em",marginBottom:12,display:"flex",alignItems:"center",gap:8},children:[e.jsx("span",{style:{width:7,height:7,borderRadius:999,background:t.green,boxShadow:"0 0 0 4px rgba(22,163,74,0.18)",display:"inline-block"}}),"Live preview · real data"]}),e.jsxs("div",{style:{background:t.cream,borderRadius:10,padding:14},children:[e.jsx("div",{style:{fontSize:13,fontWeight:900,color:t.ink,marginBottom:8},children:"Throughput · last 12 months"}),e.jsx("svg",{viewBox:"0 0 280 100",style:{width:"100%",height:90},children:[36,44,30,52,48,60,55,68,62,74,80,88].map((r,s)=>e.jsx("rect",{x:s*22+6,y:100-r,width:"14",height:r,rx:"2",fill:s>9?t.orange:t.ink},s))})]}),e.jsxs("div",{style:{marginTop:12,display:"grid",gridTemplateColumns:"1fr 1fr",gap:8},children:[e.jsxs("div",{style:{background:t.soft,borderRadius:8,padding:10},children:[e.jsx("div",{style:{fontSize:9,color:t.muted,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.06em"},children:"Total YTD"}),e.jsx("div",{style:{fontSize:18,fontWeight:900,color:t.ink,letterSpacing:"-0.02em"},children:"184,420"})]}),e.jsxs("div",{style:{background:t.soft,borderRadius:8,padding:10},children:[e.jsx("div",{style:{fontSize:9,color:t.muted,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.06em"},children:"vs LY"}),e.jsx("div",{style:{fontSize:18,fontWeight:900,color:t.green,letterSpacing:"-0.02em"},children:"+18.2%"})]})]})]})]}),C=()=>e.jsxs("div",{style:{display:"flex",flexDirection:"column",height:"100%"},children:[e.jsx("div",{style:{fontWeight:900,fontSize:16,color:t.ink,marginBottom:6},children:"Connect a data source"}),e.jsx("div",{style:{fontSize:12,color:t.muted,marginBottom:14},children:"9 native adapters. Schemas auto-introspect on connect."}),e.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(4,1fr)",gap:10,marginBottom:16},children:[["#336791","Pg","Postgres",!0],["#00758F","My","MySQL"],["#13AA52","Mo","MongoDB",!0],["#29B5E8","SF","Snowflake"],["#E10098","GQ","GraphQL"],["#1B1B1B","RX","REST"],["#FF9900","S3","Amazon S3"],["#5C2D91","BQ","BigQuery"]].map(([r,s,i,a])=>e.jsxs("div",{style:{background:a?t.cream:"#fff",border:`1.5px solid ${a?t.orange:t.line}`,borderRadius:10,padding:"12px 10px",textAlign:"center",display:"flex",flexDirection:"column",alignItems:"center",gap:6,position:"relative",fontSize:11,fontWeight:700,color:t.ink},children:[a&&e.jsx("span",{style:{position:"absolute",top:6,right:8,width:14,height:14,borderRadius:999,background:t.green,color:"#fff",fontSize:9,fontWeight:900,display:"grid",placeItems:"center"},children:"✓"}),e.jsx("div",{style:{width:32,height:32,borderRadius:8,background:r,display:"grid",placeItems:"center",fontWeight:900,fontSize:14,color:"#fff"},children:s}),i]},i))}),e.jsxs("div",{style:{background:t.ink,color:"#fff",borderRadius:10,padding:16,fontFamily:"IBM Plex Mono, monospace",fontSize:12,lineHeight:1.7,flex:1},children:[e.jsx("div",{children:e.jsx("span",{style:{color:"#6e7681"},children:"// driver_performance · Postgres"})}),e.jsxs("div",{children:[e.jsx("span",{style:{color:"#ff7b72"},children:"select"})," d.id, d.name,"]}),e.jsxs("div",{children:[" ",e.jsx("span",{style:{color:"#d2a8ff"},children:"avg"}),"(r.on_time)::",e.jsx("span",{style:{color:"#ff7b72"},children:"numeric"}),"(",e.jsx("span",{style:{color:"#79c0ff"},children:"5"}),",",e.jsx("span",{style:{color:"#79c0ff"},children:"2"}),") ",e.jsx("span",{style:{color:"#ff7b72"},children:"as"})," rate,"]}),e.jsxs("div",{children:[" ",e.jsx("span",{style:{color:"#d2a8ff"},children:"count"}),"(r.id) ",e.jsx("span",{style:{color:"#ff7b72"},children:"as"})," trips"]}),e.jsxs("div",{children:[e.jsx("span",{style:{color:"#ff7b72"},children:"from"})," drivers d"]}),e.jsxs("div",{children:[e.jsx("span",{style:{color:"#ff7b72"},children:"join"})," routes r ",e.jsx("span",{style:{color:"#ff7b72"},children:"on"})," r.driver_id = d.id"]}),e.jsxs("div",{children:[e.jsx("span",{style:{color:"#ff7b72"},children:"where"})," r.completed_at > ",e.jsx("span",{style:{color:"#a5d6ff"},children:"'2026-04-01'"})]}),e.jsxs("div",{children:[e.jsx("span",{style:{color:"#ff7b72"},children:"group by"})," ",e.jsx("span",{style:{color:"#79c0ff"},children:"1"}),", ",e.jsx("span",{style:{color:"#79c0ff"},children:"2"}),";"]})]})]}),D=()=>e.jsxs("div",{style:{height:"100%",display:"flex",flexDirection:"column",gap:12},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[e.jsx("h4",{style:{fontWeight:900,fontSize:18,color:t.ink,margin:0},children:"Operations · live"}),e.jsxs("span",{style:{fontSize:11,color:t.green,fontWeight:700,display:"flex",alignItems:"center",gap:6},children:[e.jsx("i",{style:{width:7,height:7,background:t.green,borderRadius:999,boxShadow:"0 0 0 4px rgba(22,163,74,0.2)",display:"inline-block"}}),"auto · 5m"]})]}),e.jsxs("div",{style:{display:"grid",gridTemplateColumns:"repeat(4,1fr)",gridAutoRows:80,gap:10,flex:1},children:[[{l:"On-time",v:"94.6%",d:"▲ 2.4",accent:!0},{l:"In transit",v:"1,284",d:"▲ 118"},{l:"Avg idle",v:"18m",d:"▼ 6m"},{l:"Exceptions",v:"7",dark:!0}].map(r=>e.jsxs("div",{style:{background:r.dark?t.ink:r.accent?t.cream:"#fff",border:`1px solid ${r.dark?t.ink:r.accent?"rgba(241,90,34,0.2)":t.line}`,borderRadius:10,padding:12,display:"flex",flexDirection:"column"},children:[e.jsx("div",{style:{fontSize:9,color:r.dark?"rgba(255,255,255,0.5)":t.muted,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.06em"},children:r.l}),e.jsx("div",{style:{fontSize:22,fontWeight:900,color:r.dark?"#fff":t.ink,lineHeight:1,marginTop:4},children:r.v}),r.d&&e.jsx("div",{style:{fontSize:10,color:t.green,fontWeight:700,marginTop:2},children:r.d})]},r.l)),e.jsxs("div",{style:{gridColumn:"span 2",gridRow:"span 2",background:"#fff",border:`1px solid ${t.line}`,borderRadius:10,padding:12},children:[e.jsx("div",{style:{fontSize:9,color:t.muted,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.06em"},children:"Throughput · 12m"}),e.jsx("svg",{viewBox:"0 0 200 90",style:{marginTop:6},children:[24,32,26,40,36,48,44,54,58,64,70,80].map((r,s)=>e.jsx("rect",{x:s*15+6,y:90-r,width:"9",height:r,rx:"1.5",fill:s>9?t.orange:t.ink},s))})]}),e.jsxs("div",{style:{gridColumn:"span 2",gridRow:"span 2",background:"#fff",border:`1px solid ${t.line}`,borderRadius:10,padding:12},children:[e.jsx("div",{style:{fontSize:9,color:t.muted,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.06em"},children:"On-time trend"}),e.jsxs("svg",{viewBox:"0 0 200 90",style:{marginTop:6,width:"100%"},children:[e.jsx("path",{d:"M0 60 L20 50 L40 56 L60 42 L80 46 L100 32 L120 38 L140 22 L160 28 L180 18 L200 12",fill:"none",stroke:t.orange,strokeWidth:"2.4"}),e.jsx("path",{d:"M0 60 L20 50 L40 56 L60 42 L80 46 L100 32 L120 38 L140 22 L160 28 L180 18 L200 12 L200 90 L0 90 Z",fill:t.orange,fillOpacity:"0.12"})]})]})]})]}),F=()=>e.jsxs("div",{style:{height:"100%",display:"flex",flexDirection:"column",gap:14},children:[e.jsx("div",{style:{fontWeight:900,fontSize:18,color:t.ink},children:"Publish · production"}),e.jsx("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:10},children:[{l:"Version",v:"v0.41.2 · just now",dark:!1},{l:"URL",v:"app.acme.com/fleet",dark:!0,code:!0},{l:"Build",v:"3.2s ✓",dark:!0},{l:"Auth",v:"SSO · Okta",dark:!1}].map(r=>e.jsxs("div",{style:{background:r.dark?t.ink:t.soft,borderRadius:12,padding:14},children:[e.jsx("div",{style:{fontSize:10,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.08em",color:r.dark?"rgba(255,255,255,0.5)":t.muted,marginBottom:8},children:r.l}),e.jsx("div",{style:{fontSize:14,fontWeight:700,color:r.dark?"#fff":t.ink},children:r.code?e.jsx("code",{style:{background:"rgba(255,255,255,0.08)",padding:"2px 8px",borderRadius:4,fontFamily:"IBM Plex Mono, monospace",fontSize:11,color:"#ffd9b8"},children:r.v}):r.v})]},r.l))}),e.jsxs("div",{style:{background:"#fff",border:`1px solid ${t.line}`,borderRadius:12,padding:14,flex:1},children:[e.jsx("div",{style:{fontSize:11,fontWeight:700,color:t.muted,textTransform:"uppercase",letterSpacing:"0.08em",marginBottom:6},children:"Roles & permissions"}),[{av:"BO",avBg:t.orange,name:"Brian Olivier",role:"Workspace Admin · all apps",perm:"Admin",permStyle:{background:t.ink,color:"#fff"}},{av:"SH",avBg:t.ink,name:"Sara Han",role:"Operations team",perm:"Editor",permStyle:{background:t.cream,color:t.orange}},{av:"MR",avBg:t.muted,name:"Maria Reyes",role:"Dispatch (East)",perm:"Viewer",permStyle:{background:"#E6F4EC",color:t.green}}].map((r,s)=>e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"8px 0",borderTop:s===0?"0":`1px solid ${t.line}`},children:[e.jsx("div",{style:{width:28,height:28,borderRadius:999,background:r.avBg,display:"grid",placeItems:"center",color:"#fff",fontSize:11,fontWeight:900},children:r.av}),e.jsxs("div",{style:{flex:1},children:[e.jsx("div",{style:{fontSize:12,fontWeight:700,color:t.ink},children:r.name}),e.jsx("div",{style:{fontSize:11,color:t.muted},children:r.role})]}),e.jsx("div",{style:{fontSize:11,fontWeight:700,padding:"4px 10px",borderRadius:999,...r.permStyle},children:r.perm})]},r.name))]})]}),u=[{n:"01",title:"Start with Build, not a blank file.",body:"Every screen begins from one button. Pick a Page for a structured workflow — table, form, detail. Pick a Dashboard to monitor what's happening. Pick up where you left off from Recents.",tags:["Pages","Dashboards","Recents","Templates"],frame:T},{n:"02",title:"Drag in components, not bug tickets.",body:"13 first-class building blocks — data tables, forms, KPIs, graphs, donuts, alerts, file uploads, headers. Drag, drop, snap. Layouts auto-pack so you can't break the grid.",tags:["Data Table","Form","KPI","Graph","Donut","Alert"],frame:R},{n:"03",title:"Configure live, no preview-pane lies.",body:"Every component opens a configurator. Tweak titles, columns, breakpoints, filters, units. The preview re-renders against real data as you type — so what you see in dev is what ships.",tags:["Live preview","Real data","Validation","Conditional logic"],frame:z},{n:"04",title:"Connect anything that has a URL.",body:"Postgres, MySQL, Mongo, REST, GraphQL, Snowflake, S3 — point it, query it, cache it. Bring credentials from your secrets manager, or roll xFramework's vault.",tags:["Postgres","REST","GraphQL","Snowflake","S3"],frame:C},{n:"05",title:"Roll up to dashboards stakeholders won't ignore.",body:"Mix KPIs, charts, donuts, and tables on a true grid. Refresh intervals are per-widget. Filters cascade. Export PNG or PDF. Pin a dashboard to a TV in ops with one URL.",tags:["Auto-refresh","Drilldown","TV mode","Cascading filters"],frame:D},{n:"06",title:"Ship with auth, audit, and rollback for free.",body:"Publish puts your app on a real URL with versioning, role-based access, SSO, and a full audit log. Roll back to any prior version in one click. No infra ticket.",tags:["SSO / SAML","RBAC","Audit log","Versioning"],frame:F}],W=()=>{const[r,s]=f.useState(0),[i,a]=f.useState(0),l=f.useRef([]),g=f.useRef(null);f.useEffect(()=>{const c=new IntersectionObserver(o=>{o.forEach(x=>{if(!x.isIntersecting)return;const h=l.current.findIndex(b=>b===x.target);h!==-1&&s(h)})},{threshold:0,rootMargin:"-30% 0px -45% 0px"});l.current.forEach(o=>o&&c.observe(o));const n=o=>{if(!o||o===document.documentElement)return window;const{overflowY:x}=getComputedStyle(o);return(x==="auto"||x==="scroll")&&o.scrollHeight>o.clientHeight?o:n(o.parentElement)},p=g.current?n(g.current.parentElement):window,m=()=>{if(!g.current)return;const o=window.innerHeight,x=g.current.getBoundingClientRect(),h=x.height-o,b=Math.min(Math.max(-x.top,0),h);a(h>0?b/h:0)};return m(),p.addEventListener("scroll",m,{passive:!0}),window.addEventListener("resize",m),()=>{c.disconnect(),p.removeEventListener("scroll",m),window.removeEventListener("resize",m)}},[]);const y=c=>{var n;(n=l.current[c])==null||n.scrollIntoView({behavior:"smooth",block:"center"})};return e.jsx("section",{ref:g,className:"mt-[140px] px-6 rounded-t-[32px] bg-ca-ink text-white",id:"mp-tour",children:e.jsxs("div",{className:"max-w-[1320px] mx-auto pt-[100px]",children:[e.jsxs("div",{className:"grid gap-[60px] mb-[60px] items-end",style:{gridTemplateColumns:"1fr 1fr"},children:[e.jsxs("div",{children:[e.jsx("div",{className:"text-[12px] font-bold tracking-[0.14em] uppercase text-ca-orange-500 mb-[18px]",children:"The tour · 90 seconds"}),e.jsxs("h2",{className:"font-lato font-black leading-none tracking-[-0.03em] m-0 text-white",style:{fontSize:60},children:["Watch a developer ship an app, ",e.jsx("em",{className:"not-italic text-ca-orange-500",children:"scroll by scroll."})]})]}),e.jsx("p",{className:"text-[18px] font-light leading-relaxed m-0",style:{color:"rgba(255,255,255,0.65)"},children:"Six steps — same path you'll take the first time you sign in. Scroll through to see the framework think."})]}),e.jsxs("div",{className:"relative grid gap-[80px] pb-[100px]",style:{gridTemplateColumns:"1fr 1.25fr"},children:[e.jsx("div",{className:"absolute rounded-full",style:{left:-28,top:100,width:2,height:"calc(100% - 200px)",background:"rgba(255,255,255,0.08)"},children:e.jsx("i",{className:"block w-full rounded-full transition-all duration-200",style:{background:t.orange,height:`${i*100}%`}})}),e.jsx("div",{className:"flex flex-col",children:u.map((c,n)=>e.jsxs("div",{ref:p=>{l.current[n]=p},className:"py-[60px] cursor-pointer transition-opacity duration-[400ms]",style:{borderTop:n===0?"0":"1px solid rgba(255,255,255,0.1)",opacity:r===n?1:.35},onClick:()=>y(n),children:[e.jsxs("div",{className:"font-ibm-mono text-[13px] text-ca-orange-500 tracking-[0.1em] mb-[18px] flex items-center gap-3",children:[e.jsx("span",{children:c.n}),e.jsx("span",{className:"h-px flex-1 relative max-w-[40px]",style:{background:"rgba(255,255,255,0.15)"},children:e.jsx("i",{className:"absolute left-0 top-0 h-full rounded-full transition-all duration-[600ms]",style:{background:t.orange,width:r===n?"100%":"0%"}})}),e.jsxs("span",{style:{color:"rgba(255,255,255,0.4)"},children:[String(n+1).padStart(2,"0")," / ",String(u.length).padStart(2,"0")]})]}),e.jsx("h3",{className:"font-lato font-black leading-[1.05] tracking-[-0.02em] mb-5 mt-0 text-white",style:{fontSize:38},children:c.title}),e.jsx("p",{className:"text-[16px] leading-relaxed font-light mb-5 mt-0 max-w-[460px]",style:{color:"rgba(255,255,255,0.7)"},children:c.body}),e.jsx("div",{className:"flex gap-2 flex-wrap",children:c.tags.map(p=>e.jsx("span",{className:"text-[12px] font-bold px-3 py-[5px] rounded-full whitespace-nowrap",style:{background:"rgba(255,255,255,0.07)",border:"1px solid rgba(255,255,255,0.12)",color:"rgba(255,255,255,0.85)"},children:p},p))})]},n))}),e.jsx("div",{className:"relative",children:e.jsxs("div",{className:"sticky overflow-hidden",style:{top:100,height:580,background:"#fff",borderRadius:18,boxShadow:"0 30px 80px rgba(0,0,0,0.4)",color:t.ink},children:[e.jsxs("div",{className:"flex items-center gap-1.5 h-[38px] px-3.5 border-b",style:{background:t.soft,borderColor:t.line},children:[e.jsx("span",{className:"w-2.5 h-2.5 rounded-full",style:{background:"#DDD"}}),e.jsx("span",{className:"w-2.5 h-2.5 rounded-full",style:{background:"#DDD"}}),e.jsx("span",{className:"w-2.5 h-2.5 rounded-full",style:{background:"#DDD"}}),e.jsxs("span",{className:"ml-3.5 font-ibm-mono text-[11px] bg-white px-3.5 py-1 rounded-full border flex items-center gap-1.5",style:{color:t.muted,borderColor:t.line},children:[e.jsx("i",{className:"w-2.5 h-2.5 rounded-[2px] inline-block bg-ca-orange-500"}),"xframework.app / step ",r+1," — ",u[r].n]})]}),e.jsx("div",{className:"relative overflow-hidden",style:{height:580-38},children:u.map((c,n)=>{const p=c.frame;return e.jsx("div",{className:"absolute inset-0 p-6 pointer-events-none transition-all duration-[400ms]",style:{opacity:r===n?1:0,transform:r===n?"translateY(0)":"translateY(16px)",pointerEvents:r===n?"auto":"none",overflow:"hidden"},children:e.jsx(p,{})},n)})})]})})]})]})})},B=[[["kw","import"],[" ","{ Page, DataTable, KPIRow } "],["kw","from"],[" ",""],["str",'"@xframework/react"'],[" ",";"]],[["kw","import"],[" ","{ db } "],["kw","from"],[" ",""],["str",'"@/lib/db"'],[" ",";"]],[],[["com","// Fleet performance — auto-wires auth, perms, audit"]],[["kw","export default function"],[" ",""],["fn","FleetPage"],[" ","() {"]],[[" "," "],["kw","return"],[" "," ("]],[[" "," <"],["tag","Page"],[" "," "],["att","title"],[" ","="],["str",'"Fleet"'],[" "," "],["att","role"],[" ","="],["str",'"ops.viewer"'],[" ",">"]],[[" "," <"],["tag","KPIRow"],[" "," "],["att","source"],[" ","="],["str",'"sql:fleet_kpis"'],[" "," />"]],[[" "," <"],["tag","DataTable"]],[[" "," "],["att","source"],[" ","="],["str",'"sql:driver_performance"']],[[" "," "],["att","columns"],[" ",'={["Driver", "Route", "Status", "On-time"]}']],[[" "," "],["att","refresh"],[" ","="],["str",'"5m"']],[[" "," />"]],[[" "," </"],["tag","Page"],[" ",">"]],[[" "," );"]],[[" ","}"]]],M={kw:"#ff7b72",str:"#a5d6ff",fn:"#d2a8ff",tag:"#7ee787",att:"#ffa657",com:"#6e7681"},I=()=>e.jsxs("div",{style:{background:"#0F0F0F",border:"1px solid rgba(255,255,255,0.08)",borderRadius:16,overflow:"hidden",fontFamily:"IBM Plex Mono, monospace",fontSize:13},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:10,padding:"12px 16px",borderBottom:"1px solid rgba(255,255,255,0.06)",background:"rgba(255,255,255,0.02)"},children:[e.jsx("span",{style:{width:10,height:10,borderRadius:999,background:"rgba(255,255,255,0.2)"}}),e.jsx("span",{style:{width:10,height:10,borderRadius:999,background:"rgba(255,255,255,0.2)"}}),e.jsx("span",{style:{width:10,height:10,borderRadius:999,background:"rgba(255,255,255,0.2)"}}),e.jsx("span",{style:{fontSize:11,color:"rgba(255,255,255,0.6)",marginLeft:8},children:"app/fleet/page.tsx"}),e.jsx("span",{style:{marginLeft:"auto",fontSize:11,color:"rgba(255,255,255,0.6)",padding:"4px 10px",border:"1px solid rgba(255,255,255,0.1)",borderRadius:6,cursor:"pointer"},children:"copy"})]}),e.jsx("pre",{style:{margin:0,padding:"20px 22px",lineHeight:1.75,color:"#C9D1D9",overflowX:"auto",whiteSpace:"pre"},children:e.jsx("code",{children:B.map((r,s)=>e.jsx("div",{style:{minHeight:"1em"},children:r.length===0?" ":r.map(([i,a],l)=>i===" "?e.jsx("span",{children:a},l):e.jsx("span",{style:{color:M[i]??"inherit"},children:a},l))},s))})})]}),P=[{icon:"git",title:"Code-first or no-code, your call",body:"Build in the visual editor and eject to TSX whenever you outgrow it. The artifacts are real React components — no proprietary AST."},{icon:"plug",title:"SDK + adapters in one install",body:e.jsx(e.Fragment,{children:"npm i @xframework/react ships the React SDK, CLI, and adapters for Postgres, REST, GraphQL and Snowflake."})},{icon:"shield",title:"Auth & perms at the prop level",body:'Gate any component or column with role="…". RBAC, SSO, audit log are wired automatically.'},{icon:"rocket",title:"Self-host or cloud",body:"Run xFramework Cloud, or pull the Docker image and put it behind your own load balancer. Same SDK, same APIs, same dashboard."}],A=()=>e.jsx("section",{className:"bg-ca-ink text-white ounded-b-[32px]",style:{padding:"100px 40px 110px"},id:"mp-developers",children:e.jsxs("div",{className:"max-w-[1320px] mx-auto",children:[e.jsxs("div",{className:"mb-[60px] max-w-[720px]",children:[e.jsx("div",{className:"text-[12px] font-bold tracking-[0.14em] uppercase text-ca-orange-500 mb-[18px]",children:"For developers"}),e.jsx("h2",{className:"font-lato font-black leading-[1.02] tracking-[-0.03em] m-0 text-white",style:{fontSize:56},children:"Drop xFramework into the codebase you already have."})]}),e.jsxs("div",{className:"grid gap-10",style:{gridTemplateColumns:"1.05fr 1fr"},children:[e.jsx(I,{}),e.jsx("div",{className:"flex flex-col gap-7",children:P.map(r=>e.jsxs("div",{className:"flex gap-4",children:[e.jsx("div",{className:"w-[38px] h-[38px] rounded-[10px] grid place-items-center flex-shrink-0 text-ca-orange-500",style:{background:"rgba(241,90,34,0.16)"},children:e.jsx(d,{name:r.icon,size:18})}),e.jsxs("div",{children:[e.jsx("h4",{className:"font-lato font-black text-[18px] text-white mb-1.5 mt-0",children:r.title}),e.jsx("p",{className:"text-[14px] leading-relaxed m-0",style:{color:"rgba(255,255,255,0.65)"},children:r.body})]})]},r.title))})]})]})}),E=[{num:"~4×",label:"Faster to ship",sub:"Median first-app time vs. building from scratch"},{num:"13",label:"Native components",sub:"Tables, forms, KPIs, charts and more — no NPM hunt"},{num:"9",label:"Data adapters",sub:"Postgres, MySQL, Mongo, Snowflake, REST, GraphQL…"},{num:"99.95%",label:"Cloud uptime",sub:"Last 12 months · multi-region failover"}],O=()=>e.jsx("section",{className:"py-[100px] px-10",children:e.jsx("div",{className:"max-w-[1320px] mx-auto grid grid-cols-4 border-t border-b border-ca-slate-100",style:{gap:0},children:E.map((r,s)=>e.jsxs("div",{className:"py-10 px-8",style:{borderRight:s<3?`1px solid ${t.line}`:"0"},children:[e.jsx("div",{className:"font-lato font-black leading-none tracking-[-0.03em] text-ca-ink",style:{fontSize:56},children:r.num}),e.jsx("div",{className:"text-[14px] font-bold text-ca-ink mt-3.5",children:r.label}),e.jsx("div",{className:"text-[13px] font-light text-ca-slate-500 mt-1",children:r.sub})]},r.label))})}),H=({onCta:r})=>e.jsxs("section",{className:"mx-6 mb-7 px-10 rounded-[32px] relative overflow-hidden",style:{background:t.cream,padding:"90px 40px"},children:[e.jsx("div",{className:"absolute pointer-events-none",style:{right:-120,bottom:-120,width:380,height:380,background:"radial-gradient(circle, rgba(241,90,34,0.3), transparent 70%)"}}),e.jsxs("div",{className:"relative max-w-[1320px] mx-auto grid gap-[60px] items-center",style:{gridTemplateColumns:"1fr 1fr"},children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-lato font-black leading-none tracking-[-0.03em] text-ca-ink mb-6 mt-0",style:{fontSize:64},children:"Stop hand-rolling internal tools."}),e.jsx("p",{className:"text-[18px] text-ca-slate-500 font-light leading-relaxed mb-8 mt-0",children:"Spin up a free workspace, point it at your DB, and have a real app on a real URL before lunch. Your future self — and your roadmap — will thank you."}),e.jsxs("div",{className:"flex gap-3.5 flex-wrap",children:[e.jsxs("button",{className:"inline-flex items-center gap-2.5 font-lato font-bold text-[16px] px-7 py-4 rounded-full border-0 cursor-pointer text-white bg-ca-orange-500 hover:bg-ca-orange-600 transition-all duration-200 active:scale-[0.98]",onClick:r,children:["Start building free ",e.jsx(d,{name:"arrow",size:16,stroke:2.4})]}),e.jsx("a",{href:"#mp-tour",className:"inline-flex items-center gap-2.5 font-lato font-bold text-[16px] px-7 py-4 rounded-full border border-ca-slate-100 text-ca-ink no-underline hover:border-ca-ink transition-all duration-200",children:"Re-watch the tour"})]})]}),e.jsx("div",{className:"flex flex-col gap-3.5 p-7 rounded-[18px]",style:{background:"rgba(255,255,255,0.6)",backdropFilter:"blur(8px)"},children:[{icon:"check",title:"Free forever",body:"for personal & OSS — 3 apps, unlimited views."},{icon:"lock",title:"SOC 2 Type II",body:"GDPR & HIPAA-ready. Self-host for air-gap."},{icon:"users",title:"Migration support",body:"from Retool, Appsmith & Tooljet on team plans."}].map(s=>e.jsxs("div",{className:"flex items-center gap-3 text-[14px]",children:[e.jsx("div",{className:"w-7 h-7 bg-ca-orange-500 text-white rounded-[8px] grid place-items-center flex-shrink-0",children:e.jsx(d,{name:s.icon,size:14})}),e.jsxs("div",{children:[e.jsx("b",{className:"text-ca-ink",children:s.title})," ",s.body]})]},s.title))})]})]}),$=[{title:"Product",links:["Tour","Why xFramework","For developers","Pricing","Changelog"]},{title:"Developers",links:["Documentation","SDK reference","CLI","Templates","GitHub"]},{title:"Company",links:["About","Customers","Blog","Careers","Contact"]},{title:"Trust",links:["Security","SOC 2 / GDPR","Status","Terms","Privacy"]}],G=()=>e.jsxs("footer",{className:"bg-ca-ink",style:{padding:"60px 40px 32px"},children:[e.jsxs("div",{className:"max-w-[1320px] mx-auto",style:{display:"grid",gridTemplateColumns:"1.4fr 1fr 1fr 1fr 1fr",gap:40},children:[e.jsxs("div",{children:[e.jsx("div",{className:"mb-4",children:e.jsx(v,{type:"full",mode:"dark",logoWidth:140})}),e.jsx("p",{style:{fontSize:14,color:"rgba(255,255,255,0.6)",lineHeight:1.55,margin:0},children:"The internal-app framework for software teams. Build, theme, ship — without burning a sprint."})]}),$.map(r=>e.jsxs("div",{children:[e.jsx("h5",{style:{fontSize:12,fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:"rgba(255,255,255,0.5)",margin:"0 0 16px"},children:r.title}),r.links.map(s=>e.jsx("a",{href:"#",style:{display:"block",fontSize:14,color:"rgba(255,255,255,0.85)",textDecoration:"none",padding:"4px 0"},onMouseEnter:i=>i.currentTarget.style.color=t.orange,onMouseLeave:i=>i.currentTarget.style.color="rgba(255,255,255,0.85)",children:s},s))]},r.title))]}),e.jsxs("div",{className:"max-w-[1320px] mx-auto mt-[50px] pt-6 flex justify-between items-center",style:{borderTop:"1px solid rgba(255,255,255,0.1)",fontSize:13,color:"rgba(255,255,255,0.5)"},children:[e.jsx("span",{children:"© 2026 xFramework, Inc."}),e.jsx("span",{children:"Made for the people who get pinged at midnight."})]})]}),V=()=>e.jsx("style",{children:`
|
|
2
|
-
@keyframes mpFloatA { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-8px)} }
|
|
3
|
-
@keyframes mpFloatB { 0%,100%{transform:translateY(0)} 50%{transform:translateY(10px)} }
|
|
4
|
-
`}),te=()=>{const r=j(),s=()=>r("/build/page-builder");return e.jsxs("div",{className:"font-lato font-light text-ca-slate-700 bg-white",children:[e.jsx(V,{}),e.jsx(w,{onCta:s}),e.jsx(S,{}),e.jsx(L,{}),e.jsx(W,{}),e.jsx(A,{}),e.jsx(O,{}),e.jsx(H,{onCta:s}),e.jsx(G,{})]})};export{te as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./vendor-mui-69397583.js";import{aL as v,I as R,W as A,Y as E,l as _,B,O as D,Q as q,d3 as J,d4 as W,F as K,E as Z}from"./index-c62ac197.js";import{c as U,r as d,f as ee}from"./vendor-react-ece1c85f.js";import{g as P,a as se}from"./index-ea125a16.js";import{r as Q,u as te,g as X}from"./index-cbc29fa8.js";import{c as ne,a as ae}from"./vendor-redux-a1f00e6b.js";import{a as w,F as oe}from"./FormContainer-91c2b0e4.js";import{h as le}from"./index-36ba4ea7.js";import{S as ie}from"./StickyFooter-5b934274.js";import{d as C,a as $,c as re,k as ce,F as de,b as ue}from"./index.esm-70ab539c.js";import{A as me}from"./AdaptableCard-df7695d6.js";import{a as pe}from"./index-e4c6057f.js";import{V,i as he}from"./validationPatterns-77446c46.js";import{u as fe,r as xe,g as be}from"./index-8ab45286.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import"./index-c2088808.js";import"./Drawer-949c18c6.js";import"./Switcher-c8648037.js";import"./index-36228db5.js";import"./Upload-fb34ce03.js";import{D as ge}from"./DoubleSidedImage-ae98733b.js";import{l as je}from"./lodash-306e3f66.js";const ye=({field:n,form:c,label:r})=>{const[x,b]=U.useState(!1),[u,I]=U.useState(""),t=n.value,h=t?v[t]:null,L=Object.keys(v).filter(m=>m.toLowerCase().includes(u.toLowerCase()));return e.jsxs("div",{className:"relative",children:[r&&e.jsx("span",{className:"text-sm font-medium text-gray-700",children:r}),e.jsx("button",{type:"button",className:"w-12 h-11 border rounded-lg flex items-center justify-center bg-white hover:bg-gray-50",onClick:()=>b(m=>!m),children:h?e.jsx(h,{size:20}):e.jsx("span",{className:"text-gray-400 text-lg",children:"+"})}),x&&e.jsxs("div",{className:"absolute top-full mt-2 z-50 p-2 bg-white border rounded shadow-lg w-64",children:[e.jsx("input",{type:"text",placeholder:"Search icon...",className:"px-2 py-1 mb-2 w-full border rounded",value:u,onChange:m=>I(m.target.value)}),e.jsx("div",{className:"grid grid-cols-6 gap-2 max-h-48 overflow-y-auto",children:L.map(m=>{const o=v[m];return e.jsx("button",{type:"button",className:`p-2 border rounded hover:bg-gray-100 ${t===m?"bg-blue-100 border-blue-400":""}`,title:m,onClick:()=>{c.setFieldValue(n.name,m),b(!1),I("")},children:e.jsx(o,{size:18})},m)})})]})]})},Ie=n=>{const{touched:c,errors:r,type:x,menuList:b,DYNAMIC_GRID_OPTIONS:u,LAYOUT_OPTIONS:I,values:t,setFieldValue:h}=n,[L,m]=d.useState(null),[o,p]=d.useState(null),g=[...b.map(a=>({value:a.id,label:a.name})),{value:"",label:"Select Parent"}].reverse(),M=a=>(a||"").trim().toLowerCase().replace(/[^a-z0-9\s-]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-"),f=d.useMemo(()=>{const a=t==null?void 0:t.parentId,i=(a==null?void 0:a.value)??a??"";if(!i)return"";const y=b.find(F=>F.id===i||F.id===((a==null?void 0:a.value)??a));return y?M(y.name):""},[t==null?void 0:t.parentId,b]),k=d.useMemo(()=>{if(x==="new"){const a=M(t==null?void 0:t.menuName);return a?f?`/${f}/${a}`:`/${a}`:""}},[t==null?void 0:t.menuName,f]),[s,l]=d.useState(!1);d.useEffect(()=>{!s&&x==="new"&&h("routeLink",k)},[k,s]);const j=a=>{const i=a;l(!(!i||i===k)),h("routeLink",i)},S=()=>{if(x==="new"){const a=(t==null?void 0:t.routeLink)||"",i=M(a.replace(/^\//,"")),y=i?i.startsWith("/")?i:`/${i}`:"";h("routeLink",y),l(y!==k)}},N=a=>{var y;const i=((y=a.target.files)==null?void 0:y[0])??null;if(m(i),h("moduleIcon",i),i){const F=URL.createObjectURL(i);p(F)}else p(null)},T=()=>{o&&URL.revokeObjectURL(o),m(null),p(null)};return d.useEffect(()=>()=>{o&&URL.revokeObjectURL(o)},[o]),e.jsxs(me,{className:"mb-8",children:[e.jsxs("div",{className:"flex gap-2 items-end",children:[e.jsx(w,{asterisk:!0,label:"Icon",className:"w-13",invalid:r.icon&&c.icon,errorMessage:r.icon,children:e.jsx(C,{name:"icon",component:ye})}),e.jsx(w,{asterisk:!0,label:"Menu Name",className:"flex-1",invalid:r.menuName&&c.menuName,errorMessage:r.menuName,children:e.jsx(C,{type:"text",name:"menuName",placeholder:"Menu Name",component:R})})]}),e.jsx(w,{label:"Parent Menu",children:e.jsx(C,{name:"parentId",children:({field:a,form:i})=>e.jsx(A,{field:a,form:i,options:g,name:"parentId",isClearable:!0,onChange:y=>{i.setFieldValue(a.name,y)}})})}),e.jsx(w,{asterisk:!0,label:"Description",invalid:r.description&&c.description,errorMessage:r.description,children:e.jsx(C,{type:"text",autoComplete:"off",name:"description",placeholder:"Description",component:R})}),e.jsx(w,{label:"Route Link",children:e.jsx(C,{name:"routeLink",children:()=>e.jsx(e.Fragment,{children:e.jsx(R,{name:"routeLink",value:(t==null?void 0:t.routeLink)??"",placeholder:k||"/route-link",onChange:a=>j(a.target.value),onBlur:S})})})}),!t.layoutId&&e.jsx(w,{label:"Dynamic Grid",children:e.jsx(C,{name:"dynamicTableId",children:({field:a,form:i})=>e.jsx(A,{isClearable:!0,field:a,form:i,options:u||[],name:"dynamicTableId",onChange:y=>{i.setFieldValue(a.name,y)}})})}),!t.dynamicTableId&&e.jsx(w,{label:"Layout",children:e.jsx(C,{name:"layoutId",children:({field:a,form:i})=>e.jsx(A,{isClearable:!0,field:a,form:i,options:I||[],name:"layoutId",onChange:y=>{i.setFieldValue(a.name,y)}})})}),e.jsx(w,{label:"Sequence",invalid:r.sequence&&c.sequence,errorMessage:r.sequence,children:e.jsx(C,{type:"number",autoComplete:"off",name:"sequence",min:"0",placeholder:"0",component:R})}),e.jsx("label",{className:"flex items-center space-x-2 ",style:{fontSize:"22px",paddingBottom:"10px",color:"black"},children:"Module Configuration"}),e.jsxs("div",{className:"grid grid-cols-12 gap-1 pt-2 ",style:{paddingBottom:"15px"},children:[e.jsx("div",{className:"md:col-span-6 col-span-1",children:e.jsxs("label",{className:"flex items-center space-x-2",children:[e.jsx("input",{type:"checkbox",name:"isModule",checked:t.isModule,onChange:a=>{h("isModule",a.target.checked),console.log("isModule",a.target.checked)}}),e.jsx("span",{children:"Is Module"})]})}),e.jsx("div",{className:"md:col-span-6 col-span-1",children:e.jsxs("label",{className:"flex items-center space-x-2",children:[e.jsx("input",{type:"checkbox",name:"isDeletable",checked:t.isDeletable,onChange:a=>{h("isDeletable",a.target.checked),console.log("isDeletable",a.target.checked)}}),e.jsx("span",{children:"Is Uninstallable"})]})})]}),e.jsx(w,{label:"Module Description ",invalid:r.moduleDescription&&c.moduleDescription,errorMessage:r.moduleDescription,children:e.jsx(C,{as:"textarea",name:"moduleDescription",rows:5,className:"form-control text-area",style:{width:"100%",fontFamily:"monospace",border:"1px solid #ccc",padding:"10px",boxSizing:"border-box"}})}),e.jsx(w,{label:"Module Icon ",invalid:r.moduleIcon&&c.moduleIcon,errorMessage:r.moduleIcon,className:"mb-24",children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx("input",{type:"file",accept:"image/*",onChange:N}),o&&e.jsxs("div",{className:"relative w-40 h-40",children:[e.jsx("img",{src:o,alt:"Preview",className:"w-40 h-40 object-cover rounded"}),e.jsx("button",{type:"button",onClick:T,className:"absolute top-1 right-1 bg-black/60 text-white rounded-full w-6 h-6 flex items-center justify-center hover:bg-black",children:"×"})]})]})})]})};E("layouts",xe);const{useUniqueId:Ne}=le,Y=$().matches(V.sqlInjectionSafe,"Invalid input: SQL keywords not allowed").matches(V.noSpecialChars,"Special characters like < > = { } are not allowed").test("no-base64","Base64 encoded content is not allowed",n=>n?!he(n.trim()):!0),ke=re().shape({menuName:Y.required("Menu Name Required").max(50,"Menu name must be 50 characters or less"),description:Y.required("Description Required").max(255,"Description must be 255 characters or less"),icon:$().required("Req."),routeLink:$().max(100,"Route Link must be 100 characters or less"),sequence:ce().required("Sequence Required").max(999999999,"Sequence must not exceed 9 digits")}),z=d.forwardRef((n,c)=>{const{layoutList:r}=fe(f=>f.layouts.data);console.log("layoutList",r);const x=_(),{type:b,footerWidth:u,initialData:I={id:"",menuName:"",description:"",routeLink:"",sequence:0,parentId:"",dynamicTableId:"",portal:"",isModule:!1,isDeletable:!1,moduleDescription:"",icon:"",moduleIcon:null},onFormSubmit:t,onDiscard:h,onDelete:L,menuList:m,DYNAMIC_GRID_OPTIONS:o}=n,p=()=>{x(be())};d.useEffect(()=>{p()},[]);const g=r.map(f=>({value:f.id,label:f.layoutName})),M=Ne("Role-");return e.jsx(e.Fragment,{children:e.jsx(de,{innerRef:c,initialValues:{...I},validationSchema:ke,onSubmit:(f,{setSubmitting:k})=>{const s=f;b==="new"&&(s.menuId=M),t==null||t(s,k)},children:({values:f,touched:k,errors:s,isSubmitting:l,setFieldValue:j})=>e.jsx(ue,{children:e.jsxs(oe,{children:[e.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-1 gap-4",children:e.jsx("div",{className:"lg:col-span-2",children:e.jsx(Ie,{type:b,touched:k,errors:s,menuList:m,DYNAMIC_GRID_OPTIONS:o,LAYOUT_OPTIONS:g,values:f,setFieldValue:j})})}),e.jsx(ie,{className:`px-8 flex items-center justify-between py-4 ${u?`md:${u}`:""}`,stickyClass:"bg-white dark:bg-gray-800 border-gray-200 dark:border-gray-700",children:e.jsxs("div",{className:"flex items-center justify-between w-full",children:[e.jsx(B,{size:"sm",className:"ltr:mr-3 rtl:ml-3",type:"button",onClick:()=>h==null?void 0:h(),children:"Discard"}),e.jsx(B,{size:"sm",variant:"solid",loading:l,icon:e.jsx(pe,{}),type:"submit",children:"Save"})]})})]})})})})});z.displayName="MenuForm";E("dynamicTableList",Q);const Je=n=>{const{menuList:c,onDrawerClose:r,onAddNewSuccess:x,footerWidth:b}=n,{dynamicTableList:u}=te(o=>{var p;return(p=o==null?void 0:o.dynamicTableList)==null?void 0:p.data});ee(),d.useState(!1);const I=_(),t=async o=>{var p;try{return await J(o)}catch(g){return(p=g==null?void 0:g.response)==null?void 0:p.data}},h=u.map(o=>({value:o.id,label:o.tableName})),L=async(o,p)=>{var f;const g={menuName:o.menuName??"",description:o.description??"",sequence:o.sequence??0,parentId:o.parentId.value??null,routeLink:o.routeLink??"",dynamicTableId:((f=o==null?void 0:o.dynamicTableId)==null?void 0:f.value)??null,portal:"default",isModule:o.isModule??!1,isUnInstallable:o.isDeletable??!1,moduleDescription:o.moduleDescription??"",icon:o.icon??"",moduleIcon:o.moduleIcon??""};console.log("newMenuData",g);const M=await t(g);M.success?(I(P()),x(),D.push(e.jsx(q,{title:"Success",type:"success",duration:2500,children:"Menu Successfully Added"}),{placement:"top-center"})):D.push(e.jsx(q,{title:"Error",type:"danger",duration:2500,children:M.message}),{placement:"top-center"})},m=()=>{r()};return d.useEffect(()=>{I(X({}))},[]),e.jsx(e.Fragment,{children:e.jsx(z,{type:"new",footerWidth:b,footerWidth:b,onFormSubmit:L,onDiscard:m,menuList:c,DYNAMIC_GRID_OPTIONS:h})})},Me="MenuEditState",Ke=async n=>(await W(n)).success,Se={loading:!1,menuData:{menuId:"",menuName:"",portal:"",description:"",routeLink:"",sequence:"",parentId:"",isModule:"",isUnInstallable:"",moduleDescription:""}},H=ne({name:`${Me}/state`,initialState:Se,reducers:{setLoading:(n,c)=>{n.loading=c.payload}}}),{setLoading:O}=H.actions,we=H.reducer,Le=ae({data:we}),G=K;E("MenuEditState",Le);E("dynamicTableList",Q);const Ze=({menuData:n,onDrawerClose:c,menuList:r=[],onUpdateSuccess:x,footerWidth:b})=>{const u=_(),I=G(s=>{var l,j;return(j=(l=s.MenuEditState)==null?void 0:l.data)==null?void 0:j.loading}),t=G(s=>{var l,j,S;return((j=(l=s==null?void 0:s.dynamicTableList)==null?void 0:l.data)==null?void 0:j.dynamicTableList)??((S=s==null?void 0:s.dynamicTableList)==null?void 0:S.data)??[]}),[h,L]=d.useState(null),m=d.useMemo(()=>(t==null?void 0:t.map(s=>({value:s.id,label:s.tableName})))??[],[t]),o=d.useCallback((s,l="Success")=>{D.push(e.jsxs(q,{title:l,type:"success",duration:2500,children:["Menu successfully ",s]}),{placement:"top-center"})},[]),p=d.useCallback((s="Something went wrong")=>{D.push(e.jsx(q,{title:"Error",type:"danger",duration:3500,children:s}),{placement:"top-center"})},[]);console.log("menuDetails",h);const g=d.useCallback(()=>{var S;if(!n){L(null);return}const s=r.find(N=>N.id===n.parentId),l=t==null?void 0:t.find(N=>N.id===n.dynamicTableId),j={menuName:n.name??"",menuId:n.id??"",sequence:n.sequence??0,routeLink:n.routeLink??"",parentId:s?{value:s.id,label:s.name}:{value:"",label:""},description:n.description??"",dynamicTableId:l?{value:l==null?void 0:l.id,label:l==null?void 0:l.tableName}:{},portal:"default",layoutId:n.layout?{value:n.layoutId,label:(S=n.layout)==null?void 0:S.layoutName}:null,icon:n.icon??"",isModule:n.isModule??!1,isDeletable:n.isDeletable??!1,moduleDescription:n.moduleDescription??"",moduleIcon:void 0};L(j)},[n,r,t]);d.useEffect(()=>{u(O(!0)),u(X({}))},[u]),d.useEffect(()=>{if(!n){L(null),u(O(!1));return}(!je.isEmpty(t)||n.dynamicTableId==null)&&(g(),u(O(!1)))},[n,t,g,u]);const M=d.useCallback(async(s,l)=>{var j,S;l(!0);try{const N={menuName:s.menuName??"",menuId:s.menuId??"",description:s.description??"",sequence:s.sequence??0,routeLink:s.routeLink??"",dynamicTableId:((j=s==null?void 0:s.dynamicTableId)==null?void 0:j.value)??null,icon:s.icon??"",parentId:(S=s==null?void 0:s.parentId)!=null&&S.value&&s.parentId.value!==""?s.parentId.value:null,portal:"default",isModule:s.isModule??!1,isUnInstallable:s.isDeletable??!1,moduleDescription:s.moduleDescription??"",moduleIcon:s.moduleIcon??void 0};console.log("handleFormSubmit - values",N);const T=await se(N);l(!1),T?(o("updated"),u(P()),c(),x==null||x()):p("Failed to update the menu.")}catch(N){l(!1),p((N==null?void 0:N.message)??"Failed to update the menu.")}},[u,c,x,p,o]),f=d.useCallback(()=>{c()},[c]),k=d.useCallback(async s=>{try{if(s(!1),!(n!=null&&n.id)){p("No menu selected for deletion.");return}await W(n.id)?(o("deleted"),u(P()),c()):p("Failed to delete the menu.")}catch(l){p((l==null?void 0:l.message)??"Failed to delete the menu.")}},[u,n,c,p,o]);return e.jsx(Z,{loading:I,children:h?e.jsx(z,{type:"edit",footerWidth:b,initialData:h,menuList:r,DYNAMIC_GRID_OPTIONS:m,onFormSubmit:M,onDiscard:f,onDelete:k}):!I&&e.jsxs("div",{className:"h-full flex flex-col items-center justify-center",children:[e.jsx(ge,{src:"/img/others/img-2.png",darkModeSrc:"/img/others/img-2-dark.png",alt:"No menu found!"}),e.jsx("h3",{className:"mt-8",children:"No menu found!"})]})})};export{Ze as M,Je as a,Ke as d};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import{j as d}from"./vendor-mui-69397583.js";import{F as Be,A as ge,dI as Ge,dJ as Ve,dK as Qe,dL as Ze,Y as Je,a5 as Ke,l as Xe,I as Ye,cJ as en,B as ye,dM as nn}from"./index-c62ac197.js";import{r as B,u as tn}from"./vendor-react-ece1c85f.js";import{a as rn}from"./index-42e65911.js";import{u as sn}from"./useDeviceCheck-920641a5.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import"./index-c2088808.js";import"./Drawer-949c18c6.js";import"./FormContainer-91c2b0e4.js";import"./Switcher-c8648037.js";import"./index-36228db5.js";import"./Upload-fb34ce03.js";import{b as pe,c as ln,a as an}from"./vendor-redux-a1f00e6b.js";import{f as on,g as cn}from"./BrainServices-a4bb698e.js";import{c as un}from"./index-f6be0390.js";const dn={messages:[],loading:!1,error:null,isChatDialog:!1,file:null,fileType:"",fileName:"",documentId:null,uId:null},re=pe("brain/askQuestion",async(n,t)=>{var r,a;try{const o=t.getState(),f=(a=(r=o==null?void 0:o.aiChat)==null?void 0:r.data)==null?void 0:a.uId,m=n==null?void 0:n.ipAddress,p=n==null?void 0:n.message;return console.log(o==null?void 0:o.aiChat),(await on(f,m,p)).data}catch{return t.rejectWithValue("Error occurred while asking the question")}}),se=pe("brain/apiUploadAndAsk",async({file:n,message:t},r)=>{try{return(await cn(n,t)).data.questionAnswer}catch{return r.rejectWithValue("Error occurred while asking the question")}}),ie=pe("brain/apiQueryDocument",async(n,t)=>{var m,p,l,k,w,C;const r=t.getState();let a=typeof((p=(m=r.aiChat)==null?void 0:m.data)==null?void 0:p.file)=="string";const o=JSON.stringify({fileUrl:(k=(l=r.aiChat)==null?void 0:l.data)==null?void 0:k.file,aiProvider:"Gemini",customPrompt:n==null?void 0:n.question,enableStreaming:!1,maxTokens:1e4,temperature:.5,uploadInputFile:!1,uploadProcessedResult:!1}),f={Authorization:"Bearer sample-user-key-456"};a&&(f["Content-Type"]="application/json");try{const x=new FormData;x.append("File",(C=(w=r.aiChat)==null?void 0:w.data)==null?void 0:C.file),x.append("AiProvider","Gemini"),x.append("CustomPrompt",n==null?void 0:n.question),x.append("EnableStreaming","false"),x.append("Temperature","0.5");const N=await(await fetch(`/api/ImageProcessing/${a?"process-remote-url":"process-remote-upload"}?trackOperation=false`,{method:"POST",headers:f,body:a?o:x})).json();return{content:(N==null?void 0:N.content)||"Please try again",file:N==null?void 0:N.inputFileDownloadUrl}}catch{return t.rejectWithValue("Error occurred while asking the question")}}),ze=ln({name:"brain",initialState:dn,reducers:{resetState:n=>{n.messages=[],n.loading=!1,n.error=null,n.isChatDialog=!1,n.file=null,n.fileType="",n.fileName="",n.documentId=null,n.uId=null},toggleChatDialog:(n,t)=>{n.isChatDialog=t.payload},handleFile:(n,t)=>{const{file:r,fileType:a,fileName:o}=t.payload;n.file=r,n.fileType=a,n.fileName=o},handleDocumentId:(n,t)=>{n.documentId=t.payload}},extraReducers:n=>{n.addCase(re.pending,t=>{t.loading=!0,t.error=null}).addCase(re.fulfilled,(t,r)=>{var a,o,f;console.log("action",r),t.loading=!1,t.uId=(a=r==null?void 0:r.payload)==null?void 0:a.uid,t.messages.push({question:r.meta.arg.message?r.meta.arg.message:r.meta.arg,response:((o=r==null?void 0:r.payload)==null?void 0:o.response)||((f=r==null?void 0:r.payload)==null?void 0:f.answer)||""})}).addCase(re.rejected,(t,r)=>{t.loading=!1,t.error=r.payload}).addCase(se.pending,t=>{t.loading=!0,t.error=null}).addCase(se.fulfilled,(t,r)=>{console.log("action",r),t.loading=!1,t.messages.push({question:r.meta.arg.message,response:r.payload})}).addCase(se.rejected,(t,r)=>{t.loading=!1,t.error=r.payload}).addCase(ie.pending,t=>{t.loading=!0,t.error=null}).addCase(ie.fulfilled,(t,r)=>{var a,o,f;t.loading=!1,(a=r.payload)!=null&&a.file&&(t.file=(o=r.payload)==null?void 0:o.file),t.messages.push({question:r.meta.arg.question,response:(f=r.payload)==null?void 0:f.content})}).addCase(ie.rejected,(t,r)=>{t.loading=!1,t.error=r.payload})}}),{resetState:pn,toggleChatDialog:Pt,handleFile:_t,handleDocumentId:qt}=ze.actions,fn=ze.reducer,mn=an({data:fn}),J=Be;function L(){return L=Object.assign?Object.assign.bind():function(n){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(n[a]=r[a])}return n},L.apply(this,arguments)}const hn=["children","options"],xe=["allowFullScreen","allowTransparency","autoComplete","autoFocus","autoPlay","cellPadding","cellSpacing","charSet","classId","colSpan","contentEditable","contextMenu","crossOrigin","encType","formAction","formEncType","formMethod","formNoValidate","formTarget","frameBorder","hrefLang","inputMode","keyParams","keyType","marginHeight","marginWidth","maxLength","mediaGroup","minLength","noValidate","radioGroup","readOnly","rowSpan","spellCheck","srcDoc","srcLang","srcSet","tabIndex","useMap"].reduce((n,t)=>(n[t.toLowerCase()]=t,n),{class:"className",for:"htmlFor"}),be={amp:"&",apos:"'",gt:">",lt:"<",nbsp:" ",quot:"“"},gn=["style","script","pre"],yn=["src","href","data","formAction","srcDoc","action"],xn=/([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi,bn=/\n{2,}$/,ke=/^(\s*>[\s\S]*?)(?=\n\n|$)/,kn=/^ *> ?/gm,vn=/^(?:\[!([^\]]*)\]\n)?([\s\S]*)/,jn=/^ {2,}\n/,wn=/^(?:([-*_])( *\1){2,}) *(?:\n *)+\n/,ve=/^(?: {1,3})?(`{3,}|~{3,}) *(\S+)? *([^\n]*?)?\n([\s\S]*?)(?:\1\n?|$)/,je=/^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/,Cn=/^(`+)((?:\\`|(?!\1)`|[^`])+)\1/,Nn=/^(?:\n *)*\n/,An=/\r\n?/g,Sn=/^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/,$n=/^\[\^([^\]]+)]/,On=/\f/g,Tn=/^---[ \t]*\n(.|\n)*\n---[ \t]*\n/,En=/^\s*?\[(x|\s)\]/,we=/^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,Ce=/^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,Ne=/^([^\n]+)\n *(=|-)\2{2,} *\n/,le=/^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i,In=/&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi,Ae=/^<!--[\s\S]*?(?:-->)/,Rn=/^(data|aria|x)-[a-z_][a-z\d_.-]*$/,ae=/^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i,zn=/^\{.*\}$/,Dn=/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,Mn=/^<([^ >]+[:@\/][^ >]+)>/,Fn=/-([a-z])?/gi,Se=/^(\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/,Ln=/^[^\n]+(?: \n|\n{2,})/,Pn=/^\[([^\]]*)\]:\s+<?([^\s>]+)>?\s*("([^"]*)")?/,_n=/^!\[([^\]]*)\] ?\[([^\]]*)\]/,qn=/^\[([^\]]*)\] ?\[([^\]]*)\]/,Un=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/,Hn=/\t/g,Wn=/(^ *\||\| *$)/g,Bn=/^ *:-+: *$/,Gn=/^ *:-+ *$/,Vn=/^ *-+: *$/,Y=n=>`(?=[\\s\\S]+?\\1${n?"\\1":""})`,ee="((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|\\\\\\1|[\\s\\S])+?)",Qn=RegExp(`^([*_])\\1${Y(1)}${ee}\\1\\1(?!\\1)`),Zn=RegExp(`^([*_])${Y(0)}${ee}\\1(?!\\1)`),Jn=RegExp(`^(==)${Y(0)}${ee}\\1`),Kn=RegExp(`^(~~)${Y(0)}${ee}\\1`),Xn=/^(:[a-zA-Z0-9-_]+:)/,Yn=/^\\([^0-9A-Za-z\s])/,et=/\\([^0-9A-Za-z\s])/g,nt=/^[\s\S](?:(?! \n|[0-9]\.|http)[^=*_~\-\n:<`\\\[!])*/,tt=/^\n+/,rt=/^([ \t]*)/,st=/(?:^|\n)( *)$/,fe="(?:\\d+\\.)",me="(?:[*+-])";function De(n){return"( *)("+(n===1?fe:me)+") +"}const Me=De(1),Fe=De(2);function Le(n){return RegExp("^"+(n===1?Me:Fe))}const it=Le(1),lt=Le(2);function Pe(n){return RegExp("^"+(n===1?Me:Fe)+"[^\\n]*(?:\\n(?!\\1"+(n===1?fe:me)+" )[^\\n]*)*(\\n|$)","gm")}const at=Pe(1),ot=Pe(2);function _e(n){const t=n===1?fe:me;return RegExp("^( *)("+t+") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1"+t+" (?!"+t+" ))\\n*|\\s*\\n*$)")}const qe=_e(1),Ue=_e(2);function $e(n,t){const r=t===1,a=r?qe:Ue,o=r?at:ot,f=r?it:lt;return{t:m=>f.test(m),o:U(function(m,p){const l=st.exec(p.prevCapture);return l&&(p.list||!p.inline&&!p.simple)?a.exec(m=l[1]+m):null}),i:1,u(m,p,l){const k=r?+m[2]:void 0,w=m[0].replace(bn,`
|
|
2
|
-
`).match(o);let C=!1;return{items:w.map(function(x,I){const N=f.exec(x)[0].length,G=RegExp("^ {1,"+N+"}","gm"),P=x.replace(G,"").replace(f,""),e=I===w.length-1,i=P.indexOf(`
|
|
3
|
-
|
|
4
|
-
`)!==-1||e&&C;C=i;const s=l.inline,u=l.list;let c;l.list=!0,i?(l.inline=!1,c=W(P)+`
|
|
5
|
-
|
|
6
|
-
`):(l.inline=!0,c=W(P));const h=p(c,l);return l.inline=s,l.list=u,h}),ordered:r,start:k}},l:(m,p,l)=>n(m.ordered?"ol":"ul",{key:l.key,start:m.type==="20"?m.start:void 0},m.items.map(function(k,w){return n("li",{key:w},p(k,l))}))}}const ct=RegExp(`^\\[((?:\\[[^\\[\\]]*(?:\\[[^\\[\\]]*\\][^\\[\\]]*)*\\]|[^\\[\\]])*)\\]\\(\\s*<?((?:\\([^)]*\\)|[^\\s\\\\]|\\\\.)*?)>?(?:\\s+['"]([\\s\\S]*?)['"])?\\s*\\)`),ut=/^!\[(.*?)\]\( *((?:\([^)]*\)|[^() ])*) *"?([^)"]*)?"?\)/;function Oe(n){return typeof n=="string"}function W(n){let t=n.length;for(;t>0&&n[t-1]<=" ";)t--;return n.slice(0,t)}function K(n,t){return n.startsWith(t)}function dt(n,t,r){if(Array.isArray(r)){for(let a=0;a<r.length;a++)if(K(n,r[a]))return!0;return!1}return r(n,t)}function H(n){return n.replace(/[ÀÁÂÃÄÅàáâãä忯]/g,"a").replace(/[çÇ]/g,"c").replace(/[ðÐ]/g,"d").replace(/[ÈÉÊËéèêë]/g,"e").replace(/[ÏïÎîÍíÌì]/g,"i").replace(/[Ññ]/g,"n").replace(/[øØœŒÕõÔôÓóÒò]/g,"o").replace(/[ÜüÛûÚúÙù]/g,"u").replace(/[ŸÿÝý]/g,"y").replace(/[^a-z0-9- ]/gi,"").replace(/ /gi,"-").toLowerCase()}function pt(n){return Vn.test(n)?"right":Bn.test(n)?"center":Gn.test(n)?"left":null}function Te(n,t,r,a){const o=r.inTable;r.inTable=!0;let f=[[]],m="";function p(){if(!m)return;const l=f[f.length-1];l.push.apply(l,t(m,r)),m=""}return n.trim().split(/(`[^`]*`|\\\||\|)/).filter(Boolean).forEach((l,k,w)=>{l.trim()==="|"&&(p(),a)?k!==0&&k!==w.length-1&&f.push([]):m+=l}),p(),r.inTable=o,f}function ft(n,t,r){r.inline=!0;const a=n[2]?n[2].replace(Wn,"").split("|").map(pt):[],o=n[3]?function(m,p,l){return m.trim().split(`
|
|
7
|
-
`).map(function(k){return Te(k,p,l,!0)})}(n[3],t,r):[],f=Te(n[1],t,r,!!o.length);return r.inline=!1,o.length?{align:a,cells:o,header:f,type:"25"}:{children:f,type:"21"}}function Ee(n,t){return n.align[t]==null?{}:{textAlign:n.align[t]}}function U(n){return n.inline=1,n}function F(n){return U(function(t,r){return r.inline?n.exec(t):null})}function E(n){return U(function(t,r){return r.inline||r.simple?n.exec(t):null})}function T(n){return function(t,r){return r.inline||r.simple?null:n.exec(t)}}function Z(n){return U(function(t){return n.exec(t)})}const mt=/(javascript|vbscript|data(?!:image)):/i;function ht(n){try{const t=decodeURIComponent(n).replace(/[^A-Za-z0-9/:]/g,"");if(mt.test(t))return null}catch{return null}return n}function O(n){return n&&n.replace(et,"$1")}function X(n,t,r){const a=r.inline||!1,o=r.simple||!1;r.inline=!0,r.simple=!0;const f=n(t,r);return r.inline=a,r.simple=o,f}function gt(n,t,r){const a=r.inline||!1,o=r.simple||!1;r.inline=!1,r.simple=!0;const f=n(t,r);return r.inline=a,r.simple=o,f}function yt(n,t,r){const a=r.inline||!1;r.inline=!1;const o=n(t,r);return r.inline=a,o}const oe=(n,t,r)=>({children:X(t,n[2],r)});function ce(){return{}}function ue(){return null}function xt(...n){return n.filter(Boolean).join(" ")}function de(n,t,r){let a=n;const o=t.split(".");for(;o.length&&(a=a[o[0]],a!==void 0);)o.shift();return a||r}function bt(n="",t={}){t.overrides=t.overrides||{},t.namedCodesToUnicode=t.namedCodesToUnicode?L({},be,t.namedCodesToUnicode):be;const r=t.slugify||H,a=t.sanitizer||ht,o=t.createElement||B.createElement,f=[ke,ve,je,t.enforceAtxHeadings?Ce:we,Ne,Se,qe,Ue],m=[...f,Ln,le,Ae,ae];function p(e,i){for(let s=0;s<e.length;s++)if(e[s].test(i))return!0;return!1}function l(e,i,...s){const u=de(t.overrides,e+".props",{});return o(function(c,h){const g=de(h,c);return g?typeof g=="function"||typeof g=="object"&&"render"in g?g:de(h,c+".component",c):c}(e,t.overrides),L({},i,u,{className:xt(i==null?void 0:i.className,u.className)||void 0}),...s)}function k(e){e=e.replace(Tn,"");let i=!1;t.forceInline?i=!0:t.forceBlock||(i=Un.test(e)===!1);const s=G(N(i?e:W(e).replace(tt,"")+`
|
|
8
|
-
|
|
9
|
-
`,{inline:i}));for(;Oe(s[s.length-1])&&!s[s.length-1].trim();)s.pop();if(t.wrapper===null)return s;const u=t.wrapper||(i?"span":"div");let c;if(s.length>1||t.forceWrapper)c=s;else{if(s.length===1)return c=s[0],typeof c=="string"?l("span",{key:"outer"},c):c;c=null}return o(u,{key:"outer"},c)}function w(e,i){if(!i||!i.trim())return null;const s=i.match(xn);return s?s.reduce(function(u,c){const h=c.indexOf("=");if(h!==-1){const g=function(y){return y.indexOf("-")!==-1&&y.match(Rn)===null&&(y=y.replace(Fn,function(S,A){return A.toUpperCase()})),y}(c.slice(0,h)).trim(),v=function(y){const S=y[0];return(S==='"'||S==="'")&&y.length>=2&&y[y.length-1]===S?y.slice(1,-1):y}(c.slice(h+1).trim()),b=xe[g]||g;if(b==="ref")return u;const j=u[b]=function(y,S,A,he){return S==="style"?function(_){const R=[];let z="",D=!1,V=!1,ne="";if(!_)return R;for(let M=0;M<_.length;M++){const $=_[M];if($!=='"'&&$!=="'"||D||(V?$===ne&&(V=!1,ne=""):(V=!0,ne=$)),$==="("&&z.endsWith("url")?D=!0:$===")"&&D&&(D=!1),$!==";"||V||D)z+=$;else{const q=z.trim();if(q){const te=q.indexOf(":");if(te>0){const He=q.slice(0,te).trim(),We=q.slice(te+1).trim();R.push([He,We])}}z=""}}const Q=z.trim();if(Q){const M=Q.indexOf(":");if(M>0){const $=Q.slice(0,M).trim(),q=Q.slice(M+1).trim();R.push([$,q])}}return R}(A).reduce(function(_,[R,z]){return _[R.replace(/(-[a-z])/g,D=>D[1].toUpperCase())]=he(z,y,R),_},{}):yn.indexOf(S)!==-1?he(O(A),y,S):(A.match(zn)&&(A=O(A.slice(1,A.length-1))),A==="true"||A!=="false"&&A)}(e,g,v,a);typeof j=="string"&&(le.test(j)||ae.test(j))&&(u[b]=k(j.trim()))}else c!=="style"&&(u[xe[c]||c]=!0);return u},{}):null}const C=[],x={},I={0:{t:[">"],o:T(ke),i:1,u(e,i,s){const[,u,c]=e[0].replace(kn,"").match(vn);return{alert:u,children:i(c,s)}},l(e,i,s){const u={key:s.key};return e.alert&&(u.className="markdown-alert-"+r(e.alert.toLowerCase(),H),e.children.unshift({attrs:{},children:[{type:"27",text:e.alert}],noInnerParse:!0,type:"11",tag:"header"})),l("blockquote",u,i(e.children,s))}},1:{t:[" "],o:Z(jn),i:1,u:ce,l:(e,i,s)=>l("br",{key:s.key})},2:{t:["--","__","**","- ","* ","_ "],o:T(wn),i:1,u:ce,l:(e,i,s)=>l("hr",{key:s.key})},3:{t:[" "],o:T(je),i:0,u:e=>({lang:void 0,text:O(W(e[0].replace(/^ {4}/gm,"")))}),l:(e,i,s)=>l("pre",{key:s.key},l("code",L({},e.attrs,{className:e.lang?"lang-"+e.lang:""}),e.text))},4:{t:["```","~~~"],o:T(ve),i:0,u:e=>({attrs:w("code",e[3]||""),lang:e[2]||void 0,text:e[4],type:"3"})},5:{t:["`"],o:E(Cn),i:3,u:e=>({text:O(e[2])}),l:(e,i,s)=>l("code",{key:s.key},e.text)},6:{t:["[^"],o:T(Sn),i:0,u:e=>(C.push({footnote:e[2],identifier:e[1]}),{}),l:ue},7:{t:["[^"],o:F($n),i:1,u:e=>({target:"#"+r(e[1],H),text:e[1]}),l:(e,i,s)=>l("a",{key:s.key,href:a(e.target,"a","href")},l("sup",{key:s.key},e.text))},8:{t:["[ ]","[x]"],o:F(En),i:1,u:e=>({completed:e[1].toLowerCase()==="x"}),l:(e,i,s)=>l("input",{checked:e.completed,key:s.key,readOnly:!0,type:"checkbox"})},9:{t:["#"],o:T(t.enforceAtxHeadings?Ce:we),i:1,u:(e,i,s)=>({children:X(i,e[2],s),id:r(e[2],H),level:e[1].length}),l:(e,i,s)=>l("h"+e.level,{id:e.id,key:s.key},i(e.children,s))},10:{t:e=>{const i=e.indexOf(`
|
|
10
|
-
`);return i>0&&i<e.length-1&&(e[i+1]==="="||e[i+1]==="-")},o:T(Ne),i:1,u:(e,i,s)=>({children:X(i,e[1],s),level:e[2]==="="?1:2,type:"9"})},11:{t:["<"],o:Z(le),i:1,u(e,i,s){const[,u]=e[3].match(rt),c=RegExp("^"+u,"gm"),h=e[3].replace(c,""),g=p(m,h)?yt:X,v=e[1].toLowerCase(),b=gn.indexOf(v)!==-1,j=(b?v:e[1]).trim(),y={attrs:w(j,e[2]),noInnerParse:b,tag:j};if(s.inAnchor=s.inAnchor||v==="a",b)y.text=e[3];else{const S=s.inHTML;s.inHTML=!0,y.children=g(i,h,s),s.inHTML=S}return s.inAnchor=!1,y},l:(e,i,s)=>l(e.tag,L({key:s.key},e.attrs),e.text||(e.children?i(e.children,s):""))},13:{t:["<"],o:Z(ae),i:1,u(e){const i=e[1].trim();return{attrs:w(i,e[2]||""),tag:i}},l:(e,i,s)=>l(e.tag,L({},e.attrs,{key:s.key}))},12:{t:["<!--"],o:Z(Ae),i:1,u:()=>({}),l:ue},14:{t:["!["],o:E(ut),i:1,u:e=>({alt:O(e[1]),target:O(e[2]),title:O(e[3])}),l:(e,i,s)=>l("img",{key:s.key,alt:e.alt||void 0,title:e.title||void 0,src:a(e.target,"img","src")})},15:{t:["["],o:F(ct),i:3,u:(e,i,s)=>({children:gt(i,e[1],s),target:O(e[2]),title:O(e[3])}),l:(e,i,s)=>l("a",{key:s.key,href:a(e.target,"a","href"),title:e.title},i(e.children,s))},16:{t:["<"],o:F(Mn),i:0,u(e){let i=e[1],s=!1;return i.indexOf("@")!==-1&&i.indexOf("//")===-1&&(s=!0,i=i.replace("mailto:","")),{children:[{text:i,type:"27"}],target:s?"mailto:"+i:i,type:"15"}}},17:{t:(e,i)=>!i.inAnchor&&!t.disableAutoLink&&(K(e,"http://")||K(e,"https://")),o:F(Dn),i:0,u:e=>({children:[{text:e[1],type:"27"}],target:e[1],title:void 0,type:"15"})},20:$e(l,1),33:$e(l,2),19:{t:[`
|
|
11
|
-
`],o:T(Nn),i:3,u:ce,l:()=>`
|
|
12
|
-
`},21:{o:U(function(e,i){if(i.inline||i.simple||i.inHTML&&e.indexOf(`
|
|
13
|
-
|
|
14
|
-
`)===-1&&i.prevCapture.indexOf(`
|
|
15
|
-
|
|
16
|
-
`)===-1)return null;let s="",u=0;for(;;){const h=e.indexOf(`
|
|
17
|
-
`,u),g=e.slice(u,h===-1?void 0:h+1);if(p(f,g)||(s+=g,h===-1||!g.trim()))break;u=h+1}const c=W(s);return c===""?null:[s,,c]}),i:3,u:oe,l:(e,i,s)=>l("p",{key:s.key},i(e.children,s))},22:{t:["["],o:F(Pn),i:0,u:e=>(x[e[1]]={target:e[2],title:e[4]},{}),l:ue},23:{t:["!["],o:E(_n),i:0,u:e=>({alt:e[1]?O(e[1]):void 0,ref:e[2]}),l:(e,i,s)=>x[e.ref]?l("img",{key:s.key,alt:e.alt,src:a(x[e.ref].target,"img","src"),title:x[e.ref].title}):null},24:{t:e=>e[0]==="["&&e.indexOf("](")===-1,o:F(qn),i:0,u:(e,i,s)=>({children:i(e[1],s),fallbackChildren:e[0],ref:e[2]}),l:(e,i,s)=>x[e.ref]?l("a",{key:s.key,href:a(x[e.ref].target,"a","href"),title:x[e.ref].title},i(e.children,s)):l("span",{key:s.key},e.fallbackChildren)},25:{t:["|"],o:T(Se),i:1,u:ft,l(e,i,s){const u=e;return l("table",{key:s.key},l("thead",null,l("tr",null,u.header.map(function(c,h){return l("th",{key:h,style:Ee(u,h)},i(c,s))}))),l("tbody",null,u.cells.map(function(c,h){return l("tr",{key:h},c.map(function(g,v){return l("td",{key:v,style:Ee(u,v)},i(g,s))}))})))}},27:{o:U(function(e,i){let s;return K(e,":")&&(s=Xn.exec(e)),s||nt.exec(e)}),i:4,u(e){const i=e[0];return{text:i.indexOf("&")===-1?i:i.replace(In,(s,u)=>t.namedCodesToUnicode[u]||s)}},l:e=>e.text},28:{t:["**","__"],o:E(Qn),i:2,u:(e,i,s)=>({children:i(e[2],s)}),l:(e,i,s)=>l("strong",{key:s.key},i(e.children,s))},29:{t:e=>{const i=e[0];return(i==="*"||i==="_")&&e[1]!==i},o:E(Zn),i:3,u:(e,i,s)=>({children:i(e[2],s)}),l:(e,i,s)=>l("em",{key:s.key},i(e.children,s))},30:{t:["\\"],o:E(Yn),i:1,u:e=>({text:e[1],type:"27"})},31:{t:["=="],o:E(Jn),i:3,u:oe,l:(e,i,s)=>l("mark",{key:s.key},i(e.children,s))},32:{t:["~~"],o:E(Kn),i:3,u:oe,l:(e,i,s)=>l("del",{key:s.key},i(e.children,s))}};t.disableParsingRawHTML===!0&&(delete I[11],delete I[13]);const N=function(e){var i=Object.keys(e);function s(u,c){var h=[];if(c.prevCapture=c.prevCapture||"",u.trim())for(;u;)for(var g=0;g<i.length;){var v=i[g],b=e[v];if(!b.t||dt(u,c,b.t)){var j=b.o(u,c);if(j&&j[0]){u=u.substring(j[0].length);var y=b.u(j,s,c);c.prevCapture+=j[0],y.type||(y.type=v),h.push(y);break}g++}else g++}return c.prevCapture="",h}return i.sort(function(u,c){return e[u].i-e[c].i||(u<c?-1:1)}),function(u,c){return s(function(h){return h.replace(An,`
|
|
18
|
-
`).replace(On,"").replace(Hn," ")}(u),c)}}(I),G=function(e,i){return function s(u,c={}){if(Array.isArray(u)){const h=c.key,g=[];let v=!1;for(let b=0;b<u.length;b++){c.key=b;const j=s(u[b],c),y=Oe(j);y&&v?g[g.length-1]+=j:j!==null&&g.push(j),v=y}return c.key=h,g}return function(h,g,v){const b=e[h.type].l;return i?i(()=>b(h,g,v),h,g,v):b(h,g,v)}(u,s,c)}}(I,t.renderRule),P=k(n);return C.length?l("div",null,P,l("footer",{key:"footer"},C.map(function(e){return l("div",{id:r(e.identifier,H),key:e.identifier},e.identifier,G(N(e.footnote,{inline:!0})))}))):P}const kt=n=>{let{children:t,options:r}=n,a=function(o,f){if(o==null)return{};var m,p,l={},k=Object.keys(o);for(p=0;p<k.length;p++)f.indexOf(m=k[p])>=0||(l[m]=o[m]);return l}(n,hn);return B.cloneElement(bt(t??"",r),a)},Ie="/img/logo/",vt=n=>n.trim().replace(/\n{3,}/g,`
|
|
19
|
-
|
|
20
|
-
`).replace(/(\n\s*\n)+(?=\|)/g,`
|
|
21
|
-
`).replace(/^\s*[\r\n]/gm,"").replace(/(<p>\s*<\/p>)/g,""),jt=n=>{var r;switch((r=n.split("/")[1])==null?void 0:r.toLowerCase()){case"jpg":case"jpeg":case"png":return d.jsx(Ze,{});case"pdf":return d.jsx(rn,{});case"doc":case"docx":return d.jsx(Qe,{});case"xls":case"xlsx":return d.jsx(Ve,{});default:return d.jsx(Ge,{})}},Re=({messages:n,loading:t,avatarInfo:r,imgClass:a,mode:o})=>{tn().pathname;const m=sn(),{file:p,fileName:l,fileType:k}=J(x=>x.aiChat.data),w=B.useRef(null);B.useEffect(()=>{w.current.scrollTop=w.current.scrollHeight},[n]);const C=()=>p&&d.jsxs("div",{className:"bubbles",children:[d.jsxs("div",{className:"bubble text-md",children:[d.jsx("div",{className:"bubble-default-user",children:r}),d.jsxs("div",{className:"file-icon flex justify-end",children:[d.jsx("span",{className:"mr-2",children:l}),jt(k)]})]}),d.jsxs("div",{className:"bubble text-md",children:[d.jsx("div",{className:"bubble-ai-user",children:d.jsx("img",{style:{fill:`${o}`},className:a,src:`${Ie}aica.svg`,alt:`${ge} logo`})}),"I can help you with this file. Just tell me what information you need!"]})]});return d.jsxs("div",{ref:w,className:"main-bubbles",style:m?{width:"100%"}:{},children:[(n==null?void 0:n.length)===0&&!p&&d.jsx("div",{className:"flex no-messages",children:d.jsx("div",{className:"lg:flex md:flex-none sm:flex-none flex-contain w-full",children:d.jsxs("div",{className:"lg:w-full md:w-full sm:w-full text-center",children:[d.jsx("h2",{children:"Welcome!"}),d.jsx("h3",{className:"py-5 px-8",children:"I'm here to assist with any business-related questions you have."}),d.jsx("div",{className:"px-8",children:"Whether it's about strategies, market trends, financial insights, or company-specific queries, feel free to ask!"})]})})}),p&&d.jsx(C,{}),n.map(x=>d.jsxs("div",{className:"bubbles",children:[d.jsxs("div",{className:"bubble text-md",children:[d.jsx("div",{className:"bubble-default-user",children:r}),x.question]}),d.jsxs("div",{className:"bubble text-md",children:[d.jsx("div",{className:"bubble-ai-user",children:d.jsx("img",{style:{fill:o},className:a,src:`${Ie}aica.svg`,alt:`${ge} logo`})}),d.jsx("div",{className:"markdown-preview-wrapper text-sm w-full overflow-x-auto p-0 m-0",children:d.jsx(kt,{className:"markdown-preview whitespace-pre-wrap",options:{overrides:{p:{props:{className:"my-4 leading-relaxed text-white whitespace-pre-line"}},strong:{props:{className:"font-semibold text-white"}},h1:{props:{className:"text-2xl font-bold mt-6 mb-3 text-white"}},h2:{props:{className:"text-xl font-semibold mt-5 mb-3 text-white"}},h3:{props:{className:"text-lg font-semibold mt-4 mb-2 text-white"}},ul:{props:{className:"list-disc pl-6 my-2 text-white"}},ol:{props:{className:"list-decimal pl-6 my-2 text-white"}},li:{props:{className:"ml-4 text-white my-1"}},table:{props:{className:"w-full border-collapse overflow-x-auto my-4"}},th:{props:{className:"text-white border px-2 py-1 text-left text-sm whitespace-nowrap"}},td:{props:{className:"border border-white p-2 text-white"}},hr:{props:{className:"my-4 border-white/50"}},br:{props:{className:"my-3 block"}}}},children:vt(x.response)})})]})]},x.id)),t&&d.jsxs("div",{className:"loading-spinner",children:[d.jsx("div",{className:"spinner"}),d.jsx("div",{className:"flex pl-6",children:d.jsx("div",{className:"dot-pulse"})})]})]})};Je("aiChat",mn);const Ut=({mode:n,imgClass:t})=>{const{avatar:r,userName:a}=J(p=>p.auth.user);let o;r?o=d.jsx(Ke,{size:15,shape:"circle",src:r}):o=d.jsx("span",{className:"user-no-avatar",children:a==null?void 0:a.substring(0,1)});const f=J(p=>p.aiChat.data.messages||[]),m=J(p=>p.aiChat.data.loading);return d.jsx("div",{children:f.length===0?d.jsx(Re,{messages:[],loading:m,avatarInfo:o,imgClass:t,mode:n}):d.jsx(Re,{messages:f,loading:m,avatarInfo:o,imgClass:t,mode:n})})},Ht=({onSendMessage:n})=>{const[t,r]=B.useState(""),a=Xe(),o=()=>{t.trim()&&(n(t),r(""))},f=()=>{a(pn())},m=p=>{p.key==="Enter"&&o()};return d.jsxs("div",{className:"flex message-input",children:[d.jsx("div",{className:"flex-auto",children:d.jsx(Ye,{size:"sm",type:"text",value:t,prefix:d.jsx(en,{}),onKeyDown:m,onChange:p=>r(p.target.value),placeholder:"Ask me something..."})}),d.jsx(ye,{className:"ml-3",variant:"solid",shape:"circle",size:"sm",icon:d.jsx(nn,{}),onClick:o,disabled:!t.trim()}),d.jsx(ye,{className:"ml-3",variant:"solid",shape:"circle",size:"sm",icon:d.jsx(un,{}),onClick:f})]})};export{Ut as C,Ht as M,qt as a,pn as b,re as c,_t as h,ie as q,mn as r,Pt as t,J as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./vendor-mui-69397583.js";import{A as r}from"./AdaptableCard-df7695d6.js";import{r as e}from"./vendor-react-ece1c85f.js";import"./index-c62ac197.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";const x=()=>(e.useState(!1),s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"topbar py-4 px-6 border-gray-200 border-b",children:s.jsx("div",{className:"lg:flex items-center justify-between",children:s.jsx("h3",{className:"mb-4 lg:mb-0",children:"Messages"})})}),s.jsx(r,{className:"m-6 h-full py-4 px-6 bg-transparent",bodyClass:"h-full",children:s.jsx(r,{className:"p-4",children:"Soon..."})})]}));export{x as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as p}from"./vendor-pdf-b2a5d8b1.js";import{j as e}from"./vendor-mui-69397583.js";import{M as d,S as c,U as u,s as x,a as f,H as j}from"./ClassicLayout-7d09e5ac.js";import{V as g}from"./Views-74429e81.js";import{c as s,r as a}from"./vendor-react-ece1c85f.js";import{u as b,a as h,P as y,b as v}from"./index-c62ac197.js";import{L as E}from"./Logo-3f3c9ee6.js";import"./SidePanelContent-6b13836f.js";import"./Switcher-c8648037.js";import"./index-ec2010d2.js";import"./index-6b6d0f06.js";import"./useControllableState-d0909575.js";import"./DoubleSidedImage-ae98733b.js";import"./Drawer-949c18c6.js";import"./index-c2088808.js";import"./useDidUpdate-25c4d4ed.js";import"./Alert-7dfbd254.js";import"./FormContainer-91c2b0e4.js";import"./index-36228db5.js";import"./Upload-fb34ce03.js";import"./vendor-devex-33a39e11.js";import"./index-aaad94c2.js";import"./index-e4c6057f.js";import"./index-f6be0390.js";import"./vendor-i18n-2fcb1983.js";import"./index-ea125a16.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";const S=s.lazy(()=>p(()=>import("./AiCa-9c1b25b2.js"),["assets/AiCa-9c1b25b2.js","assets/vendor-mui-69397583.js","assets/vendor-react-ece1c85f.js","assets/index-c62ac197.js","assets/vendor-redux-a1f00e6b.js","assets/vendor-pdf-b2a5d8b1.js","assets/vendor-devex-33a39e11.js","assets/vendor-i18n-2fcb1983.js","assets/vendor-msal-9caa1ed1.js","assets/vendor-charts-eccea5d1.js","assets/index-8c229076.css","assets/MessageInput-6dc83761.js","assets/index-42e65911.js","assets/useDeviceCheck-920641a5.js","assets/Alert-7dfbd254.js","assets/index-6b6d0f06.js","assets/useControllableState-d0909575.js","assets/index-c2088808.js","assets/useDidUpdate-25c4d4ed.js","assets/Drawer-949c18c6.js","assets/FormContainer-91c2b0e4.js","assets/Switcher-c8648037.js","assets/index-36228db5.js","assets/Upload-fb34ce03.js","assets/BrainServices-a4bb698e.js","assets/index-f6be0390.js"])),_=s.memo(r=>{const{menus:o}=r;return e.jsxs(e.Fragment,{children:[e.jsx(E,{type:"streamline",imgClass:"mx-auto mobile-only"}),e.jsx(d,{menus:o}),e.jsx(c,{})]})}),M=s.memo(()=>e.jsxs(e.Fragment,{children:[e.jsx(a.Suspense,{fallback:null,children:e.jsx(S,{})}),e.jsx(u,{hoverable:!1})]})),N=()=>{const[r,o]=a.useState([]);b(),h(),a.useEffect(()=>{n()},[]);const n=async()=>{var m;const i=localStorage.getItem(y);if(i){const t=await v(i,"default");let l=x((m=t==null?void 0:t.data)==null?void 0:m.$values);o(l??[])}else o([])};return e.jsx("div",{className:"app-layout-modern flex flex-auto flex-col",children:e.jsxs("div",{className:"flex flex-auto min-w-0",children:[e.jsx(f,{menus:r}),e.jsxs("div",{className:"flex flex-col flex-auto min-h-screen min-w-0 relative w-full bg-white dark:bg-gray-800 border-l border-gray-200 dark:border-gray-700",children:[e.jsx(j,{className:"border-b border-gray-200 dark:border-gray-700",headerEnd:e.jsx(M,{}),headerStart:e.jsx(_,{menus:r})}),e.jsx(g,{})]})]})})},oe=s.memo(N);export{oe as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as i}from"./vendor-mui-69397583.js";import{O as p,Q as e}from"./index-c62ac197.js";const n=(s,t="Success",o="success",c=2500)=>{p.push(i.jsx(e,{title:t,type:o,duration:c,children:s}),{placement:"top-center"})};export{n as p};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e,l as $e}from"./vendor-mui-69397583.js";import{A as je}from"./AdaptableCard-df7695d6.js";import{r as x,f as Te,L as Ne}from"./vendor-react-ece1c85f.js";import{r as ve,u as F,t as Ee,a as we,d as ze,g as Ye,s as U,b as _e,c as Se}from"./index-dc103f22.js";import{Y as G,l as le,I as ge,W as te,B as q,O as ce,Q as ie,cC as Le,f as Be,V as We,n as Ae,a5 as W,cD as Ue,cE as Ve,cF as qe,aD as Fe,a8 as Ge,d as Re,a9 as Qe,aa as Ke,Z as fe}from"./index-c62ac197.js";import{A as Xe,T as ye}from"./actioncell-17e12e21.js";import"./Alert-7dfbd254.js";import"./index-6b6d0f06.js";import{a as Ze,C as ke}from"./index-c2088808.js";import{D as V}from"./Drawer-949c18c6.js";import{F as He,a as T}from"./FormContainer-91c2b0e4.js";import"./Switcher-c8648037.js";import"./index-36228db5.js";import"./Upload-fb34ce03.js";import{a as Je,c as et,F as tt,b as at,d as z}from"./index.esm-70ab539c.js";import{f as Me,g as nt,h as st}from"./OpportunityServices-fa4fabfd.js";import{A as ot,E as rt}from"./EditLead-cc38d2a2.js";import{g as ct,a as it,r as lt}from"./index-9b41371d.js";import{a as dt,b as ut}from"./AddAccount-a05910e8.js";import{S as pt}from"./StickyFooter-5b934274.js";import{V as De,i as mt}from"./validationPatterns-77446c46.js";import{r as xt,g as ht}from"./index-6589dd2d.js";import{g as gt}from"./index-cebd880b.js";import{C as ft}from"./ConfirmDialog-3202eb3d.js";import{C as yt}from"./tableV3-3d2f4952.js";import{r as jt}from"./index-49a94e54.js";import{u as wt}from"./usePermission-d94b4984.js";import{w as vt}from"./WrapperCell-a7981b07.js";import"./vendor-redux-a1f00e6b.js";import"./vendor-pdf-b2a5d8b1.js";import"./vendor-devex-33a39e11.js";import"./vendor-i18n-2fcb1983.js";import"./vendor-msal-9caa1ed1.js";import"./vendor-charts-eccea5d1.js";import"./useControllableState-d0909575.js";import"./useDidUpdate-25c4d4ed.js";import"./DoubleSidedImage-ae98733b.js";import"./index-36ba4ea7.js";import"./LeadSourceService-e46fa85e.js";import"./index-e4c6057f.js";import"./AccountServices-62599aae.js";import"./ContactService-92281a90.js";import"./DepartmentServices-3d56a9e7.js";import"./Check-71f21a49.js";import"./createSvgIcon-c5fc0d04.js";import"./CourseService-f0dc3bf1.js";import"./ApiService-2b99757f.js";import"./UserService-047aef51.js";import"./FileSaver.min-20f3f13a.js";import"./mapView-ab35acaa.js";import"./esm-f306d015.js";import"./lodash-306e3f66.js";import"./DensitySelector-a2c1c68f.js";import"./NoData-8c485a3a.js";G("opportunity",ve);G("users",xt);G("AccountsData",ve);const ee=Je().matches(De.sqlInjectionSafe,"Invalid input: SQL keywords not allowed").matches(De.noSpecialChars,"Special characters like < > = { } are not allowed").test("no-base64","Base64 encoded content is not allowed",i=>i?!mt(i.trim()):!0),bt=et().shape({opportunityName:ee.required("Name Required").max(100,"Maximum 100 characters allowed"),notes:ee,address:ee,city:ee,state:ee}),It=i=>{if(!i)return"";const l=Number(i.toString().replace(/\D/g,""));return l?`$ ${l.toLocaleString()}`:""},Oe=i=>i?String(i).replace(/\D/g,""):null,Ct=i=>{const{type:l,footerWidth:h,ref:a,initialData:d,fetchOpportunity:N,accountId:w,leadId:D}=i,[R,O]=x.useState(!1),[k,s]=x.useState(!1),[M,y]=x.useState(""),[c,E]=x.useState(""),j=x.useRef(null);x.useRef(null);const[I,b]=x.useState(!1),[v,S]=x.useState(),[Y,de]=x.useState(!1),P=le();F(n=>{var r,C,f;return(f=(C=(r=n.LeadsData)==null?void 0:r.data)==null?void 0:C.contactList)==null?void 0:f.map(m=>({value:m.id,label:m.contactName,desc:m}))}),F(n=>{var r,C;let p=(r=n.LeadsData.data.leadList)==null?void 0:r.map(f=>({value:f.id,label:f.leadName,desc:f}));return w&&(p=(C=p==null?void 0:p.filter)==null?void 0:C.call(p,f=>{var m;return w===((m=f==null?void 0:f.desc)==null?void 0:m.accountId)})),p});const{usersList:ae}=F(n=>n.users.data),{accountList:ne}=F(n=>n.AccountsData.data);x.useEffect(()=>{Q(),L(),ue(),pe()},[]);const L=()=>{const n=ct({});P(n)},Q=()=>{const n=it();P(n)},ue=()=>{P(ht({isActive:!0}))},pe=()=>{const n=gt({});P(n)},me=(n,p)=>{s(!1),p(c,{value:n.id,label:n.contactName,desc:n}),L(),y(""),E("")},K=()=>{s(!1),y(""),E("")},xe=(n,p)=>{O(!1),p(c,{value:n.id,label:n.accountName}),Q(),y(""),E("")},X=()=>{O(!1),y(""),E("")},[he,Z]=x.useState([]),se=async n=>{var p;try{return await nt(n)}catch(r){return(p=r==null?void 0:r.response)==null?void 0:p.data}},oe=async n=>{var p;try{return await st(n)}catch(r){return(p=r==null?void 0:r.response)==null?void 0:p.data}},H=x.useCallback(async()=>{var n,p;try{const r=await Me();r!=null&&r.data&&Z((p=(n=r==null?void 0:r.data)==null?void 0:n.$values)==null?void 0:p.map(C=>({label:C.stageName,value:C.id})))}catch(r){Z([]),console.error("Failed to opportunity logs:",r)}},[]);x.useEffect(()=>{H()},[H]);const re=F(n=>n.opportunity.data.IsDrawerOpen),J=()=>{P(Ee(!re))},_=async(n,p)=>{const r=(o,g)=>{var $,B,be,Ie,Ce;const A={contactId:(($=o.opportunitySourceId)==null?void 0:$.value)??null,accountId:((B=o.accountId)==null?void 0:B.value)??null,opportunityName:o.opportunityName??"",estAnnualRevenue:Oe(o==null?void 0:o.estAnnualRevenue)??null,value:o.value??null,probability:o.probability??null,potential:Oe(o==null?void 0:o.potentialRevenue)??null,noOfEmployees:String(o.noOfEmployees)??null,industry:o.industryId??"",serviceType:o.serviceTypeId??"",product:o.productId??"",address:o.address??"",address2:o.address2??"",city:o.city??"",state:o.state??"",zip:o.zip??"",bussinessCardImagePath:"",startDate:o.startDate??null,ownerId:((be=o.ownerId)==null?void 0:be.value)??null,notes:o.notes??"",opportunitySourceId:null,opportunityStageId:((Ie=o.opportunityStageId)==null?void 0:Ie.value)??""};return g==="Add"?A:{id:o.id??"",...A,opportunityStageId:((Ce=o.opportunityStageId)==null?void 0:Ce.value)??""}},C=(o,g)=>{o.success?(N&&(Le(),N()),J(),p(!1),ce.push(e.jsx(ie,{title:"Success",type:"success",duration:2500,children:`Opportunity Successfully ${g}`}),{placement:"top-center"})):(p(!1),ce.push(e.jsx(ie,{title:"Error",type:"danger",duration:2500,children:o.message}),{placement:"top-center"}))},f=r(n,l);let m;try{l==="Add"?(m=await se(f),C(m,"Added")):l==="Edit"&&(m=await oe(f),C(m,"Updated"))}catch(o){console.error("Error during form submission:",o),p(!1),ce.push(e.jsx(ie,{title:"Error",type:"danger",duration:2500,children:`An error occurred during ${l} opportunity`}),{placement:"top-center"})}},t=()=>{S(null),b(!1),L()},u=()=>{S(null),de(!1),Q()};return e.jsx(tt,{innerRef:a,initialValues:{...d},validationSchema:bt,onSubmit:(n,{setSubmitting:p})=>{const r=n;_==null||_(r,p)},children:({values:n,touched:p,errors:r,isSubmitting:C,setFieldValue:f})=>(x.useEffect(()=>{const m=()=>{if(window.google&&window.google.maps){const o=new window.google.maps.places.Autocomplete(j.current,{types:["address"],componentRestrictions:{country:"us"}});o.addListener("place_changed",()=>{const g=o.getPlace();let A={};g.address_components.forEach($=>{const B=$.types;B.includes("locality")?A.city=$.long_name:B.includes("administrative_area_level_1")?A.state=$.short_name:B.includes("postal_code")&&(A.zipcode=$.long_name)}),f("address",g.name),f("city",A.city||""),f("state",A.state||""),f("zip",A.zipcode||"")})}};if(window.google&&window.google.maps)m();else{const o=setInterval(()=>{window.google&&window.google.maps&&(m(),clearInterval(o))},500)}},[i]),e.jsx(at,{children:e.jsx(He,{children:e.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-1 gap-4",children:e.jsx("div",{className:"lg:col-span-2 pb-8",children:e.jsxs(je,{divider:!0,className:"mb-4",children:[e.jsx(T,{label:"Opportunity Name",asterisk:!0,invalid:r.opportunityName&&p.opportunityName,errorMessage:r.opportunityName,children:e.jsx(z,{type:"text",autoComplete:"off",name:"opportunityName",placeholder:"Name",component:ge})}),e.jsx(T,{label:"Account / Company",invalid:r.accountId&&p.accountId,errorMessage:r.accountId,children:e.jsx(z,{name:"accountId",children:({field:m,form:o})=>e.jsx(te,{field:m,form:o,options:ne.map(g=>({label:g.accountName,value:g.id})),name:"accountId",isDisabled:!!D,onChange:g=>{o.setFieldValue(m.name,g)}})})}),e.jsx("div",{className:"flex space-x-4",children:e.jsx("div",{className:"flex-1",children:e.jsx(T,{label:"Amount / Deal Value",invalid:r.estAnnualRevenue&&p.estAnnualRevenue,errorMessage:r.estAnnualRevenue,children:e.jsx(z,{type:"text",value:It(n.estAnnualRevenue),autoComplete:"off",name:"estAnnualRevenue",placeholder:"Amount / Deal Value",component:ge})})})}),e.jsx("div",{className:"flex space-x-4",children:e.jsx("div",{className:"flex-1",children:e.jsx(T,{label:"Opportunity Stage",invalid:r.opportunityStageId&&p.opportunityStageId,errorMessage:r.opportunityStageId,children:e.jsx(z,{name:"opportunityStageId",children:({field:m,form:o})=>e.jsx(te,{field:m,form:o,options:he,name:"opportunityStageId",onChange:g=>{o.setFieldValue(m.name,g)}})})})})}),e.jsx(T,{label:"Close Date",invalid:r.startDate&&p.startDate,errorMessage:r.startDate,children:e.jsx(z,{name:"startDate",placeholder:"CloseDate",children:({field:m,form:o})=>e.jsx(Ze,{field:m,form:o,inputFormat:"MM/DD/YYYY",value:n.startDate?new Date(n.startDate):new Date,onChange:g=>{o.setFieldValue(m.name,g)}})})}),e.jsx(T,{label:"Owner",invalid:r.owner&&p.owner,errorMessage:r.owner,children:e.jsx(z,{name:"ownerId",children:({field:m,form:o})=>e.jsx(te,{field:m,form:o,options:ae.filter(g=>{var A;return(A=g.role)==null?void 0:A.toLowerCase().includes("admin")}).map(g=>({label:`${g.firstName} ${g.lastName}`,value:g.id})),name:"ownerId",onChange:g=>{o.setFieldValue(m.name,g)}})})}),e.jsx(T,{label:"Notes",invalid:r.notes&&p.notes,errorMessage:r.notes,children:e.jsx(z,{textArea:!0,type:"text",autoComplete:"off",name:"notes",placeholder:"Notes",component:ge})}),e.jsx(pt,{className:`px-8 flex items-center justify-between py-4 ${h?`md:${h}`:""}`,stickyClass:"bg-white dark:bg-gray-800 border-gray-200 dark:border-gray-700",children:e.jsxs("div",{className:"flex items-center justify-between w-full",children:[e.jsx(q,{size:"sm",className:"mr-2",disabled:C,onClick:()=>J(),children:"Discard"}),e.jsx(q,{size:"sm",variant:"solid",type:"submit",loading:C,children:`${l==="Edit"?"Save":l} Opportunity`})]})}),e.jsx(V,{title:"New Lead",isOpen:R,onClose:X,portalClassName:"w30",showBackdrop:!1,children:e.jsx(ot,{onDrawerClose:X,isfromDropdown:!0,onContactCreated:m=>xe(m,f),newContactName:M})}),e.jsx(V,{title:"New Contact",isOpen:k,onClose:K,portalClassName:"w30",showBackdrop:!1,children:e.jsx(dt,{onDrawerClose:K,isfromDropdown:!0,onContactCreated:m=>me(m,f),newContactName:M})}),e.jsx(V,{title:"Edit Contact",isOpen:I,onClose:t,portalClassName:"w30",showBackdrop:!1,children:e.jsx(ut,{id:v,onDrawerClose:t})}),e.jsx(V,{title:"Edit Lead",isOpen:Y,onClose:u,portalClassName:"w30",showBackdrop:!1,children:e.jsx(rt,{id:v,onDrawerClose:u})})]})})})})}))})},Pe=x.forwardRef((i,l)=>{const{type:h,footerWidth:a,fetchData:d,accountId:N,leadId:w,initialData:D={opportunitySourceID_ref:"",accountID_ref:"",leadId:"",opportunityName:"",opportunityStageID_ref:"",estAnnualRevenue:null,value:null,probability:null,potential:null,noOfEmployees:"",industryID_ref:"",serviceTypeID_ref:"",productID_ref:"",address:"",address2:"",city:"",state:"",zip:"",bussinessCardImagePath:"",startDate:new Date,wonDate:new Date,notes:""},onFormSubmit:R,onDiscard:O,onDelete:k}=i;return e.jsx(e.Fragment,{children:e.jsx(Ct,{footerWidth:a,fetchOpportunity:d,type:h,ref:l,initialData:D,accountId:N,leadId:w})})});Pe.displayName="OpportunityForm";const Nt=i=>{const l=le(),h=F(w=>w.opportunity.data.deleteConfirmation),a=F(w=>w.opportunity.data.selectedOpportunity),d=async()=>{l(we(!1)),await ze(a==null?void 0:a.id)&&(Le(),i!=null&&i.fetchData&&(i==null||i.fetchData()),ce.push(e.jsx(ie,{title:"Deleted",type:"success",duration:2500,children:"Opportunity Successfully Deleted"}),{placement:"top-center"}))},N=()=>{l(we(!h))};return e.jsx(e.Fragment,{children:e.jsx(ft,{isOpen:h,type:"danger",title:"Delete Opportunity",confirmButtonColor:"red-600",onClose:N,onRequestClose:N,onCancel:N,onConfirm:d,children:e.jsx("p",{children:"Are you sure you want to delete this opportunity?"})})})},St=({onSaveClick:i,onCancel:l,onClearFilers:h})=>e.jsxs("div",{className:"text-right w-full",children:[e.jsx(q,{size:"sm",className:"mr-2",onClick:h,children:"Clear All"}),e.jsx(q,{size:"sm",className:"mr-2",onClick:l,children:"Cancel"}),e.jsx(q,{size:"sm",variant:"solid",onClick:i,children:"Query"})]}),At=i=>{x.useRef(null);const l=le(),[h,a]=x.useState(!1),d=F(j=>{var I,b;return(b=(I=j==null?void 0:j.opportunity)==null?void 0:I.data)==null?void 0:b.filterData}),[N,w]=x.useState(d==null?void 0:d.accountId),[D,R]=x.useState(d==null?void 0:d.opportunityStageId),[O,k]=x.useState([]),s=F(j=>{var b,v,S;return(S=(v=(b=j.opportunity)==null?void 0:b.data)==null?void 0:v.accountsList)==null?void 0:S.map(Y=>({value:Y.id,label:Y.companyName}))});x.useEffect(()=>{M()},[]);const M=async()=>{var I,b;const j=Ye();l(j);try{const v=await Me();v!=null&&v.data&&k((b=(I=v==null?void 0:v.data)==null?void 0:I.$values)==null?void 0:b.map(S=>({label:S.stageName,value:S.id})))}catch(v){k([]),console.error("Failed to opportunity logs:",v)}},y=()=>{a(!1),i.onClose()},c=()=>{l(U({opportunityStageId:"",accountId:""})),w(""),R("")},E=()=>{i.onClose(),a(!1),l(U({opportunityStageId:D,accountId:N}))};return x.useEffect(()=>{i.isOpen&&a(!0)},[i.isOpen]),x.useEffect(()=>{var j,I;(j=d==null?void 0:d.accountId)!=null&&j.value?w(d==null?void 0:d.accountId):w(""),(I=d==null?void 0:d.opportunityStageId)!=null&&I.value?R(d==null?void 0:d.opportunityStageId):R("")},[d]),e.jsx(e.Fragment,{children:e.jsxs(V,{title:"Advanced Filter Selection Page",isOpen:h,portalClassName:"w30",footer:e.jsx(St,{onCancel:y,onSaveClick:E,onClearFilers:c}),onClose:y,onRequestClose:y,children:[e.jsxs("div",{className:"mb-5",children:[e.jsx("div",{className:"lg:flex md:flex-none sm:flex-none mb-4",children:e.jsx("h5",{children:"Account"})}),e.jsx(te,{size:"sm",className:"mb-4 rounded-xl",placeholder:"Please Select",isMulti:!1,value:N,onChange:j=>w(j),options:s,isClearable:!0})]}),e.jsxs("div",{className:"mb-5",children:[e.jsx("div",{className:"lg:flex md:flex-none sm:flex-none mb-4",children:e.jsx("h5",{children:"Opportunity Stage"})}),e.jsx(te,{size:"sm",className:"mb-4 rounded-xl",placeholder:"Please Select",isMulti:!1,value:D,onChange:j=>R(j),options:O,isClearable:!0})]})]})})};G("opportunity",ve);G("LeadsData",lt);G("ContactsData",jt);const Fa=i=>{var Z,se,oe,H,re,J,_;const l=(i==null?void 0:i.accountId)||null,h=(i==null?void 0:i.leadId)||null,a=(i==null?void 0:i.leadData)||null,d=le(),N=Te(),{textTheme:w}=Be();F(t=>t.opportunity.data);const[D,R]=x.useState(!1),{IsDrawerOpen:O,type:k,selectedOpportunity:s,loading:M,metricData:y,filterData:c}=F(t=>t.opportunity.data),E=F(t=>t.opportunity.data.opportunityList),[j,I]=x.useState(!1),b=wt("Opportunities"),v={edit:b.isEdit,delete:b.isDelete,view:b.isView},S=t=>{d(Ee({IsDrawerOpen:!O,type:t}))},Y=t=>{I(!1)},de=t=>{I(!0)},P=t=>{N(`/app/crm/opportunity-details/${t}`)},ae=({type:t})=>{switch(t){case"allLeads":return e.jsx(W,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Ge,{})});case"Initial Contact":return e.jsx(W,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Fe,{})});case"Proposal":return e.jsx(W,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Fe,{})});case"Won":return e.jsx(W,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(qe,{})});case"Lost":return e.jsx(W,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Ve,{})});case"Negotiation":return e.jsx(W,{size:55,shape:"circle",className:"avatar-icon !bg-transparent !text-custom-600 dark:text-custom-100 rounded-lg border-1 border-slate-200 dark:border-custom-100",icon:e.jsx(Ue,{})});default:return e.jsx("div",{})}},ne=({value:t})=>e.jsxs("span",{className:"flex items-center rounded-full gap-1",children:[e.jsxs("span",{className:Re("rounded-full p-1",t>0&&"bg-emerald-100 text-emerald-600 dark:bg-emerald-500/20 dark:text-emerald-100",t<0&&"text-red-600 bg-red-100 dark:text-red-100 dark:bg-red-500/20"),children:[t>0&&e.jsx(Qe,{}),t<0&&e.jsx(Ke,{})]}),e.jsxs("span",{className:Re("font-semibold",t>0&&"text-emerald-600",t<0&&"text-red-600"),children:[t>0&&e.jsx(e.Fragment,{children:"+ "}),t]})]}),L=x.useCallback(()=>{var t,u,n;d(_e({...((t=c==null?void 0:c.opportunityStageId)==null?void 0:t.value)&&!l&&!h&&{opportunityStageId:c.opportunityStageId.value},...((u=c==null?void 0:c.accountId)==null?void 0:u.value)&&!l&&!h&&{accountId:c.accountId.value},...((n=c==null?void 0:c.leadId)==null?void 0:n.value)&&!l&&!h&&{leadId:c.leadId.value},...l&&{accountId:l},...h&&{leadId:h}}))},[d,c,l,h]);x.useEffect(()=>{L()},[L]);const Q=(t,u)=>{u===ye.view&&P(t.id),u===ye.edit&&(S("Edit"),d(Se(t))),u===ye.delete&&(d(we(!0)),d(Se(t)))},ue=[{dataField:"Action",caption:"Action",width:"130",allowSorting:!1,allowFiltering:!1,allowSearch:!1,cellRender:t=>e.jsx("div",{id:"mAction","data-cname":"Actions",children:e.jsx(Xe,{row:t==null?void 0:t.data,actions:v,buttonClick:Q})})},{dataField:"opportunityName",caption:"Opportunity Name",width:"230",cellRender:t=>{var u;return e.jsx("div",{"data-cname":"Opportunity Name",children:e.jsx(Ne,{to:`/app/crm/opportunity-details/${(u=t==null?void 0:t.data)==null?void 0:u.id}`,className:`${w} ml-2 rtl:mr-2`,children:t.value})})}},{dataField:"accountName",caption:"Account",width:"230",cellRender:t=>{var u;return l?e.jsx("div",{"data-cname":"Account",children:t.value}):e.jsx("div",{"data-cname":"Account",children:e.jsx(Ne,{to:`/app/crm/account-details/${(u=t==null?void 0:t.data)==null?void 0:u.accountId}`,className:`${w} ml-2 rtl:mr-2`,children:t.value})})}},{dataField:"contactName",caption:"Contact Name",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Contact Name",children:t.value})},{dataField:"stageName",caption:"Stage",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Stage",children:t.value})},{dataField:"estAnnualRevenue",caption:"Revenue",width:"230",cellRender:t=>{var u,n;return(u=t.data)!=null&&u.estAnnualRevenue?e.jsxs("div",{"data-cname":"Revenue",children:["$",(n=t.data)==null?void 0:n.estAnnualRevenue.toLocaleString()]}):e.jsx("div",{"data-cname":"Revenue"})}},{dataField:"confidencePercentage",caption:"Confidence",width:"230",dataType:"number",cellRender:t=>{var u,n;return(u=t.data)!=null&&u.confidencePercentage?e.jsxs("div",{"data-cname":"Confidence",children:[(n=t.data)==null?void 0:n.confidencePercentage," %"]}):e.jsx("div",{"data-cname":"Confidence"})}},{dataField:"potential",caption:"Potential Revenue",width:"230",cellRender:t=>{var u,n;return(u=t.data)!=null&&u.potential?e.jsxs("div",{"data-cname":"Confidence",children:["$",(n=t.data)==null?void 0:n.potential.toLocaleString()]}):e.jsx("div",{"data-cname":"Confidence"})}},{dataField:"noOfEmployees",caption:"No. of Employees",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"No. of Employees",children:t.value})},{dataField:"industry",caption:"Industry",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Industry",children:t.value})},{dataField:"serviceType",caption:"Service Type",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Service Type",children:t.value})},{dataField:"product",caption:"Product",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Product",children:t.value})},{dataField:"startDate",caption:"Start Date",width:"230",dataType:"date",format:"MM-dd-yyyy",cellRender:t=>{const u=t.value?fe(t.value).format("MM/DD/YYYY"):"";return e.jsx("div",{"data-cname":"Start Date",children:u})}},{dataField:"wonDate",caption:"Won Date",width:"230",dataType:"date",format:"MM/dd/yyyy",cellRender:t=>{const u=t.value?fe(t.value).format("MM/DD/YYYY"):"";return e.jsx("div",{"data-cname":"Won Date",children:u})}},{dataField:"notes",caption:"Notes",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Notes",children:t.value})},{dataField:"owner",caption:"Owner",width:"230",cellRender:t=>e.jsx("div",{"data-cname":"Owner",children:t.value})},{dataField:"createdDate",caption:"Created Date",width:"230",dataType:"date",format:"MM/dd/yyyy",cellRender:t=>{const u=t.value?fe(t.value).format("MM/DD/YYYY"):"";return e.jsx("div",{"data-cname":"Created Date",children:u})}}],pe=t=>t.map(u=>({...u,noOfEmployees:parseInt(u.noOfEmployees,10)||""})),me=ue.map(t=>({...t,cellRender:vt(t.cellRender)})),K=t=>{t==="accountId"&&d(U({...c,accountId:""})),t==="opportunityStageId"&&d(U({...c,opportunityStageId:""}))};x.useEffect(()=>{R(!(l||h))},[l,h]);const xe=k==="Edit",X=k==="Add"&&!!h,he=xe?{...s,leadId:{label:s==null?void 0:s.contactName,value:s==null?void 0:s.leadId},accountId:{label:s==null?void 0:s.accountName,value:(s==null?void 0:s.accountId)??null},ownerId:{label:s==null?void 0:s.owner,value:(s==null?void 0:s.ownerId)??null},opportunityStageId:{label:s==null?void 0:s.stageName,value:s==null?void 0:s.stageId},opportunitySourceId:{label:s==null?void 0:s.contactName,value:s==null?void 0:s.contactId},potentialRevenue:s==null?void 0:s.potential,industryId:(s==null?void 0:s.industry)??"",serviceTypeId:(s==null?void 0:s.serviceType)??"",productId:(s==null?void 0:s.product)??""}:X?{...a,leadId:{label:a==null?void 0:a.contactName,value:a==null?void 0:a.id},accountId:{label:a==null?void 0:a.accountName,value:(a==null?void 0:a.accountId)??null},ownerId:{label:(a==null?void 0:a.owner)??null,value:(a==null?void 0:a.ownerId)??null},industryId:a==null?void 0:a.industry,noOfEmployees:a==null?void 0:a.noOfEmployees,opportunitySourceId:{label:a==null?void 0:a.contactName,value:a==null?void 0:a.contactId,desc:{contactNumber:a==null?void 0:a.contactNumber,contactPosistion:(Z=a==null?void 0:a.contactPosition)==null?void 0:Z.positionName}},address:(a==null?void 0:a.address)??"",city:(a==null?void 0:a.city)??"",state:(a==null?void 0:a.state)??"",zip:(a==null?void 0:a.zip)??""}:void 0;return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:l?"topbar py-4 pt-0 border-gray-200 border-b dark:bg-[#292f3c] dark:text-white":"topbar py-4 px-6 border-gray-200 border-b dark:bg-[#292f3c] dark:text-white",children:e.jsxs("div",{className:"lg:flex items-center justify-between",children:[e.jsx("h3",{className:"mb-4 lg:mb-0",children:" Opportunities "}),e.jsxs("div",{className:"flex flex-col lg:flex-row lg:items-center",children:[b.isEdit&&e.jsx(q,{block:!0,variant:"solid",size:"sm",icon:e.jsx(We,{}),onClick:()=>S("Add"),children:"Add Opportunity"}),e.jsx(V,{title:`${k} Opportunity`,isOpen:O,onClose:()=>S("Add"),portalClassName:"w30",children:e.jsx(Pe,{footerWidth:"w30",type:k,fetchData:L,accountId:X?a==null?void 0:a.accountId:l,leadId:h,initialData:he,onFormSubmit:function(t,u){throw new Error("Function not implemented.")}})})]})]})}),M&&e.jsx($e,{sx:{backgroundColor:"rgba(0, 0, 0, 0.1)","& .MuiLinearProgress-bar":{backgroundColor:"var(--custom-600)"}}}),e.jsxs(je,{className:l||h?"h-full py-1 px-1 my-6 bg-transparent borderless":"m-6 h-full py-4 px-6 bg-transparent",children:[D&&e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 xl:grid-cols-6 gap-4 mb-5",children:[e.jsx(Ae,{className:`crm-card crm-stat-card ${(c==null?void 0:c.opportunityStageId)===""?"is-selected":""}`,onClick:()=>{d(U({opportunityStageId:"",accountId:""}))},children:e.jsxs("div",{className:"flex items-center flex-wrap",children:[e.jsx(ae,{type:"allLeads"}),e.jsxs("div",{children:[e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none truncate",children:(y==null?void 0:y.allOpportunities)??0}),e.jsx("p",{className:"font-semibold truncate",children:" Opportunities"})]}),e.jsxs("p",{className:"flex items-center gap-1 flex-wrap",children:[e.jsx(ne,{value:(y==null?void 0:y.allOpportunitiesGrowthRate)??0}),e.jsx("span",{children:"this month"})]})]})]})}),(oe=(se=y==null?void 0:y.stages)==null?void 0:se.$values)==null?void 0:oe.map((t,u)=>{var n;return e.jsx(Ae,{className:`crm-card crm-stat-card ${((n=c==null?void 0:c.opportunityStageId)==null?void 0:n.value)===t.stageId?"is-selected":""}`,onClick:()=>d(U({...c,opportunityStageId:{label:t==null?void 0:t.stageName,value:t.stageId}})),children:e.jsxs("div",{className:"flex items-center gap-1 flex-wrap",children:[e.jsx(ae,{type:t==null?void 0:t.stageName}),e.jsxs("div",{children:[e.jsxs("div",{className:"flex gap-1.5 items-end mb-2 flex-wrap",children:[e.jsx("h3",{className:"font-bold leading-none truncate",children:(t==null?void 0:t.totalCount)??0}),e.jsx("p",{className:"font-semibold truncate",children:t==null?void 0:t.stageName})]}),e.jsxs("p",{className:"flex items-center gap-1 flex-wrap",children:[e.jsx(ne,{value:t.growthRate??0}),e.jsx("span",{children:"this month"})]})]})]})},t.stageId)})]}),e.jsxs(je,{className:l||h?"p-0 borderless":"borderless",children:[!l&&e.jsxs("div",{className:"text-right mb-3 ",children:[((H=c==null?void 0:c.accountId)==null?void 0:H.value)&&e.jsx(ke,{title:"Account",value:(re=c==null?void 0:c.accountId)==null?void 0:re.label,onRemovefilter:K,tagId:"accountId"}),((J=c==null?void 0:c.opportunityStageId)==null?void 0:J.value)&&e.jsx(ke,{title:"Opportunity Stage",value:(_=c==null?void 0:c.opportunityStageId)==null?void 0:_.label,onRemovefilter:K,tagId:"opportunityStageId"})]}),e.jsx(Nt,{fetchData:L}),e.jsx(yt,{tableName:"Opportunities",className:"pt-2",dataSource:pe(E),height:l||h?"calc(100vh - 420px)":"calc(100vh - 400px)",columns:me||[],keyExpr:"$id",stateStorageKey:"opportunity",openFilter:de,isFilterReq:!0,isLoading:M})]})]}),e.jsx(At,{isOpen:j,onClose:Y})]})};export{Fa as default};
|