Admin resources ready for contributed translations, and the pseudo-cultures in the browser (A-53)
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 25/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- csharp
- Lĩnh vực
- internationalization, testing
Hướng nghiên cứu
Start with sections 4.17, 5.1, 7, and 10.8 of docs/planning/admin-technical-spec.md, then inspect InterfaceCultureOptions.cs, LocalizationTests.cs, and eng/check-admin-size.cs. The issue defines acceptance checks across resource builds, satellite downloads, browser tests, and multiple assemblies; done means all listed acceptance criteria pass, including the ar-XB right-to-left browser case.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Problem
Row 3.18 asks for resource-based translations of the admin, and AQ14 ships English with the resources ready for contributed translations and pseudo-cultures in the tests. The exit criteria of A7 ask that the admin runs in English and in a right-to-left pseudo-culture. Today:
- One culture, and no proven path for a second.
InterfaceCultureOptions.Shippedis["en"], a list in code (admin/src/FluentCMS.Admin/Localization/InterfaceCultureOptions.cs, line 10). The repository has no resource file of a second culture (five.resxfiles, all neutral), so no build has made a satellite assembly. Nothing has shown that the app fetches the satellite assemblies of the culture chosen at start and of no other, that a lazy assembly finds its own when it loads, or that the size check leaves them out:eng/check-admin-size.csreadssatelliteResourcesof the boot configuration (lines 119 to 125), a branch no publish has reached. - The pseudo-cultures exist in bUnit only.
PseudoCulture(admin/tests/FluentCMS.Admin.Tests/PseudoLocalization.cs,en-XAandar-XB) marks every value through a localizer factory that the test context puts in place of the real one (AdminTestContext.cs, lines 92 to 95). A browser cannot run the admin right to left, so no end-to-end case and no axe-core check (A-42) sees a mirrored page. - The sweep covers one assembly.
LocalizationTestsrenders every routable page ofFluentCMS.Adminunder both pseudo-cultures (LocalizationTests.cs, lines 17 to 51 and 298). The media half and the rich text editor are not in it, and neither is what A6 adds: the administration assembly and five halves. The test of section 7 that asks every key of the neutral resources in each shipped culture does not exist, since there is one culture. - A translator would carry what is not the admin. 113 of the 706 keys of
AdminResources.resxareSystem.*, the texts of the component gallery, sample titles and names included (#3178). - Texts a translation cannot reach.
CmsLibraryTextsfeeds the component library's localizer fromCmsStrings.resx, which holds four of the library's keys; any other keeps the library's English (#3178). A menu item of a half takes its text per culture from its hand-written manifest (labels, withenalone in the media half), not from its resources, and the manifest check asks forenonly.ContentType.{name}is looked up in the resources ofFluentCMS.Adminalone (Shell/AdminLabels.cs, line 19), so only a satellite assembly of that package can name a team's types (#3178).
Proposal
- A translation is a set of resource files and nothing else. The shipped cultures come from the build: the cultures
FluentCMS.Adminhas resource files in, in place of the list in code. Each assembly of the app carries its own (AdminResources.fr.resx,CmsStrings.fr.resxand so on), each becomes a satellite assembly, and the app fetches those of the culture chosen at start only. The first download aseng/check-admin-size.csmeasures it does not change with the number of cultures. - A test of the keys. For each shipped culture and each assembly: every key of the neutral file is there, none is there that the neutral file lacks, and the placeholders of a text are those of the neutral one. It names each difference. With English alone it passes on nothing, so it is proven on the pseudo-cultures.
- The pseudo-cultures in the browser, in a test build only. With a build property (the name is open) the build writes
en-XAandar-XBresource files from the neutral ones, for every assembly of the app, with the marking ofPseudoCulture, which moves to one place that the build and the component tests share. A release build holds none. The end-to-end host is published with the property, andFluentCms:Admin:Cultures:Defaultchooses one for a run. - The sweep covers every first-party assembly. The helper that finds unmarked text moves to
admin/tests/Shared, and the test project of each half, of the rich text editor and of the administration assembly renders its pages under both pseudo-cultures. - The gallery's texts move to a resource file of their own, which the test of the keys and a translation leave out.
- The library's texts. Every text of the library that a wrapped component can show is in
CmsStrings.resxunder the library's key. A check in the browser underen-XAfinds no unmarked text in the gallery, shadow roots included; a text the library draws in script and no key reaches is listed with its component. - A half's menu texts. The manifest check asks a text in
labelsfor each culture the half has resources in, so a translated half whose manifest was forgotten fails its manifest test. - A team's type names. The app gives
AddFluentCmsAdmina resource type of its own, read before the admin's forContentType.{name}. A half's menu label stays in its manifest, as A-19 decided.
Acceptance
- A build with the pseudo-cultures publishes one satellite assembly per assembly and culture; the network shows those of the chosen culture fetched at start, none of the other, and a lazy assembly's texts in that culture once it loads
- The first download that
eng/check-admin-size.csmeasures is the same with and without the pseudo-cultures, and a release build holds no pseudo-culture - With
ar-XBas the default culture the document isdir="rtl", and an end-to-end case signs in, opens a list and a form and finds every text of the shell marked - The test of the keys names a key that a culture lacks, a key the neutral file lacks, and a text whose placeholders differ
- Every page of the administration assembly, of the rich text editor and of each half passes the sweep under both pseudo-cultures in its own test project
-
AdminResources.resxholds no key of the gallery, and no wrapped component shows an unmarked text of the library in the gallery underen-XA - The manifest test of a half fails when the half has resources in a culture that a menu label lacks
- A team's app names a content type in its own resources and the sidebar shows it
- The items of #3178 on the library's built-in strings, the gallery's texts and the label of a content type are ticked
Design: docs/planning/admin-technical-spec.md, sections 4.17, 5.1, 7 and 10.8 (A-53, split from A-41). Rows 3.18, 7.9. Takes three items of #3178. A-41 and A-42 need it. Size: M.
- Ngôn ngữ chính
- C#
- Star
- 567
- Fork
- 107
- Merge trung bình
- 1 giờ 19 phút
- Pull request đã merge (30 ngày)
- 353
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của fluentcms/FluentCMS
-
area:localization plugin type:bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
area:storage type:bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
Maintainer thường phản hồi trong vòng 1 ngày
-
area:testing type:bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
area:api area:publishing type:feature
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
fluentcms/FluentCMS#3473 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:storage plugin type:bug
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của fluentcms/FluentCMS
Issue tương tự
-
[Bug]: Threading.Analyzers 0.7.79 does not load on the .NET 10 SDK (CS9057), CHT rules silently offĐang mởbug regression threading
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
CryptoHives/Foundation#362 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[Bug]: 本地歌词翻译显示错误Đang mởbug need-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Fervent-Tempo/AF-Media-Bar#321 ·
-
a-corriger documentation
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 87/100
christian-raj/S-Aloha#345 ·
-
bug 要トリアージ
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 64/100
Maintainer thường phản hồi trong vòng 1 ngày
-
worldInstancedOccluderNode reads its appendix count as one byte, but it is a VLQCó thể đã có người làm @spuddeh đã nhận hôm nay. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày