pinokiod 1.0.20 → 1.0.21
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/package.json +1 -1
- package/server/views/browser.ejs +10 -8
package/package.json
CHANGED
package/server/views/browser.ejs
CHANGED
|
@@ -402,7 +402,7 @@ body.dark #new-tab {
|
|
|
402
402
|
</div>
|
|
403
403
|
<script>
|
|
404
404
|
window.prompt = (a, b) => {
|
|
405
|
-
console.log("
|
|
405
|
+
console.log("global overridden prompt", { a, b })
|
|
406
406
|
}
|
|
407
407
|
let loaded = {}
|
|
408
408
|
let cursorIndex = 0;
|
|
@@ -581,11 +581,12 @@ console.log({ type, index })
|
|
|
581
581
|
"allow",
|
|
582
582
|
"clipboard-read *; clipboard-write *; accelerometer *; ambient-light-sensor *; autoplay *; battery *; camera *; display-capture *; gamepad *; geolocation *; gyroscope *; hid *; identity-credentials-get *; microphone *; midi *; otp-credentials *; serial *;"
|
|
583
583
|
)
|
|
584
|
-
frame.contentWindow.prompt = function(a, b) {
|
|
585
|
-
console.log("prompt1", { a, b })
|
|
586
|
-
return prompt(a, b)
|
|
587
|
-
}
|
|
588
584
|
document.querySelector("main").appendChild(frame)
|
|
585
|
+
frame.onload = () => {
|
|
586
|
+
frame.contentWindow.prompt = (a, b) => {
|
|
587
|
+
console.log("1 overridden prompt", { a, b })
|
|
588
|
+
}
|
|
589
|
+
}
|
|
589
590
|
loaded[target.target] = true
|
|
590
591
|
}
|
|
591
592
|
} else {
|
|
@@ -691,9 +692,10 @@ const addTab = async (url) => {
|
|
|
691
692
|
"clipboard-read *; clipboard-write *; accelerometer *; ambient-light-sensor *; autoplay *; battery *; camera *; display-capture *; gamepad *; geolocation *; gyroscope *; hid *; identity-credentials-get *; microphone *; midi *; otp-credentials *; serial *;"
|
|
692
693
|
)
|
|
693
694
|
document.querySelector("main").appendChild(frame)
|
|
694
|
-
frame.
|
|
695
|
-
|
|
696
|
-
|
|
695
|
+
frame.onload = () => {
|
|
696
|
+
frame.contentWindow.prompt = (a, b) => {
|
|
697
|
+
console.log("2 overridden prompt", { a, b })
|
|
698
|
+
}
|
|
697
699
|
}
|
|
698
700
|
|
|
699
701
|
await syncTabs()
|