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

Author fields & templates; Blog App updates #1867

Merged
merged 9 commits into from
Dec 12, 2024
Merged

Conversation

burieberry
Copy link
Contributor

@burieberry burieberry commented Dec 3, 2024

Changes:

  • Add custom isolated, embedded, fitted templates for Author card
  • Added experimental field: FeaturedImage and use in author and blogpost isolated templates (uses image url, has caption/credit fields)
  • Updates from last sprint planning demo:
    • Use custom fonts only in isolated view;
    • Remove line-clamp from embedded view title and description (this means now cards may be cropped on cards-grid -- will handle cards-grid update separately)
    • Clicking "Create New" from BlogApp links the created card to the blog app by default
  • Fix display of authors in Blog App (they did not show up in current state, isUsed field property was needed)

Isolated Author:
isolated-author
isolated-small

Embedded Author:
embedded-author

One of the fitted views:
fitted-author

Copy link

github-actions bot commented Dec 3, 2024

Host Test Results

    1 files  ±0      1 suites  ±0   20m 10s ⏱️ -21s
710 tests ±0  709 ✔️ ±0  1 💤 ±0  0 ±0 
715 runs  ±0  714 ✔️ ±0  1 💤 ±0  0 ±0 

Results for commit 820f5b7. ± Comparison against base commit 9d610f8.

♻️ This comment has been updated with latest results.

@burieberry burieberry force-pushed the cs-7429-author-card branch 3 times, most recently from 4741476 to bb3ada4 Compare December 6, 2024 23:37
Comment on lines +343 to 362
let realmUrl = this.args.model[realmURL];
if (!this.args.model.id || !realmUrl?.href) {
throw new Error(`Missing card id or realm url`);
}
let relativeTo = relativeURL(
new URL(this.args.model.id),
new URL(`${cardRef.module}/${cardRef.name}`),
realmUrl,
);
if (!relativeTo) {
throw new Error(`Missing relative url`);
}
filter.query = {
filter: {
on: cardRef,
eq: { 'blog.id': this.args.model.id! },
any: [
{ eq: { 'blog.id': this.args.model.id } },
{ eq: { 'blog.id': relativeTo } },
],
},
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is to cover both relative and absolute urls in the linksTo search.

Copy link
Contributor

Choose a reason for hiding this comment

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

@habdelra @ef4 this seems like something we should normalize in our query engine

@burieberry burieberry marked this pull request as ready for review December 11, 2024 22:28
@burieberry burieberry changed the title Author fields & templates Author fields & templates; Blog App updates Dec 11, 2024
@burieberry burieberry requested a review from a team December 11, 2024 22:39
Copy link
Contributor

@lukemelia lukemelia left a comment

Choose a reason for hiding this comment

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

Looks terrific!

Copy link
Contributor

@richardhjtan richardhjtan left a comment

Choose a reason for hiding this comment

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

Looks really good! 👍

Copy link
Contributor

@jurgenwerk jurgenwerk left a comment

Choose a reason for hiding this comment

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

I tested this locally and it looks good

@burieberry burieberry merged commit 748d21f into main Dec 12, 2024
33 checks passed
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.

4 participants