Skip to content
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

Update strings 20240515 #1747

Open
wants to merge 145 commits into
base: update-strings-20240515
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
145 commits
Select commit Hold shift + click to select a range
a04c0d8
obviousAlexC/penPlus: the big ol U_res patch (#1471)
David-Orangemoon May 16, 2024
94bab3c
Update gitignore (#1472)
GarboMuffin May 16, 2024
a7999c2
Update translations (#1473)
GarboMuffin May 16, 2024
02e255b
Add translations to TempVar, TempVar2, ClonesPlus (#1477)
qxsck May 19, 2024
168e724
NOname-awa/graphics2d: Use atan2 to get coord to coord angle (#1460)
DNin01 May 19, 2024
6a18c3e
Bump eslint from 9.2.0 to 9.3.0 (#1479)
dependabot[bot] May 20, 2024
07ba291
Xeltalliv/simple3D: fix bugs with transform direction block, model im…
Xeltalliv May 20, 2024
051b271
obviousAlexC/penPlus: Return "" for early returns on reporters (#1482)
David-Orangemoon May 21, 2024
5d4d4fd
mbw/xml: Add setTextContent (#1484)
Procybit May 23, 2024
9753585
TheShovel/LZ-String: Added extension colors to match the thumbnail (#…
BlueDome77 May 24, 2024
9b7b31e
Update translations (#1491)
GarboMuffin May 26, 2024
2924d00
Update translations (#1494)
GarboMuffin May 28, 2024
b4b5c70
obviousAlexC/PenPlus: bugfixes and patches (#1496)
David-Orangemoon May 29, 2024
6d97253
Xeltalliv/simple3D: fix draw range bounds checking, fix instance XY p…
Xeltalliv Jun 1, 2024
188a0c0
obviousAlexC/penPlus: fix opening a project from project_url and the …
David-Orangemoon Jun 1, 2024
084034a
files: Fix event listener leak (#1504)
GarboMuffin Jun 2, 2024
0f81a2a
Bump adm-zip from 0.5.12 to 0.5.13 (#1507)
dependabot[bot] Jun 3, 2024
1aaca96
Bump prettier from 3.2.4 to 3.3.0 (#1506)
dependabot[bot] Jun 3, 2024
a703249
Bump eslint from 9.3.0 to 9.4.0 (#1505)
dependabot[bot] Jun 3, 2024
f8ba165
obviousAlexC/penPlus: Fix texture handling between versions of pen+ (…
David-Orangemoon Jun 4, 2024
332d0df
NexusKitten/sgrab: deal with ScratchDB being offline (#1511)
GarboMuffin Jun 4, 2024
7d8cb51
NexusKitten/sgrab: handle errors better (#1512)
GarboMuffin Jun 4, 2024
49c1bea
obviousAlexC/penPlus: don't use isPackaged (#1516)
GarboMuffin Jun 6, 2024
2b0318f
lab/text: add with/without word wrap option to # of lines block (#1497)
AshimeeAlt Jun 9, 2024
af35fb4
New extension: Vibration (#1509)
PwLDev Jun 9, 2024
e1b9fd9
Image update batch (#1518)
GarboMuffin Jun 9, 2024
953a0ed
CubesterYT/KeySimulation: Update images (#1519)
GarboMuffin Jun 9, 2024
a09a5e3
Xeltalliv/simple3D: conetxt --> context (#1521)
Jun 9, 2024
9e789d5
build(deps): bump adm-zip from 0.5.13 to 0.5.14 (#1524)
dependabot[bot] Jun 10, 2024
1315db4
build(deps-dev): bump prettier from 3.3.0 to 3.3.1 (#1525)
dependabot[bot] Jun 10, 2024
823b884
lab/text: reflow if needed in getLinesV2 (#1529)
GarboMuffin Jun 10, 2024
b4721f4
Add translations to more extensions (#1526)
qxsck Jun 10, 2024
38115fe
PwLDev/vibration: Vibration pattern block (#1522)
DNin01 Jun 11, 2024
665a8f2
NexusKitten/controlcontrols: Highlight block (#1532)
DNin01 Jun 11, 2024
22928f9
NexusKitten/controlcontrols: remove revert-layer (#1533)
GarboMuffin Jun 11, 2024
24cff03
Lily/SoundExpanded: fix set volume and start looping w/ start (#1534)
GarboMuffin Jun 11, 2024
bf8dc87
Lily/MoreEvents: don't translate an unused menu (#1535)
GarboMuffin Jun 11, 2024
eb7df9e
Lily/AllMenus: hide unused More Events menu and XML escape (#1537)
GarboMuffin Jun 11, 2024
bd8777f
A lot of text style fixes and translations (#1540)
CubesterYT Jun 14, 2024
accfb29
NOname-awa/cn-number: translate (#1543)
GarboMuffin Jun 14, 2024
bb6b39f
Fix mistake (#1544)
CubesterYT Jun 14, 2024
576c3aa
veggiecan/browserfullscreen: no-op if no change will occur (#1545)
veggiecan0419 Jun 14, 2024
2b918d9
build(deps-dev): bump prettier from 3.3.1 to 3.3.2 (#1547)
dependabot[bot] Jun 17, 2024
7f48963
build(deps-dev): bump eslint from 9.4.0 to 9.5.0 (#1548)
dependabot[bot] Jun 17, 2024
60d8a9b
NexusKitten/sgrab: remove icon (#1550)
GarboMuffin Jun 18, 2024
32befa2
XmerOriginals/closecontrol: add credit link (#1552)
xmeroriginals Jun 18, 2024
d7df8c3
Update translations (#1558)
GarboMuffin Jun 21, 2024
38be121
Use prefixed fullscreen methods (#1559)
GarboMuffin Jun 21, 2024
9a0c594
mdwalters/notifications: Fix permission denied handling (#1561)
GarboMuffin Jun 22, 2024
68dcb60
penplus: fix description (#1563)
qxsck Jun 23, 2024
3103e09
Migrate to ESM (#1564)
GarboMuffin Jun 23, 2024
be07919
SharkPool/Font-Manager: I dont go by ashime anymore. (#1565)
yuri-kiss Jun 23, 2024
61fd6a3
Add BSD-3-Clause to licenses (#1567)
DNin01 Jun 25, 2024
ae0ac9d
obviousAlexC/penPlus: Add name to "saveShader" event (#1575)
David-Orangemoon Jun 28, 2024
2a429db
Revert "Migrate to esm" (#1574)
GarboMuffin Jul 1, 2024
48faa26
build(deps-dev): bump eslint from 9.5.0 to 9.6.0 (#1577)
dependabot[bot] Jul 1, 2024
7d4ba64
obviousAlexC/penPlus: Update example project (#1579)
David-Orangemoon Jul 2, 2024
034d737
Xeltalliv/simple3D: add button to extra resources and improve sample …
Xeltalliv Jul 7, 2024
7bf116c
build(deps-dev): bump prettier from 3.3.2 to 3.3.3 (#1610)
dependabot[bot] Jul 15, 2024
d856f70
build(deps-dev): bump eslint from 9.6.0 to 9.7.0 (#1612)
dependabot[bot] Jul 15, 2024
f8b6e63
build(deps-dev): bump esquery from 1.5.0 to 1.6.0 (#1611)
dependabot[bot] Jul 15, 2024
8f734af
Update translations (#1616)
GarboMuffin Jul 16, 2024
3a59915
obviousAlexC/penPlus: Make uniforms searching specify that it has to …
David-Orangemoon Jul 18, 2024
8f48237
Xeltalliv/simple3D: Feature update v1.1.0 (#1618)
Xeltalliv Jul 20, 2024
8541c95
XmerOriginals/closecontrol: new image (#1621)
GarboMuffin Jul 23, 2024
d916741
New extension: steamworks (#1622)
GarboMuffin Jul 26, 2024
a2a57c8
steamworks: docs update (#1626)
GarboMuffin Jul 26, 2024
44e16e8
build(deps-dev): bump eslint from 9.7.0 to 9.8.0 (#1627)
dependabot[bot] Jul 27, 2024
aa22053
build(deps): bump @turbowarp/scratchblocks from 3.6.4 to 3.6.5 (#1628)
dependabot[bot] Jul 27, 2024
8dffc0d
steamworks: docs update 2 (#1630)
GarboMuffin Jul 28, 2024
aee8630
cst1229/zip: expose extension object (#1631)
CST1229 Jul 28, 2024
44ad6f2
Lily/LooksPlus: Optimize restore content block (#1638)
GarboMuffin Aug 5, 2024
eafceab
encoding: Fix unicode base64 encode/decode (#1599)
Procybit Aug 5, 2024
3ce22a6
Skyhigh173/JSON: fix json_is_valid() (#1596)
Procybit Aug 5, 2024
ea67bd8
Update translations (#1641)
GarboMuffin Aug 5, 2024
532daff
Lily/Video: clamp volume, add screenshot at current time (#1595)
SharkPool-SP Aug 6, 2024
dfb5354
Lily/Video: playback rate (#1642)
GarboMuffin Aug 6, 2024
23e5c1a
Lily/Assets: fix addCostume corruption (#1643)
GarboMuffin Aug 6, 2024
5499be0
vercte/dictionaries: Always Cast Keys to Strings (#1644)
SharkPool-SP Aug 10, 2024
d228f60
mbw/xml: fix bugs, add inner HTML blocks (#1647)
mybearworld Aug 13, 2024
ee34483
build(deps-dev): bump eslint from 9.8.0 to 9.9.0 (#1646)
dependabot[bot] Aug 19, 2024
9edfed5
build(deps): bump adm-zip from 0.5.14 to 0.5.15 (#1645)
dependabot[bot] Aug 19, 2024
263033c
Xeltalliv/clippingblending: Fix compatibility with instanced pen rend…
Xeltalliv Aug 21, 2024
f0d4e9e
build(deps-dev): bump eslint from 9.9.0 to 9.9.1 (#1659)
dependabot[bot] Aug 26, 2024
2646607
build(deps): bump adm-zip from 0.5.15 to 0.5.16 (#1668)
dependabot[bot] Sep 2, 2024
8f81856
veggiecan/LongmanDictionary: fix all defs returning array instead of …
GarboMuffin Sep 7, 2024
a834058
Lily/Video: fix videos rendering as pure black (#1692)
GarboMuffin Sep 20, 2024
7e91056
build(deps-dev): bump eslint from 9.9.1 to 9.12.0 (#1713)
dependabot[bot] Oct 7, 2024
d689cbc
build(deps): bump express from 4.19.2 to 4.21.0 (#1687)
dependabot[bot] Oct 7, 2024
363e5fb
Lily/Skins: fix `delete all skins` not deleting the renderer skins (#…
CST1229 Oct 11, 2024
d21f029
build(deps): bump express from 4.21.0 to 4.21.1 (#1722)
dependabot[bot] Oct 14, 2024
b58a62e
Revert "fix: downloadBlob isn't working properly on some old browsers…
FurryR Oct 14, 2024
33afff0
Edit some paragraphs on the homepage (#1660)
DNin01 Oct 14, 2024
93983a2
Lily/ClonesPlus, Lily/LooksPlus, Skyhigh173/json: editingTarget can b…
GarboMuffin Oct 16, 2024
5c91389
Update GitHub Actions workflows (#1728)
GarboMuffin Oct 16, 2024
63377ee
obviousAlexC/newgroundsIO: Cast medalID inputs for medal arguments (#…
JeremyGamer13 Oct 23, 2024
3e970f2
Update translations (#1734)
GarboMuffin Oct 26, 2024
f3ac83b
build(deps-dev): bump eslint from 9.12.0 to 9.13.0 (#1730)
dependabot[bot] Nov 2, 2024
0e127cf
Lily/lmsutils: fix != <= >= (#1739)
GarboMuffin Nov 2, 2024
2e9eb5a
Xeltalliv/simple3D: Feature update v1.2.0 (#1738)
Xeltalliv Nov 2, 2024
399a894
Update chokidar to v4 (#1740)
GarboMuffin Nov 2, 2024
c8c2a10
XeroName/Deltatime: don't report delta time of 0 (#1741)
GarboMuffin Nov 2, 2024
b89f305
Add links for qxsck & Skyhigh173 (#1742)
GarboMuffin Nov 3, 2024
8d1adfc
build(deps-dev): bump eslint from 9.13.0 to 9.14.0 (#1744)
dependabot[bot] Nov 3, 2024
5daee2d
build(deps): bump @turbowarp/types from `da53338` to `1f85881` (#1743)
dependabot[bot] Nov 3, 2024
fedbe62
SharkPool/Font-Manager: updates (#1745)
GarboMuffin Nov 3, 2024
079c8a0
Create tsete.txt
Eaielectronic Nov 5, 2024
8192690
Add files via upload
Eaielectronic Nov 5, 2024
e08a5de
Delete extensions/Eaielectronic/tsete.txt
Eaielectronic Nov 5, 2024
62452cd
Rename Finger mutli-mobile to Finger-mutli-mobile.js
Eaielectronic Nov 5, 2024
c418acf
Rename Fps-returne to Fps-returne.js
Eaielectronic Nov 5, 2024
ef61a2e
Rename Login page to Login-page.js
Eaielectronic Nov 5, 2024
48d84fb
Update Login-page.js
Eaielectronic Nov 5, 2024
42ad742
Update ScrollingTextBubble.js
Eaielectronic Nov 5, 2024
a73cd31
Update Login-page.js
Eaielectronic Nov 5, 2024
c854e96
Update Fps-returne.js
Eaielectronic Nov 5, 2024
a5e821f
Update Finger-mutli-mobile.js
Eaielectronic Nov 5, 2024
1e0a04b
Update Finger-mutli-mobile.js
Eaielectronic Nov 5, 2024
43330b3
Update Fps-returne.js
Eaielectronic Nov 5, 2024
fc3218e
Update Login-page.js
Eaielectronic Nov 5, 2024
17a62a5
Update ScrollingTextBubble.js
Eaielectronic Nov 5, 2024
34ba4b1
Create teste.txt
Eaielectronic Nov 5, 2024
32f7557
Create teste
Eaielectronic Nov 5, 2024
e8782c4
Add files via upload
Eaielectronic Nov 5, 2024
c7d180d
Delete images/Eaielectronic/Finger-mutli-mobile.svg
Eaielectronic Nov 5, 2024
211311d
Delete images/Eaielectronic/Finger-mutli-mobile2.svg
Eaielectronic Nov 5, 2024
09d0c3e
Delete images/Eaielectronic/teste
Eaielectronic Nov 5, 2024
a0e03c0
Delete images/Eaielectronic/teste.txt
Eaielectronic Nov 5, 2024
3907f16
Add files via upload
Eaielectronic Nov 5, 2024
ae418c5
Delete images/Eaielectronic/Finger-mutli-mobile2.svg
Eaielectronic Nov 5, 2024
b786216
Add files via upload
Eaielectronic Nov 5, 2024
aa36118
Update ScrollingTextBubble.js.svg
Eaielectronic Nov 5, 2024
d6f8ba3
Update Login-page.svg
Eaielectronic Nov 5, 2024
84f3ba2
Update Finger-mutli-mobile.svg
Eaielectronic Nov 5, 2024
a60c18c
Delete images/Eaielectronic/ScrollingTextBubble.js.svg
Eaielectronic Nov 5, 2024
acf6920
Delete images/Eaielectronic/Login-page.svg
Eaielectronic Nov 5, 2024
b4151aa
Add files via upload
Eaielectronic Nov 5, 2024
f4531fc
Update Fps-returne.js
Eaielectronic Nov 5, 2024
bdb3d5d
Update Login-page.js
Eaielectronic Nov 5, 2024
b2a48bc
Update ScrollingTextBubble.js
Eaielectronic Nov 5, 2024
77cc15c
Update ScrollingTextBubble.js
Eaielectronic Nov 5, 2024
c9d1d4d
Update ScrollingTextBubble.js
Eaielectronic Nov 5, 2024
5b74dc3
apply prettier
Eaielectronic Nov 6, 2024
155ae48
apply
Eaielectronic Nov 6, 2024
d1b6234
apply
Eaielectronic Nov 6, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
- name: Build for production
run: npm run build
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
uses: actions/upload-pages-artifact@v3
with:
path: ./build/

Expand All @@ -42,4 +42,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1
uses: actions/deploy-pages@v4
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,10 @@ build-l10n
# Various operating system caches
thumbs.db
.DS_Store

# Popular editors
.vscode
.idea
*.sublime-workspace

# Tip: .git/info/exclude is your personal gitignore for things that don't belong here
276 changes: 276 additions & 0 deletions extensions/Eaielectronic/ScrollingTextBubble.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,276 @@
// Name: Scrolling bull
// ID: scrollingTextBubble
// Description: Create scrolling text bubbles and apply styles with Html tags.
// By: Eaielectronic
// By: SERPENT1867 <https://scratch.mit.edu/users/serpent1867/>
// License: MPL-2.0
(function (Scratch) {
"use strict";

class ScrollingTextBubble {
constructor() {
this.bubbles = {};
this.defaultBubbleStyle = {
backgroundColor: "rgba(255, 255, 255, 0.8)",
borderColor: "black",
borderWidth: "2px",
borderRadius: "10px",
boxShadow: "0 4px 8px rgba(0, 0, 0, 0.2)",
padding: "15px", // Valeur par défaut du padding
};
}

getInfo() {
return {
id: "scrollingTextBubble",
name: "Scrolling Text Bubble",
blocks: [
{
opcode: "showTextBubble",
blockType: Scratch.BlockType.COMMAND,
text: "show text bubble with text [TEXT] next to sprite with speed [SPEED], font [FONT], width [WIDTH], offsetX [OFFSETX], offsetY [OFFSETY]",
arguments: {
TEXT: {
type: Scratch.ArgumentType.STRING,
defaultValue: "Hello, World!",
},
SPEED: {
type: Scratch.ArgumentType.NUMBER,
defaultValue: 50,
},
FONT: {
type: Scratch.ArgumentType.STRING,
defaultValue: "Arial",
},
WIDTH: {
type: Scratch.ArgumentType.NUMBER,
defaultValue: 200,
},
OFFSETX: {
type: Scratch.ArgumentType.NUMBER,
defaultValue: 0,
},
OFFSETY: {
type: Scratch.ArgumentType.NUMBER,
defaultValue: -60,
},
},
filter: [Scratch.TargetType.SPRITE],
},
{
opcode: "hideTextBubble",
blockType: Scratch.BlockType.COMMAND,
text: "hide text bubble",
filter: [Scratch.TargetType.SPRITE],
},
{
opcode: "hideAllTextBubbles",
blockType: Scratch.BlockType.COMMAND,
text: "hide all text bubbles",
},
{
opcode: "setBubbleColor",
blockType: Scratch.BlockType.COMMAND,
text: "set bubble color to [COLOR]",
arguments: {
COLOR: {
type: Scratch.ArgumentType.COLOR,
defaultValue: "#ffffff",
},
},
},
{
opcode: "setBubbleStyle",
blockType: Scratch.BlockType.COMMAND,
text: "set bubble style to [STYLE]",
arguments: {
STYLE: {
type: Scratch.ArgumentType.STRING,
menu: "bubbleStyleMenu",
defaultValue: "default",
},
},
},
{
opcode: "setBubblePadding",
blockType: Scratch.BlockType.COMMAND,
text: "set bubble padding to [PADDING]",
arguments: {
PADDING: {
type: Scratch.ArgumentType.NUMBER,
defaultValue: 15, // Valeur par défaut pour le padding
},
},
},
],
menus: {
bubbleStyleMenu: {
acceptReporters: true,
items: ["default", "rounded", "sharp", "shadow", "no-border"],
},
},
};
}

showTextBubble(args, util) {
const sprite = util.target;
const text = args.TEXT;
const speed = args.SPEED;
const font = args.FONT;
const width = args.WIDTH;
const offsetX = args.OFFSETX;
const offsetY = args.OFFSETY;

if (this.bubbles[sprite.id]) {
clearInterval(this.bubbles[sprite.id].intervalId);
this.bubbles[sprite.id].bubbleDiv.remove();
}

const bubbleDiv = document.createElement("div");
bubbleDiv.style.position = "absolute";
this.applyBubbleStyle(bubbleDiv);
bubbleDiv.style.maxWidth = `${width}px`;
bubbleDiv.style.overflow = "hidden";
bubbleDiv.style.whiteSpace = "pre-wrap";
bubbleDiv.style.fontFamily = font;
bubbleDiv.style.color = "black";
bubbleDiv.style.fontSize = "16px";
bubbleDiv.style.lineHeight = "1.5";

const canvas = Scratch.renderer.canvas;
const rect = canvas.getBoundingClientRect();

const textContainer = document.createElement("span");
bubbleDiv.appendChild(textContainer);
document.body.appendChild(bubbleDiv);

const updateBubblePosition = () => {
const { x, y } = sprite;

const proportionX = rect.width / 480;
const proportionY = rect.height / 360;

const adjustedOffsetX = offsetX * proportionX;
const adjustedOffsetY = offsetY * proportionY;

bubbleDiv.style.left = `${rect.left + ((x + 240) / 480) * rect.width + adjustedOffsetX}px`;
bubbleDiv.style.top = `${rect.top + ((180 - y) / 360) * rect.height + adjustedOffsetY}px`;
};

updateBubblePosition();
window.addEventListener("mousemove", updateBubblePosition);

const formattedText = this.formatText(text);
const textParts = this.splitText(formattedText);

let index = 0;
let currentHTML = "";

const intervalId = setInterval(() => {
if (index < textParts.length) {
currentHTML += textParts[index];
textContainer.innerHTML = currentHTML;
index++;
} else {
clearInterval(intervalId);
}
}, speed);

this.bubbles[sprite.id] = { intervalId, bubbleDiv };
}

hideTextBubble(args, util) {
const sprite = util.target;

if (this.bubbles[sprite.id]) {
clearInterval(this.bubbles[sprite.id].intervalId);
this.bubbles[sprite.id].bubbleDiv.remove();
delete this.bubbles[sprite.id];
}
}

hideAllTextBubbles() {
for (const spriteId in this.bubbles) {
if (Object.prototype.hasOwnProperty.call(this.bubbles, spriteId)) {
clearInterval(this.bubbles[spriteId].intervalId);
this.bubbles[spriteId].bubbleDiv.remove();
delete this.bubbles[spriteId];
}
}
}

setBubbleColor(args) {
const color = args.COLOR;
this.defaultBubbleStyle.backgroundColor = color;
}

setBubblePadding(args) {
const padding = args.PADDING;
this.defaultBubbleStyle.padding = `${padding}px`;
}

setBubbleStyle(args) {
const style = args.STYLE;

switch (style) {
case "rounded":
this.defaultBubbleStyle.borderRadius = "20px";
break;
case "sharp":
this.defaultBubbleStyle.borderRadius = "0px";
break;
case "shadow":
this.defaultBubbleStyle.boxShadow = "0 8px 16px rgba(0, 0, 0, 0.5)";
break;
case "no-border":
this.defaultBubbleStyle.borderWidth = "0px";
break;
default:
this.defaultBubbleStyle = {
backgroundColor: "rgba(255, 255, 255, 0.8)",
borderColor: "black",
borderWidth: "2px",
borderRadius: "10px",
boxShadow: "0 4px 8px rgba(0, 0, 0, 0.2)",
padding: "15px",
};
break;
}
}

applyBubbleStyle(bubbleDiv) {
bubbleDiv.style.backgroundColor = this.defaultBubbleStyle.backgroundColor;
bubbleDiv.style.border = `${this.defaultBubbleStyle.borderWidth} solid ${this.defaultBubbleStyle.borderColor}`;
bubbleDiv.style.borderRadius = this.defaultBubbleStyle.borderRadius;
bubbleDiv.style.boxShadow = this.defaultBubbleStyle.boxShadow;
bubbleDiv.style.padding = this.defaultBubbleStyle.padding;
}

formatText(text) {
// Retourne le texte brut, seules les balises HTML sont interprétées
return text;
}

splitText(text) {
const parts = [];
const tagRegex = /<\/?[^>]+>/g;
let lastIndex = 0;

text.replace(tagRegex, (match, index) => {
if (index > lastIndex) {
parts.push(...text.slice(lastIndex, index).split(""));
}
parts.push(match);
lastIndex = index + match.length;
});

if (lastIndex < text.length) {
parts.push(...text.slice(lastIndex).split(""));
}

return parts;
}
}

Scratch.extensions.register(new ScrollingTextBubble());
})(Scratch);
1 change: 1 addition & 0 deletions images/Eaielectronic/ScrollingTextBubble.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading