Skip to content

Conversation

@Alex-Tideman
Copy link
Collaborator

Description & motivation 💭

Screenshots (if applicable) 📸

Design Considerations 🎨

Testing 🧪

How was this tested 👻

  • Manual testing
  • E2E tests added
  • Unit tests added

Steps for others to test: 🚶🏽‍♂️🚶🏽‍♀️

Checklists

Draft Checklist

Merge Checklist

Issue(s) closed

Docs

Any docs updates needed?

@vercel
Copy link

vercel bot commented Dec 4, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
holocene Ready Ready Preview, Comment Dec 15, 2025 3:44pm

@Alex-Tideman
Copy link
Collaborator Author

@claude review this for bugs/mistakes

@claude
Copy link

claude bot commented Dec 4, 2025

Claude finished @Alex-Tideman's task —— View job


Code Review Complete ✅

I've reviewed this PR for bugs and mistakes. Found 2 TypeScript errors and several observations:


🐛 Critical Issues

1. Type Error in event-card.svelte (Line 87-107)

The eventCategory CVA variant is missing classifications that exist in the type system.

Problem: The type EventClassification includes "Open", "New", and "Running", but the eventCategory variants only define:

  • Failed, Canceled, TimedOut, Completed, Terminated, Scheduled, Initiated, Started, Fired, Signaled, CancelRequested, Unspecified

Impact: TypeScript compilation error. Runtime error if an event has classification "Open", "New", or "Running".

Fix: Add missing variants to the CVA definition (see inline comment on the PR).

File: src/lib/components/event/event-card.svelte:87-107

2. Type Error in schedule-input.svelte

Missing required prop isRunning when using InputAndResultsPayload component.

Problem: The InputAndResultsPayload component now requires isRunning: boolean (added in this PR), but schedule-input.svelte doesn't pass it.

Impact: TypeScript compilation error. This file isn't in the PR diff but the error was introduced by changes to InputAndResultsPayload in this PR.

Fix: Either include the fix in this PR or create a follow-up. See my separate comment for details.

File: src/lib/components/schedule/schedule-input.svelte:12


⚠️ Observations

1. Potential Logic Issue in event-details-full.svelte

Line 64 accesses group.isPending without optional chaining when group could be undefined.

const emptyValue = $derived(
  group.isPending ? 'Results will appear upon completion' : 'null',
);

Should be:

const emptyValue = $derived(
  group?.isPending ? 'Results will appear upon completion' : 'null',
);

File: src/lib/components/event/event-details-full.svelte:64

See inline comment for suggested fix.

2. Unused/Unmodified State Variable

In input-and-results-payload.svelte:18, there's an inline state variable that's never modified:

let inline = $state(false);

This is used in the template but never changes. Consider if this should be:

  • A reactive variable based on some condition
  • Just a constant instead of state
  • Connected to the (now unused) $minimizeEventView store that was removed

File: src/lib/components/workflow/input-and-results-payload.svelte:18


✅ Positive Observations

  1. Svelte 5 patterns: Excellent use of $props(), $derived(), $state(), and $effect() throughout
  2. Type safety: Good use of TypeScript interfaces for Props
  3. Component structure: Clean separation with snippets
  4. Consistent styling: Proper use of Tailwind and CVA
  5. Import order: Follows CLAUDE.md guidelines correctly

📋 Summary

  • Critical bugs: 2 TypeScript errors blocking the build
  • Potential issues: 2 observations that could cause problems
  • Code quality: Generally good, following Svelte 5 and repo patterns well

Recommendation: Fix the 2 TypeScript errors before merging. Run pnpm check to verify all type errors are resolved.


