Opened 13 years ago
Last modified 12 days ago
#25616 new enhancement
Add a content length filter to wp_dashboard_recent_drafts()
| Reported by: | tenpura | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Administration | Version: | |
| Severity: | normal | Keywords: | dev-feedback has-patch |
| Cc: | Focuses: |
Description
It would be nice to be able to change the length of the recent drafts content via a filter. The fixed value of 10 is too short for character count based users.
Attachments (1)
Change History (4)
This ticket was mentioned in PR #12434 on WordPress/wordpress-develop by @abcd95.
12 days ago
#3
- Keywords has-patch added; needs-refresh removed
Trac ticket: https://core.trac.wordpress.org/ticket/25616
This PR introduces the dashboard_recent_drafts_word_length filter to the "Recent Drafts" dashboard widget.
Previously, the draft preview length was implicitly hardcoded to 10 words via the _x('10', 'draft_length') translation context. This severely limited content spacing. It also provided no intuitive way for theme/plugin developers to easily customize this layout.
The new filter behaves similarly to the standard excerpt_length filter, allowing developers to cleanly and safely adjust the draft preview length for their specific site's needs.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
I dont't think a filter is necessary here. We could increase the default value to 20.