Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: Shape.shadows is potentially null #191

Open
malliaridis opened this issue Feb 7, 2025 · 1 comment
Open

bug: Shape.shadows is potentially null #191

malliaridis opened this issue Feb 7, 2025 · 1 comment
Labels
bug Something isn't working managed on taiga This issue has been moved to our project at Taiga.io

Comments

@malliaridis
Copy link

Steps To Reproduce

  1. Create board
  2. Access the shape's shadows via penpot.selection.shapes[id].shadows

Expected behavior

Shape.shadows is not null, but empty array [] in case when there is no shadow set for a shape.

Actual behavior

Shape.shadows is null.

Screenshots or video

No response

Desktop (please complete the following information)

No response

Smartphone (please complete the following information)

Browser / Chrome

Environment (please complete the following information)

https://design.penpot.app

Frontend Stack Trace

Backend Stack Trace

Additional context

When trying to access the shadows from a Shape, if no shadows are defined, the field is null instead of empty array [] as the API (and penpot-types define it).

I am not sure if the plugins API should be updated or if this should be updated in penpot so that it returns an empty array instead (which is preferred).

@malliaridis malliaridis added the bug Something isn't working label Feb 7, 2025
@madalenapmelo-kp madalenapmelo-kp added the managed on taiga This issue has been moved to our project at Taiga.io label Feb 19, 2025
@madalenapmelo-kp
Copy link

Hi @malliaridis,

Thanks for reporting this! We've added this to our backlog on Taiga so that we can look further into it, you can find the details here: https://tree.taiga.io/project/penpot/issue/10263

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working managed on taiga This issue has been moved to our project at Taiga.io
Projects
None yet
Development

No branches or pull requests

2 participants