فهرست منبع

Entry header meta and home page styles.

Jeff Ong 5 سال پیش
والد
کامیت
49af591fbf

+ 2 - 1
spearhead/assets/sass/_block-extends.scss

@@ -1,2 +1,3 @@
 // Import the block extends
 // Import the block extends
-@import "block-extends/button";
+@import "block-extends/button";
+@import "block-extends/latest-posts";

+ 3 - 13
spearhead/assets/sass/_header.scss

@@ -13,21 +13,11 @@
 
 
     .site-branding {
     .site-branding {
         flex-grow: 1;
         flex-grow: 1;
-        @include media( mobile ){
-            // display: flex;
-            // justify-content: space-between;
-            // margin-top: var(--global--spacing-unit);
-            text-align: left;
-        }
+        text-align: left;
 
 
-        .site-title {
-            // letter-spacing: 1px;
-            // margin-bottom: 0;
-            // text-transform: uppercase;
-            > a {
+        .site-title > a {
                 background: inherit;
                 background: inherit;
-                text-shadow: none;
-            }
+            text-shadow: none;
         }
         }
     }
     }
 
 

+ 24 - 0
spearhead/assets/sass/_posts-and-pages.scss

@@ -0,0 +1,24 @@
+.home .post .entry-title {
+    font-size: var(--global--font-size-lg);
+    margin-bottom: 0;
+}
+
+.post .entry-header {
+    display: flex;
+    flex-direction: column;
+    .entry-title {
+        margin-bottom: 0;
+    }
+    .entry-meta {
+        order: -1;
+        .posted-on {
+            svg {
+                display: none;
+            }
+            a {
+                font-family: var(--global--font-primary);
+                text-transform: uppercase;
+            }
+        }
+    }
+}

+ 0 - 4
spearhead/assets/sass/_text.scss

@@ -6,10 +6,6 @@ a {
     font-weight: 500;
     font-weight: 500;
 }
 }
 
 
-.post .entry-title {
-    font-size: var(--global--font-size-xl);
-}
-
 // These styles to limit the paragraph may eventually apply to blog page template
 // These styles to limit the paragraph may eventually apply to blog page template
 // .entry-content,
 // .entry-content,
 // .entry-content [class*="inner-container"] {
 // .entry-content [class*="inner-container"] {

+ 8 - 0
spearhead/assets/sass/block-extends/_latest-posts.scss

@@ -0,0 +1,8 @@
+.wp-block-latest-posts {
+    > li > a {
+        color: var(--global--color-foreground);
+        &:hover {
+            color: var(--global--color-primary);
+        }
+    }
+}

+ 1 - 0
spearhead/assets/sass/style.scss

@@ -14,6 +14,7 @@ Tags: one-column, flexible-header, accessibility-ready, custom-colors, custom-me
 */
 */
 
 
 @import "responsive";
 @import "responsive";
+@import "posts-and-pages";
 @import "text";
 @import "text";
 @import "header";
 @import "header";
 @import "block-extends";
 @import "block-extends";

+ 7 - 0
spearhead/functions.php

@@ -157,4 +157,11 @@ function spearhead_fonts_url() : string {
 /**
 /**
  * Load extras
  * Load extras
  */
  */
+function seedlet_entry_meta_header() : void {
+	// Hide author, post date, category and tag text for pages.
+	if ( 'post' === get_post_type() ) {
+		// Posted on
+		seedlet_posted_on();
+	}
+}
 // require get_stylesheet_directory() . '/inc/custom-header.php';
 // require get_stylesheet_directory() . '/inc/custom-header.php';

+ 36 - 6
spearhead/style-rtl.css

@@ -76,6 +76,33 @@ Tags: one-column, flexible-header, accessibility-ready, custom-colors, custom-me
 	}
 	}
 }
 }
 
 
+.home .post .entry-title {
+	font-size: var(--global--font-size-xl);
+	margin-bottom: 0;
+}
+
+.post .entry-header {
+	display: flex;
+	flex-direction: column;
+}
+
+.post .entry-header .entry-title {
+	margin-bottom: 0;
+}
+
+.post .entry-header .entry-meta {
+	order: -1;
+}
+
+.post .entry-header .entry-meta .posted-on svg {
+	display: none;
+}
+
+.post .entry-header .entry-meta .posted-on a {
+	font-family: var(--global--font-primary);
+	text-transform: uppercase;
+}
+
 a {
 a {
 	border-bottom: none;
 	border-bottom: none;
 }
 }
@@ -98,12 +125,7 @@ a {
 
 
 .site-header .site-branding {
 .site-header .site-branding {
 	flex-grow: 1;
 	flex-grow: 1;
-}
-
-@media only screen and (min-width: 482px) {
-	.site-header .site-branding {
-		text-align: right;
-	}
+	text-align: right;
 }
 }
 
 
 .site-header .site-branding .site-title > a {
 .site-header .site-branding .site-title > a {
@@ -121,3 +143,11 @@ a {
 	color: var(--global--color-secondary);
 	color: var(--global--color-secondary);
 	margin: 6px calc( var(--global--spacing-horizontal) / 2);
 	margin: 6px calc( var(--global--spacing-horizontal) / 2);
 }
 }
+
+.wp-block-latest-posts > li > a {
+	color: var(--global--color-foreground);
+}
+
+.wp-block-latest-posts > li > a:hover {
+	color: var(--global--color-primary);
+}

+ 36 - 10
spearhead/style.css

@@ -76,6 +76,33 @@ Tags: one-column, flexible-header, accessibility-ready, custom-colors, custom-me
 	}
 	}
 }
 }
 
 
+.home .post .entry-title {
+	font-size: var(--global--font-size-lg);
+	margin-bottom: 0;
+}
+
+.post .entry-header {
+	display: flex;
+	flex-direction: column;
+}
+
+.post .entry-header .entry-title {
+	margin-bottom: 0;
+}
+
+.post .entry-header .entry-meta {
+	order: -1;
+}
+
+.post .entry-header .entry-meta .posted-on svg {
+	display: none;
+}
+
+.post .entry-header .entry-meta .posted-on a {
+	font-family: var(--global--font-primary);
+	text-transform: uppercase;
+}
+
 a {
 a {
 	border-bottom: none;
 	border-bottom: none;
 }
 }
@@ -84,10 +111,6 @@ a {
 	font-weight: 500;
 	font-weight: 500;
 }
 }
 
 
-.post .entry-title {
-	font-size: var(--global--font-size-xl);
-}
-
 @media only screen and (min-width: 482px) {
 @media only screen and (min-width: 482px) {
 	.has-main-navigation .site-header {
 	.has-main-navigation .site-header {
 		padding: calc( 2 * var(--global--spacing-vertical)) 0;
 		padding: calc( 2 * var(--global--spacing-vertical)) 0;
@@ -102,12 +125,7 @@ a {
 
 
 .site-header .site-branding {
 .site-header .site-branding {
 	flex-grow: 1;
 	flex-grow: 1;
-}
-
-@media only screen and (min-width: 482px) {
-	.site-header .site-branding {
-		text-align: left;
-	}
+	text-align: left;
 }
 }
 
 
 .site-header .site-branding .site-title > a {
 .site-header .site-branding .site-title > a {
@@ -125,3 +143,11 @@ a {
 	color: var(--global--color-secondary);
 	color: var(--global--color-secondary);
 	margin: 6px calc( var(--global--spacing-horizontal) / 2);
 	margin: 6px calc( var(--global--spacing-horizontal) / 2);
 }
 }
+
+.wp-block-latest-posts > li > a {
+	color: var(--global--color-foreground);
+}
+
+.wp-block-latest-posts > li > a:hover {
+	color: var(--global--color-primary);
+}

+ 3 - 4
spearhead/variables.css

@@ -40,7 +40,7 @@
 	--heading--line-height-h2: 1.4;
 	--heading--line-height-h2: 1.4;
 	--heading--line-height-h3: 1.4;
 	--heading--line-height-h3: 1.4;
 	
 	
-	--entry-header--font-size: var(--heading--font-size-h2);
+	--entry-header--font-size: var(--heading--font-size-h1);
 	--entry-header--color: var(--global--color-foreground);
 	--entry-header--color: var(--global--color-foreground);
 
 
 	--button--border-radius: 0px;
 	--button--border-radius: 0px;
@@ -64,9 +64,8 @@
 	--pullquote--letter-spacing: 0;
 	--pullquote--letter-spacing: 0;
 	--pullquote--line-height: 1.15;
 	--pullquote--line-height: 1.15;
 
 
-	--latest-posts--title-font-family: var(--global--font-primary);
-	--latest-posts--title-font-size: var(--global--font-size-md);
-	--latest-posts--description-font-family: var(--global--font-secondary);
+	/* --latest-posts--title-font-family: var(--global--font-secondary); */
+	--latest-posts--title-font-size: var(--global--font-size-lg);
 
 
 	--list--font-family: var(--global--font-secondary);
 	--list--font-family: var(--global--font-secondary);
 }
 }