askrobots / dbbasic-admin
Public
An admin interface that builds itself from the dbbasic modules you install; its pages follow file paths, like CGI.
review.html · 22.8 KB · 603 lines
| 1 | <!DOCTYPE html> |
| 2 | <html lang="en"> |
| 3 | <head> |
| 4 | <meta charset="UTF-8"> |
| 5 | <meta name="viewport" content="width=device-width, initial-scale=1.0"> |
| 6 | <title>Review Queue - DBBASIC Studio</title> |
| 7 | <link rel="stylesheet" href="../../static/css/admin.css"> |
| 8 | </head> |
| 9 | <body> |
| 10 | <div class="studio-container"> |
| 11 | <header class="studio-header"> |
| 12 | <div class="logo"> |
| 13 | <span class="logo-icon">⚡</span> |
| 14 | <span class="logo-text">DBBASIC Studio</span> |
| 15 | </div> |
| 16 | <div class="header-actions"> |
| 17 | <span class="project-name">myblog/</span> |
| 18 | <button class="btn-icon" title="Deploy">🚀</button> |
| 19 | <button class="btn-icon" title="Settings">⚙️</button> |
| 20 | </div> |
| 21 | </header> |
| 22 | |
| 23 | <div class="studio-layout"> |
| 24 | <nav class="sidebar"> |
| 25 | <a href="../../index.html" class="nav-item"> |
| 26 | <span class="nav-icon">📊</span> |
| 27 | <span class="nav-label">Dashboard</span> |
| 28 | </a> |
| 29 | <a href="code.html" class="nav-item"> |
| 30 | <span class="nav-icon">💻</span> |
| 31 | <span class="nav-label">Code</span> |
| 32 | </a> |
| 33 | <a href="database.html" class="nav-item"> |
| 34 | <span class="nav-icon">🗄️</span> |
| 35 | <span class="nav-label">Database</span> |
| 36 | </a> |
| 37 | <a href="posts/list.html" class="nav-item"> |
| 38 | <span class="nav-icon">📝</span> |
| 39 | <span class="nav-label">Posts</span> |
| 40 | </a> |
| 41 | <a href="users/list.html" class="nav-item"> |
| 42 | <span class="nav-icon">👥</span> |
| 43 | <span class="nav-label">Users</span> |
| 44 | </a> |
| 45 | <a href="themes.html" class="nav-item"> |
| 46 | <span class="nav-icon">🎨</span> |
| 47 | <span class="nav-label">Themes</span> |
| 48 | </a> |
| 49 | <a href="media.html" class="nav-item"> |
| 50 | <span class="nav-icon">🖼️</span> |
| 51 | <span class="nav-label">Media</span> |
| 52 | </a> |
| 53 | <div class="nav-divider"></div> |
| 54 | <a href="review.html" class="nav-item active"> |
| 55 | <span class="nav-icon">✅</span> |
| 56 | <span class="nav-label">Review</span> |
| 57 | <span class="nav-badge">3</span> |
| 58 | </a> |
| 59 | <a href="metrics.html" class="nav-item"> |
| 60 | <span class="nav-icon">📈</span> |
| 61 | <span class="nav-label">Metrics</span> |
| 62 | </a> |
| 63 | <a href="analytics.html" class="nav-item"> |
| 64 | <span class="nav-icon">📊</span> |
| 65 | <span class="nav-label">Analytics</span> |
| 66 | </a> |
| 67 | <a href="jobs.html" class="nav-item"> |
| 68 | <span class="nav-icon">⏰</span> |
| 69 | <span class="nav-label">Jobs</span> |
| 70 | </a> |
| 71 | <a href="logs.html" class="nav-item"> |
| 72 | <span class="nav-icon">📋</span> |
| 73 | <span class="nav-label">Logs</span> |
| 74 | </a> |
| 75 | <a href="deploy.html" class="nav-item"> |
| 76 | <span class="nav-icon">🚀</span> |
| 77 | <span class="nav-label">Deploy</span> |
| 78 | </a> |
| 79 | <a href="backup.html" class="nav-item"> |
| 80 | <span class="nav-icon">💾</span> |
| 81 | <span class="nav-label">Backup</span> |
| 82 | </a> |
| 83 | <a href="settings.html" class="nav-item"> |
| 84 | <span class="nav-icon">⚙️</span> |
| 85 | <span class="nav-label">Settings</span> |
| 86 | </a> |
| 87 | </nav> |
| 88 | |
| 89 | <main class="main-content"> |
| 90 | <div class="content-header"> |
| 91 | <div> |
| 92 | <h1>Review Queue</h1> |
| 93 | <div class="breadcrumb">Home / Review</div> |
| 94 | </div> |
| 95 | <div class="header-actions"> |
| 96 | <span class="pending-count">3 items pending</span> |
| 97 | </div> |
| 98 | </div> |
| 99 | |
| 100 | <!-- Review Tabs --> |
| 101 | <div class="review-tabs"> |
| 102 | <button class="review-tab active"> |
| 103 | Comments <span class="tab-count">3</span> |
| 104 | </button> |
| 105 | <button class="review-tab"> |
| 106 | Posts <span class="tab-count">0</span> |
| 107 | </button> |
| 108 | <button class="review-tab"> |
| 109 | Users <span class="tab-count">0</span> |
| 110 | </button> |
| 111 | <button class="review-tab"> |
| 112 | Reports <span class="tab-count">0</span> |
| 113 | </button> |
| 114 | </div> |
| 115 | |
| 116 | <!-- Pending Comments --> |
| 117 | <div class="card"> |
| 118 | <div class="review-header"> |
| 119 | <h2>Pending Comments</h2> |
| 120 | <div class="bulk-actions"> |
| 121 | <button class="btn-secondary-small">Approve All</button> |
| 122 | <button class="btn-danger-outline-small">Delete All</button> |
| 123 | </div> |
| 124 | </div> |
| 125 | |
| 126 | <div class="review-list"> |
| 127 | <!-- Comment 1 --> |
| 128 | <div class="review-item"> |
| 129 | <div class="review-content"> |
| 130 | <div class="review-author"> |
| 131 | <div class="author-avatar">LS</div> |
| 132 | <div class="author-info"> |
| 133 | <div class="author-name">Lisa Garcia</div> |
| 134 | <div class="author-email">lisa@example.com</div> |
| 135 | </div> |
| 136 | </div> |
| 137 | |
| 138 | <div class="review-post-ref"> |
| 139 | On: <a href="#" class="post-link">Why Rails Generators Aren't Enough</a> |
| 140 | </div> |
| 141 | |
| 142 | <div class="review-text"> |
| 143 | Rails is still great, but I see your point about generators being limited. |
| 144 | Have you considered trying Hotwire? It makes Rails much more productive |
| 145 | without needing a complex JavaScript setup. |
| 146 | </div> |
| 147 | |
| 148 | <div class="review-meta"> |
| 149 | <span>Posted: 2 hours ago</span> |
| 150 | <span>•</span> |
| 151 | <span>IP: 192.168.1.45</span> |
| 152 | <span>•</span> |
| 153 | <span class="spam-score">Spam Score: 2/100</span> |
| 154 | </div> |
| 155 | </div> |
| 156 | |
| 157 | <div class="review-actions"> |
| 158 | <button class="btn-success">✓ Approve</button> |
| 159 | <button class="btn-secondary">Edit</button> |
| 160 | <button class="btn-secondary">Mark Spam</button> |
| 161 | <button class="btn-danger-outline">Delete</button> |
| 162 | </div> |
| 163 | </div> |
| 164 | |
| 165 | <!-- Comment 2 --> |
| 166 | <div class="review-item"> |
| 167 | <div class="review-content"> |
| 168 | <div class="review-author"> |
| 169 | <div class="author-avatar">JB</div> |
| 170 | <div class="author-info"> |
| 171 | <div class="author-name">James Brown</div> |
| 172 | <div class="author-email">james@suspicious-domain.xyz</div> |
| 173 | </div> |
| 174 | </div> |
| 175 | |
| 176 | <div class="review-post-ref"> |
| 177 | On: <a href="#" class="post-link">Getting Started with DBBASIC</a> |
| 178 | </div> |
| 179 | |
| 180 | <div class="review-text"> |
| 181 | Nice article! Check out my website for more web development tips! |
| 182 | http://definitely-not-spam.biz - Best SEO services guaranteed! |
| 183 | </div> |
| 184 | |
| 185 | <div class="review-meta"> |
| 186 | <span>Posted: 5 hours ago</span> |
| 187 | <span>•</span> |
| 188 | <span>IP: 123.45.67.89</span> |
| 189 | <span>•</span> |
| 190 | <span class="spam-score warning">⚠️ Spam Score: 87/100</span> |
| 191 | </div> |
| 192 | |
| 193 | <div class="spam-warning"> |
| 194 | <strong>⚠️ Potential Spam Detected:</strong> |
| 195 | <ul> |
| 196 | <li>Contains suspicious link</li> |
| 197 | <li>Email domain has low reputation</li> |
| 198 | <li>Generic positive comment</li> |
| 199 | </ul> |
| 200 | </div> |
| 201 | </div> |
| 202 | |
| 203 | <div class="review-actions"> |
| 204 | <button class="btn-success">✓ Approve</button> |
| 205 | <button class="btn-secondary">Edit</button> |
| 206 | <button class="btn-warning">Mark Spam</button> |
| 207 | <button class="btn-danger-outline">Delete</button> |
| 208 | </div> |
| 209 | </div> |
| 210 | |
| 211 | <!-- Comment 3 --> |
| 212 | <div class="review-item"> |
| 213 | <div class="review-content"> |
| 214 | <div class="review-author"> |
| 215 | <div class="author-avatar">MK</div> |
| 216 | <div class="author-info"> |
| 217 | <div class="author-name">Mike Kim</div> |
| 218 | <div class="author-email">mike@example.com</div> |
| 219 | </div> |
| 220 | </div> |
| 221 | |
| 222 | <div class="review-post-ref"> |
| 223 | On: <a href="#" class="post-link">TSV Files as a Database</a> |
| 224 | </div> |
| 225 | |
| 226 | <div class="review-text"> |
| 227 | This is fascinating! I never thought about using TSV files for a database. |
| 228 | How does it handle concurrent writes? Do you use file locking? |
| 229 | </div> |
| 230 | |
| 231 | <div class="review-meta"> |
| 232 | <span>Posted: 1 day ago</span> |
| 233 | <span>•</span> |
| 234 | <span>IP: 98.76.54.32</span> |
| 235 | <span>•</span> |
| 236 | <span class="spam-score">Spam Score: 1/100</span> |
| 237 | </div> |
| 238 | </div> |
| 239 | |
| 240 | <div class="review-actions"> |
| 241 | <button class="btn-success">✓ Approve</button> |
| 242 | <button class="btn-secondary">Edit</button> |
| 243 | <button class="btn-secondary">Mark Spam</button> |
| 244 | <button class="btn-danger-outline">Delete</button> |
| 245 | </div> |
| 246 | </div> |
| 247 | </div> |
| 248 | </div> |
| 249 | |
| 250 | <!-- Moderation Settings --> |
| 251 | <div class="card"> |
| 252 | <h2>Moderation Settings</h2> |
| 253 | <div class="moderation-settings"> |
| 254 | <div class="setting-item"> |
| 255 | <div class="setting-info"> |
| 256 | <div class="setting-label">Automatic Approval</div> |
| 257 | <div class="setting-description">Automatically approve comments from trusted users</div> |
| 258 | </div> |
| 259 | <div class="setting-value"> |
| 260 | <label class="toggle"> |
| 261 | <input type="checkbox" checked> |
| 262 | <span class="toggle-slider"></span> |
| 263 | </label> |
| 264 | </div> |
| 265 | </div> |
| 266 | |
| 267 | <div class="setting-item"> |
| 268 | <div class="setting-info"> |
| 269 | <div class="setting-label">Spam Filter</div> |
| 270 | <div class="setting-description">Use AI to detect and block spam automatically</div> |
| 271 | </div> |
| 272 | <div class="setting-value"> |
| 273 | <label class="toggle"> |
| 274 | <input type="checkbox" checked> |
| 275 | <span class="toggle-slider"></span> |
| 276 | </label> |
| 277 | </div> |
| 278 | </div> |
| 279 | |
| 280 | <div class="setting-item"> |
| 281 | <div class="setting-info"> |
| 282 | <div class="setting-label">Link Moderation</div> |
| 283 | <div class="setting-description">Hold comments with links for manual review</div> |
| 284 | </div> |
| 285 | <div class="setting-value"> |
| 286 | <label class="toggle"> |
| 287 | <input type="checkbox" checked> |
| 288 | <span class="toggle-slider"></span> |
| 289 | </label> |
| 290 | </div> |
| 291 | </div> |
| 292 | |
| 293 | <div class="setting-item"> |
| 294 | <div class="setting-info"> |
| 295 | <div class="setting-label">Email Notifications</div> |
| 296 | <div class="setting-description">Get notified when new comments need review</div> |
| 297 | </div> |
| 298 | <div class="setting-value"> |
| 299 | <label class="toggle"> |
| 300 | <input type="checkbox"> |
| 301 | <span class="toggle-slider"></span> |
| 302 | </label> |
| 303 | </div> |
| 304 | </div> |
| 305 | </div> |
| 306 | </div> |
| 307 | |
| 308 | <!-- Review Data --> |
| 309 | <div class="card"> |
| 310 | <h2>Review Queue Data</h2> |
| 311 | <div class="data-source"> |
| 312 | <div class="data-source-icon">📄</div> |
| 313 | <div class="data-source-info"> |
| 314 | <div class="data-source-title">data/comments.tsv (status=pending)</div> |
| 315 | <div class="data-source-description"> |
| 316 | Comments awaiting moderation. Query with: |
| 317 | <code>awk -F'\t' '$5 == "pending"' data/comments.tsv</code> |
| 318 | </div> |
| 319 | <div class="data-source-meta"> |
| 320 | 3 pending • 892 total comments |
| 321 | </div> |
| 322 | </div> |
| 323 | <button class="btn-secondary-small">View TSV</button> |
| 324 | </div> |
| 325 | </div> |
| 326 | </main> |
| 327 | |
| 328 | <aside class="ai-assistant"> |
| 329 | <div class="ai-header"> |
| 330 | <span class="ai-icon">🤖</span> |
| 331 | <span class="ai-title">AI Assistant</span> |
| 332 | <button class="ai-toggle">−</button> |
| 333 | </div> |
| 334 | |
| 335 | <div class="ai-content"> |
| 336 | <div class="ai-messages"> |
| 337 | <div class="ai-message ai-message-assistant"> |
| 338 | <div class="message-content"> |
| 339 | I can help you moderate comments, detect spam, or set up automatic filters. What would you like to do? |
| 340 | </div> |
| 341 | </div> |
| 342 | </div> |
| 343 | |
| 344 | <div class="ai-suggestions"> |
| 345 | <div class="suggestion-title">Try asking:</div> |
| 346 | <button class="suggestion-btn">"Is this comment spam?"</button> |
| 347 | <button class="suggestion-btn">"Create spam filter rules"</button> |
| 348 | <button class="suggestion-btn">"Bulk approve safe comments"</button> |
| 349 | </div> |
| 350 | |
| 351 | <div class="ai-input"> |
| 352 | <textarea placeholder="Ask AI about moderation..." rows="3"></textarea> |
| 353 | <button class="btn-primary">Send</button> |
| 354 | </div> |
| 355 | </div> |
| 356 | </aside> |
| 357 | </div> |
| 358 | </div> |
| 359 | |
| 360 | <style> |
| 361 | .pending-count { |
| 362 | font-weight: 600; |
| 363 | color: var(--color-warning); |
| 364 | } |
| 365 | |
| 366 | .review-tabs { |
| 367 | display: flex; |
| 368 | gap: 0.5rem; |
| 369 | margin-bottom: 2rem; |
| 370 | border-bottom: 1px solid var(--color-border); |
| 371 | } |
| 372 | |
| 373 | .review-tab { |
| 374 | display: flex; |
| 375 | align-items: center; |
| 376 | gap: 0.5rem; |
| 377 | padding: 0.75rem 1.5rem; |
| 378 | background: none; |
| 379 | border: none; |
| 380 | border-bottom: 2px solid transparent; |
| 381 | cursor: pointer; |
| 382 | font-weight: 500; |
| 383 | color: var(--color-text-muted); |
| 384 | } |
| 385 | |
| 386 | .review-tab.active { |
| 387 | color: var(--color-primary); |
| 388 | border-bottom-color: var(--color-primary); |
| 389 | } |
| 390 | |
| 391 | .tab-count { |
| 392 | padding: 0.125rem 0.5rem; |
| 393 | background: var(--color-bg); |
| 394 | border-radius: 1rem; |
| 395 | font-size: 0.75rem; |
| 396 | } |
| 397 | |
| 398 | .review-tab.active .tab-count { |
| 399 | background: var(--color-primary); |
| 400 | color: white; |
| 401 | } |
| 402 | |
| 403 | .review-header { |
| 404 | display: flex; |
| 405 | justify-content: space-between; |
| 406 | align-items: center; |
| 407 | margin-bottom: 1.5rem; |
| 408 | } |
| 409 | |
| 410 | .bulk-actions { |
| 411 | display: flex; |
| 412 | gap: 0.5rem; |
| 413 | } |
| 414 | |
| 415 | .review-list { |
| 416 | display: flex; |
| 417 | flex-direction: column; |
| 418 | gap: 1.5rem; |
| 419 | } |
| 420 | |
| 421 | .review-item { |
| 422 | padding: 1.5rem; |
| 423 | background: var(--color-bg); |
| 424 | border-radius: 0.5rem; |
| 425 | border: 1px solid var(--color-border); |
| 426 | } |
| 427 | |
| 428 | .review-content { |
| 429 | margin-bottom: 1.5rem; |
| 430 | } |
| 431 | |
| 432 | .review-author { |
| 433 | display: flex; |
| 434 | align-items: center; |
| 435 | gap: 1rem; |
| 436 | margin-bottom: 1rem; |
| 437 | } |
| 438 | |
| 439 | .author-avatar { |
| 440 | width: 3rem; |
| 441 | height: 3rem; |
| 442 | border-radius: 50%; |
| 443 | background: var(--color-primary); |
| 444 | color: white; |
| 445 | display: flex; |
| 446 | align-items: center; |
| 447 | justify-content: center; |
| 448 | font-weight: 600; |
| 449 | } |
| 450 | |
| 451 | .author-name { |
| 452 | font-weight: 600; |
| 453 | margin-bottom: 0.25rem; |
| 454 | } |
| 455 | |
| 456 | .author-email { |
| 457 | font-size: 0.875rem; |
| 458 | color: var(--color-text-muted); |
| 459 | } |
| 460 | |
| 461 | .review-post-ref { |
| 462 | font-size: 0.875rem; |
| 463 | color: var(--color-text-muted); |
| 464 | margin-bottom: 1rem; |
| 465 | } |
| 466 | |
| 467 | .post-link { |
| 468 | color: var(--color-primary); |
| 469 | text-decoration: none; |
| 470 | } |
| 471 | |
| 472 | .post-link:hover { |
| 473 | text-decoration: underline; |
| 474 | } |
| 475 | |
| 476 | .review-text { |
| 477 | padding: 1rem; |
| 478 | background: var(--color-surface); |
| 479 | border-radius: 0.375rem; |
| 480 | border-left: 3px solid var(--color-border); |
| 481 | margin-bottom: 1rem; |
| 482 | line-height: 1.6; |
| 483 | } |
| 484 | |
| 485 | .review-meta { |
| 486 | font-size: 0.875rem; |
| 487 | color: var(--color-text-muted); |
| 488 | display: flex; |
| 489 | gap: 0.5rem; |
| 490 | flex-wrap: wrap; |
| 491 | } |
| 492 | |
| 493 | .spam-score { |
| 494 | font-weight: 500; |
| 495 | } |
| 496 | |
| 497 | .spam-score.warning { |
| 498 | color: var(--color-danger); |
| 499 | font-weight: 600; |
| 500 | } |
| 501 | |
| 502 | .spam-warning { |
| 503 | margin-top: 1rem; |
| 504 | padding: 1rem; |
| 505 | background: #fef3c7; |
| 506 | border: 1px solid #f59e0b; |
| 507 | border-radius: 0.375rem; |
| 508 | font-size: 0.875rem; |
| 509 | } |
| 510 | |
| 511 | .spam-warning strong { |
| 512 | display: block; |
| 513 | margin-bottom: 0.5rem; |
| 514 | color: #92400e; |
| 515 | } |
| 516 | |
| 517 | .spam-warning ul { |
| 518 | margin: 0; |
| 519 | padding-left: 1.5rem; |
| 520 | } |
| 521 | |
| 522 | .spam-warning li { |
| 523 | color: #78350f; |
| 524 | } |
| 525 | |
| 526 | .review-actions { |
| 527 | display: flex; |
| 528 | gap: 0.75rem; |
| 529 | flex-wrap: wrap; |
| 530 | } |
| 531 | |
| 532 | .btn-success { |
| 533 | background: var(--color-success); |
| 534 | color: white; |
| 535 | border: none; |
| 536 | padding: 0.625rem 1.25rem; |
| 537 | border-radius: 0.375rem; |
| 538 | font-weight: 500; |
| 539 | cursor: pointer; |
| 540 | } |
| 541 | |
| 542 | .btn-warning { |
| 543 | background: var(--color-warning); |
| 544 | color: white; |
| 545 | border: none; |
| 546 | padding: 0.625rem 1.25rem; |
| 547 | border-radius: 0.375rem; |
| 548 | font-weight: 500; |
| 549 | cursor: pointer; |
| 550 | } |
| 551 | |
| 552 | .moderation-settings { |
| 553 | display: flex; |
| 554 | flex-direction: column; |
| 555 | } |
| 556 | |
| 557 | .toggle { |
| 558 | position: relative; |
| 559 | display: inline-block; |
| 560 | width: 48px; |
| 561 | height: 24px; |
| 562 | } |
| 563 | |
| 564 | .toggle input { |
| 565 | opacity: 0; |
| 566 | width: 0; |
| 567 | height: 0; |
| 568 | } |
| 569 | |
| 570 | .toggle-slider { |
| 571 | position: absolute; |
| 572 | cursor: pointer; |
| 573 | top: 0; |
| 574 | left: 0; |
| 575 | right: 0; |
| 576 | bottom: 0; |
| 577 | background-color: var(--color-border); |
| 578 | transition: 0.3s; |
| 579 | border-radius: 24px; |
| 580 | } |
| 581 | |
| 582 | .toggle-slider:before { |
| 583 | position: absolute; |
| 584 | content: ""; |
| 585 | height: 18px; |
| 586 | width: 18px; |
| 587 | left: 3px; |
| 588 | bottom: 3px; |
| 589 | background-color: white; |
| 590 | transition: 0.3s; |
| 591 | border-radius: 50%; |
| 592 | } |
| 593 | |
| 594 | .toggle input:checked + .toggle-slider { |
| 595 | background-color: var(--color-primary); |
| 596 | } |
| 597 | |
| 598 | .toggle input:checked + .toggle-slider:before { |
| 599 | transform: translateX(24px); |
| 600 | } |
| 601 | </style> |
| 602 | </body> |
| 603 | </html> |