Comment on lines +87 to +107
const eventCategory = cva(
['flex flex-1 flex-col overflow-hidden rounded-t-lg pb-2'],
{
variants: {
classification: {
Failed: 'bg-red-800',
Canceled: 'bg-orange-900/80',
TimedOut: 'bg-orange-700',
Completed: 'bg-green-700',
Terminated: 'bg-gray-300',
Scheduled: 'bg-orange-900/50',
Initiated: 'bg-orange-900/50',
Started: 'bg-orange-900/60',
Fired: 'bg-orange-900/90',
Signaled: 'bg-orange-900/50',
CancelRequested: 'bg-orange-900/70',
Unspecified: 'bg-orange-900/60',
},
},
},
);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Type Error: Missing classifications in CVA variants.

The EventClassification type includes "Open", "New", and "Running" but they're not defined in the variants. This will cause a TypeScript error when these classifications are used.

Add the missing variants:

Open: 'bg-orange-900/50',
New: 'bg-orange-900/50',
Running: 'bg-orange-900/60',

@claude
Copy link

claude bot commented Dec 4, 2025

Additional Issue Found (not in this PR's changes):

While running type checking, I found an error in src/lib/components/schedule/schedule-input.svelte that was likely introduced by changes in this PR to InputAndResultsPayload.

The InputAndResultsPayload component now requires an isRunning prop, but schedule-input.svelte doesn't pass it. This should be fixed in a follow-up or included in this PR if you're modifying that file.

Co-authored-by: claude[bot] <209825114+claude[bot]@users.noreply.github.com>
get finalClassification() {
return getLastEvent(this).classification;
},
get input() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • ⚠️ Property 'input' does not exist on type 'IUserMetadata | IWorkflowExecutionStartedEventAttributes | IWorkflowExecutionCompletedEventAttributes | ... 54 more ... | INexusOperationCancelRequestFailedEventAttributes'.

get input() {
return this.initialEvent.attributes?.input;
},
get result() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • ⚠️ Property 'result' does not exist on type 'IUserMetadata | IWorkflowExecutionStartedEventAttributes | IWorkflowExecutionCompletedEventAttributes | ... 54 more ... | INexusOperationCancelRequestFailedEventAttributes'.

@temporal-cicd
Copy link
Contributor

temporal-cicd bot commented Dec 15, 2025

Warnings
⚠️

📊 Strict Mode: 19 errors in 2 files (5.7% of 334 total)

src/lib/components/lines-and-dots/constants.ts (13)
  • L129:48: Function lacks ending return statement and return type does not include 'undefined'.
  • L145:6: 'group' is possibly 'undefined'.
  • L145:40: 'group' is possibly 'undefined'.
  • L148:43: 'group' is possibly 'undefined'.
  • L150:52: 'group' is possibly 'undefined'.
  • L154:70: 'group' is possibly 'undefined'.
  • L156:52: 'group' is possibly 'undefined'.
  • L158:55: 'group' is possibly 'undefined'.
  • L162:47: Argument of type 'EventGroup | undefined' is not assignable to parameter of type 'EventGroup'.
  • L163:4: 'group' is possibly 'undefined'.
  • L165:2: 'group' is possibly 'undefined'.
  • L166:9: 'group' is possibly 'undefined'.
  • L189:54: Operator '+' cannot be applied to types 'number | boolean' and 'number'.
src/lib/models/event-groups/create-event-group.ts (6)
  • L93:8: Type '(ILink | undefined)[]' is not assignable to type 'ILink[]'.
  • L103:43: Property 'input' does not exist on type 'IUserMetadata | IWorkflowExecutionStartedEventAttributes | IWorkflowExecutionCompletedEventAttributes | ... 54 more ... | INexusOperationCancelRequestFailedEventAttributes'.
  • L106:40: Property 'result' does not exist on type 'IUserMetadata | IWorkflowExecutionStartedEventAttributes | IWorkflowExecutionCompletedEventAttributes | ... 54 more ... | INexusOperationCancelRequestFailedEventAttributes'.
  • L129:24: 'event.billableActions' is possibly 'undefined'.
  • L136:61: Function lacks ending return statement and return type does not include 'undefined'.
  • L167:3: Function lacks ending return statement and return type does not include 'undefined'.

Generated by 🚫 dangerJS against 1e0cdcc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants