flowcore-fn 2.3.0 → 2.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/pkg-index.js CHANGED
@@ -30,6 +30,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
30
30
  // src/pkg-index.jsx
31
31
  var pkg_index_exports = {};
32
32
  __export(pkg_index_exports, {
33
+ Sidebar: () => Home,
33
34
  WorkflowPage: () => WorkflowPage
34
35
  });
35
36
  module.exports = __toCommonJS(pkg_index_exports);
@@ -434,7 +435,298 @@ var import_jsx_runtime4 = require("react/jsx-runtime");
434
435
  function WorkflowPage() {
435
436
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(WorkflowStep, {});
436
437
  }
438
+
439
+ // src/pages/Sidebar.js
440
+ var import_react6 = require("react");
441
+
442
+ // src/components/Sidebar.jsx
443
+ var import_react4 = require("react");
444
+ var import_react5 = require("@remixicon/react");
445
+ var import_router = require("next/router");
446
+ var import_jsx_runtime5 = require("react/jsx-runtime");
447
+ var workflowItems = [
448
+ { name: "Workflow Type", path: "/WorkflowType", icon: import_react5.RiGitMergeLine },
449
+ { name: "Workflow", path: "/workflow", icon: import_react5.RiNodeTree },
450
+ { name: "Workflow Step", path: "/workflowMaster", icon: import_react5.RiGitBranchLine },
451
+ { name: "Workflow Transition", path: "/TaskPermissionPage", icon: import_react5.RiCornerDownRightLine }
452
+ ];
453
+ var permissionItems = [
454
+ { name: "Task Permission", path: "/WorkflowType", icon: import_react5.RiUserSettingsLine },
455
+ { name: "Assignment Rule", path: "/WorkflowType", icon: import_react5.RiFileShieldLine }
456
+ ];
457
+ var hierarchyItems = [
458
+ { name: "Hierarchy Node", path: "/WorkflowType", icon: import_react5.RiNodeTree },
459
+ { name: "User Hierarchy Mapping", path: "/WorkflowType", icon: import_react5.RiUserSharedLine },
460
+ { name: "Workflow Settings", path: "/WorkflowType", icon: import_react5.RiSettings4Line }
461
+ ];
462
+ var documentItems = [
463
+ { name: "Document Configuration", path: "/WorkflowType", icon: import_react5.RiFileSettingsLine }
464
+ ];
465
+ var fileItems = [
466
+ { name: "File Instance", path: "/WorkflowType", icon: import_react5.RiFileList3Line },
467
+ { name: "File Pool", path: "/WorkflowType", icon: import_react5.RiDatabase2Line },
468
+ { name: "Uploaded Document", path: "/WorkflowType", icon: import_react5.RiFileUploadLine }
469
+ ];
470
+ var communicationItems = [
471
+ { name: "Notification", path: "/WorkflowType", icon: import_react5.RiNotification4Line },
472
+ { name: "Comment", path: "/WorkflowType", icon: import_react5.RiChat3Line }
473
+ ];
474
+ var taskItems = [
475
+ { name: "Task Instance", path: "/WorkflowType", icon: import_react5.RiCheckboxMultipleLine }
476
+ ];
477
+ var trackingItems = [
478
+ { name: "Audit Log", path: "/WorkflowType", icon: import_react5.RiShieldCheckLine },
479
+ { name: "Movement History", path: "/WorkflowType", icon: import_react5.RiHistoryLine }
480
+ ];
481
+ function Sidebar({ isOpen, onToggle }) {
482
+ const router = (0, import_router.useRouter)();
483
+ const [workflowOpen, setWorkflowOpen] = (0, import_react4.useState)(false);
484
+ const [permissionOpen, setPermissionOpen] = (0, import_react4.useState)(false);
485
+ const [hierarchyOpen, setHierarchyOpen] = (0, import_react4.useState)(false);
486
+ const [documentOpen, setDocumentOpen] = (0, import_react4.useState)(false);
487
+ const [filesOpen, setFilesOpen] = (0, import_react4.useState)(false);
488
+ const [tasksOpen, setTasksOpen] = (0, import_react4.useState)(false);
489
+ const [trackingOpen, setTrackingOpen] = (0, import_react4.useState)(false);
490
+ const [communicationOpen, setCommunicationOpen] = (0, import_react4.useState)(false);
491
+ const renderMenuItem = (item) => {
492
+ const Icon = item.icon;
493
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
494
+ "button",
495
+ {
496
+ type: "button",
497
+ className: `
498
+ flex h-[56px] w-full items-center gap-[17px]
499
+ rounded-[9px] px-[17px]
500
+ text-left transition-colors duration-150
501
+ ${router.pathname === item.path ? "bg-blue-50 text-blue-600" : "text-[#344261] hover:bg-[#F6F8FC]"}
502
+ `,
503
+ onClick: () => router.push(item.path),
504
+ children: [
505
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
506
+ "span",
507
+ {
508
+ className: "\r\n flex h-[20px] w-[20px] shrink-0\r\n items-center justify-center\r\n rounded-[6px] text-[#405170]\r\n ",
509
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Icon, { size: 17 })
510
+ }
511
+ ),
512
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "whitespace-nowrap text-[14px] font-medium leading-[22px]", children: item.name })
513
+ ]
514
+ },
515
+ item.name
516
+ );
517
+ };
518
+ const renderDropdown = (title, open, setOpen, items) => {
519
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "mb-2", children: [
520
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
521
+ "button",
522
+ {
523
+ type: "button",
524
+ onClick: () => setOpen(!open),
525
+ className: "\r\n flex h-[50px] w-full items-center justify-between\r\n rounded-[9px] px-[17px]\r\n text-left text-[#344261]\r\n transition-colors duration-150\r\n hover:bg-[#F6F8FC]\r\n ",
526
+ children: [
527
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "text-[16px] font-semibold", children: title }),
528
+ open ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react5.RiArrowDownSLine, { size: 18 }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react5.RiArrowRightSLine, { size: 18 })
529
+ ]
530
+ }
531
+ ),
532
+ open && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "ml-[8px] border-l border-[#E5E9F1] pl-[4px]", children: items.map(renderMenuItem) })
533
+ ] });
534
+ };
535
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
536
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
537
+ "aside",
538
+ {
539
+ className: `
540
+ flex h-screen flex-col overflow-hidden
541
+ border-r border-[#E5E9F1] bg-white
542
+ font-sans text-[#273657]
543
+ transition-all duration-300 ease-in-out
544
+ ${isOpen ? "w-[245px] min-w-[245px] translate-x-0 opacity-100" : "w-0 min-w-0 -translate-x-full opacity-0"}
545
+ `,
546
+ children: [
547
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
548
+ "header",
549
+ {
550
+ className: "\r\n flex h-[84px] items-center justify-between\r\n border-b border-[#EDF0F5]\r\n px-[14px]\r\n ",
551
+ children: [
552
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex items-center gap-2", children: [
553
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
554
+ "svg",
555
+ {
556
+ width: "36",
557
+ height: "42",
558
+ viewBox: "0 0 48 56",
559
+ fill: "none",
560
+ children: [
561
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
562
+ "path",
563
+ {
564
+ d: "M24 2L45 12.5L24 23L3 12.5L24 2Z",
565
+ fill: "#356AF3"
566
+ }
567
+ ),
568
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
569
+ "path",
570
+ {
571
+ d: "M24 8L34 13L24 18L14 13L24 8Z",
572
+ fill: "white"
573
+ }
574
+ ),
575
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
576
+ "path",
577
+ {
578
+ d: "M3 20L24 30.5L45 20V27L24 37.5L3 27V20Z",
579
+ fill: "#356AF3"
580
+ }
581
+ ),
582
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
583
+ "path",
584
+ {
585
+ d: "M3 33L24 43.5L45 33V40L24 50.5L3 40V33Z",
586
+ fill: "#356AF3"
587
+ }
588
+ )
589
+ ]
590
+ }
591
+ ),
592
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { children: [
593
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("h1", { className: "text-[18px] font-extrabold text-[#101318]", children: "FLOWCORE" }),
594
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "text-[12px] text-[#344261]", children: "Workflow Engine" })
595
+ ] })
596
+ ] }),
597
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
598
+ "button",
599
+ {
600
+ type: "button",
601
+ onClick: onToggle,
602
+ className: "\r\n flex h-8 w-8\r\n items-center justify-center\r\n rounded-lg\r\n hover:bg-gray-100\r\n ",
603
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react5.RiMenuLine, { size: 18 })
604
+ }
605
+ )
606
+ ]
607
+ }
608
+ ),
609
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
610
+ "div",
611
+ {
612
+ className: "\r\n min-h-0 flex-1\r\n overflow-y-auto overflow-x-hidden\r\n px-[27px] pb-[30px] pt-[31px]\r\n ",
613
+ children: [
614
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
615
+ "p",
616
+ {
617
+ className: "\r\n mb-[19px] ml-[15px]\r\n text-[14px] font-bold uppercase\r\n leading-[20px] tracking-[0.2px]\r\n text-[#3C4D74]\r\n ",
618
+ children: "Configuration Masters"
619
+ }
620
+ ),
621
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-col gap-[3px]", children: [
622
+ renderDropdown(
623
+ "Workflow",
624
+ workflowOpen,
625
+ setWorkflowOpen,
626
+ workflowItems
627
+ ),
628
+ renderDropdown(
629
+ "Permissions",
630
+ permissionOpen,
631
+ setPermissionOpen,
632
+ permissionItems
633
+ ),
634
+ renderDropdown(
635
+ "Documents",
636
+ documentOpen,
637
+ setDocumentOpen,
638
+ documentItems
639
+ ),
640
+ renderDropdown(
641
+ "Hierarchy",
642
+ hierarchyOpen,
643
+ setHierarchyOpen,
644
+ hierarchyItems
645
+ )
646
+ ] }),
647
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
648
+ "p",
649
+ {
650
+ className: "\r\n mb-[19px] ml-[15px] mt-[39px]\r\n text-[14px] font-bold uppercase\r\n leading-[20px] tracking-[0.2px]\r\n text-[#3C4D74]\r\n ",
651
+ children: "Runtime"
652
+ }
653
+ ),
654
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex flex-col gap-[3px]", children: [
655
+ renderDropdown(
656
+ "Files",
657
+ filesOpen,
658
+ setFilesOpen,
659
+ fileItems
660
+ ),
661
+ renderDropdown(
662
+ "Tasks",
663
+ tasksOpen,
664
+ setTasksOpen,
665
+ taskItems
666
+ ),
667
+ renderDropdown(
668
+ "Tracking",
669
+ trackingOpen,
670
+ setTrackingOpen,
671
+ trackingItems
672
+ ),
673
+ renderDropdown(
674
+ "Communication",
675
+ communicationOpen,
676
+ setCommunicationOpen,
677
+ communicationItems
678
+ )
679
+ ] })
680
+ ]
681
+ }
682
+ ),
683
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
684
+ "div",
685
+ {
686
+ className: "\r\n shrink-0\r\n bg-white\r\n px-[27px]\r\n pb-[34px]\r\n pt-[18px]\r\n ",
687
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
688
+ "button",
689
+ {
690
+ type: "button",
691
+ className: "\r\n flex h-[66px] w-full\r\n items-center gap-[18px]\r\n rounded-[10px]\r\n border border-[#E1E5ED]\r\n bg-white\r\n px-[23px]\r\n text-left\r\n text-[16px]\r\n font-semibold\r\n text-[#2D3A58]\r\n shadow-sm\r\n hover:bg-[#F7F8FC]\r\n transition\r\n ",
692
+ children: [
693
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react5.RiSettings4Line, { size: 20 }),
694
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: "Settings" })
695
+ ]
696
+ }
697
+ )
698
+ }
699
+ )
700
+ ]
701
+ }
702
+ ),
703
+ !isOpen && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
704
+ "button",
705
+ {
706
+ type: "button",
707
+ onClick: onToggle,
708
+ "aria-label": "Open sidebar",
709
+ className: "\r\n fixed left-[20px] top-[30px] z-[100]\r\n flex h-[46px] w-[46px]\r\n items-center justify-center\r\n rounded-[9px]\r\n border border-[#E1E5ED]\r\n bg-white text-[#344261]\r\n shadow-[0_2px_8px_rgba(0,0,0,0.08)]\r\n transition-colors\r\n hover:bg-[#F3F5F9]\r\n ",
710
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react5.RiMenuLine, { size: 18 })
711
+ }
712
+ )
713
+ ] });
714
+ }
715
+
716
+ // src/pages/Sidebar.js
717
+ var import_jsx_runtime6 = require("react/jsx-runtime");
718
+ function Home() {
719
+ const [isOpen, setIsOpen] = (0, import_react6.useState)(true);
720
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex h-screen", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
721
+ Sidebar,
722
+ {
723
+ isOpen,
724
+ onToggle: () => setIsOpen(!isOpen)
725
+ }
726
+ ) });
727
+ }
437
728
  // Annotate the CommonJS export names for ESM import in node:
