| 479 | return False |
| 480 | |
| 481 | def render_overleaf_button(overleaf_b64): |
| 482 | if not overleaf_b64: |
| 483 | return "" |
| 484 | |
| 485 | html = f""" |
| 486 | <form action="https://www.overleaf.com/docs" method="post" target="_blank"> |
| 487 | <input type="hidden" name="snip_uri" value="data:application/zip;base64,{overleaf_b64}"> |
| 488 | <input type="hidden" name="engine" value="xelatex"> |
| 489 | <button style=" |
| 490 | background:#4CAF50;color:white;padding:8px 14px; |
| 491 | border:none;border-radius:6px;cursor:pointer; margin-top:8px; |
| 492 | "> |
| 493 | 🚀 Open in Overleaf |
| 494 | </button> |
| 495 | </form> |
| 496 | """ |
| 497 | return html |
| 498 | |
| 499 | def _get_tectonic_bin(logs): |
| 500 | """Return a usable path to the tectonic binary. Try PATH/common paths; if not found, download to runs/_bin.""" |