Skip to content

Add optional style changing to insert/remove using the config on line…#27

Merged
oli-obk merged 7 commits intooli-obk:mainfrom
deg4uss3r:rth/add_styles_to_line_diff
Sep 11, 2025
Merged

Add optional style changing to insert/remove using the config on line…#27
oli-obk merged 7 commits intooli-obk:mainfrom
deg4uss3r:rth/add_styles_to_line_diff

Conversation

@deg4uss3r
Copy link
Copy Markdown
Contributor

@deg4uss3r deg4uss3r commented Sep 10, 2025

This adds a way to stylize our diff using the ContextConfig struct.

The default behavior does not change aside from adding Option<Style> to the ContextConfig for remove and insert operations.

I'll update docs, tests, and changeling if there's appetite for this change.

Thanks!

TODO (check if already done)

  • Update Docs comments for changes
  • Add tests
  • Add CHANGELOG.md entry

Comment thread src/text.rs Outdated
@oli-obk
Copy link
Copy Markdown
Owner

oli-obk commented Sep 11, 2025

The ability to do this sounds great. The impl may need a few iterations depending on what not using options does to the API

Comment thread src/text.rs Outdated
Comment thread src/text.rs
@oli-obk
Copy link
Copy Markdown
Owner

oli-obk commented Sep 11, 2025

Ok impl lgtm now. Should even just require a minor bump as most changes are in the private APIs.

Please update the changelog and possibly examples in the readme or docs that are affected.

@deg4uss3r deg4uss3r force-pushed the rth/add_styles_to_line_diff branch from ce9d98b to f1d855b Compare September 11, 2025 16:23
@deg4uss3r
Copy link
Copy Markdown
Contributor Author

CHANGELOG and READMEs are updated!

@oli-obk
Copy link
Copy Markdown
Owner

oli-obk commented Sep 11, 2025

Awesome, thanks! I'll publish when I'm sitting at a computer the next time and don't just have a phone xD latest next week

@oli-obk oli-obk merged commit dcabad2 into oli-obk:main Sep 11, 2025
5 checks passed
@deg4uss3r
Copy link
Copy Markdown
Contributor Author

@oli-obk Can we get a release of this change? Would it help if I put up a release PR?

@oli-obk
Copy link
Copy Markdown
Owner

oli-obk commented Oct 7, 2025

I managed to publish, but need to teach my phone how to git push before I can move the changes to github. If you want to bump the version and adjust the changelog, I would be very glad

@oli-obk
Copy link
Copy Markdown
Owner

oli-obk commented Oct 8, 2025

Oops yanked. It was a breaking change. Shame on me for not using semver checks

@deg4uss3r
Copy link
Copy Markdown
Contributor Author

Ahh sure enough yep, I opened #29 I hope that helps!

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