Removed last vestiges of old name, removed unnecessary imports, added manifest.json
This commit is contained in:
parent
c79fe9a2c0
commit
bd34dfcb0e
17
app.py
17
app.py
@ -1,7 +1,7 @@
|
|||||||
import io
|
import io
|
||||||
import tempfile
|
import tempfile
|
||||||
import subprocess
|
import subprocess
|
||||||
from flask import Flask, render_template_string, request, send_file, redirect, url_for, flash
|
from flask import Flask, render_template_string, request, send_from_directory
|
||||||
from PIL import Image, ImageDraw, ImageFont
|
from PIL import Image, ImageDraw, ImageFont
|
||||||
import re
|
import re
|
||||||
|
|
||||||
@ -21,7 +21,8 @@ BULLET_CHAR = "• "
|
|||||||
|
|
||||||
HTML_FORM = '''
|
HTML_FORM = '''
|
||||||
<!doctype html>
|
<!doctype html>
|
||||||
<title>Markdown Thermal Note</title>
|
<title>CatPrint</title>
|
||||||
|
<link rel="manifest" href="/static/manifest.json">
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
@ -514,5 +515,17 @@ def index():
|
|||||||
return render_template_string(HTML_FORM, img=img_data, default_md=md,
|
return render_template_string(HTML_FORM, img=img_data, default_md=md,
|
||||||
printed=printed, error=error)
|
printed=printed, error=error)
|
||||||
|
|
||||||
|
@app.route('/manifest.json')
|
||||||
|
def manifest():
|
||||||
|
return send_from_directory('static', 'manifest.json')
|
||||||
|
|
||||||
|
@app.route('/icon512_maskable.png')
|
||||||
|
def icon_maskable():
|
||||||
|
return send_from_directory('static', 'icon512_maskable.png')
|
||||||
|
|
||||||
|
@app.route('/icon512_rounded.png')
|
||||||
|
def icon_rounded():
|
||||||
|
return send_from_directory('static', 'icon512_rounded.png')
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
app.run(host="0.0.0.0", debug=True)
|
app.run(host="0.0.0.0", debug=True)
|
||||||
|
|||||||
BIN
static/icon512_maskable.png
Normal file
BIN
static/icon512_maskable.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 24 KiB |
BIN
static/icon512_rounded.png
Normal file
BIN
static/icon512_rounded.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 33 KiB |
1
static/manifest.json
Normal file
1
static/manifest.json
Normal file
@ -0,0 +1 @@
|
|||||||
|
{"theme_color":"#22282c","background_color":"#22282c","icons":[{"purpose":"maskable","sizes":"512x512","src":"icon512_maskable.png","type":"image/png"},{"purpose":"any","sizes":"512x512","src":"icon512_rounded.png","type":"image/png"}],"orientation":"any","display":"standalone","dir":"auto","lang":"es-UY","start_url":"https://catnote.netpaws.cc","scope":"https://catnote.netpaws.cc","name":"CatNote","short_name":"CatNote","id":"cc.netpaws.catnote"}
|
||||||
Loading…
Reference in New Issue
Block a user