From 2557f86ace5751cea86a77bb32c312d0a8ecc70e Mon Sep 17 00:00:00 2001 From: ccd0 Date: Sat, 23 Aug 2014 10:36:05 -0700 Subject: [PATCH] remove Emoji --- src/General/Config.coffee | 8 ---- src/General/Main.coffee | 1 - src/General/Settings.coffee | 7 +-- src/General/html/Settings/Advanced.html | 19 -------- src/Miscellaneous/Emoji.coffee | 60 ------------------------- 5 files changed, 2 insertions(+), 93 deletions(-) delete mode 100755 src/Miscellaneous/Emoji.coffee diff --git a/src/General/Config.coffee b/src/General/Config.coffee index c734364d9..b513d7f85 100755 --- a/src/General/Config.coffee +++ b/src/General/Config.coffee @@ -81,10 +81,6 @@ Config = true 'Show notifications when 4chan X is successfully updated.' ] - 'Emoji': [ - false - 'Adds icons next to names for different emails' - ] 'Color User IDs': [ false 'Assign unique colors to user IDs on boards that use them' @@ -559,10 +555,6 @@ http://iqdb.org/?url=%TURL fappe: false werk: false - 'sageEmoji': '4chan SS' - - 'emojiPos': 'before' - 'Custom CSS': false Index: diff --git a/src/General/Main.coffee b/src/General/Main.coffee index 05893be36..165318bed 100755 --- a/src/General/Main.coffee +++ b/src/General/Main.coffee @@ -284,7 +284,6 @@ Main = ['Index Generator', Index] ['Announcement Hiding', PSAHiding] ['Fourchan thingies', Fourchan] - ['Emoji', Emoji] ['Color User IDs', IDColor] ['Custom CSS', CustomCSS] ['Linkify', Linkify] diff --git a/src/General/Settings.coffee b/src/General/Settings.coffee index 77fed7a87..b34b906c7 100755 --- a/src/General/Settings.coffee +++ b/src/General/Settings.coffee @@ -281,11 +281,11 @@ Settings = items = {} inputs = {} - for name in ['boardnav', 'time', 'backlink', 'fileInfo', 'favicon', 'sageEmoji', 'emojiPos', 'usercss'] + for name in ['boardnav', 'time', 'backlink', 'fileInfo', 'favicon', 'usercss'] input = $ "[name=#{name}]", section items[name] = Conf[name] inputs[name] = input - event = if name in ['favicon', 'usercss', 'sageEmoji', 'emojiPos'] + event = if name in ['favicon', 'usercss'] 'change' else 'input' @@ -299,7 +299,6 @@ Settings = $.get items, (items) -> for key, val of items - continue if key is 'emojiPos' input = inputs[key] input.value = val continue if key is 'usercss' @@ -428,8 +427,6 @@ Settings = img[1].src = Favicon.unreadSFW img[2].src = Favicon.unreadNSFW img[3].src = Favicon.unreadDead - sageEmoji: -> - @nextElementSibling.firstElementChild.src = "data:image/png;base64,#{Emoji.sage[@value]}" togglecss: -> if $('textarea[name=usercss]', $.x 'ancestor::fieldset[1]', @).disabled = !@checked CustomCSS.rmStyle() diff --git a/src/General/html/Settings/Advanced.html b/src/General/html/Settings/Advanced.html index 9075d1344..00c79fcf5 100755 --- a/src/General/html/Settings/Advanced.html +++ b/src/General/html/Settings/Advanced.html @@ -100,25 +100,6 @@ -
- Emoji is disabled. -
- Sage Icon: - - - -
-
- Position: -
-
-
Thread Updater is disabled.
diff --git a/src/Miscellaneous/Emoji.coffee b/src/Miscellaneous/Emoji.coffee deleted file mode 100755 index ba6177c4d..000000000 --- a/src/Miscellaneous/Emoji.coffee +++ /dev/null @@ -1,60 +0,0 @@ -Emoji = - init: -> - return unless Conf['Emoji'] - - pos = Conf['emojiPos'] - css = [""" -a.useremail[href]:last-of-type::#{pos} { - vertical-align: top; - margin-#{if pos is "before" then "right" else "left"}: 5px; -}\n - """] - - @icons["PlanNine"] = Emoji.icons["Plan9"] - @icons['Sage'] = Emoji.sage[Conf['sageEmoji']] - - for name, icon of @icons - continue unless @icons.hasOwnProperty name - css.push """ -a.useremail[href*='#{name}']:last-of-type::#{pos}, -a.useremail[href*='#{name.toLowerCase()}']:last-of-type::#{pos}, -a.useremail[href*='#{name.toUpperCase()}']:last-of-type::#{pos} { - content: url('data:image/png;base64,#{icon}'); -}\n -""" - - $.addStyle css.join(""), 'emoji' - - sage: - '4chan SS': '<%= grunt.file.read("src/General/img/emoji/SS-sage.png", {encoding: "base64"}) %>' - 'appchan': '<%= grunt.file.read("src/General/img/emoji/appchan-sage.png", {encoding: "base64"}) %>' - - icons: - 'Plan9': '<%= grunt.file.read("src/General/img/emoji/plan9.png", {encoding: "base64"}) %>' - 'Neko': '<%= grunt.file.read("src/General/img/emoji/neko.png", {encoding: "base64"}) %>' - 'Madotsuki': '<%= grunt.file.read("src/General/img/emoji/madotsuki.png", {encoding: "base64"}) %>' - 'Sega': '<%= grunt.file.read("src/General/img/emoji/sega.png", {encoding: "base64"}) %>' - 'Sakamoto': '<%= grunt.file.read("src/General/img/emoji/sakamoto.png", {encoding: "base64"}) %>' - 'Baka': '<%= grunt.file.read("src/General/img/emoji/baka.png", {encoding: "base64"}) %>' - 'Ponyo': '<%= grunt.file.read("src/General/img/emoji/ponyo.png", {encoding: "base64"}) %>' - 'Rabite': '<%= grunt.file.read("src/General/img/emoji/rabite.png", {encoding: "base64"}) %>' - 'Arch': '<%= grunt.file.read("src/General/img/emoji/arch.png", {encoding: "base64"}) %>' - 'CentOS': '<%= grunt.file.read("src/General/img/emoji/centos.png", {encoding: "base64"}) %>' - 'Debian': '<%= grunt.file.read("src/General/img/emoji/debian.png", {encoding: "base64"}) %>' - 'Elementary': '<%= grunt.file.read("src/General/img/emoji/elementary.png", {encoding: "base64"}) %>' - 'Fedora': '<%= grunt.file.read("src/General/img/emoji/fedora.png", {encoding: "base64"}) %>' - 'FreeBSD': '<%= grunt.file.read("src/General/img/emoji/freebsd.png", {encoding: "base64"}) %>' - 'Gentoo': '<%= grunt.file.read("src/General/img/emoji/gentoo.png", {encoding: "base64"}) %>' - 'Mint': '<%= grunt.file.read("src/General/img/emoji/mint.png", {encoding: "base64"}) %>' - 'OpenSUSE': '<%= grunt.file.read("src/General/img/emoji/opensuse.png", {encoding: "base64"}) %>' - 'Osx': '<%= grunt.file.read("src/General/img/emoji/osx.png", {encoding: "base64"}) %>' - 'Rhel': '<%= grunt.file.read("src/General/img/emoji/rhel.png", {encoding: "base64"}) %>' - 'Sabayon': '<%= grunt.file.read("src/General/img/emoji/sabayon.png", {encoding: "base64"}) %>' - 'Slackware': '<%= grunt.file.read("src/General/img/emoji/slackware.png", {encoding: "base64"}) %>' - 'Trisquel': '<%= grunt.file.read("src/General/img/emoji/trisquel.png", {encoding: "base64"}) %>' - 'Ubuntu': '<%= grunt.file.read("src/General/img/emoji/ubuntu.png", {encoding: "base64"}) %>' - 'Windows': '<%= grunt.file.read("src/General/img/emoji/windows.png", {encoding: "base64"}) %>' - 'OpenBSD': '<%= grunt.file.read("src/General/img/emoji/openbsd.png", {encoding: "base64"}) %>' - 'Gnu': '<%= grunt.file.read("src/General/img/emoji/gnu.png", {encoding: "base64"}) %>' - 'CrunchBang': '<%= grunt.file.read("src/General/img/emoji/crunchbang.png", {encoding: "base64"}) %>' - 'Yuno': '<%= grunt.file.read("src/General/img/emoji/yuno.png", {encoding: "base64"}) %>'