Skip to content

Personalized products - #39

Merged
alexphelps merged 4 commits into
mainfrom
personalized-products
Jul 31, 2026
Merged

Personalized products#39
alexphelps merged 4 commits into
mainfrom
personalized-products

Conversation

@alexphelps

Copy link
Copy Markdown
Member

No description provided.

@cloudflare-workers-and-pages

cloudflare-workers-and-pagesBot commented Jul 31, 2026

Copy link
Copy Markdown

Deploying with Cloudflare Workers Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

StatusNameLatest CommitPreview URLUpdated (UTC)
✅ Deployment successful!
View logs
developer-docs220696aCommit Preview URL

Branch Preview URL
Jul 31 2026, 08:59 AM

Comment threadnext-env.d.ts Outdated
/// <reference types="next" />
/// <reference types="next/image-types/global" />
import"./.next/dev/types/routes.d.ts";
import"./.next/types/routes.d.ts";

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

WARNING:next-env.d.ts is auto-generated by Next.js; manual edits are overwritten on the next next dev/next build. The comment in this file explicitly says it should not be edited.

If this change is required to fix a TypeScript build, do it upstream in Next.js rather than committing it here. If it's just a drift correction that Next will regenerate, drop it from this PR to avoid future rebase churn.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

| request | The current `request` context object. |
| product | The `product` context object. |
| form_type | The form type, typically `'single'`. |
| quantity_type | Accepts `'single'` or `'multiple'`. |

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

WARNING: The third positional argument to {% cart_form %} was renamed from form_type to quantity_type in this table, but I see no other change in the PR that proves the underlying tag keyword was also renamed. If the platform code still accepts form_type, this table is now incorrect and will mislead theme authors.

Verify against the source of the cart_form template tag and either keep the documented name (form_type) or rename the tag keyword in the same change so the docs stay accurate.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

{% purchase_info_for_product request product as session %}
{% if session.availability.is_available_to_buy %}
{% cart_form request product 'single' as cart_form %}
<form id="add-to-cart" class="row g-3" action="{% url 'cart:add' pk=product.pk %}" method="post">

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

WARNING: The form action now uses {% url 'cart:add' pk=product.pk %} here, but the cart_form invocation snippet immediately above on line 100 (which this PR did not touch) still uses {% url 'cart:add' product.slug %}. Two different URL kwargs on the same docs page will confuse readers.

Pick one (PK or slug) and make both examples use it, or call out explicitly when the add endpoint expects pk versus slug.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

{% purchase_info_for_product request product as session %}
{% if session.availability.is_available_to_buy %}
{% cart_form request product 'single' as cart_form %}
<form id="add-to-cart" action="{% url 'cart:add' pk=product.pk %}" method="post">

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

WARNING: Same URL-kwargs inconsistency surfaces again: this guide uses {% url 'cart:add' pk=product.pk %} while the cart_form tag reference still uses product.slug on tags.mdx:100. Make the two pages agree.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

| Empty values | A property submitted with an empty value does not create a separate line. It is still recorded on the line, so guard your display with `{% if property.value %}`. |
| Hidden properties | Property names starting with an underscore, such as `properties[_source]`, are stored but excluded from `line.properties` and from the Storefront GraphQL API. Use them for data that should not be shown to customers. |
| Value length | Values longer than 500 characters are truncated to 500 characters. |
| Checkboxes | When a checkbox named `properties[...]` changes, the value submitted is `yes` or `no`. |

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

SUGGESTION: The "Checkboxes" row promises that a checkbox named properties[...] submits yes or no, but no example input is shown anywhere in the guide. Add a short <input type="checkbox" name="properties[GiftWrap]"> example alongside the existing text input so theme authors do not have to guess the wire format.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

| Template | View-Specific Context |
| ----- | ------ |
| `templates/index.html` | Global objects only. Use the [`where`](/docs/storefront/themes/templates/tags#where) tag to query products and categories. |
| `templates/cart.html` | `formset` (cart line forms, each `form.instance` is a [line](#line)) |

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

SUGGESTION: The added templates/cart.html row says the context provides formset, but the formset type/shape is documented only via the new ### line section above. Consider giving formset its own short entry (or at minimum a sentence under line) so readers understand they get a Django formset of line forms, not a plain list.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

@kilo-code-bot

kilo-code-botBot commented Jul 31, 2026

Copy link
Copy Markdown

Code Review Summary

Status: No New Issues Found | Recommendation: Address existing findings before merge

Overview

SeverityCount
CRITICAL0
WARNING0
SUGGESTION0

The incremental commit (220696a) only changes one line in the auto-generated next-env.d.ts (import path ./.next/types/routes.d.ts -> ./.next/dev/types/routes.d.ts). The existing inline comment on that file (id 3688961428) already covers the underlying issue (Next.js auto-generates this file; the edit will be overwritten). No new findings on changed lines.

Files Reviewed (1 file in incremental diff)
  • next-env.d.ts - 0 new issues (existing WARNING still applies)

Fix these issues in Kilo Cloud

Previous Review Summary (commit dda098b)

Current summary above is authoritative. Previous snapshots are kept for context only.

Previous review (commit dda098b)

Status: 6 Issues Found | Recommendation: Address before merge

Overview

SeverityCount
CRITICAL0
WARNING4
SUGGESTION2
Issue Details (click to expand)

WARNING

FileLineIssue
next-env.d.ts3Next.js auto-generates this file; the inline comment explicitly says it should not be edited. Manual edit will be overwritten on the next build.
content/docs/storefront/themes/templates/tags.mdx153Tag argument renamed form_type -> quantity_type in this row, but no other PR change proves the underlying tag keyword was renamed. If the platform still accepts form_type, the docs are now wrong.
content/docs/storefront/themes/templates/tags.mdx111New form example uses {% url 'cart:add' pk=product.pk %} while the unchanged snippet on the same page (line 100) uses {% url 'cart:add' product.slug %}. Inconsistent URL kwargs on one docs page.
content/docs/storefront/themes/guides/personalized-products.mdx27Same pk=product.pk vs product.slug inconsistency mirrors across this guide and tags.mdx.

SUGGESTION

FileLineIssue
content/docs/storefront/themes/guides/personalized-products.mdx81"Checkboxes" row promises yes/no values but no checkbox input example is shown; add one for parity with the text example.
content/docs/storefront/themes/templates/objects.mdx794New templates/cart.html context row references formset but does not document what formset actually is (Django formset of line forms).
Files Reviewed (5 files)
  • content/docs/storefront/themes/guides/personalized-products.mdx - 2 issues
  • content/docs/storefront/themes/templates/tags.mdx - 2 issues
  • content/docs/storefront/themes/templates/objects.mdx - 1 issue
  • next-env.d.ts - 1 issue
  • content/docs/storefront/themes/guides/meta.json - 0 issues

Fix these issues in Kilo Cloud


Reviewed by minimax-m3 · Input: 23.8K · Output: 1.7K · Cached: 143.8K

@alexphelps
alexphelps merged commit 9afc729 into mainJul 31, 2026
1 of 2 checks passed
Sign up for freeto 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

@alexphelps