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

feat: add new sketch and pad global configuration options applicable to all diagrams #8

Merged
merged 2 commits into from
Apr 27, 2024

Conversation

michaeltoohig
Copy link
Contributor

Describe the pull request

Add sketch and pad values to the global config.

Why

So that I do not need to manually add sketch=true to every d2 code block if I want my website to use sketch style by default. The same for padding.

How

I updated the handling of attributes and added new sketch and pad config options. Plus, I added a test but I'm not sure I did that correctly.

Screenshots

If applicable, add screenshots to help explain what is being modified.

I want to note that I removed the default pad and perhaps you want to return that value to 100.

Copy link

vercel bot commented Apr 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
astro-d2 ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 27, 2024 1:46pm

@michaeltoohig
Copy link
Contributor Author

This is from #6

@michaeltoohig
Copy link
Contributor Author

Oops I see I accidentally committed some ugly SVGs from testing the pad config.

@michaeltoohig
Copy link
Contributor Author

@HiDeoo I just wanted to bring your attention I believe this PR is ready.

Copy link
Owner

@HiDeoo HiDeoo left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution and your patience 🙌

I took the liberty of adding a few more test cases and documented the changes so that we can release a new version with your amazing work right away.

@HiDeoo HiDeoo changed the title Add support for global sketch and pad configuration feat: add new sketch and pad global configuration options applicable to all diagrams Apr 27, 2024
@HiDeoo HiDeoo merged commit 24dda80 into HiDeoo:main Apr 27, 2024
3 checks passed
@michaeltoohig michaeltoohig deleted the feat-additional-config branch April 27, 2024 14:28
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