Skip to content

feat: collection color image management#3904

Merged
gaspergrom merged 1 commit intomainfrom
feat/collection-image-color
Mar 10, 2026
Merged

feat: collection color image management#3904
gaspergrom merged 1 commit intomainfrom
feat/collection-image-color

Conversation

@gaspergrom
Copy link
Contributor

@gaspergrom gaspergrom commented Mar 10, 2026

Note

Medium Risk
Touches the collections DB schema and write path (create/insert) while extending the admin UI payload, so mismatches between migrations, API validation, and consumers could cause runtime errors or missing data.

Overview
Adds appearance customization for collections by introducing new imageUrl (card image) and color fields end-to-end.

This updates the admin collection create/edit drawer to collect and submit these fields (with URL validation and a color picker), extends the frontend collection/request models, and updates the data-access-layer createCollection insert to persist them.

Includes forward/backward SQL migrations to add/remove the collections.imageUrl and collections.color columns, and expands scripts/cli clean-start-fe-dev ignored services to keep more backend workers stopped during FE-only dev.

Written by Cursor Bugbot for commit 0803878. This will update automatically on new commits. Configure here.

Signed-off-by: Gašper Grom <gasper.grom@gmail.com>
@gaspergrom gaspergrom self-assigned this Mar 10, 2026
@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

2 similar comments
@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

@gaspergrom gaspergrom closed this Mar 10, 2026
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

INSERT INTO collections (name, description, slug, "categoryId", starred, "logoUrl")
VALUES ($(name), $(description), $(slug), $(categoryId), $(starred), $(logoUrl))
INSERT INTO collections (name, description, slug, "categoryId", starred, "logoUrl", "imageUrl", color)
VALUES ($(name), $(description), $(slug), $(categoryId), $(starred), $(logoUrl), $(imageUrl), $(color))
Copy link

Choose a reason for hiding this comment

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

SQL references missing properties, breaking existing callers

High Severity

The createCollection SQL now references $(imageUrl) and $(color) named parameters, but ICreateCollection declares these as optional (color?: string | null, imageUrl?: string | null). The existing caller in segmentService.ts passes an object without imageUrl or color. Since pgp.as.format throws when a named parameter references a property that doesn't exist on the object, this will cause a runtime error and break the segment creation flow.

Additional Locations (1)

Fix in Cursor Fix in Web


<!-- Card image URL -->
<article class="mb-6">
<lf-field label-text="Card image URL" :required="true">
Copy link

Choose a reason for hiding this comment

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

UI marks fields required but validation allows empty

Medium Severity

The imageUrl field's lf-field has :required="true" (showing a required indicator to the user), but the validation rules at line 265 only include { url } without a required validator. Vuelidate's url validator passes for empty strings, so the form can be submitted with an empty imageUrl despite the UI indicating it's mandatory.

Additional Locations (1)

Fix in Cursor Fix in Web

@gaspergrom gaspergrom reopened this Mar 10, 2026
@github-actions
Copy link
Contributor

⚠️ Jira Issue Key Missing

Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability.

Example:

  • feat: add user authentication (CM-123)
  • feat: add user authentication (IN-123)

Projects:

  • CM: Community Data Platform
  • IN: Insights

Please add a Jira issue key to your PR title.

@gaspergrom gaspergrom merged commit c332703 into main Mar 10, 2026
25 checks passed
@gaspergrom gaspergrom deleted the feat/collection-image-color branch March 10, 2026 09:30
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.

1 participant