Fix size picker display for pen size > 4

This commit is contained in:
Julian Descottes 2018-11-24 21:00:11 +01:00
parent 66452de1e5
commit c5c8184ae3

View file

@ -28,7 +28,7 @@
pskl.utils.Dom.removeClass('selected', this.container);
var selectedOption;
selectedOption = this.container.querySelector('[data-size="' + size + '"]');
if (typeof selectedOption === 'undefined') {
if (!selectedOption) {
selectedOption = this.container.querySelector('[data-size]:last-child');
selectedOption.classList.add('labeled');
selectedOption.setAttribute('real-size', size);