Yasr – Yet Another Stars Rating - Version 3.0.8

Version Description

  • FIXED: YASR gutenberg panel didn't shop up once hidden
  • TWEAKED: minor changes
Download this release

Release Info

Developer Dudo
Plugin Icon 128x128 Yasr – Yet Another Stars Rating
Version 3.0.8
Comparing to
See all releases

Code changes from version 3.0.7 to 3.0.8

admin/js/guten/yasr-guten-misc.js CHANGED
@@ -1 +1 @@
1
- (()=>{var e={534:(e,t,r)=>{"use strict";r.r(t),r.d(t,{YasrBlocksPanel:()=>R,YasrDivRatingOverall:()=>E,YasrNoSettingsPanel:()=>b,YasrPrintInputId:()=>h,YasrPrintSelectSize:()=>g,YasrProText:()=>v,yasrLabelSelectSize:()=>i,yasrLeaveThisBlankText:()=>m,yasrOptionalText:()=>s,yasrOverallDescription:()=>d,yasrSelectSizeChoose:()=>c,yasrSelectSizeLarge:()=>y,yasrSelectSizeMedium:()=>p,yasrSelectSizeSmall:()=>u,yasrVisitorVotesDescription:()=>f});var a=r(534),n=wp.i18n.__,o=wp.components.PanelBody,l=wp.blockEditor.InspectorControls,s=n("All these settings are optional","yet-another-stars-rating"),i=n("Choose Size","yet-another-stars-rating"),c=n("Choose stars size","yet-another-stars-rating"),u=n("Small","yet-another-stars-rating"),p=n("Medium","yet-another-stars-rating"),y=n("Large","yet-another-stars-rating"),m=n("Leave this blank if you don't know what you're doing.","yet-another-stars-rating"),d=n("Remember: only the post author can rate here.","yet-another-stars-rating"),f=n("This is the star set where your users will be able to vote","yet-another-stars-rating");function g(e){return React.createElement("form",null,React.createElement("select",{value:e.size,onChange:function(t){return(0,e.setAttributes)({size:(r=t).target.querySelector("option:checked").value}),void r.preventDefault();var r}},React.createElement("option",{value:"--"},a.yasrSelectSizeChoose),React.createElement("option",{value:"small"},a.yasrSelectSizeSmall),React.createElement("option",{value:"medium"},a.yasrSelectSizeMedium),React.createElement("option",{value:"large"},a.yasrSelectSizeLarge)))}function h(e){var t;return!1!==e.postId&&(t=e.postId),React.createElement("div",null,React.createElement("input",{type:"text",size:"4",defaultValue:t,onKeyPress:function(t){return function(e,t){if("Enter"===t.key){var r=t.target.value;!0!==/^\d+$/.test(r)&&""!==r||e({postId:r}),t.preventDefault()}}(e.setAttributes,t)}}))}function v(){var e=n("To be able to customize this ranking, you need","yet-another-stars-rating"),t=n("You can buy the plugin, including support, updates and upgrades, on","yet-another-stars-rating");return React.createElement("h3",null,e," ",React.createElement("a",{href:"https://yetanotherstarsrating.com/?utm_source=wp-plugin&utm_medium=gutenberg_panel&utm_campaign=yasr_editor_screen&utm_content=rankings#yasr-pro"},"Yasr Pro."),React.createElement("br",null),t," ",React.createElement("a",{href:"https://yetanotherstarsrating.com/?utm_source=wp-plugin&utm_medium=gutenberg_panel&utm_campaign=yasr_editor_screen&utm_content=rankings"},"yetanotherstarsrating.com"))}function b(e){return React.createElement("div",null,React.createElement(v,null))}function R(e){var t;return"visitors"===e.block&&(t=f),"overall"===e.block&&(t=d),React.createElement(l,null,"overall"===e.block&&React.createElement(E,null),React.createElement(o,{title:"Settings"},React.createElement("h3",null,s),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,i),React.createElement("div",null,React.createElement(g,{size:e.size,setAttributes:e.setAttributes}))),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,"Post ID"),React.createElement(h,{postId:e.postId,setAttributes:e.setAttributes}),React.createElement("div",{className:"yasr-guten-block-explain"},"Use return (↵) to save."),React.createElement("p",null,m)),React.createElement("div",{className:"yasr-guten-block-panel"},t)))}function E(e){if(!0===JSON.parse(yasrConstantGutenberg.isFseElement))return React.createElement("div",{className:"yasr-guten-block-panel yasr-guten-block-panel-center"},React.createElement("div",null,n("This is a template file, you can't rate here. You need to insert the rating inside the single post or page","yet-another-stars-rating")),React.createElement("br",null));var t=n("Rate this article / item","yet-another-stars-rating"),r=wp.data.select("core/editor").getCurrentPost().meta.yasr_overall_rating,a=function(e,t){e=e.toFixed(1),e=parseFloat(e),wp.data.dispatch("core/editor").editPost({meta:{yasr_overall_rating:e}}),this.setRating(e),t()};return React.createElement("div",{className:"yasr-guten-block-panel yasr-guten-block-panel-center"},t,React.createElement("div",{id:"overall-rater",ref:function(){return yasrSetRaterValue(32,"overall-rater",!1,.1,!1,r,a)}}))}}},t={};function r(a){var n=t[a];if(void 0!==n)return n.exports;var o=t[a]={exports:{}};return e[a](o,o.exports,r),o.exports}r.d=(e,t)=>{for(var a in t)r.o(t,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function r(e,t){return r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},r(e,t)}function a(t,r){if(r&&("object"===e(r)||"function"==typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t)}function n(e){return n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(e)}var o=wp.i18n.__,l=wp.blocks.registerBlockType,s=wp.components,i=s.PanelBody,c=(s.PanelRow,wp.element.Fragment),u=wp.editor,p=(u.BlockControls,u.InspectorControls),y=o("All these settings are optional","yet-another-stars-rating"),m=o("Choose Size","yet-another-stars-rating"),d=o("Choose stars size","yet-another-stars-rating"),f=o("Small","yet-another-stars-rating"),g=o("Medium","yet-another-stars-rating"),h=o("Large","yet-another-stars-rating"),v=o("Leave this blank if you don't know what you're doing.","yet-another-stars-rating"),b=o("Remember: only the post author can rate here.","yet-another-stars-rating"),R=o("This is the star set where your users will be able to vote","yet-another-stars-rating"),E=o('This block is now deprecated. It will still work, but I suggest to replace it with the new one by simply removing it and adding "Yasr Overall Rating" again.',"yet-another-stars-rating"),w=o('This block is now deprecated. It will still work, but I suggest to replace it with the new one by simply removing it and adding "Yasr Visitors Votes" again.',"yet-another-stars-rating");l("yet-another-stars-rating/yasr-overall-rating",{title:o("[DEPRECATED]Yasr: Overall Rating","yet-another-stars-rating"),description:E,icon:"star-half",keywords:[o("rating","yet-another-stars-rating"),o("author","yet-another-stars-rating"),o("overall","yet-another-stars-rating")],attributes:{overallRatingMeta:{type:"number",source:"meta",meta:"yasr_overall_rating"},size:{type:"string",default:"--"},postId:{type:"string",default:"--"}},edit:function(e){var l,s=e.attributes,u=s.overallRatingMeta,R=s.size,E=s.postId,w=e.setAttributes,k=e.isSelected,_=u,S=null,P=null;"--"!==R&&(S=' size="'+R+'"'),l=/^\d+$/.test(E),"--"!==E&&!0===l&&(P=' postid="'+E+'"');var O=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)}(p,React.Component);var l,s,i,c,u=(i=p,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=n(i);if(c){var r=n(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return a(this,e)});function p(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,p),(t=u.call(this,e)).yasrOverallRateThis=o("Rate this article / item","yet-another-stars-rating"),t}return l=p,(s=[{key:"render",value:function(){return React.createElement("div",null,this.yasrOverallRateThis,React.createElement("div",null,React.createElement("div",{id:"overall-rater",ref:function(){return raterJs({starSize:32,step:.1,showToolTip:!1,rating:_,readOnly:!1,element:document.querySelector("#overall-rater"),rateCallback:function(e,t){e=e.toFixed(1),e=parseFloat(e),w({overallRatingMeta:e}),this.setRating(e),t()}})}})))}}])&&t(l.prototype,s),Object.defineProperty(l,"prototype",{writable:!1}),p}();function z(){return React.createElement("form",null,React.createElement("select",{value:R,onChange:I},React.createElement("option",{value:"--"},d),React.createElement("option",{value:"small"},f),React.createElement("option",{value:"medium"},g),React.createElement("option",{value:"large"},h)))}function I(e){var t=e.target.querySelector("option:checked");w({size:t.value}),e.preventDefault()}function C(){return React.createElement("div",null,React.createElement("input",{type:"text",size:"4",onKeyPress:T}))}function T(e){if("Enter"===e.key){var t=e.target.value;!0!==/^\d+$/.test(t)&&""!==t||w({postId:t}),e.preventDefault()}}function N(e){return React.createElement(p,null,React.createElement("div",{class:"yasr-guten-block-panel yasr-guten-block-panel-center"},React.createElement(O,null)),React.createElement(i,{title:"Settings"},React.createElement("h3",null,y),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,m),React.createElement("div",null,React.createElement(z,null))),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,"Post ID"),React.createElement(C,null),React.createElement("div",{className:"yasr-guten-block-explain"},v)),React.createElement("div",{className:"yasr-guten-block-panel"},b)))}return React.createElement(c,null,React.createElement(N,null),React.createElement("div",{className:e.className},"[yasr_overall_rating",S,P,"]",k&&React.createElement(z,null)))},save:function(e){var t=e.attributes,r=t.size,a=t.postId,n="",o=a;return r&&(n+='size="'+r+'"'),a&&("--"===a&&(o=wp.data.select("core/editor").getCurrentPostId()),n+=' postid="'+o+'"'),React.createElement("div",null,"[yasr_overall_rating ",n,"]")}}),l("yet-another-stars-rating/yasr-visitor-votes",{title:o("[DEPRECATED]Yasr: Visitor Votes","yet-another-stars-rating"),description:w,icon:"star-half",keywords:[o("rating","yet-another-stars-rating"),o("visitor","yet-another-stars-rating"),o("votes","yet-another-stars-rating")],attributes:{size:{type:"string",default:"--"},postId:{type:"string",default:"--"}},edit:function(e){var t,r=e.attributes,a=r.size,n=r.postId,o=e.setAttributes,l=e.isSelected,s=null,u=null;function b(){return React.createElement("form",null,React.createElement("select",{value:a,onChange:E},React.createElement("option",{value:"--"},d),React.createElement("option",{value:"small"},f),React.createElement("option",{value:"medium"},g),React.createElement("option",{value:"large"},h)))}function E(e){var t=e.target.querySelector("option:checked");o({size:t.value}),e.preventDefault()}function w(){return React.createElement("div",null,React.createElement("input",{type:"text",size:"4",onKeyPress:k}))}function k(e){if("Enter"===e.key){var t=e.target.value;!0!==/^\d+$/.test(t)&&""!==t||o({postId:t}),e.preventDefault()}}function _(e){return React.createElement(p,null,React.createElement(i,{title:"Settings"},React.createElement("h3",null,y),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,m),React.createElement("div",null,React.createElement(b,null))),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,"Post ID"),React.createElement(w,null),React.createElement("div",{className:"yasr-guten-block-explain"},v)),React.createElement("div",{className:"yasr-guten-block-panel"},R)))}return t=/^\d+$/.test(n),"--"!==a&&(s=' size="'+a+'"'),"--"!==n&&!0===t&&(u=' postid="'+n+'"'),React.createElement(c,null,React.createElement(_,null),React.createElement("div",{className:e.className},"[yasr_visitor_votes",s,u,"]",l&&React.createElement(b,null)))},save:function(e){var t=e.attributes,r=t.size,a=t.postId,n="",o=a;return r&&(n+='size="'+r+'"'),a&&("--"===a&&(o=wp.data.select("core/editor").getCurrentPostId()),n+=' postid="'+o+'"'),React.createElement("div",null,"[yasr_visitor_votes ",n,"]")}}),wp.data.dispatch("core/edit-post").hideBlockTypes("yet-another-stars-rating/yasr-overall-rating"),wp.data.dispatch("core/edit-post").hideBlockTypes("yet-another-stars-rating/yasr-visitor-votes")})(),(()=>{"use strict";var e=r(534);function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function o(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&s(e,t)}function s(e,t){return s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},s(e,t)}function i(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,a=p(e);if(t){var n=p(this).constructor;r=Reflect.construct(a,arguments,n)}else r=a.apply(this,arguments);return c(this,r)}}function c(e,r){if(r&&("object"===t(r)||"function"==typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return u(e)}function u(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function p(e){return p=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},p(e)}var y=wp.i18n.__,m=wp.plugins.registerPlugin,d=wp.editPost,f=d.PluginSidebar,g=d.PluginSidebarMoreMenuItem,h=wp.components.PanelBody,v=wp.element.Fragment,b=function(){return React.createElement("div",null)},R=function(e){l(r,React.Component);var t=i(r);function r(e){var n;a(this,r),n=t.call(this,e);var o=!1;return"yes"===wp.data.select("core/editor").getCurrentPost().meta.yasr_auto_insert_disabled&&(o=!0),n.state={postExcluded:o},n.yasrUpdatePostMetaAutoInsert=n.yasrUpdatePostMetaAutoInsert.bind(u(n)),n}return o(r,[{key:"yasrUpdatePostMetaAutoInsert",value:function(e){var t=e.target,r="checkbox"===t.type?t.checked:t.value;this.setState({postExcluded:r}),!0===r?wp.data.dispatch("core/editor").editPost({meta:{yasr_auto_insert_disabled:"yes"}}):wp.data.dispatch("core/editor").editPost({meta:{yasr_auto_insert_disabled:"no"}})}},{key:"render",value:function(){return React.createElement("div",{className:"yasr-guten-block-panel-center"},React.createElement("hr",null),React.createElement("label",null,React.createElement("span",null,y("Disable auto insert for this post or page?","yet-another-stars-rating"))),React.createElement("div",{className:"yasr-onoffswitch-big yasr-onoffswitch-big-center",id:"yasr-switcher-disable-auto-insert"},React.createElement("input",{type:"checkbox",name:"yasr_auto_insert_disabled",className:"yasr-onoffswitch-checkbox",value:"yes",id:"yasr-auto-insert-disabled-switch",defaultChecked:this.state.postExcluded,onChange:this.yasrUpdatePostMetaAutoInsert}),React.createElement("label",{className:"yasr-onoffswitch-label",htmlFor:"yasr-auto-insert-disabled-switch"},React.createElement("span",{className:"yasr-onoffswitch-inner"}),React.createElement("span",{className:"yasr-onoffswitch-switch"}))))}}]),r}(),E=function(t){l(n,React.Component);var r=i(n);function n(e){var t;a(this,n),t=r.call(this,e);var o=!1;return"disabled"!==yasrConstantGutenberg.autoInsert&&(o=!0),t.state={yasrAutoInsertEnabled:o},t}return o(n,[{key:"render",value:function(){var t=[React.createElement(b,{key:0})];return wp.hooks.doAction("yasr_below_panel",t),React.createElement(v,null,React.createElement(g,{name:"yasr-sidebar",type:"sidebar",target:"yasr-guten-sidebar"},y("YASR post settings","yet-another-stars-rating")),React.createElement(f,{name:"yasr-guten-sidebar",title:"YASR Settings"},React.createElement(h,null,React.createElement("div",{className:"yasr-guten-block-panel yasr-guten-block-panel-center"},React.createElement(e.YasrDivRatingOverall,null),React.createElement("div",null,y('This is the same value that you find the "Yasr: Overall Rating" block.',"yet-another-stars-rating")),this.state.yasrAutoInsertEnabled&&React.createElement(R,null),t))))}}]),n}();m("yasr-sidebar",{icon:"star-half",title:y("Yasr: Settings","yet-another-stars-rating"),render:E})})()})();
1
+ (()=>{var e={534:(e,t,r)=>{"use strict";r.r(t),r.d(t,{YasrBlocksPanel:()=>R,YasrDivRatingOverall:()=>E,YasrNoSettingsPanel:()=>b,YasrPrintInputId:()=>h,YasrPrintSelectSize:()=>g,YasrProText:()=>v,yasrLabelSelectSize:()=>i,yasrLeaveThisBlankText:()=>m,yasrOptionalText:()=>s,yasrOverallDescription:()=>d,yasrSelectSizeChoose:()=>c,yasrSelectSizeLarge:()=>y,yasrSelectSizeMedium:()=>p,yasrSelectSizeSmall:()=>u,yasrVisitorVotesDescription:()=>f});var a=r(534),n=wp.i18n.__,o=wp.components.PanelBody,l=wp.blockEditor.InspectorControls,s=n("All these settings are optional","yet-another-stars-rating"),i=n("Choose Size","yet-another-stars-rating"),c=n("Choose stars size","yet-another-stars-rating"),u=n("Small","yet-another-stars-rating"),p=n("Medium","yet-another-stars-rating"),y=n("Large","yet-another-stars-rating"),m=n("Leave this blank if you don't know what you're doing.","yet-another-stars-rating"),d=n("Remember: only the post author can rate here.","yet-another-stars-rating"),f=n("This is the star set where your users will be able to vote","yet-another-stars-rating");function g(e){return React.createElement("form",null,React.createElement("select",{value:e.size,onChange:function(t){return(0,e.setAttributes)({size:(r=t).target.querySelector("option:checked").value}),void r.preventDefault();var r}},React.createElement("option",{value:"--"},a.yasrSelectSizeChoose),React.createElement("option",{value:"small"},a.yasrSelectSizeSmall),React.createElement("option",{value:"medium"},a.yasrSelectSizeMedium),React.createElement("option",{value:"large"},a.yasrSelectSizeLarge)))}function h(e){var t;return!1!==e.postId&&(t=e.postId),React.createElement("div",null,React.createElement("input",{type:"text",size:"4",defaultValue:t,onKeyPress:function(t){return function(e,t){if("Enter"===t.key){var r=t.target.value;!0!==/^\d+$/.test(r)&&""!==r||e({postId:r}),t.preventDefault()}}(e.setAttributes,t)}}))}function v(){var e=n("To be able to customize this ranking, you need","yet-another-stars-rating"),t=n("You can buy the plugin, including support, updates and upgrades, on","yet-another-stars-rating");return React.createElement("h3",null,e," ",React.createElement("a",{href:"https://yetanotherstarsrating.com/?utm_source=wp-plugin&utm_medium=gutenberg_panel&utm_campaign=yasr_editor_screen&utm_content=rankings#yasr-pro"},"Yasr Pro."),React.createElement("br",null),t," ",React.createElement("a",{href:"https://yetanotherstarsrating.com/?utm_source=wp-plugin&utm_medium=gutenberg_panel&utm_campaign=yasr_editor_screen&utm_content=rankings"},"yetanotherstarsrating.com"))}function b(e){return React.createElement("div",null,React.createElement(v,null))}function R(e){var t;return"visitors"===e.block&&(t=f),"overall"===e.block&&(t=d),React.createElement(l,null,"overall"===e.block&&React.createElement(E,null),React.createElement(o,{title:"Settings"},React.createElement("h3",null,s),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,i),React.createElement("div",null,React.createElement(g,{size:e.size,setAttributes:e.setAttributes}))),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,"Post ID"),React.createElement(h,{postId:e.postId,setAttributes:e.setAttributes}),React.createElement("div",{className:"yasr-guten-block-explain"},"Use return (↵) to save."),React.createElement("p",null,m)),React.createElement("div",{className:"yasr-guten-block-panel"},t)))}function E(e){if(!0===JSON.parse(yasrConstantGutenberg.isFseElement))return React.createElement("div",{className:"yasr-guten-block-panel yasr-guten-block-panel-center"},React.createElement("div",null,n("This is a template file, you can't rate here. You need to insert the rating inside the single post or page","yet-another-stars-rating")),React.createElement("br",null));var t=n("Rate this article / item","yet-another-stars-rating"),r=wp.data.select("core/editor").getCurrentPost().meta.yasr_overall_rating,a=function(e,t){e=e.toFixed(1),e=parseFloat(e),wp.data.dispatch("core/editor").editPost({meta:{yasr_overall_rating:e}}),this.setRating(e),t()};return React.createElement("div",{className:"yasr-guten-block-panel yasr-guten-block-panel-center"},t,React.createElement("div",{id:"overall-rater",ref:function(){return yasrSetRaterValue(32,"overall-rater",!1,.1,!1,r,a)}}))}}},t={};function r(a){var n=t[a];if(void 0!==n)return n.exports;var o=t[a]={exports:{}};return e[a](o,o.exports,r),o.exports}r.d=(e,t)=>{for(var a in t)r.o(t,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function r(e,t){return r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},r(e,t)}function a(t,r){if(r&&("object"===e(r)||"function"==typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t)}function n(e){return n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(e)}var o=wp.i18n.__,l=wp.blocks.registerBlockType,s=wp.components,i=s.PanelBody,c=(s.PanelRow,wp.element.Fragment),u=wp.editor,p=(u.BlockControls,u.InspectorControls),y=o("All these settings are optional","yet-another-stars-rating"),m=o("Choose Size","yet-another-stars-rating"),d=o("Choose stars size","yet-another-stars-rating"),f=o("Small","yet-another-stars-rating"),g=o("Medium","yet-another-stars-rating"),h=o("Large","yet-another-stars-rating"),v=o("Leave this blank if you don't know what you're doing.","yet-another-stars-rating"),b=o("Remember: only the post author can rate here.","yet-another-stars-rating"),R=o("This is the star set where your users will be able to vote","yet-another-stars-rating"),E=o('This block is now deprecated. It will still work, but I suggest to replace it with the new one by simply removing it and adding "Yasr Overall Rating" again.',"yet-another-stars-rating"),w=o('This block is now deprecated. It will still work, but I suggest to replace it with the new one by simply removing it and adding "Yasr Visitors Votes" again.',"yet-another-stars-rating");l("yet-another-stars-rating/yasr-overall-rating",{title:o("[DEPRECATED]Yasr: Overall Rating","yet-another-stars-rating"),description:E,icon:"star-half",keywords:[o("rating","yet-another-stars-rating"),o("author","yet-another-stars-rating"),o("overall","yet-another-stars-rating")],attributes:{overallRatingMeta:{type:"number",source:"meta",meta:"yasr_overall_rating"},size:{type:"string",default:"--"},postId:{type:"string",default:"--"}},edit:function(e){var l,s=e.attributes,u=s.overallRatingMeta,R=s.size,E=s.postId,w=e.setAttributes,k=e.isSelected,_=u,S=null,P=null;"--"!==R&&(S=' size="'+R+'"'),l=/^\d+$/.test(E),"--"!==E&&!0===l&&(P=' postid="'+E+'"');var O=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)}(p,React.Component);var l,s,i,c,u=(i=p,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=n(i);if(c){var r=n(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return a(this,e)});function p(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,p),(t=u.call(this,e)).yasrOverallRateThis=o("Rate this article / item","yet-another-stars-rating"),t}return l=p,(s=[{key:"render",value:function(){return React.createElement("div",null,this.yasrOverallRateThis,React.createElement("div",null,React.createElement("div",{id:"overall-rater",ref:function(){return raterJs({starSize:32,step:.1,showToolTip:!1,rating:_,readOnly:!1,element:document.querySelector("#overall-rater"),rateCallback:function(e,t){e=e.toFixed(1),e=parseFloat(e),w({overallRatingMeta:e}),this.setRating(e),t()}})}})))}}])&&t(l.prototype,s),Object.defineProperty(l,"prototype",{writable:!1}),p}();function z(){return React.createElement("form",null,React.createElement("select",{value:R,onChange:I},React.createElement("option",{value:"--"},d),React.createElement("option",{value:"small"},f),React.createElement("option",{value:"medium"},g),React.createElement("option",{value:"large"},h)))}function I(e){var t=e.target.querySelector("option:checked");w({size:t.value}),e.preventDefault()}function C(){return React.createElement("div",null,React.createElement("input",{type:"text",size:"4",onKeyPress:T}))}function T(e){if("Enter"===e.key){var t=e.target.value;!0!==/^\d+$/.test(t)&&""!==t||w({postId:t}),e.preventDefault()}}function N(e){return React.createElement(p,null,React.createElement("div",{class:"yasr-guten-block-panel yasr-guten-block-panel-center"},React.createElement(O,null)),React.createElement(i,{title:"Settings"},React.createElement("h3",null,y),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,m),React.createElement("div",null,React.createElement(z,null))),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,"Post ID"),React.createElement(C,null),React.createElement("div",{className:"yasr-guten-block-explain"},v)),React.createElement("div",{className:"yasr-guten-block-panel"},b)))}return React.createElement(c,null,React.createElement(N,null),React.createElement("div",{className:e.className},"[yasr_overall_rating",S,P,"]",k&&React.createElement(z,null)))},save:function(e){var t=e.attributes,r=t.size,a=t.postId,n="",o=a;return r&&(n+='size="'+r+'"'),a&&("--"===a&&(o=wp.data.select("core/editor").getCurrentPostId()),n+=' postid="'+o+'"'),React.createElement("div",null,"[yasr_overall_rating ",n,"]")}}),l("yet-another-stars-rating/yasr-visitor-votes",{title:o("[DEPRECATED]Yasr: Visitor Votes","yet-another-stars-rating"),description:w,icon:"star-half",keywords:[o("rating","yet-another-stars-rating"),o("visitor","yet-another-stars-rating"),o("votes","yet-another-stars-rating")],attributes:{size:{type:"string",default:"--"},postId:{type:"string",default:"--"}},edit:function(e){var t,r=e.attributes,a=r.size,n=r.postId,o=e.setAttributes,l=e.isSelected,s=null,u=null;function b(){return React.createElement("form",null,React.createElement("select",{value:a,onChange:E},React.createElement("option",{value:"--"},d),React.createElement("option",{value:"small"},f),React.createElement("option",{value:"medium"},g),React.createElement("option",{value:"large"},h)))}function E(e){var t=e.target.querySelector("option:checked");o({size:t.value}),e.preventDefault()}function w(){return React.createElement("div",null,React.createElement("input",{type:"text",size:"4",onKeyPress:k}))}function k(e){if("Enter"===e.key){var t=e.target.value;!0!==/^\d+$/.test(t)&&""!==t||o({postId:t}),e.preventDefault()}}function _(e){return React.createElement(p,null,React.createElement(i,{title:"Settings"},React.createElement("h3",null,y),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,m),React.createElement("div",null,React.createElement(b,null))),React.createElement("div",{className:"yasr-guten-block-panel"},React.createElement("label",null,"Post ID"),React.createElement(w,null),React.createElement("div",{className:"yasr-guten-block-explain"},v)),React.createElement("div",{className:"yasr-guten-block-panel"},R)))}return t=/^\d+$/.test(n),"--"!==a&&(s=' size="'+a+'"'),"--"!==n&&!0===t&&(u=' postid="'+n+'"'),React.createElement(c,null,React.createElement(_,null),React.createElement("div",{className:e.className},"[yasr_visitor_votes",s,u,"]",l&&React.createElement(b,null)))},save:function(e){var t=e.attributes,r=t.size,a=t.postId,n="",o=a;return r&&(n+='size="'+r+'"'),a&&("--"===a&&(o=wp.data.select("core/editor").getCurrentPostId()),n+=' postid="'+o+'"'),React.createElement("div",null,"[yasr_visitor_votes ",n,"]")}}),wp.data.dispatch("core/edit-post").hideBlockTypes("yet-another-stars-rating/yasr-overall-rating"),wp.data.dispatch("core/edit-post").hideBlockTypes("yet-another-stars-rating/yasr-visitor-votes")})(),(()=>{"use strict";var e=r(534);function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function o(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&s(e,t)}function s(e,t){return s=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},s(e,t)}function i(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,a=p(e);if(t){var n=p(this).constructor;r=Reflect.construct(a,arguments,n)}else r=a.apply(this,arguments);return c(this,r)}}function c(e,r){if(r&&("object"===t(r)||"function"==typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return u(e)}function u(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function p(e){return p=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},p(e)}var y=wp.i18n.__,m=wp.plugins.registerPlugin,d=wp.editPost,f=d.PluginSidebar,g=d.PluginSidebarMoreMenuItem,h=wp.components.PanelBody,v=wp.element.Fragment,b=function(){return React.createElement("div",null)},R=function(e){l(r,React.Component);var t=i(r);function r(e){var n;a(this,r),n=t.call(this,e);var o=!1;return"yes"===wp.data.select("core/editor").getCurrentPost().meta.yasr_auto_insert_disabled&&(o=!0),n.state={postExcluded:o},n.yasrUpdatePostMetaAutoInsert=n.yasrUpdatePostMetaAutoInsert.bind(u(n)),n}return o(r,[{key:"yasrUpdatePostMetaAutoInsert",value:function(e){var t=e.target,r="checkbox"===t.type?t.checked:t.value;this.setState({postExcluded:r}),!0===r?wp.data.dispatch("core/editor").editPost({meta:{yasr_auto_insert_disabled:"yes"}}):wp.data.dispatch("core/editor").editPost({meta:{yasr_auto_insert_disabled:"no"}})}},{key:"render",value:function(){return React.createElement("div",{className:"yasr-guten-block-panel-center"},React.createElement("hr",null),React.createElement("label",null,React.createElement("span",null,y("Disable auto insert for this post or page?","yet-another-stars-rating"))),React.createElement("div",{className:"yasr-onoffswitch-big yasr-onoffswitch-big-center",id:"yasr-switcher-disable-auto-insert"},React.createElement("input",{type:"checkbox",name:"yasr_auto_insert_disabled",className:"yasr-onoffswitch-checkbox",value:"yes",id:"yasr-auto-insert-disabled-switch",defaultChecked:this.state.postExcluded,onChange:this.yasrUpdatePostMetaAutoInsert}),React.createElement("label",{className:"yasr-onoffswitch-label",htmlFor:"yasr-auto-insert-disabled-switch"},React.createElement("span",{className:"yasr-onoffswitch-inner"}),React.createElement("span",{className:"yasr-onoffswitch-switch"}))))}}]),r}(),E=function(t){l(n,React.Component);var r=i(n);function n(e){var t;a(this,n),t=r.call(this,e);var o=!1;return"disabled"!==yasrConstantGutenberg.autoInsert&&(o=!0),t.state={yasrAutoInsertEnabled:o},t}return o(n,[{key:"render",value:function(){var t=[React.createElement(b,{key:0})];return wp.hooks.doAction("yasr_below_panel",t),React.createElement(v,null,React.createElement(g,{target:"yasr-guten-sidebar"},y("YASR post settings","yet-another-stars-rating")),React.createElement(f,{name:"yasr-guten-sidebar",title:"YASR Settings"},React.createElement(h,null,React.createElement("div",{className:"yasr-guten-block-panel yasr-guten-block-panel-center"},React.createElement(e.YasrDivRatingOverall,null),React.createElement("div",null,y('This is the same value that you find the "Yasr: Overall Rating" block.',"yet-another-stars-rating")),this.state.yasrAutoInsertEnabled&&React.createElement(R,null),t))))}}]),n}();m("yasr-sidebar",{icon:"star-half",title:y("Yasr: Settings","yet-another-stars-rating"),render:E})})()})();
admin/js/src/guten/yasr-guten-panel.js CHANGED
@@ -8,7 +8,7 @@ const ContentBelowSidebar = () => {
8
  return <div/>;
9
  };
10
 
11
- import {YasrDivRatingOverall} from './blocks/yasrGutenUtils';
12
 
13
  /**
14
  * Show auto insert option
@@ -93,7 +93,7 @@ class yasrSidebar extends React.Component {
93
  {wp.hooks.doAction('yasr_below_panel', YasrBelowSidebar)}
94
  return (
95
  <Fragment>
96
- <PluginSidebarMoreMenuItem name="yasr-sidebar" type="sidebar" target="yasr-guten-sidebar" >
97
  { __( 'YASR post settings', 'yet-another-stars-rating' ) }
98
  </PluginSidebarMoreMenuItem>
99
  <PluginSidebar name="yasr-guten-sidebar" title="YASR Settings">
8
  return <div/>;
9
  };
10
 
11
+ import {YasrDivRatingOverall} from 'yasrGutenUtils';
12
 
13
  /**
14
  * Show auto insert option
93
  {wp.hooks.doAction('yasr_below_panel', YasrBelowSidebar)}
94
  return (
95
  <Fragment>
96
+ <PluginSidebarMoreMenuItem target="yasr-guten-sidebar" >
97
  { __( 'YASR post settings', 'yet-another-stars-rating' ) }
98
  </PluginSidebarMoreMenuItem>
99
  <PluginSidebar name="yasr-guten-sidebar" title="YASR Settings">
admin/settings/yasr-settings-functions-misc.php CHANGED
@@ -279,32 +279,60 @@ function yasr_upgrade_pro_box()
279
  */
280
  function yasr_resources_box()
281
  {
282
- $div = "<div class='yasr-donatedivdx' id='yasr-resources-box'>";
283
- $text = '<div class="yasr-donate-title">Resources</div>';
284
- $text .= '<div class="yasr-donate-single-resource">
285
- <span class="dashicons dashicons-star-filled" style="color: #ccc"></span>
286
- <a target="blank" href="https://yetanotherstarsrating.com/?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=yasr_official">' . __( 'YASR official website', 'yet-another-stars-rating' ) . '</a>
287
- </div>';
288
- $text .= '<div class="yasr-donate-single-resource">
289
- <span class="dashicons dashicons-edit" style="color: #ccc"></span>
290
- <a target="blank" href="https://yetanotherstarsrating.com/docs/?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=documentation">' . __( 'Documentation', 'yet-another-stars-rating' ) . '</a>
291
- </div>';
292
- $text .= '<div class="yasr-donate-single-resource">
293
- <span class="dashicons dashicons-book-alt" style="color: #ccc"></span>
294
- <a target="blank" href="https://yetanotherstarsrating.com/docs/faq/?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=faq">' . __( 'F.A.Q.', 'yet-another-stars-rating' ) . '</a>
295
- </div>';
296
- $text .= '<div class="yasr-donate-single-resource">
297
- <span class="dashicons dashicons-video-alt3" style="color: #ccc"></span>
298
- <a target="blank" href="https://www.youtube.com/channel/UCU5jbO1PJsUUsCNbME9S-Zw">' . __( 'Youtube channel', 'yet-another-stars-rating' ) . '</a>
299
- </div>';
300
- $text .= '<div class="yasr-donate-single-resource">
301
- <span class="dashicons dashicons-smiley" style="color: #ccc"></span>
302
- <a target="blank" href="https://yetanotherstarsrating.com/#yasr-pro?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=yasr-pro">
303
- Yasr Pro
304
- </a>
305
- </div>';
306
- $div_and_text = $div . $text . '</div>';
307
- echo wp_kses_post( $div_and_text ) ;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
308
  }
309
 
310
  /**
@@ -326,8 +354,8 @@ function yasr_buy_cofee()
326
  $div = "<div class='yasr-donatedivdx' id='yasr-buy-cofee'>";
327
  $text = '<div class="yasr-donate-title">' . __( 'Buy me a coffee!', 'yet-another-stars-rating' ) . '</div>';
328
  $text .= '<div style="text-align: center">';
329
- $text .= '<a href="https://www.buymeacoffee.com/dariocurvino" target="_blank">
330
- <img src="' . YASR_IMG_DIR . '/buymecofyel.png" alt="buymeacofee">
331
  </a>';
332
  $text .= '</div>';
333
  $text .= '<div style="margin-top: 15px;">';
@@ -432,8 +460,8 @@ function yasr_right_settings_panel()
432
  }
433
 
434
  /** Change default admin footer on yasr settings pages
435
- * $text is the default wordpress text
436
- * Since 0.8.9
437
  */
438
  add_filter( 'admin_footer_text', 'yasr_custom_admin_footer' );
439
  function yasr_custom_admin_footer( $text )
279
  */
280
  function yasr_resources_box()
281
  {
282
+ ?>
283
+
284
+ <div class='yasr-donatedivdx' id='yasr-resources-box'>
285
+ <div class="yasr-donate-title">Resources</div>
286
+ <div class="yasr-donate-single-resource">
287
+ <span class="dashicons dashicons-star-filled" style="color: #6c6c6c"></span>
288
+ <a target="blank" href="https://yetanotherstarsrating.com/?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=yasr_official">
289
+ <?php
290
+ esc_html_e( 'YASR official website', 'yet-another-stars-rating' );
291
+ ?>
292
+ </a>
293
+ </div>
294
+ <div class="yasr-donate-single-resource">
295
+ <img src="<?php
296
+ echo esc_attr( YASR_IMG_DIR . 'github.svg' ) ;
297
+ ?>"
298
+ width="20" height="20" alt="github logo" style="vertical-align: bottom;">
299
+ <a target="blank" href="https://github.com/Dudo1985/yet-another-stars-rating">
300
+ GitHub Page
301
+ </a>
302
+ </div>
303
+ <div class="yasr-donate-single-resource">
304
+ <span class="dashicons dashicons-edit" style="color: #6c6c6c"></span>
305
+ <a target="blank" href="https://yetanotherstarsrating.com/docs/?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=documentation">
306
+ <?php
307
+ esc_html_e( 'Documentation', 'yet-another-stars-rating' );
308
+ ?>
309
+ </a>
310
+ </div>
311
+ <div class="yasr-donate-single-resource">
312
+ <span class="dashicons dashicons-book-alt" style="color: #6c6c6c"></span>
313
+ <a target="blank" href="https://yetanotherstarsrating.com/docs/faq/?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=faq">
314
+ <?php
315
+ esc_html_e( 'F.A.Q.', 'yet-another-stars-rating' );
316
+ ?>
317
+ </a>
318
+ </div>
319
+ <div class="yasr-donate-single-resource">
320
+ <span class="dashicons dashicons-video-alt3" style="color: #6c6c6c"></span>
321
+ <a target="blank" href="https://www.youtube.com/channel/UCU5jbO1PJsUUsCNbME9S-Zw">
322
+ <?php
323
+ esc_html_e( 'Youtube channel', 'yet-another-stars-rating' );
324
+ ?>
325
+ </a>
326
+ </div>
327
+ <div class="yasr-donate-single-resource">
328
+ <span class="dashicons dashicons-smiley" style="color: #6c6c6c"></span>
329
+ <a target="blank" href="https://yetanotherstarsrating.com/#yasr-pro?utm_source=wp-plugin&utm_medium=settings_resources&utm_campaign=yasr_settings&utm_content=yasr-pro">
330
+ Yasr Pro
331
+ </a>
332
+ </div>
333
+ </div>
334
+
335
+ <?php
336
  }
337
 
338
  /**
354
  $div = "<div class='yasr-donatedivdx' id='yasr-buy-cofee'>";
355
  $text = '<div class="yasr-donate-title">' . __( 'Buy me a coffee!', 'yet-another-stars-rating' ) . '</div>';
356
  $text .= '<div style="text-align: center">';
357
+ $text .= '<a href="https://www.paypal.com/donate/?hosted_button_id=SVTAVUF62QZ4W" target="_blank">
358
+ <img src="' . YASR_IMG_DIR . '/button_paypal.png" alt="paypal" width="200">
359
  </a>';
360
  $text .= '</div>';
361
  $text .= '<div style="margin-top: 15px;">';
460
  }
461
 
462
  /** Change default admin footer on yasr settings pages
463
+ * $text is the default wordpress text
464
+ * Since 0.8.9
465
  */
466
  add_filter( 'admin_footer_text', 'yasr_custom_admin_footer' );
467
  function yasr_custom_admin_footer( $text )
admin/yasr-admin-functions.php CHANGED
@@ -108,6 +108,7 @@ function yasr_add_admin_scripts($hook) {
108
  if ($hook === $yasr_settings_page) {
109
  YasrScriptsLoader::loadCodeEditor();
110
  YasrScriptsLoader::loadAdminSettings();
 
111
  }
112
 
113
  }
108
  if ($hook === $yasr_settings_page) {
109
  YasrScriptsLoader::loadCodeEditor();
110
  YasrScriptsLoader::loadAdminSettings();
111
+ YasrScriptsLoader::loadTableCss();
112
  }
113
 
114
  }
changelog.txt CHANGED
@@ -1,3 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
 
2
  [//]: # fs_premium_only_begin
3
  = 2.9.0.1 =
1
+ = 2.9.8 =
2
+ * TWEAKED: updated rest api
3
+ * FIX: softwareApplication itemType didn't get saved
4
+ * Fix: impossible to rate for overall rating in certain circumstances.
5
+ * Fix: minor css fixes in admin area
6
+
7
+ = 2.9.7 =
8
+ * NEW FEATURE: auto insert option has now a new feature: it is possible to place shortcodes on both above and below the content
9
+ * TWEAKED: attribute 'custom-fields' is added for all CPTS, to avoid compatibility issue in Gutenberg
10
+ * TWEAKED: nonces are checked only for logged in users.
11
+ * TWEAKED: "Stats" page is now renamed in "Manage Ratings"
12
+ * TWEAKED: below the editor is now easier to manage Multi Sets
13
+ [//]: # fs_premium_only_begin
14
+ PREMIUM ONLY:
15
+ * NEW FEATURE: is now possible to use Multi Set along with user reviews!
16
+ To enable it, just select "YES" to "Insert this Multi Set in the comment form?"
17
+ [//]: # fs_premium_only_end
18
+
19
+ = 2.9.6 =
20
+ * FIXED: support for wp_template and wp_template_part CPT, used by FSE
21
+ * FIXED: html tags in custom texts didn't work
22
+ [//]: # fs_premium_only_begin
23
+ PREMIUM ONLY:
24
+ * FIXED: comments feed didn't work if reviews in comment are enabled
25
+ [//]: # fs_premium_only_end
26
+
27
+ = 2.9.5 =
28
+ * NEW FEATURE: In the settings, is now possible to customize the text when a rating is saved / updated
29
+ * minor fixes
30
+
31
+ = 2.9.4 =
32
+ * Minor changes
33
+
34
+ = 2.9.3 =
35
+ * TWEAKED: Added support for Catch Infinite Scroll
36
+
37
+ = 2.9.2 =
38
+ * FIXED: rich snippets error that could occur in some circumstances
39
+ * FIXED: css fix
40
+ * TWEAKED: code cleanup
41
+
42
+ = 2.9.1 =
43
+ * FIXED: if shortcode exists for a post or page, but there are no ratings, wrong rich snippets are returned
44
 
45
  [//]: # fs_premium_only_begin
46
  = 2.9.0.1 =
includes/classes/YasrScriptsLoader.php CHANGED
@@ -13,22 +13,18 @@ class YasrScriptsLoader {
13
  */
14
  public function loadRequiredScripts() {
15
  //Adds window.var needed in both admin and public
16
- add_action('wp_enqueue_scripts', array($this, 'loadWindowVar'), 11);
17
- add_action('admin_enqueue_scripts', array($this, 'loadWindowVar'), 11);
18
 
19
- //Adds css needed in both admin and public
20
- add_action('wp_enqueue_scripts', array($this, 'loadTableCss'), 11);
21
- add_action('admin_enqueue_scripts', array($this, 'loadTableCss'), 11);
22
-
23
- add_action('yasr_add_front_script_css', array($this, 'loadRtlSupport'));
24
- add_action('yasr_add_admin_scripts_end', array($this, 'loadRtlSupport'));
25
 
26
  /*** Css rules for stars set, from version 1.2.7
27
  * Here I use add_action instead of directly use wp_add_inline_style so I can
28
  * use remove_action if needed (e.g. Yasr Stylish)
29
  ***/
30
- add_action('yasr_add_front_script_css', array($this, 'loadCssStarsSet'));
31
- add_action('yasr_add_admin_scripts_end', array($this, 'loadCssStarsSet'));
32
 
33
  //enqueue gutenberg stuff outside blocks
34
  add_action('enqueue_block_editor_assets', array($this, 'initGutenMisc'));
@@ -98,13 +94,40 @@ class YasrScriptsLoader {
98
  }
99
  }
100
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
101
  /**
102
  * Load Multiset and ranking css
103
  *
104
  * @author Dario Curvino <@dudo>
105
- * @since 3.0.5
106
  */
107
- public function loadTableCss () {
108
  $yasr_multiset_theme_handle = 'yasrcsslightscheme';
109
  $yasr_multiset_theme = 'yasr-table-light.css';
110
 
@@ -168,7 +191,8 @@ class YasrScriptsLoader {
168
  */
169
  public function loadRtlSupport() {
170
  if (is_rtl()) {
171
- $yasr_rtl_css = '.yasr-star-rating .yasr-star-value {
 
172
  -moz-transform: scaleX(-1);
173
  -o-transform: scaleX(-1);
174
  -webkit-transform: scaleX(-1);
@@ -188,7 +212,7 @@ class YasrScriptsLoader {
188
  *
189
  * @author Dario Curvino <@dudo>
190
  */
191
- public function loadCssStarsSet() {
192
  //if star selected is "rater", select the images
193
  if (YASR_STARS_SET === 'rater') {
194
  $star_grey = YASR_IMG_DIR . 'star_0.svg';
13
  */
14
  public function loadRequiredScripts() {
15
  //Adds window.var needed in both admin and public
16
+ add_action('wp_enqueue_scripts', array($this, 'loadWindowVar'), 11);
17
+ add_action('admin_enqueue_scripts', array($this, 'loadWindowVar'), 11);
18
 
19
+ add_action('yasr_add_front_script_css', array($this, 'loadRtlSupport'));
20
+ add_action('yasr_add_admin_scripts_end', array($this, 'loadRtlSupport'));
 
 
 
 
21
 
22
  /*** Css rules for stars set, from version 1.2.7
23
  * Here I use add_action instead of directly use wp_add_inline_style so I can
24
  * use remove_action if needed (e.g. Yasr Stylish)
25
  ***/
26
+ add_action('yasr_add_front_script_css', array($this, 'loadInlineCss'));
27
+ add_action('yasr_add_admin_scripts_end', array($this, 'loadInlineCss'));
28
 
29
  //enqueue gutenberg stuff outside blocks
30
  add_action('enqueue_block_editor_assets', array($this, 'initGutenMisc'));
94
  }
95
  }
96
 
97
+ /**
98
+ * Load main css file
99
+ *
100
+ * @author Dario Curvino <@dudo>
101
+ * @since 3.0.8
102
+ */
103
+ public static function loadRequiredCss() {
104
+ wp_enqueue_style(
105
+ 'yasrcss',
106
+ YASR_CSS_DIR_INCLUDES . 'yasr.css',
107
+ false,
108
+ YASR_VERSION_NUM
109
+ );
110
+
111
+ //Run after default css are loaded
112
+ do_action('yasr_add_front_script_css');
113
+
114
+ if (YASR_CUSTOM_CSS_RULES) {
115
+ wp_add_inline_style(
116
+ 'yasrcss',
117
+ YASR_CUSTOM_CSS_RULES
118
+ );
119
+ }
120
+
121
+ do_action('yasr_add_front_script_js');
122
+ }
123
+
124
  /**
125
  * Load Multiset and ranking css
126
  *
127
  * @author Dario Curvino <@dudo>
128
+ * @since 3.0.5
129
  */
130
+ public static function loadTableCss () {
131
  $yasr_multiset_theme_handle = 'yasrcsslightscheme';
132
  $yasr_multiset_theme = 'yasr-table-light.css';
133
 
191
  */
192
  public function loadRtlSupport() {
193
  if (is_rtl()) {
194
+ $yasr_rtl_css =
195
+ '.yasr-star-rating .yasr-star-value {
196
  -moz-transform: scaleX(-1);
197
  -o-transform: scaleX(-1);
198
  -webkit-transform: scaleX(-1);
212
  *
213
  * @author Dario Curvino <@dudo>
214
  */
215
+ public function loadInlineCss() {
216
  //if star selected is "rater", select the images
217
  if (YASR_STARS_SET === 'rater') {
218
  $star_grey = YASR_IMG_DIR . 'star_0.svg';
includes/css/yasr-table-light.css CHANGED
@@ -46,7 +46,6 @@
46
  background: #ffffff;
47
  }
48
 
49
-
50
  /* Pro rules */
51
 
52
  .yasr-pro-overall-rating-chart-text {
46
  background: #ffffff;
47
  }
48
 
 
49
  /* Pro rules */
50
 
51
  .yasr-pro-overall-rating-chart-text {
includes/css/yasr.css CHANGED
@@ -150,7 +150,7 @@ yasr_pro_comment_reviews_stats shortcode too***/
150
 
151
  .yasr-progress-bar-name {
152
  flex-grow: 1;
153
- flex-basis: 12%;
154
  font-size: 14px !important;
155
  }
156
 
@@ -159,10 +159,10 @@ yasr_pro_comment_reviews_stats shortcode too***/
159
  }
160
 
161
  .yasr-progress-bar-votes-count {
162
- flex-grow: 1;
163
- padding-left: 2px;
164
- padding-right: 2px;
165
  font-size: 14px !important;
 
166
  }
167
 
168
 
150
 
151
  .yasr-progress-bar-name {
152
  flex-grow: 1;
153
+ min-width: 72px;
154
  font-size: 14px !important;
155
  }
156
 
159
  }
160
 
161
  .yasr-progress-bar-votes-count {
162
+ flex-grow: 0;
163
+ text-align: center;
 
164
  font-size: 14px !important;
165
+ min-width: 40px;
166
  }
167
 
168
 
includes/img/button_paypal.png ADDED
Binary file
includes/img/buymecofyel.png DELETED
Binary file
includes/img/github.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="1024" height="1024" viewBox="0 0 1024 1024" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M8 0C3.58 0 0 3.58 0 8C0 11.54 2.29 14.53 5.47 15.59C5.87 15.66 6.02 15.42 6.02 15.21C6.02 15.02 6.01 14.39 6.01 13.72C4 14.09 3.48 13.23 3.32 12.78C3.23 12.55 2.84 11.84 2.5 11.65C2.22 11.5 1.82 11.13 2.49 11.12C3.12 11.11 3.57 11.7 3.72 11.94C4.44 13.15 5.59 12.81 6.05 12.6C6.12 12.08 6.33 11.73 6.56 11.53C4.78 11.33 2.92 10.64 2.92 7.58C2.92 6.71 3.23 5.99 3.74 5.43C3.66 5.23 3.38 4.41 3.82 3.31C3.82 3.31 4.49 3.1 6.02 4.13C6.66 3.95 7.34 3.86 8.02 3.86C8.7 3.86 9.38 3.95 10.02 4.13C11.55 3.09 12.22 3.31 12.22 3.31C12.66 4.41 12.38 5.23 12.3 5.43C12.81 5.99 13.12 6.7 13.12 7.58C13.12 10.65 11.25 11.33 9.47 11.53C9.76 11.78 10.01 12.26 10.01 13.01C10.01 14.08 10 14.94 10 15.21C10 15.42 10.15 15.67 10.55 15.59C13.71 14.53 16 11.53 16 8C16 3.58 12.42 0 8 0Z" transform="scale(64)" fill="#6c6c6c"/>
3
+ </svg>
includes/shortcodes/classes/YasrMultiSet.php CHANGED
@@ -32,6 +32,9 @@ class YasrMultiSet extends YasrShortcode {
32
  public function __construct($atts, $shortcode_name) {
33
  parent::__construct($atts, $shortcode_name);
34
 
 
 
 
35
  $atts = shortcode_atts(
36
  array(
37
  'setid' => YASR_FIRST_SETID,
32
  public function __construct($atts, $shortcode_name) {
33
  parent::__construct($atts, $shortcode_name);
34
 
35
+ //load css only when YasrMultiset or a Ranking is used (YasrRankings extend this)
36
+ YasrScriptsLoader::loadTableCss();
37
+
38
  $atts = shortcode_atts(
39
  array(
40
  'setid' => YASR_FIRST_SETID,
includes/shortcodes/classes/YasrShortcode.php CHANGED
@@ -141,6 +141,8 @@ abstract class YasrShortcode
141
  {
142
  //scripts required for all shortcodes
143
  YasrScriptsLoader::loadRequiredJs();
 
 
144
  do_action( 'yasr_enqueue_assets_shortcode' );
145
  }
146
 
141
  {
142
  //scripts required for all shortcodes
143
  YasrScriptsLoader::loadRequiredJs();
144
+ //css required for all shortcodes
145
+ YasrScriptsLoader::loadRequiredCss();
146
  do_action( 'yasr_enqueue_assets_shortcode' );
147
  }
148
 
includes/yasr-includes-functions.php CHANGED
@@ -201,60 +201,31 @@ function yasr_unique_multidim_array($array, $key) {
201
  return $temp_array;
202
  }
203
 
 
 
 
 
 
 
 
 
 
204
  function yasr_check_valid_url($url) {
 
 
 
205
 
206
- $timeout = 5;
207
-
208
- //Check if url is valid
209
- if (filter_var($url, FILTER_VALIDATE_URL) !== false) {
210
-
211
- //Check if curl is installed
212
- if (function_exists('curl_version')) {
213
-
214
- $ch = curl_init();
215
- curl_setopt($ch, CURLOPT_URL, $url);
216
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
217
- curl_setopt($ch, CURLOPT_TIMEOUT, $timeout);
218
-
219
- //execute curl
220
- $http_respond = trim(strip_tags(curl_exec($ch)));
221
- $http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
222
-
223
- //Check the response
224
- if (($http_code == '200') || ($http_code == '302')) {
225
- return true;
226
- }
227
-
228
- return false;
229
- //close curl
230
- curl_close($ch);
231
-
232
- } //if curl is not installed, use file_get_contents
233
- else {
234
- //...but only if enabled on the server!
235
- if (ini_get('allow_url_fopen')) {
236
-
237
- //Change timeout for file_get_contents
238
- ini_set('default_socket_timeout', $timeout); //5 seconds
239
-
240
- $headers = get_headers($url, 1);
241
- $string_to_check = '200 OK';
242
-
243
- //check if in the first heade we've 200 OK
244
- if (strpos($headers[0], $string_to_check) !== false) {
245
- return true;
246
- }
247
-
248
- return false;
249
- } //if url_fopen is not enabled
250
-
251
- return false;
252
 
253
- }
254
- } else {
255
  return false;
256
  }
257
 
 
 
 
 
 
258
  }
259
 
260
 
201
  return $temp_array;
202
  }
203
 
204
+ /**
205
+ * Return true if the requested url return 200
206
+ *
207
+ * @author Dario Curvino <@dudo>
208
+ * @since refactor in 3.0.8
209
+ * @param $url
210
+ *
211
+ * @return bool
212
+ */
213
  function yasr_check_valid_url($url) {
214
+ if (filter_var($url, FILTER_VALIDATE_URL) === false) {
215
+ return false;
216
+ }
217
 
218
+ $response = wp_remote_get($url);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
219
 
220
+ if(is_wp_error($response)) {
 
221
  return false;
222
  }
223
 
224
+ if(wp_remote_retrieve_response_code($response) === 200) {
225
+ return true;
226
+ }
227
+
228
+ return false;
229
  }
230
 
231
 
public/yasr-public-actions.php DELETED
@@ -1,47 +0,0 @@
1
- <?php
2
- /*
3
-
4
- Copyright 2014 Dario Curvino (email : d.curvino@tiscali.it)
5
-
6
- This program is free software: you can redistribute it and/or modify
7
- it under the terms of the GNU General Public License as published by
8
- the Free Software Foundation, either version 2 of the License, or
9
- (at your option) any later version.
10
-
11
- This program is distributed in the hope that it will be useful,
12
- but WITHOUT ANY WARRANTY; without even the implied warranty of
13
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
- GNU General Public License for more details.
15
-
16
- You should have received a copy of the GNU General Public License
17
- along with this program. If not, see <http://www.gnu.org/licenses/>
18
- */
19
-
20
- if (!defined('ABSPATH')) {
21
- exit('You\'re not allowed to see this page');
22
- } // Exit if accessed directly
23
-
24
- /***** Adding javascript and css *****/
25
- add_action('wp_enqueue_scripts', 'yasr_add_scripts');
26
- function yasr_add_scripts() {
27
-
28
- wp_enqueue_style(
29
- 'yasrcss',
30
- YASR_CSS_DIR_INCLUDES . 'yasr.css',
31
- false,
32
- YASR_VERSION_NUM
33
- );
34
-
35
- //Run after default css are loaded
36
- do_action('yasr_add_front_script_css');
37
-
38
- if (YASR_CUSTOM_CSS_RULES) {
39
- wp_add_inline_style(
40
- 'yasrcss',
41
- YASR_CUSTOM_CSS_RULES
42
- );
43
- }
44
-
45
- do_action('yasr_add_front_script_js');
46
-
47
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
public/yasr-public-init.php CHANGED
@@ -22,9 +22,6 @@ if (!defined('ABSPATH')) {
22
  } // Exit if accessed directly
23
 
24
 
25
-
26
- require YASR_ABSOLUTE_PATH_PUBLIC . '/yasr-public-actions.php';
27
-
28
  /**
29
  * Callback function for the spl_autoload_register above.
30
  *
22
  } // Exit if accessed directly
23
 
24
 
 
 
 
25
  /**
26
  * Callback function for the spl_autoload_register above.
27
  *
readme.txt CHANGED
@@ -1,10 +1,10 @@
1
  === Yasr - Yet Another Stars Rating ===
2
- Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=AXE284FYMNWDC
3
  Tags: rating, rate post, star rating, google rating, block
4
  Requires at least: 4.7
5
  Contributors: Dudo
6
  Tested up to: 6.0
7
- Stable tag: 3.0.7
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
10
  Boost the way people interact with your site with an easy WordPress stars rating system! With schema.org rich snippets YASR will improve your SEO
@@ -124,6 +124,7 @@ Further, it comes with a lot of hooks, you can find more info [here](https://yet
124
  == Related Link ==
125
  * [All available shortcodes in free version](https://yetanotherstarsrating.com/yasr-shortcodes/)
126
  * Documentation at [Yasr Official Site](https://yetanotherstarsrating.com/docs/)
 
127
 
128
  Do you want more feature? [Check out Yasr Pro!](https://yetanotherstarsrating.com/#yasr-pro)
129
 
@@ -203,6 +204,10 @@ Yes, YASR is 100% fully compatible with PHP 8
203
 
204
  The full changelog can be found in the plugin's directory. Recent entries:
205
 
 
 
 
 
206
  = 3.0.7 =
207
  * FIXED: when the value 0 is entered for the Price the ‘Offers’ field is not displayed in the Schema markup.
208
  * TWEAKED: minor changes
@@ -246,42 +251,7 @@ The full changelog can be found in the plugin's directory. Recent entries:
246
  = 2.9.9 =
247
  * TWEAKED: removed "Pro only features" box in the editor screen
248
 
249
- = 2.9.8 =
250
- * TWEAKED: updated rest api
251
- * FIX: softwareApplication itemType didn't get saved
252
- * Fix: impossible to rate for overall rating in certain circumstances.
253
- * Fix: minor css fixes in admin area
254
-
255
- = 2.9.7 =
256
- * NEW FEATURE: auto insert option has now a new feature: it is possible to place shortcodes on both above and below the content
257
- * TWEAKED: attribute 'custom-fields' is added for all CPTS, to avoid compatibility issue in Gutenberg
258
- * TWEAKED: nonces are checked only for logged in users.
259
- * TWEAKED: "Stats" page is now renamed in "Manage Ratings"
260
- * TWEAKED: below the editor is now easier to manage Multi Sets
261
-
262
-
263
- = 2.9.6 =
264
- * FIXED: support for wp_template and wp_template_part CPT, used by FSE
265
- * FIXED: html tags in custom texts didn't work
266
-
267
-
268
- = 2.9.5 =
269
- * NEW FEATURE: In the settings, is now possible to customize the text when a rating is saved / updated
270
- * minor fixes
271
-
272
- = 2.9.4 =
273
- * Minor changes
274
-
275
- = 2.9.3 =
276
- * TWEAKED: Added support for Catch Infinite Scroll
277
-
278
- = 2.9.2 =
279
- * FIXED: rich snippets error that could occur in some circumstances
280
- * FIXED: css fix
281
- * TWEAKED: code cleanup
282
 
283
- = 2.9.1 =
284
- * FIXED: if shortcode exists for a post or page, but there are no ratings, wrong rich snippets are returned
285
 
286
  = Additional Info =
287
  See credits.txt file
1
  === Yasr - Yet Another Stars Rating ===
2
+ Donate link: https://www.paypal.com/donate/?hosted_button_id=SVTAVUF62QZ4W
3
  Tags: rating, rate post, star rating, google rating, block
4
  Requires at least: 4.7
5
  Contributors: Dudo
6
  Tested up to: 6.0
7
+ Stable tag: 3.0.8
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
10
  Boost the way people interact with your site with an easy WordPress stars rating system! With schema.org rich snippets YASR will improve your SEO
124
  == Related Link ==
125
  * [All available shortcodes in free version](https://yetanotherstarsrating.com/yasr-shortcodes/)
126
  * Documentation at [Yasr Official Site](https://yetanotherstarsrating.com/docs/)
127
+ * [GitHub page](https://github.com/Dudo1985/yet-another-stars-rating)
128
 
129
  Do you want more feature? [Check out Yasr Pro!](https://yetanotherstarsrating.com/#yasr-pro)
130
 
204
 
205
  The full changelog can be found in the plugin's directory. Recent entries:
206
 
207
+ = 3.0.8 =
208
+ * FIXED: YASR gutenberg panel didn't shop up once hidden
209
+ * TWEAKED: minor changes
210
+
211
  = 3.0.7 =
212
  * FIXED: when the value 0 is entered for the Price the ‘Offers’ field is not displayed in the Schema markup.
213
  * TWEAKED: minor changes
251
  = 2.9.9 =
252
  * TWEAKED: removed "Pro only features" box in the editor screen
253
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
254
 
 
 
255
 
256
  = Additional Info =
257
  See credits.txt file
yet-another-stars-rating.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Yet Another Stars Rating
5
  * Plugin URI: http://wordpress.org/plugins/yet-another-stars-rating/
6
  * Description: Boost the way people interact with your site with an easy WordPress stars rating system! With schema.org rich snippets YASR will improve your SEO
7
- * Version: 3.0.7
8
  * Requires at least: 4.7
9
  * Requires PHP: 5.4
10
  * Author: Dario Curvino
@@ -78,7 +78,7 @@ if ( !function_exists( 'yasr_fs' ) ) {
78
  yasr_fs();
79
  // Signal that SDK was initiated.
80
  do_action( 'yasr_fs_loaded' );
81
- define( 'YASR_VERSION_NUM', '3.0.7' );
82
  //Plugin absolute path
83
  //e.g. /var/www/html/plugin_development/wp-content/plugins/yet-another-stars-rating
84
  define( 'YASR_ABSOLUTE_PATH', __DIR__ );
4
  * Plugin Name: Yet Another Stars Rating
5
  * Plugin URI: http://wordpress.org/plugins/yet-another-stars-rating/
6
  * Description: Boost the way people interact with your site with an easy WordPress stars rating system! With schema.org rich snippets YASR will improve your SEO
7
+ * Version: 3.0.8
8
  * Requires at least: 4.7
9
  * Requires PHP: 5.4
10
  * Author: Dario Curvino
78
  yasr_fs();
79
  // Signal that SDK was initiated.
80
  do_action( 'yasr_fs_loaded' );
81
+ define( 'YASR_VERSION_NUM', '3.0.8' );
82
  //Plugin absolute path
83
  //e.g. /var/www/html/plugin_development/wp-content/plugins/yet-another-stars-rating
84
  define( 'YASR_ABSOLUTE_PATH', __DIR__ );