plain
9 years ago
admin-cancelled-order.php
9 years ago
admin-failed-order.php
9 years ago
admin-new-order.php
9 years ago
customer-completed-order.php
9 years ago
customer-invoice.php
9 years ago
customer-new-account.php
9 years ago
customer-note.php
9 years ago
customer-on-hold-order.php
9 years ago
customer-processing-order.php
9 years ago
customer-refunded-order.php
9 years ago
customer-reset-password.php
9 years ago
email-addresses.php
9 years ago
email-customer-details.php
9 years ago
email-footer.php
9 years ago
email-header.php
9 years ago
email-order-details.php
9 years ago
email-order-items.php
9 years ago
email-styles.php
9 years ago
email-styles.php
197 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Email Styles |
| 4 | * |
| 5 | * This template can be overridden by copying it to yourtheme/woocommerce/emails/email-styles.php. |
| 6 | * |
| 7 | * HOWEVER, on occasion WooCommerce will need to update template files and you |
| 8 | * (the theme developer) will need to copy the new files to your theme to |
| 9 | * maintain compatibility. We try to do this as little as possible, but it does |
| 10 | * happen. When this occurs the version of the template file will be bumped and |
| 11 | * the readme will list any important changes. |
| 12 | * |
| 13 | * @see https://docs.woocommerce.com/document/template-structure/ |
| 14 | * @author WooThemes |
| 15 | * @package WooCommerce/Templates/Emails |
| 16 | * @version 2.3.0 |
| 17 | */ |
| 18 | |
| 19 | if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly |
| 20 | |
| 21 | // Load colors |
| 22 | $bg = get_option( 'woocommerce_email_background_color' ); |
| 23 | $body = get_option( 'woocommerce_email_body_background_color' ); |
| 24 | $base = get_option( 'woocommerce_email_base_color' ); |
| 25 | $base_text = wc_light_or_dark( $base, '#202020', '#ffffff' ); |
| 26 | $text = get_option( 'woocommerce_email_text_color' ); |
| 27 | |
| 28 | $bg_darker_10 = wc_hex_darker( $bg, 10 ); |
| 29 | $body_darker_10 = wc_hex_darker( $body, 10 ); |
| 30 | $base_lighter_20 = wc_hex_lighter( $base, 20 ); |
| 31 | $base_lighter_40 = wc_hex_lighter( $base, 40 ); |
| 32 | $text_lighter_20 = wc_hex_lighter( $text, 20 ); |
| 33 | |
| 34 | // !important; is a gmail hack to prevent styles being stripped if it doesn't like something. |
| 35 | ?> |
| 36 | #wrapper { |
| 37 | background-color: <?php echo esc_attr( $bg ); ?>; |
| 38 | margin: 0; |
| 39 | padding: 70px 0 70px 0; |
| 40 | -webkit-text-size-adjust: none !important; |
| 41 | width: 100%; |
| 42 | } |
| 43 | |
| 44 | #template_container { |
| 45 | box-shadow: 0 1px 4px rgba(0,0,0,0.1) !important; |
| 46 | background-color: <?php echo esc_attr( $body ); ?>; |
| 47 | border: 1px solid <?php echo esc_attr( $bg_darker_10 ); ?>; |
| 48 | border-radius: 3px !important; |
| 49 | } |
| 50 | |
| 51 | #template_header { |
| 52 | background-color: <?php echo esc_attr( $base ); ?>; |
| 53 | border-radius: 3px 3px 0 0 !important; |
| 54 | color: <?php echo esc_attr( $base_text ); ?>; |
| 55 | border-bottom: 0; |
| 56 | font-weight: bold; |
| 57 | line-height: 100%; |
| 58 | vertical-align: middle; |
| 59 | font-family: "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif; |
| 60 | } |
| 61 | |
| 62 | #template_header h1, |
| 63 | #template_header h1 a { |
| 64 | color: <?php echo esc_attr( $base_text ); ?>; |
| 65 | } |
| 66 | |
| 67 | #template_footer td { |
| 68 | padding: 0; |
| 69 | -webkit-border-radius: 6px; |
| 70 | } |
| 71 | |
| 72 | #template_footer #credit { |
| 73 | border:0; |
| 74 | color: <?php echo esc_attr( $base_lighter_40 ); ?>; |
| 75 | font-family: Arial; |
| 76 | font-size:12px; |
| 77 | line-height:125%; |
| 78 | text-align:center; |
| 79 | padding: 0 48px 48px 48px; |
| 80 | } |
| 81 | |
| 82 | #body_content { |
| 83 | background-color: <?php echo esc_attr( $body ); ?>; |
| 84 | } |
| 85 | |
| 86 | #body_content table td { |
| 87 | padding: 48px; |
| 88 | } |
| 89 | |
| 90 | #body_content table td td { |
| 91 | padding: 12px; |
| 92 | } |
| 93 | |
| 94 | #body_content table td th { |
| 95 | padding: 12px; |
| 96 | } |
| 97 | |
| 98 | #body_content td ul.wc-item-meta { |
| 99 | font-size: small; |
| 100 | margin: 1em 0 0; |
| 101 | padding: 0; |
| 102 | list-style: none; |
| 103 | } |
| 104 | |
| 105 | #body_content td ul.wc-item-meta li { |
| 106 | margin: 0.5em 0 0; |
| 107 | padding: 0; |
| 108 | } |
| 109 | |
| 110 | #body_content td ul.wc-item-meta li p { |
| 111 | margin: 0; |
| 112 | } |
| 113 | |
| 114 | #body_content p { |
| 115 | margin: 0 0 16px; |
| 116 | } |
| 117 | |
| 118 | #body_content_inner { |
| 119 | color: <?php echo esc_attr( $text_lighter_20 ); ?>; |
| 120 | font-family: "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif; |
| 121 | font-size: 14px; |
| 122 | line-height: 150%; |
| 123 | text-align: <?php echo is_rtl() ? 'right' : 'left'; ?>; |
| 124 | } |
| 125 | |
| 126 | .td { |
| 127 | color: <?php echo esc_attr( $text_lighter_20 ); ?>; |
| 128 | border: 1px solid <?php echo esc_attr( $body_darker_10 ); ?>; |
| 129 | } |
| 130 | |
| 131 | .text { |
| 132 | color: <?php echo esc_attr( $text ); ?>; |
| 133 | font-family: "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif; |
| 134 | } |
| 135 | |
| 136 | .link { |
| 137 | color: <?php echo esc_attr( $base ); ?>; |
| 138 | } |
| 139 | |
| 140 | #header_wrapper { |
| 141 | padding: 36px 48px; |
| 142 | display: block; |
| 143 | } |
| 144 | |
| 145 | h1 { |
| 146 | color: <?php echo esc_attr( $base ); ?>; |
| 147 | font-family: "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif; |
| 148 | font-size: 30px; |
| 149 | font-weight: 300; |
| 150 | line-height: 150%; |
| 151 | margin: 0; |
| 152 | text-align: <?php echo is_rtl() ? 'right' : 'left'; ?>; |
| 153 | text-shadow: 0 1px 0 <?php echo esc_attr( $base_lighter_20 ); ?>; |
| 154 | -webkit-font-smoothing: antialiased; |
| 155 | } |
| 156 | |
| 157 | h2 { |
| 158 | color: <?php echo esc_attr( $base ); ?>; |
| 159 | display: block; |
| 160 | font-family: "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif; |
| 161 | font-size: 18px; |
| 162 | font-weight: bold; |
| 163 | line-height: 130%; |
| 164 | margin: 16px 0 8px; |
| 165 | text-align: <?php echo is_rtl() ? 'right' : 'left'; ?>; |
| 166 | } |
| 167 | |
| 168 | h3 { |
| 169 | color: <?php echo esc_attr( $base ); ?>; |
| 170 | display: block; |
| 171 | font-family: "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif; |
| 172 | font-size: 16px; |
| 173 | font-weight: bold; |
| 174 | line-height: 130%; |
| 175 | margin: 16px 0 8px; |
| 176 | text-align: <?php echo is_rtl() ? 'right' : 'left'; ?>; |
| 177 | } |
| 178 | |
| 179 | a { |
| 180 | color: <?php echo esc_attr( $base ); ?>; |
| 181 | font-weight: normal; |
| 182 | text-decoration: underline; |
| 183 | } |
| 184 | |
| 185 | img { |
| 186 | border: none; |
| 187 | display: inline; |
| 188 | font-size: 14px; |
| 189 | font-weight: bold; |
| 190 | height: auto; |
| 191 | line-height: 100%; |
| 192 | outline: none; |
| 193 | text-decoration: none; |
| 194 | text-transform: capitalize; |
| 195 | } |
| 196 | <?php |
| 197 |