Commit c5f23de7 authored by ransome1's avatar ransome1
Browse files

Enhanced AddTodo button behavior, repo maintenaince, added threshold icon,...

Enhanced AddTodo button behavior, repo maintenaince, added threshold icon, added recurrence picker function in table list
parent ae94b6b6
......@@ -20,5 +20,5 @@ If you have interface design experience you can propose design changes. As sleek
### Translate sleek into your language
Plenty of languages are already available, but if yours is missing, you can translate the app to it.
## Write test cases
### Write test cases
Test cases are written for the Playwright end to end testing environment: https://playwright.dev/docs/api/class-playwright. Creating cases it pretty much straight forward and you can take a look on how it has been done so far: https://github.com/ransome1/sleek/blob/master/test/playwright.spec.js
\ No newline at end of file
MIT License
Copyright (c) 2021 Robin Ahle
Copyright (c) 2022 Robin Ahle
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
......
......@@ -2,6 +2,7 @@
## sleek is an open-source (FOSS) todo manager based on the todo.txt syntax. It's available for Windows, MacOS and Linux
+ [Screenshots](#screenshots)
+ [Support sleek](#support-sleek)
+ [Get it from Mac App Store](#get-sleek-from-apple-mac-app-store)
+ [Get it from Microsoft Store](#get-sleek-from-microsoft-store)
+ [Get it from Snap Store](#get-sleek-from-snap-store)
+ [Get it from Flathub](#get-sleek-from-flathub)
......@@ -22,34 +23,34 @@ sleek is available for Windows, MacOS and Linux, and in several languages. For a
### Screenshots
![Alt text](assets/screenshots/mac/main.png?raw=true "Screenshot of sleek's todo list view")
![Alt text](assets/screenshots/mac/drawer.png?raw=true "Screenshot of sleek's auto complete function and multi line todo feature")
![Alt text](assets/screenshots/mac/search.png?raw=true "Screenshot of sleek's todo list sorted by projects with due date picker shown")
### sleeks state of development
A prioritized backlog of new features and known issues as well as an overview on what is being worked on at the moment can be found <a href="https://github.com/ransome1/sleek/projects/2">here</a>.
### Support sleek
* Star, fork and watch it on Github.
* Review it on <a href="https://sourceforge.net/projects/sleek/reviews" target="blank">SourceForge</a> or <a href="https://www.microsoft.com/store/apps/9NWM2WXF60KR" target="blank">Windows Store</a>
* Contribute <a href="https://github.com/ransome1/sleek/issues">bug reports, code improvements or features</a>
* Translate sleek into your own language and contribute your translations
* Review it on <a href="https://apps.apple.com/us/app/sleek-todo-manager/id1614704209" target="blank">Mac App Store</a>, <a href="https://sourceforge.net/projects/sleek/reviews" target="blank">SourceForge</a> or <a href="https://www.microsoft.com/store/apps/9NWM2WXF60KR" target="blank">Windows Store</a>
* <a href="https://github.com/ransome1/sleek/blob/master/CONTRIBUTING.md">Contribute to sleek</a>
### Get sleek from Microsoft Store
You can install sleek from Microsofts Windows Store
### Get sleek from Apple Mac App Store
<a href="https://apps.apple.com/us/app/sleek-todo-manager/id1614704209" target="blank"><img src='assets/store_badges/Download_on_the_Mac_App_Store.png' alt='Get sleek from Apple Mac App Store' width='180'/></a>
### Get sleek from Microsoft Store
<a href="//www.microsoft.com/store/apps/9NWM2WXF60KR?cid=storebadge&ocid=badge" target="blank"><img src='https://developer.microsoft.com/store/badges/images/English_get-it-from-MS.png' alt='English badge' width='180'/></a>
### Get sleek from Snap Store
You can install sleek from Canonicals Snap Store using: `sudo snap install sleek`
[![Get it from the Snap Store](https://snapcraft.io/static/images/badges/en/snap-store-black.svg)](https://snapcraft.io/sleek)
Install sleek from <a href="https://snapcraft.io/sleek" target="blank">Snap Store</a> using: `sudo snap install sleek`
### Get sleek from Flathub
<a href="https://flathub.org/apps/details/com.github.ransome1.sleek" target="blank"><img width='180' alt="Download on Flathub" src="https://flathub.org/assets/badges/flathub-badge-en.png"/></a>
Install sleek from <a href="https://flathub.org/apps/details/com.github.ransome1.sleek" target="blank">Flathub</a> using: `flatpak install flathub com.github.ransome1.sleek`
Run it using: `flatpak run com.github.ransome1.sleek`
<a href="https://flathub.org/apps/details/com.github.ransome1.sleek" target="blank"><img width='180' alt="Download on Flathub" src="https://flathub.org/assets/badges/flathub-badge-en.png"/></a>
### Get sleek from Homebrew
Install sleek from <a href="https://formulae.brew.sh/cask/sleek" target="blank">Homebrew</a>.
`brew install --cask sleek`
......@@ -115,12 +116,16 @@ A more detailed documentation can be found in <a href="https://github.com/ransom
### Used libraries
- Electron: https://github.com/electron/electron
- Electron builder: https://github.com/electron-userland/electron-builder
- Electron Notarize: https://github.com/electron/electron-notarize
- Electron Windows Badge: https://github.com/viktor-shmigol/electron-windows-badge
- electron-reloader: https://github.com/sindresorhus/electron-reloader
- Bulma CSS: https://github.com/jgthms/bulma
- Font Awesome: https://github.com/FortAwesome/Font-Awesome
- jsTodoTxt: https://github.com/jmhobbs/jsTodoTxt
- Marked: https://github.com/markedjs/marked
- vanillajs-datepicker: https://github.com/mymth/vanillajs-datepicker
- i18next: https://github.com/i18next/i18next
- i18next-fs-backend: https://github.com/i18next/i18next-fs-backend
- Matomo: https://github.com/matomo-org/matomo
- chokidar: https://github.com/paulmillr/chokidar
- Sugar: https://github.com/andrewplummer/Sugar
......@@ -128,5 +133,3 @@ A more detailed documentation can be found in <a href="https://github.com/ransom
- Playwright: https://github.com/microsoft/playwright
- Sass: https://github.com/sass/sass
- eslint: https://github.com/eslint/eslint
- electron-reloader: https://github.com/sindresorhus/electron-reloader
- cross-env: https://github.com/kentcdodds/cross-env
......@@ -10,4 +10,4 @@ The following versions of sleek are provided with security updates.
## Reporting a Vulnerability
If you find a vulnerability in sleek, please send as much detail as possible to ransome@uber.space
If you find a vulnerability in sleek, please send as much detail as possible to ransome@duck.com
......@@ -11,7 +11,7 @@
"productivity",
"tasks"
],
"author": "Robin Ahle <mail@robbfolio.de>",
"author": "Robin Ahle <ransome@duck.com>",
"copyright": "Copyright © 2022 ${author}",
"license": "MIT",
"repository": "https://github.com/ransome1/sleek/",
......@@ -34,6 +34,7 @@
"!yarn.lock",
"!yarn-error.log",
"!assets/screenshots${/*}",
"!assets/store_badges${/*}",
"!**/node_modules/*/{CHANGELOG.md,README.md,README,readme.md,readme,test,__tests__,tests,powered-test,example,examples,*.d.ts}",
"!**/node_modules/.bin",
"!**/*.{o,hprof,orig,pyc,pyo,rbc}",
......@@ -120,6 +121,7 @@
},
"scripts": {
"build:mas": "yarn build:css && yarn build:pegjs && electron-builder -m mas --universal --publish never && bash build/resignPkg.sh",
"build:macos": "yarn build:css && yarn build:pegjs && electron-builder -m zip --universal --publish never && bash build/resignPkg.sh",
"build:appx": "yarn build:css && yarn build:pegjs && electron-builder -w appx --publish never",
"build:css": "sass src/scss/style.scss:src/css/style.css",
"build:pegjs": "peggy --format es --output src/js/filterlang.mjs src/js/filterlang.pegjs",
......@@ -130,7 +132,7 @@
"test1": "yarn playwright test -g 'Check if multi line items are displayed correctly' --config=test/playwright.config.js"
},
"dependencies": {
"@fortawesome/fontawesome-free": "^5.15.3",
"@fortawesome/fontawesome-free": "^6.1.1",
"bulma": "^0.9.2",
"chokidar": "^3.5.1",
"electron-updater": "^4.6.5",
......
......@@ -14,6 +14,12 @@ body.dark a:hover,
body.dark a:focus-visible {
color: #f0f0f0;
}
body.dark i {
color: #f0f0f0;
}
body.dark i.fa-sort-down {
color: #5a5a5a !important;
}
body.dark strong {
color: #f0f0f0;
}
......@@ -60,9 +66,6 @@ body.dark button {
color: #f0f0f0;
background: #212224;
}
body.dark button i {
color: #f0f0f0;
}
body.dark ::after {
border-color: #f0f0f0 !important;
}
......@@ -237,19 +240,19 @@ body.dark #todoTable .todo .cell.itemDueDate {
body.dark #todoTable .todo .cell.itemDueDate i {
color: inherit;
}
body.dark #todoTable .todo .cell.itemDueDate i.fa-sort-down {
color: #5a5a5a;
}
body.dark #todoTable .todo .cell.itemDueDate.today,
body.dark #todoTable .todo .cell.itemDueDate.past {
color: #ff3860;
}
body.dark #todoTable .todo .cell.itemDueDate.today i,
body.dark #todoTable .todo .cell.itemDueDate.past i {
color: inherit;
color: inherit !important;
}
body.dark #todoTable .todo .cell.itemDueDate.tomorrow {
color: #fa745e;
}
body.dark #todoTable .todo .cell.itemDueDate.tomorrow i {
color: #fa745e !important;
color: inherit !important;
}
body.dark #todoTable .todo:focus {
background: #3a3a3a !important;
......@@ -274,20 +277,19 @@ body.dark #modalForm #autoCompleteContainer section::-webkit-scrollbar-thumb:win
body.dark #modalForm #autoCompleteContainer section::-webkit-scrollbar-thumb {
background: #5a5a5a;
}
body.dark #recurrencePicker #recurrencePickerInput,
body.dark #recurrencePicker .radio {
body.dark #recurrencePickerContainer {
background: #2d2d2d;
}
body.dark #recurrencePickerContainer .radio {
cursor: pointer;
background: none !important;
color: white !important;
}
body.dark #recurrencePicker .radio:hover {
body.dark #recurrencePickerContainer .radio:hover {
color: #CCCDCF !important;
}
body.dark #recurrencePicker #recurrencePickerContainer {
background: #2d2d2d;
}
body.dark #recurrencePicker #recurrencePickerContainer .card-footer {
border-color: #212224;
body.dark #recurrencePickerContainer .card-footer {
border-color: #212224 !important;
}
body.dark #drawerContainer .drawer {
background: #3B3B3B !important;
......@@ -1101,8 +1103,8 @@ nav ul:nth-child(2):hover #versionNumber {
width: 1.2em;
display: inline-block;
background-color: #3273dc;
-webkit-mask-image: url("../../node_modules/@fortawesome/fontawesome-free/svgs/solid/times-circle.svg");
mask-image: url("../../node_modules/@fortawesome/fontawesome-free/svgs/solid/times-circle.svg");
-webkit-mask-image: url("../../node_modules/@fortawesome/fontawesome-free/svgs/solid/circle-xmark.svg");
mask-image: url("../../node_modules/@fortawesome/fontawesome-free/svgs/solid/circle-xmark.svg");
cursor: pointer;
}
#todoTableSearchContainer label {
......@@ -1744,6 +1746,10 @@ a.priority.C:focus-visible span.tag {
margin: 0 auto;
}
#modalChangeFile table tr td:last-child {
width: 1em;
}
#modalForm[open]:not(:focus-within) {
background-color: #fffffe;
transition: background-color 0.01s;
......@@ -1825,36 +1831,35 @@ a.priority.C:focus-visible span.tag {
#recurrencePicker #recurrencePickerInput {
cursor: pointer;
}
#recurrencePicker .card {
#recurrencePickerContainer {
width: auto;
display: none;
position: fixed;
z-index: 100;
}
#recurrencePicker .card .content {
#recurrencePickerContainer .content {
margin: 0;
padding: 1em;
display: flex;
align-items: center;
}
#recurrencePicker .card .content div {
#recurrencePickerContainer .content div {
width: auto;
float: left;
text-align: center;
padding: 0 0.5em;
}
#recurrencePicker .card .content div.options {
#recurrencePickerContainer .content div.options {
text-align: left;
}
#recurrencePicker .card .content #recurrencePickerDecrease,
#recurrencePicker .card .content #recurrencePickerIncrease,
#recurrencePicker .card .content #recurrencePickerSpinner {
#recurrencePickerContainer .content #recurrencePickerDecrease,
#recurrencePickerContainer .content #recurrencePickerIncrease,
#recurrencePickerContainer .content #recurrencePickerSpinner {
font-size: 1.25em;
padding: 0.5em;
}
#recurrencePicker .card .content #recurrencePickerSpinner {
width: 2em;
}
#recurrencePicker .card label {
#recurrencePickerContainer label {
font-size: 1em;
color: #2d2d2d;
display: block;
......@@ -1961,10 +1966,6 @@ a.priority.C:focus-visible span.tag {
#todoTable .todo:focus {
background: #e0eafa !important;
}
#todoTable .todo:focus .cell.itemDueDate .tags,
#todoTable .todo:focus .cell.itemDueDate .fa-sort-down {
display: block;
}
#todoTable .todo.completed .cell {
filter: opacity(50%) grayscale(100%);
}
......@@ -2019,38 +2020,34 @@ a.priority.C:focus-visible span.tag {
padding: 0;
color: #5a5a5a;
}
#todoTable .cell.text:focus-visible {
background: #f0f0f0;
border-radius: 0.65em;
}
#todoTable .cell.itemDueDate {
#todoTable .cell.hint {
color: #5a5a5a;
position: relative;
white-space: nowrap;
text-transform: lowercase;
cursor: pointer;
}
#todoTable .cell.itemDueDate .fa-sort-down {
#todoTable .cell.hint .fa-sort-down {
position: absolute;
right: 0.2em;
top: -0.5em;
display: none;
}
#todoTable .cell.itemDueDate .tags {
#todoTable .cell.hint .tags {
position: absolute;
top: -1.6em;
right: -1.5em;
z-index: 50;
display: none;
}
#todoTable .cell.itemDueDate .tags .tag {
#todoTable .cell.hint .tags .tag {
margin: 0;
}
#todoTable .cell.itemDueDate .tags .is-dark {
#todoTable .cell.hint .tags .is-dark {
background: #5a5a5a;
font-family: FreeSansBold;
}
#todoTable .cell.itemDueDate .transparentInput {
#todoTable .cell.hint .transparentInput {
width: 100%;
height: 100%;
background: transparent !important;
......
This diff is collapsed.
......@@ -102,7 +102,7 @@
</td>
</tr>
<tr>
<td id="viewBoxShowHidden"><span id="toggleShowHidden"></span></td>
<td id="viewBoxShowHidden"><span id="toggleShowHidden"></span><a href="https://github.com/ransome1/sleek/wiki/Hidden-todos-(h:)" target="_blank"><i class="fas fa-question-circle"></i></a></td>
<td>
<span class="toggle">
<label class="switch" for="showHidden">
......@@ -146,7 +146,7 @@
</td>
</tr>
<tr>
<td><span id="toggleDeferredTodos"></span> <a href="https://github.com/ransome1/sleek/wiki/Deferred-todos-(t:)" target="_blank"><i class="fas fa-question-circle"></i></a></td>
<td><span id="toggleDeferredTodos"></span><a href="https://github.com/ransome1/sleek/wiki/Deferred-todos-(t:)" target="_blank"><i class="fas fa-question-circle"></i></a></td>
<td>
<span class="toggle">
<label class="switch" for="deferredTodos">
......@@ -295,7 +295,7 @@
<div class="control has-icons-left">
<input id="datePickerInput" class="input" tabindex="0" readonly>
<a href="#" class="icon is-left" tabindex="-1">
<i class="far fa-clock is-left"></i>
<i class="fa-solid fa-clock is-left"></i>
</a>
</div>
</div>
......@@ -303,46 +303,10 @@
<div class="control has-icons-left">
<input id="recurrencePickerInput" class="input" readonly tabindex="-1">
<a href="#" class="icon is-left" tabindex="-1">
<i class="fas fa-redo"></i>
<i class="fa-solid fa-repeat"></i>
</a>
</div>
<div id="recurrencePickerContainer" class="card" tabindex="-1">
<div class="content">
<div>
<span id="recurrencePickerEvery"></span>
</div>
<div id="recurrencePickerMul">
<a href="#" id="recurrencePickerIncrease"><i class="fas fa-plus-circle"></i></a><br>
<input id="recurrencePickerSpinner" type="number" min="1" max="99"><br>
<a href="#" id="recurrencePickerDecrease"><i class="fas fa-minus-circle"></i></a>
</div>
<div class="options">
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="d">
<span id="recurrencePickerDay"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="b">
<span id="recurrencePickerBusinessDay"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="w">
<span id="recurrencePickerWeek"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="m">
<span id="recurrencePickerMonth"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="y">
<span id="recurrencePickerYear"></span>
</label>
</div>
</div>
<footer class="card-footer">
<a href="#" class="card-footer-item selection" id="recurrencePickerNoRecurrence"></a>
</footer>
</div>
</div>
</div>
......@@ -354,6 +318,47 @@
</div>
</div>
</form>
<div id="recurrencePickerContainer" class="card" tabindex="-1">
<div class="content">
<div>
<span id="recurrencePickerEvery"></span>
</div>
<div id="recurrencePickerMul">
<a href="#" id="recurrencePickerIncrease"><i class="fas fa-plus-circle"></i></a><br>
<input id="recurrencePickerSpinner" type="number" min="1" max="99"><br>
<a href="#" id="recurrencePickerDecrease"><i class="fas fa-minus-circle"></i></a>
</div>
<div class="options">
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="d">
<span id="recurrencePickerDay"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="b">
<span id="recurrencePickerBusinessDay"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="w">
<span id="recurrencePickerWeek"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="m">
<span id="recurrencePickerMonth"></span>
</label>
<label class="radio">
<input type="radio" class="selection" name="recurrence" value="y">
<span id="recurrencePickerYear"></span>
</label>
</div>
</div>
<footer class="card-footer">
<a href="#" class="card-footer-item selection" id="recurrencePickerNoRecurrence"></a>
</footer>
</div>
<div id="modalSettings" class="modal content" tabindex="0">
<div class="modal-background" role="cancel"></div>
<div class="modal-card">
......@@ -524,7 +529,7 @@
<li class="helpTab2"><a href="#" id="helpTab2Title" tabindex="0"></a></li>
<li class="helpTab3"><a href="#" id="helpTab3Title" tabindex="0"></a></li>
<li class="helpTab4"><a href="#" id="helpTab4Title" tabindex="0"></a></li>
<li class="helpTab5"><a href="#" id="helpTab5Title" tabindex="0"></a></li>
<li class="helpTab5"><a href="#" id="recurrences" tabindex="0"></a></li>
<li class="helpTab6"><a href="#" id="settingsTabAbout" tabindex="0"></a></li>
</ul>
</div>
......@@ -731,16 +736,16 @@
<tr>
<td><i class="fab fa-github"></i></td>
<td><a href="https://github.com/ransome1/sleek/issues" target="_blank" id="submitIssuesOnGithub"></a></td>
<td><i class="fas fa-star"></i></td>
<td><a href="https://sourceforge.net/projects/sleek/reviews" target="_blank" id="reviewSourceforge"></a></td>
<td><i class="fab fa-apple"></i></td>
<td><a href="https://apps.apple.com/us/app/sleek-todo-manager/id1614704209" target="_blank" id="reviewMacAppStore"></a></td>
<td><i class="fab fa-windows"></i></td>
<td><a href="https://www.microsoft.com/store/apps/9NWM2WXF60KR" target="_blank" id="reviewWindowsStore"></a></td>
</tr>
<tr>
<td><i class="fas fa-star"></i></td>
<td><a href="https://sourceforge.net/projects/sleek/reviews" target="_blank" id="reviewSourceforge"></a></td>
<td><i class="fab fa-twitter"></i></td>
<td><a href="https://twitter.com/intent/tweet?text=Check%20out%20sleek,%20a%20todo%20app%20based%20on%20todo.txt,%20free%20and%20open-source.%20Available%20for%20Linux,%20Windows%20and%20MacOS.%20https://github.com/ransome1/sleek" target="_blank" id="shareTwitter"></a></td>
<td><i class="fab fa-facebook"></i></td>
<td><a href="https://www.facebook.com/sharer/sharer.php?u=https://github.com/ransome1/sleek" target="_blank" id="shareFacebook"></a></td>
<td><i class="fab fa-linkedin"></i></td>
<td><a href="https://www.linkedin.com/shareArticle?mini=true&url=https://github.com/ransome1/sleek" target="_blank" id="shareLinkedin"></a></td>
</tr>
......@@ -766,28 +771,7 @@
<th colspan="100%" id="settingsTabAboutExternalLibraries"></th>
</tr>
<tr>
<td><a href="https://github.com/electron/electron" target="_blank">Electron</a></td>
<td><a href="https://github.com/electron-userland/electron-builder" target="_blank">Electron builder</a></td>
<td><a href="https://github.com/i18next/i18next" target="_blank">i18next</a></td>
<td><a href="https://github.com/mymth/vanillajs-datepicker" target="_blank">vanillajs-datepicker</a></td>
</tr>
<tr>
<td><a href="https://github.com/jgthms/bulma" target="_blank">Bulma CSS</a></td>
<td><a href="https://github.com/FortAwesome/Font-Awesome" target="_blank">Font Awesome</a></td>
<td><a href="https://github.com/jmhobbs/jsTodoTxt" target="_blank">jsTodoTxt</a></td>
<td><a href="https://github.com/markedjs/marked" target="_blank">Marked</a></td>
</tr>
<tr>
<td><a href="https://github.com/matomo-org/matomo" target="_blank">Matomo</a></td>
<td><a href="https://github.com/paulmillr/chokidar" target="_blank">chokidar</a></td>
<td><a href="https://github.com/viktor-shmigol/electron-windows-badge/" target="_blank">Electron Windows Badge</a></td>
<td><a href="https://github.com/andrewplummer/Sugar" target="_blank">Sugar</a></td>
</tr>
<tr>
<td><a href="https://github.com/pegjs/pegjs" target="_blank">PEG.js</a></td>
<td></td>
<td></td>
<td></td>
<td><a href="https://github.com/ransome1/sleek#used-libraries" target="_blank">https://github.com/ransome1/sleek#used-libraries</a></td>
</tr>
</table>
</section>
......
......@@ -16,7 +16,7 @@ const helpTab1Title = document.getElementById("helpTab1Title");
const helpTab2Title = document.getElementById("helpTab2Title");
const helpTab3Title = document.getElementById("helpTab3Title");
const helpTab4Title = document.getElementById("helpTab4Title");
const helpTab5Title = document.getElementById("helpTab5Title");
const recurrences = document.getElementById("recurrences");
const helpTabContextsProjectsBody = document.getElementById("helpTabContextsProjectsBody");
const helpTabContextsProjectsTitle = document.getElementById("helpTabContextsProjectsTitle");
const helpTabDatesBody1 = document.getElementById("helpTabDatesBody1");
......@@ -82,7 +82,7 @@ const settingsTabSettingsNotifications = document.getElementById("settingsTabSet
const settingsTabSettingsNotificationsBody = document.getElementById("settingsTabSettingsNotificationsBody");
const settingsTabSettingsTray = document.getElementById("settingsTabSettingsTray");
const settingsTabSettingsTrayBody = document.getElementById("settingsTabSettingsTrayBody");
const shareFacebook = document.getElementById("shareFacebook");
const reviewAppMacStore = document.getElementById("reviewWindowsStore");
const shareLinkedin = document.getElementById("shareLinkedin");
const shareTwitter = document.getElementById("shareTwitter");
const submitIssuesOnGithub = document.getElementById("submitIssuesOnGithub");
......@@ -102,7 +102,7 @@ helpTab1Title.innerHTML = translations.shortcuts;
helpTab2Title.innerHTML = translations.priorities;
helpTab3Title.innerHTML = translations.helpTab3Title;
helpTab4Title.innerHTML = translations.helpTab4Title;
helpTab5Title.innerHTML = translations.helpTab5Title;
recurrences.innerHTML = translations.recurrences;
helpTabContextsProjectsBody.innerHTML = translations.helpTabContextsProjectsBody;
helpTabContextsProjectsTitle.innerHTML = translations.helpTabContextsProjectsTitle;
helpTabDatesBody1.innerHTML = translations.helpTabDatesBody1;
......@@ -146,6 +146,7 @@ helpTabRecurrencesBody1.innerHTML = translations.helpTabRecurrencesBody1;
helpTabRecurrencesTitle1.innerHTML = translations.helpTabRecurrencesTitle1;
reviewSourceforge.innerHTML = translations.reviewSourceforge;
reviewWindowsStore.innerHTML = translations.reviewWindowsStore;
reviewMacAppStore.innerHTML = translations.reviewMacAppStore;
settingsTabAbout.innerHTML = translations.about;
settingsTabAboutContribute.innerHTML = translations.settingsTabAboutContribute;
settingsTabAboutCopyrightLicense.innerHTML = translations.settingsTabAboutCopyrightLicense;
......@@ -165,7 +166,6 @@ settingsTabSettingsNotifications.innerHTML = translations.notifications;
settingsTabSettingsNotificationsBody.innerHTML = translations.settingsTabSettingsNotificationsBody;
settingsTabSettingsTray.innerHTML = translations.settingsTabSettingsTray;
settingsTabSettingsTrayBody.innerHTML = translations.settingsTabSettingsTrayBody;
shareFacebook.innerHTML = translations.shareFacebook;
shareLinkedin.innerHTML = translations.shareLinkedin;
shareTwitter.innerHTML = translations.shareTwitter;
submitIssuesOnGithub.innerHTML = translations.submitIssuesOnGithub;
......
......@@ -121,7 +121,7 @@ modalForm.onsubmit = async function(event) {
return false;
// check if todo text is empty
} else if(!todo.text && !todo.h) {
} else if(!todo.text) {
modalFormAlert.innerHTML = translations.formInfoIncomplete;
modalFormAlert.parentElement.classList.add("is-active", "is-warning");
console.log("Info: Todo is incomplete");
......
......@@ -58,8 +58,10 @@ export async function registerShortcuts() {
if(event.key === "Escape") {
// if search is focused, lose focus on escape
// hide add todo button
if(document.activeElement.id==="todoTableSearch") {
todoTableSearch.blur();
document.getElementById("todoTableSearchAddTodo").classList.remove("is-active");
return false;
}
// if 'add as todo' is focused, return to search
......
......@@ -4,9 +4,10 @@ import { handleError } from "./helper.mjs";
import { _paq } from "./matomo.mjs";
import { resizeInput } from "./form.mjs";
import { RecExtension } from "./todotxtExtensions.mjs";
import { generateTodoTxtObject, items, editTodo } from "./todos.mjs";
import * as recurrences from "./recurrences.mjs";
const radioRecurrence = document.querySelectorAll("#recurrencePicker .selection");
const radioRecurrence = document.querySelectorAll("#recurrencePickerContainer .selection");
const recurrencePickerContainer = document.getElementById("recurrencePickerContainer");
const recurrencePickerInput = document.getElementById("recurrencePickerInput");
const recurrencePickerSpinner = document.getElementById("recurrencePickerSpinner");
......@@ -30,9 +31,8 @@ recurrencePickerInput.placeholder = translations.noRecurrence;
recurrencePickerInput.onfocus = function(element) {
// only like this compatible with body click event in event.mjs
setTimeout(function() {
showRecurrences(element);
//this.blur();
}, 100);
showRecurrences(element.target, document.getElementById("modalFormInput").value);
}, 200);
};
recurrencePickerInput.onchange = function() {
......@@ -90,26 +90,24 @@ export function setInput(recurrence) {
} else {
recurrencePickerInput.value = null;
}
resizeInput(recurrencePickerInput);
// trigger matomo event
if(userData.matomoEvents) _paq.push(["trackEvent", "Form", "Recurrence selected: " + label]);
return Promise.resolve("Success: Recurrence added");
return label;
} catch(error) {
error.functionName = setInput.name;
return Promise.reject(error);