CollectionBuilder / collectionbuilder-csv

CollectionBuilder-CSV is a "stand alone" template for creating digital collection and exhibit websites using Jekyll and a metadata CSV.
MIT License
21 stars 16 forks source link

Multi-language support for theming added (i.e. German) #48

Open maehr opened 1 year ago

maehr commented 1 year ago

Dear team,

I have made some changes to the project that I believe will enhance the user experience for non-English speaking users. Specifically, I have added multi-language support for gui elements and datatables. Currently, only German language support is available, but this lays the foundation for supporting additional languages in the future.

Additionally, I have added documentation to help users understand how to change the language of the gui elements and datatables to their preferred language.

Please review these changes and let me know if you have any feedback or concerns. I believe that these improvements will make the product more accessible and user-friendly for our international customers.

Thank you for your time and consideration.

Best regards, Moritz

evanwill commented 1 year ago

@maehr we really like the idea of this PR. @owikle has been working on a multi-lingual version of CB-GH that uses javascript to actively switch between languages on one site that in some parts parallels your approach here. I think we might be able to combine the approaches to support a single language and building multi language versions. I know there is some other well translated examples in Spanish and Italian, so we could even seed it with some more default languages. We will get you in on the discussion when we have a chance to work on it!

evanwill commented 1 year ago

Also, just wanted to say the work on the datatables translation is cool--a ton of data needed! I haven't seen that done for any custom examples yet.

maehr commented 1 year ago

@evanwill thanks for reviewing my PR and to @owikle for working on the multilingual feature. Here is the rationale for my implementation (which I am absolutely not married to): My data is in German. Therefore a multilingual interface makes little sense. I just need the possibility to customize the language in the CB. Therefore I replaced the hardcoded GUI elements that were in English with Liquid Tags. I appreciate the simplicity of CB and wanted to avoid introducing too much complexity. I used a YAML file because it is easier to handle (nested entries). (We could replace it with a CSV file to make customization more consistent. Or I am also happy to contribute to @owikle implementation via the CSV file https://github.com/owikle/cb-multilingual-again/blob/main/_data/config-translation.csv.)

Please let me know how you want to proceed.

Best Moritz

PS: I completely forgot to add documentation (and credits) for datatables localization. PPS: @evanwill I've been working on the CB-csv version because it seems to be more actively maintained than the CB-gh. Am I wrong about that?

evanwill commented 1 year ago

Thanks @maehr . Yes, we tend to do development of new features in CB-CSV, then migrate them over to CB-GH. CB-GH is simplified in a few ways, but is harder to customize (especially item pages)--most things are interchangeable, but we usually have to tweak a few parts or re-implement bits that are supported by the plugins in CB-csv.

evanwill commented 4 months ago

Note: Due to the scope of this project, work on this feature has moved to a new prototype fork of CB-CSV, cb-translate. The content of this PR has been added to that repository.

maehr commented 4 months ago

@evanwill Is it ok to git reset --hard upstream/main https://github.com/CollectionBuilder/cb-translate/ and reopen the same PR over there again. My PR in its current form is not an ideal starting point and needs some work to adhere to the new guidelines/docs.