terrastruct / d2-obsidian

The official D2 plugin for Obsidian. D2 is a modern diagram scripting language thats turns text to diagrams.
https://d2lang.com
Mozilla Public License 2.0
204 stars 12 forks source link

investigate export to PDF problem #29

Closed alixander closed 1 year ago

alixander commented 1 year ago

https://discord.com/channels/1039184639652265985/1039185315685998693/1090204837704106034

Screen Shot 2023-03-28 at 9 53 04 AM
berniexie commented 1 year ago

Right now the diagrams load fine if the debounce is not there. Maybe we can not debounce the first render so that the exporter gets a guaranteed result back

berniexie commented 1 year ago

Potential solution is detect media print +

@media print {
  .Preview__Recompile {
    display: none;
  }
}
alixander commented 1 year ago

sounds good to me @berniexie