Skip to content

Commit 8126b93

Browse files
committed
Adds prompt parameter handling and online help
1 parent 29351b9 commit 8126b93

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tools/generate.html

+8
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@
3838
fill="currentColor" />
3939
</svg>
4040
<span style="font-family:Helvetica;font-weight:700;font-size:20px;margin-left:4px;">draw.io</span>
41+
<a style="margin-left:auto;" href="https://github.com/jgraph/drawio-tools/discussions/3" target="_blank">
42+
<img style="opacity:0.6;height:16px;width:16px;filter:invert(1);" src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBmaWxsPSJub25lIiBkPSJNMCAwaDI0djI0SDB6Ii8+PHBhdGggZD0iTTExIDE4aDJ2LTJoLTJ2MnptMS0xNkM2LjQ4IDIgMiA2LjQ4IDIgMTJzNC40OCAxMCAxMCAxMCAxMC00LjQ4IDEwLTEwUzE3LjUyIDIgMTIgMnptMCAxOGMtNC40MSAwLTgtMy41OS04LThzMy41OS04IDgtOCA4IDMuNTkgOCA4LTMuNTkgOC04IDh6bTAtMTRjLTIuMjEgMC00IDEuNzktNCA0aDJjMC0xLjEuOS0yIDItMnMyIC45IDIgMmMwIDItMyAxLjc1LTMgNWgyYzAtMi4yNSAzLTIuNSAzLTUgMC0yLjIxLTEuNzktNC00LTR6Ii8+PC9zdmc+" border="0">
43+
</a>
4144
</div>
4245
<div style="display:block;align-items:center;padding:20px;">
4346
<textarea id="prompt"
@@ -232,6 +235,11 @@
232235
if (urlParams['engine'] != null) {
233236
document.getElementById('engine').value = urlParams['engine'];
234237
}
238+
239+
if (urlParams['prompt'] != null) {
240+
document.getElementById('prompt').value = urlParams['prompt'];
241+
generate();
242+
}
235243
}
236244
//]]>
237245
</script>

0 commit comments

Comments
 (0)