Repository navigation
Support localized Query Preset titles through a supported configuration API #19383
cbratschi
started this conversation in
Feature Requests & Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Problem
Shared Query Presets are useful to multilingual editorial teams, but their titles cannot be translated using Payload's supported localization/configuration APIs. Every editor sees the same literal title, regardless of the selected language.
queryPresets.labelstranslates the collection label, not an individual preset's title.Verified with Payload 3.93.0 and the current
3.xsource at commit43922e0372b9fcd7c1ac088f0ac3deff10a2ddb4. This is a missing localization/customization capability, not a claim that a documented title-localization setting stopped working. I am posting here because the v3 issue template directs new capabilities to v4 feature discussions.How to observe the limitation
enableQueryPresets: truefor a collection.A schema-only check using the actual
buildConfig()in 3.93.0 confirms that an ordinarytitletext field configured withlocalized: truestays localized, while the generatedpayload-query-presets.titlefield does not. A regular config plugin cannot modify that generated field because the preset collection has not been added when plugins execute. This check does not initialize a database.Relevant source
All links below are pinned to the inspected stable-branch commit:
localized.localenorreqtofindByID. If title localization is added, this path also needs to resolve the same locale as the drawer/list, with consistent fallback. I have not reproduced an independent wrong-translated-title bug because the native title cannot currently be localized in the first place.The earlier custom-preset-hooks PR #12462 was closed without merging; it is not an available customization mechanism.
Requested behavior
Please provide supported, opt-in localized preset titles, or a documented preset-collection customization point that allows ordinary field localization. Keep existing string titles working by default and define which language controls the display, including fallback. Content locale and admin UI language are distinct settings; the chosen behavior should be explicit and consistent across the preset drawer, active preset pill and editor.
The same preset ID, filter, sharing rules and user preferences should be retained across translations. Separate copies of each preset per language or concatenating all translations into one title are poor substitutes.
Useful coverage would include translated create/edit/select, a nondefault locale, fallback for an untranslated title, an existing nonlocalized title and loading a saved active preset after navigation. Please let me know if there is an existing supported API that I missed.
All reactions