{"version":3,"file":"ProfilesModule.CzN_UtKZ.mjs","names":["useMemo"],"sources":["https:/asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/ProfilesModule.controls.js","https:/asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/ProfilesElement/ProfilesElement.js","https:/asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/ProfilesModule.hooks.js","https:/asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/AutoProfilesModule/AutoProfilesModule.js","https:/asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/LinkedProfilesModule/LinkedProfilesModule.js","https:/asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/ProfilesModule.js","https:/framerusercontent.com/modules/ZxiJAgYKh8tJzW8zvfwh/fqSej077nus6Umyr6IwF/ProfilesModule.js"],"sourcesContent":["import { combineObjectPropertyControls } from \"../../../libs/property-controls/helpers.js\";\nimport { QUERY_CONTROL, KEYWORD_COLLECTIONS_CONTROLS, BRAND_CURATION_CONTROLS, RECOMMENDATION_CONTROLS, PRODUCT_CONTROLS } from \"../controls.js\";\nconst AUTO_PROFILES_MODULE_QUERY = {\n  ...QUERY_CONTROL,\n  controls: combineObjectPropertyControls(BRAND_CURATION_CONTROLS, KEYWORD_COLLECTIONS_CONTROLS)\n};\nconst MANUAL_PROFILES_MODULE_QUERY = {\n  ...QUERY_CONTROL,\n  controls: combineObjectPropertyControls(PRODUCT_CONTROLS, RECOMMENDATION_CONTROLS)\n};\nexport {\n  AUTO_PROFILES_MODULE_QUERY,\n  MANUAL_PROFILES_MODULE_QUERY\n};\n","import { jsx } from \"react/jsx-runtime\";\nimport { useQueryStore } from \"../../query-store/query.store.js\";\nimport { useMemo, useEffect } from \"react\";\nimport { Profiles } from \"../../../systems/curations/Profiles/index.js\";\nimport { useTrackClickButtonEvent, useSetRootModule } from \"../../hooks.js\";\nimport { EventTrigger } from \"../../../@shared/EventTrigger/index.js\";\nimport { getPadding } from \"../../../../utils/spacing.js\";\nimport { useSegment } from \"../../../@shared/providers/SegmentProvider/SegmentProvider.js\";\nconst ProfilesElement = ({\n  loading,\n  inputs: _inputs,\n  output,\n  layout,\n  currentIndex = 0\n}) => {\n  const dispatchSetQuery = useQueryStore((state) => state.dispatchSetQuery);\n  const {\n    hasName\n  } = layout;\n  const inputs = useMemo(() => attachAdditionalQuery(_inputs, output), [_inputs, output]);\n  const currentInput = inputs[currentIndex];\n  const {\n    isVisible\n  } = useSegment();\n  const trackClickButtonEvent = useTrackClickButtonEvent(currentInput == null ? void 0 : currentInput.query);\n  const handleClick = (index, name = \"\") => () => {\n    trackClickButtonEvent({\n      type: \"image_tag\",\n      layoutPosition: index + 1,\n      name\n    });\n  };\n  const handleValueChange = (value) => {\n    if (!output) {\n      return;\n    }\n    const index = Number(value);\n    const input = inputs[index];\n    dispatchSetQuery(output, input.query);\n  };\n  useEffect(() => {\n    window == null ? void 0 : window.dispatchEvent(new CustomEvent(\"layout-done\"));\n    if (!currentInput) {\n      return;\n    }\n    if (!output) {\n      return;\n    }\n    dispatchSetQuery(output, currentInput.query);\n  }, [output, currentInput]);\n  useSetRootModule(currentInput == null ? void 0 : currentInput.query, output);\n  const padding = getPadding(layout);\n  if (!isVisible) {\n    window == null ? void 0 : window.dispatchEvent(new CustomEvent(\"layout-done\"));\n    return null;\n  }\n  return /* @__PURE__ */ jsx(Profiles.Root, { loading, value: currentIndex, defaultValue: currentIndex, dragPaddingLeft: padding.left, dragPaddingRight: padding.right, onValueChange: handleValueChange, children: /* @__PURE__ */ jsx(Profiles.List, { style: {\n    paddingTop: padding.top,\n    paddingBottom: padding.bottom,\n    lineHeight: 0\n  }, list: inputs, children: ({\n    item,\n    index\n  }) => {\n    var _a;\n    return /* @__PURE__ */ jsx(EventTrigger.Target, { onClick: handleClick(index, item == null ? void 0 : item.label), children: /* @__PURE__ */ jsx(Profiles.Item, { value: index, name: hasName ? item == null ? void 0 : item.label : \"\", imageSrc: ((_a = item == null ? void 0 : item.image) == null ? void 0 : _a.src) ?? \"\" }) });\n  } }) });\n};\nconst attachAdditionalQuery = (values, output) => {\n  return values.map((value, index) => ({\n    ...value,\n    query: {\n      ...value.query,\n      facetName: value.query.facetName,\n      keys: [...value.query.keys ?? [], `profiles-${index}`],\n      isRoot: value.query.rootOutput === void 0,\n      rootOutput: value.query.rootOutput || output\n    }\n  }));\n};\nexport {\n  ProfilesElement\n};\n","import useSWR from \"../../../node_modules/swr/core/dist/index.js\";\nimport { QueryType } from \"../types.js\";\nimport { splitToNumberArray } from \"../../../utils/splitToNumberArray.js\";\nimport { brandCurationApi } from \"../../../apis/brand-curation/BrandCurationApiService.js\";\nimport { brandSaleApi } from \"../../../apis/brand-sale/BrandSaleApiService.js\";\nimport { collectionApi } from \"../../../apis/collection/CollectionApiService.js\";\nimport { orderByDateAsc, getCurrentScheduleIndex } from \"../../../utils/date.js\";\nconst PROFILES_FETCHER_KEY = \"profiles-module/profiles\";\nconst INITIAL_PRODUCT_GROUP_INDEX = 0;\nconst useProfilesQuery = (options) => {\n  const {\n    enabled: _enabled = true,\n    query\n  } = options;\n  const enabled = _enabled && query !== void 0;\n  const {\n    data = {\n      values: []\n    },\n    isLoading,\n    ...rest\n  } = useSWR(enabled ? [PROFILES_FETCHER_KEY, query] : null, () => queryProfiles(query));\n  const hasProfiles = data.values.length > 0;\n  return {\n    isLoading: isLoading || !enabled || !hasProfiles,\n    profiles: data.values,\n    currentIndex: data.currentIndex,\n    ...rest\n  };\n};\nconst fetchBrandCurationProfiles = async (query) => {\n  if (!query.brandGroupIds) {\n    return {\n      values: []\n    };\n  }\n  const brandGroupIds = splitToNumberArray(query.brandGroupIds).join(\",\");\n  const {\n    data\n  } = await brandCurationApi.getFavoriteBrands({\n    size: query.brandSize,\n    brandGroupIds\n  });\n  return {\n    values: data.frontBrands.map((brand) => ({\n      label: brand.nameKor,\n      image: {\n        src: brand.iconImageUrl\n      },\n      query: {\n        ...query,\n        brandId: brand.frontBrandId\n      }\n    }))\n  };\n};\nconst fetchCouponCollectionProfiles = async (query) => {\n  if (!query.brandSaleId) {\n    return {\n      values: []\n    };\n  }\n  const {\n    data\n  } = await brandSaleApi.getBrandSales(query.brandSaleId);\n  return {\n    values: data.brandSaleCouponList.map((item) => ({\n      label: item.frontBrand.nameKor,\n      image: {\n        src: item.frontBrand.iconImageUrl\n      },\n      query: {\n        ...query,\n        couponCollectionId: item.couponCollectionId,\n        coupon: item.coupon,\n        frontBrand: item.frontBrand\n      }\n    }))\n  };\n};\nconst fetchKeywordCollectionsProfiles = async (query) => {\n  if (!query.keywordCollectionIds) {\n    return {\n      values: []\n    };\n  }\n  const {\n    data\n  } = await collectionApi.getCollections(splitToNumberArray(query.keywordCollectionIds));\n  const collections = orderByDateAsc(data, (x) => x.displayStartAt);\n  const currentIndex = getCurrentScheduleIndex(collections, (x) => x.displayStartAt, (x) => x.displayEndAt);\n  return {\n    values: data.map((item, index) => {\n      const collection = collections[index];\n      const {\n        title,\n        displayEndAt,\n        productGroupList,\n        coverImageUrl\n      } = item;\n      const [firstProductGroup] = productGroupList ?? [];\n      return {\n        label: title,\n        image: {\n          // NOTE:(김홍동) 현재 서버에서는 coverImageUrl을 보내고 있지 않습니다. 때문에 임시로 이미지를 추가합니다.\n          // 이구위크에서는 서버의 coverImageUrl를 사용하지 않고 커스텀으로 이미지를 추가하기 때문에 coverImageUrl이 당장 필요하지 않지만 추후에 서버에서 받아야 합니다.\n          src: coverImageUrl ?? \"https://img.29cm.co.kr/cms/202505/11f0379df9076589bb067bd6be985e23.jpg\"\n        },\n        query: {\n          type: QueryType.KeywordCollection,\n          title: collection.title,\n          keywordCollectionId: String(collection.collectionId),\n          displayEndAt: displayEndAt ?? void 0,\n          couponId: collection.couponId ?? void 0,\n          productGroups: productGroupList.map((productGroup) => ({\n            ...productGroup,\n            productGroupId: productGroup.collectionProductGroupId\n          })),\n          selectedProductGroup: firstProductGroup ? {\n            id: firstProductGroup.collectionProductGroupId,\n            sort: firstProductGroup.sort,\n            index: INITIAL_PRODUCT_GROUP_INDEX\n          } : void 0\n        }\n      };\n    }),\n    currentIndex\n  };\n};\nconst queryProfiles = (query) => {\n  if (!query) {\n    return {\n      values: []\n    };\n  }\n  switch (query.type) {\n    case QueryType.BrandCuration:\n      return fetchBrandCurationProfiles(query);\n    case QueryType.CouponCollection:\n      return fetchCouponCollectionProfiles(query);\n    case QueryType.KeywordCollections:\n      return fetchKeywordCollectionsProfiles(query);\n    default:\n      return {\n        values: []\n      };\n  }\n};\nexport {\n  useProfilesQuery\n};\n","import { jsx } from \"react/jsx-runtime\";\nimport \"../../../systems/curations/IntersectionProvider/IntersectionProvider.js\";\nimport { useIntersectionContext } from \"../../../systems/curations/IntersectionProvider/IntersectionProvider.hooks.js\";\nimport { useProfilesQuery } from \"../ProfilesModule.hooks.js\";\nimport { ProfilesElement } from \"../ProfilesElement/ProfilesElement.js\";\nconst AutoProfilesModule = ({\n  query,\n  inputs,\n  output,\n  layout\n}) => {\n  const {\n    isInView\n  } = useIntersectionContext();\n  const {\n    isLoading,\n    profiles,\n    currentIndex\n  } = useProfilesQuery({\n    query,\n    enabled: isInView\n  });\n  return /* @__PURE__ */ jsx(ProfilesElement, { loading: isLoading, inputs: profiles.map((profile, index) => {\n    const input = inputs[index];\n    return {\n      ...profile,\n      label: (input == null ? void 0 : input.label) || profile.label,\n      image: (input == null ? void 0 : input.image) || profile.image\n    };\n  }), output, layout, currentIndex });\n};\nexport {\n  AutoProfilesModule\n};\n","import { jsx } from \"react/jsx-runtime\";\nimport { useQueryStore } from \"../../query-store/query.store.js\";\nimport { ProfilesElement } from \"../ProfilesElement/ProfilesElement.js\";\nimport { useProfilesQuery } from \"../ProfilesModule.hooks.js\";\nimport \"../../../systems/curations/IntersectionProvider/IntersectionProvider.js\";\nimport { useIntersectionContext } from \"../../../systems/curations/IntersectionProvider/IntersectionProvider.hooks.js\";\nimport { createKey } from \"../../utils/key.js\";\nconst LinkedProfilesModule = ({\n  value,\n  output,\n  layout\n}) => {\n  const {\n    isInView\n  } = useIntersectionContext();\n  const query = useQueryStore((state) => state.queries[value]);\n  const {\n    isLoading,\n    profiles\n  } = useProfilesQuery({\n    query,\n    enabled: isInView\n  });\n  return /* @__PURE__ */ jsx(ProfilesElement, { loading: isLoading, inputs: profiles, output, layout }, createKey(query));\n};\nexport {\n  LinkedProfilesModule\n};\n","import { jsx } from \"react/jsx-runtime\";\nimport { addPropertyControls, ControlType } from \"framer\";\nimport { SWRErrorBoundary } from \"../../@shared/SWRErrorBoundary/SWRErrorBoundary.js\";\nimport { SectionLayout } from \"../../systems/curations/SectionLayout/SectionLayout.js\";\nimport { BREAKPOINT_CONTROLS } from \"../../../libs/property-controls/breakpoint.js\";\nimport { COMPONENT_ID_PROPS } from \"../../../libs/property-controls/component-id.js\";\nimport { THEME_CONTROLS } from \"../../../libs/property-controls/theme.js\";\nimport { ProfilesModuleInputType } from \"./ProfilesModule.types.js\";\nimport { MANUAL_PROFILES_MODULE_QUERY, AUTO_PROFILES_MODULE_QUERY } from \"./ProfilesModule.controls.js\";\nimport { ProfilesElement } from \"./ProfilesElement/ProfilesElement.js\";\nimport { AutoProfilesModule } from \"./AutoProfilesModule/AutoProfilesModule.js\";\nimport { LinkedProfilesModule } from \"./LinkedProfilesModule/LinkedProfilesModule.js\";\nimport { SEGMENT_CONTROLS } from \"../../../libs/property-controls/segment.js\";\nconst ProfilesModuleInner = ({\n  input,\n  output,\n  layout\n}) => {\n  switch (input.type) {\n    case ProfilesModuleInputType.Linked:\n      return /* @__PURE__ */ jsx(LinkedProfilesModule, { value: input.value, output, layout });\n    case ProfilesModuleInputType.Auto:\n      return /* @__PURE__ */ jsx(AutoProfilesModule, { query: input.query, inputs: input.inputs, output, layout });\n    case ProfilesModuleInputType.Manual:\n      return /* @__PURE__ */ jsx(ProfilesElement, { inputs: input.values, output, layout });\n  }\n};\nconst ProfilesModule = ({\n  theme,\n  breakpoint,\n  componentId,\n  segment,\n  ...rest\n}) => {\n  return /* @__PURE__ */ jsx(SectionLayout, { theme, breakpoint, componentId, segment, children: /* @__PURE__ */ jsx(SWRErrorBoundary, { children: /* @__PURE__ */ jsx(ProfilesModuleInner, { ...rest }) }) });\n};\naddPropertyControls(ProfilesModule, {\n  ...BREAKPOINT_CONTROLS,\n  ...THEME_CONTROLS,\n  ...SEGMENT_CONTROLS,\n  componentId: {\n    hidden: ({\n      input\n    }) => (input == null ? void 0 : input.type) === ProfilesModuleInputType.Linked,\n    ...COMPONENT_ID_PROPS.componentId\n  },\n  input: {\n    type: ControlType.Object,\n    title: \"입력 값\",\n    controls: {\n      type: {\n        type: ControlType.Enum,\n        title: \"유형\",\n        options: [ProfilesModuleInputType.Linked, ProfilesModuleInputType.Auto, ProfilesModuleInputType.Manual],\n        optionTitles: [\"연결\", \"자동\", \"수동\"]\n      },\n      value: {\n        hidden: ({\n          type\n        }) => type !== ProfilesModuleInputType.Linked,\n        type: ControlType.String,\n        title: \"출력 값\",\n        defaultValue: \"\"\n      },\n      values: {\n        hidden: ({\n          type\n        }) => type !== ProfilesModuleInputType.Manual,\n        type: ControlType.Array,\n        title: \"입력 값 목록\",\n        control: {\n          type: ControlType.Object,\n          title: \"입력 값\",\n          controls: {\n            label: {\n              type: ControlType.String,\n              title: \"이름\",\n              defaultValue: \"텍스트\",\n              displayTextArea: true,\n              description: \"최대 3줄까지 가능합니다\"\n            },\n            image: {\n              type: ControlType.ResponsiveImage,\n              title: \"이미지\"\n            },\n            query: MANUAL_PROFILES_MODULE_QUERY\n          }\n        },\n        defaultValue: [{\n          label: \"텍스트\"\n        }]\n      },\n      inputs: {\n        hidden: ({\n          type\n        }) => type !== ProfilesModuleInputType.Auto,\n        type: ControlType.Array,\n        title: \"프로필 옵션 목록\",\n        description: \"자동 유형일 때에는 데이터를 통해 가져온 옵션을 대체할 수 있습니다.\",\n        control: {\n          type: ControlType.Object,\n          title: \"입력 값\",\n          controls: {\n            label: {\n              type: ControlType.String,\n              title: \"이름\",\n              defaultValue: \"\",\n              displayTextArea: true,\n              description: \"최대 3줄까지 가능합니다\"\n            },\n            image: {\n              type: ControlType.ResponsiveImage,\n              title: \"이미지\"\n            }\n          }\n        }\n      },\n      query: {\n        hidden: ({\n          type\n        }) => type !== ProfilesModuleInputType.Auto,\n        ...AUTO_PROFILES_MODULE_QUERY\n      }\n    }\n  },\n  output: {\n    type: ControlType.String,\n    title: \"출력 값\",\n    defaultValue: \"\"\n  },\n  layout: {\n    type: ControlType.Object,\n    title: \"레이아웃\",\n    controls: {\n      hasName: {\n        type: ControlType.Boolean,\n        title: \"텍스트 노출\",\n        defaultValue: true\n      },\n      padding: {\n        type: ControlType.FusedNumber,\n        title: \"패딩\",\n        defaultValue: 0,\n        toggleKey: \"isMixed\",\n        toggleTitles: [\"All\", \"Individual\"],\n        valueKeys: [\"paddingTop\", \"paddingRight\", \"paddingBottom\", \"paddingLeft\"],\n        valueLabels: [\"T\", \"R\", \"B\", \"L\"],\n        min: 0\n      }\n    }\n  }\n});\nexport {\n  ProfilesModule,\n  ProfilesModuleInner\n};\n","import{ProfilesModule}from\"https://asset.29cm.co.kr/contents/framer/components/modules/ProfilesModule/ProfilesModule.js\";ProfilesModule.displayName=\"[조립형]Profiles\";export default ProfilesModule;\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ProfilesModule\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ProfilesModule.map"],"mappings":"8vBAA2F,IACsD,CAC3I,EAA6B,CACjC,GAAG,EACH,SAAU,EAA8B,GAAyB,EAA6B,CAC/F,CACK,EAA+B,CACnC,GAAG,EACH,SAAU,EAA8B,EAAkB,GAAwB,CACnF,yBCTuC,IACyB,IACtB,IAC6B,IACI,KACN,KACZ,KACiC,CACrF,GAAmB,CACvB,UACA,OAAQ,EACR,SACA,SACA,eAAe,KACX,CACJ,IAAM,EAAmB,EAAe,GAAU,EAAM,iBAAiB,CACnE,CACJ,WACE,EACE,EAASA,MAAc,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