import{_ as l,c as p,o,x as s,a as n,U as a}from"./chunks/framework.75837252.js";const w=JSON.parse('{"title":"设置面板","description":"","frontmatter":{},"headers":[],"relativePath":"start/setting.md","lastUpdated":1674271220000}'),e={name:"start/setting.md"},t=s("h1",{id:"设置面板",tabindex:"-1"},[n("设置面板 "),s("a",{class:"header-anchor",href:"#设置面板","aria-label":'Permalink to "设置面板"'},"")],-1),c=s("p",null,[n("需先打开设置面板,播放器默认自带四个设置项:"),s("code",null,"flip"),n(", "),s("code",null,"playbackRate"),n(", "),s("code",null,"aspectRatio"),n(", "),s("code",null,"subtitleOffset")],-1),r=s("div",{className:"run-code"},"▶ Run Code",-1),D=a(`
js
var art =newArtplayer({container:'.artplayer-app',url:'/assets/sample/video.mp4',setting:true,flip:true,playbackRate:true,aspectRatio:true,subtitleOffset:true,});
`,3),i=s("div",{className:"run-code"},"▶ Run Code",-1),b=a(`
js
var art =newArtplayer({container:'.artplayer-app',url:'/assets/sample/video.mp4',setting:true,settings: [{html:'PIP Mode',tooltip:'Close',icon:'<img width="22" heigth="22" src="/assets/img/state.svg">',switch:false,onSwitch:function(item,$dom,event){console.info(item,$dom,event);constnextState=!item.switch;art.pip=nextState;item.tooltip=nextState?'Open':'Close';returnnextState;},}, ],});
const range = [5,1,10,1];const value = range[0];const min = range[1];const max = range[2];const step = range[3];
1 2 3 4 5
`,4),d=s("div",{className:"run-code"},"▶ Run Code",-1),m=a(`
js
var art =newArtplayer({container:'.artplayer-app',url:'/assets/sample/video.mp4',setting:true,settings: [{html:'Slider',tooltip:'5x',icon:'<img width="22" heigth="22" src="/assets/img/state.svg">',range: [5,1,10,1],onChange:function(item,$dom,event){console.info(item,$dom,event);returnitem.range+'x';},}, ],});
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
`,1),u=[t,c,r,D,y,F,C,A,i,b,d,m];function h(_,g,E,v,f,S){return o(),p("div",null,u)}const q=l(e,[["render",h]]);export{w as __pageData,q as default};