backdrop-contrib / flippy

Flippy generates previous/next pagers for content types.
GNU General Public License v2.0
0 stars 0 forks source link

Multilingual support #3

Open olafgrabienski opened 5 months ago

olafgrabienski commented 5 months ago

When I enable Flippy for a content type on a multilanguage site, the pager links usually don't point to other posts but to the same post in another language.

I guess this happens because translations have a separate node ID, so the 'next' NID of a certain post is often its translation. This can also happen when you other sorting criteria, e.g. by Title.

Is there a hidden trick to flip through a list of pages of the same language? Or are you open to add a respective feature?

laryn commented 5 months ago

Definitely open to it and don't know of a trick at the moment -- probably needs to be tweaked for multilingual.

Looks like this is included in the D7 version, and I'm not quite sure why it's not in this version! https://git.drupalcode.org/project/flippy/-/blob/7.x-1.x/flippy.module?ref_type=heads#L351-363

olafgrabienski commented 5 months ago

Interesting! I couldn't find a related commit in the D7 version (see search result), so the $language related part seems to be in D7 for quite a while. Maybe an oversight during the Backdrop port?

olafgrabienski commented 5 months ago

Ha, wait: no oversight, but removed "for now" in https://github.com/backdrop-contrib/flippy/commit/ae033f93cbb6b259b6eebb824f5f17dc580b633f.