nk-crew / awb

Advanced WordPress Backgrounds with Gutenberg support. Images, Videos and Parallax

Home Page:https://wpbackgrounds.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

using with browsersync makes odd port strings in gutenberg

HongPong opened this issue · comments

if i use the wp backend when browsersync is running and i'm on port 3000, it starts attaching more 3000s to the video URL. I might suspect that using it on other odd ports or setups would cause similar effects. Obviously not a common situation for end users but worth noting.

{"type":"video","videoMp4":"http://example.com:3000:3000:3000:3000:3000:3000:3000/wp-content/uploads/2019/05/test-video-looper.mp4","videoAlwaysPlay":true,"videoMobile":true,"className":"front\u002d\u002dvideohero","ghostkitStyles":{},"ghostkitClassname":"nk-awb-YErDa","ghostkitId":"YErDa"}
<div class="wp-block-nk-awb nk-awb front--videohero"><div class="nk-awb-wrap" data-awb-type="video" data-awb-video="mp4:http://example.com:3000:3000:3000:3000:3000:3000:3000/wp-content/uploads/2019/05/test-video-looper.mp4" data-awb-video-always-play="true" data-awb-video-mobile="true"><div class="nk-awb-inner"></div></div><!-- wp:heading {"className":"front\u002d\u002dvideohero-header"} -->

Hi.

I'm not sure it is AWB problem because it uses WP API to retrieve video URL:

https://github.com/nk-o/awb/blob/e038459a63379442ef8bced5c48e264ba9333b84/src/assets/admin/gutenberg/block.jsx#L503-L525