@opengrip | Stream Overlay UI Customization Kit (status_bar.html)
Want to redesign or theme the @opengrip live stream dashboard? This is the exact 1920x1080 OBS browser-source HTML/CSS/JS template used live on stream, bundled with built-in offline mock data so you can open and customize it right in your browser with zero setup.
How to Customize & Preview Locally
- Copy the full HTML block below and save it as
status_bar.html. - Double-click
status_bar.htmlto open it in Chrome, Brave, Edge, or Firefox (zoom to fit1920x1080or use DevTools Device Toolbar set to1920 x 1080). - Interactive preview hotkeys (offline mode):
- Press
1to preview the New Follower popup toast - Press
2to preview the Rumble Rant popup toast - Press
3to preview the New Subscriber VIP popup toast - Press
4to toggle Sleep Mode
- Press
- Drop-in compatibility rules (so
@opengripcan load your file live in OBS in 5 seconds):- Keep
html, bodylocked to1920px x 1080px(overflow: hidden). - Keep
fetch('/api/state')and the JSON field names (badge,task,detail,best_run,next_goal,fps_history,history,chat_messages,followers,follower_goal,donations_dollars,donation_goal,total_runs,tex_ready_pct,watching_now,alert_event,sleep_mode). - Keep all styling self-contained inside this single
.htmlfile (inline CSS/JS/SVG, no external build tools required).
- Keep
- Share your finished file back via Pastebin, Rentry, GitHub Gist, or CodePen link in Rumble chat!
Full Standalone status_bar.html
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>opengrip Live Porting Board</title>
<style>
:root {
--bg: #070A0E;
--card: rgba(12, 16, 22, 0.86);
--border: rgba(255, 255, 255, 0.10);
--border-accent: rgba(133, 199, 66, 0.42);
--ink: #F4F7FA;
--ink-soft: #C5D1DD;
--muted: #8B9BAE;
--accent: #85C742;
--accent-bright: #9EE658;
--gold: #F5C451;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
width: 1920px;
height: 1080px;
overflow: hidden;
background: var(--bg);
color: var(--ink);
font-family: "Segoe UI", "Segoe UI Emoji", "Apple Color Emoji", -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
-webkit-font-smoothing: antialiased;
}
.backdrop {
position: fixed;
inset: 0;
background: url('/assets/bg_backdrop.jpg') center center / cover no-repeat;
filter: brightness(0.42) contrast(1.08);
transform: scale(1.02);
}
.vignette {
position: fixed;
inset: 0;
background:
radial-gradient(ellipse 70% 60% at 38% 42%, rgba(133, 199, 66, 0.08) 0%, transparent 65%),
linear-gradient(180deg, rgba(6, 9, 13, 0.78) 0%, rgba(6, 9, 13, 0.56) 45%, rgba(6, 9, 13, 0.90) 100%);
}
.grid-overlay {
position: fixed;
inset: 0;
background-image:
linear-gradient(rgba(255,255,255,0.024) 1px, transparent 1px),
linear-gradient(90deg, rgba(255,255,255,0.024) 1px, transparent 1px);
background-size: 64px 64px;
mask-image: radial-gradient(ellipse 85% 75% at 50% 50%, black 35%, transparent 100%);
}
.frame {
position: relative;
z-index: 2;
width: 1920px;
height: 1080px;
padding: 44px 68px 40px 68px;
display: flex;
flex-direction: column;
justify-content: space-between;
}
/* Top Header */
.top-bar {
display: flex;
align-items: center;
justify-content: space-between;
padding-bottom: 20px;
border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}
.brand-lockup { display: flex; align-items: center; gap: 18px; }
.emblem {
width: 58px;
height: 58px;
border-radius: 14px;
border: 1px solid rgba(133, 199, 66, 0.35);
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
object-fit: cover;
}
.brand-name { font-size: 27px; font-weight: 800; letter-spacing: 0.14em; color: var(--ink); }
.brand-sub { font-size: 13px; font-weight: 600; letter-spacing: 0.16em; color: var(--accent-bright); text-transform: uppercase; margin-top: 2px; }
.top-right { display: flex; align-items: center; gap: 14px; }
.chip {
display: inline-flex;
align-items: center;
gap: 10px;
padding: 10px 18px;
border-radius: 12px;
background: var(--card);
border: 1px solid var(--border);
font-family: "Consolas", "JetBrains Mono", monospace;
font-size: 15px;
font-weight: 700;
color: var(--ink-soft);
letter-spacing: 0.04em;
}
.chip.live {
border-color: var(--border-accent);
background: rgba(133, 199, 66, 0.11);
color: var(--accent-bright);
font-family: "Segoe UI", sans-serif;
letter-spacing: 0.10em;
text-transform: uppercase;
font-size: 13px;
}
.dot {
width: 10px;
height: 10px;
border-radius: 50%;
background: var(--accent-bright);
box-shadow: 0 0 12px var(--accent-bright);
animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
0%, 100% { opacity: 1; transform: scale(1); }
50% { opacity: 0.4; transform: scale(0.82); }
}
/* Main Split Stage: Left (Hero + Recent Progress Strip) | Right (Full-Height Live Chat) */
.stage {
flex: 1;
display: grid;
grid-template-columns: 1.44fr 0.92fr;
gap: 30px;
padding: 24px 0;
min-height: 0;
}
.left-col {
display: flex;
flex-direction: column;
gap: 13px;
min-height: 0;
}
.hero-panel {
position: relative;
flex: 1;
min-height: 205px;
border-radius: 20px;
background: linear-gradient(165deg, rgba(18, 24, 32, 0.90) 0%, rgba(9, 12, 17, 0.88) 100%);
border: 1px solid var(--border-accent);
box-shadow: 0 28px 64px rgba(0, 0, 0, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.12);
padding: 20px 34px 16px 34px;
display: flex;
flex-direction: column;
justify-content: space-between;
overflow: hidden;
}
.hero-panel::before {
content: "";
position: absolute;
left: 0;
top: 22px;
bottom: 22px;
width: 6px;
border-radius: 0 6px 6px 0;
background: var(--accent-bright);
box-shadow: 0 0 22px rgba(133, 199, 66, 0.75);
}
.eyebrow-row { display: flex; align-items: center; gap: 16px; }
.status-badge {
display: inline-flex;
align-items: center;
gap: 10px;
padding: 6px 13px;
border-radius: 10px;
background: rgba(133, 199, 66, 0.16);
border: 1px solid rgba(133, 199, 66, 0.48);
color: var(--accent-bright);
font-size: 13.5px;
font-weight: 800;
letter-spacing: 0.14em;
text-transform: uppercase;
}
.eyebrow-note { font-size: 12.5px; font-weight: 600; color: var(--muted); letter-spacing: 0.06em; text-transform: uppercase; }
.hero-copy { margin: 6px 0; display: flex; flex-direction: column; gap: 7px; }
.hero-task {
font-size: 40px;
font-weight: 800;
line-height: 1.06;
letter-spacing: -0.015em;
color: var(--ink);
text-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
}
.hero-detail { font-size: 19px; font-weight: 500; line-height: 1.32; color: var(--ink-soft); }
.hero-footer {
display: flex;
align-items: center;
justify-content: space-between;
padding-top: 10px;
border-top: 1px solid rgba(255, 255, 255, 0.09);
}
.game-wait { display: flex; align-items: center; gap: 12px; font-size: 14px; font-weight: 600; color: var(--muted); }
.spinner {
width: 16px;
height: 16px;
border-radius: 50%;
border: 2.5px solid rgba(133, 199, 66, 0.25);
border-top-color: var(--accent-bright);
animation: spin 1.1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.updated-tag { font-family: "Consolas", monospace; font-size: 13px; color: rgba(152, 166, 181, 0.8); }
/* Best Run Milestones + Next Goal 2-Column Strip */
.milestones-row {
display: grid;
grid-template-columns: 1.24fr 0.96fr;
gap: 16px;
flex-shrink: 0;
}
.ms-card {
padding: 16px 20px;
border-radius: 16px;
background: var(--card);
border: 1px solid var(--border);
display: flex;
flex-direction: column;
gap: 11px;
}
.ms-card.best {
border-color: rgba(133, 199, 66, 0.34);
background: linear-gradient(175deg, rgba(15, 23, 19, 0.90) 0%, rgba(10, 14, 19, 0.88) 100%);
}
.ms-card.goal {
border-color: rgba(245, 196, 81, 0.38);
background: linear-gradient(175deg, rgba(24, 21, 13, 0.88) 0%, rgba(12, 14, 19, 0.88) 100%);
}
.ms-head {
display: flex;
align-items: center;
justify-content: space-between;
gap: 10px;
}
.ms-tag {
display: inline-flex;
align-items: center;
gap: 7px;
font-size: 12px;
font-weight: 800;
letter-spacing: 0.12em;
text-transform: uppercase;
color: var(--accent-bright);
}
.ms-card.goal .ms-tag { color: var(--gold); }
.ms-tag-dot {
width: 7px;
height: 7px;
border-radius: 50%;
background: currentColor;
box-shadow: 0 0 8px currentColor;
}
.ms-sub-tag {
font-family: "Consolas", monospace;
font-size: 11px;
font-weight: 700;
color: var(--muted);
letter-spacing: 0.05em;
text-transform: uppercase;
}
.ms-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 9px 12px;
}
.ms-stat {
padding: 8px 11px;
border-radius: 10px;
background: rgba(255, 255, 255, 0.035);
border: 1px solid rgba(255, 255, 255, 0.06);
}
.ms-stat-val {
font-family: "Consolas", "JetBrains Mono", monospace;
font-size: 18px;
font-weight: 800;
color: var(--ink);
font-variant-numeric: tabular-nums;
line-height: 1.15;
}
.ms-stat-sub {
font-size: 12px;
font-weight: 600;
color: var(--muted);
margin-top: 2px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.goal-body {
display: flex;
flex-direction: column;
justify-content: center;
gap: 7px;
flex: 1;
}
.next-goal-title {
font-size: 22px;
font-weight: 800;
line-height: 1.18;
color: var(--ink);
}
.next-goal-detail {
font-size: 14.5px;
font-weight: 500;
line-height: 1.38;
color: var(--ink-soft);
}
/* Live Average FPS Progression Chart Card */
.perf-chart-card {
flex-shrink: 0;
border-radius: 16px;
padding: 13px 20px 10px 20px;
background: linear-gradient(175deg, rgba(13, 21, 18, 0.90) 0%, rgba(9, 13, 18, 0.88) 100%);
border: 1px solid rgba(133, 199, 66, 0.30);
box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
display: flex;
flex-direction: column;
gap: 6px;
}
.pc-head {
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
}
.pc-left {
display: flex;
align-items: center;
gap: 10px;
}
.pc-title {
font-size: 12px;
font-weight: 800;
letter-spacing: 0.12em;
text-transform: uppercase;
color: var(--accent-bright);
}
.pc-sub {
font-family: "Consolas", monospace;
font-size: 11px;
font-weight: 700;
color: var(--muted);
letter-spacing: 0.04em;
text-transform: uppercase;
}
.pc-pills {
display: flex;
align-items: center;
gap: 8px;
}
.pc-pill {
font-family: "Consolas", "JetBrains Mono", monospace;
font-size: 12.5px;
font-weight: 800;
padding: 3px 10px;
border-radius: 7px;
background: rgba(158, 230, 88, 0.14);
border: 1px solid rgba(158, 230, 88, 0.42);
color: var(--accent-bright);
white-space: nowrap;
}
.pc-pill.gold {
background: rgba(245, 196, 81, 0.15);
border-color: rgba(245, 196, 81, 0.45);
color: var(--gold);
}
.pc-svg-wrap {
width: 100%;
height: 112px;
}
.pc-svg-wrap svg {
width: 100%;
height: 100%;
display: block;
overflow: visible;
}
/* Compact Recent Progress Strip under Milestones */
.recent-strip {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
flex-shrink: 0;
}
.recent-card {
padding: 12px 18px;
border-radius: 14px;
background: var(--card);
border: 1px solid var(--border);
display: flex;
flex-direction: column;
gap: 3px;
}
.rc-top { display: flex; align-items: center; justify-content: space-between; }
.rc-badge { font-size: 11px; font-weight: 800; letter-spacing: 0.11em; color: var(--accent-bright); text-transform: uppercase; }
.rc-time { font-family: "Consolas", monospace; font-size: 11px; color: var(--muted); }
.rc-task { font-size: 16px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-detail { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Right Column: Full-Height Live Rumble Chat */
.chat-panel {
height: 100%;
border-radius: 22px;
background: var(--card);
border: 1px solid var(--border);
box-shadow: 0 24px 56px rgba(0, 0, 0, 0.58);
padding: 26px 28px;
display: flex;
flex-direction: column;
min-height: 0;
overflow: hidden;
}
.chat-head {
display: flex;
align-items: center;
justify-content: space-between;
gap: 10px;
padding-bottom: 14px;
border-bottom: 1px solid rgba(255, 255, 255, 0.09);
flex-shrink: 0;
}
.chat-title {
display: flex;
align-items: center;
gap: 9px;
font-size: 13.5px;
font-weight: 800;
letter-spacing: 0.10em;
text-transform: uppercase;
color: var(--accent-bright);
white-space: nowrap;
}
.chat-viewers {
font-family: "Consolas", monospace;
font-size: 12.5px;
font-weight: 700;
color: var(--ink-soft);
padding: 4px 10px;
border-radius: 8px;
background: rgba(255, 255, 255, 0.06);
white-space: nowrap;
flex-shrink: 0;
}
.chat-list {
flex: 1;
min-height: 0;
display: flex;
flex-direction: column;
justify-content: flex-end;
gap: 10px;
padding-top: 14px;
overflow: hidden;
-webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 10%, #000 100%);
mask-image: linear-gradient(to bottom, transparent 0%, #000 10%, #000 100%);
}
.chat-msg {
padding: 12px 15px;
border-radius: 12px;
background: rgba(255, 255, 255, 0.035);
border: 1px solid rgba(255, 255, 255, 0.06);
font-size: 19px;
line-height: 1.34;
word-break: break-word;
}
.chat-msg.rant {
background: linear-gradient(135deg, rgba(133, 199, 66, 0.20) 0%, rgba(245, 196, 81, 0.14) 100%);
border-color: rgba(158, 230, 88, 0.55);
box-shadow: 0 6px 20px rgba(133, 199, 66, 0.15);
}
.cm-head {
display: flex;
align-items: center;
gap: 8px;
margin-bottom: 3px;
}
.cm-user {
font-weight: 800;
font-size: 16px;
color: var(--accent-bright);
}
.cm-rant-amt {
padding: 2px 8px;
border-radius: 6px;
background: var(--gold);
color: #0D0B04;
font-family: "Consolas", monospace;
font-size: 13px;
font-weight: 800;
}
.cm-badge {
padding: 2px 6px;
border-radius: 5px;
background: rgba(255, 255, 255, 0.10);
color: var(--ink-soft);
font-size: 11px;
font-weight: 700;
text-transform: uppercase;
}
.cm-text { color: var(--ink); font-weight: 500; }
.cm-emote-pill {
display: inline-block;
padding: 1px 7px;
margin: 0 2px;
border-radius: 6px;
background: rgba(133, 199, 66, 0.16);
border: 1px solid rgba(133, 199, 66, 0.35);
color: var(--accent-bright);
font-size: 13px;
font-weight: 800;
vertical-align: middle;
}
.cm-emote-img {
display: inline-block;
height: 32px;
width: auto;
vertical-align: -7px;
margin: 0 3px;
border-radius: 4px;
object-fit: contain;
animation: emotePop 260ms cubic-bezier(0.22, 1.4, 0.36, 1);
}
.cm-text.emote-only .cm-emote-img {
height: 46px;
vertical-align: middle;
margin: 2px 4px 0 0;
}
@keyframes emotePop {
0% { transform: scale(0.65); opacity: 0; }
100% { transform: scale(1); opacity: 1; }
}
.chat-empty {
margin: auto 0;
padding: 28px 22px;
border-radius: 16px;
background: rgba(255, 255, 255, 0.025);
border: 1px dashed rgba(255, 255, 255, 0.12);
text-align: center;
display: flex;
flex-direction: column;
gap: 8px;
}
.chat-empty-title { font-size: 19px; font-weight: 700; color: var(--ink-soft); }
.chat-empty-sub { font-size: 15px; color: var(--muted); line-height: 1.4; }
/* Bottom Live Goal Progress Bars */
.goals-bar {
display: grid;
grid-template-columns: 1.15fr 1.15fr 0.72fr;
gap: 22px;
padding-top: 18px;
border-top: 1px solid rgba(255, 255, 255, 0.09);
}
.goal-card {
padding: 18px 22px;
border-radius: 16px;
background: var(--card);
border: 1px solid var(--border);
display: flex;
flex-direction: column;
gap: 9px;
}
.goal-card.highlight {
border-color: rgba(133, 199, 66, 0.38);
background: linear-gradient(180deg, rgba(16, 24, 18, 0.88) 0%, rgba(11, 16, 20, 0.88) 100%);
}
.goal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.goal-left { display: flex; align-items: center; gap: 10px; }
.goal-tag {
padding: 5px 10px;
border-radius: 7px;
background: rgba(133, 199, 66, 0.16);
color: var(--accent-bright);
font-size: 12px;
font-weight: 800;
letter-spacing: 0.09em;
text-transform: uppercase;
}
.goal-title { font-size: 17px; font-weight: 700; color: var(--ink); }
.goal-numbers {
font-family: "Consolas", "JetBrains Mono", monospace;
font-size: 20px;
font-weight: 800;
color: var(--accent-bright);
font-variant-numeric: tabular-nums;
}
.track {
width: 100%;
height: 11px;
border-radius: 999px;
background: rgba(255, 255, 255, 0.09);
overflow: hidden;
border: 1px solid rgba(255, 255, 255, 0.06);
}
.fill {
height: 100%;
width: 0%;
border-radius: 999px;
background: linear-gradient(90deg, #6EA832 0%, #9EE658 100%);
box-shadow: 0 0 14px rgba(158, 230, 88, 0.65);
transition: width 700ms cubic-bezier(0.16, 1, 0.3, 1);
}
.goal-sub { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--muted); }
.goal-sub strong { color: var(--ink-soft); font-weight: 700; }
.boost-card {
padding: 18px 22px;
border-radius: 16px;
background: var(--card);
border: 1px solid var(--border);
display: flex;
flex-direction: column;
justify-content: center;
gap: 8px;
}
/* Live Follow / Rant Toast Banner */
.alert-toast {
position: fixed;
top: 32px;
left: 50%;
transform: translate(-50%, -140px);
z-index: 20;
min-width: 680px;
max-width: 980px;
padding: 18px 28px;
border-radius: 16px;
background: linear-gradient(135deg, rgba(18, 34, 20, 0.97) 0%, rgba(12, 18, 26, 0.97) 100%);
border: 2px solid var(--accent-bright);
box-shadow: 0 20px 54px rgba(0, 0, 0, 0.75), 0 0 36px rgba(158, 230, 88, 0.35);
display: flex;
align-items: center;
gap: 18px;
opacity: 0;
transition: transform 380ms cubic-bezier(0.16, 1, 0.3, 1), opacity 380ms ease;
}
.alert-toast.rant {
border-color: var(--gold);
box-shadow: 0 20px 54px rgba(0, 0, 0, 0.78), 0 0 42px rgba(245, 196, 81, 0.42);
}
.alert-toast.sub {
background: linear-gradient(135deg, rgba(16, 26, 46, 0.98) 0%, rgba(36, 18, 56, 0.98) 100%);
border-color: #22D3EE;
box-shadow: 0 22px 60px rgba(0, 0, 0, 0.82), 0 0 48px rgba(34, 211, 238, 0.45), 0 0 24px rgba(168, 85, 247, 0.35);
}
.alert-toast.show {
transform: translate(-50%, 0);
opacity: 1;
}
.at-pill {
padding: 8px 14px;
border-radius: 9px;
background: var(--accent-bright);
color: #071005;
font-size: 14px;
font-weight: 900;
letter-spacing: 0.1em;
text-transform: uppercase;
white-space: nowrap;
}
.alert-toast.rant .at-pill { background: var(--gold); }
.alert-toast.sub .at-pill {
background: linear-gradient(135deg, #22D3EE 0%, #C084FC 100%);
color: #06101B;
}
.at-title { font-size: 24px; font-weight: 800; color: var(--ink); }
.at-sub { font-size: 17px; color: var(--ink-soft); margin-top: 2px; }
/* Midnight Sleep Mode theme */
body.sleep-mode .vignette {
background:
radial-gradient(ellipse 75% 65% at 35% 42%, rgba(99, 132, 255, 0.14) 0%, transparent 65%),
linear-gradient(180deg, rgba(5, 8, 16, 0.86) 0%, rgba(6, 10, 20, 0.72) 45%, rgba(5, 8, 16, 0.94) 100%);
}
body.sleep-mode .hero-panel {
border-color: rgba(129, 162, 255, 0.45);
background: linear-gradient(165deg, rgba(14, 20, 36, 0.92) 0%, rgba(8, 11, 20, 0.92) 100%);
}
body.sleep-mode .hero-panel::before {
background: #81A2FF;
box-shadow: 0 0 24px rgba(129, 162, 255, 0.75);
}
body.sleep-mode .status-badge {
background: rgba(129, 162, 255, 0.16);
border-color: rgba(129, 162, 255, 0.50);
color: #A5BEFF;
}
body.sleep-mode .status-badge .dot {
background: #A5BEFF;
box-shadow: 0 0 12px #A5BEFF;
}
body.sleep-mode .chip.live {
border-color: rgba(129, 162, 255, 0.50);
background: rgba(129, 162, 255, 0.14);
color: #C7D7FF;
font-family: "Consolas", "JetBrains Mono", monospace;
font-variant-numeric: tabular-nums;
}
body.sleep-mode .chip.live .dot {
background: #A5BEFF;
box-shadow: 0 0 12px #A5BEFF;
}
body.sleep-mode .spinner {
border-color: rgba(129, 162, 255, 0.28);
border-top-color: #A5BEFF;
animation: spin 3.2s linear infinite;
}
.slide-dots {
display: none;
align-items: center;
gap: 8px;
margin-left: auto;
}
body.sleep-mode .slide-dots { display: flex; }
.slide-dot {
width: 24px;
height: 5px;
border-radius: 999px;
background: rgba(255, 255, 255, 0.14);
transition: background 300ms ease, width 300ms ease;
}
.slide-dot.active {
width: 40px;
background: #A5BEFF;
box-shadow: 0 0 10px rgba(165, 190, 255, 0.6);
}
.sleep-timer-big {
display: none;
align-items: center;
gap: 10px;
padding: 8px 14px;
border-radius: 10px;
background: rgba(129, 162, 255, 0.12);
border: 1px solid rgba(129, 162, 255, 0.35);
font-family: "Consolas", "JetBrains Mono", monospace;
font-size: 16px;
font-weight: 800;
color: #D7E3FF;
font-variant-numeric: tabular-nums;
}
body.sleep-mode .sleep-timer-big { display: inline-flex; }
</style>
</head>
<body>
<div class="alert-toast" id="alert-toast">
<div class="at-pill" id="at-pill">NEW FOLLOWER</div>
<div>
<div class="at-title" id="at-title"></div>
<div class="at-sub" id="at-sub"></div>
</div>
</div>
<div class="backdrop"></div>
<div class="vignette"></div>
<div class="grid-overlay"></div>
<div class="frame">
<div class="top-bar">
<div class="brand-lockup">
<img class="emblem" src="/assets/emblem.png" alt="opengrip" onerror="this.style.display='none'">
<div>
<div class="brand-name">OPENGRIP</div>
<div class="brand-sub">GTA VI PC Porting Lab · Live Engineering</div>
</div>
</div>
<div class="top-right">
<div class="chip">RTX 5080 · RYZEN 7 9800X3D · 32 GB</div>
<div class="chip" id="runs-chip">🧪 206 RUNS</div>
<div class="chip" id="tex-chip">🖼️ 62.5% TEX</div>
<div class="chip live"><span class="dot"></span><span id="top-mode-pill">Auto-Switches Back to Game</span></div>
</div>
</div>
<div class="stage">
<div class="left-col">
<div class="hero-panel">
<div class="eyebrow-row">
<div class="status-badge"><span class="dot"></span><span id="badge">WORKING ON</span></div>
<div class="eyebrow-note" id="eyebrow-note">What We Are Working On Right Now</div>
<div class="slide-dots" id="slide-dots">
<span class="slide-dot active"></span>
<span class="slide-dot"></span>
<span class="slide-dot"></span>
<span class="slide-dot"></span>
</div>
</div>
<div class="hero-copy">
<div class="hero-task" id="task">Building and testing GTA VI PC porting fixes</div>
<div class="hero-detail" id="detail">Improving stability, graphics behavior, and frame rates live on NVIDIA RTX 5080.</div>
</div>
<div class="hero-footer">
<div class="game-wait">
<span class="spinner"></span>
<span id="footer-msg">Game closed while applying fixes. Gameplay returns automatically on launch.</span>
</div>
<div class="sleep-timer-big" id="sleep-timer-big">ASLEEP 00:00:00</div>
<div class="updated-tag" id="updated-tag">LIVE SYNC</div>
</div>
</div>
<div class="milestones-row" id="milestones-row">
<div class="ms-card best">
<div class="ms-head">
<div class="ms-tag"><span>🏆</span><span id="best-tag">BEST RUN · STEP S27F</span></div>
<div class="ms-sub-tag">⚡ VERIFIED RTX 5080</div>
</div>
<div class="ms-grid" id="best-grid"></div>
</div>
<div class="ms-card goal">
<div class="ms-head">
<div class="ms-tag"><span>🎯</span><span id="next-goal-tag">NEXT GOAL</span></div>
<div class="ms-sub-tag">🚀 ACTIVE TARGET</div>
</div>
<div class="goal-body">
<div class="next-goal-title" id="next-goal-title">High RT + Steady 30+ FPS</div>
<div class="next-goal-detail" id="next-goal-detail">Enabling RT directional/local shadows, Ultra RT reflections & High RTGI on RTX 5080 RT cores while keeping cutscene streaming fast.</div>
</div>
</div>
</div>
<div class="perf-chart-card" id="perf-chart-card">
<div class="pc-head">
<div class="pc-left">
<span class="pc-title">📈 AVG FPS PROGRESSION</span>
<span class="pc-sub" id="pc-sub">DAY 1 TO NOW · NO FRAME GEN</span>
</div>
<div class="pc-pills">
<span class="pc-pill" id="pc-range">3.9 → 23.6 FPS</span>
<span class="pc-pill gold" id="pc-gain">+505% · 6.1×</span>
</div>
</div>
<div class="pc-svg-wrap" id="pc-svg-wrap"></div>
</div>
<div class="recent-strip" id="recent-strip"></div>
</div>
<div class="chat-panel">
<div class="chat-head">
<div class="chat-title"><span class="dot"></span><span>💬 Live Chat</span></div>
<div class="chat-viewers" id="chat-viewers">RUMBLE LIVE</div>
</div>
<div class="chat-list" id="chat-list"></div>
</div>
</div>
<div class="goals-bar">
<div class="goal-card highlight">
<div class="goal-head">
<div class="goal-left">
<span class="goal-tag">👥 FOLLOW GOAL</span>
<span class="goal-title">Follow @opengrip</span>
</div>
<div class="goal-numbers" id="f-nums">4 / 25</div>
</div>
<div class="track"><div class="fill" id="f-fill"></div></div>
<div class="goal-sub">
<span id="f-latest">Updates live when you follow</span>
<span id="f-pct">16%</span>
</div>
</div>
<div class="goal-card highlight">
<div class="goal-head">
<div class="goal-left">
<span class="goal-tag">🔥 RANTS GOAL</span>
<span class="goal-title">Stream Support</span>
</div>
<div class="goal-numbers" id="d-nums">$0 / $50</div>
</div>
<div class="track"><div class="fill" id="d-fill"></div></div>
<div class="goal-sub">
<span id="d-latest">Drop a Rumble Rant in chat · updates automatically</span>
<span id="d-pct">0%</span>
</div>
</div>
<div class="boost-card">
<div class="goal-left">
<span class="goal-tag">🚀 BOOST</span>
<span class="goal-title">Tap Rumble (+)</span>
</div>
<div class="goal-sub" id="boost-sub">Pushes the porting stream higher in Gaming</div>
</div>
</div>
</div>
<script>
const USER_COLORS = ['#9EE658', '#67E8F9', '#FCD34D', '#F9A8D4', '#A5B4FC', '#6EE7B7', '#FDBA74'];
function userColor(name) {
let h = 0;
for (let i = 0; i < name.length; i++) h = (h * 31 + name.charCodeAt(i)) >>> 0;
return USER_COLORS[h % USER_COLORS.length];
}
function relTime(ts) {
if (!ts) return 'LIVE';
const diff = Math.max(0, Math.floor(Date.now() / 1000) - ts);
if (diff < 60) return 'just now';
if (diff < 3600) return Math.floor(diff / 60) + 'm ago';
return Math.floor(diff / 3600) + 'h ago';
}
function escapeHtml(s) {
return String(s || '').replace(/[&<>"']/g, c => ({'&':'&','<':'<','>':'>','"':'"',"'":'''}[c]));
}
const RUMBLE_ANIM_EMOTES = {
bitcoin2: '/assets/emotes/bitcoin2.gif',
canada: '/assets/emotes/canada.gif',
catjam: '/assets/emotes/catjam.gif',
ceochris: '/assets/emotes/ceochris.gif',
confusedtravolta: '/assets/emotes/confusedtravolta.gif',
cooldoge: '/assets/emotes/cooldoge.gif',
dancingbanana: '/assets/emotes/dancingbanana.gif',
dumpsterfire: '/assets/emotes/dumpsterfire.gif',
excuseme: '/assets/emotes/excuseme.gif',
flamingelmo: '/assets/emotes/flamingelmo.gif',
goodgame: '/assets/emotes/goodgame.png',
greensiren: '/assets/emotes/greensiren.gif',
imout: '/assets/emotes/imout.gif',
jdlook: '/assets/emotes/jdlook.gif',
leotoast: '/assets/emotes/leotoast.gif',
mindblown: '/assets/emotes/mindblown.gif',
otter: '/assets/emotes/otter.gif',
pugdance: '/assets/emotes/pugdance.gif',
radiatingheart: '/assets/emotes/radiatingheart.gif',
rickroll: '/assets/emotes/rickroll.gif',
rumblecharge: '/assets/emotes/rumblecharge.gif',
rumblefire: '/assets/emotes/rumblefire.png',
rumbleflag: '/assets/emotes/rumbleflag.gif',
rumbleglow: '/assets/emotes/rumbleglow.gif',
rumbleheart: '/assets/emotes/rumbleheart.gif',
rumblehug: '/assets/emotes/rumblehug.png',
rumbleloading: '/assets/emotes/rumbleloading.png',
rumblerocket: '/assets/emotes/rumblerocket.gif',
rumblespinning: '/assets/emotes/rumblespinning.gif',
skeletondancers: '/assets/emotes/skeletondancers.gif',
thinking: '/assets/emotes/thinking.gif',
thisisfine: '/assets/emotes/thisisfine.gif',
trump: '/assets/emotes/trump.gif',
trumpfight: '/assets/emotes/trumpfight.gif',
trumpfloss: '/assets/emotes/trumpfloss.gif',
trumpmugshot: '/assets/emotes/trumpmugshot.png',
trumpnod: '/assets/emotes/trumpnod.gif',
trumpvibe: '/assets/emotes/trumpvibe.gif',
usa: '/assets/emotes/usa.gif',
w: '/assets/emotes/w.gif',
};
const COLON_EMOJI_FALLBACK = {
bow: '🙇',
siren: '🚨',
fire: '🔥',
lit: '🔥',
heart: '❤️',
clap: '👏',
pog: '😮',
lul: '😂',
lol: '😂',
kekw: '😂',
chad: '🗿',
salute: '🫡',
goat: '🐐',
rocket: '🚀',
money: '💵',
rant: '🔥',
thumbsup: '👍',
crown: '👑',
coffee: '☕',
sleep: '😴',
skull: '💀',
eyes: '👀',
100: '💯',
cry: '😭',
};
function isEmoteOnlyMsg(s) {
const stripped = String(s || '').replace(/:r\+[a-zA-Z0-9_-]+:/g, '').trim();
return stripped.length === 0 && /:r\+[a-zA-Z0-9_-]+:/.test(String(s || ''));
}
function renderChatText(s) {
const esc = escapeHtml(s);
let out = esc.replace(/:r\+([a-zA-Z0-9_-]+):/g, (_, name) => {
const key = name.toLowerCase();
if (RUMBLE_ANIM_EMOTES[key]) {
const fb = CDN_FALLBACK[key] ? (' onerror="this.onerror=null;this.src=\'' + CDN_FALLBACK[key] + '\'"') : ''; return '<img class="cm-emote-img" src="' + RUMBLE_ANIM_EMOTES[key] + '"' + fb + ' alt="' + escapeHtml(name) + '">';
}
if (COLON_EMOJI_FALLBACK[key]) return COLON_EMOJI_FALLBACK[key];
return '<span class="cm-emote-pill">' + escapeHtml(name.toUpperCase()) + '</span>';
});
out = out.replace(/:([a-zA-Z0-9_]+):/g, (full, name) => {
const key = name.toLowerCase();
if (RUMBLE_ANIM_EMOTES[key]) {
const fb = CDN_FALLBACK[key] ? (' onerror="this.onerror=null;this.src=\'' + CDN_FALLBACK[key] + '\'"') : ''; return '<img class="cm-emote-img" src="' + RUMBLE_ANIM_EMOTES[key] + '"' + fb + ' alt="' + escapeHtml(name) + '">';
}
if (COLON_EMOJI_FALLBACK[key]) return COLON_EMOJI_FALLBACK[key];
return full;
});
return out;
}
const STAT_ICONS = ['⚡', '💾', '⏱️', '🖼️'];
function fmtMoney(v) {
const n = Number(v || 0);
return '$' + (Number.isInteger(n) ? n : n.toFixed(2));
}
function fmtHMS(secs) {
const s = Math.max(0, Math.floor(secs || 0));
const h = String(Math.floor(s / 3600)).padStart(2, '0');
const m = String(Math.floor((s % 3600) / 60)).padStart(2, '0');
const sec = String(s % 60).padStart(2, '0');
return h + ':' + m + ':' + sec;
}
const SLEEP_SLIDES = [
{
badge: 'SLEEPING',
eyebrow: 'Recharging During the 40+ Hour Porting Marathon',
task: 'Catching some sleep. Live porting resumes when I wake up.',
detail: 'Hanging out on chilled ambient radio while I recharge. Background test builds stay off-screen until I am back live on mic. Follow @opengrip so you catch the next live session.',
},
{
badge: 'PORTING RECAP',
eyebrow: 'What We Built Live on Stream',
task: '26/26 Hardware DXR 1.1 RT Shaders + Wave 5B Mesh Shaders',
detail: 'Lifted all 26 RT passes onto RTX 5080 hardware RT cores (0% SW BVH), hit 23.0 FPS avg on High RT at 10.7 GB VRAM with 0 refused shaders, and validated 300 native mesh shaders for Wave 5B.',
},
{
badge: 'UP NEXT',
eyebrow: 'Active Engineering Targets',
task: 'Wave 5B Launch & Wave 6 · Steady 30+ FPS Native PC',
detail: 'Launching Wave 5B on a warm shader cache, then stripping unified-memory CPU copy-back overhead, adding R16_TYPELESS compressed index decoding, and pushing instant textures past 80%.',
},
{
badge: 'LIVE DOCS',
eyebrow: 'Full Architecture Guides & Live Shader Tracker',
task: 'rentry.co/opengrip-gtavi · rentry.co/opengrip-nvidia-rt',
detail: 'Auto-updating live roadmap with all 26 HW RT shaders plus our standalone NVIDIA RTX hardware RT cores technical deep-dive.',
},
];
const CDN_FALLBACK = {"catjam": "https://hugh.cdn.rumble.cloud/video/z12/0/t/2/N/0t2Na.baa.gif", "w": "https://hugh.cdn.rumble.cloud/video/z12/c/O/V/0/cOV0b.baa.gif", "dancingbanana": "https://hugh.cdn.rumble.cloud/video/z12/b/A/o/9/bAo9H.baa.gif", "leotoast": "https://hugh.cdn.rumble.cloud/video/z12/F/2/1/N/F21Na.baa.gif", "mindblown": "https://hugh.cdn.rumble.cloud/video/z12/r/4/1/N/r41Na.baa.1.gif", "rumbleglow": "https://hugh.cdn.rumble.cloud/video/z12/J/J/V/S/JJVSq.baa.gif"};
let lastSleepMode = false;
let lastSleepStartedAt = 0;
let lastChatSig = '__init__';
function renderSleepClockAndSlide() {
if (!lastSleepMode) return;
const elapsed = lastSleepStartedAt ? Math.max(0, Math.floor(Date.now() / 1000) - lastSleepStartedAt) : 0;
const hms = fmtHMS(elapsed);
document.getElementById('top-mode-pill').textContent = 'SLEEPING · ' + hms;
document.getElementById('sleep-timer-big').textContent = 'ASLEEP ' + hms;
const idx = Math.floor(Date.now() / 18000) % SLEEP_SLIDES.length;
const sl = SLEEP_SLIDES[idx];
document.getElementById('badge').textContent = sl.badge;
document.getElementById('eyebrow-note').textContent = sl.eyebrow;
document.getElementById('task').textContent = sl.task;
document.getElementById('detail').textContent = sl.detail;
document.getElementById('footer-msg').textContent = 'Chilled ambient radio live · Chat & goals stay active · Back on mic soon';
document.getElementById('updated-tag').style.display = 'none';
const dots = document.querySelectorAll('#slide-dots .slide-dot');
dots.forEach((el, i) => el.classList.toggle('active', i === idx));
}
// ---- Standalone Mock Data (used ONLY when opened offline without /api/state) ----
const MOCK_STATE = {
sleep_mode: false,
sleep_started_at: 0,
badge: 'TESTING BUILD',
task: 'Wave 16: 4 KiB Sub-Page Dirty Tracking',
detail: 'Upgrading CARD_COMPARE & readback on the 174 MB shared heap to cut remaining CPU prep overhead.',
auto_updated_at: Math.floor(Date.now() / 1000) - 45,
total_runs: 230,
tex_ready_pct: 62.5,
tex_mean_ms: 68,
followers: 533,
follower_goal: 750,
latest_follower: 'CommunityDesigner',
donations_dollars: 118,
donation_goal: 150,
latest_rant: { username: 'Supporter', amount_dollars: 10, text: 'Keep pushing!' },
watching_now: 590,
stream_live: true,
best_run: {
tag: 'BEST RUN · WAVE 4D · HIGH RT',
stats: [
{ val: '23.6 FPS', sub: 'Avg · 36+ Peak · No FG' },
{ val: '11.0 GB', sub: 'VRAM · 12.9G Peak' },
{ val: '31.3 ms', sub: 'Prep 24.6 · Copy 6.7' },
{ val: '60.6% TEX', sub: 'Instant Ready · 68 ms avg' },
],
},
next_goal: {
tag: 'NEXT GOAL',
title: 'Wave 16 · Final Unified-Memory Piece (Part 5)',
detail: '4 KiB sub-page dirty tracking on the 174 MB shared heap + cutting remaining 17 ms steps_refresh.',
},
fps_runs_analyzed: 134,
fps_history: [
{ label: 'DAY 1', fps: 3.9 }, { label: 'SW BVH', fps: 4.7 },
{ label: 'HW RT', fps: 8.0 }, { label: 'RT FIX', fps: 9.4 },
{ label: 'SPEED RT', fps: 11.5 }, { label: 'SLAB 12', fps: 15.3 },
{ label: 'STEP B', fps: 16.7 }, { label: 'STEP R2', fps: 17.3 },
{ label: 'S27A', fps: 21.0 }, { label: 'S27F', fps: 21.8 },
{ label: 'W4B', fps: 22.3 }, { label: 'W4C', fps: 23.2 },
{ label: 'W4D', fps: 23.6 },
],
history: [
{ badge: 'TESTING BUILD', task: 'Wave 16: 4 KiB Sub-Page Dirty Tracking', detail: 'Testing 4 KiB sub-page tracking on RTX 5080.', ts: Math.floor(Date.now()/1000) - 45 },
{ badge: 'DONE', task: 'Wave 15 Read Trap v2 Whole-Page Guard', detail: 'Gated strictly to >=64 KiB aligned buffers, 0 errors.', ts: Math.floor(Date.now()/1000) - 600 },
{ badge: 'DONE', task: 'Wave 14 2.2 GB Direct ReBAR Arena', detail: 'Mapped committed WC pool straight into GDDR7 VRAM.', ts: Math.floor(Date.now()/1000) - 1800 },
],
chat_messages: [
{ username: 'ViewerOne', text: 'This overlay is clean! Trying a custom theme now', badges: [], created_on: '1', rant_dollars: 0 },
{ username: 'RTXFan', text: ':r+w:', badges: [], created_on: '2', rant_dollars: 0 },
{ username: 'DevChatter', text: '3.9 FPS to 23.6 FPS in 48 hours is wild :r+catjam:', badges: [], created_on: '3', rant_dollars: 0 },
{ username: 'Supporter', text: 'Keep pushing for 30+ FPS!', badges: [], created_on: '4', rant_dollars: 10 },
],
alert_event: null,
};
let mockAlert = null;
let mockSleep = false;
window.addEventListener('keydown', (e) => {
const now = Math.floor(Date.now() / 1000);
if (e.key === '1') mockAlert = { id: 'm-' + now, type: 'follow', username: 'NewFollower', amount_dollars: 0, text: 'Welcome to the porting lab!', ts: now };
if (e.key === '2') mockAlert = { id: 'm-' + now, type: 'rant', username: 'BigSupporter', amount_dollars: 20, text: 'Let us hit 30+ FPS!', ts: now };
if (e.key === '3') mockAlert = { id: 'm-' + now, type: 'subscriber', username: 'SubHero', amount_dollars: 5, text: 'Welcome to the @opengrip Sub Club! ($5/mo)', ts: now };
if (e.key === '4') mockSleep = !mockSleep;
if (['1','2','3','4'].includes(e.key)) poll();
});
async function poll() {
try {
let d;
try {
const r = await fetch('/api/state', { cache: 'no-store' });
if (!r.ok) throw new Error('offline');
d = await r.json();
} catch (_) {
d = Object.assign({}, MOCK_STATE, { sleep_mode: mockSleep, sleep_started_at: mockSleep ? (Math.floor(Date.now()/1000) - 3725) : 0, alert_event: mockAlert });
}
const isSleep = Boolean(d.sleep_mode);
lastSleepMode = isSleep;
lastSleepStartedAt = Number(d.sleep_started_at || 0);
document.body.classList.toggle('sleep-mode', isSleep);
const strip = document.getElementById('recent-strip');
if (isSleep) {
renderSleepClockAndSlide();
strip.style.display = 'grid';
strip.innerHTML = `
<div class="recent-card">
<div class="rc-top">
<span class="rc-badge">PORTING LAB</span>
<span class="rc-time">40H+ MARATHON</span>
</div>
<div class="rc-task">26/26 DXR 1.1 HW RT Shaders + Wave 5B Mesh</div>
<div class="rc-detail">High RT · 23.0 FPS Avg · 10.7 GB VRAM · 0% Software BVH</div>
</div>
<div class="recent-card">
<div class="rc-top">
<span class="rc-badge">LIVE DOCS</span>
<span class="rc-time">AUTO-UPDATING</span>
</div>
<div class="rc-task">rentry.co/opengrip-gtavi</div>
<div class="rc-detail">All 26 HW RT shaders + NVIDIA RT guide: rentry.co/opengrip-nvidia-rt</div>
</div>
`;
} else {
document.getElementById('top-mode-pill').textContent = 'Auto-Switches Back to Game';
document.getElementById('eyebrow-note').textContent = 'What We Are Working On Right Now';
document.getElementById('footer-msg').textContent = 'Game closed while applying fixes. Gameplay returns automatically on launch.';
document.getElementById('updated-tag').style.display = '';
document.getElementById('badge').textContent = d.badge || 'WORKING ON';
document.getElementById('task').textContent = d.task || 'Working on GTA VI PC porting updates';
document.getElementById('detail').textContent = d.detail || '';
document.getElementById('updated-tag').textContent = d.auto_updated_at ? ('UPDATED ' + relTime(d.auto_updated_at).toUpperCase()) : 'LIVE SYNC';
// Recent progress strip (previous 2 milestones)
const hist = Array.isArray(d.history) ? d.history.slice(1, 3) : [];
if (hist.length > 0) {
strip.style.display = 'grid';
strip.innerHTML = hist.map(item => `
<div class="recent-card">
<div class="rc-top">
<span class="rc-badge">${escapeHtml(item.badge || 'DONE')}</span>
<span class="rc-time">${escapeHtml(relTime(item.ts))}</span>
</div>
<div class="rc-task">${escapeHtml(item.task)}</div>
<div class="rc-detail">${escapeHtml(item.detail)}</div>
</div>
`).join('');
} else {
strip.style.display = 'none';
}
}
// Total logged test runs & live texture-loaded % chips
const totalRuns = Number(d.total_runs || 0);
if (totalRuns > 0) {
document.getElementById('runs-chip').textContent = '🧪 ' + totalRuns + ' RUNS';
}
const texPct = Number(d.tex_ready_pct || 0);
if (texPct > 0) {
document.getElementById('tex-chip').textContent = '🖼️ ' + texPct.toFixed(1) + '% TEX';
}
// Best Run Milestones + Next Goal cards
const br = d.best_run || {};
document.getElementById('best-tag').textContent = br.tag || 'BEST RUN · STEP S27F';
const brStats = Array.isArray(br.stats) ? br.stats.slice(0, 4) : [];
document.getElementById('best-grid').innerHTML = brStats.map((s, idx) => `
<div class="ms-stat">
<div class="ms-stat-val">${STAT_ICONS[idx] || '▸'} ${escapeHtml(s.val)}</div>
<div class="ms-stat-sub">${escapeHtml(s.sub)}</div>
</div>
`).join('');
const ng = d.next_goal || {};
document.getElementById('next-goal-tag').textContent = ng.tag || 'NEXT GOAL';
document.getElementById('next-goal-title').textContent = ng.title || 'High RT + Steady 30+ FPS';
document.getElementById('next-goal-detail').textContent = ng.detail || '';
// Live Auto-Updating Average FPS Progression SVG Chart
renderFpsChart(d.fps_history, d.fps_runs_analyzed);
// Live Rumble Chat panel
const viewers = Number(d.watching_now || 0);
document.getElementById('chat-viewers').textContent = viewers > 0 ? (viewers + ' LIVE') : (d.stream_live ? 'LIVE NOW' : 'READY');
const msgs = Array.isArray(d.chat_messages) ? d.chat_messages.slice(-8) : [];
const chatEl = document.getElementById('chat-list');
const chatSig = msgs.map(m => (m.created_on || '') + '|' + (m.username || '') + '|' + (m.text || '') + '|' + (m.rant_dollars || 0)).join('\n');
if (chatSig !== lastChatSig) {
lastChatSig = chatSig;
if (msgs.length === 0) {
chatEl.innerHTML = `
<div class="chat-empty">
<div class="chat-empty-title">Live Rumble Chat Connected</div>
<div class="chat-empty-sub">Messages and Rumble Rants sent in live chat appear right here on screen while we apply porting fixes.</div>
</div>
`;
} else {
chatEl.innerHTML = msgs.map(m => {
const isRant = Number(m.rant_dollars || 0) > 0;
const color = userColor(m.username || 'viewer');
const badgesHtml = (m.badges || []).map(b => `<span class="cm-badge">${escapeHtml(b)}</span>`).join('');
const rantHtml = isRant ? `<span class="cm-rant-amt">${escapeHtml(fmtMoney(m.rant_dollars))} RANT</span>` : '';
const eoClass = isEmoteOnlyMsg(m.text) ? ' emote-only' : '';
return `
<div class="chat-msg ${isRant ? 'rant' : ''}">
<div class="cm-head">
<span class="cm-user" style="color:${color}">${escapeHtml(m.username)}</span>
${rantHtml}${badgesHtml}
</div>
<div class="cm-text${eoClass}">${renderChatText(m.text)}</div>
</div>
`;
}).join('');
}
}
// Live Follower Goal
const fCur = Number(d.followers || 0);
const fGoal = Math.max(1, Number(d.follower_goal || 25));
const fPct = Math.min(100, Math.round((fCur / fGoal) * 100));
document.getElementById('f-nums').textContent = fCur + ' / ' + fGoal;
document.getElementById('f-fill').style.width = fPct + '%';
document.getElementById('f-pct').textContent = fPct + '%';
document.getElementById('f-latest').innerHTML = d.latest_follower
? ('Latest follower: <strong>' + escapeHtml(d.latest_follower) + '</strong>')
: 'Updates live when you hit Follow';
// Live Rants Goal
const dCur = Number(d.donations_dollars || 0);
const dGoal = Math.max(1, Number(d.donation_goal || 50));
const dPct = Math.min(100, Math.round((dCur / dGoal) * 100));
document.getElementById('d-nums').textContent = fmtMoney(dCur) + ' / ' + fmtMoney(dGoal);
document.getElementById('d-fill').style.width = dPct + '%';
document.getElementById('d-pct').textContent = dPct + '%';
if (d.latest_rant && d.latest_rant.username) {
document.getElementById('d-latest').innerHTML = 'Latest Rant: <strong>' + escapeHtml(d.latest_rant.username) + ' (' + fmtMoney(d.latest_rant.amount_dollars) + ')</strong>';
} else {
document.getElementById('d-latest').textContent = 'Drop a Rumble Rant in chat · updates automatically';
}
if (viewers > 0) {
document.getElementById('boost-sub').innerHTML = '<strong>' + viewers + ' watching live</strong> · Tap (+) to boost';
}
// Live Follow / Rant / Subscriber toast
const ev = d.alert_event;
const toast = document.getElementById('alert-toast');
const maxAge = (ev && ev.type === 'subscriber') ? 8.0 : 6.5;
if (ev && ev.id && (Date.now() / 1000 - Number(ev.ts || 0) <= maxAge)) {
const isRant = ev.type === 'rant';
const isSub = ev.type === 'subscriber';
toast.className = 'alert-toast show' + (isSub ? ' sub' : (isRant ? ' rant' : ''));
document.getElementById('at-pill').textContent = isSub
? ('★ NEW SUBSCRIBER')
: (isRant ? (fmtMoney(ev.amount_dollars) + ' RUMBLE RANT') : 'NEW FOLLOWER');
document.getElementById('at-title').textContent = ev.username || 'Viewer';
document.getElementById('at-sub').textContent = ev.text || (isSub ? 'Welcome to the @opengrip Sub Club!' : (isRant ? 'Thank you for supporting the stream!' : 'Welcome to the porting lab!'));
} else {
toast.classList.remove('show');
}
} catch (e) {}
}
let lastChartSig = '';
function renderFpsChart(pts, analyzedCount) {
const wrap = document.getElementById('pc-svg-wrap');
if (!wrap || !Array.isArray(pts) || pts.length < 2) return;
const sig = pts.map(p => p.label + ':' + p.fps).join('|') + '|' + (analyzedCount || 0);
if (sig === lastChartSig) return;
lastChartSig = sig;
const first = Number(pts[0].fps || 3.9);
const last = Number(pts[pts.length - 1].fps || first);
const gainPct = first > 0 ? Math.round(((last - first) / first) * 100) : 0;
const mult = first > 0 ? (last / first).toFixed(1) : '1.0';
document.getElementById('pc-range').textContent = first.toFixed(1) + ' → ' + last.toFixed(1) + ' FPS';
document.getElementById('pc-gain').textContent = '+' + gainPct + '% · ' + mult + '×';
document.getElementById('pc-sub').textContent = analyzedCount
? ('DAY 1 TO NOW · ' + analyzedCount + ' VERIFIED LOGS · NO FG')
: 'DAY 1 TO NOW · NO FRAME GEN';
const W = 980, H = 112;
const padL = 36, padR = 22, padT = 18, padB = 22;
const plotW = W - padL - padR;
const plotH = H - padT - padB;
const maxFps = Math.max(30, Math.ceil((last + 4) / 10) * 10);
const xAt = (i) => padL + (pts.length === 1 ? plotW / 2 : (i / (pts.length - 1)) * plotW);
const yAt = (v) => padT + plotH - Math.max(0, Math.min(1, v / maxFps)) * plotH;
// Horizontal gridlines
const step = maxFps <= 30 ? 10 : (maxFps <= 40 ? 10 : 15);
let gridHtml = '';
for (let v = 0; v <= maxFps; v += step) {
const y = yAt(v).toFixed(1);
gridHtml += `<line x1="${padL}" y1="${y}" x2="${W - padR}" y2="${y}" stroke="rgba(255,255,255,0.07)" stroke-width="1"/>`;
gridHtml += `<text x="${padL - 8}" y="${(Number(y) + 3.5).toFixed(1)}" text-anchor="end" fill="#7D8FA3" font-family="Consolas,monospace" font-size="11" font-weight="700">${v}</text>`;
}
// 30 FPS target line (label on left so it never crowds the rightmost peak value)
const y30 = yAt(30).toFixed(1);
const goalLine = `
<line x1="${padL}" y1="${y30}" x2="${W - padR}" y2="${y30}" stroke="rgba(245,196,81,0.52)" stroke-width="1.2" stroke-dasharray="5 5"/>
<text x="${padL + 6}" y="${(Number(y30) - 4).toFixed(1)}" text-anchor="start" fill="#F5C451" font-family="Consolas,monospace" font-size="10.5" font-weight="800" letter-spacing="0.06em">30 FPS GOAL</text>
`;
// Smooth monotonic-ish Catmull-Rom path
const coords = pts.map((p, i) => ({ x: xAt(i), y: yAt(Number(p.fps || 0)), fps: Number(p.fps || 0), label: String(p.label || '') }));
let lineD = `M ${coords[0].x.toFixed(1)} ${coords[0].y.toFixed(1)}`;
for (let i = 0; i < coords.length - 1; i++) {
const p0 = coords[Math.max(0, i - 1)];
const p1 = coords[i];
const p2 = coords[i + 1];
const p3 = coords[Math.min(coords.length - 1, i + 2)];
const c1x = p1.x + (p2.x - p0.x) / 6;
const c1y = Math.min(padT + plotH, Math.max(padT, p1.y + (p2.y - p0.y) / 6));
const c2x = p2.x - (p3.x - p1.x) / 6;
const c2y = Math.min(padT + plotH, Math.max(padT, p2.y - (p3.y - p1.y) / 6));
lineD += ` C ${c1x.toFixed(1)} ${c1y.toFixed(1)}, ${c2x.toFixed(1)} ${c2y.toFixed(1)}, ${p2.x.toFixed(1)} ${p2.y.toFixed(1)}`;
}
const baseLine = (padT + plotH).toFixed(1);
const areaD = `${lineD} L ${coords[coords.length - 1].x.toFixed(1)} ${baseLine} L ${coords[0].x.toFixed(1)} ${baseLine} Z`;
// Decide which labels to draw cleanly without overlap
let lastLblX = -999;
let dotsHtml = '';
coords.forEach((c, i) => {
const isFirst = i === 0;
const isLast = i === coords.length - 1;
const showLbl = isFirst || isLast || (c.x - lastLblX >= 84 && (coords[coords.length - 1].x - c.x >= 68));
if (showLbl) {
lastLblX = c.x;
const valY = Math.max(12, c.y - 9).toFixed(1);
const valColor = isLast ? '#9EE658' : '#E3ECF5';
const valSize = isLast ? '12.5' : '11';
dotsHtml += `<text x="${c.x.toFixed(1)}" y="${valY}" text-anchor="${isFirst ? 'start' : (isLast ? 'end' : 'middle')}" fill="${valColor}" font-family="Consolas,monospace" font-size="${valSize}" font-weight="800">${c.fps.toFixed(1)}</text>`;
dotsHtml += `<text x="${c.x.toFixed(1)}" y="${H - 4}" text-anchor="${isFirst ? 'start' : (isLast ? 'end' : 'middle')}" fill="${isLast ? '#9EE658' : '#8B9BAE'}" font-family="Consolas,monospace" font-size="10.5" font-weight="700">${escapeHtml(c.label)}</text>`;
}
if (isLast) {
dotsHtml += `<circle cx="${c.x.toFixed(1)}" cy="${c.y.toFixed(1)}" r="9" fill="rgba(158,230,88,0.22)"/>`;
dotsHtml += `<circle cx="${c.x.toFixed(1)}" cy="${c.y.toFixed(1)}" r="4.8" fill="#9EE658" stroke="#071005" stroke-width="2"/>`;
} else {
dotsHtml += `<circle cx="${c.x.toFixed(1)}" cy="${c.y.toFixed(1)}" r="3.4" fill="#9EE658" stroke="#0B1117" stroke-width="1.6"/>`;
}
});
wrap.innerHTML = `
<svg viewBox="0 0 ${W} ${H}" preserveAspectRatio="none">
<defs>
<linearGradient id="fpsAreaGrad" x1="0" y1="0" x2="0" y2="1">
<stop offset="0%" stop-color="#9EE658" stop-opacity="0.34"/>
<stop offset="100%" stop-color="#9EE658" stop-opacity="0.01"/>
</linearGradient>
<filter id="fpsGlow" x="-5%" y="-20%" width="110%" height="140%">
<feGaussianBlur stdDeviation="2.5" result="blur"/>
<feMerge><feMergeNode in="blur"/><feMergeNode in="SourceGraphic"/></feMerge>
</filter>
</defs>
${gridHtml}
${goalLine}
<path d="${areaD}" fill="url(#fpsAreaGrad)"/>
<path d="${lineD}" fill="none" stroke="#9EE658" stroke-width="2.8" stroke-linecap="round" stroke-linejoin="round" filter="url(#fpsGlow)"/>
${dotsHtml}
</svg>
`;
}
poll();
setInterval(poll, 1500);
setInterval(renderSleepClockAndSlide, 1000);
</script>
</body>
</html>
|