438
729
  0 && (module.exports = {
730
+ Sidebar,
439
731
  WorkflowPage
440
732
  });
@@ -398,6 +398,318 @@ import { jsx as jsx4 } from "react/jsx-runtime";
398
398
  function WorkflowPage() {
399
399
  return /* @__PURE__ */ jsx4(WorkflowStep, {});
400
400
  }
401
+
402
+ // src/pages/Sidebar.js
403
+ import { useState as useState3 } from "react";
404
+
405
+ // src/components/Sidebar.jsx
406
+ import { useState as useState2 } from "react";
407
+ import {
408
+ RiMenuLine,
409
+ RiGitMergeLine,
410
+ RiNodeTree,
411
+ RiGitBranchLine,
412
+ RiCornerDownRightLine,
413
+ RiUserSettingsLine,
414
+ RiFileShieldLine,
415
+ RiUserSharedLine,
416
+ RiSettings4Line,
417
+ RiFileSettingsLine,
418
+ RiFileList3Line,
419
+ RiFileUploadLine,
420
+ RiNotification4Line,
421
+ RiDatabase2Line,
422
+ RiChat3Line,
423
+ RiCheckboxMultipleLine,
424
+ RiShieldCheckLine,
425
+ RiHistoryLine,
426
+ RiArrowDownSLine,
427
+ RiArrowRightSLine
428
+ } from "@remixicon/react";
429
+ import { useRouter } from "next/router";
430
+ import { Fragment, jsx as jsx5, jsxs as jsxs4 } from "react/jsx-runtime";
431
+ var workflowItems = [
432
+ { name: "Workflow Type", path: "/WorkflowType", icon: RiGitMergeLine },
433
+ { name: "Workflow", path: "/workflow", icon: RiNodeTree },
434
+ { name: "Workflow Step", path: "/workflowMaster", icon: RiGitBranchLine },
435
+ { name: "Workflow Transition", path: "/TaskPermissionPage", icon: RiCornerDownRightLine }
436
+ ];
437
+ var permissionItems = [
438
+ { name: "Task Permission", path: "/WorkflowType", icon: RiUserSettingsLine },
439
+ { name: "Assignment Rule", path: "/WorkflowType", icon: RiFileShieldLine }
440
+ ];
441
+ var hierarchyItems = [
442
+ { name: "Hierarchy Node", path: "/WorkflowType", icon: RiNodeTree },
443
+ { name: "User Hierarchy Mapping", path: "/WorkflowType", icon: RiUserSharedLine },
444
+ { name: "Workflow Settings", path: "/WorkflowType", icon: RiSettings4Line }
445
+ ];
446
+ var documentItems = [
447
+ { name: "Document Configuration", path: "/WorkflowType", icon: RiFileSettingsLine }
448
+ ];
449
+ var fileItems = [
450
+ { name: "File Instance", path: "/WorkflowType", icon: RiFileList3Line },
451
+ { name: "File Pool", path: "/WorkflowType", icon: RiDatabase2Line },
452
+ { name: "Uploaded Document", path: "/WorkflowType", icon: RiFileUploadLine }
453
+ ];
454
+ var communicationItems = [
455
+ { name: "Notification", path: "/WorkflowType", icon: RiNotification4Line },
456
+ { name: "Comment", path: "/WorkflowType", icon: RiChat3Line }
457
+ ];
458
+ var taskItems = [
459
+ { name: "Task Instance", path: "/WorkflowType", icon: RiCheckboxMultipleLine }
460
+ ];
461
+ var trackingItems = [
462
+ { name: "Audit Log", path: "/WorkflowType", icon: RiShieldCheckLine },
463
+ { name: "Movement History", path: "/WorkflowType", icon: RiHistoryLine }
464
+ ];
465
+ function Sidebar({ isOpen, onToggle }) {
466
+ const router = useRouter();
467
+ const [workflowOpen, setWorkflowOpen] = useState2(false);
468
+ const [permissionOpen, setPermissionOpen] = useState2(false);
469
+ const [hierarchyOpen, setHierarchyOpen] = useState2(false);
470
+ const [documentOpen, setDocumentOpen] = useState2(false);
471
+ const [filesOpen, setFilesOpen] = useState2(false);
472
+ const [tasksOpen, setTasksOpen] = useState2(false);
473
+ const [trackingOpen, setTrackingOpen] = useState2(false);
474
+ const [communicationOpen, setCommunicationOpen] = useState2(false);
475
+ const renderMenuItem = (item) => {
476
+ const Icon = item.icon;
477
+ return /* @__PURE__ */ jsxs4(
478
+ "button",
479
+ {
480
+ type: "button",
481
+ className: `
482
+ flex h-[56px] w-full items-center gap-[17px]
483
+ rounded-[9px] px-[17px]
484
+ text-left transition-colors duration-150
485
+ ${router.pathname === item.path ? "bg-blue-50 text-blue-600" : "text-[#344261] hover:bg-[#F6F8FC]"}
486
+ `,
487
+ onClick: () => router.push(item.path),
488
+ children: [
489
+ /* @__PURE__ */ jsx5(
490
+ "span",
491
+ {
492
+ className: "\r\n flex h-[20px] w-[20px] shrink-0\r\n items-center justify-center\r\n rounded-[6px] text-[#405170]\r\n ",
493
+ children: /* @__PURE__ */ jsx5(Icon, { size: 17 })
494
+ }
495
+ ),
496
+ /* @__PURE__ */ jsx5("span", { className: "whitespace-nowrap text-[14px] font-medium leading-[22px]", children: item.name })
497
+ ]
498
+ },
499
+ item.name
500
+ );
501
+ };
502
+ const renderDropdown = (title, open, setOpen, items) => {
503
+ return /* @__PURE__ */ jsxs4("div", { className: "mb-2", children: [
504
+ /* @__PURE__ */ jsxs4(
505
+ "button",
506
+ {
507
+ type: "button",
508
+ onClick: () => setOpen(!open),
509
+ className: "\r\n flex h-[50px] w-full items-center justify-between\r\n rounded-[9px] px-[17px]\r\n text-left text-[#344261]\r\n transition-colors duration-150\r\n hover:bg-[#F6F8FC]\r\n ",
510
+ children: [
511
+ /* @__PURE__ */ jsx5("span", { className: "text-[16px] font-semibold", children: title }),
512
+ open ? /* @__PURE__ */ jsx5(RiArrowDownSLine, { size: 18 }) : /* @__PURE__ */ jsx5(RiArrowRightSLine, { size: 18 })
513
+ ]
514
+ }
515
+ ),
516
+ open && /* @__PURE__ */ jsx5("div", { className: "ml-[8px] border-l border-[#E5E9F1] pl-[4px]", children: items.map(renderMenuItem) })
517
+ ] });
518
+ };
519
+ return /* @__PURE__ */ jsxs4(Fragment, { children: [
520
+ /* @__PURE__ */ jsxs4(
521
+ "aside",
522
+ {
523
+ className: `
524
+ flex h-screen flex-col overflow-hidden
525
+ border-r border-[#E5E9F1] bg-white
526
+ font-sans text-[#273657]
527
+ transition-all duration-300 ease-in-out
528
+ ${isOpen ? "w-[245px] min-w-[245px] translate-x-0 opacity-100" : "w-0 min-w-0 -translate-x-full opacity-0"}
529
+ `,
530
+ children: [
531
+ /* @__PURE__ */ jsxs4(
532
+ "header",
533
+ {
534
+ className: "\r\n flex h-[84px] items-center justify-between\r\n border-b border-[#EDF0F5]\r\n px-[14px]\r\n ",
535
+ children: [
536
+ /* @__PURE__ */ jsxs4("div", { className: "flex items-center gap-2", children: [
537
+ /* @__PURE__ */ jsxs4(
538
+ "svg",
539
+ {
540
+ width: "36",
541
+ height: "42",
542
+ viewBox: "0 0 48 56",
543
+ fill: "none",
544
+ children: [
545
+ /* @__PURE__ */ jsx5(
546
+ "path",
547
+ {
548
+ d: "M24 2L45 12.5L24 23L3 12.5L24 2Z",
549
+ fill: "#356AF3"
550
+ }
551
+ ),
552
+ /* @__PURE__ */ jsx5(
553
+ "path",
554
+ {
555
+ d: "M24 8L34 13L24 18L14 13L24 8Z",
556
+ fill: "white"
557
+ }
558
+ ),
559
+ /* @__PURE__ */ jsx5(
560
+ "path",
561
+ {
562
+ d: "M3 20L24 30.5L45 20V27L24 37.5L3 27V20Z",
563
+ fill: "#356AF3"
564
+ }
565
+ ),
566
+ /* @__PURE__ */ jsx5(
567
+ "path",
568
+ {
569
+ d: "M3 33L24 43.5L45 33V40L24 50.5L3 40V33Z",
570
+ fill: "#356AF3"
571
+ }
572
+ )
573
+ ]
574
+ }
575
+ ),
576
+ /* @__PURE__ */ jsxs4("div", { children: [
577
+ /* @__PURE__ */ jsx5("h1", { className: "text-[18px] font-extrabold text-[#101318]", children: "FLOWCORE" }),
578
+ /* @__PURE__ */ jsx5("p", { className: "text-[12px] text-[#344261]", children: "Workflow Engine" })
579
+ ] })
580
+ ] }),
581
+ /* @__PURE__ */ jsx5(
582
+ "button",
583
+ {
584
+ type: "button",
585
+ onClick: onToggle,
586
+ className: "\r\n flex h-8 w-8\r\n items-center justify-center\r\n rounded-lg\r\n hover:bg-gray-100\r\n ",
587
+ children: /* @__PURE__ */ jsx5(RiMenuLine, { size: 18 })
588
+ }
589
+ )
590
+ ]
591
+ }
592
+ ),
593
+ /* @__PURE__ */ jsxs4(
594
+ "div",
595
+ {
596
+ className: "\r\n min-h-0 flex-1\r\n overflow-y-auto overflow-x-hidden\r\n px-[27px] pb-[30px] pt-[31px]\r\n ",
597
+ children: [
598
+ /* @__PURE__ */ jsx5(
599
+ "p",
600
+ {
601
+ className: "\r\n mb-[19px] ml-[15px]\r\n text-[14px] font-bold uppercase\r\n leading-[20px] tracking-[0.2px]\r\n text-[#3C4D74]\r\n ",
602
+ children: "Configuration Masters"
603
+ }
604
+ ),
605
+ /* @__PURE__ */ jsxs4("div", { className: "flex flex-col gap-[3px]", children: [
606
+ renderDropdown(
607
+ "Workflow",
608
+ workflowOpen,
609
+ setWorkflowOpen,
610
+ workflowItems
611
+ ),
612
+ renderDropdown(
613
+ "Permissions",
614
+ permissionOpen,
615
+ setPermissionOpen,
616
+ permissionItems
617
+ ),
618
+ renderDropdown(
619
+ "Documents",
620
+ documentOpen,
621
+ setDocumentOpen,
622
+ documentItems
623
+ ),
624
+ renderDropdown(
625
+ "Hierarchy",
626
+ hierarchyOpen,
627
+ setHierarchyOpen,
628
+ hierarchyItems
629
+ )
630
+ ] }),
631
+ /* @__PURE__ */ jsx5(
632
+ "p",
633
+ {
634
+ className: "\r\n mb-[19px] ml-[15px] mt-[39px]\r\n text-[14px] font-bold uppercase\r\n leading-[20px] tracking-[0.2px]\r\n text-[#3C4D74]\r\n ",
635
+ children: "Runtime"
636
+ }
637
+ ),
638
+ /* @__PURE__ */ jsxs4("div", { className: "flex flex-col gap-[3px]", children: [
639
+ renderDropdown(
640
+ "Files",
641
+ filesOpen,
642
+ setFilesOpen,
643
+ fileItems
644
+ ),
645
+ renderDropdown(
646
+ "Tasks",
647
+ tasksOpen,
648
+ setTasksOpen,
649
+ taskItems
650
+ ),
651
+ renderDropdown(
652
+ "Tracking",
653
+ trackingOpen,
654
+ setTrackingOpen,
655
+ trackingItems
656
+ ),
657
+ renderDropdown(
658
+ "Communication",
659
+ communicationOpen,
660
+ setCommunicationOpen,
661
+ communicationItems
662
+ )
663
+ ] })
664
+ ]
665
+ }
666
+ ),
667
+ /* @__PURE__ */ jsx5(
668
+ "div",
669
+ {
670
+ className: "\r\n shrink-0\r\n bg-white\r\n px-[27px]\r\n pb-[34px]\r\n pt-[18px]\r\n ",
671
+ children: /* @__PURE__ */ jsxs4(
672
+ "button",
673
+ {
674
+ type: "button",
675
+ className: "\r\n flex h-[66px] w-full\r\n items-center gap-[18px]\r\n rounded-[10px]\r\n border border-[#E1E5ED]\r\n bg-white\r\n px-[23px]\r\n text-left\r\n text-[16px]\r\n font-semibold\r\n text-[#2D3A58]\r\n shadow-sm\r\n hover:bg-[#F7F8FC]\r\n transition\r\n ",
676
+ children: [
677
+ /* @__PURE__ */ jsx5(RiSettings4Line, { size: 20 }),
678
+ /* @__PURE__ */ jsx5("span", { children: "Settings" })
679
+ ]
680
+ }
681
+ )
682
+ }
683
+ )
684
+ ]
685
+ }
686
+ ),
687
+ !isOpen && /* @__PURE__ */ jsx5(
688
+ "button",
689
+ {
690
+ type: "button",
691
+ onClick: onToggle,
692
+ "aria-label": "Open sidebar",
693
+ className: "\r\n fixed left-[20px] top-[30px] z-[100]\r\n flex h-[46px] w-[46px]\r\n items-center justify-center\r\n rounded-[9px]\r\n border border-[#E1E5ED]\r\n bg-white text-[#344261]\r\n shadow-[0_2px_8px_rgba(0,0,0,0.08)]\r\n transition-colors\r\n hover:bg-[#F3F5F9]\r\n ",
694
+ children: /* @__PURE__ */ jsx5(RiMenuLine, { size: 18 })
695
+ }
696
+ )
697
+ ] });
698
+ }
699
+
700
+ // src/pages/Sidebar.js
701
+ import { jsx as jsx6 } from "react/jsx-runtime";
702
+ function Home() {
703
+ const [isOpen, setIsOpen] = useState3(true);
704
+ return /* @__PURE__ */ jsx6("div", { className: "flex h-screen", children: /* @__PURE__ */ jsx6(
705
+ Sidebar,
706
+ {
707
+ isOpen,
708
+ onToggle: () => setIsOpen(!isOpen)
709
+ }
710
+ ) });
711
+ }
401
712
  export {
713
+ Home as Sidebar,
402
714
  WorkflowPage
403
715
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flowcore-fn",
3
- "version": "2.3.0",
3
+ "version": "2.5.0",
4
4
 
5
5
  "main": "dist/pkg-index.js",
6
6
  "module": "dist/pkg-index.mjs",