Compare commits
1 Commits
Author | SHA1 | Date |
---|---|---|
Alexander | f5be64938e |
|
@ -100,7 +100,7 @@ def query(url = None):
|
|||
print(clean(responsetext.decode('utf8', errors='ignore')))
|
||||
print("</code></pre>")
|
||||
elif response.responsecode == 20:
|
||||
print(f"<h1>RESPONSE: \"20 Success\", but...</h1><p>The Wobbly browser only supports text responses, and this response is '{clean(response.meta)}'.</p>\n<p>You can visit the url with a real gemini browser via <a href='{clean(baseurl)}'>{clean(baseurl)}</a></p>")
|
||||
print(f"<h1>RESPONSE: \"20 Success\", but...</h1><p>The Wobbly browser only supports text responses, and this response is '{clean(response.meta)}'.</p>\n<p>You can visit the url with a real gemini browser via <a href='{clean(baseurl)}' target='_blank'>{clean(baseurl)}</a></p>")
|
||||
elif response.responsecode in [40, 41, 42, 43, 44, 50, 51, 52, 53, 59]:
|
||||
print(f"<h1>RESPONSE: \"{str(response.responsecode)} {clean(response.meta)}\"</h1><p>This is an error message from the server. Hopefully it makes sense to you.</p>")
|
||||
elif response.responsecode in [60, 61, 62]:
|
||||
|
|
2
main.js
2
main.js
|
@ -140,7 +140,7 @@ function geminiEnterListener(e) {
|
|||
|
||||
// Hijack any clicks from anchor links that use the gemini protocol
|
||||
function geminiLinkClickListener(e) {
|
||||
if (e.target.tagName === 'A' && e.target.href.startsWith("gemini://")) {
|
||||
if (e.target.tagName === 'A' && e.target.href.startsWith("gemini://") && e.target.target != '_blank') {
|
||||
// We only care about clicked gemini:// links
|
||||
e.preventDefault()
|
||||
wobblyAddressBar.value = e.target.href
|
||||
|
|
Loading…
Reference in New Issue