-
-
Notifications
You must be signed in to change notification settings - Fork 257
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Web & Device Extension by InfinityLoop #1186
Closed
Closed
Changes from 7 commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
5707338
Upload Web & Device
InfinityLoop1 4ae4f3e
Rename extensions/WebandDevice.js to extensions/InfinityLoopGaming/We…
InfinityLoop1 dfd04ee
Update WebandDevice.js
InfinityLoop1 25863f1
Update WebandDevice.js
InfinityLoop1 206732c
Attempting to use Prettier
InfinityLoop1 fd11283
Update extensions.json
InfinityLoop1 8a25fb3
Add clipboard
InfinityLoop1 4bd6901
Replace "get" with "fetch"
InfinityLoop1 39f6812
Merge branch 'TurboWarp:master' into master
InfinityLoop1 38865c3
Merge branch 'TurboWarp:master' into master
InfinityLoop1 e20e07c
Remove "get" (2), fix extension ID
InfinityLoop1 3569eae
Run Prettier, fix extension ID (2)
InfinityLoop1 a3eb9fd
Merge branch 'TurboWarp:master' into master
InfinityLoop1 82fafce
Add battery blocks
InfinityLoop1 d4d62d9
Run Prettier (3)
InfinityLoop1 365f8ec
Merge branch 'TurboWarp:master' into master
InfinityLoop1 49d85bd
Update WebandDevice.js
InfinityLoop1 7335f3a
Update WebandDevice.js
InfinityLoop1 0113e7a
Update WebandDevice.js
InfinityLoop1 987b3d9
Update WebandDevice.js
InfinityLoop1 6d3cb95
Update WebandDevice.js
InfinityLoop1 c81514d
Merge branch 'TurboWarp:master' into master
InfinityLoop1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,311 @@ | ||
// Name: Web & Device | ||
// ID: webanddevice_InfinityLoopGaming | ||
// Description: Interacts and gets data from websites, your device, and your network. | ||
// By: InfinityLoopGaming <https://scratch.mit.edu/users/InfinityLoopGaming/> | ||
(function (Scratch) { | ||
"use strict"; | ||
if (!Scratch.extensions.unsandboxed) { | ||
throw new Error("This extension must be run unsandboxed!"); | ||
} | ||
const paletteIcon = | ||
"data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHdpZHRoPSIxMzMuNjY2NjciIGhlaWdodD0iMTMzLjY2NjY3IiB2aWV3Qm94PSIwLDAsMTMzLjY2NjY3LDEzMy42NjY2NyI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoLTE3My41LC0xMTQuNSkiPjxnIGRhdGEtcGFwZXItZGF0YT0ieyZxdW90O2lzUGFpbnRpbmdMYXllciZxdW90Ozp0cnVlfSIgZmlsbC1ydWxlPSJub256ZXJvIiBzdHJva2U9Im5vbmUiIHN0cm9rZS1saW5lY2FwPSJidXR0IiBzdHJva2UtbGluZWpvaW49Im1pdGVyIiBzdHJva2UtbWl0ZXJsaW1pdD0iMTAiIHN0cm9rZS1kYXNoYXJyYXk9IiIgc3Ryb2tlLWRhc2hvZmZzZXQ9IjAiIHN0eWxlPSJtaXgtYmxlbmQtbW9kZTogbm9ybWFsIj48cGF0aCBkPSJNMTczLjUsMjQ4LjE2NjY3di0xMzMuNjY2NjdoMTMzLjY2NjY3djEzMy42NjY2N3oiIGZpbGw9Im5vbmUiIHN0cm9rZS13aWR0aD0iMCIvPjxnIGZpbGw9IiNmZmZmZmYiIHN0cm9rZS13aWR0aD0iMSI+PHBhdGggZD0iTTI4NC4zNDA2NiwyMDYuNjA0NGgtODguNjgxMzJjLTAuNDQzNDEsMCAtMC43MzkwMSwtMC4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2LjMzNyA2LjczNiwxMC4xOTdjMS41MDIsLTAuMzQ1IDMuMDI5LC0wLjc1OCA0LjU3OCwtMS4yNTVjLTIuNTM1LC00LjIwOCAtNi41NDgsLTcuNDMgLTExLjMxNCwtOC45NDJ6TTIyMi41MzE1LDE2OC4zMjc1YzEuMDU0LDAuMzUyIDIuNjQ0LDAuODMgNC42NzQsMS4yODdjMS40MzIsLTMuOTAxIDMuNzYxLC03LjQzIDYuODEsLTEwLjI5MWMtNC44NDMsMS40OTIgLTguOTIsNC43NDIgLTExLjQ4NCw5LjAwNHoiIGZpbGw9IiNmZmZmZmYiIHN0cm9rZS13aWR0aD0iMSIvPjwvZz48L2c+PC9zdmc+"; | ||
class WebAndDevice { | ||
getInfo() { | ||
return { | ||
id: "webanddevice_InfinityLoopGaming", | ||
name: "Web & Device", | ||
color1: "#348ceb", | ||
color2: "#5b95d4", | ||
color3: "#84a3c4", | ||
menuIconURI: paletteIcon, | ||
blocks: [ | ||
{ | ||
opcode: "setTitle", | ||
blockType: Scratch.BlockType.COMMAND, | ||
text: Scratch.translate("set page title to [title]"), | ||
arguments: { | ||
title: { | ||
type: Scratch.ArgumentType.STRING, | ||
}, | ||
}, | ||
}, | ||
{ | ||
opcode: "pageTitle", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("page title"), | ||
}, | ||
"---", | ||
{ | ||
opcode: "enterFullscreen", | ||
blockType: Scratch.BlockType.COMMAND, | ||
text: Scratch.translate("enter fullscreen"), | ||
}, | ||
{ | ||
opcode: "exitFullscreen", | ||
blockType: Scratch.BlockType.COMMAND, | ||
text: Scratch.translate("exit fullscreen"), | ||
}, | ||
{ | ||
opcode: "isFullscreen", | ||
blockType: Scratch.BlockType.BOOLEAN, | ||
text: Scratch.translate("is page fullscreen?"), | ||
}, | ||
"---", | ||
{ | ||
opcode: "connected_to_internet", | ||
blockType: Scratch.BlockType.BOOLEAN, | ||
text: "connected to internet?", | ||
}, | ||
{ | ||
opcode: "networktype", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("network type"), | ||
}, | ||
{ | ||
opcode: "networkgeneration", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("network generation"), | ||
}, | ||
"---", | ||
{ | ||
opcode: "open_url", | ||
blockType: Scratch.BlockType.COMMAND, | ||
text: Scratch.translate("open url [url] in new tab"), | ||
arguments: { | ||
url: { | ||
type: Scratch.ArgumentType.STRING, | ||
}, | ||
}, | ||
}, | ||
{ | ||
opcode: "redirect_url", | ||
blockType: Scratch.BlockType.COMMAND, | ||
text: "redirect to url [url]", | ||
arguments: { | ||
url: { | ||
type: Scratch.ArgumentType.STRING, | ||
}, | ||
}, | ||
}, | ||
{ | ||
opcode: "currenturl", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("current link"), | ||
}, | ||
{ | ||
opcode: "getdatafromurl", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: "get data from url [url]", | ||
arguments: { | ||
url: { | ||
type: Scratch.ArgumentType.STRING, | ||
}, | ||
}, | ||
}, | ||
"---", | ||
{ | ||
opcode: "browser", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("browser"), | ||
}, | ||
{ | ||
opcode: "operatingsystem", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("operating system"), | ||
}, | ||
{ | ||
opcode: "devicememory", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: Scratch.translate("device memory"), | ||
}, | ||
"---", | ||
{ | ||
opcode: "screenWidth", | ||
text: "screen width", | ||
blockType: Scratch.BlockType.REPORTER, | ||
}, | ||
{ | ||
opcode: "screenHeight", | ||
text: "screen height", | ||
blockType: Scratch.BlockType.REPORTER, | ||
}, | ||
"---", | ||
{ | ||
opcode: "set_clipboard", | ||
blockType: Scratch.BlockType.COMMAND, | ||
text: "Set clipboard to [text]", | ||
arguments: { | ||
text: { | ||
type: Scratch.ArgumentType.STRING, | ||
}, | ||
}, | ||
}, | ||
|
||
{ | ||
opcode: "get_clipboard", | ||
blockType: Scratch.BlockType.REPORTER, | ||
text: "get clipboard", | ||
}, | ||
], | ||
}; | ||
} | ||
|
||
setTitle(args) { | ||
document.title = args.title; | ||
} | ||
pageTitle() { | ||
return document.title; | ||
} | ||
enterFullscreen() { | ||
if (document.fullscreenElement === null) { | ||
document.documentElement.requestFullscreen(); | ||
} | ||
} | ||
exitFullscreen() { | ||
if (document.fullscreenElement !== null) { | ||
document.exitFullscreen(); | ||
} | ||
} | ||
isFullscreen() { | ||
return document.fullscreenElement !== null; | ||
} | ||
networktype() { | ||
try { | ||
switch (navigator.connection.type) { | ||
case "bluetooth": | ||
return "bluetooth"; | ||
case "cellular": | ||
return "cellular"; | ||
case "ethernet": | ||
return "ethernet"; | ||
case "wifi": | ||
return "wi-fi"; | ||
case "wimax": | ||
return "wimax"; | ||
default: | ||
return ""; | ||
} | ||
} catch (err) { | ||
return ""; | ||
} | ||
} | ||
networkgeneration() { | ||
try { | ||
switch (navigator.connection.effectiveType) { | ||
case "slow-2g": | ||
case "2g": | ||
return "2g"; | ||
case "3g": | ||
return "3g"; | ||
case "4g": | ||
return "4g"; | ||
default: | ||
return ""; | ||
} | ||
} catch (err) { | ||
return ""; | ||
} | ||
} | ||
currenturl() { | ||
try { | ||
return document.URL || ""; | ||
} catch (err) { | ||
return ""; | ||
} | ||
} | ||
browser() { | ||
try { | ||
let has = (input) => navigator.userAgent.includes(input); | ||
if (has("Firefox")) return "firefox"; | ||
if (has("SamsungBrowser")) return "samsung internet"; | ||
if ((has("Opera") || has("OPR")) && has("GX")) return "opera gx"; | ||
if (has("Opera") || has("OPR")) return "opera"; | ||
if (has("Trident")) return "internet explorer"; | ||
if (has("Edge")) return "legacy"; | ||
if (has("Edg")) return "edge"; | ||
if (has("YaBrowser") || has("YaSearchBrowser")) return "yandex"; | ||
if (has("Miui")) return "mi browser"; | ||
if (has("UBrowser")) return "uc browser"; | ||
if (has("Chrome")) return "chromium"; | ||
if (has("Safari")) return "safari"; | ||
return ""; | ||
} catch (err) { | ||
return ""; | ||
} | ||
} | ||
operatingsystem() { | ||
const userAgent = navigator.userAgent; | ||
if (userAgent.includes("Windows")) { | ||
return "Windows"; | ||
} else if (userAgent.includes("Android")) { | ||
return "Android"; | ||
} else if ( | ||
userAgent.includes("iPhone") || | ||
userAgent.includes("iPod") || | ||
userAgent.includes("iPad") | ||
) { | ||
return "iOS"; | ||
} else if (userAgent.includes("Linux")) { | ||
return "Linux"; | ||
} else if (userAgent.includes("CrOS")) { | ||
return "ChromeOS"; | ||
} else if (userAgent.includes("Mac OS")) { | ||
return "macOS"; | ||
} | ||
return "Other"; | ||
} | ||
devicememory() { | ||
// @ts-expect-error | ||
if (navigator.deviceMemory === undefined) { | ||
return "Unsupported"; | ||
} else { | ||
// @ts-expect-error | ||
return navigator.deviceMemory; | ||
} | ||
} | ||
open_url({ url }) { | ||
Scratch.openWindow(url); | ||
} | ||
redirect_url({ url }) { | ||
Scratch.redirect(url); | ||
} | ||
connected_to_internet() { | ||
try { | ||
return navigator.onLine; | ||
} catch (err) { | ||
return false; | ||
} | ||
} | ||
screenWidth() { | ||
return window.screen.width; | ||
} | ||
screenHeight() { | ||
return window.screen.height; | ||
} | ||
getdatafromurl(args) { | ||
return Scratch.fetch(args.URL) | ||
.then((r) => r.text()) | ||
.catch(() => ""); | ||
} | ||
set_clipboard(args) { | ||
if (navigator.clipboard && navigator.clipboard.writeText) { | ||
navigator.clipboard.writeText(args.text); | ||
} | ||
} | ||
|
||
get_clipboard() { | ||
if (navigator.clipboard && navigator.clipboard.readText) { | ||
return Scratch.canReadClipboard().then((allowed) => { | ||
if (allowed) { | ||
return navigator.clipboard.readText(); | ||
} | ||
return ""; | ||
}); | ||
} | ||
return ""; | ||
} | ||
} | ||
Scratch.extensions.register(new WebAndDevice()); | ||
})(Scratch); | ||
|
||
//Credits to Network, Navigator, Fetch, and Window Controls extensions for help with scripts. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"get" in the text of reporters is discouraged
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't that the only word in Fetch?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In fetch there isn't any other noun the block could use (e.g naming the block
([url])
would be weird), and it's also called that because it makes a GET request.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So what should I use instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use
fetch