PluginProbe
Panorama – Turn Photos into Immersive Virtual Tours / trunk
Panorama – Turn Photos into Immersive Virtual Tours vtrunk
1.8.0 1.7.4 1.7.3 1.7.2 1.7.1 1.7.0 1.6.1 trunk 1.0.0 1.0.1 1.0.10 1.0.3 1.0.4 1.0.5 1.0.6 1.0.7 1.1.3 1.1.4 1.1.5 1.1.6 1.2.0 1.2.1 1.2.2 1.2.3 1.3.0 All 38 releases
panorama / blocks / video.php

video.php in Panorama – Turn Photos into Immersive Virtual Tours trunk, at blocks/video.php

48 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 if ( ! defined( 'ABSPATH' ) ) {
3 exit;
4 }
5
6 $bppiv_block = call_user_func( function() use ( $get_value, $bppiv_meta, $bppiv_width, $bppiv_height ) {
7 return [
8 "blockName" => "panorama/video",
9 "attrs" => [
10 "videoUrl" => $get_value('bppiv_video_src', false, 0, 'url'),
11 "options" => [
12 "autoplay" => $get_value('bppiv_auto_play', true),
13 "loop" => $get_value('bppiv_video_loop', true, true),
14 "muted" => $get_value('bppiv_video_mute', true),
15 "controlBar" => $get_value('control_show_hide_video', true, true),
16 "fullscreen" => $get_value('video_fullscreen_ctrl', true, true),
17 "setting" => $get_value('video_setting_ctrl', true, true),
18 "video" => $get_value('video_video_range_ctrl', true, true),
19 "initialView" => $get_value('initial_view_video', true),
20 "initialPosition" => [
21 "x" => (float)$get_value('initial_view_video_property', false, 0, 'top'),
22 "y" => (float)$get_value('initial_view_video_property', false, 0, 'right'),
23 "z" => (float)$get_value('initial_view_video_property', false, 0, 'bottom')
24 ]
25 ],
26 "layout" => [
27 "alignSl" => [
28 "desktop" =>$bppiv_meta['bppiv_alignment'] ?? "center",
29 "tablet" => $bppiv_meta['bppiv_alignment'] ?? "center",
30 "mobile" => $bppiv_meta['bppiv_alignment'] ?? "center"
31 ],
32 "width" => [
33 "desktop" => $bppiv_width,
34 "tablet" => $bppiv_width,
35 "mobile" => $bppiv_width
36 ],
37 "height" => [
38 "desktop" => $bppiv_height,
39 "tablet" => $bppiv_height,
40 "mobile" => $bppiv_height
41 ]
42 ]
43 ],
44 "innerBlocks" => [],
45 "innerHTML" => "",
46 "innerContent" => []
47 ];
48 } );