chore(release): components
This commit is contained in:
@@ -1,2 +1,2 @@
|
||||
document.addEventListener("DOMContentLoaded",(function(){let e,t,n,o,i,a=!1,r=!0,s=!1;const l=["address","article","aside","blockquote","details","dialog","dd","div","dl","dt","fieldset","figcaption","figure","footer","form","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","li","main","nav","ol","p","pre","section","table","ul"].join(", ");function c(){if(t){const i=t;e.saveItemWithPresave(i,(()=>{o=$("#summernote").summernote("code"),i.clientData=n,i.content.text=o,i.content.preview_plain=function(e,t=90){return e.length<=t?e:e.substring(0,t)+"..."}(function(e){const t=document.implementation.createHTMLDocument("New").body;return t.innerHTML=e,t.textContent||t.innerText||""}(o)),i.content.preview_html=null}))}}function u(){return e.getComponentDataValueForKey("notes")||{}}$("#summernote").summernote({height:500,minHeight:null,maxHeight:null,focus:!0,tabDisable:!0,showDomainOnlyForAutolink:!1,toolbar:[["para",["style"]],["style",["bold","italic","underline","strikethrough","clear"]],["fontsize",["fontsize","fontname"]],["color",["color"]],["para",["ul","ol","paragraph"]],["height",["height"]],["insert",["table","link","hr","picture","video"]],["misc",["codeview","help"]]],fontNames:["Arial","Arial Black","Comic Sans MS","Courier New","Helvetica Neue","Helvetica","Impact","Lucida Grande","Monospace","Roboto","system-ui","Tahoma","Times New Roman","Verdana"],callbacks:{onInit:function(){},onImageUpload:function(){alert("Until we can encrypt image files, uploads are not currently supported. We recommend using the Image button in the toolbar and copying an image URL instead.")}}}),$("#summernote").on("summernote.change",(function(){document.querySelectorAll(l).forEach((e=>e.setAttribute("dir","auto"))),a||c()})),$("textarea.note-codable").on("input",(()=>{c()})),e=new ComponentRelay({initialPermissions:[{name:"stream-context-item"}],targetWindow:window,onReady:()=>{const t=e.platform;t&&document.body.classList.add(t)}}),e.streamContextItem((l=>{!function(l){if(l.uuid!==i&&(o=null,r=!0,i=l.uuid),t=l,l.isMetadataUpdate)return;n=l.clientData;let c=l.content.text;if($(".note-editable").attr("spellcheck",JSON.stringify(l.content.spellcheck)),c==o)return;const m=$("#summernote");if(m){a=!0;const t=/<[a-z][\s\S]*>/i.test(c);s||(m.summernote("fullscreen.toggle"),s=!0),r&&!t&&(c=((c||"")+"").replace(/\t/g," ").replace(/\r\n|\r|\n/g,"<br />"));let n=!1;if(function(e){const t=(new DOMParser).parseFromString(`<body>${e}</body>`,"text/html");return Array.from(t.body.childNodes).some((e=>"SCRIPT"==e.nodeName))}(c)){const t=u()[i];t?n=t.trustUnsafeContent||!1:new Promise((e=>{new Stylekit.SKAlert({title:null,text:"We’ve detected that this note contains a script or code snippet which may be unsafe to execute. Scripts executed in the editor have the ability to impersonate as the editor to Standard Notes. Press Continue to mark this script as safe and proceed, or Cancel to avoid rendering this note.",buttons:[{text:"Cancel",style:"neutral",action:function(){e(!1)}},{text:"Continue",style:"danger",action:function(){e(!0)}}]}).present()})).then((t=>{t&&(function(t,n){const o=u();o[i]={trustUnsafeContent:n},e.setComponentDataValueForKey("notes",o)}(0,t),n=t)}))}else n=!0;if(!n)return m.summernote("code",""),void m.summernote("disable");m.summernote("enable"),m.summernote("code",c),r&&(m.summernote("commit"),r=!1),a=!1}}(l)}))}));
|
||||
document.addEventListener("DOMContentLoaded",(function(){let e,t,n,o,i,a=!1,r=!0,s=!1;const l=["address","article","aside","blockquote","details","dialog","dd","div","dl","dt","fieldset","figcaption","figure","footer","form","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","li","main","nav","ol","p","pre","section","table","ul"].join(", ");function c(){if(t){const i=t;e.saveItemWithPresave(i,(()=>{o=$("#summernote").summernote("code"),i.clientData=n,i.content.text=o,i.content.preview_plain=function(e,t=90){return e.length<=t?e:e.substring(0,t)+"..."}(function(e){const t=document.implementation.createHTMLDocument("New").body;return t.innerHTML=e,t.textContent||t.innerText||""}(o)),i.content.preview_html=null}))}}function d(){return e.getComponentDataValueForKey("notes")||{}}$("#summernote").summernote({height:500,minHeight:null,maxHeight:null,focus:!0,tabDisable:!0,showDomainOnlyForAutolink:!1,toolbar:[["para",["style"]],["style",["bold","italic","underline","strikethrough","clear"]],["fontsize",["fontsize","fontname"]],["color",["color"]],["para",["ul","ol","paragraph"]],["height",["height"]],["insert",["table","link","hr","picture","video"]],["misc",["codeview","help"]]],fontNames:["Arial","Arial Black","Comic Sans MS","Courier New","Helvetica Neue","Helvetica","Impact","Lucida Grande","Monospace","Roboto","system-ui","Tahoma","Times New Roman","Verdana"],callbacks:{onInit:function(){},onImageUpload:function(){alert("Embedding encrypted images directly inside the editor is not presently supported. You can attach files to be outside the editor instead. For embedding images directly inside this note, use the Image button in the toolbar and insert the URL of an image hosted externally (outside of Standard Notes). For more information, visit https://standardnotes.com/help/36/how-do-i-attach-encrypted-files-to-my-notes.")}}}),$("#summernote").on("summernote.change",(function(){document.querySelectorAll(l).forEach((e=>e.setAttribute("dir","auto"))),a||c()})),$("textarea.note-codable").on("input",(()=>{c()})),e=new ComponentRelay({initialPermissions:[{name:"stream-context-item"}],targetWindow:window,onReady:()=>{const t=e.platform;t&&document.body.classList.add(t)}}),e.streamContextItem((l=>{!function(l){if(l.uuid!==i&&(o=null,r=!0,i=l.uuid),t=l,l.isMetadataUpdate)return;n=l.clientData;let c=l.content.text;if($(".note-editable").attr("spellcheck",JSON.stringify(l.content.spellcheck)),c==o)return;const u=$("#summernote");if(u){a=!0;const t=/<[a-z][\s\S]*>/i.test(c);s||(u.summernote("fullscreen.toggle"),s=!0),r&&!t&&(c=((c||"")+"").replace(/\t/g," ").replace(/\r\n|\r|\n/g,"<br />"));let n=!1;if(function(e){const t=(new DOMParser).parseFromString(`<body>${e}</body>`,"text/html");return Array.from(t.body.childNodes).some((e=>"SCRIPT"==e.nodeName))}(c)){const t=d()[i];t?n=t.trustUnsafeContent||!1:new Promise((e=>{new Stylekit.SKAlert({title:null,text:"We’ve detected that this note contains a script or code snippet which may be unsafe to execute. Scripts executed in the editor have the ability to impersonate as the editor to Standard Notes. Press Continue to mark this script as safe and proceed, or Cancel to avoid rendering this note.",buttons:[{text:"Cancel",style:"neutral",action:function(){e(!1)}},{text:"Continue",style:"danger",action:function(){e(!0)}}]}).present()})).then((t=>{t&&(function(t,n){const o=d();o[i]={trustUnsafeContent:n},e.setComponentDataValueForKey("notes",o)}(0,t),n=t)}))}else n=!0;if(!n)return u.summernote("code",""),void u.summernote("disable");u.summernote("enable"),u.summernote("code",c),r&&(u.summernote("commit"),r=!1),a=!1}}(l)}))}));
|
||||
//# sourceMappingURL=dist.js.map
|
||||
File diff suppressed because one or more lines are too long
6
packages/components/dist/zips/checksums.json
vendored
6
packages/components/dist/zips/checksums.json
vendored
@@ -45,9 +45,9 @@
|
||||
"binary": "deaece4cd37801f796eca2bf37fcccabfc6ddc43581630aa9ed04b9b0f7a7762"
|
||||
},
|
||||
"org.standardnotes.plus-editor": {
|
||||
"version": "1.6.6",
|
||||
"base64": "89cceec289f023b68fc5a76832730a145ebac612da9b33610de48c2f0353da0e",
|
||||
"binary": "a728c207ccf79c41852f00afeda2ed3384485bbd616c2abaca06ab317ea1ec79"
|
||||
"version": "1.7.0",
|
||||
"base64": "a63f79a3b6398ab13f8a4e106bbfc06312d31336967bbc5d2aa16c0c94ee08bb",
|
||||
"binary": "fd258ce43577024cbe297904963b1beabe239d053b7666b7e469cf1aaf0abd8d"
|
||||
},
|
||||
"org.standardnotes.simple-markdown-editor": {
|
||||
"version": "1.4.7",
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user