remove pip
This commit is contained in:
		
							parent
							
								
									b17fb633ff
								
							
						
					
					
						commit
						82dca831a4
					
				
					 1 changed files with 1 additions and 10 deletions
				
			
		|  | @ -31,7 +31,6 @@ import { ref, onMounted } from 'vue'; | ||||||
| import * as misskey from 'misskey-js'; | import * as misskey from 'misskey-js'; | ||||||
| import 'vlitejs/dist/vlite.css'; | import 'vlitejs/dist/vlite.css'; | ||||||
| import Vlitejs from 'vlitejs'; | import Vlitejs from 'vlitejs'; | ||||||
| import VlitejsPip from 'vlitejs/dist/plugins/pip'; |  | ||||||
| import { defaultStore } from '@/store'; | import { defaultStore } from '@/store'; | ||||||
| 
 | 
 | ||||||
| const props = defineProps<{ | const props = defineProps<{ | ||||||
|  | @ -39,20 +38,12 @@ const props = defineProps<{ | ||||||
| }>(); | }>(); | ||||||
| 
 | 
 | ||||||
| const videoEl = $ref<HTMLVideoElement | null>(); | const videoEl = $ref<HTMLVideoElement | null>(); | ||||||
| try { |  | ||||||
| 	Vlitejs.registerPlugin('pip', VlitejsPip); |  | ||||||
| } |  | ||||||
| catch (err) { |  | ||||||
| 	console.error('Pip plugin is already registered'); |  | ||||||
| } |  | ||||||
| 
 | 
 | ||||||
| const playerInstance = ref(); | const playerInstance = ref(); | ||||||
| 
 | 
 | ||||||
| onMounted(() => { | onMounted(() => { | ||||||
| 	if (videoEl) { | 	if (videoEl) { | ||||||
| 		playerInstance.value = new Vlitejs(videoEl, { | 		playerInstance.value = new Vlitejs('#player'); | ||||||
| 			plugins: ['pip'], |  | ||||||
| 		}); |  | ||||||
| 	} | 	} | ||||||
| }); | }); | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue