alexbol99 / flatten-js

Javascript library for 2d geometry
MIT License
535 stars 56 forks source link

v1.4 Relations.intersect() doesn't allow Polygon argument #149

Closed jstemo-titan closed 10 months ago

jstemo-titan commented 11 months ago

Thank you for this library.

First saw this in 1.4. Also appears in 1.4.1

const polygon = new Flatten.Polygon(new Flatten.Box(2, 2, 3, 3));
const box = new Flatten.Box(1, 1, 10, 10);
Relations.intersect(polygon, box);

Argument of type 'Polygon' is not assignable to parameter of type 'Shape'. Property 'scale' is missing in type 'Polygon' but required in type 'Shape'.

alexbol99 commented 11 months ago

Hi, @jstemo-titan This is a typescript bug, correct? I submitted a fix. I will release it soon

jstemo-titan commented 11 months ago

Hi Alex,

Yes this is a typescript bug – sorry for not being more clear. Thank you for looking into this.

-Jeremy

From: Alex Bol @.> Date: Tuesday, August 29, 2023 at 8:00 AM To: alexbol99/flatten-js @.> Cc: Stemo, Jeremy @.>, Mention @.> Subject: Re: [alexbol99/flatten-js] v1.4 Relations.intersect() doesn't allow Polygon argument (Issue #149) You don't often get email from @.*** Learn why this is importanthttps://aka.ms/LearnAboutSenderIdentification CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.

Hi, @jstemo-titanhttps://github.com/jstemo-titan This is a typescript bug, correct? I submitted a fix. I will release it soon

— Reply to this email directly, view it on GitHubhttps://github.com/alexbol99/flatten-js/issues/149#issuecomment-1697502534, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AXWQA3TCH4Z4UL7JX2HJL4TXXXYXBANCNFSM6AAAAAA32IAX7E. You are receiving this because you were mentioned.Message ID: @.***>

alexbol99 commented 10 months ago

Fixed in the patch v1.4.3