Browse Source

add icons to accordion panels in preferences
fix typo in pref-prefs closing panel tag

Andrew Dolgov 1 year ago
parent
commit
814e49f8f7

+ 6 - 3
classes/pref/feeds.php

@@ -1134,7 +1134,8 @@ class Pref_Feeds extends Handler_Protected {
 	function index() {
 
 		print "<div dojoType=\"dijit.layout.AccordionContainer\" region=\"center\">";
-		print "<div id=\"pref-feeds-feeds\" dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Feeds')."\">";
+		print "<div id=\"pref-feeds-feeds\" dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>rss_feed</i> ".__('Feeds')."\">";
 
 		$sth = $this->pdo->prepare("SELECT COUNT(id) AS num_errors
 			FROM ttrss_feeds WHERE last_error != '' AND owner_uid = ?");
@@ -1268,7 +1269,8 @@ class Pref_Feeds extends Handler_Protected {
 
 		print "</div>"; # feeds pane
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('OPML')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>import_export</i> ".__('OPML')."\">";
 
 		print __("Using OPML you can export and import your feeds, filters, labels and Tiny Tiny RSS settings.") .
 			__("Only main settings profile can be migrated using OPML.");
@@ -1323,7 +1325,8 @@ class Pref_Feeds extends Handler_Protected {
 
 		print "</div>"; # pane
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Published & shared articles / Generated feeds')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>share</i> ".__('Published & shared articles / Generated feeds')."\">";
 
 		print __('Published articles can be subscribed by anyone who knows the following URL:');
 

+ 9 - 4
classes/pref/prefs.php

@@ -176,7 +176,8 @@ class Pref_Prefs extends Handler_Protected {
 		$_SESSION["prefs_op_result"] = "";
 
 		print "<div dojoType=\"dijit.layout.AccordionContainer\" region=\"center\">";
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Personal data / Authentication')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>person</i> ".__('Personal data / Authentication')."\">";
 
 		print "<form dojoType=\"dijit.form.Form\" id=\"changeUserdataForm\">";
 
@@ -422,7 +423,8 @@ class Pref_Prefs extends Handler_Protected {
 
 		print "</div>"; #pane
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" selected=\"true\" title=\"".__('Preferences')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" selected=\"true\" 
+			title=\"<i class='material-icons'>settings</i> ".__('Preferences')."\">";
 
 		print "<form dojoType=\"dijit.form.Form\" id=\"changeSettingsForm\">";
 
@@ -675,7 +677,8 @@ class Pref_Prefs extends Handler_Protected {
 
 		print "</div>"; #pane
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Plugins')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>extension</i> ".__('Plugins')."\">";
 
 		print "<form dojoType=\"dijit.form.Form\" id=\"changePluginsForm\">";
 
@@ -839,14 +842,16 @@ class Pref_Prefs extends Handler_Protected {
 		print "</div>"; #pane
 
 		print "</div>"; #pane
-		print "</doiv>"; #border-container
+		print "</div>"; #border-container
 
 		print "</form>";
 
+
 		PluginHost::getInstance()->run_hooks(PluginHost::HOOK_PREFS_TAB,
 			"hook_prefs_tab", "prefPrefs");
 
 		print "</div>"; #container
+
 	}
 
 	function toggleAdvanced() {

+ 2 - 1
classes/pref/system.php

@@ -26,7 +26,8 @@ class Pref_System extends Handler_Protected {
 	function index() {
 
 		print "<div dojoType=\"dijit.layout.AccordionContainer\" region=\"center\">";
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Event Log')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>report</i> ".__('Event Log')."\">";
 
 		if (LOG_DESTINATION == "sql") {
 

+ 7 - 0
css/default.css

@@ -1437,6 +1437,13 @@ body.ttrss_prefs .dijitTree#labelTree .dijitTreeIcon,
 body.ttrss_prefs .dijitTree#filterTree .dijitTreeIcon {
   display: none;
 }
+body.ttrss_prefs .dijitAccordionTitle i.material-icons {
+  top: -1px;
+  position: relative;
+}
+body.ttrss_prefs .dijitAccordionTitleSelected i.material-icons {
+  color: white;
+}
 body.ttrss_prefs #pref-filter-wrap,
 body.ttrss_prefs #pref-filter-header,
 body.ttrss_prefs #pref-filter-content,

File diff suppressed because it is too large
+ 0 - 0
css/default.css.map


+ 9 - 0
css/prefs.less

@@ -38,6 +38,15 @@ body.ttrss_prefs {
 		display : none;
 	}
 
+	.dijitAccordionTitle i.material-icons {
+		top : -1px;
+		position : relative;
+	}
+
+	.dijitAccordionTitleSelected i.material-icons {
+		color : white;
+	}
+
 	/* div#pref-tabs .dijitContentPane {
 		font-size : 14px;
 	} */

+ 2 - 1
plugins/af_comics/init.php

@@ -46,7 +46,8 @@ class Af_Comics extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefFeeds") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Feeds supported by af_comics')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>photo</i> ".__('Feeds supported by af_comics')."\">";
 
 		print "<p>" . __("The following comics are currently supported:") . "</p>";
 

+ 2 - 1
plugins/af_psql_trgm/init.php

@@ -121,7 +121,8 @@ class Af_Psql_Trgm extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefFeeds") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Mark similar articles as read')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>extension</i> ".__('Mark similar articles as read')."\">";
 
 		if (DB_TYPE != "pgsql") {
 			print_error("Database type not supported.");

+ 2 - 1
plugins/af_readability/init.php

@@ -44,7 +44,8 @@ class Af_Readability extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefFeeds") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Readability settings (af_readability)')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>extension</i> ".__('Readability settings (af_readability)')."\">";
 
 		if (version_compare(PHP_VERSION, '5.6.0', '<')) {
 			print_error("This plugin requires PHP version 5.6.");

+ 2 - 1
plugins/af_redditimgur/init.php

@@ -27,7 +27,8 @@ class Af_RedditImgur extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefFeeds") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Reddit content settings (af_redditimgur)')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>extension</i> ".__('Reddit content settings (af_redditimgur)')."\">";
 
 		$enable_readability = $this->host->get($this, "enable_readability");
 		$enable_content_dupcheck = $this->host->get($this, "enable_content_dupcheck");

+ 2 - 1
plugins/af_zz_imgproxy/init.php

@@ -205,7 +205,8 @@ class Af_Zz_ImgProxy extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefFeeds") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Image proxy settings (af_zz_imgproxy)')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>extension</i> ".__('Image proxy settings (af_zz_imgproxy)')."\">";
 
 		print "<form dojoType=\"dijit.form.Form\">";
 

+ 2 - 1
plugins/bookmarklets/init.php

@@ -17,7 +17,8 @@ class Bookmarklets extends Plugin {
   function hook_prefs_tab($args) {
     if ($args == "prefFeeds") {
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Bookmarklets')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>bookmark</i> ".__('Bookmarklets')."\">";
 
 		print __("Drag the link below to your browser toolbar, open the feed you're interested in in your browser and click on the link to subscribe to it.");
 

+ 2 - 1
plugins/import_export/init.php

@@ -50,7 +50,8 @@ class Import_Export extends Plugin implements IHandler {
 	function hook_prefs_tab($args) {
 		if ($args != "prefFeeds") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Import and export')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>import_export</i> ".__('Import and export')."\">";
 
 		print_notice(__("You can export and import your Starred and Archived articles for safekeeping or when migrating between tt-rss instances of same version."));
 

+ 2 - 1
plugins/mail/init.php

@@ -32,7 +32,8 @@ class Mail extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefPrefs") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__('Mail plugin')."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>mail</i> ".__('Mail plugin')."\">";
 
 		print "<p>" . __("You can set predefined email addressed here (comma-separated list):") . "</p>";
 

+ 2 - 1
plugins/nsfw/init.php

@@ -49,7 +49,8 @@ class NSFW extends Plugin {
 	function hook_prefs_tab($args) {
 		if ($args != "prefPrefs") return;
 
-		print "<div dojoType=\"dijit.layout.AccordionPane\" title=\"".__("NSFW Plugin")."\">";
+		print "<div dojoType=\"dijit.layout.AccordionPane\" 
+			title=\"<i class='material-icons'>extension</i> ".__("NSFW Plugin")."\">";
 
 		print "<br/>";
 

+ 7 - 0
themes/night.css

@@ -1437,6 +1437,13 @@ body.ttrss_prefs .dijitTree#labelTree .dijitTreeIcon,
 body.ttrss_prefs .dijitTree#filterTree .dijitTreeIcon {
   display: none;
 }
+body.ttrss_prefs .dijitAccordionTitle i.material-icons {
+  top: -1px;
+  position: relative;
+}
+body.ttrss_prefs .dijitAccordionTitleSelected i.material-icons {
+  color: white;
+}
 body.ttrss_prefs #pref-filter-wrap,
 body.ttrss_prefs #pref-filter-header,
 body.ttrss_prefs #pref-filter-content,

File diff suppressed because it is too large
+ 0 - 0
themes/night.css.map


Some files were not shown because too many files changed in this diff