vyleung / logseq-helium-plugin

a Logseq plugin to float items (e.g. videos) for an improved note-taking experience
MIT License
85 stars 6 forks source link

Remebering Height/Width across Video Sessions. #22

Closed amanhigh closed 1 year ago

amanhigh commented 1 year ago

Is it possible to Remember Video Size across Various Float Sessions ?

I have a large Screen and it involves me resizing Video after every start to make it right Size. If Plugin could remember last Width or allow it to be Configured in Setting that would be of Great Help.

vyleung commented 1 year ago

hi, it may be simpler to change the size for all videos by copying and pasting the following code to your custom.css file, which can be found in the logseq folder of your graph (reference):

/* you can change the height to whatever works best for you */
iframe[id^='youtube-player'] {
  height: 500px !important;
  width: 100% !important;
}

/* for wide mode */
main.ls-wide-mode iframe[id^='youtube-player'] {
  height: 750px !important;
  width: 100% !important;
}
amanhigh commented 1 year ago

Thanks this worked Perfectly !!

For others trying out, do note edit custom.css can be done from settings as well. However due to a bug currently its not working. https://github.com/logseq/logseq/issues/9296

Direct File edit works and applies without any reload of Logseq.