Daandelange / k3-translations

Translations menu replacement, field and section for Kirby 3.
30 stars 0 forks source link

incompatibility with sebastiangreger's commentions plugin #8

Closed hariom147 closed 1 year ago

hariom147 commented 2 years ago

I am not sure, which plugin is to "blame", but I would like to notify you as well that when installing k3-translations, the commentions plugin breaks.

sebastiangreger commented 2 years ago

Thank you, @hariom147, for reporting – I am yet to find the time to look into this, but just a quick heads-up: I have a hunch that the Commentions plugin is to "blame", as we use a slightly unconventional solution for rendering translations as seen here: https://github.com/sebastiangreger/kirby3-commentions/blob/4dc2067a8ced97d10701704ee18a1f72eaaa86f9/languages/en.php#L132

The rationale and mechanism behind this solution is documented at https://forum.getkirby.com/t/override-translations-in-plugins/17997 and I am not currently aware is overriding default locales of plugins still an issue as it was back in 2020 when this workaround was invented.

hariom147 commented 2 years ago

Thank you for your reply, @sebastiangreger. At the moment further looking into this issue is beyond my skills in regard to Kirby, but when I find the time I will try to further look into it and share anything I might find.

Daandelange commented 1 year ago

Hey, sorry for replying late and thanks for the notice. On the k3-translations side, the k-languages-dropdown Vue component is replaced, which should stay retro-compatible. It does not touch any other content, so I guess it's on the commentions-side. Any errors in the console ? I haven't commentions installed but I'll try to give it a shot.

hariom147 commented 1 year ago

Hi Daan, thanks for the reply.

Sebastian Greger, who is the developer of the Commentions plugin, that he will be sunsetting it.

So I believe this issue can be closed.

Daandelange commented 1 year ago

Just for the note, this issue seems to be due to the usage of t(...) within the translation files themselves, triggering a recursion blockage, stopping the translations parsing when the translations plugin is loaded.
This should have been fixed in https://github.com/Daandelange/k3-translations/commit/e81938b95f66df9aca99a719f5c47a864e75eae1 (untested with Commentions).