Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,45 @@
# CHANGELOG


## v0.24.0 (2026-08-12)

### Bug Fixes

- **Core**: :bug: pin redis
([`a0262b4`](https://github.com/iandday/okletsdoit/commit/a0262b4fd663a305eaaf70480fad45b9f56e600e))

- Rebuild entry point
([`b87060a`](https://github.com/iandday/okletsdoit/commit/b87060aa4e2c5b7c4970b189f84d674914b99f61))

- **Core**: :fire: remove blank tests
([`de24dc2`](https://github.com/iandday/okletsdoit/commit/de24dc23aca54ff2eb4ab8409bbec05cb70ac71e))

### Chores

- Sync files from main (v0.23.1)
([`96a69e2`](https://github.com/iandday/okletsdoit/commit/96a69e2313d8adecb3463209f002638dd0a90cb5))

### Features

- **Core**: :sparkles: add photo review function
([`1392582`](https://github.com/iandday/okletsdoit/commit/1392582be8ec1d7bbda51f7c4314005de194948b))

- **Core**: :sparkles: initial photo review
([`f22e062`](https://github.com/iandday/okletsdoit/commit/f22e06250e50c423f82fc6218538409990c694a4))

- **Core**: :zap: extract photo gallery
([`2f1008b`](https://github.com/iandday/okletsdoit/commit/2f1008bc99c22b9e4f6fbcae695f304736910978))

- **Core**: :art: fix photo page
([`135167a`](https://github.com/iandday/okletsdoit/commit/135167ad17a98ed871ee37ac9e1b1db111ebd691))

- **Core**: :sparkles: add photos
([`cf3c8fc`](https://github.com/iandday/okletsdoit/commit/cf3c8fcb940d6108982448cf4ec675ae45a08449))

- **Core**: :zap: update guest activity toggle
([`eb27774`](https://github.com/iandday/okletsdoit/commit/eb277740386932094f5c460060a56f98601370d6))


## v0.23.1 (2026-07-22)

### Bug Fixes
Expand Down
54 changes: 51 additions & 3 deletions frontend/src/routes/planning/timeline/+page.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,47 @@ export const load: PageServerLoad = async ({ locals }) => {
};

export const actions = {
create: async ({ request, locals }) => {
const api = createApiClient(locals.sessionCookie);
const formData = await request.formData();

const name = (formData.get("name") as string | null)?.trim() || "";
const description = (formData.get("description") as string | null) ?? "";
const startRaw = (formData.get("start") as string | null) ?? "";
const endRaw = (formData.get("end") as string | null) ?? "";

const parseDateValue = (raw: string) => {
if (!raw) return null;
const parsed = new Date(raw);
return Number.isNaN(parsed.getTime()) ? null : parsed;
};

const start = parseDateValue(startRaw);
const end = parseDateValue(endRaw);

if (!name || !start) {
return fail(400, { error: "Name and start time are required" });
}

try {
const created = await api.core.coreApiCreateTimeline({
timelineCreateSchema: {
name,
description,
start,
end,
published: false,
confirmed: false,
},
});

return { success: true, created };
} catch (error) {
console.error("Failed to create timeline:", error);
return fail(500, { error: "Failed to create timeline event" });
}
},

update: async ({ request, locals }) => {
const api = createApiClient(locals.sessionCookie);
const formData = await request.formData();
Expand All @@ -28,14 +69,20 @@ export const actions = {
try {
const updateData: any = {};

const parseDateValue = (raw: string) => {
if (!raw) return null;
const parsed = new Date(raw);
return Number.isNaN(parsed.getTime()) ? null : parsed;
};

// Single field update (for toggles)
if (field && value !== null) {
if (field === "published" || field === "confirmed") {
updateData[field] = value === "true";
} else if (field === "order") {
updateData[field] = parseInt(value, 10);
} else if (field === "start" || field === "end") {
updateData[field] = value;
updateData[field] = parseDateValue(value);
} else if (field === "name" || field === "description") {
updateData[field] = value;
}
Expand All @@ -48,8 +95,9 @@ export const actions = {

if (name) updateData.name = name;
if (description !== null) updateData.description = description;
if (start) updateData.start = start;
if (end) updateData.end = end;
if (start) updateData.start = parseDateValue(start);
// Allow clearing the end time by sending null when empty.
if (formData.has("end")) updateData.end = parseDateValue(end);
}

await api.core.coreApiUpdateTimeline({
Expand Down
Loading
Loading