diff --git a/system/public/kidlisp.com/index.html b/system/public/kidlisp.com/index.html
index f62dad28b3..10261efcb4 100644
--- a/system/public/kidlisp.com/index.html
+++ b/system/public/kidlisp.com/index.html
@@ -4132,16 +4132,6 @@
color: #5c3d1e;
}
- /* Sub-tab colors - Keeps (Gray) */
- .list-subtab[data-subtab="keeps"] {
- background: rgba(250, 204, 21, 0.65);
- color: #78716c;
- }
- .list-subtab[data-subtab="keeps"].active {
- background: linear-gradient(to bottom, #a3a3a3 0%, #d4d4d4 100%);
- color: #262626;
- }
-
/* Dark mode sub-tabs */
[data-theme="dark"] .list-subtab[data-subtab="examples"] {
background: rgba(253, 224, 71, 0.8);
@@ -4167,14 +4157,6 @@
background: linear-gradient(to bottom, #a3724a 0%, #6b4423 100%);
color: #e8d4bc;
}
- [data-theme="dark"] .list-subtab[data-subtab="keeps"] {
- background: rgba(253, 224, 71, 0.8);
- color: #57534e;
- }
- [data-theme="dark"] .list-subtab[data-subtab="keeps"].active {
- background: linear-gradient(to bottom, #737373 0%, #525252 100%);
- color: #f5f5f5;
- }
/* Slideshow icon button in subtabs bar */
.slideshow-icon-btn {
@@ -4944,11 +4926,6 @@
background: linear-gradient(to bottom, rgba(180, 130, 90, 0.35) 0%, rgba(180, 130, 90, 0.1) 40%, rgba(250, 204, 21, 0.05) 100%);
}
- #keeps-subcontent:not(.hidden) {
- display: flex;
- overflow: hidden;
- }
-
.language-tab {
border-left: 1px solid var(--border-color);
border-right: 1px solid var(--border-color);
@@ -9293,6 +9270,7 @@
@@ -17053,6 +17030,11 @@ s("ape_breaks_3").loopAt(2)
// Listen for cursor position changes to update Learn tab documentation
editor.onDidChangeCursorPosition((e) => {
+ // Skip while content is being set programmatically (initial restore /
+ // code-load / decrypt animation). Monaco is still chunking in then, and
+ // these fire spuriously, evaluating references against transient content
+ // and pushing them at the Learn tab.
+ if (isSettingValueProgrammatically) return;
const model = editor.getModel();
if (!model) return;
@@ -20080,12 +20062,14 @@ s("ape_breaks_3").loopAt(2)
const listContent = document.getElementById('list-content');
const jukeboxContent = document.getElementById('jukebox-content');
const jockeyContent = document.getElementById('jockey-content');
+ const keepContent = document.getElementById('keep-content');
const mobileConsoleContent = document.getElementById('mobile-console-content');
const codeTab = document.getElementById('reference-tab');
const guideTab = document.getElementById('guide-tab');
const listTab = document.getElementById('list-tab');
const jukeboxTab = document.getElementById('jukebox-tab');
const jockeyTab = document.getElementById('jockey-tab');
+ const keepTab = document.getElementById('keep-tab');
const consoleTab = document.getElementById('console-tab');
let examplesLoaded = false;
let recentLoaded = false;
@@ -20099,6 +20083,7 @@ s("ape_breaks_3").loopAt(2)
listContent?.classList.add('hidden');
jukeboxContent?.classList.add('hidden');
jockeyContent?.classList.add('hidden');
+ keepContent?.classList.add('hidden');
mobileConsoleContent?.classList.add('hidden');
}
@@ -20109,6 +20094,7 @@ s("ape_breaks_3").loopAt(2)
listTab?.classList.remove('active');
jukeboxTab?.classList.remove('active');
jockeyTab?.classList.remove('active');
+ keepTab?.classList.remove('active');
consoleTab?.classList.remove('active');
}
@@ -20134,18 +20120,6 @@ s("ape_breaks_3").loopAt(2)
if (!recentLoaded) loadRecent();
} else if (subtab === 'history') {
loadHistory();
- } else if (subtab === 'keeps') {
- // Lazy-load keeps iframe on first click (avoid loading 14k+ items on page init)
- const keepsIframe = document.getElementById('keeps-iframe');
- if (keepsIframe && !keepsIframe.hasAttribute('src')) {
- console.log('📦 [KEEPS] Lazy-loading keeps iframe');
- // Post the current piece once the embedded keeps page loads.
- keepsIframe.addEventListener('load', postCurrentPieceToKeeps, { once: true });
- keepsIframe.src = keepsIframe.dataset.src;
- } else {
- // Already loaded — re-target it at whatever piece is open now.
- postCurrentPieceToKeeps();
- }
}
const listIdBySubtab = {
@@ -20285,6 +20259,28 @@ s("ape_breaks_3").loopAt(2)
updateJockeyPanel();
});
+ // Keep tab - embedded focused-keep panel for the current editor piece
+ keepTab?.addEventListener('click', function(e) {
+ e.stopPropagation();
+ e.preventDefault();
+ log.tabs.debug('Keep tab');
+ deactivateAllTabs();
+ hideAllTabContents();
+ keepTab.classList.add('active');
+ keepContent.classList.remove('hidden');
+ expandReferencePanelOnMobile();
+ // Lazy-load keeps iframe on first open; otherwise re-target at the
+ // piece that's open now.
+ const keepsIframe = document.getElementById('keeps-iframe');
+ if (keepsIframe && !keepsIframe.hasAttribute('src')) {
+ console.log('📦 [KEEPS] Lazy-loading keeps iframe');
+ keepsIframe.addEventListener('load', postCurrentPieceToKeeps, { once: true });
+ keepsIframe.src = keepsIframe.dataset.src;
+ } else {
+ postCurrentPieceToKeeps();
+ }
+ });
+
// List sub-tab click handlers
document.querySelectorAll('.list-subtab').forEach(subtab => {
subtab.addEventListener('click', function(e) {