Skip to content

Commit

Permalink
Show changed wiplimit immediately
Browse files Browse the repository at this point in the history
  • Loading branch information
sh-csg committed Dec 5, 2024
1 parent 77e60ac commit f106f17
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion amd/build/column.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion amd/build/column.min.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion amd/build/selectors.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion amd/build/selectors.min.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions amd/src/column.js
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,7 @@ export default class extends KanbanComponent {
let options = JSON.parse(element.options);
this.toggleClass(options.autohide, 'mod_kanban_autohide');
this.toggleClass(options.wiplimit > 0, 'mod_kanban_wiplimit');
this.getElement(selectors.WIPNUMBER).innerHTML = options.wiplimit;
}
this.getElement(selectors.CARDCOUNT).innerHTML = this.getElements(selectors.CARD).length;
// Enable/disable dragging (e.g. if column is locked).
Expand Down
1 change: 1 addition & 0 deletions amd/src/selectors.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,5 @@ export default {
UNCOMPLETE: `[data-action="uncomplete_card"]`,
UNLOCKCOLUMN: `[data-action="unlock_column"]`,
UNLOCKBOARDCOLUMNS: `[data-action="unlock_board_columns"]`,
WIPNUMBER: `.mod_kanban_wipnumber`,
};
2 changes: 1 addition & 1 deletion styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ a.mod_kanban_attachment_item {
.mod_kanban_column.mod_kanban_autohide.mod_kanban_show_hidden [data-action="show_hidden"],
.mod_kanban_column:not(.mod_kanban_autohide) .mod_kanban_hidden_actions,
.mod_kanban_column.mod_kanban_autohide:not(.mod_kanban_show_hidden) .mod_kanban_card.mod_kanban_closed,
.mod_kanban_column:not(.mod_kanban_column_wiplimit) .mod_kanban_wipinfo,
.mod_kanban_column:not(.mod_kanban_wiplimit) .mod_kanban_wipinfo,
.mod_kanban_card.mod_kanban_closed .mod_kanban_complete_card,
.mod_kanban_card.mod_kanban_closed .mod_kanban_duedate,
.mod_kanban_card:not(.mod_kanban_closed) .mod_kanban_uncomplete_card,
Expand Down
4 changes: 2 additions & 2 deletions templates/column.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"cardcount": 12
}
}}
<li class="mod_kanban_column col card{{#autohide}} mod_kanban_autohide{{/autohide}} {{#locked}}mod_kanban_locked_column{{/locked}} {{#wiplimit}}mod_kanban_column_wiplimit{{/wiplimit}}" id="mod_kanban_column-{{id}}" data-id="{{id}}">
<li class="mod_kanban_column col card{{#autohide}} mod_kanban_autohide{{/autohide}} {{#locked}}mod_kanban_locked_column{{/locked}} {{#wiplimit}}mod_kanban_wiplimit{{/wiplimit}}" id="mod_kanban_column-{{id}}" data-id="{{id}}">
<h5 class="mod_kanban_column_title card-title">
<span class="inplaceeditable inplaceeditable-text"{{#managecolumns}} {{^locked}}data-inplaceeditable="1" {{/locked}}data-component="mod_kanban" data-itemtype="column" data-itemid="{{id}}"
data-value="{{{title}}}" data-type="text"{{/managecolumns}}>
Expand All @@ -42,7 +42,7 @@
</h5>
<div class="mod_kanban_column_stats">
<span class="badge badge-light mod_kanban_wip"><span class="mod_kanban_cardcount">{{cardcount}}</span> {{#pix}} e/template, core, {{#str}} cardcount, mod_kanban{{/str}} {{/pix}}</span>
<span class="badge badge-light mod_kanban_wipinfo">{{wiplimit}} / {{#pix}} t/user, core, {{#str}} wiplimit, mod_kanban{{/str}} {{/pix}}</span>
<span class="badge badge-light mod_kanban_wipinfo"><span class="mod_kanban_wipnumber">{{wiplimit}}</span> / {{#pix}} t/user, core, {{#str}} wiplimit, mod_kanban{{/str}} {{/pix}}</span>
</div>
<div class="mod_kanban_hidden_actions">
<button data-action="show_hidden" class="btn btn-icon icon-no-margin p-0">{{#pix}} i/show, core, {{#str}} showhidden, mod_kanban {{/str}} {{/pix}}</button>
Expand Down

0 comments on commit f106f17

Please sign in to comment.