@innovatorved/code-lab 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/code-lab.css +209 -1
- package/dist/code-lab.esm.js +253 -16
- package/dist/code-lab.js +253 -16
- package/dist/shell.esm.js +52 -1
- package/dist/shell.js +52 -1
- package/package.json +2 -2
- package/src/code-lab.css +209 -1
- package/src/shell.js +52 -1
- package/src/shell.ts +28 -1
- package/src/workbench.js +201 -15
- package/src/workbench.ts +201 -15
package/src/workbench.js
CHANGED
|
@@ -1170,6 +1170,8 @@ declare module 'bun:sqlite' {
|
|
|
1170
1170
|
this.completedSteps = new Set(this.savedState.completedSteps || []);
|
|
1171
1171
|
this.folders = new Set(this.savedState?.folders || []);
|
|
1172
1172
|
this.collapsedFolders = new Set(this.savedState?.collapsedFolders || []);
|
|
1173
|
+
this.explorerFolder = this.savedState?.explorerFolder || ''; // '' = workspace root, else folder path scope
|
|
1174
|
+
this.folderSwitcherOpen = false;
|
|
1173
1175
|
this.creatingItem = null; // { type: 'file' | 'folder', parentFolder: string } | null
|
|
1174
1176
|
this.renamingItem = null;
|
|
1175
1177
|
this._draggedFile = null;
|
|
@@ -1505,7 +1507,8 @@ declare module 'bun:sqlite' {
|
|
|
1505
1507
|
openTabs: Array.isArray(this.openTabs) ? [...this.openTabs] : undefined,
|
|
1506
1508
|
activeFile: this.activeFile,
|
|
1507
1509
|
folders: Array.from(this.folders || []),
|
|
1508
|
-
collapsedFolders: Array.from(this.collapsedFolders || [])
|
|
1510
|
+
collapsedFolders: Array.from(this.collapsedFolders || []),
|
|
1511
|
+
explorerFolder: this.explorerFolder || ''
|
|
1509
1512
|
};
|
|
1510
1513
|
this.savedState = state;
|
|
1511
1514
|
if (this.options && this.options.persistState === false) {
|
|
@@ -1949,23 +1952,59 @@ declare module 'bun:sqlite' {
|
|
|
1949
1952
|
</button>
|
|
1950
1953
|
` : '';
|
|
1951
1954
|
|
|
1952
|
-
|
|
1955
|
+
const folderOptions = this._listWorkspaceFolders();
|
|
1956
|
+
const scope = this.explorerFolder || '';
|
|
1957
|
+
const scopeLabel = scope ? scope.split('/').pop() : 'workspace';
|
|
1958
|
+
|
|
1959
|
+
const switcherHtml = `
|
|
1960
|
+
<div class="codelab-folder-switcher ${this.folderSwitcherOpen ? 'is-open' : ''}">
|
|
1961
|
+
<button type="button" class="codelab-folder-switcher__toggle ${scope ? 'is-scoped' : ''}" data-cl-action="toggle-folder-switcher" aria-haspopup="true" aria-expanded="${this.folderSwitcherOpen ? 'true' : 'false'}" title="Switch workspace folder">
|
|
1962
|
+
${CL_ICONS.folder}
|
|
1963
|
+
<span class="codelab-folder-switcher__label">${escapeHtml(scopeLabel)}</span>
|
|
1964
|
+
${CL_ICONS.chevronDown}
|
|
1965
|
+
</button>
|
|
1966
|
+
${this.folderSwitcherOpen ? `
|
|
1967
|
+
<div class="codelab-folder-switcher__menu" role="menu" aria-label="Workspace folders">
|
|
1968
|
+
<div class="codelab-folder-switcher__section">Switch Folder</div>
|
|
1969
|
+
<button type="button" role="menuitem" class="codelab-folder-switcher__option ${!scope ? 'active' : ''}" data-cl-folder-option="">
|
|
1970
|
+
<span class="codelab-folder-switcher__icon">${CL_ICONS.folder}</span>
|
|
1971
|
+
<span class="codelab-folder-switcher__name">workspace</span>
|
|
1972
|
+
<span class="codelab-folder-switcher__path">/</span>
|
|
1973
|
+
</button>
|
|
1974
|
+
${folderOptions.map(f => {
|
|
1975
|
+
const fDepth = f.split('/').length;
|
|
1976
|
+
const fName = f.split('/').pop();
|
|
1977
|
+
return `
|
|
1978
|
+
<button type="button" role="menuitem" class="codelab-folder-switcher__option ${scope === f ? 'active' : ''}" data-cl-folder-option="${escapeHtml(f)}" style="padding-left:${10 + (fDepth - 1) * 12}px;">
|
|
1979
|
+
<span class="codelab-folder-switcher__icon">${CL_ICONS.folder}</span>
|
|
1980
|
+
<span class="codelab-folder-switcher__name">${escapeHtml(fName)}</span>
|
|
1981
|
+
<span class="codelab-folder-switcher__path">${escapeHtml(f)}</span>
|
|
1982
|
+
</button>
|
|
1983
|
+
`;
|
|
1984
|
+
}).join('')}
|
|
1985
|
+
${folderOptions.length ? '' : '<div class="codelab-folder-switcher__empty">No subfolders yet</div>'}
|
|
1986
|
+
</div>
|
|
1987
|
+
` : ''}
|
|
1988
|
+
</div>
|
|
1989
|
+
`;
|
|
1990
|
+
|
|
1991
|
+
let pathHtml = `<button type="button" class="codelab-breadcrumbs__item codelab-breadcrumbs__item--root" data-action="command-palette-files" data-cl-action="command-palette-files" title="Quick Open File (⌘P)">workspace</button>`;
|
|
1953
1992
|
|
|
1954
1993
|
if (this.activeFile) {
|
|
1955
1994
|
const segments = this.activeFile.split('/');
|
|
1956
1995
|
for (let i = 0; i < segments.length - 1; i++) {
|
|
1957
1996
|
const folderPath = segments.slice(0, i + 1).join('/');
|
|
1958
|
-
pathHtml += `<span class="codelab-
|
|
1959
|
-
pathHtml += `<button type="button" class="codelab-
|
|
1997
|
+
pathHtml += `<span class="codelab-breadcrumbs__sep" aria-hidden="true">›</span>`;
|
|
1998
|
+
pathHtml += `<button type="button" class="codelab-breadcrumbs__item codelab-breadcrumbs__item--folder" data-cl-breadcrumb-folder="${escapeHtml(folderPath)}" data-folder="${escapeHtml(folderPath)}" title="Scope explorer to ${escapeHtml(folderPath)}">${escapeHtml(segments[i])}</button>`;
|
|
1960
1999
|
}
|
|
1961
2000
|
const fileName = segments[segments.length - 1];
|
|
1962
|
-
pathHtml += `<span class="codelab-
|
|
1963
|
-
pathHtml += `<button type="button" class="codelab-
|
|
2001
|
+
pathHtml += `<span class="codelab-breadcrumbs__sep" aria-hidden="true">›</span>`;
|
|
2002
|
+
pathHtml += `<button type="button" class="codelab-breadcrumbs__item codelab-breadcrumbs__item--file active" data-cl-breadcrumb-file="${escapeHtml(this.activeFile)}" data-file="${escapeHtml(this.activeFile)}">${escapeHtml(fileName)}</button>`;
|
|
1964
2003
|
|
|
1965
2004
|
const symbol = this._detectActiveSymbol(this.activeFile);
|
|
1966
2005
|
if (symbol) {
|
|
1967
|
-
pathHtml += `<span class="codelab-
|
|
1968
|
-
pathHtml += `<span class="codelab-
|
|
2006
|
+
pathHtml += `<span class="codelab-breadcrumbs__sep" aria-hidden="true">›</span>`;
|
|
2007
|
+
pathHtml += `<span class="codelab-breadcrumbs__item codelab-breadcrumbs__item--symbol" data-cl-breadcrumb-symbol="${escapeHtml(symbol)}">ƒ ${escapeHtml(symbol)}</span>`;
|
|
1969
2008
|
}
|
|
1970
2009
|
}
|
|
1971
2010
|
|
|
@@ -1986,7 +2025,10 @@ declare module 'bun:sqlite' {
|
|
|
1986
2025
|
|
|
1987
2026
|
host.innerHTML = `
|
|
1988
2027
|
${expandBtnHtml}
|
|
1989
|
-
<div class="codelab-
|
|
2028
|
+
<div class="codelab-breadcrumbs__left">
|
|
2029
|
+
${switcherHtml}
|
|
2030
|
+
<div class="codelab-breadcrumbs__path">${pathHtml}</div>
|
|
2031
|
+
</div>
|
|
1990
2032
|
<div class="codelab-breadcrumbs__actions">
|
|
1991
2033
|
${diffBtnHtml}
|
|
1992
2034
|
<button type="button" class="codelab-breadcrumb__btn" data-action="command-palette" data-cl-action="command-palette" title="Open Command Palette (⌘⇧P)">
|
|
@@ -2229,6 +2271,36 @@ declare module 'bun:sqlite' {
|
|
|
2229
2271
|
return rootNode;
|
|
2230
2272
|
}
|
|
2231
2273
|
|
|
2274
|
+
_listWorkspaceFolders() {
|
|
2275
|
+
const set = new Set();
|
|
2276
|
+
if (this.folders) {
|
|
2277
|
+
for (const f of this.folders) {
|
|
2278
|
+
if (f) set.add(f);
|
|
2279
|
+
}
|
|
2280
|
+
}
|
|
2281
|
+
for (const filePath of this._orderedFileNames()) {
|
|
2282
|
+
const idx = filePath.lastIndexOf('/');
|
|
2283
|
+
if (idx <= 0) continue;
|
|
2284
|
+
const parts = filePath.slice(0, idx).split('/');
|
|
2285
|
+
let running = '';
|
|
2286
|
+
for (const p of parts) {
|
|
2287
|
+
running = running ? `${running}/${p}` : p;
|
|
2288
|
+
set.add(running);
|
|
2289
|
+
}
|
|
2290
|
+
}
|
|
2291
|
+
return Array.from(set).sort((a, b) => a.localeCompare(b));
|
|
2292
|
+
}
|
|
2293
|
+
|
|
2294
|
+
_resolveFolderNode(rootNode, folderPath) {
|
|
2295
|
+
if (!rootNode || !folderPath) return null;
|
|
2296
|
+
let current = rootNode;
|
|
2297
|
+
for (const seg of folderPath.split('/')) {
|
|
2298
|
+
if (!current || !current.folders || !current.folders.has(seg)) return null;
|
|
2299
|
+
current = current.folders.get(seg);
|
|
2300
|
+
}
|
|
2301
|
+
return current || null;
|
|
2302
|
+
}
|
|
2303
|
+
|
|
2232
2304
|
_renderFileLists() {
|
|
2233
2305
|
const explorerEl = this.container.querySelector('#cl-explorer-list');
|
|
2234
2306
|
const tabsEl = this.container.querySelector('#cl-file-tabs');
|
|
@@ -2237,6 +2309,12 @@ declare module 'bun:sqlite' {
|
|
|
2237
2309
|
if (!explorerEl || !tabsEl) return;
|
|
2238
2310
|
|
|
2239
2311
|
const treeRoot = this._buildFileTree();
|
|
2312
|
+
if (this.explorerFolder && !this._resolveFolderNode(treeRoot, this.explorerFolder)) {
|
|
2313
|
+
this.explorerFolder = '';
|
|
2314
|
+
}
|
|
2315
|
+
const scope = this.explorerFolder || '';
|
|
2316
|
+
const renderRoot = scope ? this._resolveFolderNode(treeRoot, scope) : treeRoot;
|
|
2317
|
+
const rootParent = scope;
|
|
2240
2318
|
let treeHtml = '';
|
|
2241
2319
|
|
|
2242
2320
|
const renderNode = (node, depth) => {
|
|
@@ -2291,7 +2369,7 @@ declare module 'bun:sqlite' {
|
|
|
2291
2369
|
}
|
|
2292
2370
|
};
|
|
2293
2371
|
|
|
2294
|
-
if (this.creatingItem && this.creatingItem.parentFolder ===
|
|
2372
|
+
if (this.creatingItem && this.creatingItem.parentFolder === rootParent) {
|
|
2295
2373
|
treeHtml += `
|
|
2296
2374
|
<div class="codelab-tree-create-row" style="padding-left: 10px;">
|
|
2297
2375
|
<span class="codelab-tree-create-icon">${this.creatingItem.type === 'folder' ? CL_ICONS.folder : CL_ICONS.file}</span>
|
|
@@ -2300,7 +2378,16 @@ declare module 'bun:sqlite' {
|
|
|
2300
2378
|
`;
|
|
2301
2379
|
}
|
|
2302
2380
|
|
|
2303
|
-
|
|
2381
|
+
if (scope) {
|
|
2382
|
+
treeHtml += `
|
|
2383
|
+
<button type="button" class="codelab-scope-up" data-cl-folder-option="" title="Back to workspace root">
|
|
2384
|
+
<span class="codelab-scope-up__arrow">←</span>
|
|
2385
|
+
<span class="codelab-scope-up__label">workspace</span>
|
|
2386
|
+
</button>
|
|
2387
|
+
`;
|
|
2388
|
+
}
|
|
2389
|
+
|
|
2390
|
+
renderNode(renderRoot, 0);
|
|
2304
2391
|
explorerEl.innerHTML = treeHtml;
|
|
2305
2392
|
|
|
2306
2393
|
// Attach file drag events
|
|
@@ -3861,6 +3948,29 @@ declare module 'bun:sqlite' {
|
|
|
3861
3948
|
this._portToasts.delete(p);
|
|
3862
3949
|
}
|
|
3863
3950
|
|
|
3951
|
+
_showToast(message, kind = 'info') {
|
|
3952
|
+
const toastHost = this.container ? this.container.querySelector('#cl-toast-container') : null;
|
|
3953
|
+
if (!toastHost || typeof document === 'undefined') return;
|
|
3954
|
+
const toast = document.createElement('div');
|
|
3955
|
+
toast.className = `codelab-toast codelab-toast--${kind === 'error' ? 'error' : 'info'}`;
|
|
3956
|
+
const icon = kind === 'error' ? (CL_ICONS.x || '⚠') : (CL_ICONS.externalLink || CL_ICONS.radio || '');
|
|
3957
|
+
toast.innerHTML = `
|
|
3958
|
+
<div class="codelab-toast__icon">${icon}</div>
|
|
3959
|
+
<div class="codelab-toast__body">
|
|
3960
|
+
<div class="codelab-toast__meta">${escapeHtml(message)}</div>
|
|
3961
|
+
</div>
|
|
3962
|
+
<button type="button" class="codelab-toast__close" aria-label="Dismiss notification">${CL_ICONS.x || '×'}</button>
|
|
3963
|
+
`;
|
|
3964
|
+
const closeBtn = toast.querySelector('.codelab-toast__close');
|
|
3965
|
+
const remove = () => {
|
|
3966
|
+
if (typeof toast.remove === 'function') toast.remove();
|
|
3967
|
+
else if (toast.parentNode) toast.parentNode.removeChild(toast);
|
|
3968
|
+
};
|
|
3969
|
+
if (closeBtn) closeBtn.addEventListener('click', remove);
|
|
3970
|
+
toastHost.appendChild(toast);
|
|
3971
|
+
setTimeout(remove, 5000);
|
|
3972
|
+
}
|
|
3973
|
+
|
|
3864
3974
|
_registerPreviewServiceWorker() {
|
|
3865
3975
|
if (typeof navigator === 'undefined' || !navigator.serviceWorker || typeof navigator.serviceWorker.register !== 'function') return;
|
|
3866
3976
|
const url = (this.options && this.options.previewSwUrl) || 'preview-sw.js';
|
|
@@ -3951,9 +4061,53 @@ declare module 'bun:sqlite' {
|
|
|
3951
4061
|
_previewGo(urlOrPath) {
|
|
3952
4062
|
let url = String(urlOrPath || '').trim();
|
|
3953
4063
|
if (!url) return Promise.resolve();
|
|
4064
|
+
|
|
4065
|
+
const loopbackPort = this.previewState.port || this._firstListeningPort() || 3000;
|
|
4066
|
+
const localHostRe = /^(localhost|127\.0\.0\.1|0\.0\.0\.0|\[::1\])(:\d+)?(\/.*)?$/i;
|
|
4067
|
+
|
|
4068
|
+
// Normalize the input into an absolute URL.
|
|
3954
4069
|
if (!/^https?:\/\//i.test(url)) {
|
|
3955
|
-
|
|
4070
|
+
if (localHostRe.test(url)) {
|
|
4071
|
+
url = `http://${url}`;
|
|
4072
|
+
} else if (/^[a-z0-9-]+(\.[a-z0-9-]+)+(:\d+)?([/?#].*)?$/i.test(url)) {
|
|
4073
|
+
// Bare public domain, e.g. "google.com" or "example.com/path".
|
|
4074
|
+
url = `https://${url}`;
|
|
4075
|
+
} else {
|
|
4076
|
+
url = `http://127.0.0.1:${loopbackPort}${url.startsWith('/') ? '' : '/'}${url}`;
|
|
4077
|
+
}
|
|
3956
4078
|
}
|
|
4079
|
+
|
|
4080
|
+
// Public (non-loopback) URLs cannot be served by the virtual loopback Service
|
|
4081
|
+
// Worker, so open them in a real browser tab instead of the in-browser frame.
|
|
4082
|
+
let isExternal = false;
|
|
4083
|
+
try {
|
|
4084
|
+
const u = new URL(url);
|
|
4085
|
+
const host = (u.hostname || '').toLowerCase();
|
|
4086
|
+
isExternal = !(host === 'localhost' || host === '127.0.0.1' || host === '0.0.0.0' || host === '::1' || host === '[::1]');
|
|
4087
|
+
} catch (_) { isExternal = false; }
|
|
4088
|
+
|
|
4089
|
+
if (isExternal) {
|
|
4090
|
+
let opened = false;
|
|
4091
|
+
if (typeof window !== 'undefined' && typeof window.open === 'function') {
|
|
4092
|
+
try {
|
|
4093
|
+
const win = window.open(url, '_blank');
|
|
4094
|
+
if (win) {
|
|
4095
|
+
try { win.opener = null; } catch (_) {}
|
|
4096
|
+
opened = true;
|
|
4097
|
+
}
|
|
4098
|
+
} catch (_) { opened = false; }
|
|
4099
|
+
}
|
|
4100
|
+
if (typeof this._showToast === 'function') {
|
|
4101
|
+
this._showToast(
|
|
4102
|
+
opened ? `Opened ${url} in a new tab` : `Could not open ${url} — allow pop-ups and try again`,
|
|
4103
|
+
opened ? 'info' : 'error'
|
|
4104
|
+
);
|
|
4105
|
+
}
|
|
4106
|
+
const inputEl = this.container.querySelector('#cl-preview-url-input');
|
|
4107
|
+
if (inputEl) inputEl.value = this.previewState.url || inputEl.value;
|
|
4108
|
+
return Promise.resolve();
|
|
4109
|
+
}
|
|
4110
|
+
|
|
3957
4111
|
let port = this.previewState.port;
|
|
3958
4112
|
let path = '/';
|
|
3959
4113
|
try {
|
|
@@ -4063,7 +4217,7 @@ declare module 'bun:sqlite' {
|
|
|
4063
4217
|
<button type="button" class="codelab-preview-btn" data-cl-action="preview-reload" title="Reload">${CL_ICONS.refresh || '⟳'}</button>
|
|
4064
4218
|
</div>
|
|
4065
4219
|
<select class="codelab-preview-port-select" data-cl-action="preview-port-change" aria-label="Preview port">${portOptions}</select>
|
|
4066
|
-
<input type="text" class="codelab-preview-url-input" id="cl-preview-url-input" value="${escapeHtml(this.previewState.url)}" placeholder="
|
|
4220
|
+
<input type="text" class="codelab-preview-url-input" id="cl-preview-url-input" value="${escapeHtml(this.previewState.url)}" placeholder="127.0.0.1:3000/ or https://example.com" aria-label="Preview URL" title="Localhost/virtual ports load in-frame; public URLs open in a new tab" />
|
|
4067
4221
|
<div class="codelab-preview-modes">
|
|
4068
4222
|
<button type="button" class="codelab-preview-btn ${this.previewState.frameMode === 'desktop' ? 'active' : ''}" data-cl-action="preview-mode" data-mode="desktop" title="Desktop">${CL_ICONS.monitor || '▭'}</button>
|
|
4069
4223
|
<button type="button" class="codelab-preview-btn ${this.previewState.frameMode === 'tablet' ? 'active' : ''}" data-cl-action="preview-mode" data-mode="tablet" title="Tablet">${CL_ICONS.tablet || '▢'}</button>
|
|
@@ -4682,6 +4836,11 @@ declare module 'bun:sqlite' {
|
|
|
4682
4836
|
this._previewGo(previewInput.value);
|
|
4683
4837
|
return;
|
|
4684
4838
|
}
|
|
4839
|
+
if (e.key === 'Escape' && this.folderSwitcherOpen) {
|
|
4840
|
+
this.folderSwitcherOpen = false;
|
|
4841
|
+
this._renderBreadcrumbs();
|
|
4842
|
+
return;
|
|
4843
|
+
}
|
|
4685
4844
|
if (e.key === 'F1' || ((e.metaKey || e.ctrlKey) && e.shiftKey && keyLower === 'p')) {
|
|
4686
4845
|
e.preventDefault();
|
|
4687
4846
|
this.openCommandPalette('commands');
|
|
@@ -4882,12 +5041,39 @@ declare module 'bun:sqlite' {
|
|
|
4882
5041
|
return;
|
|
4883
5042
|
}
|
|
4884
5043
|
|
|
5044
|
+
const fsToggle = e.target.closest('[data-cl-action="toggle-folder-switcher"]');
|
|
5045
|
+
if (fsToggle) {
|
|
5046
|
+
e.stopPropagation();
|
|
5047
|
+
this.folderSwitcherOpen = !this.folderSwitcherOpen;
|
|
5048
|
+
this._renderBreadcrumbs();
|
|
5049
|
+
return;
|
|
5050
|
+
}
|
|
5051
|
+
|
|
5052
|
+
const fsOption = e.target.closest('[data-cl-folder-option]');
|
|
5053
|
+
if (fsOption) {
|
|
5054
|
+
e.stopPropagation();
|
|
5055
|
+
const scopeVal = fsOption.dataset.clFolderOption || '';
|
|
5056
|
+
this.explorerFolder = scopeVal;
|
|
5057
|
+
if (scopeVal) this.collapsedFolders.delete(scopeVal);
|
|
5058
|
+
this.folderSwitcherOpen = false;
|
|
5059
|
+
this._renderFileLists();
|
|
5060
|
+
this._renderBreadcrumbs();
|
|
5061
|
+
return;
|
|
5062
|
+
}
|
|
5063
|
+
|
|
5064
|
+
if (this.folderSwitcherOpen && !e.target.closest('.codelab-folder-switcher')) {
|
|
5065
|
+
this.folderSwitcherOpen = false;
|
|
5066
|
+
this._renderBreadcrumbs();
|
|
5067
|
+
}
|
|
5068
|
+
|
|
4885
5069
|
const bcFolder = e.target.closest('[data-cl-breadcrumb-folder]');
|
|
4886
5070
|
if (bcFolder) {
|
|
4887
5071
|
const folder = bcFolder.dataset.clBreadcrumbFolder;
|
|
4888
5072
|
if (folder) {
|
|
4889
5073
|
this.collapsedFolders.delete(folder);
|
|
5074
|
+
this.explorerFolder = folder;
|
|
4890
5075
|
this._renderFileLists();
|
|
5076
|
+
this._renderBreadcrumbs();
|
|
4891
5077
|
}
|
|
4892
5078
|
return;
|
|
4893
5079
|
}
|
|
@@ -5022,10 +5208,10 @@ declare module 'bun:sqlite' {
|
|
|
5022
5208
|
this.isCreatingFile = true;
|
|
5023
5209
|
this._renderFileLists();
|
|
5024
5210
|
} else if (action === 'new-file-root') {
|
|
5025
|
-
this.creatingItem = { type: 'file', parentFolder: '' };
|
|
5211
|
+
this.creatingItem = { type: 'file', parentFolder: this.explorerFolder || '' };
|
|
5026
5212
|
this._renderFileLists();
|
|
5027
5213
|
} else if (action === 'new-folder-root') {
|
|
5028
|
-
this.creatingItem = { type: 'folder', parentFolder: '' };
|
|
5214
|
+
this.creatingItem = { type: 'folder', parentFolder: this.explorerFolder || '' };
|
|
5029
5215
|
this._renderFileLists();
|
|
5030
5216
|
} else if (action === 'new-file-folder') {
|
|
5031
5217
|
const folder = actionBtn.dataset.clFolder || '';
|