diff --git a/customize.dist/messages.js b/customize.dist/messages.js index fd8a5f879..46e50d8d4 100755 --- a/customize.dist/messages.js +++ b/customize.dist/messages.js @@ -157,6 +157,8 @@ define(req, function(AppConfig, Default, Language) { } }; + Messages.kanban_quickView = "Minimize card content"; // XXX + Messages.kanban_fullView = "Show card content"; return Messages; }); diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 56380a975..699891187 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -4448,6 +4448,7 @@ define([ var $color = $(h('button.cp-palette-color')); all.push($color); $color.addClass('cp-palette-'+(color || 'nocolor')); + $color.attr('aria-label', Messages['color' + i]); const checkIcon = Icons.get('check'); $(checkIcon).addClass('cp-check-icon is-hidden'); // added hidden class to overcome Lucide rendering $color.append(checkIcon); diff --git a/www/kanban/inner.js b/www/kanban/inner.js index aa86c84ae..ef25b30b1 100644 --- a/www/kanban/inner.js +++ b/www/kanban/inner.js @@ -1111,16 +1111,28 @@ define([ var $cContainer = $('#cp-app-kanban-container'); var addControls = function () { // Quick or normal mode - var small = h('button.cp-kanban-view-small', Icons.get('kanban-minimize')); - var big = h('button.cp-kanban-view', Icons.get('kanban-maximize')); + var small = h('button.cp-kanban-view-small', Icons.get('kanban-minimize'), { + 'title': Messages.kanban_quickView, + 'aria-label': Messages.kanban_quickView, + 'aria-pressed': $cContainer.hasClass('cp-kanban-quick') ? 'true' : 'false' + }); + var big = h('button.cp-kanban-view', Icons.get('kanban-maximize'), { + 'title': Messages.kanban_fullView, + 'aria-label': Messages.kanban_fullView, + 'aria-pressed': $cContainer.hasClass('cp-kanban-quick') ? 'false' : 'true' + }); $(small).click(function () { if ($cContainer.hasClass('cp-kanban-quick')) { return; } $cContainer.addClass('cp-kanban-quick'); + small.setAttribute('aria-pressed', 'true'); + big.setAttribute('aria-pressed', 'false'); //framework._.sfCommon.setPadAttribute('quickMode', true); }); $(big).click(function () { if (!$cContainer.hasClass('cp-kanban-quick')) { return; } $cContainer.removeClass('cp-kanban-quick'); + small.setAttribute('aria-pressed', 'false'); + big.setAttribute('aria-pressed', 'true'); //framework._.sfCommon.setPadAttribute('quickMode', false); });