Commit 4369a71e authored by Peter Hoffmann's avatar Peter Hoffmann
Browse files

Fix arrow rotation for inner24 mode

parent 31581832
......@@ -822,9 +822,15 @@ class mdDateTimePicker {
spoke = 12
value = me._sDialog.sDate.format('h')
}
const rotationClass = me._calcRotation(spoke, parseInt(value, 10))
const parsedValue = parseInt(value, 10);
const rotationClass = me._calcRotation(spoke, parsedValue);
if (rotationClass) {
needle.classList.add(rotationClass)
needle.classList.add(rotationClass);
if (this._inner24 === true && spoke === 24 && parsedValue > 12) {
needle.classList.add('mddtp-picker__cell--rotate24');
}
}
}
......@@ -1495,7 +1501,16 @@ class mdDateTimePicker {
if (spoke === 12) {
value *= 10
} else if (spoke === 24) {
value *= 5
if (this._inner24 === true) {
if (value > 12) {
value -= 12;
}
value *= 10;
} else {
value *= 5;
}
} else {
value *= 2
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment