This encoding is used to safely transport numbers in a UTF-8 string. Essentially it's a Base127 format with each character incremented by 1, producing a sequence of ASCII characters 1-127, LSB first.
Eg.
- 1 -> 02h 01h in 2B encoding.
let fs = require("fs"); | |
let myArgs = process.argv.slice(2); | |
fs.readFile(myArgs[0], "utf8", function (err, data) { | |
if (err) throw err; | |
const ar = Array.from(data); | |
let table = []; | |
ar.forEach(function(k) { | |
if (k.codePointAt(0) > 127 && table.indexOf(k)<0) { | |
let bn = encodeURIComponent(k).replace(/%[A-F\d]{2}/g, 'U').length; |
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒ | |
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ | |
││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││││ | |
wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww | |
♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥♥ | |
################################################################################ | |
iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii | |
................................................................................ | |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | |
──────────────────────────────────────────────────────────────────────────────── |
// ==UserScript== | |
// @name github network link | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description add back link to network graph on github | |
// @author MightyPork | |
// @match https://github.com/*/* | |
// @grant none | |
// ==/UserScript== |
// uQuery | |
function qsa(q){return document.querySelectorAll(q)} | |
function qs(q){return document.querySelector(q)} | |
function bind(el,evt,fn){el.addEventListener(evt,fn)} | |
function qbind(q,evt,fn){var els=qsa(q);els&&els.forEach(function(el){el.addEventListener(evt, fn)})} |
0 0000 | |
1 ☺ 263A | |
2 ☻ 263B | |
3 ♥ 2665 | |
4 ♦ 2666 | |
5 ♣ 2663 | |
6 ♠ 2660 | |
7 • 2022 | |
8 ◘ 25D8 | |
9 ○ 25CB |
0000 0 | |
263A ☺ 1 | |
263B ☻ 2 | |
2665 ♥ 3 | |
2666 ♦ 4 | |
2663 ♣ 5 | |
2660 ♠ 6 | |
2022 • 7 | |
25D8 ◘ 8 | |
25CB ○ 9 |
:grinning: | |
:grin: | |
:joy: | |
:rofl: | |
:smiley: | |
:smile: | |
:sweat_smile: | |
:laughing: | |
:wink: | |
:blush: |
Index: app/javascript/mastodon/components/media_gallery.js | |
IDEA additional info: | |
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP | |
<+>UTF-8 | |
=================================================================== | |
--- app/javascript/mastodon/components/media_gallery.js (revision f2233c3e25bd52388798e5d76311896fa8029413) | |
+++ app/javascript/mastodon/components/media_gallery.js (revision ) | |
@@ -173,6 +173,7 @@ | |
onOpenMedia: PropTypes.func.isRequired, | |
intl: PropTypes.object.isRequired, |
// ==UserScript== | |
// @name xyz instance filter | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description Adds a filtering box to the instance list. | |
// Syntax is like JS or mysql, columns are: | |
// name,up,down,score,version,users,toots,connections,open,closed,uptime | |
// | |
// @author You | |
// @match https://instances.mastodon.xyz/list |