WP Recipe Maker - Version 1.22.0

Version Description

  • Feature: RTL support for recipe templates and print
  • Improvement: Print and unit conversion functionality when using the print templates
  • Improvement: Combined public JS files
  • Improvement: Apply appearance settings to print template as well
  • Improvement: Recipe rating saved as post meta
  • Improvement: Migrate WP Ultimate Recipe Premium user ratings
  • Fix: Heading style dropdown in Recipe Notes
Download this release

Release Info

Developer BrechtVds
Plugin Icon 128x128 WP Recipe Maker
Version 1.22.0
Comparing to
See all releases

Code changes from version 1.21.0 to 1.22.0

Files changed (39) hide show
  1. assets/css/admin/import.min.css +1 -1
  2. assets/css/admin/modal.min.css +1 -1
  3. assets/css/admin/modal/_container.scss +4 -0
  4. assets/css/public/_print.scss +13 -0
  5. assets/css/public/public.min.css +1 -1
  6. assets/css/public/public.scss +1 -0
  7. assets/icons/checkbox-checked.svg +1 -0
  8. assets/icons/checkbox-empty.svg +1 -0
  9. assets/js/public.js +88 -0
  10. assets/js/public.min.js +1 -0
  11. assets/js/public/comment-rating.js +37 -35
  12. includes/admin/import/class-wprm-import-wpultimaterecipe.php +7 -0
  13. includes/class-wp-recipe-maker.php +4 -2
  14. includes/public/class-wprm-assets.php +51 -0
  15. includes/public/class-wprm-comment-rating.php +7 -11
  16. includes/public/class-wprm-print.php +19 -21
  17. includes/public/class-wprm-rating.php +118 -0
  18. includes/public/class-wprm-recipe.php +27 -41
  19. includes/public/class-wprm-settings.php +3 -0
  20. includes/public/class-wprm-shortcode.php +0 -10
  21. includes/public/class-wprm-template-helper.php +27 -14
  22. includes/public/class-wprm-template-manager.php +10 -3
  23. readme.txt +32 -13
  24. templates/admin/menu/faq/whats_new.php +19 -0
  25. templates/admin/settings/appearance.php +6 -0
  26. templates/admin/settings/features.php +15 -0
  27. templates/recipe/clean-print-with-image/clean-print-with-image.min.css +1 -1
  28. templates/recipe/clean-print-with-image/clean-print-with-image.php +2 -0
  29. templates/recipe/clean-print-with-image/clean-print-with-image.scss +14 -7
  30. templates/recipe/clean-print/clean-print.min.css +1 -1
  31. templates/recipe/clean-print/clean-print.php +2 -0
  32. templates/recipe/clean-print/clean-print.scss +9 -7
  33. templates/recipe/simple/simple.min.css +1 -1
  34. templates/recipe/simple/simple.php +1 -5
  35. templates/recipe/simple/simple.scss +16 -11
  36. templates/recipe/tastefully-simple/tastefully-simple.min.css +1 -1
  37. templates/recipe/tastefully-simple/tastefully-simple.php +1 -5
  38. templates/recipe/tastefully-simple/tastefully-simple.scss +59 -10
  39. wp-recipe-maker.php +1 -1
assets/css/admin/import.min.css CHANGED
@@ -1 +1 @@
1
- .wprm-import p{max-width:600px}.wprm-import .wprm-import-error{max-width:600px;border:1px solid #8b0000;background-color:#ff9f9f;padding:10px}.wprm-import .wprm-import-recipes{width:100%}.wprm-import .wprm-import-recipes input[type=checkbox]{vertical-align:top}.wprm-import .wprm-import-recipes a{text-decoration:none}.wprm-import .wprm-import-recipes .dashicons.dashicons-visibility{font-size:18px}.wprm-import .wprm-import-recipes td:nth-child(1){width:2%}.wprm-import .wprm-import-recipes td:nth-child(2){width:30%}.wprm-import #wprm-import-progress-container{width:100%;max-width:300px;height:20px;margin:10px 0;border:1px solid #000;background-color:#fff}.wprm-import #wprm-import-progress-bar{width:0;height:100%;background-color:#4484ce}.wprm-import #wprm-import-finished{display:none}
1
+ .wprm-import p{max-width:600px}.wprm-import .wprm-import-error{max-width:600px;border:1px solid #8b0000;background-color:#ff9f9f;padding:10px}.wprm-import .wprm-import-recipes{width:100%}.wprm-import .wprm-import-recipes input[type=checkbox]{vertical-align:top}.wprm-import .wprm-import-recipes a{text-decoration:none}.wprm-import .wprm-import-recipes .dashicons.dashicons-visibility{font-size:18px}.wprm-import .wprm-import-recipes td:nth-child(1){width:2%}.wprm-import .wprm-import-recipes td:nth-child(2){width:30%}.wprm-import #wprm-import-progress-container{width:100%;max-width:300px;height:20px;margin:10px 0;border:1px solid #000;background-color:#fff}.wprm-import #wprm-import-progress-bar{width:0%;height:100%;background-color:#4484ce}.wprm-import #wprm-import-finished{display:none}
assets/css/admin/modal.min.css CHANGED
@@ -1 +1 @@
1
- .wprm-frame-title .dashicons,.wprm-frame.hide-router .wprm-frame-router,.wprm-modal-container{display:none}.wprm-giveaway-notice{border:1px solid #006400;background-color:rgba(0,255,0,.15);padding:10px;margin-bottom:10px}.wprm-easyrecipe-warning{display:none;border:1px solid #8b0000;background-color:rgba(255,0,0,.15);padding:10px 10px 0;margin-bottom:10px}.select2_wprm-container{z-index:100075}.select2_wprm-container.select2_wprm-container--focus .select2_wprm-selection{border-color:#5b9dd9}.select2_wprm-container li{margin:0}.select2_wprm-container .select2_wprm-selection{border-color:#ddd}.medium-editor-anchor-preview,.medium-editor-toolbar{z-index:100080}.medium-editor-anchor-preview{font-size:12px}.medium-editor-element{border:1px solid #ddd;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.07);box-shadow:inset 0 1px 2px rgba(0,0,0,.07);min-height:68px;padding:3px 5px}.medium-editor-element:focus{border-color:#5b9dd9;-webkit-box-shadow:0 0 2px rgba(30,140,190,.8);box-shadow:0 0 2px rgba(30,140,190,.8)}.medium-editor-element:after{font-style:normal;color:#999;opacity:.5;font-size:14px;line-height:28px}.medium-editor-element p:first-child{margin-top:0}.medium-editor-element p:last-child{margin-bottom:0}.wprm-modal-hint{max-width:400px;margin-bottom:20px}.wprm-modal-hint .wprm-modal-hint-header{font-weight:700;font-variant:small-caps}.wprm-modal-hint .wprm-modal-hint-text{font-style:italic}.wprm-modal-backdrop{position:fixed;top:0;left:0;right:0;bottom:0;min-height:360px;background:#000;opacity:.7;z-index:100000}.wprm-modal{position:fixed;top:30px;left:30px;right:30px;bottom:30px;z-index:100050}.wprm-modal *{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.wprm-modal-close{position:absolute;top:0;right:0;width:50px;height:50px;padding:0;z-index:1000;-webkit-transition:color .1s ease-in-out,background .1s ease-in-out;transition:color .1s ease-in-out,background .1s ease-in-out}.wprm-modal-close .wprm-modal-icon:before{content:"\f158";font:400 20px/1 dashicons;speak:none;vertical-align:middle;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;color:#666}.wprm-modal-content{position:absolute;top:0;left:0;right:0;bottom:0;overflow:auto;min-height:300px;-webkit-box-shadow:0 5px 15px rgba(0,0,0,.7);box-shadow:0 5px 15px rgba(0,0,0,.7);background:#fcfcfc;-webkit-font-smoothing:subpixel-antialiased}.wprm-modal-content ::-webkit-input-placeholder{color:#999;opacity:.5}.wprm-modal-content :-moz-placeholder{color:#999;opacity:.5}.wprm-modal-content ::-moz-placeholder{color:#999;opacity:.5}.wprm-modal-content :-ms-input-placeholder{color:#999;opacity:.5}.wprm-frame{overflow:hidden;right:0}.wprm-frame,.wprm-frame-menu{position:absolute;left:0;bottom:0;top:0}.wprm-frame-menu{width:200px;z-index:150}.wprm-frame-title{top:0;height:50px}.wprm-frame-router,.wprm-frame-title{z-index:200;left:200px;position:absolute;right:0}.wprm-menu-item{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.wprm-menu{position:absolute;left:0;margin:0;padding:10px 0;border-right-width:1px;border-right-style:solid;border-right-color:#ccc;user-select:none}.wprm-menu-hidden{padding:5px 5px 0 10px;font-style:italic}.wprm-menu,.wprm-sidebar{top:0;bottom:0;background:#f3f3f3;right:0}.wprm-menu .active,.wprm-menu .active:hover{color:#23282d;font-weight:700}.wprm-menu>a{display:block;position:relative;padding:8px 20px;margin:0;color:#0073aa}.wprm-button-action-save,.wprm-frame .hidden,.wprm-frame-content-tab:not(.active),.wprm-router:not(.active){display:none}.wprm-menu>a,.wprm-router>a{line-height:18px;font-size:14px;text-decoration:none}.wprm-frame a{border-bottom:none;color:#0073aa}.wprm-menu .separator{height:0;margin:12px 20px;padding:0;border-top:1px solid #ddd}.wprm-frame-title h1{padding:0 16px;font-size:22px;line-height:50px;margin:0}.wprm-frame-router{top:50px;height:36px}.wprm-router{position:relative;padding:0 6px;margin:0;clear:both;user-select:none}.wprm-router>a{position:relative;float:left;padding:8px 10px 9px;margin:0;height:18px}.wprm-router a{-webkit-transition:none;transition:none}.wprm-router>a:last-child{border-right:0}.wprm-router .active,.wprm-router>a.active:last-child{margin:-1px -1px 0;background:#fff;border:1px solid #ddd;border-bottom:none}.wprm-router .active,.wprm-router .active:hover{color:#32373c}.wprm-frame-content{position:absolute;top:84px;left:200px;right:0;bottom:61px;height:auto;width:auto;margin:0;overflow:auto;background:#fff;border-top:1px solid #ddd;border-bottom:1px solid #ddd}.wprm-frame-toolbar,.wprm-toolbar{position:absolute;right:0;z-index:100;height:60px}.wprm-frame-content-tab{margin:20px}.wprm-frame-toolbar{left:200px;bottom:0}.wprm-toolbar{top:0;left:0;padding:0 16px;border:0 solid #ddd;overflow:hidden}.wprm-modal-content .wprm-toolbar-primary.search-form{width:33%}.wprm-toolbar-primary{float:right;height:100%}.wprm-modal-content .wprm-toolbar-primary .wprm-button{float:right}.wprm-toolbar-primary>.wprm-button,.wprm-toolbar-primary>.wprm-button-group{margin-left:10px;float:left;margin-top:15px}@media only screen and (max-width:900px){.wprm-frame:not(.hide-menu) .wprm-frame-title .dashicons{display:inline-block;line-height:50px}.wprm-frame:not(.hide-menu) .wprm-frame-menu{position:static;width:0}.wprm-frame:not(.hide-menu) .wprm-frame-content,.wprm-frame:not(.hide-menu) .wprm-frame-router,.wprm-frame:not(.hide-menu) .wprm-frame-title,.wprm-frame:not(.hide-menu) .wprm-frame-toolbar,.wprm-frame:not(.hide-menu) .wprm-menu.visible{left:0}.wprm-frame:not(.hide-menu) .wprm-menu{width:auto;max-width:80%;overflow:auto;z-index:2000;top:50px;left:-300px;right:auto;bottom:auto;padding:5px 0;border:1px solid #ccc}.wprm-frame:not(.hide-menu) .wprm-menu>a.active{display:none}.wprm-frame:not(.hide-menu) .wprm-menu>a{padding:12px 16px;font-size:16px}.wprm-frame:not(.hide-menu) .wprm-menu .separator{margin:5px 10px}.wprm-frame:not(.hide-menu) .wprm-frame-title h1{color:#0073aa;line-height:3;font-size:18px;float:left;cursor:pointer}}@media only screen and (max-width:640px),screen and (max-height:400px){.wprm-modal{position:fixed;top:0;left:0;right:0;bottom:0}.wprm-modal .wprm-frame-title{height:40px}}@media only screen and (max-width:480px){.wprm-frame:not(.hide-menu) .wprm-frame-title .dashicons{line-height:40px}.wprm-frame-router,.wprm-frame:not(.hide-menu) .wprm-menu{top:40px}.wprm-frame:not(.hide-menu) .wprm-frame-title h1,.wprm-modal .wprm-frame-title h1{font-size:18px;line-height:40px}.wprm-frame-content{top:74px}}.wprm-recipe-form{max-width:600px}.wprm-recipe-form .wprm-recipe-form-container{margin-bottom:15px;vertical-align:top}.wprm-recipe-form .wprm-recipe-form-container-halfs{display:inline-block;width:50%}.wprm-recipe-form .wprm-recipe-form-container-thirds{display:inline-block;width:33.3%}.wprm-recipe-form label{display:block;font-weight:700;margin-bottom:5px}.wprm-recipe-form input[type=text],.wprm-recipe-form input[type=number]{margin:0;width:100%;max-width:120px;height:34px;line-height:34px}.wprm-recipe-form input[type=text][type=number],.wprm-recipe-form input[type=number][type=number]{max-width:50px}.wprm-recipe-form input[type=text].select2_wprm-search__field,.wprm-recipe-form input[type=number].select2_wprm-search__field{height:18px;line-height:18px}.wprm-recipe-form select{width:100%}.wprm-recipe-form textarea{width:100%;resize:vertical}@media only screen and (max-width:480px){.wprm-recipe-form .wprm-recipe-form-container-halfs,.wprm-recipe-form .wprm-recipe-form-container-thirds{display:block;width:100%}}.wprm-recipe-import-text-form .import-text-buttons{margin-bottom:10px}.wprm-recipe-import-text-form .import-text-step{display:none}.wprm-recipe-import-text-form .import-text-step#import-text-step-input{display:block}.wprm-recipe-import-text-form #import-text-highlight-sandbox,.wprm-recipe-import-text-form .import-text-input{margin-top:10px}.wprm-recipe-import-text-form #import-text-ingredient-groups label,.wprm-recipe-import-text-form #import-text-instruction-groups label{display:inline;font-weight:400}.wprm-recipe-import-text-form .import-text-group-warning{margin-top:10px;display:none}.wprm-recipe-import-text-form #import-text-highlight-sandbox{display:none;max-height:400px;overflow:scroll;padding:10px;border:1px dashed #999}.wprm-loader,.wprm-loader:after,.wprm-loader:before{border-radius:50%;width:1.5em;height:1.5em;-webkit-animation:load7 1.8s infinite ease-in-out;animation:load7 1.8s infinite ease-in-out}.wprm-loader{display:none;color:#444;font-size:10px;margin:20px auto;position:relative;text-indent:-9999em;-webkit-transform:translateZ(0);-ms-transform:translateZ(0);transform:translateZ(0);-webkit-animation-delay:-.16s;animation-delay:-.16s}.wprm-loader:after,.wprm-loader:before{content:'';position:absolute;top:0}.wprm-loader:before{left:-2.5em;-webkit-animation-delay:-.32s;animation-delay:-.32s}.wprm-loader:after{left:2.5em}@-webkit-keyframes load7{0%,100%,80%{box-shadow:0 2.5em 0 -1.3em}40%{box-shadow:0 2.5em 0 0}}@keyframes load7{0%,100%,80%{box-shadow:0 2.5em 0 -1.3em}40%{box-shadow:0 2.5em 0 0}}.wprm-recipe-details-form input#wprm-recipe-name{max-width:450px}.wprm-recipe-details-form input#wprm-recipe-author-link,.wprm-recipe-details-form input#wprm-recipe-author-name{max-width:none}.wprm-recipe-details-form input#wprm-recipe-calories{max-width:70px}.wprm-recipe-details-form .wprm-recipe-image-preview{float:right;max-width:100px}.wprm-recipe-details-form .wprm-recipe-image-preview img{max-width:100%;height:auto}.wprm-recipe-details-form .wprm-recipe-summary-container{clear:both}@media only screen and (max-width:480px){.wprm-recipe-details-form .wprm-recipe-image-preview{float:none;margin:10px auto}}.wprm-recipe-ingredients-form,.wprm-recipe-instructions-form{max-width:750px;margin-bottom:15px}.wprm-recipe-ingredients-form input,.wprm-recipe-instructions-form input{margin:0;width:100%;height:34px;line-height:34px}.wprm-recipe-ingredients-form textarea,.wprm-recipe-instructions-form textarea{width:100%;resize:vertical}.wprm-recipe-ingredients-form ::-webkit-input-placeholder,.wprm-recipe-instructions-form ::-webkit-input-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form :-moz-placeholder,.wprm-recipe-instructions-form :-moz-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form ::-moz-placeholder,.wprm-recipe-instructions-form ::-moz-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form :-ms-input-placeholder,.wprm-recipe-instructions-form :-ms-input-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form table,.wprm-recipe-instructions-form table{width:100%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th,.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th{text-align:left}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(1),.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(6),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(1),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(6){width:5%;text-align:center}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(2),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(2){width:10%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(3),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(3){width:15%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(4),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(4){width:40%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(5),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(5){width:25%}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th,.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th{text-align:left}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(1),.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(4),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(1),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(4){width:5%;text-align:center}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(2),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(2){width:65%}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(3),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(3){width:25%}.wprm-recipe-ingredients-form table .wprm-recipe-ingredients-placeholder,.wprm-recipe-ingredients-form table .wprm-recipe-instructions-placeholder,.wprm-recipe-instructions-form table .wprm-recipe-ingredients-placeholder,.wprm-recipe-instructions-form table .wprm-recipe-instructions-placeholder{display:none}.wprm-recipe-ingredients-form table td,.wprm-recipe-instructions-form table td{text-align:left;vertical-align:top}.wprm-recipe-ingredients-form table td:first-child,.wprm-recipe-ingredients-form table td:last-child,.wprm-recipe-instructions-form table td:first-child,.wprm-recipe-instructions-form table td:last-child{text-align:center;vertical-align:middle}.wprm-recipe-ingredients-form .ui-sortable-helper,.wprm-recipe-instructions-form .ui-sortable-helper{display:table}.wprm-recipe-ingredients-form .ui-sortable-helper .wprm-recipe-instruction-text,.wprm-recipe-instructions-form .ui-sortable-helper .wprm-recipe-instruction-text{min-width:200px}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-sort,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-sort{cursor:move}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-delete,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-delete{cursor:pointer}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-delete,.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-sort,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-delete,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-sort{color:#999;opacity:.5}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-delete:hover,.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-sort:hover,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-delete:hover,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-sort:hover{color:#444;opacity:1}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-actions,.wprm-recipe-ingredients-form .wprm-recipe-instructions-actions,.wprm-recipe-instructions-form .wprm-recipe-ingredients-actions,.wprm-recipe-instructions-form .wprm-recipe-instructions-actions{margin:10px}.wprm-recipe-ingredients-form .wprm-recipe-image-preview,.wprm-recipe-instructions-form .wprm-recipe-image-preview{max-width:75px}.wprm-recipe-ingredients-form .wprm-recipe-image-preview img,.wprm-recipe-instructions-form .wprm-recipe-image-preview img{max-width:100%;height:auto}.wprm-shortcode-builder .wprm-shortcode-builder-container{margin-bottom:15px;vertical-align:top}.wprm-shortcode-builder .wprm-shortcode-builder-container-halfs{display:inline-block;width:50%}.wprm-shortcode-builder .wprm-shortcode-builder-container-thirds{display:inline-block;width:33.3%}.wprm-shortcode-builder label{display:block;font-weight:700;margin-bottom:5px}.wprm-shortcode-builder .wprm-shortcode-builder-helper{margin-left:5px;font-size:.8em;font-style:italic}.wprm-shortcode-builder input{margin:0;width:100%;max-width:250px;height:34px;line-height:34px}.wprm-shortcode-builder input.select2_wprm-search__field{height:18px;line-height:18px}.wprm-shortcode-builder select{width:250px}
1
+ .wprm-frame-title .dashicons,.wprm-frame.hide-router .wprm-frame-router,.wprm-modal-container{display:none}.wprm-giveaway-notice{border:1px solid #006400;background-color:rgba(0,255,0,.15);padding:10px;margin-bottom:10px}.wprm-easyrecipe-warning{display:none;border:1px solid #8b0000;background-color:rgba(255,0,0,.15);padding:10px 10px 0;margin-bottom:10px}.mce-floatpanel{z-index:100100!important}.select2_wprm-container{z-index:100075}.select2_wprm-container.select2_wprm-container--focus .select2_wprm-selection{border-color:#5b9dd9}.select2_wprm-container li{margin:0}.select2_wprm-container .select2_wprm-selection{border-color:#ddd}.medium-editor-anchor-preview,.medium-editor-toolbar{z-index:100080}.medium-editor-anchor-preview{font-size:12px}.medium-editor-element{border:1px solid #ddd;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.07);box-shadow:inset 0 1px 2px rgba(0,0,0,.07);min-height:68px;padding:3px 5px}.medium-editor-element:focus{border-color:#5b9dd9;-webkit-box-shadow:0 0 2px rgba(30,140,190,.8);box-shadow:0 0 2px rgba(30,140,190,.8)}.medium-editor-element:after{font-style:normal;color:#999;opacity:.5;font-size:14px;line-height:28px}.medium-editor-element p:first-child{margin-top:0}.medium-editor-element p:last-child{margin-bottom:0}.wprm-modal-hint{max-width:400px;margin-bottom:20px}.wprm-modal-hint .wprm-modal-hint-header{font-weight:700;font-variant:small-caps}.wprm-modal-hint .wprm-modal-hint-text{font-style:italic}.wprm-modal-backdrop{position:fixed;top:0;left:0;right:0;bottom:0;min-height:360px;background:#000;opacity:.7;z-index:100000}.wprm-modal{position:fixed;top:30px;left:30px;right:30px;bottom:30px;z-index:100050}.wprm-modal *{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.wprm-modal-close{position:absolute;top:0;right:0;width:50px;height:50px;padding:0;z-index:1000;-webkit-transition:color .1s ease-in-out,background .1s ease-in-out;transition:color .1s ease-in-out,background .1s ease-in-out}.wprm-modal-close .wprm-modal-icon:before{content:"\f158";font:400 20px/1 dashicons;speak:none;vertical-align:middle;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;color:#666}.wprm-modal-content{position:absolute;top:0;left:0;right:0;bottom:0;overflow:auto;min-height:300px;-webkit-box-shadow:0 5px 15px rgba(0,0,0,.7);box-shadow:0 5px 15px rgba(0,0,0,.7);background:#fcfcfc;-webkit-font-smoothing:subpixel-antialiased}.wprm-modal-content ::-webkit-input-placeholder{color:#999;opacity:.5}.wprm-modal-content :-moz-placeholder{color:#999;opacity:.5}.wprm-modal-content ::-moz-placeholder{color:#999;opacity:.5}.wprm-modal-content :-ms-input-placeholder{color:#999;opacity:.5}.wprm-frame{overflow:hidden;right:0}.wprm-frame,.wprm-frame-menu{position:absolute;left:0;bottom:0;top:0}.wprm-frame-menu{width:200px;z-index:150}.wprm-frame-title{top:0;height:50px}.wprm-frame-router,.wprm-frame-title{z-index:200;left:200px;position:absolute;right:0}.wprm-menu-item{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.wprm-menu{position:absolute;left:0;margin:0;padding:10px 0;border-right-width:1px;border-right-style:solid;border-right-color:#ccc;user-select:none}.wprm-menu-hidden{padding:5px 5px 0 10px;font-style:italic}.wprm-menu,.wprm-sidebar{top:0;bottom:0;background:#f3f3f3;right:0}.wprm-menu .active,.wprm-menu .active:hover{color:#23282d;font-weight:700}.wprm-menu>a{display:block;position:relative;padding:8px 20px;margin:0;color:#0073aa}.wprm-button-action-save,.wprm-frame .hidden,.wprm-frame-content-tab:not(.active),.wprm-router:not(.active){display:none}.wprm-menu>a,.wprm-router>a{line-height:18px;font-size:14px;text-decoration:none}.wprm-frame a{border-bottom:none;color:#0073aa}.wprm-menu .separator{height:0;margin:12px 20px;padding:0;border-top:1px solid #ddd}.wprm-frame-title h1{padding:0 16px;font-size:22px;line-height:50px;margin:0}.wprm-frame-router{top:50px;height:36px}.wprm-router{position:relative;padding:0 6px;margin:0;clear:both;user-select:none}.wprm-router>a{position:relative;float:left;padding:8px 10px 9px;margin:0;height:18px}.wprm-router a{-webkit-transition:none;transition:none}.wprm-router>a:last-child{border-right:0}.wprm-router .active,.wprm-router>a.active:last-child{margin:-1px -1px 0;background:#fff;border:1px solid #ddd;border-bottom:none}.wprm-router .active,.wprm-router .active:hover{color:#32373c}.wprm-frame-content{position:absolute;top:84px;left:200px;right:0;bottom:61px;height:auto;width:auto;margin:0;overflow:auto;background:#fff;border-top:1px solid #ddd;border-bottom:1px solid #ddd}.wprm-frame-toolbar,.wprm-toolbar{position:absolute;right:0;z-index:100;height:60px}.wprm-frame-content-tab{margin:20px}.wprm-frame-toolbar{left:200px;bottom:0}.wprm-toolbar{top:0;left:0;padding:0 16px;border:0 solid #ddd;overflow:hidden}.wprm-modal-content .wprm-toolbar-primary.search-form{width:33%}.wprm-toolbar-primary{float:right;height:100%}.wprm-modal-content .wprm-toolbar-primary .wprm-button{float:right}.wprm-toolbar-primary>.wprm-button,.wprm-toolbar-primary>.wprm-button-group{margin-left:10px;float:left;margin-top:15px}@media only screen and (max-width:900px){.wprm-frame:not(.hide-menu) .wprm-frame-title .dashicons{display:inline-block;line-height:50px}.wprm-frame:not(.hide-menu) .wprm-frame-menu{position:static;width:0}.wprm-frame:not(.hide-menu) .wprm-frame-content,.wprm-frame:not(.hide-menu) .wprm-frame-router,.wprm-frame:not(.hide-menu) .wprm-frame-title,.wprm-frame:not(.hide-menu) .wprm-frame-toolbar,.wprm-frame:not(.hide-menu) .wprm-menu.visible{left:0}.wprm-frame:not(.hide-menu) .wprm-menu{width:auto;max-width:80%;overflow:auto;z-index:2000;top:50px;left:-300px;right:auto;bottom:auto;padding:5px 0;border:1px solid #ccc}.wprm-frame:not(.hide-menu) .wprm-menu>a.active{display:none}.wprm-frame:not(.hide-menu) .wprm-menu>a{padding:12px 16px;font-size:16px}.wprm-frame:not(.hide-menu) .wprm-menu .separator{margin:5px 10px}.wprm-frame:not(.hide-menu) .wprm-frame-title h1{color:#0073aa;line-height:3;font-size:18px;float:left;cursor:pointer}}@media only screen and (max-width:640px),screen and (max-height:400px){.wprm-modal{position:fixed;top:0;left:0;right:0;bottom:0}.wprm-modal .wprm-frame-title{height:40px}}@media only screen and (max-width:480px){.wprm-frame:not(.hide-menu) .wprm-frame-title .dashicons{line-height:40px}.wprm-frame-router,.wprm-frame:not(.hide-menu) .wprm-menu{top:40px}.wprm-frame:not(.hide-menu) .wprm-frame-title h1,.wprm-modal .wprm-frame-title h1{font-size:18px;line-height:40px}.wprm-frame-content{top:74px}}.wprm-recipe-form{max-width:600px}.wprm-recipe-form .wprm-recipe-form-container{margin-bottom:15px;vertical-align:top}.wprm-recipe-form .wprm-recipe-form-container-halfs{display:inline-block;width:50%}.wprm-recipe-form .wprm-recipe-form-container-thirds{display:inline-block;width:33.3%}.wprm-recipe-form label{display:block;font-weight:700;margin-bottom:5px}.wprm-recipe-form input[type=text],.wprm-recipe-form input[type=number]{margin:0;width:100%;max-width:120px;height:34px;line-height:34px}.wprm-recipe-form input[type=text][type=number],.wprm-recipe-form input[type=number][type=number]{max-width:50px}.wprm-recipe-form input[type=text].select2_wprm-search__field,.wprm-recipe-form input[type=number].select2_wprm-search__field{height:18px;line-height:18px}.wprm-recipe-form select{width:100%}.wprm-recipe-form textarea{width:100%;resize:vertical}@media only screen and (max-width:480px){.wprm-recipe-form .wprm-recipe-form-container-halfs,.wprm-recipe-form .wprm-recipe-form-container-thirds{display:block;width:100%}}.wprm-recipe-import-text-form .import-text-buttons{margin-bottom:10px}.wprm-recipe-import-text-form .import-text-step{display:none}.wprm-recipe-import-text-form .import-text-step#import-text-step-input{display:block}.wprm-recipe-import-text-form #import-text-highlight-sandbox,.wprm-recipe-import-text-form .import-text-input{margin-top:10px}.wprm-recipe-import-text-form #import-text-ingredient-groups label,.wprm-recipe-import-text-form #import-text-instruction-groups label{display:inline;font-weight:400}.wprm-recipe-import-text-form .import-text-group-warning{margin-top:10px;display:none}.wprm-recipe-import-text-form #import-text-highlight-sandbox{display:none;max-height:400px;overflow:scroll;padding:10px;border:1px dashed #999}.wprm-loader,.wprm-loader:after,.wprm-loader:before{border-radius:50%;width:1.5em;height:1.5em;-webkit-animation:load7 1.8s infinite ease-in-out;animation:load7 1.8s infinite ease-in-out}.wprm-loader{display:none;color:#444;font-size:10px;margin:20px auto;position:relative;text-indent:-9999em;-webkit-transform:translateZ(0);-ms-transform:translateZ(0);transform:translateZ(0);-webkit-animation-delay:-.16s;animation-delay:-.16s}.wprm-loader:after,.wprm-loader:before{content:'';position:absolute;top:0}.wprm-loader:before{left:-2.5em;-webkit-animation-delay:-.32s;animation-delay:-.32s}.wprm-loader:after{left:2.5em}@-webkit-keyframes load7{0%,100%,80%{box-shadow:0 2.5em 0 -1.3em}40%{box-shadow:0 2.5em 0 0}}@keyframes load7{0%,100%,80%{box-shadow:0 2.5em 0 -1.3em}40%{box-shadow:0 2.5em 0 0}}.wprm-recipe-details-form input#wprm-recipe-name{max-width:450px}.wprm-recipe-details-form input#wprm-recipe-author-link,.wprm-recipe-details-form input#wprm-recipe-author-name{max-width:none}.wprm-recipe-details-form input#wprm-recipe-calories{max-width:70px}.wprm-recipe-details-form .wprm-recipe-image-preview{float:right;max-width:100px}.wprm-recipe-details-form .wprm-recipe-image-preview img{max-width:100%;height:auto}.wprm-recipe-details-form .wprm-recipe-summary-container{clear:both}@media only screen and (max-width:480px){.wprm-recipe-details-form .wprm-recipe-image-preview{float:none;margin:10px auto}}.wprm-recipe-ingredients-form,.wprm-recipe-instructions-form{max-width:750px;margin-bottom:15px}.wprm-recipe-ingredients-form input,.wprm-recipe-instructions-form input{margin:0;width:100%;height:34px;line-height:34px}.wprm-recipe-ingredients-form textarea,.wprm-recipe-instructions-form textarea{width:100%;resize:vertical}.wprm-recipe-ingredients-form ::-webkit-input-placeholder,.wprm-recipe-instructions-form ::-webkit-input-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form :-moz-placeholder,.wprm-recipe-instructions-form :-moz-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form ::-moz-placeholder,.wprm-recipe-instructions-form ::-moz-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form :-ms-input-placeholder,.wprm-recipe-instructions-form :-ms-input-placeholder{color:#999;opacity:.5}.wprm-recipe-ingredients-form table,.wprm-recipe-instructions-form table{width:100%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th,.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th{text-align:left}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(1),.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(6),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(1),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(6){width:5%;text-align:center}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(2),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(2){width:10%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(3),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(3){width:15%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(4),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(4){width:40%}.wprm-recipe-ingredients-form table.wprm-recipe-ingredients-container th:nth-child(5),.wprm-recipe-instructions-form table.wprm-recipe-ingredients-container th:nth-child(5){width:25%}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th,.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th{text-align:left}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(1),.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(4),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(1),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(4){width:5%;text-align:center}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(2),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(2){width:65%}.wprm-recipe-ingredients-form table.wprm-recipe-instructions-container th:nth-child(3),.wprm-recipe-instructions-form table.wprm-recipe-instructions-container th:nth-child(3){width:25%}.wprm-recipe-ingredients-form table .wprm-recipe-ingredients-placeholder,.wprm-recipe-ingredients-form table .wprm-recipe-instructions-placeholder,.wprm-recipe-instructions-form table .wprm-recipe-ingredients-placeholder,.wprm-recipe-instructions-form table .wprm-recipe-instructions-placeholder{display:none}.wprm-recipe-ingredients-form table td,.wprm-recipe-instructions-form table td{text-align:left;vertical-align:top}.wprm-recipe-ingredients-form table td:first-child,.wprm-recipe-ingredients-form table td:last-child,.wprm-recipe-instructions-form table td:first-child,.wprm-recipe-instructions-form table td:last-child{text-align:center;vertical-align:middle}.wprm-recipe-ingredients-form .ui-sortable-helper,.wprm-recipe-instructions-form .ui-sortable-helper{display:table}.wprm-recipe-ingredients-form .ui-sortable-helper .wprm-recipe-instruction-text,.wprm-recipe-instructions-form .ui-sortable-helper .wprm-recipe-instruction-text{min-width:200px}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-sort,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-sort{cursor:move}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-delete,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-delete{cursor:pointer}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-delete,.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-sort,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-delete,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-sort{color:#999;opacity:.5}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-delete:hover,.wprm-recipe-ingredients-form .wprm-recipe-ingredients-instructions-sort:hover,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-delete:hover,.wprm-recipe-instructions-form .wprm-recipe-ingredients-instructions-sort:hover{color:#444;opacity:1}.wprm-recipe-ingredients-form .wprm-recipe-ingredients-actions,.wprm-recipe-ingredients-form .wprm-recipe-instructions-actions,.wprm-recipe-instructions-form .wprm-recipe-ingredients-actions,.wprm-recipe-instructions-form .wprm-recipe-instructions-actions{margin:10px}.wprm-recipe-ingredients-form .wprm-recipe-image-preview,.wprm-recipe-instructions-form .wprm-recipe-image-preview{max-width:75px}.wprm-recipe-ingredients-form .wprm-recipe-image-preview img,.wprm-recipe-instructions-form .wprm-recipe-image-preview img{max-width:100%;height:auto}.wprm-shortcode-builder .wprm-shortcode-builder-container{margin-bottom:15px;vertical-align:top}.wprm-shortcode-builder .wprm-shortcode-builder-container-halfs{display:inline-block;width:50%}.wprm-shortcode-builder .wprm-shortcode-builder-container-thirds{display:inline-block;width:33.3%}.wprm-shortcode-builder label{display:block;font-weight:700;margin-bottom:5px}.wprm-shortcode-builder .wprm-shortcode-builder-helper{margin-left:5px;font-size:.8em;font-style:italic}.wprm-shortcode-builder input{margin:0;width:100%;max-width:250px;height:34px;line-height:34px}.wprm-shortcode-builder input.select2_wprm-search__field{height:18px;line-height:18px}.wprm-shortcode-builder select{width:250px}
assets/css/admin/modal/_container.scss CHANGED
@@ -16,6 +16,10 @@
16
  margin-bottom: 10px;
17
  }
18
 
 
 
 
 
19
  .select2_wprm-container {
20
  z-index: 100075;
21
 
16
  margin-bottom: 10px;
17
  }
18
 
19
+ .mce-floatpanel {
20
+ z-index: 100100 !important;
21
+ }
22
+
23
  .select2_wprm-container {
24
  z-index: 100075;
25
 
assets/css/public/_print.scss ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // main: public.scss
2
+
3
+ .wprm-print {
4
+ .wprm-recipe {
5
+ max-width: 750px;
6
+ margin: 0 auto;
7
+ }
8
+
9
+ .wprm-recipe-print,
10
+ .wprm-unit-conversion-container {
11
+ display: none;
12
+ }
13
+ }
assets/css/public/public.min.css CHANGED
@@ -1 +1 @@
1
- .comment-form-wprm-rating .wprm-rating-star{cursor:pointer}.wprm-rating-star svg{vertical-align:middle;width:16px;height:16px;margin:0}.wprm-rating-star.rated svg polygon{fill:#000}.wprm-recipe{overflow:auto;zoom:1}.wprm-recipe li,.wprm-recipe p{font-size:1em}.wprm-recipe li{list-style-position:outside}.wprm-recipe li:before{display:none}
1
+ .wprm-print .wprm-recipe-print,.wprm-print .wprm-unit-conversion-container,.wprm-recipe li:before{display:none}.comment-form-wprm-rating .wprm-rating-star{cursor:pointer}.wprm-rating-star svg{vertical-align:middle;width:16px;height:16px;margin:0}.wprm-rating-star.rated svg polygon{fill:#000}.wprm-print .wprm-recipe{max-width:750px;margin:0 auto}.wprm-recipe{overflow:auto;zoom:1}.wprm-recipe li,.wprm-recipe p{font-size:1em}.wprm-recipe li{list-style-position:outside}
assets/css/public/public.scss CHANGED
@@ -1,2 +1,3 @@
1
  @import "comments";
 
2
  @import "template_reset";
1
  @import "comments";
2
+ @import "print";
3
  @import "template_reset";
assets/icons/checkbox-checked.svg ADDED
@@ -0,0 +1 @@
 
1
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 16 16" xml:space="preserve" width="16" height="16"><g class="nc-icon-wrapper" fill="#444444"><polyline data-color="color-2" fill="none" stroke="#444444" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" points="4.5,7.5 7,10 12,5 "></polyline><path fill="none" stroke="#444444" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="M14.5,15.5h-13c-0.552,0-1-0.448-1-1v-13c0-0.552,0.448-1,1-1h13c0.552,0,1,0.448,1,1v13C15.5,15.052,15.052,15.5,14.5,15.5z"></path></g></svg>
assets/icons/checkbox-empty.svg ADDED
@@ -0,0 +1 @@
 
1
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 16 16" xml:space="preserve" width="16" height="16"><g class="nc-icon-wrapper" fill="#444444"><path fill="none" stroke="#444444" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" d="M14.5,15.5h-13c-0.552,0-1-0.448-1-1v-13c0-0.552,0.448-1,1-1h13c0.552,0,1,0.448,1,1v13C15.5,15.052,15.052,15.5,14.5,15.5z"></path></g></svg>
assets/js/public.js ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ var wprm = wprm || {};
2
+
3
+ if (wprm_public.settings.features_comment_ratings) {
4
+ jQuery(document).ready(function($) {
5
+ if (jQuery('.wprm-recipe-container').length > 0 || jQuery('body.wp-admin').length > 0) {
6
+ jQuery('.comment-form-wprm-rating').show();
7
+
8
+ var color = jQuery('.comment-form-wprm-rating').data('color');
9
+
10
+ jQuery(document).on('mouseenter', '.comment-form-wprm-rating .wprm-rating-star', function() {
11
+ jQuery(this).prevAll().andSelf().each(function() {
12
+ jQuery(this).find('polygon').css('fill', color);
13
+ });
14
+ jQuery(this).nextAll().each(function() {
15
+ jQuery(this).find('polygon').css('fill', 'none');
16
+ });
17
+ });
18
+ jQuery(document).on('mouseleave', '.comment-form-wprm-rating .wprm-rating-star', function() {
19
+ jQuery(this).siblings().andSelf().each(function() {
20
+ jQuery(this).find('polygon').css('fill', '');
21
+ });
22
+ });
23
+ jQuery(document).on('click', '.comment-form-wprm-rating .wprm-rating-star', function() {
24
+ var star = jQuery(this),
25
+ rating = star.data('rating'),
26
+ input = star.parents('.comment-form-wprm-rating').find('#wprm-comment-rating'),
27
+ current_rating = input.val();
28
+
29
+ if (current_rating == rating) {
30
+ input.val('');
31
+
32
+ jQuery(this).siblings('').andSelf().each(function() {
33
+ jQuery(this).removeClass('rated');
34
+ });
35
+ } else {
36
+ input.val(rating);
37
+
38
+ jQuery(this).prevAll().andSelf().each(function() {
39
+ jQuery(this).addClass('rated');
40
+ });
41
+ jQuery(this).nextAll().each(function() {
42
+ jQuery(this).removeClass('rated');
43
+ });
44
+ }
45
+ });
46
+ } else {
47
+ // Hide when no recipe is found.
48
+ jQuery('.comment-form-wprm-rating').hide();
49
+ }
50
+ });
51
+ }
52
+
53
+ var wprm = wprm || {};
54
+
55
+ wprm.print_recipe = function(recipe_id, servings, system) {
56
+ var print_window = window.open(wprm_public.home_url + 'wprm_print/' + recipe_id, '_blank');
57
+ print_window.onload = function() {
58
+ print_window.focus();
59
+ print_window.document.title = document.title;
60
+ print_window.history.pushState('', 'Print Recipe', location.href.replace(location.hash,""));
61
+ print_window.wprm.set_print_system(system);
62
+ print_window.wprm.set_print_servings(servings);
63
+ print_window.print();
64
+ };
65
+ };
66
+
67
+ jQuery(document).ready(function($) {
68
+ jQuery('.wprm-recipe-print').on('click', function(e) {
69
+ e.preventDefault();
70
+
71
+ var recipe = jQuery(this).parents('.wprm-recipe-container'),
72
+ servings = parseInt(recipe.find('.wprm-recipe-servings').data('servings')),
73
+ system = 1,
74
+ recipe_id = recipe.data('recipe-id');
75
+
76
+ if('undefined' !== typeof wprmpuc) {
77
+ system = wprmpuc.get_active_system(recipe);
78
+ }
79
+
80
+ wprm.print_recipe(recipe_id, servings, system);
81
+ });
82
+ jQuery('.wprm-print-recipe-shortcode').on('click', function(e) {
83
+ e.preventDefault();
84
+
85
+ var recipe_id = jQuery(this).data('recipe-id');
86
+ wprm.print_recipe(recipe_id, false, 1);
87
+ });
88
+ });
assets/js/public.min.js ADDED
@@ -0,0 +1 @@
 
1
+ var wprm=wprm||{};wprm_public.settings.features_comment_ratings&&jQuery(document).ready(function(e){if(jQuery(".wprm-recipe-container").length>0||jQuery("body.wp-admin").length>0){jQuery(".comment-form-wprm-rating").show();var r=jQuery(".comment-form-wprm-rating").data("color");jQuery(document).on("mouseenter",".comment-form-wprm-rating .wprm-rating-star",function(){jQuery(this).prevAll().andSelf().each(function(){jQuery(this).find("polygon").css("fill",r)}),jQuery(this).nextAll().each(function(){jQuery(this).find("polygon").css("fill","none")})}),jQuery(document).on("mouseleave",".comment-form-wprm-rating .wprm-rating-star",function(){jQuery(this).siblings().andSelf().each(function(){jQuery(this).find("polygon").css("fill","")})}),jQuery(document).on("click",".comment-form-wprm-rating .wprm-rating-star",function(){var e=jQuery(this),r=e.data("rating"),n=e.parents(".comment-form-wprm-rating").find("#wprm-comment-rating");n.val()==r?(n.val(""),jQuery(this).siblings("").andSelf().each(function(){jQuery(this).removeClass("rated")})):(n.val(r),jQuery(this).prevAll().andSelf().each(function(){jQuery(this).addClass("rated")}),jQuery(this).nextAll().each(function(){jQuery(this).removeClass("rated")}))})}else jQuery(".comment-form-wprm-rating").hide()}),(wprm=wprm||{}).print_recipe=function(e,r,n){var t=window.open(wprm_public.home_url+"wprm_print/"+e,"_blank");t.onload=function(){t.focus(),t.document.title=document.title,t.history.pushState("","Print Recipe",location.href.replace(location.hash,"")),t.wprm.set_print_system(n),t.wprm.set_print_servings(r),t.print()}},jQuery(document).ready(function(e){jQuery(".wprm-recipe-print").on("click",function(e){e.preventDefault();var r=jQuery(this).parents(".wprm-recipe-container"),n=parseInt(r.find(".wprm-recipe-servings").data("servings")),t=1,i=r.data("recipe-id");"undefined"!=typeof wprmpuc&&(t=wprmpuc.get_active_system(r)),wprm.print_recipe(i,n,t)}),jQuery(".wprm-print-recipe-shortcode").on("click",function(e){e.preventDefault();var r=jQuery(this).data("recipe-id");wprm.print_recipe(r,!1,1)})});
assets/js/public/comment-rating.js CHANGED
@@ -1,49 +1,51 @@
1
  var wprm = wprm || {};
2
 
3
- jQuery(document).ready(function($) {
 
4
  if (jQuery('.wprm-recipe-container').length > 0 || jQuery('body.wp-admin').length > 0) {
5
- jQuery('.comment-form-wprm-rating').show();
6
 
7
- var color = jQuery('.comment-form-wprm-rating').data('color');
8
 
9
- jQuery(document).on('mouseenter', '.comment-form-wprm-rating .wprm-rating-star', function() {
10
- jQuery(this).prevAll().andSelf().each(function() {
11
- jQuery(this).find('polygon').css('fill', color);
12
- });
13
- jQuery(this).nextAll().each(function() {
14
- jQuery(this).find('polygon').css('fill', 'none');
15
- });
16
  });
17
- jQuery(document).on('mouseleave', '.comment-form-wprm-rating .wprm-rating-star', function() {
18
- jQuery(this).siblings().andSelf().each(function() {
19
- jQuery(this).find('polygon').css('fill', '');
20
- });
21
  });
22
- jQuery(document).on('click', '.comment-form-wprm-rating .wprm-rating-star', function() {
23
- var star = jQuery(this),
24
- rating = star.data('rating'),
25
- input = star.parents('.comment-form-wprm-rating').find('#wprm-comment-rating'),
26
- current_rating = input.val();
 
 
 
 
 
 
27
 
28
- if (current_rating == rating) {
29
- input.val('');
30
 
31
- jQuery(this).siblings('').andSelf().each(function() {
32
- jQuery(this).removeClass('rated');
33
- });
34
- } else {
35
- input.val(rating);
36
 
37
- jQuery(this).prevAll().andSelf().each(function() {
38
- jQuery(this).addClass('rated');
39
- });
40
- jQuery(this).nextAll().each(function() {
41
- jQuery(this).removeClass('rated');
42
- });
43
- }
44
- });
45
  } else {
46
  // Hide when no recipe is found.
47
  jQuery('.comment-form-wprm-rating').hide();
48
  }
49
- });
 
1
  var wprm = wprm || {};
2
 
3
+ if (wprm_public.settings.features_comment_ratings) {
4
+ jQuery(document).ready(function($) {
5
  if (jQuery('.wprm-recipe-container').length > 0 || jQuery('body.wp-admin').length > 0) {
6
+ jQuery('.comment-form-wprm-rating').show();
7
 
8
+ var color = jQuery('.comment-form-wprm-rating').data('color');
9
 
10
+ jQuery(document).on('mouseenter', '.comment-form-wprm-rating .wprm-rating-star', function() {
11
+ jQuery(this).prevAll().andSelf().each(function() {
12
+ jQuery(this).find('polygon').css('fill', color);
 
 
 
 
13
  });
14
+ jQuery(this).nextAll().each(function() {
15
+ jQuery(this).find('polygon').css('fill', 'none');
 
 
16
  });
17
+ });
18
+ jQuery(document).on('mouseleave', '.comment-form-wprm-rating .wprm-rating-star', function() {
19
+ jQuery(this).siblings().andSelf().each(function() {
20
+ jQuery(this).find('polygon').css('fill', '');
21
+ });
22
+ });
23
+ jQuery(document).on('click', '.comment-form-wprm-rating .wprm-rating-star', function() {
24
+ var star = jQuery(this),
25
+ rating = star.data('rating'),
26
+ input = star.parents('.comment-form-wprm-rating').find('#wprm-comment-rating'),
27
+ current_rating = input.val();
28
 
29
+ if (current_rating == rating) {
30
+ input.val('');
31
 
32
+ jQuery(this).siblings('').andSelf().each(function() {
33
+ jQuery(this).removeClass('rated');
34
+ });
35
+ } else {
36
+ input.val(rating);
37
 
38
+ jQuery(this).prevAll().andSelf().each(function() {
39
+ jQuery(this).addClass('rated');
40
+ });
41
+ jQuery(this).nextAll().each(function() {
42
+ jQuery(this).removeClass('rated');
43
+ });
44
+ }
45
+ });
46
  } else {
47
  // Hide when no recipe is found.
48
  jQuery('.comment-form-wprm-rating').hide();
49
  }
50
+ });
51
+ }
includes/admin/import/class-wprm-import-wpultimaterecipe.php CHANGED
@@ -308,6 +308,13 @@ class WPRM_Import_Wpultimaterecipe extends WPRM_Import {
308
  exit();
309
  }
310
 
 
 
 
 
 
 
 
311
  // If import type is "hide" we count on the fallback shortcode.
312
  if ( 'convert' === $import_type ) {
313
  $post = get_post( $id );
308
  exit();
309
  }
310
 
311
+ // Migrate user ratings.
312
+ $user_ratings = get_post_meta( $id, 'recipe_user_ratings' );
313
+
314
+ foreach ( $user_ratings as $user_rating ) {
315
+ add_post_meta( $wprm_id, 'wprm_user_ratings', $user_rating );
316
+ }
317
+
318
  // If import type is "hide" we count on the fallback shortcode.
319
  if ( 'convert' === $import_type ) {
320
  $post = get_post( $id );
includes/class-wp-recipe-maker.php CHANGED
@@ -31,8 +31,8 @@ class WP_Recipe_Maker {
31
  * @since 1.0.0
32
  */
33
  private function define_constants() {
34
- define( 'WPRM_VERSION', '1.21.0' );
35
- define( 'WPRM_PREMIUM_VERSION_REQUIRED', '1.3.0' );
36
  define( 'WPRM_POST_TYPE', 'wprm_recipe' );
37
  define( 'WPRM_DIR', plugin_dir_path( dirname( __FILE__ ) ) );
38
  define( 'WPRM_URL', plugin_dir_url( dirname( __FILE__ ) ) );
@@ -74,6 +74,7 @@ class WP_Recipe_Maker {
74
  // Public.
75
  require_once( WPRM_DIR . 'includes/public/class-wprm-addons.php' );
76
  require_once( WPRM_DIR . 'includes/public/class-wprm-api.php' );
 
77
 
78
  if ( WPRM_Settings::get( 'features_comment_ratings' ) ) {
79
  require_once( WPRM_DIR . 'includes/public/class-wprm-comment-rating.php' );
@@ -83,6 +84,7 @@ class WP_Recipe_Maker {
83
  require_once( WPRM_DIR . 'includes/public/class-wprm-metadata.php' );
84
  require_once( WPRM_DIR . 'includes/public/class-wprm-post-type.php' );
85
  require_once( WPRM_DIR . 'includes/public/class-wprm-print.php' );
 
86
  require_once( WPRM_DIR . 'includes/public/class-wprm-recipe-manager.php' );
87
  require_once( WPRM_DIR . 'includes/public/class-wprm-recipe.php' );
88
  require_once( WPRM_DIR . 'includes/public/class-wprm-shortcode.php' );
31
  * @since 1.0.0
32
  */
33
  private function define_constants() {
34
+ define( 'WPRM_VERSION', '1.22.0' );
35
+ define( 'WPRM_PREMIUM_VERSION_REQUIRED', '1.6.0' );
36
  define( 'WPRM_POST_TYPE', 'wprm_recipe' );
37
  define( 'WPRM_DIR', plugin_dir_path( dirname( __FILE__ ) ) );
38
  define( 'WPRM_URL', plugin_dir_url( dirname( __FILE__ ) ) );
74
  // Public.
75
  require_once( WPRM_DIR . 'includes/public/class-wprm-addons.php' );
76
  require_once( WPRM_DIR . 'includes/public/class-wprm-api.php' );
77
+ require_once( WPRM_DIR . 'includes/public/class-wprm-assets.php' );
78
 
79
  if ( WPRM_Settings::get( 'features_comment_ratings' ) ) {
80
  require_once( WPRM_DIR . 'includes/public/class-wprm-comment-rating.php' );
84
  require_once( WPRM_DIR . 'includes/public/class-wprm-metadata.php' );
85
  require_once( WPRM_DIR . 'includes/public/class-wprm-post-type.php' );
86
  require_once( WPRM_DIR . 'includes/public/class-wprm-print.php' );
87
+ require_once( WPRM_DIR . 'includes/public/class-wprm-rating.php' );
88
  require_once( WPRM_DIR . 'includes/public/class-wprm-recipe-manager.php' );
89
  require_once( WPRM_DIR . 'includes/public/class-wprm-recipe.php' );
90
  require_once( WPRM_DIR . 'includes/public/class-wprm-shortcode.php' );
includes/public/class-wprm-assets.php ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Responsible for loading the WPRM assets.
4
+ *
5
+ * @link http://bootstrapped.ventures
6
+ * @since 1.22.0
7
+ *
8
+ * @package WP_Recipe_Maker
9
+ * @subpackage WP_Recipe_Maker/includes/public
10
+ */
11
+
12
+ /**
13
+ * Responsible for loading the WPRM assets.
14
+ *
15
+ * @since 1.22.0
16
+ * @package WP_Recipe_Maker
17
+ * @subpackage WP_Recipe_Maker/includes/public
18
+ * @author Brecht Vandersmissen <brecht@bootstrapped.ventures>
19
+ */
20
+ class WPRM_Assets {
21
+
22
+ /**
23
+ * Register actions and filters.
24
+ *
25
+ * @since 1.22.0
26
+ */
27
+ public static function init() {
28
+ add_action( 'wp_enqueue_scripts', array( __CLASS__, 'enqueue' ), 1 );
29
+ }
30
+
31
+ /**
32
+ * Enqueue stylesheets and scripts.
33
+ *
34
+ * @since 1.22.0
35
+ */
36
+ public static function enqueue() {
37
+ wp_enqueue_style( 'wprm-public', WPRM_URL . 'assets/css/public/public.min.css', array(), WPRM_VERSION, 'all' );
38
+ wp_enqueue_script( 'wprm-public', WPRM_URL . 'assets/js/public.js', array( 'jquery' ), WPRM_VERSION, true );
39
+
40
+ wp_localize_script( 'wprm-public', 'wprm_public', array(
41
+ 'settings' => array(
42
+ 'features_comment_ratings' => WPRM_Settings::get( 'features_comment_ratings' ),
43
+ ),
44
+ 'home_url' => home_url( '/' ),
45
+ 'ajax_url' => admin_url( 'admin-ajax.php' ),
46
+ 'nonce' => wp_create_nonce( 'wprm' ),
47
+ ));
48
+ }
49
+ }
50
+
51
+ WPRM_Assets::init();
includes/public/class-wprm-comment-rating.php CHANGED
@@ -36,27 +36,23 @@ class WPRM_Comment_Rating {
36
  add_action( 'comment_post', array( __CLASS__, 'save_comment_rating' ) );
37
  add_action( 'edit_comment', array( __CLASS__, 'save_admin_comment_rating' ) );
38
 
39
- add_action( 'wp_enqueue_scripts', array( __CLASS__, 'enqueue' ) );
40
  add_action( 'admin_enqueue_scripts', array( __CLASS__, 'enqueue_admin' ) );
41
  }
42
 
43
- /**
44
- * Enqueue stylesheets and scripts.
45
- *
46
- * @since 1.1.0
47
- */
48
- public static function enqueue() {
49
- wp_enqueue_script( 'wprm-comment-rating', WPRM_URL . 'assets/js/public/comment-rating.js', array( 'jquery' ), WPRM_VERSION, true );
50
- }
51
-
52
  /**
53
  * Enqueue stylesheets and scripts for admin.
54
  *
55
  * @since 1.1.0
56
  */
57
  public static function enqueue_admin() {
58
- wp_enqueue_script( 'wprm-comment-rating', WPRM_URL . 'assets/js/public/comment-rating.js', array( 'jquery' ), WPRM_VERSION, true );
59
  wp_enqueue_style( 'wprm-comments', WPRM_URL . 'assets/css/admin/comments.min.css', array(), WPRM_VERSION, 'all' );
 
 
 
 
 
 
 
60
  }
61
 
62
  /**
36
  add_action( 'comment_post', array( __CLASS__, 'save_comment_rating' ) );
37
  add_action( 'edit_comment', array( __CLASS__, 'save_admin_comment_rating' ) );
38
 
 
39
  add_action( 'admin_enqueue_scripts', array( __CLASS__, 'enqueue_admin' ) );
40
  }
41
 
 
 
 
 
 
 
 
 
 
42
  /**
43
  * Enqueue stylesheets and scripts for admin.
44
  *
45
  * @since 1.1.0
46
  */
47
  public static function enqueue_admin() {
 
48
  wp_enqueue_style( 'wprm-comments', WPRM_URL . 'assets/css/admin/comments.min.css', array(), WPRM_VERSION, 'all' );
49
+ wp_enqueue_script( 'wprm-comment-rating', WPRM_URL . 'assets/js/public/comment-rating.js', array( 'jquery' ), WPRM_VERSION, true );
50
+
51
+ wp_localize_script( 'wprm-comment-rating', 'wprm_public', array(
52
+ 'settings' => array(
53
+ 'features_comment_ratings' => WPRM_Settings::get( 'features_comment_ratings' ),
54
+ ),
55
+ ));
56
  }
57
 
58
  /**
includes/public/class-wprm-print.php CHANGED
@@ -29,26 +29,9 @@ class WPRM_Print {
29
  add_action( 'wp_ajax_wprm_print_recipe', array( __CLASS__, 'ajax_print_recipe' ) );
30
  add_action( 'wp_ajax_nopriv_wprm_print_recipe', array( __CLASS__, 'ajax_print_recipe' ) );
31
 
32
- add_action( 'wp_enqueue_scripts', array( __CLASS__, 'enqueue' ) );
33
-
34
  add_filter( 'wprm_get_template', array( __CLASS__, 'print_credit' ), 10, 3 );
35
  }
36
 
37
- /**
38
- * Enqueue stylesheets and scripts.
39
- *
40
- * @since 1.0.0
41
- */
42
- public static function enqueue() {
43
- wp_enqueue_script( 'wprm-print', WPRM_URL . 'assets/js/public/print.js', array( 'jquery' ), WPRM_VERSION, true );
44
-
45
- wp_localize_script( 'wprm-print', 'wprm_public', array(
46
- 'home_url' => home_url( '/' ),
47
- 'ajax_url' => admin_url( 'admin-ajax.php' ),
48
- 'nonce' => wp_create_nonce( 'wprm' ),
49
- ));
50
- }
51
-
52
  /**
53
  * Check if someone is trying to reach the print page.
54
  *
@@ -63,17 +46,28 @@ class WPRM_Print {
63
  $styles = WPRM_Template_Manager::get_template_styles( $recipe, 'print' );
64
  $styles .= '<style>body { position: relative; padding-bottom: 30px; } #wprm-print-footer { position: absolute; bottom: 0; left: 0; right: 0; text-align: center; font-size: 0.8em; }</style>';
65
 
 
 
 
 
 
 
 
 
 
 
 
 
 
66
  if ( WPRM_Settings::get( 'print_css' ) ) {
67
  $styles .= '<style>' . WPRM_Settings::get( 'print_css' ) . '</style>';
68
  }
69
 
70
- if ( WPRM_Addons::is_active( 'premium' ) ) {
71
- $styles .= '<link rel="stylesheet" type="text/css" href="' . WPRMP_URL . 'assets/css/public/public.min.css"/>';
72
- }
73
 
74
  $scripts = '';
75
  if ( WPRM_Addons::is_active( 'premium' ) ) {
76
  $scripts .= '<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>';
 
77
  $scripts .= '<script src="' . WPRMP_URL . 'assets/js/public/servings-changer.js"></script>';
78
 
79
  if ( WPRM_Addons::is_active( 'unit-conversion' ) ) {
@@ -98,7 +92,11 @@ class WPRM_Print {
98
  header( 'HTTP/1.1 200 OK' );
99
 
100
  $charset = get_bloginfo( 'charset' );
101
- $print_html = '<html><head><meta http-equiv="Content-Type" content="text/html; charset=' . $charset . '" /><meta name="robots" content="noindex">' . $styles . $scripts . '</head><body class="wprm-print" data-recipe="' . esc_attr( $recipe_id ) . '">';
 
 
 
 
102
  $print_html .= WPRM_Template_Manager::get_template( $recipe, 'print' );
103
  $print_html .= '</body></html>';
104
  echo $print_html;
29
  add_action( 'wp_ajax_wprm_print_recipe', array( __CLASS__, 'ajax_print_recipe' ) );
30
  add_action( 'wp_ajax_nopriv_wprm_print_recipe', array( __CLASS__, 'ajax_print_recipe' ) );
31
 
 
 
32
  add_filter( 'wprm_get_template', array( __CLASS__, 'print_credit' ), 10, 3 );
33
  }
34
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
  /**
36
  * Check if someone is trying to reach the print page.
37
  *
46
  $styles = WPRM_Template_Manager::get_template_styles( $recipe, 'print' );
47
  $styles .= '<style>body { position: relative; padding-bottom: 30px; } #wprm-print-footer { position: absolute; bottom: 0; left: 0; right: 0; text-align: center; font-size: 0.8em; }</style>';
48
 
49
+ $styles .= '<link rel="stylesheet" type="text/css" href="' . WPRM_URL . 'assets/css/public/public.min.css"/>';
50
+ if ( WPRM_Addons::is_active( 'premium' ) ) {
51
+ $styles .= '<link rel="stylesheet" type="text/css" href="' . WPRMP_URL . 'assets/css/public/public.min.css"/>';
52
+ }
53
+
54
+ // Custom Style.
55
+ ob_start();
56
+ WPRM_Template_Manager::custom_css( 'print' );
57
+ $custom_css = ob_get_contents();
58
+ ob_end_clean();
59
+
60
+ $styles .= $custom_css;
61
+
62
  if ( WPRM_Settings::get( 'print_css' ) ) {
63
  $styles .= '<style>' . WPRM_Settings::get( 'print_css' ) . '</style>';
64
  }
65
 
 
 
 
66
 
67
  $scripts = '';
68
  if ( WPRM_Addons::is_active( 'premium' ) ) {
69
  $scripts .= '<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>';
70
+ $scripts .= '<script>var wprmp_public = { settings : { features_adjustable_servings : true } };</script>';
71
  $scripts .= '<script src="' . WPRMP_URL . 'assets/js/public/servings-changer.js"></script>';
72
 
73
  if ( WPRM_Addons::is_active( 'unit-conversion' ) ) {
92
  header( 'HTTP/1.1 200 OK' );
93
 
94
  $charset = get_bloginfo( 'charset' );
95
+
96
+ $dir = is_rtl() ? 'rtl' : 'ltr';
97
+ $rtl_class = is_rtl() ? ' rtl' : '';
98
+
99
+ $print_html = '<html dir="' . $dir . '"><head><meta http-equiv="Content-Type" content="text/html; charset=' . $charset . '" /><meta name="robots" content="noindex">' . $styles . $scripts . '</head><body class="wprm-print' . $rtl_class . '" data-recipe="' . esc_attr( $recipe_id ) . '">';
100
  $print_html .= WPRM_Template_Manager::get_template( $recipe, 'print' );
101
  $print_html .= '</body></html>';
102
  echo $print_html;
includes/public/class-wprm-rating.php ADDED
@@ -0,0 +1,118 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Calculate and store the recipe rating.
4
+ *
5
+ * @link http://bootstrapped.ventures
6
+ * @since 1.22.0
7
+ *
8
+ * @package WP_Recipe_Maker
9
+ * @subpackage WP_Recipe_Maker/includes/public
10
+ */
11
+
12
+ /**
13
+ * Calculate and store the recipe rating.
14
+ *
15
+ * @since 1.22.0
16
+ * @package WP_Recipe_Maker
17
+ * @subpackage WP_Recipe_Maker/includes/public
18
+ * @author Brecht Vandersmissen <brecht@bootstrapped.ventures>
19
+ */
20
+ class WPRM_Rating {
21
+
22
+ /**
23
+ * Register actions and filters.
24
+ *
25
+ * @since 1.22.0
26
+ */
27
+ public static function init() {
28
+ add_action( 'comment_post', array( __CLASS__, 'check_for_comment_rating' ), 11 );
29
+ add_action( 'edit_comment', array( __CLASS__, 'check_for_comment_rating' ), 11 );
30
+ add_action( 'transition_comment_status', array( __CLASS__, 'check_for_comment_rating_on_transition' ), 10, 3 );
31
+ }
32
+
33
+ /**
34
+ * Check if comment is getting approved.
35
+ *
36
+ * @since 1.22.0
37
+ * @param mixed $new_status New status of the comment.
38
+ * @param mixed $old_status Old status of the comment.
39
+ * @param mixed $comment Comment object.
40
+ */
41
+ public static function check_for_comment_rating_on_transition( $new_status, $old_status, $comment ) {
42
+ self::check_for_comment_rating( $comment->comment_ID );
43
+ }
44
+
45
+ /**
46
+ * Check if there is a comment rating.
47
+ *
48
+ * @since 1.22.0
49
+ * @param mixed $comment_id ID of the comment we need to check for rating.
50
+ */
51
+ public static function check_for_comment_rating( $comment_id ) {
52
+ $comment_rating = intval( get_comment_meta( $comment_id, 'wprm-comment-rating', true ) );
53
+
54
+ if ( $comment_rating ) {
55
+ $comment = get_comment( $comment_id );
56
+ $post_id = $comment->comment_post_ID;
57
+ $post_content = get_post_field( 'post_content', $post_id );
58
+
59
+ $recipe_ids = WPRM_Recipe_Manager::get_recipe_ids_from_content( $post_content );
60
+
61
+ if ( count( $recipe_ids ) > 0 ) {
62
+ foreach ( $recipe_ids as $recipe_id ) {
63
+ self::update_recipe_rating( $recipe_id );
64
+ }
65
+ }
66
+ }
67
+ }
68
+
69
+ /**
70
+ * Update the rating for a specific recipe.
71
+ *
72
+ * @since 1.22.0
73
+ * @param int $recipe_id Recipe ID to to update the rating for.
74
+ */
75
+ public static function update_recipe_rating( $recipe_id ) {
76
+ $recipe = WPRM_Recipe_Manager::get_recipe( $recipe_id );
77
+ $rating = array(
78
+ 'count' => 0,
79
+ 'total' => 0,
80
+ 'average' => 0,
81
+ );
82
+
83
+ // Get comment ratings.
84
+ $comments = get_approved_comments( $recipe->parent_post_id() );
85
+
86
+ foreach ( $comments as $comment ) {
87
+ $comment_rating = intval( get_comment_meta( $comment->comment_ID, 'wprm-comment-rating', true ) );
88
+ if ( $comment_rating ) {
89
+ $rating['count']++;
90
+ $rating['total'] += $comment_rating;
91
+ }
92
+ }
93
+
94
+ // Get user ratings.
95
+ $user_ratings = get_post_meta( $recipe_id, 'wprm_user_ratings' );
96
+
97
+ foreach ( $user_ratings as $user_rating ) {
98
+ $rating['count']++;
99
+ $rating['total'] += $user_rating['rating'];
100
+ }
101
+
102
+ if ( $rating['count'] > 0 ) {
103
+ $rating['average'] = ceil( $rating['total'] / $rating['count'] * 100 ) / 100;
104
+ }
105
+
106
+ // Update recipe rating and average (to sort by).
107
+ update_post_meta( $recipe_id, 'wprm_rating', $rating );
108
+ update_post_meta( $recipe_id, 'wprm_rating_average', $rating['average'] );
109
+
110
+ // Update parent post with rating data (TODO account for multiple recipes in a post).
111
+ update_post_meta( $recipe->parent_post_id(), 'wprm_rating', $rating );
112
+ update_post_meta( $recipe->parent_post_id(), 'wprm_rating_average', $rating['average'] );
113
+
114
+ return $rating;
115
+ }
116
+ }
117
+
118
+ WPRM_Rating::init();
includes/public/class-wprm-recipe.php CHANGED
@@ -115,6 +115,22 @@ class WPRM_Recipe {
115
  return $default;
116
  }
117
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
118
  /**
119
  * Callback for regex to fix serialize issues.
120
  *
@@ -309,14 +325,7 @@ class WPRM_Recipe {
309
  * @since 1.0.0
310
  */
311
  public function nutrition() {
312
- $serialized = $this->meta( 'wprm_nutrition', array() );
313
- $nutrition = @maybe_unserialize( $serialized );
314
-
315
- if ( false === $nutrition ) {
316
- $nutrition = unserialize( preg_replace_callback( '!s:(\d+):"(.*?)";!', array( $this, 'regex_replace_serialize' ), $serialized ) );
317
- }
318
-
319
- return $nutrition;
320
  }
321
 
322
  /**
@@ -335,25 +344,16 @@ class WPRM_Recipe {
335
  * @since 1.1.0
336
  */
337
  public function rating() {
338
- $rating = array(
339
- 'count' => 0,
340
- 'total' => 0,
341
- 'average' => 0,
342
- );
343
-
344
- // TODO cache the recipe rating.
345
- $comments = get_approved_comments( $this->parent_post_id() );
346
-
347
- foreach ( $comments as $comment ) {
348
- $comment_rating = intval( get_comment_meta( $comment->comment_ID, 'wprm-comment-rating', true ) );
349
- if ( $comment_rating ) {
350
- $rating['count']++;
351
- $rating['total'] += $comment_rating;
352
- }
353
  }
354
 
355
- if ( $rating['count'] > 0 ) {
356
- $rating['average'] = ceil( $rating['total'] / $rating['count'] * 100 ) / 100;
 
357
  }
358
 
359
  return $rating;
@@ -482,14 +482,7 @@ class WPRM_Recipe {
482
  * @since 1.0.0
483
  */
484
  public function ingredients() {
485
- $serialized = $this->meta( 'wprm_ingredients', array() );
486
- $ingredients = @maybe_unserialize( $serialized );
487
-
488
- if ( false === $ingredients ) {
489
- $ingredients = unserialize( preg_replace_callback( '!s:(\d+):"(.*?)";!', array( $this, 'regex_replace_serialize' ), $serialized ) );
490
- }
491
-
492
- return $ingredients;
493
  }
494
 
495
  /**
@@ -523,14 +516,7 @@ class WPRM_Recipe {
523
  * @since 1.0.0
524
  */
525
  public function instructions() {
526
- $serialized = $this->meta( 'wprm_instructions', array() );
527
- $instructions = @maybe_unserialize( $serialized );
528
-
529
- if ( false === $instructions ) {
530
- $instructions = unserialize( preg_replace_callback( '!s:(\d+):"(.*?)";!', array( $this, 'regex_replace_serialize' ), $serialized ) );
531
- }
532
-
533
- return $instructions;
534
  }
535
 
536
  /**
115
  return $default;
116
  }
117
 
118
+ /**
119
+ * Try to unserialize as best as possible.
120
+ *
121
+ * @since 1.22.0
122
+ * @param mixed $maybe_serialized Potentially serialized data.
123
+ */
124
+ public function unserialize( $maybe_serialized ) {
125
+ $unserialized = @maybe_unserialize( $maybe_serialized );
126
+
127
+ if ( false === $unserialized ) {
128
+ $unserialized = unserialize( preg_replace_callback( '!s:(\d+):"(.*?)";!', array( $this, 'regex_replace_serialize' ), $maybe_serialized ) );
129
+ }
130
+
131
+ return $unserialized;
132
+ }
133
+
134
  /**
135
  * Callback for regex to fix serialize issues.
136
  *
325
  * @since 1.0.0
326
  */
327
  public function nutrition() {
328
+ return self::unserialize( $this->meta( 'wprm_nutrition', array() ) );
 
 
 
 
 
 
 
329
  }
330
 
331
  /**
344
  * @since 1.1.0
345
  */
346
  public function rating() {
347
+ $rating = self::unserialize( $this->meta( 'wprm_rating', array() ) );
348
+
349
+ // Recalculate if rating has not been set yet.
350
+ if ( empty( $rating ) ) {
351
+ $rating = WPRM_Rating::update_recipe_rating( $this->id() );
 
 
 
 
 
 
 
 
 
 
352
  }
353
 
354
+ // Attach current user rating.
355
+ if ( WPRM_Addons::is_active( 'premium' ) ) {
356
+ $rating['user'] = WPRMP_User_Rating::get_user_rating_for( $this->id() );
357
  }
358
 
359
  return $rating;
482
  * @since 1.0.0
483
  */
484
  public function ingredients() {
485
+ return self::unserialize( $this->meta( 'wprm_ingredients', array() ) );
 
 
 
 
 
 
 
486
  }
487
 
488
  /**
516
  * @since 1.0.0
517
  */
518
  public function instructions() {
519
+ return self::unserialize( $this->meta( 'wprm_instructions', array() ) );
 
 
 
 
 
 
 
520
  }
521
 
522
  /**
includes/public/class-wprm-settings.php CHANGED
@@ -68,6 +68,7 @@ class WPRM_Settings {
68
  'features_custom_style' => true,
69
  // Features Premium.
70
  'features_adjustable_servings' => true,
 
71
  // Advanced.
72
  'recipe_css' => '',
73
  'print_css' => '',
@@ -334,6 +335,7 @@ class WPRM_Settings {
334
  $features_comment_ratings = isset( $_POST['features_comment_ratings'] ) && sanitize_key( $_POST['features_comment_ratings'] ) ? true : false; // Input var okay.
335
  $features_custom_style = isset( $_POST['features_custom_style'] ) && sanitize_key( $_POST['features_custom_style'] ) ? true : false; // Input var okay.
336
  $features_adjustable_servings = isset( $_POST['features_adjustable_servings'] ) && sanitize_key( $_POST['features_adjustable_servings'] ) ? true : false; // Input var okay.
 
337
 
338
  $settings = array();
339
 
@@ -342,6 +344,7 @@ class WPRM_Settings {
342
  $settings['features_comment_ratings'] = $features_comment_ratings;
343
  $settings['features_custom_style'] = $features_custom_style;
344
  $settings['features_adjustable_servings'] = $features_adjustable_servings;
 
345
 
346
  self::update_settings( $settings );
347
  }
68
  'features_custom_style' => true,
69
  // Features Premium.
70
  'features_adjustable_servings' => true,
71
+ 'features_user_ratings' => true,
72
  // Advanced.
73
  'recipe_css' => '',
74
  'print_css' => '',
335
  $features_comment_ratings = isset( $_POST['features_comment_ratings'] ) && sanitize_key( $_POST['features_comment_ratings'] ) ? true : false; // Input var okay.
336
  $features_custom_style = isset( $_POST['features_custom_style'] ) && sanitize_key( $_POST['features_custom_style'] ) ? true : false; // Input var okay.
337
  $features_adjustable_servings = isset( $_POST['features_adjustable_servings'] ) && sanitize_key( $_POST['features_adjustable_servings'] ) ? true : false; // Input var okay.
338
+ $features_user_ratings = isset( $_POST['features_user_ratings'] ) && sanitize_key( $_POST['features_user_ratings'] ) ? true : false; // Input var okay.
339
 
340
  $settings = array();
341
 
344
  $settings['features_comment_ratings'] = $features_comment_ratings;
345
  $settings['features_custom_style'] = $features_custom_style;
346
  $settings['features_adjustable_servings'] = $features_adjustable_servings;
347
+ $settings['features_user_ratings'] = $features_user_ratings;
348
 
349
  self::update_settings( $settings );
350
  }
includes/public/class-wprm-shortcode.php CHANGED
@@ -36,16 +36,6 @@ class WPRM_Shortcode {
36
  add_filter( 'content_edit_pre', array( __CLASS__, 'replace_bigoven_shortcode' ) );
37
 
38
  add_action( 'init', array( __CLASS__, 'fallback_shortcodes' ), 11 );
39
- add_action( 'wp_enqueue_scripts', array( __CLASS__, 'enqueue' ) );
40
- }
41
-
42
- /**
43
- * Enqueue stylesheets and scripts.
44
- *
45
- * @since 1.1.0
46
- */
47
- public static function enqueue() {
48
- wp_enqueue_style( 'wprm-public', WPRM_URL . 'assets/css/public/public.min.css', array(), WPRM_VERSION, 'all' );
49
  }
50
 
51
  /**
36
  add_filter( 'content_edit_pre', array( __CLASS__, 'replace_bigoven_shortcode' ) );
37
 
38
  add_action( 'init', array( __CLASS__, 'fallback_shortcodes' ), 11 );
 
 
 
 
 
 
 
 
 
 
39
  }
40
 
41
  /**
includes/public/class-wprm-template-helper.php CHANGED
@@ -217,27 +217,40 @@ class WPRM_Template_Helper {
217
  * @param boolean $show_details Wether to display the rating details.
218
  */
219
  public static function rating_stars( $rating, $show_details = false ) {
 
220
  $rating_value = ceil( $rating['average'] );
221
 
222
- $output = '<div class="wprm-recipe-rating">';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
223
  for ( $i = 1; $i <= 5; $i++ ) {
224
- $output .= '<span class="wprm-rating-star">';
225
- if ( $i <= $rating_value ) {
226
- ob_start();
227
- include( WPRM_DIR . 'assets/icons/star-full.svg' );
228
- $output .= ob_get_contents();
229
- ob_end_clean();
230
- } else {
231
- ob_start();
232
- include( WPRM_DIR . 'assets/icons/star-empty.svg' );
233
- $output .= ob_get_contents();
234
- ob_end_clean();
235
- }
236
  $output .= '</span>';
237
  }
238
 
239
  if ( $show_details ) {
240
- $output .= '<div class="wprm-recipe-rating-details" itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating"><span itemprop="ratingValue">' . $rating['average'] . '</span> ' . __( 'from', 'wp-recipe-maker' ) . ' <span itemprop="ratingCount">' . $rating['count'] . '</span> ' . _n( 'vote', 'votes', $rating['count'], 'wp-recipe-maker' ) . '</div>';
241
  } else {
242
  $output .= '<div class="wprm-recipe-rating-details-meta" itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating">';
243
  $output .= '<meta itemprop="ratingValue" content="' . $rating['average'] . '">';
217
  * @param boolean $show_details Wether to display the rating details.
218
  */
219
  public static function rating_stars( $rating, $show_details = false ) {
220
+ $user_ratings = WPRM_Addons::is_active( 'premium' ) && WPRM_Settings::get( 'features_user_ratings' );
221
  $rating_value = ceil( $rating['average'] );
222
 
223
+ // Only output when there is an actual rating or users can rate.
224
+ if ( ! $user_ratings && ! $rating_value ) {
225
+ return '';
226
+ }
227
+
228
+ if ( $user_ratings && WPRMP_User_Rating::is_user_allowed_to_vote() ) {
229
+ $class = ' wprm-user-rating wprm-user-rating-allowed';
230
+ $data = ' data-average="' . $rating['average'] . '" data-count="' . $rating['count'] . '" data-total="' . $rating['total'] . '" data-user="' . $rating['user'] . '"';
231
+ } elseif ( $user_ratings ) {
232
+ $class = ' wprm-user-rating';
233
+ $data = '';
234
+ } else {
235
+ $class = '';
236
+ $data = '';
237
+ }
238
+
239
+ $output = '<div class="wprm-recipe-rating' . $class . '"' . $data . '>';
240
  for ( $i = 1; $i <= 5; $i++ ) {
241
+ $class = $i <= $rating_value ? 'wprm-rating-star-full' : 'wprm-rating-star-empty';
242
+ $output .= '<span class="wprm-rating-star wprm-rating-star-' . $i . ' ' . $class . '" data-rating="' . $i . '">';
243
+
244
+ ob_start();
245
+ include( WPRM_DIR . 'assets/icons/star-empty.svg' );
246
+ $output .= ob_get_contents();
247
+ ob_end_clean();
248
+
 
 
 
 
249
  $output .= '</span>';
250
  }
251
 
252
  if ( $show_details ) {
253
+ $output .= '<div class="wprm-recipe-rating-details" itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating"><span class="wprm-recipe-rating-average" itemprop="ratingValue">' . $rating['average'] . '</span> ' . __( 'from', 'wp-recipe-maker' ) . ' <span class="wprm-recipe-rating-count" itemprop="ratingCount">' . $rating['count'] . '</span> ' . _n( 'vote', 'votes', $rating['count'], 'wp-recipe-maker' ) . '</div>';
254
  } else {
255
  $output .= '<div class="wprm-recipe-rating-details-meta" itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating">';
256
  $output .= '<meta itemprop="ratingValue" content="' . $rating['average'] . '">';
includes/public/class-wprm-template-manager.php CHANGED
@@ -55,9 +55,10 @@ class WPRM_Template_Manager {
55
  * Output custom CSS from the options.
56
  *
57
  * @since 1.10.0
 
58
  */
59
- public static function custom_css() {
60
- $selector = ' html body .wprm-recipe-container';
61
 
62
  $output = '<style type="text/css">';
63
 
@@ -87,6 +88,7 @@ class WPRM_Template_Manager {
87
  $output .= $selector . ' svg path { fill: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
88
  $output .= $selector . ' svg rect { fill: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
89
  $output .= $selector . ' svg polygon { stroke: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
 
90
  $output .= $selector . ' .wprm-recipe .wprm-color-accent { background-color: ' . WPRM_Settings::get( 'template_color_accent' ) . '; }';
91
  $output .= $selector . ' .wprm-recipe .wprm-color-accent { color: ' . WPRM_Settings::get( 'template_color_accent_text' ) . '; }';
92
  $output .= $selector . ' .wprm-recipe .wprm-color-accent2 { background-color: ' . WPRM_Settings::get( 'template_color_accent2' ) . '; }';
@@ -108,8 +110,13 @@ class WPRM_Template_Manager {
108
  $output .= ' .wprm-comment-rating svg path, .comment-form-wprm-rating svg path { fill: ' . WPRM_Settings::get( 'template_color_comment_rating' ) . '; }';
109
  $output .= ' .wprm-comment-rating svg polygon, .comment-form-wprm-rating svg polygon { stroke: ' . WPRM_Settings::get( 'template_color_comment_rating' ) . '; }';
110
 
 
 
 
111
  // Custom recipe CSS.
112
- $output .= WPRM_Settings::get( 'recipe_css' );
 
 
113
 
114
  $output .= '</style>';
115
 
55
  * Output custom CSS from the options.
56
  *
57
  * @since 1.10.0
58
+ * @param mixed $type Type of recipe to output the custom CSS for.
59
  */
60
+ public static function custom_css( $type = 'recipe' ) {
61
+ $selector = 'print' === $type ? ' html body.wprm-print' : ' html body .wprm-recipe-container';
62
 
63
  $output = '<style type="text/css">';
64
 
88
  $output .= $selector . ' svg path { fill: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
89
  $output .= $selector . ' svg rect { fill: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
90
  $output .= $selector . ' svg polygon { stroke: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
91
+ $output .= $selector . ' .wprm-rating-star-full svg polygon { fill: ' . WPRM_Settings::get( 'template_color_icon' ) . '; }';
92
  $output .= $selector . ' .wprm-recipe .wprm-color-accent { background-color: ' . WPRM_Settings::get( 'template_color_accent' ) . '; }';
93
  $output .= $selector . ' .wprm-recipe .wprm-color-accent { color: ' . WPRM_Settings::get( 'template_color_accent_text' ) . '; }';
94
  $output .= $selector . ' .wprm-recipe .wprm-color-accent2 { background-color: ' . WPRM_Settings::get( 'template_color_accent2' ) . '; }';
110
  $output .= ' .wprm-comment-rating svg path, .comment-form-wprm-rating svg path { fill: ' . WPRM_Settings::get( 'template_color_comment_rating' ) . '; }';
111
  $output .= ' .wprm-comment-rating svg polygon, .comment-form-wprm-rating svg polygon { stroke: ' . WPRM_Settings::get( 'template_color_comment_rating' ) . '; }';
112
 
113
+ // Allow add-ons to hook in.
114
+ $output = apply_filters( 'wprm_custom_css', $output, $type, $selector );
115
+
116
  // Custom recipe CSS.
117
+ if ( 'print' !== $type ) {
118
+ $output .= WPRM_Settings::get( 'recipe_css' );
119
+ }
120
 
121
  $output .= '</style>';
122
 
readme.txt CHANGED
@@ -34,19 +34,7 @@ An overview of WP Recipe Maker features:
34
  * **Full text search** for your recipes
35
  * Access your recipes through the WordPress **REST API**
36
  * Built-in **SEO check** for your recipe metadata
37
-
38
- = Import Options =
39
-
40
- Currently using another recipe plugin? No problem! You can easily migrate all your existing recipes to WP Recipe Maker if you're using any of the following plugins:
41
-
42
- * EasyRecipe
43
- * WP Ultimate Recipe
44
- * Meal Planner Pro
45
- * BigOven
46
- * ZipList and Zip Recipes
47
- * Yummly
48
- * Yumprint Recipe Card
49
- * (More coming soon!)
50
 
51
  = WP Recipe Maker Premium =
52
 
@@ -55,13 +43,29 @@ Looking for some more advanced functionality? We also have the [WP Recipe Maker
55
  * Use **ingredient links** for linking to products or other recipes
56
  * **Adjustable servings** make it easy for your visitors
57
  * Display all nutrition data in a **nutrition label**
 
58
  * Add a mobile-friendly **kitchen timer** to your recipes
59
  * More **Premium templates** for a unique recipe template
60
  * Create custom **recipe taxonomies** like price level, difficulty, ...
 
61
 
62
  Even more add-ons can add the following functionality:
63
 
64
  * Integration with a **Nutrition API** for automatic nutrition facts
 
 
 
 
 
 
 
 
 
 
 
 
 
 
65
 
66
  This plugin is in active development. Feel free to contact us with any feature requests or ideas.
67
 
@@ -97,6 +101,15 @@ Yes! We pride ourselves on offering awesome support and almost always answer sup
97
 
98
  == Changelog ==
99
 
 
 
 
 
 
 
 
 
 
100
  = 1.21.0 =
101
  * Feature: change ingredients and instructions list style from settings page
102
  * Feature: Rename terms on the manage page
@@ -324,6 +337,12 @@ Yes! We pride ourselves on offering awesome support and almost always answer sup
324
 
325
  == Upgrade notice ==
326
 
 
 
 
 
 
 
327
  = 1.20.0 =
328
  Update for a few great tweaks
329
 
34
  * **Full text search** for your recipes
35
  * Access your recipes through the WordPress **REST API**
36
  * Built-in **SEO check** for your recipe metadata
37
+ * **Import your recipes** from other plugins (see below)
 
 
 
 
 
 
 
 
 
 
 
 
38
 
39
  = WP Recipe Maker Premium =
40
 
43
  * Use **ingredient links** for linking to products or other recipes
44
  * **Adjustable servings** make it easy for your visitors
45
  * Display all nutrition data in a **nutrition label**
46
+ * **User Ratings** allow visitors to vote without commenting
47
  * Add a mobile-friendly **kitchen timer** to your recipes
48
  * More **Premium templates** for a unique recipe template
49
  * Create custom **recipe taxonomies** like price level, difficulty, ...
50
+ * Use **checkboxes** for your ingredients and instructions
51
 
52
  Even more add-ons can add the following functionality:
53
 
54
  * Integration with a **Nutrition API** for automatic nutrition facts
55
+ * **Unit Conversion** to reach an international audience with a different unit system
56
+
57
+ = Import Options =
58
+
59
+ Currently using another recipe plugin? No problem! You can easily migrate all your existing recipes to WP Recipe Maker if you're using any of the following plugins:
60
+
61
+ * EasyRecipe
62
+ * WP Ultimate Recipe
63
+ * Meal Planner Pro
64
+ * BigOven
65
+ * ZipList and Zip Recipes
66
+ * Yummly
67
+ * Yumprint Recipe Card
68
+ * (More coming soon!)
69
 
70
  This plugin is in active development. Feel free to contact us with any feature requests or ideas.
71
 
101
 
102
  == Changelog ==
103
 
104
+ = 1.22.0 =
105
+ * Feature: RTL support for recipe templates and print
106
+ * Improvement: Print and unit conversion functionality when using the print templates
107
+ * Improvement: Combined public JS files
108
+ * Improvement: Apply appearance settings to print template as well
109
+ * Improvement: Recipe rating saved as post meta
110
+ * Improvement: Migrate WP Ultimate Recipe Premium user ratings
111
+ * Fix: Heading style dropdown in Recipe Notes
112
+
113
  = 1.21.0 =
114
  * Feature: change ingredients and instructions list style from settings page
115
  * Feature: Rename terms on the manage page
337
 
338
  == Upgrade notice ==
339
 
340
+ = 1.22.0 =
341
+ Update required if you want to use the latest version of WP Recipe Maker Premium
342
+
343
+ = 1.21.0 =
344
+ Update for the latest version of this recipe plugin
345
+
346
  = 1.20.0 =
347
  Update for a few great tweaks
348
 
templates/admin/menu/faq/whats_new.php CHANGED
@@ -11,6 +11,25 @@
11
 
12
  ?>
13
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
14
  <h3>2017-08-21 | WP Recipe Maker 1.21.0</h3>
15
  <ul>
16
  <li>Feature: change ingredients and instructions list style from settings page</li>
11
 
12
  ?>
13
 
14
+ <h3>2017-08-24 | WP Recipe Maker Premium 1.6.0</h3>
15
+ <ul>
16
+ <li>Feature: User Ratings</li>
17
+ <li>Feature: Use checkboxes for ingredients and instructions</li>
18
+ <li>Improvement: Combined public JS files</li>
19
+ <li>Improvement: Inline license key activation</li>
20
+ </ul>
21
+
22
+ <h3>2017-08-24 | WP Recipe Maker 1.22.0</h3>
23
+ <ul>
24
+ <li>Feature: RTL support for recipe templates and print</li>
25
+ <li>Improvement: Print and unit conversion functionality when using the print templates</li>
26
+ <li>Improvement: Combined public JS files</li>
27
+ <li>Improvement: Apply appearance settings to print template as well</li>
28
+ <li>Improvement: Recipe rating saved as post meta</li>
29
+ <li>Improvement: Migrate WP Ultimate Recipe Premium user ratings</li>
30
+ <li>Fix: Heading style dropdown in Recipe Notes</li>
31
+ </ul>
32
+
33
  <h3>2017-08-21 | WP Recipe Maker 1.21.0</h3>
34
  <ul>
35
  <li>Feature: change ingredients and instructions list style from settings page</li>
templates/admin/settings/appearance.php CHANGED
@@ -155,8 +155,11 @@
155
  <td>
156
  <select id="template_ingredient_list_style" name="template_ingredient_list_style">
157
  <?php
 
 
158
  $options = array(
159
  'none' => __( 'None', 'wp-recipe-maker' ),
 
160
  'circle' => __( 'Circle', 'wp-recipe-maker' ),
161
  'disc' => __( 'Disc', 'wp-recipe-maker' ),
162
  'square' => __( 'Square', 'wp-recipe-maker' ),
@@ -187,8 +190,11 @@
187
  <td>
188
  <select id="template_instruction_list_style" name="template_instruction_list_style">
189
  <?php
 
 
190
  $options = array(
191
  'none' => __( 'None', 'wp-recipe-maker' ),
 
192
  'circle' => __( 'Circle', 'wp-recipe-maker' ),
193
  'disc' => __( 'Disc', 'wp-recipe-maker' ),
194
  'square' => __( 'Square', 'wp-recipe-maker' ),
155
  <td>
156
  <select id="template_ingredient_list_style" name="template_ingredient_list_style">
157
  <?php
158
+ $premium_only = WPRM_Addons::is_active( 'premium' ) ? '' : ' (' . __( 'WP Recipe Maker Premium only', 'wp-recipe-maker' ) . ')';
159
+
160
  $options = array(
161
  'none' => __( 'None', 'wp-recipe-maker' ),
162
+ 'checkbox' => __( 'Checkbox', 'wp-recipe-maker' ) . $premium_only,
163
  'circle' => __( 'Circle', 'wp-recipe-maker' ),
164
  'disc' => __( 'Disc', 'wp-recipe-maker' ),
165
  'square' => __( 'Square', 'wp-recipe-maker' ),
190
  <td>
191
  <select id="template_instruction_list_style" name="template_instruction_list_style">
192
  <?php
193
+ $premium_only = WPRM_Addons::is_active( 'premium' ) ? '' : ' (' . __( 'WP Recipe Maker Premium only', 'wp-recipe-maker' ) . ')';
194
+
195
  $options = array(
196
  'none' => __( 'None', 'wp-recipe-maker' ),
197
+ 'checkbox' => __( 'Checkbox', 'wp-recipe-maker' ) . $premium_only,
198
  'circle' => __( 'Circle', 'wp-recipe-maker' ),
199
  'disc' => __( 'Disc', 'wp-recipe-maker' ),
200
  'square' => __( 'Square', 'wp-recipe-maker' ),
templates/admin/settings/features.php CHANGED
@@ -104,6 +104,21 @@
104
  </p>
105
  </td>
106
  </tr>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
107
  </tbody>
108
  </table>
109
  <?php submit_button( __( 'Save Changes', 'wp-recipe-maker' ) ); ?>
104
  </p>
105
  </td>
106
  </tr>
107
+ <tr>
108
+ <th scope="row">
109
+ <?php esc_html_e( 'User Ratings', 'wp-recipe-maker' ); ?>
110
+ </th>
111
+ <td>
112
+ <label for="features_user_ratings">
113
+ <?php $checked = WPRM_Settings::get( 'features_user_ratings' ) ? ' checked="checked"' : ''; ?>
114
+ <input name="features_user_ratings" type="checkbox" id="features_user_ratings"<?php echo esc_html( $checked ); ?> />
115
+ <?php esc_html_e( 'Visitors can rate your recipes without commenting', 'wp-recipe-maker' ); ?>
116
+ </label>
117
+ <p class="description">
118
+ <a href="http://bootstrapped.ventures/wp-recipe-maker/user-ratings/" target="_blank"><?php esc_html_e( 'Learn more', 'wp-recipe-maker' ); ?></a>
119
+ </p>
120
+ </td>
121
+ </tr>
122
  </tbody>
123
  </table>
124
  <?php submit_button( __( 'Save Changes', 'wp-recipe-maker' ) ); ?>
templates/recipe/clean-print-with-image/clean-print-with-image.min.css CHANGED
@@ -1 +1 @@
1
- .wprm-recipe-clean-print-with-image{font-size:.9em}.wprm-recipe-clean-print-with-image :after,.wprm-recipe-clean-print-with-image :before{display:none}.wprm-recipe-clean-print-with-image .wprm-recipe-image{float:left;margin:0 15px 15px 0}.wprm-recipe-clean-print-with-image h2.wprm-recipe-name,.wprm-recipe-clean-print-with-image h3.wprm-recipe-header,.wprm-recipe-clean-print-with-image h4.wprm-recipe-group-name{font-variant:normal;text-transform:none;letter-spacing:normal;margin:0;padding:0}.wprm-recipe-clean-print-with-image h2.wprm-recipe-name{clear:none;font-size:1.8em}.wprm-recipe-clean-print-with-image .wprm-recipe-details-container,.wprm-recipe-clean-print-with-image .wprm-recipe-summary{margin-bottom:15px}.wprm-recipe-clean-print-with-image .wprm-recipe-details-name{display:inline-block;font-weight:700;min-width:130px}.wprm-recipe-clean-print-with-image .wprm-recipe-details-unit{font-size:.8em}.wprm-recipe-clean-print-with-image h3.wprm-recipe-header{margin-top:10px;font-size:1.2em}.wprm-recipe-clean-print-with-image ol,.wprm-recipe-clean-print-with-image ul{margin:0 0 8px}.wprm-recipe-clean-print-with-image ol li,.wprm-recipe-clean-print-with-image ul li{margin:0 0 0 32px}.wprm-recipe-clean-print-with-image h4.wprm-recipe-group-name{margin-top:5px!important;font-weight:300;font-size:1em}.wprm-recipe-clean-print-with-image .wprm-recipe-ingredient-notes{opacity:.7}.wprm-recipe-clean-print-with-image .wprm-recipe-instructions .wprm-recipe-instruction{margin-bottom:5px}.wprm-recipe-clean-print-with-image .wprm-recipe-instruction-text p{margin:0 0 5px}.wprm-recipe-clean-print-with-image .wprm-recipe-instruction-text p:last-of-type{margin-bottom:0}.wprm-print .wprm-recipe-clean-print-with-image{max-width:750px;margin:0 auto}
1
+ .rtl .wprm-recipe-clean-print-with-image .wprm-recipe-image{float:right;margin:0 0 15px 15px}.rtl .wprm-recipe-clean-print-with-image ol li,.rtl .wprm-recipe-clean-print-with-image ul li{margin:0 32px 0 0}.wprm-recipe-clean-print-with-image{font-size:.9em}.wprm-recipe-clean-print-with-image :after,.wprm-recipe-clean-print-with-image :before{display:none}.wprm-recipe-clean-print-with-image .wprm-recipe-image{float:left;margin:0 15px 15px 0}.wprm-recipe-clean-print-with-image h2.wprm-recipe-name,.wprm-recipe-clean-print-with-image h3.wprm-recipe-header,.wprm-recipe-clean-print-with-image h4.wprm-recipe-group-name{font-variant:normal;text-transform:none;letter-spacing:normal;margin:0;padding:0}.wprm-recipe-clean-print-with-image h2.wprm-recipe-name{clear:none;font-size:1.8em}.wprm-recipe-clean-print-with-image .wprm-recipe-details-container,.wprm-recipe-clean-print-with-image .wprm-recipe-summary{margin-bottom:15px}.wprm-recipe-clean-print-with-image .wprm-recipe-details-name{display:inline-block;font-weight:700;min-width:130px}.wprm-recipe-clean-print-with-image .wprm-recipe-details-unit{font-size:.8em}.wprm-recipe-clean-print-with-image h3.wprm-recipe-header{margin-top:10px;font-size:1.2em}.wprm-recipe-clean-print-with-image ol,.wprm-recipe-clean-print-with-image ul{margin:0 0 8px}.wprm-recipe-clean-print-with-image ol li,.wprm-recipe-clean-print-with-image ul li{margin:0 0 0 32px}.wprm-recipe-clean-print-with-image h4.wprm-recipe-group-name{margin-top:5px!important;font-weight:300;font-size:1em}.wprm-recipe-clean-print-with-image .wprm-recipe-ingredient-notes{opacity:.7}.wprm-recipe-clean-print-with-image .wprm-recipe-instructions .wprm-recipe-instruction{margin-bottom:5px}.wprm-recipe-clean-print-with-image .wprm-recipe-instruction-text p{margin:0 0 5px}.wprm-recipe-clean-print-with-image .wprm-recipe-instruction-text p:last-of-type{margin-bottom:0}
templates/recipe/clean-print-with-image/clean-print-with-image.php CHANGED
@@ -12,6 +12,7 @@
12
  // @codingStandardsIgnoreStart
13
  ?>
14
  <div class="wprm-recipe wprm-recipe-clean-print-with-image">
 
15
  <div class="wprm-recipe-image"><?php echo WPRM_Template_Helper::recipe_image( $recipe, 'thumbnail' ); ?></div>
16
  <h2 class="wprm-recipe-name"><?php echo $recipe->name(); ?></h2>
17
  <div class="wprm-recipe-summary">
@@ -104,6 +105,7 @@
104
  </div>
105
  <?php endforeach; // Ingredient groups. ?>
106
  </div>
 
107
  <?php endif; // Ingredients. ?>
108
  <?php
109
  $instructions = $recipe->instructions();
12
  // @codingStandardsIgnoreStart
13
  ?>
14
  <div class="wprm-recipe wprm-recipe-clean-print-with-image">
15
+ <div class="wprm-recipe-print"><span class="wprm-recipe-details-icon"><?php include( WPRM_DIR . 'assets/icons/printer.svg' ); ?></span> <?php echo WPRM_Template_Helper::label( 'print_button' ); ?></div>
16
  <div class="wprm-recipe-image"><?php echo WPRM_Template_Helper::recipe_image( $recipe, 'thumbnail' ); ?></div>
17
  <h2 class="wprm-recipe-name"><?php echo $recipe->name(); ?></h2>
18
  <div class="wprm-recipe-summary">
105
  </div>
106
  <?php endforeach; // Ingredient groups. ?>
107
  </div>
108
+ <?php echo WPRM_Template_Helper::unit_conversion( $recipe ); ?>
109
  <?php endif; // Ingredients. ?>
110
  <?php
111
  $instructions = $recipe->instructions();
templates/recipe/clean-print-with-image/clean-print-with-image.scss CHANGED
@@ -1,3 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  .wprm-recipe-clean-print-with-image {
2
  font-size: 0.9em;
3
 
@@ -80,10 +94,3 @@
80
  }
81
  }
82
  }
83
-
84
- .wprm-print {
85
- .wprm-recipe-clean-print-with-image {
86
- max-width: 750px;
87
- margin: 0 auto;
88
- }
89
- }
1
+ .rtl .wprm-recipe-clean-print-with-image {
2
+ .wprm-recipe-image {
3
+ float: right;
4
+ margin: 0 0 15px 15px;
5
+ }
6
+
7
+ ol,
8
+ ul {
9
+ li {
10
+ margin: 0 32px 0 0;
11
+ }
12
+ }
13
+ }
14
+
15
  .wprm-recipe-clean-print-with-image {
16
  font-size: 0.9em;
17
 
94
  }
95
  }
96
  }
 
 
 
 
 
 
 
templates/recipe/clean-print/clean-print.min.css CHANGED
@@ -1 +1 @@
1
- .wprm-recipe-clean-print{font-size:.9em}.wprm-recipe-clean-print :after,.wprm-recipe-clean-print :before{display:none}.wprm-recipe-clean-print h2.wprm-recipe-name,.wprm-recipe-clean-print h3.wprm-recipe-header,.wprm-recipe-clean-print h4.wprm-recipe-group-name{font-variant:normal;text-transform:none;letter-spacing:normal;margin:0;padding:0}.wprm-recipe-clean-print h2.wprm-recipe-name{clear:none;font-size:1.8em}.wprm-recipe-clean-print .wprm-recipe-details-container,.wprm-recipe-clean-print .wprm-recipe-summary{margin-bottom:15px}.wprm-recipe-clean-print .wprm-recipe-details-name{display:inline-block;font-weight:700;min-width:130px}.wprm-recipe-clean-print .wprm-recipe-details-unit{font-size:.8em}.wprm-recipe-clean-print h3.wprm-recipe-header{margin-top:10px;font-size:1.2em}.wprm-recipe-clean-print ol,.wprm-recipe-clean-print ul{margin:0 0 8px}.wprm-recipe-clean-print ol li,.wprm-recipe-clean-print ul li{margin:0 0 0 32px}.wprm-recipe-clean-print h4.wprm-recipe-group-name{margin-top:5px!important;font-weight:300;font-size:1em}.wprm-recipe-clean-print .wprm-recipe-ingredient-notes{opacity:.7}.wprm-recipe-clean-print .wprm-recipe-instructions .wprm-recipe-instruction{margin-bottom:5px}.wprm-recipe-clean-print .wprm-recipe-instruction-text p{margin:0 0 5px}.wprm-recipe-clean-print .wprm-recipe-instruction-text p:last-of-type{margin-bottom:0}.wprm-print .wprm-recipe-clean-print{max-width:750px;margin:0 auto}
1
+ .rtl .wprm-recipe-clean-print ol li,.rtl .wprm-recipe-clean-print ul li{margin:0 32px 0 0}.wprm-recipe-clean-print{font-size:.9em}.wprm-recipe-clean-print :after,.wprm-recipe-clean-print :before{display:none}.wprm-recipe-clean-print h2.wprm-recipe-name,.wprm-recipe-clean-print h3.wprm-recipe-header,.wprm-recipe-clean-print h4.wprm-recipe-group-name{font-variant:normal;text-transform:none;letter-spacing:normal;margin:0;padding:0}.wprm-recipe-clean-print h2.wprm-recipe-name{clear:none;font-size:1.8em}.wprm-recipe-clean-print .wprm-recipe-details-container,.wprm-recipe-clean-print .wprm-recipe-summary{margin-bottom:15px}.wprm-recipe-clean-print .wprm-recipe-details-name{display:inline-block;font-weight:700;min-width:130px}.wprm-recipe-clean-print .wprm-recipe-details-unit{font-size:.8em}.wprm-recipe-clean-print h3.wprm-recipe-header{margin-top:10px;font-size:1.2em}.wprm-recipe-clean-print ol,.wprm-recipe-clean-print ul{margin:0 0 8px}.wprm-recipe-clean-print ol li,.wprm-recipe-clean-print ul li{margin:0 0 0 32px}.wprm-recipe-clean-print h4.wprm-recipe-group-name{margin-top:5px!important;font-weight:300;font-size:1em}.wprm-recipe-clean-print .wprm-recipe-ingredient-notes{opacity:.7}.wprm-recipe-clean-print .wprm-recipe-instructions .wprm-recipe-instruction{margin-bottom:5px}.wprm-recipe-clean-print .wprm-recipe-instruction-text p{margin:0 0 5px}.wprm-recipe-clean-print .wprm-recipe-instruction-text p:last-of-type{margin-bottom:0}
templates/recipe/clean-print/clean-print.php CHANGED
@@ -12,6 +12,7 @@
12
  // @codingStandardsIgnoreStart
13
  ?>
14
  <div class="wprm-recipe wprm-recipe-clean-print">
 
15
  <h2 class="wprm-recipe-name"><?php echo $recipe->name(); ?></h2>
16
  <div class="wprm-recipe-summary">
17
  <?php echo $recipe->summary(); ?>
@@ -103,6 +104,7 @@
103
  </div>
104
  <?php endforeach; // Ingredient groups. ?>
105
  </div>
 
106
  <?php endif; // Ingredients. ?>
107
  <?php
108
  $instructions = $recipe->instructions();
12
  // @codingStandardsIgnoreStart
13
  ?>
14
  <div class="wprm-recipe wprm-recipe-clean-print">
15
+ <div class="wprm-recipe-print"><span class="wprm-recipe-details-icon"><?php include( WPRM_DIR . 'assets/icons/printer.svg' ); ?></span> <?php echo WPRM_Template_Helper::label( 'print_button' ); ?></div>
16
  <h2 class="wprm-recipe-name"><?php echo $recipe->name(); ?></h2>
17
  <div class="wprm-recipe-summary">
18
  <?php echo $recipe->summary(); ?>
104
  </div>
105
  <?php endforeach; // Ingredient groups. ?>
106
  </div>
107
+ <?php echo WPRM_Template_Helper::unit_conversion( $recipe ); ?>
108
  <?php endif; // Ingredients. ?>
109
  <?php
110
  $instructions = $recipe->instructions();
templates/recipe/clean-print/clean-print.scss CHANGED
@@ -1,3 +1,12 @@
 
 
 
 
 
 
 
 
 
1
  .wprm-recipe-clean-print {
2
  font-size: 0.9em;
3
 
@@ -75,10 +84,3 @@
75
  }
76
  }
77
  }
78
-
79
- .wprm-print {
80
- .wprm-recipe-clean-print {
81
- max-width: 750px;
82
- margin: 0 auto;
83
- }
84
- }
1
+ .rtl .wprm-recipe-clean-print {
2
+ ol,
3
+ ul {
4
+ li {
5
+ margin: 0 32px 0 0;
6
+ }
7
+ }
8
+ }
9
+
10
  .wprm-recipe-clean-print {
11
  font-size: 0.9em;
12
 
84
  }
85
  }
86
  }
 
 
 
 
 
 
 
templates/recipe/simple/simple.min.css CHANGED
@@ -1 +1 @@
1
- .wprm-recipe-simple{border-top:1px solid #aaa;background-color:#fafafa;padding:10px;margin:20px 0;font-size:.9em}.wprm-recipe-simple li,.wprm-recipe-simple p{font-size:1em}.wprm-recipe-simple :after,.wprm-recipe-simple :before{display:none}.wprm-recipe-simple h2.wprm-recipe-name,.wprm-recipe-simple h3.wprm-recipe-header,.wprm-recipe-simple h4.wprm-recipe-group-name{font-variant:normal;text-transform:none;letter-spacing:normal;margin:0;padding:0}.wprm-recipe-simple .wprm-recipe-image-container{float:right;text-align:center;margin:0 0 10px 10px}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-image{margin:0}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-rating{margin-bottom:5px}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-rating svg{vertical-align:middle;width:16px;height:16px;margin:0}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-rating .wprm-recipe-rating-details{font-size:.8em}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-print{font-size:.9em;cursor:pointer}.wprm-recipe-simple h2.wprm-recipe-name{clear:none;font-size:1.8em}.wprm-recipe-simple .wprm-recipe-details-container,.wprm-recipe-simple .wprm-recipe-summary{margin-bottom:15px}.wprm-recipe-simple .wprm-recipe-details-icon svg{vertical-align:middle;width:16px;height:16px}.wprm-recipe-simple .wprm-recipe-details-name{display:inline-block;font-weight:700;min-width:130px}.wprm-recipe-simple .wprm-recipe-details-unit{font-size:.8em}.wprm-recipe-simple h3.wprm-recipe-header{margin-top:10px;font-size:1.2em}.wprm-recipe-simple ol,.wprm-recipe-simple ul{margin:0 0 8px}.wprm-recipe-simple ol li,.wprm-recipe-simple ul li{margin:0 0 0 32px}.wprm-recipe-simple h4.wprm-recipe-group-name{margin-top:5px!important;font-weight:300;font-size:1em}.wprm-recipe-simple .wprm-recipe-ingredient-notes{opacity:.7}.wprm-recipe-simple .wprm-recipe-instructions .wprm-recipe-instruction{margin-bottom:5px}.wprm-recipe-simple .wprm-recipe-instruction-text{font-size:1em}.wprm-recipe-simple .wprm-recipe-instruction-text p{margin:0 0 5px}.wprm-recipe-simple .wprm-recipe-instruction-text p:last-of-type{margin-bottom:0}.wprm-recipe-simple .wprm-recipe-instruction-image{margin:5px 0 15px}.wprm-print .wprm-recipe-simple{max-width:750px;margin:0 auto}.wprm-print .wprm-recipe-print{display:none}@media only screen and (max-width:640px){.wprm-recipe-simple .wprm-recipe-image-container{float:none}.wprm-recipe-simple .wprm-recipe-details-name{min-width:0}}
1
+ .rtl .wprm-recipe-simple .wprm-recipe-image-container{float:left;margin:0 10px 10px 0}.rtl .wprm-recipe-simple ol li,.rtl .wprm-recipe-simple ul li{margin:0 32px 0 0}.wprm-recipe-simple{border-top:1px solid #aaa;background-color:#fafafa;padding:10px;margin:20px 0;font-size:.9em}.wprm-recipe-simple li,.wprm-recipe-simple p{font-size:1em}.wprm-recipe-simple :after,.wprm-recipe-simple :before{display:none}.wprm-recipe-simple h2.wprm-recipe-name,.wprm-recipe-simple h3.wprm-recipe-header,.wprm-recipe-simple h4.wprm-recipe-group-name{font-variant:normal;text-transform:none;letter-spacing:normal;margin:0;padding:0}.wprm-recipe-simple .wprm-recipe-image-container{float:right;text-align:center;margin:0 0 10px 10px}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-image{margin:0}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-rating{margin-bottom:5px}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-rating svg{vertical-align:middle;width:16px;height:16px;margin:0}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-rating .wprm-recipe-rating-details{font-size:.8em}.wprm-recipe-simple .wprm-recipe-image-container .wprm-recipe-print{font-size:.9em;cursor:pointer}.wprm-recipe-simple h2.wprm-recipe-name{clear:none;font-size:1.8em}.wprm-recipe-simple .wprm-recipe-details-container,.wprm-recipe-simple .wprm-recipe-summary{margin-bottom:15px}.wprm-recipe-simple .wprm-recipe-details-icon svg{vertical-align:middle;width:16px;height:16px}.wprm-recipe-simple .wprm-recipe-details-name{display:inline-block;font-weight:700;min-width:130px}.wprm-recipe-simple .wprm-recipe-details-unit{font-size:.8em}.wprm-recipe-simple h3.wprm-recipe-header{margin-top:10px;font-size:1.2em}.wprm-recipe-simple ol,.wprm-recipe-simple ul{margin:0 0 8px}.wprm-recipe-simple ol li,.wprm-recipe-simple ul li{margin:0 0 0 32px}.wprm-recipe-simple h4.wprm-recipe-group-name{margin-top:5px!important;font-weight:300;font-size:1em}.wprm-recipe-simple .wprm-recipe-ingredient-notes{opacity:.7}.wprm-recipe-simple .wprm-recipe-instructions .wprm-recipe-instruction{margin-bottom:5px}.wprm-recipe-simple .wprm-recipe-instruction-text{font-size:1em}.wprm-recipe-simple .wprm-recipe-instruction-text p{margin:0 0 5px}.wprm-recipe-simple .wprm-recipe-instruction-text p:last-of-type{margin-bottom:0}.wprm-recipe-simple .wprm-recipe-instruction-image{margin:5px 0 15px}@media only screen and (max-width:640px){.rtl .wprm-recipe-simple .wprm-recipe-image-container,.wprm-recipe-simple .wprm-recipe-image-container{float:none}.rtl .wprm-recipe-simple .wprm-recipe-details-name,.wprm-recipe-simple .wprm-recipe-details-name{min-width:0}}
templates/recipe/simple/simple.php CHANGED
@@ -18,11 +18,7 @@
18
  <div class="wprm-recipe-image-container">
19
  <div class="wprm-recipe-image"><?php echo WPRM_Template_Helper::recipe_image( $recipe, 'thumbnail' ); ?></div>
20
  <div class="wprm-recipe-buttons">
21
- <?php
22
- if ( $recipe->has_rating() ) {
23
- echo $recipe->rating_stars( true );
24
- }
25
- ?>
26
  <span class="wprm-recipe-print"><span class="wprm-recipe-details-icon"><?php include( WPRM_DIR . 'assets/icons/printer.svg' ); ?></span> <?php echo WPRM_Template_Helper::label( 'print_button' ); ?></span>
27
  </div>
28
  </div>
18
  <div class="wprm-recipe-image-container">
19
  <div class="wprm-recipe-image"><?php echo WPRM_Template_Helper::recipe_image( $recipe, 'thumbnail' ); ?></div>
20
  <div class="wprm-recipe-buttons">
21
+ <?php echo $recipe->rating_stars( true ); ?>
 
 
 
 
22
  <span class="wprm-recipe-print"><span class="wprm-recipe-details-icon"><?php include( WPRM_DIR . 'assets/icons/printer.svg' ); ?></span> <?php echo WPRM_Template_Helper::label( 'print_button' ); ?></span>
23
  </div>
24
  </div>
templates/recipe/simple/simple.scss CHANGED
@@ -1,3 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  .wprm-recipe-simple {
2
  border-top: 1px solid #aaaaaa;
3
  background-color: #fafafa;
@@ -128,18 +142,9 @@
128
  }
129
  }
130
 
131
- .wprm-print {
132
- .wprm-recipe-simple {
133
- max-width: 750px;
134
- margin: 0 auto;
135
- }
136
-
137
- .wprm-recipe-print {
138
- display: none;
139
- }
140
- }
141
  @media only screen and (max-width: 640px) {
142
- .wprm-recipe-simple {
 
143
  .wprm-recipe-image-container {
144
  float: none;
145
  }
1
+ .rtl .wprm-recipe-simple {
2
+ .wprm-recipe-image-container {
3
+ float: left;
4
+ margin: 0 10px 10px 0;
5
+ }
6
+
7
+ ol,
8
+ ul {
9
+ li {
10
+ margin: 0 32px 0 0;
11
+ }
12
+ }
13
+ }
14
+
15
  .wprm-recipe-simple {
16
  border-top: 1px solid #aaaaaa;
17
  background-color: #fafafa;
142
  }
143
  }
144
 
 
 
 
 
 
 
 
 
 
 
145
  @media only screen and (max-width: 640px) {
146
+ .wprm-recipe-simple,
147
+ .rtl .wprm-recipe-simple {
148
  .wprm-recipe-image-container {
149
  float: none;
150
  }
templates/recipe/tastefully-simple/tastefully-simple.min.css CHANGED
@@ -1 +1 @@
1
- .wprm-print .wprm-recipe-print,.wprm-print .wprm-recipe-tastefully-simple :after,.wprm-print .wprm-recipe-tastefully-simple :before,.wprm-recipe-container .wprm-recipe-tastefully-simple :after,.wprm-recipe-container .wprm-recipe-tastefully-simple :before{display:none}.wprm-print .wprm-recipe-tastefully-simple,.wprm-recipe-container .wprm-recipe-tastefully-simple{font:12px Verdana,Arial,Geneva,sans-serif;border:1px dashed #666;padding:10px}.wprm-print .wprm-recipe-tastefully-simple li,.wprm-print .wprm-recipe-tastefully-simple p,.wprm-recipe-container .wprm-recipe-tastefully-simple li,.wprm-recipe-container .wprm-recipe-tastefully-simple p{font:1em Verdana,Arial,Geneva,sans-serif}.wprm-print .wprm-recipe-tastefully-simple div,.wprm-print .wprm-recipe-tastefully-simple li,.wprm-print .wprm-recipe-tastefully-simple ol,.wprm-print .wprm-recipe-tastefully-simple p,.wprm-print .wprm-recipe-tastefully-simple span,.wprm-print .wprm-recipe-tastefully-simple ul,.wprm-recipe-container .wprm-recipe-tastefully-simple div,.wprm-recipe-container .wprm-recipe-tastefully-simple li,.wprm-recipe-container .wprm-recipe-tastefully-simple ol,.wprm-recipe-container .wprm-recipe-tastefully-simple p,.wprm-recipe-container .wprm-recipe-tastefully-simple span,.wprm-recipe-container .wprm-recipe-tastefully-simple ul{margin:0;padding:0;line-height:inherit}.wprm-print .wprm-recipe-tastefully-simple svg,.wprm-recipe-container .wprm-recipe-tastefully-simple svg{vertical-align:middle;width:16px;height:16px;margin:0}.wprm-print .wprm-recipe-tastefully-simple .wprm-clear-left,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-clear-left{clear:left;line-height:0;height:0}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container{float:right;max-width:40%;text-align:right}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating{margin-bottom:5px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating .wprm-recipe-rating-details,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating .wprm-recipe-rating-details{font:.8em "Trebuchet MS",Arial,Helvetica,sans-serif}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image{margin-left:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons{margin-top:10px;text-align:center}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons .wprm-recipe-print,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons .wprm-recipe-print{font-size:11px;cursor:pointer;-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px;padding:.4em 1em}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-name,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-name{font:1.5em Verdana,Geneva,sans-serif;margin-bottom:15px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-times-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-times-container{border-top:1px dotted #666;border-bottom:1px dotted #666;width:60%;padding-top:5px;padding-bottom:5px;margin-bottom:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container{width:33%;text-align:center;float:left;font-weight:700;border-left:1px solid #ccc}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container:first-child,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container:first-child{border-left:none}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time-header,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time-header{margin-bottom:4px;word-break:break-all}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time{font-size:.8em;font-weight:400}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-details-container,.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-ingredients-container,.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-summary,.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-summary p,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-details-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-ingredients-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-summary,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-summary p{margin-bottom:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-header,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-header{font-size:1.4em;font-weight:700;margin-top:1em;margin-bottom:1em}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-group-name,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-group-name{margin-top:3px;margin-bottom:3px;font-weight:700}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-ingredients li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-ingredients li{list-style-position:inside;margin-left:10px;line-height:inherit;background:0 0}.wprm-print .wprm-recipe-tastefully-simple .wprm-unit-conversion-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-unit-conversion-container{margin-top:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-instructions li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-instructions li{margin-left:30px;line-height:inherit;background:0 0}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ul li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ul li{list-style:disc inside;margin-left:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ol li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ol li{list-style:decimal;margin-left:30px}.wprm-print .wprm-recipe-tastefully-simple{max-width:750px;margin:0 auto}@media only screen and (max-width:480px){.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container{float:none;width:100%;max-width:none;text-align:center;margin-bottom:10px}.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image{margin-left:0}.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-times-container{width:100%}}
1
+ .rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image,.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-ingredients li,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-ingredients li{margin-right:10px;margin-left:0}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container{float:left;text-align:left}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container{float:right;border-left:none;border-right:1px solid #ccc}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-clear-left,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-clear-left{clear:right}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container:first-child,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container:first-child{border-right:none}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-instructions li,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-instructions li{margin-left:0;margin-right:30px}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ul li,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ul li{margin-left:0;margin-right:10px}.rtl .wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ol li,.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ol li{margin-left:0;margin-right:30px}.wprm-print .wprm-recipe-tastefully-simple,.wprm-recipe-container .wprm-recipe-tastefully-simple{font:12px Verdana,Arial,Geneva,sans-serif;border:1px dashed #666;padding:10px}.wprm-print .wprm-recipe-tastefully-simple li,.wprm-print .wprm-recipe-tastefully-simple p,.wprm-recipe-container .wprm-recipe-tastefully-simple li,.wprm-recipe-container .wprm-recipe-tastefully-simple p{font:1em Verdana,Arial,Geneva,sans-serif}.wprm-print .wprm-recipe-tastefully-simple div,.wprm-print .wprm-recipe-tastefully-simple li,.wprm-print .wprm-recipe-tastefully-simple ol,.wprm-print .wprm-recipe-tastefully-simple p,.wprm-print .wprm-recipe-tastefully-simple span,.wprm-print .wprm-recipe-tastefully-simple ul,.wprm-recipe-container .wprm-recipe-tastefully-simple div,.wprm-recipe-container .wprm-recipe-tastefully-simple li,.wprm-recipe-container .wprm-recipe-tastefully-simple ol,.wprm-recipe-container .wprm-recipe-tastefully-simple p,.wprm-recipe-container .wprm-recipe-tastefully-simple span,.wprm-recipe-container .wprm-recipe-tastefully-simple ul{margin:0;padding:0;line-height:inherit}.wprm-print .wprm-recipe-tastefully-simple :after,.wprm-print .wprm-recipe-tastefully-simple :before,.wprm-recipe-container .wprm-recipe-tastefully-simple :after,.wprm-recipe-container .wprm-recipe-tastefully-simple :before{display:none}.wprm-print .wprm-recipe-tastefully-simple svg,.wprm-recipe-container .wprm-recipe-tastefully-simple svg{vertical-align:middle;width:16px;height:16px;margin:0}.wprm-print .wprm-recipe-tastefully-simple .wprm-clear-left,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-clear-left{clear:left;line-height:0;height:0}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container{float:right;max-width:40%;text-align:right}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating{margin-bottom:5px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating .wprm-recipe-rating-details,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-rating .wprm-recipe-rating-details{font:.8em "Trebuchet MS",Arial,Helvetica,sans-serif}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image{margin-left:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons{margin-top:10px;text-align:center}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons .wprm-recipe-print,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-buttons .wprm-recipe-print{font-size:11px;cursor:pointer;-webkit-border-radius:5px 5px 5px 5px;-moz-border-radius:5px;border-radius:5px;padding:.4em 1em}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-name,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-name{font:1.5em Verdana,Geneva,sans-serif;margin-bottom:15px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-times-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-times-container{border-top:1px dotted #666;border-bottom:1px dotted #666;width:60%;padding-top:5px;padding-bottom:5px;margin-bottom:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container{width:33%;text-align:center;float:left;font-weight:700;border-left:1px solid #ccc}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container:first-child,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container:first-child{border-left:none}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time-header,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time-header{margin-bottom:4px;word-break:break-all}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-time-container .wprm-recipe-time{font-size:.8em;font-weight:400}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-details-container,.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-ingredients-container,.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-summary,.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-summary p,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-details-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-ingredients-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-summary,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-summary p{margin-bottom:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-header,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-header{font-size:1.4em;font-weight:700;margin-top:1em;margin-bottom:1em}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-group-name,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-group-name{margin-top:3px;margin-bottom:3px;font-weight:700}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-ingredients li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-ingredients li{list-style-position:inside;margin-left:10px;line-height:inherit;background:0 0}.wprm-print .wprm-recipe-tastefully-simple .wprm-unit-conversion-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-unit-conversion-container{margin-top:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-instructions li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-instructions li{margin-left:30px;line-height:inherit;background:0 0}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ul li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ul li{list-style:disc inside;margin-left:10px}.wprm-print .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ol li,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-notes-container ol li{list-style:decimal;margin-left:30px}@media only screen and (max-width:480px){.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container{float:none;width:100%;max-width:none;text-align:center;margin-bottom:10px}.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-image-container .wprm-recipe-image{margin-left:0;margin-right:0}.rtl .wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-times-container,.wprm-recipe-container .wprm-recipe-tastefully-simple .wprm-recipe-times-container{width:100%}}
templates/recipe/tastefully-simple/tastefully-simple.php CHANGED
@@ -16,11 +16,7 @@
16
  <meta itemprop="datePublished" content="<?php echo $recipe->date(); ?>" />
17
  <meta itemprop="image" content="<?php echo $recipe->image_url( 'full' ); ?>" />
18
  <div class="wprm-recipe-image-container">
19
- <?php
20
- if ( $recipe->has_rating() ) {
21
- echo $recipe->rating_stars( true );
22
- }
23
- ?>
24
  <div class="wprm-recipe-image"><?php echo WPRM_Template_Helper::recipe_image( $recipe, 'thumbnail' ); ?></div>
25
  <div class="wprm-recipe-buttons">
26
  <span class="wprm-recipe-print wprm-color-accent"><?php echo WPRM_Template_Helper::label( 'print_button' ); ?></span>
16
  <meta itemprop="datePublished" content="<?php echo $recipe->date(); ?>" />
17
  <meta itemprop="image" content="<?php echo $recipe->image_url( 'full' ); ?>" />
18
  <div class="wprm-recipe-image-container">
19
+ <?php echo $recipe->rating_stars( true ); ?>
 
 
 
 
20
  <div class="wprm-recipe-image"><?php echo WPRM_Template_Helper::recipe_image( $recipe, 'thumbnail' ); ?></div>
21
  <div class="wprm-recipe-buttons">
22
  <span class="wprm-recipe-print wprm-color-accent"><?php echo WPRM_Template_Helper::label( 'print_button' ); ?></span>
templates/recipe/tastefully-simple/tastefully-simple.scss CHANGED
@@ -1,3 +1,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  .wprm-recipe-container .wprm-recipe-tastefully-simple,
2
  .wprm-print .wprm-recipe-tastefully-simple {
3
  font: 12px Verdana, Arial, Geneva, sans-serif;
@@ -162,17 +217,10 @@
162
  }
163
  }
164
  }
165
- .wprm-print {
166
- .wprm-recipe-tastefully-simple {
167
- max-width: 750px;
168
- margin: 0 auto;
169
- }
170
- .wprm-recipe-print {
171
- display: none;
172
- }
173
- }
174
  @media only screen and (max-width: 480px) {
175
- .wprm-recipe-container .wprm-recipe-tastefully-simple {
 
176
  .wprm-recipe-image-container {
177
  float: none;
178
  width: 100%;
@@ -182,6 +230,7 @@
182
 
183
  .wprm-recipe-image {
184
  margin-left: 0;
 
185
  }
186
  }
187
  .wprm-recipe-times-container {
1
+ .rtl .wprm-recipe-container .wprm-recipe-tastefully-simple,
2
+ .rtl .wprm-print .wprm-recipe-tastefully-simple {
3
+ .wprm-recipe-image-container {
4
+ float: left;
5
+ text-align: left;
6
+
7
+ .wprm-recipe-image {
8
+ margin-left: 0;
9
+ margin-right: 10px;
10
+ }
11
+ }
12
+
13
+ .wprm-recipe-time-container {
14
+ float: right;
15
+ }
16
+
17
+ .wprm-clear-left {
18
+ clear: right;
19
+ }
20
+
21
+ .wprm-recipe-time-container {
22
+ border-left: none;
23
+ border-right: 1px solid #ccc;
24
+
25
+ &:first-child {
26
+ border-right: none;
27
+ }
28
+ }
29
+
30
+ .wprm-recipe-ingredients {
31
+ li {
32
+ margin-left: 0;
33
+ margin-right: 10px;
34
+ }
35
+ }
36
+
37
+ .wprm-recipe-instructions {
38
+ li {
39
+ margin-left: 0;
40
+ margin-right: 30px;
41
+ }
42
+ }
43
+
44
+ .wprm-recipe-notes-container {
45
+ ul li {
46
+ margin-left: 0;
47
+ margin-right: 10px;
48
+ }
49
+ ol li {
50
+ margin-left: 0;
51
+ margin-right: 30px;
52
+ }
53
+ }
54
+ }
55
+
56
  .wprm-recipe-container .wprm-recipe-tastefully-simple,
57
  .wprm-print .wprm-recipe-tastefully-simple {
58
  font: 12px Verdana, Arial, Geneva, sans-serif;
217
  }
218
  }
219
  }
220
+
 
 
 
 
 
 
 
 
221
  @media only screen and (max-width: 480px) {
222
+ .wprm-recipe-container .wprm-recipe-tastefully-simple,
223
+ .rtl .wprm-recipe-container .wprm-recipe-tastefully-simple {
224
  .wprm-recipe-image-container {
225
  float: none;
226
  width: 100%;
230
 
231
  .wprm-recipe-image {
232
  margin-left: 0;
233
+ margin-right: 0;
234
  }
235
  }
236
  .wprm-recipe-times-container {
wp-recipe-maker.php CHANGED
@@ -15,7 +15,7 @@
15
  * Plugin Name: WP Recipe Maker
16
  * Plugin URI: http://bootstrapped.ventures/wp-recipe-maker/
17
  * Description: The easy and user-friendly recipe plugin for everyone. Automatic JSON-LD metadata for better SEO will get you more visitors!
18
- * Version: 1.21.0
19
  * Author: Bootstrapped Ventures
20
  * Author URI: http://bootstrapped.ventures/
21
  * License: GPL-2.0+
15
  * Plugin Name: WP Recipe Maker
16
  * Plugin URI: http://bootstrapped.ventures/wp-recipe-maker/
17
  * Description: The easy and user-friendly recipe plugin for everyone. Automatic JSON-LD metadata for better SEO will get you more visitors!
18
+ * Version: 1.22.0
19
  * Author: Bootstrapped Ventures
20
  * Author URI: http://bootstrapped.ventures/
21
  * License: GPL-2.0+