Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 9 additions & 27 deletions .github/ipsum-demo-content.xml

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Block Styles page in the demo content says "Here is every style Ipsum offers", but the new Plain on Color style isn't listed in the Quotes section yet. Could we add an example of it there, like the removed Quote Mark on Color one?

That said, this file isn't subject to localization, so it's fine to handle this in a follow-up.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, Aki! Added

Original file line number Diff line number Diff line change
Expand Up @@ -1647,7 +1647,7 @@ audio/mpeg
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>Three styles, shared by both. The first is for saying one thing loudly.</p>
<p>One style, shared by both, for saying one thing loudly.</p>
<!-- /wp:paragraph -->

<!-- wp:heading {"className":"is-style-text-display"} -->
Expand All @@ -1662,32 +1662,6 @@ audio/mpeg
<p class="has-small-font-size">Display · <code>is-style-text-display</code></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>The second hangs a quotation mark over a line worth repeating.</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph {"className":"is-style-text-quote-mark","fontSize":"x-large"} -->
<p class="is-style-text-quote-mark has-x-large-font-size">Write the sentence first. The page can wait.</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph {"fontSize":"small"} -->
<p class="has-small-font-size">Quote Mark · <code>is-style-text-quote-mark</code></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>The third is the same mark for a card in a strong color: it takes the color of the text instead of a faint line.</p>
<!-- /wp:paragraph -->

<!-- wp:group {"style":{"spacing":{"padding":{"top":"var:preset|spacing|50","bottom":"var:preset|spacing|50","left":"var:preset|spacing|40","right":"var:preset|spacing|40"}},"border":{"radius":{"topLeft":"10px","topRight":"10px","bottomLeft":"10px","bottomRight":"10px"}}},"backgroundColor":"accent-3","textColor":"base","layout":{"type":"constrained"}} -->
<div class="wp-block-group has-base-color has-accent-3-background-color has-text-color has-background" style="border-top-left-radius:10px;border-top-right-radius:10px;border-bottom-left-radius:10px;border-bottom-right-radius:10px;padding-top:var(--wp--preset--spacing--50);padding-right:var(--wp--preset--spacing--40);padding-bottom:var(--wp--preset--spacing--50);padding-left:var(--wp--preset--spacing--40)"><!-- wp:heading {"className":"is-style-text-quote-mark-on-color"} -->
<h2 class="wp-block-heading is-style-text-quote-mark-on-color">The page can wait. It always has.</h2>
<!-- /wp:heading --></div>
<!-- /wp:group -->

<!-- wp:paragraph {"fontSize":"small"} -->
<p class="has-small-font-size">Quote Mark on Color · <code>is-style-text-quote-mark-on-color</code></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Display also fits the Site Title, the Post Title and, on archive pages, the Query Title. Here are the first two, showing this site's name and this page's:</p>
<!-- /wp:paragraph -->
Expand Down Expand Up @@ -1774,6 +1748,14 @@ audio/mpeg
<!-- /wp:paragraph --><cite>Plain · <code>is-style-plain</code></cite></blockquote>
<!-- /wp:quote -->

<!-- wp:group {"style":{"spacing":{"padding":{"top":"var:preset|spacing|50","bottom":"var:preset|spacing|50","left":"var:preset|spacing|40","right":"var:preset|spacing|40"}},"border":{"radius":"10px"}},"backgroundColor":"accent-3","textColor":"base","layout":{"type":"constrained"}} -->
<div class="wp-block-group has-base-color has-accent-3-background-color has-text-color has-background" style="border-radius:10px;padding-top:var(--wp--preset--spacing--50);padding-right:var(--wp--preset--spacing--40);padding-bottom:var(--wp--preset--spacing--50);padding-left:var(--wp--preset--spacing--40)"><!-- wp:quote {"className":"is-style-plain-on-color"} -->
<blockquote class="wp-block-quote is-style-plain-on-color"><!-- wp:paragraph -->
<p>Plain on Color is the same quote for a card in a strong color: the mark takes the color of the text instead of a faint line.</p>
<!-- /wp:paragraph --><cite>Plain on Color · <code>is-style-plain-on-color</code></cite></blockquote>
<!-- /wp:quote --></div>
<!-- /wp:group -->

<!-- wp:heading -->
<h2 class="wp-block-heading">Images</h2>
<!-- /wp:heading -->
Expand Down
5 changes: 3 additions & 2 deletions DESIGN.md
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,7 @@ The class is `is-style-` plus the slug.
| --- | --- | --- | --- |
| Crop Contents | `is-style-crop-contents` | Group | `overflow: clip` |
| Display | `is-style-text-display` | Heading, Paragraph, Post Title, Site Title, Query Title | A size above 2X-Large that scales with the viewport, line height 1.2 |
| Quote Mark | `is-style-text-quote-mark` | Heading, Paragraph | A ❝ above the text, in Border, at 2X-Large |
| Quote Mark on Color | `is-style-text-quote-mark-on-color` | Heading, Paragraph | The same mark in the current text color; Text Statement uses it on a Strong Contrast card |
| Plain on Color | `is-style-plain-on-color` | Quote | Quote Plain with the ❝ in the current text color instead of Border; Text Statement uses it on a Strong Contrast card |
| Evening | `is-style-evening` | Code | A black ground with near-white text and border, the same under every variation |
| Sharp | `is-style-sharp` | Site Logo | Square corners |
| Pinned to Bottom | `is-style-sticky-bottom` | Template Part | Pins the part to the bottom of the screen; see [Utility block styles](#utility-block-styles) |
Expand All @@ -174,6 +173,8 @@ The class is `is-style-` plus the slug.

Ipsum also restyles core's own block styles: Button Outline (a separate style from Search's Outline, though they share the name), Quote Plain (no ground, padding or corners), Separator Wide (capped at the wide width), Site Logo Rounded (9999px) and Social Icons Logos Only (icons in the current text color).

Text Statement Wide and Page Blog Home open with a Plain Quote, and Text Statement with a Plain on Color Quote, all three citing the same line from the persona's essays.

## Templates and parts

### Templates
Expand Down
8 changes: 5 additions & 3 deletions patterns/page-blog-home.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@
?>
<!-- wp:group {"metadata":{"name":"<?php echo esc_html_x( 'Text Statement', 'Name of the Text Statement element', 'ipsum' ); ?>"},"align":"wide","style":{"spacing":{"padding":{"top":"var:preset|spacing|60","bottom":"var:preset|spacing|60"},"blockGap":"var:preset|spacing|20"}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group alignwide" style="padding-top:var(--wp--preset--spacing--60);padding-bottom:var(--wp--preset--spacing--60)"><!-- wp:group {"metadata":{"name":"<?php echo esc_html_x( 'Text Statement Wrapper', 'Name of the Text Statement Wrapper element', 'ipsum' ); ?>"},"style":{"spacing":{"blockGap":"0"}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group"><!-- wp:paragraph {"className":"is-style-text-quote-mark","style":{"typography":{"fontStyle":"normal","fontWeight":"400","lineHeight":"1.3"}},"fontSize":"x-large"} -->
<p class="is-style-text-quote-mark has-x-large-font-size" style="font-style:normal;font-weight:400;line-height:1.3"><?php echo wp_kses_post( __( 'I teach and write about books, slow mornings, and the occasional recipe that actually works—start with the <a href="#">essays</a>.', 'ipsum' ) ); ?></p>
<!-- /wp:paragraph --></div>
<div class="wp-block-group"><!-- wp:quote {"className":"is-style-plain","style":{"spacing":{"blockGap":"var:preset|spacing|30"}}} -->
<blockquote class="wp-block-quote is-style-plain"><!-- wp:paragraph {"style":{"typography":{"fontStyle":"normal","fontWeight":"400","lineHeight":"1.3"}},"fontSize":"x-large"} -->
<p class="has-x-large-font-size" style="font-style:normal;font-weight:400;line-height:1.3"><?php esc_html_e( 'Write the sentence first. The page can wait.', 'ipsum' ); ?></p>
<!-- /wp:paragraph --><cite><?php echo wp_kses_post( __( 'From the <a href="#">essays</a>', 'ipsum' ) ); ?></cite></blockquote>
<!-- /wp:quote --></div>
<!-- /wp:group --></div>
<!-- /wp:group -->

Expand Down
8 changes: 5 additions & 3 deletions patterns/text-statement-wide.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,10 @@
?>
<!-- wp:group {"metadata":{"name":"<?php echo esc_html_x( 'Text Statement Wide', 'Name of the Text Statement Wide element', 'ipsum' ); ?>"},"align":"wide","style":{"spacing":{"margin":{"top":"0","bottom":"0"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group alignwide" style="margin-top:0;margin-bottom:0"><!-- wp:group {"metadata":{"name":"<?php echo esc_html_x( 'Text Statement Wide Wrapper', 'Name of the Text Statement Wide Wrapper element', 'ipsum' ); ?>"},"align":"wide","style":{"spacing":{"padding":{"top":"var:preset|spacing|70","bottom":"var:preset|spacing|70"},"blockGap":"var:preset|spacing|20"}},"layout":{"type":"default"}} -->
<div class="wp-block-group alignwide" style="padding-top:var(--wp--preset--spacing--70);padding-bottom:var(--wp--preset--spacing--70)"><!-- wp:paragraph {"className":"is-style-text-quote-mark","style":{"typography":{"lineHeight":"1.2","fontStyle":"normal","fontWeight":"400"}},"fontSize":"2-x-large"} -->
<p class="is-style-text-quote-mark has-2-x-large-font-size" style="font-style:normal;font-weight:400;line-height:1.2"><?php echo wp_kses_post( __( 'I teach and write about books, slow mornings, and the occasional recipe that actually works—start with the <a href="#">essays</a>.', 'ipsum' ) ); ?></p>
<!-- /wp:paragraph --></div>
<div class="wp-block-group alignwide" style="padding-top:var(--wp--preset--spacing--70);padding-bottom:var(--wp--preset--spacing--70)"><!-- wp:quote {"className":"is-style-plain","style":{"spacing":{"blockGap":"var:preset|spacing|30"}}} -->
<blockquote class="wp-block-quote is-style-plain"><!-- wp:paragraph {"style":{"typography":{"lineHeight":"1.2","fontStyle":"normal","fontWeight":"400"}},"fontSize":"2-x-large"} -->
<p class="has-2-x-large-font-size" style="font-style:normal;font-weight:400;line-height:1.2"><?php esc_html_e( 'Write the sentence first. The page can wait.', 'ipsum' ); ?></p>
<!-- /wp:paragraph --><cite><?php echo wp_kses_post( __( 'From the <a href="#">essays</a>', 'ipsum' ) ); ?></cite></blockquote>
<!-- /wp:quote --></div>
<!-- /wp:group --></div>
<!-- /wp:group -->
8 changes: 5 additions & 3 deletions patterns/text-statement.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,10 @@
?>
<!-- wp:group {"metadata":{"name":"<?php echo esc_html_x( 'Text Statement', 'Name of the Text Statement element', 'ipsum' ); ?>"},"style":{"spacing":{"padding":{"top":"var:preset|spacing|40","bottom":"var:preset|spacing|40"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group" style="padding-top:var(--wp--preset--spacing--40);padding-bottom:var(--wp--preset--spacing--40)"><!-- wp:group {"metadata":{"name":"<?php echo esc_html_x( 'Text Statement Wrapper', 'Name of the Text Statement Wrapper element', 'ipsum' ); ?>"},"style":{"spacing":{"padding":{"top":"var:preset|spacing|50","bottom":"var:preset|spacing|50","left":"var:preset|spacing|40","right":"var:preset|spacing|40"},"blockGap":"var:preset|spacing|30"},"elements":{"link":{"color":{"text":"var:preset|color|base"}}},"border":{"radius":"10px"}},"backgroundColor":"accent-3","textColor":"base","layout":{"type":"constrained"}} -->
<div class="wp-block-group has-base-color has-accent-3-background-color has-text-color has-background has-link-color" style="border-radius:10px;padding-top:var(--wp--preset--spacing--50);padding-right:var(--wp--preset--spacing--40);padding-bottom:var(--wp--preset--spacing--50);padding-left:var(--wp--preset--spacing--40)"><!-- wp:paragraph {"className":"is-style-text-quote-mark-on-color","style":{"typography":{"lineHeight":"1.3","fontStyle":"normal","fontWeight":"500","letterSpacing":"-0.02rem","textAlign":"center"}},"fontSize":"x-large"} -->
<p class="has-text-align-center is-style-text-quote-mark-on-color has-x-large-font-size" style="font-style:normal;font-weight:500;letter-spacing:-0.02rem;line-height:1.3"><?php echo wp_kses_post( __( 'I teach and write about books, slow mornings, and the occasional recipe that actually works—start with the <a href="#">essays</a>.', 'ipsum' ) ); ?></p>
<!-- /wp:paragraph --></div>
<div class="wp-block-group has-base-color has-accent-3-background-color has-text-color has-background has-link-color" style="border-radius:10px;padding-top:var(--wp--preset--spacing--50);padding-right:var(--wp--preset--spacing--40);padding-bottom:var(--wp--preset--spacing--50);padding-left:var(--wp--preset--spacing--40)"><!-- wp:quote {"className":"is-style-plain-on-color","style":{"spacing":{"blockGap":"var:preset|spacing|30"},"typography":{"textAlign":"center"}}} -->
<blockquote class="wp-block-quote has-text-align-center is-style-plain-on-color"><!-- wp:paragraph {"style":{"typography":{"lineHeight":"1.3","fontStyle":"normal","fontWeight":"500","letterSpacing":"-0.02rem","textAlign":"center"}},"fontSize":"x-large"} -->
<p class="has-text-align-center has-x-large-font-size" style="font-style:normal;font-weight:500;letter-spacing:-0.02rem;line-height:1.3"><?php esc_html_e( 'Write the sentence first. The page can wait.', 'ipsum' ); ?></p>
<!-- /wp:paragraph --><cite><?php echo wp_kses_post( __( 'From the <a href="#">essays</a>', 'ipsum' ) ); ?></cite></blockquote>
<!-- /wp:quote --></div>
<!-- /wp:group --></div>
<!-- /wp:group -->
24 changes: 24 additions & 0 deletions styles/blocks/plain-on-color.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"$schema": "https://schemas.wp.org/trunk/theme.json",
"version": 3,
"title": "Plain on Color",
"slug": "plain-on-color",
"blockTypes": ["core/quote"],
"styles": {
"border": {
"radius": "0px"
},
"color": {
"background": "transparent"
},
"spacing": {
"padding": {
"bottom": "0px",
"left": "0px",
"right": "0px",
"top": "0px"
}
},
"css": "&::before{color:currentcolor;}"
}
}
10 changes: 0 additions & 10 deletions styles/blocks/quote-mark-on-color.json

This file was deleted.

10 changes: 0 additions & 10 deletions styles/blocks/quote-mark.json

This file was deleted.

Loading