Skip to content
This repository has been archived by the owner on Sep 15, 2022. It is now read-only.

Influence order of posts on homepage and topic pages #155

Closed
rofe opened this issue Apr 7, 2020 · 7 comments
Closed

Influence order of posts on homepage and topic pages #155

rofe opened this issue Apr 7, 2020 · 7 comments
Labels
batch-1 enhancement New feature or request

Comments

@rofe
Copy link
Contributor

rofe commented Apr 7, 2020

We need articles to publish by default in chronological order, as we have now, but we also need to be able to move articles around on both the homepage and category pages. So if an important news item needs to keep top billing for a few days, we can make that happen.

@rofe rofe added enhancement New feature or request batch-1 labels Apr 7, 2020
@rofe
Copy link
Contributor Author

rofe commented Apr 7, 2020

@davidnuescheler suggested that we enable this by allowing the curator to add a list of links to the homepage or topic page using Word. Links can simply be absolute URLs copied from the staging environment. Helix would clean them up automatically to hide backend specifics. On the blog side, we would detach the list from the DOM and reorder the query hits accordingly.

@davidnuescheler
Copy link
Contributor

i quickly prototyped an implementation... find here:
https://featured-posts--theblog--adobe.hlx.page/

@rofe
Copy link
Contributor Author

rofe commented Apr 10, 2020

Cool!

Should we make the featured posts an ordered list? I think it would be more explicit for the curator, and we could simply look for a <ol> in the DOM, wherever it is...

I'd propose to open a PR for easier collaboration.

@davidnuescheler
Copy link
Contributor

i was thinking that initially as well, and then i realized that depending on how this goes, it may or may not be easier.... currently i am looking for a section that has a title "featured posts" and then simply take all the links in there... i don't think the additional constraint of an <ol> is really helpful, but you should be able to use a list as a best practice in the index.docx already...

btw. this should almost already work on topic and possibly author pages as well... just in case someone wants to try that...

@rofe
Copy link
Contributor Author

rofe commented Apr 10, 2020

i don't think the additional constraint of an <ol> is really helpful

It might be quicker for users to just insert a list than to type "featured posts" 😉. Also, we wouldn't force non-English speakers to write English in a different language branch...

but you should be able to use a list as a best practice

Makes sense.

I successfully used it on the German homepage: https://featured-posts--theblog--adobe.hlx.page/de

rofe added a commit that referenced this issue Apr 21, 2020
Co-authored-by: rofe <github@rofe.com>
Co-authored-by: Dominique Pfister <dpfister@adobe.com>
@rofe
Copy link
Contributor Author

rofe commented Apr 21, 2020

Tested on homepage, topic and author page.

@rofe rofe closed this as completed Apr 21, 2020
@rofe
Copy link
Contributor Author

rofe commented Apr 21, 2020

Documentation

Homepages

  1. Open the top level index.docx for the global homepage, or the one in a language folder
  2. Add a section underneath the title by typing --- (three dashes) followed by a line break
  3. Type Featured Posts and give it the style Heading 2
  4. Below, insert a set of URLs to existing blog posts in the order you want them to appear, separated by line breaks
  5. Refresh the homepage in your browser

Topic or author pages

  1. Navigate to the .md file of the author or topic you want to add featured posts to, then click Open in Text Editor.
  2. Add a section underneath the title by typing --- (three dashes) followed by a line break
  3. Type ## Featured Posts
  4. Below, insert an set of URLs to existing blog posts in the order you want them to appear, separated by line breaks
  5. Refresh the topic or author page in your browser

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
batch-1 enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants