From fa6e168ccce7873fa7a54e21f4944d6f62abe1d3 Mon Sep 17 00:00:00 2001 From: Chord Date: Tue, 31 Dec 2019 09:46:34 -0500 Subject: [PATCH] Application improvements * Change favicon * Display account banned status on admin search * Pull in application version from Webpack * Add "Feedback" button in footer and github references * Fix faction icons to make them the same size * PaginatedList component now supports back * Tabbed navs support back * Hide Pagination when only one page * Improve admin table style and size --- api/db.js | 2 +- app/App.svelte | 29 +++++++- app/components/CharacterLink.svelte | 7 +- app/components/LoginList.svelte | 6 +- app/components/PaginatedList.svelte | 23 ++++-- app/components/Pagination.svelte | 22 +++--- app/util/navigation.js | 19 +++++ app/views/AdminPanel.svelte | 22 +++--- app/views/CharacterList.svelte | 15 ++-- app/views/Home.svelte | 2 +- app/views/UserList.svelte | 19 ++--- public/favicon.ico | Bin 0 -> 562718 bytes public/favicon.png | Bin 3127 -> 0 bytes public/img/nc_icon.png | Bin 6014 -> 4778 bytes public/img/tr_icon.png | Bin 1802 -> 1562 bytes public/img/vs_icon.png | Bin 5853 -> 4763 bytes public/index.html | 5 +- scss/base.scss | 81 +++++++++++++++++++++ scss/custom.scss | 1 + scss/defaults.scss | 108 ---------------------------- scss/main.scss | 5 ++ scss/planetside.scss | 32 +++++++++ webpack.config.cjs | 4 ++ 23 files changed, 244 insertions(+), 158 deletions(-) create mode 100644 app/util/navigation.js create mode 100644 public/favicon.ico delete mode 100644 public/favicon.png create mode 100644 scss/base.scss create mode 100644 scss/planetside.scss diff --git a/api/db.js b/api/db.js index 0187932..aa0493f 100644 --- a/api/db.js +++ b/api/db.js @@ -350,7 +350,7 @@ export async function search(term, pagination) { const values = ['%'+term.toUpperCase()+'%', start_id, pagination.items_per_page]; try { - const accounts = await pool.query('SELECT id, username, gm FROM accounts ' + + const accounts = await pool.query('SELECT id, username, gm, inactive FROM accounts ' + 'WHERE upper(username) LIKE $1 '+ ` ORDER BY username OFFSET $2 LIMIT $3`, values); const characters = await pool.query('SELECT id, name, account_id, faction_id FROM characters ' + diff --git a/app/App.svelte b/app/App.svelte index 3462444..32fb417 100644 --- a/app/App.svelte +++ b/app/App.svelte @@ -27,6 +27,9 @@ import UserList from './views/UserList.svelte'; import AdminPanel from './views/AdminPanel.svelte'; import CharacterList from './views/CharacterList.svelte'; +// Defined by webpack +let APP_VERSION = __VERSION__; + // prevent view pop-in let initialized = false; @@ -117,7 +120,9 @@ page("*", setRoute(BadRoute));