Procházet zdrojové kódy

Change category configuration (#2410)

* Change category configuration

Before, we had a drop-down list to interract on categories. It was not
working the same way as feeds.
Now, categories and feeds behave in a similar manner. At the moment,
there is no change in features but it will allow to expand them.

See #2369

* Minor whitespace
Alexis Degrugillier před 6 roky
rodič
revize
2decc82c3e

+ 43 - 3
app/Controllers/subscriptionController.php

@@ -35,9 +35,20 @@ class FreshRSS_subscription_Controller extends Minz_ActionController {
 		$this->view->onlyFeedsWithError = Minz_Request::paramTernary('error');
 
 		$id = Minz_Request::param('id');
-		if ($id !== false) {
-			$feedDAO = FreshRSS_Factory::createFeedDao();
-			$this->view->feed = $feedDAO->searchById($id);
+		$this->view->displaySlider = false;
+		if (false !== $id) {
+			$type = Minz_Request::param('type');
+			$this->view->displaySlider = true;
+			switch ($type) {
+				case 'category':
+					$categoryDAO = FreshRSS_Factory::createCategoryDao();
+					$this->view->category = $categoryDAO->searchById($id);
+					break;
+				default:
+					$feedDAO = FreshRSS_Factory::createFeedDao();
+					$this->view->feed = $feedDAO->searchById($id);
+					break;
+			}
 		}
 	}
 
@@ -140,6 +151,35 @@ class FreshRSS_subscription_Controller extends Minz_ActionController {
 		}
 	}
 
+	public function categoryAction() {
+		$this->view->_useLayout(false);
+
+		$categoryDAO = FreshRSS_Factory::createCategoryDao();
+
+		$id = Minz_Request::param('id');
+		$category = $categoryDAO->searchById($id);
+		if ($id === false || null === $category) {
+			Minz_Error::error(404);
+			return;
+		}
+		$this->view->category = $category;
+
+		if (Minz_Request::isPost()) {
+			$values = array(
+				'name' => Minz_Request::param('name', ''),
+			);
+
+			invalidateHttpCache();
+
+			$url_redirect = array('c' => 'subscription', 'params' => array('id' => $id, 'type' => 'category'));
+			if (false !== $categoryDAO->updateCategory($id, $values)) {
+				Minz_Request::good(_t('feedback.sub.category.updated'), $url_redirect);
+			} else {
+				Minz_Request::bad(_t('feedback.sub.category.error'), $url_redirect);
+			}
+		}
+	}
+
 	/**
 	 * This action displays the bookmarklet page.
 	 */

+ 7 - 0
app/Models/Category.php

@@ -7,6 +7,7 @@ class FreshRSS_Category extends Minz_Model {
 	private $nbNotRead = -1;
 	private $feeds = null;
 	private $hasFeedsWithError = false;
+	private $isDefault = false;
 
 	public function __construct($name = '', $feeds = null) {
 		$this->_name($name);
@@ -28,6 +29,9 @@ class FreshRSS_Category extends Minz_Model {
 	public function name() {
 		return $this->name;
 	}
+	public function isDefault() {
+		return $this->isDefault;
+	}
 	public function nbFeed() {
 		if ($this->nbFeed < 0) {
 			$catDAO = FreshRSS_Factory::createCategoryDao();
@@ -70,6 +74,9 @@ class FreshRSS_Category extends Minz_Model {
 	public function _name($value) {
 		$this->name = trim($value);
 	}
+	public function _isDefault($value) {
+		$this->isDefault = $value;
+	}
 	public function _feeds($values) {
 		if (!is_array($values)) {
 			$values = array($values);

+ 1 - 0
app/Models/CategoryDAO.php

@@ -282,6 +282,7 @@ class FreshRSS_CategoryDAO extends Minz_ModelPdo implements FreshRSS_Searchable
 				$dao['name']
 			);
 			$cat->_id($dao['id']);
+			$cat->_isDefault(static::DEFAULTCATEGORYID === intval($dao['id']));
 			$list[$key] = $cat;
 		}
 

+ 3 - 1
app/i18n/cz/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Kategorie',
 		'add' => 'Přidat kategorii',
 		'empty' => 'Vyprázdit kategorii',
+		'information' => 'Informace',
 		'new' => 'Nová kategorie',
+		'title' => 'Název',
 	),
 	'feed' => array(
 		'add' => 'Přidat RSS kanál',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Informace',
+		'information' => 'Informace',
 		'keep_history' => 'Zachovat tento minimální počet článků',
 		'moved_category_deleted' => 'Po smazání kategorie budou v ní obsažené kanály automaticky přesunuty do <em>%s</em>.',
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/de/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Kategorie',
 		'add' => 'Eine Kategorie hinzufügen',
 		'empty' => 'Leere Kategorie',
+		'information' => 'Information',
 		'new' => 'Neue Kategorie',
+		'title' => 'Titel',
 	),
 	'feed' => array(
 		'add' => 'Einen RSS-Feed hinzufügen',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Information',
+		'information' => 'Information',
 		'keep_history' => 'Minimale Anzahl an Artikeln, die behalten wird',
 		'moved_category_deleted' => 'Wenn Sie eine Kategorie entfernen, werden deren Feeds automatisch in die Kategorie <em>%s</em> eingefügt.',
 		'mute' => 'Stumm schalten',

+ 3 - 1
app/i18n/en/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Category',
 		'add' => 'Add a category',
 		'empty' => 'Empty category',
+		'information' => 'Information',
 		'new' => 'New category',
+		'title' => 'Title',
 	),
 	'feed' => array(
 		'add' => 'Add a RSS feed',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',
 			'help' => 'Write one search filter per line.',
 		),
-		'informations' => 'Information',
+		'information' => 'Information',
 		'keep_history' => 'Minimum number of articles to keep',
 		'moved_category_deleted' => 'When you delete a category, its feeds are automatically classified under <em>%s</em>.',
 		'mute' => 'mute',

+ 3 - 1
app/i18n/es/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Categoría',
 		'add' => 'Añadir a la categoría',
 		'empty' => 'Vaciar categoría',
+		'information' => 'Información',
 		'new' => 'Nueva categoría',
+		'title' => 'Título',
 	),
 	'feed' => array(
 		'add' => 'Añadir fuente RSS',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Información',
+		'information' => 'Información',
 		'keep_history' => 'Número mínimo de artículos a conservar',
 		'moved_category_deleted' => 'Al borrar una categoría todas sus fuentes pasan automáticamente a la categoría <em>%s</em>.',
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/fr/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Catégorie',
 		'add' => 'Ajouter une catégorie',
 		'empty' => 'Catégorie vide',
+		'information' => 'Informations',
 		'new' => 'Nouvelle catégorie',
+		'title' => 'Titre',
 	),
 	'feed' => array(
 		'add' => 'Ajouter un flux RSS',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filtres d’action',
 			'help' => 'Écrivez une recherche par ligne.',
 		),
-		'informations' => 'Informations',
+		'information' => 'Informations',
 		'keep_history' => 'Nombre minimum d’articles à conserver',
 		'moved_category_deleted' => 'Lors de la suppression d’une catégorie, ses flux seront automatiquement classés dans <em>%s</em>.',
 		'mute' => 'muet',

+ 3 - 1
app/i18n/he/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'קטגוריה',
 		'add' => 'הוספת קטגוריה',
 		'empty' => 'Empty category',	//TODO - Translation
+		'information' => 'מידע',
 		'new' => 'קטגוריה חדשה',
+		'title' => 'כותרת',
 	),
 	'feed' => array(
 		'add' => 'הוספת הזנה',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'מידע',
+		'information' => 'מידע',
 		'keep_history' => 'מסםר מינימלי של מאמרים לשמור',
 		'moved_category_deleted' => 'כאשר הקטגוריה נמחקת ההזנות שבתוכה אוטומטית מקוטלגות תחת  <em>%s</em>.',
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/it/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Categoria',
 		'add' => 'Aggiungi una categoria',
 		'empty' => 'Categoria vuota',
+		'information' => 'Informazioni',
 		'new' => 'Nuova categoria',
+		'title' => 'Titolo',
 	),
 	'feed' => array(
 		'add' => 'Aggiungi un Feed RSS',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Informazioni',
+		'information' => 'Informazioni',
 		'keep_history' => 'Numero minimo di articoli da mantenere',
 		'moved_category_deleted' => 'Cancellando una categoria i feed al suo interno verranno classificati automaticamente come <em>%s</em>.',
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/kr/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => '카테고리',
 		'add' => '카테고리 추가',
 		'empty' => '빈 카테고리',
+		'information' => '정보',
 		'new' => '새 카테고리',
+		'title' => '제목',
 	),
 	'feed' => array(
 		'add' => 'RSS 피드 추가',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => '정보',
+		'information' => '정보',
 		'keep_history' => '최소 유지 글 개수',
 		'moved_category_deleted' => '카테고리를 삭제하면, 해당 카테고리 아래에 있던 피드들은 자동적으로 <em>%s</em> 아래로 분류됩니다.',
 		'mute' => '무기한 새로고침 금지',

+ 3 - 1
app/i18n/nl/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Categorie',
 		'add' => 'Voeg categorie toe',
 		'empty' => 'Lege categorie',
+		'information' => 'Informatie',
 		'new' => 'Nieuwe categorie',
+		'title' => 'Titel',
 	),
 	'feed' => array(
 		'add' => 'Voeg een RSS feed toe',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Informatie',
+		'information' => 'Informatie',
 		'keep_history' => 'Minimum aantal artikelen om te houden',
 		'moved_category_deleted' => 'Als u een categorie verwijderd, worden de feeds automatisch geclassificeerd onder <em>%s</em>.',
 		'mute' => 'demp',

+ 3 - 1
app/i18n/oc/sub.php

@@ -13,7 +13,9 @@ return array(
 		'_' => 'Categoria',
 		'add' => 'Ajustar una categoria',
 		'empty' => 'Categoria voida',
+		'information' => 'Informacions',
 		'new' => 'Nòva categoria',
+		'title' => 'Títol',
 	),
 	'feed' => array(
 		'add' => 'Ajustar un flux RSS',
@@ -36,7 +38,7 @@ return array(
 			'_' => 'Filtre d’accion',
 			'help' => 'Escrivètz una recèrca per linha.',
 		),
-		'informations' => 'Informacions',
+		'information' => 'Informacions',
 		'keep_history' => 'Nombre minimum d’articles de servar',
 		'moved_category_deleted' => 'Quand escafatz una categoria, sos fluxes son automaticament classats dins <em>%s</em>.',
 		'mute' => 'mut',

+ 3 - 1
app/i18n/pt-br/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Categoria',
 		'add' => 'Adicionar uma categoria',
 		'empty' => 'Categoria vazia',
+		'information' => 'Informações',
 		'new' => 'Nova categoria',
+		'title' => 'Título',
 	),
 	'feed' => array(
 		'add' => 'Adicionar um RSS feed',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Informações',
+		'information' => 'Informações',
 		'keep_history' => 'Número mínimo de artigos para manter',
 		'moved_category_deleted' => 'Quando você deleta uma categoria, seus feeds são automaticamente classificados como <em>%s</em>.',
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/ru/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Category',	//TODO - Translation
 		'add' => 'Add a category',	//TODO - Translation
 		'empty' => 'Empty category',	//TODO - Translation
+		'information' => 'Information',	//TODO - Translation
 		'new' => 'New category',	//TODO - Translation
+		'title' => 'Title',	//TODO - Translation
 	),
 	'feed' => array(
 		'add' => 'Add a RSS feed',	//TODO - Translation
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Information',	//TODO - Translation
+		'information' => 'Information',	//TODO - Translation
 		'keep_history' => 'Minimum number of articles to keep',	//TODO - Translation
 		'moved_category_deleted' => 'When you delete a category, its feeds are automatically classified under <em>%s</em>.',	//TODO - Translation
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/tr/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => 'Kategori',
 		'add' => 'Kategori ekle',
 		'empty' => 'Boş kategori',
+		'information' => 'Bilgi',
 		'new' => 'Yeni kategori',
+		'title' => 'Başlık',
 	),
 	'feed' => array(
 		'add' => 'RSS akışı ekle',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => 'Bilgi',
+		'information' => 'Bilgi',
 		'keep_history' => 'En az tutulacak makale sayısı',
 		'moved_category_deleted' => 'Bir kategoriyi silerseniz, içerisindeki akışlar <em>%s</em> içerisine yerleşir.',
 		'mute' => 'mute',	//TODO - Translation

+ 3 - 1
app/i18n/zh-cn/sub.php

@@ -14,7 +14,9 @@ return array(
 		'_' => '分类',
 		'add' => '添加分类',
 		'empty' => '空分类',
+		'information' => '信息',
 		'new' => '新分类',
+		'title' => '标题',
 	),
 	'feed' => array(
 		'add' => '添加 RSS 源',
@@ -37,7 +39,7 @@ return array(
 			'_' => 'Filter actions',	//TODO - Translation
 			'help' => 'Write one search filter per line.',	//TODO - Translation
 		),
-		'informations' => '信息',
+		'information' => '信息',
 		'keep_history' => '至少保存的文章数',
 		'moved_category_deleted' => '删除分类时,其中的 RSS 源会自动归类到 <em>%s</em>',
 		'mute' => '暂停',

+ 1 - 1
app/views/feed/add.phtml

@@ -8,7 +8,7 @@
 
 	<form method="post" action="<?php echo _url('feed', 'add'); ?>" autocomplete="off">
 		<input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
-		<legend><?php echo _t('sub.feed.informations'); ?></legend>
+		<legend><?php echo _t('sub.feed.information'); ?></legend>
 		<?php if ($this->load_ok) { ?>
 		<div class="form-group">
 			<label class="group-name"><?php echo _t('sub.feed.title'); ?></label>

+ 34 - 0
app/views/helpers/category/update.phtml

@@ -0,0 +1,34 @@
+<div class="post">
+	<h1><?php echo $this->category->name(); ?></h1>
+
+	<div>
+		<a href="<?php echo _url('index', 'index', 'get', 'c_' . $this->category->id()); ?>"><?php echo _i('link'); ?> <?php echo _t('gen.action.filter'); ?></a>
+	</div>
+
+	<form method="post" action="<?php echo _url('subscription', 'category', 'id', $this->category->id()); ?>" autocomplete="off">
+		<input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
+		<legend><?php echo _t('sub.category.information'); ?></legend>
+		<div class="form-group">
+			<label class="group-name" for="name"><?php echo _t('sub.category.title'); ?></label>
+			<div class="group-controls">
+				<input type="text" name="name" id="name" class="extend" value="<?php echo $this->category->name() ; ?>" />
+			</div>
+		</div>
+
+		<div class="form-group form-actions">
+			<div class="group-controls">
+				<button class="btn btn-important"><?php echo _t('gen.action.submit'); ?></button>
+				<button class="btn btn-attention confirm"
+					data-str-confirm="<?php echo _t('gen.js.confirm_action_feed_cat'); ?>"
+					formaction="<?php echo _url('category', 'empty', 'id', $this->category->id()); ?>"
+					formmethod="post"><?php echo _t('gen.action.empty'); ?></button>
+				<?php if (!$this->category->isDefault()): ?>
+				<button class="btn btn-attention confirm"
+					data-str-confirm="<?php echo _t('gen.js.confirm_action_feed_cat'); ?>"
+					formaction="<?php echo _url('category', 'delete', 'id', $this->category->id()); ?>"
+					formmethod="post"><?php echo _t('gen.action.remove'); ?></button>
+				<?php endif;?>
+			</div>
+		</div>
+	</form>
+</div>

+ 1 - 1
app/views/helpers/feed/update.phtml

@@ -19,7 +19,7 @@
 
 	<form method="post" action="<?php echo _url('subscription', 'feed', 'id', $this->feed->id()); ?>" autocomplete="off">
 		<input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
-		<legend><?php echo _t('sub.feed.informations'); ?></legend>
+		<legend><?php echo _t('sub.feed.information'); ?></legend>
 		<div class="form-group">
 			<label class="group-name" for="name"><?php echo _t('sub.feed.title'); ?></label>
 			<div class="group-controls">

+ 5 - 0
app/views/subscription/category.phtml

@@ -0,0 +1,5 @@
+<?php
+
+if ($this->category) {
+	$this->renderHelper('category/update');
+}

+ 5 - 44
app/views/subscription/index.phtml

@@ -80,50 +80,9 @@
 	?>
 	<div class="box">
 		<div class="box-title">
-			<form action="<?php echo _url('category', 'update', 'id', $cat->id()); ?>" method="post">
-				<input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
-				<input type="text" name="name" value="<?php echo $cat->name(); ?>" />
-
-				<div class="dropdown">
-					<div id="dropdown-cat-<?php echo $cat->id(); ?>" class="dropdown-target"></div>
-
-					<a class="dropdown-toggle btn" href="#dropdown-cat-<?php echo $cat->id(); ?>"><?php echo _i('down'); ?></a>
-					<ul class="dropdown-menu">
-						<li class="dropdown-close"><a href="#close">❌</a></li>
-
-						<li class="item"><a href="<?php echo _url('index', 'index', 'get', 'c_' . $cat->id()); ?>"><?php echo _t('gen.action.filter'); ?></a></li>
-
-						<?php
-							$no_feed = empty($feeds);
-							$is_default = ($cat->id() === $this->default_category->id());
-
-							if (!$no_feed || !$is_default) {
-						?>
-						<li class="separator"></li>
-						<?php } if (!$no_feed) { ?>
-						<li class="item">
-							<button class="as-link confirm"
-							        data-str-confirm="<?php echo _t('gen.js.confirm_action_feed_cat'); ?>"
-							        type="submit"
-							        form="controller-category"
-							        formaction="<?php echo _url('category', 'empty', 'id', $cat->id()); ?>">
-							        <?php echo _t('gen.action.empty'); ?></button>
-						</li>
-						<?php } if (!$is_default) { ?>
-						<li class="item">
-							<button class="as-link confirm"
-							        data-str-confirm="<?php echo _t('gen.js.confirm_action_feed_cat'); ?>"
-							        type="submit"
-							        form="controller-category"
-							        formaction="<?php echo _url('category', 'delete', 'id', $cat->id()); ?>">
-							        <?php echo _t('gen.action.remove'); ?></button>
-						</li>
-						<?php } ?>
-					</ul>
-				</div>
-			</form>
+			<a class="configure open-slider" href="<?php echo _url('subscription', 'category', 'id', $cat->id()); ?>"><?php echo _i('configure'); ?></a>
+			<?php echo $cat->name(); ?>
 		</div>
-
 		<ul class="box-content" data-cat-id="<?php echo $cat->id(); ?>">
 			<?php if (!empty($feeds)) { ?>
 			<?php
@@ -159,12 +118,14 @@
 	</ul>
 </div>
 
-<?php $class = isset($this->feed) ? ' class="active"' : ''; ?>
+<?php $class = $this->displaySlider ? ' class="active"' : ''; ?>
 <a href="#" id="close-slider"<?php echo $class; ?>></a>
 <div id="slider"<?php echo $class; ?>>
 <?php
 	if (isset($this->feed)) {
 		$this->renderHelper('feed/update');
+	} elseif (isset($this->category)) {
+		$this->renderHelper('category/update');
 	}
 ?>
 </div>

+ 29 - 1
p/themes/Ansum/_components.scss

@@ -211,12 +211,40 @@
 
     .box-title {
 	margin: 0;
-	padding: 5px 10px;
+	padding: 0.5rem 0.75rem;
 	background: $grey-light;
 	color: $main-font-color;
 	// border-bottom: 1px solid #ddd;
 	border-radius: 2px 2px 0 0;
 
+	img{
+		margin-right: 0.75rem;
+	}
+
+	&:hover{
+		.configure {
+			visibility: visible;
+			background: url("icons/cog.svg") no-repeat 4px 4px;
+			width: 1.75rem;
+			height: 1.75rem;
+			display: block;
+			border-radius: 2px;
+			float: left;
+			margin-right: 0.5rem;
+			.icon {
+				vertical-align: middle;
+				border-radius: 3px;
+				display: none;
+			}
+			&:hover {
+				background: url("icons/cog-white.svg") no-repeat 4px 4px $main-first;
+			}
+		}
+	}
+	.configure {
+		visibility: hidden;
+	}
+
 	form{
 	    input{
 		width: 85%;

+ 20 - 1
p/themes/Ansum/ansum.css

@@ -339,10 +339,29 @@ form th {
   box-shadow: 0px 2px 2px 0px rgba(0, 0, 0, 0.25); }
   .box .box-title {
     margin: 0;
-    padding: 5px 10px;
+    padding: 0.5rem 0.75rem;
     background: #f5f0ec;
     color: #363330;
     border-radius: 2px 2px 0 0; }
+    .box .box-title img {
+      margin-right: 0.75rem; }
+    .box .box-title:hover .configure {
+      visibility: visible;
+      background: url("icons/cog.svg") no-repeat 4px 4px;
+      width: 1.75rem;
+      height: 1.75rem;
+      display: block;
+      border-radius: 2px;
+      float: left;
+      margin-right: 0.5rem; }
+      .box .box-title:hover .configure .icon {
+        vertical-align: middle;
+        border-radius: 3px;
+        display: none; }
+      .box .box-title:hover .configure:hover {
+        background: url("icons/cog-white.svg") no-repeat 4px 4px #ca7227; }
+    .box .box-title .configure {
+      visibility: hidden; }
     .box .box-title form input {
       width: 85%; }
     .box .box-title form .dropdown {

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 0
p/themes/Ansum/ansum.css.map


+ 2 - 0
p/themes/BlueLagoon/BlueLagoon.css

@@ -503,9 +503,11 @@ a.btn {
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 2 - 0
p/themes/Dark/dark.css

@@ -453,9 +453,11 @@ a.btn {
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 2 - 0
p/themes/Flat/flat.css

@@ -455,6 +455,7 @@ a.btn {
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
@@ -463,6 +464,7 @@ a.btn {
 	background-color: #95a5a6;
 	border-radius: 3px;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 27 - 0
p/themes/Mapco/_components.scss

@@ -216,6 +216,33 @@
 	color: $main-font-color;
 	// border-bottom: 1px solid #ddd;
 	border-radius: 2px 2px 0 0;
+	img{
+		margin-right: 0.75rem;
+	}
+
+	&:hover{
+		.configure {
+			visibility: visible;
+			background: url("icons/cog.svg") no-repeat 4px 4px;
+			width: 1.75rem;
+			height: 1.75rem;
+			display: block;
+			border-radius: 2px;
+			float: left;
+			margin-right: 0.5rem;
+			.icon {
+				vertical-align: middle;
+				border-radius: 3px;
+				display: none;
+			}
+			&:hover {
+				background: url("icons/cog-white.svg") no-repeat 4px 4px $main-first;
+			}
+		}
+	}
+	.configure {
+		visibility: hidden;
+	}
 
 	form{
 	    input{

+ 19 - 0
p/themes/Mapco/mapco.css

@@ -345,6 +345,25 @@ form th {
     background: #eff0f2;
     color: #303136;
     border-radius: 2px 2px 0 0; }
+    .box .box-title img {
+      margin-right: 0.75rem; }
+    .box .box-title:hover .configure {
+      visibility: visible;
+      background: url("icons/cog.svg") no-repeat 4px 4px;
+      width: 1.75rem;
+      height: 1.75rem;
+      display: block;
+      border-radius: 2px;
+      float: left;
+      margin-right: 0.5rem; }
+      .box .box-title:hover .configure .icon {
+        vertical-align: middle;
+        border-radius: 3px;
+        display: none; }
+      .box .box-title:hover .configure:hover {
+        background: url("icons/cog-white.svg") no-repeat 4px 4px #3366cc; }
+    .box .box-title .configure {
+      visibility: hidden; }
     .box .box-title form input {
       width: 85%; }
     .box .box-title form .dropdown {

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 0
p/themes/Mapco/mapco.css.map


+ 2 - 0
p/themes/Origine-compact/origine-compact.css

@@ -484,9 +484,11 @@ a.btn,
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 2 - 0
p/themes/Origine/origine.css

@@ -482,9 +482,11 @@ a.btn {
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 2 - 0
p/themes/Pafat/pafat.css

@@ -456,9 +456,11 @@ a.btn {
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 2 - 0
p/themes/Screwdriver/screwdriver.css

@@ -503,9 +503,11 @@ a.btn {
 	line-height: 2.5em;
 }
 
+.box .box-title .configure,
 .box .box-content .item .configure {
 	visibility: hidden;
 }
+.box .box-title:hover .configure,
 .box .box-content .item:hover .configure {
 	visibility: visible;
 }

+ 0 - 4
p/themes/base-theme/template.css

@@ -344,10 +344,6 @@ a.btn {
 	position: relative;
 	font-size: 1.2rem;
 	font-weight: bold;
-	text-align: center;
-}
-.box .box-title a {
-	display: block;
 }
 .box .box-title form {
 	margin: 0;

Některé soubory nejsou zobrazeny, neboť je v těchto rozdílových datech změněno mnoho souborů