Conversation
|
Updates to Preview Branch (feature/bug-sweep) ↗︎
Tasks are run on every commit but only new migration files are pushed.
View logs for this Workflow Run ↗︎. |
There was a problem hiding this comment.
8 issues found across 27 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="apps/app/src/hooks/use-variant-form.ts">
<violation number="1" location="apps/app/src/hooks/use-variant-form.ts:280">
P2: Rounding before the negative check means small negative percentages (e.g., -0.004) become 0 and bypass validation. Validate the raw percentage value before rounding so any negative input is rejected.</violation>
</file>
<file name="packages/dpp-components/src/lib/google-fonts.ts">
<violation number="1" location="packages/dpp-components/src/lib/google-fonts.ts:104">
P2: The variable-font weight filter can return an empty list, producing malformed `:wght@` URLs.</violation>
</file>
<file name="apps/app/src/components/select/font-select.tsx">
<violation number="1" location="apps/app/src/components/select/font-select.tsx:134">
P2: The pending auto-select flag is not cleared when no new custom font is added, which can cause unexpected future auto-selection on later `customFonts` updates.</violation>
</file>
<file name="packages/dpp-components/src/components/layout/product-image.tsx">
<violation number="1" location="packages/dpp-components/src/components/layout/product-image.tsx:24">
P2: Using `width={0}` and `height={0}` on `next/image` removes meaningful intrinsic sizing and can cause layout shift now that the fixed aspect-ratio wrapper was removed.</violation>
</file>
<file name="apps/app/src/hooks/use-passport-form.ts">
<violation number="1" location="apps/app/src/hooks/use-passport-form.ts:257">
P2: Validate raw percentage bounds before rounding; current check can accept slightly negative or >100 inputs.</violation>
</file>
<file name="packages/dpp-components/src/components/materials/materials-frame.tsx">
<violation number="1" location="packages/dpp-components/src/components/materials/materials-frame.tsx:29">
P2: Scheme detection is case-sensitive, so valid mixed/uppercase `http(s)` URLs are transformed into malformed links.</violation>
</file>
<file name="packages/dpp-components/src/components/product/product-details.tsx">
<violation number="1" location="packages/dpp-components/src/components/product/product-details.tsx:32">
P2: Protocol detection is case-sensitive, which can generate malformed links for valid mixed/upper-case `http(s)` URLs.</violation>
</file>
<file name="apps/app/src/components/theme-editor/panel/views/typography-editor.tsx">
<violation number="1" location="apps/app/src/components/theme-editor/panel/views/typography-editor.tsx:200">
P2: Variable fonts without a `wght` axis incorrectly expose all weight options (100–900), allowing unsupported font weights to be selected.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
packages/dpp-components/src/components/layout/product-image.tsx
Outdated
Show resolved
Hide resolved
packages/dpp-components/src/components/materials/materials-frame.tsx
Outdated
Show resolved
Hide resolved
packages/dpp-components/src/components/product/product-details.tsx
Outdated
Show resolved
Hide resolved
apps/app/src/components/theme-editor/panel/views/typography-editor.tsx
Outdated
Show resolved
Hide resolved
Greptile SummaryThis is a broad feature/bug sweep touching 36 files across the DPP, app, and shared packages. The main themes are: adding YouTube to the social links feature set (type, defaults, demo data, footer, component tree), surfacing manufacturer website and certification URLs as clickable links in the DPP, replacing hardcoded Google Fonts weight lists with font-metadata-aware weight resolution, floating-point-safe percentage arithmetic in the materials block and validation hooks, and a collection of UI polish fixes (image quality, popover sizing, scroll-to-selected, font auto-select after upload). Key changes:
Confidence Score: 3/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant User
participant TypographyEditor
participant FontSelect
participant GoogleFontsLib
participant GoogleFonts
User->>FontSelect: Selects font family
FontSelect->>GoogleFontsLib: generateGoogleFontsUrlForFont(family)
GoogleFontsLib->>GoogleFontsLib: isGoogleFont(family)
alt Google Font
GoogleFontsLib->>GoogleFontsLib: getFontWeights(family)<br/>(reads font metadata/axes)
GoogleFontsLib-->>FontSelect: Fonts CSS URL with exact weights
FontSelect->>GoogleFonts: Load stylesheet link
else Local/Custom Font
GoogleFontsLib-->>FontSelect: "" (skip)
end
FontSelect-->>TypographyEditor: onValueChange(fontFamily)
TypographyEditor->>TypographyEditor: getAvailableWeightOptions(fontFamily, customFonts)
TypographyEditor->>TypographyEditor: useEffect: validate current fontWeight<br/>vs available options
alt Weight not available
TypographyEditor->>TypographyEditor: onChange(fallbackWeight)
end
User->>TypographyEditor: Saves theme
TypographyEditor->>GoogleFontsLib: generateGoogleFontsUrlFromTypography(typography)
GoogleFontsLib-->>TypographyEditor: Combined URL for all scale fonts
TypographyEditor->>GoogleFonts: Inject preconnect + stylesheet links
|
packages/dpp-components/src/components/product/product-details.tsx
Outdated
Show resolved
Hide resolved
🚀 Preview Deployment SummaryApp: https://avelero-9zxwovq6p-avelero.vercel.app Preview environments will auto-delete when PR closes. |
There was a problem hiding this comment.
1 issue found across 14 files (changes from recent commits).
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="packages/jobs/src/trigger/bulk/export-qr-codes.ts">
<violation number="1" location="packages/jobs/src/trigger/bulk/export-qr-codes.ts:97">
P2: This adds a duplicate implementation of storage public URL remapping that already exists in packages/supabase/src/utils/storage.ts. Reuse the shared utility to avoid divergence and reduce maintenance overhead.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
🚀 Preview Deployment SummaryApp: https://avelero-ivubmq137-avelero.vercel.app Preview environments will auto-delete when PR closes. |
🚀 Preview Deployment SummaryApp: ❌ Failed Preview environments will auto-delete when PR closes. |
🚀 Preview Deployment SummaryApp: https://avelero-bdq7k6ir3-avelero.vercel.app Preview environments will auto-delete when PR closes. |
There was a problem hiding this comment.
4 issues found across 13 files (changes from recent commits).
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="packages/jobs/src/trigger/catalog/fan-out.ts">
<violation number="1" location="packages/jobs/src/trigger/catalog/fan-out.ts:59">
P2: The queue config doesn’t enforce the “1 per brand” behavior described in the comment. Without a `concurrencyKey`, `concurrencyLimit: 5` applies to the whole queue and allows concurrent runs for the same brand, which can still step on each other’s snapshot writes. Consider using a per-brand `concurrencyKey` at trigger time (or align the comment/config).</violation>
</file>
<file name="apps/api/src/trpc/routers/catalog/index.ts">
<violation number="1" location="apps/api/src/trpc/routers/catalog/index.ts:371">
P2: New fan-out branch duplicates core CRUD logic instead of reusing shared helpers, increasing maintenance drift risk.</violation>
<violation number="2" location="apps/api/src/trpc/routers/catalog/index.ts:445">
P1: Delete fan-out is triggered after FK nullification, which can miss affected published products for manufacturer/certification deletions.</violation>
</file>
<file name="packages/db/src/queries/products/catalog-fan-out.ts">
<violation number="1" location="packages/db/src/queries/products/catalog-fan-out.ts:108">
P2: Certification fan-out duplicates material fan-out query logic instead of sharing one implementation, creating a high risk of future logic drift.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
🚀 Preview Deployment SummaryApp: https://avelero-9no6is4m6-avelero.vercel.app Preview environments will auto-delete when PR closes. |
🚀 Preview Deployment SummaryApp: https://avelero-mgf1ztw69-avelero.vercel.app Preview environments will auto-delete when PR closes. |
Summary by cubic
Strengthens theme editing and DPP with stable materials, adaptive fonts, sharper images, and safe external links. Adds storage‑domain config and URL remapping across apps, revalidates DPP passports on publish via UPID/barcode tags, and introduces a delete‑safe catalog fan‑out that auto‑republishes affected products.
New Features
Bug Fixes
Written for commit 1ce0cc3. Summary will update on new commits.