Closed berndporr closed 2 years ago
This is an old post but I would like to know if anything as changed since? I just started using the pluging and I have the same probleme: too large on the phone and not responsively adjusting. Any progress since your post? thanks
Thanks! Very usefull!
full
and half
can now be used as sizes. They will automatically adjust to the available screen width.
I have a page with a lot of youTube clips: https://biosignals.berndporr.me.uk/doku.php?id=ecg:gndamp and the problem has been that the clips were too large on the phone and too small on a PC screen. I just had a look at the code and the width are hard coded into it.
Suggestion: instead of hard coding the width in it it would be better to do a design which automatically adjusts the width in relative units. a) for a PC the width about 80% of the screen b) for a mobile about 99% of the screen Below this is just a "hack" where basically changes the geometry of the iframe so that it has full width on a mobile and then 80% width on a PC. All that embedded into a div.
php fragment from
syntax.php
:Basically the iframe is positioned in absolute coordinate system within a div which has fake padding of the right size. Then that's wapped in a div for padding of that div which is then device dependent. I'm sure it can be simplified but as a hack it's OK for now. Happy to do a proper pull request at some point if there is appetite.