diff --git a/arma/client/addons/bank/ui/_site/bank.css b/arma/client/addons/bank/ui/_site/bank.css index 88b0334..e47ed66 100644 --- a/arma/client/addons/bank/ui/_site/bank.css +++ b/arma/client/addons/bank/ui/_site/bank.css @@ -4,6 +4,9 @@ --bg-surface-hover: #f1f5f9; --primary: #475569; --primary-hover: #1e293b; + --window-blue: #12325b; + --window-blue-border: #214978; + --window-blue-highlight: #d7e5f8; --text-main: #1f2937; --text-muted: #64748b; --text-inverse: #f8fafc; @@ -13,6 +16,11 @@ --footer-bg: #1e293b; } +html, +body { + height: 100%; +} + body { font-family: 'Inter', system-ui, -apple-system, sans-serif; margin: 0; @@ -20,16 +28,107 @@ body { background: var(--bg-app); color: var(--text-main); line-height: 1.6; + overflow: hidden; } #app { - min-height: 100vh; + height: 100vh; + overflow: hidden; +} + +.app-shell { + height: 100vh; + display: flex; + flex-direction: column; + overflow: hidden; } main { display: flex; flex-direction: column; - min-height: 100vh; + flex: 1 1 auto; + min-height: 0; + overflow: auto; + overscroll-behavior: contain; +} + +.window-titlebar { + display: flex; + align-items: center; + justify-content: space-between; + gap: 1rem; + padding: 0.8rem 1.25rem; + background: linear-gradient(180deg, var(--window-blue) 0%, #0d2643 100%); + border-bottom: 1px solid var(--window-blue-border); + color: var(--text-inverse); + box-shadow: 0 10px 24px rgb(18 50 91 / 0.24); + position: sticky; + top: 0; + z-index: 30; + flex-shrink: 0; +} + +.window-titlebar-brand { + display: flex; + flex-direction: column; + gap: 0.1rem; +} + +.window-titlebar-kicker { + font-size: 0.68rem; + font-weight: 700; + letter-spacing: 0.16em; + text-transform: uppercase; + color: rgb(215 229 248 / 0.78); +} + +.window-titlebar-title { + font-size: 0.95rem; + font-weight: 700; + letter-spacing: 0.04em; + color: var(--text-inverse); +} + +.window-titlebar-controls { + display: flex; + align-items: center; + gap: 0.5rem; +} + +.window-control-btn { + min-width: 2.5rem; + padding: 0.45rem 0.7rem; + border-radius: 6px; + border: 1px solid rgb(215 229 248 / 0.22); + background: rgb(255 255 255 / 0.08); + color: var(--window-blue-highlight); + font-size: 0.82rem; + font-weight: 700; + letter-spacing: 0.08em; + text-transform: uppercase; + cursor: not-allowed; + box-shadow: none; + transform: none; +} + +.window-control-btn:hover { + background: rgb(255 255 255 / 0.08); + box-shadow: none; + transform: none; +} + +.window-control-btn:disabled { + opacity: 0.55; +} + +.window-control-btn.is-close { + cursor: pointer; + opacity: 1; + border-color: rgb(255 255 255 / 0.24); +} + +.window-control-btn.is-close:hover { + background: rgb(255 255 255 / 0.18); } .container { @@ -102,22 +201,6 @@ main { font-family: 'Consolas', 'Monaco', monospace; } -.btn-signout { - background: transparent; - color: var(--text-muted); - border: 1px solid var(--border); - padding: 0.5rem 1rem; - font-size: 0.85rem; - - &:hover { - background: var(--bg-surface-hover); - color: var(--primary-hover); - border-color: var(--primary); - transform: none; - box-shadow: none; - } -} - .content { display: grid; grid-template-columns: 1fr 1fr; @@ -343,3 +426,15 @@ form { } } } + +@media (max-width: 720px) { + .window-titlebar { + flex-direction: column; + align-items: flex-start; + } + + .window-titlebar-controls { + width: 100%; + justify-content: flex-end; + } +} diff --git a/arma/client/addons/bank/ui/_site/bank.js b/arma/client/addons/bank/ui/_site/bank.js index bc53805..7b5209b 100644 --- a/arma/client/addons/bank/ui/_site/bank.js +++ b/arma/client/addons/bank/ui/_site/bank.js @@ -70,16 +70,44 @@ function Navbar() { h('div', { className: 'profile-info' }, h('span', { className: 'profile-label' }, 'Account'), h('span', { className: 'profile-id' }, uid) - ), - h('button', { - className: 'btn-signout', - onClick: () => sendEvent('bank::close', {}) - }, 'Sign Out') + ) ) ) ); } +function WindowTitleBar() { + return h('div', { className: 'window-titlebar' }, + h('div', { className: 'window-titlebar-brand' }, + h('span', { className: 'window-titlebar-kicker' }, 'FDIC Workspace'), + h('span', { className: 'window-titlebar-title' }, 'Global Financial Network') + ), + h('div', { className: 'window-titlebar-controls' }, + h('button', { + type: 'button', + className: 'window-control-btn', + disabled: true, + title: 'Minimize unavailable', + 'aria-label': 'Minimize unavailable' + }, '-'), + h('button', { + type: 'button', + className: 'window-control-btn', + disabled: true, + title: 'Maximize unavailable', + 'aria-label': 'Maximize unavailable' + }, '[ ]'), + h('button', { + type: 'button', + className: 'window-control-btn is-close', + onClick: () => sendEvent('bank::close', {}), + title: 'Close', + 'aria-label': 'Close banking interface' + }, 'X') + ) + ); +} + function TransactionHistory() { const state = store.getState(); const transactions = state.transactions || []; @@ -295,12 +323,15 @@ function Footer() { } function App() { - return h('main', null, - Navbar(), - h('div', { className: 'container' }, - BankDashboard() - ), - Footer() + return h('div', { className: 'app-shell' }, + WindowTitleBar(), + h('main', null, + Navbar(), + h('div', { className: 'container' }, + BankDashboard() + ), + Footer() + ) ); } diff --git a/arma/client/addons/notifications/CfgSounds.hpp b/arma/client/addons/notifications/CfgSounds.hpp new file mode 100644 index 0000000..ae86ed6 --- /dev/null +++ b/arma/client/addons/notifications/CfgSounds.hpp @@ -0,0 +1,9 @@ +class CfgSounds { + sounds[] += {QGVAR(notify)}; + + class GVAR(notify) { + name = QGVAR(notify); + sound[] = {QPATHTOF2(sounds\notify.ogg), 1, 1}; + titles[] = {}; + }; +}; diff --git a/arma/client/addons/notifications/XEH_postInitClient.sqf b/arma/client/addons/notifications/XEH_postInitClient.sqf index 072b241..6eada6a 100644 --- a/arma/client/addons/notifications/XEH_postInitClient.sqf +++ b/arma/client/addons/notifications/XEH_postInitClient.sqf @@ -11,5 +11,6 @@ [QGVAR(recieveNotification), { params [["_type", "", [""]], ["_title", "", [""]], ["_content", "", [""]], ["_duration", 4000, [4000]]]; + playSound QGVAR(notify); GVAR(NotificationClass) call ["create", [_type, _title, _content, _duration]]; }] call CFUNC(addEventHandler); diff --git a/arma/client/addons/notifications/config.cpp b/arma/client/addons/notifications/config.cpp index fdb31cc..e458924 100644 --- a/arma/client/addons/notifications/config.cpp +++ b/arma/client/addons/notifications/config.cpp @@ -16,6 +16,7 @@ class CfgPatches { }; }; +#include "CfgSounds.hpp" #include "CfgEventHandlers.hpp" #include "ui\RscCommon.hpp" #include "ui\RscNotifications.hpp" diff --git a/arma/client/addons/notifications/sounds/notify.ogg b/arma/client/addons/notifications/sounds/notify.ogg new file mode 100644 index 0000000..06e8125 Binary files /dev/null and b/arma/client/addons/notifications/sounds/notify.ogg differ diff --git a/arma/client/addons/notifications/ui/_site/index.html b/arma/client/addons/notifications/ui/_site/index.html index b07114a..d1d769a 100644 --- a/arma/client/addons/notifications/ui/_site/index.html +++ b/arma/client/addons/notifications/ui/_site/index.html @@ -1,35 +1,44 @@ - + +
+ + +