!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports["video/player/remember-video-collection"]=t():e["video/player/remember-video-collection"]=t()}(globalThis,(()=>(()=>{var e,t,n={792:(e,t,n)=>{"use strict";n.d(t,{KX:()=>u,Lp:()=>l,MO:()=>s,bP:()=>f,dK:()=>p,e6:()=>m,hv:()=>a,vL:()=>c});var o=n(104),i=n(728);const r=".video-pod__slide",a=()=>dq(".video-pod"),s=e=>dqa(`.${e.join(", .")}`),c=e=>dq(`.video-pod__list [data-key="${e}"]`),d=()=>dq(`${r} .slide-item.active[data-slide-value]`),l=e=>!!e.firstElementChild&&e.firstElementChild.classList.contains("multi-p"),p=(e,t)=>e.querySelector(`.page-list .page-item:nth-child(${t})`),u=e=>Array.from(e.querySelectorAll(".page-list .page-item")),A=e=>{const t=e.querySelector(".title");return t instanceof HTMLElement?t:e instanceof HTMLElement?e:null},b=(e,t)=>{if(void 0===t)return null;const n=p(e,t);return n instanceof HTMLElement?A(n):null},v=e=>{const t=(e=>[e.bvid,e.cid].filter((e=>null!=e)).map(String))(e);for(const n of t){const t=c(n);if(!t)continue;if(l(t)){const n=b(t,e.page);if(n)return n;continue}const o=A(t);if(o)return o}return null},g=async e=>{if(void 0===e)return!1;const t=(n=String(e),dq(`${r} .slide-item[data-slide-value][data-slide-value="${n}"]`));var n;if(!(t instanceof HTMLElement))return!1;const o=d();if(o?.dataset.slideValue===String(e))return!0;t.click();const a=await(0,i.sq)((()=>d()),(t=>t?.dataset.slideValue===String(e)),{maxRetry:8,queryInterval:50});return Boolean(a)},m=async e=>{if((e=>{const t=v(e);return!!t&&(t.click(),!0)})(e))return!0;if(!await g(e.sectionId))return!1;const t=await(0,i.sq)((()=>v(e)),(e=>e instanceof HTMLElement),{maxRetry:8,queryInterval:50});return t instanceof HTMLElement&&(t.click(),!0)},f=e=>{const t=a();if(!t)return lodash.noop;const[n]=(0,o.childListSubtree)(t,lodash.debounce((t=>{0!==t.length&&e()}),50));return()=>n.disconnect()}},756:(e,t,n)=>{"use strict";n.d(t,{Dy:()=>p,F1:()=>C,Hg:()=>A,L_:()=>g,OZ:()=>m,ZR:()=>u,_d:()=>E,h_:()=>b,ig:()=>x,lv:()=>h,wS:()=>f});var o=n(761);const i=(e,t)=>{if((e?.length??0)<=1)return;const n=e?.findIndex((e=>e.cid===t))??-1;return n<0?void 0:n+1},r=e=>e?e.pages??(e.page?[e.page]:[]):[],a=e=>{const{bvid:t,cid:n,ugcSeason:o}=e,i=o?.sections?.flatMap((e=>e.episodes??[]))??[];return i.find((e=>r(e).some((e=>e.cid===n))))??i.find((e=>e.bvid===t))},s=e=>{if("number"==typeof e.cid)return i(e.pages,e.cid)??i(r(a(e)),e.cid)},c=e=>{const{ugcSeason:t}=e,n=a(e);if(n)return t?.sections?.find((e=>(e.episodes??[]).some((e=>e===n))))},d=e=>{const{ugcSeason:t}=e;return lodash.isEmpty(t)?{sectionId:void 0,sectionRootId:void 0,sectionsCount:0}:{sectionId:c(e)?.id,sectionRootId:t?.id,sectionsCount:t?.sections?.length??0}},l=e=>e?.trim()||void 0,p=e=>{if(!e.bvid||"number"!=typeof e.cid)return null;const{sectionId:t,sectionRootId:n}=d(e);return{bvid:e.bvid,cid:e.cid,page:s(e),sectionId:t,sectionRootId:n,timestamp:Date.now()}},u=e=>{const{bvid:t}=e,{sectionRootId:n,sectionsCount:o}=d(e);return 0===o?(e.pages?.length??0)>1?{bvid:t,type:"multi-p"}:null:o>1?{sectionRootId:n,type:"multi-sections"}:{sectionRootId:n,type:"sections"}},A=(e,t,n)=>{if(e){if("multi-p"===e.type)return`multi-p:${e.bvid??n?.bvid??""}`;if("sections"===e.type)return`sections:${e.sectionRootId??n?.sectionRootId??""}`;if("multi-sections"===e.type){const i=e.sectionRootId??n?.sectionRootId??"";return t===o.d.Split?`multi-sections:split:${i}:${n?.sectionId??e.sectionId??""}`:`multi-sections:unified:${i}`}return[e.type,e.bvid??n?.bvid??"",e.sectionRootId??n?.sectionRootId??"",t===o.d.Split?n?.sectionId??e.sectionId??"":""].join(":")}},b=(e,t)=>Array.isArray(e)&&0!==e.length&&t?"multi-p"===t.type?e.filter((e=>e.bvid===t.bvid)):"sections"===t.type?void 0===t.sectionRootId?[]:e.filter((e=>e.sectionRootId===t.sectionRootId)):"multi-sections"===t.type?void 0!==t.sectionRootId?e.filter((e=>e.sectionRootId===t.sectionRootId)):void 0!==t.sectionId?e.filter((e=>e.sectionId===t.sectionId)):[]:[]:[],v=(e,t)=>"multi-p"===t.type?e.bvid===t.bvid:("sections"===t.type||"multi-sections"===t.type)&&(void 0!==t.sectionRootId&&e.sectionRootId===t.sectionRootId),g=(e,t,n,i)=>{if(!t)return e;return n===o.d.Split&&"multi-sections"===t.type&&void 0!==i?.sectionRootId&&void 0!==i.sectionId?e.filter((e=>!(e.sectionRootId===i.sectionRootId&&e.sectionId===i.sectionId))):e.filter((e=>!v(e,t)))},m=(e,t,n,i)=>{if(!t)return[];return n===o.d.Split&&"multi-sections"===t.type&&void 0!==i?.sectionRootId&&void 0!==i.sectionId?e.filter((e=>e.sectionRootId===i.sectionRootId&&e.sectionId===i.sectionId)):e.filter((e=>v(e,t)))},f=(e,t,n)=>e?t===o.d.Split&&"multi-sections"===e.type&&void 0!==n?.sectionId?"将清除当前 TAB 下的合集记忆":"multi-p"===e.type?"将清除当前视频的合集记忆":"将清除当前合集的合集记忆":"当前页面没有可管理的合集记忆",C=(e,t,n,i)=>{if(e&&t){if("multi-p"===t.type)return l(e.title);if("sections"===t.type)return l(e.ugcSeason?.title);if("multi-sections"===t.type){const t=e.ugcSeason?.sections??[],r=t.find((e=>e.id===i?.sectionId))??(void 0!==i?.sectionId?t[i.sectionId]:void 0);return n===o.d.Split?l(r?.title)??l(e.ugcSeason?.title):l(e.ugcSeason?.title)}}},h=e=>e.sort(((e,t)=>e.timestamp-t.timestamp)),y=e=>[e.bvid,e.cid,e.page??"",e.sectionId??"",e.sectionRootId??""].join("|"),x=(e,t)=>{if(!t)return e;const n=y(t);return e.filter((e=>y(e)!==n))},E=(e,t)=>[...x(e,t),t]},523:(e,t,n)=>{"use strict";n.d(t,{_K:()=>T,cE:()=>I,cV:()=>M,iZ:()=>L,kv:()=>R,we:()=>k});var o=n(765),i=n(728),r=n(756),a=n(761),s=n(792);const c=(0,o.useScopedConsole)("remember-video-collection"),d="be-rvc-watched",l="be-rvc-last",p="be-rvc-multi-page",u="be-rvc-multi-page-all-watched",A="be-rvc-style-default",b="be-rvc-style-distinguish",v=[d,l,p,u],g=[A,b],m={maxRetry:15,queryInterval:200};let f=0,C=0;const h=e=>{e?.classList.remove(...g)},y=e=>{let{includeStyle:t}=e;(0,s.MO)([...v]).forEach((e=>{e.classList.remove(...v)})),t&&h((0,s.hv)())},x=e=>{const t=(e=>[e.bvid,e.cid].filter((e=>null!=e)).map(String))(e);for(const n of t){const t=(0,s.vL)(n);if(t)return!(0,s.Lp)(t)||void 0===e.page||null!==(0,s.dK)(t,e.page)}return!1},E=e=>{const t=[e.bvid,e.cid].filter((e=>null!=e)).map(String);if(0===t.length)return c.warn("applyInstruction skipped: empty instruction id.",e),!1;let n=null;for(const e of t)if(n=(0,s.vL)(e),n)break;if(!n)return c.warn("applyInstruction skipped: target not found.",{ids:t,instruction:e}),!1;const o="last-played"===e.type?l:d;if((0,s.Lp)(n)&&void 0!==e.page){n.classList.add(p,o),c.log("multipage podItemElement",n);const t=(0,s.dK)(n,e.page);return!!t&&(t.classList.add(o),!0)}return n.classList.add(o),!0},B=e=>{f=0,y({includeStyle:!1});let t=0;for(const n of e)E(n)&&t++;return(0,s.MO)([p]).forEach((e=>{const t=(0,s.KX)(e),n=t.length>0&&t.every((e=>e.classList.contains(d)||e.classList.contains(l)));e.classList.toggle(u,n)})),{appliedCount:t,totalCount:e.length}},w=e=>e===C,_=(e,t)=>{(async e=>{0!==e.length&&await(0,i.sq)((()=>{const t=(0,s.hv)();return t&&e.some(x)?t:null}),(e=>null!==e),m)})(e).then((async()=>{w(t)&&await(0,i.sq)((()=>w(t)?B(e):{appliedCount:0,totalCount:0}),((e,n)=>w(t)?0===e.totalCount||e.appliedCount>0:(n(),!0)),m)}))},k=()=>{C++,0!==f&&(cancelAnimationFrame(f),f=0),y({includeStyle:!0})},I=(e,t)=>{const n=++C;((e,t)=>{(0,i.sq)((()=>(0,s.hv)()),(e=>null!==e),m).then((n=>{n&&w(t)&&(h(n),n.classList.add(e===a.z.Distinguish?b:A),c.log("setMarkingStyle root",n))}))})(t,n),_(e,n)},S=e=>{const t=(0,r.lv)([...e]),n=t.length-1;return t.map(((e,t)=>({bvid:e.bvid,cid:e.cid,page:e.page,sectionId:e.sectionId,timestamp:e.timestamp,type:t===n?"last-played":"watched"})))},L=(e,t)=>Array.isArray(e)&&0!==e.length?t!==a.d.Split?S(e):Object.values(lodash.groupBy(e,(e=>e.sectionId))).flatMap(S):[],R=e=>(0,s.bP)(e),T=(e,t,n)=>n===a.d.Split?lodash.maxBy(lodash.filter(e,{type:"last-played",sectionId:t.sectionId}),"timestamp"):lodash.maxBy(lodash.filter(e,{type:"last-played"}),"timestamp"),M=(e,t)=>!t||e.bvid===t.bvid&&e.cid===t.cid&&e.page===t.page},148:(e,t,n)=>{"use strict";n.d(t,{aI:()=>A,tX:()=>b});var o=n(792),i=n(523);const r=e=>e?.trim()||void 0,a=e=>e?`第 ${e} P`:void 0,s=e=>e?e.pages??(e.page?[e.page]:[]):[],c=e=>r(e?.title),d=(e,t)=>e.bvid===t?.bvid&&e.cid===t?.cid&&e.page===t?.page&&e.sectionId===t?.sectionId,l=(e,t)=>{const n=e.ugcSeason?.sections??[];let o,i=0,r=-1;for(const e of n)for(const n of e.episodes??[]){i++,r++;const e=s(n),a=e.findIndex((e=>e.cid===t.cid));if(a>=0)return{episode:n,page:e[a],pageIndex:a+1,episodeOrder:i,episodeIndex:r};!o&&t.bvid&&n.bvid===t.bvid&&(o={episode:n,page:t.page&&t.page>0?s(n)[t.page-1]:void 0,pageIndex:t.page,episodeOrder:i,episodeIndex:r})}return o},p=(e,t)=>{if(!((t.ugcSeason?.sections?.length??0)>0)){const n=((e,t)=>{const n=e.pages??[],o=n.findIndex((e=>e.cid===t.cid));return o>=0?{page:n[o],pageIndex:o+1}:t.page&&t.page>0?{page:n[t.page-1],pageIndex:t.page}:{page:void 0,pageIndex:t.page}})(t,e),o=c(n.page),i=a(n.pageIndex);return o&&i?`${i} - ${o}`:o??i??e.bvid??String(e.cid??"")}const n=l(t,e),o=r(n?.episode?.title),i=c(n?.page),d=s(n?.episode).length,p=0===d||d>1?a(n?.pageIndex??e.page):void 0;if(o&&i&&i!==o)return`《${o}》 - ${i}`;if(o&&p)return`《${o}》的${p}`;if(o)return`《${o}》`;if(i){return`${n?.episodeOrder?`第 ${n.episodeOrder} 个视频`:"目标视频"} - ${i}`}if(p){return`${n?.episodeOrder?`第 ${n.episodeOrder} 个视频`:"目标视频"}的${p}`}return e.bvid??String(e.cid??"")},u=(e,t)=>(t.ugcSeason?.sections?.length??0)>0?((e,t)=>{const n=e.ugcSeason?.sections?.flatMap((e=>e.episodes??[]))??[],o=l(e,t),i=o?.episode;if(!o||!i)return;const r=s(i),a="number"==typeof o.pageIndex&&o.pageIndex>0?o.pageIndex-1:-1;if(r.length>1&&a>=0&&a1?1:void 0,sectionId:c.section_id}:void 0})(t,e):((e,t)=>{const n=e.pages??[];if(n.length<=1)return;let o=n.findIndex((e=>e.cid===t.cid));o<0&&(o=t.page&&t.page>0?t.page-1:-1);const i=n[o+1];return i?.cid?{bvid:e.bvid,cid:i.cid,page:o+2}:void 0})(t,e),A=async e=>!!await(0,o.e6)(e)||(e=>!!e.bvid&&(window.location.assign((e=>{const t=e.page&&e.page>1?`?p=${e.page}`:"";return`https://www.bilibili.com/video/${e.bvid}/${t}`})(e)),!0))(e),b=e=>{let{currentInstructions:t,currentMemory:n,currentDetail:o,sectionMode:r}=e;if(!n)return{lastPlayedInstruction:void 0,lastPlayedLabel:void 0,nextInstruction:void 0,nextLabel:void 0,canJumpLast:!1,canJumpNext:!1};const a=(0,i._K)(t,n,r),s=a?u(a,o):void 0,c=void 0===(l=s)||void 0===l.bvid&&void 0===l.cid?void 0:s;var l,A,b;return{lastPlayedInstruction:a,lastPlayedLabel:a?p(a,o):void 0,nextInstruction:c,nextLabel:c?p(c,o):void 0,canJumpLast:Boolean(a&&!d(n,a)),canJumpNext:Boolean(a&&c&&(A=c,b=a,!(A?.bvid===b?.bvid&&A?.cid===b?.cid&&A?.page===b?.page&&A?.sectionId===b?.sectionId))&&!d(n,c))}}},964:(e,t,n)=>{"use strict";n.d(t,{rememberVideoCollectionNamespaceProvider:()=>s});var o=n(905),i=n(444);const r="rememberVideoCollection",a=e=>{const t=e.trim().toUpperCase();return"ON"===t||"OFF"===t?t:null},s={displayName:"记忆合集",primaryName:r,description:"兼容「记忆合集」组件的恢复策略控制。ON 按原逻辑恢复并记忆合集进度,OFF 则跳过恢复且不记录当前合集记忆进度。",prepare:e=>{(0,i.JC)((0,i.R1)(e.video.aid,e.video.cid))},getTakeoverState:()=>(0,i.hg)(),setTakeoverState:e=>{(0,i.br)(e)},isComponentEnabled:()=>(0,o.getComponentSettings)(r).enabled,setup:e=>{(0,o.addComponentListener)(`${r}.useRbvp`,(()=>{e.requestApplyRules()}))},validateAction:e=>{if(null===a(e))throw new Error(`不支持的 rememberVideoCollection 动作值: ${e}`)},resolveAction:e=>{const t=a(e);return t?{namespace:r,value:t,displayValue:t}:null},execute:async(e,t)=>{const n="OFF"===e.value?"OFF":"ON",o=(0,i.R1)(t.video.aid,t.video.cid);return(0,i.uv)(n,o),"ON"===n&&await(0,i.dM)(o),`${r} => ${n}`}}},444:(e,t,n)=>{"use strict";n.d(t,{JC:()=>u,Lf:()=>l,QZ:()=>A,R1:()=>c,br:()=>f,dM:()=>g,hg:()=>m,oI:()=>b,uv:()=>p,xu:()=>v});var o=n(347),i=n(905);const r="rememberVideoCollection";let a=null,s=null;const c=function(){return`${(arguments.length>0&&void 0!==arguments[0]?arguments[0]:unsafeWindow.aid)??""}:${(arguments.length>1&&void 0!==arguments[1]?arguments[1]:unsafeWindow.cid)??""}`},d=()=>(0,i.getComponentSettings)(r).options,l=()=>{const e=(0,i.getComponentSettings)(r);return e.enabled&&e.options.useRbvp&&Boolean(o.componentsMap.rbvp)&&(0,i.getComponentSettings)("rbvp").enabled},p=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:c();a={videoKey:t,mode:e}},u=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c();a&&a.videoKey!==e||(a=null)},A=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c();return!l()||"ON"===function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c();return a?.videoKey===e?a.mode:null}(e)},b=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:c();s={videoKey:t,apply:e}},v=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c();s&&s.videoKey!==e||(s=null)},g=async function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c();return!(!s||s.videoKey!==e)&&(await s.apply(),!0)},m=()=>d().useRbvp,f=e=>{d().useRbvp=e}},20:(e,t,n)=>{"use strict";n.d(t,{A_:()=>C,FE:()=>E,Kp:()=>B,WA:()=>_,aH:()=>m,cp:()=>h,hB:()=>y,mz:()=>f,nj:()=>k,uz:()=>g,yU:()=>w});var o=n(905),i=n(5),r=n(756),a=n(148),s=n(761);const c="rememberVideoCollection",d="记忆合集进度",l=new Set,p={currentDetail:void 0,currentMemory:void 0,currentInstructions:[],historyScope:null,pendingJumpTargets:void 0,sectionMode:s.d.Split};let u={available:!1,canJumpLast:!1,canJumpNext:!1,canClear:!1,canClearAll:!1,clearDescription:"当前页面没有可管理的合集记忆",clearScopeButtonText:"清除当前作用域记忆",scopeLabel:"当前作用域",scopeTitle:void 0,scopedHistoryCount:0,totalHistoryCount:0};const A=()=>{l.forEach((e=>e({...u})))},b=(e,t,n)=>t===s.d.Split&&"multi-sections"===e?.type&&void 0!==n?.sectionId?"清除当前 TAB 记忆":"multi-p"===e?.type?"清除当前视频记忆":"sections"===e?.type?"清除当前合集记忆":"清除当前作用域记忆",v=()=>{const{currentDetail:e,currentMemory:t,historyScope:n,pendingJumpTargets:i,sectionMode:a}=p,d=Boolean(e&&t&&n),l=(0,o.getComponentSettings)(c).options.history,u=(0,r.OZ)(l,n,a,t),A=i??{lastPlayedInstruction:void 0,lastPlayedLabel:void 0,nextInstruction:void 0,nextLabel:void 0,canJumpLast:!1,canJumpNext:!1};return{available:d,canJumpLast:A.canJumpLast,canJumpNext:A.canJumpNext,canClear:u.length>0,canClearAll:l.length>0,clearDescription:(0,r.wS)(n,a,t),clearScopeButtonText:b(n,a,t),scopeLabel:a===s.d.Split&&"multi-sections"===n?.type&&void 0!==t?.sectionId?"当前 TAB":"当前作用域",scopeTitle:(0,r.F1)(e,n,a,t),scopedHistoryCount:u.length,totalHistoryCount:l.length,lastPlayedInstruction:A.lastPlayedInstruction,lastPlayedLabel:A.lastPlayedLabel,nextInstruction:A.nextInstruction,nextLabel:A.nextLabel}},g=e=>{Object.assign(p,e),u=v(),A()},m=()=>{p.currentDetail=void 0,p.currentMemory=void 0,p.currentInstructions=[],p.historyScope=null,p.pendingJumpTargets=void 0,p.sectionMode=s.d.Split,u=v(),A()},f=()=>({...u}),C=e=>(l.add(e),e({...u}),()=>l.delete(e)),h=e=>{p.pendingJumpTargets=e,u=v(),A()},y=()=>{h(void 0)},x=async(e,t)=>{if(!e)return!1;return await(0,a.aI)(e)?(y(),i.Toast.success(t,d,3e3),!0):(i.Toast.error("跳转失败",d,3e3),!1)},E=()=>x(u.lastPlayedInstruction,"已跳转到上次播放"),B=()=>x(u.nextInstruction,"已跳转到下一个视频"),w=()=>{const{currentMemory:e}=p;if(!e)return!1;const t=(0,o.getComponentSettings)(c),n=(0,r.ig)(t.options.history,e);return n.length!==t.options.history.length&&(t.options.history=n,y(),i.Toast.success("已清除当前视频记忆",d,3e3),!0)},_=()=>{const{historyScope:e,currentMemory:t,sectionMode:n}=p;if(!e)return!1;const a=(0,o.getComponentSettings)(c),s=(0,r.L_)(a.options.history,e,n,t);return s.length!==a.options.history.length&&(a.options.history=s,y(),i.Toast.success("已清除当前作用域的合集记忆",d,3e3),!0)},k=()=>{const e=(0,o.getComponentSettings)(c);return 0!==e.options.history.length&&(e.options.history=[],y(),i.Toast.success("已清除全部合集记忆",d,3e3),!0)}},761:(e,t,n)=>{"use strict";n.d(t,{d:()=>o,z:()=>i});let o=function(e){return e.Split="分别记忆",e.Unified="统一记忆",e}({}),i=function(e){return e.Default="不区分",e.Distinguish="区分",e}({})},120:(e,t,n)=>{var o=n(904),i=n(955)(o);i.push([e.id,".be-rvc-widget-popup {\n top: 50%;\n left: calc(100% + 8px);\n width: 304px;\n padding: 0;\n transform: translateY(-50%) scale(0.9);\n transform-origin: left;\n transition: 0.2s ease-out;\n background-color: #fff;\n box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.05);\n border-radius: 8px;\n border: none;\n}\nbody.dark .be-rvc-widget-popup {\n background-color: var(--be-color-panel-bg, #333);\n}\nbody.dark .be-rvc-widget-popup {\n box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.2);\n}\n.be-rvc-widget-popup.open {\n transform: translateY(-50%) scale(1);\n}\nbody.settings-panel-dock-right .be-rvc-widget-popup {\n right: calc(100% + 8px);\n left: unset;\n transform-origin: right;\n}\n.be-rvc-widget-panel {\n display: flex;\n flex-direction: column;\n gap: 12px;\n padding: 14px;\n}\n.be-rvc-widget-title {\n font-size: 14px;\n font-weight: 600;\n}\n.be-rvc-widget-tabs {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 8px;\n}\n.be-rvc-widget-tab {\n border: none;\n border-radius: 999px;\n padding: 7px 12px;\n background-color: #8881;\n color: inherit;\n font-size: 12px;\n font-weight: 500;\n cursor: pointer;\n transition: background-color 0.2s ease-out, box-shadow 0.2s ease-out;\n}\n.be-rvc-widget-tab:hover {\n background-color: #8882;\n}\n.be-rvc-widget-tab.active {\n background-color: var(--theme-color-20);\n box-shadow: 0 0 0 1px var(--theme-color-40);\n color: var(--theme-color);\n}\n.be-rvc-widget-tab-panel {\n display: flex;\n flex-direction: column;\n gap: 12px;\n}\n.be-rvc-widget-card {\n display: flex;\n flex-direction: column;\n gap: 4px;\n padding: 10px 12px;\n background-color: #8881;\n border-radius: 8px;\n}\n.be-rvc-widget-label {\n font-size: 12px;\n opacity: 0.7;\n}\n.be-rvc-widget-value {\n line-height: 1.5;\n word-break: break-word;\n}\n.be-rvc-widget-value.empty {\n opacity: 0.65;\n}\n.be-rvc-widget-count {\n color: var(--theme-color);\n font-weight: 600;\n}\n.be-rvc-widget-tip,\n.be-rvc-widget-hint {\n font-size: 12px;\n line-height: 1.5;\n opacity: 0.75;\n}\n.be-rvc-widget-actions {\n display: grid;\n grid-template-columns: 1fr;\n gap: 8px;\n}\n.be-rvc-widget-danger-tip {\n padding: 8px 10px;\n border-radius: 8px;\n background-color: rgba(244, 63, 94, 0.1);\n color: #b42318;\n font-size: 12px;\n line-height: 1.5;\n}\nbody.dark .be-rvc-widget-danger-tip {\n color: #ffb4b4;\n}\n.be-rvc-widget-danger-actions {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 8px;\n}\n.be-rvc-widget-danger.be-button:not(.disabled),\n.be-rvc-widget-danger-confirm.be-button:not(.disabled) {\n box-shadow: 0 0 0 1px rgba(244, 63, 94, 0.3) !important;\n background-color: rgba(244, 63, 94, 0.1) !important;\n color: #b42318;\n}\nbody.dark .be-rvc-widget-danger.be-button:not(.disabled),\nbody.dark .be-rvc-widget-danger-confirm.be-button:not(.disabled) {\n color: #ffb4b4;\n}\n.be-rvc-widget-danger.be-button:not(.disabled):hover, .be-rvc-widget-danger.be-button:not(.disabled):focus-within,\n.be-rvc-widget-danger-confirm.be-button:not(.disabled):hover,\n.be-rvc-widget-danger-confirm.be-button:not(.disabled):focus-within {\n box-shadow: 0 0 0 1px rgba(244, 63, 94, 0.45) !important;\n background-color: rgba(244, 63, 94, 0.16) !important;\n}","",{version:3,sources:["webpack://./registry/lib/components/video/player/remember-video-collection/Widget.vue"],names:[],mappings:"AAAA;EACE,QAAQ;EACR,sBAAsB;EACtB,YAAY;EACZ,UAAU;EACV,sCAAsC;EACtC,sBAAsB;EACtB,yBAAyB;EACzB,sBAAsB;EACtB,4CAA4C;EAC5C,kBAAkB;EAClB,YAAY;AACd;AACA;EACE,gDAAgD;AAClD;AACA;EACE,2CAA2C;AAC7C;AACA;EACE,oCAAoC;AACtC;AACA;EACE,uBAAuB;EACvB,WAAW;EACX,uBAAuB;AACzB;AAEA;EACE,aAAa;EACb,sBAAsB;EACtB,SAAS;EACT,aAAa;AACf;AAEA;EACE,eAAe;EACf,gBAAgB;AAClB;AAEA;EACE,aAAa;EACb,8BAA8B;EAC9B,QAAQ;AACV;AAEA;EACE,YAAY;EACZ,oBAAoB;EACpB,iBAAiB;EACjB,uBAAuB;EACvB,cAAc;EACd,eAAe;EACf,gBAAgB;EAChB,eAAe;EACf,oEAAoE;AACtE;AACA;EACE,uBAAuB;AACzB;AACA;EACE,uCAAuC;EACvC,2CAA2C;EAC3C,yBAAyB;AAC3B;AAEA;EACE,aAAa;EACb,sBAAsB;EACtB,SAAS;AACX;AAEA;EACE,aAAa;EACb,sBAAsB;EACtB,QAAQ;EACR,kBAAkB;EAClB,uBAAuB;EACvB,kBAAkB;AACpB;AAEA;EACE,eAAe;EACf,YAAY;AACd;AAEA;EACE,gBAAgB;EAChB,sBAAsB;AACxB;AACA;EACE,aAAa;AACf;AAEA;EACE,yBAAyB;EACzB,gBAAgB;AAClB;AAEA;;EAEE,eAAe;EACf,gBAAgB;EAChB,aAAa;AACf;AAEA;EACE,aAAa;EACb,0BAA0B;EAC1B,QAAQ;AACV;AAEA;EACE,iBAAiB;EACjB,kBAAkB;EAClB,wCAAwC;EACxC,cAAc;EACd,eAAe;EACf,gBAAgB;AAClB;AACA;EACE,cAAc;AAChB;AAEA;EACE,aAAa;EACb,8BAA8B;EAC9B,QAAQ;AACV;AAEA;;EAEE,uDAAuD;EACvD,mDAAmD;EACnD,cAAc;AAChB;AACA;;EAEE,cAAc;AAChB;AACA;;;EAGE,wDAAwD;EACxD,oDAAoD;AACtD",sourcesContent:[".be-rvc-widget-popup {\n top: 50%;\n left: calc(100% + 8px);\n width: 304px;\n padding: 0;\n transform: translateY(-50%) scale(0.9);\n transform-origin: left;\n transition: 0.2s ease-out;\n background-color: #fff;\n box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.05);\n border-radius: 8px;\n border: none;\n}\nbody.dark .be-rvc-widget-popup {\n background-color: var(--be-color-panel-bg, #333);\n}\nbody.dark .be-rvc-widget-popup {\n box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.2);\n}\n.be-rvc-widget-popup.open {\n transform: translateY(-50%) scale(1);\n}\nbody.settings-panel-dock-right .be-rvc-widget-popup {\n right: calc(100% + 8px);\n left: unset;\n transform-origin: right;\n}\n\n.be-rvc-widget-panel {\n display: flex;\n flex-direction: column;\n gap: 12px;\n padding: 14px;\n}\n\n.be-rvc-widget-title {\n font-size: 14px;\n font-weight: 600;\n}\n\n.be-rvc-widget-tabs {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 8px;\n}\n\n.be-rvc-widget-tab {\n border: none;\n border-radius: 999px;\n padding: 7px 12px;\n background-color: #8881;\n color: inherit;\n font-size: 12px;\n font-weight: 500;\n cursor: pointer;\n transition: background-color 0.2s ease-out, box-shadow 0.2s ease-out;\n}\n.be-rvc-widget-tab:hover {\n background-color: #8882;\n}\n.be-rvc-widget-tab.active {\n background-color: var(--theme-color-20);\n box-shadow: 0 0 0 1px var(--theme-color-40);\n color: var(--theme-color);\n}\n\n.be-rvc-widget-tab-panel {\n display: flex;\n flex-direction: column;\n gap: 12px;\n}\n\n.be-rvc-widget-card {\n display: flex;\n flex-direction: column;\n gap: 4px;\n padding: 10px 12px;\n background-color: #8881;\n border-radius: 8px;\n}\n\n.be-rvc-widget-label {\n font-size: 12px;\n opacity: 0.7;\n}\n\n.be-rvc-widget-value {\n line-height: 1.5;\n word-break: break-word;\n}\n.be-rvc-widget-value.empty {\n opacity: 0.65;\n}\n\n.be-rvc-widget-count {\n color: var(--theme-color);\n font-weight: 600;\n}\n\n.be-rvc-widget-tip,\n.be-rvc-widget-hint {\n font-size: 12px;\n line-height: 1.5;\n opacity: 0.75;\n}\n\n.be-rvc-widget-actions {\n display: grid;\n grid-template-columns: 1fr;\n gap: 8px;\n}\n\n.be-rvc-widget-danger-tip {\n padding: 8px 10px;\n border-radius: 8px;\n background-color: rgba(244, 63, 94, 0.1);\n color: #b42318;\n font-size: 12px;\n line-height: 1.5;\n}\nbody.dark .be-rvc-widget-danger-tip {\n color: #ffb4b4;\n}\n\n.be-rvc-widget-danger-actions {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 8px;\n}\n\n.be-rvc-widget-danger.be-button:not(.disabled),\n.be-rvc-widget-danger-confirm.be-button:not(.disabled) {\n box-shadow: 0 0 0 1px rgba(244, 63, 94, 0.3) !important;\n background-color: rgba(244, 63, 94, 0.1) !important;\n color: #b42318;\n}\nbody.dark .be-rvc-widget-danger.be-button:not(.disabled),\nbody.dark .be-rvc-widget-danger-confirm.be-button:not(.disabled) {\n color: #ffb4b4;\n}\n.be-rvc-widget-danger.be-button:not(.disabled):hover, .be-rvc-widget-danger.be-button:not(.disabled):focus-within,\n.be-rvc-widget-danger-confirm.be-button:not(.disabled):hover,\n.be-rvc-widget-danger-confirm.be-button:not(.disabled):focus-within {\n box-shadow: 0 0 0 1px rgba(244, 63, 94, 0.45) !important;\n background-color: rgba(244, 63, 94, 0.16) !important;\n}"],sourceRoot:""}]),e.exports=i},463:(e,t,n)=>{var o=n(904),i=n(955)(o);i.push([e.id,".remember-video-collection-extra-options {\n display: flex;\n flex-direction: column;\n gap: 8px;\n padding: 4px 0;\n}\n.remember-video-collection-extra-options-tip {\n font-size: 12px;\n opacity: 0.8;\n line-height: 1.5;\n}","",{version:3,sources:["webpack://./registry/lib/components/video/player/remember-video-collection/settings/ExtraOptions.vue"],names:[],mappings:"AAAA;EACE,aAAa;EACb,sBAAsB;EACtB,QAAQ;EACR,cAAc;AAChB;AACA;EACE,eAAe;EACf,YAAY;EACZ,gBAAgB;AAClB",sourcesContent:[".remember-video-collection-extra-options {\n display: flex;\n flex-direction: column;\n gap: 8px;\n padding: 4px 0;\n}\n.remember-video-collection-extra-options-tip {\n font-size: 12px;\n opacity: 0.8;\n line-height: 1.5;\n}"],sourceRoot:""}]),e.exports=i},379:(e,t,n)=>{var o=n(904),i=n(955)(o);i.push([e.id,'.be-rvc-watched:not(.be-rvc-multi-page) .title-txt,\n.be-rvc-watched:not(.be-rvc-multi-page) .title:not(:has(.title-txt)),\n.be-rvc-last:not(.be-rvc-multi-page) .title-txt,\n.be-rvc-last:not(.be-rvc-multi-page) .title:not(:has(.title-txt)) {\n opacity: 0.65;\n}\n.be-rvc-watched:not(.be-rvc-multi-page) .title::before,\n.be-rvc-last:not(.be-rvc-multi-page) .title::before {\n content: "";\n display: inline-block;\n width: 6px;\n height: 6px;\n min-width: 6px;\n margin-right: 6px;\n border-radius: 50%;\n vertical-align: middle;\n background: #9aa0a6;\n}\n\n.be-rvc-multi-page.be-rvc-multi-page-all-watched .title-txt {\n opacity: 0.65;\n}\n.be-rvc-multi-page .head .title::before {\n content: "";\n display: inline-block;\n width: 6px;\n height: 6px;\n min-width: 6px;\n margin-right: 6px;\n border-radius: 50%;\n vertical-align: middle;\n background: #9aa0a6;\n}\n\n.video-pod.be-rvc-style-distinguish .be-rvc-last:not(.be-rvc-multi-page) .title::before, .video-pod.be-rvc-style-distinguish .be-rvc-last.be-rvc-multi-page .head .title::before {\n background: var(--theme-color, #00a1d6);\n}\n.video-pod.be-rvc-style-distinguish .video-pod__list.grid .page.be-rvc-last::before {\n background: var(--theme-color, #00a1d6);\n}\n\n.video-pod__list.grid .page.be-rvc-watched, .video-pod__list.grid .page.be-rvc-last {\n position: relative;\n opacity: 0.65;\n}\n.video-pod__list.grid .page.be-rvc-watched::before, .video-pod__list.grid .page.be-rvc-last::before {\n content: "";\n position: absolute;\n top: -3px;\n right: -3px;\n width: 6px;\n height: 6px;\n border-radius: 50%;\n background: #9aa0a6;\n box-shadow: 0 0 0 2px var(--be-color-bg1, #2f3238);\n pointer-events: none;\n}\n\n.video-pod__body:has(.multip.grid) {\n overflow: visible !important;\n}\n\n.toast-card,\n.toast-card-message {\n overflow: visible;\n}\n\n.toast-card .be-rvc-prompt {\n display: flex;\n width: 100%;\n flex-direction: column;\n align-items: stretch;\n gap: 8px;\n}\n.toast-card .be-rvc-prompt-summary {\n color: var(--be-color-text-content, #000);\n line-height: 1.6;\n}\n.toast-card .be-rvc-prompt-targets {\n display: flex;\n flex-direction: column;\n gap: 8px;\n padding: 1px 0 2px;\n}\n.toast-card .be-rvc-prompt-target {\n display: flex;\n width: 100%;\n flex-direction: column;\n align-items: flex-start;\n gap: 6px;\n margin: 0;\n padding: 9px 10px;\n border: 1px solid rgba(128, 128, 128, 0.18);\n border-radius: 8px;\n background: rgba(128, 128, 128, 0.08);\n color: var(--be-color-text-content, #000);\n text-align: left;\n line-height: 1.5;\n word-break: break-word;\n cursor: pointer;\n appearance: none;\n transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background-color 0.16s ease;\n}\n.toast-card .be-rvc-prompt-target strong {\n font-weight: 600;\n}\n.toast-card .be-rvc-prompt-target-caption {\n display: inline-flex;\n align-items: center;\n padding: 1px 6px;\n border-radius: 999px;\n background: rgba(128, 128, 128, 0.1);\n color: inherit;\n font-size: 12px;\n line-height: 1.4;\n opacity: 0.72;\n}\n.toast-card .be-rvc-prompt-target-text {\n display: block;\n}\n.toast-card .be-rvc-prompt-target:hover {\n transform: translateY(-1px);\n border-color: rgba(128, 128, 128, 0.28);\n background: rgba(128, 128, 128, 0.12);\n box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);\n}\n.toast-card .be-rvc-prompt-target:active {\n transform: translateY(0);\n background: rgba(128, 128, 128, 0.16);\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);\n}',"",{version:3,sources:["webpack://./registry/lib/components/video/player/remember-video-collection/remember-video-collection.scss"],names:[],mappings:"AAAA;;;;EAIE,aAAa;AACf;AACA;;EAEE,WAAW;EACX,qBAAqB;EACrB,UAAU;EACV,WAAW;EACX,cAAc;EACd,iBAAiB;EACjB,kBAAkB;EAClB,sBAAsB;EACtB,mBAAmB;AACrB;;AAEA;EACE,aAAa;AACf;AACA;EACE,WAAW;EACX,qBAAqB;EACrB,UAAU;EACV,WAAW;EACX,cAAc;EACd,iBAAiB;EACjB,kBAAkB;EAClB,sBAAsB;EACtB,mBAAmB;AACrB;;AAEA;EACE,uCAAuC;AACzC;AACA;EACE,uCAAuC;AACzC;;AAEA;EACE,kBAAkB;EAClB,aAAa;AACf;AACA;EACE,WAAW;EACX,kBAAkB;EAClB,SAAS;EACT,WAAW;EACX,UAAU;EACV,WAAW;EACX,kBAAkB;EAClB,mBAAmB;EACnB,kDAAkD;EAClD,oBAAoB;AACtB;;AAEA;EACE,4BAA4B;AAC9B;;AAEA;;EAEE,iBAAiB;AACnB;;AAEA;EACE,aAAa;EACb,WAAW;EACX,sBAAsB;EACtB,oBAAoB;EACpB,QAAQ;AACV;AACA;EACE,yCAAyC;EACzC,gBAAgB;AAClB;AACA;EACE,aAAa;EACb,sBAAsB;EACtB,QAAQ;EACR,kBAAkB;AACpB;AACA;EACE,aAAa;EACb,WAAW;EACX,sBAAsB;EACtB,uBAAuB;EACvB,QAAQ;EACR,SAAS;EACT,iBAAiB;EACjB,2CAA2C;EAC3C,kBAAkB;EAClB,qCAAqC;EACrC,yCAAyC;EACzC,gBAAgB;EAChB,gBAAgB;EAChB,sBAAsB;EACtB,eAAe;EACf,gBAAgB;EAChB,6GAA6G;AAC/G;AACA;EACE,gBAAgB;AAClB;AACA;EACE,oBAAoB;EACpB,mBAAmB;EACnB,gBAAgB;EAChB,oBAAoB;EACpB,oCAAoC;EACpC,cAAc;EACd,eAAe;EACf,gBAAgB;EAChB,aAAa;AACf;AACA;EACE,cAAc;AAChB;AACA;EACE,2BAA2B;EAC3B,uCAAuC;EACvC,qCAAqC;EACrC,yCAAyC;AAC3C;AACA;EACE,wBAAwB;EACxB,qCAAqC;EACrC,wCAAwC;AAC1C",sourcesContent:['.be-rvc-watched:not(.be-rvc-multi-page) .title-txt,\n.be-rvc-watched:not(.be-rvc-multi-page) .title:not(:has(.title-txt)),\n.be-rvc-last:not(.be-rvc-multi-page) .title-txt,\n.be-rvc-last:not(.be-rvc-multi-page) .title:not(:has(.title-txt)) {\n opacity: 0.65;\n}\n.be-rvc-watched:not(.be-rvc-multi-page) .title::before,\n.be-rvc-last:not(.be-rvc-multi-page) .title::before {\n content: "";\n display: inline-block;\n width: 6px;\n height: 6px;\n min-width: 6px;\n margin-right: 6px;\n border-radius: 50%;\n vertical-align: middle;\n background: #9aa0a6;\n}\n\n.be-rvc-multi-page.be-rvc-multi-page-all-watched .title-txt {\n opacity: 0.65;\n}\n.be-rvc-multi-page .head .title::before {\n content: "";\n display: inline-block;\n width: 6px;\n height: 6px;\n min-width: 6px;\n margin-right: 6px;\n border-radius: 50%;\n vertical-align: middle;\n background: #9aa0a6;\n}\n\n.video-pod.be-rvc-style-distinguish .be-rvc-last:not(.be-rvc-multi-page) .title::before, .video-pod.be-rvc-style-distinguish .be-rvc-last.be-rvc-multi-page .head .title::before {\n background: var(--theme-color, #00a1d6);\n}\n.video-pod.be-rvc-style-distinguish .video-pod__list.grid .page.be-rvc-last::before {\n background: var(--theme-color, #00a1d6);\n}\n\n.video-pod__list.grid .page.be-rvc-watched, .video-pod__list.grid .page.be-rvc-last {\n position: relative;\n opacity: 0.65;\n}\n.video-pod__list.grid .page.be-rvc-watched::before, .video-pod__list.grid .page.be-rvc-last::before {\n content: "";\n position: absolute;\n top: -3px;\n right: -3px;\n width: 6px;\n height: 6px;\n border-radius: 50%;\n background: #9aa0a6;\n box-shadow: 0 0 0 2px var(--be-color-bg1, #2f3238);\n pointer-events: none;\n}\n\n.video-pod__body:has(.multip.grid) {\n overflow: visible !important;\n}\n\n.toast-card,\n.toast-card-message {\n overflow: visible;\n}\n\n.toast-card .be-rvc-prompt {\n display: flex;\n width: 100%;\n flex-direction: column;\n align-items: stretch;\n gap: 8px;\n}\n.toast-card .be-rvc-prompt-summary {\n color: var(--be-color-text-content, #000);\n line-height: 1.6;\n}\n.toast-card .be-rvc-prompt-targets {\n display: flex;\n flex-direction: column;\n gap: 8px;\n padding: 1px 0 2px;\n}\n.toast-card .be-rvc-prompt-target {\n display: flex;\n width: 100%;\n flex-direction: column;\n align-items: flex-start;\n gap: 6px;\n margin: 0;\n padding: 9px 10px;\n border: 1px solid rgba(128, 128, 128, 0.18);\n border-radius: 8px;\n background: rgba(128, 128, 128, 0.08);\n color: var(--be-color-text-content, #000);\n text-align: left;\n line-height: 1.5;\n word-break: break-word;\n cursor: pointer;\n appearance: none;\n transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background-color 0.16s ease;\n}\n.toast-card .be-rvc-prompt-target strong {\n font-weight: 600;\n}\n.toast-card .be-rvc-prompt-target-caption {\n display: inline-flex;\n align-items: center;\n padding: 1px 6px;\n border-radius: 999px;\n background: rgba(128, 128, 128, 0.1);\n color: inherit;\n font-size: 12px;\n line-height: 1.4;\n opacity: 0.72;\n}\n.toast-card .be-rvc-prompt-target-text {\n display: block;\n}\n.toast-card .be-rvc-prompt-target:hover {\n transform: translateY(-1px);\n border-color: rgba(128, 128, 128, 0.28);\n background: rgba(128, 128, 128, 0.12);\n box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);\n}\n.toast-card .be-rvc-prompt-target:active {\n transform: translateY(0);\n background: rgba(128, 128, 128, 0.16);\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);\n}'],sourceRoot:""}]),e.exports=i},955:e=>{"use strict"; // eslint-disable-next-line func-names e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=e(t);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")}, // eslint-disable-next-line func-names t.i=function(e,n,o){"string"==typeof e&&( // eslint-disable-next-line no-param-reassign e=[[null,e,""]]);var i={};if(o)for(var r=0;r{"use strict";function t(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null==n)return;var o,i,r=[],a=!0,s=!1;try{for(n=n.call(e);!(a=(o=n.next()).done)&&(r.push(o.value),!t||r.length!==t);a=!0);}catch(e){s=!0,i=e}finally{try{a||null==n.return||n.return()}finally{if(s)throw i}}return r}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return n(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return Array.from(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return n(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n{"use strict";var o,i=function(){return void 0===o&&( // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 // @see https://github.com/webpack-contrib/style-loader/issues/177 o=Boolean(window&&document&&document.all&&!window.atob)),o},r=function(){var e={};return function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}e[t]=n}return e[t]}}(),a=[];function s(e){for(var t=-1,n=0;n{var o=n(379);o&&o.__esModule&&(o=o.default),e.exports="string"==typeof o?o:o.toString()},74:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var o=function(){var e=this,t=e._self._c;e._self._setupProxy;return t("div",{staticClass:"multiple-widgets"},[t("VPopup",{staticClass:"be-rvc-widget-popup widgets-popup",attrs:{"trigger-element":e.$refs.button},model:{value:e.open,callback:function(t){e.open=t},expression:"open"}},[t("div",{staticClass:"be-rvc-widget-panel"},[t("div",{staticClass:"be-rvc-widget-title"},[e._v("合集记忆")]),e._v(" "),t("div",{staticClass:"be-rvc-widget-tabs",attrs:{role:"tablist","aria-label":"合集记忆功能页签"}},[t("button",{staticClass:"be-rvc-widget-tab",class:{active:"resume"===e.activeTab},attrs:{type:"button"},on:{click:function(t){e.activeTab="resume"}}},[e._v("\n 上次播放\n ")]),e._v(" "),t("button",{staticClass:"be-rvc-widget-tab",class:{active:"manage"===e.activeTab},attrs:{type:"button"},on:{click:function(t){e.activeTab="manage"}}},[e._v("\n 记忆管理\n ")])]),e._v(" "),"resume"===e.activeTab?t("div",{staticClass:"be-rvc-widget-tab-panel"},[t("div",{staticClass:"be-rvc-widget-card"},[t("div",{staticClass:"be-rvc-widget-label"},[e._v("上次播放")]),e._v(" "),t("div",{staticClass:"be-rvc-widget-value",class:{empty:!e.state.lastPlayedLabel}},[e._v("\n "+e._s(e.lastPlayedText)+"\n ")])]),e._v(" "),t("div",{staticClass:"be-rvc-widget-card"},[t("div",{staticClass:"be-rvc-widget-label"},[e._v("下一个")]),e._v(" "),t("div",{staticClass:"be-rvc-widget-value",class:{empty:!e.state.nextLabel}},[e._v("\n "+e._s(e.nextText)+"\n ")])]),e._v(" "),e.state.available&&e.state.lastPlayedLabel&&!e.state.canJumpLast?t("div",{staticClass:"be-rvc-widget-tip"},[e._v("\n 当前已经位于上次播放位置。\n ")]):e._e(),e._v(" "),t("div",{staticClass:"be-rvc-widget-actions"},[t("VButton",{attrs:{type:"primary",disabled:!e.state.canJumpLast},on:{click:e.handleJumpLast}},[e._v("\n 跳转到上次播放\n ")]),e._v(" "),t("VButton",{attrs:{disabled:!e.state.canJumpNext},on:{click:e.handleJumpNext}},[e._v("跳转到下一个")])],1)]):t("div",{staticClass:"be-rvc-widget-tab-panel"},[t("div",{staticClass:"be-rvc-widget-card"},[t("div",{staticClass:"be-rvc-widget-label"},[e._v("当前作用域")]),e._v(" "),t("div",{staticClass:"be-rvc-widget-value"},[t("span",[e._v(e._s(e.scopeSummaryPrefixText))]),e._v(" "),t("span",{staticClass:"be-rvc-widget-count"},[e._v(e._s(e.scopeSummaryCountText))])]),e._v(" "),t("div",{staticClass:"be-rvc-widget-hint"},[e._v(e._s(e.state.clearDescription))])]),e._v(" "),t("div",{staticClass:"be-rvc-widget-card"},[t("div",{staticClass:"be-rvc-widget-label"},[e._v("全部记忆")]),e._v(" "),t("div",{staticClass:"be-rvc-widget-value"},[t("span",[e._v("全部记忆 • ")]),e._v(" "),t("span",{staticClass:"be-rvc-widget-count"},[e._v(e._s(e.state.totalHistoryCount)+" 个视频")])]),e._v(" "),t("div",{staticClass:"be-rvc-widget-hint"},[e._v("清除全部记忆是危险操作,确认后无法恢复。")])]),e._v(" "),t("div",{staticClass:"be-rvc-widget-actions"},[t("VButton",{attrs:{disabled:!e.state.canClear},on:{click:e.handleClearHistory}},[e._v("\n "+e._s(e.state.clearScopeButtonText)+"\n ")]),e._v(" "),e.confirmClearAll?[t("div",{staticClass:"be-rvc-widget-danger-tip"},[e._v("\n 这是危险操作,会清除所有合集记忆。确认后无法恢复。\n ")]),e._v(" "),t("div",{staticClass:"be-rvc-widget-danger-actions"},[t("VButton",{staticClass:"be-rvc-widget-danger-confirm",attrs:{type:"primary",disabled:!e.state.canClearAll},on:{click:e.handleConfirmClearAll}},[e._v("\n 确认清除全部记忆\n ")]),e._v(" "),t("VButton",{on:{click:function(t){e.confirmClearAll=!1}}},[e._v("取消")])],1)]:t("VButton",{staticClass:"be-rvc-widget-danger",attrs:{disabled:!e.state.canClearAll},on:{click:function(t){e.confirmClearAll=!0}}},[e._v("\n 清除全部记忆\n ")])],2)])])]),e._v(" "),t("DefaultWidget",{ref:"button",attrs:{icon:"mdi-history"},on:{click:function(t){e.open=!e.open}}},[t("span",[e._v("合集记忆")])])],1)};o._withStripped=!0;var i=n(164),r=n(20);const a=Vue.extend({components:{DefaultWidget:i.DefaultWidget,VButton:i.VButton,VPopup:i.VPopup},data:()=>({open:!1,activeTab:"resume",confirmClearAll:!1,state:(0,r.mz)(),unsubscribe:null}),computed:{lastPlayedText(){return this.state.lastPlayedLabel?this.state.lastPlayedLabel:this.state.available?"当前作用域暂无上次播放记录":"当前页面没有可用的合集记忆"},nextText(){return this.state.nextLabel?this.state.nextLabel:this.state.available?"没有可跳转的下一个视频":"当前页面没有可用的合集记忆"},scopeSummaryPrefixText(){return this.state.scopeTitle?`${this.state.scopeTitle} • `:`${this.state.scopeLabel} • `},scopeSummaryCountText(){return`${this.state.scopedHistoryCount} 个视频`}},watch:{open(e){e||(this.activeTab="resume",this.confirmClearAll=!1)},activeTab(e){"manage"!==e&&(this.confirmClearAll=!1)}},mounted(){this.unsubscribe=(0,r.A_)((e=>{this.state=e,e.canClearAll||(this.confirmClearAll=!1)}))},beforeDestroy(){this.unsubscribe?.(),this.unsubscribe=null},methods:{async handleJumpLast(){await(0,r.FE)()&&(this.confirmClearAll=!1,this.open=!1)},async handleJumpNext(){await(0,r.Kp)()&&(this.confirmClearAll=!1,this.open=!1)},handleClearHistory(){(0,r.WA)(),this.confirmClearAll=!1},handleConfirmClearAll(){(0,r.nj)()&&(this.confirmClearAll=!1)}}});var s=n(991),c=n.n(s),d=n(120),l=n.n(d),p={insert:"head",singleton:!1};c()(l(),p);l().locals;const u=(0,n(678).A)(a,o,[],!1,null,null,null).exports},668:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>b});var o=function(){var e=this,t=e._self._c;e._self._setupProxy;return e.hasRbvp?t("div",{staticClass:"remember-video-collection-extra-options"},[t("CheckBox",{model:{value:e.useRbvp,callback:function(t){e.useRbvp=t},expression:"useRbvp"}},[e._v("交由 RBVP 决定恢复策略")]),e._v(" "),t("div",{staticClass:"remember-video-collection-extra-options-tip"},[e._v("\n 启用后,「记忆合集」不再自行决定是否恢复和记录合集进度,而是由 RBVP 通过\n `rememberVideoCollection:ON` / `rememberVideoCollection:OFF` 控制当前视频的行为。\n ")])],1):e._e()};o._withStripped=!0;var i=n(347),r=n(905),a=n(164),s=n(444);const c=Vue.extend({components:{CheckBox:a.CheckBox},computed:{hasRbvp:()=>Boolean(i.componentsMap.rbvp)&&(0,r.getComponentSettings)("rbvp").enabled,useRbvp:{get:()=>(0,s.hg)(),set(e){(0,s.br)(e)}}}});var d=n(991),l=n.n(d),p=n(463),u=n.n(p),A={insert:"head",singleton:!1};l()(u(),A);u().locals;const b=(0,n(678).A)(c,o,[],!1,null,null,null).exports},678:(e,t,n)=>{"use strict";function o(e,t,n,o,i,r,a,s){var c,d="function"==typeof e?e.options:e;if(t&&(d.render=t,d.staticRenderFns=n,d._compiled=!0),o&&(d.functional=!0),r&&(d._scopeId="data-v-"+r),a?(c=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},d._ssrRegister=c):i&&(c=s?function(){i.call(this,(d.functional?this.parent:this).$root.$options.shadowRoot)}:i),c)if(d.functional){d._injectStyles=c;var l=d.render;d.render=function(e,t){return c.call(t),l(e,t)}}else{var p=d.beforeCreate;d.beforeCreate=p?[].concat(p,c):[c]}return{exports:e,options:d}}n.d(t,{A:()=>o})},430:e=>{function t(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}t.keys=()=>[],t.resolve=t,t.id=430,e.exports=t},237:e=>{"use strict";e.exports="> 记忆合集与多 P 视频的播放进度,在列表中标记已观看/上次播放位置,并提供跳转提示与记忆管理功能面板.\n\n#### 🔧 **选项**\n\n- `标记样式`:控制视频列表中已观看和上次播放视频的视觉标记方式。「不区分」使用相同的标记样式,「区分」则对「上次播放」和「已观看」使用不同的标记样式.\n- `多TAB合集模式`:对于包含多个 TAB 分区的合集,「分别记忆」为每个 TAB 单独记录播放进度,「统一记忆」则将整个合集视为一个整体进行记忆.\n- `提示是否跳转到上次播放`:打开此选项后,每次进入合集页面时若检测到上次播放位置与当前不一致,将弹出提示框询问是否跳转到上次播放位置,同时可一键跳转到下一个视频.\n- `交由 RBVP 决定恢复策略`:打开此选项后,「记忆合集」不再自行决定是否恢复和记录合集进度,而是作为 RBVP 的兼容存储层使用.\n - 此选项仅在安装并启用 RBVP 组件后可见.\n\n#### ⌨️ **快捷键**\n\n组件安装后会自动注册以下快捷键(可在「插件 - 快捷键扩展」中自定义):\n\n- `Shift + H`:跳转到上次播放\n- `Shift + N`:跳转到下一个视频\n- `Shift + Delete`:清除当前视频的合集记忆\n\n#### 📋 **侧栏面板**\n\n点击播放器侧栏的「合集记忆」按钮可打开面板,包含两个页签:\n\n- **上次播放**:查看上次播放和下一个视频信息,并提供一键跳转按钮.\n- **记忆管理**:查看当前作用域及全部记忆的视频数量,支持清除当前作用域或全部合集记忆.\n\n#### 🔗 **RBVP 联动**\n\n在 RBVP 规则中可通过命名空间 `rememberVideoCollection` 调用本组件(别名可在 RBVP 设置 - 命名空间页自定义,写入主规则文本),支持以下动作值:\n\n- `ON`:按原逻辑恢复并记录合集进度\n- `OFF`:跳过恢复且不记录当前合集记忆进度\n\n使用前需先开启选项「交由 RBVP 决定恢复策略」.\n\n#### 🌈 **温馨提示**\n\n「记忆合集」的记忆数据均存储在本地,不会上传到服务器.\n\n如需管理或清除特定视频的记忆,可在播放页面使用快捷键或侧栏面板操作.\n"},347:e=>{"use strict";e.exports=coreApis.componentApis.component},104:e=>{"use strict";e.exports=coreApis.observer},905:e=>{"use strict";e.exports=coreApis.settings},728:e=>{"use strict";e.exports=coreApis.spinQuery},5:e=>{"use strict";e.exports=coreApis.toast},164:e=>{"use strict";e.exports=coreApis.ui},765:e=>{"use strict";e.exports=coreApis.utils.log}},o={};function i(e){var t=o[e];if(void 0!==t)return t.exports;var r=o[e]={id:e,exports:{}};return n[e](r,r.exports,i),r.exports}i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(n,o){if(1&o&&(n=this(n)),8&o)return n;if("object"==typeof n&&n){if(4&o&&n.__esModule)return n;if(16&o&&"function"==typeof n.then)return n}var r=Object.create(null);i.r(r);var a={};e=e||[null,t({}),t([]),t(t)];for(var s=2&o&&n;"object"==typeof s&&!~e.indexOf(s);s=t(s))Object.getOwnPropertyNames(s).forEach((e=>a[e]=()=>n[e]));return a.default=()=>n,i.d(r,a),r},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var r={};return(()=>{"use strict";i.d(r,{component:()=>j});const e=coreApis.componentApis.define,t=coreApis.componentApis.video.videoInfo;var n=i(104),o=i(905),a=i(5),s=i(765);const c=coreApis.utils.urls;var d=i(756),l=i(523),p=i(761),u=i(148);const A=async e=>{let{currentInstructions:t,currentMemory:n,currentDetail:o,enabled:i,signal:r,title:s,sectionMode:c}=e;const{lastPlayedInstruction:d,nextInstruction:A,canJumpNext:b}=(0,u.tX)({currentInstructions:t,currentMemory:n,currentDetail:o,sectionMode:c});if(!i||r?.aborted||!d||(0,l.cV)(n,d))return{action:"continue",lastPlayedInstruction:d};const v=await(async(e,t,n,o,i)=>{if(i?.aborted)return"ignore";const r=lodash.uniqueId("remember-video-collection-"),{nextLabel:s,canJumpNext:c,lastPlayedLabel:d}=(0,u.tX)({currentInstructions:[e],currentMemory:t,currentDetail:n,sectionMode:p.d.Unified}),l=d?``:"",A=c&&s?``:"",b=a.Toast.info(`
\n
检测到上次播放位置与当前不一致,点击下方卡片即可跳转:
\n
\n ${l}\n ${A}\n
\n
`,o,1e4);return new Promise((e=>{let t=!1;const n=[],o=o=>{t||(t=!0,n.forEach((e=>e())),b.close(),e(o))},a=window.setTimeout((()=>o("ignore")),1e4);if(n.push((()=>clearTimeout(a))),i){const e=()=>o("ignore");i.addEventListener("abort",e,{once:!0}),n.push((()=>i.removeEventListener("abort",e)))}b.element.then((e=>{if(t||!(e instanceof HTMLElement))return;const i=(t,i)=>{const r=e.querySelector(t);if(!(r instanceof HTMLElement))return;const a=e=>{e.preventDefault(),e.stopPropagation(),o(i)};r.addEventListener("click",a),n.push((()=>r.removeEventListener("click",a)))};i(`[data-rvc-action="jump-${r}"]`,"jump"),c&&i(`[data-rvc-action="jump-next-${r}"]`,"jump-next");const a=e.querySelector(".toast-card-close");if(a instanceof HTMLElement){const e=()=>o("ignore");a.addEventListener("click",e),n.push((()=>a.removeEventListener("click",e)))}}))}))})(d,n,o,s,r);if("jump"!==v&&"jump-next"!==v||r?.aborted)return{action:"continue",lastPlayedInstruction:d};const g="jump-next"===v&&b?A:d;return{action:v,lastPlayedInstruction:d,jumpSucceeded:await(0,u.aI)(g)}};var b=i(444),v=i(20);const g=(0,s.useScopedConsole)("rememberVideoCollection"),m="rememberVideoCollection",f="记忆合集";let C=[],h=null,y=lodash.noop,x=null,E=0,B=null,w=null,_=null;const k=e=>{h&&(0,l.cE)(C,e?.markingStyle??h.options.markingStyle)},I=()=>{(0,v.uz)({currentInstructions:C,currentDetail:B??void 0,currentMemory:_,historyScope:w,sectionMode:h?.options.sectionMode??p.d.Split})},S=(e,t,n)=>({displayName:e,run:async()=>{const e=(0,o.getComponentSettings)(m).enabled?(0,v.mz)().available?void 0:"当前页面没有可用的合集记忆":"组件已禁用,不能使用合集记忆快捷键";return e?(a.Toast.error(e,f,5e3),!0):(await t()||a.Toast.info(n(),f,3e3),!0)}}),L=e=>{if(!h||!w)return C=[],k(),void I();const t=e?.forceApply||(0,b.QZ)(e?.videoKey??(0,b.R1)(B?.aid,B?.cid))?(0,d.h_)(h.options.history,w):[];g.info("scopedHistory",t),C=(0,l.iZ)(t,h.options.sectionMode),g.info("currentInstructions",C),k(),I()},R=e=>k({markingStyle:e}),T=()=>L(),M=()=>L(),V=()=>{ // eslint-disable-next-line @typescript-eslint/no-use-before-define $(f)},P=()=>{E++,x?.abort(),x=null,(0,o.removeComponentListener)(`${m}.markingStyle`,R),(0,o.removeComponentListener)(`${m}.history`,T),(0,o.removeComponentListener)(`${m}.sectionMode`,M),(0,o.removeComponentListener)(`${m}.useRbvp`,V),y(),y=lodash.noop,C=[],B=null,w=null,_=null,(0,b.xu)(),(0,b.JC)(),(0,l.we)(),(0,v.aH)()},$=async e=>{if(P(),!h)return;(0,o.addComponentListener)(`${m}.markingStyle`,R,!0),(0,o.addComponentListener)(`${m}.history`,T),(0,o.addComponentListener)(`${m}.sectionMode`,M),(0,o.addComponentListener)(`${m}.useRbvp`,V);const i=++E,r=new AbortController;x=r;let s,c=0,p=!0;await(0,n.videoChange)((async n=>{if(r.signal.aborted||i!==E)return;const o=++c,m=new t.VideoInfo(n.aid);let x;try{x=await m.fetchInfo(),x.cid=Number(n.cid)}catch(e){return void(r.signal.aborted||i!==E||o!==c||g.warn("failed to fetch video info",e))}if(r.signal.aborted||i!==E||o!==c)return;const S=(0,b.R1)(x.aid,x.cid);if(B=x,g.info("video detail",x),w=(0,d.ZR)(x),g.info("historyScope",w),!w)return p=!1,s=void 0,C=[],_=null,(0,b.xu)(S),(0,v.hB)(),k(),y(),void I();let R=h.options.history;L({videoKey:S}),y(),y=(0,l.kv)((()=>{k()})),_=(0,d.Dy)(x),g.info("currentMemory",_);const T=(0,d.Hg)(w,h.options.sectionMode,_);g.info("visitKey",T);const M=p||T!==s;if(g.info("isFirstLoad",M),p=!1,s=T,!_)return M&&((0,b.xu)(S),(0,v.hB)()),void I();let V=!1;const P=async()=>{if(!V&&!r.signal.aborted&&i===E){if(V=!0,L({videoKey:S}),M){const e=(0,u.tX)({currentInstructions:C,currentMemory:_,currentDetail:x,sectionMode:h.options.sectionMode});(0,v.cp)(e.canJumpLast?e:void 0)}if(I(),M){const t=await A({currentInstructions:C,currentMemory:_,currentDetail:x,enabled:h.options.showPrompt,signal:r.signal,title:e,sectionMode:h.options.sectionMode});if(r.signal.aborted||i!==E)return;if(g.info("first load prompt result",t),"jump"===t.action||"jump-next"===t.action)return t.jumpSucceeded?(0,v.hB)():(g.warn("failed to jump to last played instruction",t.lastPlayedInstruction),a.Toast.error("跳转失败",f)),void(0,b.xu)(S)}R=(0,d._d)(R,_),h.options.history=R,g.info("currentHistory",R),L(),(0,b.xu)(S)}};if((0,b.Lf)())return(0,b.oI)(P,S),(0,b.QZ)(S)?void await P():(M&&(0,v.hB)(),void I());(0,b.xu)(S),await P()}),{signal:r.signal})},j=(0,e.defineComponentMetadata)({name:m,displayName:f,author:{name:"JLoeve (with Kilo Code & Codex)",link:"https://github.com/LonelySteve"},tags:[componentsTags.video],urlInclude:c.playerUrls,instantStyles:[{name:"rememberVideoCollection",style:()=>Promise.resolve().then(i.t.bind(i,873,23))}],widget:{component:()=>Promise.resolve().then(i.bind(i,74)).then((e=>e.default))},plugin:{displayName:"合集记忆 - 快捷键支持",setup:async e=>{let{addData:t}=e;const{rememberVideoCollectionNamespaceProvider:n}=await Promise.resolve().then(i.bind(i,964));t("keymap.actions",(e=>{e.rememberVideoCollectionJumpLast=S("合集记忆:跳转到上次播放",(()=>!!(0,v.mz)().canJumpLast&&(0,v.FE)()),(()=>(0,v.mz)().lastPlayedLabel?"当前已经位于上次播放位置":"当前作用域暂无上次播放记录")),e.rememberVideoCollectionJumpNext=S("合集记忆:跳转到下一个",(()=>!!(0,v.mz)().canJumpNext&&(0,v.Kp)()),(()=>"没有可跳转的下一个视频")),e.rememberVideoCollectionClearCurrent=S("合集记忆:清除当前视频记忆",v.yU,(()=>"当前视频暂无可清除的合集记忆"))})),t("keymap.presets",(e=>{e.rememberVideoCollectionJumpLast="shift h",e.rememberVideoCollectionJumpNext="shift n",e.rememberVideoCollectionClearCurrent="shift delete"})),t("rbvp.namespaces",(e=>{delete e.collection,e.rememberVideoCollection=n}))}},options:{history:{defaultValue:[],hidden:!0},markingStyle:{defaultValue:p.z.Distinguish,displayName:"标记样式",dropdownEnum:p.z},sectionMode:{defaultValue:p.d.Split,displayName:"多TAB合集模式",dropdownEnum:p.d},showPrompt:{defaultValue:!0,displayName:"提示是否跳转到上次播放"},useRbvp:{defaultValue:!1,displayName:"交由 RBVP 决定恢复策略",hidden:!0}},extraOptions:()=>Promise.resolve().then(i.bind(i,668)).then((e=>e.default)),entry:async e=>{let{metadata:t,settings:n}=e;h=n,await $(t.displayName)},reload:()=>$(f),unload:P,commitHash:"867cbe391f1b6db8bbf006534335b241d479fc41",coreVersion:"2.11.5",description:(()=>{const e=i(430);return{...Object.fromEntries(e.keys().map((t=>[t.match(/index\.(.+)\.md$/)[1],e(t)]))),"zh-CN":()=>Promise.resolve().then(i.t.bind(i,237,17)).then((e=>e.default))}})()})})(),r=r.component})())); //# sourceMappingURL=https://raw.githubusercontent.com/the1812/Bilibili-Evolved/master/registry/dist/components/video/player/remember-video-collection.js.map