Skip to content

Conversation

@johanohly
Copy link
Owner

@johanohly johanohly commented Jan 4, 2026

  • much more, this kinda got out of hand

Improved flight creation modal layout
New mobile flight list
Browser back button now closes newest modal
Show modals as drawers on mobile
Add user editing


Summary by cubic

Adds airline icons end-to-end (display, uploads, default import) and updates flight creation/list for a smoother mobile experience. Also adds airport municipality and admin user editing, with improved modal behavior (mobile drawers and reliable back-button close).

  • New Features

    • Airline icons: new AirlineIcon component, upload support with /api/uploads, default icon import from settings.
    • Flight list (mobile): swipe to edit/delete, compact FlightCard, better grouping by year/month.
    • Flight form: unified create/edit, two-column on desktop, drawer on mobile, improved seat info and PassengerPicker with inline user creation.
    • Modals: drawers on mobile, back-button closes the latest modal.
    • Airport municipality field, shown in forms and flight cards.
    • Admin user editing via a new UserModal.
  • Migration

    • Run Prisma migrations to add airline.icon_path and airport.municipality.
    • To enable uploads, set UPLOAD_LOCATION and (optionally) mount a Docker volume; files are served from /api/uploads.
    • Replaced vaul-svelte with @johly/vaul-svelte; install new deps and rebuild.

Written for commit 6827ff9. Summary will update on new commits.

…idered valid with the municipality field missing
@johanohly johanohly self-assigned this Jan 4, 2026
@github-actions github-actions bot added the Web label Jan 4, 2026
Copy link
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

7 issues found across 210 files

Note: This PR contains a large number of files. cubic only reviews up to 75 files per PR, so some files may not have been reviewed.

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them.


<file name="src/lib/components/modals/settings/pages/data-page/airline/Airline.svelte">

<violation number="1" location="src/lib/components/modals/settings/pages/data-page/airline/Airline.svelte:94">
P2: Typo in Tailwind class: `shrink-o` should be `shrink-0` (zero, not letter &#39;o&#39;). This invalid class will have no effect on the element.</violation>
</file>

<file name="src/lib/components/modals/settings/pages/users-page/UserModal.svelte">

<violation number="1" location="src/lib/components/modals/settings/pages/users-page/UserModal.svelte:94">
P2: Password field is never reset when modal reopens because empty string is falsy. If a user types a password, closes the modal, and reopens it, the old password will still be visible. The condition should check for key existence only, not truthiness of the value.</violation>
</file>

<file name="package.json">

<violation number="1" location="package.json:98">
P2: `@types/tar@^6.1.13` is unnecessary and potentially problematic since `tar@^7.5.2` ships its own TypeScript types. Using version 6 type definitions with version 7 of the package may cause type mismatches. Remove `@types/tar` from devDependencies.</violation>
</file>

<file name="src/app.css">

<violation number="1" location="src/app.css:187">
P2: The `.scrollbar-hide` utility is incomplete - it won&#39;t hide scrollbars in Chrome, Safari, or Chromium-based Edge browsers. Add the webkit pseudo-element rule to ensure cross-browser support.</violation>
</file>

<file name="src/lib/components/helpers/confirm/ConfirmDialog.svelte">

<violation number="1" location="src/lib/components/helpers/confirm/ConfirmDialog.svelte:23">
P1: Both `onCancel` and `onConfirm` are called when user clicks Confirm. The `$effect` triggers `onCancel?.()` whenever `open` becomes false, regardless of which button was clicked. Consider tracking the action intent to distinguish between confirm and cancel.</violation>
</file>

<file name="src/lib/components/display/AirlineIcon.svelte">

<violation number="1" location="src/lib/components/display/AirlineIcon.svelte:43">
P3: The fallback icon rendering logic is duplicated in two places (Avatar.Fallback and the else block). Consider extracting this into a Svelte snippet to reduce duplication and ensure consistency if the fallback logic changes.</violation>
</file>

<file name="src/lib/components/helpers/confirm/index.ts">

<violation number="1" location="src/lib/components/helpers/confirm/index.ts:35">
P2: Calling `show()` while a confirmation is already pending will leave the previous Promise unresolved forever, as `confirm.set(newConfirm)` overwrites the store and makes the old `resolve` callback unreachable. Consider rejecting or resolving the previous Promise before setting a new one.</violation>
</file>

Since this is your first cubic review, here's how it works:

  • cubic automatically reviews your code and comments on bugs and improvements
  • Teach cubic by replying to its comments. cubic learns from your replies and gets better over time
  • Ask questions if you need clarification on any suggestion

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Jan 4, 2026

@johanohly johanohly merged commit db2b784 into main Jan 4, 2026
11 checks passed
@johanohly johanohly deleted the feat/airline-icons branch January 4, 2026 22:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants