Commit abf595b2 authored by ransome1's avatar ransome1
Browse files

Improved file tabbing, improved print CSS, fixed tray function, fixed h:1 function

parent 6000e80f
......@@ -5,6 +5,7 @@
+ [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)
+ [Get it from Homebrew](#get-sleek-from-homebrew)
+ [Get it from Arch User Repository](#get-sleek-from-arch-user-repository)
+ [Download it](#download-sleek)
+ [Build it from source code](#build-sleek-from-source-code)
......@@ -25,9 +26,9 @@ Todos with due date or repeating todos will trigger notifications and completed
![Alt text](assets/screenshots/linux/multiline_autocomplete_dark.png?raw=true "Screenshot of sleek's auto complete function and multi line todo feature on Linux")
### Support sleek
* Star, fork and watch it on Github. Once sleek reaches **30 watchers, 30 forks and 75 stars**, we can distribute it to MacOS using the <a href="https://github.com/Homebrew/brew" target="blank">Homebrew Package Manager</a>
* 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, features or simply suggest new features</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
### Get sleek from Microsoft Store
......@@ -98,7 +99,7 @@ A prioritized backlog of new features and known issues can be found <a href="htt
* Filters are sorted alphanummerically
* Hyperlinks are detected automatically and can be clicked using the icon
* A file watcher rereads the todo.txt file if it has been changed
* Multiple todo.txt files can be managed
* Multiple todo.txt files can be managed and switched between using a tab bar or keyboard shortcuts
* Multiple languages are either detected or can be set by hand to
- English
- German
......
{
"name": "sleek",
"productName": "sleek",
"version": "1.1.0-rc.3",
"version": "1.1.0-rc.4",
"description": "Todo app based on todo.txt for Linux, Windows and MacOS, free and open-source",
"synopsis": "Todo app based on todo.txt for Linux, Windows and MacOS, free and open-source",
"category": "ProjectManagement",
......
This diff is collapsed.
This diff is collapsed.
......@@ -684,7 +684,7 @@
</section>
<section id="helpTab6" class="modal-card-body" data-track-content data-content-name="Help" data-content-piece="About">
<h3 class="title is-3" id="settingsTabAboutHeadline"></h3>
<p><code>Current version: <span id="version"></span></code></p>
<p><code>Version: <span id="version"></span></code></p>
<table>
<tr>
<th colspan="100%" id="settingsTabAboutContribute"></th>
......
......@@ -160,6 +160,7 @@ toggleTray.onclick = function(event) {
}
toggleNotifications.checked = userData.notifications;
toggleTray.checked = userData.tray;
function setTray(setting) {
setUserData("tray", setting);
......
"use strict";
import { resetFilters, resetModal, handleError, userData, setUserData, translations } from "../render.js";
import { resetFilters, resetModal, handleError, userData, appData, setUserData, translations } from "../render.js";
import { _paq } from "./matomo.mjs";
import { createModalJail } from "../configs/modal.config.mjs";
......@@ -17,7 +17,7 @@ function removeFileFromList(isActive, index) {
}
userData.files.splice(index, 1);
setUserData("files", userData.files);
resetFilters().then(function(response) {
resetFilters(true).then(function(response) {
console.info(response);
index = userData.files.findIndex(file => file[0] === 1);
window.api.send("startFileWatcher", userData.files[index][1]);
......@@ -32,7 +32,7 @@ function removeFileFromList(isActive, index) {
function selectFileFromList(index) {
try {
resetFilters().then(function(response) {
resetFilters(false).then(function(response) {
console.info(response);
}).catch(function(error) {
handleError(error);
......@@ -62,12 +62,15 @@ function generateFileList() {
for (let i = 0; i < userData.files.length; i++) {
let isActive = userData.files[i][0];
let fileName = userData.files[i][1].split("/").pop();
if(appData.os === "windows") fileName = userData.files[i][1].split("\\").pop();
let listItem = document.createElement("li");
listItem.innerHTML = fileName;
listItem.innerHTML += "<i class=\"fas fa-minus-circle\"></i>";
if(isActive===1) listItem.classList.add("is-highlighted");
listItem.querySelector("i").onclick = function() {
removeFileFromList(isActive, i);
// trigger matomo event
if(userData.matomoEvents) _paq.push(["trackEvent", "File-Tab", "Click on remove icon"]);
}
if(!isActive) {
listItem.onclick = function(event) {
......@@ -97,7 +100,7 @@ function generateFileList() {
handleError(error);
});
// trigger matomo event
if(userData.matomoEvents) _paq.push(["trackEvent", "File", "Click on select button"]);
if(userData.matomoEvents) _paq.push(["trackEvent", "File-Chooser", "Click on select button"]);
}
}
cell2.innerHTML = userData.files[i][1];
......@@ -112,6 +115,8 @@ function generateFileList() {
}).catch(error => {
handleError(error);
});
// trigger matomo event
if(userData.matomoEvents) _paq.push(["trackEvent", "File-Chooser", "Click on remove button"]);
}
}
return Promise.resolve("Success: File changer modal built and opened");
......
......@@ -155,16 +155,13 @@ function filterItems(items) {
}
// apply filters
items = items.filter(function(item) {
if(!item.text) return false
if(!item.text && !item.h) return false;
if(!userData.showHidden && item.h) return false;
if(!userData.showCompleted && item.complete) return false;
if(!userData.showDueIsToday && item.due && isToday(item.due)) return false;
if(!userData.showDueIsPast && item.due && isPast(item.due)) return false;
if(!userData.showDueIsFuture && item.due && isFuture(item.due)) return false;
// filter deferred todos that are set in the future
if(!userData.deferredTodos && item.t && isFuture(item.t)) return false;
// remove todos with no text
if(item.text==="") return false;
return true;
});
return Promise.resolve(items);
......
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