Skip to content

Uniform processing and output of descriptions for methods and properties#375

Merged
mspirkov merged 5 commits intomasterfrom
fix-244
Feb 17, 2026
Merged

Uniform processing and output of descriptions for methods and properties#375
mspirkov merged 5 commits intomasterfrom
fix-244

Conversation

@mspirkov
Copy link
Contributor

@mspirkov mspirkov commented Feb 17, 2026

Q A
Is bugfix?
New feature? ✔️
Breaks BC? ✔️
Fixed issues #244

Properties

image

Methods

image

@codecov
Copy link

codecov bot commented Feb 17, 2026

Codecov Report

❌ Patch coverage is 81.81818% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 80.84%. Comparing base (5c85b65) to head (23d5af6).
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
models/Context.php 0.00% 6 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master     #375      +/-   ##
============================================
+ Coverage     80.80%   80.84%   +0.03%     
- Complexity      827      828       +1     
============================================
  Files            58       58              
  Lines          2698     2714      +16     
============================================
+ Hits           2180     2194      +14     
- Misses          518      520       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mspirkov mspirkov marked this pull request as ready for review February 17, 2026 08:38
@mspirkov mspirkov requested a review from samdark February 17, 2026 08:38
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR addresses issue #244 by standardizing the processing and display of descriptions for properties and methods in API documentation. Previously, properties included the short description within the full description, while methods separated them. This inconsistency has been resolved by introducing a new helper method that uniformly processes descriptions.

Changes:

  • Introduced TextHelper::getDescriptionsByFullDescription() to uniformly split full descriptions into short and detailed parts
  • Updated PropertyDoc, TypeDoc, and Context classes to use the new helper method for consistent description processing
  • Modified propertyDetails.php and methodDetails.php templates to display descriptions uniformly with short descriptions in bold followed by detailed descriptions

Reviewed changes

Copilot reviewed 42 out of 60 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
helpers/TextHelper.php Adds new getDescriptionsByFullDescription() method to extract short and detailed descriptions from full text
tests/helpers/TextHelperTest.php Adds comprehensive test coverage for the new description parsing method
models/PropertyDoc.php Updates to use new helper method and removes unused StringHelper import
models/TypeDoc.php Updates @Property and @method tag processing to use new helper method
models/Context.php Updates getter/setter property generation to use new helper method
templates/html/views/propertyDetails.php Updates template to render short description in bold followed by detailed description, matching method pattern
templates/html/views/methodDetails.php Adds guard to prevent rendering empty description elements
tests/data/api/animal/Animal.php Adds test properties and methods with long descriptions to verify new functionality
CHANGELOG.md Documents the enhancement

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@mspirkov mspirkov merged commit 1abf3fe into master Feb 17, 2026
54 of 55 checks passed
@mspirkov mspirkov deleted the fix-244 branch February 17, 2026 16:17
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.

3 participants