Skip to content

Conversation

@davidtaylorhq
Copy link
Member

@davidtaylorhq davidtaylorhq commented Dec 4, 2024

This makes the theme component compatible with core's glimmer topic list, while maintaining compatibility with the raw-hbs topic list.

Some parts of the logic (e.g. the masonry layout system, and the topic-list-before-link outlet) are reimplemented in a way which works in both old and new topic-lists.

Other parts are re-implemented separately for the new topic list. For those parts, the legacy versions are isolated in the topic-thumbnails-init-legacy.js initializer for future removal.

Depends on discourse/discourse#30105

@davidtaylorhq davidtaylorhq force-pushed the modernize branch 3 times, most recently from a7f26fd to a66b7bd Compare December 4, 2024 16:36
@davidtaylorhq davidtaylorhq changed the title WIP: Reimplement for new topic list DEV: Add support for glimmer topic list Dec 4, 2024
davidtaylorhq added a commit to discourse/discourse that referenced this pull request Dec 4, 2024
This makes the theme component compatible with core's glimmer topic list, while maintaining compatibility with the raw-hbs topic list.

Some parts of the logic (e.g. the masonry layout system, and the topic-list-before-link outlet) are reimplemented in a way which works in both old and new topic-lists.

Other parts are re-implemented separately for the new topic list. For those parts, the legacy versions are isolated in the `topic-thumbnails-init-legacy.js` initializer for future removal.
davidtaylorhq added a commit to discourse/discourse that referenced this pull request Dec 4, 2024
davidtaylorhq added a commit to discourse/discourse that referenced this pull request Dec 4, 2024
davidtaylorhq added a commit to discourse/discourse that referenced this pull request Dec 5, 2024
@davidtaylorhq davidtaylorhq marked this pull request as ready for review December 5, 2024 17:36
@davidtaylorhq davidtaylorhq marked this pull request as draft December 5, 2024 17:37
@davidtaylorhq davidtaylorhq marked this pull request as ready for review December 6, 2024 00:43
davidtaylorhq added a commit to discourse/discourse that referenced this pull request Dec 6, 2024

const siteSettings = api.container.lookup("service:site-settings");
if (settings.docs_thumbnail_mode !== "none" && siteSettings.docs_enabled) {
api.modifyClass("component:docs-topic-list", {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to keep it as is or can we update it to the native class syntax?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't currently have any way to control classNameBindings via the native class syntax, so will leave it for now 😬

@davidtaylorhq davidtaylorhq merged commit 5e569d4 into main Dec 16, 2024
4 checks passed
@davidtaylorhq davidtaylorhq deleted the modernize branch December 16, 2024 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants