PageSourceSearch

https://www.ulifestyle.com.hk/community/_next/static/chunks/7481.10d38f180704c0b7.js

js ulifestyle.com.hk collected 2026-10-01 09:15:12 UTC 7,923 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7481],{37481:function(t,e,n){n.r(e);var o=n(57437),r=n(2265),a=n(33145),c=n(27648),i=n(99376),l=n(722),u=n(11779),s=n(78425),d=n(22835),m=n(44434);e.default=r.memo(t=>{let{layout:e,item:n}=t,f=(0,l.ac)({maxWidth:768}),p=(0,i.useRouter)(),{userId:g,isOnboardingFilled:h,setAuthContext:x}=(0,u.a)(),b=h?"completed":"uncompleted",v="/community_main_recruitment/onboarding/form",y=(0,r.useMemo)(()=>({desktop:{completed:{title:"管理你的帳戶資料",icon:"",desc:"",style:{backgroundColor:"#fff"}},uncompleted:{title:"解鎖創作者活動配對系統",icon:"",desc:"",style:{backgroundColor:"#e2f2ec"}}},mobile:{completed:{title:"管理你的帳戶資料",desc:"輕鬆更新資料,加速配對最新社群活動!",icon:"/images/main_recruitment/creator_recruitment_edit_form_button.svg",style:{backgroundColor:"#fff"}},uncompleted:{title:"創作者招募",desc:"填妥個人資料,快人一步配對社群獨家活動!",icon:"/images/main_recruitment/creator_recruitment_fill_in_form_button.svg",style:{backgroundColor:"#e2f2ec"}}},"header-menu":{completed:{title:"",desc:"",icon:"",style:{}},uncompleted:{title:"",desc:"",icon:"",style:{}}}}),[]),w=(0,r.useCallback)(()=>{p.push(v)},[p]),_=y[e][b];return((0,r.useEffect)(()=>{(async()=>{if(!g)return;let t=await (0,m.R)(g);t!==h&&x(e=>({...e,isOnboardingFilled:t}))})()},[h,x,g]),"desktop"===e)?(0,o.jsxs)("button",{type:"button",onClick:w,className:"w-fit hidden md:inline-flex items-center px-3 py-2 rounded-full border border-[#d7ece4] font-normal text-gray-600 text-left",style:_.style,children:[(0,o.jsx)(a.default,{className:"w-[24px] h-[24px] mr-[4px]",src:"/images/main_recruitment/community-campaign-header-icn-info-type-form.svg",alt:_.title,width:24,height:24}),(0,o.jsx)("span",{className:"text-sm font-medium text-left text-[#333]",children:_.title})]}):"header-menu"===e?(0,o.jsx)(o.Fragment,{children:n&&(0,o.jsx)(c.default,{href:v,target:n.newTab?"_blank":"_self",className:"cursor-pointer block no-underline",prefetch:!1,children:(0,o.jsx)(s.Z,{item:n,wrapperClasses:f?(0,d.cn)("py-4 rounded-t-none",{"border-t-[1px]":n.borderTop}):"p-4"})})}):(0,o.jsx)("button",{type:"button",onClick:w,className:"w-full flex md:hidden flex-col justify-start items-start rounded-xl border-[#d7ece4] border border-solid text-[#333] text-left",style:_.style,children:(0,o.jsx)(a.default,{className:"w-full h-auto",src:_.icon,alt:_.title,width:343,height:64,priority:!1})})})},11779:function(t,e,n){n.d(e,{AuthProvider:function(){return c},a:function(){return i}});var o=n(57437),r=n(2265);let a=(0,r.createContext)(void 0);function c(t){let{children:e,initialAuthContext:n}=t,[c,i]=(0,r.useState)(n);(0,r.useEffect)(()=>{c.userId?function(t,e){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:30;if("undefined"==typeof document)return;let o=new Date(Date.now()+864e5*n).toUTCString();document.cookie="".concat(t,"=").concat(encodeURIComponent(e),"; expires=").concat(o,"; path=/")}("community_auth_context",JSON.stringify(c)):document.cookie="community_auth_context=; Max-Age=0; path=/"},[c]);let l=(0,r.useMemo)(()=>({...c,setAuthContext:i}),[c]);return(0,o.jsx)(a.Provider,{value:l,children:e})}let i=()=>{let t=(0,r.useContext)(a);if(void 0===t)throw Error("useAuth must be used within an AuthProvider");return t}},78425:function(t,e,n){var o=n(57437),r=n(33145);e.Z=t=>{let{item:e,wrapperClasses:n}=t;return(0,o.jsx)("div",{className:n,children:(0,o.jsxs)("div",{className:"flex items-center gap-3",children:[(0,o.jsx)(r.default,{src:e.icon,width:"24",height:"24",alt:e.key}),(0,o.jsx)("span",{className:"text-slate-700 text-base",children:e.name})]})})}},44434:function(t,e,n){n.d(e,{Cx:function(){return u},GN:function(){return y},J0:function(){return l},K4:function(){return w},Kh:function(){return b},Ne:function(){return m},R:function(){return S},RR:function(){return h},Uz:function(){return p},Vo:function(){return d},dn:function(){return s},fR:function(){return v},he:function(){return x},s_:function(){return _},sl:function(){return g}});var o=n(84833),r=n(12),a=n(57635),c=n.n(a),i=n(14438);function l(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3e3;(0,i.toast)(t,{duration:e,classNames:{toast:"[&&]:!bg-[#333]/80 !w-fit !rounded-full !bottom-[50px] !py-[9.5px] !px-4",title:"!text-white [&&]:!pr-0 !text-[15px] !font-medium",closeButton:"!hidden"}})}let u={UCOMMUNITY:{imgSrc:"/images/creator-hub/social-platform-ucommunity.png",text:"U Community"},UBLOG:{imgSrc:"/images/creator-hub/social-platform-ublog.png",text:"U Blog"},IG_POST:{imgSrc:"/images/creator-hub/social-platform-ig.png",text:"Instagram"},IG_REEL:{imgSrc:"/images/creator-hub/social-platform-ig.png",text:"Instagram Reel"},THREAD:{imgSrc:"/images/creator-hub/social-platform-threads.png",text:"Thread"},XHS:{imgSrc:"/images/creator-hub/social-platform-xhs.png",text:"小紅書"},IG_STORY:{imgSrc:"/images/creator-hub/social-platform-ig.png",text:"Instagram Story"}},s=t=>{let e=new Date(t.replace(" ","T")),n=e.getFullYear(),o=(e.getMonth()+1).toString().padStart(2,"0"),r=e.getDate().toString().padStart(2,"0"),a=e.getHours(),c=e.getMinutes().toString().padStart(2,"0"),i=a>=12?"PM":"AM";0==(a%=12)&&(a=12);let l="".concat(a,":").concat(c).concat(i);return"".concat(n,"/").concat(o,"/").concat(r," ").concat(l)},d=t=>t.substring(0,10).replaceAll("-","/"),m=(t,e)=>t&&e?"".concat(t,"歲-").concat(e,"歲"):t?"".concat(t,"歲或以上"):e?"".concat(e,"歲或以下"):"",f=t=>
1t.toLocaleString(),p=(t,e)=>t&&e?"".concat(f(t),"-").concat(f(e),"個粉絲"):t?"".concat(f(t),"個粉絲或以上"):e?"".concat(f(e),"個粉絲以下"):"",g=(t,e,n)=>{var o;if(0===t.length)return"";let r=1===t.length?u[t[0]].text:t.length>2?t.map(t=>{var e;return null===(e=u[t])||void 0===e?void 0:e.text}).slice(0,-1).join("、")+"及"+(null===(o=u[t[t.length-1]])||void 0===o?void 0:o.text):t.map(t=>{var e;return null===(e=u[t])||void 0===e?void 0:e.text}).join("及"),a=t.length>1?"共":"";return e&&n?"閣下之".concat(r,"帳戶").concat(a,"擁有").concat(f(e),"-").concat(f(n),"個粉絲"):e?"閣下之".concat(r,"帳戶").concat(a,"擁有").concat(f(e),"個粉絲或以上"):n?"閣下之".concat(r,"帳戶").concat(a,"擁有").concat(f(n),"個粉絲以下"):""},h=t=>{let e=new Date;return new Date(t.replace(" ","T"))>e},x=t=>{let e=new Date;return new Date(t.replace(" ","T"))<e},b=(t,e)=>{let n=new Date,o=new Date(t.replace(" ","T")),r=new Date(e.replace(" ","T"));return n>=o&&n<=r},v=t=>{let e=new Date(t.replace(" ","T")),n=(e.getMonth()+1).toString().padStart(2,"0"),o=e.getDate().toString().padStart(2,"0");return"".concat(o,"/").concat(n)},y=async(t,e)=>{try{let n=await fetch(t,{mode:"cors"});if(!n.ok)return!1;let o=await n.blob(),r=function(t){let e=t.match(/\.([^.\/\\]+)(?:[?#]|$)/);return e?e[1].toLowerCase():""}(t);e=e+"."+(r||"jpg");let a=URL.createObjectURL(o),c=document.createElement("a");return c.href=a,c.download=e,document.body.appendChild(c),c.click(),c.remove(),URL.revokeObjectURL(a),!0}catch(t){return console.error("Download failed",t),!1}},w=async function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"images.zip",n=new(c());await Promise.all(t.map(async(t,e)=>{var o;let r=await fetch(t);if(!r.ok)throw Error("Failed to fetch image: ".concat(t));let a=await r.blob(),c=(null===(o=t.split(".").pop())||void 0===o?void 0:o.split(/\#|\?/)[0])||"jpg";n.file("promo-image_".concat(e+1,".").concat(c),a)}));let o=await n.generateAsync({type:"blob"});(0,r.saveAs)(o,e)};function _(t){var e,n,o;return(null===(e=t.personalInfo)||void 0===e?void 0:e.isComplete)&&(null===(n=t.socialMedia)||void 0===n?void 0:n.isComplete)&&(null===(o=t.extraInfo)||void 0===o?void 0:o.isComplete)}async function S(t){try{let e=await (0,o.S)("users/".concat(t,"/user-summary"));if(e)return _(e)}catch(t){console.error("Failed to get onboarding status:",t)}return!1}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.