Add RustyWind::sort_class_value for sorting bare class attribute values - #151
Add RustyWind::sort_class_value for sorting bare class attribute values#151UnknownPlatypus wants to merge 1 commit into
RustyWind::sort_class_value for sorting bare class attribute values#151Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughAdds ChangesClass-value sorting
Estimated code review effort: 2 (Simple) | ~15 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
| Filename | Overview |
|---|---|
| rustywind-core/src/app.rs | Adds the public bare-value sorting method and reuses its template-aware classification helper across existing document extraction paths. |
| rustywind-core/tests/template_aware_sorting.rs | Adds coverage for static and dynamic values, local duplicate removal, malformed syntax, wrapping configuration, and equivalence with document sorting. |
| rustywind-core/CHANGELOG.md | Documents the new sort_class_value public API and its intended parser-integration use case. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Caller supplies class value and SourceLanguage] --> B[sort_class_value]
B --> C[sortable_class_value]
C -->|No wrapping| D[Analyze language-specific static runs]
C -->|Configured wrapping| E[Parse validated wrapped class list]
D --> F[Sort each static run independently]
E --> G[Sort wrapped classes]
F --> H[Return sorted or borrowed value]
G --> H
C -->|Opaque or invalid| I[Return original borrowed value]
Reviews (1): Last reviewed commit: "Add `RustyWind::sort_class_value` for so..." | Re-trigger Greptile
Hi !
I'm trying to integrate rustywind to djangofmt and was needing an api to format a class content directly, respecting the template language
I've added an api for that and updated existing code to reuse it.
Let me know what you think
Summary by CodeRabbit
New Features
Bug Fixes
Documentation