Skip to content

Conversation

@SwarnimDoegar
Copy link

No description provided.

@SwarnimDoegar SwarnimDoegar changed the title Support negative values in position x and y for image and text layer Imagekit Editor improvements Jan 20, 2026
@ahnv
Copy link
Member

ahnv commented Jan 22, 2026

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7663b96035

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 2941 to +2945
} else if (focus === "coordinates") {
// Handle coordinate-based focus
// x/y are top-left coordinates, xc/yc are center coordinates
if (x) transforms.x = x
if (y) transforms.y = y
if (xc) transforms.xc = xc
if (yc) transforms.yc = yc
if (coordinateMethod === "topleft") {
if (x) transforms.x = x

Choose a reason for hiding this comment

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

P2 Badge Preserve focus coordinates when coordinateMethod is absent

This new gating on coordinateMethod means existing transformations saved before this change (which only stored focus: "coordinates" plus x/y or xc/yc) will no longer emit any coordinates unless coordinateMethod is set. In that case the formatter will silently drop the stored coordinates and the resulting crop will fall back to default positioning. Consider defaulting the branch when coordinateMethod is undefined (e.g., use x/y if present, otherwise xc/yc) to keep backward compatibility. The same pattern appears again in the imageLayer formatter.

Useful? React with 👍 / 👎.

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.

2 participants