From 42c5885cbd037fdfc53cc99a120767e747432023 Mon Sep 17 00:00:00 2001 From: MrCasual Date: Wed, 9 Sep 2015 21:01:05 -0400 Subject: [PATCH 1/8] - Ported newsletter rendering engine --- lib/Newsletter/Blocks/Button.php | 41 ++++ lib/Newsletter/Blocks/Divider.php | 22 ++ lib/Newsletter/Blocks/Footer.php | 27 +++ lib/Newsletter/Blocks/Header.php | 27 +++ lib/Newsletter/Blocks/Image.php | 19 ++ lib/Newsletter/Blocks/Renderer.php | 107 ++++++++++ lib/Newsletter/Blocks/Social.php | 23 +++ lib/Newsletter/Blocks/Spacer.php | 22 ++ lib/Newsletter/Blocks/Text.php | 74 +++++++ lib/Newsletter/Columns/Renderer.php | 65 ++++++ lib/Newsletter/NewsletterData.json | 1 + lib/Newsletter/NewsletterTemplate.html | 266 +++++++++++++++++++++++++ lib/Newsletter/Renderer.php | 89 +++++++++ 13 files changed, 783 insertions(+) create mode 100644 lib/Newsletter/Blocks/Button.php create mode 100644 lib/Newsletter/Blocks/Divider.php create mode 100644 lib/Newsletter/Blocks/Footer.php create mode 100644 lib/Newsletter/Blocks/Header.php create mode 100644 lib/Newsletter/Blocks/Image.php create mode 100644 lib/Newsletter/Blocks/Renderer.php create mode 100644 lib/Newsletter/Blocks/Social.php create mode 100644 lib/Newsletter/Blocks/Spacer.php create mode 100644 lib/Newsletter/Blocks/Text.php create mode 100644 lib/Newsletter/Columns/Renderer.php create mode 100644 lib/Newsletter/NewsletterData.json create mode 100644 lib/Newsletter/NewsletterTemplate.html create mode 100644 lib/Newsletter/Renderer.php diff --git a/lib/Newsletter/Blocks/Button.php b/lib/Newsletter/Blocks/Button.php new file mode 100644 index 0000000000..21ef1691de --- /dev/null +++ b/lib/Newsletter/Blocks/Button.php @@ -0,0 +1,41 @@ + + +
+ + + + +
+ + + ' . $element['text'] . ' + +
+
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Divider.php b/lib/Newsletter/Blocks/Divider.php new file mode 100644 index 0000000000..a443460118 --- /dev/null +++ b/lib/Newsletter/Blocks/Divider.php @@ -0,0 +1,22 @@ + + + + + + +
+
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Footer.php b/lib/Newsletter/Blocks/Footer.php new file mode 100644 index 0000000000..2718738ce6 --- /dev/null +++ b/lib/Newsletter/Blocks/Footer.php @@ -0,0 +1,27 @@ + + +
' . $element['text'] . '
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Header.php b/lib/Newsletter/Blocks/Header.php new file mode 100644 index 0000000000..556a57c11a --- /dev/null +++ b/lib/Newsletter/Blocks/Header.php @@ -0,0 +1,27 @@ + + +
' . $element['text'] . '
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Image.php b/lib/Newsletter/Blocks/Image.php new file mode 100644 index 0000000000..ea340153dd --- /dev/null +++ b/lib/Newsletter/Blocks/Image.php @@ -0,0 +1,19 @@ + + + + + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Renderer.php b/lib/Newsletter/Blocks/Renderer.php new file mode 100644 index 0000000000..80054b6509 --- /dev/null +++ b/lib/Newsletter/Blocks/Renderer.php @@ -0,0 +1,107 @@ + "Arial, 'Helvetica Neue', Helvetica, sans-serif", + 'Comic Sans MS' => "'Comic Sans MS', 'Marker Felt-Thin', Arial, sans-serif", + 'Courier New' => "'Courier New', Courier, 'Lucida Sans Typewriter', 'Lucida Typewriter', monospace", + 'Georgia' => "Georgia, Times, 'Times New Roman', serif", + 'Lucida' => "'Lucida Sans Unicode', 'Lucida Grande', sans-serif", + 'Tahoma' => "Tahoma, Verdana, Segoe, sans-serif", + 'Times New Roman' => "'Times New Roman', Times, Baskerville, Georgia, serif", + 'Trebuchet MS' => "'Trebuchet MS', 'Lucida Grande', 'Lucida Sans Unicode', 'Lucida Sans', Tahoma, sans-serif", + 'Verdana' => "Verdana, Geneva, sans-serif" + ); + + static $cssAtributesTable = array( + 'backgroundColor' => 'background-color', + 'fontColor' => 'color', + 'fontFamily' => 'font-family', + 'textDecoration' => 'text-decoration', + 'textAlign' => 'text-align', + 'fontSize' => 'font-size', + 'borderWidth' => 'border-width', + 'borderStyle' => 'border-style', + 'borderColor' => 'border-color', + 'borderRadius' => 'border-radius', + 'lineHeight' => 'line-height' + ); + + static function render($data, $column = null) { + $blockContent = ''; + $blockCount = count($data['blocks']); + + foreach ($data['blocks'] as $i => $block) { + $blockContent .= self::createElementFromBlockType($block); + if(isset($block['blocks']) && is_array($block['blocks'])) { + $blockContent = self::render($block); + } + + // vertical orientation denotes column container + if($block['type'] == 'container' && $block['orientation'] == 'vertical') { + $columns[] = $blockContent; + } + } + + return (isset($columns)) ? $columns : $blockContent; + } + + static function createElementFromBlockType($block) { + switch ($block['type']) { + case 'header': + $element = Header::render($block); + break; + case 'image': + $element = Image::render($block); + break; + case 'text': + $element = Text::render($block); + break; + case 'button': + $element = Button::render($block); + break; + case 'divider': + $element = Divider::render($block); + break; + case 'spacer': + $element = Spacer::render($block); + break; + case 'social': + $element = Social::render($block); + break; + case 'footer': + $element = Footer::render($block); + break; + default: + $element = '';//'UNRECOGNIZED ELEMENT'; + break; + } + + return $element; + } + + static function getBlockStyles($element, $ignore = false) { + if(!isset($element['styles']['block'])) { + return; + } + + return self::getStyles($element['styles'], 'block', $ignore); + } + + static function getStyles($styles, $type, $ignore = false) { + $css = ''; + foreach ($styles[$type] as $attribute => $style) { + if($ignore && in_array($attribute, $ignore)) { + continue; + } + $css .= self::translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; + } + + return $css; + } + + static function translateCSSAttribute($attribute) { + return (isset(self::$cssAtributesTable[$attribute])) ? self::$cssAtributesTable[$attribute] : $attribute; + } +} diff --git a/lib/Newsletter/Blocks/Social.php b/lib/Newsletter/Blocks/Social.php new file mode 100644 index 0000000000..acdeea20cd --- /dev/null +++ b/lib/Newsletter/Blocks/Social.php @@ -0,0 +1,23 @@ +' . $icon['iconType'] . ''; + } + } + $template = ' + +
+ ' . $iconsBlock . ' +
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Spacer.php b/lib/Newsletter/Blocks/Spacer.php new file mode 100644 index 0000000000..76568a6c22 --- /dev/null +++ b/lib/Newsletter/Blocks/Spacer.php @@ -0,0 +1,22 @@ + + + + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Text.php b/lib/Newsletter/Blocks/Text.php new file mode 100644 index 0000000000..6911842dd7 --- /dev/null +++ b/lib/Newsletter/Blocks/Text.php @@ -0,0 +1,74 @@ + elements to tables + $blockquoteTemplate = ' + + + + + +
+ $1 +
+
'; + $element['text'] = preg_replace('/
(.*?)<\/blockquote>/s', $blockquoteTemplate, $element['text']); + + // add line breaks after tags + $element['text'] = preg_replace('/(<\/(ul|ol|h\d)>)/', '$1
', $element['text']); + + $element['text'] = self::removeEmptyHTMLTags($element['text']); + + // convert empty

tags to line breaks + $element['text'] = preg_replace('/<\/p>/', '
', $element['text']); + + // convert

to + $element['text'] = preg_replace('/

(.*?)<\/p>/', '
$1
', $element['text']); + $element['text'] = preg_replace('/(.*?)<\/p>/', '
$2
', $element['text']); + + // remove the last break line + $element['text'] = preg_replace('/
([^
]*)$/s', '', $element['text']); + + $template = ' + + ' . $element['text'] . ' + + '; + + return $template; + } + + static function removeEmptyHTMLTags($html) { + $pattern = <<<'EOD' + ~ + < + (?: + !--[^-]*(?:-(?!->)[^-]*)*-->[^<]*(*SKIP)(*F) # skip comments + | + ( # group 1 + (span|em|strong) # tag name in group 2 + [^"'>]* #'"# all that is not a quote or a closing angle bracket + (?: # quoted attributes + "[^\\"]*(?:\\.[^\\"]*)*+" [^"'>]* #'"# double quote + | + '[^\\']*(?:\\.[^\\']*)*+' [^"'>]* #'"# single quote + )*+ + > + \s* + (?: + \s* # html comments + | + <(?1) \s* # recursion with the group 1 + )*+ + # closing tag + ) # end of the group 1 + ) + ~sxi +EOD; + + return preg_replace($pattern, '', $html); + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Columns/Renderer.php b/lib/Newsletter/Columns/Renderer.php new file mode 100644 index 0000000000..22ab496fc6 --- /dev/null +++ b/lib/Newsletter/Columns/Renderer.php @@ -0,0 +1,65 @@ + 600, + 2 => 300, + 3 => 200 + ); + $columnClasses = array( + 1 => 'mailpoet_col-one', + 2 => 'mailpoet_col-two', + 3 => 'mailpoet_col-three' + ); + $columnWidth = $columnWidths[$columnsCount]; + $columnClass = $columnClasses[$columnsCount]; + + // open column container + $columnContainerTemplate = ' + + + + + +
+ '; + $columnOpenTemplate = ''; + $columnCloseTemplate = '
+ '; + + foreach ($columnsData as $index => $columnData) { + $index++; + $columnContainerTemplate .= $columnOpenTemplate . $columnData; + if($columnsCount > 1 && $index != $columnsCount) { + $columnContainerTemplate .= $columnCloseTemplate; + } + + } + + // close column container + $columnContainerTemplate .= '
+ + + + + + '; + + return $columnContainerTemplate; + } +} diff --git a/lib/Newsletter/NewsletterData.json b/lib/Newsletter/NewsletterData.json new file mode 100644 index 0000000000..0757ee8917 --- /dev/null +++ b/lib/Newsletter/NewsletterData.json @@ -0,0 +1 @@ +{"data":{"data":{"type":"container","orientation":"vertical","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"container","orientation":"horizontal","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"container","orientation":"vertical","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"header","text":"

Display problems? View it in your browser. If I add a lot of text to test what happens... Well, nothing really (exciting) happens. Things don't break.

","styles":{"block":{"backgroundColor":"#333333"},"text":{"fontColor":"#aaaaaa","fontFamily":"Arial","fontSize":"12px","textAlign":"center"},"link":{"fontColor":"#a86b6b","textDecoration":"underline"}}},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/600x250.jpg","alt":"600x250","padded":true,"width":"600px","height":"250px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs sha

\n

\n

nk cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

\n
"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/600x250.jpg","alt":"600x250","padded":false,"width":"600px","height":"250px","styles":{"block":{"textAlign":"center"}}}]}]},{"orientation":"horizontal","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":true,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":false,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}}]},{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":true,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":false,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}}]}]},{"orientation":"horizontal","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":true,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":false,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}}]},{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":true,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":false,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}}]},{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":true,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":false,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}}]}]},{"orientation":"horizontal","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"footer","text":"

You are receiving this email because you opted in on our website. Update your email preferences or unsubscribe

\n

123 Maple Avenue
93102
Oakland, California

","styles":{"block":{"backgroundColor":"#333333"},"text":{"fontColor":"#aaaaaa","fontFamily":"Arial","fontSize":"12px","textAlign":"center"},"link":{"fontColor":"#a86b6b","textDecoration":"underline"}}}]}]}]},"styles":{"text":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"16px"},"h1":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"36px"},"h2":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"26px"},"h3":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"18px"},"link":{"fontColor":"#a86b6b","textDecoration":"underline"},"newsletter":{"backgroundColor":"#999999"},"background":{"backgroundColor":"#333333"}},"newsletter":233}} \ No newline at end of file diff --git a/lib/Newsletter/NewsletterTemplate.html b/lib/Newsletter/NewsletterTemplate.html new file mode 100644 index 0000000000..9e44d82dd2 --- /dev/null +++ b/lib/Newsletter/NewsletterTemplate.html @@ -0,0 +1,266 @@ + + + + + + + + MailPoet Newsletter Template + + + + + + + + +
+ + + + {{newsletter_editor_content}} + +
+ +
+ + diff --git a/lib/Newsletter/Renderer.php b/lib/Newsletter/Renderer.php new file mode 100644 index 0000000000..a426f435e5 --- /dev/null +++ b/lib/Newsletter/Renderer.php @@ -0,0 +1,89 @@ +data = $newsletterData; + $this->template = file_get_contents(dirname(__FILE__) . '/' . $this->template); + } + + function renderAll() { + $newsletterContent = $this->renderContent($this->data['data']); + $newsletterStyles = $this->renderStyles($this->data['styles']); + + $renderedTemplate = $this->renderTemplate($this->template, array( + $newsletterStyles, + $newsletterContent + )); + $renderedTemplateWithInlinedStyles = $this->inlineCSSStyles($renderedTemplate); + + return $this->postProcessRenderedTemplate($renderedTemplateWithInlinedStyles); + } + + function renderContent($content) { + $newsletterContent = ''; + foreach ($content['blocks'] as $contentBlock) { + if(isset($contentBlock['blocks']) && is_array($contentBlock['blocks'])) { + $columnCount = count($contentBlock['blocks']); + $columnData = Blocks\Renderer::render($contentBlock); + $newsletterContent .= Columns\Renderer::render($columnCount, $columnData); + } + } + + return $newsletterContent; + } + + function renderStyles($styles) { + $newsletterStyles = ''; + foreach ($styles as $selector => $style) { + switch ($selector) { + case 'text': + $selector = 'span.paragraph, ul, ol'; + break; + case 'background': + $selector = '.mailpoet_content-wrapper'; + break; + case 'link': + $selector = '.mailpoet_content-wrapper a'; + break; + case 'newsletter': + $selector = '.mailpoet_container, .mailpoet_col-one, .mailpoet_col-two, .mailpoet_col-three'; + break; + } + $newsletterStyles .= $selector . '{' . PHP_EOL; + foreach ($style as $attribute => $individualStyle) { + $newsletterStyles .= Blocks\Renderer::translateCSSAttribute($attribute) . ':' . $individualStyle . ';' . PHP_EOL; + } + $newsletterStyles .= '}' . PHP_EOL; + } + + return $newsletterStyles; + } + + function renderTemplate($template, $data) { + return preg_replace_callback('/{{\w+}}/', function ($matches) use (&$data) { + return array_shift($data); + }, $template); + } + + function inlineCSSStyles($template) { + $inliner = new \MailPoet\Util\CSS(); + + return $inliner->inlineCSS(null, $template); + } + + function postProcessRenderedTemplate($template) { + // remove padding from last element inside each column + $DOM = \pQuery::parseStr($template); + $lastColumnElement = $DOM->query('.mailpoet_col > tbody > tr:last-child > td'); + foreach ($lastColumnElement as $element) { + $element->setAttribute('style', str_replace('padding-bottom:20px;', '', $element->attributes['style'])); + } + + return $DOM->__toString(); + } +} \ No newline at end of file From 7e4bd0d044a21786c989277bf93b2a049b2b60c9 Mon Sep 17 00:00:00 2001 From: MrCasual Date: Thu, 10 Sep 2015 20:32:12 -0400 Subject: [PATCH 2/8] Indented HTML code as per Marco's comment --- lib/Newsletter/Blocks/Button.php | 64 +++++++++++++------------ lib/Newsletter/Blocks/Divider.php | 25 +++++----- lib/Newsletter/Blocks/Footer.php | 11 +++-- lib/Newsletter/Blocks/Header.php | 13 +++--- lib/Newsletter/Blocks/Image.php | 13 ++++-- lib/Newsletter/Blocks/Social.php | 13 +++--- lib/Newsletter/Blocks/Spacer.php | 8 ++-- lib/Newsletter/Blocks/Text.php | 9 ++-- lib/Newsletter/Columns/Renderer.php | 72 ++++++++++++++++------------- 9 files changed, 123 insertions(+), 105 deletions(-) diff --git a/lib/Newsletter/Blocks/Button.php b/lib/Newsletter/Blocks/Button.php index 21ef1691de..0f931426a3 100644 --- a/lib/Newsletter/Blocks/Button.php +++ b/lib/Newsletter/Blocks/Button.php @@ -5,35 +5,41 @@ use MailPoet\Newsletter\Blocks\Renderer as BlocksRenderer; class Button { static function render($element) { - $template = ' - -
- - - - -
- - - ' . $element['text'] . ' - -
-
- - '; + $template = ' + + +
+ + + + +
+ + ' . $element['text'] . ' + +
+
+ +'; return $template; } diff --git a/lib/Newsletter/Blocks/Divider.php b/lib/Newsletter/Blocks/Divider.php index a443460118..b19bdc6b9c 100644 --- a/lib/Newsletter/Blocks/Divider.php +++ b/lib/Newsletter/Blocks/Divider.php @@ -3,18 +3,19 @@ class Divider { static function render($element) { - $template = ' - - - - - -
-
- - '; + $template = ' + + + + + + +
+
+ +'; return $template; } diff --git a/lib/Newsletter/Blocks/Footer.php b/lib/Newsletter/Blocks/Footer.php index 2718738ce6..3b818c29c4 100644 --- a/lib/Newsletter/Blocks/Footer.php +++ b/lib/Newsletter/Blocks/Footer.php @@ -15,11 +15,12 @@ class Footer { $element['text'] = str_replace(' -
' . $element['text'] . '
- - '; + $template = ' + + +
' . $element['text'] . '
+ +'; return $template; } diff --git a/lib/Newsletter/Blocks/Header.php b/lib/Newsletter/Blocks/Header.php index 556a57c11a..6e92e1c434 100644 --- a/lib/Newsletter/Blocks/Header.php +++ b/lib/Newsletter/Blocks/Header.php @@ -1,7 +1,7 @@ - -
' . $element['text'] . '
- - '; + $template = ' + + +
' . $element['text'] . '
+ +'; return $template; } diff --git a/lib/Newsletter/Blocks/Image.php b/lib/Newsletter/Blocks/Image.php index ea340153dd..b1b02d09a9 100644 --- a/lib/Newsletter/Blocks/Image.php +++ b/lib/Newsletter/Blocks/Image.php @@ -7,11 +7,14 @@ class Image { static function render($element) { $element['width'] = (int) $element['width']; - $template = ' - - - - '; + $template = ' + + + + +'; return $template; } diff --git a/lib/Newsletter/Blocks/Social.php b/lib/Newsletter/Blocks/Social.php index acdeea20cd..704ce34c10 100644 --- a/lib/Newsletter/Blocks/Social.php +++ b/lib/Newsletter/Blocks/Social.php @@ -9,13 +9,12 @@ class Social { $iconsBlock .= '' . $icon['iconType'] . ''; } } - $template = ' - -
- ' . $iconsBlock . ' -
- - '; + $template = ' + + +
' . $iconsBlock . '
+ +'; return $template; } diff --git a/lib/Newsletter/Blocks/Spacer.php b/lib/Newsletter/Blocks/Spacer.php index 76568a6c22..558b2d319b 100644 --- a/lib/Newsletter/Blocks/Spacer.php +++ b/lib/Newsletter/Blocks/Spacer.php @@ -11,10 +11,10 @@ class Spacer { unset($element['styles']['block']['backgroundColor']); } - $template = ' - - - '; + $template = ' + + +'; return $template; } diff --git a/lib/Newsletter/Blocks/Text.php b/lib/Newsletter/Blocks/Text.php index 6911842dd7..7cfbd29ed9 100644 --- a/lib/Newsletter/Blocks/Text.php +++ b/lib/Newsletter/Blocks/Text.php @@ -31,11 +31,10 @@ class Text { // remove the last break line $element['text'] = preg_replace('/
([^
]*)$/s', '', $element['text']); - $template = ' - - ' . $element['text'] . ' - - '; + $template = ' + + ' . $element['text'] . ' +'; return $template; } diff --git a/lib/Newsletter/Columns/Renderer.php b/lib/Newsletter/Columns/Renderer.php index 22ab496fc6..7386e6b909 100644 --- a/lib/Newsletter/Columns/Renderer.php +++ b/lib/Newsletter/Columns/Renderer.php @@ -17,24 +17,32 @@ class Renderer { $columnClass = $columnClasses[$columnsCount]; // open column container - $columnContainerTemplate = ' - - - - - + - -
- '; - $columnOpenTemplate = ''; - $columnCloseTemplate = '
- '; + $columnContainerTemplate = ' +
+ + + + -
+ '; + $columnOpenTemplate = ' + + '; + $columnCloseTemplate = ' + +
+'; foreach ($columnsData as $index => $columnData) { $index++; @@ -42,23 +50,23 @@ class Renderer { if($columnsCount > 1 && $index != $columnsCount) { $columnContainerTemplate .= $columnCloseTemplate; } - } // close column container - $columnContainerTemplate .= '
- -
- - '; + $columnContainerTemplate .= ' + + + + + + + +'; return $columnContainerTemplate; } From 42d659472e472bfe2bf7eda26259b8fbb64edc04 Mon Sep 17 00:00:00 2001 From: MrCasual Date: Fri, 11 Sep 2015 14:31:12 -0400 Subject: [PATCH 3/8] - Made all rendering classes dynamic except for single blocks --- lib/Newsletter/Blocks/Button.php | 4 ++- lib/Newsletter/Blocks/Footer.php | 10 +++--- lib/Newsletter/Blocks/Header.php | 20 ++++++------ lib/Newsletter/Blocks/Image.php | 4 ++- lib/Newsletter/Blocks/Renderer.php | 24 +++++++------- lib/Newsletter/Blocks/Social.php | 8 ++++- lib/Newsletter/Blocks/Spacer.php | 5 ++- lib/Newsletter/Columns/Renderer.php | 31 +++++++++++-------- lib/Newsletter/Renderer.php | 18 ++++++----- ...{NewsletterTemplate.html => Template.html} | 0 .../{NewsletterData.json => TestData.json} | 0 11 files changed, 72 insertions(+), 52 deletions(-) rename lib/Newsletter/{NewsletterTemplate.html => Template.html} (100%) rename lib/Newsletter/{NewsletterData.json => TestData.json} (100%) diff --git a/lib/Newsletter/Blocks/Button.php b/lib/Newsletter/Blocks/Button.php index 0f931426a3..8f82f21756 100644 --- a/lib/Newsletter/Blocks/Button.php +++ b/lib/Newsletter/Blocks/Button.php @@ -5,6 +5,8 @@ use MailPoet\Newsletter\Blocks\Renderer as BlocksRenderer; class Button { static function render($element) { + $blocksRenderer = new Renderer(); + $template = ' @@ -32,7 +34,7 @@ class Button { ' . $element['text'] . ' + style="display:inline-block;text-align:center;text-decoration:none;-webkit-text-size-adjust:none;mso-hide:all;' . $blocksRenderer->getBlockStyles($element, array('textAlign')) . '"> ' . $element['text'] . ' diff --git a/lib/Newsletter/Blocks/Footer.php b/lib/Newsletter/Blocks/Footer.php index 3b818c29c4..1cd1842e1e 100644 --- a/lib/Newsletter/Blocks/Footer.php +++ b/lib/Newsletter/Blocks/Footer.php @@ -1,23 +1,23 @@ getStyles($element['styles'], 'link') . '"', $element['text']); } // apply text styles if(isset($element['styles']['link'])) { - $element['text'] = str_replace(' +
' . $element['text'] . '
'; diff --git a/lib/Newsletter/Blocks/Header.php b/lib/Newsletter/Blocks/Header.php index 6e92e1c434..c4c3359b5f 100644 --- a/lib/Newsletter/Blocks/Header.php +++ b/lib/Newsletter/Blocks/Header.php @@ -1,28 +1,28 @@ getStyles($element['styles'], 'link') . '"', $element['text']); } - + // apply text styles if(isset($element['styles']['link'])) { - $element['text'] = str_replace(' +
' . $element['text'] . '
'; - + return $template; } - + } \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Image.php b/lib/Newsletter/Blocks/Image.php index b1b02d09a9..2810983204 100644 --- a/lib/Newsletter/Blocks/Image.php +++ b/lib/Newsletter/Blocks/Image.php @@ -5,11 +5,13 @@ use MailPoet\Newsletter\Blocks\Renderer as BlocksRenderer; class Image { static function render($element) { + $blocksRenderer = new Renderer(); + $element['width'] = (int) $element['width']; $template = ' - + diff --git a/lib/Newsletter/Blocks/Renderer.php b/lib/Newsletter/Blocks/Renderer.php index 80054b6509..978dddd41c 100644 --- a/lib/Newsletter/Blocks/Renderer.php +++ b/lib/Newsletter/Blocks/Renderer.php @@ -2,7 +2,7 @@ class Renderer { - static $typeFace = array( + public $typeFace = array( 'Arial' => "Arial, 'Helvetica Neue', Helvetica, sans-serif", 'Comic Sans MS' => "'Comic Sans MS', 'Marker Felt-Thin', Arial, sans-serif", 'Courier New' => "'Courier New', Courier, 'Lucida Sans Typewriter', 'Lucida Typewriter', monospace", @@ -14,7 +14,7 @@ class Renderer { 'Verdana' => "Verdana, Geneva, sans-serif" ); - static $cssAtributesTable = array( + public $cssAtributesTable = array( 'backgroundColor' => 'background-color', 'fontColor' => 'color', 'fontFamily' => 'font-family', @@ -28,14 +28,14 @@ class Renderer { 'lineHeight' => 'line-height' ); - static function render($data, $column = null) { + function render($data, $column = null) { $blockContent = ''; $blockCount = count($data['blocks']); foreach ($data['blocks'] as $i => $block) { - $blockContent .= self::createElementFromBlockType($block); + $blockContent .= $this->createElementFromBlockType($block); if(isset($block['blocks']) && is_array($block['blocks'])) { - $blockContent = self::render($block); + $blockContent = $this->render($block); } // vertical orientation denotes column container @@ -47,7 +47,7 @@ class Renderer { return (isset($columns)) ? $columns : $blockContent; } - static function createElementFromBlockType($block) { + function createElementFromBlockType($block) { switch ($block['type']) { case 'header': $element = Header::render($block); @@ -81,27 +81,27 @@ class Renderer { return $element; } - static function getBlockStyles($element, $ignore = false) { + function getBlockStyles($element, $ignore = false) { if(!isset($element['styles']['block'])) { return; } - return self::getStyles($element['styles'], 'block', $ignore); + return $this->getStyles($element['styles'], 'block', $ignore); } - static function getStyles($styles, $type, $ignore = false) { + function getStyles($styles, $type, $ignore = false) { $css = ''; foreach ($styles[$type] as $attribute => $style) { if($ignore && in_array($attribute, $ignore)) { continue; } - $css .= self::translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; + $css .= $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; } return $css; } - static function translateCSSAttribute($attribute) { - return (isset(self::$cssAtributesTable[$attribute])) ? self::$cssAtributesTable[$attribute] : $attribute; + function translateCSSAttribute($attribute) { + return (isset($this->cssAtributesTable[$attribute])) ? $this->cssAtributesTable[$attribute] : $attribute; } } diff --git a/lib/Newsletter/Blocks/Social.php b/lib/Newsletter/Blocks/Social.php index 704ce34c10..909ab799a4 100644 --- a/lib/Newsletter/Blocks/Social.php +++ b/lib/Newsletter/Blocks/Social.php @@ -4,11 +4,17 @@ class Social { static function render($element) { $iconsBlock = ''; + if(is_array($element['icons'])) { foreach ($element['icons'] as $icon) { - $iconsBlock .= '' . $icon['iconType'] . ''; + $iconsBlock .= ' + + ' . $icon['iconType'] . ' + +'; } } + $template = ' diff --git a/lib/Newsletter/Blocks/Spacer.php b/lib/Newsletter/Blocks/Spacer.php index 558b2d319b..14ff428f94 100644 --- a/lib/Newsletter/Blocks/Spacer.php +++ b/lib/Newsletter/Blocks/Spacer.php @@ -5,6 +5,9 @@ use MailPoet\Newsletter\Blocks\Renderer as BlocksRenderer; class Spacer { static function render($element) { + + $blocksRenderer = new Renderer(); + // if the parent container (column) has background set and the divider element has a transparent background, // it will assume the newsletter background, not that of the parent container if($element['styles']['block']['backgroundColor'] === 'transparent') { @@ -13,7 +16,7 @@ class Spacer { $template = ' - + '; return $template; diff --git a/lib/Newsletter/Columns/Renderer.php b/lib/Newsletter/Columns/Renderer.php index 7386e6b909..af10762303 100644 --- a/lib/Newsletter/Columns/Renderer.php +++ b/lib/Newsletter/Columns/Renderer.php @@ -2,19 +2,22 @@ class Renderer { - static function render($columnsCount, $columnsData) { - $columnWidths = array( - 1 => 600, - 2 => 300, - 3 => 200 - ); - $columnClasses = array( - 1 => 'mailpoet_col-one', - 2 => 'mailpoet_col-two', - 3 => 'mailpoet_col-three' - ); - $columnWidth = $columnWidths[$columnsCount]; - $columnClass = $columnClasses[$columnsCount]; + public $columnWidths = array( + 1 => 600, + 2 => 300, + 3 => 200 + ); + + public $columnClasses = array( + 1 => 'mailpoet_col-one', + 2 => 'mailpoet_col-two', + 3 => 'mailpoet_col-three' + ); + + function render($columnsCount, $columnsData) { + + $columnWidth = $this->columnWidths[$columnsCount]; + $columnClass = $this->columnClasses[$columnsCount]; // open column container $columnContainerTemplate = ' @@ -30,12 +33,14 @@ class Renderer { '; + $columnOpenTemplate = ' '; + $columnCloseTemplate = '
diff --git a/lib/Newsletter/Renderer.php b/lib/Newsletter/Renderer.php index a426f435e5..01737cd8b9 100644 --- a/lib/Newsletter/Renderer.php +++ b/lib/Newsletter/Renderer.php @@ -4,9 +4,13 @@ if(!defined('ABSPATH')) exit; class Renderer { - public $template = 'NewsletterTemplate.html'; + public $template = 'Template.html'; function __construct($newsletterData) { + $this->blocksRenderer = new Blocks\Renderer(); + $this->columnsRenderer = new Columns\Renderer(); + $this->DOMQuery = new \pQuery(); + $this->CSSInliner = new \MailPoet\Util\CSS(); $this->data = $newsletterData; $this->template = file_get_contents(dirname(__FILE__) . '/' . $this->template); } @@ -29,8 +33,8 @@ class Renderer { foreach ($content['blocks'] as $contentBlock) { if(isset($contentBlock['blocks']) && is_array($contentBlock['blocks'])) { $columnCount = count($contentBlock['blocks']); - $columnData = Blocks\Renderer::render($contentBlock); - $newsletterContent .= Columns\Renderer::render($columnCount, $columnData); + $columnData = $this->blocksRenderer->render($contentBlock); + $newsletterContent .= $this->columnsRenderer->render($columnCount, $columnData); } } @@ -56,7 +60,7 @@ class Renderer { } $newsletterStyles .= $selector . '{' . PHP_EOL; foreach ($style as $attribute => $individualStyle) { - $newsletterStyles .= Blocks\Renderer::translateCSSAttribute($attribute) . ':' . $individualStyle . ';' . PHP_EOL; + $newsletterStyles .= $this->blocksRenderer->translateCSSAttribute($attribute) . ':' . $individualStyle . ';' . PHP_EOL; } $newsletterStyles .= '}' . PHP_EOL; } @@ -71,14 +75,12 @@ class Renderer { } function inlineCSSStyles($template) { - $inliner = new \MailPoet\Util\CSS(); - - return $inliner->inlineCSS(null, $template); + return $this->CSSInliner->inlineCSS(null, $template); } function postProcessRenderedTemplate($template) { // remove padding from last element inside each column - $DOM = \pQuery::parseStr($template); + $DOM = $this->DOMQuery->parseStr($template); $lastColumnElement = $DOM->query('.mailpoet_col > tbody > tr:last-child > td'); foreach ($lastColumnElement as $element) { $element->setAttribute('style', str_replace('padding-bottom:20px;', '', $element->attributes['style'])); diff --git a/lib/Newsletter/NewsletterTemplate.html b/lib/Newsletter/Template.html similarity index 100% rename from lib/Newsletter/NewsletterTemplate.html rename to lib/Newsletter/Template.html diff --git a/lib/Newsletter/NewsletterData.json b/lib/Newsletter/TestData.json similarity index 100% rename from lib/Newsletter/NewsletterData.json rename to lib/Newsletter/TestData.json From 1e6e59f58f959cb6a3d95addbec145447ccdc071 Mon Sep 17 00:00:00 2001 From: MrCasual Date: Tue, 15 Sep 2015 18:56:05 -0400 Subject: [PATCH 4/8] Refactored using PSEUDO* as per Marco's advice --- lib/Newsletter/Blocks/Renderer.php | 59 ++++++------------------------ lib/Newsletter/Renderer.php | 16 +++----- 2 files changed, 18 insertions(+), 57 deletions(-) diff --git a/lib/Newsletter/Blocks/Renderer.php b/lib/Newsletter/Blocks/Renderer.php index 978dddd41c..8a2829902a 100644 --- a/lib/Newsletter/Blocks/Renderer.php +++ b/lib/Newsletter/Blocks/Renderer.php @@ -29,56 +29,23 @@ class Renderer { ); function render($data, $column = null) { - $blockContent = ''; - $blockCount = count($data['blocks']); - - foreach ($data['blocks'] as $i => $block) { + array_map(function($block) use(&$blockContent, &$columns) { $blockContent .= $this->createElementFromBlockType($block); - if(isset($block['blocks']) && is_array($block['blocks'])) { + if(isset($block['blocks'])) { $blockContent = $this->render($block); } - // vertical orientation denotes column container - if($block['type'] == 'container' && $block['orientation'] == 'vertical') { + if($block['type'] === 'container' && $block['orientation'] === 'vertical') { $columns[] = $blockContent; } - } + }, $data['blocks']); return (isset($columns)) ? $columns : $blockContent; } function createElementFromBlockType($block) { - switch ($block['type']) { - case 'header': - $element = Header::render($block); - break; - case 'image': - $element = Image::render($block); - break; - case 'text': - $element = Text::render($block); - break; - case 'button': - $element = Button::render($block); - break; - case 'divider': - $element = Divider::render($block); - break; - case 'spacer': - $element = Spacer::render($block); - break; - case 'social': - $element = Social::render($block); - break; - case 'footer': - $element = Footer::render($block); - break; - default: - $element = '';//'UNRECOGNIZED ELEMENT'; - break; - } - - return $element; + $blockClass = __NAMESPACE__ . '\\' . ucfirst($block['type']); + return (class_exists($blockClass)) ? $blockClass::render($block) : ''; } function getBlockStyles($element, $ignore = false) { @@ -89,16 +56,14 @@ class Renderer { return $this->getStyles($element['styles'], 'block', $ignore); } - function getStyles($styles, $type, $ignore = false) { - $css = ''; - foreach ($styles[$type] as $attribute => $style) { - if($ignore && in_array($attribute, $ignore)) { - continue; + function getStyles($data, $type, $ignore = false) { + array_map(function($attribute, $style) use(&$styles, $ignore) { + if(!$ignore || !in_array($attribute, $ignore)) { + $styles .= $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; } - $css .= $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; - } + }, array_keys($data[$type]), $data[$type]); - return $css; + return $styles; } function translateCSSAttribute($attribute) { diff --git a/lib/Newsletter/Renderer.php b/lib/Newsletter/Renderer.php index 01737cd8b9..94ef6036b6 100644 --- a/lib/Newsletter/Renderer.php +++ b/lib/Newsletter/Renderer.php @@ -29,15 +29,11 @@ class Renderer { } function renderContent($content) { - $newsletterContent = ''; - foreach ($content['blocks'] as $contentBlock) { - if(isset($contentBlock['blocks']) && is_array($contentBlock['blocks'])) { - $columnCount = count($contentBlock['blocks']); - $columnData = $this->blocksRenderer->render($contentBlock); - $newsletterContent .= $this->columnsRenderer->render($columnCount, $columnData); - } - } - + array_map(function($contentBlock) use(&$newsletterContent) { + $columnCount = count($contentBlock['blocks']); + $columnData = $this->blocksRenderer->render($contentBlock); + $newsletterContent .= $this->columnsRenderer->render($columnCount, $columnData); + }, $content['blocks']); return $newsletterContent; } @@ -69,7 +65,7 @@ class Renderer { } function renderTemplate($template, $data) { - return preg_replace_callback('/{{\w+}}/', function ($matches) use (&$data) { + return preg_replace_callback('/{{\w+}}/', function($matches) use(&$data) { return array_shift($data); }, $template); } From 692e69d567c386c2a3fd986c847959f5cb35e6e3 Mon Sep 17 00:00:00 2001 From: marco Date: Thu, 17 Sep 2015 12:03:34 +0200 Subject: [PATCH 5/8] Pretty newsletter json test data. I'm trying to uderstand more about how the generated json works. --- lib/Newsletter/TestData.json | 1197 +++++++++++++++++++++++++++++++++- 1 file changed, 1196 insertions(+), 1 deletion(-) diff --git a/lib/Newsletter/TestData.json b/lib/Newsletter/TestData.json index 0757ee8917..54360dab84 100644 --- a/lib/Newsletter/TestData.json +++ b/lib/Newsletter/TestData.json @@ -1 +1,1196 @@ -{"data":{"data":{"type":"container","orientation":"vertical","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"container","orientation":"horizontal","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"container","orientation":"vertical","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"header","text":"

Display problems? View it in your browser. If I add a lot of text to test what happens... Well, nothing really (exciting) happens. Things don't break.

","styles":{"block":{"backgroundColor":"#333333"},"text":{"fontColor":"#aaaaaa","fontFamily":"Arial","fontSize":"12px","textAlign":"center"},"link":{"fontColor":"#a86b6b","textDecoration":"underline"}}},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/600x250.jpg","alt":"600x250","padded":true,"width":"600px","height":"250px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs sha

\n

\n

nk cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

\n
"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/600x250.jpg","alt":"600x250","padded":false,"width":"600px","height":"250px","styles":{"block":{"textAlign":"center"}}}]}]},{"orientation":"horizontal","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":true,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":false,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}}]},{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":true,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/300x125.jpg","alt":"300x125","padded":false,"width":"300px","height":"125px","styles":{"block":{"textAlign":"center"}}}]}]},{"orientation":"horizontal","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":true,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":false,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}}]},{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":true,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":false,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}}]},{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":true,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}},{"type":"text","text":"

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

"},{"type":"divider","styles":{"block":{"backgroundColor":"transparent","padding":"13px","borderStyle":"solid","borderWidth":"3px","borderColor":"#000000"}}},{"type":"spacer","styles":{"block":{"backgroundColor":"transparent","height":"50px"}}},{"type":"button","text":"Button","url":"http://example.org","styles":{"block":{"backgroundColor":"#666666","borderColor":"#1e3650","borderWidth":"1px","borderRadius":"20px","borderStyle":"solid","width":"100px","lineHeight":"30px","fontColor":"#ffffff","fontFamily":"Arial","fontSize":"13px","textAlign":"center"}}},{"type":"social","icons":[{"type":"socialIcon","iconType":"custom","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/custom.png","height":"32px","width":"32px","text":"Custom"},{"type":"socialIcon","iconType":"facebook","link":"http://www.facebook.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png","height":"32px","width":"32px","text":"Facebook"},{"type":"socialIcon","iconType":"twitter","link":"http://www.twitter.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png","height":"32px","width":"32px","text":"Twitter"},{"type":"socialIcon","iconType":"google-plus","link":"http://plus.google.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png","height":"32px","width":"32px","text":"Google Plus"},{"type":"socialIcon","iconType":"youtube","link":"http://www.youtube.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png","height":"32px","width":"32px","text":"Youtube"},{"type":"socialIcon","iconType":"website","link":"http://example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Website.png","height":"32px","width":"32px","text":"Website"},{"type":"socialIcon","iconType":"email","link":"mailto:mail@example.org","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Email.png","height":"32px","width":"32px","text":"Email"},{"type":"socialIcon","iconType":"instagram","link":"http://instagram.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png","height":"32px","width":"32px","text":"Instagram"},{"type":"socialIcon","iconType":"pinterest","link":"http://www.pinterest.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png","height":"32px","width":"32px","text":"Pinterest"},{"type":"socialIcon","iconType":"linkedin","link":"http://www.linkedin.com","image":"http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png","height":"32px","width":"32px","text":"LinkedIn"}],"iconSet":"default"},{"type":"image","link":"http://example.org","src":"http://mp3.mailpoet.net/various/200x83.jpg","alt":"200x83","padded":false,"width":"200px","height":"83px","styles":{"block":{"textAlign":"center"}}}]}]},{"orientation":"horizontal","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"orientation":"vertical","type":"container","styles":{"block":{"backgroundColor":"transparent"}},"blocks":[{"type":"footer","text":"

You are receiving this email because you opted in on our website. Update your email preferences or unsubscribe

\n

123 Maple Avenue
93102
Oakland, California

","styles":{"block":{"backgroundColor":"#333333"},"text":{"fontColor":"#aaaaaa","fontFamily":"Arial","fontSize":"12px","textAlign":"center"},"link":{"fontColor":"#a86b6b","textDecoration":"underline"}}}]}]}]},"styles":{"text":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"16px"},"h1":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"36px"},"h2":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"26px"},"h3":{"fontColor":"#565656","fontFamily":"Arial","fontSize":"18px"},"link":{"fontColor":"#a86b6b","textDecoration":"underline"},"newsletter":{"backgroundColor":"#999999"},"background":{"backgroundColor":"#333333"}},"newsletter":233}} \ No newline at end of file +{ + "data": { + "type": "container", + "orientation": "vertical", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "orientation": "horizontal", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "type": "header", + "text": "

Display problems? View it in your browser. If I add a lot of text to test what happens... Well, nothing really (exciting) happens. Things don't break.

", + "styles": { + "block": { + "backgroundColor": "#333333" + }, + "text": { + "fontColor": "#aaaaaa", + "fontFamily": "Arial", + "fontSize": "12px", + "textAlign": "center" + }, + "link": { + "fontColor": "#a86b6b", + "textDecoration": "underline" + } + } + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/600x250.jpg", + "alt": "600x250", + "padded": true, + "width": "600px", + "height": "250px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "type": "text", + "text": "

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, + { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, + { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, + { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, + { + "type": "social", + "icons": [ + { + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, + { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, + { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, + { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, + { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, + { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, + { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, + { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, + { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, + { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + } + ], + "iconSet": "default" + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/600x250.jpg", + "alt": "600x250", + "padded": false, + "width": "600px", + "height": "250px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "orientation": "horizontal", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", + "alt": "300x125", + "padded": true, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "type": "text", + "text": "

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, + { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, + { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, + { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, + { + "type": "social", + "icons": [ + { + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, + { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, + { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, + { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, + { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, + { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, + { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, + { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, + { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, + { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + } + ], + "iconSet": "default" + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", + "alt": "300x125", + "padded": false, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + } + ] + }, + { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", + "alt": "300x125", + "padded": true, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "type": "text", + "text": "

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, + { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, + { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, + { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, + { + "type": "social", + "icons": [ + { + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, + { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, + { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, + { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, + { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, + { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, + { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, + { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, + { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, + { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + } + ], + "iconSet": "default" + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", + "alt": "300x125", + "padded": false, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + } + ] + } + ] + } + ] + } + ] + }, + { + "orientation": "horizontal", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", + "alt": "200x83", + "padded": true, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "type": "text", + "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, + { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, + { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, + { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, + { + "type": "social", + "icons": [ + { + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, + { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, + { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, + { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, + { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, + { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, + { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, + { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, + { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, + { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + } + ], + "iconSet": "default" + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", + "alt": "200x83", + "padded": false, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + } + ] + }, + { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", + "alt": "200x83", + "padded": true, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "type": "text", + "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, + { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, + { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, + { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, + { + "type": "social", + "icons": [ + { + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, + { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, + { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, + { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, + { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, + { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, + { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, + { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, + { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, + { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + } + ], + "iconSet": "default" + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", + "alt": "200x83", + "padded": false, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + } + ] + }, + { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [ + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", + "alt": "200x83", + "padded": true, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, + { + "type": "text", + "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, + { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, + { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, + { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, + { + "type": "social", + "icons": [ + { + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, + { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, + { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, + { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, + { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, + { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, + { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, + { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, + { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, + { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + } + ], + "iconSet": "default" + }, + { + "type": "image", + "link": "http://example.org", + "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", + "alt": "200x83", + "padded": false, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + } + ] + } + ] + }, + { + "type": "footer", + "text": "

You are receiving this email because you opted in on our website. Update your email preferences or unsubscribe

\n

123 Maple Avenue
93102
Oakland, California

", + "styles": { + "block": { + "backgroundColor": "#333333" + }, + "text": { + "fontColor": "#aaaaaa", + "fontFamily": "Arial", + "fontSize": "12px", + "textAlign": "center" + }, + "link": { + "fontColor": "#a86b6b", + "textDecoration": "underline" + } + } + } + ] + }, + "styles": { + "text": { + "fontColor": "#565656", + "fontFamily": "Arial", + "fontSize": "16px" + }, + "h1": { + "fontColor": "#565656", + "fontFamily": "Arial", + "fontSize": "36px" + }, + "h2": { + "fontColor": "#565656", + "fontFamily": "Arial", + "fontSize": "26px" + }, + "h3": { + "fontColor": "#565656", + "fontFamily": "Arial", + "fontSize": "18px" + }, + "link": { + "fontColor": "#a86b6b", + "textDecoration": "underline" + }, + "newsletter": { + "backgroundColor": "#999999" + }, + "background": { + "backgroundColor": "#333333" + } + } +} From 01b54168820b3cedbf97f9fc6faf9bc751f8a62f Mon Sep 17 00:00:00 2001 From: MrCasual Date: Mon, 21 Sep 2015 13:18:01 -0400 Subject: [PATCH 6/8] Refactors Newsletters as per @badshark's comments --- lib/Newsletter/Blocks/Button.php | 49 -------- lib/Newsletter/Blocks/Divider.php | 23 ---- lib/Newsletter/Blocks/Footer.php | 28 ----- lib/Newsletter/Blocks/Header.php | 28 ----- lib/Newsletter/Blocks/Image.php | 24 ---- lib/Newsletter/Blocks/Renderer.php | 72 ----------- lib/Newsletter/Blocks/Social.php | 28 ----- lib/Newsletter/Blocks/Text.php | 73 ----------- lib/Newsletter/Columns/Renderer.php | 78 ------------ lib/Newsletter/Renderer/Blocks/Button.php | 49 ++++++++ lib/Newsletter/Renderer/Blocks/Divider.php | 25 ++++ lib/Newsletter/Renderer/Blocks/Footer.php | 32 +++++ lib/Newsletter/Renderer/Blocks/Header.php | 32 +++++ lib/Newsletter/Renderer/Blocks/Image.php | 26 ++++ lib/Newsletter/Renderer/Blocks/Renderer.php | 25 ++++ lib/Newsletter/Renderer/Blocks/Social.php | 28 +++++ .../{ => Renderer}/Blocks/Spacer.php | 12 +- lib/Newsletter/Renderer/Blocks/Text.php | 116 ++++++++++++++++++ lib/Newsletter/Renderer/Columns/Renderer.php | 78 ++++++++++++ lib/Newsletter/{ => Renderer}/Renderer.php | 9 +- lib/Newsletter/Renderer/StylesHelper.php | 40 ++++++ lib/Newsletter/{ => Renderer}/Template.html | 0 lib/Newsletter/{ => Renderer}/TestData.json | 0 23 files changed, 462 insertions(+), 413 deletions(-) delete mode 100644 lib/Newsletter/Blocks/Button.php delete mode 100644 lib/Newsletter/Blocks/Divider.php delete mode 100644 lib/Newsletter/Blocks/Footer.php delete mode 100644 lib/Newsletter/Blocks/Header.php delete mode 100644 lib/Newsletter/Blocks/Image.php delete mode 100644 lib/Newsletter/Blocks/Renderer.php delete mode 100644 lib/Newsletter/Blocks/Social.php delete mode 100644 lib/Newsletter/Blocks/Text.php delete mode 100644 lib/Newsletter/Columns/Renderer.php create mode 100644 lib/Newsletter/Renderer/Blocks/Button.php create mode 100644 lib/Newsletter/Renderer/Blocks/Divider.php create mode 100644 lib/Newsletter/Renderer/Blocks/Footer.php create mode 100644 lib/Newsletter/Renderer/Blocks/Header.php create mode 100644 lib/Newsletter/Renderer/Blocks/Image.php create mode 100644 lib/Newsletter/Renderer/Blocks/Renderer.php create mode 100644 lib/Newsletter/Renderer/Blocks/Social.php rename lib/Newsletter/{ => Renderer}/Blocks/Spacer.php (60%) create mode 100644 lib/Newsletter/Renderer/Blocks/Text.php create mode 100644 lib/Newsletter/Renderer/Columns/Renderer.php rename lib/Newsletter/{ => Renderer}/Renderer.php (87%) create mode 100644 lib/Newsletter/Renderer/StylesHelper.php rename lib/Newsletter/{ => Renderer}/Template.html (100%) rename lib/Newsletter/{ => Renderer}/TestData.json (100%) diff --git a/lib/Newsletter/Blocks/Button.php b/lib/Newsletter/Blocks/Button.php deleted file mode 100644 index 8f82f21756..0000000000 --- a/lib/Newsletter/Blocks/Button.php +++ /dev/null @@ -1,49 +0,0 @@ - - - - -'; - - return $template; - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Divider.php b/lib/Newsletter/Blocks/Divider.php deleted file mode 100644 index b19bdc6b9c..0000000000 --- a/lib/Newsletter/Blocks/Divider.php +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - -
-
- -'; - - return $template; - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Footer.php b/lib/Newsletter/Blocks/Footer.php deleted file mode 100644 index 1cd1842e1e..0000000000 --- a/lib/Newsletter/Blocks/Footer.php +++ /dev/null @@ -1,28 +0,0 @@ -getStyles($element['styles'], 'link') . '"', $element['text']); - } - - // apply text styles - if(isset($element['styles']['link'])) { - $element['text'] = str_replace('getStyles($element['styles'], 'block') . '" valign="top"> -
' . $element['text'] . '
- -'; - - return $template; - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Header.php b/lib/Newsletter/Blocks/Header.php deleted file mode 100644 index c4c3359b5f..0000000000 --- a/lib/Newsletter/Blocks/Header.php +++ /dev/null @@ -1,28 +0,0 @@ -getStyles($element['styles'], 'link') . '"', $element['text']); - } - - // apply text styles - if(isset($element['styles']['link'])) { - $element['text'] = str_replace('getBlockStyles($element) . '" valign="top"> -
' . $element['text'] . '
- -'; - - return $template; - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Image.php b/lib/Newsletter/Blocks/Image.php deleted file mode 100644 index 2810983204..0000000000 --- a/lib/Newsletter/Blocks/Image.php +++ /dev/null @@ -1,24 +0,0 @@ - - - - -'; - - return $template; - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Renderer.php b/lib/Newsletter/Blocks/Renderer.php deleted file mode 100644 index 8a2829902a..0000000000 --- a/lib/Newsletter/Blocks/Renderer.php +++ /dev/null @@ -1,72 +0,0 @@ - "Arial, 'Helvetica Neue', Helvetica, sans-serif", - 'Comic Sans MS' => "'Comic Sans MS', 'Marker Felt-Thin', Arial, sans-serif", - 'Courier New' => "'Courier New', Courier, 'Lucida Sans Typewriter', 'Lucida Typewriter', monospace", - 'Georgia' => "Georgia, Times, 'Times New Roman', serif", - 'Lucida' => "'Lucida Sans Unicode', 'Lucida Grande', sans-serif", - 'Tahoma' => "Tahoma, Verdana, Segoe, sans-serif", - 'Times New Roman' => "'Times New Roman', Times, Baskerville, Georgia, serif", - 'Trebuchet MS' => "'Trebuchet MS', 'Lucida Grande', 'Lucida Sans Unicode', 'Lucida Sans', Tahoma, sans-serif", - 'Verdana' => "Verdana, Geneva, sans-serif" - ); - - public $cssAtributesTable = array( - 'backgroundColor' => 'background-color', - 'fontColor' => 'color', - 'fontFamily' => 'font-family', - 'textDecoration' => 'text-decoration', - 'textAlign' => 'text-align', - 'fontSize' => 'font-size', - 'borderWidth' => 'border-width', - 'borderStyle' => 'border-style', - 'borderColor' => 'border-color', - 'borderRadius' => 'border-radius', - 'lineHeight' => 'line-height' - ); - - function render($data, $column = null) { - array_map(function($block) use(&$blockContent, &$columns) { - $blockContent .= $this->createElementFromBlockType($block); - if(isset($block['blocks'])) { - $blockContent = $this->render($block); - } - // vertical orientation denotes column container - if($block['type'] === 'container' && $block['orientation'] === 'vertical') { - $columns[] = $blockContent; - } - }, $data['blocks']); - - return (isset($columns)) ? $columns : $blockContent; - } - - function createElementFromBlockType($block) { - $blockClass = __NAMESPACE__ . '\\' . ucfirst($block['type']); - return (class_exists($blockClass)) ? $blockClass::render($block) : ''; - } - - function getBlockStyles($element, $ignore = false) { - if(!isset($element['styles']['block'])) { - return; - } - - return $this->getStyles($element['styles'], 'block', $ignore); - } - - function getStyles($data, $type, $ignore = false) { - array_map(function($attribute, $style) use(&$styles, $ignore) { - if(!$ignore || !in_array($attribute, $ignore)) { - $styles .= $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; - } - }, array_keys($data[$type]), $data[$type]); - - return $styles; - } - - function translateCSSAttribute($attribute) { - return (isset($this->cssAtributesTable[$attribute])) ? $this->cssAtributesTable[$attribute] : $attribute; - } -} diff --git a/lib/Newsletter/Blocks/Social.php b/lib/Newsletter/Blocks/Social.php deleted file mode 100644 index 909ab799a4..0000000000 --- a/lib/Newsletter/Blocks/Social.php +++ /dev/null @@ -1,28 +0,0 @@ - - ' . $icon['iconType'] . ' - -'; - } - } - - $template = ' - - -
' . $iconsBlock . '
- -'; - - return $template; - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Text.php b/lib/Newsletter/Blocks/Text.php deleted file mode 100644 index 7cfbd29ed9..0000000000 --- a/lib/Newsletter/Blocks/Text.php +++ /dev/null @@ -1,73 +0,0 @@ - elements to tables - $blockquoteTemplate = ' - - - - - -
- $1 -
-
'; - $element['text'] = preg_replace('/
(.*?)<\/blockquote>/s', $blockquoteTemplate, $element['text']); - - // add line breaks after tags - $element['text'] = preg_replace('/(<\/(ul|ol|h\d)>)/', '$1
', $element['text']); - - $element['text'] = self::removeEmptyHTMLTags($element['text']); - - // convert empty

tags to line breaks - $element['text'] = preg_replace('/<\/p>/', '
', $element['text']); - - // convert

to - $element['text'] = preg_replace('/

(.*?)<\/p>/', '
$1
', $element['text']); - $element['text'] = preg_replace('/(.*?)<\/p>/', '
$2
', $element['text']); - - // remove the last break line - $element['text'] = preg_replace('/
([^
]*)$/s', '', $element['text']); - - $template = ' - - ' . $element['text'] . ' -'; - - return $template; - } - - static function removeEmptyHTMLTags($html) { - $pattern = <<<'EOD' - ~ - < - (?: - !--[^-]*(?:-(?!->)[^-]*)*-->[^<]*(*SKIP)(*F) # skip comments - | - ( # group 1 - (span|em|strong) # tag name in group 2 - [^"'>]* #'"# all that is not a quote or a closing angle bracket - (?: # quoted attributes - "[^\\"]*(?:\\.[^\\"]*)*+" [^"'>]* #'"# double quote - | - '[^\\']*(?:\\.[^\\']*)*+' [^"'>]* #'"# single quote - )*+ - > - \s* - (?: - \s* # html comments - | - <(?1) \s* # recursion with the group 1 - )*+ - # closing tag - ) # end of the group 1 - ) - ~sxi -EOD; - - return preg_replace($pattern, '', $html); - } - -} \ No newline at end of file diff --git a/lib/Newsletter/Columns/Renderer.php b/lib/Newsletter/Columns/Renderer.php deleted file mode 100644 index af10762303..0000000000 --- a/lib/Newsletter/Columns/Renderer.php +++ /dev/null @@ -1,78 +0,0 @@ - 600, - 2 => 300, - 3 => 200 - ); - - public $columnClasses = array( - 1 => 'mailpoet_col-one', - 2 => 'mailpoet_col-two', - 3 => 'mailpoet_col-three' - ); - - function render($columnsCount, $columnsData) { - - $columnWidth = $this->columnWidths[$columnsCount]; - $columnClass = $this->columnClasses[$columnsCount]; - - // open column container - $columnContainerTemplate = ' - - - - - - -
- '; - - $columnOpenTemplate = ' - - '; - - $columnCloseTemplate = ' - -
-'; - - foreach ($columnsData as $index => $columnData) { - $index++; - $columnContainerTemplate .= $columnOpenTemplate . $columnData; - if($columnsCount > 1 && $index != $columnsCount) { - $columnContainerTemplate .= $columnCloseTemplate; - } - } - - // close column container - $columnContainerTemplate .= ' -
- - - - - -'; - - return $columnContainerTemplate; - } -} diff --git a/lib/Newsletter/Renderer/Blocks/Button.php b/lib/Newsletter/Renderer/Blocks/Button.php new file mode 100644 index 0000000000..fa3b07c1de --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Button.php @@ -0,0 +1,49 @@ + + +

+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Divider.php b/lib/Newsletter/Renderer/Blocks/Divider.php new file mode 100644 index 0000000000..684494eaf7 --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Divider.php @@ -0,0 +1,25 @@ + + + + + + +
+
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Footer.php b/lib/Newsletter/Renderer/Blocks/Footer.php new file mode 100644 index 0000000000..e3387726f2 --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Footer.php @@ -0,0 +1,32 @@ +getStyles($element['styles'], 'link') . '"', $element['text']); + } + + // apply text styles + if(isset($element['styles']['link'])) { + $element['text'] = str_replace('getStyles($element['styles'], 'block') . '" + valign="top"> +
' . $element['text'] . '
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Header.php b/lib/Newsletter/Renderer/Blocks/Header.php new file mode 100644 index 0000000000..8bfe1508cf --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Header.php @@ -0,0 +1,32 @@ +getStyles($element['styles'], 'link') . '"', $element['text']); + } + + // apply text styles + if(isset($element['styles']['link'])) { + $element['text'] = str_replace('getBlockStyles($element) . '" + valign="top"> +
' . $element['text'] . '
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Image.php b/lib/Newsletter/Renderer/Blocks/Image.php new file mode 100644 index 0000000000..82472fb2c6 --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Image.php @@ -0,0 +1,26 @@ + + + + + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Renderer.php b/lib/Newsletter/Renderer/Blocks/Renderer.php new file mode 100644 index 0000000000..f06d8548d3 --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Renderer.php @@ -0,0 +1,25 @@ +createElementFromBlockType($block); + if(isset($block['blocks'])) { + $blockContent = $this->render($block); + } + // vertical orientation denotes column container + if($block['type'] === 'container' && $block['orientation'] === 'vertical') { + $columns[] = $blockContent; + } + }, $data['blocks']); + + return (isset($columns)) ? $columns : $blockContent; + } + + function createElementFromBlockType($block) { + $blockClass = __NAMESPACE__ . '\\' . ucfirst($block['type']); + return (class_exists($blockClass)) ? $blockClass::render($block) : ''; + } + +} diff --git a/lib/Newsletter/Renderer/Blocks/Social.php b/lib/Newsletter/Renderer/Blocks/Social.php new file mode 100644 index 0000000000..3285f96111 --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Social.php @@ -0,0 +1,28 @@ + + ' . $icon['iconType'] . ' + + '; + } + } + + $template = ' + + +
' . $iconsBlock . '
+ + '; + + return $template; + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Blocks/Spacer.php b/lib/Newsletter/Renderer/Blocks/Spacer.php similarity index 60% rename from lib/Newsletter/Blocks/Spacer.php rename to lib/Newsletter/Renderer/Blocks/Spacer.php index 14ff428f94..9262001434 100644 --- a/lib/Newsletter/Blocks/Spacer.php +++ b/lib/Newsletter/Renderer/Blocks/Spacer.php @@ -1,12 +1,12 @@ - - -'; + + + '; return $template; } diff --git a/lib/Newsletter/Renderer/Blocks/Text.php b/lib/Newsletter/Renderer/Blocks/Text.php new file mode 100644 index 0000000000..e2a1985434 --- /dev/null +++ b/lib/Newsletter/Renderer/Blocks/Text.php @@ -0,0 +1,116 @@ + "Arial, 'Helvetica Neue', Helvetica, sans-serif", + 'Comic Sans MS' => "'Comic Sans MS', 'Marker Felt-Thin', Arial, sans-serif", + 'Courier New' => "'Courier New', Courier, 'Lucida Sans Typewriter', 'Lucida Typewriter', monospace", + 'Georgia' => "Georgia, Times, 'Times New Roman', serif", + 'Lucida' => "'Lucida Sans Unicode', 'Lucida Grande', sans-serif", + 'Tahoma' => "Tahoma, Verdana, Segoe, sans-serif", + 'Times New Roman' => "'Times New Roman', Times, Baskerville, Georgia, serif", + 'Trebuchet MS' => "'Trebuchet MS', 'Lucida Grande', 'Lucida Sans Unicode', 'Lucida Sans', Tahoma, sans-serif", + 'Verdana' => "Verdana, Geneva, sans-serif" + ); + + static function render($element) { + $html = $element['text']; + + $html = self::convertBlockquotesToTables($html); + $html = self::addLineBreakAfterTags($html); + $html = self::removeEmptyTags($html); + $html = self::convertEmptyParagraphsToLineBreaks($html); + $html = self::convertParagraphsToTables($html); + $html = self::removeLastBreakLine($html); + + $template = ' + + ' . $html . ' + '; + + return $template; + } + + static function removeLastBreakLine($html) { + return preg_replace('/
([^
]*)$/s', '', $html); + } + + static function convertParagraphsToTables($html) { + $html = preg_replace('/

(.*?)<\/p>/', ' + + + + +
+ + $1 + +
', $html); + + return preg_replace('/(.*?)<\/p>/', ' + + + + +
+ + $2 + +
', $html); + } + + static function convertEmptyParagraphsToLineBreaks($html) { + return preg_replace('/<\/p>/', '
', $html); + } + + static function addLineBreakAfterTags($html) { + return preg_replace('/(<\/(ul|ol|h\d)>)/', '$1
', $html); + } + + static function convertBlockquotesToTables($html) { + $template = ' + + + + + + +
$1
+
'; + + return preg_replace('/

(.*?)<\/blockquote>/s', $template, $html); + } + + static function removeEmptyTags($html) { + $pattern = <<<'EOD' + ~ + < + (?: + !--[^-]*(?:-(?!->)[^-]*)*-->[^<]*(*SKIP)(*F) # skip comments + | + ( # group 1 + (span|em|strong) # tag name in group 2 + [^"'>]* #'"# all that is not a quote or a closing angle bracket + (?: # quoted attributes + "[^\\"]*(?:\\.[^\\"]*)*+" [^"'>]* #'"# double quote + | + '[^\\']*(?:\\.[^\\']*)*+' [^"'>]* #'"# single quote + )*+ + > + \s* + (?: + \s* # html comments + | + <(?1) \s* # recursion with the group 1 + )*+ + # closing tag + ) # end of the group 1 + ) + ~sxi +EOD; + + return preg_replace($pattern, '', $html); + } + +} \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Columns/Renderer.php b/lib/Newsletter/Renderer/Columns/Renderer.php new file mode 100644 index 0000000000..236ee2d9fb --- /dev/null +++ b/lib/Newsletter/Renderer/Columns/Renderer.php @@ -0,0 +1,78 @@ + 600, + 2 => 300, + 3 => 200 + ); + + public $columnClasses = array( + 1 => 'mailpoet_col-one', + 2 => 'mailpoet_col-two', + 3 => 'mailpoet_col-three' + ); + + function render($columnsCount, $columnsData) { + + $columnWidth = $this->columnWidths[$columnsCount]; + $columnClass = $this->columnClasses[$columnsCount]; + + // open column container + $columnContainerTemplate = ' + + + + + + +
+ '; + + $columnOpenTemplate = ' + + '; + + $columnCloseTemplate = ' + +
+ '; + + foreach ($columnsData as $index => $columnData) { + $index++; + $columnContainerTemplate .= $columnOpenTemplate . $columnData; + if($columnsCount > 1 && $index != $columnsCount) { + $columnContainerTemplate .= $columnCloseTemplate; + } + } + + // close column container + $columnContainerTemplate .= ' +
+ + + + + + '; + + return $columnContainerTemplate; + } +} diff --git a/lib/Newsletter/Renderer.php b/lib/Newsletter/Renderer/Renderer.php similarity index 87% rename from lib/Newsletter/Renderer.php rename to lib/Newsletter/Renderer/Renderer.php index 94ef6036b6..963d376eea 100644 --- a/lib/Newsletter/Renderer.php +++ b/lib/Newsletter/Renderer/Renderer.php @@ -1,5 +1,5 @@ blocksRenderer = new Blocks\Renderer(); $this->columnsRenderer = new Columns\Renderer(); + $this->stylesHelper = new StylesHelper(); $this->DOMQuery = new \pQuery(); $this->CSSInliner = new \MailPoet\Util\CSS(); $this->data = $newsletterData; @@ -29,7 +30,7 @@ class Renderer { } function renderContent($content) { - array_map(function($contentBlock) use(&$newsletterContent) { + array_map(function ($contentBlock) use (&$newsletterContent) { $columnCount = count($contentBlock['blocks']); $columnData = $this->blocksRenderer->render($contentBlock); $newsletterContent .= $this->columnsRenderer->render($columnCount, $columnData); @@ -56,7 +57,7 @@ class Renderer { } $newsletterStyles .= $selector . '{' . PHP_EOL; foreach ($style as $attribute => $individualStyle) { - $newsletterStyles .= $this->blocksRenderer->translateCSSAttribute($attribute) . ':' . $individualStyle . ';' . PHP_EOL; + $newsletterStyles .= $this->stylesHelper->translateCSSAttribute($attribute) . ':' . $individualStyle . ';' . PHP_EOL; } $newsletterStyles .= '}' . PHP_EOL; } @@ -65,7 +66,7 @@ class Renderer { } function renderTemplate($template, $data) { - return preg_replace_callback('/{{\w+}}/', function($matches) use(&$data) { + return preg_replace_callback('/{{\w+}}/', function ($matches) use (&$data) { return array_shift($data); }, $template); } diff --git a/lib/Newsletter/Renderer/StylesHelper.php b/lib/Newsletter/Renderer/StylesHelper.php new file mode 100644 index 0000000000..dd0339b568 --- /dev/null +++ b/lib/Newsletter/Renderer/StylesHelper.php @@ -0,0 +1,40 @@ + 'background-color', + 'fontColor' => 'color', + 'fontFamily' => 'font-family', + 'textDecoration' => 'text-decoration', + 'textAlign' => 'text-align', + 'fontSize' => 'font-size', + 'borderWidth' => 'border-width', + 'borderStyle' => 'border-style', + 'borderColor' => 'border-color', + 'borderRadius' => 'border-radius', + 'lineHeight' => 'line-height' + ); + + function getBlockStyles($element, $ignore = false) { + if(!isset($element['styles']['block'])) { + return; + } + + return $this->getStyles($element['styles'], 'block', $ignore); + } + + function getStyles($data, $type, $ignore = false) { + array_map(function ($attribute, $style) use (&$styles, $ignore) { + if(!$ignore || !in_array($attribute, $ignore)) { + $styles .= $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; + } + }, array_keys($data[$type]), $data[$type]); + + return $styles; + } + + function translateCSSAttribute($attribute) { + return (array_key_exists($attribute, $this->cssAtributesTable)) ? $this->cssAtributesTable[$attribute] : $attribute; + } +} diff --git a/lib/Newsletter/Template.html b/lib/Newsletter/Renderer/Template.html similarity index 100% rename from lib/Newsletter/Template.html rename to lib/Newsletter/Renderer/Template.html diff --git a/lib/Newsletter/TestData.json b/lib/Newsletter/Renderer/TestData.json similarity index 100% rename from lib/Newsletter/TestData.json rename to lib/Newsletter/Renderer/TestData.json From b3e376cd011a41c799ecc22721881b6bc48fcec8 Mon Sep 17 00:00:00 2001 From: MrCasual Date: Wed, 23 Sep 2015 11:24:08 -0400 Subject: [PATCH 7/8] - Refactored using @badshark's comments - Integrated changes to JSON data --- lib/Newsletter/Renderer/Blocks/Button.php | 2 - lib/Newsletter/Renderer/Blocks/Divider.php | 2 - lib/Newsletter/Renderer/Blocks/Footer.php | 2 - lib/Newsletter/Renderer/Blocks/Header.php | 2 - lib/Newsletter/Renderer/Blocks/Image.php | 2 - lib/Newsletter/Renderer/Blocks/Renderer.php | 3 +- lib/Newsletter/Renderer/Blocks/Social.php | 2 - lib/Newsletter/Renderer/Blocks/Spacer.php | 2 - lib/Newsletter/Renderer/Blocks/Text.php | 2 - lib/Newsletter/Renderer/Columns/Renderer.php | 2 - lib/Newsletter/Renderer/Renderer.php | 15 +- lib/Newsletter/Renderer/StylesHelper.php | 15 +- lib/Newsletter/Renderer/Template.html | 4 +- lib/Newsletter/Renderer/TestData.json | 2208 +++++++++--------- 14 files changed, 1066 insertions(+), 1197 deletions(-) diff --git a/lib/Newsletter/Renderer/Blocks/Button.php b/lib/Newsletter/Renderer/Blocks/Button.php index fa3b07c1de..b34223cd58 100644 --- a/lib/Newsletter/Renderer/Blocks/Button.php +++ b/lib/Newsletter/Renderer/Blocks/Button.php @@ -3,7 +3,6 @@ use MailPoet\Newsletter\Renderer\StylesHelper; class Button { - static function render($element) { $stylesHelper = new StylesHelper(); @@ -45,5 +44,4 @@ class Button { return $template; } - } \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Divider.php b/lib/Newsletter/Renderer/Blocks/Divider.php index 684494eaf7..ccab9ce7a4 100644 --- a/lib/Newsletter/Renderer/Blocks/Divider.php +++ b/lib/Newsletter/Renderer/Blocks/Divider.php @@ -1,7 +1,6 @@ @@ -21,5 +20,4 @@ class Divider { return $template; } - } \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Footer.php b/lib/Newsletter/Renderer/Blocks/Footer.php index e3387726f2..005c75f62c 100644 --- a/lib/Newsletter/Renderer/Blocks/Footer.php +++ b/lib/Newsletter/Renderer/Blocks/Footer.php @@ -3,7 +3,6 @@ use MailPoet\Newsletter\Renderer\StylesHelper; class Footer { - static function render($element) { $stylesHelper = new StylesHelper(); @@ -28,5 +27,4 @@ class Footer { return $template; } - } \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Header.php b/lib/Newsletter/Renderer/Blocks/Header.php index 8bfe1508cf..3be509324c 100644 --- a/lib/Newsletter/Renderer/Blocks/Header.php +++ b/lib/Newsletter/Renderer/Blocks/Header.php @@ -3,7 +3,6 @@ use MailPoet\Newsletter\Renderer\StylesHelper; class Header { - static function render($element) { $stylesHelper = new StylesHelper(); @@ -28,5 +27,4 @@ class Header { return $template; } - } \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Image.php b/lib/Newsletter/Renderer/Blocks/Image.php index 82472fb2c6..92cc0b0327 100644 --- a/lib/Newsletter/Renderer/Blocks/Image.php +++ b/lib/Newsletter/Renderer/Blocks/Image.php @@ -3,7 +3,6 @@ use MailPoet\Newsletter\Renderer\StylesHelper; class Image { - static function render($element) { $stylesHelper = new StylesHelper(); @@ -22,5 +21,4 @@ class Image { return $template; } - } \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Blocks/Renderer.php b/lib/Newsletter/Renderer/Blocks/Renderer.php index f06d8548d3..3db1285863 100644 --- a/lib/Newsletter/Renderer/Blocks/Renderer.php +++ b/lib/Newsletter/Renderer/Blocks/Renderer.php @@ -1,8 +1,7 @@ createElementFromBlockType($block); if(isset($block['blocks'])) { diff --git a/lib/Newsletter/Renderer/Blocks/Social.php b/lib/Newsletter/Renderer/Blocks/Social.php index 3285f96111..241e4cca84 100644 --- a/lib/Newsletter/Renderer/Blocks/Social.php +++ b/lib/Newsletter/Renderer/Blocks/Social.php @@ -1,7 +1,6 @@ "Arial, 'Helvetica Neue', Helvetica, sans-serif", 'Comic Sans MS' => "'Comic Sans MS', 'Marker Felt-Thin', Arial, sans-serif", @@ -112,5 +111,4 @@ EOD; return preg_replace($pattern, '', $html); } - } \ No newline at end of file diff --git a/lib/Newsletter/Renderer/Columns/Renderer.php b/lib/Newsletter/Renderer/Columns/Renderer.php index 236ee2d9fb..975d9bba02 100644 --- a/lib/Newsletter/Renderer/Columns/Renderer.php +++ b/lib/Newsletter/Renderer/Columns/Renderer.php @@ -1,7 +1,6 @@ 600, 2 => 300, @@ -15,7 +14,6 @@ class Renderer { ); function render($columnsCount, $columnsData) { - $columnWidth = $this->columnWidths[$columnsCount]; $columnClass = $this->columnClasses[$columnsCount]; diff --git a/lib/Newsletter/Renderer/Renderer.php b/lib/Newsletter/Renderer/Renderer.php index 963d376eea..c7cb08f0dd 100644 --- a/lib/Newsletter/Renderer/Renderer.php +++ b/lib/Newsletter/Renderer/Renderer.php @@ -3,7 +3,6 @@ namespace MailPoet\Newsletter\Renderer; if(!defined('ABSPATH')) exit; class Renderer { - public $template = 'Template.html'; function __construct($newsletterData) { @@ -17,8 +16,8 @@ class Renderer { } function renderAll() { - $newsletterContent = $this->renderContent($this->data['data']); - $newsletterStyles = $this->renderStyles($this->data['styles']); + $newsletterContent = $this->renderContent($this->data['content']); + $newsletterStyles = $this->renderStyles($this->data['globalStyles']); $renderedTemplate = $this->renderTemplate($this->template, array( $newsletterStyles, @@ -30,12 +29,12 @@ class Renderer { } function renderContent($content) { - array_map(function ($contentBlock) use (&$newsletterContent) { + $newsletterContent = array_map(function ($contentBlock) { $columnCount = count($contentBlock['blocks']); $columnData = $this->blocksRenderer->render($contentBlock); - $newsletterContent .= $this->columnsRenderer->render($columnCount, $columnData); + return $this->columnsRenderer->render($columnCount, $columnData); }, $content['blocks']); - return $newsletterContent; + return implode('', $newsletterContent); } function renderStyles($styles) { @@ -45,13 +44,13 @@ class Renderer { case 'text': $selector = 'span.paragraph, ul, ol'; break; - case 'background': + case 'body': $selector = '.mailpoet_content-wrapper'; break; case 'link': $selector = '.mailpoet_content-wrapper a'; break; - case 'newsletter': + case 'wrapper': $selector = '.mailpoet_container, .mailpoet_col-one, .mailpoet_col-two, .mailpoet_col-three'; break; } diff --git a/lib/Newsletter/Renderer/StylesHelper.php b/lib/Newsletter/Renderer/StylesHelper.php index dd0339b568..1898cdc492 100644 --- a/lib/Newsletter/Renderer/StylesHelper.php +++ b/lib/Newsletter/Renderer/StylesHelper.php @@ -1,7 +1,6 @@ 'background-color', 'fontColor' => 'color', @@ -16,22 +15,20 @@ class StylesHelper { 'lineHeight' => 'line-height' ); - function getBlockStyles($element, $ignore = false) { + function getBlockStyles($element) { if(!isset($element['styles']['block'])) { return; } - return $this->getStyles($element['styles'], 'block', $ignore); + return $this->getStyles($element['styles'], 'block'); } - function getStyles($data, $type, $ignore = false) { - array_map(function ($attribute, $style) use (&$styles, $ignore) { - if(!$ignore || !in_array($attribute, $ignore)) { - $styles .= $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; - } + function getStyles($data, $type) { + $styles = array_map(function ($attribute, $style) { + return $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; }, array_keys($data[$type]), $data[$type]); - return $styles; + return implode('', $styles); } function translateCSSAttribute($attribute) { diff --git a/lib/Newsletter/Renderer/Template.html b/lib/Newsletter/Renderer/Template.html index 9e44d82dd2..283b37326d 100644 --- a/lib/Newsletter/Renderer/Template.html +++ b/lib/Newsletter/Renderer/Template.html @@ -151,7 +151,7 @@ .mailpoet_padded { padding-left: 20px; padding-right: 20px; - word-break: break-word; + /*word-break: break-all;*/ word-wrap: break-word; } @@ -238,7 +238,7 @@ } .mailpoet_social img { - height: 32x !important; + height: 32px !important; width: 32px !important; padding-bottom: 20px !important; } diff --git a/lib/Newsletter/Renderer/TestData.json b/lib/Newsletter/Renderer/TestData.json index 54360dab84..f075bd6ae0 100644 --- a/lib/Newsletter/Renderer/TestData.json +++ b/lib/Newsletter/Renderer/TestData.json @@ -1,5 +1,5 @@ { - "data": { + "content": { "type": "container", "orientation": "vertical", "styles": { @@ -7,1161 +7,1050 @@ "backgroundColor": "transparent" } }, - "blocks": [ - { - "orientation": "horizontal", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "orientation": "vertical", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "type": "header", - "text": "

Display problems? View it in your browser. If I add a lot of text to test what happens... Well, nothing really (exciting) happens. Things don't break.

", - "styles": { - "block": { - "backgroundColor": "#333333" - }, - "text": { - "fontColor": "#aaaaaa", - "fontFamily": "Arial", - "fontSize": "12px", - "textAlign": "center" - }, - "link": { - "fontColor": "#a86b6b", - "textDecoration": "underline" - } - } - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/600x250.jpg", - "alt": "600x250", - "padded": true, - "width": "600px", - "height": "250px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "type": "text", - "text": "

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" - }, - { - "type": "divider", - "styles": { - "block": { - "backgroundColor": "transparent", - "padding": "13px", - "borderStyle": "solid", - "borderWidth": "3px", - "borderColor": "#000000" - } - } - }, - { - "type": "spacer", - "styles": { - "block": { - "backgroundColor": "transparent", - "height": "50px" - } - } - }, - { - "type": "button", - "text": "Button", - "url": "http://example.org", - "styles": { - "block": { - "backgroundColor": "#666666", - "borderColor": "#1e3650", - "borderWidth": "1px", - "borderRadius": "20px", - "borderStyle": "solid", - "width": "100px", - "lineHeight": "30px", - "fontColor": "#ffffff", - "fontFamily": "Arial", - "fontSize": "13px", - "textAlign": "center" - } - } - }, - { - "type": "social", - "icons": [ - { - "type": "socialIcon", - "iconType": "custom", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", - "height": "32px", - "width": "32px", - "text": "Custom" - }, - { - "type": "socialIcon", - "iconType": "facebook", - "link": "http://www.facebook.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", - "height": "32px", - "width": "32px", - "text": "Facebook" - }, - { - "type": "socialIcon", - "iconType": "twitter", - "link": "http://www.twitter.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", - "height": "32px", - "width": "32px", - "text": "Twitter" - }, - { - "type": "socialIcon", - "iconType": "google-plus", - "link": "http://plus.google.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", - "height": "32px", - "width": "32px", - "text": "Google Plus" - }, - { - "type": "socialIcon", - "iconType": "youtube", - "link": "http://www.youtube.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", - "height": "32px", - "width": "32px", - "text": "Youtube" - }, - { - "type": "socialIcon", - "iconType": "website", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", - "height": "32px", - "width": "32px", - "text": "Website" - }, - { - "type": "socialIcon", - "iconType": "email", - "link": "mailto:mail@example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", - "height": "32px", - "width": "32px", - "text": "Email" - }, - { - "type": "socialIcon", - "iconType": "instagram", - "link": "http://instagram.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", - "height": "32px", - "width": "32px", - "text": "Instagram" - }, - { - "type": "socialIcon", - "iconType": "pinterest", - "link": "http://www.pinterest.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", - "height": "32px", - "width": "32px", - "text": "Pinterest" - }, - { - "type": "socialIcon", - "iconType": "linkedin", - "link": "http://www.linkedin.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", - "height": "32px", - "width": "32px", - "text": "LinkedIn" - } - ], - "iconSet": "default" - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/600x250.jpg", - "alt": "600x250", - "padded": false, - "width": "600px", - "height": "250px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "orientation": "horizontal", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "orientation": "vertical", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", - "alt": "300x125", - "padded": true, - "width": "300px", - "height": "125px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "type": "text", - "text": "

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" - }, - { - "type": "divider", - "styles": { - "block": { - "backgroundColor": "transparent", - "padding": "13px", - "borderStyle": "solid", - "borderWidth": "3px", - "borderColor": "#000000" - } - } - }, - { - "type": "spacer", - "styles": { - "block": { - "backgroundColor": "transparent", - "height": "50px" - } - } - }, - { - "type": "button", - "text": "Button", - "url": "http://example.org", - "styles": { - "block": { - "backgroundColor": "#666666", - "borderColor": "#1e3650", - "borderWidth": "1px", - "borderRadius": "20px", - "borderStyle": "solid", - "width": "100px", - "lineHeight": "30px", - "fontColor": "#ffffff", - "fontFamily": "Arial", - "fontSize": "13px", - "textAlign": "center" - } - } - }, - { - "type": "social", - "icons": [ - { - "type": "socialIcon", - "iconType": "custom", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", - "height": "32px", - "width": "32px", - "text": "Custom" - }, - { - "type": "socialIcon", - "iconType": "facebook", - "link": "http://www.facebook.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", - "height": "32px", - "width": "32px", - "text": "Facebook" - }, - { - "type": "socialIcon", - "iconType": "twitter", - "link": "http://www.twitter.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", - "height": "32px", - "width": "32px", - "text": "Twitter" - }, - { - "type": "socialIcon", - "iconType": "google-plus", - "link": "http://plus.google.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", - "height": "32px", - "width": "32px", - "text": "Google Plus" - }, - { - "type": "socialIcon", - "iconType": "youtube", - "link": "http://www.youtube.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", - "height": "32px", - "width": "32px", - "text": "Youtube" - }, - { - "type": "socialIcon", - "iconType": "website", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", - "height": "32px", - "width": "32px", - "text": "Website" - }, - { - "type": "socialIcon", - "iconType": "email", - "link": "mailto:mail@example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", - "height": "32px", - "width": "32px", - "text": "Email" - }, - { - "type": "socialIcon", - "iconType": "instagram", - "link": "http://instagram.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", - "height": "32px", - "width": "32px", - "text": "Instagram" - }, - { - "type": "socialIcon", - "iconType": "pinterest", - "link": "http://www.pinterest.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", - "height": "32px", - "width": "32px", - "text": "Pinterest" - }, - { - "type": "socialIcon", - "iconType": "linkedin", - "link": "http://www.linkedin.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", - "height": "32px", - "width": "32px", - "text": "LinkedIn" - } - ], - "iconSet": "default" - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", - "alt": "300x125", - "padded": false, - "width": "300px", - "height": "125px", - "styles": { - "block": { - "textAlign": "center" - } - } - } - ] - }, - { - "orientation": "vertical", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", - "alt": "300x125", - "padded": true, - "width": "300px", - "height": "125px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "type": "text", - "text": "

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" - }, - { - "type": "divider", - "styles": { - "block": { - "backgroundColor": "transparent", - "padding": "13px", - "borderStyle": "solid", - "borderWidth": "3px", - "borderColor": "#000000" - } - } - }, - { - "type": "spacer", - "styles": { - "block": { - "backgroundColor": "transparent", - "height": "50px" - } - } - }, - { - "type": "button", - "text": "Button", - "url": "http://example.org", - "styles": { - "block": { - "backgroundColor": "#666666", - "borderColor": "#1e3650", - "borderWidth": "1px", - "borderRadius": "20px", - "borderStyle": "solid", - "width": "100px", - "lineHeight": "30px", - "fontColor": "#ffffff", - "fontFamily": "Arial", - "fontSize": "13px", - "textAlign": "center" - } - } - }, - { - "type": "social", - "icons": [ - { - "type": "socialIcon", - "iconType": "custom", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", - "height": "32px", - "width": "32px", - "text": "Custom" - }, - { - "type": "socialIcon", - "iconType": "facebook", - "link": "http://www.facebook.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", - "height": "32px", - "width": "32px", - "text": "Facebook" - }, - { - "type": "socialIcon", - "iconType": "twitter", - "link": "http://www.twitter.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", - "height": "32px", - "width": "32px", - "text": "Twitter" - }, - { - "type": "socialIcon", - "iconType": "google-plus", - "link": "http://plus.google.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", - "height": "32px", - "width": "32px", - "text": "Google Plus" - }, - { - "type": "socialIcon", - "iconType": "youtube", - "link": "http://www.youtube.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", - "height": "32px", - "width": "32px", - "text": "Youtube" - }, - { - "type": "socialIcon", - "iconType": "website", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", - "height": "32px", - "width": "32px", - "text": "Website" - }, - { - "type": "socialIcon", - "iconType": "email", - "link": "mailto:mail@example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", - "height": "32px", - "width": "32px", - "text": "Email" - }, - { - "type": "socialIcon", - "iconType": "instagram", - "link": "http://instagram.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", - "height": "32px", - "width": "32px", - "text": "Instagram" - }, - { - "type": "socialIcon", - "iconType": "pinterest", - "link": "http://www.pinterest.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", - "height": "32px", - "width": "32px", - "text": "Pinterest" - }, - { - "type": "socialIcon", - "iconType": "linkedin", - "link": "http://www.linkedin.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", - "height": "32px", - "width": "32px", - "text": "LinkedIn" - } - ], - "iconSet": "default" - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/300x125.jpg", - "alt": "300x125", - "padded": false, - "width": "300px", - "height": "125px", - "styles": { - "block": { - "textAlign": "center" - } - } - } - ] - } - ] - } - ] - } - ] - }, - { - "orientation": "horizontal", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "orientation": "vertical", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", - "alt": "200x83", - "padded": true, - "width": "200px", - "height": "83px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "type": "text", - "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" - }, - { - "type": "divider", - "styles": { - "block": { - "backgroundColor": "transparent", - "padding": "13px", - "borderStyle": "solid", - "borderWidth": "3px", - "borderColor": "#000000" - } - } - }, - { - "type": "spacer", - "styles": { - "block": { - "backgroundColor": "transparent", - "height": "50px" - } - } - }, - { - "type": "button", - "text": "Button", - "url": "http://example.org", - "styles": { - "block": { - "backgroundColor": "#666666", - "borderColor": "#1e3650", - "borderWidth": "1px", - "borderRadius": "20px", - "borderStyle": "solid", - "width": "100px", - "lineHeight": "30px", - "fontColor": "#ffffff", - "fontFamily": "Arial", - "fontSize": "13px", - "textAlign": "center" - } - } - }, - { - "type": "social", - "icons": [ - { - "type": "socialIcon", - "iconType": "custom", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", - "height": "32px", - "width": "32px", - "text": "Custom" - }, - { - "type": "socialIcon", - "iconType": "facebook", - "link": "http://www.facebook.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", - "height": "32px", - "width": "32px", - "text": "Facebook" - }, - { - "type": "socialIcon", - "iconType": "twitter", - "link": "http://www.twitter.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", - "height": "32px", - "width": "32px", - "text": "Twitter" - }, - { - "type": "socialIcon", - "iconType": "google-plus", - "link": "http://plus.google.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", - "height": "32px", - "width": "32px", - "text": "Google Plus" - }, - { - "type": "socialIcon", - "iconType": "youtube", - "link": "http://www.youtube.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", - "height": "32px", - "width": "32px", - "text": "Youtube" - }, - { - "type": "socialIcon", - "iconType": "website", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", - "height": "32px", - "width": "32px", - "text": "Website" - }, - { - "type": "socialIcon", - "iconType": "email", - "link": "mailto:mail@example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", - "height": "32px", - "width": "32px", - "text": "Email" - }, - { - "type": "socialIcon", - "iconType": "instagram", - "link": "http://instagram.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", - "height": "32px", - "width": "32px", - "text": "Instagram" - }, - { - "type": "socialIcon", - "iconType": "pinterest", - "link": "http://www.pinterest.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", - "height": "32px", - "width": "32px", - "text": "Pinterest" - }, - { - "type": "socialIcon", - "iconType": "linkedin", - "link": "http://www.linkedin.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", - "height": "32px", - "width": "32px", - "text": "LinkedIn" - } - ], - "iconSet": "default" - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", - "alt": "200x83", - "padded": false, - "width": "200px", - "height": "83px", - "styles": { - "block": { - "textAlign": "center" - } - } - } - ] - }, - { - "orientation": "vertical", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", - "alt": "200x83", - "padded": true, - "width": "200px", - "height": "83px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "type": "text", - "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" - }, - { - "type": "divider", - "styles": { - "block": { - "backgroundColor": "transparent", - "padding": "13px", - "borderStyle": "solid", - "borderWidth": "3px", - "borderColor": "#000000" - } - } - }, - { - "type": "spacer", - "styles": { - "block": { - "backgroundColor": "transparent", - "height": "50px" - } - } - }, - { - "type": "button", - "text": "Button", - "url": "http://example.org", - "styles": { - "block": { - "backgroundColor": "#666666", - "borderColor": "#1e3650", - "borderWidth": "1px", - "borderRadius": "20px", - "borderStyle": "solid", - "width": "100px", - "lineHeight": "30px", - "fontColor": "#ffffff", - "fontFamily": "Arial", - "fontSize": "13px", - "textAlign": "center" - } - } - }, - { - "type": "social", - "icons": [ - { - "type": "socialIcon", - "iconType": "custom", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", - "height": "32px", - "width": "32px", - "text": "Custom" - }, - { - "type": "socialIcon", - "iconType": "facebook", - "link": "http://www.facebook.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", - "height": "32px", - "width": "32px", - "text": "Facebook" - }, - { - "type": "socialIcon", - "iconType": "twitter", - "link": "http://www.twitter.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", - "height": "32px", - "width": "32px", - "text": "Twitter" - }, - { - "type": "socialIcon", - "iconType": "google-plus", - "link": "http://plus.google.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", - "height": "32px", - "width": "32px", - "text": "Google Plus" - }, - { - "type": "socialIcon", - "iconType": "youtube", - "link": "http://www.youtube.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", - "height": "32px", - "width": "32px", - "text": "Youtube" - }, - { - "type": "socialIcon", - "iconType": "website", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", - "height": "32px", - "width": "32px", - "text": "Website" - }, - { - "type": "socialIcon", - "iconType": "email", - "link": "mailto:mail@example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", - "height": "32px", - "width": "32px", - "text": "Email" - }, - { - "type": "socialIcon", - "iconType": "instagram", - "link": "http://instagram.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", - "height": "32px", - "width": "32px", - "text": "Instagram" - }, - { - "type": "socialIcon", - "iconType": "pinterest", - "link": "http://www.pinterest.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", - "height": "32px", - "width": "32px", - "text": "Pinterest" - }, - { - "type": "socialIcon", - "iconType": "linkedin", - "link": "http://www.linkedin.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", - "height": "32px", - "width": "32px", - "text": "LinkedIn" - } - ], - "iconSet": "default" - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", - "alt": "200x83", - "padded": false, - "width": "200px", - "height": "83px", - "styles": { - "block": { - "textAlign": "center" - } - } - } - ] - }, - { - "orientation": "vertical", - "type": "container", - "styles": { - "block": { - "backgroundColor": "transparent" - } - }, - "blocks": [ - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", - "alt": "200x83", - "padded": true, - "width": "200px", - "height": "83px", - "styles": { - "block": { - "textAlign": "center" - } - } - }, - { - "type": "text", - "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" - }, - { - "type": "divider", - "styles": { - "block": { - "backgroundColor": "transparent", - "padding": "13px", - "borderStyle": "solid", - "borderWidth": "3px", - "borderColor": "#000000" - } - } - }, - { - "type": "spacer", - "styles": { - "block": { - "backgroundColor": "transparent", - "height": "50px" - } - } - }, - { - "type": "button", - "text": "Button", - "url": "http://example.org", - "styles": { - "block": { - "backgroundColor": "#666666", - "borderColor": "#1e3650", - "borderWidth": "1px", - "borderRadius": "20px", - "borderStyle": "solid", - "width": "100px", - "lineHeight": "30px", - "fontColor": "#ffffff", - "fontFamily": "Arial", - "fontSize": "13px", - "textAlign": "center" - } - } - }, - { - "type": "social", - "icons": [ - { - "type": "socialIcon", - "iconType": "custom", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/custom.png", - "height": "32px", - "width": "32px", - "text": "Custom" - }, - { - "type": "socialIcon", - "iconType": "facebook", - "link": "http://www.facebook.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Facebook.png", - "height": "32px", - "width": "32px", - "text": "Facebook" - }, - { - "type": "socialIcon", - "iconType": "twitter", - "link": "http://www.twitter.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Twitter.png", - "height": "32px", - "width": "32px", - "text": "Twitter" - }, - { - "type": "socialIcon", - "iconType": "google-plus", - "link": "http://plus.google.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Google-Plus.png", - "height": "32px", - "width": "32px", - "text": "Google Plus" - }, - { - "type": "socialIcon", - "iconType": "youtube", - "link": "http://www.youtube.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Youtube.png", - "height": "32px", - "width": "32px", - "text": "Youtube" - }, - { - "type": "socialIcon", - "iconType": "website", - "link": "http://example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Website.png", - "height": "32px", - "width": "32px", - "text": "Website" - }, - { - "type": "socialIcon", - "iconType": "email", - "link": "mailto:mail@example.org", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Email.png", - "height": "32px", - "width": "32px", - "text": "Email" - }, - { - "type": "socialIcon", - "iconType": "instagram", - "link": "http://instagram.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Instagram.png", - "height": "32px", - "width": "32px", - "text": "Instagram" - }, - { - "type": "socialIcon", - "iconType": "pinterest", - "link": "http://www.pinterest.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/Pinterest.png", - "height": "32px", - "width": "32px", - "text": "Pinterest" - }, - { - "type": "socialIcon", - "iconType": "linkedin", - "link": "http://www.linkedin.com", - "image": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/social-icons/01-social/LinkedIn.png", - "height": "32px", - "width": "32px", - "text": "LinkedIn" - } - ], - "iconSet": "default" - }, - { - "type": "image", - "link": "http://example.org", - "src": "http://127.0.0.1/wp-content/plugins/mailpoet/assets/img/newsletter_editor/200x83.jpg", - "alt": "200x83", - "padded": false, - "width": "200px", - "height": "83px", - "styles": { - "block": { - "textAlign": "center" - } - } - } - ] - } - ] - }, - { - "type": "footer", - "text": "

You are receiving this email because you opted in on our website. Update your email preferences or unsubscribe

\n

123 Maple Avenue
93102
Oakland, California

", - "styles": { - "block": { - "backgroundColor": "#333333" - }, - "text": { - "fontColor": "#aaaaaa", - "fontFamily": "Arial", - "fontSize": "12px", - "textAlign": "center" - }, - "link": { - "fontColor": "#a86b6b", - "textDecoration": "underline" - } + "blocks": [{ + "type": "container", + "orientation": "horizontal", + "styles": { + "block": { + "backgroundColor": "transparent" } - } - ] + }, + "blocks": [{ + "type": "container", + "orientation": "vertical", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "header", + "text": "

Display problems? View it in your browser. If I add a lot of text to test what happens... Well, nothing really (exciting) happens. Things don't break.

", + "styles": { + "block": { + "backgroundColor": "#333333" + }, + "text": { + "fontColor": "#aaaaaa", + "fontFamily": "Arial", + "fontSize": "12px", + "textAlign": "center" + }, + "link": { + "fontColor": "#a86b6b", + "textDecoration": "underline" + } + } + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/600x250.jpg", + "alt": "600x250", + "padded": true, + "width": "600px", + "height": "250px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, { + "type": "text", + "text": "

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

1/1 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, { + "type": "social", + "icons": [{ + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + }], + "iconSet": "default" + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/600x250.jpg", + "alt": "600x250", + "padded": false, + "width": "600px", + "height": "250px", + "styles": { + "block": { + "textAlign": "center" + } + } + }] + }] + }, { + "orientation": "horizontal", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/300x125.jpg", + "alt": "300x125", + "padded": true, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, { + "type": "text", + "text": "

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, { + "type": "social", + "icons": [{ + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + }], + "iconSet": "default" + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/300x125.jpg", + "alt": "300x125", + "padded": false, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + }] + }, { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/300x125.jpg", + "alt": "300x125", + "padded": true, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, { + "type": "text", + "text": "

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

1/2 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, { + "type": "social", + "icons": [{ + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + }], + "iconSet": "default" + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/300x125.jpg", + "alt": "300x125", + "padded": false, + "width": "300px", + "height": "125px", + "styles": { + "block": { + "textAlign": "center" + } + } + }] + }] + }, { + "orientation": "horizontal", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/200x83.jpg", + "alt": "200x83", + "padded": true, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, { + "type": "text", + "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, { + "type": "social", + "icons": [{ + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + }], + "iconSet": "default" + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/200x83.jpg", + "alt": "200x83", + "padded": false, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }] + }, { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/200x83.jpg", + "alt": "200x83", + "padded": true, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, { + "type": "text", + "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, { + "type": "social", + "icons": [{ + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + }], + "iconSet": "default" + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/200x83.jpg", + "alt": "200x83", + "padded": false, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }] + }, { + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/200x83.jpg", + "alt": "200x83", + "padded": true, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }, { + "type": "text", + "text": "

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

1/3 Column

\n

Heading (size 2)

\n

Paragraph under heading to test line-height.

\n

Heading (size 3)

\n

Heading (size 3) with link

\n

Heading (size 3)

\n

Paragraph under heading to test line-height.

\n

Bacon ipsum dolor amet short ribs shank cow, ribeye corned beef short loin t-bone kielbasa meatloaf ball tip rump venison boudin brisket beef ribs. Fatback landjaeger frankfurter, meatloaf picanha andouille leberkas. Tail beef ribs boudin salami, kevin cupim landjaeger pork loin tenderloin ham filet mignon drumstick short loin. Biltong frankfurter shank pork belly picanha prosciutto meatloaf tail hamburger landjaeger pancetta shankle pig. Pig tri-tip tenderloin ground round ribeye alcatra turkey salami turducken sausage pork loin kielbasa hamburger meatloaf strip steak. Ribeye boudin cow, beef ribs t-bone pig short ribs tri-tip pork loin rump shank hamburger short loin. Salami pastrami meatball shoulder cupim.

\n

Bacon kevin shank ball tip shoulder. Jowl leberkas fatback, short loin chuck beef beef ribs short ribs ribeye turducken pork chop brisket filet mignon cow. Turkey ball tip rump bacon filet mignon sausage jowl shoulder chicken ground round kielbasa shankle. Drumstick pancetta corned beef kielbasa porchetta jerky swine leberkas kevin boudin chicken shoulder bacon tri-tip venison. Ham hock ball tip beef ribs spare ribs tail pork ground round, biltong doner t-bone pork chop rump hamburger pancetta brisket.

\n

Brisket beef kielbasa jowl hamburger, doner flank. Shoulder ham hock sausage t-bone pork belly chicken picanha pork loin ham bresaola tri-tip ground round kevin. Chicken sirloin shankle fatback boudin t-bone pig tri-tip bresaola doner cow short loin pancetta short ribs andouille. Cupim doner short ribs, andouille cow t-bone ground round pork porchetta beef capicola. Rump drumstick biltong shank kielbasa bacon ball tip pancetta meatloaf shankle fatback.

\n

Kielbasa jowl flank biltong. Pork loin fatback chicken ham prosciutto sausage cow short loin porchetta kielbasa. Bresaola ham hock pancetta, cow ham tenderloin flank turducken fatback beef jowl short loin pig. Picanha turkey spare ribs capicola andouille, tongue short loin sausage corned beef kevin meatball venison kielbasa pastrami. Beef ribs ground round tenderloin flank.

\n

Alcatra flank ground round corned beef tenderloin prosciutto chicken sirloin, venison leberkas turducken shoulder pastrami bresaola. Chicken leberkas t-bone pork loin drumstick flank. T-bone flank venison alcatra andouille brisket short ribs shankle biltong pancetta pork belly bacon. Tri-tip biltong ham hock jowl chicken. Spare ribs beef ribs shankle corned beef short loin picanha prosciutto bacon ham rump tri-tip doner ground round cupim. Meatloaf andouille bresaola strip steak kevin, pork turducken.

\n

Jowl strip steak pork belly jerky short ribs filet mignon. Kielbasa ham shoulder turducken sausage jerky beef ham

\n

Alcatra hamburger jowl shank jerky. 

\n
    \n
  • One
  • \n
  • Two
  • \n
  • Three
  • \n
\n
    \n
  1. One
  2. \n
  3. Two
  4. \n
  5. Three
  6. \n
\n

Bacon ipsum dolor amet shoulder turkey meatball pork chop porchetta, filet mignon shankle. Sausage meatloaf flank picanha jowl chuck capicola tri-tip. Meatloaf andouille kielbasa beef ribs. 

\n

— Mr. Bacon

" + }, { + "type": "divider", + "styles": { + "block": { + "backgroundColor": "transparent", + "padding": "13px", + "borderStyle": "solid", + "borderWidth": "3px", + "borderColor": "#000000" + } + } + }, { + "type": "spacer", + "styles": { + "block": { + "backgroundColor": "transparent", + "height": "50px" + } + } + }, { + "type": "button", + "text": "Button", + "url": "http://example.org", + "styles": { + "block": { + "backgroundColor": "#666666", + "borderColor": "#1e3650", + "borderWidth": "1px", + "borderRadius": "20px", + "borderStyle": "solid", + "width": "100px", + "lineHeight": "30px", + "fontColor": "#ffffff", + "fontFamily": "Arial", + "fontSize": "13px", + "textAlign": "center" + } + } + }, { + "type": "social", + "icons": [{ + "type": "socialIcon", + "iconType": "custom", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/custom.png", + "height": "32px", + "width": "32px", + "text": "Custom" + }, { + "type": "socialIcon", + "iconType": "facebook", + "link": "http://www.facebook.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Facebook.png", + "height": "32px", + "width": "32px", + "text": "Facebook" + }, { + "type": "socialIcon", + "iconType": "twitter", + "link": "http://www.twitter.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Twitter.png", + "height": "32px", + "width": "32px", + "text": "Twitter" + }, { + "type": "socialIcon", + "iconType": "google-plus", + "link": "http://plus.google.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Google-Plus.png", + "height": "32px", + "width": "32px", + "text": "Google Plus" + }, { + "type": "socialIcon", + "iconType": "youtube", + "link": "http://www.youtube.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Youtube.png", + "height": "32px", + "width": "32px", + "text": "Youtube" + }, { + "type": "socialIcon", + "iconType": "website", + "link": "http://example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Website.png", + "height": "32px", + "width": "32px", + "text": "Website" + }, { + "type": "socialIcon", + "iconType": "email", + "link": "mailto:mail@example.org", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Email.png", + "height": "32px", + "width": "32px", + "text": "Email" + }, { + "type": "socialIcon", + "iconType": "instagram", + "link": "http://instagram.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Instagram.png", + "height": "32px", + "width": "32px", + "text": "Instagram" + }, { + "type": "socialIcon", + "iconType": "pinterest", + "link": "http://www.pinterest.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/Pinterest.png", + "height": "32px", + "width": "32px", + "text": "Pinterest" + }, { + "type": "socialIcon", + "iconType": "linkedin", + "link": "http://www.linkedin.com", + "image": "http://mp3.mailpoet.net/various/social-icons/01-social/LinkedIn.png", + "height": "32px", + "width": "32px", + "text": "LinkedIn" + }], + "iconSet": "default" + }, { + "type": "image", + "link": "http://example.org", + "src": "http://mp3.mailpoet.net/various/200x83.jpg", + "alt": "200x83", + "padded": false, + "width": "200px", + "height": "83px", + "styles": { + "block": { + "textAlign": "center" + } + } + }] + }] + }, { + "orientation": "horizontal", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "orientation": "vertical", + "type": "container", + "styles": { + "block": { + "backgroundColor": "transparent" + } + }, + "blocks": [{ + "type": "footer", + "text": "

You are receiving this email because you opted in on our website. Update your email preferences or unsubscribe

\n

123 Maple Avenue
93102
Oakland, California

", + "styles": { + "block": { + "backgroundColor": "#333333" + }, + "text": { + "fontColor": "#aaaaaa", + "fontFamily": "Arial", + "fontSize": "12px", + "textAlign": "center" + }, + "link": { + "fontColor": "#a86b6b", + "textDecoration": "underline" + } + } + }] + }] + }] }, - "styles": { + "globalStyles": { "text": { "fontColor": "#565656", "fontFamily": "Arial", @@ -1186,11 +1075,14 @@ "fontColor": "#a86b6b", "textDecoration": "underline" }, - "newsletter": { + "wrapper": { "backgroundColor": "#999999" }, - "background": { + "body": { "backgroundColor": "#333333" } - } -} + }, + "subject": "Click to change the subject!", + "preheader": "", + "id": 3 +} \ No newline at end of file From a2494cfa1b4dc84e94b71c601000c6ab4e437b18 Mon Sep 17 00:00:00 2001 From: MrCasual Date: Wed, 23 Sep 2015 22:42:11 -0400 Subject: [PATCH 8/8] - Adds tests for newsletter renderer --- lib/Newsletter/Renderer/StylesHelper.php | 10 +- tests/unit/Newsletter/RendererCest.php | 130 ++++++++++++++++++ .../unit/Newsletter/RendererTestData.json | 0 3 files changed, 136 insertions(+), 4 deletions(-) create mode 100644 tests/unit/Newsletter/RendererCest.php rename lib/Newsletter/Renderer/TestData.json => tests/unit/Newsletter/RendererTestData.json (100%) diff --git a/lib/Newsletter/Renderer/StylesHelper.php b/lib/Newsletter/Renderer/StylesHelper.php index 1898cdc492..5ebc31febc 100644 --- a/lib/Newsletter/Renderer/StylesHelper.php +++ b/lib/Newsletter/Renderer/StylesHelper.php @@ -15,17 +15,19 @@ class StylesHelper { 'lineHeight' => 'line-height' ); - function getBlockStyles($element) { + function getBlockStyles($element, $ignoreSpecificStyles = false) { if(!isset($element['styles']['block'])) { return; } - return $this->getStyles($element['styles'], 'block'); + return $this->getStyles($element['styles'], 'block', $ignoreSpecificStyles); } - function getStyles($data, $type) { - $styles = array_map(function ($attribute, $style) { + function getStyles($data, $type, $ignoreSpecificStyles = false) { + $styles = array_map(function ($attribute, $style) use($ignoreSpecificStyles) { + if(!$ignoreSpecificStyles || !in_array($attribute, $ignoreSpecificStyles)) { return $this->translateCSSAttribute($attribute) . ': ' . $style . ' !important;'; + } }, array_keys($data[$type]), $data[$type]); return implode('', $styles); diff --git a/tests/unit/Newsletter/RendererCest.php b/tests/unit/Newsletter/RendererCest.php new file mode 100644 index 0000000000..16930b5fac --- /dev/null +++ b/tests/unit/Newsletter/RendererCest.php @@ -0,0 +1,130 @@ +newsletterData = json_decode(file_get_contents(dirname(__FILE__) . '/RendererTestData.json'), true); + $this->renderer = new Renderer($this->newsletterData); + $this->columnRenderer = new ColumnRenderer(); + $this->queryDOM = new \pQuery(); + } + + function itRendersCompleteNewsletter() { + $template = $this->renderer->renderAll(); + $DOM = $this->queryDOM->parseStr($template); + + // we expect to have 4 column containers and 7 columns (1x1, 1x2, 1x3, 1x1) + expect(count($DOM('.mailpoet_cols-wrapper')))->equals(4); + expect(count($DOM('.mailpoet_force-row')))->equals(7); + } + + function itRendersColumns() { + $columnContent = array( + 'one', + 'two', + 'three' + ); + $DOM = $this->queryDOM->parseStr($this->columnRenderer->render(count($columnContent), $columnContent)); + + // rendered object should cocntain three columns + foreach ($DOM('.mailpoet_force-row > tbody') as $column) { + $renderedColumnContent[] = trim($column->text()); + }; + expect(count(array_diff($renderedColumnContent, $columnContent)))->equals(0); + } + + function itRendersHeader() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][0]; + $DOM = $this->queryDOM->parseStr(Header::render($template)); + + // element should be proplerly nested, and styles should be applied to , and

elements + expect(is_object($DOM('tr > td > p', 0)))->true(); + expect(is_object($DOM('tr > td > p > a', 0)))->true(); + expect($DOM('a', 0)->attr('style'))->notEmpty(); + expect($DOM('p', 0)->attr('style'))->notEmpty(); + } + + function itRendersImage() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][1]; + $DOM = $this->queryDOM->parseStr(Image::render($template)); + + // element should be properly nested, it's width set and style applied to + expect(is_object($DOM('tr > td > img', 0)))->true(); + expect($DOM('tr > td > img', 0)->attr('width'))->equals(560); + expect($DOM('tr > td', 0)->attr('style'))->notEmpty(); + } + + function itRendersText() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][2]; + $DOM = $this->queryDOM->parseStr(Text::render($template)); + + // blockquotes and paragraphs should be converted to spans and placed inside a table + expect(is_object($DOM('tr > td.mailpoet_text > table > tr > td > span.paragraph', 0)))->true(); + expect(is_object($DOM('tr > td.mailpoet_text > table.mailpoet_blockquote > tbody > tr > td > table > tr > td > span.paragraph', 0)))->true(); + } + + function itRendersDivider() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][3]; + $DOM = $this->queryDOM->parseStr(Divider::render($template)); + + // element should be properly nested and its border-top-width set + expect(is_object($DOM('tr > td.mailpoet_divider > table > tr > td', 0)))->true(); + expect(preg_match('/border-top-width: 3px/', $DOM('tr > td.mailpoet_divider > table > tr > td', 0)->attr('style')))->equals(1); + } + + function itRendersSpacer() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][4]; + $DOM = $this->queryDOM->parseStr(Spacer::render($template)); + + // element should be properly nested and its height set + expect(is_object($DOM('tr > td.mailpoet_spacer', 0)))->true(); + expect(preg_match('/height: 50px/', $DOM('tr > td.mailpoet_spacer', 0)->attr('style')))->equals(1); + } + + function itRendersButton() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][5]; + $DOM = $this->queryDOM->parseStr(Button::render($template)); + + // element should be properly nested with arcsize/styles/fillcolor set + expect(is_object($DOM('tr > td.mailpoet_button > div > table > tr > td > a.mailpoet_button', 0)))->true(); + expect(preg_match('/line-height: 30px/', $DOM('a.mailpoet_button', 0)->attr('style')))->equals(1); + expect(preg_match('/arcsize="' . round(20 / 30 * 100) . '%"/', $DOM('tr > td.mailpoet_button > div > table > tr > td', 0)->text()))->equals(1); + expect(preg_match('/style="height:30px.*?width:100px/', $DOM('tr > td.mailpoet_button > div > table > tr > td', 0)->text()))->equals(1); + expect(preg_match('/style="color:#ffffff.*?font-family:Arial.*?font-size:13px/', $DOM('tr > td.mailpoet_button > div > table > tr > td', 0)->text()))->equals(1); + expect(preg_match('/fillcolor="#666666/', $DOM('tr > td.mailpoet_button > div > table > tr > td', 0)->text()))->equals(1); + } + + function itRendersSocialIcons() { + $template = $this->newsletterData['content']['blocks'][0]['blocks'][0]['blocks'][6]; + $DOM = $this->queryDOM->parseStr(Social::render($template)); + + // element should be properly nested, contain social icons and image source/link href/alt should be properly set + expect(is_object($DOM('tr > td.mailpoet_social > div', 0)))->true(); + expect(count($DOM('a > img')))->equals(10); + expect($DOM('a', 0)->attr('href'))->equals('http://example.org'); + expect($DOM('a > img', 0)->attr('src'))->equals('http://mp3.mailpoet.net/various/social-icons/custom.png'); + expect($DOM('a > img', 0)->attr('alt'))->equals('custom'); + } + + function itRendersFooter() { + $template = $this->newsletterData['content']['blocks'][3]['blocks'][0]['blocks'][0]; + $DOM = $this->queryDOM->parseStr(Footer::render($template)); + + // element should be proplerly nested, and styles should be applied to , and

elements + expect(is_object($DOM('tr > td.mailpoet_footer > div', 0)))->true(); + expect(is_object($DOM('tr > td.mailpoet_footer > div > a > p', 0)))->true(); + expect($DOM('tr > td.mailpoet_footer', 0)->attr('style'))->notEmpty(); + expect($DOM('a', 0)->attr('style'))->notEmpty(); + expect($DOM('p', 0)->attr('style'))->notEmpty(); + } +} diff --git a/lib/Newsletter/Renderer/TestData.json b/tests/unit/Newsletter/RendererTestData.json similarity index 100% rename from lib/Newsletter/Renderer/TestData.json rename to tests/unit/Newsletter/RendererTestData.json