浏览代码

Rainfall: Format files by exporting

Alex Lende 3 年之前
父节点
当前提交
933a91ea8a
共有 5 个文件被更改,包括 97 次插入120 次删除
  1. 9 11
      rainfall/parts/header.html
  2. 2 2
      rainfall/templates/404.html
  3. 2 2
      rainfall/templates/page.html
  4. 2 2
      rainfall/templates/single.html
  5. 82 103
      rainfall/theme.json

+ 9 - 11
rainfall/parts/header.html

@@ -1,13 +1,11 @@
 <!-- wp:group {"backgroundColor":"light-orange","layout":{"inherit":"true"}} -->
-<div class="wp-block-group has-light-orange-background-color has-background">
-	<!-- wp:group {"align":"wide","style":{"spacing":{"padding":{"bottom":"30px","top":"30px"}}},"layout":{"type":"flex","justifyContent":"space-between"}} -->
-	<div class="wp-block-group alignwide" style="padding-top:30px;padding-bottom:30px">
-		<!-- wp:site-title {"style":{"elements":{"link":{"color":{"text":"var:preset|color|black"}}},"typography":{"textTransform":"uppercase"}},"fontSize":"small"} /-->
-		<!-- wp:navigation {"layout":{"type":"flex","setCascadingProperties":true,"justifyContent":"right","orientation":"horizontal"},"style":{"spacing":{"margin":{"top":"0"}, "blockGap":"2.87rem"}}} /-->
-		</div>
-	<!-- /wp:group -->
-	<!-- wp:spacer {"height":"60px"} -->
-	<div style="height:60px" aria-hidden="true" class="wp-block-spacer"></div>
-	<!-- /wp:spacer -->
-</div>
+<div class="wp-block-group has-light-orange-background-color has-background"><!-- wp:group {"align":"wide","style":{"spacing":{"padding":{"bottom":"30px","top":"30px"}}},"layout":{"type":"flex","justifyContent":"space-between"}} -->
+<div class="wp-block-group alignwide" style="padding-top:30px;padding-bottom:30px"><!-- wp:site-title {"style":{"elements":{"link":{"color":{"text":"var:preset|color|black"}}},"typography":{"textTransform":"uppercase"}},"fontSize":"small"} /-->
+
+<!-- wp:navigation {"layout":{"type":"flex","setCascadingProperties":true,"justifyContent":"right","orientation":"horizontal"},"style":{"spacing":{"margin":{"top":"0"},"blockGap":"2.87rem"}}} /--></div>
 <!-- /wp:group -->
+
+<!-- wp:spacer {"height":"60px"} -->
+<div style="height:60px" aria-hidden="true" class="wp-block-spacer"></div>
+<!-- /wp:spacer --></div>
+<!-- /wp:group -->

+ 2 - 2
rainfall/templates/404.html

@@ -1,10 +1,10 @@
-<!-- wp:group {"backgroundColor":"light-orange"}} -->
+<!-- wp:group {"backgroundColor":"light-orange"} -->
 <div class="wp-block-group has-light-orange-background-color has-background">
     <!-- wp:template-part {"slug":"header"} /-->
 </div>
 <!-- /wp:group -->
 
-<!-- wp:group {"layout":{"inherit":true},"tagName":"main", "style":{"spacing":{"margin":{"top":"0px","right":"0px","bottom":"0px","left":"0px"}}}} -->
+<!-- wp:group {"layout":{"inherit":true},"tagName":"main","style":{"spacing":{"margin":{"top":"0px","right":"0px","bottom":"0px","left":"0px"}}}} -->
 <main class="wp-block-group" style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px">
     <!-- wp:pattern {"slug":"rainfall/hidden-404"} /-->
 </main>

+ 2 - 2
rainfall/templates/page.html

@@ -1,8 +1,8 @@
 <!-- wp:template-part {"slug":"header"} /-->
 
-<!-- wp:group {"layout": {"inherit": true}} -->
+<!-- wp:group {"layout":{"inherit":true}} -->
 <div class="wp-block-group">
-	<!-- wp:group {"align": "wide"} -->
+	<!-- wp:group {"align":"wide"} -->
 	<div class="alignwide wp-block-group">
 		<!-- wp:columns -->
 		<div class="wp-block-columns"><!-- wp:column -->

+ 2 - 2
rainfall/templates/single.html

@@ -1,8 +1,8 @@
 <!-- wp:template-part {"slug":"header"} /-->
 
-<!-- wp:group {"layout": {"inherit": true}} -->
+<!-- wp:group {"layout":{"inherit":true}} -->
 <div class="wp-block-group">
-	<!-- wp:group {"align": "wide"} -->
+	<!-- wp:group {"align":"wide"} -->
 	<div class="alignwide wp-block-group">
 		<!-- wp:columns -->
 		<div class="wp-block-columns"><!-- wp:column -->

+ 82 - 103
rainfall/theme.json

@@ -2,40 +2,40 @@
 	"$schema": "https://schemas.wp.org/trunk/theme.json",
 	"settings": {
 		"appearanceTools": true,
-        "color": {
-            "palette": [
-                {
-                    "color": "#000",
-                    "name": "Black",
-                    "slug": "black"
-                },
-                {
-                    "color": "#636363",
-                    "name": "Dark Grey",
-                    "slug": "dark-grey"
-                },
-                {
-                    "color": "#FFF",
-                    "name": "White",
-                    "slug": "white"
-                },
-                {
-                    "color": "#A43D00",
-                    "name": "Brown",
-                    "slug": "brown"
-                },
-                {
-                    "color": "#FF7D2F",
-                    "name": "Orange",
-                    "slug": "orange"
-                },
-                {
-                    "color": "#FDEEE5",
-                    "name": "Light Orange",
-                    "slug": "light-orange"
-                }
-            ]
-        },
+		"color": {
+			"palette": [
+				{
+					"color": "#000",
+					"name": "Black",
+					"slug": "black"
+				},
+				{
+					"color": "#636363",
+					"name": "Dark Grey",
+					"slug": "dark-grey"
+				},
+				{
+					"color": "#FFF",
+					"name": "White",
+					"slug": "white"
+				},
+				{
+					"color": "#A43D00",
+					"name": "Brown",
+					"slug": "brown"
+				},
+				{
+					"color": "#FF7D2F",
+					"name": "Orange",
+					"slug": "orange"
+				},
+				{
+					"color": "#FDEEE5",
+					"name": "Light Orange",
+					"slug": "light-orange"
+				}
+			]
+		},
 		"layout": {
 			"contentSize": "119ch",
 			"wideSize": "1280px"
@@ -100,11 +100,20 @@
 					"textTransform": "uppercase"
 				}
 			},
+			"core/post-title": {
+				"elements": {
+					"link": {
+						"typography": {
+							"textDecoration": "none"
+						}
+					}
+				}
+			},
 			"core/quote": {
 				"border": {
 					"color": "var(--wp--preset--color--orange)",
-					"width": "2px",
-					"style": "solid"
+					"style": "solid",
+					"width": "2px"
 				},
 				"spacing": {
 					"padding": {
@@ -128,141 +137,104 @@
 				}
 			},
 			"core/site-title": {
-				"typography": {
-					"fontWeight": "bold",
-					"fontSize": "var(--wp--preset--font--size--small)",
-					"lineHeight": {
-						"ref": "styles.typography.lineHeight"
-					}
-				},
 				"elements": {
 					"link": {
 						"typography": {
 							"textDecoration": "none"
 						}
 					}
-				}
-			},
-			"core/post-title": {
-				"elements": {
-					"link": {
-						"typography": {
-							"textDecoration": "none"
-						}
+				},
+				"typography": {
+					"fontSize": "var(--wp--preset--font--size--small)",
+					"fontWeight": "bold",
+					"lineHeight": {
+						"ref": "styles.typography.lineHeight"
 					}
 				}
 			}
 		},
 		"color": {
-			"text": "var(--wp--preset--color--black)",
-			"background": "var(--wp--preset--color--white)"
-		},
-		"typography": {
-			"fontFamily": "var(--wp--preset--font-family--helvetica-neue)",
-			"lineHeight": "1.6"
+			"background": "var(--wp--preset--color--white)",
+			"text": "var(--wp--preset--color--black)"
 		},
 		"elements": {
 			"button": {
 				"border": {
 					"radius": "0"
 				},
-				"typography": {
-					"textTransform": "uppercase"
-				},
 				"color": {
-					"text": {
-						"ref": "styles.color.background"
-					},
 					"background": {
 						"ref": "styles.color.text"
+					},
+					"text": {
+						"ref": "styles.color.background"
 					}
 				},
 				"spacing": {
 					"padding": {
+						"bottom": "18",
 						"left": "33",
 						"right": "33",
-						"bottom": "18",
 						"top": "18"
 					}
 				},
-				"//": "Pseudo-classes need to be implemented for buttons",
-				":hover": {
-					"color": {
-						"background": {
-							"ref": "styles.elements.link.:hover.color.text"
-						},
-						"text": {
-							"ref": "styles.color.background"
-						}
-					}
-				},
-				":active": {
-					"color": {
-						"background": {
-							"ref": "styles.elements.link.:active.color.text"
-						},
-						"text": {
-							"ref": "styles.color.background"
-						}
-					}
-				}
-			},
-			"heading": {
 				"typography": {
 					"textTransform": "uppercase"
 				}
 			},
 			"h1": {
 				"typography": {
-					"fontWeight": "400",
 					"fontSize": "clamp(4rem, 6vw, 6.5rem)",
+					"fontWeight": "400",
 					"lineHeight": "0.92"
 				}
 			},
 			"h2": {
 				"typography": {
-					"fontWeight": "400",
 					"fontSize": "clamp(2rem, 5vw, 2.375rem)",
+					"fontWeight": "400",
 					"lineHeight": "1"
 				}
 			},
 			"h3": {
 				"typography": {
-					"fontWeight": "700",
 					"fontSize": "var(--wp--preset--font-size--x-large)",
+					"fontWeight": "700",
 					"lineHeight": "1.2"
 				}
 			},
 			"h4": {
 				"typography": {
-					"fontWeight": "700",
 					"fontSize": "1.75rem",
+					"fontWeight": "700",
 					"lineHeight": "1.1"
 				}
 			},
 			"h5": {
 				"typography": {
-					"fontWeight": "700",
 					"fontSize": "1.5rem",
+					"fontWeight": "700",
 					"lineHeight": "1.2"
 				}
 			},
 			"h6": {
 				"typography": {
-					"fontWeight": "700",
 					"fontSize": "var(--wp--preset--font-size--small)",
+					"fontWeight": "700",
 					"lineHeight": "1.3"
 				}
 			},
+			"heading": {
+				"typography": {
+					"textTransform": "uppercase"
+				}
+			},
 			"link": {
-				"color": {
-					"text": {
-						"ref": "styles.color.text"
+				":active": {
+					"color": {
+						"text": "var(--wp--preset--color--brown)"
 					}
 				},
-				"typography": {
-					"textDecoration": "underline"
-				},
 				":hover": {
 					"color": {
 						"text": "var(--wp--preset--color--dark-grey)"
@@ -271,15 +243,22 @@
 						"textDecoration": "none"
 					}
 				},
-				":active": {
-					"color": {
-						"text": "var(--wp--preset--color--brown)"
+				"color": {
+					"text": {
+						"ref": "styles.color.text"
 					}
+				},
+				"typography": {
+					"textDecoration": "underline"
 				}
 			}
 		},
 		"spacing": {
 			"blockGap": "2.5rem"
+		},
+		"typography": {
+			"fontFamily": "var(--wp--preset--font-family--helvetica-neue)",
+			"lineHeight": "1.6"
 		}
 	},
 	"templateParts": [
@@ -293,4 +272,4 @@
 		}
 	],
 	"version": 2
-}
+}