Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sugar Stories Page and Authors added #618

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

MostlyKIGuess
Copy link

Fixes #571. Continuation of #613. Special thanks to @saumyashahi for the initial work on this feature!

Improvements Implemented:

  1. Dynamic Author Display

    • To display authors on any page, simply add the author: "Author Name" field.
      Author
  2. Fallback for Missing Author Information

    • Since not all _posts include author information, an initial check has been added.
    • If the author field is present, the name will be displayed. Otherwise, the layout will remain unchanged.
      Example:
      With Author
      vs
      Without Author
  3. Bug Fixes from Issue:#571 Added author name to blogs #613

    • Resolved the issue where clicking on certain links redirected users back to the "Sugar Stories" page instead of /press.
      Sugar Stories
  4. Navigation Enhancement

    • Added a direct "Sugar Stories" link in the navbar for easier access.

Further Instructions:

  1. New Stories Addition:New stories can be added by creating .md files in _post with the layout: story.

@pikurasa
Copy link
Contributor

The default name, for when we do not know the name of the author, should be "Sugar Community Member".

I did not write /stories/2016/05/15/The-connection-between-Sugar-Students-Teachers/, so using my name as author for that article is misleading.

The next step would be to add:

@MostlyKIGuess
Copy link
Author

The default name, for when we do not know the name of the author, should be "Sugar Community Member".

I did not write /stories/2016/05/15/The-connection-between-Sugar-Students-Teachers/, so using my name as author for that article is misleading.

The next step would be to add:

Would you happen to know who wrote that article?
And yes I will change the default behaviour.

As well as add the 2 articles as sugar stories .

@pikurasa
Copy link
Contributor

Would you happen to know who wrote that article?

You can see the author for both articles in the articles -- myself for the parent one, and James Simmons for the Sugar Activity one.

@MostlyKIGuess
Copy link
Author

@pikurasa I have added those stories, and everywhere we have authors made it default to Sugar Community Member as you said.

Copy link
Contributor

@quozl quozl left a comment

Choose a reason for hiding this comment

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

Trivial changes suggested.

@@ -18,6 +18,7 @@
<li class="listFont">
<a href="{{ post.url }}">{{ post.title }}</a>
<i style="display: block;">{{ post.date | date: "%b %-d %Y" }}</i>
<i class="display:block;" >By {{ page.author | default: "Sugar Community Member" }}</i>
Copy link
Contributor

Choose a reason for hiding this comment

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

Blank before tag close.

Copy link
Author

Choose a reason for hiding this comment

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

I don't understand, what exactly do I change here?

Copy link
Author

Choose a reason for hiding this comment

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

Did you mean regarding the space ber" }} and the space after double quos?. It shouldn't be a problem because it only takes the String

Copy link
Contributor

Choose a reason for hiding this comment

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

You changed <i style="display: block;"> to <<i class="display:block;" >, but my preference is <i class="display:block;">, which is shorter and more expected. When you trip your reviewer with oddness, they slow down, and if they slow down enough they say something.

Copy link
Author

Choose a reason for hiding this comment

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

I am sorry I still don't understand, it's still <i for me.

Copy link
Author

Choose a reason for hiding this comment

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

Oh I understood now, I will fix it and rebase

Copy link
Contributor

Choose a reason for hiding this comment

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

One of our monospace font training methods 30 years ago was to play Rogue or Moria. It taught the eye and brain to detect miniscule changes in text. An essential skill for programming.

Copy link
Author

Choose a reason for hiding this comment

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

Indeed, 🙂 I think I am having a hard time writing and testing spice and verilog code. I should adapt to the code and learn to write it as it was maintained before me.

@@ -31,6 +31,7 @@ <h2 class="text-center">PRESS RELEASE</h2>
<li class="listFont">
<a href="{{ post.url }}">{{ post.title }}</a>
<i style="display: block;">{{ post.date | date: "%b %-d %Y" }}</i>
<i class="display:block;" >By {{ post.author | default: "Sugar Community Member" }}</i>
Copy link
Contributor

Choose a reason for hiding this comment

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

Blank before tag close.

_layouts/story.html Outdated Show resolved Hide resolved
Copy link
Contributor

@pikurasa pikurasa left a comment

Choose a reason for hiding this comment

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

I'm asking for a few more changes before merging, but otherwise good progress.

Thanks!

@@ -0,0 +1,89 @@
---
layout: story
title: "Reflections-as-Parents-and-Teachers-Sugar-at-home-and-in-their-classroom"
Copy link
Contributor

Choose a reason for hiding this comment

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

The title should be the same as the title is in the article.

Also dashes are unnecessary. They render in the HTML, which is not what we want.

Screenshot from 2025-01-04 16-09-39

@@ -0,0 +1,29 @@
---
layout: story
title: "Writing-new-Activities-and-sharing-sugar-with-youthclassroom"
Copy link
Contributor

Choose a reason for hiding this comment

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

Please also correct this title in the manner requested for the other article.

The basic way that the Speak Activity works is by taking typed input from a user and speaking it back to them when they press return. I remember Kai walking around the house, finding words on various things around the house, typing those words into the computer, and listening to the result. It was in this way that he memorized the spelling of a few words, and, soon enough, he was creating sentences and telling the computer to speak those words back to him (or to me). It was also around this time that we went on a long family road trip, where Kai sat in the back seat typing various words and sentences and learning more and more about language.

<!-- ![](https://miro.medium.com/v2/resize:fit:977/1*8oHCHgkPpYH7UkTAoIEe2Q.jpeg) -->
<img src="/assets/stories/students2.jpg" alt="Kai Again <3" class="img-fluid" width="100%"/>
Copy link
Contributor

Choose a reason for hiding this comment

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

Are you able to alternate where the image appears on the page? (left then right then left etc.)

There's no reason they need to fill the entire width. They do so on Medium because that's the only option that they give us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add author name to blogs
4 participants