(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-580bb60b"],{"0251":function(t,e,a){var i=a("673a");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var s=a("499e").default;s("176cb371",i,!0,{sourceMap:!1,shadowMode:!1})},"02d3":function(t,e,a){"use strict";a("367e")},"2e45":function(t,e,a){t.exports=a.p+"static/img/character1.992e7559.png"},"367e":function(t,e,a){var i=a("ede9");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var s=a("499e").default;s("d3a3f48c",i,!0,{sourceMap:!1,shadowMode:!1})},"3c26":function(t,e,a){"use strict";a("0251")},"3c54":function(t,e,a){"use strict";a.d(e,"c",(function(){return s})),a.d(e,"d",(function(){return n})),a.d(e,"a",(function(){return o})),a.d(e,"b",(function(){return r}));var i=a("829b");a("b775");function s(t){return Object(i["a"])({url:"https://gpt4.cocorobo.cn/get_agent_park_chat",method:"post",data:t,hideloading:!0})}function n(t){return Object(i["a"])({url:"https://gpt4.cocorobo.cn/insert_chat",method:"post",data:t,hideloading:!0})}function o(t){return Object(i["a"])({url:"https://gpt4.cocorobo.cn/ai_agent_park_chat_new",method:"post",data:t,hideloading:!0})}function r(t){return Object(i["a"])({url:"https://gpt4.cocorobo.cn/ai_agent_park_chat",method:"post",data:t,hideloading:!0})}},5013:function(t,e,a){t.exports=a.p+"static/img/bg3.aadcec19.png"},"673a":function(t,e,a){var i=a("24fb");e=i(!1),e.push([t.i,".bar[data-v-2fea8964]{width:100%;height:1.06667rem;z-index:999;font-weight:550;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;box-sizing:border-box;padding:0 .26667rem;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;position:fixed;top:0;left:0;font-size:.45333rem;color:#000!important;background-color:#fff!important}.barTitle[data-v-2fea8964]{max-width:50vw;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}",""]),t.exports=e},"682d":function(t,e,a){"use strict";a.r(e);var i=a("53ca"),s=(a("caad"),a("2532"),function(){var t=this,e=t._self._c;return e("div",{staticClass:"pocAi"},[e("bar",{attrs:{tit:"智能學伴"}}),t._m(0),5==t.chatStatusType?e("div",{staticClass:"pa_goIndex"},[e("span",{on:{click:function(e){return e.stopPropagation(),t.courseSelection()}}},[t._v(t._s(t.userInfo.userId?"開始學習":"開始選課"))])]):t._e(),t.showOpeningRemarks?t._e():e("div",{staticClass:"pa_chatArea"},[e("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"pa_ca_chat"},[e("div",{ref:"chatListRef",staticClass:"pa_ca_c_list"},t._l(t.chatList,(function(i,s){return e("div",{key:s},[i.content?e("div",{staticClass:"userChat"},[e("div",{staticClass:"uc_left"},[e("div",{staticClass:"chatName"},[t._v("科科")]),e("div",{staticClass:"chatMessage"},[e("span",{domProps:{textContent:t._s(i.content)}}),e("div",{staticClass:"cm_btnArea"},[e("span",{on:{click:function(e){return e.stopPropagation(),t.copy(i.content)}}},[e("svg",{attrs:{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.76904 1.3171C2.76904 0.588877 3.35938 -0.00146484 4.08761 -0.00146484H10.6804C11.4087 -0.00146484 11.999 0.588876 11.999 1.3171V7.90992C11.999 8.63814 11.4087 9.22849 10.6804 9.22849H4.08761C3.35938 9.22849 2.76904 8.63814 2.76904 7.90992V1.3171ZM4.08761 0.987458C3.90555 0.987458 3.75797 1.13504 3.75797 1.3171V7.90992C3.75797 8.09198 3.90555 8.23956 4.08761 8.23956H10.6804C10.8625 8.23956 11.0101 8.09198 11.0101 7.90992V1.3171C11.0101 1.13504 10.8625 0.987458 10.6804 0.987458H4.08761Z",fill:"#333333"}}),e("path",{attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1.31856 3.75748C1.13651 3.75748 0.988923 3.90506 0.988923 4.08712V10.6799C0.988923 10.862 1.13651 11.0096 1.31856 11.0096H7.91139C8.09344 11.0096 8.24103 10.862 8.24103 10.6799V9.85584C8.24103 9.58275 8.46241 9.36138 8.73549 9.36138C9.00857 9.36138 9.22995 9.58275 9.22995 9.85584V10.6799C9.22995 11.4082 8.63961 11.9985 7.91139 11.9985H1.31856C0.590342 11.9985 0 11.4082 0 10.6799V4.08712C0 3.3589 0.590341 2.76855 1.31856 2.76855H2.14267C2.41575 2.76855 2.63713 2.98993 2.63713 3.26302C2.63713 3.5361 2.41575 3.75748 2.14267 3.75748H1.31856Z",fill:"#333333"}})])])])])]),e("div",{staticClass:"uc_right"},[e("el-avatar",{staticClass:"chatAvatar",attrs:{src:a("e8e8")}})],1)]):t._e(),e("div",{staticClass:"aiChat"},[e("div",{staticClass:"ac_left"},[e("el-avatar",{staticClass:"chatAvatar",attrs:{src:a("2e45")}})],1),e("div",{staticClass:"ac_right"},[t._m(1,!0),[0,2,3].includes(i.chatStatusType)?e("div",{staticClass:"chatMessage"},[0==i.chatStatusType?e("div",[e("div",{staticClass:"chatStatusMessage"},[t._v(" 為咗更了解妳同提供更啱妳嘅幫助,我想先問妳幾個問題:妳而家讀緊邊一級呀?🎓 ")]),e("div",{staticClass:"chatStatusMessageInputArea"},[e("span",[t._v("年級:")]),e("el-select",{staticClass:"chatStatusMessageInputAreaSelect",attrs:{placeholder:"快來選擇妳的年級",disabled:0!=t.chatStatusType},on:{change:function(e){return t.gradeChange()}},model:{value:t.choseGrade,callback:function(e){t.choseGrade=e},expression:"choseGrade"}},t._l(t.gradeList,(function(t,a){return e("el-option",{key:a,attrs:{disabled:![6].includes(a),label:t,value:t}})})),1)],1)]):t._e(),2==i.chatStatusType?e("div",[t._m(2,!0),2==t.chatStatusType?e("div",{staticClass:"chatStatusMessageInputArea"},[e("span",{staticClass:"csmia_btn",on:{click:function(e){return e.stopPropagation(),t.goChat()}}},[t._v("開始聊天")]),e("span",{staticClass:"csmia_btn",on:{click:function(e){return e.stopPropagation(),t.courseSelection()}}},[t._v(t._s(t.userInfo.userId?"開始學習":"開始選課"))])]):t._e()]):t._e(),3==i.chatStatusType?e("div",[e("div",{staticClass:"chatStatusMessage"},[t._v("好嘞,咁我哋就一齊嚟揀揀妳今日想學嘅科目、教材同埋章節啦~📔")]),e("div",{staticClass:"csm_inputArea"},[e("div",{staticClass:"csm_ia_item"},[e("span",[t._v("學科")]),e("el-select",{staticClass:"chatStatusMessageInputAreaSelect",staticStyle:{width:"100%","margin-top":"5px"},attrs:{placeholder:"請選擇授課科目",disabled:3!=t.chatStatusType},model:{value:t.type3Form.subject,callback:function(e){t.$set(t.type3Form,"subject",e)},expression:"type3Form.subject"}},t._l(t.subjectList,(function(t,a){return e("el-option",{key:a,attrs:{disabled:t.disabled,label:t.label,value:t.label}})})),1)],1),e("div",{staticClass:"csm_ia_item"},[e("span",[t._v("章節")]),e("el-select",{staticClass:"chatStatusMessageInputAreaSelect",staticStyle:{width:"100%","margin-top":"5px"},attrs:{placeholder:"請選擇授課章節",disabled:3!=t.chatStatusType},model:{value:t.type3Form.chapter,callback:function(e){t.$set(t.type3Form,"chapter",e)},expression:"type3Form.chapter"}},t._l(t.classList,(function(t,a){return e("el-option",{key:a,attrs:{disabled:t.disabled,label:t.title,value:a}})})),1)],1),e("div",{staticClass:"csm_ia_item"},[e("span",[t._v("版本")]),e("el-select",{staticClass:"chatStatusMessageInputAreaSelect",staticStyle:{width:"100%","margin-top":"5px"},attrs:{placeholder:"請選擇授課版本",disabled:3!=t.chatStatusType},model:{value:t.type3Form.edition,callback:function(e){t.$set(t.type3Form,"edition",e)},expression:"type3Form.edition"}},t._l(t.editionList,(function(t,a){return e("el-option",{key:a,attrs:{disabled:t.disabled,label:t.label,value:t.label}})})),1)],1),e("div",{staticClass:"csm_ia_btnArea"},[e("span",{on:{click:function(e){return e.stopPropagation(),t.resetType3Form()}}},[t._v("重置")]),e("span",{on:{click:function(e){return e.stopPropagation(),t.type3FormSubmit()}}},[t._v("開始學習")])])])]):t._e()]):e("div",{directives:[{name:"loading",rawName:"v-loading",value:i.loading,expression:"item.loading"}],staticClass:"chatMessage",style:i.loading?"border:none;padding:20px;border-radius:8px;overflow:hidden":""},[e("span",{domProps:{innerHTML:t._s(i.aiContent)}}),e("div",{staticClass:"cm_btnArea"},[e("span",{on:{click:function(e){return e.stopPropagation(),t.copy(i.aiContent)}}},[e("svg",{attrs:{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.76904 1.3171C2.76904 0.588877 3.35938 -0.00146484 4.08761 -0.00146484H10.6804C11.4087 -0.00146484 11.999 0.588876 11.999 1.3171V7.90992C11.999 8.63814 11.4087 9.22849 10.6804 9.22849H4.08761C3.35938 9.22849 2.76904 8.63814 2.76904 7.90992V1.3171ZM4.08761 0.987458C3.90555 0.987458 3.75797 1.13504 3.75797 1.3171V7.90992C3.75797 8.09198 3.90555 8.23956 4.08761 8.23956H10.6804C10.8625 8.23956 11.0101 8.09198 11.0101 7.90992V1.3171C11.0101 1.13504 10.8625 0.987458 10.6804 0.987458H4.08761Z",fill:"#333333"}}),e("path",{attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1.31856 3.75748C1.13651 3.75748 0.988923 3.90506 0.988923 4.08712V10.6799C0.988923 10.862 1.13651 11.0096 1.31856 11.0096H7.91139C8.09344 11.0096 8.24103 10.862 8.24103 10.6799V9.85584C8.24103 9.58275 8.46241 9.36138 8.73549 9.36138C9.00857 9.36138 9.22995 9.58275 9.22995 9.85584V10.6799C9.22995 11.4082 8.63961 11.9985 7.91139 11.9985H1.31856C0.590342 11.9985 0 11.4082 0 10.6799V4.08712C0 3.3589 0.590341 2.76855 1.31856 2.76855H2.14267C2.41575 2.76855 2.63713 2.98993 2.63713 3.26302C2.63713 3.5361 2.41575 3.75748 2.14267 3.75748H1.31856Z",fill:"#333333"}})])])])]),e("div",{staticClass:"ac_r_btnArea"},[1==i.chatStatusType?e("div",{staticClass:"ac_r_ba_box"},t._l(t.pleaseList,(function(a,i){return e("span",{key:i,class:[t.chosePleaseList.includes(a)?"ac_r_ba_boxActive":""],on:{click:function(e){return e.stopPropagation(),t.chosePlease(a)}}},[t._v(t._s(a))])})),0):t._e()])])])])})),0),e("div",{staticClass:"pa_ca_c_bottom"},[e("div",{staticClass:"pa_ca_c_b_inputArea"},[e("el-input",{ref:"textAreaRef",staticClass:"pa_ca_c_b_ia_input",attrs:{placeholder:"請在此輸入您想了解的內容",disabled:null!=t.source||t.isChatStatus},model:{value:t.chatValue,callback:function(e){t.chatValue=e},expression:"chatValue"}}),e("div",{staticClass:"pa_ca_c_b_btnArea"},[e("span",{class:["pa_ca_c_b_ba_btn",t.source?"pa_ca_c_b_ba_btnDisabled":""],on:{click:t.sendChat}},[e("svg",{staticClass:"icon",attrs:{t:"1724748020468",viewBox:"0 0 1024 1024",version:"1.1",xmlns:"http://www.w3.org/2000/svg","p-id":"7309",width:"200",height:"200"}},[e("path",{attrs:{d:"M931.392 11.264L45.12 530.688c-28.736 16.896-43.52 39.424-45.12 61.248v8.128c2.048 26.112 23.04 49.984 61.632 60.416l171.968 46.592a34.304 34.304 0 0 0 41.28-25.536 35.584 35.584 0 0 0-23.808-43.136L79.68 592l873.408-511.872-95.232 703.488c-1.408 10.432-9.152 15.68-18.752 12.992l-365.632-100.288 296.32-305.856a36.416 36.416 0 0 0 0-50.24 33.728 33.728 0 0 0-48.704 0l-324.8 335.36a110.72 110.72 0 0 0-7.872 9.088 35.52 35.52 0 0 0-16.128 30.784 104 104 0 0 0-5.248 32.64v206.4c0 49.664 53.568 79.168 93.568 51.712l166.272-114.368c10.24-6.976 16-19.136 15.232-31.872a35.712 35.712 0 0 0-19.2-29.504 33.28 33.28 0 0 0-34.24 2.304L435.84 937.856v-178.432l385.472 105.6c49.6 13.632 97.472-19.072 104.576-71.808l97.152-717.568c8.448-60.48-40-94.72-91.648-64.384z","p-id":"7310"}})])])])],1)])])]),t.showOpeningRemarks?e("div",{staticClass:"pa_openingRemarks",on:{click:function(e){return e.stopPropagation(),t.openingRemarksAllFn()}}},[e("div",{staticClass:"pa_or_character"},[e("img",{attrs:{src:a("2e45")}})]),e("div",{staticClass:"pa_or_bottom"},[e("span",[t._l(t.openingRemarksMessage[0],(function(a,s){return"object"==Object(i["a"])(t.openingRemarksMessage[0])?e("span",{key:"0-"+s,domProps:{textContent:t._s(a)}}):t._e()})),"object"!=Object(i["a"])(t.openingRemarksMessage[0])?e("span",{domProps:{textContent:t._s(t.openingRemarksMessage[0])}}):t._e()],2),e("span",[t._l(t.openingRemarksMessage[1],(function(a,s){return"object"==Object(i["a"])(t.openingRemarksMessage[1])?e("span",{key:"1-"+s,domProps:{textContent:t._s(a)}}):t._e()})),"object"!=Object(i["a"])(t.openingRemarksMessage[1])?e("span",{domProps:{textContent:t._s(t.openingRemarksMessage[1])}}):t._e()],2),e("span",[t._l(t.openingRemarksMessage[2],(function(a,s){return"object"==Object(i["a"])(t.openingRemarksMessage[2])?e("span",{key:"2-"+s,domProps:{textContent:t._s(a)}}):t._e()})),"object"!=Object(i["a"])(t.openingRemarksMessage[2])?e("span",{domProps:{textContent:t._s(t.openingRemarksMessage[2])}}):t._e()],2)])]):t._e()],1)}),n=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"pa_background"},[e("img",{attrs:{src:a("5013")}})])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"chatName"},[e("span",[t._v("圓鼓鼓的大胖魚")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"csm_message"},[e("span",[t._v("明白曬,而家我對妳熟悉多咗喇,噉我哋宜家可以開始做啲咩呢? ")]),e("span",[t._v(" 💬開始聊天:如果妳想要隨意啲,我哋可以邊聊邊學,妳可以問我任何學習上嘅問題,或者分享下妳最近學到嘅有趣知識。")]),e("span",[t._v("📚開始選課:如果妳想開始系統噉學習,我哋可以選擇一個具體嘅科目和章節,我會根據妳嘅需要提供詳細嘅講解,用妳最喜歡嘅講解方式嚟幫妳學習,令到學習過程更加開心。")]),e("span",[t._v(" 妳想要點樣開始呢?係想隨性啲聊天,定係有目標噉學習特定嘅內容?揀選妳嘅方式,我哋一齊開始啦!🌟")])])}],o=(a("498a"),a("14d9"),a("ac1f"),a("5319"),a("5b81"),a("b64b"),a("7db0"),a("d3b7"),a("a630"),a("3ca3"),a("e9c4"),a("b0c0"),a("c740"),a("4de4"),a("a15b"),a("11c1")),r=a("d4cd"),c=a.n(r),l=a("3c54"),d=a("becf"),p={data:function(){return{userId:this.$store.state.user.userinfo.userid,org:this.$store.state.user.userinfo.org,oid:this.$store.state.user.userinfo.organizeid,showOpeningRemarks:!0,chatValue:"",source:null,loading:!1,chatList:[],openingRemarksMessage:[[],[],[]],isAllOpeningRemarks:!1,chatStatusType:0,isChatStatus:!0,gradeList:["小一","小二","小三","小四","小五","小六","中一","中二","中三","中四","中五","中六"],subjectList:[{value:0,label:"中國語文",disabled:!0},{value:1,label:"英國語文 ",disabled:!0},{value:2,label:"數學",disabled:!0},{value:3,label:"公民與社會發展",disabled:!0},{value:4,label:"科學",disabled:!1},{value:5,label:"物理",disabled:!0},{value:6,label:"化學",disabled:!0},{value:7,label:"生物",disabled:!0},{value:8,label:"中國歷史",disabled:!0}],editionList:[{value:0,label:"牛津大學",disabled:!1},{value:1,label:"聯合培進",disabled:!0}],classList:[{title:"第一章:科學入門",disabled:!0,allClass:[{title:"學習科學",type:0,isComplete:!0,subject:4,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8741724834676182.png"},{title:"科學的實踐",type:0,subject:4,isComplete:!0,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8731724834767532.png"},{title:"實驗室安全",type:0,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8721724834685472.png"},{title:"實驗室儀器及基本實驗技巧",type:0,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8751724834771676.png"},{title:"綜合練習",type:1,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8711724834666052.png"}]},{title:"第二章:水",disabled:!1,allClass:[{title:"水的物熊變化",type:0,subject:4,isComplete:!0,disabled:!1,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8761724834777931.png"},{title:"水循環",type:0,subject:4,isComplete:!0,disabled:!1,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8771724834845597.png"},{title:"溶解",type:0,subject:4,isComplete:!0,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8781724834847977.png"},{title:"水的淨化",type:0,subject:4,isComplete:!0,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8791724834873373.png"},{title:"食水的進一步處理",type:0,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8761724834777931.png"},{title:"節約用水和水汙染",type:0,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8771724834845597.png"},{title:"綜合練習",type:1,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8721724834685472.png"}]},{title:"第三章:觀察生物",disabled:!0,allClass:[{title:"生物",type:0,isComplete:!0,subject:4,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8741724834676182.png"},{title:"生物的分類",type:0,subject:4,isComplete:!0,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8731724834767532.png"},{title:"檢索表",type:0,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8721724834685472.png"},{title:"生物多樣性",type:0,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8751724834771676.png"},{title:"綜合練習",type:1,subject:4,isComplete:!1,disabled:!0,image:"https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%9B%BE%E7%89%8711724834666052.png"}]}],pleaseList:["講解細致","講很多不同的例子","講一些故事和笑話","提很多問題,啟發思考","提供具體的圖像和視頻","提供詳細的操作示範","提供鼓勵和表揚"],chosePleaseList:[],choseGrade:"",userInfo:{grade:"",pleaseList:[],subject:"",chapter:"",edition:"",userName:"科科",choseCharacter:0,userAvatar:a("e8e8")},type3Form:{subject:"",chapter:"",edition:""}}},components:{bar:d["a"]},methods:{chatListScrollBottom:function(){var t=this;this.$nextTick((function(){t.$refs.chatListRef.scrollTop=t.$refs.chatListRef.scrollHeight}))},sendChat:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.chatValue;if([0,1].includes(this.chatStatusType))return[0].includes(this.chatStatusType)?this.chatStatusType=1:[1].includes(this.chatStatusType)&&(this.chatStatusType=2),void this.startChat();if(this.source)return this.$toast("還在對話中,請稍等");if("string"!==typeof t&&(t=this.chatValue),t.trim()){this.chatValue="";var e=a("b532"),i=e.Converter({from:"cn",to:"hk"}),s=Object(o["v4"])();this.chatList.push({role:"user",content:"".concat(t),uid:s,AI:"AI",aiContent:"",oldContent:"",isShowSynchronization:!1,filename:"",index:this.chatList.length,is_mind_map:!1,createtime:(new Date).toLocaleString().replaceAll("/","-"),loading:!0}),this.chatListScrollBottom();var n=[];n.push({role:"user",content:t});var r={assistant_id:"1601e39b-6dbf-11ef-8ce0-12e77c4cb76b",userId:this.userId,message:t,session_name:"".concat(s,"-pocAi-md"),uid:s,file_ids:[],model:"gpt-4o-2024-08-06"};Object(l["a"])(r).then((function(t){i(t.FunctionResponse.result)==i("發送成功")||console.log(t.FunctionResponse.result)})).catch((function(t){console.log(t)})),this.getAtAuContent(s)}},getAtAuContent:function(t){var e=this;this.source=new EventSource("https://gpt4.cocorobo.cn/question/".concat(t));var a="",i="",s=new c.a;this.source.onmessage=function(n){var o=JSON.parse(n.data);if("[DONE]"==o.content.replace("'","").replace("'","")){var r=[];if("result"in o){r=o.result;for(var c=0;c0){for(var s=[],n=0;n]+>/g,""),e.style.position="absolute",e.style.left="-9999px",document.body.appendChild(e),e.select(),document.execCommand("copy"),document.body.removeChild(e),this.$toast.success("復制成功")},setOpeningRemarksMessage:function(){var t=this;this.openingRemarksMessage=[[],[],[]];var e=null,a=null,i=null,s=["👋📚 親愛嘅同學,哈囉!👋","我係妳嘅專屬學習夥伴,希望能夠陪住妳喺學習旅程中一齊進步。🚀🌟","我對好多知識都有認識📚,仲有唔會厭煩嘅耐心👀,無論妳係想學嘢,定係需要啲情感支持💖或者生活建議🛠,我都好樂意做妳嘅聆聽者同指導者,成為妳嘅最佳拍檔🧚‍♂️。"],n=[[],[],[]];n[0]=Array.from(s[0]),n[1]=Array.from(s[1]),n[2]=Array.from(s[2]);var o=n[0].length,r=n[1].length,c=n[2].length,l=0,d=0,p=0,u=50;e=setInterval((function(){if(t.isAllOpeningRemarks)return clearInterval(e),void(e=null);o>l?(t.openingRemarksMessage[0].push(n[0][l]),l++):(clearInterval(e),e=null,a=setInterval((function(){if(t.isAllOpeningRemarks)return clearInterval(a),void(a=null);r>d?(t.openingRemarksMessage[1].push(n[1][d]),d++):(clearInterval(a),a=null,i=setInterval((function(){if(t.isAllOpeningRemarks)return clearInterval(i),void(i=null);c>p?(t.openingRemarksMessage[2].push(n[2][p]),p++):(clearInterval(i),i=null,t.openingRemarksMessage[2]=n[2],t.isAllOpeningRemarks=!0,setTimeout((function(){t.openingRemarksAllFn()}),5e3))}),u))}),u))}),u)},openingRemarksAllFn:function(){if(this.isAllOpeningRemarks){if(this.userInfo.userId&&this.userInfo.userId==this.userId)return window.localStorage.setItem("showDialog",JSON.stringify({type:2,time:(new Date).getTime()})),void("pocStartIndex"==this.$route.name&&this.$router.push("/pocAiClassroom"));if(!this.showOpeningRemarks)return;this.showOpeningRemarks=!1,this.userInfo.userId&&(this.chatStatusType=2),this.startChat()}else this.isAllOpeningRemarks=!0,this.openingRemarksMessage=["👋📚 親愛嘅同學,哈囉!👋","我係妳嘅專屬學習夥伴,希望能夠陪住妳喺學習旅程中一齊進步。🚀🌟","我對好多知識都有認識📚,仲有唔會厭煩嘅耐心👀,無論妳係想學嘢,定係需要啲情感支持💖或者生活建議🛠,我都好樂意做妳嘅聆聽者同指導者,成為妳嘅最佳拍檔🧚‍♂️。"]},startChat:function(){if(0==this.chatStatusType)this.chatList.push({role:"user",content:"",uid:"",AI:"AI",aiContent:"",chatStatusType:this.chatStatusType,oldContent:"",isShowSynchronization:!1,filename:"",createtime:(new Date).toLocaleString().replaceAll("/","-"),loading:!1}),this.chatListScrollBottom();else if(1==this.chatStatusType){if(!this.choseGrade)return this.chatStatusType=0,this.$toast("請選擇年級");this.chatList.push({role:"user",content:"".concat(this.choseGrade),uid:"",AI:"AI",aiContent:"妳有冇鍾意嘅上堂方式,好似妳鍾意邊種教學風格?係耐心細緻、例子講解更多啲,定係鍾意通過故事嚟學習?🤔可以揀多個選項㗎~ ",chatStatusType:this.chatStatusType,oldContent:"",isShowSynchronization:!1,filename:"",createtime:(new Date).toLocaleString().replaceAll("/","-"),loading:!1}),this.chatValue="",this.chatListScrollBottom()}else if(2==this.chatStatusType){if(0==this.userInfo.pleaseList.length)return this.chatStatusType=1,this.$toast("請選擇教學風格");this.chatList.push({role:"user",content:"".concat(this.chatValue),uid:"",AI:"AI",aiContent:"",chatStatusType:this.chatStatusType,oldContent:"",isShowSynchronization:!1,filename:"",createtime:(new Date).toLocaleString().replaceAll("/","-"),loading:!1}),this.chatValue="",this.chatListScrollBottom()}else 3==this.chatStatusType&&(this.chatList.push({role:"user",content:"開始選課",uid:"",AI:"AI",aiContent:"",chatStatusType:this.chatStatusType,oldContent:"",isShowSynchronization:!1,filename:"",createtime:(new Date).toLocaleString().replaceAll("/","-"),loading:!1}),this.chatValue="",this.chatListScrollBottom())},gradeChange:function(){var t=this;this.userInfo.grade=this.gradeList.findIndex((function(e){return e==t.choseGrade})),this.chatValue=this.choseGrade},chosePlease:function(t){1==this.chatStatusType&&(this.chosePleaseList.includes(t)?this.chosePleaseList=this.chosePleaseList.filter((function(e){return e!=t})):this.chosePleaseList.push(t),this.userInfo.pleaseList=this.chosePleaseList,this.chatValue=this.chosePleaseList.join("、"))},goChat:function(){var t=this;5!=this.chatStatusType&&(this.chatStatusType=5,this.isChatStatus=!1,this.$nextTick((function(){t.$refs.textAreaRef.focus()})))},courseSelection:function(){this.userInfo.userId?this.$router.push("/pocAiClassroom"):(5==this.chatStatusType||2==this.chatStatusType)&&(this.chatStatusType=3,this.startChat())},resetType3Form:function(){this.type3Form={subject:"",chapter:"",edition:""}},type3FormSubmit:function(){return""==this.type3Form.subject?this.$toast("請選擇學科"):""==this.type3Form.chapter?this.$toast("請選擇章節"):""==this.type3Form.edition?this.$toast("請選擇版本"):(this.userInfo.subject=this.type3Form.subject,this.userInfo.chapter=this.type3Form.chapter,this.userInfo.edition=this.type3Form.edition,this.userInfo.userId=this.userId,this.userInfo.phone="",this.userInfo.birthday="",window.localStorage.setItem("pocUserInfo",JSON.stringify(this.userInfo)),void this.$router.push("/pocAiClassroom"))},getUserInfoData:function(){var t=window.localStorage.getItem("pocUserInfo");t&&(t=JSON.parse(t),t.userId==this.userId&&(this.userInfo=t))}},mounted:function(){this.setOpeningRemarksMessage(),this.getUserInfoData()}},u=p,h=(a("02d3"),a("2877")),m=Object(h["a"])(u,s,n,!1,null,"50459819",null);e["default"]=m.exports},becf:function(t,e,a){"use strict";var i=function(){var t=this,e=t._self._c;return e("div",{staticClass:"bar",style:{background:t.num?"#005CCD":"#f9f9f9",color:t.num?"#fff":"rgba(0, 0, 0, 0.90)"}},[0!==t.num||0!==t.backPage?e("div",{staticStyle:{position:"absolute",left:"10px"}},[e("van-icon",{attrs:{name:"arrow-left"},on:{click:t.back}})],1):t._e(),""!==t.tit?e("div",{staticClass:"barTitle",staticStyle:{"font-size":"20px"}},[t._v(" "+t._s(t.tit)+" ")]):e("div",[t._t("title")],2),t.setting?e("div",{staticStyle:{position:"absolute",right:"10px"}},[e("van-popover",{attrs:{placement:"bottom-end",trigger:"click"},scopedSlots:t._u([{key:"reference",fn:function(){return[t._t("settingIcon")]},proxy:!0}],null,!0),model:{value:t.showSetting,callback:function(e){t.showSetting=e},expression:"showSetting"}},[t._t("setting")],2)],1):t._e(),e("div",{staticStyle:{position:"absolute",right:"10px"}},[t._t("changeChapter")],2)])},s=[],n=(a("a9e3"),{bind:function(t,e){t.clickOutsideEvent=function(a){t===a.target||t.contains(a.target)||e.value(a)},document.addEventListener("click",t.clickOutsideEvent)},unbind:function(t){document.removeEventListener("click",t.clickOutsideEvent)}}),o={props:{tit:{type:String,default:""},num:{type:Number,default:0},backPage:{type:Number,default:0},setting:{type:Boolean,default:!1}},directives:{"click-outside":n},data:function(){return{barBackColor:"barBackColor",showSetting:!1}},methods:{back:function(){1==this.backPage?(console.log(this.backPage),this.$router.go(-1)):this.$emit("cutPage")},settingFn:function(){this.showSetting=!this.showSetting}}},r=o,c=(a("3c26"),a("2877")),l=Object(c["a"])(r,i,s,!1,null,"2fea8964",null);e["a"]=l.exports},e8e8:function(t,e,a){t.exports=a.p+"static/img/defaultAvatar.762b260d.png"},ede9:function(t,e,a){var i=a("24fb");e=i(!1),e.push([t.i,".pocAi[data-v-50459819]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;box-sizing:border-box;background-color:#000;padding-top:1.06667rem}.pa_background[data-v-50459819],.pocAi[data-v-50459819]{width:100vw;height:100vh}.pa_background[data-v-50459819]{position:fixed;top:0;left:0;z-index:1}.pa_background>img[data-v-50459819]{width:100%;height:100%;object-fit:cover}.pa_chatArea[data-v-50459819]{width:100vw;height:100%;overflow:auto;box-sizing:border-box;position:relative;z-index:2}.pa_ca_header[data-v-50459819]{height:1.33333rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;padding:0 .53333rem}.pa_ca_chat[data-v-50459819],.pa_ca_header[data-v-50459819]{width:100%;box-sizing:border-box}.pa_ca_chat[data-v-50459819]{height:100%}.pa_ca_c_list[data-v-50459819]{width:100%;height:calc(100% - 1.6rem);overflow:auto;padding-top:1.33333rem;padding-bottom:1.33333rem;box-sizing:border-box}.pa_ca_c_bottom[data-v-50459819]{width:100%;height:1.6rem;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;box-sizing:border-box;background-color:#fff}.pa_ca_c_b_inputArea[data-v-50459819],.pa_ca_c_bottom[data-v-50459819]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.pa_ca_c_b_inputArea[data-v-50459819]{width:95%;height:70%;border-radius:2.66667rem}.pa_ca_c_b_btnArea[data-v-50459819]{width:1.6rem;height:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end}.pa_ca_c_b_ia_input[data-v-50459819] .el-input__inner{border-radius:1.33333rem;background:#f3f3f3!important;color:#000!important}.pa_ca_c_b_ba_btn[data-v-50459819]{width:1.06667rem;height:1.06667rem;margin-right:.13333rem;border-radius:50%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;cursor:pointer;background-image:-webkit-linear-gradient(right,#4977eb,#005bea);background-image:linear-gradient(270deg,#4977eb 0,#005bea)}.pa_ca_c_b_ba_btn>svg[data-v-50459819]{fill:#fff;width:.53333rem;height:.53333rem}.pa_ca_c_b_ba_btnDisabled[data-v-50459819]{opacity:.5}.pa_ca_c_b_inputArea>textarea[data-v-50459819]{min-height:1.33333rem;height:calc(100% - 1.06667rem);background:none;margin:.18667rem 0;width:calc(100% - 1.6rem);font-size:.42667rem;border:none;outline:none;resize:none;overflow:auto;margin-left:.53333rem}#myTextarea[data-v-50459819]::-webkit-input-placeholder{font-size:.37333rem;color:grey}#myTextarea[data-v-50459819]:-moz-placeholder,#myTextarea[data-v-50459819]::-moz-placeholder{font-size:.37333rem;color:grey;opacity:1}#myTextarea[data-v-50459819]:-ms-input-placeholder{font-size:.37333rem;color:grey}.userChat[data-v-50459819]{width:100%;height:auto;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end;-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start}.uc_left[data-v-50459819]{max-width:90vw;width:auto;height:auto;padding:.26667rem 0 .26667rem 0}.uc_left>.chatName[data-v-50459819]{text-align:right}.uc_left>.chatMessage[data-v-50459819]{border-radius:.26667rem .05333rem .26667rem .26667rem;background-color:#e0eafb;padding:.26667rem}.uc_left>.chatMessage>.cm_btnArea[data-v-50459819]{left:-.93333rem}.uc_right[data-v-50459819]{padding:.26667rem .26667rem .26667rem .26667rem}.aiChat[data-v-50459819]{width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:start;-webkit-justify-content:flex-start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start}.ac_left[data-v-50459819]{padding:.26667rem .26667rem .26667rem .26667rem}.ac_right[data-v-50459819]{width:auto;height:auto;padding:.26667rem 0 .26667rem 0}.chatMessage[data-v-50459819]{max-width:65vw;background-color:#fff;border:.02667rem solid rgba(0,0,0,.8980392156862745);color:#000;padding:0 .53333rem;border-radius:.05333rem .21333rem .21333rem .21333rem;font-size:.37333rem;position:relative;box-shadow:0 .10667rem .26667rem 0 rgba(29,57,131,.0784313725490196);box-shadow:.02667rem .02667rem .53333rem .10667rem rgba(29,57,131,.050980392156862744);word-break:break-all}.cm_btnArea[data-v-50459819]{width:.8rem;height:100%;position:absolute;right:-.93333rem;bottom:0;-webkit-box-align:end;-webkit-align-items:flex-end;-ms-flex-align:end;align-items:flex-end}.cm_btnArea[data-v-50459819],.cm_btnArea>span[data-v-50459819]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center}.cm_btnArea>span[data-v-50459819]{width:.4rem;height:.4rem;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;cursor:pointer;margin-bottom:.13333rem}.cm_btnArea>span>svg[data-v-50459819]{width:100%;height:100%}.chatMessage[data-v-50459819] ol,.chatMessage[data-v-50459819] ul{margin-left:.66667rem}.ac_r_time[data-v-50459819]{margin-top:.26667rem;font-size:.42667rem;color:#8f8f8f}.ac_r_btnArea[data-v-50459819]{margin-top:.13333rem;width:auto;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;height:auto}.ac_r_btnArea>span[data-v-50459819]{max-height:1.6rem;padding:.13333rem .26667rem .13333rem .26667rem;background:hsla(0,0%,100%,.5490196078431373);border:.02667rem solid hsla(0,0%,100%,.5490196078431373);border-radius:.16rem;cursor:pointer;color:#000;font-size:.37333rem;margin-right:.53333rem}.chatAvatar[data-v-50459819]{width:1.06667rem;height:1.06667rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;font-size:.48rem;background:#fff;border-radius:100%}.chatName[data-v-50459819]{font-size:.37333rem;color:hsla(0,0%,100%,.5490196078431373);margin-bottom:.21333rem}.pa_openingRemarks[data-v-50459819]{width:100vw;height:100vh;position:fixed;bottom:0;left:0;z-index:3;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end}.pa_or_character[data-v-50459819]{width:8rem;height:5.33333rem;position:relative}.pa_or_character>img[data-v-50459819]{width:100%;position:absolute;bottom:-.64rem}.pa_or_bottom[data-v-50459819]{width:100%;background:hsla(0,0%,100%,.5490196078431373);height:6.66667rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:start;-webkit-justify-content:flex-start;-ms-flex-pack:start;justify-content:flex-start;box-sizing:border-box;padding:.8rem}.pa_or_bottom>span[data-v-50459819]{font-size:.42667rem;margin:.10667rem 0}.chatStatusMessage[data-v-50459819]{margin-bottom:.26667rem}.chatStatusMessageInputArea[data-v-50459819]{width:100%;height:auto;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.chatStatusMessageInputArea>span[data-v-50459819]{width:3em}.csm_message[data-v-50459819]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column}.csm_message>span[data-v-50459819]{margin-bottom:.26667rem}.csmia_btn[data-v-50459819]{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;height:.93333rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;font-size:.42667rem;background-color:#f0f2f5;color:rgba(0,0,0,.6);margin-top:.26667rem;border-radius:.16rem}.chatStatusMessageInputArea>.csmia_btn[data-v-50459819]:nth-of-type(2){margin-left:.26667rem;background-color:#3681fc;color:#fff}.chatStatusMessageInputArea[data-v-50459819] .chatStatusMessageInputAreaSelect{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;border-top:none;border-left:none;border-right:none}.chatStatusMessageInputArea[data-v-50459819] .chatStatusMessageInputAreaSelect .el-input__inner{border-top:none;border-left:none;border-right:none;border-radius:0}.ac_right>.chatMessage[data-v-50459819]{padding:.26667rem}.ac_r_ba_box[data-v-50459819]{width:100%;height:auto;margin-top:.26667rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.ac_r_ba_box>span[data-v-50459819]{padding:.13333rem .26667rem;border-radius:.16rem;background-color:#fff;color:rgba(0,0,0,.6);margin:.13333rem .26667rem .13333rem 0;font-size:.37333rem;border:.02667rem solid #fff;-webkit-transition:.3s;transition:.3s}.ac_r_ba_boxActive[data-v-50459819]{border:.02667rem solid #3681fc!important;background-color:#e0eafb!important;color:#3681fc!important}.pa_goIndex[data-v-50459819]{position:fixed;top:1.46667rem;right:.26667rem;width:auto;height:auto;z-index:5}.pa_goIndex>span[data-v-50459819]{padding:.26667rem .4rem;background-color:#3681fc;color:#fff;font-size:.42667rem;border-radius:.16rem}.csm_ia_item[data-v-50459819]{margin-top:.26667rem}.csm_ia_item>span[data-v-50459819]{margin:.13333rem 0}.csm_ia_btnArea[data-v-50459819]{-ms-flex-align:center;margin-top:.26667rem}.csm_ia_btnArea[data-v-50459819],.csm_ia_btnArea>span[data-v-50459819]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;align-items:center}.csm_ia_btnArea>span[data-v-50459819]{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;height:1.06667rem;font-size:.42667rem;border-radius:.16rem;background-color:#f0f2f5;color:rgba(0,0,0,.6);-ms-flex-align:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center}.csm_ia_btnArea>span[data-v-50459819]:nth-of-type(2){background-color:#3681fc;color:#fff;margin-left:.26667rem}",""]),t.exports=e}}]); //# sourceMappingURL=chunk-580bb60b.390a425c.js.map