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

Build Article index and show views #10

Merged
merged 6 commits into from
May 1, 2024

Conversation

JoshAntBrown
Copy link
Contributor

@JoshAntBrown JoshAntBrown commented May 1, 2024

/claim #8
Resolves #8

This PR builds out the index and show views for Article. I've also created a couple of helpers for reading time and one that selects a gradient per article. Gradient selection is calculated using the article's id ensuring that all the articles don't change gradients on each refresh or page navigation.

Lucide doesn't appear to have up to date icons for X/Twitter, and the LinkedIn one looks different, I'll look into these later though — perhaps we could add our own icons to the lucide package?

For the content I've used the simple_format helper to ensure new lines are split into paragraphs, this can easily be swapped out at some point if you end up using a rich text editor or plan to drop html directly into the content of the article.

maybe-article-views.mov

app/helpers/articles_helper.rb Show resolved Hide resolved
app/models/article.rb Outdated Show resolved Hide resolved
@Shpigford Shpigford merged commit 9fc138c into maybe-finance:main May 1, 2024
4 checks passed
@JoshAntBrown JoshAntBrown deleted the feature/article-views branch May 1, 2024 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build out Article index and show views
2 participants