Improved website, added styling, replaced bad JS color picker with HTML5 picker.

This commit is contained in:
psannus
2021-02-25 21:36:06 +02:00
parent 8750b4d9f0
commit 9a8a239c49
6 changed files with 964 additions and 3272 deletions

View File

@@ -1,7 +1,6 @@
#!/usr/bin/env python3
import logging
import sys
import json
import lib.ProgramLoading as Pl
from lib.Litsimaja import Litsimaja
@@ -20,8 +19,7 @@ logger.addHandler(stdout_handler)
# start litsimaja
lm = Litsimaja()
app = Flask(__name__)
# Pl.run('siinus', 'Static', lm, logger, {'color': [50, 50, 50]})
app = Flask(__name__, static_url_path='', static_folder='templates')
@app.route('/', methods=['GET'])
@@ -29,11 +27,6 @@ def respondroot():
return render_template('index.html', programs=Pl.list_all(True))
@app.route('/jscolor.js', methods=['GET'])
def respondjs():
return render_template('jscolor.js')
@app.route('/run')
def run():
Pl.run('siinus', 'MyProgram', lm, logger, {'color': [50, 50, 50]})