Sorry for a very long query – I tried to make it as short as possible but it’s rarely possible with the i18n related stuff 🙁
I’m working on a multilingual D8 site. The default language is English, other languages will be gradually added for users’ convenience. All new content will be first added in English, then gradually translated into other enabled languages. Due to the dynamic nature of the content, at no point in time ALL content will be translated into ALL languages but nevertheless any user regardless of the UI language currently selected should see ALL content relevant to their query regardless of whether it has been translated to the current UI language or not. If an entity has a translation to the current user’s UI language (let’s make it Russian for brevity) then it should be displayed in Russian, if not – it should be displayed in English.
If I apply no language-related filters to a view at all, every translation is shown as one more row in the view output, along with its English original which is not good. If I filter on “Translation language” equals “Interface text language selected for page” then I only see the content that has been translated which is no good either. I added “Default translation (= True)” filter and chose “Interface text language selected for page” for Rendering Language. This way I see ALL content, each entity ONLY ONCE, and if it has been translated then its label in the teaser is in Russian, if not then it’s displayed in English. Looks good so far BUT once I click on a link in the list leading to an untranslated entity, not only the content is displayed in English which is expected behaviour but the UI language falls back to English as well which is not quite what I want.
When I look at the links to entities generated by the view in the teaser list (which displays perfectly in itself), I see that the links to translated entities include the language in their paths (e.g. /ru/node/5) while the links to untranslated entities don’t (e.g. /node/6). Obviously when I click on such a link I lose the UI language forever. But if I manually enter the URL /ru/node/6 it correctly displays Russian interface and English content (for lack of Russian translation of that particular node).
QUESTION: What do I do to the view for it to produce links to the Russian (translated) versions of node pages (always with /ru/ in them) REGARDLESS of whether there exists a Russian translation for that node or not?