nvis-fe-cms-libs 1.0.0 → 1.0.1
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.
|
@@ -618,12 +618,432 @@
|
|
|
618
618
|
)
|
|
619
619
|
] });
|
|
620
620
|
};
|
|
621
|
+
const TimelineSection = ({ data, t, isDarkMode }) => {
|
|
622
|
+
var _a;
|
|
623
|
+
const timelineData = ((_a = data == null ? void 0 : data.sectionDataBindingItems) == null ? void 0 : _a.map((item) => item.data)) || [];
|
|
624
|
+
const [timelineVisible, setTimelineVisible] = require$$0.useState([]);
|
|
625
|
+
const timelineRefs = require$$0.useRef([]);
|
|
626
|
+
require$$0.useEffect(() => {
|
|
627
|
+
setTimelineVisible(new Array(timelineData.length).fill(false));
|
|
628
|
+
}, [timelineData.length]);
|
|
629
|
+
require$$0.useEffect(() => {
|
|
630
|
+
const observer = new IntersectionObserver(
|
|
631
|
+
(entries) => {
|
|
632
|
+
entries.forEach((entry) => {
|
|
633
|
+
if (entry.isIntersecting) {
|
|
634
|
+
const index2 = timelineRefs.current.findIndex((el) => el === entry.target);
|
|
635
|
+
if (index2 !== -1) {
|
|
636
|
+
setTimelineVisible((prev) => {
|
|
637
|
+
const newVisible = [...prev];
|
|
638
|
+
newVisible[index2] = true;
|
|
639
|
+
return newVisible;
|
|
640
|
+
});
|
|
641
|
+
}
|
|
642
|
+
observer.unobserve(entry.target);
|
|
643
|
+
}
|
|
644
|
+
});
|
|
645
|
+
},
|
|
646
|
+
{ threshold: 0.1 }
|
|
647
|
+
);
|
|
648
|
+
timelineRefs.current.forEach((el) => el && observer.observe(el));
|
|
649
|
+
return () => {
|
|
650
|
+
timelineRefs.current.forEach((el) => el && observer.unobserve(el));
|
|
651
|
+
};
|
|
652
|
+
}, [timelineData.length]);
|
|
653
|
+
if (!timelineData.length) {
|
|
654
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("section", { className: `py-20 ${isDarkMode ? "bg-gray-900/50" : "bg-white"}`, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "max-w-7xl mx-auto px-4 text-center", children: [
|
|
655
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: `text-lg font-semibold mb-2 ${isDarkMode ? "text-white" : "text-gray-900"}`, children: t("timeline.noData.title") || "Chưa có dữ liệu" }),
|
|
656
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: `${isDarkMode ? "text-gray-300" : "text-gray-600"}`, children: t("timeline.noData.description") || "Hiện tại chưa có milestone nào được thiết lập." })
|
|
657
|
+
] }) });
|
|
658
|
+
}
|
|
659
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("section", { className: `py-20 ${isDarkMode ? "bg-gray-800" : "bg-white"}`, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "max-w-7xl mx-auto px-4 sm:px-6 lg:px-8", children: [
|
|
660
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "text-center mb-12", children: [
|
|
661
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
662
|
+
"div",
|
|
663
|
+
{
|
|
664
|
+
className: `relative inline-block px-4 py-2 rounded-full text-sm font-semibold mb-4 border transition-all duration-300 transform hover:scale-105 shadow-md hover:shadow-lg overflow-hidden ${isDarkMode ? "bg-gradient-to-br from-slate-900 via-blue-900 to-indigo-900 text-emerald-300 border-blue-800" : "bg-white text-emerald-800 border-gray-200"}`,
|
|
665
|
+
children: [
|
|
666
|
+
"📈 ",
|
|
667
|
+
t("timeline.header.badge") || "HÀNH TRÌNH PHÁT TRIỂN",
|
|
668
|
+
isDarkMode && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
669
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
670
|
+
"div",
|
|
671
|
+
{
|
|
672
|
+
className: "absolute w-12 h-12 bg-white/5 rounded-full",
|
|
673
|
+
style: { left: "10%", top: "20%" }
|
|
674
|
+
}
|
|
675
|
+
),
|
|
676
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
677
|
+
"div",
|
|
678
|
+
{
|
|
679
|
+
className: "absolute w-10 h-10 bg-white/5 rounded-full",
|
|
680
|
+
style: { right: "30%", bottom: "10%" }
|
|
681
|
+
}
|
|
682
|
+
),
|
|
683
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
684
|
+
"div",
|
|
685
|
+
{
|
|
686
|
+
className: "absolute w-14 h-14 bg-white/5 rounded-md",
|
|
687
|
+
style: { left: "20%", bottom: "30%" }
|
|
688
|
+
}
|
|
689
|
+
),
|
|
690
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
691
|
+
"div",
|
|
692
|
+
{
|
|
693
|
+
className: 'absolute inset-0 bg-[url("data:image/svg+xml,%3Csvg width=\\\\\\"60\\\\\\" height=\\\\\\"60\\\\\\" viewBox=\\\\\\"0 0 60 60\\\\\\" xmlns=\\\\\\"http://www.w3.org/2000/svg\\\\\\"%3E%3Cg fill=\\\\\\"none\\\\\\" fill-rule=\\\\\\"evenodd\\\\\\"%3E%3Cg fill=\\\\\\"%23ffffff\\\\\\" fill-opacity=\\\\\\"0.05\\\\\\"%3E%3Ccircle cx=\\\\\\"30\\\\\\" cy=\\\\\\"30\\\\\\" r=\\\\\\"2\\\\\\"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E")] opacity-20'
|
|
694
|
+
}
|
|
695
|
+
)
|
|
696
|
+
] })
|
|
697
|
+
]
|
|
698
|
+
}
|
|
699
|
+
),
|
|
700
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
701
|
+
"h2",
|
|
702
|
+
{
|
|
703
|
+
className: `text-3xl lg:text-4xl font-bold mb-4 ${isDarkMode ? "text-white" : "text-gray-900"}`,
|
|
704
|
+
children: [
|
|
705
|
+
t("timeline.header.title1") || "Những cột mốc",
|
|
706
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "block bg-gradient-to-r from-emerald-600 to-teal-600 bg-clip-text text-transparent", children: t("timeline.header.title2") || "Quan trọng" })
|
|
707
|
+
]
|
|
708
|
+
}
|
|
709
|
+
)
|
|
710
|
+
] }),
|
|
711
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative", children: [
|
|
712
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute left-1/2 transform -translate-x-1/2 w-1 h-full bg-gradient-to-b from-blue-500 to-purple-600 rounded-full" }),
|
|
713
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "space-y-8", children: timelineData.map((milestone, index2) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
714
|
+
"div",
|
|
715
|
+
{
|
|
716
|
+
ref: (el) => timelineRefs.current[index2] = el,
|
|
717
|
+
className: `flex items-center transition-all duration-700 ease-out ${index2 % 2 === 0 ? "flex-row" : "flex-row-reverse"} ${timelineVisible[index2] ? "opacity-100 scale-100" : "opacity-0 scale-75"}`,
|
|
718
|
+
style: { transitionDelay: `${index2 * 200}ms` },
|
|
719
|
+
children: [
|
|
720
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1 px-8", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
721
|
+
"div",
|
|
722
|
+
{
|
|
723
|
+
className: `relative p-5 rounded-xl shadow-lg transition-all duration-300 hover:shadow-xl overflow-hidden ${isDarkMode ? "bg-gradient-to-br from-slate-900 via-blue-900 to-indigo-900 border border-blue-800 hover:border-blue-600" : "bg-gray-50 hover:shadow-2xl"}`,
|
|
724
|
+
children: [
|
|
725
|
+
isDarkMode && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
726
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
727
|
+
"div",
|
|
728
|
+
{
|
|
729
|
+
className: "absolute w-12 h-12 bg-white/5 rounded-full",
|
|
730
|
+
style: { left: "10%", top: "20%" }
|
|
731
|
+
}
|
|
732
|
+
),
|
|
733
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
734
|
+
"div",
|
|
735
|
+
{
|
|
736
|
+
className: "absolute w-10 h-10 bg-white/5 rounded-full",
|
|
737
|
+
style: { right: "30%", bottom: "10%" }
|
|
738
|
+
}
|
|
739
|
+
),
|
|
740
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
741
|
+
"div",
|
|
742
|
+
{
|
|
743
|
+
className: "absolute w-14 h-14 bg-white/5 rounded-md",
|
|
744
|
+
style: { left: "20%", bottom: "30%" }
|
|
745
|
+
}
|
|
746
|
+
),
|
|
747
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
748
|
+
"div",
|
|
749
|
+
{
|
|
750
|
+
className: 'absolute inset-0 bg-[url("data:image/svg+xml,%3Csvg width=\\\\\\"60\\\\\\" height=\\\\\\"60\\\\\\" viewBox=\\\\\\"0 0 60 60\\\\\\" xmlns=\\\\\\"http://www.w3.org/2000/svg\\\\\\"%3E%3Cg fill=\\\\\\"none\\\\\\" fill-rule=\\\\\\"evenodd\\\\\\"%3E%3Cg fill=\\\\\\"%23ffffff\\\\\\" fill-opacity=\\\\\\"0.05\\\\\\"%3E%3Ccircle cx=\\\\\\"30\\\\\\" cy=\\\\\\"30\\\\\\" r=\\\\\\"2\\\\\\"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E")] opacity-20'
|
|
751
|
+
}
|
|
752
|
+
)
|
|
753
|
+
] }),
|
|
754
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-blue-600 font-bold text-xl mb-2", children: milestone.year }),
|
|
755
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
756
|
+
"h3",
|
|
757
|
+
{
|
|
758
|
+
className: `text-lg font-bold mb-2 ${isDarkMode ? "text-white" : "text-gray-900"}`,
|
|
759
|
+
children: milestone.title
|
|
760
|
+
}
|
|
761
|
+
),
|
|
762
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
763
|
+
"p",
|
|
764
|
+
{
|
|
765
|
+
className: `${isDarkMode ? "text-gray-300" : "text-gray-600"}`,
|
|
766
|
+
children: milestone.description
|
|
767
|
+
}
|
|
768
|
+
)
|
|
769
|
+
]
|
|
770
|
+
}
|
|
771
|
+
) }),
|
|
772
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
773
|
+
"div",
|
|
774
|
+
{
|
|
775
|
+
className: `w-6 h-6 bg-gradient-to-r from-blue-500 to-purple-600 rounded-full border-4 ${isDarkMode ? "border-gray-800" : "border-white"} shadow-[0_0_10px_5px_rgba(59,130,246,0.5)] flex-shrink-0 z-10 animate-pulse`
|
|
776
|
+
}
|
|
777
|
+
),
|
|
778
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1" })
|
|
779
|
+
]
|
|
780
|
+
},
|
|
781
|
+
index2
|
|
782
|
+
)) })
|
|
783
|
+
] })
|
|
784
|
+
] }) });
|
|
785
|
+
};
|
|
786
|
+
const PartnerCard = ({ partner, idx, t, getLogoUrl, isDarkMode }) => {
|
|
787
|
+
const itemRef = require$$0.useRef(null);
|
|
788
|
+
const [visible, setVisible] = require$$0.useState(false);
|
|
789
|
+
require$$0.useEffect(() => {
|
|
790
|
+
const observer = new IntersectionObserver(
|
|
791
|
+
(entries) => {
|
|
792
|
+
entries.forEach((entry) => {
|
|
793
|
+
if (entry.isIntersecting) {
|
|
794
|
+
setVisible(true);
|
|
795
|
+
observer.unobserve(entry.target);
|
|
796
|
+
}
|
|
797
|
+
});
|
|
798
|
+
},
|
|
799
|
+
{ threshold: 0.2 }
|
|
800
|
+
);
|
|
801
|
+
if (itemRef.current) observer.observe(itemRef.current);
|
|
802
|
+
return () => itemRef.current && observer.unobserve(itemRef.current);
|
|
803
|
+
}, []);
|
|
804
|
+
const logoSrc = getLogoUrl(partner.logoUrl);
|
|
805
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
806
|
+
"div",
|
|
807
|
+
{
|
|
808
|
+
ref: itemRef,
|
|
809
|
+
className: `partner-card relative flex flex-col items-center justify-center p-4 rounded-xl shadow-sm transition-all duration-700 ease-out cursor-pointer overflow-hidden
|
|
810
|
+
${isDarkMode ? "bg-gradient-to-br from-slate-900 via-blue-900 to-indigo-900 border border-blue-800 hover:border-blue-500" : "bg-white border border-gray-200 hover:border-blue-300"}
|
|
811
|
+
${visible ? "opacity-100 scale-100" : "opacity-0 scale-75"}`,
|
|
812
|
+
style: { transitionDelay: `${idx * 150}ms` },
|
|
813
|
+
onClick: () => partner.websiteUrl && window.open(partner.websiteUrl, "_blank"),
|
|
814
|
+
children: [
|
|
815
|
+
isDarkMode && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
816
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
817
|
+
"div",
|
|
818
|
+
{
|
|
819
|
+
className: "absolute w-12 h-12 bg-white/5 rounded-full",
|
|
820
|
+
style: { left: "10%", top: "20%" }
|
|
821
|
+
}
|
|
822
|
+
),
|
|
823
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
824
|
+
"div",
|
|
825
|
+
{
|
|
826
|
+
className: "absolute w-10 h-10 bg-white/5 rounded-full",
|
|
827
|
+
style: { right: "30%", bottom: "10%" }
|
|
828
|
+
}
|
|
829
|
+
),
|
|
830
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
831
|
+
"div",
|
|
832
|
+
{
|
|
833
|
+
className: "absolute w-14 h-14 bg-white/5 rounded-md",
|
|
834
|
+
style: { left: "20%", bottom: "30%" }
|
|
835
|
+
}
|
|
836
|
+
),
|
|
837
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
838
|
+
"div",
|
|
839
|
+
{
|
|
840
|
+
className: 'absolute inset-0 bg-[url("data:image/svg+xml,%3Csvg width=\\\\\\"60\\\\\\" height=\\\\\\"60\\\\\\" viewBox=\\\\\\"0 0 60 60\\\\\\" xmlns=\\\\\\"http://www.w3.org/2000/svg\\\\\\"%3E%3Cg fill=\\\\\\"none\\\\\\" fill-rule=\\\\\\"evenodd\\\\\\"%3E%3Cg fill=\\\\\\"%23ffffff\\\\\\" fill-opacity=\\\\\\"0.05\\\\\\"%3E%3Ccircle cx=\\\\\\"30\\\\\\" cy=\\\\\\"30\\\\\\" r=\\\\\\"2\\\\\\"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E")] opacity-20'
|
|
841
|
+
}
|
|
842
|
+
)
|
|
843
|
+
] }),
|
|
844
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "logo-container w-20 h-14 flex items-center justify-center mb-4 rounded-lg overflow-hidden", children: logoSrc ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
845
|
+
"img",
|
|
846
|
+
{
|
|
847
|
+
src: logoSrc,
|
|
848
|
+
alt: partner.name,
|
|
849
|
+
className: "logo-image max-w-full max-h-full object-contain"
|
|
850
|
+
}
|
|
851
|
+
) : /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "w-full h-full bg-gradient-to-br from-blue-500 to-purple-600 flex items-center justify-center", children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-white font-bold text-center text-sm px-1", children: partner.name }) }) }),
|
|
852
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
853
|
+
"h4",
|
|
854
|
+
{
|
|
855
|
+
className: `font-bold text-center mb-2 ${isDarkMode ? "text-white" : "text-gray-900"}`,
|
|
856
|
+
children: partner.name
|
|
857
|
+
}
|
|
858
|
+
),
|
|
859
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
860
|
+
"p",
|
|
861
|
+
{
|
|
862
|
+
className: `text-sm text-center mb-2 ${isDarkMode ? "text-gray-300" : "text-gray-600"}`,
|
|
863
|
+
children: partner.description
|
|
864
|
+
}
|
|
865
|
+
),
|
|
866
|
+
partner.websiteUrl && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "website-hint", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "text-sm text-blue-600 font-medium", children: [
|
|
867
|
+
t("partners.viewDetails") || "Xem chi tiết",
|
|
868
|
+
" →"
|
|
869
|
+
] }) }),
|
|
870
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("style", { jsx: true, children: `
|
|
871
|
+
.partner-card {
|
|
872
|
+
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
873
|
+
}
|
|
874
|
+
.partner-card:hover {
|
|
875
|
+
transform: translateY(-3px);
|
|
876
|
+
box-shadow: 0 8px 20px ${isDarkMode ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)"};
|
|
877
|
+
}
|
|
878
|
+
.logo-container {
|
|
879
|
+
background: ${isDarkMode ? "linear-gradient(135deg, #374151 0%, #1f2937 100%)" : "linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%)"};
|
|
880
|
+
border: 1px solid ${isDarkMode ? "#4b5563" : "#e2e8f0"};
|
|
881
|
+
transition: all 0.3s ease;
|
|
882
|
+
}
|
|
883
|
+
.partner-card:hover .logo-container {
|
|
884
|
+
border-color: #3b82f6;
|
|
885
|
+
background: ${isDarkMode ? "linear-gradient(135deg, #4b5563 0%, #374151 100%)" : "linear-gradient(135deg, #ffffff 0%, #f8fafc 100%)"};
|
|
886
|
+
}
|
|
887
|
+
.logo-image {
|
|
888
|
+
filter: ${isDarkMode ? "grayscale(0.3) opacity(0.8)" : "grayscale(0.2) opacity(0.9)"};
|
|
889
|
+
transition: all 0.3s ease;
|
|
890
|
+
}
|
|
891
|
+
.partner-card:hover .logo-image {
|
|
892
|
+
filter: grayscale(0) opacity(1);
|
|
893
|
+
transform: scale(1.05);
|
|
894
|
+
}
|
|
895
|
+
.website-hint {
|
|
896
|
+
opacity: 0;
|
|
897
|
+
transform: translateY(4px);
|
|
898
|
+
transition: all 0.3s ease;
|
|
899
|
+
}
|
|
900
|
+
.partner-card:hover .website-hint {
|
|
901
|
+
opacity: 1;
|
|
902
|
+
transform: translateY(0);
|
|
903
|
+
}
|
|
904
|
+
` })
|
|
905
|
+
]
|
|
906
|
+
}
|
|
907
|
+
);
|
|
908
|
+
};
|
|
909
|
+
function useWindowSize() {
|
|
910
|
+
const [width, setWidth] = require$$0.useState(
|
|
911
|
+
typeof window !== "undefined" ? window.innerWidth : 1200
|
|
912
|
+
);
|
|
913
|
+
require$$0.useEffect(() => {
|
|
914
|
+
if (typeof window === "undefined") return;
|
|
915
|
+
const handleResize = () => setWidth(window.innerWidth);
|
|
916
|
+
window.addEventListener("resize", handleResize);
|
|
917
|
+
return () => window.removeEventListener("resize", handleResize);
|
|
918
|
+
}, []);
|
|
919
|
+
return width;
|
|
920
|
+
}
|
|
921
|
+
const PartnersSection = ({ data, t, isDarkMode, imageBaseUrl = "" }) => {
|
|
922
|
+
var _a;
|
|
923
|
+
const partnersData = ((_a = data == null ? void 0 : data.sectionDataBindingItems) == null ? void 0 : _a.map((item) => item.data)) || [];
|
|
924
|
+
const [currentPartnerSlide, setCurrentPartnerSlide] = require$$0.useState(0);
|
|
925
|
+
const [partnersVisible, setPartnersVisible] = require$$0.useState(false);
|
|
926
|
+
const partnersRef = require$$0.useRef(null);
|
|
927
|
+
const windowWidth = useWindowSize();
|
|
928
|
+
const getLogoUrl = (logoUrl) => {
|
|
929
|
+
if (!logoUrl) return null;
|
|
930
|
+
if (logoUrl.startsWith("http")) return logoUrl;
|
|
931
|
+
return `${imageBaseUrl}${logoUrl}`;
|
|
932
|
+
};
|
|
933
|
+
const partners = require$$0.useMemo(() => {
|
|
934
|
+
const getPerSlide = () => {
|
|
935
|
+
if (windowWidth < 640) return 2;
|
|
936
|
+
if (windowWidth < 1024) return 3;
|
|
937
|
+
return 4;
|
|
938
|
+
};
|
|
939
|
+
const grouped = [];
|
|
940
|
+
const perSlide = getPerSlide();
|
|
941
|
+
for (let i = 0; i < partnersData.length; i += perSlide) {
|
|
942
|
+
grouped.push(partnersData.slice(i, i + perSlide));
|
|
943
|
+
}
|
|
944
|
+
return grouped;
|
|
945
|
+
}, [partnersData, windowWidth]);
|
|
946
|
+
require$$0.useEffect(() => {
|
|
947
|
+
if (partners.length > 1) {
|
|
948
|
+
const interval = setInterval(() => {
|
|
949
|
+
setCurrentPartnerSlide((prev) => (prev + 1) % partners.length);
|
|
950
|
+
}, 5e3);
|
|
951
|
+
return () => clearInterval(interval);
|
|
952
|
+
}
|
|
953
|
+
}, [partners.length]);
|
|
954
|
+
require$$0.useEffect(() => {
|
|
955
|
+
const observer = new IntersectionObserver(
|
|
956
|
+
(entries) => {
|
|
957
|
+
entries.forEach((entry) => {
|
|
958
|
+
if (entry.isIntersecting) {
|
|
959
|
+
setPartnersVisible(true);
|
|
960
|
+
observer.unobserve(entry.target);
|
|
961
|
+
}
|
|
962
|
+
});
|
|
963
|
+
},
|
|
964
|
+
{ threshold: 0.1 }
|
|
965
|
+
);
|
|
966
|
+
if (partnersRef.current) observer.observe(partnersRef.current);
|
|
967
|
+
return () => partnersRef.current && observer.unobserve(partnersRef.current);
|
|
968
|
+
}, []);
|
|
969
|
+
if (!partnersData.length) return null;
|
|
970
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
971
|
+
"section",
|
|
972
|
+
{
|
|
973
|
+
className: `py-12 lg:py-20 transition-colors duration-300 ${isDarkMode ? "bg-gradient-to-b from-gray-950 via-gray-900 to-gray-800" : "bg-gradient-to-b from-white via-gray-50 to-gray-100"}`,
|
|
974
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "max-w-7xl mx-auto px-4 sm:px-6 lg:px-8", children: [
|
|
975
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "text-center mb-12", children: [
|
|
976
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
977
|
+
"div",
|
|
978
|
+
{
|
|
979
|
+
className: `inline-block px-4 py-2 rounded-full text-sm font-semibold mb-4 border shadow-sm ${isDarkMode ? "bg-blue-900/30 text-blue-300 border-blue-800" : "bg-blue-100 text-blue-800 border-blue-200"}`,
|
|
980
|
+
children: [
|
|
981
|
+
"🤝 ",
|
|
982
|
+
t("partners.header.badge")
|
|
983
|
+
]
|
|
984
|
+
}
|
|
985
|
+
),
|
|
986
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
987
|
+
"h2",
|
|
988
|
+
{
|
|
989
|
+
className: `text-3xl lg:text-5xl font-bold leading-tight ${isDarkMode ? "text-white" : "text-gray-800"}`,
|
|
990
|
+
children: [
|
|
991
|
+
t("partners.header.title"),
|
|
992
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "block bg-gradient-to-r from-blue-500 to-purple-500 bg-clip-text text-transparent mt-2", children: t("partners.header.subtitle") })
|
|
993
|
+
]
|
|
994
|
+
}
|
|
995
|
+
)
|
|
996
|
+
] }),
|
|
997
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: partnersRef, className: "relative overflow-hidden", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
998
|
+
"div",
|
|
999
|
+
{
|
|
1000
|
+
className: `transition-all duration-1000 ease-out ${partnersVisible ? "opacity-100 scale-100" : "opacity-0 scale-95"}`,
|
|
1001
|
+
children: [
|
|
1002
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative h-56 md:h-64 lg:h-72 xl:h-80 mb-8", children: partners.map((group, slideIndex) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1003
|
+
"div",
|
|
1004
|
+
{
|
|
1005
|
+
className: `absolute inset-0 transition-all duration-1000 ease-in-out ${slideIndex === currentPartnerSlide ? "opacity-100 translate-x-0" : slideIndex < currentPartnerSlide ? "opacity-0 -translate-x-full" : "opacity-0 translate-x-full"}`,
|
|
1006
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-6 h-full px-2", children: group.map((partner, idx) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1007
|
+
PartnerCard,
|
|
1008
|
+
{
|
|
1009
|
+
partner,
|
|
1010
|
+
idx,
|
|
1011
|
+
t,
|
|
1012
|
+
getLogoUrl,
|
|
1013
|
+
isDarkMode
|
|
1014
|
+
},
|
|
1015
|
+
partner.id || idx
|
|
1016
|
+
)) })
|
|
1017
|
+
},
|
|
1018
|
+
slideIndex
|
|
1019
|
+
)) }),
|
|
1020
|
+
partners.length > 1 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center space-x-2", children: partners.map((_, index2) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
1021
|
+
"button",
|
|
1022
|
+
{
|
|
1023
|
+
onClick: () => setCurrentPartnerSlide(index2),
|
|
1024
|
+
className: `w-3 h-3 rounded-full transition-all ${index2 === currentPartnerSlide ? "bg-blue-500 scale-125" : isDarkMode ? "bg-gray-600 hover:bg-blue-400" : "bg-gray-300 hover:bg-blue-500"}`
|
|
1025
|
+
},
|
|
1026
|
+
index2
|
|
1027
|
+
)) })
|
|
1028
|
+
]
|
|
1029
|
+
}
|
|
1030
|
+
) })
|
|
1031
|
+
] })
|
|
1032
|
+
}
|
|
1033
|
+
);
|
|
1034
|
+
};
|
|
621
1035
|
const index = {
|
|
622
1036
|
AboutCompanySection,
|
|
623
|
-
CompanyValues
|
|
1037
|
+
CompanyValues,
|
|
1038
|
+
TimelineSection,
|
|
1039
|
+
PartnerCard,
|
|
1040
|
+
PartnersSection
|
|
624
1041
|
};
|
|
625
1042
|
exports2.AboutCompanySection = AboutCompanySection;
|
|
626
1043
|
exports2.CompanyValues = CompanyValues;
|
|
1044
|
+
exports2.PartnerCard = PartnerCard;
|
|
1045
|
+
exports2.PartnersSection = PartnersSection;
|
|
1046
|
+
exports2.TimelineSection = TimelineSection;
|
|
627
1047
|
exports2.default = index;
|
|
628
1048
|
Object.defineProperties(exports2, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
629
1049
|
}));
|