Skip to content

Commit

Permalink
Created 404 pattern in Purr Theme (#224)
Browse files Browse the repository at this point in the history
* Created 404 pattern & Keep text Trasnaltable

* Added space

* Added space
  • Loading branch information
shail-mehta authored Jul 15, 2024
1 parent 299bb8c commit 674d6ad
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 9 deletions.
17 changes: 17 additions & 0 deletions purr/patterns/hidden-404.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?php
/**
* Title: 404
* Slug: purr/hidden-404
* Inserter: no
*/
?>

<!-- wp:group {"style":{"spacing":{"padding":{"right":"var:preset|spacing|30","left":"var:preset|spacing|30"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group" style="padding-right:var(--wp--preset--spacing--30);padding-left:var(--wp--preset--spacing--30)"><!-- wp:heading {"level":1} -->
<h1 class="wp-block-heading"><?php esc_html_e( 'Nothing Here', 'purr' ); ?></h1>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p><?php echo esc_html_x( 'It looks like nothing was found at this location. Maybe try a search?', '404 page message', 'purr' ); ?></p>
<!-- /wp:paragraph --></div>
<!-- /wp:group -->
11 changes: 2 additions & 9 deletions purr/templates/404.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,8 @@
<div class="wp-block-group alignfull" style="border-bottom-color:#f2f2f2;border-bottom-width:1px;padding-top:0;padding-right:0;padding-bottom:0;padding-left:0"><!-- wp:template-part {"slug":"header","tagName":"header"} /--></div>
<!-- /wp:group -->

<!-- wp:group {"style":{"spacing":{"padding":{"right":"var:preset|spacing|30","left":"var:preset|spacing|30"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group" style="padding-right:var(--wp--preset--spacing--30);padding-left:var(--wp--preset--spacing--30)"><!-- wp:heading {"level":1} -->
<h1 class="wp-block-heading">Nothing Here</h1>
<!-- /wp:heading -->
<!-- wp:pattern {"slug":"purr/hidden-404"} /--></div>

<!-- wp:paragraph -->
<p>It looks like nothing was found at this location. Maybe try a search?</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

Expand All @@ -32,4 +25,4 @@ <h1 class="wp-block-heading">Nothing Here</h1>
<!-- /wp:columns -->

<!-- wp:template-part {"slug":"footer","tagName":"footer"} /--></div>
<!-- /wp:group -->
<!-- /wp:group -->

0 comments on commit 674d6ad

Please sign in to comment.