Fix kanban tags issues

This commit is contained in:
yflory 2025-03-07 17:53:43 +01:00
parent a070e3c344
commit cbfee93c3a
5 changed files with 14 additions and 13 deletions

View File

@ -164,7 +164,7 @@
@cp_buttons-hover: @cryptpad_color_brand_fadest;
@cp_buttons-default: @cryptpad_color_grey_700;
@cp_buttons-default-color: @cryptpad_text_col;
@cp_buttons-default-alt-color: @cryptpad_color_black;
@cp_buttons-default-alt-color: @cryptpad_color_grey_700;
@cp_buttons-default-border: @cryptpad_text_col;
@cp_buttons-red: #E55236;
@cp_buttons-red-text: @cryptpad_color_light_red;

View File

@ -164,6 +164,7 @@
@cp_buttons-default: #CCC;
@cp_buttons-default-color: @cryptpad_text_col;
@cp_buttons-default-border: @cryptpad_text_col;
@cp_buttons-default-alt-color: @cryptpad_color_grey_50;
@cp_buttons-red: #E55236;
@cp_buttons-red-text: @cp_buttons-red;
@cp_buttons-red-color: #FFF;

View File

@ -200,8 +200,8 @@
}
}
&.btn-default-alt {
border-color: @cp_toolbar-bottom-fg;
color: @cp_toolbar-bottom-fg;
border-color: @cp_buttons-default-alt-color;
color: @cp_buttons-default-alt-color;
background-color: @cp_buttons-default-color;
&:hover, &:not(:disabled):active, &:focus {
border-color: @cp_buttons-default-color;

View File

@ -454,16 +454,8 @@
}
flex-flow: column;
flex-shrink: 0;
& > * {
visibility: hidden;
}
& > span {
display: inline-block;
height: 38px;
line-height: 38px;
}
& > button {
margin-top: -38px;
}
}
button.cp-kanban-filterTags-reset {

View File

@ -933,9 +933,9 @@ define([
// Tags filter
var existing = getExistingTags(kanban.options.boards);
var list = h('div.cp-kanban-filterTags-list');
var reset = h('button.btn.btn-cancel.cp-kanban-filterTags-reset', [
var reset = h('button.btn.btn-cancel.cp-kanban-filterTags-reset.cp-kanban-toggle-tags', [
h('i.fa.fa-times'),
Messages.kanban_clearFilter
h('span', Messages.kanban_clearFilter)
]);
var hint = h('span.cp-kanban-filterTags-name', Messages.kanban_tags);
var tags = h('div.cp-kanban-filterTags', [
@ -951,8 +951,16 @@ define([
var $hint = $(hint);
var setTagFilterState = function (bool) {
//$hint.toggle(!bool);
//$reset.toggle(!!bool);
$hint.css('visibility', bool? 'hidden': 'visible');
$hint.css('height', bool ? 0 : '');
$hint.css('padding-top', bool ? 0 : '');
$hint.css('padding-bottom', bool ? 0 : '');
$reset.css('visibility', bool? 'visible': 'hidden');
$reset.css('height', !bool ? 0 : '');
$reset.css('padding-top', !bool ? 0 : '');
$reset.css('padding-bottom', !bool ? 0 : '');
};
setTagFilterState();