docs: improve CrocoDocs API signature and cross-reference rendering#6442
Open
ndonkoHenri wants to merge 6 commits intorelease/v0.85.0from
Open
docs: improve CrocoDocs API signature and cross-reference rendering#6442ndonkoHenri wants to merge 6 commits intorelease/v0.85.0from
ndonkoHenri wants to merge 6 commits intorelease/v0.85.0from
Conversation
Deploying flet-examples with
|
| Latest commit: |
b901c05
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://a4fe90e0.flet-examples.pages.dev |
| Branch Preview URL: | https://improve-crocodocs.flet-examples.pages.dev |
Contributor
Author
|
@sourcery-ai review |
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Improves CrocoDocs API reference rendering by generating cleaner, multi-line signatures and displaying more modern, readable type annotations, while also shortening public cross-reference labels for extension packages.
Changes:
- Add Ruff-based formatting + type-annotation modernizing to the CrocoDocs extraction pipeline (formatted signatures,
Optional[T]→T | None, unwrapAnnotated[...]). - Render extracted
formatted_signature(and preserve return types) in the website’s API UI. - Strip
ft./flet./flet_*.prefixes from visible cross-reference labels while keeping the underlying links intact.
Reviewed changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| website/src/css/custom.css | Tweaks whitespace handling for rendered signature-like content. |
| website/src/components/crocodocs/utils.js | Centralizes Flet display-prefix stripping via a single regex. |
| website/src/components/crocodocs/ClassBlock.js | Uses extracted formatted_signature and preserves return types in method display. |
| tools/crocodocs/src/crocodocs/griffe_extract_script.py | Generates modernized annotations and Ruff-formatted signatures during extraction. |
| tools/crocodocs/pyproject.toml | Adds Ruff dependency to support signature formatting. |
| tools/crocodocs/.gitignore | Expands ignore patterns for Python tooling/artifacts. |
| sdk/python/packages/flet-map/src/flet_map/map.py | Docstring line-wrapping tweak for readability. |
| CHANGELOG.md | Adds a Documentation section entry for the CrocoDocs improvements. |
| .agents/skills/write-changelog-entry/SKILL.md | Updates changelog-writing guidance to include a Documentation section. |
| .agents/skills/docs-conventions/SKILL.md | Documents extension reference rendering conventions. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Improves CrocoDocs API rendering to make generated reference docs easier to read.
Changes
T | Noneinstead ofOptional[T].Annotated[...]in displayed type annotations.flet_map.and other extension package prefixes from visible cross-reference labels while keeping links/anchors unchanged.Summary by Sourcery
Improve CrocoDocs-generated API reference readability and consistency across signatures, type annotations, and cross-reference labels.
Enhancements:
Build:
Documentation: