MCPcopy Create free account
hub / github.com/Useful-Scripts-Extension/useful-script / doEncode

Function doEncode

scripts/createInvisibleText.js:51–81  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

49 }
50
51 async function doEncode() {
52 let result = await Swal.fire({
53 icon: "question",
54 title: t({ vi: "Nhập tin nhắn", en: "Enter message" }),
55 html: t({
56 vi: "Đặt ngoặc nhọn >< bao ngoài những nội dung muốn tàng hình<br/><br/> Ví dụ: Gọi tôi <b>>0123456789<</b> là Hoang.",
57 en: "Wrap text in >< to hide messages<br/><br/> Example: Call me <b>>0123456789, abc street<</b> Jane.",
58 }),
59 input: "textarea",
60 showCancelButton: true,
61 });
62 if (result.isConfirmed) {
63 let encoded = encode(result.value);
64 await Swal.fire({
65 icon: "success",
66 title: t({
67 vi: "Tạo tin tàng hình thành công",
68 en: "Create invisible message successfully",
69 }),
70 html:
71 result.value +
72 "<br/><br/>" +
73 t({
74 vi: " Bạn hãy copy và sử dụng nhé",
75 en: " Please copy and use",
76 }),
77 input: "textarea",
78 inputValue: encoded,
79 });
80 }
81 }
82
83 async function doDecode() {
84 let result = await Swal.fire({

Callers 1

Calls 2

encodeFunction · 0.85
tFunction · 0.50

Tested by

no test coverage detected