MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / forwardedSource

Function forwardedSource

quote/quote.ts:368–383  ·  view source on GitHub ↗
(msg: Api.Message)

Source from the content-addressed store, hash-verified

366 const scaleEq = lower.match(/^(?:scale|s)[=:](\d+(?:\.\d+)?)$/);
367 if (scaleEq) {
368 const s = Number(scaleEq[1]);
369 if (Number.isFinite(s) && s > 0) out.scale = Math.min(20, Math.max(1, s));
370 continue;
371 }
372 if (lower === "scale" || lower === "s") {
373 const next = args[i + 1];
374 const s = next ? Number(next) : NaN;
375 if (Number.isFinite(s) && s > 0) {
376 out.scale = Math.min(20, Math.max(1, s));
377 i++;
378 }
379 continue;
380 }
381
382 // bg=#xxx / color=#xxx / background=#xxx
383 const colorEq = lower.match(/^(?:bg|color|background)[=:](.+)$/i);
384 if (colorEq) {
385 out.backgroundColor = normalizeColorToken(colorEq[1]);
386 out.color = out.backgroundColor;

Callers 2

forwardPreviewFunction · 0.85
toQuoteMessageFunction · 0.85

Calls 4

fwdPeerFunction · 0.85
fwdHeaderNameFunction · 0.85
getPeerEntityFunction · 0.85
displayNameFunction · 0.85

Tested by

no test coverage detected