pinokiod 1.3.75 → 1.3.77
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/kernel/api/fs/index.js
CHANGED
|
@@ -13,6 +13,7 @@ const Environment = require("../../environment")
|
|
|
13
13
|
const Util = require("../../util")
|
|
14
14
|
|
|
15
15
|
const log = (msgs, ondata) => {
|
|
16
|
+
console.log("# LOG")
|
|
16
17
|
for(let msg of msgs) {
|
|
17
18
|
if (typeof msg === "object") {
|
|
18
19
|
msg = JSON.stringify(msg, null, 2).replace(/\n/g, "\r\n")
|
|
@@ -277,6 +278,9 @@ class FS {
|
|
|
277
278
|
}
|
|
278
279
|
}
|
|
279
280
|
|
|
281
|
+
console.log(" >> d before", d)
|
|
282
|
+
console.log(JSON.stringify({ copy, move }, null, 2))
|
|
283
|
+
|
|
280
284
|
for(let relpath of copy) {
|
|
281
285
|
if (drive_home) {
|
|
282
286
|
d.copy[relpath] = path.resolve(drive_home, p, relpath)
|
|
@@ -291,6 +295,7 @@ class FS {
|
|
|
291
295
|
d.move[relpath] = kernel.path("drive", p, relpath)
|
|
292
296
|
}
|
|
293
297
|
}
|
|
298
|
+
console.log(">> d after", d)
|
|
294
299
|
ondata({
|
|
295
300
|
raw: "\r\nLINKING DRIVES:\r\n" + JSON.stringify(d, null, 2).replace(/\n/g, "\r\n")
|
|
296
301
|
})
|
package/package.json
CHANGED
package/server/index.js
CHANGED
|
@@ -2315,6 +2315,7 @@ class Server {
|
|
|
2315
2315
|
await this.renderMenu(uri, name, config, [])
|
|
2316
2316
|
}
|
|
2317
2317
|
|
|
2318
|
+
console.log("this.kernel.shell.shells.length", this.kernel.shell.shells.length)
|
|
2318
2319
|
|
|
2319
2320
|
ejs.renderFile(path.resolve(__dirname, "views/partials/menu.ejs"), { menu: config.menu }, (err, html) => {
|
|
2320
2321
|
res.send(html)
|
|
@@ -2433,11 +2434,11 @@ class Server {
|
|
|
2433
2434
|
} else if (req.body.name) {
|
|
2434
2435
|
let folderPath = this.kernel.path("api", req.body.name)
|
|
2435
2436
|
await fse.remove(folderPath)
|
|
2436
|
-
await fs.promises.mkdir(folderPath, { recursive: true }).catch((e) => { })
|
|
2437
|
+
// await fs.promises.mkdir(folderPath, { recursive: true }).catch((e) => { })
|
|
2437
2438
|
await new Promise((resolve, reject) => {
|
|
2438
2439
|
setTimeout(() => {
|
|
2439
2440
|
resolve()
|
|
2440
|
-
},
|
|
2441
|
+
}, 2000)
|
|
2441
2442
|
})
|
|
2442
2443
|
res.json({ success: true })
|
|
2443
2444
|
}
|
package/server/public/style.css
CHANGED
|
@@ -31,14 +31,14 @@
|
|
|
31
31
|
}
|
|
32
32
|
#menu img {
|
|
33
33
|
display: none;
|
|
34
|
-
height:
|
|
34
|
+
height: 30px;
|
|
35
35
|
object-fit: contain;
|
|
36
36
|
/*
|
|
37
37
|
border-radius: 20px
|
|
38
38
|
*/
|
|
39
39
|
}
|
|
40
40
|
#menu.margin {
|
|
41
|
-
padding:
|
|
41
|
+
padding: 5px;
|
|
42
42
|
}
|
|
43
43
|
#menu.margin i {
|
|
44
44
|
display: none;
|
|
@@ -131,6 +131,7 @@ body.dark .header-item .btn2 {
|
|
|
131
131
|
}
|
|
132
132
|
.bar .btn2 i {
|
|
133
133
|
display: block;
|
|
134
|
+
margin-right: 5px;
|
|
134
135
|
}
|
|
135
136
|
.header-item > * {
|
|
136
137
|
display: block;
|
|
@@ -348,18 +349,19 @@ body.dark nav {
|
|
|
348
349
|
*/
|
|
349
350
|
border-top: 1px solid rgba(255,255,255,0.04);
|
|
350
351
|
}
|
|
352
|
+
/*
|
|
351
353
|
.container:hover nav {
|
|
352
354
|
display: block;
|
|
353
|
-
max-height: 200px;
|
|
354
355
|
}
|
|
356
|
+
*/
|
|
355
357
|
nav {
|
|
358
|
+
/*
|
|
356
359
|
overflow: hidden;
|
|
357
360
|
max-height: 0;
|
|
358
361
|
transition: max-height 0.4s ease-out;
|
|
359
|
-
|
|
360
|
-
/*
|
|
361
362
|
display: none;
|
|
362
363
|
*/
|
|
364
|
+
|
|
363
365
|
background: white;
|
|
364
366
|
/*
|
|
365
367
|
position: absolute;
|
|
@@ -393,7 +395,9 @@ nav .btn2 {
|
|
|
393
395
|
flex-shrink: 0;
|
|
394
396
|
|
|
395
397
|
display: flex;
|
|
398
|
+
/*
|
|
396
399
|
flex-direction: column;
|
|
400
|
+
*/
|
|
397
401
|
justify-content: center;
|
|
398
402
|
align-items: center;
|
|
399
403
|
}
|
|
@@ -485,6 +489,7 @@ body.dark .loader-container {
|
|
|
485
489
|
width: auto !important;
|
|
486
490
|
min-width: 40px;
|
|
487
491
|
border-right: none;
|
|
492
|
+
flex-direction: column;
|
|
488
493
|
}
|
|
489
494
|
.app-info {
|
|
490
495
|
display: flex;
|
|
@@ -597,17 +602,6 @@ body.dark .loader-container {
|
|
|
597
602
|
-->
|
|
598
603
|
</aside>
|
|
599
604
|
<div class='container'>
|
|
600
|
-
<main class='browserview'>
|
|
601
|
-
<% if (false) { %>
|
|
602
|
-
<% if (config.menu) { %>
|
|
603
|
-
<% config.menu.forEach((item) => { %>
|
|
604
|
-
<% if (item.btn && item.src) { %>
|
|
605
|
-
<iframe name='<%=item.src%>' class='hidden'></iframe>
|
|
606
|
-
<% } %>
|
|
607
|
-
<% }) %>
|
|
608
|
-
<% } %>
|
|
609
|
-
<% } %>
|
|
610
|
-
</main>
|
|
611
605
|
<nav>
|
|
612
606
|
<div class='bar'>
|
|
613
607
|
<button class='btn2' id='menu-mobile'><i class="fa-solid fa-bars"></i></button>
|
|
@@ -619,30 +613,28 @@ body.dark .loader-container {
|
|
|
619
613
|
<button class='btn2' id='back'><i class="fa-solid fa-chevron-left"></i></button>
|
|
620
614
|
<button class='btn2' id='forward'><i class="fa-solid fa-chevron-right"></i></button>
|
|
621
615
|
<% } %>
|
|
622
|
-
<button class='btn2' id='
|
|
616
|
+
<button class='btn2' id='reload'><i class="fa-solid fa-rotate-right"></i> Refresh</button>
|
|
623
617
|
<% if (agent === "electron") { %>
|
|
624
618
|
<a class='btn2' id='open-browser' target="_blank" href="" features="browser"><i class="fa-solid fa-square-arrow-up-right"></i> Popout</a>
|
|
625
619
|
<% } else { %>
|
|
626
620
|
<a class='btn2' id='open-browser' target="_blank" href=""><i class="fa-solid fa-square-arrow-up-right"></i> Popout</a>
|
|
627
621
|
<% } %>
|
|
628
|
-
<button class='btn2' id='reload'><i class="fa-solid fa-rotate-right"></i> Refresh</button>
|
|
629
|
-
<div id='new-tab' class='btn2'><i class="fa-solid fa-plus"></i> Tab</div>
|
|
630
|
-
<!--
|
|
631
|
-
<button class='btn2 logo' id='reload'><i class="fa-solid fa-rotate-right"></i></button>
|
|
632
|
-
-->
|
|
633
622
|
<input type='url' id='location' readonly>
|
|
634
|
-
|
|
635
|
-
<div id='
|
|
636
|
-
-->
|
|
623
|
+
<button class='btn2' id='clone-tab'><i class='fa-regular fa-copy'></i> Clone</button>
|
|
624
|
+
<div id='new-tab' class='btn2'><i class="fa-solid fa-plus"></i> Tab</div>
|
|
637
625
|
</div>
|
|
638
|
-
<!--
|
|
639
|
-
<div class='flexible'></div>
|
|
640
|
-
<a class='btn2' href="/?mode=explore"><div><i class="fa-solid fa-globe"></i></div><div>Discover</div></a>
|
|
641
|
-
<a class='btn2' id='report'><div><i class="fa-solid fa-bug"></i></div><div>Report Bug</div></a>
|
|
642
|
-
<a class='btn2' href='https://discord.gg/TQdNwadtE4' target="_blank"><div><i class="fa-brands fa-discord"></i></div><div>Discord</div></a>
|
|
643
|
-
<a class='btn2' href='https://twitter.com/cocktailpeanut' target="_blank"><div><i class="fa-brands fa-twitter"></i></div><div>Twitter</div></a>
|
|
644
|
-
-->
|
|
645
626
|
</nav>
|
|
627
|
+
<main class='browserview'>
|
|
628
|
+
<% if (false) { %>
|
|
629
|
+
<% if (config.menu) { %>
|
|
630
|
+
<% config.menu.forEach((item) => { %>
|
|
631
|
+
<% if (item.btn && item.src) { %>
|
|
632
|
+
<iframe name='<%=item.src%>' class='hidden'></iframe>
|
|
633
|
+
<% } %>
|
|
634
|
+
<% }) %>
|
|
635
|
+
<% } %>
|
|
636
|
+
<% } %>
|
|
637
|
+
</main>
|
|
646
638
|
</div>
|
|
647
639
|
<script>
|
|
648
640
|
let loaded = {}
|
|
@@ -191,9 +191,7 @@ document.addEventListener("DOMContentLoaded", async () => {
|
|
|
191
191
|
<% } %>
|
|
192
192
|
<label for="cloudflare"><i class="fa-brands fa-cloudflare"></i> Run a Public Node</label>
|
|
193
193
|
<ul>
|
|
194
|
-
<li>This will
|
|
195
|
-
<li>Anyone with a URL can access a public node.</li>
|
|
196
|
-
<li>Users can't access Pinokio itself, only can access each app's UI.</li>
|
|
194
|
+
<li>This will let you share your local Pinokio app to the public internet, which anyone with a URL can access.</li>
|
|
197
195
|
<li>Powered by <a href="https://www.cloudflare.com/products/tunnel/" target="_blank" features="browser">Cloudflare Tunnel</a></li>
|
|
198
196
|
<li>You can manually configure this in through the Configure menu (set PINOKIO_SHARE_CLOUDFLARE to true)</li>
|
|
199
197
|
</ul>
|