Skip to content

Commit 83a4421

Browse files
committed
chore: v0.11.0 release
- Bump nextjs version to address security CVE-2025-55182 - Add week start preference setting (0=Sunday, 1=Monday) with UI controls in appearance settings - Implement new week-month-picker component with customizable week start support - Update calendar views and task scheduling components to respect week start preference - Cancellable quick add parsed patterns - Fix #215 - Refactor data migration system into modular functions for better maintainability - Update type imports to use @tasktrove/packages structure consistently across codebase - Add comprehensive test coverage for new week start functionality - Improve import route with better version normalization and migration handling - Update branding assets (icons, app icons) with improved designs - Refactor notification sound ordering settings for better UX - Clean up drag-drop utilities and UI component organization - Add new appearance form with theme and week start controls - Update project and task components to use new type system structure
1 parent 27d9438 commit 83a4421

269 files changed

Lines changed: 6235 additions & 4200 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# tasktrove
22

3+
## 0.11.0
4+
5+
### Features
6+
7+
🎉 Feature - Add week start preference setting (0=Sunday, 1=Monday) with UI controls in appearance settings
8+
🎉 Feature - Implement new week-month-picker component with customizable week start support
9+
🎉 Feature - Update calendar views and task scheduling components to respect week start preference
10+
🎉 Feature - Cancellable quick add parsed patterns
11+
12+
### Patch Changes
13+
14+
🐛 Bug - Bump nextjs version to address security CVE-2025-55182
15+
🐛 Bug - Fix #215
16+
317
## 0.10.0
418

519
### Features

apps/web/app/api/[...notFound]/route.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { describe, it, expect } from "vitest"
22
import { NextRequest } from "next/server"
33
import { GET, POST, PATCH, DELETE } from "./route"
4-
import { ApiErrorCode } from "@/lib/types"
4+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
55

66
describe("API 404 Catch-All Handler", () => {
77
const createRequest = (path: string, method: string) => {

apps/web/app/api/[...notFound]/route.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { NextRequest, NextResponse } from "next/server"
2-
import { ApiErrorCode, ErrorResponse } from "@/lib/types"
2+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
3+
import type { ErrorResponse } from "@tasktrove/types/api-responses"
34

45
/**
56
* Catch-all route handler for non-existent API endpoints

apps/web/app/api/backup/route.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@ import { withMutexProtection } from "@/lib/utils/api-mutex"
44
import { withAuthentication } from "@/lib/middleware/auth"
55
import { withApiVersion } from "@/lib/middleware/api-version"
66
import { withApiLogging } from "@/lib/middleware/api-logger"
7-
import { ApiErrorCode, ErrorResponse, API_ROUTES } from "@/lib/types"
7+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
8+
import type { ErrorResponse } from "@tasktrove/types/api-responses"
9+
import { API_ROUTES } from "@tasktrove/types/constants"
810

911
async function createBackup() {
1012
try {

apps/web/app/api/data/initialize/route.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ import { withMutexProtection } from "@/lib/utils/api-mutex"
55
import { withApiVersion } from "@/lib/middleware/api-version"
66
import { writeInitialDataFile } from "@/lib/utils/data-initialization"
77
import { withApiLogging, type EnhancedRequest } from "@/lib/middleware/api-logger"
8-
import { ApiErrorCode, ErrorResponse, API_ROUTES } from "@/lib/types"
8+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
9+
import { API_ROUTES } from "@tasktrove/types/constants"
10+
import { type ErrorResponse } from "@tasktrove/types/api-responses"
911
import { DataInitializeRequestSchema } from "@tasktrove/types/api-requests"
1012
import { validateRequestBody, createErrorResponse } from "@/lib/utils/validation"
1113

apps/web/app/api/data/migrate/route.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,10 @@ import { withAuthentication } from "@/lib/middleware/auth"
77
import { withApiVersion } from "@/lib/middleware/api-version"
88
import { withApiLogging } from "@/lib/middleware/api-logger"
99
import { safeWriteDataFile } from "@/lib/utils/safe-file-operations"
10-
import type { Json, ErrorResponse } from "@/lib/types"
11-
import { ApiErrorCode, API_ROUTES } from "@/lib/types"
10+
import type { Json } from "@tasktrove/types/constants"
11+
import type { ErrorResponse } from "@tasktrove/types/api-responses"
12+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
13+
import { API_ROUTES } from "@tasktrove/types/constants"
1214

1315
async function migrateData() {
1416
try {

apps/web/app/api/health/route.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
CURRENT_API_VERSION,
88
SUPPORTED_API_VERSIONS,
99
} from "@/lib/middleware/api-version"
10-
import { API_ROUTES } from "@/lib/types"
10+
import { API_ROUTES } from "@tasktrove/types/constants"
1111

1212
async function healthCheck() {
1313
try {

apps/web/app/api/import/route.test.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import { describe, it, expect, beforeEach, vi } from "vitest"
22
import { POST } from "./route"
3-
import { DEFAULT_EMPTY_DATA_FILE, createVersionString } from "@/lib/types"
3+
import { DEFAULT_EMPTY_DATA_FILE } from "@tasktrove/types/defaults"
4+
import { createVersionString } from "@tasktrove/types/id"
5+
import { LATEST_DATA_VERSION } from "@tasktrove/types/schema-version"
46
import { safeReadDataFile, safeWriteDataFile } from "@/lib/utils/safe-file-operations"
57
import { createMockEnhancedRequest } from "@/lib/utils/test-helpers"
68

@@ -66,7 +68,7 @@ describe("/api/import", () => {
6668

6769
const request = buildRequest({
6870
...baseImportPayload,
69-
version: createVersionString("v0.10.0"),
71+
version: LATEST_DATA_VERSION,
7072
})
7173

7274
const response = await POST(request)
@@ -81,12 +83,12 @@ describe("/api/import", () => {
8183
it("allows import when versions match", async () => {
8284
mockSafeReadDataFile.mockResolvedValue({
8385
...DEFAULT_EMPTY_DATA_FILE,
84-
version: createVersionString("v0.10.0"),
86+
version: LATEST_DATA_VERSION,
8587
})
8688

8789
const request = buildRequest({
8890
...baseImportPayload,
89-
version: createVersionString("v0.10.0"),
91+
version: LATEST_DATA_VERSION,
9092
})
9193

9294
const response = await POST(request)

apps/web/app/api/import/route.ts

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,14 @@ import { withAuthentication } from "@/lib/middleware/auth"
1111
import { withApiVersion } from "@/lib/middleware/api-version"
1212
import { createErrorResponse } from "@/lib/utils/validation"
1313
import { log } from "@/lib/utils/logger"
14-
import { DataFile, DataFileSchema, JsonSchema, ApiErrorCode, API_ROUTES } from "@/lib/types"
15-
import type { ErrorResponse, ProjectId, LabelId } from "@/lib/types"
14+
import { DataFileSchema } from "@tasktrove/types/data-file"
15+
import { JsonSchema } from "@tasktrove/types/constants"
16+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
17+
import { API_ROUTES } from "@tasktrove/types/constants"
18+
import type { DataFile } from "@tasktrove/types/data-file"
19+
import { LATEST_DATA_VERSION } from "@tasktrove/types/schema-version"
20+
import type { ErrorResponse } from "@tasktrove/types/api-responses"
21+
import type { ProjectId, LabelId } from "@tasktrove/types/id"
1622
import { migrateDataFile, needsMigration, getMigrationInfo } from "@/lib/utils/data-migration"
1723
import { compareVersions } from "@tasktrove/utils/version"
1824

@@ -38,9 +44,20 @@ async function importData(
3844
// Validate import data structure - accepts any JSON object
3945
const rawImportData = JsonSchema.parse(body)
4046

47+
// Ensure version exists for migration checks; fall back to latest when absent
48+
const normalizedImportData =
49+
typeof rawImportData === "object" &&
50+
rawImportData !== null &&
51+
!Array.isArray(rawImportData) &&
52+
(!("version" in rawImportData) ||
53+
rawImportData.version == null ||
54+
rawImportData.version === "")
55+
? { ...rawImportData, version: LATEST_DATA_VERSION }
56+
: rawImportData
57+
4158
// Get migration info for the import data
42-
const requiresMigration = needsMigration(rawImportData)
43-
const migrationInfo = getMigrationInfo(rawImportData)
59+
const requiresMigration = needsMigration(normalizedImportData)
60+
const migrationInfo = getMigrationInfo(normalizedImportData)
4461

4562
log.info(
4663
{
@@ -54,7 +71,7 @@ async function importData(
5471
let importData: DataFile
5572
try {
5673
if (requiresMigration) {
57-
importData = migrateDataFile(rawImportData)
74+
importData = migrateDataFile(normalizedImportData)
5875
log.info(
5976
{
6077
module: "import",
@@ -67,7 +84,7 @@ async function importData(
6784
)
6885
} else {
6986
// No migration needed, validate and use data as-is
70-
importData = DataFileSchema.parse(rawImportData)
87+
importData = DataFileSchema.parse(normalizedImportData)
7188
log.info(
7289
{
7390
module: "import",

apps/web/app/api/v1/assets/[...path]/route.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import { NextResponse } from "next/server"
22
import { readFile } from "fs/promises"
33
import { getSecureAssetPath } from "@/lib/utils/path-validation"
4-
import { ApiErrorCode, ErrorResponse, API_ROUTES } from "@/lib/types"
4+
import { ApiErrorCode } from "@tasktrove/types/api-errors"
5+
import type { ErrorResponse } from "@tasktrove/types/api-responses"
6+
import { API_ROUTES } from "@tasktrove/types/constants"
57
import { withAuthentication } from "@/lib/middleware/auth"
68
import { withApiVersion } from "@/lib/middleware/api-version"
79
import { withApiLogging, type EnhancedRequest, logSecurityEvent } from "@/lib/middleware/api-logger"

0 commit comments

Comments
 (0)