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,WAAYA,EAAe,YAAaA,EAAe,kBAAmBA,EAAe,8BAA+BA,EAAe,4BAA6BE,EAAc,mBAAoBA,EAAc,kBAAmBA,EAAc,WAAYS,OAAQ,KACpjBxB,EAAQ,KAAqB,EAC9ByB,QAAS,KACRzB,EAAQ,KAAsB,GAC7BY,EAAQnY,KAAI,EAAGkD,MAAKqC,QAAQ8D,IAAW,gBAAoB,SAAU,CAAEhJ,IAAKgJ,EAAOnG,IAAKA,EAAKqC,KAAMA,QAChH,CAKA,SAAS0T,GAAM,QAAE3C,IACbA,GAAQ,EAAGN,QAAUc,MAAOoC,KAAgBvC,GAAcQ,WAAUN,MAAgB,CAChFb,OAAQ,CACJc,MAAO,EAAGA,QAAOO,SAAQ8B,WACrB,IAAIC,EACJ,OARhB,SAAsBtC,GAClB,MAAsB,UAAfA,EAAMvR,IACjB,CAMoB8T,CAAavC,GACL,gBAAoBM,EAAY,CAAE/W,IAA8B,QAAxB+Y,EAAKtC,EAAMqB,eAA4B,IAAPiB,OAAgB,EAASA,EAAGpZ,KAAKsZ,GAAWA,EAAOpW,MAAKwP,KAAK,KAAMoE,MAAOA,EAAOO,OAAQA,IAEtJ,OAAhB6B,QAAwC,IAAhBA,OAAyB,EAASA,EAAY,CAAEpC,QAAOO,SAAQ8B,QAAO,KAEtGxC,GAEPQ,MAAOD,EAAkBC,MACtBN,KAEX,C","sources":["webpack:///./app/javascript/components/CargoProfileContent/style.js","webpack:///./app/javascript/components/CargoProfileContent/loading.jsx","webpack:///./app/javascript/components/CargoProfileContent/translations.js","webpack:///./app/javascript/components/CargoProfileContent/index.jsx","webpack:///./app/javascript/components/Item/CouponList/style.js","webpack:///./app/javascript/components/Item/CouponList/useItemVoucher.js","webpack:///./app/javascript/components/Item/CouponList/loading.jsx","webpack:///./app/javascript/components/Item/CouponList/index.jsx","webpack:///./app/javascript/components/Item/GeneralInfo/Certifications/style.js","webpack:///./app/javascript/components/Item/GeneralInfo/Certifications/index.jsx","webpack:///./app/javascript/components/Item/GeneralInfo/Certifications/translations.js","webpack:///./app/javascript/components/Item/GeneralInfo/ItemCategories/style.js","webpack:///./app/javascript/components/Item/GeneralInfo/ItemCategories/index.jsx","webpack:///./app/javascript/components/Item/ItemBundle/ItemBundleShortList/BundleCard/index.jsx","webpack:///./app/javascript/components/Item/ItemBundle/ItemBundleShortList/BundleCard/loading.jsx","webpack:///./app/javascript/components/Item/ItemBundle/ItemBundleShortList/BundleCard/style.js","webpack:///./app/javascript/components/Item/ItemBundle/ItemBundleShortList/hooks.js","webpack:///./app/javascript/components/Item/ItemComparisonGroup/ComparisonByBrand/style.js","webpack:///./app/javascript/components/Item/ItemComparisonGroup/ComparisonByBrand/useItemComparisonByBrandQuery.js","webpack:///./app/javascript/components/Item/ItemComparisonGroup/ComparisonByBrand/loading.jsx","webpack:///./app/javascript/components/Item/ItemComparisonGroup/ComparisonByBrand/index.jsx","webpack:///./app/javascript/components/Item/ItemComparisonGroup/ComparisonByBrand/translations.js","webpack:///./app/javascript/components/Item/ProjectSelector/style.js","webpack:///./app/javascript/components/Item/ProjectSelector/component.jsx","webpack:///./app/javascript/components/Item/ProjectSelector/translations.js","webpack:///./app/javascript/components/Item/ProjectSelector/hooks.js","webpack:///./app/javascript/components/Me/Project/Form/translations.js","webpack:///./app/javascript/components/Me/Project/Form/index.jsx","webpack:///./app/javascript/components/Me/Project/Form/style.js","webpack:///./app/javascript/components/MyCart/Promotion/Coupons/Card/index.jsx","webpack:///./app/javascript/components/MyCart/Promotion/Coupons/Card/loading.jsx","webpack:///./app/javascript/components/MyCart/Promotion/Coupons/Card/style.js","webpack:///./app/javascript/components/MyCart/Promotion/Coupons/translations.js","webpack:///./app/javascript/components/Projects/Selector/translations.js","webpack:///./app/javascript/components/Projects/Selector/hooks.js","webpack:///./app/javascript/utilities/mutationObserver.js","webpack:///./node_modules/yet-another-react-lightbox/dist/plugins/captions/index.js","webpack:///./node_modules/yet-another-react-lightbox/dist/plugins/video/index.js"],"sourcesContent":["import styled from 'styled-components'\n\nexport const Wrapper = styled.div`\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n`\n\nexport const Header = styled.div`\n  height: 44px;\n  cursor: pointer;\n\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  gap: 16px;\n`\n\nexport const HeaderText = styled.div`\n  color: ${props => props.theme.colors.textHeading};\n  font-size: ${props => props.$size};\n  font-weight: 600;\n  margin: 0;\n`\n\nexport const Collapsible = styled.div`\n  height: ${props => props.$collapsed ? '0' : props.$height};\n  overflow: hidden;\n  transition: height 0.3s ease-in-out;\n`\n","import * as Styled from './style'\nimport DescriptionLoading from '../Description/loading'\nimport { Skeleton } from '../../elements'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nconst ItemCargoProfileContentLoading = ({\n  titleSize = '18px',\n  collapsed\n}) => {\n  return (\n    <Styled.Wrapper>\n      <Styled.Header>\n        <Skeleton width=\"200px\" size={titleSize} />\n      </Styled.Header>\n\n      <Styled.Collapsible $collapsed={collapsed}>\n        <DescriptionLoading />\n      </Styled.Collapsible>\n    </Styled.Wrapper>\n  )\n}\n\nItemCargoProfileContentLoading.propTypes = {\n  titleSize: PropTypes.string,\n  collapsed: PropTypes.bool.isRequired\n}\n\nexport default ItemCargoProfileContentLoading\n","export default {\n  en: {\n    ItemCargoProfileContent: {\n      title: 'Shipping Information'\n    }\n  },\n\n  th: {\n    ItemCargoProfileContent: {\n      title: 'การจัดส่งสินค้า'\n    }\n  }\n}\n","import * as Styled from './style'\nimport ItemCargoProfileContentLoading from './loading'\nimport Description from '../Description'\n\nimport translations from '../CargoProfileContent/translations'\nimport { i18n, initializeI18n } from '../../utilities/i18n'\nimport { useMutationObserver } from '../../utilities/mutationObserver'\n\nimport React, { useState } from 'react'\nimport PropTypes from 'prop-types'\nimport { gql, useQuery } from '@apollo/client'\n\nconst QUERY = gql`\n  query ItemCargoProfileContent($itemId: String!) {\n    item(id: $itemId) {\n      id\n      cargoProfile {\n        id\n        content {\n          body\n        }\n        defaultContent {\n          body\n        }\n      }\n    }\n  }\n`\n\nconst getBody = ({ content, defaultContent }) => {\n  return content?.body || defaultContent?.body\n}\n\nconst ItemCargoProfileContent = ({\n  itemId,\n  titleAs = 'h3',\n  titleSize = '18px'\n}) => {\n  initializeI18n({ localeFiles: translations })\n\n  const [collapsibleHeight, setCollapsibleHeight] = useState('auto')\n  const [collapsed, setCollapsed] = useState(false)\n\n  const { data, loading, error } = useQuery(QUERY, { variables: { itemId } })\n  const body = getBody(data?.item?.cargoProfile || {})\n\n  const collapsibleRef = useMutationObserver(e => {\n    setCollapsibleHeight(e.offsetHeight + 'px')\n  })\n\n  if (error) { console.error(error) }\n  if (loading) return <ItemCargoProfileContentLoading titleSize={titleSize} collapsed={collapsed} />\n  if (!body) return null\n\n  const toggleCollapsed = () => {\n    setCollapsed(!collapsed)\n  }\n\n  return (\n    <Styled.Wrapper>\n      <Styled.Header onClick={toggleCollapsed}>\n        <Styled.HeaderText as={titleAs} $size={titleSize}>\n          {i18n.t('ItemCargoProfileContent.title')}\n        </Styled.HeaderText>\n        {collapsed ? <i className=\"fa-regular fa-chevron-down\"></i> : <i className=\"fa-regular fa-chevron-up\"></i>}\n      </Styled.Header>\n      <Styled.Collapsible $height={collapsibleHeight} $collapsed={collapsed}>\n        <div ref={collapsibleRef}>\n          <Description description={{ body }} />\n        </div>\n      </Styled.Collapsible>\n    </Styled.Wrapper>\n  )\n}\n\nItemCargoProfileContent.propTypes = {\n  itemId: PropTypes.string.isRequired,\n  titleAs: PropTypes.string,\n  titleSize: PropTypes.string\n}\n\nexport default ItemCargoProfileContent\n","import { styled } from 'styled-components'\n\nexport const ItemCouponList = styled.div`\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n`","import { gql, useQuery } from '@apollo/client'\n\nconst ITEM_USABLE_VOUCHERS = gql`\n  query ItemUsableVouchers($itemId: String!) {\n    item(id: $itemId) {\n      id\n      usableVouchers {\n        totalCount\n        edges {\n          node {\n            id\n            uuid\n            title\n            description\n            displayDurationDate\n          }\n        }\n      }\n    }\n  }\n`\n\nexport const useItemUsableVouchers = (itemId) => {\n  return useQuery(ITEM_USABLE_VOUCHERS, {\n    variables: { itemId }\n  })\n}\n","import * as Styled from './style'\nimport CouponCardLoading from '../..//MyCart/Promotion/Coupons/Card/loading.jsx'\n\nimport React from 'react'\n\nexport const ItemCouponListLoading = () => {\n  return (\n    <Styled.ItemCouponList>\n      <CouponCardLoading />\n    </Styled.ItemCouponList>\n  )\n}","import * as Styled from './style'\nimport { useItemUsableVouchers } from './useItemVoucher'\nimport { ItemCouponListLoading } from './loading'\nimport CouponCard from '../../MyCart/Promotion/Coupons/Card'\nimport { i18n } from '../../../utilities/i18n'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nexport const ItemCouponList = ({ itemId }) => {\n  const { data, loading, error } = useItemUsableVouchers(itemId)\n  const { item } = data || {}\n  const { usableVouchers } = item || {}\n  const { totalCount, edges } = usableVouchers || {}\n  const vouchers = edges?.map(({ node }) => node) || []\n\n  if (loading) return <ItemCouponListLoading />\n  if (error) return <ItemCouponListLoading />\n\n  if (!totalCount || totalCount === 0) return null\n\n  return (\n    <Styled.ItemCouponList>\n      {vouchers.map(voucher => (\n        <CouponCard\n          key={voucher.id}\n          coupon={voucher}\n          href={`/${i18n.locale}/vouchers/${voucher.uuid}`}\n          onChangeVoucher={() => {}} // Do nothing for this case\n          hideUseButton={true}\n        />\n      ))}\n    </Styled.ItemCouponList>\n  )\n}\nItemCouponList.propTypes = {\n  itemId: PropTypes.string.isRequired\n}","import { Link } from '../../../../elements'\n\nimport styled from 'styled-components'\n\nexport const Wrapper = styled.div`\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n`\n\nexport const CertificationContainer = styled.div`\n  display: grid;\n  grid-template-columns: ${props => props.$isMobile ? '1fr' : '1fr 1fr'};\n  gap: 16px;\n`\n\nexport const Header = styled.h3`\n  font-size: 16px;\n  font-weight: 600;\n  margin: 0;\n`\n\nexport const Section = styled.div`\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n  padding: 16px;\n  border-radius: 8px;\n  border: 1px solid ${props => props.theme.colors.zinc300};\n`\n\nexport const SubHeader = styled.h4`\n  font-size: 14px;\n  font-weight: 600;\n  margin: 0;\n`\n\nexport const Box = styled(Link)`\n  display: flex;\n  gap: 8px;\n  align-items: center;\n\n  &:hover {\n    text-decoration: none;\n  }\n`\n\nexport const Image = styled.div`\n  height: ${props => props.$isMobile ? '24px' : '32px'};\n\n  img {\n    height: 100%;\n  }\n`\n\nexport const Label = styled.div`\n  color: ${props => props.theme.colors.textSubHeading};\n  font-size: 14px;\n  flex: 1;\n\n  :hover {\n    color: ${props => props.theme.colors.textLink};\n  }\n  a {\n    color: ${props => props.theme.colors.textSubHeading};\n  }\n  a::after {\n   content: \", \"\n  }\n  a:last-of-type::after{\n    display: none;\n  }\n`\n","import * as Styled from './style'\nimport translations from './translations'\n\nimport { i18n, initializeI18n } from '../../../../utilities/i18n'\nimport TGLLogo from '../../../../../assets/images/base/logos/tgl.png'\nimport TISLogo from '../../../../../assets/images/base/logos/tis.png'\nimport { Link } from 'elements'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\nimport { gql, useSuspenseQuery } from '@apollo/client'\n\nconst QUERY = gql`\n  query ItemThaiIndustrialStandard($itemId: String!) {\n    item(id: $itemId) {\n      id\n      thaiGreenLabels {\n        id\n        tglNo\n        name\n        url\n      }\n      thaiIndustrialStandard {\n        id\n        tisNo\n        url\n      }\n    }\n  }\n`\n\ninitializeI18n({ localeFiles: translations })\n\nconst renderTGL = (thaiGreenLabels, isMobile) => {\n  if (!thaiGreenLabels.length) return null\n\n  return (\n    <Styled.Section>\n      <Styled.SubHeader>{i18n.t('Certifications.tgl')}</Styled.SubHeader>\n\n      <Styled.Box as=\"div\">\n        <Styled.Image $isMobile={isMobile}>\n          <img src={TGLLogo} />\n        </Styled.Image>\n        <Styled.Label>\n          {i18n.t('Certifications.tglNo')} {renderTGLNo(thaiGreenLabels)}\n        </Styled.Label>\n      </Styled.Box>\n    </Styled.Section>\n  )\n}\n\nconst renderTGLNo = thaiGreenLabels => {\n  return thaiGreenLabels.map(({ tglNo, name, url }) => {\n    const label = name ? name : `TGL-${tglNo}`\n    const mixpanelObj = {\n      event: 'Click TGL',\n      params: {\n        tglNo: tglNo\n      }\n    }\n    return (\n      <Link key={tglNo} id={tglNo} href={url} mixpanelObj={mixpanelObj}>\n        {label}\n      </Link>\n    )\n  })\n}\n\nconst renderTIS = (thaiIndustrialStandard, isMobile) => {\n  if (!thaiIndustrialStandard) return null\n\n  const tisNo = thaiIndustrialStandard.tisNo\n\n  return (\n    <Styled.Section>\n      <Styled.SubHeader>{i18n.t('Certifications.tis')}</Styled.SubHeader>\n\n      <Styled.Box href={thaiIndustrialStandard.url} id={tisNo} >\n        <Styled.Image $isMobile={isMobile}>\n          <img src={TISLogo} />\n        </Styled.Image>\n        <Styled.Label>\n          {i18n.t('Certifications.tisNo', { code: tisNo })}\n        </Styled.Label>\n      </Styled.Box>\n    </Styled.Section>\n  )\n}\n\n// TODO: Add loading here\nconst ItemCertifications = ({ itemId, isMobile = false }) => {\n  const { data, error } = useSuspenseQuery(QUERY, { variables: { itemId } })\n\n  if (error) console.error(error)\n\n  const item = data.item || {}\n  const thaiIndustrialStandard = item.thaiIndustrialStandard\n  const thaiGreenLabels = item.thaiGreenLabels || []\n\n  if (!thaiGreenLabels.length && !thaiIndustrialStandard) return null\n\n  return (\n    <Styled.Wrapper>\n      <Styled.Header>{i18n.t('Certifications.title')}</Styled.Header>\n      <Styled.CertificationContainer $isMobile={isMobile}>\n        {renderTIS(thaiIndustrialStandard, isMobile)}\n        {renderTGL(thaiGreenLabels, isMobile)}\n      </Styled.CertificationContainer>\n    </Styled.Wrapper>\n  )\n}\n\nItemCertifications.propTypes = {\n  itemId: PropTypes.string.isRequired,\n  isMobile: PropTypes.bool\n}\n\nexport default ItemCertifications\n","export default {\n  en: {\n    Certifications: {\n      title: 'Standards & Certifications',\n      tgl: 'Eco-Labeling',\n      tglNo: 'Thai Green Labels (TGL):',\n      tis: 'Thai Industrial Standard (TIS)',\n      tisNo: 'TIS %{code}'\n    }\n  },\n\n  th: {\n    Certifications: {\n      title: 'มาตรฐานและฉลากที่ได้รับรอง',\n      tgl: 'ฉลากสิ่งแวดล้อม',\n      tglNo: 'ฉลากเขียว:',\n      tis: 'มาตรฐานผลิตภัณฑ์อุตสาหกรรม (มอก.)',\n      tisNo: 'มอก. %{code}'\n    }\n  }\n}\n","import styled from 'styled-components'\n\nexport const Wrapper = styled.div`\n  display: flex;\n  gap: 8px;\n  align-items: center;\n`\n\nexport const List = styled.div`\n  display: flex;\n  gap: 8px;\n  flex-wrap: wrap;\n`\n\nexport const Badge = styled.a`\n  cursor: pointer;\n\n  :hover {\n    color: ${props => props.theme.colors.textLink};\n  }\n`\n","import * as Styled from './style'\n\nimport { Badge } from '../../../../elements'\nimport React from 'react'\nimport PropTypes from 'prop-types'\nimport { gql, useQuery } from '@apollo/client'\n\nconst QUERY = gql`\n  query ItemCategories($itemId: String!) {\n    item(id: $itemId) {\n      id\n      productCategories {\n        id\n        name\n        url\n      }\n    }\n  }\n`\n\nconst renderCategoryBadges = productCategories => {\n  return productCategories.map(({ id, name, url }) => {\n    return (\n      <Badge key={id} as={Styled.Badge} href={url} htmlType=\"blue-soft\">\n        {name}\n      </Badge>\n    )\n  })\n}\n\nconst ItemCategories = ({ itemId }) => {\n  const { loading, data, error } = useQuery(QUERY, { variables: { itemId } })\n\n  if (loading) return null\n  if (error) console.error(error)\n\n  const productCategories = data.item?.productCategories || []\n\n  if (productCategories.length < 1) return null\n\n  return (\n    <Styled.Wrapper>\n      <i className=\"fa-regular fa-clone\"></i>\n\n      <Styled.List>\n        {renderCategoryBadges(productCategories)}\n      </Styled.List>\n    </Styled.Wrapper>\n  )\n}\n\nItemCategories.propTypes = {\n  itemId: PropTypes.string.isRequired\n}\n\n\n\nexport { ItemCategories }\n","import * as Styled from './style'\nimport { calculateDiffFromPercentage, formatNumber } from '../../../../../utilities/number'\n\nimport LogoHomeGray from '../../../../../../assets/images/base/osh-logo/logo-home-gray.png'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nimport { Badge, Link } from 'elements'\n\nconst renderPrice = (price, clearancePrice, listPrice, discountPercentage) => {\n  if (!price || isNaN(price)) return <Styled.PriceWrapper />\n\n  const currentPrice = clearancePrice || price\n  const displayPrice = calculateDiffFromPercentage(currentPrice, discountPercentage || 0)\n  const discount = (Math.max(listPrice, price) - displayPrice).toFixed(2)\n\n  return (\n    <Styled.PriceWrapper>\n      <Badge htmlType=\"red\" size=\"small\">- ฿ {discount}</Badge>\n      <Styled.Price>฿ {formatNumber(displayPrice)}</Styled.Price>\n    </Styled.PriceWrapper>\n  )\n}\n\nconst BundleCard = ({ data }) => {\n  const { discountPercentage, bundleItem } = data\n  const image = bundleItem.image?.medium || LogoHomeGray\n  const clearancePrice = parseFloat(bundleItem.clearancePrice || 0)\n  const price = parseFloat(bundleItem.price || 0)\n  const listPrice = parseFloat(bundleItem.listPrice || 0)\n\n  return (\n    <Link href={bundleItem.url}>\n      <Styled.Wrapper>\n        <Styled.Image src={image} alt={bundleItem.name} />\n        {renderPrice(price, clearancePrice, listPrice, discountPercentage)}\n      </Styled.Wrapper>\n    </Link>\n  )\n}\n\nBundleCard.propTypes = {\n  data: PropTypes.object.isRequired\n}\n\n\n\nexport default BundleCard\n","import * as Styled from './style'\n\nimport React from 'react'\nimport { Skeleton } from 'elements'\n\nconst BundleCardLoading = () => {\n  return (\n    <Styled.Wrapper>\n      <Skeleton width=\"100%\" height=\"auto\" customStyle={{ paddingTop: '100%' }} type=\"image\" rounded />\n\n      <Styled.PriceWrapper>\n        <Skeleton width=\"70%\" />\n        <Skeleton width=\"50px\" height=\"18px\" type=\"image\" circle />\n      </Styled.PriceWrapper>\n    </Styled.Wrapper>\n  )\n}\n\nBundleCardLoading.propTypes = {}\n\n\n\nexport default BundleCardLoading\n","import styled from 'styled-components'\n\nexport const Wrapper = styled.div`\n  background-color: ${props => props.theme.colors.white};\n  border-radius: 12px;\n  padding: 6px;\n  display: flex;\n  flex-direction: column;\n  justify-content: space-between;\n  gap: 4px;\n`\n\nexport const Image = styled.img`\n  width: 100%;\n  border-radius: 12px;\n`\n\nexport const PriceWrapper = styled.div`\n  height: 42px;\n\n  display: flex;\n  flex-direction: column;\n  justify-content: flex-end;\n`\n\nexport const Price = styled.div`\n  color: ${props => props.theme.colors.textPrice};\n  font-weight: 600;\n`\n","import translations from '../translations'\n\nimport { initializeI18n } from '../../../../utilities/i18n'\n\nimport PropTypes from 'prop-types'\nimport { gql, useQuery } from '@apollo/client'\n\nconst QUERY = gql`\n  query ItemBundleShortListHooks($itemId: String!, $limit: Int) {\n    item(id: $itemId) {\n      id\n      itemBundles(first: $limit) {\n        nodes {\n          id\n          discountPercentage\n          bundleItem {\n            id\n            name\n            listPrice\n            price\n            clearancePrice\n            url\n            image {\n              medium\n            }\n          }\n        }\n      }\n    }\n  }\n`\n\nexport const useHooks = ({\n  itemId,\n  limit\n}) => {\n  initializeI18n({ localeFiles: translations })\n\n  const { loading, data, error } = useQuery(QUERY, {\n    variables: { itemId, limit}\n  })\n\n  if (error) return console.error(error)\n\n  return {\n    dataSource: data?.item?.itemBundles?.nodes || [],\n    loading: loading\n  }\n}\n\nuseHooks.propTypes = {\n  itemId: PropTypes.string.isRequired,\n  limit: PropTypes.number\n}\n","import { styled } from 'styled-components'\n\nexport const ItemComparisonByBrandContainer = styled.div`\n  padding: 12px 16px;\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n  border-radius: 12px;\n  border: 1px solid ${({ theme }) => theme.colors.zinc300};\n`\n\nexport const Title = styled.h3`\n  font-size: 16px;\n  font-weight: 600;\n  margin: 0px;\n  color: ${({ theme }) => theme.colors.mainBlue};\n`\n\nexport const ComparisonSection = styled.div`\n  display: flex;\n  flex-direction: ${({ $direction }) => $direction};\n  gap: 16px;\n`\n\nexport const ComparironLabelSection = styled.div`\n  display: flex;\n  flex-direction: ${({ $direction }) => $direction};\n  gap: 10px;\n  justify-content: space-around;\n  > label {\n    font-size: 14px;\n    font-weight: 400;\n    margin: 0px;\n    color: ${({ theme }) => theme.colors.textHeading};\n  }\n`\n\nexport const VerticalDivider = styled.div`\n  width: 1px;\n  background-color: ${({ theme }) => theme.colors.zinc300};\n`\n\nexport const BrandCard = styled.div`\n  display: flex;\n  flex-direction: ${({ $direction }) => $direction};\n  gap: 4px;\n  justify-content: space-between;\n`\n\nexport const BrandLogo = styled.img`\n  width: 48px;\n  height: 48px;\n  border-radius: 12px;\n  border: 1px solid ${({ theme }) => theme.colors.zinc300};\n`\n\nexport const BrandName = styled.label`\n  font-size: 14px;\n  font-weight: 400;\n  margin: 0px;\n  color: ${({ theme }) => theme.colors.textHeading};\n  cursor: pointer;\n`\n\nexport const BrandSection = styled.div`\n  display: flex;\n  gap: 8px;\n  align-items: center;\n`\n\nexport const BrandPrice = styled.p`\n  font-size: 16px;\n  font-weight: 600;\n  margin: 0px;\n  color: ${({ theme }) => theme.colors.textPrice};\n  &:before {\n    content: '฿ ';\n  }\n`\n\nexport const DiscountSection = styled.div`\n  display: flex;\n  gap: 8px;\n  align-items: center;\n`\n\nexport const BrandListPrice = styled.p`\n  font-size: 14px;\n  font-weight: 400;\n  margin: 0px;\n  color: ${({ theme }) => theme.colors.textSubHeading};\n  text-decoration: line-through;\n`\n\nexport const HorizontalDivider = styled.div`\n  width: 100%;\n  height: 1px;\n  background-color: ${({ theme }) => theme.colors.zinc200};\n`\n\nexport const PriceSection = styled.div`\n  display: flex;\n  gap: 4px;\n  flex-direction: column;\n`","import { gql, useQuery } from '@apollo/client'\n\nconst GET_ITEM_COMPARISON_BY_BRAND = gql`\n  query ItemComparisonByBrand($id: String!) {\n    item(id: $id) {\n      id\n      comparisonGroups(first: 5, comparisonType: \"brand\") {\n        edges {\n          node {\n            id\n            comparisonType\n            items(first: 5) {\n              edges {\n                node {\n                  id\n                  url\n                  priceSummary {\n                    listPrice\n                    priceAfterDiscount\n                  }\n                  brand {\n                    id\n                    name\n                    logo {\n                      small\n                    }\n                  }\n                }\n              }\n            }\n          }\n        }\n      }\n    }\n  }\n`\n\nexport const useItemComparisonByBrand = (id) => {\n  return useQuery(GET_ITEM_COMPARISON_BY_BRAND, {\n    variables: { id }\n  })\n}","import { Skeleton } from 'elements'\n\nimport React from 'react'\n\nexport const ItemComparisonByBrandLoading = () => {\n  return (\n    <div>\n      <Skeleton type='image' height='160px' width='100%' rounded />\n    </div>\n  )\n}","import * as Styled from './style'\nimport { useItemComparisonByBrand } from './useItemComparisonByBrandQuery'\nimport { ItemComparisonByBrandLoading } from './loading'\nimport ItemComparisonByBrandTranslation from './translations'\nimport { formatNumber } from '../../../../utilities/number'\nimport { i18n, initializeI18n } from '../../../../utilities/i18n'\ninitializeI18n({ localeFiles: ItemComparisonByBrandTranslation })\nimport DefaultLogo from '../../../../../assets/images/base/osh-logo/logo-home-red.png'\nimport { Badge, Link } from 'elements'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nconst CompareBrandPriceCard = ({ brand, priceAfterDiscount, listPrice, direction }) => {\n  const { logo: { small }, name } = brand || { logo: { small: '' }, name: '' }\n  const discountAmount = listPrice ? parseFloat(listPrice) - parseFloat(priceAfterDiscount) : 0\n  return (\n    <Styled.BrandCard $direction={direction}>\n      <Styled.BrandSection>\n        <Styled.BrandLogo\n          src={small || DefaultLogo}\n          alt={name}\n        />\n        <Styled.BrandName>{name}</Styled.BrandName>\n      </Styled.BrandSection>\n      <Styled.PriceSection>\n        {discountAmount > 0 && (\n          <Styled.DiscountSection>\n            <Badge\n              htmlType='red'\n              rounded size='small'\n              customStyle={{ cursor: 'pointer' }}\n            >\n              -฿ {formatNumber(discountAmount)}\n            </Badge>\n            <Styled.BrandListPrice>\n              {formatNumber(listPrice)}\n            </Styled.BrandListPrice>\n          </Styled.DiscountSection>\n        )}\n        <Styled.BrandPrice>{formatNumber(priceAfterDiscount || '')}</Styled.BrandPrice>\n      </Styled.PriceSection>\n    </Styled.BrandCard>\n  )\n}\nCompareBrandPriceCard.propTypes = {\n  brand: PropTypes.object,\n  priceAfterDiscount: PropTypes.string,\n  listPrice: PropTypes.string,\n  direction: PropTypes.oneOf(['row', 'column'])\n}\n\n// Horizontal for desktop\nexport const ItemComparisonByBrandHorizontal = ({ edges }) => {\n  return edges.map(({ node }) => (\n    <Styled.ItemComparisonByBrandContainer key={node.id}>\n      <Styled.Title>{i18n.t('ItemComparisonByBrand.title')}</Styled.Title>\n      <Styled.ComparisonSection $direction='row'>\n        <Styled.ComparironLabelSection $direction='column'>\n          <label>{i18n.t('ItemComparisonByBrand.brand')}</label>\n          <label>{i18n.t('ItemComparisonByBrand.pricePerPiece')}</label>\n        </Styled.ComparironLabelSection>\n        {node.items.edges.map(({ node }, index) => {\n          const { id, url, brand, priceSummary } = node\n          const { listPrice, priceAfterDiscount } = priceSummary || { listPrice: '', priceAfterDiscount: '' }\n          return (\n            <React.Fragment key={id}>\n              {index > 0 && <Styled.VerticalDivider />}\n              <Link href={url}>\n                <CompareBrandPriceCard\n                  key={id}\n                  brand={brand}\n                  priceAfterDiscount={priceAfterDiscount}\n                  listPrice={listPrice}\n                  direction='column'\n                />\n              </Link>\n            </React.Fragment>\n          )\n        })}\n      </Styled.ComparisonSection>\n    </Styled.ItemComparisonByBrandContainer>\n  ))\n}\nItemComparisonByBrandHorizontal.propTypes = {\n  edges: PropTypes.array.isRequired\n}\n\n// Vertical for mobile\nexport const ItemComparisonByBrandVertical = ({ edges }) => {\n  return edges.map(({ node }) => (\n    <Styled.ItemComparisonByBrandContainer key={node.id}>\n      <Styled.Title>{i18n.t('ItemComparisonByBrand.title')}</Styled.Title>\n      <Styled.ComparisonSection $direction='column'>\n        <Styled.ComparironLabelSection $direction='row'>\n          <label>{i18n.t('ItemComparisonByBrand.brand')}</label>\n          <label>{i18n.t('ItemComparisonByBrand.pricePerPiece')}</label>\n        </Styled.ComparironLabelSection>\n        {node.items.edges.map(({ node }) => {\n          const { id, url, brand, priceSummary } = node\n          const { listPrice, priceAfterDiscount } = priceSummary || { listPrice: '', priceAfterDiscount: '' }\n          return (\n            <Link href={url} key={id}>\n              <CompareBrandPriceCard\n                key={id}\n                brand={brand}\n                priceAfterDiscount={priceAfterDiscount}\n                listPrice={listPrice}\n                direction='row'\n              />\n            </Link>\n          )\n        })}\n      </Styled.ComparisonSection>\n    </Styled.ItemComparisonByBrandContainer>\n  ))\n}\nItemComparisonByBrandHorizontal.propTypes = {\n  edges: PropTypes.array.isRequired\n}\n\nexport const ItemComparisonByBrand = ({ itemId, direction = 'row' }) => {\n  const { loading, error, data } = useItemComparisonByBrand(itemId)\n  const { comparisonGroups: { edges } } = data?.item || { comparisonGroups: { edges: [] }}\n\n  if (loading) return <ItemComparisonByBrandLoading />\n  if (error) return <ItemComparisonByBrandLoading />\n\n  if (edges.length === 0) return null // No data\n\n  switch (direction) {\n  case 'row':\n    return <ItemComparisonByBrandHorizontal edges={edges} />\n  case 'column':\n    return <ItemComparisonByBrandVertical edges={edges} />\n  default:\n    return null\n  }\n}\nItemComparisonByBrand.propTypes = {\n  itemId: PropTypes.string.isRequired,\n  direction: PropTypes.oneOf(['row', 'column'])\n}","export default {\n  en: {\n    ItemComparisonByBrand: {\n      title: 'Compare price with other brands',\n      brand: 'Brand',\n      pricePerPiece: 'Price/Piece',\n    }\n  },\n  th: {\n    ItemComparisonByBrand: {\n      title: 'เปรียบเทียบราคาสินค้ากับแบรนด์อื่น',\n      brand: 'แบรนด์',\n      pricePerPiece: 'ราคา/ชิ้น',\n    }\n  }\n}","import styled from 'styled-components'\n\nexport const Wrapper = styled.div`\n  height: 128px;\n  background-color: ${props => props.theme.colors.project};\n  border-radius: 16px;\n  padding: 16px 24px;\n\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n\n  position: relative;\n  overflow: hidden;\n`\n\nexport const BGImage = styled.img`\n  width: 140px;\n  height: 100%;\n  object-fit: contain;\n\n  position: absolute;\n  right: -12px;\n  top: 6px;\n`\n\nexport const Title = styled.div`\n  color: ${props => props.theme.colors.textHeading};\n  font-family: Kanit;\n  font-size: 18px;\n  font-weight: 500;\n`\n\nexport const Text = styled.div`\n  color: ${props => props.theme.colors.textPlaceholder};\n  font-size: 14px;\n\n  display: flex;\n  gap: 4px;\n  align-items: center;\n`\n","import * as Styled from './style'\n\nimport { i18n } from '../../../utilities/i18n'\n\nimport ProjectLogo from '../../../images/shared/Me/Projects/project.png'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nimport { ButtonIcon } from 'elements'\n\nconst ItemProjectSelectorComponent = ({\n  onAuthorize,\n  onOpenOptions\n}) => {\n  return (\n    <Styled.Wrapper>\n      <ButtonIcon\n        icon={<i className=\"fa-regular fa-plus\"></i>}\n        onClick={onOpenOptions}\n        htmlType=\"yellow\"\n        size=\"small\"\n        rounded />\n      <Styled.Title>{i18n.t('ProjectSelector.title')}</Styled.Title>\n      <Styled.Text\n        as=\"a\"\n        href={`/${i18n.locale}/me/projects`}\n        onClick={onAuthorize}>\n        <span>{i18n.t('ProjectSelector.description')}</span>\n        <i className=\"fa-regular fa-chevron-right\"></i>\n      </Styled.Text>\n\n      <Styled.BGImage alt=\"Assign item to projects\" src={ProjectLogo} />\n    </Styled.Wrapper>\n  )\n}\n\nItemProjectSelectorComponent.propTypes = {\n  onAuthorize: PropTypes.func.isRequired,\n  onOpenOptions: PropTypes.func.isRequired\n}\n\nexport default ItemProjectSelectorComponent\n","export default {\n  en: {\n    ProjectSelector: {\n      title: 'Add product to project',\n      description: 'What is project?',\n    }\n  },\n\n  th: {\n    ProjectSelector: {\n      title: 'เพิ่มสินค้าลงโปรเจกต์',\n      description: 'โปรเจกต์คืออะไร',\n    }\n  }\n}\n","import translations from './translations'\nimport { initializeI18n } from '../../../utilities/i18n'\n\nimport { useAuthorizationContext } from '../../../context/authorizationContext'\n\nimport { useState } from 'react'\nimport PropTypes from 'prop-types'\nimport { gql, useMutation, useQuery } from '@apollo/client'\n\nconst MUTATION = gql`\n  mutation AssignItemToProject($itemId: ID!, $projectId: ID!) {\n    assignItemToProject(itemId: $itemId, projectId: $projectId) {\n      companyProject {\n        id\n      }\n    }\n  }\n`\n\nconst QUERY = gql`\n  query ItemProjectSelectorHooks($itemId: String!) {\n    item(id: $itemId) {\n      id\n      companyProjects {\n        id\n      }\n    }\n  }\n`\n\nexport const useHooks = ({ itemId }) => {\n  initializeI18n({ localeFiles: translations })\n\n  const { onAuthorize } = useAuthorizationContext()\n  const [saving, setSaving] = useState([])\n  const [showOptionsModal, setOptionsModal] = useState(false)\n\n  const { data, error, refetch } = useQuery(QUERY, { variables: { itemId } })\n\n  if (error) return console.error(error)\n\n  const [assignToProject] = useMutation(MUTATION, {\n    onCompleted: ({ assignItemToProject: { companyProject } }) => {\n      refetch()\n      setSaving(values => values.filter(value => value !== companyProject.id))\n    }\n  })\n\n  const onAssignToProject = projectId => {\n    setSaving(values => [...values, projectId])\n    assignToProject({ variables: { itemId, projectId } })\n  }\n\n  const onOpenOptionsModal = () => {\n    onAuthorize(null, () => setOptionsModal(true))\n  }\n\n  return {\n    assignState: {\n      saving: saving,\n      selected: (data?.item?.companyProjects || []).map(({ id }) => id),\n      onAssign: onAssignToProject,\n    },\n    onAuthorize,\n    optionsState: {\n      visible: showOptionsModal,\n      onClose: () => setOptionsModal(false),\n      onOpen: onOpenOptionsModal\n    },\n  }\n}\n\nuseHooks.propTypes = {\n  itemId: PropTypes.string.isRequired,\n  isMobile: PropTypes.bool\n}\n","export default {\n  en: {\n    ProjectForm: {\n      cancel: 'Cancel',\n      create: 'Create Project',\n      description: 'Description',\n      name: 'Project Name*',\n      nameEx: 'e.g. Single House, Front Yard',\n      update: 'Update Project'\n    }\n  },\n\n  th: {\n    ProjectForm: {\n      create: 'สร้างโปรเจกต์',\n      cancel: 'ยกเลิก',\n      description: 'รายละเอียด',\n      name: 'ชื่อโปรเจกต์*',\n      nameEx: 'เช่น โครงการบ้านเดี่ยว, สวนหน้าบ้าน',\n      update: 'แก้ไขโปรเจกต์'\n    }\n  }\n}\n","import * as Styled from'./style'\nimport translations from './translations'\nimport { i18n, initializeI18n } from '../../../../utilities/i18n'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nimport { Button, Form, FormItem, Input, InputArea } from 'elements'\n\nconst findErrorMessages = (errors, key) =>{\n  return  errors.find(({ key: errorKey }) => errorKey === key)?.message\n}\n\nconst ProjectForm = ({\n  errors = [],\n  formType = 'create',\n  initialValues,\n  onCancel = () => {},\n  onSubmitForm,\n  saving,\n  showCancelBtn = false,\n  actionStyle\n}) => {\n  initializeI18n({ localeFiles: translations })\n  return (\n    <Form onSubmit={onSubmitForm}>\n      <FormItem\n        label={i18n.t('ProjectForm.name')}\n        errors={findErrorMessages(errors, 'name')}\n        spacing=\"24px\">\n        <Input\n          width=\"100%\"\n          name=\"name\"\n          defaultValue={initialValues?.name}\n          placeholder={i18n.t('ProjectForm.nameEx')}\n        />\n      </FormItem>\n      <FormItem\n        label={i18n.t('ProjectForm.description')}\n        errors={findErrorMessages(errors, 'description')}\n        spacing=\"24px\">\n        <InputArea\n          width=\"100%\"\n          name=\"description\"\n          defaultValue={initialValues?.description}\n          placeholder={i18n.t('ProjectForm.description')}\n          rows=\"3\" />\n      </FormItem>\n\n      <Styled.Actions $customStyle={actionStyle}>\n        {showCancelBtn && (\n          <Button width=\"100%\" onClick={onCancel} htmlType=\"primary-outlined\">\n            {i18n.t('ProjectForm.cancel')}\n          </Button>\n        )}\n        <Button width=\"100%\" type=\"submit\" htmlType=\"primary\" disabled={saving}>\n          {i18n.t(`ProjectForm.${formType}`)}\n        </Button>\n      </Styled.Actions>\n    </Form>\n  )\n}\n\nProjectForm.propTypes = {\n  errors: PropTypes.array,\n  formType: PropTypes.oneOf(['create', 'update']),\n  initialValues: PropTypes.object,\n  onCancel: PropTypes.func,\n  onSubmitForm: PropTypes.func.isRequired,\n  saving: PropTypes.bool,\n  showCancelBtn: PropTypes.bool,\n  actionStyle: PropTypes.any\n}\n\nexport default ProjectForm\n","import styled from 'styled-components'\n\nexport const Actions = styled.div`\n  display: flex;\n  justify-content: stretch;\n  gap: 24px;\n\n  ${props => props.$customStyle}\n`\n","import * as Styled from './style'\nimport translations from '../translations'\nimport { Button, Link } from '../../../../../elements'\n\nimport { i18n, initializeI18n } from '../../../../../utilities/i18n'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\ninitializeI18n({ localeFiles: translations })\n\nconst getAction = htmlType => {\n  switch (htmlType) {\n  case 'disabled':\n    return {\n      elementType: Button,\n      props: {\n        htmlType: 'green',\n        size: 'extraSmall',\n        children: i18n.t('CouponCard.disabled'),\n        disabled: true\n      }\n    }\n  case 'used':\n    return {\n      elementType: Styled.UsedButton,\n      props: {\n        htmlType: 'green',\n        size: 'extraSmall',\n        prefix: <i className='fa-regular fa-check' />,\n        children: i18n.t('CouponCard.used')\n      }\n    }\n  default:\n    return {\n      elementType: Styled.UseButton,\n      props: {\n        htmlType: 'green',\n        size: 'extraSmall',\n        children: i18n.t('CouponCard.use')\n      }\n    }\n  }\n}\n\nconst getHTMLType = ({ checker }, isUsed) => {\n  if (checker?.isError) return 'disabled'\n\n  return isUsed ? 'used' : 'default'\n}\n\nconst CouponCard = ({\n  bgColor = 'white',\n  href,\n  coupon,\n  onChangeVoucher,\n  isUsed = false,\n  hideUseButton = false\n}) => {\n  const htmlType = getHTMLType(coupon, isUsed)\n  const { elementType: ButtonElement, props: actionProps } = getAction(htmlType)\n  const { uuid } = coupon || {}\n\n  const handleUseVoucher = (event) => {\n    event.stopPropagation()\n    if (htmlType === 'disabled' || htmlType === 'used') return null\n\n    onChangeVoucher({ voucherId: coupon.id })\n  }\n\n  return (\n    <Styled.Wrapper as={href ? Link : 'div'} href={href}>\n      <Styled.Frame onClick={handleUseVoucher} $type={htmlType}>\n        <Styled.HeaderSection $type={htmlType}>\n          <Styled.Title $type={htmlType}>{coupon.title}</Styled.Title>\n          <Styled.LeftCurve $bgColor={bgColor} $type={htmlType} />\n          <Styled.RightCurve $bgColor={bgColor} $type={htmlType} />\n        </Styled.HeaderSection>\n\n        <Styled.BottomSection>\n          <Styled.Description>{coupon.description}</Styled.Description>\n          <Styled.FooterSection>\n            <Styled.Duration>{i18n.t('CouponCard.redeemUntil')}: {coupon.displayDurationDate}</Styled.Duration>\n            <Styled.ButtonSection>\n              <Styled.InfoIcon\n                className='fa-regular fa-info-circle'\n                onClick={event => {\n                  event.stopPropagation()\n                  event.preventDefault()\n                  // NOTE: For now this icon open new window to voucher page\n                  window.open(`/${i18n.locale}/vouchers/${uuid}`, '_blank')\n                }}\n              />\n              { !hideUseButton && <ButtonElement onClick={handleUseVoucher} {...actionProps} /> }\n            </Styled.ButtonSection>\n          </Styled.FooterSection>\n        </Styled.BottomSection>\n      </Styled.Frame>\n    </Styled.Wrapper>\n  )\n}\n\nCouponCard.propTypes = {\n  bgColor: PropTypes.string,\n  href: PropTypes.string,\n  coupon: PropTypes.shape({\n    id: PropTypes.string.isRequired,\n    title: PropTypes.string.isRequired,\n    description: PropTypes.string,\n    displayDurationDate: PropTypes.string,\n    checker: PropTypes.shape({\n      isError: PropTypes.bool\n    })\n  }).isRequired,\n  onChangeVoucher: PropTypes.func.isRequired,\n  isUsed: PropTypes.bool,\n  hideUseButton: PropTypes.bool\n}\n\nexport default CouponCard\n","import * as Styled from './style'\nimport { Skeleton } from '../../../../../elements'\n\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nconst CouponCardLoading = ({\n  bgColor = 'white',\n}) => {\n  return (\n    <Styled.Wrapper>\n      <Styled.Frame $loading>\n        <Styled.HeaderSection $loading>\n          <Skeleton size=\"16px\" />\n          <Skeleton size=\"16px\" />\n          <Styled.LeftCurve $bgColor={bgColor} $loading />\n          <Styled.RightCurve $bgColor={bgColor} $loading />\n        </Styled.HeaderSection>\n\n        <Styled.BottomSection>\n          <Styled.BackContent>\n            <Skeleton width=\"100%\" size=\"12px\" />\n            <Skeleton width=\"60%\" size=\"12px\" />\n            <Skeleton size=\"10px\" />\n          </Styled.BackContent>\n\n          <Skeleton width=\"50px\" height=\"24px\" type=\"image\" rounded />\n        </Styled.BottomSection>\n      </Styled.Frame>\n    </Styled.Wrapper>\n  )\n}\n\nCouponCardLoading.propTypes = {\n  bgColor: PropTypes.string\n}\n\nexport default CouponCardLoading\n","import { Button as ButtonElement } from '../../../../../elements'\n\nimport { styled } from 'styled-components'\n\nconst CURVE_SIZE = '16px'\nconst CURVE_POSITION = '-8px'\n\nexport const Wrapper = styled.div`\n  line-height: 1.5;\n  overflow: hidden;\n  position: relative;\n`\n\nconst getBaseColor = ({ theme, $loading, $type }) => {\n  if ($loading) return theme.colors.white\n\n  switch ($type) {\n  case 'disabled':\n    return theme.colors.grey50\n  case 'used':\n    return theme.colors.green100\n  default:\n    return theme.colors.white\n  }\n}\n\nconst getPrimaryColor = ({ theme, $loading, $type }) => {\n  if ($loading || $type === 'disabled') return theme.colors.zinc300\n\n  return theme.colors.success\n}\n\nexport const Frame = styled.div`\n  background-color: ${props => getBaseColor(props)};\n  border: 2px solid ${props => getPrimaryColor(props)};\n  border-radius: 12px;\n  display: flex;\n  flex-direction: column;\n  cursor: pointer;\n`\n\nconst getBGColor = ({ theme, $bgColor }) => {\n  return theme.colors[$bgColor] || $bgColor\n}\n\nconst BlankCurve = styled.div`\n  width: ${CURVE_SIZE};\n  height: ${CURVE_SIZE};\n  background-color: ${props => getBGColor(props)};\n  border: 2px solid ${props => getPrimaryColor(props)};\n  border-radius: 50%;\n\n  position: absolute;\n`\n\nexport const LeftCurve = styled(BlankCurve)`\n  left: ${CURVE_POSITION};\n  bottom: ${CURVE_POSITION};\n`\n\nexport const RightCurve = styled(BlankCurve)`\n  right: ${CURVE_POSITION};\n  bottom: ${CURVE_POSITION};\n`\n\nexport const HeaderSection = styled.div`\n  border-bottom: 2px dashed ${props => getPrimaryColor(props)};\n  padding: 8px;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  position: relative;\n`\n\nconst getTitleColor = ({ theme, $type }) => {\n  switch ($type) {\n  case 'disabled':\n    return theme.colors.textPlaceholder\n  case 'used':\n    return theme.colors.textDiscount\n  default:\n    return theme.colors.success\n  }\n}\n\nexport const Title = styled.div`\n  color: ${props => getTitleColor(props)};\n  font-weight: 600;\n  text-align: center;\n`\n\nexport const BottomSection = styled.div`\n  flex: auto;\n  padding: 8px;\n\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n  justify-content: space-between;\n`\n\nexport const BackContent = styled.div`\n  width: 100%;\n`\n\nexport const Description = styled.div`\n  color: ${props => props.theme.colors.textSubHeading};\n  font-size: 12px;\n  font-weight: 600;\n  min-height: 54px;\n`\n\nexport const Duration = styled.div`\n  color: ${props => props.theme.colors.textSubHeading};\n  font-size: 10px;\n  font-weight: 500;\n`\n\nexport const UseButton = styled(ButtonElement)`\n  background-color: ${props => props.theme.colors.success};\n  border-color: ${props => props.theme.colors.success};\n`\n\nexport const UsedButton = styled(ButtonElement)`\n  background-color: ${props => props.theme.colors.textDiscount};\n  border-color: ${props => props.theme.colors.textDiscount};\n`\n\nexport const InfoIcon = styled.i`\n  color: ${props => props.theme.colors.textPlaceholder};\n  font-size: 16px;\n`\n\nexport const FooterSection = styled.div`\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n`\n\nexport const ButtonSection = styled.div`\n  display: flex;\n  justify-content: flex-end;\n  align-items: center;\n  gap: 4px;\n`","export default {\n  en: {\n    CouponCard: {\n      disabled: 'Invalid',\n      use: 'Use',\n      used: 'Used',\n      redeemUntil: 'until'\n    },\n    CouponList: {\n      title: 'Other Coupons',\n    },\n    CurrentCoupon: {\n      title: 'Use Coupon'\n    }\n  },\n\n  th: {\n    CouponCard: {\n      disabled: 'ไม่ตรงเงื่อนไข',\n      use: 'ใช้',\n      used: 'ถูกใช้',\n      redeemUntil: 'แลกได้'\n    },\n    CouponList: {\n      title: 'คูปองอื่นๆ',\n    },\n    CurrentCoupon: {\n      title: 'คูปองที่ใช้'\n    }\n  }\n}\n","export default {\n  en: {\n    ProjectSelector: {\n      add: 'Add to Projects',\n      create: 'Create new project',\n      emptyAddress: 'No address',\n      grandTotal: 'Grand total of project',\n      submit: 'Submit'\n    }\n  },\n\n  th: {\n    ProjectSelector: {\n      add: 'เพิ่มลงโปรเจกต์',\n      create: 'สร้างโปรเจกต์ใหม่',\n      emptyAddress: 'ไม่ระบุสถานที่',\n      grandTotal: 'ยอดรวมสินค้าในโปรเจกต์',\n      submit: 'ยืนยัน'\n    }\n  }\n}\n","import translations from './translations'\n\nimport { initializeI18n } from '../../../utilities/i18n'\n\nimport { useState } from 'react'\nimport PropTypes from 'prop-types'\nimport { gql, useMutation, useQuery } from '@apollo/client'\n\nconst MUTATION = gql`\n  mutation CreateProject($params: CompanyProjectInput!) {\n    createCustomerProject(companyProjectParams: $params) {\n      companyProject {\n        id\n      }\n    }\n  }\n`\n\nconst QUERY = gql`\n  query ProjectSelectorHooks {\n    userCompanyProjects {\n      id\n      name\n      province {\n        id\n        name\n      }\n      district {\n        id\n        name\n      }\n      postalCode\n      oshPrice {\n        display\n      }\n    }\n  }\n`\n\nexport const useHooks = ({\n  saving,\n  selected,\n  skip\n}) => {\n  initializeI18n({ localeFiles: translations })\n\n  const [showForm, setShowForm] = useState(false)\n\n  const { loading, data, error, refetch } = useQuery(QUERY, { skip })\n  const [createProject] = useMutation(MUTATION, {\n    onCompleted: ({ createCustomerProject: { companyProject } }) => {\n      if (companyProject) {\n        refetch()\n        setShowForm(false)\n      }\n    }\n  })\n\n  if (error) return console.error(error)\n\n  const getAddress = ({ province, district, postalCode }) => {\n    if (!province || !district || !postalCode) return null\n  \n    return [province.name, district.name, postalCode].filter(Boolean).join(' ')\n  }\n\n  const isActive = projectId => {\n    return selected.includes(projectId)\n  }\n\n  const isSaving = projectId => {\n    return saving.includes(projectId)\n  }\n\n  const onSubmitForm = values => {\n    createProject({ variables: { params: values } })\n  }\n\n  return {\n    loading: loading,\n    projects: data?.userCompanyProjects || [],\n    cardState: {\n      getAddress: getAddress,\n      isActive: isActive,\n      isSaving: isSaving\n    },\n    formState: {\n      visible: showForm,\n      onClose: () => setShowForm(false),\n      onOpen: () => setShowForm(true),\n      onSubmit: onSubmitForm\n    }\n  }\n}\n\nuseHooks.propTypes = {\n  saving: PropTypes.array.isRequired,\n  selected: PropTypes.array.isRequired,\n  skip: PropTypes.bool\n}\n","import { useEffect, useRef } from 'react'\n\nexport const useMutationObserver = (callback, inputRef) => {\n  const innerRef = inputRef || useRef()\n  const element = innerRef.current\n\n  useEffect(() => {\n    onDOMChange()\n    const observer = new MutationObserver(onDOMChange)\n\n    if (element) {\n      observer.observe(element, { subtree: true, childList: true, attribute: true })\n    }\n  }, [element])\n\n  const onDOMChange = () => {\n    if (!element) return null\n\n    callback(element)\n  }\n\n  return innerRef\n}\n","import { cssClass, useLightboxProps, makeUseContext, useController, clsx, cssVar, createIcon, createIconDisabled, IconButton, addToolbarButton, createModule } from '../../index.js';\nimport * as React from 'react';\nimport { PLUGIN_CAPTIONS } from '../../types.js';\n\nconst cssPrefix = (className) => cssClass(`slide_${className}`);\n\nconst defaultCaptionsProps = {\n    descriptionTextAlign: \"start\",\n    descriptionMaxLines: 3,\n    showToggle: false,\n};\nconst resolveCaptionsProps = (captions) => ({\n    ...defaultCaptionsProps,\n    ...captions,\n});\nfunction useCaptionsProps() {\n    const { captions } = useLightboxProps();\n    return resolveCaptionsProps(captions);\n}\n\nconst CaptionsContext = React.createContext(null);\nconst useCaptions = makeUseContext(\"useCaptions\", \"CaptionsContext\", CaptionsContext);\nfunction CaptionsContextProvider({ captions, children }) {\n    const { ref } = resolveCaptionsProps(captions);\n    const [visible, setVisible] = React.useState(true);\n    const context = React.useMemo(() => ({\n        visible,\n        show: () => setVisible(true),\n        hide: () => setVisible(false),\n    }), [visible]);\n    React.useImperativeHandle(ref, () => context, [context]);\n    return React.createElement(CaptionsContext.Provider, { value: context }, children);\n}\n\nfunction Title({ title }) {\n    const { toolbarWidth } = useController();\n    const { styles } = useLightboxProps();\n    const { visible } = useCaptions();\n    if (!visible)\n        return null;\n    return (React.createElement(\"div\", { style: styles.captionsTitleContainer, className: clsx(cssPrefix(\"captions_container\"), cssPrefix(\"title_container\")) },\n        React.createElement(\"div\", { className: cssPrefix(\"title\"), style: {\n                ...(toolbarWidth ? { [cssVar(\"toolbar_width\")]: `${toolbarWidth}px` } : null),\n                ...styles.captionsTitle,\n            } }, title)));\n}\n\nfunction Description({ description }) {\n    const { descriptionTextAlign, descriptionMaxLines } = useCaptionsProps();\n    const { styles } = useLightboxProps();\n    const { visible } = useCaptions();\n    if (!visible)\n        return null;\n    return (React.createElement(\"div\", { style: styles.captionsDescriptionContainer, className: clsx(cssPrefix(\"captions_container\"), cssPrefix(\"description_container\")) },\n        React.createElement(\"div\", { className: cssPrefix(\"description\"), style: {\n                ...(descriptionTextAlign !== defaultCaptionsProps.descriptionTextAlign ||\n                    descriptionMaxLines !== defaultCaptionsProps.descriptionMaxLines\n                    ? {\n                        [cssVar(\"slide_description_text_align\")]: descriptionTextAlign,\n                        [cssVar(\"slide_description_max_lines\")]: descriptionMaxLines,\n                    }\n                    : null),\n                ...styles.captionsDescription,\n            } }, typeof description === \"string\"\n            ? description\n                .split(\"\\n\")\n                .flatMap((line, index) => [...(index > 0 ? [React.createElement(\"br\", { key: index })] : []), line])\n            : description)));\n}\n\nconst captionsIcon = () => (React.createElement(React.Fragment, null,\n    React.createElement(\"path\", { strokeWidth: 2, stroke: \"currentColor\", strokeLinejoin: \"round\", fill: \"none\", d: \"M3 5l18 0l0 14l-18 0l0-14z\" }),\n    React.createElement(\"path\", { d: \"M7 15h3c.55 0 1-.45 1-1v-1H9.5v.5h-2v-3h2v.5H11v-1c0-.55-.45-1-1-1H7c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1zm7 0h3c.55 0 1-.45 1-1v-1h-1.5v.5h-2v-3h2v.5H18v-1c0-.55-.45-1-1-1h-3c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1z\" })));\nconst CaptionsVisible = createIcon(\"CaptionsVisible\", captionsIcon());\nconst CaptionsHidden = createIconDisabled(\"CaptionsVisible\", captionsIcon());\nfunction CaptionsButton() {\n    const { visible, show, hide } = useCaptions();\n    const { render } = useLightboxProps();\n    if (render.buttonCaptions) {\n        return React.createElement(React.Fragment, null, render.buttonCaptions({ visible, show, hide }));\n    }\n    return (React.createElement(IconButton, { label: visible ? \"Hide captions\" : \"Show captions\", icon: visible ? CaptionsVisible : CaptionsHidden, renderIcon: visible ? render.iconCaptionsVisible : render.iconCaptionsHidden, onClick: visible ? hide : show }));\n}\n\nfunction Captions({ augment, addModule }) {\n    augment(({ captions: captionsProps, render: { slideFooter: renderFooter, ...restRender }, toolbar, ...restProps }) => {\n        const captions = resolveCaptionsProps(captionsProps);\n        return {\n            render: {\n                slideFooter: ({ slide }) => (React.createElement(React.Fragment, null, renderFooter === null || renderFooter === void 0 ? void 0 :\n                    renderFooter({ slide }),\n                    slide.title && React.createElement(Title, { title: slide.title }),\n                    slide.description && React.createElement(Description, { description: slide.description }))),\n                ...restRender,\n            },\n            toolbar: addToolbarButton(toolbar, PLUGIN_CAPTIONS, captions.showToggle ? React.createElement(CaptionsButton, null) : null),\n            captions,\n            ...restProps,\n        };\n    });\n    addModule(createModule(PLUGIN_CAPTIONS, CaptionsContextProvider));\n}\n\nexport { Captions as default };\n","import * as React from 'react';\nimport { useLightboxProps, useEvents, useContainerRect, useEventCallback, clsx, cssClass } from '../../index.js';\nimport { ACTIVE_SLIDE_LOADING, CLASS_FLEX_CENTER, CLASS_SLIDE_WRAPPER, ACTIVE_SLIDE_PLAYING, ACTIVE_SLIDE_COMPLETE } from '../../types.js';\n\nconst defaultVideoProps = {\n    controls: true,\n    playsInline: true,\n};\nconst resolveVideoProps = (video) => ({\n    ...defaultVideoProps,\n    ...video,\n});\nfunction useVideoProps() {\n    const { video } = useLightboxProps();\n    return resolveVideoProps(video);\n}\n\nfunction VideoSlide({ slide, offset }) {\n    const video = useVideoProps();\n    const { publish } = useEvents();\n    const { setContainerRef, containerRect } = useContainerRect();\n    const videoRef = React.useRef(null);\n    React.useEffect(() => {\n        if (offset !== 0 && videoRef.current && !videoRef.current.paused) {\n            videoRef.current.pause();\n        }\n    }, [offset]);\n    React.useEffect(() => {\n        if (offset === 0 && videoRef.current && (slide.autoPlay || video.autoPlay)) {\n            publish(ACTIVE_SLIDE_LOADING);\n            videoRef.current.play().catch(() => { });\n        }\n    }, [offset, video.autoPlay, slide.autoPlay, publish]);\n    const handleVideoRef = useEventCallback((node) => {\n        if (offset === 0 && (video.autoPlay || slide.autoPlay) && node.paused) {\n            node.play().catch(() => { });\n        }\n    });\n    const setVideoRef = React.useCallback((node) => {\n        videoRef.current = node;\n        if (node) {\n            handleVideoRef(node);\n        }\n    }, [handleVideoRef]);\n    const { width, height, poster, sources } = slide;\n    const scaleWidthAndHeight = () => {\n        const scalingProps = {};\n        scalingProps.style = { maxWidth: \"100%\", maxHeight: \"100%\" };\n        if (width && height && containerRect) {\n            const widthBound = width / height > containerRect.width / containerRect.height;\n            const elementWidth = widthBound ? containerRect.width : Math.round((containerRect.height / height) * width);\n            const elementHeight = !widthBound ? containerRect.height : Math.round((containerRect.width / width) * height);\n            scalingProps.width = elementWidth;\n            scalingProps.height = elementHeight;\n            scalingProps.style.width = elementWidth;\n            scalingProps.style.height = elementHeight;\n        }\n        return scalingProps;\n    };\n    const resolveBoolean = (attr) => {\n        if (slide[attr] === false)\n            return null;\n        if (slide[attr] === true)\n            return { [attr]: true };\n        if (video[attr] === false)\n            return null;\n        if (video[attr] === true)\n            return { [attr]: true };\n        return null;\n    };\n    const resolveString = (attr) => {\n        if (video[attr] || slide[attr]) {\n            return { [attr]: slide[attr] || video[attr] };\n        }\n        return null;\n    };\n    return (React.createElement(React.Fragment, null, sources && (React.createElement(\"div\", { ref: setContainerRef, style: {\n            width: \"100%\",\n            height: \"100%\",\n            ...(width ? { maxWidth: `${width}px` } : null),\n        }, className: clsx(cssClass(\"video_container\"), cssClass(CLASS_FLEX_CENTER), cssClass(CLASS_SLIDE_WRAPPER)) }, containerRect && (React.createElement(\"video\", { ref: setVideoRef, poster: poster, ...scaleWidthAndHeight(), ...resolveBoolean(\"controls\"), ...resolveBoolean(\"playsInline\"), ...resolveBoolean(\"loop\"), ...resolveBoolean(\"muted\"), ...resolveBoolean(\"playsInline\"), ...resolveBoolean(\"disablePictureInPicture\"), ...resolveBoolean(\"disableRemotePlayback\"), ...resolveString(\"controlsList\"), ...resolveString(\"crossOrigin\"), ...resolveString(\"preload\"), onPlay: () => {\n            publish(ACTIVE_SLIDE_PLAYING);\n        }, onEnded: () => {\n            publish(ACTIVE_SLIDE_COMPLETE);\n        } }, sources.map(({ src, type }, index) => (React.createElement(\"source\", { key: index, src: src, type: type })))))))));\n}\n\nfunction isVideoSlide(slide) {\n    return slide.type === \"video\";\n}\nfunction Video({ augment }) {\n    augment(({ render: { slide: renderSlide, ...restRender }, video, ...restProps }) => ({\n        render: {\n            slide: ({ slide, offset, rect }) => {\n                var _a;\n                if (isVideoSlide(slide)) {\n                    return (React.createElement(VideoSlide, { key: (_a = slide.sources) === null || _a === void 0 ? void 0 : _a.map((source) => source.src).join(\" \"), slide: slide, offset: offset }));\n                }\n                return renderSlide === null || renderSlide === void 0 ? void 0 : renderSlide({ slide, offset, rect });\n            },\n            ...restRender,\n        },\n        video: resolveVideoProps(video),\n        ...restProps,\n    }));\n}\n\nexport { Video as default };\n"],"names":["Wrapper","styled","div","_templateObject","_taggedTemplateLiteral","Header","_templateObject2","HeaderText","_templateObject3","props","theme","colors","textHeading","$size","Collapsible","_templateObject4","$collapsed","$height","_ref","_ref$titleSize","titleSize","collapsed","React","Styled","Skeleton","width","size","DescriptionLoading","en","ItemCargoProfileContent","title","th","QUERY","gql","_ref2","_data$item","itemId","_ref2$titleAs","titleAs","_ref2$titleSize","initializeI18n","localeFiles","translations","content","defaultContent","_useState2","_slicedToArray","useState","collapsibleHeight","setCollapsibleHeight","_useState4","setCollapsed","_useQuery","useQuery","variables","data","loading","error","body","item","cargoProfile","collapsibleRef","useMutationObserver","e","offsetHeight","console","ItemCargoProfileContentLoading","onClick","as","i18n","t","className","ref","Description","description","ItemCouponList","ITEM_USABLE_VOUCHERS","ItemCouponListLoading","CouponCardLoading","_useItemUsableVoucher","useItemUsableVouchers","_ref4","usableVouchers","totalCount","edges","vouchers","map","_ref5","node","voucher","CouponCard","key","id","coupon","href","concat","locale","uuid","onChangeVoucher","hideUseButton","CertificationContainer","$isMobile","h3","Section","zinc300","SubHeader","h4","_templateObject5","Box","Link","_templateObject6","Image","_templateObject7","Label","_templateObject8","textSubHeading","textLink","Certifications","tgl","tglNo","tis","tisNo","renderTGLNo","thaiGreenLabels","name","url","label","mixpanelObj","event","params","_ref2$isMobile","isMobile","_useSuspenseQuery","useSuspenseQuery","thaiIndustrialStandard","length","src","TISLogo","code","renderTIS","TGLLogo","renderTGL","List","Badge","a","ItemCategories","productCategories","htmlType","renderCategoryBadges","_bundleItem$image","discountPercentage","bundleItem","image","medium","LogoHomeGray","clearancePrice","parseFloat","price","listPrice","alt","isNaN","currentPrice","displayPrice","calculateDiffFromPercentage","discount","Math","max","toFixed","formatNumber","renderPrice","height","customStyle","paddingTop","type","rounded","circle","white","img","PriceWrapper","Price","textPrice","useHooks","limit","dataSource","itemBundles","nodes","propTypes","PropTypes","isRequired","ItemComparisonByBrandContainer","Title","mainBlue","ComparisonSection","_ref3","$direction","ComparironLabelSection","VerticalDivider","_ref6","BrandCard","_ref7","BrandLogo","_ref8","BrandName","_ref9","BrandSection","_templateObject9","BrandPrice","p","_templateObject10","_ref10","DiscountSection","_templateObject11","BrandListPrice","_templateObject12","_ref11","PriceSection","_templateObject13","_ref12","zinc200","_templateObject14","GET_ITEM_COMPARISON_BY_BRAND","ItemComparisonByBrandLoading","ItemComparisonByBrand","brand","pricePerPiece","CompareBrandPriceCard","priceAfterDiscount","direction","logo","small","discountAmount","DefaultLogo","cursor","ItemComparisonByBrandHorizontal","items","index","priceSummary","ItemComparisonByBrandVertical","_ref11$direction","_useItemComparisonByB","comparisonGroups","project","BGImage","Text","textPlaceholder","onAuthorize","onOpenOptions","ButtonIcon","icon","ProjectLogo","ProjectSelector","MUTATION","useAuthorizationContext","saving","setSaving","showOptionsModal","setOptionsModal","refetch","assignToProject","useMutation","onCompleted","companyProject","assignItemToProject","values","filter","value","assignState","selected","companyProjects","onAssign","projectId","_toConsumableArray","optionsState","visible","onClose","onOpen","ProjectForm","cancel","create","nameEx","update","findErrorMessages","errors","_errors$find","find","message","_ref2$errors","_ref2$formType","formType","initialValues","_ref2$onCancel","onCancel","onSubmitForm","_ref2$showCancelBtn","showCancelBtn","actionStyle","Form","onSubmit","FormItem","spacing","Input","defaultValue","placeholder","InputArea","rows","$customStyle","Button","disabled","Actions","_ref2$bgColor","bgColor","_ref2$isUsed","isUsed","_ref2$hideUseButton","checker","isError","getHTMLType","_getAction","elementType","children","prefix","getAction","ButtonElement","actionProps","handleUseVoucher","stopPropagation","voucherId","$type","$bgColor","displayDurationDate","preventDefault","window","open","Object","assign","_ref$bgColor","$loading","CURVE_SIZE","CURVE_POSITION","getPrimaryColor","success","Frame","grey50","green100","getBaseColor","BlankCurve","LeftCurve","RightCurve","HeaderSection","textDiscount","getTitleColor","BottomSection","BackContent","Duration","UseButton","UsedButton","InfoIcon","i","FooterSection","_templateObject15","ButtonSection","_templateObject16","use","used","redeemUntil","CouponList","CurrentCoupon","add","emptyAddress","grandTotal","submit","skip","showForm","setShowForm","createProject","createCustomerProject","projects","userCompanyProjects","cardState","getAddress","province","district","postalCode","Boolean","join","isActive","includes","isSaving","formState","callback","inputRef","innerRef","useRef","element","current","useEffect","onDOMChange","observer","MutationObserver","observe","subtree","childList","attribute","cssPrefix","defaultCaptionsProps","descriptionTextAlign","descriptionMaxLines","showToggle","resolveCaptionsProps","captions","CaptionsContext","useCaptions","CaptionsContextProvider","setVisible","context","show","hide","Provider","toolbarWidth","styles","style","captionsTitleContainer","captionsTitle","useCaptionsProps","captionsDescriptionContainer","captionsDescription","split","flatMap","line","captionsIcon","strokeWidth","stroke","strokeLinejoin","fill","d","CaptionsVisible","CaptionsHidden","CaptionsButton","render","buttonCaptions","renderIcon","iconCaptionsVisible","iconCaptionsHidden","Captions","augment","addModule","captionsProps","slideFooter","renderFooter","restRender","toolbar","restProps","slide","defaultVideoProps","controls","playsInline","resolveVideoProps","video","VideoSlide","offset","useVideoProps","publish","setContainerRef","containerRect","videoRef","paused","pause","autoPlay","play","catch","handleVideoRef","setVideoRef","poster","sources","resolveBoolean","attr","resolveString","maxWidth","scalingProps","maxHeight","widthBound","elementWidth","round","elementHeight","scaleWidthAndHeight","onPlay","onEnded","Video","renderSlide","rect","_a","isVideoSlide","source"],"sourceRoot":""}