Last active
February 10, 2017 16:44
-
-
Save robneu/e10f39ee62358b68e171235503491dd3 to your computer and use it in GitHub Desktop.
Add custom inline styles to the Cookbook print/print preview.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'cookbook_recipe_print_head', 'prefix_cookbook_inline_print_css', 99 ); | |
/** | |
* Inline custom print styles in the Cookbook print head. | |
* | |
* @since 1.0.0 | |
* @access public | |
* @return void | |
*/ | |
function prefix_cookbook_inline_print_css() { | |
?> | |
<style> | |
.cookbook-recipe-print-body { | |
font-size: 14px; | |
} | |
.cookbook-nutrition { | |
page-break-before: avoid; | |
} | |
</style> | |
<?php | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment