├── Source ├── abacus-16.png ├── abacus-48.png ├── abacus-128.png ├── abacus-600.png ├── manifest.json └── content_script.js ├── CREDITS.txt ├── CryptographyToMathematics.crx ├── LICENSE.txt └── README.md /Source/abacus-16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gabrielg/cryptography-to-mathematics/HEAD/Source/abacus-16.png -------------------------------------------------------------------------------- /Source/abacus-48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gabrielg/cryptography-to-mathematics/HEAD/Source/abacus-48.png -------------------------------------------------------------------------------- /Source/abacus-128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gabrielg/cryptography-to-mathematics/HEAD/Source/abacus-128.png -------------------------------------------------------------------------------- /Source/abacus-600.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gabrielg/cryptography-to-mathematics/HEAD/Source/abacus-600.png -------------------------------------------------------------------------------- /CREDITS.txt: -------------------------------------------------------------------------------- 1 | 1. Abacus icon created by anbileru adaleru from Noun Project. https://thenounproject.com/search/?q=mathematics&i=217048 -------------------------------------------------------------------------------- /CryptographyToMathematics.crx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gabrielg/cryptography-to-mathematics/HEAD/CryptographyToMathematics.crx -------------------------------------------------------------------------------- /Source/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "manifest_version": 2, 3 | "name": "Cryptography to Mathematics", 4 | "version": "1.3", 5 | "description": "Replaces the text 'cryptography' with 'mathematics'.", 6 | "icons": { 7 | "16": "abacus-16.png", 8 | "48": "abacus-48.png", 9 | "128": "abacus-128.png" 10 | }, "content_scripts": [{ 11 | "matches": ["*://*/*"], 12 | "js": ["content_script.js"], 13 | "run_at": "document_end" 14 | }] 15 | } 16 | 17 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE 2 | Version 2, December 2004 3 | 4 | Copyright (C) 2004 Sam Hocevar 5 | 6 | Everyone is permitted to copy and distribute verbatim or modified 7 | copies of this license document, and changing it is allowed as long 8 | as the name is changed. 9 | 10 | DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE 11 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 12 | 13 | 0. You just DO WHAT THE FUCK YOU WANT TO. 14 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | cryptography-to-math 2 | ============= 3 | 4 | ![](Source/abacus-128.png) 5 | 6 | Fork of the [cloud-to-butt Chrome extension](https://github.com/panicsteve/cloud-to-butt) that replaces occurrences of 'cryptography' with 'mathematics'. 7 | 8 | [Direct download of crx file](https://github.com/gabrielg/cryptography-to-mathematics/blob/master/CryptographyToMathematics.crx?raw=true) 9 | 10 | Installation 11 | ------------ 12 | 13 | In Chrome, choose Window > Extensions. Drag CryptographyToMathematics.crx into the page that appears. 14 | -------------------------------------------------------------------------------- /Source/content_script.js: -------------------------------------------------------------------------------- 1 | var replacements = [ 2 | ['Cryptography', 'Mathematics'], 3 | ['cryptography', 'mathematics'], 4 | ['Crypto', 'Math'], 5 | ['crypto', 'math'], 6 | ['Encryption', 'Use of math'], 7 | ['encryption', 'use of math'], 8 | ['Encrypted', 'Mathed'], 9 | ['encrypted', 'mathed'], 10 | ['Cryptographer', 'Math-Liker'], 11 | ['cryptographer', 'math-liker'], 12 | ]; 13 | 14 | for (i = 0; i < replacements.length; i++) { 15 | replacements[i][0] = new RegExp('\\b' + replacements[i][0] + '\\b', 'g'); 16 | } 17 | 18 | function walk(node) 19 | { 20 | // I stole this function from here: 21 | // http://is.gd/mwZp7E 22 | 23 | var child, next; 24 | 25 | switch (node.nodeType) 26 | { 27 | case 1: // Element 28 | case 9: // Document 29 | case 11: // Document fragment 30 | child = node.firstChild; 31 | while (child) 32 | { 33 | next = child.nextSibling; 34 | walk(child); 35 | child = next; 36 | } 37 | break; 38 | 39 | case 3: // Text node 40 | handleText(node); 41 | break; 42 | } 43 | } 44 | 45 | function handleText(textNode) 46 | { 47 | var v = textNode.nodeValue; 48 | 49 | for (i = 0; i < replacements.length; i++) { 50 | v = v.replace(replacements[i][0], replacements[i][1]); 51 | } 52 | 53 | textNode.nodeValue = v; 54 | } 55 | 56 | walk(document.body); 57 | --------------------------------------------------------------------------------