pixflow-upgrade-planning 1.2.2 → 1.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +6 -6
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -57,8 +57,8 @@ class PixflowUpgradePlanning extends HTMLElement {
|
|
|
57
57
|
}
|
|
58
58
|
})
|
|
59
59
|
}
|
|
60
|
-
|
|
61
|
-
if(localStorage.getItem("unlock") == "0"){
|
|
60
|
+
|
|
61
|
+
if(cep_manifest.get_extension_id() != "net.pixflow.voiceai" && localStorage.getItem("unlock") == "0"){
|
|
62
62
|
this.querySelector("div.activate-code").classList.add("active");
|
|
63
63
|
}
|
|
64
64
|
|
|
@@ -82,9 +82,12 @@ class PixflowUpgradePlanning extends HTMLElement {
|
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
get_product_price_detail(){
|
|
85
|
+
const self = this;
|
|
85
86
|
if(cep_manifest.get_extension_id() == "net.pixflow.voiceai")
|
|
86
87
|
return;
|
|
87
|
-
|
|
88
|
+
self.querySelector("div.pixflow div.activate-code-block button").addEventListener("click", function(){
|
|
89
|
+
window.cep.util.openURLInDefaultBrowser(`https://pixflow.net/product/${cep_manifest.get_link()}/`);
|
|
90
|
+
})
|
|
88
91
|
const xhr = new XMLHttpRequest();
|
|
89
92
|
xhr.open("GET", `https://pixflow.net/wp-json/pixflow/get_product_price_detail?product-id=${cep_manifest.get_post_id()}&token=${token()}`);
|
|
90
93
|
xhr.addEventListener("load", function(){
|
|
@@ -110,9 +113,6 @@ class PixflowUpgradePlanning extends HTMLElement {
|
|
|
110
113
|
el_plan.setAttribute("data-url", url);
|
|
111
114
|
el_plan.querySelector("div > p").textContent = plan;
|
|
112
115
|
}
|
|
113
|
-
self.querySelector("div.pixflow div.activate-code-block button").addEventListener("click", function(){
|
|
114
|
-
window.cep.util.openURLInDefaultBrowser(`https://pixflow.net/product/${cep_manifest.get_link()}/`);
|
|
115
|
-
})
|
|
116
116
|
self.querySelectorAll("div.plan > div > div").forEach(function(element){
|
|
117
117
|
element.addEventListener("click", function(){
|
|
118
118
|
try {
|