Skip to content

Commit

Permalink
Update style references
Browse files Browse the repository at this point in the history
Formattign changes
  • Loading branch information
VitalikL committed Oct 8, 2024
1 parent 3e4e019 commit 218be68
Show file tree
Hide file tree
Showing 59 changed files with 602 additions and 498 deletions.
4 changes: 2 additions & 2 deletions ops/deploy/deploy-documents.js
Original file line number Diff line number Diff line change
Expand Up @@ -254,8 +254,8 @@ let processDocuments = async function (resourceType) {

// await database.collection(FIREBASE_DATABASE_DOCUMENTS).doc(documentInfo.id).set(documentInfo)

let defaultStyle = deepMerge(SEGMENT_DEFAULT_BLOCK_STYLES, resourceInfoYaml.defaultStyles)
documentInfo.defaultStyles = deepMerge(defaultStyle, documentInfo.defaultStyles)
let style = deepMerge(SEGMENT_DEFAULT_BLOCK_STYLES, resourceInfoYaml.style)
documentInfo.style = deepMerge(style, documentInfo.style)

fs.outputFileSync(`${API_DIST}/${documentPathInfo.language}/${resourceType}/${documentPathInfo.title}/${documentPathInfo.section ? documentPathInfo.section + "-" : ""}${documentPathInfo.document}/index.json`, JSON.stringify(documentInfo))
}
Expand Down
4 changes: 4 additions & 0 deletions ops/helpers/blocks.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ let parseBlock = async function (block, resourcePath, index, parentId, depth) {
// does not exist. In this case we will skip it
if (!processedBlock) { return null }

if (parentId !== "root") {
processedBlock.nested = true
}

return { ...processedBlock, ...blockStyle }
}

Expand Down
3 changes: 2 additions & 1 deletion ops/helpers/blocks/excerpt.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ export const excerpt = {
let item = {
id: crypto.createHash("sha256").update(`${documentIndex}-${r.id}-${block.type}-${index}`).digest("hex"),
option: passageArray.name,
type: "excerpt-item"
type: "excerpt-item",
nested: true,
}
let markdown = ""
for (let verse of Object.keys(passageArray.verses)) {
Expand Down
1 change: 1 addition & 0 deletions ops/helpers/blocks/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export const list = {
"index": index,
"id": listItemId,
"data": p.data ?? null,
"nested": true,
})
} else {
blockData.items.push(
Expand Down
108 changes: 55 additions & 53 deletions ops/helpers/styles.js
Original file line number Diff line number Diff line change
@@ -1,66 +1,68 @@
export const SEGMENT_DEFAULT_BLOCK_STYLES = {
"inline": {
"all": {
"wrapper": {
"padding": {
"start": "base",
"end": "base"
}
}
},
"blocks": [
{
"type": "reference",
"style": {
"block": {
"rounded": true
"blocks": {
"inline": {
"all": {
"wrapper": {
"padding": {
"start": "base",
"end": "base"
}
}
},
{
"type": "image",
"style": {
"block": {
"rounded": true
"blocks": [
{
"type": "reference",
"style": {
"block": {
"rounded": true
}
}
}
},
{
"type": "collapse",
"style": {
"block": {
"padding": {
"top": "none",
"bottom": "none",
"start": "none",
"end": "none"
},
{
"type": "image",
"style": {
"block": {
"rounded": true
}
}
},
{
"type": "collapse",
"style": {
"block": {
"padding": {
"top": "none",
"bottom": "none",
"start": "none",
"end": "none"
}
}
}
}
}
]
},
"nested": {
"all": {
"wrapper": {
"padding": {
"start": "none",
"end": "none"
}
}
]
},
"blocks": [
{
"type": "list",
"style": {
"wrapper": {
"padding": {
"start": "base",
"end": "none"
"nested": {
"all": {
"wrapper": {
"padding": {
"start": "none",
"end": "none"
}
}
},
"blocks": [
{
"type": "list",
"style": {
"wrapper": {
"padding": {
"start": "base",
"end": "none"
}
}
}
}
}
]
}
]
}
},
}
3 changes: 2 additions & 1 deletion ops/sync/transfer-resource-assets.js
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,8 @@ let transferResourcesFonts = async function () {
}
}

if (mode === "remote") fs.outputFileSync(resourceInfoFile, yaml.dump(resourceInfo))
// if (mode === "remote")
fs.outputFileSync(resourceInfoFile, yaml.dump(resourceInfo))
}
}

Expand Down
Binary file not shown.
40 changes: 25 additions & 15 deletions src/en/aij/2025-00-bb-pb/info.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
title: 'Baby Steps: Growing with Jesus'
subtitle: Parent Book
markdownTitle: "^[Baby Steps]({\"style\": {\"text\": {\"typeface\": \"CaliforniaPalmsScriptThicker\", \"size\": \"xl\", \"color\":\"#c18967\"}}})\\\n^[Growing with Jesus]({\"style\": {\"text\": {\"typeface\": \"Astralaga Bold\", \"size\": \"xs\",\"color\":\"#c18967\"}}})"
description: A Guide for Parents of Babies 0–12 Months at Home and in Sabbath School
primaryColor: '#E8E9E0'
primaryColorDark: '#CED0B8'
Expand All @@ -25,6 +26,9 @@ credits:
featuredResources:
- en/aij/2025-00-bb-tg
- en/aij/2025-01-bb-pth
- en/aij/2025-02-bb-pth
- en/aij/2025-03-bb-pth
- en/aij/2025-04-bb-pth
- en/aij/aij-training-videos
covers:
landscape: >-
Expand All @@ -35,23 +39,25 @@ covers:
https://sabbath-school-resources-assets.adventech.io/en/aij/2025-00-bb-pb/assets/cover.png
splash: >-
https://sabbath-school-resources-assets.adventech.io/en/aij/2025-00-bb-pb/assets/splash.png
defaultStyles:
inline:
all:
style:
blocks:
inline:
all:
text:
typeface: PTSans-Regular
nested:
all:
text:
typeface: PTSans-Regular
segment:
title:
text:
typeface: PTSans-Regular
nested:
all:
typeface: Astralaga Bold
color: '#c18967'
align: center
subtitle:
text:
typeface: PTSans-Regular
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: center
subtitle:
text:
align: center
align: center
fonts:
- name: BaskervilleBT-Bold
weight: 700
Expand Down Expand Up @@ -105,3 +111,7 @@ fonts:
weight: 600
src: >-
https://sabbath-school-resources-assets.adventech.io/en/aij/2025-00-bb-pb/assets/fonts/astralaga-semibold.ttf
- name: CaliforniaPalmsScriptThicker
weight: 400
src: >-
http://localhost:3002/api/v3/en/aij/2025-00-bb-pb/assets/fonts/CaliforniaPalms_Script_thicker.ttf
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
---
title: Trust
cover: https://sabbath-school-resources-assets.adventech.io/en/aij/2025-00-bb-pb/part-1-03-the-foundation-for-spiritual-growth/bicycle.png
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

The love you express to your baby also serves to teach trust. Unlike many baby animals, your baby has many needs and cannot survive unless they are cared for. As your baby grows, they need to trust that they will receive what they need. As with love, your little one will learn to trust you as you keep them clean and fed, and when you listen to them. As your baby grows, they will need to be reassured through your actions that you say what you mean and you mean what you say; that you will honor promises and follow through with consequences for behavior. Your little one needs to know that you can be counted on.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
---
title: Obedience
cover: https://sabbath-school-resources-assets.adventech.io/en/aij/2025-00-bb-pb/part-1-03-the-foundation-for-spiritual-growth/bees.png
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

Obedience can be learned more easily when your baby has first learned love and trust. As a parent, you have control over their life, because you make all the decisions about their daily experiences. These repeated experiences become habits and routines. Routines bring security and happiness to them, making it easier for them to obey you.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
title: Invest in Your Spiritual Health
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

{"style": {"text": {"color": "#a65726", "size": "xl", "typeface": "BaskervilleBT-Bold"}}}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
title: Invest in Your Physical and Emotional Health
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

Because you’re the object of His love, God isn’t interested in just your spiritual life. He’s interested in all aspects of your life, which includes your physical, emotional, and mental health.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
title: The Sabbath
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

Acknowledging and keeping the Sabbath is an important part of what it means to be a Seventh-day Adventist. It is a special day that is different from the other days of the week. When God rested on the Sabbath, He blessed it, He sanctified it, and He made it holy (Genesis 2:2, 3). God asks us to remember the Sabbath every Friday sundown through Saturday sundown so that we can rest from the busyness and pressures of this life, while investing in time with God, worshipping with a community of believers, and being a blessing to those we can serve. We grow in knowledge of Him and His Word, and our love for God grows deeper as we spend time with Him.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
title: Church
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

Going to church regularly will create positive Sabbath routines for your baby, your family, and yourself. Church is a wonderful opportunity to honor God on His Sabbath and be blessed. It is also a day to bless others by sharing and encouraging each other in your Christian journey. Here are some suggestions to make church a positive and joyful experience for you and your family:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
title: Baby Dedication
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

Mary and Joseph took Baby Jesus to the temple to present Him before the priest soon after His birth. It was a Jewish tradition to consecrate the boys to God. This tradition has reached down to our days as a special ceremony for your family, your baby, and your local church.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
---
title: Music
cover: https://sabbath-school-resources-assets.adventech.io/en/aij/2025-01-bb-pb/part-1-07-other-tools-for-your-babys-spiritual-growth/cover.png
defaultStyles:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
style:
segment:
title:
text:
typeface: Astralaga Bold
color: '#c18967'
align: left
---

+ Studies have shown that premature babies gain weight more easily when listening to classical music in the intensive-care unit, which contributes to them being discharged faster and having greater chances of survival (Lubetzky, Memouni, et al., 2010).
Expand Down
Loading

0 comments on commit 218be68

Please sign in to comment.