Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
autorun(reaction => {
this.activeTitle = toJS(store.activeTitle);
this.shareUrl = document.location.href;
this.shareMsg = this.activeTitle + " " + this.shareUrl;
if (varGet(store.activeItem, "metadata.fields.subtitle", false)) {
this.subtitle = store.activeItem.metadata.fields.subtitle;
} else {
this.subtitle = false;
}
// look for image on the post and make it the pin share
if (varGet(store.activeItem, "metadata.fields.images.0.src", false)) {
this.activeImage = store.activeItem.metadata.fields.images[0].src;
}
this.__disposer.push(reaction);
});
}
autorun(reaction => {
this.activeTitle = toJS(store.activeTitle);
this.shareUrl = document.location.href;
this.shareMsg = this.activeTitle + " " + this.shareUrl;
if (varGet(store.activeItem, "metadata.fields.subtitle", false)) {
this.subtitle = store.activeItem.metadata.fields.subtitle;
} else {
this.subtitle = false;
}
// look for image on the post and make it the pin share
if (varGet(store.activeItem, "metadata.fields.images.0.src", false)) {
this.activeImage = store.activeItem.metadata.fields.images[0].src;
}
this.__disposer.push(reaction);
});
}
autorun(reaction => {
this.activeTitle = toJS(store.activeTitle);
this.shareUrl = document.location.href;
this.shareMsg = this.activeTitle + " " + this.shareUrl;
if (varGet(store.activeItem, "metadata.fields.subtitle", false)) {
this.subtitle = store.activeItem.metadata.fields.subtitle;
} else {
this.subtitle = false;
}
// look for image on the post and make it the pin share
if (varGet(store.activeItem, "metadata.fields.images.0.src", false)) {
this.activeImage = store.activeItem.metadata.fields.images[0].src;
}
this.__disposer.push(reaction);
});
}
b2.appendChild(document.createTextNode("cancel"));
b2.setAttribute("dialog-dismiss", "dialog-dismiss");
let b = document.createElement("div");
b.style.position = "absolute";
b.style.bottom = 0;
b.style.left = 0;
b.style.right = 0;
b.style.zIndex = 1000000;
b.appendChild(b1);
b.appendChild(b2);
const evt = new CustomEvent("simple-modal-show", {
bubbles: true,
composed: true,
cancelable: false,
detail: {
title: "Edit " + store.activeTitle + " fields",
styles: {
"--simple-modal-width": "75vw",
"--simple-modal-max-width": "75vw"
},
elements: {
content: c,
buttons: b
},
invokedBy: this.__nodeFieldsInvoked,
clone: false,
modal: true
}
});
window.dispatchEvent(evt);
}
autorun(reaction => {
this.activeTitle = toJS(store.activeTitle);
this.__title = this._makeTitle(
this.dynamicMethodology,
this.activeTitle,
this.parentTitle,
this.ancestorTitle
);
this.__disposer.push(reaction);
});
autorun(reaction => {