Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions BilingualBlog/85de4d7a-e9d8-459d-80a7-d9f0508c9ea1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"data": {
"type": "card",
"attributes": {
"translation": "",
"headline": "",
"slug": null,
"body": "To quote wikipedia:\n\nMicroblogging is a form of blogging using short posts without titles known as microposts[1][2][3] (or status updates on a minority of websites like Meta Platforms'). Microblogs \"allow users to exchange small elements of content such as short sentences, individual images, or video links\",[1] which may be the major reason for their popularity.[4] Some popular social networks such as Twitter, Threads, Mastodon, Tumblr, Koo, and Instagram can be viewed as collections of microblogs.",
"publishDate": null,
"featuredImage": {
"imageUrl": null,
"credit": null,
"caption": null,
"altText": null,
"size": "actual",
"height": null,
"width": null
},
"cardDescription": null,
"cardThumbnailURL": null
},
"relationships": {
"authorBio": {
"links": {
"self": null
}
},
"blog": {
"links": {
"self": null
}
}
},
"meta": {
"adoptsFrom": {
"module": "../bilingual-blog",
"name": "BilingualBlog"
}
}
}
}
134 changes: 134 additions & 0 deletions CardListing/b2b43084-8be5-49c1-894f-7f8ceb6e70e4.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
{
"data": {
"meta": {
"adoptsFrom": {
"name": "CardListing",
"module": "https://realms-staging.stack.cards/catalog/catalog-app/listing/listing"
}
},
"type": "card",
"attributes": {
"name": "BilingualBlog",
"images": [],
"summary": "The BilingualBlog is a specialized blog post card that extends the standard BlogPost to support content in two languages. It adds a translation field designed to hold a complete French translation of the blog post body. Its primary purpose is to facilitate bilingual content presentation within a card-driven content system.",
"cardInfo": {
"name": null,
"notes": null,
"summary": null,
"cardThumbnailURL": null
}
},
"relationships": {
"tags.0": {
"links": {
"self": "https://realms-staging.stack.cards/catalog/Tag/4d0f9ae2-048e-4ce0-b263-7006602ce6a4"
}
},
"specs.0": {
"links": {
"self": "../Spec/050d0757-f0bf-4401-bd5b-74cffa5d0c38"
}
},
"specs.1": {
"links": {
"self": "../Spec/98a7b9f4-86d5-448c-a77c-99c7dfc6cd88"
}
},
"specs.2": {
"links": {
"self": "../CatalogEntry/author"
}
},
"specs.3": {
"links": {
"self": "../CatalogEntry/blog"
}
},
"specs.4": {
"links": {
"self": "../Spec/d5b48c27-7c99-47df-86cd-88dfec16b031"
}
},
"specs.5": {
"links": {
"self": "../Spec/86d5b48c-277c-49c7-9fc6-cd88dfec16b0"
}
},
"specs.6": {
"links": {
"self": "../CatalogEntry/blog-post"
}
},
"specs.7": {
"links": {
"self": "../Spec/b48c277c-99c7-4fc6-8d88-dfec16b03120"
}
},
"specs.8": {
"links": {
"self": "../Spec/16b03120-8ae6-4b78-9a10-0314e0050563"
}
},
"specs.9": {
"links": {
"self": "../Spec/ec16b031-208a-46eb-b81a-100314e00505"
}
},
"specs.10": {
"links": {
"self": "../Spec/dfec16b0-3120-4ae6-ab78-1a100314e005"
}
},
"specs.11": {
"links": {
"self": "../CatalogEntry/fields/contact-link-field"
}
},
"specs.12": {
"links": {
"self": "../CatalogEntry/fields/featured-image-field"
}
},
"specs.13": {
"links": {
"self": "../Spec/99c7dfc6-cd88-4fec-96b0-31208ae6eb78"
}
},
"skills": {
"links": {
"self": null
}
},
"license": {
"links": {
"self": "https://realms-staging.stack.cards/catalog/License/4c5a023b-a72c-4f90-930b-da60a1de5b2d"
}
},
"publisher": {
"links": {
"self": null
}
},
"categories.0": {
"links": {
"self": "https://realms-staging.stack.cards/catalog/Category/content-creation"
}
},
"examples.0": {
"links": {
"self": "../BilingualBlog/85de4d7a-e9d8-459d-80a7-d9f0508c9ea1"
}
},
"cardInfo.theme": {
"links": {
"self": null
}
},
"cardInfo.cardThumbnail": {
"links": {
"self": null
}
}
}
}
}
30 changes: 30 additions & 0 deletions CatalogEntry/author.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"data": {
"type": "card",
"attributes": {
"readMe": "what is this going on",
"ref": {
"name": "Author",
"module": "../author"
},
"specType": "card",
"containedExamples": [],
"title": "Author",
"description": "Spec for Author",
"thumbnailURL": null
},
"relationships": {
"linkedExamples": {
"links": {
"self": null
}
}
},
"meta": {
"adoptsFrom": {
"module": "https://cardstack.com/base/spec",
"name": "Spec"
}
}
}
}
20 changes: 20 additions & 0 deletions CatalogEntry/blog-post.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"data": {
"type": "card",
"attributes": {
"title": "BlogPost",
"description": "Spec for BlogPost",
"specType": "card",
"ref": {
"module": "../blog-post",
"name": "BlogPost"
}
},
"meta": {
"adoptsFrom": {
"module": "https://cardstack.com/base/spec",
"name": "Spec"
}
}
}
}
20 changes: 20 additions & 0 deletions CatalogEntry/blog.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"data": {
"type": "card",
"attributes": {
"title": "Blog",
"description": "Spec for Blog App card",
"ref": {
"module": "../blog-app",
"name": "BlogApp"
},
"specType": "card"
},
"meta": {
"adoptsFrom": {
"module": "https://cardstack.com/base/spec",
"name": "Spec"
}
}
}
}
19 changes: 19 additions & 0 deletions CatalogEntry/fields/contact-link-field.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"data": {
"type": "card",
"attributes": {
"title": "Contact Link Field",
"specType": "field",
"ref": {
"module": "../../fields/contact-link",
"name": "ContactLinkField"
}
},
"meta": {
"adoptsFrom": {
"module": "https://cardstack.com/base/spec",
"name": "Spec"
}
}
}
}
19 changes: 19 additions & 0 deletions CatalogEntry/fields/featured-image-field.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"data": {
"type": "card",
"attributes": {
"title": "Featured Image Field",
"specType": "field",
"ref": {
"module": "../../fields/featured-image",
"name": "FeaturedImageField"
}
},
"meta": {
"adoptsFrom": {
"module": "https://cardstack.com/base/spec",
"name": "Spec"
}
}
}
}
40 changes: 40 additions & 0 deletions Spec/050d0757-f0bf-4401-bd5b-74cffa5d0c38.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"data": {
"meta": {
"adoptsFrom": {
"name": "Spec",
"module": "https://cardstack.com/base/spec"
}
},
"type": "card",
"attributes": {
"ref": {
"name": "BilingualBlog",
"module": "../bilingual-blog"
},
"title": "BilingualBlog",
"readMe": "# BilingualBlog\n\nThe BilingualBlog card definition extends the base BlogPost card, adding a `translation` field that contains the blog post content translated to French.\n\n## Import\n\nTo import the BilingualBlog code, use the following:\n\n```js\nimport { BilingualBlog } from 'https://realms-staging.stack.cards/experiments/bilingual-blog/bilingual-blog';\n```\n\n## Define Field\n\nThe `translation` field is defined as a `contains(StringField)` field, which means it is an embedded field within the BilingualBlog card.\n\n```js\n@field translation = contains(StringField, {\n description: 'A full translation of the blog post body in French'\n});\n```\n\n## Invoke Template\n\nIn templates, you can access the `translation` field using the fields API:\n\n```hbs\n<div class=\"translation\">\n <@fields.translation />\n</div>\n```\n\n## Dependencies\n\nThe BilingualBlog card definition depends on the following:\n\n- `BlogPost` card definition\n- `StringField` from the Boxel base API\n- `Langugages` icon from the Boxel icon set\n\n## Usage and Examples\n\nThe BilingualBlog card can be used anywhere a BlogPost card would be used, but with the added benefit of having a French translation of the post body available.\n\nHere's an example of how you might use the BilingualBlog card:\n\n```json\n{\n \"data\": {\n \"type\": \"card\",\n \"attributes\": {\n \"title\": \"Bienvenue sur notre blog!\",\n \"body\": \"Ceci est le contenu de notre premier article de blog bilingue.\",\n \"translation\": \"Welcome to our blog!\\nThis is the content of our first bilingual blog post.\"\n },\n \"meta\": {\n \"adoptsFrom\": {\n \"module\": \"./bilingual-blog\",\n \"name\": \"BilingualBlog\"\n }\n }\n }\n}\n```\n\nIn this example, the `BilingualBlog` card is used to display a blog post with both the original French content and the English translation.",
"cardInfo": {
"notes": null,
"title": null,
"description": null,
"thumbnailURL": null
},
"specType": "card",
"description": null,
"containedExamples": []
},
"relationships": {
"cardInfo.theme": {
"links": {
"self": null
}
},
"linkedExamples": {
"links": {
"self": null
}
}
}
}
}
40 changes: 40 additions & 0 deletions Spec/16b03120-8ae6-4b78-9a10-0314e0050563.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"data": {
"type": "card",
"attributes": {
"readMe": null,
"ref": {
"module": "../components/grid",
"name": "CardsGrid"
},
"specType": "component",
"containedExamples": [],
"cardTitle": "CardsGrid",
"cardDescription": null,
"cardInfo": {
"name": null,
"summary": null,
"cardThumbnailURL": null,
"notes": null
}
},
"relationships": {
"linkedExamples": {
"links": {
"self": null
}
},
"cardInfo.theme": {
"links": {
"self": null
}
}
},
"meta": {
"adoptsFrom": {
"module": "https://cardstack.com/base/spec",
"name": "Spec"
}
}
}
}
Loading
Loading