Skip to content

feat: make translation cache column opt-in and more compact - #17

Open
YvetteNikolov wants to merge 2 commits into
mainfrom
feat/remove-translation-cache-column
Open

YvetteNikolov wants to merge 2 commits into
mainfrom
feat/remove-translation-cache-column

Conversation

@YvetteNikolov

@YvetteNikolov YvetteNikolov commented Nov 10, 2026 •

Copy link
Copy Markdown

The translation cache column made already crowded list screens wider. Now:

  • Off by default. Enable under Settings > Yard DeepL > Translation cache column.
Yard DeepL settings page with the new Translation cache column option highlighted
  • Compact: label shortened to "Cache", column fixed at 6% width, smaller badges.

Before (column takes an equal share, 619px at 1600px viewport)

Pages list before: Vertaalcache column as wide as the title column

After (6%, 160px)

Pages list after: compact Cache column

Tests: pest passes (20 tests). Checked locally: column is gone by default and comes back compact once enabled.

🤖 Generated with Claude Code

The column added a wide column to every public post type list screen. The uncached and incomplete request counters only fed this column, so they go with it instead of writing post meta on every visitor request.
@YvetteNikolov
YvetteNikolov requested a review from a team as a code owner November 10, 2026 15:25
@YvetteNikolov
YvetteNikolov requested review from ShunLuk, SimonvanWijhe, dtakken, ictbeheer, mvdhoek1, richardkorthuis and rivanuff and a balanced review from Copilot and removed request for a team November 10, 2026 15:25

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues were identified for the Translation cache column removal.

No open issues 🎉

What changed in this PR

Removes the Translation cache column from WordPress post lists to reduce clutter, while preserving the cache metabox, translation caching, and rate limiting.

Changes:

  • Removes the column provider, styles, compiled assets, and webpack entry.
  • Removes request counters used only by the column, eliminating their post-meta writes.
  • Updates tests and documentation to reflect the removal; existing counter metadata is left untouched.
File Description
webpack.config.js Removes the admin-column build entry.
tests/​Unit/​TranslationServiceTest.php Removes counter assertions while retaining cache checks.
tests/​Unit/​TranslationRepositoryTest.php Removes counter tests and retains cache-deletion coverage.
tests/​Unit/​RestAPIControllerTest.php Removes the incomplete-request counter test.
tests/​Unit/​AdminColumnsServiceProviderTest.php Deletes column-rendering tests.
src/​Traits/​CachePostTypesTrait.php Removes a comment referencing the deleted provider.
src/​Services/​TranslationService.php Removes request-counter calls and delegation.
src/​Repositories/​TranslationRepository.php Removes column data queries and counter management.
src/​Providers/​AdminColumnsServiceProvider.php Deletes column registration, rendering, and stylesheet loading.
src/​Controllers/​RestAPIController.php Stops recording incomplete-request counts.
src/​Bootstrap.php Removes the column provider registration and import.
readme.txt Removes column and badge documentation.
README.md Removes column and badge documentation.
dist/​admin-columns.js Removes the generated column JavaScript artifact.
dist/​admin-columns.css Removes compiled column styles.
dist/​admin-columns.asset.php Removes generated column asset metadata.
assets/​css/​admin-columns.css Deletes column badge source styles.

Review effort: Balanced

Restores the column and its counters, but only registers it when enabled on the settings page. Shortens the label to "Cache" and narrows the column to 6%.
@YvetteNikolov YvetteNikolov changed the title feat: remove translation cache admin column feat: make translation cache column opt-in and more compact Nov 10, 2026

@mvdhoek1 mvdhoek1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Geef maar een seintje als je merged, dan doe ik de release daarna.
Kunnen we gelijk de andere PR testen.

}

/**
* @since 2.3.0

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@since 2.3.0 -> @since NEXT, als iemand anders nu die versie uitbrengt klopt het niet meer.

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