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AA4B,IAAIlK,IAAI,CAC7C1H,EAAWK,gBACXL,EAAWM,uBAGR,SAASuR,EAA4B7W,GACxC,OAAO4W,EAA0B9J,IAAI9M,EACzC,C,kDCtNA,MAAM8W,EAAwB,CAC1B,iBACA,eACA,qBACA,iBACA,gBACA,gBACA,gBACA,gBACA,gBACA,kBACA,qBACA,mBACA,eACA,oBACA,eACA,iBACA,eACA,uBACA,kBACA,gBACA,kBACA,kBACA,kBACA,gBACA,sBACA,cACA,iBACA,kBACA,gBACA,kBACA,eACA,oBACA,cACA,gBACA,oBACA,gBACA,gBACA,gBACA,gBACA,iBACA,mBACA,kBACA,iBACA,kBACA,gBACA,oBACA,qBACA,oBACA,kBACA,iBACA,eACA,kBACA,eACA,oBACA,mBACA,kBACA,oBACA,6BACA,iCACA,0BACA,6BACA,6BACA,4BACA,4BACA,gBACA,mBACA,gBACA,yBACA,mBACA,gBACA,iBACA,uBACA,oBACA,iBACA,gBACA,uBACA,wBACA,uBACA,iBACA,kBACA,oBACA,kBACA,iBACA,kBACA,oBACA,wBACA,wBACA,kBACA,qBACA,kBACA,iBACA,kBACA,uBACA,iBACA,uBACA,iBACA,kBACA,mBACA,mBACA,mBACA,sBACA,sBACA,oBACA,oBACA,kBACA,oBACA,qBACA,kBACA,qBACA,oBACA,oBACA,iBACA,kBACA,iBACA,qBACA,uBACA,0BACA,6BACA,4BACA,wBACA,4BACA,0BACA,uBACA,iBACA,kBACA,kBACA,gBACA,iBACA,8BACA,qBACA,iBACA,eACA,sBACA,qBACA,wBACA,iBACA,kBACA,iBACA,kBACA,qBACA,oBACA,mBACA,kBACA,oBACA,iBACA,qBACA,sBACA,mBACA,kBACA,oBACA,qBACA,qBACA,iBACA,mBACA,kBACA,eACA,kBACA,8BACA,8BACA,iCACA,kBACA,iBACA,sBACA,qBACA,kBACA,yBACA,wBACA,sBACA,sBACA,uBACA,sBACA,uBACA,iBACA,iBACA,mBACA,qBACA,uBACA,mBACA,mBACA,wBACA,oBACA,uBACA,gBACA,wBACA,mBACA,mBACA,mBACA,oBACA,qBACA,wBACA,sBACA,gBACA,sBACA,kBACA,kBACA,kBACA,oBACA,qBACA,mBACA,kBACA,sBACA,mBACA,mBACA,4BACA,uBACA,oBACA,qBACA,oBACA,qBACA,mBACA,mBACA,oBACA,sBACA,YACA,cACA,aACA,cACA,aACA,cACA,gBACA,cACA,eACA,eACA,YACA,eACA,eACA,cACA,eACA,cACA,gBACA,aACA,kBACA,eACA,gBACA,aACA,YACA,aACA,gBACA,iBACA,YACA,cACA,iBACA,YACA,eACA,eACA,gBACA,iBACA,aACA,iBACA,eACA,gBACA,gBACA,mBACA,oBACA,eACA,cACA,aACA,eACA,gBACA,cACA,cACA,eACA,oBACA,mBACA,YACA,YACA,kBACA,iBACA,iBACA,aACA,gBACA,iBACA,eACA,cACA,cACA,gBACA,iBACA,aACA,gBACA,iBACA,qBACA,cACA,gBACA,eACA,cACA,eACA,aACA,aACA,mBACA,cACA,gBACA,iBACA,mBACA,eACA,qBACA,eACA,kBACA,mBACA,kBACA,sBACA,kBACA,mBACA,qBACA,yBACA,qBACA,mBACA,qBACA,qBACA,wBACA,mBACA,mBACA,kBACA,mBACA,qBACA,sBACA,sBACA,kBACA,mBACA,mBACA,iBACA,mBACA,gBACA,kBACA,gBACA,oBACA,kBACA,mBACA,kBACA,kBACA,kBACA,oBACA,gBACA,mBACA,kBACA,kBACA,qBACA,kBACA,gBACA,qBACA,cACA,eACA,gBACA,mBACA,gBACA,oBACA,gBACA,eACA,mBACA,eACA,gBACA,gBACA,cACA,eACA,mBACA,gBACA,cACA,cACA,gBACA,oBACA,kBACA,iBACA,oBACA,gBACA,eACA,mBACA,iBACA,gBACA,mBACA,kBACA,eACA,iBACA,gBACA,iBACA,mBACA,gBACA,gBACA,oBACA,gBACA,sBACA,gBACA,mBACA,eACA,gBACA,mBACA,cACA,kBACA,mBACA,iBACA,iBACA,eACA,mBACA,uBACA,kBACA,iBACA,gBACA,oBACA,kBACA,eACA,mBACA,oBACA,kBACA,sBACA,eACA,mBACA,mBACA,qBACA,iBACA,oBACA,iBACA,oBACA,iBACA,gBACA,eACA,kBACA,iBACA,oBACA,gBACA,mBACA,iBACA,uBACA,oBACA,iBACA,iBACA,iBACA,oBACA,eACA,eACA,kBAIEC,EAAkB,CACpB,gBACA,kBACA,mCACA,eACA,iBACA,eACA,qBACA,iBACA,kBACA,mBACA,kBACA,sBACA,uBACA,oBACA,wBACA,kBACA,gBACA,gBACA,gBACA,gBACA,iBACA,mBACA,qBACA,yBACA,mBACA,qBACA,kBACA,uBACA,gBACA,kBACA,qBACA,mBACA,qBACA,mBACA,gBACA,kBACA,qBACA,kBACA,eACA,oBACA,eACA,iBACA,qBACA,qBACA,wBACA,mBACA,mBACA,kBACA,sBACA,qBACA,eACA,uBACA,kBACA,gBACA,kBACA,mBACA,qBACA,sBACA,sBACA,kBACA,uBACA,mBACA,kBACA,kBACA,kBACA,gBACA,sBACA,kBACA,mBACA,sBACA,iBACA,sBACA,wBACA,sBACA,cACA,iBACA,kBACA,mBACA,iBACA,mBACA,gBACA,iBACA,gBACA,iBACA,iBACA,gBACA,kBACA,eACA,oBACA,kBACA,gBACA,oBACA,kBACA,aACA,cACA,gBACA,eACA,cACA,gBACA,oBACA,gBACA,mBACA,kBACA,kBACA,kBACA,gBACA,aACA,eACA,cACA,gBACA,gBACA,gBACA,iBACA,oBACA,gBACA,mBACA,kBACA,gBACA,cACA,qBACA,kBACA,mBACA,kBACA,iBACA,kBACA,kBACA,qBACA,kBACA,gBACA,kBACA,qBACA,gBACA,qBACA,gBACA,oBACA,qBACA,oBACA,qBACA,eACA,cACA,gBACA,mBACA,gBACA,kBACA,gBACA,kBACA,iBACA,eACA,kBACA,mBACA,gBACA,oBACA,gBACA,uBACA,kBACA,qBACA,qBACA,eACA,oBACA,mBACA,kBACA,eACA,mBACA,eACA,gBACA,iBACA,uBACA,cACA,mBACA,oBACA,iCACA,8BACA,4BACA,gBACA,cACA,eACA,mBACA,cACA,cACA,kBACA,iBACA,0BACA,6BACA,4BACA,iCACA,gBACA,cACA,cACA,gBACA,iBACA,kBACA,sBACA,iBACA,0BACA,6BACA,6BACA,4BACA,oBACA,kBACA,iBACA,oBACA,sBACA,eACA,MACA,oBACA,4BACA,gBACA,mBACA,mBACA,gBACA,eACA,mBACA,iBACA,qBACA,UACA,OACA,MACA,gBACA,yBACA,mBACA,gBACA,gBACA,mBACA,eACA,iBACA,QACA,OACA,MACA,UACA,iBACA,uBACA,oBACA,iBACA,gBACA,iBACA,mBACA,gBACA,UACA,YACA,YACA,aACA,gBACA,wBACA,uBACA,iBACA,gBACA,gBACA,aACA,aACA,YACA,YACA,kBACA,kBACA,iBACA,kBACA,sBACA,gBACA,mBACA,eACA,YACA,YACA,YACA,YACA,oBACA,wBACA,qBACA,kBACA,gBACA,mBACA,cACA,kBACA,YACA,YACA,YACA,YACA,iBACA,kBACA,uBACA,iBACA,mBACA,iBACA,iBACA,aACA,aACA,aACA,aACA,uBACA,iBACA,kBACA,mBACA,eACA,mBACA,uBACA,kBACA,aACA,YACA,YACA,YACA,mBACA,mBACA,sBACA,sBACA,gBACA,iBACA,gBACA,kBACA,YACA,YACA,YACA,YACA,oBACA,oBACA,oBACA,qBACA,eACA,mBACA,oBACA,kBACA,YACA,WACA,gBACA,UACA,kBACA,qBACA,oBACA,oBACA,sBACA,eACA,mBACA,iBACA,gBACA,UACA,WACA,iBACA,iBACA,kBACA,iBACA,qBACA,qBACA,iBACA,oBACA,iBACA,cACA,iBACA,kBACA,kBACA,+BACA,uBACA,0BACA,6BACA,oBACA,iBACA,gBACA,eACA,oBACA,UACA,KACA,UACA,4BACA,wBACA,4BACA,0BACA,kBACA,iBACA,oBACA,gBACA,MACA,QACA,QACA,OACA,iBACA,kBACA,kBACA,iBACA,mBACA,kBACA,uBACA,oBACA,YACA,WACA,MACA,UACA,8BACA,8BACA,qBACA,iBACA,iBACA,iBACA,iBACA,oBACA,OACA,SACA,UACA,QACA,eACA,sBACA,wBACA,iBACA,eACA,iBACA,YACA,QACA,MACA,mBACA,kBACA,iBACA,kBACA,qBACA,YACA,cACA,aACA,cACA,iBACA,iBACA,MACA,UACA,oBACA,mBACA,oBACA,iBACA,aACA,cACA,gBACA,cACA,SACA,KACA,UACA,oBACA,qBACA,sBACA,mBACA,kBACA,eACA,eACA,YACA,eACA,mBACA,iBACA,gBACA,eACA,oBACA,qBACA,qBACA,iBACA,eACA,cACA,eACA,cACA,cACA,SACA,WACA,MACA,mBACA,eACA,kBACA,8BACA,aACA,kBACA,eACA,gBACA,UACA,MACA,MACA,YACA,8BACA,iCACA,eACA,kBACA,aACA,YACA,aACA,gBACA,SACA,MACA,YACA,YACA,iBACA,qBACA,kBACA,yBACA,iBACA,YACA,cACA,mBACA,cACA,aACA,aACA,kBACA,wBACA,sBACA,sBACA,uBACA,iBACA,YACA,eACA,eACA,aACA,YACA,oBACA,cACA,uBACA,iBACA,iBACA,mBACA,gBACA,iBACA,aACA,iBACA,cACA,aACA,WACA,MACA,qBACA,mBACA,mBACA,wBACA,eACA,iBACA,gBACA,eACA,OACA,MACA,OACA,oBACA,uBACA,gBACA,wBACA,mBACA,oBACA,eACA,cACA,mBACA,mBACA,4BACA,uBACA,mBACA,mBACA,mBACA,oBACA,aACA,eACA,gBACA,cACA,oBACA,qBACA,oBACA,qBACA,qBACA,wBACA,sBACA,gBACA,cACA,eACA,oBACA,mBACA,mBACA,mBACA,oBACA,sBACA,kBACA,kBACA,kBACA,oBACA,YACA,YACA,kBACA,iBACA,qBACA,mBACA,kBACA,iBACA,aACA,gBACA,iBACA,cACA,gBACA,iBACA,aACA,gBACA,iBACA,qBACA,cACA,gBACA,eACA,cACA,eACA,aACA,aACA,mBACA,cACA,gBACA,iBACA,mBACA,eACA,cACA,qBACA,gBAGSC,E,MACTC,GAAAA,QACY9pB,IAAA,IAAC,OAAE+pB,GAAQ/pB,EAAA,OAAK4pB,EAAgBvZ,SAAS0Z,EAAO,IACvDtK,QAAO/d,IAAA,IAAC,OAAEqoB,GAA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AAA,OAC9BA,IAAAA,MAAgB,CACnDE,eAAgBF,IAAAA,OAChBG,oBAAqBH,IAAAA,OACrBI,gBAAiBJ,IAAAA,OACjBK,WAAYL,IAAAA,OACZM,UAAWN,IAAAA,OACXO,YAAaP,IAAAA,OACbQ,YAAaR,IAAAA,OACbS,iBAAkBT,IAAAA,OAClBU,YAAaV,IAAAA,OACbW,iBAAkBX,IAAAA,OAClBY,WAAYZ,IAAAA,Q","sources":["Mui/Button.js","Mui/ButtonWithLoadingEffect.js","Mui/styles/shadow.js","api/utils.js","client/utils/login.js","client/utils/queryString.js","client/utils/tracking.js","components/KeyVision/config.js","config/enterpriseReducePointMode.js","config/formTypes.js","config/functionKeysAndDisplayConfig.js","config/passcode.js","config/planKeys.js","config/postMsgEvent.js","config/promoGameTypes.js","config/promoLotteryTypes.js","config/promoOnlineStatus.js","config/promoPrizeTypes.js","config/timezone.js","editor/components/Gallery/SettingPreviews/defaultGameSetting.js","editor/components/SideBar/Prize/configs/prizeTypeConfig.js","editor/components/SideBar/Qualify/limitPlayTimes/periodPlay/PeriodPlayModeSelector.js","editor/components/SideBar/Qualify/limitPlayTimes/periodPlay/utils.js","editor/game_pickThePrize/components/SettingPreviews/defaultGameSetting.js","editor/game_pointsRedeem/components/SettingPreviews/defaultGameSetting.js","styles/common.js","styles/generateBgStyleByType.js","styles/keyframes.js","ugc/components/workPage/SettingPreviews/defaultGameSetting.js","utils/breakpoint.js","utils/colorConvert.js","utils/dateTime.js","utils/filter.js","utils/getMgmFlags.js","utils/localStorage.js","utils/manipulatePartnerSponsor.js","config/lotteryDefaultAnimationSettingValue.js","utils/parseAnimationSettings.js","utils/propTypes.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport MuiButton from '@material-ui/core/Button';\n\nconst useStyles = makeStyles({\n button: {\n padding: props => (props.variant === 'outlined' ? '5px 16px' : '6px 16px'),\n boxShadow: 'none',\n textTransform: 'initial',\n '&:active': {\n boxShadow: 'none'\n },\n '&:hover': {\n boxShadow: 'none'\n }\n }\n});\n\nfunction Button({\n forwardRef = () => {},\n disabled,\n children,\n startIcon,\n endIcon,\n variant,\n className,\n color,\n onClick,\n disableAllRipple = false,\n href,\n target,\n size,\n ...restProps\n}) {\n const classes = useStyles({ variant });\n\n return (\n \n {children}\n \n );\n}\n\nexport default Button;\n\nButton.propTypes = {\n forwardRef: PropTypes.oneOfType([PropTypes.object, PropTypes.func]),\n disabled: PropTypes.bool,\n children: PropTypes.any,\n startIcon: PropTypes.node,\n endIcon: PropTypes.node,\n variant: PropTypes.string,\n className: PropTypes.string,\n color: PropTypes.string,\n onClick: PropTypes.func\n};\n","import React from 'react';\nimport { css } from '@emotion/core';\nimport PropTypes from 'prop-types';\nimport CircularProgress from '@material-ui/core/CircularProgress';\n\nimport Button from 'Mui/Button';\nimport { absolutePositionCenterStyle } from 'styles/common';\n\nexport default function ButtonWithLoadingEffect({ isLoading, children, disabled, ...restProps }) {\n return (\n \n {isLoading && }\n {children}\n \n );\n}\n\nButtonWithLoadingEffect.propTypes = {\n ...Button.propTypes,\n isLoading: PropTypes.bool,\n children: PropTypes.node\n};\n","export const dp00 = {\n boxShadow: 'none'\n};\nexport const dp01 = {\n boxShadow:\n '0px 2px 1px -1px rgba(0,0,0,0.2),0px 1px 1px 0px rgba(0,0,0,0.14),0px 1px 3px 0px rgba(0,0,0,0.12)'\n};\nexport const dp02 = {\n boxShadow:\n '0px 3px 1px -2px rgba(0,0,0,0.2),0px 2px 2px 0px rgba(0,0,0,0.14),0px 1px 5px 0px rgba(0,0,0,0.12)'\n};\nexport const dp03 = {\n boxShadow:\n '0px 3px 3px -2px rgba(0,0,0,0.2),0px 3px 4px 0px rgba(0,0,0,0.14),0px 1px 8px 0px rgba(0,0,0,0.12)'\n};\n\nexport const dp04 = {\n boxShadow:\n '0px 2px 4px -1px rgba(0,0,0,0.2),0px 4px 5px 0px rgba(0,0,0,0.14),0px 1px 10px 0px rgba(0,0,0,0.12)'\n};\nexport const dp05 = {\n boxShadow:\n '0px 3px 5px -1px rgba(0,0,0,0.2),0px 5px 8px 0px rgba(0,0,0,0.14),0px 1px 14px 0px rgba(0,0,0,0.12)'\n};\nexport const dp06 = {\n boxShadow:\n '0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)'\n};\nexport const dp07 = {\n boxShadow:\n '0px 4px 5px -2px rgba(0,0,0,0.2),0px 7px 10px 1px rgba(0,0,0,0.14),0px 2px 16px 1px rgba(0,0,0,0.12)'\n};\nexport const dp08 = {\n boxShadow:\n '0px 5px 5px -3px rgba(0,0,0,0.2),0px 8px 10px 1px rgba(0,0,0,0.14),0px 3px 14px 2px rgba(0,0,0,0.12)'\n};\nexport const dp09 = {\n boxShadow:\n '0px 5px 6px -3px rgba(0,0,0,0.2),0px 9px 12px 1px rgba(0,0,0,0.14),0px 3px 16px 2px rgba(0,0,0,0.12)'\n};\nexport const dp10 = {\n boxShadow:\n '0px 6px 6px -3px rgba(0,0,0,0.2),0px 10px 14px 1px rgba(0,0,0,0.14),0px 4px 18px 3px rgba(0,0,0,0.12)'\n};\nexport const dp11 = {\n boxShadow:\n '0px 6px 7px -4px rgba(0,0,0,0.2),0px 11px 15px 1px rgba(0,0,0,0.14),0px 4px 20px 3px rgba(0,0,0,0.12)'\n};\nexport const dp12 = {\n boxShadow:\n '0px 7px 8px -4px rgba(0,0,0,0.2),0px 12px 17px 2px rgba(0,0,0,0.14),0px 5px 22px 4px rgba(0,0,0,0.12)'\n};\nexport const dp13 = {\n boxShadow:\n '0px 7px 8px -4px rgba(0,0,0,0.2),0px 13px 19px 2px rgba(0,0,0,0.14),0px 5px 24px 4px rgba(0,0,0,0.12)'\n};\nexport const dp14 = {\n boxShadow:\n '0px 7px 9px -4px rgba(0,0,0,0.2),0px 14px 21px 2px rgba(0,0,0,0.14),0px 5px 26px 4px rgba(0,0,0,0.12)'\n};\nexport const dp15 = {\n boxShadow:\n '0px 8px 9px -5px rgba(0,0,0,0.2),0px 15px 22px 2px rgba(0,0,0,0.14),0px 6px 28px 5px rgba(0,0,0,0.12)'\n};\nexport const dp16 = {\n boxShadow:\n '0px 8px 10px -5px rgba(0,0,0,0.2),0px 16px 24px 2px rgba(0,0,0,0.14),0px 6px 30px 5px rgba(0,0,0,0.12)'\n};\nexport const dp17 = {\n boxShadow:\n '0px 8px 11px -5px rgba(0,0,0,0.2),0px 17px 26px 2px rgba(0,0,0,0.14),0px 6px 32px 5px rgba(0,0,0,0.12)'\n};\nexport const dp18 = {\n boxShadow:\n '0px 9px 11px -5px rgba(0,0,0,0.2),0px 18px 28px 2px rgba(0,0,0,0.14),0px 7px 34px 6px rgba(0,0,0,0.12)'\n};\nexport const dp19 = {\n boxShadow:\n '0px 9px 12px -6px rgba(0,0,0,0.2),0px 19px 29px 2px rgba(0,0,0,0.14),0px 7px 36px 6px rgba(0,0,0,0.12)'\n};\nexport const dp20 = {\n boxShadow:\n '0px 10px 13px -6px rgba(0,0,0,0.2),0px 20px 31px 3px rgba(0,0,0,0.14),0px 8px 38px 7px rgba(0,0,0,0.12)'\n};\nexport const dp21 = {\n boxShadow:\n '0px 10px 13px -6px rgba(0,0,0,0.2),0px 21px 33px 3px rgba(0,0,0,0.14),0px 8px 40px 7px rgba(0,0,0,0.12)'\n};\nexport const dp22 = {\n boxShadow:\n '0px 10px 14px -6px rgba(0,0,0,0.2),0px 22px 35px 3px rgba(0,0,0,0.14),0px 8px 42px 7px rgba(0,0,0,0.12)'\n};\nexport const dp23 = {\n boxShadow:\n '0px 11px 14px -7px rgba(0,0,0,0.2),0px 23px 36px 3px rgba(0,0,0,0.14),0px 9px 44px 8px rgba(0,0,0,0.12)'\n};\nexport const dp24 = {\n boxShadow:\n '0px 11px 15px -7px rgba(0,0,0,0.2),0px 24px 38px 3px rgba(0,0,0,0.14),0px 9px 46px 8px rgba(0,0,0,0.12)'\n};\n\nexport const dp25 = {\n boxShadow:\n ' 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 3px rgba(0, 0, 0, 0.12), 0px 4px 15px 0px rgba(0, 0, 0, 0.20)'\n};\n","import _orderBy from 'lodash/orderBy';\nimport { parseJSON_ifParsable, transformApiResponse } from 'utils/objectManipulate';\nimport parseAnimationSettings from 'utils/parseAnimationSettings';\nimport { gameTypes, isPurePrizeGames } from 'config/promoGameTypes';\n\nexport async function normalizePromoTasksList(list = []) {\n const orderedList = _orderBy(list, ['seq']);\n\n const result = {\n allUUIDs: [],\n byUUIDs: {},\n settingsByUUIDS: {},\n optionsByUUIDS: {},\n relationByUUIDS: {}\n };\n\n for (const d of orderedList) {\n result.allUUIDs.push(d.uuid);\n const [main, settings, taskOption, styles, promotions] = normalizePromoTaskData(d);\n result.byUUIDs[d.uuid] = main;\n result.settingsByUUIDS[d.uuid] = {\n ...settings,\n ...styles\n };\n result.optionsByUUIDS[d.uuid] = taskOption;\n result.relationByUUIDS[d.uuid] = {\n uuid: promotions?.uuid\n };\n }\n\n return result;\n}\n\nfunction normalizePromoTaskData(data) {\n const {\n settings: {\n PromotionOptions: { uuid: optionUUIDS } = {},\n Task,\n Tasks,\n Styles = {},\n Promotions = {}\n } = {},\n ...rest\n } = data;\n const task = Tasks || Task || {};\n\n const convertedTask = transformApiResponse(task, {\n prefixes: ['enable'],\n suffixes: ['Type, id', 'Id'],\n Constructor: Number\n });\n const convertedStyles = transformApiResponse(Styles, {\n prefixes: ['enable'],\n suffixes: ['Type', 'id', 'Id'],\n Constructor: Number\n });\n\n return [\n rest,\n convertedTask,\n parseJSON_ifParsable(optionUUIDS, []),\n convertedStyles,\n Promotions\n ];\n}\n\nexport function normalizePromoLotteryList(list = []) {\n return list.reduce((obj, data) => {\n const {\n lottery: { type, uuid } = {},\n lotterySetting: {\n Lotteries: { showRest = 0, entryLotteryLimit, suspendWhenNoPrize } = {},\n AnimationSettings,\n Tasks: TasksSetting = {}\n } = {},\n prizeLimited,\n prizeRemainder\n } = data;\n obj[uuid] = {\n type,\n showRest,\n remainder: prizeRemainder,\n suspendWhenNoPrize,\n prizeLimited,\n entryLotteryLimit,\n AnimationSettings: parseAnimationSettings(AnimationSettings, type),\n TasksSetting\n };\n return obj;\n }, {});\n}\n\n// [#86entxjdp] 空 formbased 模組強制不 create form\nexport function canNotRetrieveFormData(formId, gameType) {\n if (!formId || isPurePrizeGames(gameType) || gameType === gameTypes.SIGN_FORM) {\n return true;\n }\n return false;\n}\n\nexport const attemptAsync = (promise, errorTypes = []) =>\n promise\n .then(response => [null, response])\n .catch(error => {\n const shouldCatch =\n errorTypes.length === 0 || errorTypes.some(type => error instanceof type);\n return shouldCatch ? [error, null] : Promise.reject(error);\n });\n","import { isMobile } from 'react-device-detect';\nimport queryString from 'query-string';\nimport * as clientErrTypes from 'config/clientErrorTypes';\nimport {\n FEVER_LOGIN_API_ENDPOINT,\n CLIENT_API_FEVER_HOST,\n IS_IFRAME_MODE,\n IS_UGC_FLOW\n} from 'config/envVariable';\nimport {\n loginTypesForLiff,\n loginTypeMappingPointRoutesParam,\n loginTypes,\n loginTypesForApi\n} from 'config/loginTypes';\nimport * as postMsgEvent from 'config/postMsgEvent';\nimport { getQsOfParentUrl } from 'client/utils/queryString';\nimport { getLogInInfoAPI } from 'client/utils/tokenManager';\nimport { setLocalStorage, getLoginSeverKeyPutIntoLocalParams } from 'utils/localStorage';\nimport { generateApiErrObj } from 'client/hooks/useClientErrorHandler';\n\nexport function getRedirectUrlFromLoginServerToPromoOrUgc({ promoUUID, promoId } = {}) {\n const { parentUrl, ...restQs } = queryString.parse(window.location.search);\n const qsOfParentUrl = getQsOfParentUrl(parentUrl);\n const qs = queryString.stringify({\n ...qsOfParentUrl,\n ...restQs,\n ...(IS_UGC_FLOW ? { ugc_path: window.location.pathname } : {})\n });\n const pathHandleLoginRedirectBack = `${\n window.location.origin\n }/promotions/${promoUUID}/${promoId}/login${qs ? `?${qs}` : ''}${window.location.hash}`;\n return pathHandleLoginRedirectBack;\n}\n\nexport function getRedirectUrlFromLoginServerToSponsorReward({\n sponsorUUID,\n loginType,\n appendQsObj = {}\n} = {}) {\n const query = { ...queryString.parse(window.location.search), ...appendQsObj };\n const qs = queryString.stringify(query);\n return `${window.location.origin}/promotions/rewards/${sponsorUUID}/${loginType}${\n qs ? `?${qs}` : ''\n }${window.location.hash}`;\n}\n\n// 返回點數紀錄頁 LoginHandle 頁\nexport function getRedirectToPointLoginHandlerUrl({\n sponsorUUID,\n pointPoolUUID,\n loginType,\n appendQsObj = {}\n} = {}) {\n const query = { ...queryString.parse(window.location.search), ...appendQsObj };\n const qs = queryString.stringify(query);\n return `${\n window.location.origin\n }/point/${sponsorUUID}/${pointPoolUUID}/${loginType}/loginHandle${qs ? `?${qs}` : ''}${\n window.location.hash\n }`;\n}\n\n// 返回點數紀錄頁面\nexport function getRedirectUrlFromLoginServerToPointRecord({\n sponsorUUID,\n pointPoolUUID,\n loginType,\n appendQsObj = {}\n} = {}) {\n const query = { ...queryString.parse(window.location.search), ...appendQsObj };\n const qs = queryString.stringify(query);\n return `${window.location.origin}/point/${sponsorUUID}/${pointPoolUUID}/${loginType}${\n qs ? `?${qs}` : ''\n }${window.location.hash}`;\n}\n\nexport function getFeverLoginUrl({ loginType, redirectUrl, sponsorUUID, appendQsObj = {} } = {}) {\n const loginUrl = `${FEVER_LOGIN_API_ENDPOINT}/auth/client/${loginType}`;\n const urlParam = {\n redirect_uri: redirectUrl,\n 'fever-host': appendQsObj?.['fever-host']\n ? appendQsObj?.['fever-host']\n : CLIENT_API_FEVER_HOST,\n sponsor_uuid: sponsorUUID\n };\n const qsString = queryString.stringify({ ...appendQsObj, ...urlParam });\n\n return `${loginUrl}?${qsString}`;\n}\n\nexport function getLiffUrl({\n liffId,\n sponsorUUID,\n loginType = loginTypesForLiff.LIFF_TOKEN,\n redirectPath,\n appendQsObj = {}\n} = {}) {\n let liffUrlQueryObj = {\n ...appendQsObj,\n login_type: loginType,\n liff_id: liffId,\n sponsor_uuid: sponsorUUID\n };\n const liffUrlQueryString = queryString.stringify(liffUrlQueryObj);\n\n return `https://liff.line.me/${liffId}${redirectPath}?${liffUrlQueryString}`;\n}\n\nexport function getEnterpriseLoginUrl({\n partner = {},\n sponsor = {},\n promoId,\n redirectUrl,\n appendQsObj = {}\n} = {}) {\n const { uuid: sponsorUUID, enterpriseShopDomain, enterpriseShopId } = sponsor;\n // [NFV-557] 91 登入串接用,讓他能在 promo 用企業登入\n const isEnterpriseCustomLogin = Boolean(enterpriseShopDomain) && Boolean(enterpriseShopId);\n if (isEnterpriseCustomLogin) {\n return getEnterpriseLoginUrlCustom(enterpriseShopDomain, enterpriseShopId, promoId);\n } else {\n return getFeverLoginUrl({\n loginType: 'enterprise',\n sponsorUUID,\n redirectUrl,\n appendQsObj: {\n ...appendQsObj,\n ...getEnterpriseLoginUrlAppendQuery({\n partner,\n sponsor,\n promoId\n })\n }\n });\n }\n}\nfunction getEnterpriseLoginUrlCustom(enterpriseShopDomain, enterpriseShopId, promoId) {\n const loginUrl = `https://${enterpriseShopDomain}/v2/FSevent/${enterpriseShopId}/${promoId}`;\n return loginUrl;\n}\nfunction getEnterpriseLoginUrlAppendQuery({ partner = {}, sponsor = {}, promoId }) {\n const {\n enableEnterpriseLoginFvQuery,\n enterpriseLoginAppId: partnerEnterpriseLoginAppId,\n enterpriseLiteLoginAppId: partnerEnterpriseLiteLoginAppId,\n enterpriseCustomizedLoginType: partnerEnterpriseCustomizedLoginType,\n enterpriseLoginSubType: partnerEnterpriseLoginSubType\n } = partner;\n const {\n id: sponsorId,\n enterpriseLoginAppId: sponsorEnterpriseLoginAppId,\n enterpriseLiteLoginAppId: sponsorEnterpriseLiteLoginAppId,\n enterpriseCustomizedLoginType: sponsorEnterpriseCustomizedLoginType,\n enterpriseLoginSubType: sponsorEnterpriseLoginSubType\n } = sponsor;\n\n let obj = {};\n if (Boolean(enableEnterpriseLoginFvQuery)) {\n obj.fv_sponsor_id = sponsorId;\n obj.fv_promo_id = promoId;\n }\n // [#86enfp1m8] 客製登入\n // [#86eq80qa4] 提供以 Cookieless 方式完成 oAuth 驗證\n // 有設定 App Id 代表有串其他平台登入\n if (sponsorEnterpriseLoginAppId || partnerEnterpriseLoginAppId) {\n // handle sponsor 有設定 subtype,但是沒有給 sponsor 對應需要的 Lite Login AppId\n if (sponsorEnterpriseLoginSubType === 'lite' && !sponsorEnterpriseLiteLoginAppId) {\n return obj;\n }\n // handle partner 有設定 subtype,但是沒有給 sponsor 對應需要的 Lite Login AppId\n if (partnerEnterpriseLoginSubType === 'lite' && !partnerEnterpriseLiteLoginAppId) {\n return obj;\n }\n\n // sponsor / partner setting 有設定 enterpriseLoginSubType 就會給subtype參數到客製化連結 (Ex: cookieless: 後端手動塞, lite: admin-tool 可以設定)\n if (partnerEnterpriseLoginSubType) {\n obj.subtype = partnerEnterpriseLoginSubType;\n }\n\n if (sponsorEnterpriseLoginSubType) {\n obj.subtype = sponsorEnterpriseLoginSubType;\n }\n\n // Ex: sponsorEnterpriseCustomizedLoginType = skm, 91App...etc\n if (sponsorEnterpriseCustomizedLoginType || partnerEnterpriseCustomizedLoginType) {\n obj.subtype = 'custom';\n }\n } else {\n // 如果沒有串其他平台登入,但他有提供 enterpriseLiteLoginAppId,那就是可以走簡易登入\n if (sponsorEnterpriseLiteLoginAppId || partnerEnterpriseLiteLoginAppId) {\n obj.subtype = 'lite';\n }\n }\n return obj;\n}\n\nconst isInMitch = window.location.host === 'events.mitch.tw';\nexport function getLoginLinkClickAction(bindRef, url) {\n if (isMobile) {\n if (IS_IFRAME_MODE) {\n return isInMitch\n ? {\n onClick: event => {\n event.preventDefault();\n setLocalStorage(getLoginSeverKeyPutIntoLocalParams());\n window.parent.postMessage(\n {\n event: postMsgEvent.PARENT_REDIRECT,\n payload: { url }\n },\n '*'\n );\n }\n }\n : {\n target: '_blank',\n href: url,\n onClick: () => {\n setLocalStorage(getLoginSeverKeyPutIntoLocalParams());\n }\n };\n } else {\n return {\n target: '_self',\n href: url,\n onClick: () => {\n setLocalStorage(getLoginSeverKeyPutIntoLocalParams());\n }\n };\n }\n } else {\n return {\n onClick: event => {\n event.preventDefault();\n bindRef.current = openWindow(url, { name: 'login' });\n setLocalStorage(getLoginSeverKeyPutIntoLocalParams());\n }\n };\n }\n}\n\nexport function openWindow(url, { name = '', width = 600, height = 700 } = {}) {\n const left = window.screen.width / 2 - width / 2;\n const top = window.screen.height / 2 - height / 2;\n return window.open(\n url,\n name,\n `menubar=0,resizable=0,width=${width},height=${height}, top=${top}, left=${left}`\n );\n}\n\nexport const getLoginUserInfo = async loginMethod => {\n if (loginMethod === loginTypes.ANONYMOUSLOGIN) {\n return { loginType: loginTypesForApi.ANONYMOUS };\n }\n if (loginMethod === loginTypes.INSTAGRAM) {\n return { loginType: loginTypesForApi.INSTAGRAM };\n }\n const [loginType] = loginTypeMappingPointRoutesParam[loginMethod] || [null];\n const resp = await getLogInInfoAPI({ loginType });\n\n if (resp[loginType] && typeof resp[loginType] === 'object') {\n const { user } = Object.values(resp[loginType])[0];\n return { ...user, loginType };\n } else {\n const maskedSensitiveResp = await recursiveMask(resp, {\n app_id: { visibleStart: 4, visibleEnd: 4 },\n code: { visibleStart: 0, visibleEnd: 0 },\n email: { visibleStart: 2, visibleEnd: 10 },\n fullname: { visibleStart: 1, visibleEnd: 0 },\n access_token: { visibleStart: 4, visibleEnd: 4 }\n });\n throw generateApiErrObj(maskedSensitiveResp, clientErrTypes.LOGIN_USER_INFO_FAILED, {\n loginType,\n loginMethod\n });\n }\n};\n\n/**\n * @description Masks a given string or value by replacing the middle portion with asterisks (`*`),\n * while keeping a specified number of characters visible at the start and end.\n * @param {string} value - The string to be masked.\n * @param {number} [visibleCharsStart=0] - The number of characters to keep visible at the start of the string.\n * @param {number} [visibleCharsEnd=0] - The number of characters to keep visible at the end of the string.\n * @returns {string} - The masked string with asterisks in the middle and visible characters at the start and end.\n *\n * @example\n * // Example 1: Masking an email address\n * const maskedEmail = maskValue('s110319022@stu.ntue.edu.tw', 2, 10);\n * // maskedEmail -> \"s1********@stu.ntue.edu.tw\"\n *\n * @example\n * // Example 2: Masking an access token\n * const maskedToken = maskValue('EAADTmsjG8VMBO1UCaT7ucEqixaJgiExvXyGwaUt', 4, 4);\n * // maskedToken -> \"EAAD************aUt\"\n */\nexport function maskValue(value, visibleCharsStart = 0, visibleCharsEnd = 0) {\n const totalLength = value.length;\n const maskedPortion = '*'.repeat(totalLength - visibleCharsStart - visibleCharsEnd);\n return (\n value.substring(0, visibleCharsStart) +\n maskedPortion +\n value.substring(totalLength - visibleCharsEnd)\n );\n}\n\n/**\n * @description Recursive function to traverse and mask the object.\n * It masks specific keys based on the provided keysToMask configuration.\n * @param {Object} obj - The object to traverse and mask.\n * @param {Object} keysToMask - An object defining which keys to mask and how many characters to show.\n * @param {Object} keysToMask.key - For each key to be masked, specify the number of visible characters at the start and end.\n * @param {number} keysToMask.key.visibleStart - The number of characters to show at the start of the value.\n * @param {number} keysToMask.key.visibleEnd - The number of characters to show at the end of the value.\n * @returns {Object} - A new object with masked values.\n *\n * @example\n * const keysToMask = {\n * \"id\": { visibleStart: 4, visibleEnd: 4 },\n * \"app_id\": { visibleStart: 4, visibleEnd: 4 },\n * \"member_uuid\": { visibleStart: 4, visibleEnd: 4 },\n * \"email\": { visibleStart: 2, visibleEnd: 10 },\n * \"fullname\": { visibleStart: 1, visibleEnd: 0 },\n * \"gender\": { visibleStart: 0, visibleEnd: 0 }, // Completely mask gender\n * \"access_token\": { visibleStart: 4, visibleEnd: 4 }\n * };\n *\n * recursiveMask(userLoginInfo, keysToMask);\n */\nexport async function recursiveMask(obj, keysToMask) {\n const _obj = { ...obj };\n\n for (let key in _obj) {\n if (typeof _obj[key] === 'object' && _obj[key] !== null) {\n // If the value is an object, call the function recursively\n _obj[key] = await recursiveMask(_obj[key], keysToMask);\n } else {\n // Apply masking for keys that are in the keysToMask argument\n if (keysToMask[key]) {\n if (typeof _obj[key] === 'string' || typeof _obj[key] === 'number') {\n const valueStr = _obj[key].toString();\n const { visibleStart, visibleEnd } = keysToMask[key];\n _obj[key] = maskValue(valueStr, visibleStart, visibleEnd);\n }\n }\n }\n }\n return _obj;\n}\n","import queryString from 'query-string';\n\nexport function qsParseNoArray(search) {\n return Object.entries(queryString.parse(search)).reduce((newObj, [key, val]) => {\n if (Array.isArray(val)) {\n newObj[key] = val[0];\n } else {\n newObj[key] = val;\n }\n return newObj;\n }, {});\n}\n\nexport function qsParseJoinArray(search) {\n return Object.entries(queryString.parse(search)).reduce((newObj, [key, val]) => {\n if (Array.isArray(val)) {\n newObj[key] = val.join(',');\n } else {\n newObj[key] = val;\n }\n return newObj;\n }, {});\n}\n\nexport function getQsOfParentUrl(parentUrl) {\n if (!parentUrl) {\n return {};\n }\n\n let url = parentUrl;\n try {\n url = decodeURIComponent(parentUrl);\n } catch (error) {\n console.log(error);\n }\n const { query } = queryString.parseUrl(url);\n return query;\n}\n\nexport function removeKeysFromQueryString(keys = []) {\n const qsObj = qsParseNoArray(window.location.search);\n const newQsObj = Object.entries(qsObj).reduce((obj, [key, val]) => {\n if (!keys.includes(key)) {\n obj[key] = val;\n }\n return obj;\n }, {});\n\n return queryString.stringify(newQsObj);\n}\n\nexport function getSubdomainIndex(url) {\n try {\n // Extract the hostname from the URL\n const hostname = new URL(url).hostname;\n\n // Split the hostname into parts\n const parts = hostname.split('.');\n\n // Calculate the subdomain index according to Meta's specification\n // Subtracting 2 aligns with Meta's counting system\n return parts.length - 2;\n } catch (error) {\n console.error('Invalid URL:', error);\n return null; // Return null if the URL is invalid\n }\n}\n","import { IS_LOCAL_DEV } from 'config/envVariable';\nimport { getGameTypeModuleName } from 'config/promoGameTypes';\nimport { filterUndefinedOrNull } from 'utils/filter';\nimport { getSubdomainIndex } from 'client/utils/queryString';\nimport { createTagManger } from 'utils/createElement';\n\nexport function initTagManager({ promo = {}, partner = {}, sponsor = {} }) {\n const { id: promoId } = promo;\n if (sponsor.reportGA4MeasurementId) {\n const { name: sponsorName, reportGA4MeasurementId } = sponsor;\n gtmAccountInfoInit({\n uniqueName: sponsorName,\n site: window.location.hostname,\n promoId,\n reportGA4MeasurementId\n });\n } else if (partner.reportGA4MeasurementId) {\n const { name: partnerName, reportGA4MeasurementId } = partner;\n gtmAccountInfoInit({\n uniqueName: partnerName,\n site: window.location.hostname,\n promoId,\n reportGA4MeasurementId\n });\n }\n\n const { openInApp: partnerOpenInApp = 'false' } = partner;\n const {\n gtmId: custom_GTM,\n adwordRemarketingId: custom_Adwords_Remarketing,\n facebookPixelId: custom_FB_Pixel,\n lineTagId: custom_Line_TagId,\n sendPageView = 1,\n customGA4MeasurementId,\n openInApp: sponsorOpenInApp = 'false'\n } = sponsor;\n gtmCustomInit({\n custom_FB_Pixel,\n custom_Adwords_Remarketing,\n custom_Line_TagId,\n send_page_view: sendPageView,\n customGA4MeasurementId,\n openInApp: JSON.parse(sponsorOpenInApp) || JSON.parse(partnerOpenInApp) || false\n });\n const nonce = window?.nonceForCSP || '';\n createTagManger(custom_GTM, nonce);\n}\n\nfunction pushDataLayer() {\n if (IS_LOCAL_DEV) {\n return;\n }\n try {\n window.dataLayer = window.dataLayer || [];\n if (arguments.length > 1) {\n window.dataLayer.push(arguments);\n } else if (arguments[0]) {\n window.dataLayer.push(arguments[0]);\n }\n } catch (error) {\n console.log('Push data layer failed:', error);\n }\n}\n\nexport function gtmAccountInfoInit({ uniqueName, site, promoId, reportGA4MeasurementId }) {\n pushDataLayer({\n uniqueName,\n site,\n promoId,\n reportGA4MeasurementId\n });\n}\n\nexport function gtmCustomInit({\n custom_FB_Pixel,\n custom_Adwords_Remarketing,\n custom_Line_TagId,\n send_page_view,\n customGA4MeasurementId,\n openInApp\n}) {\n pushDataLayer({\n event: 'render',\n action: 'render_done',\n custom_FB_Pixel,\n custom_Adwords_Remarketing,\n custom_Line_TagId,\n send_page_view,\n customGA4MeasurementId,\n openInApp\n });\n}\n\nexport function gtmPushPrize({ prizeName, prizeType, loginId, promoId }) {\n pushDataLayer(\n filterUndefinedOrNull({\n event: 'fever_prize',\n prizeName,\n prizeType,\n promoId,\n loginId\n })\n );\n}\n\nexport function gtmPushUserLogin({ uid, loginType = '', promoId }) {\n pushDataLayer(\n filterUndefinedOrNull({\n event: 'fever_login',\n loginType,\n loginId: uid,\n promoId\n })\n );\n}\n\nexport function gtmPushSignUpFormSubmit({ loginId, entryUuid, formId, promoId, sponsorId }) {\n pushDataLayer(\n filterUndefinedOrNull({\n event: 'fever_form_submit',\n entryUuid,\n formId,\n promoId,\n sponsorId,\n loginId\n })\n );\n}\n\nexport function gtmPushUserPromoEnter({ loginId, entryUuid, promoId, sponsorId, gameType }) {\n pushDataLayer(\n filterUndefinedOrNull({\n event: 'fever_engage_complete',\n entryUuid,\n promoId,\n sponsorId,\n gameType: getGameTypeModuleName(gameType),\n loginId\n })\n );\n}\n\nexport function gtmPushUserVote({ loginId, entryUuid, mediaId, promoId, sponsorId }) {\n pushDataLayer(\n filterUndefinedOrNull({\n event: 'fever_contest_vote',\n entryUuid,\n mediaId, //(投票作品的id)\n promoId,\n sponsorId,\n loginId\n })\n );\n}\n\nexport function gtmPushUserOpenAppInWebView({ webViewEventName }) {\n pushDataLayer({\n event: 'fever_open_app',\n webViewEventName\n });\n}\n\nexport function gtmPushPromoPublish({\n promoId,\n promoUuId,\n sponsorId,\n gameType,\n uniqueName,\n site,\n promoStartDate,\n promoEndDate,\n promoTitle\n}) {\n pushDataLayer({\n event: 'promoPublish',\n promoId,\n promoUuId,\n sponsorId,\n gameType: getGameTypeModuleName(gameType),\n uniqueName,\n site,\n promoStartDate,\n promoEndDate,\n promoTitle\n });\n}\n\nexport function gtmPushPagePublish({ pageId, sponsorId, uniqueName, site, pageTitle }) {\n pushDataLayer({\n event: 'pagePublish',\n pageId,\n sponsorId,\n uniqueName,\n site,\n pageTitle\n });\n}\n\nexport function gtmPushPrizeResponseFormSubmit({ entryUuid, formId, promoId, sponsorId }) {\n pushDataLayer({\n event: 'fever_winnerform_submit',\n entryUuid,\n formId,\n promoId,\n sponsorId\n });\n}\n\n// https://developers.facebook.com/docs/marketing-api/conversions-api/parameters/fbp-and-fbc?locale=en_US\n// 2. Format ClickID\nexport function generateFbcByFbclid(fbclid) {\n const version = 'fb';\n const subdomainIndex = getSubdomainIndex(window.location.href);\n const creationTime = Date.now();\n return subdomainIndex ? `${version}.${subdomainIndex}.${creationTime}.${fbclid}` : null;\n}\n","// 背景 + 文字 有兩種類型 (1: 自訂背景 / 2: 預設背景)\nexport const froalaKeyVisionTypeMapping = {\n IMAGE: 1,\n COLOR: 2\n};\n\nexport const coverImg = {\n default: 'https://assets.fevercdn.com/promotion/img/ugc_image/Cover1.svg',\n cover_one: 'https://assets.fevercdn.com/promotion/img/key_vision/cover_background_01.png',\n cover_two: 'https://assets.fevercdn.com/promotion/img/key_vision/cover_background_02.png',\n cover_ugc: 'https://assets.fevercdn.com/promotion/img/ugc_image/UGC_Cover.jpg'\n};\n\n// 主視覺尺寸比例\n\n/**\n * 網頁背景:2880 x 1620 (px)、590 x 1280 (px)\n * 點數兌獎、UGC 作品集、多元發票登錄、個人點數歷程頁: 2880 x 600 (px)、590 x 250 (px)\n * 邀請好友任務、新客加入獎勵:2880 x 1200 (px)、590 x 400 (px)\n */\nexport const ratio = {\n background: {\n mobile: {\n width: 590,\n height: 1280\n },\n desktop: {\n width: 2880,\n height: 1620\n }\n },\n ugc: {\n mobile: {\n width: 590,\n height: 250\n },\n desktop: {\n width: 2880,\n height: 600\n }\n },\n promo: {\n mobile: {\n width: 590,\n height: 400\n },\n desktop: {\n width: 2880,\n height: 1200\n }\n }\n};\n","export const reducePointModes = {\n KK_BOX: 'kkbox',\n GENERAL: 'general',\n POINT_SYSTEMS: 'pointSystems'\n};\n\nexport const enterprisePointInputModes = {\n NUMBER: 'number',\n CUSTOM_CODE: 'customCode'\n};\n","export const FORM_BLANK = 1;\nexport const FORM_PSYCHO_QUIZ = 2;\nexport const SIGNUP_FORM = 3;\nexport const REDEEM_FORM = 4;\nexport const FORM_QUIZ = 5;\nexport const FORM_SURVEY = 6;\nexport const FORM_LOTTERY_GAME = 7;\nexport const FORM_INVOICE = 8;\nexport const FORM_VOTE = 9;\n","import _merge from 'lodash/merge';\n\nimport { planKeys } from 'config/planKeys';\n\n/* 大部分直接使用 plan key value\n * 其他常數的 key 值 則是前端自用的(大多依賴 partner / sponsor 的設定做判斷)\n */\nexport const functionKeys = _merge({}, planKeys, {\n loginQualify: {\n line: { ADD_FRIEND: 'LINE_ADD_FRIEND', BIND_MEMBER_ACCOUNT: 'LINE_BIND_MEMBER_ACCOUNT' },\n CYBERBIZ_EC_MEMBER: 'CYBERBIZ_EC_MEMBER',\n NEW_REGISTER_MEMBER: 'NEW_REGISTER_MEMBER',\n APP_LOGIN: 'APP_LOGIN'\n },\n qualify: {\n nameList: {\n API: 'QUALIFY_NAME_LIST_API'\n },\n MEMBER_ORDER: 'QUALIFY_MEMBER_ORDER'\n },\n point: {\n REDUCE_POINT: 'QUALIFY_REDUCE_POINT'\n },\n prizeTypes: {\n CASH_VOUCHER: 'CASH_VOUCHER',\n POINT: 'POINT',\n PROMO_POINT: 'PROMO_POINT', // 活動點數 (動態 & 固定)\n PRIZE_CODE: 'PRIZE_CODE',\n CYBERBIZ_COUPON: 'CYBERBIZ_COUPON',\n SHOPLINE_COUPON_CODE: 'SHOPLINE_COUPON_CODE'\n }\n});\n\nexport const partnerDisplayKeys = {\n DISPLAY_LOGIN: 'displayLoginType',\n DISPLAY_PLAY_TIMES: 'displayPlayTimes',\n DISPLAY_LOTTERIES: 'displayLotteries'\n};\n\nexport const functionKeysMappingDisplayType = [\n [functionKeys.login, partnerDisplayKeys.DISPLAY_LOGIN],\n [functionKeys.lotteries, partnerDisplayKeys.DISPLAY_LOTTERIES],\n [functionKeys.entries, partnerDisplayKeys.DISPLAY_PLAY_TIMES]\n].reduce((obj, [settingKeysGroup, displayKey]) => {\n Object.entries(settingKeysGroup).forEach(([, val]) => (obj[val] = displayKey));\n return obj;\n}, {});\n\n// 此 value 跟 promo setting 的 redeemPointType 的 value 一樣,負責控制現在是會員點數(一般會員點數/kk point) or 活動點數 被綁定\nexport const bindingPointPoolKeys = {\n PROMO_POINT: 'PromotionPoint',\n MEMBER_POINT: 'MemberPoint',\n KK_POINT: 'kkPoint'\n};\n","import i18n from 'i18next';\n\nexport const errorTypes = {\n // 找不到 passcode\n ERROR: 'error',\n // passcode 已經被別人使用過,不可再使用\n DUPLICATE: 'duplicate',\n // 這個 entry 需要 passcode 才能加加活動,但是沒有提供\n ENTRY_NEED_PASSCODE: 'entry-need-passcode',\n // 這個 passcode 參家活動的剩餘次數已經用完了\n USAGE_LIMIT_EXCEEDED: 'usage-limit-exceeded',\n // reCaptcha 驗證失敗\n RECAPTCHA_TOK_AUTH_FAILED: 'reCaptcha-token-authorize-failed'\n};\n\n// 1 : 不重複序號, 2 : 單一序號, 3 : 自行上傳, 4 : 即時不重複序號, 5 : 門市人員產生的通關序號\nexport const passcodeTypes = {\n UNIQUE_CODE: 1,\n SINGLE_CODE: 2,\n UPLOAD_CODE: 3,\n REALTIME_UNIQUE_CODE: 4,\n ONSITE_ASSISTANT_CODE: 5\n};\n\nexport function getPasscodeErrorType(resp = {}) {\n const { httpStatus, payload } = resp;\n const code = String(payload.code).toLowerCase();\n\n switch (true) {\n // check entry and passcode status\n case httpStatus === 403 && code === 'epc-v0-ff1':\n return errorTypes.ENTRY_NEED_PASSCODE;\n // set game result and need passcode\n case httpStatus === 400 && code === 'epc-v0-ff1':\n return errorTypes.ENTRY_NEED_PASSCODE;\n // Verify passcode and passcode used to limit\n case httpStatus === 400 && code === 'pc-r1-f0':\n return errorTypes.USAGE_LIMIT_EXCEEDED;\n // Verify passcode and passcode not found\n case httpStatus === 400 && code === 'pc-r1-fnf1':\n return errorTypes.ERROR;\n // Submit passcode and different member (passcode was used)\n case httpStatus === 400 && code === 'ent-r1-ff1':\n return errorTypes.DUPLICATE;\n case httpStatus === 400 && payload?.message === 'reCaptcha token authorize failed - empty':\n case httpStatus === 400 && payload?.message === 'reCaptcha token authorize failed':\n return errorTypes.RECAPTCHA_TOK_AUTH_FAILED;\n // TODO: 400 待確認\n case httpStatus === 400 && payload?.message === 'already have entry flow':\n case httpStatus === 400 && payload?.message === 'passcode not available':\n case httpStatus === 400 && payload?.message === 'no entry':\n default:\n return errorTypes.ERROR;\n }\n}\n\nexport function getErrorTypeMessage(type) {\n switch (type) {\n case errorTypes.DUPLICATE:\n case errorTypes.USAGE_LIMIT_EXCEEDED:\n return i18n.t('label.passcode.verify.validate.duplicate');\n case errorTypes.ERROR:\n default:\n return i18n.t('label.passcode.verify.validate.error');\n }\n}\n\nexport function getErrorTypeDialogDesc(type) {\n switch (type) {\n case errorTypes.DUPLICATE:\n return i18n.t('label.passcode.duplicate');\n case errorTypes.USAGE_LIMIT_EXCEEDED:\n return i18n.t('label.passcode.reach_limit');\n case errorTypes.ERROR:\n default:\n return i18n.t('label.passcode.invalid');\n }\n}\n","export const planKeys = {\n modules: {\n PSYCHO_QUIZ: 'promotionPsychologicalTest',\n SIGN_FORM: 'promotionRegistration',\n QUIZ: 'promotionQuiz',\n SURVEY: 'promotionSurvey',\n WIN_WHEEL: 'promotionRoulette',\n VOTE: 'promotionIssueVote',\n POKE_GAME: 'promotionPoke',\n SCRATCH_CARD: 'promotionScratchCard',\n INVOICE: 'promotionInvoiceTW',\n RED_ENVELOPE_RAIN: 'promotionRedEnvelope',\n PHOTO_UPLOAD: 'promotionImageUpload',\n CHECK_IN: 'promotionCheckIn',\n CONTEST_PHOTO_UPLOAD: 'promotionPhotoContest',\n PHOTO_FRAME_COMPOSITE: 'promotionCreativeFrame',\n SLOTS: 'promotionSlot',\n PICK_THE_PRIZE: 'promotionPickThePrize',\n MEMORY_MATCH: 'promotionMemoryMatch',\n COMMENT: 'promotionComment',\n CONTEST_ADMIN_UPLOAD: 'promotionVotingContest',\n CONTEST_PHOTO_FRAME_COMPOSITE: 'promotionFramedPhotoContest',\n CHALLENGE_PHOTO_FRAME_COMPOSITE: 'promotionPhotoChallenge',\n VIDEO_UPLOAD: 'promotionVideoUpload',\n CONTEST_VIDEO_UPLOAD: 'promotionVideoContest',\n PURCHASE_REWARD: 'promotionPurchaseReward',\n POINTS_REDEEM: 'promotionPointsRedeem',\n MGM_SHARE: 'promotionMGMShare',\n SIGN_UP: 'promotionSignUp',\n MULTI_CHALLENGE: 'promotionMultiChallenge',\n ORDER_REWARD: 'promotionOrderReward',\n CART_REWARD: 'promotionCartReward'\n },\n lotteries: {\n JOIN_AND_GET: 'lotteryParticipant',\n SCRATCH_CARD: 'lotteryScratchCard',\n WIN_WHEEL: 'lotteryRoulette',\n POKE_GAME: 'lotteryPoke',\n RED_ENVELOPE_RAIN: 'lotteryRedEnvelope',\n SLOTS: 'lotterySlot',\n PICK_THE_PRIZE: 'lotteryPickThePrize',\n ADMIN: 'lotteryAdmin',\n POINTS_REDEEM: 'lotteryPointsRedeem'\n },\n login: {\n ANONYMOUS: 'anonymousLogin',\n FACEBOOK: 'facebookLogin',\n LINE: 'lineLogin',\n ENTERPRISE: 'enterpriseLogin'\n },\n qualify: {\n LIMITATION: 'entryRules'\n },\n entries: {\n DAILY_PLAY_TIMES: 'dailyPlayTimes',\n TOTAL_PLAY_TIMES: 'totalPlayTimes',\n PERIOD_PLAY_MODE: 'periodPlayMode'\n },\n prizes: {\n PRIZE_VIRTUAL_NUMBER: 'prizeVirtualNumber'\n },\n form: {\n FORM_REDIRECT: 'formRedirect',\n SIGNUP_FORM_LIMIT: 'formSignUp'\n },\n tags: {\n TAGGED_BY_PROMO: 'taggedByPromotion'\n },\n webhook: {\n API_WEBHOOK: 'apiWebhook'\n }\n};\n\nexport const planTypes = {\n PROMO_PLAN: 1,\n POINT_PLAN: 2\n};\n","// 透過 post message API 傳遞的事件名稱\nexport const HEIGHT_RESIZE = '@feverevent/height-resize'; // 通知 zine 的 iframe 高度變更,需要隨著 promo 高度調整 iframe 高度\nexport const SCROLL_INTO_VIEW = '@feverevent/scroll-into-view';\nexport const PARENT_REDIRECT = '@feverevent/parent-redirect';\nexport const PARENT_POPUP = '@feverevent/open-popup';\nexport const IS_ZINES_EMBEDDED = '@feverevent/is-zines-embedded';\nexport const IS_WIDGET_EMBEDDED = '@feverevent/is-widget-embedded';\n","import i18n from 'i18next';\n\nimport { planKeys } from 'config/planKeys';\nimport {\n FORM_PSYCHO_QUIZ,\n FORM_QUIZ,\n FORM_SURVEY,\n FORM_LOTTERY_GAME,\n FORM_VOTE,\n FORM_INVOICE\n} from 'config/formTypes';\nimport * as lotteryTypes from 'config/promoLotteryTypes';\n\n/**\n * Game 類型\n *\n * - 2: 心理測驗 (formbased)\n * - 7: 登錄給獎 (空 formbased)\n * - 5: 問答小學堂 (formbased)\n * - 6: 問卷調查 (formbased)\n * - 8: 大輪盤 (空 formbased + 純獎)\n * - 9: 議題投票 (formbased)\n * - 10: 戳戳樂 (空 formbased + 純獎)\n * - 11: 刮刮卡 (空 formbased + 純獎)\n * - 12: 發票 (formbased)\n * - 13: 紅包雨 (空 formbased + 純獎)\n * - 14: 圖片上傳 (ugc)\n * - 15: 簽到模組\n * - 16: 徵圖比賽 (投票 + ugc 14)\n * - 17: 創意相框 (ugc)\n * - 18: 拉霸 (空 formbased + 純獎)\n * - 19: 自由選\n * - 20: 翻牌遊戲\n * - 21: 留言模組 (ugc)\n * - 22: 票選比賽 (投票 + admin 上稿 ugc 14 / ugc 25)\n * - 23: 圖片闖關\n * - 24: 相框合成比賽 (投票 + ugc 17)\n * - 25: 影片上傳 (ugc)\n * - 26: 徵片比賽 (投票 + ugc 25)\n * - 27: IG 模組\n * - 28: 發票 v4.0\n * - 32: 點數兌獎\n * - 33: 邀請好友任務\n * - 35: 新客加入獎勵\n * - 36: 多元任務模組\n * - 37: 訂單模組\n * - 38: 購物車模組\n */\nexport const gameTypes = {\n PSYCHO_QUIZ: 2,\n SIGN_FORM: 7,\n QUIZ: 5,\n SURVEY: 6,\n WIN_WHEEL: 8,\n VOTE: 9,\n POKE_GAME: 10,\n SCRATCH_CARD: 11,\n INVOICE: 12,\n RED_ENVELOPE_RAIN: 13,\n PHOTO_UPLOAD: 14,\n CHECK_IN: 15,\n CONTEST_PHOTO_UPLOAD: 16,\n PHOTO_FRAME_COMPOSITE: 17,\n SLOTS: 18,\n PICK_THE_PRIZE: 19,\n MEMORY_MATCH: 20,\n COMMENT: 21,\n CONTEST_ADMIN_UPLOAD: 22,\n CHALLENGE_PHOTO_FRAME_COMPOSITE: 23,\n CONTEST_PHOTO_FRAME_COMPOSITE: 24,\n VIDEO_UPLOAD: 25,\n CONTEST_VIDEO_UPLOAD: 26,\n INSTAGRAM: 27,\n PURCHASE_REWARD: 28,\n POINTS_REDEEM: 32,\n MGM_SHARE: 33,\n MGM_REFERRAL: 34,\n SIGN_UP: 35,\n MULTI_CHALLENGE: 36,\n ORDER_REWARD: 37,\n CART_REWARD: 38\n};\n\nexport const pureGameTypeMappingLotteryType = {\n [gameTypes.SCRATCH_CARD]: lotteryTypes.SCRATCH_CARD,\n [gameTypes.WIN_WHEEL]: lotteryTypes.WIN_WHEEL,\n [gameTypes.POKE_GAME]: lotteryTypes.POKE_GAME,\n [gameTypes.RED_ENVELOPE_RAIN]: lotteryTypes.RED_ENVELOPE_RAIN,\n [gameTypes.SLOTS]: lotteryTypes.SLOTS,\n [gameTypes.PICK_THE_PRIZE]: lotteryTypes.PICK_THE_PRIZE,\n [gameTypes.POINTS_REDEEM]: lotteryTypes.POINTS_REDEEM\n};\n\nexport const gamesConfig = {\n PSYCHO_QUIZ: {\n type: gameTypes.PSYCHO_QUIZ,\n planKey: planKeys.modules.PSYCHO_QUIZ,\n formBasedType: FORM_PSYCHO_QUIZ,\n i18nNameKey: 'label.game_type_psycho_quiz',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_psychological_test.png',\n descriptionText: 'label.psycho_quiz.description_text',\n moduleNameForWebhook: 'personalityQuiz'\n },\n SIGN_FORM: {\n type: gameTypes.SIGN_FORM,\n planKey: planKeys.modules.SIGN_FORM,\n formBasedType: FORM_LOTTERY_GAME,\n i18nNameKey: 'label.game_type_signup_form',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_sign_form.png',\n descriptionText: 'label.sign_form.description_text',\n moduleNameForWebhook: 'enterToWin'\n },\n QUIZ: {\n type: gameTypes.QUIZ,\n planKey: planKeys.modules.QUIZ,\n formBasedType: FORM_QUIZ,\n i18nNameKey: 'label.game_type_quiz',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_quiz.png',\n descriptionText: 'label.quiz.description_text',\n moduleNameForWebhook: 'qaQuiz'\n },\n SURVEY: {\n type: gameTypes.SURVEY,\n planKey: planKeys.modules.SURVEY,\n formBasedType: FORM_SURVEY,\n i18nNameKey: 'label.game_type_survey',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_survey.png',\n descriptionText: 'label.survey.description_text',\n moduleNameForWebhook: 'survey'\n },\n WIN_WHEEL: {\n type: gameTypes.WIN_WHEEL,\n planKey: planKeys.modules.WIN_WHEEL,\n formBasedType: FORM_LOTTERY_GAME,\n purePrizeGameLotteryType: lotteryTypes.WIN_WHEEL,\n i18nNameKey: 'label.game_type_winwheel',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_winwheel.png',\n descriptionText: 'label.win_wheel.description_text',\n moduleNameForWebhook: 'luckyWheel',\n isPurePrizeGame: true\n },\n VOTE: {\n type: gameTypes.VOTE,\n planKey: planKeys.modules.VOTE,\n formBasedType: FORM_VOTE,\n i18nNameKey: 'label.game_type_vote',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_vote.png',\n descriptionText: 'label.vote.description_text',\n moduleNameForWebhook: 'poll'\n },\n POKE_GAME: {\n type: gameTypes.POKE_GAME,\n planKey: planKeys.modules.POKE_GAME,\n formBasedType: FORM_LOTTERY_GAME,\n purePrizeGameLotteryType: lotteryTypes.POKE_GAME,\n i18nNameKey: 'label.game_type_poke_game',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_poke_game.png',\n descriptionText: 'label.poke_game.description_text',\n moduleNameForWebhook: 'pokeAPrize',\n isPurePrizeGame: true\n },\n SCRATCH_CARD: {\n type: gameTypes.SCRATCH_CARD,\n planKey: planKeys.modules.SCRATCH_CARD,\n formBasedType: FORM_LOTTERY_GAME,\n purePrizeGameLotteryType: lotteryTypes.POKE_GAME,\n i18nNameKey: 'label.game_type_scratch_card',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_scratch_card.png',\n descriptionText: 'label.scratch_card.description_text',\n moduleNameForWebhook: 'scratchCards',\n isPurePrizeGame: true\n },\n INVOICE: {\n type: gameTypes.INVOICE,\n planKey: planKeys.modules.INVOICE,\n formBasedType: FORM_INVOICE,\n i18nNameKey: 'label.game_type_invoice',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_invoice.png',\n descriptionText: 'label.invoice.description_text',\n moduleNameForWebhook: 'purchaseToWin'\n },\n RED_ENVELOPE_RAIN: {\n type: gameTypes.RED_ENVELOPE_RAIN,\n planKey: planKeys.modules.RED_ENVELOPE_RAIN,\n formBasedType: FORM_LOTTERY_GAME,\n purePrizeGameLotteryType: lotteryTypes.RED_ENVELOPE_RAIN,\n i18nNameKey: 'label.red_envelope_rain',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_red_envelope_rain.png',\n descriptionText: 'label.red_envelope_rain.description_text',\n moduleNameForWebhook: 'prizeShower',\n isPurePrizeGame: true\n },\n PHOTO_UPLOAD: {\n type: gameTypes.PHOTO_UPLOAD,\n planKey: planKeys.modules.PHOTO_UPLOAD,\n i18nNameKey: 'label.game_type_photo_upload',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_photo_upload.png',\n descriptionText: 'label.photo_upload.description_text',\n moduleNameForWebhook: 'photoUpload',\n isUgcGame: true,\n canLinkWithContestModule: true\n },\n CHECK_IN: {\n type: gameTypes.CHECK_IN,\n planKey: planKeys.modules.CHECK_IN,\n i18nNameKey: 'label.game_type_check_in',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_check_in.png',\n descriptionText: 'label.check_in.description_text',\n moduleNameForWebhook: 'checkIn'\n },\n CONTEST_PHOTO_UPLOAD: {\n type: gameTypes.CONTEST_PHOTO_UPLOAD,\n planKey: planKeys.modules.CONTEST_PHOTO_UPLOAD,\n i18nNameKey: 'label.game_type_photo_contest',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_photo_contest.png',\n descriptionText: 'label.contest_photo_upload.description_text',\n moduleNameForWebhook: 'photoContest',\n hasUgcFlow: true,\n ugcLinkKeys: [planKeys.modules.PHOTO_UPLOAD]\n },\n PHOTO_FRAME_COMPOSITE: {\n type: gameTypes.PHOTO_FRAME_COMPOSITE,\n planKey: planKeys.modules.PHOTO_FRAME_COMPOSITE,\n i18nNameKey: 'label.game_type_photo_frame_composite',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_photo_composite.png',\n descriptionText: 'label.photo_frame_composite.description_text',\n moduleNameForWebhook: 'creativeFrame',\n hasRelatedPromoOptions: true,\n isUgcGame: true,\n canLinkWithContestModule: true\n },\n SLOTS: {\n type: gameTypes.SLOTS,\n planKey: planKeys.modules.SLOTS,\n formBasedType: FORM_LOTTERY_GAME,\n purePrizeGameLotteryType: lotteryTypes.SLOTS,\n i18nNameKey: 'label.slots',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_slots.png',\n descriptionText: 'label.slots.description_text',\n moduleNameForWebhook: 'slot',\n isPurePrizeGame: true\n },\n PICK_THE_PRIZE: {\n type: gameTypes.PICK_THE_PRIZE,\n planKey: planKeys.modules.PICK_THE_PRIZE,\n formBasedType: FORM_LOTTERY_GAME,\n purePrizeGameLotteryType: lotteryTypes.PICK_THE_PRIZE,\n i18nNameKey: 'label.game_type_pick_the_prize',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_choose.png',\n descriptionText: 'label.pick_the_prize.description_text',\n moduleNameForWebhook: 'pickThePrize',\n isPurePrizeGame: true\n },\n MEMORY_MATCH: {\n type: gameTypes.MEMORY_MATCH,\n planKey: planKeys.modules.MEMORY_MATCH,\n i18nNameKey: 'label.memoryMatch',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_memory_match.png',\n descriptionText: 'label.memory_match.description_text',\n moduleNameForWebhook: 'memoryMatch',\n hasRelatedPromoOptions: true\n },\n COMMENT: {\n type: gameTypes.COMMENT,\n planKey: planKeys.modules.COMMENT,\n i18nNameKey: 'label.game_type_comment',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_comment.png',\n descriptionText: 'label.comment.description_text',\n moduleNameForWebhook: 'comment',\n hasRelatedPromoOptions: true,\n isUgcGame: true\n },\n CONTEST_ADMIN_UPLOAD: {\n type: gameTypes.CONTEST_ADMIN_UPLOAD,\n planKey: planKeys.modules.CONTEST_ADMIN_UPLOAD,\n i18nNameKey: 'label.game_type_voting_contest',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_voting_contest.png',\n descriptionText: 'label.contest_admin_upload.description_text',\n moduleNameForWebhook: 'votingContest',\n hasUgcFlow: false,\n ugcLinkKeys: [planKeys.modules.PHOTO_UPLOAD, planKeys.modules.VIDEO_UPLOAD]\n },\n CONTEST_PHOTO_FRAME_COMPOSITE: {\n type: gameTypes.CONTEST_PHOTO_FRAME_COMPOSITE,\n planKey: planKeys.modules.CONTEST_PHOTO_FRAME_COMPOSITE,\n i18nNameKey: 'label.game_type_frame_composite_contest',\n imageSrc:\n 'https://assets.fevercdn.com/nc-admin/images/promo_module_frame_composite_contest.png',\n descriptionText: 'label.contest_photo_frame_composite.description_text',\n moduleNameForWebhook: 'framedPhotoContest',\n hasUgcFlow: true,\n ugcLinkKeys: [planKeys.modules.PHOTO_FRAME_COMPOSITE]\n },\n CHALLENGE_PHOTO_FRAME_COMPOSITE: {\n type: gameTypes.CHALLENGE_PHOTO_FRAME_COMPOSITE,\n planKey: planKeys.modules.CHALLENGE_PHOTO_FRAME_COMPOSITE,\n i18nNameKey: 'label.game_type_challenge_photo_frame_composite',\n imageSrc:\n 'https://assets.fevercdn.com/nc-admin/images/promo_module_challenge_photo_composite.png',\n descriptionText: 'label.challenge_photo_frame_composite.description_text',\n moduleNameForWebhook: 'photoChallenge',\n hasRelatedPromoOptions: true,\n hasRelatedPromoTask: true,\n isUgcGame: true\n },\n VIDEO_UPLOAD: {\n type: gameTypes.VIDEO_UPLOAD,\n planKey: planKeys.modules.VIDEO_UPLOAD,\n i18nNameKey: 'label.game_type_video_upload',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_video_upload.png',\n descriptionText: 'label.video_upload.description_text',\n moduleNameForWebhook: 'videoUpload',\n isUgcGame: true,\n canLinkWithContestModule: true\n },\n CONTEST_VIDEO_UPLOAD: {\n type: gameTypes.CONTEST_VIDEO_UPLOAD,\n planKey: planKeys.modules.CONTEST_VIDEO_UPLOAD,\n i18nNameKey: 'label.game_type_video_contest',\n imageSrc:\n 'https://assets.fevercdn.com/nc-admin/images/promo_module_contest_video_upload.png',\n descriptionText: 'label.contest_video_upload.description_text',\n moduleNameForWebhook: 'videoContest',\n hasUgcFlow: true,\n ugcLinkKeys: [planKeys.modules.VIDEO_UPLOAD]\n },\n INSTAGRAM: {\n type: gameTypes.INSTAGRAM,\n planKey: 'promotionInstagram',\n i18nNameKey: 'label.game_type_instagram',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_instagram_module.png',\n descriptionText: 'label.instagram.description_text',\n moduleNameForWebhook: 'instagram',\n isUgcGame: true\n },\n PURCHASE_REWARD: {\n type: gameTypes.PURCHASE_REWARD,\n planKey: planKeys.modules.PURCHASE_REWARD,\n hasRelatedPromoOptions: true,\n i18nNameKey: 'label.game_type_purchase_reward',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_invoice.png',\n descriptionText: 'label.purchase_reward.description_text',\n moduleNameForWebhook: 'purchaseReward'\n },\n POINTS_REDEEM: {\n type: gameTypes.POINTS_REDEEM,\n planKey: planKeys.modules.POINTS_REDEEM,\n i18nNameKey: 'label.game_type_points_redeem',\n purePrizeGameLotteryType: lotteryTypes.POINTS_REDEEM,\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_points_redeem.svg',\n descriptionText: 'label.points_redeem.description_text',\n moduleNameForWebhook: 'pointsRedeem',\n isPurePrizeGame: true\n },\n MGM_SHARE: {\n type: gameTypes.MGM_SHARE,\n planKey: planKeys.modules.MGM_SHARE,\n i18nNameKey: 'label.game_type_mgm_share',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_refer_a_friend.svg',\n descriptionText: 'label.mgm_share.description_text',\n moduleNameForWebhook: 'mgmShare'\n },\n SIGN_UP: {\n type: gameTypes.SIGN_UP,\n planKey: planKeys.modules.SIGN_UP,\n i18nNameKey: 'label.game_type_sign_up',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_sign_up_reward.svg',\n descriptionText: 'label.sign_up.description_text',\n moduleNameForWebhook: 'signUp'\n },\n MULTI_CHALLENGE: {\n type: gameTypes.MULTI_CHALLENGE,\n planKey: planKeys.modules.MULTI_CHALLENGE,\n i18nNameKey: 'label.game_type_multi_challenge',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_sign_up_reward.svg',\n descriptionText: 'label.multi_challenge.description_text',\n hasRelatedPromoTask: true,\n moduleNameForWebhook: 'multiChallenge'\n },\n ORDER_REWARD: {\n type: gameTypes.ORDER_REWARD,\n planKey: planKeys.modules.ORDER_REWARD,\n hasRelatedPromoOptions: true,\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_order_reward.png',\n descriptionText: 'label.order_reward.description_text',\n i18nNameKey: 'label.game_type_order_reward',\n moduleNameForWebhook: 'orderReward'\n },\n CART_REWARD: {\n type: gameTypes.CART_REWARD,\n planKey: planKeys.modules.CART_REWARD,\n hasRelatedPromoOptions: true,\n i18nNameKey: 'label.game_type_cart_reward',\n imageSrc: 'https://assets.fevercdn.com/nc-admin/images/promo_module_cart_reward.png',\n descriptionText: 'label.cart_reward.description_text',\n moduleNameForWebhook: 'addToCart'\n }\n};\n\nconst gameTypeImageSrc = Object.entries(gamesConfig).reduce((obj, [, { type, imageSrc }]) => {\n obj[type] = imageSrc;\n return obj;\n}, {});\n\nexport function getGameTypeImageSrc(gameType) {\n const imageSrc = gameTypeImageSrc[gameType];\n return Boolean(imageSrc) ? imageSrc : '';\n}\n\nconst gameTypeNames = Object.entries(gamesConfig).reduce((obj, [, { type, i18nNameKey }]) => {\n obj[type] = i18nNameKey;\n return obj;\n}, {});\n\nexport function getGameTypeLabel(gameType, t = (...args) => i18n.t(...args)) {\n const i18nKey = gameTypeNames[gameType];\n return Boolean(i18nKey) ? t(i18nKey) : '';\n}\n\nconst gameTypeModuleNames = Object.entries(gamesConfig).reduce(\n (obj, [, { type, moduleNameForWebhook }]) => {\n obj[type] = moduleNameForWebhook;\n return obj;\n },\n {}\n);\nexport function getGameTypeModuleName(gameType) {\n const moduleNameForWebhook = gameTypeModuleNames[gameType];\n return Boolean(moduleNameForWebhook) ? moduleNameForWebhook : '';\n}\n\nconst formbasedGames = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, formBasedType }]) => (formBasedType !== undefined ? type : undefined))\n .filter(t => t !== undefined)\n]);\nexport function isFormBasedGame(gameType) {\n return formbasedGames.has(gameType);\n}\n\nconst purePrizeGames = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, isPurePrizeGame }]) => (isPurePrizeGame ? type : undefined))\n .filter(t => t !== undefined)\n]);\nexport function isPurePrizeGames(gameType) {\n return purePrizeGames.has(gameType);\n}\n\nconst ugcGames = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, isUgcGame }]) => (isUgcGame ? type : undefined))\n .filter(t => t !== undefined)\n]);\nexport function isUgcGames(gameType) {\n return ugcGames.has(gameType);\n}\n\nconst hasPromoTaskGames = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, hasRelatedPromoTask }]) => (hasRelatedPromoTask ? type : undefined))\n .filter(t => t !== undefined)\n]);\nexport function checkIsGameHasPromoTask(gameType) {\n return hasPromoTaskGames.has(gameType);\n}\n\nconst hasPromoOptionGames = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, hasRelatedPromoOptions }]) => (hasRelatedPromoOptions ? type : undefined))\n .filter(t => t !== undefined)\n]);\nexport function checkIsGameHasPromoOptions(gameType) {\n return hasPromoOptionGames.has(gameType);\n}\n\nexport const contestGamesForUserPlayableUgc = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, ugcLinkKeys, hasUgcFlow }]) =>\n Array.isArray(ugcLinkKeys) && hasUgcFlow ? type : undefined\n )\n .filter(t => t !== undefined)\n]);\nexport function isContestGamesForUserPlayableUgc(gameType) {\n return contestGamesForUserPlayableUgc.has(gameType);\n}\n\nconst contestGamesWithSecondaryUgc = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, ugcLinkKeys }]) => (Array.isArray(ugcLinkKeys) ? type : undefined))\n .filter(t => t !== undefined)\n]);\nexport function isContestGamesWithSecondaryUgc(gameType) {\n return isContestGamesForUserPlayableUgc(gameType) || contestGamesWithSecondaryUgc.has(gameType);\n}\n\nexport const ugcGamesCanLinkWithContestModule = new Set([\n ...Object.entries(gamesConfig)\n .map(([, { type, canLinkWithContestModule }]) =>\n canLinkWithContestModule ? type : undefined\n )\n .filter(t => t !== undefined)\n]);\n\n// 模組可進入作品集、作品頁頁面\nexport function isUgcGameAndHasUgcMediaFlow(gameType) {\n return gameType !== gameTypes.COMMENT && isUgcGames(gameType);\n}\n\n//特殊需求模組列表(純獎模組 & 問券模組外 要使用960px的寬度)\nconst smallPromoWidthGames = new Set([gameTypes.SURVEY]);\nexport function isSmallPromoWidth(gameType) {\n return isPurePrizeGames(gameType) || smallPromoWidthGames.has(gameType);\n}\n\n// 比賽搭配 ugc 雙模組的情況下,promo settings 裡會用該 key 存放關聯的 ugc 的 promoUUID\nconst ugcLinkedKeysInContestModule = Object.entries(gamesConfig).reduce(\n (obj, [moduleKey, { canLinkWithContestModule, planKey }]) => {\n if (canLinkWithContestModule) {\n obj[moduleKey] = planKey;\n }\n return obj;\n },\n {}\n);\nexport const ugcLinkedKeysInContestModuleSet = new Set([\n ...Object.values(ugcLinkedKeysInContestModule)\n]);\n\nconst contestModuleMappingUsableUgcLinkKeys = Object.entries(gamesConfig).reduce(\n (obj, [, { type, ugcLinkKeys }]) => {\n if (Array.isArray(ugcLinkKeys)) {\n obj[type] = ugcLinkKeys;\n }\n return obj;\n },\n {}\n);\nexport function contestGetUgcLinkKey(gameType, settingPromo) {\n const usableUgcLinkKeys = contestModuleMappingUsableUgcLinkKeys[gameType] ?? [];\n const [ugcLinkKey] =\n Object.entries(settingPromo).find(([key]) => usableUgcLinkKeys.includes(key)) ?? [];\n\n return ugcLinkKey;\n}\n\n// 符合獎品相關設定頁籤 - 點數計算規則\nconst pointCountRuleGames = new Set([\n gameTypes.PURCHASE_REWARD,\n gameTypes.ORDER_REWARD,\n gameTypes.CART_REWARD\n]);\nexport function hasPointCountRuleGames(gameType) {\n return pointCountRuleGames.has(gameType);\n}\n\n// 是否要呈現出獎品相關設定頁籤\nexport function hasShowPointRelatedSettingTab(gameType) {\n return hasPointCountRuleGames(gameType);\n}\n\n// 符合獎品類型動態計算 ( 會員點數 )\nconst dynamicPrizeTypeGames = new Set([\n gameTypes.PURCHASE_REWARD,\n gameTypes.ORDER_REWARD,\n gameTypes.CART_REWARD\n]);\nexport function hasShowDynamicCountPrizeType(gameType) {\n return dynamicPrizeTypeGames.has(gameType);\n}\n\n// 跳過 Checker 的登入檢查\nconst passLoginCheckTrigger = new Set([gameTypes.SIGN_UP]);\nexport function hasPassLoginCheckTriggerGame(gameType) {\n return passLoginCheckTrigger.has(gameType);\n}\n\n// 隱藏獎品發完處理方式設定 ( 邀請模組要隱藏,但目前獎品區塊使用 mgm reduxt ,因此透過 MGM_REFERRAL 設定 )\nconst hideSettingPromoWhenNoPrizeGames = new Set([gameTypes.MGM_SHARE, gameTypes.MGM_REFERRAL]);\nexport function hasHideSettingPromoWhenNoPrizeGames(gameType) {\n return hideSettingPromoWhenNoPrizeGames.has(gameType);\n}\n\nexport const promoFormTemplateMapping = Object.entries(gamesConfig).reduce(\n (obj, [, { type, formBasedType }]) => {\n if (formBasedType !== undefined) {\n obj[type] = formBasedType;\n }\n return obj;\n },\n {}\n);\n\nexport const promoLotteryTemplateMapping = Object.entries(gamesConfig).reduce(\n (obj, [, { type, purePrizeGameLotteryType }]) => {\n if (purePrizeGameLotteryType !== undefined) {\n obj[type] = purePrizeGameLotteryType;\n }\n return obj;\n },\n {}\n);\n\n// 不開放標籤設定 [目前僅有 ig]\nconst canNotUseTags = new Set([gameTypes.INSTAGRAM]);\nexport function isCanNotUseTags(gameType) {\n return canNotUseTags.has(gameType);\n}\n\n// 可以設定 Promotion 審核機制模組\nconst canSetVerifyMechanismGames = new Set([\n gameTypes.INVOICE,\n gameTypes.PURCHASE_REWARD,\n gameTypes.SIGN_UP,\n gameTypes.PSYCHO_QUIZ,\n gameTypes.QUIZ,\n gameTypes.SURVEY,\n gameTypes.SIGN_FORM,\n gameTypes.VOTE,\n gameTypes.CHECK_IN,\n gameTypes.MEMORY_MATCH,\n gameTypes.MULTI_CHALLENGE,\n gameTypes.ORDER_REWARD,\n gameTypes.CART_REWARD\n]);\nexport function isCanSetVerifyMechanismGames(gameType) {\n return canSetVerifyMechanismGames.has(gameType) || isUgcGames(gameType);\n}\n\n// 強制開啟 Promotion 審核機制模組\nconst hasForceVerifyMechanismGames = new Set([\n gameTypes.PURCHASE_REWARD,\n gameTypes.SIGN_UP,\n gameTypes.ORDER_REWARD,\n gameTypes.CART_REWARD\n]);\nexport function isForceVerifyMechanismGames(gameType) {\n return hasForceVerifyMechanismGames.has(gameType) || isUgcGames(gameType);\n}\n\n// 流程進行導轉時若發現有 unOpenWinnerPrize ,進行開獎後在導轉\nconst hasAutoTriggerAnimationGames = new Set([gameTypes.PICK_THE_PRIZE, gameTypes.POINTS_REDEEM]);\nexport function isAutoTriggerAnimationGames(gameType) {\n return hasAutoTriggerAnimationGames.has(gameType);\n}\n\n// 可以開啟全對才能獲獎-給獎資格\nconst canSetAllCorrectGetPrizeRuleGames = new Set([gameTypes.MEMORY_MATCH, gameTypes.QUIZ]);\nexport function isCanSetAllCorrectGetPrizeRuleGames(gameType) {\n return canSetAllCorrectGetPrizeRuleGames.has(gameType);\n}\n\n// 需要有會員登入的活動\nconst hasNeedLoginEnterpriseGames = new Set([gameTypes.SIGN_UP]);\nexport function isNeedLoginEnterpriseGames(type) {\n return hasNeedLoginEnterpriseGames.has(type);\n}\n\n// 不可以跟多元任務模組關聯的活動 #86eq8hqf7\nexport const canNotRelateMultiChallengeTaskGames = new Set([\n gameTypes.INVOICE,\n gameTypes.CONTEST_PHOTO_UPLOAD,\n gameTypes.CONTEST_ADMIN_UPLOAD,\n gameTypes.CONTEST_PHOTO_FRAME_COMPOSITE,\n gameTypes.CONTEST_VIDEO_UPLOAD,\n gameTypes.INSTAGRAM,\n gameTypes.MULTI_CHALLENGE,\n gameTypes.SIGN_UP\n]);\n\nexport function isCanRelateMultiChallengeTaskGames(type) {\n return !canNotRelateMultiChallengeTaskGames.has(type);\n}\n\n// gameResultRecords 要確認有沒有 lotteryParticipant 才成立\nconst checkGameResultRecordsHasLotteryParticipant = new Set([gameTypes.POINTS_REDEEM]);\nexport function isCheckGameResultRecordsHasLotteryParticipant(type) {\n return checkGameResultRecordsHasLotteryParticipant.has(type);\n}\n\n// 給獎規則可以顯示開啟鑑賞期後才能使用獎品\nconst canShowUseRevalidationGames = new Set([gameTypes.ORDER_REWARD, gameTypes.PURCHASE_REWARD]);\nexport function isCanShowUseRevalidationGames(type) {\n return canShowUseRevalidationGames.has(type);\n}\n","import { planKeys } from 'config/planKeys';\n\n/**\n * - 0: 後台抽獎\n * - 1: 參加獎\n * - 3: 刮刮卡\n * - 4: 大輪盤\n * - 5: 戳戳樂\n * - 6: 紅包雨\n * - 7: 拉霸\n * - 8: 好禮自由選\n * - 9: 點數兌獎\n */\nexport const ADMIN = 0;\nexport const JOIN_AND_GET = 1;\nexport const SCRATCH_CARD = 3;\nexport const WIN_WHEEL = 4;\nexport const POKE_GAME = 5;\nexport const RED_ENVELOPE_RAIN = 6;\nexport const SLOTS = 7;\nexport const PICK_THE_PRIZE = 8;\nexport const POINTS_REDEEM = 9;\n\n// 泛用的直接 開獎品路徑\nexport const lotteryGeneralAnimationType = Symbol('lotteryGeneralType');\nexport const lotteryOpenPathParams = {\n GENERAL: 'general',\n WIN_WHEEL: 'winwheel',\n SCRATCH_CARD: 'scratchcard',\n POKE_GAME: 'pokeGame',\n RED_ENVELOPE_RAIN: 'redEnvelopeRain',\n SLOTS: 'slots',\n PICK_THE_PRIZE: 'pickThePrize',\n POINTS_REDEEM: 'pointsRedeem'\n};\n\nexport const lotteriesConfig = {\n instant: {\n JOIN_AND_GET: {\n type: JOIN_AND_GET,\n planKey: planKeys.lotteries.JOIN_AND_GET,\n lotteryAnimatePath: lotteryOpenPathParams.GENERAL\n }\n },\n participant: {\n SCRATCH_CARD: {\n type: SCRATCH_CARD,\n planKey: planKeys.lotteries.SCRATCH_CARD,\n lotteryAnimatePath: lotteryOpenPathParams.SCRATCH_CARD\n },\n WIN_WHEEL: {\n type: WIN_WHEEL,\n planKey: planKeys.lotteries.WIN_WHEEL,\n lotteryAnimatePath: lotteryOpenPathParams.WIN_WHEEL\n },\n POKE_GAME: {\n type: POKE_GAME,\n planKey: planKeys.lotteries.POKE_GAME,\n lotteryAnimatePath: lotteryOpenPathParams.POKE_GAME\n },\n RED_ENVELOPE_RAIN: {\n type: RED_ENVELOPE_RAIN,\n planKey: planKeys.lotteries.RED_ENVELOPE_RAIN,\n lotteryAnimatePath: lotteryOpenPathParams.RED_ENVELOPE_RAIN\n },\n SLOTS: {\n type: SLOTS,\n planKey: planKeys.lotteries.SLOTS,\n lotteryAnimatePath: lotteryOpenPathParams.SLOTS\n },\n PICK_THE_PRIZE: {\n type: PICK_THE_PRIZE,\n planKey: planKeys.lotteries.PICK_THE_PRIZE,\n lotteryAnimatePath: lotteryOpenPathParams.PICK_THE_PRIZE\n },\n POINTS_REDEEM: {\n type: POINTS_REDEEM,\n planKey: planKeys.lotteries.POINTS_REDEEM,\n lotteryAnimatePath: lotteryOpenPathParams.POINTS_REDEEM\n }\n },\n admin: {\n ADMIN: {\n type: ADMIN,\n planKey: planKeys.lotteries.ADMIN,\n lotteryAnimatePath: lotteryOpenPathParams.GENERAL\n }\n }\n};\n\n// 給獎動畫對應路徑\nexport const lotteryAnimationPathMapping = Object.entries({\n ...lotteriesConfig.instant,\n ...lotteriesConfig.participant,\n ...lotteriesConfig.admin\n}).reduce(\n (obj, [, { type, lotteryAnimatePath }]) => {\n obj[type] = lotteryAnimatePath;\n return obj;\n },\n {\n [lotteryGeneralAnimationType]: lotteryOpenPathParams.GENERAL\n }\n);\nexport const lotteryInstantTypes = Object.entries(lotteriesConfig.instant).reduce(\n (obj, [key, { type }]) => {\n obj[key] = type;\n return obj;\n },\n {}\n);\nexport const lotteryParticipantTypes = Object.entries(lotteriesConfig.participant).reduce(\n (obj, [key, { type }]) => {\n obj[key] = type;\n return obj;\n },\n {}\n);\nexport const lotteryAdminTypes = Object.entries(lotteriesConfig.admin).reduce(\n (obj, [key, { type }]) => {\n obj[key] = type;\n return obj;\n },\n {}\n);\n\nconst lotteriesHaveAnimation = new Set([\n WIN_WHEEL,\n SCRATCH_CARD,\n POKE_GAME,\n RED_ENVELOPE_RAIN,\n SLOTS,\n PICK_THE_PRIZE\n]);\nexport function isLotteryHasAnimation(type) {\n return lotteriesHaveAnimation.has(type);\n}\n\nconst hideThankPrizeLottery = new Set([ADMIN, PICK_THE_PRIZE]);\nexport function getHideThankPrizeLottery(type) {\n return hideThankPrizeLottery.has(type);\n}\n\n/**\n * 獎品分配規則算法\n *\n * - 0: 機率\n * - 1: 順序\n * - 2: 沒限制,自由選\n */\nexport const lotteryAlgorithmTypes = {\n PERCENT: 0,\n ORDER: 1,\n SELF_PICK: 2\n};\n\n/**\n * 獎品數量顯示\n *\n * - 0: 不顯示\n * - 1: 顯示獎品總數\n * - 2: 顯示獎品剩餘數量總數\n */\nconst NOT_SHOW = 0;\nconst SHOW_REMAIN_AMOUNT = 1;\nconst SHOW_TOTAL_AMOUNT = 2;\nexport const lotteryRestShowTypes = {\n NOT_SHOW,\n SHOW_REMAIN_AMOUNT,\n SHOW_TOTAL_AMOUNT\n};\n\n/**\n * 獎品發完處理方式\n *\n * - 1: 自動暫停活動\n * - 0: 繼續進行活動\n */\nconst CONTINUE = 0;\nconst SUSPEND = 1;\nexport const lotteryWhenNoPrizeTypes = {\n SUSPEND,\n CONTINUE\n};\n\n/**\n * 獎品領取限制\n *\n * - -1: 無限制\n * - 1: 限制領取上限 (最多一個)\n */\nconst UNLIMITED = -1;\nconst LIMITED = 1;\nexport const lotteryPrizeGetLimitTypes = {\n UNLIMITED,\n LIMITED\n};\n","import i18n from 'i18next';\n\nimport { hasUtcDTStartInLocal } from 'utils/dateTime';\n\nexport const IS_NO_PLANS = -2;\nexport const IS_END = -1;\nexport const IS_OFFLINE = 0;\nexport const IS_ONLINE = 1;\nexport const IS_SUSPEND = 2;\n\nexport function getStatusLabel(status, promoStartDate) {\n switch (status) {\n case IS_OFFLINE:\n return i18n.t('label.no_publish');\n case IS_ONLINE:\n return Boolean(promoStartDate) && hasUtcDTStartInLocal(promoStartDate)\n ? i18n.t('label.is_published')\n : i18n.t('label.is_queue_publish');\n case IS_SUSPEND:\n return i18n.t('label.is_suspended');\n case IS_END:\n return i18n.t('label.is_end');\n default:\n return '';\n }\n}\n\n// 詳情請見 Ticket [NFV-2746]\n// 以下這些全都是兩個模組架構下的特例 wording 處理 = =\nexport function getStatusLabelWhenPromoStructureIsTwoPromo({\n primaryStatus,\n secondaryStatus,\n primaryStartDate,\n secondaryStartDate\n} = {}) {\n const DEFAULT_CASE = 'DEFAULT_CASE';\n const PARTICULAR_CASE_WHEN_BOTH_PROMO_ONLINE = 'PARTICULAR_CASE_WHEN_BOTH_PROMO_ONLINE';\n\n const labelStatusHandler = {\n [DEFAULT_CASE]: (status, promoStartDate) => {\n return getIsPromoSuspendNotYetStart(status, promoStartDate)\n ? i18n.t('label.suspend_start')\n : getStatusLabel(status, promoStartDate);\n },\n [PARTICULAR_CASE_WHEN_BOTH_PROMO_ONLINE]: (status, promoStartDate, isQueuePublish) => {\n return isQueuePublish\n ? i18n.t('label.about_to_start')\n : getStatusLabel(status, promoStartDate);\n }\n };\n\n const isBothPromoOnline = primaryStatus === IS_ONLINE && secondaryStatus === IS_ONLINE;\n const isPrimaryPromoQueuePublish = getIsQueuePublishStatus(primaryStatus, primaryStartDate);\n const isSecondaryPromoQueuePublish = getIsQueuePublishStatus(\n secondaryStatus,\n secondaryStartDate\n );\n const isHasOnlyOneQueuePublishPromo = Boolean(\n isPrimaryPromoQueuePublish ^ isSecondaryPromoQueuePublish\n );\n\n let currentParticularCase = DEFAULT_CASE;\n let primaryStatusLabel = '';\n let secondaryStatusLabel = '';\n\n if (isBothPromoOnline) {\n currentParticularCase = isHasOnlyOneQueuePublishPromo\n ? PARTICULAR_CASE_WHEN_BOTH_PROMO_ONLINE\n : currentParticularCase;\n }\n\n switch (currentParticularCase) {\n case PARTICULAR_CASE_WHEN_BOTH_PROMO_ONLINE:\n primaryStatusLabel = labelStatusHandler[currentParticularCase](\n primaryStatus,\n primaryStartDate,\n isPrimaryPromoQueuePublish\n );\n secondaryStatusLabel = labelStatusHandler[currentParticularCase](\n secondaryStatus,\n secondaryStartDate,\n isSecondaryPromoQueuePublish\n );\n break;\n default:\n primaryStatusLabel = labelStatusHandler[currentParticularCase](\n primaryStatus,\n primaryStartDate\n );\n secondaryStatusLabel = labelStatusHandler[currentParticularCase](\n secondaryStatus,\n secondaryStartDate\n );\n break;\n }\n\n return [primaryStatusLabel, secondaryStatusLabel];\n}\n\nexport function getIsPromoSuspendNotYetStart(status, promoStartDate) {\n return (\n status === IS_SUSPEND && Boolean(promoStartDate) && !hasUtcDTStartInLocal(promoStartDate)\n );\n}\n\nexport function getIsQueuePublishStatus(status, promoStartDate) {\n return status === IS_ONLINE && Boolean(promoStartDate) && !hasUtcDTStartInLocal(promoStartDate);\n}\n","/**\n * 獎品類型\n *\n * - 1: 寄送獎\n * - 2: 自製優惠卷\n * - 3: 上傳序號\n * - 4: 銘謝惠顧\n * - 5: 會員點數 - 固定給予\n * - 6: 購物金\n * - 7: 獎品代碼\n * - 8: Cyberbiz 動態序號\n * - 9: 會員點數 - 動態計算\n * - 10: 活動點數 - 動態計算\n * - 11: 活動點數 - 固定給予\n * - 12: Shopline 動態序號\n */\n\nconst GENERAL_PRIZE = 1;\nconst GENERAL_COUPON = 2;\nconst COUPON_CODE = 3;\nconst THANKYOU = 4;\nconst POINT = 5;\nconst CASH_VOUCHER = 6;\nconst PRIZE_CODE = 7;\nconst CYBERBIZ_COUPON = 8;\nconst MEMBERSHIP_DYNAMIC_POINT = 9;\nconst PROMO_DYNAMIC_POINT = 10;\nconst PROMO_FIXED_POINT = 11;\nconst SHOPLINE_COUPON_CODE = 12;\n\nexport const prizeTypes = {\n GENERAL_PRIZE,\n GENERAL_COUPON,\n COUPON_CODE,\n THANKYOU,\n POINT,\n CASH_VOUCHER,\n PRIZE_CODE,\n CYBERBIZ_COUPON,\n MEMBERSHIP_DYNAMIC_POINT,\n PROMO_DYNAMIC_POINT,\n PROMO_FIXED_POINT,\n SHOPLINE_COUPON_CODE\n};\n\n/**\n * 支援收藏獎品類型\n *\n * - 2: 自製優惠卷\n * - 3: 上傳序號\n */\n\nexport const supportCollectPrizeTypes = [GENERAL_COUPON, COUPON_CODE];\n\n/**\n * 獎品兌換期限類型\n *\n * - 0: 不限\n * - 1: 時間區間\n * - 2: 配獎後 N 天內\n * - 3: 配獎後 N 月後月底\n * - 4: 固定到期日\n */\n\nconst NO_LIMIT = 0;\nconst RANGE = 1;\nconst WITHIN = 2;\nconst WITHIN_MONTH_LAST_DAY = 3;\nconst FIXED_EXPIRATION = 4;\nexport const prizeRedeemDateLimitTypes = {\n NO_LIMIT,\n RANGE,\n WITHIN,\n WITHIN_MONTH_LAST_DAY,\n FIXED_EXPIRATION\n};\n\n/**\n * 上傳序號 檔案類型\n *\n * - 1: 序號\n * - 2: 兌換連結\n * - 3: 序號 + 兌換連結\n */\n\nconst UPLOAD_COUPON_CODE = 1;\nconst UPLOAD_URL = 2;\nconst UPLOAD_CODE_AND_URL = 3;\n\nexport const uploadCouponFileTypes = {\n UPLOAD_COUPON_CODE,\n UPLOAD_URL,\n UPLOAD_CODE_AND_URL\n};\n\n/**\n * 獎品類型 - 實體獎品\n * - 0: 不顯示\n * - 1: 顯示\n */\n\nconst UNLIMITED = 0;\nconst LIMITED = 1;\nexport const prizeQuantityLimitedTypes = {\n UNLIMITED,\n LIMITED\n};\n\n/**\n * 領獎限制 - 顯示獎品\n * - 0: 不顯示\n * - 1: 顯示\n */\n\nconst INVISIBLE = 0;\nconst VISIBLE = 1;\nexport const prizeVisibleTypes = {\n INVISIBLE,\n VISIBLE\n};\n\n/**\n * 兌換設定 - 實體核銷\n * - 1: 在獎品頁顯示核銷按鈕,由現場人員點擊兌換。 (針對獎品是 一般實體獎 / 自製優惠卷 / 上傳序號時或啟用)\n * - 2: 在獎品頁顯示 QRcode,由實體活動小幫手掃描核銷\n * - 3: 即時監聽電商訂單使用核銷 (針對獎品是 Cyberbiz 優惠券 / Shopline 優惠券 時或啟用)\n */\n\nconst REDEEM_BUTTON = 1;\nconst ON_SITE_ASSISTANT_TOOL = 2;\nconst ECOMMERCE_ORDER_REDEMPTION_LISTENER = 3;\nexport const prizeStoreRedeemTypes = {\n REDEEM_BUTTON,\n ON_SITE_ASSISTANT_TOOL,\n ECOMMERCE_ORDER_REDEMPTION_LISTENER\n};\n\n// 取得配獎模式名稱\nexport const prizeGiveWayLabel = Object.entries(prizeTypes).reduce((obj, [name, type]) => {\n obj[type] = name;\n return obj;\n}, {});\n\nexport function getPrizeTypeLabel(prizeType) {\n const prizeLabel = prizeGiveWayLabel[prizeType];\n return Boolean(prizeLabel) ? prizeLabel : '';\n}\n\n// 會員點數\nconst memberPointPrizeTypes = new Set([prizeTypes.POINT, prizeTypes.MEMBERSHIP_DYNAMIC_POINT]);\nexport function hasMemberPointPrizeType(prizeType) {\n return memberPointPrizeTypes.has(prizeType);\n}\n\n// 活動點數\nconst promoPointPrizeTypes = new Set([\n prizeTypes.PROMO_DYNAMIC_POINT,\n prizeTypes.PROMO_FIXED_POINT\n]);\nexport function hasPromoPointPrizeType(prizeType) {\n return promoPointPrizeTypes.has(prizeType);\n}\n\n// 固定點數\nconst fixedPointPrizeTypes = new Set([prizeTypes.POINT, prizeTypes.PROMO_FIXED_POINT]);\nexport function hasFixedPointPrizeType(prizeType) {\n return fixedPointPrizeTypes.has(prizeType);\n}\n\n// 動態點數\nconst dynamicPointPrizeTypes = new Set([\n prizeTypes.MEMBERSHIP_DYNAMIC_POINT,\n prizeTypes.PROMO_DYNAMIC_POINT\n]);\nexport function hasDynamicPointPrizeType(prizeType) {\n return dynamicPointPrizeTypes.has(prizeType);\n}\n\n// 點數獎品\nconst pointPrizeTypes = new Set([\n prizeTypes.MEMBERSHIP_DYNAMIC_POINT,\n prizeTypes.PROMO_DYNAMIC_POINT,\n prizeTypes.POINT,\n prizeTypes.PROMO_FIXED_POINT\n]);\nexport function hasPointPrizeType(prizeType) {\n return pointPrizeTypes.has(prizeType);\n}\n\n// 可自動歸戶的獎品\nexport const carrierClaimPrizeTypesForParticipateWinner = new Set([\n prizeTypes.POINT,\n prizeTypes.CASH_VOUCHER,\n prizeTypes.PRIZE_CODE,\n prizeTypes.CYBERBIZ_COUPON,\n prizeTypes.MEMBERSHIP_DYNAMIC_POINT,\n prizeTypes.SHOPLINE_COUPON_CODE\n]);\n\nexport function isCarrierClaimPrizeTypesForParticipateWinner(prizeType) {\n return carrierClaimPrizeTypesForParticipateWinner.has(prizeType);\n}\n\n// 切換獎品類型需轉換兌換設定時間\nconst convertRedeemTimePrizeTypes = new Set([prizeTypes.CASH_VOUCHER]);\nexport function isConvertRedeemTimePrizeType(prizeType) {\n return convertRedeemTimePrizeTypes.has(prizeType) || pointPrizeTypes.has(prizeTypes);\n}\n\n// 電商優惠卷類型獎品\nexport const ecommerceCouponPrizeTypes = new Set([\n prizeTypes.CYBERBIZ_COUPON,\n prizeTypes.SHOPLINE_COUPON_CODE\n]);\n\nexport function isEcommerceCouponPrizeTypes(prizeType) {\n return ecommerceCouponPrizeTypes.has(prizeType);\n}\n","import timezones from 'timezones-list';\n\n// 透過 Intl.supportedValuesOf('timeZone'); 取得,但因支援度太新,有些裝置無法執行,因此直接列舉出來。\nconst dayjsSupportTimeZones = [\n 'Africa/Abidjan',\n 'Africa/Accra',\n 'Africa/Addis_Ababa',\n 'Africa/Algiers',\n 'Africa/Asmera',\n 'Africa/Bamako',\n 'Africa/Bangui',\n 'Africa/Banjul',\n 'Africa/Bissau',\n 'Africa/Blantyre',\n 'Africa/Brazzaville',\n 'Africa/Bujumbura',\n 'Africa/Cairo',\n 'Africa/Casablanca',\n 'Africa/Ceuta',\n 'Africa/Conakry',\n 'Africa/Dakar',\n 'Africa/Dar_es_Salaam',\n 'Africa/Djibouti',\n 'Africa/Douala',\n 'Africa/El_Aaiun',\n 'Africa/Freetown',\n 'Africa/Gaborone',\n 'Africa/Harare',\n 'Africa/Johannesburg',\n 'Africa/Juba',\n 'Africa/Kampala',\n 'Africa/Khartoum',\n 'Africa/Kigali',\n 'Africa/Kinshasa',\n 'Africa/Lagos',\n 'Africa/Libreville',\n 'Africa/Lome',\n 'Africa/Luanda',\n 'Africa/Lubumbashi',\n 'Africa/Lusaka',\n 'Africa/Malabo',\n 'Africa/Maputo',\n 'Africa/Maseru',\n 'Africa/Mbabane',\n 'Africa/Mogadishu',\n 'Africa/Monrovia',\n 'Africa/Nairobi',\n 'Africa/Ndjamena',\n 'Africa/Niamey',\n 'Africa/Nouakchott',\n 'Africa/Ouagadougou',\n 'Africa/Porto-Novo',\n 'Africa/Sao_Tome',\n 'Africa/Tripoli',\n 'Africa/Tunis',\n 'Africa/Windhoek',\n 'America/Adak',\n 'America/Anchorage',\n 'America/Anguilla',\n 'America/Antigua',\n 'America/Araguaina',\n 'America/Argentina/La_Rioja',\n 'America/Argentina/Rio_Gallegos',\n 'America/Argentina/Salta',\n 'America/Argentina/San_Juan',\n 'America/Argentina/San_Luis',\n 'America/Argentina/Tucuman',\n 'America/Argentina/Ushuaia',\n 'America/Aruba',\n 'America/Asuncion',\n 'America/Bahia',\n 'America/Bahia_Banderas',\n 'America/Barbados',\n 'America/Belem',\n 'America/Belize',\n 'America/Blanc-Sablon',\n 'America/Boa_Vista',\n 'America/Bogota',\n 'America/Boise',\n 'America/Buenos_Aires',\n 'America/Cambridge_Bay',\n 'America/Campo_Grande',\n 'America/Cancun',\n 'America/Caracas',\n 'America/Catamarca',\n 'America/Cayenne',\n 'America/Cayman',\n 'America/Chicago',\n 'America/Chihuahua',\n 'America/Ciudad_Juarez',\n 'America/Coral_Harbour',\n 'America/Cordoba',\n 'America/Costa_Rica',\n 'America/Creston',\n 'America/Cuiaba',\n 'America/Curacao',\n 'America/Danmarkshavn',\n 'America/Dawson',\n 'America/Dawson_Creek',\n 'America/Denver',\n 'America/Detroit',\n 'America/Dominica',\n 'America/Edmonton',\n 'America/Eirunepe',\n 'America/El_Salvador',\n 'America/Fort_Nelson',\n 'America/Fortaleza',\n 'America/Glace_Bay',\n 'America/Godthab',\n 'America/Goose_Bay',\n 'America/Grand_Turk',\n 'America/Grenada',\n 'America/Guadeloupe',\n 'America/Guatemala',\n 'America/Guayaquil',\n 'America/Guyana',\n 'America/Halifax',\n 'America/Havana',\n 'America/Hermosillo',\n 'America/Indiana/Knox',\n 'America/Indiana/Marengo',\n 'America/Indiana/Petersburg',\n 'America/Indiana/Tell_City',\n 'America/Indiana/Vevay',\n 'America/Indiana/Vincennes',\n 'America/Indiana/Winamac',\n 'America/Indianapolis',\n 'America/Inuvik',\n 'America/Iqaluit',\n 'America/Jamaica',\n 'America/Jujuy',\n 'America/Juneau',\n 'America/Kentucky/Monticello',\n 'America/Kralendijk',\n 'America/La_Paz',\n 'America/Lima',\n 'America/Los_Angeles',\n 'America/Louisville',\n 'America/Lower_Princes',\n 'America/Maceio',\n 'America/Managua',\n 'America/Manaus',\n 'America/Marigot',\n 'America/Martinique',\n 'America/Matamoros',\n 'America/Mazatlan',\n 'America/Mendoza',\n 'America/Menominee',\n 'America/Merida',\n 'America/Metlakatla',\n 'America/Mexico_City',\n 'America/Miquelon',\n 'America/Moncton',\n 'America/Monterrey',\n 'America/Montevideo',\n 'America/Montserrat',\n 'America/Nassau',\n 'America/New_York',\n 'America/Nipigon',\n 'America/Nome',\n 'America/Noronha',\n 'America/North_Dakota/Beulah',\n 'America/North_Dakota/Center',\n 'America/North_Dakota/New_Salem',\n 'America/Ojinaga',\n 'America/Panama',\n 'America/Pangnirtung',\n 'America/Paramaribo',\n 'America/Phoenix',\n 'America/Port-au-Prince',\n 'America/Port_of_Spain',\n 'America/Porto_Velho',\n 'America/Puerto_Rico',\n 'America/Punta_Arenas',\n 'America/Rainy_River',\n 'America/Rankin_Inlet',\n 'America/Recife',\n 'America/Regina',\n 'America/Resolute',\n 'America/Rio_Branco',\n 'America/Santa_Isabel',\n 'America/Santarem',\n 'America/Santiago',\n 'America/Santo_Domingo',\n 'America/Sao_Paulo',\n 'America/Scoresbysund',\n 'America/Sitka',\n 'America/St_Barthelemy',\n 'America/St_Johns',\n 'America/St_Kitts',\n 'America/St_Lucia',\n 'America/St_Thomas',\n 'America/St_Vincent',\n 'America/Swift_Current',\n 'America/Tegucigalpa',\n 'America/Thule',\n 'America/Thunder_Bay',\n 'America/Tijuana',\n 'America/Toronto',\n 'America/Tortola',\n 'America/Vancouver',\n 'America/Whitehorse',\n 'America/Winnipeg',\n 'America/Yakutat',\n 'America/Yellowknife',\n 'Antarctica/Casey',\n 'Antarctica/Davis',\n 'Antarctica/DumontDUrville',\n 'Antarctica/Macquarie',\n 'Antarctica/Mawson',\n 'Antarctica/McMurdo',\n 'Antarctica/Palmer',\n 'Antarctica/Rothera',\n 'Antarctica/Syowa',\n 'Antarctica/Troll',\n 'Antarctica/Vostok',\n 'Arctic/Longyearbyen',\n 'Asia/Aden',\n 'Asia/Almaty',\n 'Asia/Amman',\n 'Asia/Anadyr',\n 'Asia/Aqtau',\n 'Asia/Aqtobe',\n 'Asia/Ashgabat',\n 'Asia/Atyrau',\n 'Asia/Baghdad',\n 'Asia/Bahrain',\n 'Asia/Baku',\n 'Asia/Bangkok',\n 'Asia/Barnaul',\n 'Asia/Beirut',\n 'Asia/Bishkek',\n 'Asia/Brunei',\n 'Asia/Calcutta',\n 'Asia/Chita',\n 'Asia/Choibalsan',\n 'Asia/Colombo',\n 'Asia/Damascus',\n 'Asia/Dhaka',\n 'Asia/Dili',\n 'Asia/Dubai',\n 'Asia/Dushanbe',\n 'Asia/Famagusta',\n 'Asia/Gaza',\n 'Asia/Hebron',\n 'Asia/Hong_Kong',\n 'Asia/Hovd',\n 'Asia/Irkutsk',\n 'Asia/Jakarta',\n 'Asia/Jayapura',\n 'Asia/Jerusalem',\n 'Asia/Kabul',\n 'Asia/Kamchatka',\n 'Asia/Karachi',\n 'Asia/Katmandu',\n 'Asia/Khandyga',\n 'Asia/Krasnoyarsk',\n 'Asia/Kuala_Lumpur',\n 'Asia/Kuching',\n 'Asia/Kuwait',\n 'Asia/Macau',\n 'Asia/Magadan',\n 'Asia/Makassar',\n 'Asia/Manila',\n 'Asia/Muscat',\n 'Asia/Nicosia',\n 'Asia/Novokuznetsk',\n 'Asia/Novosibirsk',\n 'Asia/Omsk',\n 'Asia/Oral',\n 'Asia/Phnom_Penh',\n 'Asia/Pontianak',\n 'Asia/Pyongyang',\n 'Asia/Qatar',\n 'Asia/Qostanay',\n 'Asia/Qyzylorda',\n 'Asia/Rangoon',\n 'Asia/Riyadh',\n 'Asia/Saigon',\n 'Asia/Sakhalin',\n 'Asia/Samarkand',\n 'Asia/Seoul',\n 'Asia/Shanghai',\n 'Asia/Singapore',\n 'Asia/Srednekolymsk',\n 'Asia/Taipei',\n 'Asia/Tashkent',\n 'Asia/Tbilisi',\n 'Asia/Tehran',\n 'Asia/Thimphu',\n 'Asia/Tokyo',\n 'Asia/Tomsk',\n 'Asia/Ulaanbaatar',\n 'Asia/Urumqi',\n 'Asia/Ust-Nera',\n 'Asia/Vientiane',\n 'Asia/Vladivostok',\n 'Asia/Yakutsk',\n 'Asia/Yekaterinburg',\n 'Asia/Yerevan',\n 'Atlantic/Azores',\n 'Atlantic/Bermuda',\n 'Atlantic/Canary',\n 'Atlantic/Cape_Verde',\n 'Atlantic/Faeroe',\n 'Atlantic/Madeira',\n 'Atlantic/Reykjavik',\n 'Atlantic/South_Georgia',\n 'Atlantic/St_Helena',\n 'Atlantic/Stanley',\n 'Australia/Adelaide',\n 'Australia/Brisbane',\n 'Australia/Broken_Hill',\n 'Australia/Currie',\n 'Australia/Darwin',\n 'Australia/Eucla',\n 'Australia/Hobart',\n 'Australia/Lindeman',\n 'Australia/Lord_Howe',\n 'Australia/Melbourne',\n 'Australia/Perth',\n 'Australia/Sydney',\n 'Europe/Amsterdam',\n 'Europe/Andorra',\n 'Europe/Astrakhan',\n 'Europe/Athens',\n 'Europe/Belgrade',\n 'Europe/Berlin',\n 'Europe/Bratislava',\n 'Europe/Brussels',\n 'Europe/Bucharest',\n 'Europe/Budapest',\n 'Europe/Busingen',\n 'Europe/Chisinau',\n 'Europe/Copenhagen',\n 'Europe/Dublin',\n 'Europe/Gibraltar',\n 'Europe/Guernsey',\n 'Europe/Helsinki',\n 'Europe/Isle_of_Man',\n 'Europe/Istanbul',\n 'Europe/Jersey',\n 'Europe/Kaliningrad',\n 'Europe/Kiev',\n 'Europe/Kirov',\n 'Europe/Lisbon',\n 'Europe/Ljubljana',\n 'Europe/London',\n 'Europe/Luxembourg',\n 'Europe/Madrid',\n 'Europe/Malta',\n 'Europe/Mariehamn',\n 'Europe/Minsk',\n 'Europe/Monaco',\n 'Europe/Moscow',\n 'Europe/Oslo',\n 'Europe/Paris',\n 'Europe/Podgorica',\n 'Europe/Prague',\n 'Europe/Riga',\n 'Europe/Rome',\n 'Europe/Samara',\n 'Europe/San_Marino',\n 'Europe/Sarajevo',\n 'Europe/Saratov',\n 'Europe/Simferopol',\n 'Europe/Skopje',\n 'Europe/Sofia',\n 'Europe/Stockholm',\n 'Europe/Tallinn',\n 'Europe/Tirane',\n 'Europe/Ulyanovsk',\n 'Europe/Uzhgorod',\n 'Europe/Vaduz',\n 'Europe/Vatican',\n 'Europe/Vienna',\n 'Europe/Vilnius',\n 'Europe/Volgograd',\n 'Europe/Warsaw',\n 'Europe/Zagreb',\n 'Europe/Zaporozhye',\n 'Europe/Zurich',\n 'Indian/Antananarivo',\n 'Indian/Chagos',\n 'Indian/Christmas',\n 'Indian/Cocos',\n 'Indian/Comoro',\n 'Indian/Kerguelen',\n 'Indian/Mahe',\n 'Indian/Maldives',\n 'Indian/Mauritius',\n 'Indian/Mayotte',\n 'Indian/Reunion',\n 'Pacific/Apia',\n 'Pacific/Auckland',\n 'Pacific/Bougainville',\n 'Pacific/Chatham',\n 'Pacific/Easter',\n 'Pacific/Efate',\n 'Pacific/Enderbury',\n 'Pacific/Fakaofo',\n 'Pacific/Fiji',\n 'Pacific/Funafuti',\n 'Pacific/Galapagos',\n 'Pacific/Gambier',\n 'Pacific/Guadalcanal',\n 'Pacific/Guam',\n 'Pacific/Honolulu',\n 'Pacific/Johnston',\n 'Pacific/Kiritimati',\n 'Pacific/Kosrae',\n 'Pacific/Kwajalein',\n 'Pacific/Majuro',\n 'Pacific/Marquesas',\n 'Pacific/Midway',\n 'Pacific/Nauru',\n 'Pacific/Niue',\n 'Pacific/Norfolk',\n 'Pacific/Noumea',\n 'Pacific/Pago_Pago',\n 'Pacific/Palau',\n 'Pacific/Pitcairn',\n 'Pacific/Ponape',\n 'Pacific/Port_Moresby',\n 'Pacific/Rarotonga',\n 'Pacific/Saipan',\n 'Pacific/Tahiti',\n 'Pacific/Tarawa',\n 'Pacific/Tongatapu',\n 'Pacific/Truk',\n 'Pacific/Wake',\n 'Pacific/Wallis'\n];\n\n// https://app.clickup.com/t/86enkghkg\nconst backendTimezone = [\n 'Africa/Asmera',\n 'Africa/Timbuktu',\n 'America/Argentina/ComodRivadavia',\n 'America/Atka',\n 'Africa/Abidjan',\n 'Africa/Accra',\n 'Africa/Addis_Ababa',\n 'Africa/Algiers',\n 'Atlantic/Azores',\n 'Atlantic/Bermuda',\n 'Atlantic/Canary',\n 'Atlantic/Cape_Verde',\n 'America/Buenos_Aires',\n 'America/Catamarca',\n 'America/Coral_Harbour',\n 'America/Cordoba',\n 'Africa/Asmara',\n 'Africa/Bamako',\n 'Africa/Bangui',\n 'Africa/Banjul',\n 'Atlantic/Faroe',\n 'Atlantic/Madeira',\n 'Atlantic/Reykjavik',\n 'Atlantic/South_Georgia',\n 'America/Ensenada',\n 'America/Fort_Wayne',\n 'America/Godthab',\n 'America/Indianapolis',\n 'Africa/Bissau',\n 'Africa/Blantyre',\n 'Africa/Brazzaville',\n 'Africa/Bujumbura',\n 'Atlantic/St_Helena',\n 'Atlantic/Stanley',\n 'America/Jujuy',\n 'America/Knox_IN',\n 'America/Louisville',\n 'America/Mendoza',\n 'Africa/Cairo',\n 'Africa/Casablanca',\n 'Africa/Ceuta',\n 'Africa/Conakry',\n 'Australia/Adelaide',\n 'Australia/Brisbane',\n 'Australia/Broken_Hill',\n 'Australia/Darwin',\n 'America/Montreal',\n 'America/Nipigon',\n 'America/Pangnirtung',\n 'America/Porto_Acre',\n 'Africa/Dakar',\n 'Africa/Dar_es_Salaam',\n 'Africa/Djibouti',\n 'Africa/Douala',\n 'Australia/Eucla',\n 'Australia/Hobart',\n 'Australia/Lindeman',\n 'Australia/Lord_Howe',\n 'America/Rainy_River',\n 'America/Rosario',\n 'America/Santa_Isabel',\n 'America/Shiprock',\n 'Africa/El_Aaiun',\n 'Africa/Freetown',\n 'Africa/Gaborone',\n 'Africa/Harare',\n 'Australia/Melbourne',\n 'Australia/Perth',\n 'Australia/Sydney',\n 'America/Thunder_Bay',\n 'America/Virgin',\n 'America/Yellowknife',\n 'Antarctica/South_Pole',\n 'Africa/Johannesburg',\n 'Africa/Juba',\n 'Africa/Kampala',\n 'Africa/Khartoum',\n 'Europe/Amsterdam',\n 'Europe/Andorra',\n 'Europe/Astrakhan',\n 'Europe/Athens',\n 'Asia/Ashkhabad',\n 'Asia/Calcutta',\n 'Asia/Chongqing',\n 'Asia/Chungking',\n 'Africa/Kigali',\n 'Africa/Kinshasa',\n 'Africa/Lagos',\n 'Africa/Libreville',\n 'Europe/Belgrade',\n 'Europe/Berlin',\n 'Europe/Bratislava',\n 'Europe/Brussels',\n 'Asia/Dacca',\n 'Asia/Harbin',\n 'Asia/Istanbul',\n 'Asia/Kashgar',\n 'Africa/Lome',\n 'Africa/Luanda',\n 'Africa/Lubumbashi',\n 'Africa/Lusaka',\n 'Europe/Bucharest',\n 'Europe/Budapest',\n 'Europe/Busingen',\n 'Europe/Chisinau',\n 'Asia/Katmandu',\n 'Asia/Macao',\n 'Asia/Rangoon',\n 'Asia/Saigon',\n 'Africa/Malabo',\n 'Africa/Maputo',\n 'Africa/Maseru',\n 'Africa/Mbabane',\n 'Europe/Copenhagen',\n 'Europe/Dublin',\n 'Europe/Gibraltar',\n 'Europe/Guernsey',\n 'Asia/Tel_Aviv',\n 'Asia/Thimbu',\n 'Asia/Ujung_Pandang',\n 'Asia/Ulan_Bator',\n 'Africa/Mogadishu',\n 'Africa/Monrovia',\n 'Africa/Nairobi',\n 'Africa/Ndjamena',\n 'Europe/Helsinki',\n 'Europe/Isle_of_Man',\n 'Europe/Istanbul',\n 'Europe/Jersey',\n 'Atlantic/Faeroe',\n 'Atlantic/Jan_Mayen',\n 'Australia/ACT',\n 'Australia/Canberra',\n 'Africa/Niamey',\n 'Africa/Nouakchott',\n 'Africa/Ouagadougou',\n 'Africa/Porto-Novo',\n 'Europe/Kaliningrad',\n 'Europe/Kirov',\n 'Europe/Kyiv',\n 'Europe/Lisbon',\n 'Australia/Currie',\n 'Australia/LHI',\n 'Australia/North',\n 'Australia/NSW',\n 'Africa/Sao_Tome',\n 'Africa/Tripoli',\n 'Africa/Tunis',\n 'Africa/Windhoek',\n 'Europe/Ljubljana',\n 'Europe/London',\n 'Europe/Luxembourg',\n 'Europe/Madrid',\n 'Australia/Queensland',\n 'Australia/South',\n 'Australia/Tasmania',\n 'Australia/Victoria',\n 'America/Adak',\n 'America/Anchorage',\n 'America/Anguilla',\n 'America/Antigua',\n 'Europe/Malta',\n 'Europe/Mariehamn',\n 'Europe/Minsk',\n 'Europe/Monaco',\n 'Australia/West',\n 'Australia/Yancowinna',\n 'Brazil/Acre',\n 'Brazil/DeNoronha',\n 'America/Araguaina',\n 'America/Argentina/Buenos_Aires',\n 'America/Argentina/Catamarca',\n 'America/Argentina/Cordoba',\n 'Europe/Moscow',\n 'Europe/Oslo',\n 'Europe/Paris',\n 'Europe/Podgorica',\n 'Brazil/East',\n 'Brazil/West',\n 'Canada/Atlantic',\n 'Canada/Central',\n 'America/Argentina/Jujuy',\n 'America/Argentina/La_Rioja',\n 'America/Argentina/Mendoza',\n 'America/Argentina/Rio_Gallegos',\n 'Europe/Prague',\n 'Europe/Riga',\n 'Europe/Rome',\n 'Europe/Samara',\n 'Canada/Eastern',\n 'Canada/Mountain',\n 'Canada/Newfoundland',\n 'Canada/Pacific',\n 'America/Argentina/Salta',\n 'America/Argentina/San_Juan',\n 'America/Argentina/San_Luis',\n 'America/Argentina/Tucuman',\n 'Europe/San_Marino',\n 'Europe/Sarajevo',\n 'Europe/Saratov',\n 'Europe/Simferopol',\n 'Canada/Saskatchewan',\n 'Canada/Yukon',\n 'CET',\n 'Chile/Continental',\n 'America/Argentina/Ushuaia',\n 'America/Aruba',\n 'America/Asuncion',\n 'America/Atikokan',\n 'Europe/Skopje',\n 'Europe/Sofia',\n 'Europe/Stockholm',\n 'Europe/Tallinn',\n 'Chile/EasterIsland',\n 'CST6CDT',\n 'Cuba',\n 'EET',\n 'America/Bahia',\n 'America/Bahia_Banderas',\n 'America/Barbados',\n 'America/Belem',\n 'Europe/Tirane',\n 'Europe/Ulyanovsk',\n 'Europe/Vaduz',\n 'Europe/Vatican',\n 'Egypt',\n 'Eire',\n 'EST',\n 'EST5EDT',\n 'America/Belize',\n 'America/Blanc-Sablon',\n 'America/Boa_Vista',\n 'America/Bogota',\n 'Europe/Vienna',\n 'Europe/Vilnius',\n 'Europe/Volgograd',\n 'Europe/Warsaw',\n 'Etc/GMT',\n 'Etc/GMT+0',\n 'Etc/GMT+1',\n 'Etc/GMT+10',\n 'America/Boise',\n 'America/Cambridge_Bay',\n 'America/Campo_Grande',\n 'America/Cancun',\n 'Europe/Zagreb',\n 'Europe/Zurich',\n 'Etc/GMT+11',\n 'Etc/GMT+12',\n 'Etc/GMT+2',\n 'Etc/GMT+3',\n 'America/Caracas',\n 'America/Cayenne',\n 'America/Cayman',\n 'America/Chicago',\n 'Indian/Antananarivo',\n 'Indian/Chagos',\n 'Indian/Christmas',\n 'Indian/Cocos',\n 'Etc/GMT+4',\n 'Etc/GMT+5',\n 'Etc/GMT+6',\n 'Etc/GMT+7',\n 'America/Chihuahua',\n 'America/Ciudad_Juarez',\n 'America/Costa_Rica',\n 'America/Creston',\n 'Indian/Comoro',\n 'Indian/Kerguelen',\n 'Indian/Mahe',\n 'Indian/Maldives',\n 'Etc/GMT+8',\n 'Etc/GMT+9',\n 'Etc/GMT-0',\n 'Etc/GMT-1',\n 'America/Cuiaba',\n 'America/Curacao',\n 'America/Danmarkshavn',\n 'America/Dawson',\n 'Indian/Mauritius',\n 'Indian/Mayotte',\n 'Indian/Reunion',\n 'Etc/GMT-10',\n 'Etc/GMT-11',\n 'Etc/GMT-12',\n 'Etc/GMT-13',\n 'America/Dawson_Creek',\n 'America/Denver',\n 'America/Detroit',\n 'America/Dominica',\n 'Pacific/Apia',\n 'Pacific/Auckland',\n 'Pacific/Bougainville',\n 'Pacific/Chatham',\n 'Etc/GMT-14',\n 'Etc/GMT-2',\n 'Etc/GMT-3',\n 'Etc/GMT-4',\n 'America/Edmonton',\n 'America/Eirunepe',\n 'America/El_Salvador',\n 'America/Fort_Nelson',\n 'Pacific/Chuuk',\n 'Pacific/Easter',\n 'Pacific/Efate',\n 'Pacific/Fakaofo',\n 'Etc/GMT-5',\n 'Etc/GMT-6',\n 'Etc/GMT-7',\n 'Etc/GMT-8',\n 'America/Fortaleza',\n 'America/Glace_Bay',\n 'America/Goose_Bay',\n 'America/Grand_Turk',\n 'Pacific/Fiji',\n 'Pacific/Funafuti',\n 'Pacific/Galapagos',\n 'Pacific/Gambier',\n 'Etc/GMT-9',\n 'Etc/GMT0',\n 'Etc/Greenwich',\n 'Etc/UCT',\n 'America/Grenada',\n 'America/Guadeloupe',\n 'America/Guatemala',\n 'America/Guayaquil',\n 'Pacific/Guadalcanal',\n 'Pacific/Guam',\n 'Pacific/Honolulu',\n 'Pacific/Kanton',\n 'Etc/Universal',\n 'Etc/UTC',\n 'Etc/Zulu',\n 'Europe/Belfast',\n 'America/Guyana',\n 'America/Halifax',\n 'America/Havana',\n 'America/Hermosillo',\n 'Pacific/Kiritimati',\n 'Pacific/Kosrae',\n 'Pacific/Kwajalein',\n 'Pacific/Majuro',\n 'Europe/Kiev',\n 'Europe/Nicosia',\n 'Europe/Tiraspol',\n 'Europe/Uzhgorod',\n 'America/Indiana/Indianapolis',\n 'America/Indiana/Knox',\n 'America/Indiana/Marengo',\n 'America/Indiana/Petersburg',\n 'Pacific/Marquesas',\n 'Pacific/Midway',\n 'Pacific/Nauru',\n 'Pacific/Niue',\n 'Europe/Zaporozhye',\n 'Factory',\n 'GB',\n 'GB-Eire',\n 'America/Indiana/Tell_City',\n 'America/Indiana/Vevay',\n 'America/Indiana/Vincennes',\n 'America/Indiana/Winamac',\n 'Pacific/Norfolk',\n 'Pacific/Noumea',\n 'Pacific/Pago_Pago',\n 'Pacific/Palau',\n 'GMT',\n 'GMT+0',\n 'GMT-0',\n 'GMT0',\n 'America/Inuvik',\n 'America/Iqaluit',\n 'America/Jamaica',\n 'America/Juneau',\n 'Pacific/Pitcairn',\n 'Pacific/Pohnpei',\n 'Pacific/Port_Moresby',\n 'Pacific/Rarotonga',\n 'Greenwich',\n 'Hongkong',\n 'HST',\n 'Iceland',\n 'America/Kentucky/Louisville',\n 'America/Kentucky/Monticello',\n 'America/Kralendijk',\n 'America/La_Paz',\n 'Pacific/Saipan',\n 'Pacific/Tahiti',\n 'Pacific/Tarawa',\n 'Pacific/Tongatapu',\n 'Iran',\n 'Israel',\n 'Jamaica',\n 'Japan',\n 'America/Lima',\n 'America/Los_Angeles',\n 'America/Lower_Princes',\n 'America/Maceio',\n 'Pacific/Wake',\n 'Pacific/Wallis',\n 'Kwajalein',\n 'Libya',\n 'MET',\n 'Mexico/BajaNorte',\n 'America/Managua',\n 'America/Manaus',\n 'America/Marigot',\n 'America/Martinique',\n 'Asia/Aden',\n 'Asia/Almaty',\n 'Asia/Amman',\n 'Asia/Anadyr',\n 'Mexico/BajaSur',\n 'Mexico/General',\n 'MST',\n 'MST7MDT',\n 'America/Matamoros',\n 'America/Mazatlan',\n 'America/Menominee',\n 'America/Merida',\n 'Asia/Aqtau',\n 'Asia/Aqtobe',\n 'Asia/Ashgabat',\n 'Asia/Atyrau',\n 'Navajo',\n 'NZ',\n 'NZ-CHAT',\n 'Pacific/Enderbury',\n 'America/Metlakatla',\n 'America/Mexico_City',\n 'America/Miquelon',\n 'America/Moncton',\n 'Asia/Baghdad',\n 'Asia/Bahrain',\n 'Asia/Baku',\n 'Asia/Bangkok',\n 'Pacific/Johnston',\n 'Pacific/Ponape',\n 'Pacific/Samoa',\n 'Pacific/Truk',\n 'America/Monterrey',\n 'America/Montevideo',\n 'America/Montserrat',\n 'America/Nassau',\n 'Asia/Barnaul',\n 'Asia/Beirut',\n 'Asia/Bishkek',\n 'Asia/Brunei',\n 'Pacific/Yap',\n 'Poland',\n 'Portugal',\n 'PRC',\n 'America/New_York',\n 'America/Nome',\n 'America/Noronha',\n 'America/North_Dakota/Beulah',\n 'Asia/Chita',\n 'Asia/Choibalsan',\n 'Asia/Colombo',\n 'Asia/Damascus',\n 'PST8PDT',\n 'ROC',\n 'ROK',\n 'Singapore',\n 'America/North_Dakota/Center',\n 'America/North_Dakota/New_Salem',\n 'America/Nuuk',\n 'America/Ojinaga',\n 'Asia/Dhaka',\n 'Asia/Dili',\n 'Asia/Dubai',\n 'Asia/Dushanbe',\n 'Turkey',\n 'UCT',\n 'Universal',\n 'US/Alaska',\n 'America/Panama',\n 'America/Paramaribo',\n 'America/Phoenix',\n 'America/Port-au-Prince',\n 'Asia/Famagusta',\n 'Asia/Gaza',\n 'Asia/Hebron',\n 'Asia/Ho_Chi_Minh',\n 'US/Aleutian',\n 'US/Arizona',\n 'US/Central',\n 'US/East-Indiana',\n 'America/Port_of_Spain',\n 'America/Porto_Velho',\n 'America/Puerto_Rico',\n 'America/Punta_Arenas',\n 'Asia/Hong_Kong',\n 'Asia/Hovd',\n 'Asia/Irkutsk',\n 'Asia/Jakarta',\n 'US/Eastern',\n 'US/Hawaii',\n 'US/Indiana-Starke',\n 'US/Michigan',\n 'America/Rankin_Inlet',\n 'America/Recife',\n 'America/Regina',\n 'America/Resolute',\n 'Asia/Jayapura',\n 'Asia/Jerusalem',\n 'Asia/Kabul',\n 'Asia/Kamchatka',\n 'US/Mountain',\n 'US/Pacific',\n 'US/Samoa',\n 'UTC',\n 'America/Rio_Branco',\n 'America/Santarem',\n 'America/Santiago',\n 'America/Santo_Domingo',\n 'Asia/Karachi',\n 'Asia/Kathmandu',\n 'Asia/Khandyga',\n 'Asia/Kolkata',\n 'W-SU',\n 'WET',\n 'Zulu',\n 'America/Sao_Paulo',\n 'America/Scoresbysund',\n 'America/Sitka',\n 'America/St_Barthelemy',\n 'Asia/Krasnoyarsk',\n 'Asia/Kuala_Lumpur',\n 'Asia/Kuching',\n 'Asia/Kuwait',\n 'Antarctica/Casey',\n 'Antarctica/Davis',\n 'Antarctica/DumontDUrville',\n 'Antarctica/Macquarie',\n 'America/St_Johns',\n 'America/St_Kitts',\n 'America/St_Lucia',\n 'America/St_Thomas',\n 'Asia/Macau',\n 'Asia/Magadan',\n 'Asia/Makassar',\n 'Asia/Manila',\n 'Antarctica/Mawson',\n 'Antarctica/McMurdo',\n 'Antarctica/Palmer',\n 'Antarctica/Rothera',\n 'America/St_Vincent',\n 'America/Swift_Current',\n 'America/Tegucigalpa',\n 'America/Thule',\n 'Asia/Muscat',\n 'Asia/Nicosia',\n 'Asia/Novokuznetsk',\n 'Asia/Novosibirsk',\n 'Antarctica/Syowa',\n 'Antarctica/Troll',\n 'Antarctica/Vostok',\n 'Arctic/Longyearbyen',\n 'America/Tijuana',\n 'America/Toronto',\n 'America/Tortola',\n 'America/Vancouver',\n 'Asia/Omsk',\n 'Asia/Oral',\n 'Asia/Phnom_Penh',\n 'Asia/Pontianak',\n 'America/Whitehorse',\n 'America/Winnipeg',\n 'America/Yakutat',\n 'Asia/Pyongyang',\n 'Asia/Qatar',\n 'Asia/Qostanay',\n 'Asia/Qyzylorda',\n 'Asia/Riyadh',\n 'Asia/Sakhalin',\n 'Asia/Samarkand',\n 'Asia/Seoul',\n 'Asia/Shanghai',\n 'Asia/Singapore',\n 'Asia/Srednekolymsk',\n 'Asia/Taipei',\n 'Asia/Tashkent',\n 'Asia/Tbilisi',\n 'Asia/Tehran',\n 'Asia/Thimphu',\n 'Asia/Tokyo',\n 'Asia/Tomsk',\n 'Asia/Ulaanbaatar',\n 'Asia/Urumqi',\n 'Asia/Ust-Nera',\n 'Asia/Vientiane',\n 'Asia/Vladivostok',\n 'Asia/Yakutsk',\n 'Asia/Yangon',\n 'Asia/Yekaterinburg',\n 'Asia/Yerevan'\n];\n\nexport const timezoneList = (() =>\n timezones\n .filter(({ tzCode }) => backendTimezone.includes(tzCode))\n .filter(({ tzCode }) => dayjsSupportTimeZones.includes(tzCode)))();\n","import i18n from 'i18next';\nimport { system900, white } from 'Mui/styles/color';\n\nexport const ImageShowTypeMapping = {\n SQUARE: 1,\n WATERFALL: 2,\n SLIDERSHOW: 3,\n MARQUEE: 4,\n COLLAGE: 5\n};\n\nexport const galleryGameSetting = {\n versionStyleSettings: {\n //網格式:1,瀑布流:2,幻燈片:3,跑馬燈:4,作品拼貼:5\n imgShowType: ImageShowTypeMapping.SQUARE,\n isShowWorkInformation: false\n },\n buttonSettings: {\n isShowButton: true,\n buttonText: i18n.t('btn.read_more'),\n textColor: white.color,\n bgColor: system900.color,\n maskColor: white.color\n }\n};\n\nexport const squareFakeData = (igGame, isGallery) => {\n const getDefaultAvatarByType = (igGame, isGallery) => {\n if (igGame || isGallery) {\n return null;\n } else {\n return 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultOrigin.jpeg';\n }\n };\n let array = [];\n const fakeData1 = {\n avatar: getDefaultAvatarByType(igGame, isGallery),\n memberId: 123456,\n media: [\n {\n result: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultSquare.png',\n seq: 1,\n subtype: '',\n type: 'image'\n },\n {\n result: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultSquare.png',\n seq: 1,\n subtype: 'youtube',\n type: 'video'\n }\n ],\n ugcAuthorName: 'feversocial.tw',\n title: i18n.t('label.ugc.work_title')\n };\n const fakeData2 = {\n avatar: getDefaultAvatarByType(igGame, isGallery),\n memberId: 123456,\n media: [\n {\n result: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultOrigin.jpeg',\n seq: 1,\n subtype: '',\n type: 'image'\n },\n {\n result: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultOrigin.jpeg',\n seq: 1,\n subtype: 'youtube',\n type: 'video'\n }\n ],\n ugcAuthorName: 'feversocial.tw',\n title: i18n.t('label.ugc.work_title')\n };\n\n for (let i = 0; i < 6; i++) {\n array.push(fakeData1);\n array.push(fakeData2);\n }\n return array;\n};\n\nexport const sliderShowFakeData = () => {\n let data = [];\n const fakeData1 = {\n uuid: 1,\n value: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultSquare.png'\n };\n const fakeData2 = {\n uuid: 2,\n value: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultSquare.png'\n };\n\n for (let i = 0; i < 3; i++) {\n data.push(fakeData1);\n data.push(fakeData2);\n }\n return data;\n};\n\nexport const marqueeFakeData = () => {\n let data = [];\n const fakeData1 = {\n serialNo: 1,\n value: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultSquare.png'\n };\n const fakeData2 = {\n serialNo: 2,\n value: 'https://assets.fevercdn.com/promotion/img/ugc_image/defaultOrigin.jpeg'\n };\n\n for (let i = 0; i < 3; i++) {\n data.push(fakeData1);\n data.push(fakeData2);\n }\n\n let obj = { data: data, secondaryData: data };\n\n return obj;\n};\n","import i18n from 'i18next';\nimport { functionKeys } from 'config/functionKeysAndDisplayConfig';\nimport {\n lotteryInstantTypes,\n lotteryParticipantTypes,\n lotteryAdminTypes\n} from 'config/promoLotteryTypes';\nimport { fromEntries } from 'utils/core';\n\nexport const lotteryCategories = {\n IS_INSTANT_LOTTERY: 'isLotteryInstant',\n IS_PARTICIPANT_LOTTERY: 'isLotteryParticipant',\n IS_ADMIN_LOTTERY: 'isLotteryAdmin'\n};\n\nexport const prizeQuantityTypes = {\n LIMITED: 1,\n UNLIMITED: 0\n};\n\nconst adminPrize = {\n label: () => i18n.t('label.lottery'),\n value: lotteryAdminTypes.ADMIN,\n category: lotteryCategories.IS_ADMIN_LOTTERY,\n settingKey: functionKeys.lotteries.ADMIN\n};\nconst participantPrize = {\n label: () => i18n.t('label.instant_win'),\n value: lotteryInstantTypes.JOIN_AND_GET,\n category: lotteryCategories.IS_INSTANT_LOTTERY,\n settingKey: functionKeys.lotteries.JOIN_AND_GET\n};\nconst sketchPrize = {\n label: () => i18n.t('label.sketch_prize'),\n value: lotteryParticipantTypes.SCRATCH_CARD,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n isSketch: true,\n additionalConfig: 'scratch_card',\n settingKey: functionKeys.lotteries.SCRATCH_CARD\n};\nconst winWheelPrize = {\n label: () => i18n.t('label.winwheel'),\n value: lotteryParticipantTypes.WIN_WHEEL,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n additionalConfig: 'wheel',\n settingKey: functionKeys.lotteries.WIN_WHEEL\n};\nconst pokeGamePrize = {\n label: () => i18n.t('label.poke_game'),\n value: lotteryParticipantTypes.POKE_GAME,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n additionalConfig: 'poke_game',\n settingKey: functionKeys.lotteries.POKE_GAME\n};\nconst redEnvelopeRainPrize = {\n label: () => i18n.t('label.red_envelope_rain'),\n value: lotteryParticipantTypes.RED_ENVELOPE_RAIN,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n additionalConfig: 'red_envelope_rain',\n settingKey: functionKeys.lotteries.RED_ENVELOPE_RAIN\n};\nconst slotsPrize = {\n label: () => i18n.t('label.slots'),\n value: lotteryParticipantTypes.SLOTS,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n additionalConfig: 'slots',\n settingKey: functionKeys.lotteries.SLOTS\n};\nconst pickThePrizePrize = {\n label: () => i18n.t('label.game_type_pick_the_prize'),\n value: lotteryParticipantTypes.PICK_THE_PRIZE,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n additionalConfig: 'pickThePrize',\n settingKey: functionKeys.lotteries.PICK_THE_PRIZE\n};\nconst pointsRedeemPrize = {\n label: () => i18n.t('label.game_type_points_redeem'),\n value: lotteryParticipantTypes.POINTS_REDEEM,\n category: lotteryCategories.IS_PARTICIPANT_LOTTERY,\n additionalConfig: 'pointsRedeem',\n settingKey: functionKeys.lotteries.POINTS_REDEEM\n};\n\nexport const lotteryConfigList = [\n adminPrize,\n participantPrize,\n sketchPrize,\n winWheelPrize,\n pokeGamePrize,\n redEnvelopeRainPrize,\n slotsPrize,\n pickThePrizePrize,\n pointsRedeemPrize\n];\n\nexport const defaultSelectableLotteryTypesList = Object.values(lotteryCategories);\nexport function getLotteryConfig(type) {\n return (\n lotteryConfigList.find(({ value }) => Number(type) === value) || {\n label: () => {}\n }\n );\n}\n\nexport function getUnCreatedLotteryCategories(lotteryList) {\n const enableCreateLotteriesOptions = defaultSelectableLotteryTypesList.filter(\n category => !lotteryList.map(lottery => lottery.category).includes(category)\n );\n return enableCreateLotteriesOptions;\n}\n\nexport function getCreatedLotteryCategories(lotteryList) {\n const enableCreateLotteriesOptions = defaultSelectableLotteryTypesList.filter(category =>\n lotteryList.map(lottery => lottery.category).includes(category)\n );\n return enableCreateLotteriesOptions;\n}\n\nexport function getDefaultLotteryTypeByCategory(lotteryCategory) {\n const lotteryType = (category => {\n switch (category) {\n case lotteryCategories.IS_ADMIN_LOTTERY:\n return ADMIN_PRIZE_DEFAULT_VALUE;\n case lotteryCategories.IS_INSTANT_LOTTERY:\n return INSTANT_PRIZE_DEFAULT_VALUE;\n case lotteryCategories.IS_PARTICIPANT_LOTTERY:\n default:\n return PARTICIPANT_PRIZE_DEFAULT_VALUE;\n }\n })(lotteryCategory);\n return lotteryType;\n}\n\nexport function getActivePrizeTabByCategory(lotteryCategory) {\n const lotteryType = (category => {\n switch (category) {\n case lotteryCategories.IS_ADMIN_LOTTERY:\n return prizeTabPanelIds.lotteryPrizeManageTab;\n case lotteryCategories.IS_INSTANT_LOTTERY:\n return prizeTabPanelIds.instantPrizeManageTab;\n case lotteryCategories.IS_PARTICIPANT_LOTTERY:\n default:\n return prizeTabPanelIds.participantPrizeManageTab;\n }\n })(lotteryCategory);\n return lotteryType;\n}\n\nexport function getShouldExpandTabIndex(lotteryCategory) {\n const tabIndex = defaultSelectableLotteryTypesList.findIndex(c => c === lotteryCategory);\n return tabIndex;\n}\n\nexport const getDefaultTab = lotteryCategory => getActivePrizeTabByCategory(lotteryCategory);\n\n// 檢查目前 Share LOTTERY 跟 primary LOTTERY 有無共用獎池, 代表會顯示 共用獎項 Chip\nexport const checkCurrentLotteryIsBindingPrimaryLottery = (\n lotteryCategory,\n isPrimaryLotteryInstantSharing,\n isPrimaryLotteryParticipantSharing\n) => {\n if (lotteryCategory === lotteryCategories.IS_INSTANT_LOTTERY) {\n return isPrimaryLotteryInstantSharing;\n }\n\n if (lotteryCategory === lotteryCategories.IS_PARTICIPANT_LOTTERY) {\n return isPrimaryLotteryParticipantSharing;\n }\n\n return false;\n};\n\n// 抽獎不會有共用獎池設定,故不加上\nexport const getExistEnableBindingPrimaryLottery = (\n primaryLotteryInstant = {},\n primaryLotteryParticipant = {}\n) =>\n [primaryLotteryInstant, primaryLotteryParticipant].filter(\n lottery => Object.keys(lottery).length > 0\n );\n\n// 所有配獎動畫的 tab panel, 要對應 prizeType \b才可以在不同配獎模式的動畫編輯處正常切換,不然會一直出現上一個編輯動畫的 panel\nexport const gameDesignTabPanels = {\n participantPrizeDesignScratchCardTab: {\n id: 'participantPrize_design_scratch_card',\n label: 'label.scratch_card_design',\n lotteryType: sketchPrize.value\n },\n participantPrizeDesignWinWheelTab: {\n id: 'participantPrize_design_Winwheel',\n label: 'label.win_wheel_design',\n lotteryType: winWheelPrize.value\n },\n participantPrizeDesignPokeGameTab: {\n id: 'participantPrize_design_poke_game',\n label: 'label.poke_game_design',\n lotteryType: pokeGamePrize.value\n },\n participantPrizeDesignRedEnvelopeRainTab: {\n id: 'participantPrize_design_red_envelope_rain',\n label: 'label.red_envelope_rain_design',\n lotteryType: redEnvelopeRainPrize.value\n },\n participantPrizeDesignSlotsTab: {\n id: 'participantPrize_design_slots',\n label: 'label.slots_design',\n lotteryType: slotsPrize.value\n },\n participantPrizeDesignPickThePrizeTab: {\n id: 'participantPrize_design_pick_the_prize',\n label: 'label.pick_the_prize_design',\n lotteryType: pickThePrizePrize.value\n },\n participantPrizeDesignPointsRedeemTab: {\n id: 'participantPrize_design_points_redeem',\n label: 'label.points_redeem_design',\n lotteryType: pointsRedeemPrize.value\n }\n};\n\nexport function isGameDesignLotteryType(type) {\n return Object.entries(gameDesignTabPanels).some(([, tab]) => tab.lotteryType === type);\n}\n\n// 各個對應的 tab panel id\nexport const prizeTabPanelIds = {\n participantPrizeManageTab: 'participantPrize_manage',\n participantPrizeRuleTab: 'participantPrize_rule',\n lotteryPrizeManageTab: 'lotteryPrize_manage',\n lotteryPrizeRuleTab: 'lotteryPrize_rule',\n instantPrizeManageTab: 'instantPrize_manage',\n instantPrizeRuleTab: 'instantPrize_rule',\n prizeRelatedSettingTab: 'prize_related_setting',\n responseFormTab: 'responseForm',\n lotteryTaskPrizeDesignPickThePrizeTab: 'lotteryTaskPrizeDesignTab',\n ...fromEntries(Object.entries(gameDesignTabPanels).map(([key, tab]) => [key, tab.id]))\n};\n\nexport const INSTANT_PRIZE_DEFAULT_VALUE = participantPrize.value;\nexport const ADMIN_PRIZE_DEFAULT_VALUE = adminPrize.value;\nexport const PARTICIPANT_PRIZE_DEFAULT_VALUE = sketchPrize.value;\n\nexport const prizeTabTypes = {\n UGC_TAB_INDEX: 0,\n VOTE_TAB_INDEX: 1,\n PRIZE_TAB_INDEX: 2,\n TASK_TAB_INDEX: 3,\n CHECK_IN_TAB_INDEX: 4,\n SHARE_INVITE_TAB_INDEX: 5,\n SHARE_SPECIFY_TAB_INDEX: 6,\n PRIZE_SETTINGS: 7\n};\n","import React, { useMemo } from 'react';\nimport PropTypes from 'prop-types';\nimport i18n from 'i18next';\nimport { css } from '@emotion/core';\nimport Select from '@material-ui/core/Select';\nimport MenuItem from '@material-ui/core/MenuItem';\n\nexport const modes = {\n DAY: 1,\n WEEK: 2\n};\n\nconst listConfig = [\n { label: () => i18n.t('label.period_play.mode.day'), value: modes.DAY },\n { label: () => i18n.t('label.period_play.mode.week'), value: modes.WEEK }\n];\n\nexport default function PeriodPlayModeSelector({ value, onChange, style, disabled }) {\n const lists = useMemo(\n () =>\n listConfig.map(t => (\n \n {t.label()}\n \n )),\n []\n );\n return (\n {\n const { value } = e.target;\n onChange(value);\n }}\n variant=\"outlined\"\n disabled={disabled}\n fullWidth\n >\n {lists}\n \n );\n}\n\nPeriodPlayModeSelector.propTypes = {\n style: PropTypes.oneOfType([PropTypes.object, PropTypes.string]),\n value: PropTypes.number,\n onChange: PropTypes.func,\n disabled: PropTypes.bool\n};\n\nconst selectorStyle = css`\n background-color: #fff;\n font-size: 14px;\n & .MuiSelect-root {\n padding-top: 10px;\n padding-bottom: 10px;\n }\n & fieldset {\n border: none;\n }\n`;\n","import dayjs from 'dayjs';\n\nimport i18n from 'i18next';\n\nimport { modes } from 'editor/components/SideBar/Qualify/limitPlayTimes/periodPlay/PeriodPlayModeSelector';\nimport { timezoneList } from 'config/timezone';\n\nexport function periodTimeUtcToTimeZone(timezone, timeArrays) {\n const offset =\n timezoneList.find(tz => String(tz.tzCode).toLowerCase() === String(timezone).toLowerCase())\n ?.utc || '+00:00';\n const method = offset[0] === '+' ? (a, b) => a + b : (a, b) => a - b;\n return offsetHandler(offset, timeArrays, method);\n}\n\nexport function periodTimeTimezoneToUtc(timezone, timeArrays = []) {\n const offset =\n timezoneList.find(tz => String(tz.tzCode).toLowerCase() === String(timezone).toLowerCase())\n ?.utc || '+00:00';\n const method = offset[0] === '+' ? (a, b) => a - b : (a, b) => a + b;\n return offsetHandler(offset, timeArrays, method);\n}\n\nexport function offsetHandler(offset, timeArrays = [], calcMethod) {\n return timeArrays.map(t => {\n const obj = { start: { ...t.start }, end: { ...t.end } };\n const start = calculateOffset(offset, t.start.time, calcMethod);\n const end = calculateOffset(offset, t.end.time, calcMethod);\n obj.start.time = trimSecond(start.timeStr);\n obj.end.time = trimSecond(end.timeStr);\n if (obj.start.weekday) {\n obj.start.weekday = clampWeekDay(obj.start.weekday + start.dayoffset);\n }\n if (obj.end.weekday) {\n obj.end.weekday = clampWeekDay(obj.end.weekday + end.dayoffset);\n }\n return obj;\n });\n}\n\nexport function calculateOffset(offset, timeStr, calcMethod) {\n const offsetHour = offset.substring(1, 3);\n const offsetMin = offset.substring(4, 6);\n const timeHour = timeStr.substring(0, 2);\n const timeMin = timeStr.substring(3, 5);\n const timeSec = timeStr.substring(6, 8);\n\n let timeMinWithOffset = calcMethod(Number(timeMin), Number(offsetMin));\n const minCauseHourOffset = (() => {\n if (timeMinWithOffset > 59) return 1;\n else if (timeMinWithOffset < 0) return -1;\n else return 0;\n })();\n\n let timeHourWithOffset = calcMethod(Number(timeHour), Number(offsetHour)) + minCauseHourOffset;\n\n const dayoffset = (() => {\n if (timeHourWithOffset < 0) return -1;\n else if (timeHourWithOffset / 24 >= 1) return 1;\n else return 0;\n })();\n\n timeHourWithOffset = timeHourWithOffset < 0 ? timeHourWithOffset + 24 : timeHourWithOffset % 24;\n timeMinWithOffset = timeMinWithOffset < 0 ? timeMinWithOffset + 60 : timeMinWithOffset % 60;\n\n return {\n timeStr: `${String(timeHourWithOffset).padStart(2, '0')}:${String(\n timeMinWithOffset\n ).padStart(2, '0')}${Boolean(timeSec) ? `:${timeSec}` : ''}`,\n dayoffset\n };\n}\n\nfunction trimSecond(timeStr) {\n return `${timeStr.substring(0, 5)}:00`;\n}\n\nfunction clampWeekDay(weekday) {\n if (weekday > 7) {\n return 1;\n } else if (weekday < 1) {\n return 7;\n } else {\n return weekday;\n }\n}\n\nexport function hasNotPlayedInPeriod({ rangeStart, rangeEnd, current, lastEntries } = {}) {\n return (\n rangeStart <= current &&\n current <= rangeEnd &&\n !(rangeStart <= lastEntries && lastEntries <= rangeEnd)\n );\n}\n\nexport function generatePeriodTimeMatchInfo(\n isPeriodPlayMode,\n { timezone, mode = modes.DAY, periodTimes = [] } = {}\n) {\n if (!isPeriodPlayMode) {\n return {\n match: true,\n periodStartInTZ: '',\n periodEndInTZ: '',\n currentInTZ: ''\n };\n }\n\n const currentInTimezone = dayjs().tz(timezone);\n const currentInTimezoneDate = currentInTimezone.format('YYYY-MM-DD');\n const currentInTimezoneTime = currentInTimezone.format('HH:mm:ss');\n const periodTimeInTimeZone = periodTimeUtcToTimeZone(timezone, JSON.parse(periodTimes));\n const currentInTZ = `${currentInTimezoneDate} ${currentInTimezoneTime}`;\n\n if (mode === modes.DAY) {\n const matchedPeriod = periodTimeInTimeZone.find(\n ({ start, end }) =>\n currentInTimezoneTime >= start.time && currentInTimezoneTime < end.time\n );\n if (matchedPeriod) {\n return {\n match: true,\n periodStartInTZ: `${currentInTimezoneDate} ${matchedPeriod.start.time}`,\n periodEndInTZ: `${currentInTimezoneDate} ${matchedPeriod.end.time}`,\n currentInTZ\n };\n }\n } else if (mode === modes.WEEK) {\n const currentInTimezoneWeekDay = currentInTimezone.isoWeekday();\n const matchedPeriod = periodTimeInTimeZone.find(({ start, end }) => {\n const isSpanWeek = start.weekday > end.weekday;\n const isWeekdayInRange = isSpanWeek\n ? !(\n end.weekday < currentInTimezoneWeekDay &&\n currentInTimezoneWeekDay < start.weekday\n )\n : start.weekday <= currentInTimezoneWeekDay &&\n currentInTimezoneWeekDay <= end.weekday;\n const isTimeInRange =\n (currentInTimezoneWeekDay !== start.weekday ||\n currentInTimezoneTime >= start.time) &&\n (currentInTimezoneWeekDay !== end.weekday || currentInTimezoneTime < end.time);\n return isWeekdayInRange && isTimeInRange;\n });\n\n if (matchedPeriod) {\n const startWeekdayOffset = (() => {\n const o = currentInTimezoneWeekDay - matchedPeriod.start.weekday;\n return o < 0 ? o + 7 : o;\n })();\n const endWeekdayOffset = (() => {\n const o = matchedPeriod.end.weekday - currentInTimezoneWeekDay;\n return o < 0 ? o + 7 : o;\n })();\n const periodStartInTZ = `${currentInTimezone\n .subtract(startWeekdayOffset, 'day')\n .format('YYYY-MM-DD')} ${matchedPeriod.start.time}`;\n const periodEndInTZ = `${currentInTimezone\n .add(endWeekdayOffset, 'day')\n .format('YYYY-MM-DD')} ${matchedPeriod.end.time}`;\n\n return {\n match: true,\n periodStartInTZ,\n periodEndInTZ,\n currentInTZ\n };\n }\n }\n\n return { match: false, periodStartInTZ: '', periodEndInTZ: '', currentInTZ };\n}\n\nexport const errorMessage = {\n EMPTY: () => i18n.t('label.period_play.error.required'),\n SMALLER_END_DATE: () => i18n.t('label.period_play.error.smaller_end'),\n OVERLAP_PERIOD: () => i18n.t('label.period_play.error.overlap'),\n EXCEED_WEEK_PERIOD: () => i18n.t('label.period_play.error.exceed_week')\n};\n\nexport function isOverLapTime(a, b) {\n return a?.start?.time < b?.end?.time && b?.start?.time < a?.end?.time;\n}\n\nexport function checkEmptyDatetimeError(datetimeArray = []) {\n let hasEmptyError = false;\n let errorObj = {};\n datetimeArray.forEach((t, index) => {\n errorObj[index] = {};\n if (t.start.time === null) {\n hasEmptyError = true;\n errorObj[index].start = true;\n }\n if (t.end.time === null) {\n hasEmptyError = true;\n errorObj[index].end = true;\n }\n });\n if (hasEmptyError) {\n return {\n message: errorMessage.EMPTY(),\n items: errorObj\n };\n }\n}\n\nexport function checkSmallerEndDateError(datetimeArray = []) {\n let hasInvalidPeriodError = false;\n let errorObj = {};\n datetimeArray.forEach((t, index) => {\n if (t.start.time >= t.end.time) {\n hasInvalidPeriodError = true;\n errorObj[index] = { start: true, end: true };\n }\n });\n if (hasInvalidPeriodError) {\n return {\n message: errorMessage.SMALLER_END_DATE(),\n items: errorObj\n };\n }\n}\n\nexport function checkOverlapPeriodError(datetimeArray = []) {\n let hasOverLapError = false;\n let errorObj = {};\n for (let [i, t] of datetimeArray.entries()) {\n for (let [j, otherT] of datetimeArray.entries()) {\n if (i !== j) {\n if (isOverLapTime(t, otherT)) {\n hasOverLapError = true;\n errorObj[i] = { start: true, end: true };\n errorObj[j] = { start: true, end: true };\n break;\n }\n }\n }\n }\n if (hasOverLapError) {\n return {\n message: errorMessage.OVERLAP_PERIOD(),\n items: errorObj\n };\n }\n}\n\nexport function checkExceedWeekPeriodError(datetimeArray = []) {\n let hasExceedWeekPeriodError = false;\n let errorObj = {};\n datetimeArray.forEach((t, index) => {\n if (t.start.weekday === t.end.weekday && t.end.time >= t.start.time) {\n hasExceedWeekPeriodError = true;\n errorObj[index] = { start: true, end: true };\n }\n });\n if (hasExceedWeekPeriodError) {\n return {\n message: errorMessage.EXCEED_WEEK_PERIOD(),\n items: errorObj\n };\n }\n}\n","import { bgTypes } from 'styles/generateBgStyleByType';\nimport { system100, white, black } from 'Mui/styles/color';\n\n/**\n * 好禮自由選設計 - 主視覺\n * isShowKeyVision: boolean 顯示主視覺\n * isUseCustomKeyVision: boolean 使用主視覺圖片網址\n * bgType: 主視覺背景類型 ( 1 : 顏色 / 2 : 圖片 / 3 : 文字+背景 )\n * customImgUrl: 自訂背景圖片 url (電腦)\n * customMobileImgUrl 自訂背景圖片 url (手機)\n **/\n\nexport const defaultKeyVisionConfig = {\n isShowKeyVision: true,\n isUseCustomKeyVision: false,\n bgType: bgTypes.FROALA,\n customImgUrl: 'https://assets.fevercdn.com/promotion/img/PickThePrize_Keyvisual_Template.jpg',\n customMobileImgUrl:\n 'https://assets.fevercdn.com/promotion/img/PickThePrize_Keyvisual_Template.jpg'\n};\n\n/**\n * 好禮自由選設計 - 獎品樣式\n * type: \"image\"(純圖片), \"text\"(純文字), \"both\"(圖片 & 文字)\n * isShowCaption: boolean 顯示獎品說明\n * colorText: string 文字顏色\n * colorBg: string 背景顏色\n **/\nexport const DISPLAY_IMAGE_TEXT = 'both';\nexport const DISPLAY_TEXT = 'text';\nexport const DISPLAY_IMAGE = 'image';\nexport const defaultPrizeCardStyleConfig = {\n type: DISPLAY_IMAGE_TEXT,\n isShowCaption: true,\n colorText: black.color,\n colorBg: white.color\n};\n\nexport const CARD_GAP_SIZE = 8;\n\n/**\n * 好禮自由選設計 - 獎品順序\n * prizesOrder: Prize[]\n **/\nexport const defaultPrizeOrderConfig = {\n prizesOrder: []\n};\n\n/**\n * 好禮自由選設計 - 排列方式\n * desktop: x1, x2, x3, x4\n * mobile: x1, x2\n **/\nexport const defaultPrizeCardLayoutConfig = {\n desktop: 4,\n mobile: 2\n};\n\n/**\n * 好禮自由選設計 - 領取取品按鈕\n * color: string 按鈕文字顏色\n * colorBg: string 按鈕背景顏色\n * isUseCustomImg: boolean 自訂樣式\n * customImgUrl: string 按鈕圖片\n **/\nexport const defaultActionButtonConfig = {\n color: white.color,\n colorBg: black.color,\n isUseCustomImg: false,\n customImgUrl: ''\n};\n\n/**\n * 好禮自由選設計 - 背景\n * colorBg: string 背景顏色\n * isUseCustomImg: boolean 自訂樣式\n * customImgUrl: string 背景圖片\n **/\nexport const defaultBgStyleConfig = {\n colorBg: system100.color,\n isUseCustomImg: false,\n customImgUrl: ''\n};\n\nexport const defaultAnimationSetting = {\n keyVision: defaultKeyVisionConfig,\n prizeCardLayout: defaultPrizeCardStyleConfig,\n prizeCardOrder: defaultPrizeOrderConfig,\n prizeCardStyle: defaultPrizeCardLayoutConfig,\n button: defaultActionButtonConfig,\n BackgroundStyle: defaultBgStyleConfig\n};\n","import i18next from 'i18next';\nimport { i18nLangOfGame } from 'locale/i18n';\nimport { bgTypes } from 'styles/generateBgStyleByType';\nimport { fever500, warning, system900, system100, white } from 'Mui/styles/color';\nimport { IS_EDITOR_MODE } from 'config/envVariable';\n/**\n * 點數兌獎設計 - 主視覺\n * isShowKeyVision: boolean 顯示主視覺\n * isUseCustomKeyVision: boolean 使用主視覺圖片網址\n * customImgUrl: 自訂背景圖片 url (電腦)\n * customMobileImgUrl 自訂背景圖片 url (手機)\n * bgType: 主視覺背景類型 ( 1 : 顏色 / 2 : 圖片 / 3 : 文字+背景 )\n * colorBg: string 背景顏色\n * froalaEditor: string 主視覺上的 html code 組成的文字\n **/\n\nconst translate = i18nKey => (IS_EDITOR_MODE ? i18nLangOfGame.t(i18nKey) : i18next.t(i18nKey));\nexport const defaultKeyVisionConfig = {\n isShowKeyVision: true,\n isUseCustomKeyVision: false,\n bgType: bgTypes.FROALA,\n colorBg: warning.color,\n customImgUrl: '',\n customMobileImgUrl: '',\n froalaEditor: `

${translate(\n 'label.game_type_points_redeem'\n )}

`\n};\n\n/**\n * 點數兌獎設計 - 獎品樣式\n * colorText: string 文字顏色\n * colorBg: string 背景顏色\n * colorButtonText: string 按鈕文字顏色\n * colorButtonBg: string 按鈕背景顏色\n **/\n\nexport const defaultPrizeCardStyleConfig = {\n colorText: system900.color,\n colorBg: warning.color,\n colorButtonText: white.color,\n colorButtonBg: fever500.color\n};\n\nexport const CARD_GAP_SIZE = 8;\n\n/**\n * 點數兌獎設計/好禮自由選設計 - 獎品順序\n * prizesOrder: Prize[]\n **/\nexport const defaultPrizeOrderConfig = {\n prizesOrder: []\n};\n\n/**\n * 點數兌獎設計/好禮自由選設計 - 排列方式\n * desktop: x1, x2, x3, x4\n * mobile: x1, x2\n **/\nexport const defaultPrizeCardLayoutConfig = {\n desktop: 4,\n mobile: 2\n};\n\n/**\n * 點數兌獎設計/好禮自由選設計 - 背景\n * colorBg: string 背景顏色\n * isUseCustomImg: boolean 自訂樣式\n * customImgUrl: string 背景圖片\n **/\nexport const defaultBgStyleConfig = {\n colorBg: system100.color,\n isUseCustomImg: false,\n customImgUrl: ''\n};\n\nexport const defaultAnimationSetting = {\n keyVision: defaultKeyVisionConfig,\n prizeCardLayout: defaultPrizeCardStyleConfig,\n prizeCardOrder: defaultPrizeOrderConfig,\n prizeCardStyle: defaultPrizeCardLayoutConfig,\n BackgroundStyle: defaultBgStyleConfig\n};\n","import { css } from '@emotion/core';\nimport Color from 'color';\n\nimport { lightenDarkenColor, adjustColorAlpha } from 'utils/colorConvert';\nimport { feverShake } from 'styles/keyframes';\n\nexport const btnVariants = {\n FILLED: 'filled',\n OUTLINED: 'outlined',\n TEXT: 'text'\n};\n\nexport function getColorRGBA(color) {\n try {\n return Color(color).rgb().object();\n } catch (error) {\n console.log(error);\n return {};\n }\n}\n\nexport const getShakeAnimationStyle = () => css`\n animation: ${feverShake} 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;\n animation-delay: 0s;\n transition-delay: 0s;\n`;\n\nexport const absolutePositionCenterStyle = `\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n margin: auto;\n`;\n\nexport const preventMarginCollapse = `\n &:before {\n display: table;\n content: ' ';\n }\n &:after {\n display: table;\n content: ' ';\n }\n`;\n\nexport const containerShadow = `box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);`;\n\nexport const shadowLightStyle = `\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 1px -1px rgba(0, 0, 0, 0.12), 0 1px 1px 0 rgba(0, 0, 0, 0.14);\n`;\n\n// 使用演算法自動判斷按鈕背景顏色後決定顯示「白色」or「黑色」文字\nexport function getForegroundColor(color) {\n if (!color) {\n return '';\n }\n const { r = 0, g = 0, b = 0 } = getColorRGBA(color);\n const sum = Math.round((parseInt(r) * 299 + parseInt(g) * 587 + parseInt(b) * 114) / 1000);\n return sum > 128 ? 'black' : 'white';\n}\n\nexport const addHoverStyle = (styleObj = {}) => ({\n ...styleObj,\n ...(styleObj.backgroundColor\n ? {\n '&:hover': {\n backgroundColor: lightenDarkenColor(styleObj.backgroundColor, 0.1)\n }\n }\n : {})\n});\n\nexport const addOutlineBtnHoverStyle = color =>\n color\n ? {\n borderColor: color,\n '& *': {\n color\n },\n '&:hover': {\n borderColor: color,\n backgroundColor: adjustColorAlpha(color, 0.04)\n }\n }\n : {};\n\nexport const lineClampStyle = rowsMax => css`\n display: block; /* Fallback for non-webkit */\n display: -webkit-box;\n -webkit-line-clamp: ${rowsMax};\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: pre-wrap;\n`;\n\nexport const themedButtonStyle = (color, btnVariant = btnVariants.FILLED) => css`\n color: ${btnVariant === 'text' ? color : getForegroundColor(color)};\n background-color: ${btnVariant === 'text' ? 'transparent' : color};\n\n &:hover {\n background-color: ${btnVariant === 'text' ? 'transparent' : color};\n }\n`;\n","import { belowContain } from 'utils/breakpoint';\n\nexport const bgTypes = {\n COLOR: 1,\n IMG: 2,\n FROALA: 3\n};\n\nexport default function generateBgStyleByType({\n isFixedMode,\n type,\n imageUrl,\n mobileImgUrl,\n color = 'rgba(219,219,219,1)'\n}) {\n switch (type) {\n case bgTypes.IMG:\n return `\n background-color: ${color};\n ${imageUrl ? `background-image: url('${imageUrl}');` : ''}\n ${isFixedMode ? 'background-attachment: fixed;' : ''}\n background-repeat: no-repeat;\n background-position: center center;\n background-size: cover;\n ${\n mobileImgUrl\n ? `${belowContain('xsm')}{ background-image: url('${mobileImgUrl}'); }`\n : ''\n }\n `;\n case bgTypes.FROALA:\n return '';\n case bgTypes.COLOR:\n default:\n return `background-color: ${color};`;\n }\n}\n","import { keyframes } from '@emotion/core';\n\nexport const feverShake = keyframes`\n 10%, 90% {\n transform: translate3d(-1px, 0, 0)\n }\n 20%, 80% {\n transform: translate3d(2px, 0, 0)\n }\n 30%, 50%, 70% {\n transform: translate3d(-4px, 0, 0)\n }\n 40%, 60% {\n transform: translate3d(4px, 0, 0)\n }\n`;\n\nexport const feverBlink = keyframes`\n from, 20%, 60%, 90% {\n opacity: 0;\n }\n 10%, 50%, 70%, to {\n opacity: 1;\n }\n`;\n\nexport const feverZoomIn = keyframes`\n from {\n transform: scale(0);\n opacity: 0;\n }\n 50% {\n transform: scale(1.05);\n }\n 75% {\n transform: scale(0.95);\n }\n to {\n transform: scale(1);\n opacity: 1;\n }\n`;\n\nexport const feverZoomScale = keyframes`\n 0% {\n transform: scale(1);\n }\n 16.6% {\n transform: scale(1.05);\n }\n 33.2% {\n transform: scale(1);\n }\n 49.8% {\n transform: scale(1.05);\n }\n 66.4% {\n transform: scale(1);\n }\n 83.0% {\n transform: scale(1.05);\n }\n`;\n\nexport const feverSpin = keyframes`\n from {\n transform: rotate(0);\n }\n to{\n transform: rotate(359deg);\n }\n`;\n","import i18n from 'i18next';\nimport { black, white, functional, promo100, system050 } from 'Mui/styles/color';\nimport { froalaKeyVisionTypeMapping, coverImg } from 'components/KeyVision/config';\nimport { bgTypes } from 'styles/generateBgStyleByType';\n\n// Search Bar 下拉選單 => 無:0, 參加者:1, 作品標題:2\nexport const searchTypes = {\n NO_SEARCH: 0,\n AUTHOR_NAME: 1,\n PORTFOLIO_NAME: 2\n};\n\n// Tab 切換 => 作品集:1, 作品頁:2\nexport const PageType = {\n COLLECTIONS: 0,\n PORTFOLIO: 1\n};\n\n// 預設排列樣式 => 隨機:0, 排名:1, 參加時間:2\nexport const SortTypeMapping = {\n RANDOM: 0,\n RANK: 1,\n TIME: 2\n};\n// 圖片顯示方式 => 方形裁切:1, 原始比例:2\nexport const ImageShowTypeMapping = {\n ORIGIN: 1,\n SQUARE: 2\n};\n\n// 黑色:1,白色:2\nexport const MaskTypeMapping = {\n BLACK: 1,\n WHITE: 2\n};\n\n// 設計作品集 & 作品頁\nexport const ugcGameSetting = {\n // 功能列\n headerFunctionSettings: {\n defaultSortType: SortTypeMapping.RANDOM,\n defaultHomePageButtonText: i18n.t('lable.ugc.default_homepage_button_text'),\n textColor: black.color,\n bgColor: white.color\n },\n // 主視覺\n masterVisionSettings: {\n isShowKeyVision: true,\n defaultMainVisionType: froalaKeyVisionTypeMapping.COLOR,\n customImgUrl: coverImg.cover_ugc,\n customMobileImgUrl: coverImg.cover_ugc,\n bgType: bgTypes.FROALA,\n froalaEditor: `\n

\n \n \n \n \n \n

\n `,\n bgColor: '#003BBD'\n },\n // 作品卡片\n cardSettings: {\n defaultImgShowType: ImageShowTypeMapping.ORIGIN,\n // 顯示作品資訊\n isShowWorkInformation: true,\n textColor: black.color,\n bgColor: white.color,\n defaultMaskStyle: MaskTypeMapping.BLACK\n },\n // 主題\n topicSettings: {\n // 顯示投稿資訊\n isShowSubmitInformation: true,\n isShowVoteInformation: true,\n textColor: black.color,\n bgColor: system050.color\n },\n // 社群分享\n shareButtonSettings: {\n textColor: white.color,\n bgColor: functional.color,\n enableFacebookCommentsPlugin: true\n },\n // 投票按鈕\n voteButtonSettings: {\n textColor: white.color,\n bgColor: functional.color,\n borderColor: promo100.color\n }\n};\n","export const breakpoints = {\n xsm: 480,\n sm: 768,\n md: 1024,\n lg: 1200,\n xlg: 1440\n};\n\nexport const heightBreakpoints = {\n sm: 540\n};\n\nexport function getBreakpoint(size) {\n const breakpoint = breakpoints[size];\n if (!breakpoint) {\n console.error('Size not defined in default Breakpoints');\n }\n return breakpoint;\n}\n\nexport function above(size) {\n const breakpoint = getBreakpoint(size);\n return `@media screen and (min-width: ${breakpoint + 1}px)`;\n}\n\nexport function below(size) {\n const breakpoint = getBreakpoint(size);\n return `@media screen and (max-width: ${breakpoint - 1}px)`;\n}\n\nexport function belowContain(size) {\n const breakpoint = getBreakpoint(size);\n return `@media screen and (max-width: ${breakpoint}px)`;\n}\n\nexport function between(minSize, maxSize) {\n const minBreakpoint = getBreakpoint(minSize);\n const maxBreakpoint = getBreakpoint(maxSize);\n if (minBreakpoint > maxBreakpoint) {\n console.error('Breakpoint size incorrect');\n }\n return `\n @media screen and (min-width: ${minBreakpoint}px) and (max-width: ${maxBreakpoint - 1}px)`;\n}\n\nexport function getScreenOrientation() {\n if (window.innerHeight > window.innerWidth) return 'portrait';\n else return 'landscape';\n}\n","import Color from 'color';\n\nimport { isEmptyObject } from 'utils/objectManipulate';\n\nexport function getColorRGBA(color) {\n try {\n // Prevent empty string to parse\n if (!Boolean(color)) {\n return {};\n }\n const rgba = Color(color).rgb().object();\n if (rgba.alpha == null) {\n rgba.alpha = 1;\n }\n return rgba;\n } catch (error) {\n console.log(error);\n return {};\n }\n}\n\nexport function convertRGBtoRGBA(color, customAlpha) {\n const colorObj = getColorRGBA(color);\n if (!isEmptyObject(colorObj)) {\n const { r, g, b, alpha = 1 } = colorObj;\n return `rgba(${r}, ${g}, ${b}, ${customAlpha || alpha})`;\n }\n return color;\n}\n\nexport function adjustColorAlpha(color, transparent) {\n const colorObj = getColorRGBA(color);\n if (!isEmptyObject(colorObj)) {\n const { r, g, b, alpha = 1 } = colorObj;\n return `rgba(${r}, ${g}, ${b}, ${alpha * transparent})`;\n }\n return color;\n}\n\nexport function convertRGBAtoHEX(color) {\n try {\n return Color(color).hex();\n } catch (error) {\n return color;\n }\n}\n\nexport function validRGBAColor(value) {\n return /(rgb)a\\((\\d{1,3}%?,\\s?){3}(1|0?\\.\\d+)\\)/.test(value);\n}\n\nexport function isLightColor(color) {\n const { r = 0, g = 0, b = 0 } = getColorRGBA(color);\n const sum = Math.round((parseInt(r) * 299 + parseInt(g) * 587 + parseInt(b) * 114) / 1000);\n return sum > 128;\n}\n\nexport function getForegroundColor(color) {\n return isLightColor(color) ? '#000' : '#fff';\n}\n\nexport function lightenDarkenColor(color, amount, type = 'light') {\n try {\n if (!color) {\n return color;\n }\n const c = Color(color);\n return type === 'light' ? c.lighten(amount).hex() : c.darken(amount).hex();\n } catch (error) {\n console.log(error);\n return color;\n }\n}\n","import { timezoneList } from 'config/timezone';\nimport dayjs from 'dayjs';\n\nimport { calculateOffset } from 'editor/components/SideBar/Qualify/limitPlayTimes/periodPlay/utils';\n\nfunction getTimezoneOffset(timezone) {\n return (timezoneList.find(t => t.tzCode === timezone) || {}).utc || 'Z';\n}\n\nexport function utcDTStr2UTC(dateStr = '') {\n return new Date(`${dateStr.replace(/\\s/, 'T')}Z`).getTime();\n}\n\n// dayjs 在轉換成某時區的日期時間是貌似會被 DST 影響,目前 github issue 有好些這問題有關\n// issue 見:https://github.com/iamkun/dayjs/issues?q=is%3Aissue+is%3Aopen+timezone\n// 目前先以暴力計算方式解決\nexport function utcDTStr2TimezoneDTStr(dateStr = '', timezone, format = 'YYYY-MM-DD HH:mm:ss') {\n const [date = '', time = ''] = dateStr.split(' ');\n const offset =\n timezoneList.find(tz => String(tz.tzCode).toLowerCase() === String(timezone).toLowerCase())\n ?.utc || '+00:00';\n const method = offset[0] === '+' ? (a, b) => a + b : (a, b) => a - b;\n const { timeStr, dayoffset } = calculateOffset(offset, time, method);\n const timezoneDate = (dayoffset < 0\n ? dayjs(date).subtract(Math.abs(dayoffset), 'day')\n : dayjs(date).add(Math.abs(dayoffset), 'day')\n ).format('YYYY-MM-DD');\n\n return dayjs(`${timezoneDate} ${timeStr}`).format(format);\n // return utc2TimezoneDTStr(utcDTStr2UTC(dateStr), timezone, format);\n}\n\nexport function utc2TimezoneDTStr(timeStamp, timezone, format = 'YYYY-MM-DD HH:mm:ss') {\n return dayjs(timeStamp).tz(timezone).format(format);\n}\n\nexport function utcDTStr2LocalDTStr(dateStr = '', format) {\n return getDateTimeStr(`${dateStr.replace(/\\s/, 'T')}Z`, format);\n}\n\nexport function getCurrentUtcDTStr() {\n return new Date().toISOString().replace('T', ' ').split('.')[0];\n}\n\nexport function getCurrentUtcDateStr() {\n return new Date().toISOString().split('T')[0];\n}\n\n/**\n * 判斷 UTC 日期是否在現在之後\n * @param {String} dateStr - UTC 日期字串\n * @returns {Boolean} 是否在現在之後\n */\nexport function isUtcDateAfterNow(dateStr) {\n return dayjs(dateStr).isAfter(dayjs(), 'day');\n}\n\nexport function timezoneDTStr2UTC(dateStr = '', timezone) {\n const tzOffset = getTimezoneOffset(timezone);\n return new Date(`${dateStr.replace(/\\s/, 'T')}${tzOffset}`).getTime();\n}\n\nexport function timezoneDTStr2UtcDTStr(dateStr, timezone) {\n return timeStamp2UtcDtStr(timezoneDTStr2UTC(dateStr, timezone));\n}\n\nexport function timeStamp2UtcDtStr(timestamp) {\n const [str] = new Date(timestamp).toISOString().split('.');\n return str.replace('T', ' ');\n}\n\nexport function timezoneDTStr2LocalDTStr(dateStr = '', timezone, format) {\n const tzOffset = getTimezoneOffset(timezone);\n return getDateTimeStr(`${dateStr.replace(/\\s/, 'T')}${tzOffset}`, format);\n}\n\nexport function getDayRange(date1, date2) {\n const d1 = dayjs(date1);\n return Math.abs(d1.diff(date2, 'day'));\n}\n\nexport function hasUtcDTStartInLocal(startDate) {\n return Date.now() >= utcDTStr2UTC(startDate);\n}\n\nexport function hasUtcDTEndInLocal(endDate) {\n return Date.now() >= utcDTStr2UTC(endDate);\n}\n\nexport function getLocalTimezone() {\n return dayjs.tz.guess();\n}\n\nexport function getDateTimeStr(dateData, format = 'YYYY-MM-DD HH:mm:ss') {\n return dayjs(dateData).format(format);\n}\n\nexport function dateTimeStrIsLocalToday(dateStr) {\n return dayjs(timezoneDTStr2UTC(dateStr)).isToday();\n}\n\nexport function isLocalSameDateInPromoTimezone(dateStr, timezone) {\n const dateStrInPromoTimezone = utcDTStr2TimezoneDTStr(dateStr, timezone, 'YYYY-MM-DD');\n const localDateStrInPromoTimezone = utcDTStr2TimezoneDTStr(\n getCurrentUtcDTStr(),\n timezone,\n 'YYYY-MM-DD'\n );\n return dateStrInPromoTimezone === localDateStrInPromoTimezone;\n}\n\nexport function removeSecondsFromDTStr(dateStr) {\n return dayjs(dateStr).format('YYYY-MM-DD HH:mm');\n}\n\nexport function isBefore(a, b) {\n return dayjs(a).isBefore(dayjs(b));\n}\n\nexport function UTC_toLocalTime(timeString, format) {\n if (format) return dayjs(timeString).utc(true).local().format(format);\n return dayjs(timeString).utc(true).local();\n}\n","/**\n * 檢查或取代斜線\n * @typedef {Object} filterSlash\n * @property {string} text - 檢查的字串\n * @property {boolean} isReplace - 是否要取代\n * @property {string} replaceText - 取代後的問字\n * @returns {boolean|string} 若只有檢查返回布林值 ( 有斜線返回 true ),若有取代返回字串\n */\nexport const filterSlash = (text = '', isReplace = false, replaceText = '') => {\n if (typeof text !== 'string') return false;\n const reg = /[/\\\\]+/g;\n\n if (isReplace) return text.replace(reg, replaceText);\n else {\n if (reg.test(text)) return true;\n else return false;\n }\n};\n\n/**\n * Filter out the keys with values that are undefined or null from the input object\n * @typedef {Object} filterUndefinedOrNull\n * @property {string} obj - 要過濾的的物件\n */\nexport const filterUndefinedOrNull = obj => {\n if (!obj || typeof obj !== 'object') return {};\n if (Object.keys(obj).length === 0) return obj;\n\n for (const key in obj) {\n if (obj[key] === undefined || obj[key] === null) {\n delete obj[key];\n }\n }\n return obj;\n};\n\n/**\n * To extract the UUID from a nested object structure\n */\nexport const extractUUIDs = obj => {\n const uuids = [];\n function traverse(o) {\n for (const key in o) {\n if (o.hasOwnProperty(key)) {\n if (key === 'uuid' && typeof o[key] === 'string') {\n uuids.push(o[key]);\n } else if (typeof o[key] === 'object' && o[key] !== null) {\n traverse(o[key]);\n }\n }\n }\n }\n traverse(obj);\n return uuids;\n};\n\n/**\n * 替換文本中的用戶名變量\n * @param {Object} params - 替換參數\n * @param {string} params.text - 要處理的文本\n * @param {string} params.variable - 變量名稱 (例如: \"username\")\n * @param {string} [params.data] - 要替換成的數據,若未提供則替換為空字符串\n * @param {boolean} [params.reverse=false] - 是否反向替換 (將 {{system:variable}} 替換為 @variable)\n * @returns {string} 替換後的文本\n */\nexport const replaceUsername = ({ text, variable, data, reverse = false }) => {\n if (reverse) text.replace(`{{system:${variable}}}`, `@${variable}`);\n return text.replace(`@${variable}`, data || '').replace(`{{system:${variable}}}`, data || '');\n};\n","/**\n * isMgmShare: 我是邀請模組\n * isMgmMission: 我是任務模組\n * isMgmSelf: 我有開分享獎(我既是邀請模組也是任務模組)\n */\nconst getMgmFlags = (mgmConfig = {}) => {\n const mgmMapping = Array.isArray(mgmConfig) ? mgmConfig : Object.entries(mgmConfig);\n const {\n mgmShare: isMgmShare = false,\n mgmMission: isMgmMission = false,\n mgmSelf: isMgmSelf = false\n } = mgmMapping.reduce((result, [k, v]) => {\n if (mgmConfig[k] && k === 'mgmRole') {\n return { ...result, [v]: true };\n }\n return { ...result, [v]: false };\n }, {});\n\n return { isMgmShare, isMgmMission, isMgmSelf };\n};\n\nexport default getMgmFlags;\n","function isLocalStorageEnable() {\n return navigator?.cookieEnabled && Boolean(window?.localStorage);\n}\n\nexport function setLocalStorage({ key, value }) {\n const item = {\n value\n };\n try {\n if (isLocalStorageEnable()) {\n localStorage.setItem(key, JSON.stringify(item));\n } else {\n console.log('Failed to access window local storage');\n }\n } catch (error) {\n if (error.name === 'NS_ERROR_FILE_CORRUPTED') {\n // Firefox browser error: https://stackoverflow.com/questions/18877643/error-in-local-storage-ns-error-file-corrupted-firefox\n console.log('Firefox storage has been corrupted when set local storage', error);\n } else {\n console.log('Failed to set local storage', error);\n }\n }\n\n return item;\n}\n\nexport const getLoginSeverKeyPutIntoLocalParams = () => ({\n key: 'isfirstPassLoginSever',\n value: 'isfirstPassLoginSever'\n});\n\nexport function getLocalStorage({ key }) {\n try {\n return isLocalStorageEnable() ? JSON.parse(localStorage.getItem(key)) : undefined;\n } catch (error) {\n if (error.name === 'NS_ERROR_FILE_CORRUPTED') {\n // Firefox browser error: https://stackoverflow.com/questions/18877643/error-in-local-storage-ns-error-file-corrupted-firefox\n console.log('Firefox storage has been corrupted when get local storage', error);\n } else {\n console.log('Failed to get local storage', error);\n }\n }\n}\n\nexport function deleteLocalStorage({ key }) {\n try {\n if (isLocalStorageEnable()) {\n localStorage.removeItem(key);\n }\n } catch (error) {\n if (error.name === 'NS_ERROR_FILE_CORRUPTED') {\n // Firefox browser error: https://stackoverflow.com/questions/18877643/error-in-local-storage-ns-error-file-corrupted-firefox\n console.log('Firefox storage has been corrupted when delete local storage', error);\n } else {\n console.log('Failed to delete local storage', error);\n }\n }\n}\n","const lineConfigKeys = ['lineLoginAppBotPrompt', 'lineLoginAppId', 'lineLoginAppLiffId'];\nexport function retrieveLineConfig({ partner = {}, sponsor = {} }) {\n const hasSponsorSiteConfig = Boolean(sponsor.lineLoginAppId);\n\n return lineConfigKeys.reduce((obj, key) => {\n const valInSponsor = sponsor[key];\n const valInPartner = partner[key];\n obj[key] = hasSponsorSiteConfig ? valInSponsor : valInPartner;\n return obj;\n }, {});\n}\n","import _merge from 'lodash/merge';\nimport _cloneDeep from 'lodash/cloneDeep';\nimport i18next from 'i18next';\nimport { i18nLangOfGame } from 'locale/i18n';\nimport { lotteryInstantTypes, lotteryParticipantTypes } from 'config/promoLotteryTypes';\nimport { system100, system900, fever500, warning, black, white } from 'Mui/styles/color';\n\nimport { DISPLAY_IMAGE_TEXT } from 'editor/game_pickThePrize/components/SettingPreviews/defaultGameSetting';\nimport { bgTypes } from 'styles/generateBgStyleByType';\nimport { froalaKeyVisionTypeMapping } from 'components/KeyVision/config';\nimport { IS_EDITOR_MODE } from 'config/envVariable';\n\nexport const getLotteryDefaultAnimationSettingValue = lotteryType => {\n const t = id => (IS_EDITOR_MODE ? i18nLangOfGame.t(id) : i18next.t(id));\n const config = {\n [lotteryInstantTypes.JOIN_AND_GET]: {},\n [lotteryParticipantTypes.SCRATCH_CARD]: {},\n [lotteryParticipantTypes.WIN_WHEEL]: {},\n [lotteryParticipantTypes.POKE_GAME]: {},\n [lotteryParticipantTypes.RED_ENVELOPE_RAIN]: {},\n [lotteryParticipantTypes.SLOTS]: {},\n [lotteryParticipantTypes.PICK_THE_PRIZE]: {\n /**\n * 點數兌獎設計 - 主視覺\n * isShowKeyVision: 是否顯示主視覺\n * defaultMainVisionType: 背景類型 ( 1 : 自訂背景 / 2 : 預設背景 )\n * bgType: 主視覺背景類型 ( 1 : 顏色 / 2 : 圖片 / 3 : 文字+背景 )\n * bgColor: 主視覺背景(顏色 / 文字+背景) 之 預設背景顏色\n * customImgUrl: 自訂背景圖片 url (電腦)\n * customMobileImgUrl 自訂背景圖片 url (手機)\n * froalaEditor: 主視覺背景(文字+背景) 之 Froala 編輯器內容\n **/\n keyVisionSettings: {\n isShowKeyVision: true,\n defaultMainVisionType: froalaKeyVisionTypeMapping.COLOR,\n bgType: bgTypes.FROALA,\n bgColor: 'rgba(0,67,216,1)',\n customImgUrl: '',\n customMobileImgUrl: '',\n froalaEditor: `

${t(\n 'label.game_type_pick_the_prize'\n )}

`\n },\n /**\n * 好禮自由選設計 - 獎品樣式\n * type: \"image\"(純圖片), \"text\"(純文字), \"both\"(圖片 & 文字)\n * isShowCaption: boolean 顯示獎品說明\n * textColor: string 文字顏色\n * bgColor: string 背景顏色\n **/\n prizeCardStyleSettings: {\n type: DISPLAY_IMAGE_TEXT,\n isShowCaption: true,\n textColor: black.color,\n bgColor: white.color,\n hintColor: black.color\n },\n\n /**\n * 好禮自由選設計 - 獎品順序\n * prizesOrder: Prize[]\n **/\n prizeCardOrderSettings: {\n prizesOrder: []\n },\n /**\n * 好禮自由選設計 - 排列方式\n * desktop: x1, x2, x3, x4\n * mobile: x1, x2\n **/\n prizeCardLayoutSettings: {\n desktop: 4,\n mobile: 2\n },\n /**\n * 好禮自由選設計 - 領取取品按鈕\n * color: string 按鈕文字顏色\n * bgColor: string 按鈕背景顏色\n * defaultBackgroundType: 自訂樣式 ( 1 : 自訂背景 / 2 : 預設背景 )\n * customImgUrl: string 按鈕圖片\n **/\n actionButtonSettings: {\n color: white.color,\n bgColor: black.color,\n defaultBackgroundType: froalaKeyVisionTypeMapping.COLOR,\n customImgUrl: ''\n },\n /**\n * 點數兌獎設計/好禮自由選設計 - 背景\n * bgColor: 背景顏色\n * defaultBackgroundType: 自訂樣式 ( 1 : 自訂背景 / 2 : 預設背景 )\n * customImgUrl: 背景圖片\n **/\n backgroundSettings: {\n bgColor: system100.color,\n defaultBackgroundType: froalaKeyVisionTypeMapping.COLOR,\n customImgUrl: ''\n }\n },\n [lotteryParticipantTypes.POINTS_REDEEM]: {\n /**\n * 點數兌獎設計 - 主視覺\n * isShowKeyVision: 是否顯示主視覺\n * defaultMainVisionType: 背景類型 ( 1 : 自訂背景 / 2 : 預設背景 )\n * bgType: 主視覺背景類型 ( 1 : 顏色 / 2 : 圖片 / 3 : 文字+背景 )\n * bgColor: 主視覺背景(顏色 / 文字+背景) 之 預設背景顏色\n * customImgUrl: 自訂背景圖片 url (電腦)\n * customMobileImgUrl 自訂背景圖片 url (手機)\n * froalaEditor: 主視覺背景(文字+背景) 之 Froala 編輯器內容\n **/\n keyVisionSettings: {\n isShowKeyVision: true,\n defaultMainVisionType: froalaKeyVisionTypeMapping.COLOR,\n bgType: bgTypes.FROALA,\n bgColor: warning.color,\n customImgUrl: '',\n customMobileImgUrl: '',\n froalaEditor: `

${t(\n 'label.game_type_points_redeem'\n )}

`\n },\n /**\n * 點數兌獎設計 - 獎品樣式\n * textColor: 文字顏色\n * bgColor: 背景顏色\n * buttonTextColor: 按鈕文字顏色\n * buttonBgColor: 按鈕背景顏色\n **/\n prizeCardStyleSettings: {\n textColor: system900.color,\n bgColor: warning.color,\n buttonTextColor: white.color,\n buttonBgColor: fever500.color\n },\n /**\n * 點數兌獎設計/好禮自由選設計 - 獎品順序\n * prizesOrder: Prize[]\n **/\n prizeCardOrderSettings: {\n prizesOrder: []\n },\n /**\n * 點數兌獎設計/好禮自由選設計 - 排列方式\n * desktop: x1, x2, x3, x4\n * mobile: x1, x2\n **/\n prizeCardLayoutSettings: {\n desktop: 4,\n mobile: 2\n },\n /**\n * 點數兌獎設計/好禮自由選設計 - 背景\n * bgColor: 背景顏色\n * defaultBackgroundType: 自訂樣式 ( 1 : 自訂背景 / 2 : 預設背景 )\n * customImgUrl: 背景圖片\n **/\n backgroundSettings: {\n bgColor: system100.color,\n defaultBackgroundType: froalaKeyVisionTypeMapping.COLOR,\n customImgUrl: ''\n }\n }\n };\n\n const defaults = {};\n return _merge(_cloneDeep(defaults), config[lotteryType] || {});\n};\n","import _isEmpty from 'lodash/isEmpty';\nimport { objFirstLevelJSONStringify } from 'utils/objectManipulate';\nimport { froalaKeyVisionTypeMapping } from 'components/KeyVision/config';\nimport { defaultAnimationSetting } from 'editor/game_pointsRedeem/components/SettingPreviews/defaultGameSetting';\n// import { getPromoDefaultSettingValue } from 'config/promoDefaultSettingValue';\nimport { getLotteryDefaultAnimationSettingValue } from 'config//lotteryDefaultAnimationSettingValue';\nimport { lotteryParticipantTypes } from 'config/promoLotteryTypes';\nimport { bgTypes } from 'styles/generateBgStyleByType';\nimport { fromEntries } from 'utils/core';\n\nexport default function parseAnimationSettings(settingData, lotteryType) {\n // 如果動畫設定值 (AnimationSettings) 有 key 但對應的 key 裡面是 undefined 或是動畫設定本身就是 undefined 就給空物件\n const isSettingDataValueUndefined = settingData\n ? Object.entries(settingData).some(([, value]) => typeof value === 'undefined')\n : true;\n // 如果動畫設定值 (AnimationSettings) 為空物件,則回傳空物件\n const isSettingDataEmpty = _isEmpty(settingData);\n\n // 如果 API animation setting 沒值,拿預設值 (mapping promo default setting value 的 settingGameStyle 到 animation setting)\n if (isSettingDataEmpty || isSettingDataValueUndefined)\n return getLotteryDefaultAnimationSettingValue(lotteryType) ?? {};\n\n // 後端有資料的話,值都會是字串儲存,所以要 parse\n const parsed = fromEntries(\n Object.entries(settingData).map(([key, value]) => {\n try {\n if (typeof value === 'string') {\n return [key, JSON.parse(value)];\n } else {\n return [key, value];\n }\n } catch (err) {\n return [key, {}];\n }\n })\n );\n\n // 用 keyVisionSettings 與 keyVision 確認是否是新版 AnimationSettings\n return parsed?.keyVisionSettings ? parsed : migratedAnimationSettings(parsed, lotteryType);\n}\n\nexport const stringifyAnimationSetting = settingData => {\n return objFirstLevelJSONStringify(settingData);\n};\n\nconst migratedAnimationSettings = (deprecatedSetting, lotteryType) => {\n const newSettings = getLotteryDefaultAnimationSettingValue(lotteryType);\n let animationSetting = {};\n if (Object.keys(newSettings).length > 0) {\n switch (lotteryType) {\n case lotteryParticipantTypes.PICK_THE_PRIZE:\n animationSetting = {\n keyVisionSettings: {\n ...newSettings.keyVisionSettings,\n isShowKeyVision:\n deprecatedSetting?.keyVisual?.isShowKeyVision ??\n deprecatedSetting?.keyVision?.isShowKeyVision ??\n newSettings.keyVisionSettings.isShowKeyVision,\n bgType: bgTypes.IMG,\n bgColor:\n deprecatedSetting?.keyVisual?.colorBg ??\n deprecatedSetting?.keyVision?.colorBg ??\n newSettings.keyVisionSettings.bgColor,\n defaultMainVisionType:\n deprecatedSetting?.keyVisual?.isUseCustomKeyVision ??\n deprecatedSetting?.keyVision?.isUseCustomKeyVision\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR,\n customImgUrl:\n deprecatedSetting?.keyVisual?.customImgUrl ??\n deprecatedSetting?.keyVision?.customImgUrl ??\n newSettings.keyVisionSettings.customImgUrl,\n customMobileImgUrl:\n deprecatedSetting?.keyVisual?.customImgUrl ??\n deprecatedSetting?.keyVision?.customImgUrl ??\n newSettings.keyVisionSettings.customMobileImgUrl\n },\n prizeCardStyleSettings: {\n ...newSettings.prizeCardStyleSettings,\n type:\n deprecatedSetting?.pickThePrizeCardStyle?.type ??\n newSettings.prizeCardStyleSettings.type,\n isShowCaption:\n deprecatedSetting?.pickThePrizeCardStyle?.isShowCaption ??\n newSettings.prizeCardStyleSettings.isShowCaption,\n textColor:\n deprecatedSetting?.pickThePrizeCardStyle?.colorText ??\n newSettings.prizeCardStyleSettings.textColor,\n bgColor:\n deprecatedSetting?.pickThePrizeCardStyle?.colorBg ??\n newSettings.prizeCardStyleSettings.bgColor\n },\n prizeCardOrderSettings: {\n ...newSettings.prizeCardOrderSettings,\n prizesOrder:\n deprecatedSetting?.prizeCardOrder?.prizesOrder ??\n newSettings.prizeCardOrderSettings.prizesOrder\n },\n prizeCardLayoutSettings: {\n ...newSettings.prizeCardLayoutSettings,\n ...(deprecatedSetting?.prizeCardLayout ??\n newSettings.prizeCardLayoutSettings)\n },\n actionButtonSettings: {\n ...newSettings.actionButtonSettings,\n color:\n deprecatedSetting?.button?.color ??\n newSettings.actionButtonSettings.color,\n bgColor:\n deprecatedSetting?.button?.colorBg ??\n newSettings.actionButtonSettings.bgColor,\n defaultBackgroundType: deprecatedSetting?.button?.isUseCustomImg\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR,\n customImgUrl:\n deprecatedSetting?.button?.customImgUrl ??\n newSettings.actionButtonSettings.bgColor\n },\n backgroundSettings: {\n ...newSettings.backgroundSettings,\n bgColor:\n deprecatedSetting?.BackgroundStyle?.colorBg ??\n newSettings.backgroundSettings.bgColor,\n defaultBackgroundType: deprecatedSetting?.BackgroundStyle?.isUseCustomImg\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR,\n customImgUrl:\n deprecatedSetting?.BackgroundStyle?.customImgUrl ??\n newSettings.backgroundSettings.customImgUrl\n }\n };\n break;\n case lotteryParticipantTypes.POINTS_REDEEM:\n animationSetting = {\n keyVisionSettings: {\n ...newSettings.keyVisionSettings,\n isShowKeyVision:\n deprecatedSetting?.keyVision?.isShowKeyVision ??\n newSettings.keyVisionSettings.isShowKeyVision,\n bgType: bgTypes.FROALA,\n bgColor:\n deprecatedSetting?.keyVision?.colorBg ??\n newSettings.keyVisionSettings.bgColor,\n defaultMainVisionType: deprecatedSetting?.keyVision?.isUseCustomKeyVision\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR,\n customImgUrl:\n deprecatedSetting?.keyVision?.customImgUrl ??\n newSettings.keyVisionSettings.customImgUrl,\n customMobileImgUrl:\n deprecatedSetting?.keyVision?.customImgUrl ??\n newSettings.keyVisionSettings.customMobileImgUrl,\n froalaEditor:\n deprecatedSetting?.keyVision?.froalaEditor ??\n newSettings.keyVisionSettings.froalaEditor\n },\n prizeCardStyleSettings: {\n ...newSettings.prizeCardStyleSettings,\n textColor:\n deprecatedSetting?.prizeCardStyle?.colorText ??\n newSettings.prizeCardStyleSettings.textColor,\n bgColor:\n deprecatedSetting?.prizeCardStyle?.colorBg ??\n newSettings.prizeCardStyleSettings.bgColor,\n buttonTextColor:\n deprecatedSetting?.prizeCardStyle?.colorButtonText ??\n newSettings.prizeCardStyleSettings.buttonTextColor,\n buttonBgColor:\n deprecatedSetting?.prizeCardStyle?.colorButtonBg ??\n newSettings.prizeCardStyleSettings.buttonBgColor\n },\n prizeCardOrderSettings: {\n ...newSettings.prizeCardOrderSettings,\n prizesOrder:\n deprecatedSetting?.prizeCardOrder?.prizesOrder ??\n newSettings.prizeCardOrderSettings.prizesOrder\n },\n prizeCardLayoutSettings: {\n ...newSettings.prizeCardLayoutSettings,\n ...(deprecatedSetting?.prizeCardLayout ??\n newSettings.prizeCardLayoutSettings)\n },\n backgroundSettings: {\n ...newSettings.backgroundSettings,\n bgColor:\n deprecatedSetting?.BackgroundStyle?.colorBg ??\n newSettings.backgroundSettings.bgColor,\n defaultBackgroundType: deprecatedSetting?.BackgroundStyle?.isUseCustomImg\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR,\n customImgUrl:\n deprecatedSetting?.BackgroundStyle?.customImgUrl ??\n newSettings.backgroundSettings.customImgUrl\n }\n };\n break;\n default:\n animationSetting = newSettings;\n }\n return animationSetting;\n }\n return deprecatedSetting;\n};\n\nexport const migrateAnimationSetting2SettingGameStyle = (\n promoDefaultSettingValue,\n AnimationSettings\n) => {\n const migratedDefaultValue = {\n ...promoDefaultSettingValue,\n settingGameStyle: {\n keyVisionSettings: {\n bgType:\n AnimationSettings?.keyVision?.bgType ??\n promoDefaultSettingValue.settingGameStyle?.keyVisionSettings?.bgType ??\n defaultAnimationSetting.keyVision.bgType,\n bgColor:\n AnimationSettings?.keyVision?.colorBg ??\n promoDefaultSettingValue.settingGameStyle.keyVisionSettings?.bgColor ??\n defaultAnimationSetting.keyVision.colorBg,\n customImgUrl:\n AnimationSettings?.keyVision?.customImgUrl ??\n promoDefaultSettingValue.settingGameStyle.settingGameStyle?.customImgUrl ??\n defaultAnimationSetting.keyVision.customImgUrl,\n customMobileImgUrl:\n AnimationSettings?.keyVision?.customMobileImgUrl ??\n promoDefaultSettingValue.settingGameStyle?.keyVisionSettings\n ?.customMobileImgUrl ??\n defaultAnimationSetting.keyVision.customMobileImgUrl,\n defaultMainVisionType:\n AnimationSettings?.keyVision?.isUseCustomKeyVision ??\n promoDefaultSettingValue.settingGameStyle.keyVisionSettings\n ?.defaultMainVisionType\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR,\n froalaEditor:\n AnimationSettings?.keyVision?.froalaEditor ??\n promoDefaultSettingValue.settingGameStyle.keyVisionSettings?.froalaEditor ??\n defaultAnimationSetting.keyVision.froalaEditor,\n isShowKeyVision:\n AnimationSettings?.keyVision?.isShowKeyVision ??\n promoDefaultSettingValue.settingGameStyle.keyVisionSettings?.isShowKeyVision ??\n defaultAnimationSetting.keyVision.isShowKeyVision\n },\n prizeCardStyleSettings: {\n textColor:\n AnimationSettings?.prizeCardStyle?.colorText ??\n promoDefaultSettingValue.settingGameStyle?.prizeCardStyleSettings?.textColor ??\n defaultAnimationSetting.prizeCardStyle.colorText,\n bgColor:\n AnimationSettings?.prizeCardStyle?.colorBg ??\n promoDefaultSettingValue.settingGameStyle?.prizeCardStyleSettings?.bgColor ??\n defaultAnimationSetting.prizeCardStyle.colorBg,\n buttonTextColor:\n AnimationSettings?.prizeCardStyle?.colorButtonText ??\n promoDefaultSettingValue.settingGameStyle?.prizeCardStyleSettings\n ?.buttonTextColor ??\n defaultAnimationSetting.prizeCardStyle.colorButtonText,\n buttonBgColor:\n AnimationSettings?.prizeCardStyle?.colorButtonBg ??\n promoDefaultSettingValue.settingGameStyle?.prizeCardStyleSettings\n ?.buttonBgColor ??\n defaultAnimationSetting.prizeCardStyle.colorButtonBg\n },\n prizeCardOrderSettings: {\n prizesOrder:\n AnimationSettings?.prizeCardOrder?.prizesOrder ??\n defaultAnimationSetting.defaultAnimationSetting.prizeCardOrder\n },\n prizeCardLayoutSettings:\n AnimationSettings?.prizeCardLayout ??\n defaultAnimationSetting.defaultAnimationSetting.prizeCardLayout,\n backgroundSettings: {\n bgColor:\n AnimationSettings?.BackgroundStyle?.colorBg ??\n promoDefaultSettingValue.settingGameStyle?.backgroundSettings?.bgColor ??\n defaultAnimationSetting.BackgroundStyle.colorBg,\n customImgUrl:\n AnimationSettings?.BackgroundStyle?.customImgUrl ??\n promoDefaultSettingValue.settingGameStyle?.backgroundSettings?.customImgUrl ??\n defaultAnimationSetting.BackgroundStyle.customImgUrl,\n defaultBackgroundType: AnimationSettings?.BackgroundStyle?.isUseCustomImg\n ? froalaKeyVisionTypeMapping.IMAGE\n : froalaKeyVisionTypeMapping.COLOR\n }\n }\n };\n return migratedDefaultValue;\n};\n","import PropTypes from 'prop-types';\n\nexport const stylePropType = PropTypes.oneOfType([\n PropTypes.object,\n PropTypes.string,\n PropTypes.array\n]);\nexport const btnPropType = PropTypes.shape({\n backgroundColor: PropTypes.string,\n border: PropTypes.string,\n color: PropTypes.string\n});\n\nexport const childrenPropType = PropTypes.oneOfType([PropTypes.node, PropTypes.func]);\nexport const componentStylePropTypes = PropTypes.shape({\n contentBgColor: PropTypes.string,\n contentBorderRadius: PropTypes.number,\n titleFontWeight: PropTypes.number,\n titleColor: PropTypes.string,\n descColor: PropTypes.string,\n answerColor: PropTypes.string,\n optionColor: PropTypes.string,\n optionLabelColor: PropTypes.string,\n buttonColor: PropTypes.string,\n buttonLabelColor: PropTypes.string,\n buttonSize: PropTypes.string\n});\n"],"names":["useStyles","makeStyles","button","padding","props","variant","boxShadow","textTransform","_ref","forwardRef","disabled","children","startIcon","endIcon","className","color","onClick","disableAllRipple","href","target","size","restProps","classes","___EmotionJSX","MuiButton","_extends","ref","clsx","disableRipple","disableFocusRipple","disableTouchRipple","name","styles","ButtonWithLoadingEffect","_ref2","isLoading","Button","css","CircularProgress","absolutePositionCenterStyle","dp01","dp02","dp03","dp04","dp06","dp07","dp08","dp16","dp25","async","normalizePromoTasksList","list","arguments","length","undefined","orderedList","_orderBy","result","allUUIDs","byUUIDs","settingsByUUIDS","optionsByUUIDS","relationByUUIDS","d","push","uuid","main","settings","taskOption","promotions","normalizePromoTaskData","data","PromotionOptions","optionUUIDS","Task","Tasks","Styles","Promotions","rest","task","convertedTask","transformApiResponse","prefixes","suffixes","Constructor","Number","convertedStyles","parseJSON_ifParsable","normalizePromoLotteryList","reduce","obj","lottery","type","lotterySetting","Lotteries","showRest","entryLotteryLimit","suspendWhenNoPrize","AnimationSettings","TasksSetting","prizeLimited","prizeRemainder","remainder","parseAnimationSettings","canNotRetrieveFormData","formId","gameType","isPurePrizeGames","gameTypes","SIGN_FORM","attemptAsync","promise","errorTypes","then","response","catch","error","some","Promise","reject","getRedirectUrlFromLoginServerToPromoOrUgc","promoUUID","promoId","parentUrl","restQs","queryString","parse","window","location","search","qsOfParentUrl","getQsOfParentUrl","qs","stringify","IS_UGC_FLOW","ugc_path","pathname","concat","origin","hash","getRedirectUrlFromLoginServerToSponsorReward","sponsorUUID","loginType","appendQsObj","query","getRedirectToPointLoginHandlerUrl","pointPoolUUID","getRedirectUrlFromLoginServerToPointRecord","getFeverLoginUrl","redirectUrl","loginUrl","FEVER_LOGIN_API_ENDPOINT","urlParam","redirect_uri","CLIENT_API_FEVER_HOST","sponsor_uuid","qsString","getLiffUrl","liffId","loginTypesForLiff","LIFF_TOKEN","redirectPath","liffUrlQueryObj","login_type","liff_id","liffUrlQueryString","getEnterpriseLoginUrl","partner","sponsor","enterpriseShopDomain","enterpriseShopId","Boolean","getEnterpriseLoginUrlCustom","getEnterpriseLoginUrlAppendQuery","enableEnterpriseLoginFvQuery","enterpriseLoginAppId","partnerEnterpriseLoginAppId","enterpriseLiteLoginAppId","partnerEnterpriseLiteLoginAppId","enterpriseCustomizedLoginType","partnerEnterpriseCustomizedLoginType","enterpriseLoginSubType","partnerEnterpriseLoginSubType","id","sponsorId","sponsorEnterpriseLoginAppId","sponsorEnterpriseLiteLoginAppId","sponsorEnterpriseCustomizedLoginType","sponsorEnterpriseLoginSubType","fv_sponsor_id","fv_promo_id","subtype","isInMitch","host","getLoginLinkClickAction","bindRef","url","isMobile","IS_IFRAME_MODE","event","preventDefault","setLocalStorage","getLoginSeverKeyPutIntoLocalParams","parent","postMessage","postMsgEvent","payload","current","openWindow","width","height","left","screen","top","open","getLoginUserInfo","loginMethod","loginTypes","ANONYMOUSLOGIN","loginTypesForApi","ANONYMOUS","INSTAGRAM","loginTypeMappingPointRoutesParam","resp","getLogInInfoAPI","user","Object","values","maskedSensitiveResp","recursiveMask","app_id","visibleStart","visibleEnd","code","email","fullname","access_token","generateApiErrObj","clientErrTypes","maskValue","value","visibleCharsStart","visibleCharsEnd","totalLength","maskedPortion","repeat","substring","keysToMask","_obj","key","valueStr","toString","qsParseNoArray","entries","newObj","val","Array","isArray","qsParseJoinArray","join","decodeURIComponent","console","log","parseUrl","removeKeysFromQueryString","keys","qsObj","newQsObj","_ref3","includes","getSubdomainIndex","hostname","URL","split","initTagManager","_window","promo","reportGA4MeasurementId","sponsorName","gtmAccountInfoInit","uniqueName","site","partnerName","openInApp","partnerOpenInApp","gtmId","custom_GTM","adwordRemarketingId","custom_Adwords_Remarketing","facebookPixelId","custom_FB_Pixel","lineTagId","custom_Line_TagId","sendPageView","customGA4MeasurementId","sponsorOpenInApp","send_page_view","pushDataLayer","action","gtmCustomInit","JSON","nonce","nonceForCSP","createTagManger","IS_LOCAL_DEV","dataLayer","gtmPushPrize","_ref4","prizeName","prizeType","loginId","filterUndefinedOrNull","gtmPushUserLogin","_ref5","uid","gtmPushSignUpFormSubmit","_ref6","entryUuid","gtmPushUserPromoEnter","_ref7","getGameTypeModuleName","gtmPushUserVote","_ref8","mediaId","gtmPushUserOpenAppInWebView","_ref9","webViewEventName","gtmPushPromoPublish","_ref10","promoUuId","promoStartDate","promoEndDate","promoTitle","gtmPushPagePublish","_ref11","pageId","pageTitle","gtmPushPrizeResponseFormSubmit","_ref12","generateFbcByFbclid","fbclid","subdomainIndex","creationTime","Date","now","froalaKeyVisionTypeMapping","IMAGE","COLOR","coverImg","default","cover_one","cover_two","cover_ugc","ratio","background","mobile","desktop","ugc","reducePointModes","KK_BOX","GENERAL","POINT_SYSTEMS","enterprisePointInputModes","NUMBER","CUSTOM_CODE","FORM_PSYCHO_QUIZ","SIGNUP_FORM","REDEEM_FORM","FORM_QUIZ","FORM_SURVEY","FORM_LOTTERY_GAME","FORM_INVOICE","FORM_VOTE","functionKeys","_merge","planKeys","loginQualify","line","ADD_FRIEND","BIND_MEMBER_ACCOUNT","CYBERBIZ_EC_MEMBER","NEW_REGISTER_MEMBER","APP_LOGIN","qualify","nameList","API","MEMBER_ORDER","point","REDUCE_POINT","prizeTypes","CASH_VOUCHER","POINT","PROMO_POINT","PRIZE_CODE","CYBERBIZ_COUPON","SHOPLINE_COUPON_CODE","partnerDisplayKeys","DISPLAY_LOGIN","DISPLAY_PLAY_TIMES","DISPLAY_LOTTERIES","functionKeysMappingDisplayType","login","lotteries","settingKeysGroup","displayKey","forEach","bindingPointPoolKeys","MEMBER_POINT","KK_POINT","ERROR","DUPLICATE","ENTRY_NEED_PASSCODE","USAGE_LIMIT_EXCEEDED","RECAPTCHA_TOK_AUTH_FAILED","passcodeTypes","UNIQUE_CODE","SINGLE_CODE","UPLOAD_CODE","REALTIME_UNIQUE_CODE","ONSITE_ASSISTANT_CODE","getPasscodeErrorType","httpStatus","String","toLowerCase","message","getErrorTypeMessage","i18n","t","getErrorTypeDialogDesc","modules","PSYCHO_QUIZ","QUIZ","SURVEY","WIN_WHEEL","VOTE","POKE_GAME","SCRATCH_CARD","INVOICE","RED_ENVELOPE_RAIN","PHOTO_UPLOAD","CHECK_IN","CONTEST_PHOTO_UPLOAD","PHOTO_FRAME_COMPOSITE","SLOTS","PICK_THE_PRIZE","MEMORY_MATCH","COMMENT","CONTEST_ADMIN_UPLOAD","CONTEST_PHOTO_FRAME_COMPOSITE","CHALLENGE_PHOTO_FRAME_COMPOSITE","VIDEO_UPLOAD","CONTEST_VIDEO_UPLOAD","PURCHASE_REWARD","POINTS_REDEEM","MGM_SHARE","SIGN_UP","MULTI_CHALLENGE","ORDER_REWARD","CART_REWARD","JOIN_AND_GET","ADMIN","FACEBOOK","LINE","ENTERPRISE","LIMITATION","DAILY_PLAY_TIMES","TOTAL_PLAY_TIMES","PERIOD_PLAY_MODE","prizes","PRIZE_VIRTUAL_NUMBER","form","FORM_REDIRECT","SIGNUP_FORM_LIMIT","tags","TAGGED_BY_PROMO","webhook","API_WEBHOOK","planTypes","PROMO_PLAN","POINT_PLAN","HEIGHT_RESIZE","SCROLL_INTO_VIEW","PARENT_REDIRECT","PARENT_POPUP","IS_ZINES_EMBEDDED","IS_WIDGET_EMBEDDED","MGM_REFERRAL","pureGameTypeMappingLotteryType","lotteryTypes","gamesConfig","planKey","formBasedType","i18nNameKey","imageSrc","descriptionText","moduleNameForWebhook","purePrizeGameLotteryType","isPurePrizeGame","isUgcGame","canLinkWithContestModule","hasUgcFlow","ugcLinkKeys","hasRelatedPromoOptions","hasRelatedPromoTask","gameTypeImageSrc","getGameTypeImageSrc","gameTypeNames","getGameTypeLabel","i18nKey","gameTypeModuleNames","formbasedGames","Set","map","filter","isFormBasedGame","has","purePrizeGames","ugcGames","isUgcGames","hasPromoTaskGames","checkIsGameHasPromoTask","hasPromoOptionGames","checkIsGameHasPromoOptions","contestGamesForUserPlayableUgc","isContestGamesForUserPlayableUgc","contestGamesWithSecondaryUgc","isContestGamesWithSecondaryUgc","ugcGamesCanLinkWithContestModule","isUgcGameAndHasUgcMediaFlow","smallPromoWidthGames","isSmallPromoWidth","ugcLinkedKeysInContestModule","moduleKey","ugcLinkedKeysInContestModuleSet","contestModuleMappingUsableUgcLinkKeys","_ref13","contestGetUgcLinkKey","settingPromo","_contestModuleMapping","_Object$entries$find","usableUgcLinkKeys","ugcLinkKey","find","_ref14","pointCountRuleGames","hasPointCountRuleGames","hasShowPointRelatedSettingTab","dynamicPrizeTypeGames","hasShowDynamicCountPrizeType","passLoginCheckTrigger","hasPassLoginCheckTriggerGame","hideSettingPromoWhenNoPrizeGames","hasHideSettingPromoWhenNoPrizeGames","promoFormTemplateMapping","_ref15","promoLotteryTemplateMapping","_ref16","canNotUseTags","isCanNotUseTags","canSetVerifyMechanismGames","isCanSetVerifyMechanismGames","hasForceVerifyMechanismGames","isForceVerifyMechanismGames","hasAutoTriggerAnimationGames","isAutoTriggerAnimationGames","canSetAllCorrectGetPrizeRuleGames","isCanSetAllCorrectGetPrizeRuleGames","hasNeedLoginEnterpriseGames","isNeedLoginEnterpriseGames","canNotRelateMultiChallengeTaskGames","isCanRelateMultiChallengeTaskGames","checkGameResultRecordsHasLotteryParticipant","isCheckGameResultRecordsHasLotteryParticipant","canShowUseRevalidationGames","isCanShowUseRevalidationGames","lotteryGeneralAnimationType","Symbol","lotteryOpenPathParams","lotteriesConfig","instant","lotteryAnimatePath","participant","admin","lotteryAnimationPathMapping","lotteryInstantTypes","lotteryParticipantTypes","lotteryAdminTypes","lotteriesHaveAnimation","isLotteryHasAnimation","hideThankPrizeLottery","getHideThankPrizeLottery","lotteryAlgorithmTypes","PERCENT","ORDER","SELF_PICK","lotteryRestShowTypes","NOT_SHOW","SHOW_REMAIN_AMOUNT","SHOW_TOTAL_AMOUNT","lotteryWhenNoPrizeTypes","SUSPEND","CONTINUE","lotteryPrizeGetLimitTypes","UNLIMITED","LIMITED","IS_END","IS_OFFLINE","IS_ONLINE","IS_SUSPEND","getStatusLabel","status","hasUtcDTStartInLocal","getStatusLabelWhenPromoStructureIsTwoPromo","primaryStatus","secondaryStatus","primaryStartDate","secondaryStartDate","DEFAULT_CASE","PARTICULAR_CASE_WHEN_BOTH_PROMO_ONLINE","labelStatusHandler","getIsPromoSuspendNotYetStart","isQueuePublish","isBothPromoOnline","isPrimaryPromoQueuePublish","getIsQueuePublishStatus","isSecondaryPromoQueuePublish","isHasOnlyOneQueuePublishPromo","currentParticularCase","primaryStatusLabel","secondaryStatusLabel","GENERAL_PRIZE","GENERAL_COUPON","COUPON_CODE","THANKYOU","MEMBERSHIP_DYNAMIC_POINT","PROMO_DYNAMIC_POINT","PROMO_FIXED_POINT","supportCollectPrizeTypes","prizeRedeemDateLimitTypes","NO_LIMIT","RANGE","WITHIN","WITHIN_MONTH_LAST_DAY","FIXED_EXPIRATION","uploadCouponFileTypes","UPLOAD_COUPON_CODE","UPLOAD_URL","UPLOAD_CODE_AND_URL","prizeQuantityLimitedTypes","prizeVisibleTypes","INVISIBLE","VISIBLE","prizeStoreRedeemTypes","REDEEM_BUTTON","ON_SITE_ASSISTANT_TOOL","ECOMMERCE_ORDER_REDEMPTION_LISTENER","prizeGiveWayLabel","getPrizeTypeLabel","prizeLabel","memberPointPrizeTypes","hasMemberPointPrizeType","promoPointPrizeTypes","hasPromoPointPrizeType","fixedPointPrizeTypes","hasFixedPointPrizeType","dynamicPointPrizeTypes","hasDynamicPointPrizeType","pointPrizeTypes","hasPointPrizeType","carrierClaimPrizeTypesForParticipateWinner","isCarrierClaimPrizeTypesForParticipateWinner","convertRedeemTimePrizeTypes","isConvertRedeemTimePrizeType","ecommerceCouponPrizeTypes","isEcommerceCouponPrizeTypes","dayjsSupportTimeZones","backendTimezone","timezoneList","timezones","tzCode","ImageShowTypeMapping","SQUARE","WATERFALL","SLIDERSHOW","MARQUEE","COLLAGE","galleryGameSetting","versionStyleSettings","imgShowType","isShowWorkInformation","buttonSettings","isShowButton","buttonText","textColor","white","bgColor","system900","maskColor","squareFakeData","igGame","isGallery","getDefaultAvatarByType","array","fakeData1","avatar","memberId","media","seq","ugcAuthorName","title","fakeData2","i","sliderShowFakeData","marqueeFakeData","serialNo","secondaryData","lotteryCategories","IS_INSTANT_LOTTERY","IS_PARTICIPANT_LOTTERY","IS_ADMIN_LOTTERY","prizeQuantityTypes","adminPrize","label","category","settingKey","participantPrize","sketchPrize","isSketch","additionalConfig","winWheelPrize","pokeGamePrize","redEnvelopeRainPrize","slotsPrize","pickThePrizePrize","pointsRedeemPrize","lotteryConfigList","defaultSelectableLotteryTypesList","getLotteryConfig","getUnCreatedLotteryCategories","lotteryList","getDefaultLotteryTypeByCategory","lotteryCategory","ADMIN_PRIZE_DEFAULT_VALUE","INSTANT_PRIZE_DEFAULT_VALUE","PARTICIPANT_PRIZE_DEFAULT_VALUE","getActivePrizeTabByCategory","prizeTabPanelIds","lotteryPrizeManageTab","instantPrizeManageTab","participantPrizeManageTab","getShouldExpandTabIndex","findIndex","c","checkCurrentLotteryIsBindingPrimaryLottery","isPrimaryLotteryInstantSharing","isPrimaryLotteryParticipantSharing","getExistEnableBindingPrimaryLottery","gameDesignTabPanels","participantPrizeDesignScratchCardTab","lotteryType","participantPrizeDesignWinWheelTab","participantPrizeDesignPokeGameTab","participantPrizeDesignRedEnvelopeRainTab","participantPrizeDesignSlotsTab","participantPrizeDesignPickThePrizeTab","participantPrizeDesignPointsRedeemTab","isGameDesignLotteryType","tab","participantPrizeRuleTab","lotteryPrizeRuleTab","instantPrizeRuleTab","prizeRelatedSettingTab","responseFormTab","lotteryTaskPrizeDesignPickThePrizeTab","fromEntries","prizeTabTypes","UGC_TAB_INDEX","VOTE_TAB_INDEX","PRIZE_TAB_INDEX","TASK_TAB_INDEX","CHECK_IN_TAB_INDEX","SHARE_INVITE_TAB_INDEX","SHARE_SPECIFY_TAB_INDEX","PRIZE_SETTINGS","modes","DAY","WEEK","listConfig","PeriodPlayModeSelector","onChange","style","lists","useMemo","MenuItem","Select","_css","selectorStyle","e","fullWidth","periodTimeUtcToTimeZone","timezone","timeArrays","_timezoneList$find","offset","tz","utc","offsetHandler","a","b","periodTimeTimezoneToUtc","_timezoneList$find2","calcMethod","start","end","calculateOffset","time","trimSecond","timeStr","weekday","clampWeekDay","dayoffset","offsetHour","offsetMin","timeHour","timeMin","timeSec","timeMinWithOffset","minCauseHourOffset","timeHourWithOffset","padStart","generatePeriodTimeMatchInfo","isPeriodPlayMode","mode","periodTimes","match","periodStartInTZ","periodEndInTZ","currentInTZ","currentInTimezone","dayjs","currentInTimezoneDate","format","currentInTimezoneTime","periodTimeInTimeZone","matchedPeriod","currentInTimezoneWeekDay","isoWeekday","isWeekdayInRange","isTimeInRange","startWeekdayOffset","o","endWeekdayOffset","subtract","add","errorMessage","EMPTY","SMALLER_END_DATE","OVERLAP_PERIOD","EXCEED_WEEK_PERIOD","isOverLapTime","_a$start","_b$end","_b$start","_a$end","checkEmptyDatetimeError","hasEmptyError","errorObj","index","items","checkSmallerEndDateError","hasInvalidPeriodError","checkOverlapPeriodError","datetimeArray","hasOverLapError","j","otherT","checkExceedWeekPeriodError","hasExceedWeekPeriodError","bgTypes","FROALA","DISPLAY_IMAGE_TEXT","DISPLAY_TEXT","DISPLAY_IMAGE","CARD_GAP_SIZE","black","defaultPrizeCardLayoutConfig","system100","warning","IS_EDITOR_MODE","i18nLangOfGame","i18next","fever500","btnVariants","FILLED","OUTLINED","TEXT","getShakeAnimationStyle","feverShake","preventMarginCollapse","containerShadow","shadowLightStyle","getForegroundColor","r","g","Color","rgb","object","getColorRGBA","Math","round","parseInt","addHoverStyle","styleObj","backgroundColor","lightenDarkenColor","addOutlineBtnHoverStyle","borderColor","adjustColorAlpha","lineClampStyle","rowsMax","themedButtonStyle","btnVariant","IMG","generateBgStyleByType","isFixedMode","imageUrl","mobileImgUrl","belowContain","keyframes","_templateObject","_taggedTemplateLiteral","feverBlink","_templateObject2","feverZoomIn","_templateObject3","feverZoomScale","_templateObject4","feverSpin","_templateObject5","searchTypes","NO_SEARCH","AUTHOR_NAME","PORTFOLIO_NAME","PageType","COLLECTIONS","PORTFOLIO","SortTypeMapping","RANDOM","RANK","TIME","ORIGIN","MaskTypeMapping","BLACK","WHITE","ugcGameSetting","headerFunctionSettings","defaultSortType","defaultHomePageButtonText","masterVisionSettings","isShowKeyVision","defaultMainVisionType","customImgUrl","customMobileImgUrl","bgType","froalaEditor","cardSettings","defaultImgShowType","defaultMaskStyle","topicSettings","isShowSubmitInformation","isShowVoteInformation","system050","shareButtonSettings","functional","enableFacebookCommentsPlugin","voteButtonSettings","promo100","breakpoints","xsm","sm","md","lg","xlg","heightBreakpoints","getBreakpoint","breakpoint","above","below","getScreenOrientation","innerHeight","innerWidth","rgba","alpha","convertRGBtoRGBA","customAlpha","colorObj","isEmptyObject","transparent","convertRGBAtoHEX","hex","amount","lighten","darken","getTimezoneOffset","utcDTStr2UTC","replace","getTime","utcDTStr2TimezoneDTStr","dateStr","date","method","timezoneDate","abs","utc2TimezoneDTStr","timeStamp","utcDTStr2LocalDTStr","getDateTimeStr","getCurrentUtcDTStr","toISOString","getCurrentUtcDateStr","timezoneDTStr2UTC","tzOffset","timezoneDTStr2UtcDTStr","timestamp","str","timeStamp2UtcDtStr","getDayRange","date1","date2","d1","diff","startDate","hasUtcDTEndInLocal","endDate","getLocalTimezone","guess","dateData","isLocalSameDateInPromoTimezone","removeSecondsFromDTStr","isBefore","UTC_toLocalTime","timeString","local","filterSlash","text","replaceText","reg","test","extractUUIDs","uuids","traverse","hasOwnProperty","replaceUsername","variable","reverse","mgmConfig","mgmMapping","mgmShare","isMgmShare","mgmMission","isMgmMission","mgmSelf","isMgmSelf","k","v","isLocalStorageEnable","_navigator","navigator","cookieEnabled","localStorage","item","setItem","getLocalStorage","getItem","deleteLocalStorage","removeItem","lineConfigKeys","retrieveLineConfig","hasSponsorSiteConfig","lineLoginAppId","valInSponsor","valInPartner","getLotteryDefaultAnimationSettingValue","config","keyVisionSettings","prizeCardStyleSettings","isShowCaption","hintColor","prizeCardOrderSettings","prizesOrder","prizeCardLayoutSettings","actionButtonSettings","defaultBackgroundType","backgroundSettings","buttonTextColor","buttonBgColor","_cloneDeep","settingData","_getLotteryDefaultAni","isSettingDataValueUndefined","_isEmpty","parsed","err","migratedAnimationSettings","stringifyAnimationSetting","objFirstLevelJSONStringify","deprecatedSetting","_deprecatedSetting$ke","_deprecatedSetting$ke2","_deprecatedSetting$ke3","_deprecatedSetting$ke4","_deprecatedSetting$ke5","_deprecatedSetting$ke6","_deprecatedSetting$ke7","_deprecatedSetting$ke8","_deprecatedSetting$ke9","_deprecatedSetting$ke10","_deprecatedSetting$ke11","_deprecatedSetting$ke12","_deprecatedSetting$ke13","_deprecatedSetting$ke14","_deprecatedSetting$ke15","_deprecatedSetting$pi","_deprecatedSetting$pi2","_deprecatedSetting$pi3","_deprecatedSetting$pi4","_deprecatedSetting$pi5","_deprecatedSetting$pi6","_deprecatedSetting$pi7","_deprecatedSetting$pi8","_deprecatedSetting$pr","_deprecatedSetting$pr2","_deprecatedSetting$pr3","_deprecatedSetting$bu","_deprecatedSetting$bu2","_deprecatedSetting$bu3","_deprecatedSetting$bu4","_deprecatedSetting$bu5","_deprecatedSetting$bu6","_deprecatedSetting$bu7","_deprecatedSetting$Ba","_deprecatedSetting$Ba2","_deprecatedSetting$Ba3","_deprecatedSetting$Ba4","_deprecatedSetting$Ba5","_deprecatedSetting$ke16","_deprecatedSetting$ke17","_deprecatedSetting$ke18","_deprecatedSetting$ke19","_deprecatedSetting$ke20","_deprecatedSetting$ke21","_deprecatedSetting$ke22","_deprecatedSetting$ke23","_deprecatedSetting$ke24","_deprecatedSetting$ke25","_deprecatedSetting$ke26","_deprecatedSetting$pr4","_deprecatedSetting$pr5","_deprecatedSetting$pr6","_deprecatedSetting$pr7","_deprecatedSetting$pr8","_deprecatedSetting$pr9","_deprecatedSetting$pr10","_deprecatedSetting$pr11","_deprecatedSetting$pr12","_deprecatedSetting$pr13","_deprecatedSetting$pr14","_deprecatedSetting$Ba6","_deprecatedSetting$Ba7","_deprecatedSetting$Ba8","_deprecatedSetting$Ba9","_deprecatedSetting$Ba10","newSettings","animationSetting","keyVisual","keyVision","colorBg","isUseCustomKeyVision","pickThePrizeCardStyle","colorText","prizeCardOrder","prizeCardLayout","isUseCustomImg","BackgroundStyle","prizeCardStyle","colorButtonText","colorButtonBg","stylePropType","PropTypes","border","contentBgColor","contentBorderRadius","titleFontWeight","titleColor","descColor","answerColor","optionColor","optionLabelColor","buttonColor","buttonLabelColor","buttonSize"],"sourceRoot":""}