Add support for oval hole shape in Hole component and corresponding tests#2392
Closed
rushabhcodes wants to merge 6 commits into
Closed
Add support for oval hole shape in Hole component and corresponding tests#2392rushabhcodes wants to merge 6 commits into
rushabhcodes wants to merge 6 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
7890142 to
e2970fd
Compare
…into add-hole-types
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request adds support for oval-shaped PCB holes to the codebase, ensuring that the
Holecomponent, circuit JSON parsing, and testing infrastructure all recognize and handle the new "oval" shape. The main changes include updates to theHolecomponent logic, the circuit JSON component creation utility, and the addition of a dedicated test.Oval Hole Support
Holecomponent inHole.tsto recognize and handle the "oval" shape, both in dimension calculation and when inserting into the database. ([[1]](https://github.com/tscircuit/core/pull/2392/files#diff-a1e24807489838518cf5a06f03f4650aeee566fe9ba1350d2c7c7d6b2165f6d7L3-R9),[[2]](https://github.com/tscircuit/core/pull/2392/files#diff-a1e24807489838518cf5a06f03f4650aeee566fe9ba1350d2c7c7d6b2165f6d7R27-R29),[[3]](https://github.com/tscircuit/core/pull/2392/files#diff-a1e24807489838518cf5a06f03f4650aeee566fe9ba1350d2c7c7d6b2165f6d7R90-R104))createComponentsFromCircuitJson.tsutility to constructHolecomponents with the "oval" shape when parsing circuit JSON. ([lib/utils/createComponentsFromCircuitJson.tsR248-R257](https://github.com/tscircuit/core/pull/2392/files#diff-7ad9fac440629299aada6cdd6a7e3b3f17a2a159e81c275ce59100b472cdc352R248-R257))Testing
hole-oval.test.tsxto verify correct creation, storage, and rendering of oval-shaped PCB holes. ([tests/components/primitive-components/hole-oval.test.tsxR1-R26](https://github.com/tscircuit/core/pull/2392/files#diff-8d816351d93ef4353a273fd5bf21da3849fdf85e5a1345ae4bdf8aadd7632eb8R1-R26))