-
Notifications
You must be signed in to change notification settings - Fork 103
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
Feat: Page Builder Featured Pages Component #389
Feat: Page Builder Featured Pages Component #389
Conversation
Hey @leandrocp could you help me with something here? I am not really sure what to do with @published_date and @@image_path. |
4bce575
to
1f57bb1
Compare
@edborsa I just realized the issue isn't well described but you're still on the right path. Components are supposed to be reusable, and even though this one is extracted from dockyard.com, it still needs to be as generic as possible providing a default implementation that can be overwritten, thus we need to:
So the component call will look like this: <BeaconWeb.Components.featured_pages /> Which should render a row with 3 pages displaying the But the user may want to change which pages are displayed, so that component can accept a <BeaconWeb.Components.featured_pages pages={Beacon.Content.list_pages(@beacon.site, per_page: 3, query: "products", sort: :title)} /> Not only that but the user may want to customize how the pages are displayed as well: <BeaconWeb.Components.featured_pages :let={page} pages={Beacon.Content.list_pages(...)}>
<article ...>
<%= page.title %>
</article>
</BeaconWeb.Components.featured_pages> Some notes:
I hope that's more clear now but feel free to ask. Thanks! |
Signed-off-by: Eduardo Borsa <[email protected]>
Signed-off-by: Eduardo Borsa <[email protected]>
f5329f4
to
bf014df
Compare
Signed-off-by: Eduardo Borsa <[email protected]>
bf014df
to
2404a86
Compare
25b9bbc
to
2e5f4db
Compare
@leandrocp I think I got it. |
❤️ |
Issue: #357