Skip to content
This repository has been archived by the owner on Sep 13, 2024. It is now read-only.

Commit

Permalink
feat(patterns): simplify
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasguillot committed Jun 11, 2024
1 parent 0ab9888 commit 1e23a86
Show file tree
Hide file tree
Showing 8 changed files with 132 additions and 135 deletions.
6 changes: 3 additions & 3 deletions includes/block-patterns/ad-specs.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
?>
<!-- wp:columns {"metadata":{"name":"<?php echo esc_html__( 'Ad Specs', 'publisher-media-kit' ); ?>"},"align":"wide","className":"newspack-grid"} -->
<div class="wp-block-columns alignwide newspack-grid"><!-- wp:column {"width":"33.33%"} -->
<div class="wp-block-column" style="flex-basis:33.33%"><!-- wp:heading {"align":"wide"} -->
<h2 class="wp-block-heading alignwide"><?php echo esc_html__( 'Ad Specs', 'publisher-media-kit' ); ?></h2>
<div class="wp-block-column" style="flex-basis:33.33%"><!-- wp:heading -->
<h2 class="wp-block-heading"><?php echo esc_html__( 'Ad Specs', 'publisher-media-kit' ); ?></h2>
<!-- /wp:heading --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"66.66%"} -->
<div class="wp-block-column" style="flex-basis:66.66%"><!-- wp:newspack/tabs {"align":"wide"} -->
<div class="wp-block-column" style="flex-basis:66.66%"><!-- wp:newspack/tabs -->
<!-- wp:newspack/tabs-item {"header":"<?php echo esc_html__( 'Standard Display', 'publisher-media-kit' ); ?>"} -->
<!-- wp:table -->
<figure class="wp-block-table"><table><thead><tr><th class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Ad Type', 'publisher-media-kit' ); ?></th><th class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Dimensions', 'publisher-media-kit' ); ?></th><th class="has-text-align-left" data-align="left"><?php echo esc_html__( 'File/Creative Type', 'publisher-media-kit' ); ?></th><th class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Device', 'publisher-media-kit' ); ?></th></tr></thead><tbody><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Billboard', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">970x250</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Desktop', 'publisher-media-kit' ); ?></td></tr><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Super Leaderboard', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">970x90</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Desktop', 'publisher-media-kit' ); ?></td></tr><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Leaderboard', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">728x90</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Desktop, Tablet', 'publisher-media-kit' ); ?></td></tr><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Medium Rectangle', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">300x250</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Desktop, Tablet, Mobile', 'publisher-media-kit' ); ?></td></tr><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Half Page', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">300x600</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Desktop', 'publisher-media-kit' ); ?></td></tr><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Small Mobile Banner', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">320x50</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Mobile', 'publisher-media-kit' ); ?></td></tr><tr><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Large Mobile Banner', 'publisher-media-kit' ); ?></td><td class="has-text-align-left" data-align="left">320x100</td><td class="has-text-align-left" data-align="left">GIF/JPEG - 250KB | HTML 5 - 500KB</td><td class="has-text-align-left" data-align="left"><?php echo esc_html__( 'Mobile', 'publisher-media-kit' ); ?></td></tr></tbody></table></figure>
Expand Down
74 changes: 39 additions & 35 deletions includes/block-patterns/audience.php

Large diffs are not rendered by default.

7 changes: 3 additions & 4 deletions includes/block-patterns/contact-compact.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
<?php
// phpcs:ignoreFile
?>
<!-- wp:group {"metadata":{"name":"<?php echo esc_html__( 'Contact (Compact)', 'publisher-media-kit' ); ?>"},"align":"full","style":{"spacing":{"padding":{"right":"var:preset|spacing|30","left":"var:preset|spacing|30"},"margin":{"top":"var:preset|spacing|80","bottom":"var:preset|spacing|80"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group alignfull" style="margin-top:var(--wp--preset--spacing--80);margin-bottom:var(--wp--preset--spacing--80);padding-right:var(--wp--preset--spacing--30);padding-left:var(--wp--preset--spacing--30)"><!-- wp:group {"align":"wide","style":{"spacing":{"padding":{"top":"var:preset|spacing|50","bottom":"var:preset|spacing|50","left":"var:preset|spacing|50","right":"var:preset|spacing|50"},"margin":{"top":"0","bottom":"0"},"blockGap":"var:preset|spacing|40"},"border":{"radius":"6px","width":"1px"}},"borderColor":"base-3","layout":{"type":"flex","flexWrap":"wrap","justifyContent":"space-between","verticalAlignment":"bottom"}} -->
<div class="wp-block-group alignwide has-border-color has-base-3-border-color" style="border-width:1px;border-radius:6px;margin-top:0;margin-bottom:0;padding-top:var(--wp--preset--spacing--50);padding-right:var(--wp--preset--spacing--50);padding-bottom:var(--wp--preset--spacing--50);padding-left:var(--wp--preset--spacing--50)"><!-- wp:group {"metadata":{"name":"<?php echo esc_html__( 'Content', 'publisher-media-kit' ); ?>"},"style":{"spacing":{"blockGap":"var:preset|spacing|20"}},"layout":{"type":"constrained"}} -->
<!-- wp:group {"metadata":{"name":"<?php echo esc_html__( 'Contact (Compact)', 'publisher-media-kit' ); ?>"},"align":"wide","style":{"spacing":{"padding":{"top":"var:preset|spacing|50","bottom":"var:preset|spacing|50","left":"var:preset|spacing|50","right":"var:preset|spacing|50"},"blockGap":"var:preset|spacing|30"},"border":{"radius":"6px","width":"1px"}},"borderColor":"base-3","layout":{"type":"flex","flexWrap":"wrap","justifyContent":"space-between","verticalAlignment":"bottom"}} -->
<div class="wp-block-group alignwide has-border-color has-base-3-border-color" style="border-width:1px;border-radius:6px;padding-top:var(--wp--preset--spacing--50);padding-right:var(--wp--preset--spacing--50);padding-bottom:var(--wp--preset--spacing--50);padding-left:var(--wp--preset--spacing--50)"><!-- wp:group {"metadata":{"name":"<?php echo esc_html__( 'Content', 'publisher-media-kit' ); ?>"},"style":{"spacing":{"blockGap":"var:preset|spacing|20"}},"layout":{"type":"constrained","justifyContent":"left"}} -->
<div class="wp-block-group"><!-- wp:heading {"level":4} -->
<h4 class="wp-block-heading"><?php echo esc_html__( 'Get started today', 'publisher-media-kit' ); ?></h4>
<!-- /wp:heading -->
Expand All @@ -18,5 +17,5 @@
<div class="wp-block-button"><a class="wp-block-button__link wp-element-button"><?php echo esc_html__( 'Get in touch', 'publisher-media-kit' ); ?></a></div>
<!-- /wp:button --></div>
<!-- /wp:buttons --></div>
<!-- /wp:group --></div>
<!-- /wp:group -->

6 changes: 2 additions & 4 deletions includes/block-patterns/contact.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
<?php
// phpcs:ignoreFile
?>
<!-- wp:group {"metadata":{"name":"<?php echo esc_html__( 'Contact', 'publisher-media-kit' ); ?>"},"align":"full","style":{"spacing":{"padding":{"right":"var:preset|spacing|30","left":"var:preset|spacing|30"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group alignfull" style="padding-right:var(--wp--preset--spacing--30);padding-left:var(--wp--preset--spacing--30)"><!-- wp:group {"metadata":{},"align":"wide","style":{"spacing":{"padding":{"top":"var:preset|spacing|80","bottom":"var:preset|spacing|80","left":"var:preset|spacing|80","right":"var:preset|spacing|80"},"margin":{"top":"0","bottom":"0"}},"border":{"radius":"6px","width":"1px"}},"borderColor":"base-3","layout":{"type":"constrained"}} -->
<div class="wp-block-group alignwide has-border-color has-base-3-border-color" style="border-width:1px;border-radius:6px;margin-top:0;margin-bottom:0;padding-top:var(--wp--preset--spacing--80);padding-right:var(--wp--preset--spacing--80);padding-bottom:var(--wp--preset--spacing--80);padding-left:var(--wp--preset--spacing--80)"><!-- wp:heading {"textAlign":"center"} -->
<!-- wp:group {"metadata":{"name":"<?php echo esc_html__( 'Contact', 'publisher-media-kit' ); ?>"},"align":"wide","style":{"spacing":{"padding":{"top":"var:preset|spacing|80","bottom":"var:preset|spacing|80","left":"var:preset|spacing|80","right":"var:preset|spacing|80"}},"border":{"radius":"6px","width":"1px"}},"borderColor":"base-3","layout":{"type":"constrained"}} -->
<div class="wp-block-group alignwide has-border-color has-base-3-border-color" style="border-width:1px;border-radius:6px;padding-top:var(--wp--preset--spacing--80);padding-right:var(--wp--preset--spacing--80);padding-bottom:var(--wp--preset--spacing--80);padding-left:var(--wp--preset--spacing--80)"><!-- wp:heading {"textAlign":"center"} -->
<h2 class="wp-block-heading has-text-align-center"><?php echo esc_html__( 'Get started today', 'publisher-media-kit' ); ?></h2>
<!-- /wp:heading -->

Expand All @@ -16,5 +15,4 @@
<div class="wp-block-button"><a class="wp-block-button__link wp-element-button"><?php echo esc_html__( 'Get in touch', 'publisher-media-kit' ); ?></a></div>
<!-- /wp:button --></div>
<!-- /wp:buttons --></div>
<!-- /wp:group --></div>
<!-- /wp:group -->
Loading

0 comments on commit 1e23a86

Please sign in to comment.