711480f8f6
This pull request introduces the dedicated containerized infrastructure and configuration for deploying NexusReader's beta version in the Test environment. ### Summary of Changes 1. **Docker Infrastructure & Secrets**: - **`docker-compose.test.yml`**: Configured dedicated database and auxiliary services (PostgreSQL 17, Qdrant, Neo4j) on isolated, non-standard ports to ensure zero conflict with the existing server configurations. - **`.env.test.template`**: Provided an environment variable template showing required setups, including mandatory database passwords, API keys, and admin custom passwords. - **`.gitignore`**: Excluded local `.env` files to prevent accidental commits of production or staging secrets. 2. **Database Hardening**: - Configured Neo4j with basic authentication (`IDriver` instantiation uses basic auth when credentials are provided in configuration). - Configured PostgreSQL to use mandatory authentication. - Configured the admin seeder (`DbInitializer.cs`) to dynamically use `NEXUS_ADMIN_PASSWORD` from environment variables, falling back to a default password in local Development only. 3. **Feature-Flagged Restrictions**: - **`appsettings.Test.json`**: Implemented `Features:AllowRegistration` and `Features:AllowPasswordReset` flags set to `false`. - **Middleware Enforcement (`Program.cs`)**: Intercepts requests to `/identity/register` and `/identity/forgotPassword` (and their MVC/form variations) and rejects them with a `403 Forbidden` response in restricted environments. - **OAuth Provisioning Guard (`Program.cs`)**: Blocks new account provisioning via Google OAuth callback by checking the `Features:AllowRegistration` configuration, redirecting users to the login page with a descriptive error. - **UI Protection (`Login.razor`, `Register.razor`)**: Conditionally hides registration/password reset links and intercepts manual navigation attempts to `/account/register` by redirecting to login with a warning. --------- Co-authored-by: Marek Jasiński <jasins.marek@gmail.com> Reviewed-on: #56 Co-authored-by: Antigravity <antigravity@google.com> Co-committed-by: Antigravity <antigravity@google.com>
347 lines
7.0 KiB
CSS
347 lines
7.0 KiB
CSS
.hub-container {
|
|
display: flex;
|
|
width: 100vw;
|
|
height: 100vh;
|
|
background: #121212;
|
|
color: #e0e0e0;
|
|
overflow: hidden;
|
|
}
|
|
|
|
::deep .hub-sidebar {
|
|
width: 260px;
|
|
height: 100%;
|
|
background: #161616;
|
|
border-right: 1px solid rgba(255, 255, 255, 0.05);
|
|
display: flex;
|
|
flex-direction: column;
|
|
z-index: 100;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
::deep .sidebar-header {
|
|
padding: 2.5rem 1.5rem;
|
|
}
|
|
|
|
::deep .logo {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.75rem;
|
|
}
|
|
|
|
::deep .logo-icon {
|
|
color: var(--nexus-neon);
|
|
filter: drop-shadow(0 0 10px rgba(0, 255, 153, 0.4));
|
|
}
|
|
|
|
::deep .logo-text {
|
|
font-family: var(--nexus-font-serif);
|
|
font-size: 1.5rem;
|
|
font-weight: 700;
|
|
color: #ffffff;
|
|
letter-spacing: -0.01em;
|
|
}
|
|
|
|
::deep .sidebar-nav {
|
|
flex: 1;
|
|
padding: 0;
|
|
display: flex;
|
|
flex-direction: column;
|
|
}
|
|
|
|
::deep .nav-item {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 1rem;
|
|
padding: 1rem 1.5rem;
|
|
color: #A0A0A0;
|
|
text-decoration: none;
|
|
transition: all 0.2s ease;
|
|
border-left: 3px solid transparent;
|
|
font-family: var(--nexus-font-sans);
|
|
font-size: 0.9rem;
|
|
font-weight: 500;
|
|
}
|
|
|
|
::deep .nav-item:hover {
|
|
background: rgba(255, 255, 255, 0.02);
|
|
color: #ffffff;
|
|
}
|
|
|
|
::deep .nav-item.active {
|
|
color: #ffffff;
|
|
background: rgba(0, 255, 153, 0.03);
|
|
border-left: 3px solid var(--nexus-neon);
|
|
}
|
|
|
|
::deep .nav-item.active .nav-icon {
|
|
color: var(--nexus-neon);
|
|
}
|
|
|
|
::deep .nav-icon {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: 20px;
|
|
opacity: 0.7;
|
|
transition: opacity 0.2s;
|
|
}
|
|
|
|
::deep .nav-item:hover .nav-icon,
|
|
::deep .nav-item.active .nav-icon {
|
|
opacity: 1;
|
|
}
|
|
|
|
::deep .sidebar-footer {
|
|
padding: 1.25rem 1.5rem;
|
|
border-top: 1px solid rgba(255, 255, 255, 0.05);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
}
|
|
|
|
::deep .user-brief {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.75rem;
|
|
overflow: hidden;
|
|
}
|
|
|
|
::deep .user-avatar {
|
|
width: 32px;
|
|
height: 32px;
|
|
background: #222;
|
|
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 0.8rem;
|
|
font-weight: 600;
|
|
color: #A0A0A0;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
::deep .user-details {
|
|
display: flex;
|
|
flex-direction: column;
|
|
overflow: hidden;
|
|
}
|
|
|
|
::deep .user-name {
|
|
font-size: 0.85rem;
|
|
font-weight: 500;
|
|
color: #A0A0A0;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
}
|
|
|
|
::deep .logout-btn {
|
|
background: transparent;
|
|
border: none;
|
|
color: #666;
|
|
cursor: pointer;
|
|
padding: 0.4rem;
|
|
border-radius: 6px;
|
|
transition: all 0.2s;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
::deep .logout-btn:hover {
|
|
background: rgba(255, 255, 255, 0.05);
|
|
color: #ffffff;
|
|
}
|
|
|
|
.hub-main {
|
|
flex: 1;
|
|
height: 100%;
|
|
overflow-y: auto;
|
|
background: radial-gradient(circle at center, #1a1a1a 0%, #121212 100%);
|
|
}
|
|
|
|
.hub-content {
|
|
padding: 2.5rem;
|
|
min-height: 100%;
|
|
}
|
|
|
|
::deep .hub-loading {
|
|
width: 100%;
|
|
height: 100%;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
gap: 1.5rem;
|
|
}
|
|
|
|
::deep .nexus-loader {
|
|
width: 32px;
|
|
height: 32px;
|
|
border: 2px solid rgba(0, 255, 153, 0.1);
|
|
border-top-color: var(--nexus-neon);
|
|
border-radius: 50%;
|
|
animation: spin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
|
|
filter: drop-shadow(0 0 5px var(--nexus-neon));
|
|
}
|
|
|
|
@keyframes spin {
|
|
to { transform: rotate(360deg); }
|
|
}
|
|
|
|
/* Mobile Styles */
|
|
.nexus-mobile-topbar {
|
|
display: none;
|
|
}
|
|
|
|
@media (max-width: 768px) {
|
|
.nexus-mobile-topbar {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
height: 60px;
|
|
background: rgba(18, 18, 18, 0.85);
|
|
backdrop-filter: blur(20px);
|
|
-webkit-backdrop-filter: blur(20px);
|
|
border-bottom: 1px solid rgba(255, 255, 255, 0.05);
|
|
padding: 0 1.25rem;
|
|
z-index: 150;
|
|
}
|
|
|
|
.hamburger-btn {
|
|
background: transparent;
|
|
border: none;
|
|
color: #e0e0e0;
|
|
cursor: pointer;
|
|
padding: 0.5rem;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 8px;
|
|
transition: background-color 0.2s;
|
|
min-height: 48px;
|
|
min-width: 48px;
|
|
touch-action: manipulation;
|
|
}
|
|
|
|
.hamburger-btn:hover {
|
|
background: rgba(255, 255, 255, 0.05);
|
|
}
|
|
|
|
.mobile-logo {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.5rem;
|
|
}
|
|
|
|
.pulsing-logo {
|
|
animation: pulse-glow 2s infinite ease-in-out;
|
|
}
|
|
|
|
@keyframes pulse-glow {
|
|
0%, 100% {
|
|
filter: drop-shadow(0 0 5px rgba(0, 255, 153, 0.4));
|
|
opacity: 0.8;
|
|
}
|
|
50% {
|
|
filter: drop-shadow(0 0 12px rgba(0, 255, 153, 0.8));
|
|
opacity: 1;
|
|
}
|
|
}
|
|
|
|
.mobile-user-pill {
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.user-avatar-mini {
|
|
width: 32px;
|
|
height: 32px;
|
|
background: linear-gradient(135deg, var(--nexus-neon) 0%, #0099ff 100%);
|
|
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 0.85rem;
|
|
font-weight: 700;
|
|
color: #121212;
|
|
box-shadow: 0 0 10px rgba(0, 255, 153, 0.2);
|
|
}
|
|
|
|
.mobile-sidebar-backdrop {
|
|
position: fixed;
|
|
inset: 0;
|
|
background: rgba(0, 0, 0, 0.6);
|
|
backdrop-filter: blur(4px);
|
|
-webkit-backdrop-filter: blur(4px);
|
|
z-index: 190;
|
|
animation: fade-in 0.2s ease-out;
|
|
}
|
|
|
|
@keyframes fade-in {
|
|
from { opacity: 0; }
|
|
to { opacity: 1; }
|
|
}
|
|
|
|
::deep .hub-sidebar {
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
bottom: 0;
|
|
width: 280px;
|
|
height: 100%;
|
|
background: #141414;
|
|
z-index: 200;
|
|
transform: translateX(-100%);
|
|
will-change: transform;
|
|
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
box-shadow: none;
|
|
}
|
|
|
|
.mobile-menu-open ::deep .hub-sidebar {
|
|
transform: translateX(0);
|
|
box-shadow: 10px 0 30px rgba(0, 0, 0, 0.5);
|
|
}
|
|
|
|
.hub-container {
|
|
flex-direction: column;
|
|
}
|
|
|
|
.hub-main {
|
|
margin-top: 60px;
|
|
width: 100%;
|
|
height: calc(100vh - 60px);
|
|
}
|
|
|
|
.hub-content {
|
|
padding: 1.25rem;
|
|
}
|
|
|
|
::deep .sidebar-header {
|
|
padding: 1.5rem 1.25rem;
|
|
border-bottom: 1px solid rgba(255, 255, 255, 0.05);
|
|
}
|
|
|
|
::deep .sidebar-nav {
|
|
padding: 1rem 0;
|
|
}
|
|
|
|
::deep .nav-item {
|
|
padding: 0.9rem 1.25rem;
|
|
font-size: 0.95rem;
|
|
min-height: 48px; /* Touch target */
|
|
}
|
|
|
|
::deep .sidebar-footer {
|
|
padding: 1rem 1.25rem;
|
|
}
|
|
}
|
|
|
|
|