Skip to content

Commit 3fb2651

Browse files
committed
feat: update changelog for version 1.4.3 and enhance UI/UX across the application
1 parent 56824ec commit 3fb2651

25 files changed

Lines changed: 402 additions & 42 deletions

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,22 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
55

66
---
77

8+
## [1.4.3] - 2026-05-23
9+
10+
### Changed
11+
12+
#### Dashboard and Global UI Polish
13+
14+
- **Balanced dashboard chart cards** - aligned the Hourly Distribution card and Top Apps card heights for a cleaner two-column layout
15+
- **Refined app-wide visual style** - added layered ambient background gradients, enhanced glass-card depth/hover behavior, and shell-level decorative light effects across main pages
16+
- **Typography refresh** - upgraded the global font stack for better readability in both Chinese and English UI surfaces
17+
- **Full-width page layout for key modules** - removed fixed max-width constraints on Categories, Goals, and Focus Mode pages so content fills the available main area without a large right-side blank zone
18+
19+
### Fixed
20+
21+
- **Hourly distribution overflow bug** - fixed per-hour aggregation so usage segments are split across hour boundaries, preventing impossible values such as single-hour totals over 60 minutes
22+
- **UWP app identification on Windows** - improved foreground window resolution to avoid reporting UWP apps as `ApplicationFrameHost` or `Unknown` by resolving the real process behind the frame host window
23+
824
## [1.4.2] - 2026-05-22
925

1026
### Added

docs/ROADMAP_FROM_1.4.3.md

Lines changed: 179 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,179 @@
1+
# TimeLens Roadmap (From v1.4.3)
2+
3+
Last updated: 2026-05-23
4+
5+
## Starting Point
6+
7+
Current stable baseline: **v1.4.3**
8+
9+
Existing foundation already in place:
10+
11+
- Local-first desktop time tracking with SQLite
12+
- Widget Center with official widgets and third-party widget loading
13+
- Permission and bridge-key based extension integration
14+
- Data Health, Backup/Restore v2, and cross-platform startup controls
15+
16+
## Product Direction After v1.4.3
17+
18+
- Keep local-first as the default architecture.
19+
- Upgrade from "data display" to "action guidance".
20+
- Grow widgets into a practical daily workflow system.
21+
- Make extension and widget ecosystem safe, observable, and stable.
22+
23+
## Milestones
24+
25+
## v2.2.0 (2026 Q3) - 小组件爆发期
26+
27+
### 主题目标
28+
29+
把 Widget Center 做成真正高频入口。
30+
31+
### 核心功能
32+
33+
- 小组件商店页升级:分类、搜索、推荐、最近使用。
34+
- 组件组合场景:晨间面板、专注面板、复盘面板,一键启用布局。
35+
- 组件状态同步:同一组件多实例支持独立配置模板。
36+
- 组件性能监测:CPU/内存占用可视化、异常自动降级。
37+
38+
### 新增官方小组件(第一批)
39+
40+
- Habits Tracker(习惯打卡)
41+
- Calendar Agenda(日程清单,支持本地 iCal/ics)
42+
- Quick Capture(极速收集箱)
43+
- Focus Music Controller(本地播放器控制)
44+
- Water Break(喝水与休息提醒)
45+
- Sticky Board(便签看板,多便签)
46+
- Daily Quote(每日一句,可本地词库)
47+
- Battery & Device Status(设备状态)
48+
49+
### 验收指标
50+
51+
- 小组件日活使用率提升到 60%+。
52+
- 单日平均打开组件次数提升 40%。
53+
54+
## v2.4.0 (2026 Q4) - 深度专注与目标执行
55+
56+
### 主题目标
57+
58+
把洞察变成“可执行计划”。
59+
60+
### 核心功能
61+
62+
- Focus Plan:基于历史行为自动生成今日专注计划。
63+
- Goal Coach:目标拆分、风险提示、延期建议。
64+
- Session Review:每次专注会话后自动总结(本地规则引擎)。
65+
- Anti-Distraction:分心应用预警和弹性封锁策略。
66+
67+
### 新增官方小组件(第二批)
68+
69+
- Focus Session Timeline(专注会话时间轴)
70+
- Goal Progress Ring(目标环)
71+
- Distraction Radar(分心雷达)
72+
- Session Notes(会话笔记)
73+
- Pomodoro Matrix(番茄矩阵)
74+
- Break Stretch Guide(拉伸指导)
75+
76+
### 验收指标
77+
78+
- 用户周均专注时长提升 20%。
79+
- 目标达成率提升 15%。
80+
81+
## v2.6.0 (2027 Q1) - 开发生态与可扩展平台
82+
83+
### 主题目标
84+
85+
让第三方组件开发“易上手、可运营、可审计”。
86+
87+
### 核心功能
88+
89+
- Widget SDK v3:脚手架、热重载、调试面板。
90+
- 权限中心 v3:细粒度授权、按来源隔离、调用审计。
91+
- 本地 API 治理:限流、配额、错误分析、客户端信誉分。
92+
- 组件质量分:启动耗时、稳定性、资源占用评分。
93+
94+
### 新增官方小组件(第三批,偏开发与效率)
95+
96+
- Code Focus Heatmap(编码热力图)
97+
- Git Activity Summary(本地 Git 活动概览)
98+
- Build Monitor(构建状态)
99+
- Meeting Guard(会议防打断)
100+
- Context Switch Counter(上下文切换计数器)
101+
102+
### 验收指标
103+
104+
- 第三方组件安装占比 30%+。
105+
- 组件崩溃率下降 50%。
106+
107+
## v3.0.0 (2027 Q2) - Local-First 生产力平台
108+
109+
### 主题目标
110+
111+
形成“仪表盘 + 行动系统 + 组件生态”的完整闭环。
112+
113+
### 核心功能
114+
115+
- Unified Workspace 2.0:洞察、计划、执行、复盘同屏联动。
116+
- Personal Automation:本地规则自动触发(时间、状态、应用场景)。
117+
- Data Lifecycle Pro:冷热分层、压缩、快速恢复。
118+
- Accessibility & i18n 全面补齐。
119+
120+
### 新增官方小组件(第四批,平台级)
121+
122+
- AI-Free Smart Assistant(纯本地规则助手,非云 AI)
123+
- Weekly Review Board(周复盘看板)
124+
- Time Budget Planner(时间预算)
125+
- Multi-Goal Kanban(多目标看板)
126+
- Life Balance Radar(生活平衡雷达)
127+
128+
### 验收指标
129+
130+
- 离线核心流程覆盖率 100%。
131+
- 首次启动到可用时间降低 30%。
132+
- NPS 与留存明显提升。
133+
134+
## Widget Roadmap Matrix
135+
136+
### Category Plan
137+
138+
- Execution widgets: tasks, timers, planning, review
139+
- Focus-health widgets: break, water, stretch, recovery
140+
- Insight widgets: trends, anomaly, heatmap, category monitor
141+
- Developer widgets: coding sessions, build status, project rhythm
142+
- Ambient widgets: pet, quotes, lightweight motivation
143+
144+
### Priority Recommendation
145+
146+
- P0:
147+
- Habits Tracker
148+
- Quick Capture Inbox
149+
- Calendar Agenda
150+
- Goal Progress Ring
151+
- P1:
152+
- Distraction Radar
153+
- Focus Session Timeline
154+
- Weekly Review Board
155+
- P2:
156+
- Git Activity Summary
157+
- Build Monitor
158+
- Life Balance Radar
159+
160+
## Release Gates (Every Version)
161+
162+
- Performance gate:
163+
- Widget open/render/memory limits are measured and enforced.
164+
- Security gate:
165+
- Principle of least privilege for widget permissions.
166+
- User can audit and revoke access at any time.
167+
- Reliability gate:
168+
- Backup/restore compatibility passes for supported versions.
169+
- Data integrity checks pass on upgrade datasets.
170+
- Local-first gate:
171+
- Core journeys are fully usable when offline.
172+
173+
## Scope Boundaries
174+
175+
Still out of scope for this roadmap window:
176+
177+
- Mandatory cloud account dependency for core features
178+
- Mandatory cloud sync for daily usage data
179+
- Uploading user behavior data by default

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "timelens",
33
"private": true,
4-
"version": "1.4.2",
4+
"version": "1.4.3",
55
"authors": [
66
"Shan Wenxiao"
77
],

src-tauri/Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src-tauri/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "timelens"
3-
version = "1.4.2"
3+
version = "1.4.3"
44
description = "A screen time tracker and desktop widget manager"
55
authors = ["Shan Wenxiao"]
66
license = "MIT"

src-tauri/src/db/mod.rs

Lines changed: 58 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
use rusqlite::{params, Connection, Result};
22
use std::path::Path;
3+
use chrono::Timelike;
34

45
const SYSTEM_INTERACTIVE_EXE_WHITELIST_SQL: &str = "
56
lower(COALESCE(exe_path, '')) LIKE '%\\explorer.exe'
@@ -415,22 +416,73 @@ pub fn get_app_totals_in_range(
415416
/// Get hourly distribution (hour 0-23, seconds) for a given date.
416417
pub fn get_hourly_distribution(conn: &Connection, date: &str) -> Result<Vec<(i32, i64)>> {
417418
let ignore_system = get_bool_setting(conn, "ignore_system_processes", false)? as i32;
419+
let day_start = match chrono::NaiveDate::parse_from_str(date, "%Y-%m-%d") {
420+
Ok(d) => d.and_hms_opt(0, 0, 0),
421+
Err(_) => None,
422+
};
423+
let Some(day_start) = day_start else {
424+
return Ok(Vec::new());
425+
};
426+
let day_end = day_start + chrono::Duration::days(1);
427+
418428
let sql = format!(
419-
"SELECT CAST(strftime('%H', first_seen_at) AS INTEGER) as hour,
420-
SUM(active_seconds) as seconds
429+
"SELECT first_seen_at,
430+
active_seconds
421431
FROM app_usage
422432
WHERE date = ?1
423433
AND lower(COALESCE(exe_path, '')) NOT IN (SELECT exe_path FROM ignored_apps)
424434
AND {}
425-
GROUP BY hour
426-
ORDER BY hour",
435+
ORDER BY first_seen_at",
427436
system_process_filter_sql_with_param(2)
428437
);
429438
let mut stmt = conn.prepare(&sql)?;
430439
let rows = stmt.query_map(params![date, ignore_system], |row| {
431-
Ok((row.get::<_, i32>(0)?, row.get::<_, i64>(1)?))
440+
Ok((row.get::<_, String>(0)?, row.get::<_, i64>(1)?))
432441
})?;
433-
rows.collect()
442+
443+
let mut buckets = [0i64; 24];
444+
445+
for row in rows {
446+
let (first_seen_at, active_seconds) = row?;
447+
if active_seconds <= 0 {
448+
continue;
449+
}
450+
451+
let Ok(start_raw) = chrono::NaiveDateTime::parse_from_str(&first_seen_at, "%Y-%m-%dT%H:%M:%S") else {
452+
continue;
453+
};
454+
let seg_end_raw = start_raw + chrono::Duration::seconds(active_seconds);
455+
456+
let seg_start = if start_raw < day_start { day_start } else { start_raw };
457+
let seg_end = if seg_end_raw > day_end { day_end } else { seg_end_raw };
458+
if seg_end <= seg_start {
459+
continue;
460+
}
461+
462+
let mut cursor = seg_start;
463+
while cursor < seg_end {
464+
let hour_start = cursor
465+
.date()
466+
.and_hms_opt(cursor.time().hour(), 0, 0)
467+
.unwrap_or(cursor);
468+
let next_hour = hour_start + chrono::Duration::hours(1);
469+
let chunk_end = if next_hour < seg_end { next_hour } else { seg_end };
470+
let chunk_secs = (chunk_end - cursor).num_seconds();
471+
if chunk_secs > 0 {
472+
let hour_idx = cursor.time().hour() as usize;
473+
if hour_idx < 24 {
474+
buckets[hour_idx] += chunk_secs;
475+
}
476+
}
477+
cursor = chunk_end;
478+
}
479+
}
480+
481+
Ok(buckets
482+
.iter()
483+
.enumerate()
484+
.filter_map(|(hour, secs)| (*secs > 0).then_some((hour as i32, *secs)))
485+
.collect())
434486
}
435487

436488
/// Get total seconds for each of the past N days.

0 commit comments

Comments
 (0)