瀏覽代碼

match the seedlet author bio markup to the jetpack markup

Ben Dwyer 4 年之前
父節點
當前提交
95c115960b

+ 2 - 2
seedlet/assets/css/print.css

@@ -41,7 +41,7 @@ Andreas Hecht in https://www.jotform.com/blog/css-perfect-print-stylesheet-98272
 	.has-regular-font-size,
 	.has-large-font-size,
 	h2.author-title,
-	p.author-bio,
+	p.entry-author,
 	.comments-title, h3 {
 		font-size: 14pt;
 		margin-top: 25px;
@@ -101,7 +101,7 @@ Andreas Hecht in https://www.jotform.com/blog/css-perfect-print-stylesheet-98272
 	.site-branding-container:before,
 	.entry .entry-title:before,
 	.entry-footer,
-	.author-description:before,
+	.author-bio:before,
 	.post-navigation,
 	.widget-area,
 	.comment-form-flex,

文件差異過大導致無法顯示
+ 0 - 0
seedlet/assets/css/print.css.map


+ 4 - 4
seedlet/assets/css/style-editor.css

@@ -1756,21 +1756,21 @@ pre.wp-block-verse {
  * Author
  */
 /* Author description */
-.author-bio {
+.entry-author {
 	font-size: var(--global--font-size-xs);
 	max-width: var(--responsive--aligndefault-width);
 }
 
-.site-main > article > .author-bio {
+.site-main > article > .entry-author {
 	margin-top: calc(2 * var(--global--spacing-vertical));
 }
 
-.author-bio .author-title {
+.entry-author .author-title {
 	font-family: var(--entry-author-bio--font-family);
 	font-size: var(--entry-author-bio--font-size);
 }
 
-.author-bio .author-description {
+.entry-author .author-bio {
 	font-size: var(--global--font-size-md);
 }
 

文件差異過大導致無法顯示
+ 0 - 0
seedlet/assets/css/style-editor.css.map


+ 2 - 2
seedlet/assets/sass/components/entry/_author-bio.scss

@@ -4,7 +4,7 @@
 
 /* Author description */
 
-.author-bio {
+.entry-author {
 
 	font-size: var(--global--font-size-xs);
 	max-width: var(--responsive--aligndefault-width);
@@ -18,7 +18,7 @@
 		font-size: var(--entry-author-bio--font-size);
 	}
 
-	.author-description {
+	.author-bio {
 		font-size: var(--global--font-size-md);
 	}
 }

+ 2 - 2
seedlet/assets/sass/print.scss

@@ -51,7 +51,7 @@ Andreas Hecht in https://www.jotform.com/blog/css-perfect-print-stylesheet-98272
   .has-regular-font-size,
   .has-large-font-size,
   h2.author-title,
-  p.author-bio,
+  p.entry-author,
   .comments-title, h3 {
     font-size: 14pt;
     margin-top: 25px;
@@ -126,7 +126,7 @@ Andreas Hecht in https://www.jotform.com/blog/css-perfect-print-stylesheet-98272
   .site-branding-container:before,
   .entry .entry-title:before,
   .entry-footer,
-  .author-description:before,
+  .author-bio:before,
   .post-navigation,
   .widget-area,
   .comment-form-flex,

+ 2 - 2
seedlet/assets/sass/structure/_vertical-margins.scss

@@ -84,7 +84,7 @@
 .post-thumbnail,
 .entry-content,
 .entry-footer,
-.author-bio,
+.entry-author,
 .widget-area {
 	margin-top: var(--global--spacing-vertical);
 	margin-right: auto;
@@ -131,7 +131,7 @@
 .post-thumbnail > *,
 .page-content > *,
 .comment-content > *,
-.author-bio > *,
+.entry-author > *,
 .widget > * {
 	margin-top: var(--global--spacing-unit);
 	margin-bottom: var(--global--spacing-unit);

+ 8 - 8
seedlet/style-rtl.css

@@ -441,7 +441,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail,
 .entry-content,
 .entry-footer,
-.author-bio,
+.entry-author,
 .widget-area {
 	margin-top: var(--global--spacing-vertical);
 	margin-left: auto;
@@ -510,7 +510,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail > *,
 .page-content > *,
 .comment-content > *,
-.author-bio > *,
+.entry-author > *,
 .widget > * {
 	margin-top: var(--global--spacing-unit);
 	margin-bottom: var(--global--spacing-unit);
@@ -521,7 +521,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail > *:first-child,
 .page-content > *:first-child,
 .comment-content > *:first-child,
-.author-bio > *:first-child,
+.entry-author > *:first-child,
 .widget > *:first-child {
 	margin-top: 0;
 }
@@ -531,7 +531,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail > *:last-child,
 .page-content > *:last-child,
 .comment-content > *:last-child,
-.author-bio > *:last-child,
+.entry-author > *:last-child,
 .widget > *:last-child {
 	margin-bottom: 0;
 }
@@ -3290,21 +3290,21 @@ nav a {
  * Author
  */
 /* Author description */
-.author-bio {
+.entry-author {
 	font-size: var(--global--font-size-xs);
 	max-width: var(--responsive--aligndefault-width);
 }
 
-.site-main > article > .author-bio {
+.site-main > article > .entry-author {
 	margin-top: calc(2 * var(--global--spacing-vertical));
 }
 
-.author-bio .author-title {
+.entry-author .author-title {
 	font-family: var(--entry-author-bio--font-family);
 	font-size: var(--entry-author-bio--font-size);
 }
 
-.author-bio .author-description {
+.entry-author .author-bio {
 	font-size: var(--global--font-size-md);
 }
 

+ 8 - 8
seedlet/style.css

@@ -441,7 +441,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail,
 .entry-content,
 .entry-footer,
-.author-bio,
+.entry-author,
 .widget-area {
 	margin-top: var(--global--spacing-vertical);
 	margin-right: auto;
@@ -510,7 +510,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail > *,
 .page-content > *,
 .comment-content > *,
-.author-bio > *,
+.entry-author > *,
 .widget > * {
 	margin-top: var(--global--spacing-unit);
 	margin-bottom: var(--global--spacing-unit);
@@ -521,7 +521,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail > *:first-child,
 .page-content > *:first-child,
 .comment-content > *:first-child,
-.author-bio > *:first-child,
+.entry-author > *:first-child,
 .widget > *:first-child {
 	margin-top: 0;
 }
@@ -531,7 +531,7 @@ Included in theme screenshot and in block patterns.
 .post-thumbnail > *:last-child,
 .page-content > *:last-child,
 .comment-content > *:last-child,
-.author-bio > *:last-child,
+.entry-author > *:last-child,
 .widget > *:last-child {
 	margin-bottom: 0;
 }
@@ -3311,21 +3311,21 @@ nav a {
  * Author
  */
 /* Author description */
-.author-bio {
+.entry-author {
 	font-size: var(--global--font-size-xs);
 	max-width: var(--responsive--aligndefault-width);
 }
 
-.site-main > article > .author-bio {
+.site-main > article > .entry-author {
 	margin-top: calc(2 * var(--global--spacing-vertical));
 }
 
-.author-bio .author-title {
+.entry-author .author-title {
 	font-family: var(--entry-author-bio--font-family);
 	font-size: var(--entry-author-bio--font-size);
 }
 
-.author-bio .author-description {
+.entry-author .author-bio {
 	font-size: var(--global--font-size-md);
 }
 

文件差異過大導致無法顯示
+ 0 - 1
seedlet/style.css.map


+ 20 - 19
seedlet/template-parts/post/author-bio.php

@@ -3,29 +3,30 @@
  * The template for displaying Author info
  *
  * @package Seedlet
- * @since 1.0.0
  */
 
 if ( (bool) get_the_author_meta( 'description' ) ) : ?>
-<div class="author-bio">
-	<?php
-	_e( 'Published by', 'seedlet' );
-	?>
-	<h2 class="author-title">
-		<span class="author-heading">
-			<?php
-			printf(
-				/* post author */
-				esc_html( get_the_author() )
-			);
-			?>
-		</span>
-	</h2>
-	<p class="author-description">
+<div class="entry-author">
+
+	<div class="author-heading">
+		<h2 class="author-title">
+			<?php esc_html_e( 'Published by', 'seedlet' ); ?>
+			<span class="author-name">
+				<?php
+				printf(
+					/* post author */
+					esc_html( get_the_author() )
+				);
+				?>
+			</span><!-- .author-name -->
+		</h2>
+	</div><!-- .author-heading -->
+
+	<p class="author-bio">
 		<?php the_author_meta( 'description' ); ?></br>
 		<a class="author-link" href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ); ?>" rel="author">
-			<?php _e( 'View more posts', 'seedlet' ); ?>
+			<?php printf( esc_html__( 'View all posts by %s', 'seedlet' ), get_the_author() ); ?>
 		</a>
-	</p><!-- .author-description -->
-</div><!-- .author-bio -->
+	</p><!-- .author-bio -->
+</div><!-- .entry-author -->
 <?php endif; ?>

部分文件因文件數量過多而無法顯示