Skip to content

Commit 86a249c

Browse files
committed
iOS supported added.
- Fixed issues with iOS. - Improved UI. - Fixed issues with setTime dialog.
1 parent 71f2e53 commit 86a249c

File tree

4 files changed

+27
-11
lines changed

4 files changed

+27
-11
lines changed

css/timer.css

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,27 @@ footer {
5757
position: relative;
5858
}
5959

60-
.btnAction {
61-
font-size: xx-large;
62-
text-align: center;
63-
color: black;
60+
@supports (-webkit-overflow-scrolling: touch) {
61+
.btnAction {
62+
font-size: xx-large;
63+
text-align: center;
64+
color: black;
65+
padding: 0px;
66+
}
67+
.btnClock{
68+
left: 264px;
69+
}
70+
}
71+
72+
@supports not (-webkit-overflow-scrolling: touch) {
73+
.btnAction {
74+
font-size: xx-large;
75+
text-align: center;
76+
color: black;
77+
}
78+
.btnClock{
79+
left: 202px;
80+
}
6481
}
6582

6683
.btnPopUp {

index.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<head>
44
<meta charset="utf-8">
55
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
6-
<meta name="viewport" content="width=device-width, initial-scale=1">
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, shrink-to-fit=no">
77
<meta name="description" content="Toastmasters Timer">
88
<meta name="keywords" content="HTML,CSS,JavaScript,jQuery,Toastmasters,The Leader Ship,Lodz,Poland,Polska">
99
<meta name="author" content="Federico Navarrete">
@@ -275,7 +275,7 @@ <h4 class="hCustom" data-tag="clapping"></h4>
275275
<h4 class="hCustom" data-tag="timeMinimum"></h4>
276276
</div>
277277
<div class="mdl-textfield mdl-js-textfield">
278-
<label class="mdl-button mdl-js-button mdl-button--icon" for="txtMin" style='left: 202px;'>
278+
<label class="mdl-button mdl-js-button mdl-button--icon btnClock" for="txtMin">
279279
<span class="mdi mdi-av-timer"></span>
280280
</label>
281281
<input class="mdl-textfield__input" type="text" id="txtMin" readonly value="00:00:00">
@@ -287,7 +287,7 @@ <h4 class="hCustom" data-tag="timeMinimum"></h4>
287287
<h4 class="hCustom" data-tag="timeHalfway"></h4>
288288
</div>
289289
<div class="mdl-textfield mdl-js-textfield">
290-
<label class="mdl-button mdl-js-button mdl-button--icon" for="txtAvg" style='left: 202px;'>
290+
<label class="mdl-button mdl-js-button mdl-button--icon btnClock" for="txtAvg">
291291
<span class="mdi mdi-av-timer"></span>
292292
</label>
293293
<input class="mdl-textfield__input" type="text" id="txtAvg" readonly value="00:00:00">
@@ -299,7 +299,7 @@ <h4 class="hCustom" data-tag="timeHalfway"></h4>
299299
<h4 class="hCustom" data-tag="timeMaximum"></h4>
300300
</div>
301301
<div class="mdl-textfield mdl-js-textfield">
302-
<label class="mdl-button mdl-js-button mdl-button--icon" for="txtMax" style='left: 202px;'>
302+
<label class="mdl-button mdl-js-button mdl-button--icon btnClock" for="txtMax">
303303
<span class="mdi mdi-av-timer"></span>
304304
</label>
305305
<input class="mdl-textfield__input" type="text" id="txtMax" readonly value="00:00:00">

js/setTimeDialog.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ let i = 0, j = 0, k = 0, timeOutS = 0, timeOutM = 0, timeOutH = 0;
1010

1111
btnSetTime.addEventListener('click', function () {
1212
$(`#${chosenInputText}`)[0].parentElement.MaterialTextfield.change(`${txtH.value}:${txtM.value}:${txtS.value}`);
13-
removeDialogFromStack('setTime');
1413
dialogSetTime.close();
1514
});
1615

@@ -21,7 +20,6 @@ btnClearTime.addEventListener('click', function () {
2120
});
2221

2322
dialogSetTime.querySelector('.close').addEventListener('click', function () {
24-
removeDialogFromStack('setTime');
2523
clearIntervals();
2624
dialogSetTime.close();
2725
});
@@ -52,7 +50,6 @@ function setNewTime(inputText, currentTxt) {
5250
} else
5351
openSetDialog(currentTxt);
5452
try {
55-
addDialogToStack('setTime');
5653
dialogSetTime.showModal();
5754
} catch (e) { }
5855
}

js/timer.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1007,6 +1007,8 @@ $(function() {
10071007
if (typeof HTMLDialogElement !== 'function') {
10081008
$("#welcomeDialog").removeClass("centeredDialog");
10091009
$("#welcomeDialog").addClass("centeredDialogNoSupport");
1010+
$("#setTimeDialog").removeClass("centeredDialog");
1011+
$("#setTimeDialog").addClass("centeredDialogNoSupport");
10101012
}
10111013

10121014
$('body').focus(function() {

0 commit comments

Comments
 (0)