diff --git a/app/routes/__init__.py b/app/routes/__init__.py index df23730..bc74cf3 100644 --- a/app/routes/__init__.py +++ b/app/routes/__init__.py @@ -1,6 +1,6 @@ # Register routes here -from app.routes import index, search, users, tools, development +from app.routes import index, search, users, tools, development, chat from app.routes.account import login, account, notification, polls from app.routes.admin import index, groups, account, forums, \ attachments, config, members, polls, login_as diff --git a/app/routes/chat.py b/app/routes/chat.py new file mode 100644 index 0000000..84457de --- /dev/null +++ b/app/routes/chat.py @@ -0,0 +1,16 @@ +from app import app +from app.utils.render import render +from flask import send_file, url_for + +@app.route('/chat') +def chat(): + return render('chat.html', + styles=[ + '+css/v5shoutbox.css'], + scripts=[ + '-scripts/trigger_menu.js', + '-scripts/editor.js']) + +@app.route('/v5shoutbox.js') +def v5shoutbox_js(): + return send_file('static/scripts/v5shoutbox.js') diff --git a/app/static/css/v5shoutbox.css b/app/static/css/v5shoutbox.css new file mode 120000 index 0000000..6cac5dd --- /dev/null +++ b/app/static/css/v5shoutbox.css @@ -0,0 +1 @@ +../../../submodules/v5shoutbox/style.css \ No newline at end of file diff --git a/app/static/scripts/v5shoutbox.js b/app/static/scripts/v5shoutbox.js new file mode 120000 index 0000000..c094849 --- /dev/null +++ b/app/static/scripts/v5shoutbox.js @@ -0,0 +1 @@ +../../../submodules/v5shoutbox/v5shoutbox.js \ No newline at end of file diff --git a/app/templates/base/scripts.html b/app/templates/base/scripts.html index 09062fb..9ba5bb9 100644 --- a/app/templates/base/scripts.html +++ b/app/templates/base/scripts.html @@ -1,4 +1,5 @@ {% for s in scripts %} {% endfor %} + diff --git a/app/templates/chat.html b/app/templates/chat.html new file mode 100644 index 0000000..ecf2d28 --- /dev/null +++ b/app/templates/chat.html @@ -0,0 +1,10 @@ +{% set tabtitle = "Shoutbox" %} + + + + {% include "base/head.html" with context %} + + {% include "widgets/v5shoutbox.html" %} + {% include "base/scripts.html" %} + + diff --git a/app/templates/widgets/v5shoutbox.html b/app/templates/widgets/v5shoutbox.html new file mode 120000 index 0000000..fb91d1c --- /dev/null +++ b/app/templates/widgets/v5shoutbox.html @@ -0,0 +1 @@ +../../../submodules/v5shoutbox/widget.html \ No newline at end of file diff --git a/submodules/v5shoutbox b/submodules/v5shoutbox index 203b128..d7e9290 160000 --- a/submodules/v5shoutbox +++ b/submodules/v5shoutbox @@ -1 +1 @@ -Subproject commit 203b1288e4dea747aa2b996839459c92fd4cddd4 +Subproject commit d7e929000f039488f42385912c98be88b4a63fcf