| 1 |
<?php |
| 2 |
|
| 3 |
namespace YayMail\TemplateLibrary\Templates\Processing; |
| 4 |
|
| 5 |
use YayMail\Abstracts\BaseTemplate; |
| 6 |
use YayMail\Elements\BillingAddress; |
| 7 |
use YayMail\Elements\Button; |
| 8 |
use YayMail\Elements\Column; |
| 9 |
use YayMail\Elements\ColumnLayout; |
| 10 |
use YayMail\Elements\Heading; |
| 11 |
use YayMail\Elements\Image; |
| 12 |
use YayMail\Elements\Logo; |
| 13 |
use YayMail\Elements\OrderDetails; |
| 14 |
use YayMail\Elements\ShippingAddress; |
| 15 |
use YayMail\Elements\SocialIcon; |
| 16 |
use YayMail\Elements\Text; |
| 17 |
use YayMail\Utils\SingletonTrait; |
| 18 |
|
| 19 |
/** |
| 20 |
* Bold Thanks template for Processing Order email. |
| 21 |
*/ |
| 22 |
class BoldThanks extends BaseTemplate { |
| 23 |
use SingletonTrait; |
| 24 |
|
| 25 |
public function __construct() { |
| 26 |
parent::__construct(); |
| 27 |
$this->id = 'processing_order_v5'; |
| 28 |
$this->email_type = 'customer_processing_order'; |
| 29 |
$this->name = 'Bold Thanks'; |
| 30 |
$this->description = 'Large, attention-grabbing thank-you hero.'; |
| 31 |
$this->categories = [ 'Purple Collection' ]; |
| 32 |
$this->template_settings = [ |
| 33 |
'text_link_color' => '#5D19E0', |
| 34 |
]; |
| 35 |
$this->access = 'free'; |
| 36 |
$this->elements = [ |
| 37 |
ColumnLayout::get_object_data( |
| 38 |
4, |
| 39 |
[ |
| 40 |
'children' => [ |
| 41 |
Column::get_object_data( |
| 42 |
29, |
| 43 |
[ |
| 44 |
'children' => [ |
| 45 |
Logo::get_object_data( |
| 46 |
[ |
| 47 |
'padding' => [ |
| 48 |
'top' => '10', |
| 49 |
'right' => '10', |
| 50 |
'bottom' => '10', |
| 51 |
'left' => '0', |
| 52 |
], |
| 53 |
'background_color' => '#5D19E000', |
| 54 |
'src' => 'https://images.wpbrandy.com/uploads/woo-white-logo.png', |
| 55 |
'align' => 'left', |
| 56 |
'width' => '117', |
| 57 |
'alt' => 'Store logo', |
| 58 |
] |
| 59 |
), |
| 60 |
], |
| 61 |
] |
| 62 |
), |
| 63 |
Column::get_object_data( |
| 64 |
34.49, |
| 65 |
[ |
| 66 |
'children' => [ |
| 67 |
Text::get_object_data( |
| 68 |
[ |
| 69 |
'padding' => [ |
| 70 |
'top' => '15', |
| 71 |
'right' => '0', |
| 72 |
'bottom' => '15', |
| 73 |
'left' => '0', |
| 74 |
], |
| 75 |
'background_color' => '#723af5', |
| 76 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 77 |
'text_color' => '#EFEDF3', |
| 78 |
'rich_text' => '<p style="text-align: right"><span style="font-size: 14px;font-weight: 400">My Account</span></p>', |
| 79 |
] |
| 80 |
), |
| 81 |
], |
| 82 |
] |
| 83 |
), |
| 84 |
Column::get_object_data( |
| 85 |
27.76, |
| 86 |
[ |
| 87 |
'children' => [ |
| 88 |
Text::get_object_data( |
| 89 |
[ |
| 90 |
'padding' => [ |
| 91 |
'top' => '15', |
| 92 |
'right' => '0', |
| 93 |
'bottom' => '15', |
| 94 |
'left' => '0', |
| 95 |
], |
| 96 |
'background_color' => '#723af5', |
| 97 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 98 |
'text_color' => '#EFEDF3', |
| 99 |
'rich_text' => '<p style="text-align: center"><span style="font-size: 14px;font-weight: 400">Order Tracking</span></p>', |
| 100 |
] |
| 101 |
), |
| 102 |
], |
| 103 |
] |
| 104 |
), |
| 105 |
Column::get_object_data( |
| 106 |
8.75, |
| 107 |
[ |
| 108 |
'children' => [ |
| 109 |
Text::get_object_data( |
| 110 |
[ |
| 111 |
'padding' => [ |
| 112 |
'top' => '15', |
| 113 |
'right' => '2', |
| 114 |
'bottom' => '15', |
| 115 |
'left' => '0', |
| 116 |
], |
| 117 |
'background_color' => '#5D19E000', |
| 118 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 119 |
'text_color' => '#EFEDF3', |
| 120 |
'rich_text' => '<p style="text-align: right"><span style="font-size: 14px;font-weight: 400">Contact</span></p>', |
| 121 |
] |
| 122 |
), |
| 123 |
], |
| 124 |
] |
| 125 |
), |
| 126 |
], |
| 127 |
'padding' => [ |
| 128 |
'top' => '15', |
| 129 |
'right' => '50', |
| 130 |
'bottom' => '15', |
| 131 |
'left' => '50', |
| 132 |
], |
| 133 |
'background_color' => '#723af5', |
| 134 |
] |
| 135 |
), |
| 136 |
ColumnLayout::get_object_data( |
| 137 |
1, |
| 138 |
[ |
| 139 |
'children' => [ |
| 140 |
Column::get_object_data( |
| 141 |
100, |
| 142 |
[ |
| 143 |
'children' => [ |
| 144 |
ColumnLayout::get_object_data( |
| 145 |
2, |
| 146 |
[ |
| 147 |
'children' => [ |
| 148 |
Column::get_object_data( |
| 149 |
58, |
| 150 |
[ |
| 151 |
'children' => [ |
| 152 |
Text::get_object_data( |
| 153 |
[ |
| 154 |
'padding' => [ |
| 155 |
'top' => 15, |
| 156 |
'right' => '10', |
| 157 |
'bottom' => 0, |
| 158 |
'left' => '0', |
| 159 |
], |
| 160 |
'background_color' => '#C6F6D500', |
| 161 |
'font_family' => 'Arial, Helvetica, sans-serif', |
| 162 |
'text_color' => '#5d19e0', |
| 163 |
'rich_text' => '<p><span style="font-size: 14px;font-weight: bold">ORDER CONFIRMED</span></p>', |
| 164 |
] |
| 165 |
), |
| 166 |
Heading::get_object_data( |
| 167 |
[ |
| 168 |
'padding' => [ |
| 169 |
'top' => 10, |
| 170 |
'right' => 0, |
| 171 |
'bottom' => 10, |
| 172 |
'left' => '0', |
| 173 |
], |
| 174 |
'background_color' => '#C6F6D500', |
| 175 |
'font_family' => '"Arial Black", Gadget, sans-serif', |
| 176 |
'text_color' => '#5d19e0', |
| 177 |
'rich_text' => '<p style="font-size: 30px;font-weight: 900; line-height: 1.2 !important;"><span style="line-height: 1.2 !important;">We\'ve Received</span><br /><span style="line-height: 1.2 !important;">Your Order</span></p>', |
| 178 |
] |
| 179 |
), |
| 180 |
Text::get_object_data( |
| 181 |
[ |
| 182 |
'padding' => [ |
| 183 |
'top' => '0', |
| 184 |
'right' => '10', |
| 185 |
'bottom' => '0', |
| 186 |
'left' => '0', |
| 187 |
], |
| 188 |
'background_color' => '#C6F6D500', |
| 189 |
'font_family' => 'Arial, Helvetica, sans-serif', |
| 190 |
'text_color' => '#5d19e0', |
| 191 |
'rich_text' => '<p><span style="font-size: 14px">Order placed on [yaymail_order_date]</span></p><p><span style="font-size: 14px">Number ID: #[yaymail_order_id is_plain="true"]</span></p>', |
| 192 |
] |
| 193 |
), |
| 194 |
], |
| 195 |
] |
| 196 |
), |
| 197 |
Column::get_object_data( |
| 198 |
42, |
| 199 |
[ |
| 200 |
'children' => [ |
| 201 |
Image::get_object_data( |
| 202 |
[ |
| 203 |
'padding' => [ |
| 204 |
'top' => '0', |
| 205 |
'right' => '0', |
| 206 |
'bottom' => '0', |
| 207 |
'left' => '0', |
| 208 |
], |
| 209 |
'background_color' => '#C6F6D500', |
| 210 |
'src' => 'https://images.wpbrandy.com/uploads/processing-5-img-2.png', |
| 211 |
'width' => 648, |
| 212 |
'alt' => 'Shopping cart illustration', |
| 213 |
] |
| 214 |
), |
| 215 |
], |
| 216 |
] |
| 217 |
), |
| 218 |
], |
| 219 |
'vertical_align' => 'middle', |
| 220 |
'padding' => [ |
| 221 |
'top' => 0, |
| 222 |
'right' => 0, |
| 223 |
'bottom' => 20, |
| 224 |
'left' => 30, |
| 225 |
], |
| 226 |
'border_radius' => [ |
| 227 |
'top_left' => 0, |
| 228 |
'top_right' => 0, |
| 229 |
'bottom_left' => null, |
| 230 |
'bottom_right' => 0, |
| 231 |
], |
| 232 |
'background_color' => '#bdedea', |
| 233 |
'background_image' => [ |
| 234 |
'url' => '', |
| 235 |
'position' => 'top_right', |
| 236 |
'x_position' => 84, |
| 237 |
'y_position' => -26, |
| 238 |
'repeat' => 'no-repeat', |
| 239 |
'size' => 'contain', |
| 240 |
], |
| 241 |
] |
| 242 |
), |
| 243 |
], |
| 244 |
] |
| 245 |
), |
| 246 |
], |
| 247 |
'padding' => [ |
| 248 |
'top' => 0, |
| 249 |
'right' => '40', |
| 250 |
'bottom' => '0', |
| 251 |
'left' => '40', |
| 252 |
], |
| 253 |
'background_color' => '#723af5', |
| 254 |
] |
| 255 |
), |
| 256 |
Text::get_object_data( |
| 257 |
[ |
| 258 |
'padding' => [ |
| 259 |
'top' => '32', |
| 260 |
'right' => '50', |
| 261 |
'bottom' => 0, |
| 262 |
'left' => '50', |
| 263 |
], |
| 264 |
'background_color' => '#723af5', |
| 265 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 266 |
'text_color' => '#ffffff', |
| 267 |
'rich_text' => '<p style="text-align: center"><span style="font-size: 24px">Hi <strong>[yaymail_billing_first_name],</strong></span></p>', |
| 268 |
] |
| 269 |
), |
| 270 |
Text::get_object_data( |
| 271 |
[ |
| 272 |
'padding' => [ |
| 273 |
'top' => 0, |
| 274 |
'right' => '50', |
| 275 |
'bottom' => 0, |
| 276 |
'left' => 50, |
| 277 |
], |
| 278 |
'background_color' => '#723af5', |
| 279 |
'font_family' => '"Arial Black", Gadget, sans-serif', |
| 280 |
'text_color' => '#ffffff', |
| 281 |
'rich_text' => '<p style="text-align: center"><span style="font-size: 80px;font-weight: 800; line-height: normal">THANKS FOR YOUR ORDER!</span></p>', |
| 282 |
] |
| 283 |
), |
| 284 |
Text::get_object_data( |
| 285 |
[ |
| 286 |
'padding' => [ |
| 287 |
'top' => 0, |
| 288 |
'right' => '50', |
| 289 |
'bottom' => '24', |
| 290 |
'left' => 50, |
| 291 |
], |
| 292 |
'background_color' => '#723af5', |
| 293 |
'font_family' => 'Arial, Helvetica, sans-serif', |
| 294 |
'text_color' => '#ffffff', |
| 295 |
'rich_text' => '<p style="text-align: center"><span style="font-size: 56px;font-weight: bold; line-height: normal">WE HAVE SUCCESSFULLY RECEIVED IT AND IT\'S NOW BEING PROCESSED.</span></p>', |
| 296 |
] |
| 297 |
), |
| 298 |
ColumnLayout::get_object_data( |
| 299 |
1, |
| 300 |
[ |
| 301 |
'children' => [ |
| 302 |
Column::get_object_data( |
| 303 |
100, |
| 304 |
[ |
| 305 |
'children' => [ |
| 306 |
ColumnLayout::get_object_data( |
| 307 |
1, |
| 308 |
[ |
| 309 |
'children' => [ |
| 310 |
Column::get_object_data( |
| 311 |
100, |
| 312 |
[ |
| 313 |
'children' => [ |
| 314 |
OrderDetails::get_object_data( |
| 315 |
[ |
| 316 |
'padding' => [ |
| 317 |
'top' => '0', |
| 318 |
'right' => '0', |
| 319 |
'bottom' => '8', |
| 320 |
'left' => '0', |
| 321 |
], |
| 322 |
'background_color' => '#bdedea00', |
| 323 |
'layout_type' => 'modern', |
| 324 |
'title' => '<span style="font-size: 20px;font-weight: 800">Order Summary</span>', |
| 325 |
'title_color' => '#5d19e0', |
| 326 |
'text_color' => '#5d19e0', |
| 327 |
'border_color' => '#5d19e033', |
| 328 |
'font_family' => 'Arial, Helvetica, sans-serif', |
| 329 |
'table_heading_font_size' => '12', |
| 330 |
'product_title' => 'PRODUCT', |
| 331 |
'quantity_title' => 'QUANTITY', |
| 332 |
'price_title' => 'PRICE', |
| 333 |
] |
| 334 |
), |
| 335 |
Button::get_object_data( |
| 336 |
[ |
| 337 |
'padding' => [ |
| 338 |
'top' => '0', |
| 339 |
'right' => '0', |
| 340 |
'bottom' => '0', |
| 341 |
'left' => '0', |
| 342 |
], |
| 343 |
'background_color' => '#ffffff', |
| 344 |
'width' => '100%', |
| 345 |
'height' => 27, |
| 346 |
'button_background_color' => '#7B42F6', |
| 347 |
'border_radius' => [ |
| 348 |
'top_left' => 0, |
| 349 |
'top_right' => 0, |
| 350 |
'bottom_right' => 0, |
| 351 |
'bottom_left' => 0, |
| 352 |
], |
| 353 |
'text' => 'View Your Order', |
| 354 |
'url' => '[yaymail_order_url]', |
| 355 |
'font_size' => '16', |
| 356 |
'weight' => '600', |
| 357 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 358 |
] |
| 359 |
), |
| 360 |
], |
| 361 |
] |
| 362 |
), |
| 363 |
], |
| 364 |
'padding' => [ |
| 365 |
'top' => '24', |
| 366 |
'right' => '24', |
| 367 |
'bottom' => '24', |
| 368 |
'left' => '24', |
| 369 |
], |
| 370 |
'background_color' => '#bdedea', |
| 371 |
] |
| 372 |
), |
| 373 |
], |
| 374 |
] |
| 375 |
), |
| 376 |
], |
| 377 |
'padding' => [ |
| 378 |
'top' => '0', |
| 379 |
'right' => '40', |
| 380 |
'bottom' => '24', |
| 381 |
'left' => '40', |
| 382 |
], |
| 383 |
'background_color' => '#723af5', |
| 384 |
] |
| 385 |
), |
| 386 |
ColumnLayout::get_object_data( |
| 387 |
2, |
| 388 |
[ |
| 389 |
'children' => [ |
| 390 |
Column::get_object_data( |
| 391 |
50, |
| 392 |
[ |
| 393 |
'children' => [ |
| 394 |
Text::get_object_data( |
| 395 |
[ |
| 396 |
'padding' => [ |
| 397 |
'top' => 15, |
| 398 |
'right' => 0, |
| 399 |
'bottom' => 0, |
| 400 |
'left' => 0, |
| 401 |
], |
| 402 |
'background_color' => '#bdedea', |
| 403 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 404 |
'text_color' => '#5d19e0', |
| 405 |
'rich_text' => '<p style="text-align: center"><strong style="font-size: 20px;text-align: center">Shipping Address</strong></p>', |
| 406 |
] |
| 407 |
), |
| 408 |
ShippingAddress::get_object_data( |
| 409 |
[ |
| 410 |
'padding' => [ |
| 411 |
'top' => 0, |
| 412 |
'right' => 30, |
| 413 |
'bottom' => 30, |
| 414 |
'left' => 30, |
| 415 |
], |
| 416 |
'background_color' => '#bdedea', |
| 417 |
'layout_type' => 'modern', |
| 418 |
'title_color' => '#1a1a1a', |
| 419 |
'text_color' => '#5d19e0', |
| 420 |
'border_color' => '#c7ccc7', |
| 421 |
'font_family' => '"Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 422 |
'title' => '', |
| 423 |
'shipping_content_alignment' => 'center', |
| 424 |
'shipping_content_text_format' => [ |
| 425 |
'bold' => false, |
| 426 |
'italic' => false, |
| 427 |
'underline' => false, |
| 428 |
], |
| 429 |
] |
| 430 |
), |
| 431 |
], |
| 432 |
] |
| 433 |
), |
| 434 |
Column::get_object_data( |
| 435 |
50, |
| 436 |
[ |
| 437 |
'children' => [ |
| 438 |
Text::get_object_data( |
| 439 |
[ |
| 440 |
'padding' => [ |
| 441 |
'top' => '15', |
| 442 |
'right' => 0, |
| 443 |
'bottom' => 0, |
| 444 |
'left' => 0, |
| 445 |
], |
| 446 |
'background_color' => '#bdedea', |
| 447 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 448 |
'text_color' => '#5d19e0', |
| 449 |
'rich_text' => '<p style="text-align: center"><strong style="font-size: 20px;text-align: center">Billing Address</strong></p>', |
| 450 |
] |
| 451 |
), |
| 452 |
BillingAddress::get_object_data( |
| 453 |
[ |
| 454 |
'padding' => [ |
| 455 |
'top' => 0, |
| 456 |
'right' => 30, |
| 457 |
'bottom' => 30, |
| 458 |
'left' => 30, |
| 459 |
], |
| 460 |
'background_color' => '#bdedea', |
| 461 |
'layout_type' => 'modern', |
| 462 |
'title_color' => '#1a1a1a', |
| 463 |
'text_color' => '#5d19e0', |
| 464 |
'border_color' => '#23661b33', |
| 465 |
'font_family' => '"Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 466 |
'title' => '', |
| 467 |
'billing_content_alignment' => 'center', |
| 468 |
'billing_content_text_format' => [ |
| 469 |
'bold' => false, |
| 470 |
'italic' => false, |
| 471 |
'underline' => false, |
| 472 |
], |
| 473 |
] |
| 474 |
), |
| 475 |
], |
| 476 |
] |
| 477 |
), |
| 478 |
], |
| 479 |
'column_spacing' => 20, |
| 480 |
'padding' => [ |
| 481 |
'top' => 30, |
| 482 |
'right' => 50, |
| 483 |
'bottom' => 30, |
| 484 |
'left' => 50, |
| 485 |
], |
| 486 |
'background_color' => '#723af5', |
| 487 |
] |
| 488 |
), |
| 489 |
Text::get_object_data( |
| 490 |
[ |
| 491 |
'padding' => [ |
| 492 |
'top' => 50, |
| 493 |
'right' => '50', |
| 494 |
'bottom' => '24', |
| 495 |
'left' => '50', |
| 496 |
], |
| 497 |
'background_color' => '#723af5', |
| 498 |
'font_family' => 'Arial, Helvetica, sans-serif', |
| 499 |
'text_color' => '#ffffff', |
| 500 |
'rich_text' => '<p style="text-align: left"><span style="font-size: 18px">Thanks again for shopping with us!</span></p> |
| 501 |
<p style="text-align: left"><span style="font-size: 18px">Your order will be shipped within 24-48 hours.</span></p> |
| 502 |
<p style="text-align: left"><span style="font-size: 18px">Got questions? Check out our <u>Returns</u> & <u>Refunds Policy</u> or contact <u>Here</u> for support. We\'re happy to help!</span></p> |
| 503 |
<p style="text-align: left"><span style="font-size: 18px">Best regards,<br />The <strong>[yaymail_site_name]</strong> Team</span></p>', |
| 504 |
] |
| 505 |
), |
| 506 |
ColumnLayout::get_object_data( |
| 507 |
1, |
| 508 |
[ |
| 509 |
'children' => [ |
| 510 |
Column::get_object_data( |
| 511 |
100, |
| 512 |
[ |
| 513 |
'children' => [ |
| 514 |
SocialIcon::get_object_data( |
| 515 |
[ |
| 516 |
'padding' => [ |
| 517 |
'top' => '0', |
| 518 |
'right' => '0', |
| 519 |
'bottom' => '16', |
| 520 |
'left' => '0', |
| 521 |
], |
| 522 |
'background_color' => '#5f19e000', |
| 523 |
'width_icon' => '32', |
| 524 |
'spacing' => '12', |
| 525 |
'icon_list' => [ |
| 526 |
[ |
| 527 |
'icon' => 'facebook', |
| 528 |
'url' => '#', |
| 529 |
], |
| 530 |
[ |
| 531 |
'icon' => 'instagram', |
| 532 |
'url' => '#', |
| 533 |
], |
| 534 |
[ |
| 535 |
'icon' => 'tiktok', |
| 536 |
'url' => '#', |
| 537 |
], |
| 538 |
[ |
| 539 |
'icon' => 'youtube', |
| 540 |
'url' => '#', |
| 541 |
], |
| 542 |
], |
| 543 |
] |
| 544 |
), |
| 545 |
Text::get_object_data( |
| 546 |
[ |
| 547 |
'padding' => [ |
| 548 |
'top' => '0', |
| 549 |
'right' => '0', |
| 550 |
'bottom' => '0', |
| 551 |
'left' => '0', |
| 552 |
], |
| 553 |
'background_color' => '#8049ff', |
| 554 |
'font_family' => '"Rethink Sans","Helvetica Neue",Helvetica,Roboto,Arial,sans-serif', |
| 555 |
'text_color' => '#efedf3', |
| 556 |
'rich_text' => '<p style="text-align: center"><span style="font-size: 12px">© 2024 WooCommerce</span></p>', |
| 557 |
] |
| 558 |
), |
| 559 |
], |
| 560 |
] |
| 561 |
), |
| 562 |
], |
| 563 |
'padding' => [ |
| 564 |
'top' => 40, |
| 565 |
'right' => '50', |
| 566 |
'bottom' => 40, |
| 567 |
'left' => '50', |
| 568 |
], |
| 569 |
'background_color' => '#8049ff', |
| 570 |
] |
| 571 |
), |
| 572 |
]; |
| 573 |
} |
| 574 |
} |
| 575 |
|