update to kirby 4.8
This commit is contained in:
commit
7d7df341d1
636 changed files with 139949 additions and 0 deletions
3
site/plugins/kirby-writer-callout/index.css
Normal file
3
site/plugins/kirby-writer-callout/index.css
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
.k-writer .ProseMirror .callout {
|
||||
font-size: 2.0625rem;
|
||||
}
|
||||
1
site/plugins/kirby-writer-callout/index.js
Normal file
1
site/plugins/kirby-writer-callout/index.js
Normal file
|
|
@ -0,0 +1 @@
|
|||
(function(){"use strict";function i(e){const t=window.panel.plugins.thirdParty;if(t.__marksInitialized)return;const n=t.marks;if(!n)return;const s=e.component("k-writer");e.component("k-writer",{extends:s,methods:{createMarks(){const l=s.options.methods.createMarks.call(this).filter(({name:r})=>!Object.keys(n).includes(r)),c=Object.entries(n).reduce((r,[d,m])=>(r[d]=new m,r),{});return[...l,...this.filterExtensions(c,this.marks)]}}}),t.__marksInitialized=!0}class a{constructor(t={}){this.options={...this.defaults,...t}}init(){return null}bindEditor(t=null){this.editor=t}get name(){return null}get type(){return"extension"}get defaults(){return{}}plugins(){return[]}inputRules(){return[]}pasteRules(){return[]}keys(){return{}}}class u extends a{constructor(t={}){super(t)}command(){return()=>{}}remove(){this.editor.removeMark(this.name)}get schema(){return null}get type(){return"mark"}toggle(){return this.editor.toggleMark(this.name)}update(t){this.editor.updateMark(this.name,t)}}class o extends u{get button(){return{icon:"star",label:"Callout"}}commands(){return()=>this.toggle()}get name(){return"callout"}get schema(){return{parseDOM:[{tag:"span"}],toDOM:t=>["span",{...t.attrs,class:"callout"},0]}}}window.panel.plugin("adrienpayet/kirby-writer-callout",{use:[i],thirdParty:{marks:{...window.panel.plugins.thirdParty.marks||{},callout:o}}})})();
|
||||
9
site/plugins/kirby-writer-callout/index.php
Normal file
9
site/plugins/kirby-writer-callout/index.php
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
<?php
|
||||
|
||||
/*
|
||||
* Add `article-footnote` to Kirby's Sane class allowed tags, otherwise
|
||||
* the writer field content parsed by the sanitizer would strip it
|
||||
*/
|
||||
// \Kirby\Sane\Html::$allowedTags['article-footnote'] = true;
|
||||
|
||||
\Kirby\Cms\App::plugin('adrienpayet/kirby-writer-callout', []);
|
||||
Loading…
Add table
Add a link
Reference in a new issue