From 4fd5ceadb24d880985de2591d7cdb7a1a13c9f60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lorenz=20H=C3=BCbschle-Schneider?= Date: Thu, 16 Oct 2014 15:50:36 +0200 Subject: [PATCH] Don't automatically show NSFW content Fixes #472 --- css/glowingbear.css | 6 ++++++ index.html | 2 +- js/plugin-directive.js | 3 ++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/css/glowingbear.css b/css/glowingbear.css index 47bb717..90d3a5a 100644 --- a/css/glowingbear.css +++ b/css/glowingbear.css @@ -535,6 +535,12 @@ li.buffer.indent.private a { padding-right: -15px; } +.settings-help { + display: block; + margin: -5px 0 -3px 19px; + font-size: small; +} + /* */ /* Mobile layout */ /* */ diff --git a/index.html b/index.html index d459bb6..f50e093 100644 --- a/index.html +++ b/index.html @@ -348,7 +348,7 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
diff --git a/js/plugin-directive.js b/js/plugin-directive.js index fca573b..fa8dabd 100644 --- a/js/plugin-directive.js +++ b/js/plugin-directive.js @@ -19,7 +19,8 @@ weechat.directive('plugin', ['$rootScope', function($rootScope) { $scope.displayedContent = ""; - $scope.plugin.visible = $rootScope.auto_display_embedded_content; + // Auto-display embedded content only if it isn't NSFW + $scope.plugin.visible = $rootScope.auto_display_embedded_content && !$scope.plugin.nsfw; // user-accessible hash key that is a valid CSS class name $scope.plugin.className = "embed_" + $scope.plugin.$$hashKey.replace(':','_');