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EAAQ,KAAO,KAChBC,EAAKG,mBAAmB,KAAM,CAC5BC,KAAM,UACNC,OAAQ,YAGZ,MAAOhK,GACP,MAAO,KAIE5H,EAAa,SAAC4R,G,IAAgBC,IAAAA,UAAAA,OAAAA,QAAAA,IAAAA,UAAAA,KAAAA,UAAAA,GACzC,MAAMC,EAAeD,EAAU,IAAM,SAC/BE,EAAaF,EAAU,IAAM,OAEnC,IAAIG,EAAIJ,EAAS,KACbK,EAAQhK,KAAKiK,MAAMN,EAAS,IAC5BO,EAAUH,EAAI,GACdI,EAAUJ,EAAI,GAElB,OAAIJ,EAAS,GACJA,EAASE,EAGbD,EAOI5J,KAAKiK,MAAMN,EAAS,IAAMG,EAAaH,EAC1C,IAAMA,EAASE,EACf,GARG,GAIH7J,OAHQ,IAAVgK,EACI,GAAgBhK,OAAbgK,EAAM,SAA2B,OAApBhK,KAAKiK,MAAMC,GAAS,UACpC,GAAU,OAAPP,EAAO,UACf,KAAuB,OAApB3J,KAAKiK,MAAME,GAAS,WAQfC,EAAUC,IACrB,MAAMC,IAAcD,EACdE,EAAOC,GAAeA,EAAI,GAAK,IAAM,OAAFA,GAAM,GAAK,OAAFA,GAClD,OAAIF,GAAa,KACR,GAA2BC,UAArBD,EAAY,MAAM,KAAyCC,OAAtCA,QAAUD,EAAY,MAAQ,KAAK,KAEnE,OAFsEC,EACtED,EAAY,KAELA,GAAa,GACf,GAAyBC,UAAnBD,EAAY,IAAI,KAAuB,OAApBC,EAAID,EAAY,KAEzC,KAAoB,OAAfC,EAAID,M,sHC7Fb,MAMMG,EAAwB,KACnCC,EAAAA,EAAAA,IAAO,MAAO,gCAEHzO,EAAwB,KACnCyO,EAAAA,EAAAA,IAAO,MAAO,kCAKHC,EAAwB,KACnCD,EAAAA,EAAAA,IAAO,MAAO","sources":["webpack://_N_E/./src/components/Card/CardCourse.legacy.tsx","webpack://_N_E/./src/components/Card/CardNotFound.tsx","webpack://_N_E/./src/components/Container.tsx","webpack://_N_E/./src/components/Form/FieldSearch.tsx","webpack://_N_E/./src/components/InstantSearchBox/SearchHitsCourse.tsx","webpack://_N_E/./src/components/InstantSearchBox/SearchResultsLms.tsx","webpack://_N_E/./src/components/InstantSearchBox/SearchBox.tsx","webpack://_N_E/./src/components/InstantSearchBox/InstantSearchBox.tsx","webpack://_N_E/./src/components/InstantSearchBox/ModalSearchBox.tsx","webpack://_N_E/./src/components/InstantSearchBox/searchStore.ts","webpack://_N_E/./src/components/Modal/index.tsx","webpack://_N_E/./src/components/ModalPortal/ModalPortal.tsx","webpack://_N_E/./src/components/ModalPortal/Modal.tsx","webpack://_N_E/./src/lib/date.ts","webpack://_N_E/./src/modules/Explore/exploreApi.ts"],"sourcesContent":["import { Image } from \"components/Image/Image\";\nimport { toDuration } from \"lib/date\";\nimport { paths } from \"lib/__generatedApiSpec\";\nimport { OpReturnType } from \"openapi-typescript-fetch/dist/cjs/types\";\nimport Images from \"next/image\";\nimport Badge from \"components/Badge\";\nimport { IconStar } from \"components/Icon/IconStar\";\nimport { Course } from \"./interfaces\";\nimport Button from \"components/Button\";\nimport { formatRating, isCustomDomain, numberWithCommas } from \"lib/helper\";\nimport { useIsDesktop } from \"lib/device\";\nimport { LogoChip } from \"components/Chip/LogoChip\";\nimport Tooltip from \"components/Tooltip\";\nimport { IconTimer } from \"components/Icon/IconTimer\";\nimport { IconCheck } from \"components/Icon/IconCheck\";\nimport { useRouter } from \"next/router\";\nimport React, { useEffect, useState } from \"react\";\nimport { trackEvent, trackEventGA, trackEventGTM } from \"lib/amplitude\";\nimport { Chip } from \"components/Chip/Chip\";\nimport { useIsBusiness, useIsSubdomain, useIsTenant } from \"lib/host\";\nimport { IconPlusCircle } from \"components/Icon/IconPlusCircle\";\nimport { IconCheckCircle } from \"components/Icon/IconCheckCircle\";\nimport { useCartStore } from \"modules/Business/Selection/cartStore\";\nimport useTranslation from \"next-translate/useTranslation\";\nimport Link from \"next/link\";\nimport { IconPlayCircle } from \"components/Icon/IconPlayCircle\";\n\ntype PropsCard = Course & {\n isUncheck?: boolean;\n isHide?: boolean;\n};\n\n//@ts-ignore\nexport const CardCourse: React.FC = ({\n isLayoutNew = false,\n className = \"\",\n isUncheck = false,\n isHide = false,\n ...props\n}) => {\n const isSubdomainTenant = useIsSubdomain();\n const isDesktop = useIsDesktop();\n const [timeout, setModalTimeout] = useState(null);\n const [checkedCard, setCheckedCard] = useState([]);\n const isTenatURL = useIsTenant();\n const isB2B = useIsTenant() || useIsSubdomain();\n const isBusiness = !isB2B;\n\n const updateCart = useCartStore((state) => state.updateCart);\n\n let institutionImage =\n //@ts-ignore\n props?.institution?.image_url\n ? //@ts-ignore\n props?.institution?.image_url\n : typeof props?.institution == \"string\" &&\n //@ts-ignore\n props?.institution?.split(\"||\").length > 1 &&\n //@ts-ignore\n props?.institution?.split(\"||\")[1].includes(\"https\")\n ? //@ts-ignore\n props?.institution?.split(\"||\")[1]\n : //@ts-ignore\n props?.institution && typeof props?.institution == \"object\"\n ? //@ts-ignore\n props?.institution?.image_url\n : null;\n\n let institutionName =\n //@ts-ignore\n props.institution?.name || props.institution?.split(\"||\")[0] || \"\";\n\n const classHeight =\n className == \"card-my-class\"\n ? \"112px\"\n : className == \"card-default\"\n ? \"164px\"\n : \"171px\";\n\n const wCustom = props?.isHorizontal ? 287 : 328;\n const hCustom = props?.isHorizontal ? 164 : 228;\n\n const hasUserPaid: boolean = (props as any).is_paid;\n const isCourseFree: boolean =\n props.original_price === 0 || props.discounted_price === 0;\n\n const isCourseFinished =\n props.enrollment_progress?.finished === props.enrollment_progress?.total;\n\n const router = useRouter();\n\n const events = {\n event: \"course_hover_a\",\n property: {\n course_name: props?.name ?? \"\",\n course_slug: props?.slug ?? \"\",\n section_name: props?.sectionName ?? \"\",\n institution_name:\n //@ts-ignore\n props?.institution_name ?? props.institution?.name ?? \"\",\n index: props?.index ?? 0,\n page: router.pathname,\n },\n };\n\n const { t } = useTranslation(\"common\");\n\n if (isLayoutNew) {\n return (\n {\n //@ts-ignore\n if (props.onSelect) {\n //@ts-ignore\n // props.onSelect();\n updateCart(props);\n }\n }}\n >\n {\n timeout && clearTimeout(timeout);\n setModalTimeout(\n setTimeout(() => {\n trackEventGTM({\n ...(events as any),\n });\n trackEventGA({\n ...(events as any),\n });\n }, 3000)\n );\n }\n }\n onMouseLeave={\n isBusiness\n ? undefined\n : () => {\n timeout && clearTimeout(timeout);\n }\n }\n >\n
\n {props.isHorizontal ? (\n <>\n {props.image_cover_url ? (\n \n ) : (\n
\n )}\n \n ) : (\n <>\n {props.image_cover_url ? (\n \n ) : (\n \n )}\n \n )}\n\n {!isBusiness && (\n \n
\n {/* */}\n \n
\n \n )}\n {/* @ts-ignore */}\n {isBusiness && router.pathname == \"/pilih-kursus\" && !isUncheck && (\n \n \n \n )}\n\n {/* {!isBusiness && !isSubdomainTenant && !isTenatURL && (\n \n \n {t(\"free\").toUpperCase()}\n \n \n )} */}\n \n\n
\n \n \n \n \n

\n {props.name}\n

\n\n
\n {institutionImage && (\n // \n \n )}\n\n
\n
\n {institutionName}\n
\n\n
\n {/* @ts-ignore */}\n {typeof props?.review_summary?.star_avg === \"number\" &&\n //@ts-ignore\n props?.review_summary?.star_avg !== 0 &&\n !isB2B ? (\n <>\n
\n \n
\n {formatRating(\n //@ts-ignore\n props?.review_summary?.star_avg.toFixed(1)\n )}\n
\n
\n |\n \n ) : (\n <>\n )}\n {props.total_learners !== 0 && !isB2B && (\n
{`${numberWithCommas(props.total_learners)} ${t(\n \"pelajar\"\n ).toLowerCase()}`}
\n )}\n
\n
\n
\n\n
\n {isBusiness ? (\n \n \n \n ) : (\n <>\n {props.skills.length > 0 ? (\n <>\n
\n {t(\"skills\")}\n
\n\n
\n {props?.skills?.slice(0, 3).map((skill) => (\n \n {skill.name || skill.toString()}\n \n ))}\n\n {props?.skills.length > 3 && (\n
\n +{props.skills.length - 3} Skill lainnya\n
\n )}\n
\n \n ) : null}\n \n )}\n
\n
\n\n {className == \"card-my-class\" && (\n
\n {isCourseFinished &&\n (!hasUserPaid || isCourseFree) ? null : isCourseFinished ? (\n \n Download Sertifikat\n \n ) : props.enrollment_progress?.finished === 0 ? (\n \n ) : props.enrollment_progress?.finished <\n props.enrollment_progress?.total ? (\n
\n
\n {props.enrollment_progress.finished} dari{\" \"}\n {props.enrollment_progress.total}\n
\n
\n
\n
\n
\n
\n ) : null}\n
\n )}\n \n \n \n\n {/* @ts-ignore */}\n {props.isChecked ? (\n
\n \n
\n ) : null}\n\n {isHide && (\n
\n
\n Khusus goKampus Business\n
\n
\n )}\n \n \n );\n } else {\n return (\n
\n
\n \n
\n
\n
\n
\n \n
\n
\n
\n {props.institution?.name}\n
\n
\n
{props.name}
\n
\n
\n {props.total_learners && !isB2B\n ? `${numberWithCommas(props.total_learners)} pelajar | `\n : null}\n {props.duration == 0 ? null : toDuration(props.duration, false)}\n
\n
\n {/*
GRATIS
*/}\n
\n
\n );\n }\n};\n","import Image from \"next/image\";\nimport Button from \"components/Button\";\nimport { trackEvent } from \"lib/amplitude\";\nimport Link from \"next/link\";\nimport { useRouter } from \"next/router\";\n\ninterface Props {\n title?: string;\n message?: string;\n useButton?: BProps[];\n src?: string;\n className?: string;\n useSmallIcon?: boolean;\n useMaxWidth?: number;\n}\n\ninterface BProps {\n label?: string;\n href?: any;\n variant?: string;\n onClose?(): void;\n}\n\nexport const CardNotFound: React.FC = ({\n useSmallIcon = false,\n useMaxWidth = 0,\n ...props\n}) => {\n const router = useRouter();\n const { title, message, useButton, src, className = \"\" } = props;\n\n const pushToTrackEvents = (label: string) => {\n switch (label) {\n case \"Mulai Belajar Gratis\":\n trackEvent({\n event: \"myclass_startlearning_a\",\n });\n break;\n\n case \"Kembali ke Homepage\":\n trackEvent({\n event: \"error_404_back_to_homepage_a\",\n });\n break;\n\n case \"Coba Lagi\":\n trackEvent({\n event: \"error_500_retry_a\",\n });\n router.reload()\n break;\n\n case \"Kembali\":\n trackEvent({\n event: \"error_500_back_a\",\n });\n router.back()\n break;\n\n default:\n break;\n }\n };\n\n return (\n \n \n\n
\n
\n {title &&
{title}
}\n {message &&
{message}
}\n
\n\n {useButton && useButton.length > 0 ? (\n 1 ? \"gap-8\" : \"\")\n }\n >\n {useButton.map((el) => (\n {\n pushToTrackEvents(el.label);\n if (el.onClose) {\n el.onClose();\n }\n }}\n key={\"useButton\" + el.href}\n >\n \n {el.label}\n \n \n ))}\n
\n ) : null}\n
\n
\n );\n};\n","import React, { ReactNode, use } from \"react\";\nimport { BottomNav } from \"modules/Nav/BottomNav\";\nimport { BarLoader, ClipLoader, MoonLoader } from \"react-spinners\";\nimport { useIsDesktop } from \"lib/device\";\nimport { useRouter } from \"next/router\";\n\nexport type Props = {\n children?: ReactNode;\n className?: string;\n wrapperClassName?: string;\n isFullHeight?: boolean;\n useNavbar?: boolean;\n isLoader?: boolean;\n useLoader?: boolean;\n};\n\nconst Container: React.FC = ({\n children,\n className = \"\",\n wrapperClassName = \"\",\n useNavbar = false,\n isLoader = false,\n useLoader = false,\n}) => {\n const isDesktop = useIsDesktop();\n const router = useRouter();\n\n return (\n
\n \n {children}\n\n {useLoader && isLoader && (\n
\n \n
\n )}\n
\n\n {useNavbar && }\n
\n );\n};\n\nexport default Container;\n\nexport const ContainerDesktop = ({\n children,\n className = \"\",\n classBackgroundFull = \"\",\n useMinHeight = false,\n useAuto = false,\n customStyle = null,\n}) => {\n return (\n \n \n {children ?? null}\n \n \n );\n};\n","import React, { DetailedHTMLProps, InputHTMLAttributes, useState } from \"react\";\n\nimport { IconSearch } from \"components/Icon/IconSearch\";\nimport { trackEvent, trackEventGA, trackEventGTM } from \"lib/amplitude\";\nimport { useRouter } from \"next/router\";\nimport { ModalSearchBox } from \"components/InstantSearchBox/ModalSearchBox\";\n\nexport type Props = DetailedHTMLProps<\n InputHTMLAttributes,\n HTMLInputElement\n> & {\n text?: string;\n onChangeSearch?: (text: any) => void;\n events?: any;\n placeholder?: string;\n position?: \"right\" | \"left\";\n theme?: \"default\" | \"white\";\n handleClick?: () => void;\n submitSearch?: () => void;\n setModal?: (a: boolean) => void;\n isShow?: boolean;\n indexName?: string;\n classWidth?: string;\n};\n\nconst FieldSearch: React.FC = ({\n onChangeSearch,\n text,\n placeholder = \"Ingin belajar apa hari ini?\",\n position = \"left\",\n theme = \"default\",\n handleClick,\n submitSearch,\n indexName,\n isShow,\n setModal,\n classWidth = \"w-600 x-max:w-400\",\n}) => {\n const router = useRouter();\n const themes = {\n default: \"placeholder-input_placeholder bg-white text-neutral-50 \",\n white: \"placeholder-white bg-[#ffffff33] text-white \",\n };\n\n const themeIcon = {\n default: \"#5D586C \",\n white: \"#FFFFFF \",\n };\n\n const themeBorder = {\n default: \"border border-neutral-40 \",\n white: \"border-none outline-none \",\n };\n\n return (\n
\n \n \n
\n\n {\n e.preventDefault();\n }}\n >\n {\n trackEventGTM({\n event: \"explore_searchbar_start_a\",\n property: {\n page: router.pathname,\n },\n });\n trackEventGA({\n event: \"explore_searchbar_start_a\",\n property: {\n page: router.pathname,\n },\n });\n setModal(true);\n }}\n className={\n `w-full focus:outline-none p-8 text-b1 font-light rounded-6 ${themes[theme]} ${themeBorder[theme]} ` +\n (position == \"left\" ? \" pl-36\" : \" pr-36\")\n }\n placeholder={placeholder}\n />\n \n \n\n {\n setModal(false);\n router.push({\n pathname: \"/\",\n });\n }}\n />\n \n );\n};\n\nexport default FieldSearch;\n","import { connectStateResults, connectHits } from \"react-instantsearch-dom\";\nimport Link from \"next/link\";\nimport { Course } from \"components/Card/interfaces\";\nimport { IconStar } from \"components/Icon/IconStar\";\nimport { formatRating, getCookie, numberWithCommas } from \"lib/helper\";\nimport { CardNotFound } from \"components/Card/CardNotFound\";\nimport { useAuthStore } from \"modules/Auth/authStore\";\nimport { trackEvent } from \"lib/amplitude\";\nimport { useRouter } from \"next/router\";\nimport IconPlay from \"components/Icon/IconPlay\";\nimport { IconPlayCircle } from \"components/Icon/IconPlayCircle\";\nimport Button from \"components/Button\";\nimport { Image } from \"components/Image/Image\";\nimport { useEffect, useState } from \"react\";\nimport { ArrayObjectSortBy } from \"lib/object\";\nimport { SkeletonRect, SkeletonWrapper } from \"components/Skeleton/Skeleton\";\nimport { useSearchStore } from \"./searchStore\";\nimport useTranslation from \"next-translate/useTranslation\";\nimport { getSubDomain, useIsSubdomain, useIsTenant } from \"lib/host\";\nimport { useAccessCourseTenant } from \"modules/Explore/exploreApi\";\nimport { isBrowser } from \"lib/ssr\";\nimport { useGetCoursesByTenantSlug } from \"modules/Tenant/homeTenantApi\";\nimport { generateIndexName } from \"lib/algolia\";\n\nfunction SearchHitsCourse({ searchState, searchResults, indexName, ...props }) {\n const [recommendCourses, setRecommendCourses] = useState([]);\n const [isLoading, setIsLoading] = useState(false);\n const [allCourses, setAllCourses] = useState(null);\n const { t } = useTranslation(\"common\");\n const isB2B = useIsTenant() || useIsSubdomain();\n const loginState = useAuthStore((state) => state.loginState);\n const { setRecommendData } = useSearchStore();\n const router = useRouter();\n\n /// Access Courses List\n const accessCourseApi = useAccessCourseTenant();\n const getCourses = useGetCoursesByTenantSlug();\n const currentUser = useAuthStore((state) => state.currentUser);\n\n // checking if the query length is >= 3\n // (since 3 is the minimum Algolia query length)\n const validQuery = searchState.query?.length >= 3;\n const totalData = searchResults?.nbHits;\n const dataCourses =\n searchResults?.hits.length > 0 && searchState.query && validQuery\n ? searchResults.hits\n : searchResults?.hits.length > 0 && !searchState.query\n ? searchResults.hits\n : null;\n\n let seeAllBtn = null;\n let searchResultsLms = null;\n if (props.showBtn) {\n seeAllBtn = (\n \n Lihat semua\n \n );\n searchResultsLms = (\n
\n {totalData > 0 && {totalData}}\n

Hasil Pencarian untuk

\n \n \"{props.searchValue}\"\n \n
\n );\n }\n\n const getCourseRecommend = () => {\n const computeIndexName = () => {\n if (currentUser) {\n if (currentUser.referral.includes(\"gaji-c\")) {\n return currentUser.referral !== \"gaji-c0000117\"\n ? generateIndexName(\"gaji\")\n : generateIndexName(currentUser.referral);\n }\n return generateIndexName(\n window.location.hostname === \"e-learning.bluebirdgroup.com\"\n ? \"bluebird\"\n : currentUser.referral === \"bssn\"\n ? \"tapinkab\"\n : currentUser.referral\n );\n }\n return generateIndexName(\n window.location.hostname === \"e-learning.bluebirdgroup.com\"\n ? \"bluebird\"\n : subDomain === \"bssn\"\n ? \"tapinkab\"\n : subDomain\n );\n };\n\n const indexName = computeIndexName();\n\n setAllCourses(null);\n setIsLoading(true);\n const subDomain = isBrowser()\n ? getSubDomain(window.location.hostname)\n : null;\n\n const referral = isB2B\n ? currentUser?.referral ?? subDomain\n : currentUser?.referral;\n\n if (referral && ![\"moodle\", \"example\"].includes(referral)) {\n fetch(\n referral\n ? searchState.query\n ? `/api/search-algolia?indexName=${indexName}&q=${searchState.query}`\n : `/api/search-algolia?indexName=${indexName}`\n : \"/api/search\"\n )\n .then((res) => res.json())\n .then((res) => {\n const data =\n ArrayObjectSortBy(res.data?.hits, \"created_date\", true) ?? [];\n const recommendCourses = data.slice(0, 4);\n setRecommendCourses(recommendCourses);\n\n if (recommendCourses.length) {\n setRecommendData(recommendCourses);\n }\n\n setTimeout(() => {\n setIsLoading(false);\n }, 200);\n });\n }\n };\n\n const referralCode =\n getCookie(\"ref_code_gk\") && getCookie(\"ref_code_gk\") !== \"null\"\n ? getCookie(\"ref_code_gk\")\n : typeof window !== \"undefined\"\n ? new URLSearchParams(window.location.search).get(\"referral\")\n : \"\";\n\n useEffect(() => {\n if (!searchState.query) {\n setAllCourses(null);\n setIsLoading(true);\n const subDomain = isBrowser()\n ? getSubDomain(window.location.hostname)\n : null;\n\n const referral = isB2B\n ? currentUser?.referral ?? subDomain\n : currentUser?.referral;\n\n if (\n referral &&\n ![\"moodle\", \"example\"].includes(referral)\n // ||\n // referralCode == \"trenggalekkab\"\n ) {\n getCourses.doFetch(\n {\n slug:\n window.location.hostname === \"e-learning.bluebirdgroup.com\"\n ? \"bluebird\"\n : // : referralCode == \"trenggalekkab\"\n // ? referralCode\n referral,\n // @ts-ignore\n popular: 1,\n },\n {\n onSuccess(data) {\n // Get first 3 courses\n setAllCourses(data?.data.slice(0, 3));\n\n setIsLoading(false);\n },\n }\n );\n }\n return;\n }\n\n if (dataCourses && dataCourses.length > 0) {\n const newData = isB2B\n ? loginState === \"LOGIN\"\n ? dataCourses\n : dataCourses.filter((a) => !a.tenant)\n : dataCourses.filter((a) => !a.is_institution_business);\n\n /// Run normal function without checking\n /// allowed course or not when user is anonymous\n if (!currentUser?.referral) {\n if (newData && newData.length > 0) {\n setAllCourses(newData);\n } else {\n getCourseRecommend();\n }\n return;\n }\n /// Fetch access course API to get\n /// list of allowed course\n accessCourseApi.doFetch(\n {\n // @ts-ignore\n slug:\n window.location.hostname === \"e-learning.bluebirdgroup.com\"\n ? \"bluebird\"\n : // : referralCode == \"trenggalekkab\"\n // ? referralCode\n currentUser?.referral,\n },\n {\n onSuccess(data) {\n const listAccessCourses = data?.data;\n const userId = currentUser?.id;\n const listForbiddenCourses = [];\n\n /// Generate forbidden course where\n /// userId != id from API\n if (\n Array.isArray(listAccessCourses) &&\n listAccessCourses.length > 0\n ) {\n listAccessCourses.forEach((course) => {\n if (Array.isArray(course.courses)) {\n const listCoursesSlug = course.courses.map((c) => c.slug);\n\n if (course.user != userId) {\n listForbiddenCourses.push(listCoursesSlug);\n }\n } else {\n // @ts-ignore\n const listCoursesSlug = course.courses?.slug;\n\n if (course.user !== userId) {\n listForbiddenCourses.push(listCoursesSlug);\n }\n }\n });\n\n /// Hide course where it listed on forbidden courses\n if (listForbiddenCourses.length > 0) {\n const showedCourses = newData.filter(\n (course) => !listForbiddenCourses.includes(course.slug)\n );\n // console.log(\"showedCourses:\",showedCourses)\n setAllCourses(showedCourses);\n } else {\n console.log(\"no forbidden course\");\n if (newData && newData.length > 0) {\n setAllCourses(newData);\n } else {\n getCourseRecommend();\n }\n }\n } else {\n getCourseRecommend();\n }\n },\n onError(err) {\n if (newData && newData.length > 0) {\n setAllCourses(newData);\n } else {\n getCourseRecommend();\n }\n },\n }\n );\n } else {\n getCourseRecommend();\n }\n }, [\n // dataCourses,\n searchState.query,\n // referralCode\n ]);\n\n useEffect(() => {\n if (searchState.query) {\n trackEvent({\n event: \"explore_searchbar_suggestion_a\",\n property: {\n page: router.pathname,\n query: searchState.query,\n },\n });\n }\n }, [searchResults?.hits]);\n\n return (\n <>\n {!allCourses || allCourses.length === 0 ? (\n
\n
\n {!isLoading && recommendCourses.length === 0 ? (\n \n ) : (\n
\n {t(\"recommendationForYou\")}\n
\n )}\n\n {isLoading ? (\n \n
\n {[1, 2, 3, 4].map((el) => (\n \n \n\n
\n \n \n \n
\n
\n ))}\n
\n \n ) : (\n recommendCourses &&\n recommendCourses.map((hit: Course, index: any) => (\n // @ts-ignore\n \n ))\n )}\n
\n \n ) : (\n <>\n {searchResultsLms}\n\n {!searchState.query && allCourses.length > 0 && (\n
\n {t(\"popularCourses\")}\n
\n )}\n\n {allCourses.map((hit: Course, index: any) => (\n // @ts-ignore\n \n ))}\n\n {seeAllBtn}\n \n )}\n \n );\n}\nexport default connectStateResults(SearchHitsCourse);\n\nfunction ItemCourse({ ...props }) {\n const loginState = useAuthStore((state) => state.loginState);\n const router = useRouter();\n const closeModal = () => (props.closeModal ? props.closeModal() : null);\n const isLMS = router.pathname.includes(\"/course/[courseSlug]\");\n const isB2B = useIsTenant() || useIsSubdomain();\n const institutionName =\n props?.institution?.name ?? props?.institution?.split(\"||\")[0];\n return (\n {\n trackEvent({\n event: \"explore_searchbar_suggestion_course_a\",\n property: {\n page: router.pathname,\n course_name: props.name,\n course_slug: props.slug,\n institution_name: props.institution.split(\"||\")[0] || \"\",\n index: props.index,\n query: props.query,\n },\n });\n closeModal();\n }}\n href={\n loginState == \"LOGIN\" && isLMS\n ? {\n pathname: \"/r/[page]\",\n query: {\n page: `/course/${props?.slug}`,\n },\n }\n : loginState == \"LOGIN\"\n ? {\n pathname: \"/course/[courseSlug]\",\n query: { courseSlug: props?.slug },\n }\n : {\n pathname: \"/login\",\n query: {\n url: encodeURIComponent(`/course/${props?.slug}`),\n },\n }\n }\n >\n
\n {props?.image_cover_url ? (\n
\n \n\n
\n \n
\n
\n ) : (\n
\n )}\n
\n
{institutionName}
\n
\n {props?.name}\n
\n\n
\n {typeof props?.review_summary?.star_avg === \"number\" &&\n props?.review_summary?.star_avg !== 0 &&\n !isB2B ? (\n <>\n
\n \n
\n {formatRating(\n // @ts-ignore\n props?.review_summary?.star_avg.toFixed(1)\n )}\n
\n
\n |\n \n ) : (\n <>\n )}\n {props?.total_learners !== 0 && !isB2B && (\n
{`${numberWithCommas(props?.total_learners)} pelajar`}
\n )}\n
\n
\n
\n \n );\n}\n","import { connectStateResults, connectHits } from \"react-instantsearch-dom\";\nimport { Course } from \"components/Card/interfaces\";\nimport { CardNotFound } from \"components/Card/CardNotFound\";\nimport { CardCourse } from \"components/Card/CardCourse.legacy\";\nimport { ContainerDesktop } from \"components/Container\";\nimport IconClose from \"components/Icon/IconClose\";\nimport Link from \"next/link\";\nimport { useAuthStore } from \"modules/Auth/authStore\";\nimport { trackEvent } from \"lib/amplitude\";\nimport { useRouter } from \"next/router\";\nimport { useEffect, useState } from \"react\";\nimport { useIsSubdomain, useIsTenant } from \"lib/host\";\n\nfunction SearchResultsLms({ searchState, searchResults, ...props }) {\n // checking if the query length is >= 3\n // (since 3 is the minimum Algolia query length)\n const validQuery = searchState.query?.length >= 3;\n const loginState = useAuthStore((state) => state.loginState);\n const totalData = searchResults?.nbHits\n const router = useRouter();\n const [isLoading, setIsLoading] = useState(false);\n const [allCourses, setAllCourses] = useState(null);\n const isB2B = useIsTenant() || useIsSubdomain();\n\n const dataCourses =\n searchResults?.hits.length > 0 && searchState.query && validQuery\n ? searchResults.hits\n : searchResults?.hits.length > 0 && !searchState.query\n ? searchResults.hits\n : null;\n\n useEffect(() => {\n if (dataCourses && dataCourses.length > 0) {\n const newData = isB2B\n ? dataCourses\n : dataCourses.filter((a) => !a.is_institution_business);\n if (newData && newData.length > 0) {\n setAllCourses(newData);\n } else {\n setAllCourses(null); \n }\n } else {\n setAllCourses(null);\n }\n }, [dataCourses]);\n\n\n const searchResultsTitle = (\n
\n
\n \n
\n {\n props.searchValue && (\n
\n {\n allCourses && allCourses.length > 0 && (\n \n {allCourses.length}\n \n )\n }\n

\n Hasil Pencarian untuk\n

\n \n \"{props.searchValue}\"\n \n
\n )\n }\n
\n )\n\n return (\n
\n {!allCourses ? (\n \n {searchResultsTitle}\n\n \n \n ) : (\n \n
\n {searchResultsTitle}\n\n \n\n

{\n trackEvent({\n event: \"explore_searchbar_srp_course_more_a\",\n property: {\n page: router.pathname,\n query: props.searchValue\n }\n })\n props.onClickEnter()\n }} className=\"pr-16 text-purple-50 text-b1 font-medium cursor-pointer\">Lihat Semua Hasil

\n
\n
\n {allCourses.map((hit: Course, index: any) => (\n // @ts-ignore\n {\n trackEvent({\n event: \"explore_searchbar_srp_course_a\",\n property: {\n page: router.pathname,\n query: props.searchValue,\n course_name: hit.name,\n course_slug: hit.slug,\n institution_name: hit?.institution?.split('||')[0],\n index,\n },\n })\n props.closeModal()\n }}\n >\n \n \n ))}\n
\n
\n )}\n
\n );\n}\n\nexport default connectStateResults(SearchResultsLms);\n","import { IconSearch } from \"components/Icon/IconSearch\";\nimport { ChangeEvent, useEffect, useState } from \"react\";\nimport { connectSearchBox, Configure, Index } from \"react-instantsearch-dom\";\nimport { ClipLoader } from \"react-spinners\";\nimport React from \"react\";\nimport { useIsDesktop } from \"lib/device\";\nimport { trackEvent, trackEventGA, trackEventGTM } from \"lib/amplitude\";\nimport { useRouter } from \"next/router\";\nimport { CONST } from \"lib/const\";\nimport SearchHitsCourse from \"./SearchHitsCourse\";\nimport { BackButton } from \"components/PageHeader/BackButton\";\nimport Modal from \"components/ModalPortal/Modal\";\nimport SearchResultsLms from \"./SearchResultsLms\";\nimport { useIsSubdomain, useIsTenant } from \"lib/host\";\nimport { FilteredKeys } from \"lib/object\";\nimport IconClose from \"components/Icon/IconClose\";\nimport SearchHitsKeyword from \"./SearchHitsKeyword copy\";\nimport { useSystemStore } from \"components/PageHeader/systemStore\";\n\nconst useOutsideClick = (callback: () => void) => {\n const ref = React.useRef();\n\n React.useEffect(() => {\n const handleClick = (event: any) => {\n if (ref.current && !(ref.current as any)?.contains(event.target)) {\n callback();\n }\n };\n\n document.addEventListener(\"click\", handleClick, true);\n\n return () => {\n document.removeEventListener(\"click\", handleClick, true);\n };\n }, [ref]);\n\n return ref;\n};\n\nfunction SearchBox({\n currentRefinement,\n refine,\n className,\n indexName,\n ...props\n}) {\n const router = useRouter();\n const query = (router && router.query.q) || null;\n const [theme] = useSystemStore((state) => [state.theme]);\n\n /// read value from path param of q\n const [value, setValue] = useState(currentRefinement || query);\n const [timeout, setTime] = useState(null);\n const [isLoading, setIsLoading] = useState(false);\n const isDesktop = typeof window !== \"undefined\" && window.innerWidth > 720;\n const [show, setShow] = useState(false);\n const [showLms, setLms] = useState(false);\n const [showBtn, setShowBtn] = useState(false);\n const isLMS = router.pathname.includes(\"/course/[courseSlug]\");\n const isB2B = useIsTenant() || useIsSubdomain();\n const tagsKey = (router.query.tagsKey as any) ?? \"\";\n const institutionKey = (router.query.institutionKey as any) ?? \"\";\n\n const q = router?.query?.q ?? \"\";\n const institutionNames =\n typeof router.query.institutionKey == \"string\" &&\n router.query.institutionKey\n ? router.query.institutionKey.split(\",\")\n : [];\n const institutionKeyFilter = institutionNames.length\n ? `${institutionNames.map((ins) => `institution:\"${ins}\"`).join(\" OR \")}`\n : \"\";\n\n const tagsNames =\n typeof router.query.tagsKey == \"string\" && router.query.tagsKey\n ? router.query.tagsKey.split(\",\")\n : [];\n const tagsKeyFilter = tagsNames.length\n ? `${tagsNames.map((ins) => `tags:\"${ins}\"`).join(\" OR \")}`\n : \"\";\n const isEnteredSearch = tagsKeyFilter !== \"\" || institutionKeyFilter !== \"\";\n const isAnyFiltered = q !== \"\";\n const handleReset = () => {\n setValue(\"\");\n router.push({\n pathname: \"/\",\n });\n };\n\n const themes = {\n default: \"placeholder-input_placeholder bg-white text-neutral-50 \",\n white: \"placeholder-white bg-[#ffffff33] text-white \",\n transparent:\n \"placeholder-input_placeholder bg-transparent text-neutral-50 \",\n };\n\n const themeIcon = {\n default: \"#5D586C \",\n white: \"#FFFFFF \",\n transparent: \"#44199A\",\n };\n\n useEffect(() => {\n if (!q) {\n setValue(\"\");\n }\n }, [q]);\n\n const ref = useOutsideClick(() => {\n setShow(false);\n });\n\n const onChangeDebounced = (event: ChangeEvent) => {\n const value = event.currentTarget.value;\n\n // if (value === \"\") {\n // setShow(false);\n // setLms(false);\n // setShowBtn(false);\n // }\n\n timeout && clearTimeout(timeout);\n\n if (value) {\n setIsLoading(true);\n } else {\n // only push route for desktop view\n // No need to change path since this makes\n // LMS page move to homepage when activated (23/7/24)\n // if (isB2B && window.screen.availWidth > 900) {\n // router.push({\n // pathname: \"/\",\n // });\n // }\n }\n\n setTime(\n setTimeout(() => {\n refine(value);\n setIsLoading(false);\n }, 500)\n );\n\n /// No need to redirect since algolia already return\n /// recommendation after delete the form in search box\n // if(isB2B && !value && isDesktop && !isLMS) {\n // router.push({\n // pathname: \"/\",\n // });\n // }\n setValue(value);\n };\n\n useEffect(() => {\n if (props.focus) {\n setShow(true);\n }\n }, [props]);\n\n const toExplorePage = () => {\n router.push({\n pathname: \"/explore/search\",\n query: {\n q: value,\n },\n });\n setShow(false);\n };\n\n const toHomeTenantPage = () => {\n router.push({\n pathname: \"/\",\n query: {\n ...router.query,\n ...(value && { q: value }),\n },\n });\n\n setShow(false);\n };\n\n const handleKeyPress = (event) => {\n if (\n (event.charCode == 13 || event.key == \"Enter\") &&\n event.target.value !== \"\"\n ) {\n event.preventDefault();\n\n trackEventGTM({\n event: \"explore_searchbar_a\",\n property: {\n query: value,\n page: router.pathname,\n },\n });\n trackEventGA({\n event: \"explore_searchbar_a\",\n property: {\n query: value,\n page: router.pathname,\n },\n });\n\n if (isDesktop && isLMS) {\n event.target.blur();\n setShow(false);\n\n /// Directly redirect user to search page\n /// Instead of showing popup result 4 recommendation courses\n\n // setLms(true);\n if (isB2B) {\n toHomeTenantPage();\n } else {\n toExplorePage();\n }\n return;\n }\n\n if (isLMS && !isDesktop) {\n event.target.blur();\n /// Directly redirect user to search page\n /// Instead of showing popup result 4 recommendation courses\n\n // setShowBtn(true);\n if (isB2B) {\n toHomeTenantPage();\n } else {\n toExplorePage();\n }\n return;\n }\n\n if (isB2B) {\n toHomeTenantPage();\n } else {\n toExplorePage();\n }\n }\n };\n\n const renderResult = () => {\n let courseSuggestions = 3;\n if (showBtn) courseSuggestions = 4;\n\n return (\n \n \n \n \n \n\n {/* {!showBtn && (\n setShow(false)}\n onSetValue={(keyword) => setValue(keyword)}\n />\n )} */}\n \n );\n };\n\n return (\n
\n {props.onBackHeader && props.onBackHeader()} />}\n\n {props.position == \"left\" && (\n \n {isLoading ? (\n \n ) : (\n <>\n {isAnyFiltered ? (\n
\n \n
\n ) : (\n \n )}\n \n )}\n
\n )}\n\n {\n onChangeDebounced(e);\n }}\n onKeyPress={handleKeyPress}\n onFocus={() => {\n trackEventGTM({\n event: \"explore_searchbar_start_a\",\n property: {\n page: router.pathname,\n },\n });\n trackEventGA({\n event: \"explore_searchbar_start_a\",\n property: {\n page: router.pathname,\n },\n });\n setShow(true);\n setLms(false);\n }}\n onKeyDown={(e) => {\n if (e.key === \"Enter\") {\n props?.setModal && props.setModal(false);\n\n router.push({\n pathname: \"/\",\n query: {\n q: value,\n },\n });\n }\n }}\n value={value}\n autoFocus={props.focus ?? false}\n />\n\n {props?.position == \"right\" && (\n \n {isLoading ? (\n \n ) : (\n <>\n {isAnyFiltered ? (\n
\n \n
\n ) : (\n \n )}\n \n )}\n \n )}\n\n {show && <>{renderResult()}}\n\n {showLms && (\n setLms(false)}>\n \n \n setLms(false)}\n />\n \n \n )}\n \n );\n}\nexport default connectSearchBox(SearchBox);\n","import React, { DetailedHTMLProps, InputHTMLAttributes } from \"react\";\nimport { useState, useMemo } from \"react\";\nimport { InstantSearch } from \"react-instantsearch-dom\";\nimport SearchBox from \"./SearchBox\";\nimport algoliasearch from \"algoliasearch\";\nimport { CONST } from \"lib/const\";\nimport { useIsDesktop } from \"lib/device\";\n\nexport type Props = DetailedHTMLProps<\n InputHTMLAttributes,\n HTMLInputElement\n> & {\n events?: any;\n placeholder?: string;\n position?: \"right\" | \"left\";\n focus?: boolean;\n setModal?: (a: boolean) => void;\n contentClass?: string;\n onBackHeader?(): void;\n theme?: string;\n indexName?: string;\n};\n\nconst searchClient = algoliasearch(\n CONST.ALGOLIA_APP_ID,\n CONST.ALGOLIA_SEARCH_KEY\n);\n\nconst InstantSearchBox: React.FC = ({ indexName, ...props }) => {\n return (\n
\n \n
\n \n
\n \n
\n );\n};\n\nexport default InstantSearchBox;\n","import Modal from \"components/Modal\";\nimport InstantSearchBox from \"./InstantSearchBox\";\nimport { useRouter } from \"next/router\";\nimport useTranslation from \"next-translate/useTranslation\";\nimport { useIsTenant } from \"lib/host\";\n\nexport const ModalSearchBox: React.FC<{\n title?: string;\n isShow?: boolean;\n setModal?: (a: boolean) => void;\n onClose?(): void;\n indexName?: string;\n}> = ({ isShow, setModal, onClose, title, indexName, ...props }) => {\n const { t } = useTranslation(\"common\");\n const router = useRouter();\n\n return (\n \n
\n \n
\n \n );\n};\n","import { Course, PopularCourse, Searches } from \"components/Card/interfaces\";\nimport createStore from \"zustand\";\n\nexport type SearchStore = {\n // state\n currentRecommend: Course[];\n totalFilter: number;\n popularCourse: PopularCourse[];\n searches: Searches[];\n keywords: string[];\n indexName: string;\n\n // actions\n setRecommendData: (items: Course[]) => void;\n setTotalFilter: (filter: number) => void;\n setPopularCourse: (items: PopularCourse[]) => void;\n setSearches: (items: Searches[]) => void;\n setKeywords: (items: string[]) => void;\n setIndexName: (item: string) => void;\n};\n\nexport const useSearchStore = createStore((set) => ({\n // state\n currentRecommend: [],\n totalFilter: 0,\n popularCourse: [],\n searches: [],\n keywords: [],\n indexName: \"\",\n\n // actions\n setRecommendData(item) {\n set({ currentRecommend: item });\n },\n setTotalFilter(filter) {\n set({ totalFilter: filter });\n },\n setPopularCourse(item) {\n set({ popularCourse: item });\n },\n setSearches(item) {\n set({ searches: item });\n },\n setKeywords(item) {\n set({ keywords: item });\n },\n setIndexName(item) {\n set({ indexName: item });\n },\n}));\n","import React, { ReactNode, useContext, useState } from \"react\";\nimport IconClose from \"../Icon/IconClose\";\nimport { useIsDesktop } from \"lib/device\";\nimport { isMoodleURL, useIsSubdomain, useIsTenant } from \"lib/host\";\nimport { motion } from \"framer-motion\";\nimport { useModalStore } from \"./modalStore\";\nimport { useSystemStore } from \"components/PageHeader/systemStore\";\n\nconst useOutsideClick = (callback: () => void) => {\n const ref = React.useRef();\n\n React.useEffect(() => {\n const handleClick = (event: any) => {\n if (ref.current && !(ref.current as any)?.contains(event.target)) {\n callback();\n }\n };\n\n document.addEventListener(\"click\", handleClick, true);\n\n return () => {\n document.removeEventListener(\"click\", handleClick, true);\n };\n }, [ref]);\n\n return ref;\n};\n\nexport type Props = {\n useParentRef?: any;\n isAlert?: boolean;\n isQuiz?: boolean;\n isShow?: boolean;\n isSearch?: boolean;\n isFullScreen?: boolean;\n isTopBorderTransparent?: boolean;\n contentStyles?: object;\n contentWidth?: number;\n isWidthScreen?: string;\n className?: string;\n childrenClassName?: string;\n contentClassName?: string;\n zIndex?: number;\n title?: string | ReactNode;\n onClose?(): void;\n onClickOutside?(): void;\n children: ReactNode;\n color?: string;\n hFull?: Boolean;\n bottomChildren?: ReactNode;\n customTitleElement?: ReactNode;\n};\n\nconst Modal: React.FC = ({\n useParentRef = null,\n isAlert = false,\n isQuiz = false,\n isShow,\n isSearch = false,\n isFullScreen,\n isTopBorderTransparent,\n className,\n childrenClassName,\n contentClassName,\n zIndex,\n contentStyles,\n contentWidth,\n isWidthScreen,\n title,\n onClose,\n onClickOutside,\n children,\n color = \"#19093A\",\n hFull = true,\n bottomChildren,\n customTitleElement,\n}) => {\n const isDesktop = useIsDesktop();\n const isSubdomainTenant = useIsSubdomain();\n const isTenantURL = useIsTenant();\n const isB2B = isTenantURL;\n const [isClosed, setisClosed] = useState(false);\n // const { openModal } = useModalStore((state) => state);\n const isSijuleTenant =\n typeof window !== \"undefined\" && isMoodleURL(window.location.hostname);\n const theme = useSystemStore((state) => state.theme);\n const screen = typeof window !== \"undefined\" && window.innerWidth;\n const isMobile = screen < 770;\n\n const transitionDuration = 700;\n\n const onCloseModal = () => {\n // openModal(false);\n setisClosed(true);\n setTimeout(() => {\n onClose();\n setisClosed(false);\n }, transitionDuration);\n };\n\n const ref = useOutsideClick(() => {\n if (onClickOutside) {\n setisClosed(true);\n setTimeout(() => {\n onClickOutside();\n setisClosed(false);\n }, transitionDuration);\n }\n });\n\n // if (isSearch) {\n // openModal(isSearch);\n // }\n\n if (isShow) {\n return (\n \n \n \n {customTitleElement ?? (\n \n {title && (\n

{title}

\n )}\n {onClose && (\n \n \n \n )}\n \n )}\n\n
{children}
\n\n {bottomChildren && (\n \n {bottomChildren}\n \n )}\n \n \n\n \n \n );\n }\n return null;\n};\n\nexport default Modal;\n","import { useEffect, useState } from 'react';\nimport ReactDOM from 'react-dom';\n\ntype ModalPortalProps = {\n children: React.ReactNode;\n};\n\nconst ModalPortal: React.FC = ({ children }) => {\n const [mounted, setMounted] = useState(false);\n\n useEffect(() => {\n setMounted(true);\n return () => {\n setMounted(false);\n };\n }, []);\n\n if (typeof document === 'undefined' || !mounted) return null;\n\n const modalRoot = document.getElementById('modal');\n\n return ReactDOM.createPortal(children, modalRoot);\n};\n\nexport default ModalPortal;\n\n","import ModalPortal from './ModalPortal';\n\ntype ModalProps = {\n children: React.ReactNode;\n closeModal?: () => void;\n show?: Boolean;\n hide?: Boolean;\n isCenter?: Boolean;\n isBottom?: Boolean;\n zIdx?: number;\n top?: string;\n isFull?: Boolean;\n}\n\nconst Modal: React.FC = ({\n children,\n closeModal,\n show = true,\n isCenter = false,\n isBottom = false,\n zIdx = 0,\n isFull = false,\n hide = false,\n top = '0',\n}) => {\n if (!show) return null\n\n const modal_style = {\n position: 'fixed',\n transform: 'translate(-50%, -50%)',\n top: '50%',\n left: '50%',\n zIndex: 1001,\n } as React.CSSProperties;\n\n const modal_style_bottom = {\n position: 'fixed',\n transform: 'translateX(-50%)', // Only translate horizontally\n bottom: '0', // Position at the bottom\n left: '50%', // Center horizontally\n zIndex: 1001,\n } as React.CSSProperties;\n\n const modal_style_top = {\n position: 'fixed',\n transform: 'translateX(-50%)', // Only translate horizontally\n top, // Position at the top\n left: '50%', // Center horizontally\n zIndex: 1001,\n } as React.CSSProperties;\n \n const overlay = {\n zIndex: zIdx\n } as React.CSSProperties;\n\n const style = \"w-full\"\n\n return (\n \n <>\n {/* Modal content */}\n \n \n \n {children}\n \n \n \n );\n};\n\nexport default Modal;\n","export type FormatString =\n | \"numeric\"\n | \"2-digit\"\n | \"long\"\n | \"short\"\n | \"narrow\"\n | undefined;\n\nexport const toDDMMYYYY = (str: string, format?: FormatString) => {\n try {\n str = str.endsWith(\"Z\") ? str : str + \"Z\";\n const date = new Date(str);\n return date.toLocaleDateString(\"id\", {\n year: \"numeric\",\n month: format ? format : \"long\",\n day: \"numeric\",\n });\n } catch (err) {\n return \"\";\n }\n};\n\nexport const toDDMMYYYYHHMM = (\n str: string,\n format?: FormatString,\n useComma?: boolean,\n useWeekdays?: boolean\n) => {\n try {\n let comma = useComma == false ? useComma : true;\n\n str = str.endsWith(\"Z\") ? str : str + \"Z\";\n const date = new Date(str);\n\n let objectDate = {\n year: \"numeric\",\n month: format ? format : \"short\",\n day: \"numeric\",\n };\n\n if (useWeekdays) {\n //@ts-ignore\n objectDate.weekday = \"long\";\n }\n\n return (\n //@ts-ignore\n date.toLocaleDateString(\"id\", objectDate) +\n (comma ? \", \" : \" \") +\n date.toLocaleTimeString(\"id\", {\n hour: \"2-digit\",\n minute: \"2-digit\",\n })\n );\n } catch (err) {\n return \"\";\n }\n};\n\nexport const toDuration = (minute: number, isShort: boolean = true) => {\n const minuteString = isShort ? \"m\" : \" menit\";\n const hourString = isShort ? \"j\" : \" jam\";\n\n let y = minute % 3600;\n let hours = Math.floor(minute / 60);\n let minutes = y / 60;\n let seconds = y % 60;\n\n if (minute < 60) {\n return minute + minuteString;\n }\n\n if (!isShort) {\n return `${\n hours !== 0\n ? `${hours} jam ${Math.floor(minutes)} menit`\n : `${minute} menit`\n } ${Math.floor(seconds)} detik`;\n } else {\n return Math.floor(minute / 60) + hourString + minute\n ? \" \" + minute + minuteString\n : \"\";\n }\n};\n\nexport const toTime = (second: number) => {\n const secondInt = ~~second;\n const pad = (n: number) => (n < 10 ? `0${n}` : `${n}`);\n if (secondInt >= 3600) {\n return `${~~(secondInt / 3600)}:${pad(~~(~~(secondInt % 3600) / 60))}:${pad(\n secondInt % 60\n )}`;\n } else if (secondInt >= 60) {\n return `${~~(secondInt / 60)}:${pad(secondInt % 60)}`;\n } else {\n return `0:${pad(secondInt)}`;\n }\n};\n","import { useApi } from \"lib/apiFetcher\";\n\nexport const useExploreCourseCategories = () =>\n useApi(\"get\", \"/course-categories\");\n\nexport const useExploreCourseInstitutions = () =>\n useApi(\"get\", \"/course-institutions\");\n\nexport const useInstitutionsTenant = () =>\n useApi(\"get\", \"/tenants/{slug}/institutions\");\n\nexport const useAccessCourseTenant = () =>\n useApi(\"get\", \"/tenants/{slug}/access-courses\");\n\nexport const useExploreCompetences = () =>\n useApi(\"get\", \"/course-competences\");\n\nexport const useCompetenciesTenant = () =>\n useApi(\"get\", \"/tenants/{slug}/competencies\");\n\nexport const useGetCoursesByCategory = () =>\n useApi(\"get\", \"/course-institutions/{slug}\");\n"],"names":["CardCourse","isLayoutNew","className","isUncheck","isHide","props","useIsSubdomain","isDesktop","useIsDesktop","timeout","setModalTimeout","useState","checkedCard","setCheckedCard","isB2B","useIsTenant","isBusiness","updateCart","useCartStore","state","institutionImage","institution","image_url","split","length","includes","institutionName","name","classHeight","wCustom","isHorizontal","hCustom","hasUserPaid","is_paid","isCourseFree","original_price","discounted_price","isCourseFinished","enrollment_progress","finished","total","router","useRouter","events","event","property","course_name","course_slug","slug","section_name","sectionName","institution_name","index","page","pathname","t","useTranslation","div","onClick","onSelect","onMouseEnter","undefined","clearTimeout","setTimeout","trackEventGTM","trackEventGA","onMouseLeave","image_cover_url","Image","src","width","height","data-testid","style","borderRadius","IconPlayCircle","size","classes","isBgCustomized","IconPlusCircle","Images","alt","h3","LogoChip","padding","useResizeImage","review_summary","star_avg","IconStar","fill","color","formatRating","toFixed","total_learners","numberWithCommas","toLowerCase","Link","href","passHref","rel","Button","variant","skills","h5","slice","map","skill","Chip","toString","isFull","isChecked","IconCheckCircle","duration","toDuration","CardNotFound","useSmallIcon","useMaxWidth","title","message","useButton","el","label","trackEvent","reload","back","pushToTrackEvents","onClose","children","wrapperClassName","useNavbar","isLoader","useLoader","join","MoonLoader","loading","BottomNav","ContainerDesktop","classBackgroundFull","useMinHeight","useAuto","customStyle","onChangeSearch","text","placeholder","position","theme","handleClick","submitSearch","indexName","isShow","setModal","classWidth","IconSearch","default","white","form","onSubmit","e","preventDefault","input","onFocus","themeBorder","type","ModalSearchBox","push","connectStateResults","searchState","searchResults","recommendCourses","setRecommendCourses","isLoading","setIsLoading","allCourses","setAllCourses","loginState","useAuthStore","setRecommendData","useSearchStore","accessCourseApi","useAccessCourseTenant","getCourses","useGetCoursesByTenantSlug","currentUser","validQuery","query","totalData","nbHits","dataCourses","hits","seeAllBtn","searchResultsLms","showBtn","onClickEnter","span","p","searchValue","getCourseRecommend","referral","generateIndexName","window","location","hostname","subDomain","isBrowser","getSubDomain","fetch","then","res","json","ArrayObjectSortBy","data","getCookie","URLSearchParams","search","get","useEffect","newData","filter","a","tenant","is_institution_business","doFetch","onSuccess","listAccessCourses","userId","id","listForbiddenCourses","Array","isArray","forEach","course","courses","listCoursesSlug","c","user","showedCourses","onError","err","popular","hit","ItemCourse","closeModal","Math","random","SkeletonWrapper","SkeletonRect","isLMS","courseSlug","url","encodeURIComponent","searchResultsTitle","IconClose","connectSearchBox","currentRefinement","refine","q","useSystemStore","value","setValue","setTime","innerWidth","show","setShow","showLms","setLms","setShowBtn","tagsKey","institutionKey","institutionNames","tagsNames","ins","isAnyFiltered","handleReset","ref","callback","React","current","contains","target","document","addEventListener","removeEventListener","useOutsideClick","focus","toExplorePage","toHomeTenantPage","onBackHeader","BackButton","backTo","ClipLoader","themes","transparent","onChange","currentTarget","onChangeDebounced","onKeyPress","charCode","key","blur","onKeyDown","autoFocus","borderTopRightRadius","borderBottomRightRadius","courseSuggestions","contentClass","Index","CONST","Configure","hitsPerPage","SearchHitsCourse","renderResult","Modal","SearchResultsLms","searchClient","algoliasearch","InstantSearch","SearchBox","contentClassName","InstantSearchBox","createStore","set","currentRecommend","totalFilter","popularCourse","searches","keywords","item","setTotalFilter","setPopularCourse","setSearches","setKeywords","setIndexName","useParentRef","isAlert","isQuiz","isSearch","isFullScreen","isTopBorderTransparent","childrenClassName","zIndex","contentStyles","contentWidth","isWidthScreen","onClickOutside","hFull","bottomChildren","customTitleElement","isClosed","setisClosed","isSijuleTenant","isMoodleURL","isMobile","onCloseModal","motion","initial","opacity","animate","transition","transitionDuration","maxHeight","maxWidth","marginTop","button","mounted","setMounted","modalRoot","getElementById","ReactDOM","isCenter","isBottom","zIdx","hide","top","modal_style_top","transform","left","overlay","ModalPortal","bottom","toDDMMYYYY","str","format","endsWith","Date","toLocaleDateString","year","month","day","toDDMMYYYYHHMM","useComma","useWeekdays","comma","date","objectDate","weekday","toLocaleTimeString","hour","minute","isShort","minuteString","hourString","y","hours","floor","minutes","seconds","toTime","second","secondInt","pad","n","useInstitutionsTenant","useApi","useCompetenciesTenant"],"sourceRoot":""}