Files
desk-moloni/modules/desk_moloni/assets/css/admin.css
Emanuel Almeida c19f6fd9ee fix(perfexcrm module): align version to 3.0.1, unify entrypoint, and harden routes/views
- Bump DESK_MOLONI version to 3.0.1 across module
- Normalize hooks to after_client_* and instantiate PerfexHooks safely
- Fix OAuthController view path and API client class name
- Add missing admin views for webhook config/logs; adjust view loading
- Harden client portal routes and admin routes mapping
- Make Dashboard/Logs/Queue tolerant to optional model methods
- Align log details query with existing schema; avoid broken joins

This makes the module operational in Perfex (admin + client), reduces 404s,
and avoids fatal errors due to inconsistent tables/methods.
2025-09-11 17:38:45 +01:00

613 lines
12 KiB
CSS

/**
* Desk-Moloni Admin CSS v3.0
*
* Modern responsive styling for the admin interface
* Features: CSS Grid, Flexbox, Dark mode support, Animations
*
* @package DeskMoloni\Assets
* @version 3.0
*/
/* CSS Variables for theming */
:root {
--dm-primary: #3b82f6;
--dm-primary-dark: #2563eb;
--dm-success: #10b981;
--dm-warning: #f59e0b;
--dm-error: #ef4444;
--dm-info: #06b6d4;
--dm-bg: #ffffff;
--dm-bg-secondary: #f8fafc;
--dm-text: #1e293b;
--dm-text-secondary: #64748b;
--dm-border: #e2e8f0;
--dm-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
--dm-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
--dm-border-radius: 8px;
--dm-transition: all 0.2s ease-in-out;
}
/* Dark mode support */
@media (prefers-color-scheme: dark) {
:root {
--dm-bg: #1e293b;
--dm-bg-secondary: #334155;
--dm-text: #f1f5f9;
--dm-text-secondary: #94a3b8;
--dm-border: #475569;
}
}
/* Modern Grid Layout */
.desk-moloni-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 1.5rem;
margin: 1.5rem 0;
}
.desk-moloni-grid--2col {
grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
}
.desk-moloni-grid--3col {
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}
/* Modern Card Design */
.desk-moloni-card {
background: var(--dm-bg);
border: 1px solid var(--dm-border);
border-radius: var(--dm-border-radius);
box-shadow: var(--dm-shadow);
padding: 1.5rem;
transition: var(--dm-transition);
position: relative;
overflow: hidden;
}
.desk-moloni-card:hover {
transform: translateY(-2px);
box-shadow: var(--dm-shadow-lg);
}
.desk-moloni-card__header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 1rem;
padding-bottom: 1rem;
border-bottom: 1px solid var(--dm-border);
}
.desk-moloni-card__title {
font-size: 1.125rem;
font-weight: 600;
color: var(--dm-text);
margin: 0;
}
.desk-moloni-card__content {
color: var(--dm-text-secondary);
}
.desk-moloni-card__footer {
margin-top: 1.5rem;
padding-top: 1rem;
border-top: 1px solid var(--dm-border);
}
/* Status Indicators - Modern Design */
.desk-moloni-status {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.375rem 0.75rem;
border-radius: 6px;
font-size: 0.875rem;
font-weight: 500;
transition: var(--dm-transition);
}
.desk-moloni-status--success {
background: rgba(16, 185, 129, 0.1);
color: var(--dm-success);
border: 1px solid rgba(16, 185, 129, 0.2);
}
.desk-moloni-status--error {
background: rgba(239, 68, 68, 0.1);
color: var(--dm-error);
border: 1px solid rgba(239, 68, 68, 0.2);
}
.desk-moloni-status--warning {
background: rgba(245, 158, 11, 0.1);
color: var(--dm-warning);
border: 1px solid rgba(245, 158, 11, 0.2);
}
.desk-moloni-status--info {
background: rgba(6, 182, 212, 0.1);
color: var(--dm-info);
border: 1px solid rgba(6, 182, 212, 0.2);
}
/* Modern Buttons */
.desk-moloni-btn {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.625rem 1.25rem;
border: none;
border-radius: 6px;
font-size: 0.875rem;
font-weight: 500;
text-decoration: none;
cursor: pointer;
transition: var(--dm-transition);
white-space: nowrap;
}
.desk-moloni-btn--primary {
background: var(--dm-primary);
color: white;
}
.desk-moloni-btn--primary:hover {
background: var(--dm-primary-dark);
transform: translateY(-1px);
}
.desk-moloni-btn--secondary {
background: var(--dm-bg-secondary);
color: var(--dm-text);
border: 1px solid var(--dm-border);
}
.desk-moloni-btn--secondary:hover {
background: var(--dm-border);
}
/* Dashboard Metrics */
.desk-moloni-metrics {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 1rem;
}
.desk-moloni-metric {
background: var(--dm-bg);
border: 1px solid var(--dm-border);
border-radius: var(--dm-border-radius);
padding: 1.5rem;
text-align: center;
position: relative;
overflow: hidden;
}
.desk-moloni-metric__value {
font-size: 2rem;
font-weight: 700;
color: var(--dm-primary);
margin-bottom: 0.5rem;
}
.desk-moloni-metric__label {
font-size: 0.875rem;
color: var(--dm-text-secondary);
text-transform: uppercase;
letter-spacing: 0.05em;
}
/* Progress Bars */
.desk-moloni-progress {
width: 100%;
height: 8px;
background: var(--dm-bg-secondary);
border-radius: 4px;
overflow: hidden;
position: relative;
}
.desk-moloni-progress__bar {
height: 100%;
background: linear-gradient(90deg, var(--dm-primary), var(--dm-primary-dark));
border-radius: 4px;
transition: width 0.3s ease;
position: relative;
}
.desk-moloni-progress__bar::after {
content: '';
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
animation: shimmer 2s infinite;
}
@keyframes shimmer {
0% { transform: translateX(-100%); }
100% { transform: translateX(100%); }
}
/* Tables */
.desk-moloni-table {
width: 100%;
border-collapse: collapse;
background: var(--dm-bg);
border-radius: var(--dm-border-radius);
overflow: hidden;
box-shadow: var(--dm-shadow);
}
.desk-moloni-table th,
.desk-moloni-table td {
padding: 1rem;
text-align: left;
border-bottom: 1px solid var(--dm-border);
}
.desk-moloni-table th {
background: var(--dm-bg-secondary);
font-weight: 600;
color: var(--dm-text);
font-size: 0.875rem;
text-transform: uppercase;
letter-spacing: 0.05em;
}
.desk-moloni-table tr:hover {
background: var(--dm-bg-secondary);
}
/* Forms */
.desk-moloni-form {
display: grid;
gap: 1.5rem;
}
.desk-moloni-form__group {
display: flex;
flex-direction: column;
gap: 0.5rem;
}
.desk-moloni-form__label {
font-size: 0.875rem;
font-weight: 500;
color: var(--dm-text);
}
.desk-moloni-form__input {
padding: 0.75rem;
border: 1px solid var(--dm-border);
border-radius: 6px;
font-size: 0.875rem;
background: var(--dm-bg);
color: var(--dm-text);
transition: var(--dm-transition);
}
.desk-moloni-form__input:focus {
outline: none;
border-color: var(--dm-primary);
box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}
/* Responsive Design */
@media (max-width: 768px) {
.desk-moloni-grid {
grid-template-columns: 1fr;
gap: 1rem;
}
.desk-moloni-metrics {
grid-template-columns: repeat(2, 1fr);
}
.desk-moloni-card {
padding: 1rem;
}
.desk-moloni-table {
font-size: 0.875rem;
}
.desk-moloni-table th,
.desk-moloni-table td {
padding: 0.75rem 0.5rem;
}
}
@media (max-width: 480px) {
.desk-moloni-metrics {
grid-template-columns: 1fr;
}
.desk-moloni-btn {
width: 100%;
justify-content: center;
}
}
font-weight: bold;
text-transform: uppercase;
}
.desk-moloni-status.success {
background-color: #5cb85c;
color: white;
}
.desk-moloni-status.error {
background-color: #d9534f;
color: white;
}
.desk-moloni-status.warning {
background-color: #f0ad4e;
color: white;
}
.desk-moloni-status.pending {
background-color: #777;
color: white;
}
/* Configuration forms */
.desk-moloni-config-section {
background: #fff;
border: 1px solid #ddd;
border-radius: 4px;
margin-bottom: 20px;
overflow: hidden;
}
.desk-moloni-config-header {
background: #f5f5f5;
border-bottom: 1px solid #ddd;
padding: 15px 20px;
font-weight: bold;
}
.desk-moloni-config-body {
padding: 20px;
}
/* Sync status cards */
.desk-moloni-stats {
display: flex;
gap: 20px;
margin-bottom: 20px;
}
.desk-moloni-stat-card {
flex: 1;
background: #fff;
border: 1px solid #ddd;
border-radius: 4px;
padding: 20px;
text-align: center;
}
.desk-moloni-stat-number {
font-size: 2em;
font-weight: bold;
color: #337ab7;
}
.desk-moloni-stat-label {
color: #777;
margin-top: 5px;
}
/* Queue table styling */
.desk-moloni-queue-table {
width: 100%;
border-collapse: collapse;
}
.desk-moloni-queue-table th,
.desk-moloni-queue-table td {
padding: 8px 12px;
text-align: left;
border-bottom: 1px solid #ddd;
}
.desk-moloni-queue-table th {
background-color: #f5f5f5;
font-weight: bold;
}
/* Log viewer */
.desk-moloni-log-viewer {
background: #f8f8f8;
border: 1px solid #ddd;
border-radius: 4px;
font-family: 'Courier New', monospace;
font-size: 12px;
height: 400px;
overflow-y: auto;
padding: 10px;
}
.desk-moloni-log-line {
margin-bottom: 2px;
}
.desk-moloni-log-line.error {
color: #d9534f;
}
.desk-moloni-log-line.warning {
color: #f0ad4e;
}
.desk-moloni-log-line.info {
color: #337ab7;
}
/* Buttons */
.desk-moloni-btn {
background-color: #337ab7;
border: 1px solid #2e6da4;
border-radius: 4px;
color: white;
cursor: pointer;
display: inline-block;
font-size: 14px;
font-weight: normal;
line-height: 1.42857143;
margin-bottom: 0;
padding: 6px 12px;
text-align: center;
text-decoration: none;
vertical-align: middle;
white-space: nowrap;
}
.desk-moloni-btn:hover {
background-color: #286090;
border-color: #204d74;
color: white;
text-decoration: none;
}
.desk-moloni-btn-success {
background-color: #5cb85c;
border-color: #4cae4c;
}
.desk-moloni-btn-success:hover {
background-color: #449d44;
border-color: #398439;
}
.desk-moloni-btn-danger {
background-color: #d9534f;
border-color: #d43f3a;
}
.desk-moloni-btn-danger:hover {
background-color: #c9302c;
border-color: #ac2925;
}
/* Loading spinner */
.desk-moloni-loading {
display: inline-block;
width: 20px;
height: 20px;
border: 3px solid #f3f3f3;
border-top: 3px solid #337ab7;
border-radius: 50%;
animation: desk-moloni-spin 1s linear infinite;
}
@keyframes desk-moloni-spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
/* Notifications */
.desk-moloni-notification {
border-radius: 4px;
margin-bottom: 15px;
padding: 15px;
}
.desk-moloni-notification.success {
background-color: #dff0d8;
border: 1px solid #d6e9c6;
color: #3c763d;
}
.desk-moloni-notification.error {
background-color: #f2dede;
border: 1px solid #ebccd1;
color: #a94442;
}
.desk-moloni-notification.warning {
background-color: #fcf8e3;
border: 1px solid #faebcc;
color: #8a6d3b;
}
.desk-moloni-notification.info {
background-color: #d9edf7;
border: 1px solid #bce8f1;
color: #31708f;
}
/* Responsive adjustments */
@media (max-width: 768px) {
.desk-moloni-stats {
flex-direction: column;
}
.desk-moloni-stat-card {
margin-bottom: 10px;
}
}
/* Form inputs */
.desk-moloni-form-group {
margin-bottom: 15px;
}
.desk-moloni-form-label {
display: block;
font-weight: bold;
margin-bottom: 5px;
}
.desk-moloni-form-control {
background-color: #fff;
background-image: none;
border: 1px solid #ccc;
border-radius: 4px;
box-shadow: inset 0 1px 1px rgba(0,0,0,.075);
color: #555;
display: block;
font-size: 14px;
height: 34px;
line-height: 1.42857143;
padding: 6px 12px;
transition: border-color ease-in-out .15s,box-shadow ease-in-out .15s;
width: 100%;
}
.desk-moloni-form-control:focus {
border-color: #66afe9;
box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102,175,233,.6);
outline: 0;
}
/* Utility classes */
.desk-moloni-text-center {
text-align: center;
}
.desk-moloni-text-right {
text-align: right;
}
.desk-moloni-pull-right {
float: right;
}
.desk-moloni-pull-left {
float: left;
}
.desk-moloni-clearfix:after {
clear: both;
content: "";
display: table;
}