@ckeditor/ckeditor5-export-word 44.1.0 → 44.2.0-alpha.1
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/LICENSE.md +1 -1
- package/README.md +1 -1
- package/build/export-word.js +2 -2
- package/dist/index-content.css +2 -2
- package/dist/index-editor.css +2 -2
- package/dist/index.css +2 -2
- package/dist/index.js +2 -2
- package/dist/translations/af.d.ts +2 -2
- package/dist/translations/af.js +2 -2
- package/dist/translations/af.umd.js +2 -2
- package/dist/translations/ar.d.ts +2 -2
- package/dist/translations/ar.js +2 -2
- package/dist/translations/ar.umd.js +2 -2
- package/dist/translations/ast.d.ts +2 -2
- package/dist/translations/ast.js +2 -2
- package/dist/translations/ast.umd.js +2 -2
- package/dist/translations/az.d.ts +2 -2
- package/dist/translations/az.js +2 -2
- package/dist/translations/az.umd.js +2 -2
- package/dist/translations/bg.d.ts +2 -2
- package/dist/translations/bg.js +2 -2
- package/dist/translations/bg.umd.js +2 -2
- package/dist/translations/bn.d.ts +2 -2
- package/dist/translations/bn.js +2 -2
- package/dist/translations/bn.umd.js +2 -2
- package/dist/translations/bs.d.ts +2 -2
- package/dist/translations/bs.js +2 -2
- package/dist/translations/bs.umd.js +2 -2
- package/dist/translations/ca.d.ts +2 -2
- package/dist/translations/ca.js +2 -2
- package/dist/translations/ca.umd.js +2 -2
- package/dist/translations/cs.d.ts +2 -2
- package/dist/translations/cs.js +2 -2
- package/dist/translations/cs.umd.js +2 -2
- package/dist/translations/da.d.ts +2 -2
- package/dist/translations/da.js +2 -2
- package/dist/translations/da.umd.js +2 -2
- package/dist/translations/de-ch.d.ts +2 -2
- package/dist/translations/de-ch.js +2 -2
- package/dist/translations/de-ch.umd.js +2 -2
- package/dist/translations/de.d.ts +2 -2
- package/dist/translations/de.js +2 -2
- package/dist/translations/de.umd.js +2 -2
- package/dist/translations/el.d.ts +2 -2
- package/dist/translations/el.js +2 -2
- package/dist/translations/el.umd.js +2 -2
- package/dist/translations/en-au.d.ts +2 -2
- package/dist/translations/en-au.js +2 -2
- package/dist/translations/en-au.umd.js +2 -2
- package/dist/translations/en-gb.d.ts +2 -2
- package/dist/translations/en-gb.js +2 -2
- package/dist/translations/en-gb.umd.js +2 -2
- package/dist/translations/en.d.ts +2 -2
- package/dist/translations/en.js +2 -2
- package/dist/translations/en.umd.js +2 -2
- package/dist/translations/eo.d.ts +2 -2
- package/dist/translations/eo.js +2 -2
- package/dist/translations/eo.umd.js +2 -2
- package/dist/translations/es-co.d.ts +2 -2
- package/dist/translations/es-co.js +2 -2
- package/dist/translations/es-co.umd.js +2 -2
- package/dist/translations/es.d.ts +2 -2
- package/dist/translations/es.js +2 -2
- package/dist/translations/es.umd.js +2 -2
- package/dist/translations/et.d.ts +2 -2
- package/dist/translations/et.js +2 -2
- package/dist/translations/et.umd.js +2 -2
- package/dist/translations/eu.d.ts +2 -2
- package/dist/translations/eu.js +2 -2
- package/dist/translations/eu.umd.js +2 -2
- package/dist/translations/fa.d.ts +2 -2
- package/dist/translations/fa.js +2 -2
- package/dist/translations/fa.umd.js +2 -2
- package/dist/translations/fi.d.ts +2 -2
- package/dist/translations/fi.js +2 -2
- package/dist/translations/fi.umd.js +2 -2
- package/dist/translations/fr.d.ts +2 -2
- package/dist/translations/fr.js +2 -2
- package/dist/translations/fr.umd.js +2 -2
- package/dist/translations/gl.d.ts +2 -2
- package/dist/translations/gl.js +2 -2
- package/dist/translations/gl.umd.js +2 -2
- package/dist/translations/gu.d.ts +2 -2
- package/dist/translations/gu.js +2 -2
- package/dist/translations/gu.umd.js +2 -2
- package/dist/translations/he.d.ts +2 -2
- package/dist/translations/he.js +2 -2
- package/dist/translations/he.umd.js +2 -2
- package/dist/translations/hi.d.ts +2 -2
- package/dist/translations/hi.js +2 -2
- package/dist/translations/hi.umd.js +2 -2
- package/dist/translations/hr.d.ts +2 -2
- package/dist/translations/hr.js +2 -2
- package/dist/translations/hr.umd.js +2 -2
- package/dist/translations/hu.d.ts +2 -2
- package/dist/translations/hu.js +2 -2
- package/dist/translations/hu.umd.js +2 -2
- package/dist/translations/hy.d.ts +2 -2
- package/dist/translations/hy.js +2 -2
- package/dist/translations/hy.umd.js +2 -2
- package/dist/translations/id.d.ts +2 -2
- package/dist/translations/id.js +2 -2
- package/dist/translations/id.umd.js +2 -2
- package/dist/translations/it.d.ts +2 -2
- package/dist/translations/it.js +2 -2
- package/dist/translations/it.umd.js +2 -2
- package/dist/translations/ja.d.ts +2 -2
- package/dist/translations/ja.js +2 -2
- package/dist/translations/ja.umd.js +2 -2
- package/dist/translations/jv.d.ts +2 -2
- package/dist/translations/jv.js +2 -2
- package/dist/translations/jv.umd.js +2 -2
- package/dist/translations/kk.d.ts +2 -2
- package/dist/translations/kk.js +2 -2
- package/dist/translations/kk.umd.js +2 -2
- package/dist/translations/km.d.ts +2 -2
- package/dist/translations/km.js +2 -2
- package/dist/translations/km.umd.js +2 -2
- package/dist/translations/kn.d.ts +2 -2
- package/dist/translations/kn.js +2 -2
- package/dist/translations/kn.umd.js +2 -2
- package/dist/translations/ko.d.ts +2 -2
- package/dist/translations/ko.js +2 -2
- package/dist/translations/ko.umd.js +2 -2
- package/dist/translations/ku.d.ts +2 -2
- package/dist/translations/ku.js +2 -2
- package/dist/translations/ku.umd.js +2 -2
- package/dist/translations/lt.d.ts +2 -2
- package/dist/translations/lt.js +2 -2
- package/dist/translations/lt.umd.js +2 -2
- package/dist/translations/lv.d.ts +2 -2
- package/dist/translations/lv.js +2 -2
- package/dist/translations/lv.umd.js +2 -2
- package/dist/translations/ms.d.ts +2 -2
- package/dist/translations/ms.js +2 -2
- package/dist/translations/ms.umd.js +2 -2
- package/dist/translations/nb.d.ts +2 -2
- package/dist/translations/nb.js +2 -2
- package/dist/translations/nb.umd.js +2 -2
- package/dist/translations/ne.d.ts +2 -2
- package/dist/translations/ne.js +2 -2
- package/dist/translations/ne.umd.js +2 -2
- package/dist/translations/nl.d.ts +2 -2
- package/dist/translations/nl.js +2 -2
- package/dist/translations/nl.umd.js +2 -2
- package/dist/translations/no.d.ts +2 -2
- package/dist/translations/no.js +2 -2
- package/dist/translations/no.umd.js +2 -2
- package/dist/translations/oc.d.ts +2 -2
- package/dist/translations/oc.js +2 -2
- package/dist/translations/oc.umd.js +2 -2
- package/dist/translations/pl.d.ts +2 -2
- package/dist/translations/pl.js +2 -2
- package/dist/translations/pl.umd.js +2 -2
- package/dist/translations/pt-br.d.ts +2 -2
- package/dist/translations/pt-br.js +2 -2
- package/dist/translations/pt-br.umd.js +2 -2
- package/dist/translations/pt.d.ts +2 -2
- package/dist/translations/pt.js +2 -2
- package/dist/translations/pt.umd.js +2 -2
- package/dist/translations/ro.d.ts +2 -2
- package/dist/translations/ro.js +2 -2
- package/dist/translations/ro.umd.js +2 -2
- package/dist/translations/ru.d.ts +2 -2
- package/dist/translations/ru.js +2 -2
- package/dist/translations/ru.umd.js +2 -2
- package/dist/translations/si.d.ts +2 -2
- package/dist/translations/si.js +2 -2
- package/dist/translations/si.umd.js +2 -2
- package/dist/translations/sk.d.ts +2 -2
- package/dist/translations/sk.js +2 -2
- package/dist/translations/sk.umd.js +2 -2
- package/dist/translations/sl.d.ts +2 -2
- package/dist/translations/sl.js +2 -2
- package/dist/translations/sl.umd.js +2 -2
- package/dist/translations/sq.d.ts +2 -2
- package/dist/translations/sq.js +2 -2
- package/dist/translations/sq.umd.js +2 -2
- package/dist/translations/sr-latn.d.ts +2 -2
- package/dist/translations/sr-latn.js +2 -2
- package/dist/translations/sr-latn.umd.js +2 -2
- package/dist/translations/sr.d.ts +2 -2
- package/dist/translations/sr.js +2 -2
- package/dist/translations/sr.umd.js +2 -2
- package/dist/translations/sv.d.ts +2 -2
- package/dist/translations/sv.js +2 -2
- package/dist/translations/sv.umd.js +2 -2
- package/dist/translations/th.d.ts +2 -2
- package/dist/translations/th.js +2 -2
- package/dist/translations/th.umd.js +2 -2
- package/dist/translations/ti.d.ts +2 -2
- package/dist/translations/ti.js +2 -2
- package/dist/translations/ti.umd.js +2 -2
- package/dist/translations/tk.d.ts +2 -2
- package/dist/translations/tk.js +2 -2
- package/dist/translations/tk.umd.js +2 -2
- package/dist/translations/tr.d.ts +2 -2
- package/dist/translations/tr.js +2 -2
- package/dist/translations/tr.umd.js +2 -2
- package/dist/translations/tt.d.ts +2 -2
- package/dist/translations/tt.js +2 -2
- package/dist/translations/tt.umd.js +2 -2
- package/dist/translations/ug.d.ts +2 -2
- package/dist/translations/ug.js +2 -2
- package/dist/translations/ug.umd.js +2 -2
- package/dist/translations/uk.d.ts +2 -2
- package/dist/translations/uk.js +2 -2
- package/dist/translations/uk.umd.js +2 -2
- package/dist/translations/ur.d.ts +2 -2
- package/dist/translations/ur.js +2 -2
- package/dist/translations/ur.umd.js +2 -2
- package/dist/translations/uz.d.ts +2 -2
- package/dist/translations/uz.js +2 -2
- package/dist/translations/uz.umd.js +2 -2
- package/dist/translations/vi.d.ts +2 -2
- package/dist/translations/vi.js +2 -2
- package/dist/translations/vi.umd.js +2 -2
- package/dist/translations/zh-cn.d.ts +2 -2
- package/dist/translations/zh-cn.js +2 -2
- package/dist/translations/zh-cn.umd.js +2 -2
- package/dist/translations/zh.d.ts +2 -2
- package/dist/translations/zh.js +2 -2
- package/dist/translations/zh.umd.js +2 -2
- package/lang/translations/af.po +1 -1
- package/lang/translations/ar.po +1 -1
- package/lang/translations/ast.po +1 -1
- package/lang/translations/az.po +1 -1
- package/lang/translations/bg.po +1 -1
- package/lang/translations/bn.po +1 -1
- package/lang/translations/bs.po +1 -1
- package/lang/translations/ca.po +1 -1
- package/lang/translations/cs.po +1 -1
- package/lang/translations/da.po +1 -1
- package/lang/translations/de-ch.po +1 -1
- package/lang/translations/de.po +1 -1
- package/lang/translations/el.po +1 -1
- package/lang/translations/en-au.po +1 -1
- package/lang/translations/en-gb.po +1 -1
- package/lang/translations/en.po +1 -1
- package/lang/translations/eo.po +1 -1
- package/lang/translations/es-co.po +1 -1
- package/lang/translations/es.po +1 -1
- package/lang/translations/et.po +1 -1
- package/lang/translations/eu.po +1 -1
- package/lang/translations/fa.po +1 -1
- package/lang/translations/fi.po +1 -1
- package/lang/translations/fr.po +1 -1
- package/lang/translations/gl.po +1 -1
- package/lang/translations/gu.po +1 -1
- package/lang/translations/he.po +1 -1
- package/lang/translations/hi.po +1 -1
- package/lang/translations/hr.po +1 -1
- package/lang/translations/hu.po +1 -1
- package/lang/translations/hy.po +1 -1
- package/lang/translations/id.po +1 -1
- package/lang/translations/it.po +1 -1
- package/lang/translations/ja.po +1 -1
- package/lang/translations/jv.po +1 -1
- package/lang/translations/kk.po +1 -1
- package/lang/translations/km.po +1 -1
- package/lang/translations/kn.po +1 -1
- package/lang/translations/ko.po +1 -1
- package/lang/translations/ku.po +1 -1
- package/lang/translations/lt.po +1 -1
- package/lang/translations/lv.po +1 -1
- package/lang/translations/ms.po +1 -1
- package/lang/translations/nb.po +1 -1
- package/lang/translations/ne.po +1 -1
- package/lang/translations/nl.po +1 -1
- package/lang/translations/no.po +1 -1
- package/lang/translations/oc.po +1 -1
- package/lang/translations/pl.po +1 -1
- package/lang/translations/pt-br.po +1 -1
- package/lang/translations/pt.po +1 -1
- package/lang/translations/ro.po +1 -1
- package/lang/translations/ru.po +1 -1
- package/lang/translations/si.po +1 -1
- package/lang/translations/sk.po +1 -1
- package/lang/translations/sl.po +1 -1
- package/lang/translations/sq.po +1 -1
- package/lang/translations/sr-latn.po +1 -1
- package/lang/translations/sr.po +1 -1
- package/lang/translations/sv.po +1 -1
- package/lang/translations/th.po +1 -1
- package/lang/translations/ti.po +1 -1
- package/lang/translations/tk.po +1 -1
- package/lang/translations/tr.po +1 -1
- package/lang/translations/tt.po +1 -1
- package/lang/translations/ug.po +1 -1
- package/lang/translations/uk.po +1 -1
- package/lang/translations/ur.po +1 -1
- package/lang/translations/uz.po +1 -1
- package/lang/translations/vi.po +1 -1
- package/lang/translations/zh-cn.po +1 -1
- package/lang/translations/zh.po +1 -1
- package/package.json +32 -5
- package/src/augmentation.d.ts +1 -1
- package/src/augmentation.js +1 -1
- package/src/exportword.d.ts +2 -2
- package/src/exportword.js +2 -2
- package/src/exportwordcommand.d.ts +1 -1
- package/src/exportwordcommand.js +2 -2
- package/src/exportwordui.d.ts +1 -1
- package/src/exportwordui.js +2 -2
- package/src/index.d.ts +1 -1
- package/src/index.js +2 -2
- package/src/utils/common-translations.d.ts +1 -1
- package/src/utils/common-translations.js +2 -2
- package/src/utils.d.ts +1 -7
- package/src/utils.js +2 -2
- package/dist/augmentation.d.ts +0 -25
- package/dist/exportword.d.ts +0 -364
- package/dist/exportwordcommand.d.ts +0 -40
- package/dist/exportwordui.d.ts +0 -35
- package/dist/index.d.ts +0 -14
- package/dist/utils/common-translations.d.ts +0 -13
- package/dist/utils.d.ts +0 -62
package/src/utils.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) 2003-
|
|
2
|
+
* Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
*
|
|
4
4
|
*
|
|
5
5
|
*
|
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
(function(
|
|
23
|
+
(function(_0x33ad94,_0x575134){const _0x2ce016=_0x231d,_0x920bac=_0x33ad94();while(!![]){try{const _0x5047be=parseInt(_0x2ce016(0x1bd))/0x1+parseInt(_0x2ce016(0x1b6))/0x2*(parseInt(_0x2ce016(0x1cc))/0x3)+-parseInt(_0x2ce016(0x1a7))/0x4+-parseInt(_0x2ce016(0x1ce))/0x5+-parseInt(_0x2ce016(0x1d6))/0x6*(parseInt(_0x2ce016(0x1d3))/0x7)+parseInt(_0x2ce016(0x1ad))/0x8+parseInt(_0x2ce016(0x1bb))/0x9*(parseInt(_0x2ce016(0x1c0))/0xa);if(_0x5047be===_0x575134)break;else _0x920bac['push'](_0x920bac['shift']());}catch(_0x1eaa93){_0x920bac['push'](_0x920bac['shift']());}}}(_0x3be6,0x2890e));export function getConverterOptions(_0x578668,_0x3a70fb={}){const _0x43fd2d=_0x231d,_0x274123=_0x578668[_0x43fd2d(0x1db)][_0x43fd2d(0x1c3)](_0x43fd2d(0x1c4)),_0x212326=_0x578668[_0x43fd2d(0x1db)][_0x43fd2d(0x1c3)](_0x43fd2d(0x1b0)),_0xef2adc=_0x578668[_0x43fd2d(0x1db)][_0x43fd2d(0x1c3)](_0x43fd2d(0x1dd)),_0x43317d=_0x3a70fb;if(_0x274123&&_0x212326){const _0x5abebc=getComments(_0x578668[_0x43fd2d(0x1db)][_0x43fd2d(0x1b8)](_0x43fd2d(0x1b0))[_0x43fd2d(0x1cd)]({'skipNotAttached':!0x0,'skipEmpty':!0x0}));Object[_0x43fd2d(0x1c5)](_0x5abebc)[_0x43fd2d(0x1d8)]&&(_0x43317d[_0x43fd2d(0x1d7)]=_0x5abebc);}if(_0x274123&&_0xef2adc){const _0x21e5f5=_0x578668[_0x43fd2d(0x1db)][_0x43fd2d(0x1b8)](_0x43fd2d(0x1dd)),_0x1ef9ae=_0x578668[_0x43fd2d(0x1db)][_0x43fd2d(0x1b8)](_0x43fd2d(0x1c4)),_0x1dbbff=getSuggestions(_0x21e5f5[_0x43fd2d(0x1b4)]({'toJSON':!0x0}),_0x1ef9ae[_0x43fd2d(0x1ca)]);Object[_0x43fd2d(0x1c5)](_0x1dbbff)[_0x43fd2d(0x1d8)]&&(_0x43317d[_0x43fd2d(0x1ba)]=_0x1dbbff);}return(_0x43317d[_0x43fd2d(0x1ba)]||_0x43317d[_0x43fd2d(0x1d7)])&&(_0x43317d[_0x43fd2d(0x1af)]=new Intl[(_0x43fd2d(0x1d5))]()[_0x43fd2d(0x1c9)]()[_0x43fd2d(0x1d9)]),_0x43317d;}export function getComments(_0x1d0c63){const _0x367bc2=_0x231d,_0x4f81fd={};if(!_0x1d0c63[_0x367bc2(0x1d8)])return _0x4f81fd;for(const _0x13328d of _0x1d0c63)_0x13328d[_0x367bc2(0x1d7)][_0x367bc2(0x1c1)](_0xca4e=>{const _0x11aa5b=_0x367bc2;void 0x0===_0x4f81fd[_0x13328d['id']]&&(_0x4f81fd[_0x13328d['id']]=[]),_0x4f81fd[_0x13328d['id']][_0x11aa5b(0x1ab)]({'author':_0xca4e[_0x11aa5b(0x1b5)][_0x11aa5b(0x1c7)],'content':_0xca4e[_0x11aa5b(0x1b3)],'created':_0xca4e[_0x11aa5b(0x1c2)],'is_resolved':_0x13328d[_0x11aa5b(0x1dc)]});});return _0x4f81fd;}export function getSuggestions(_0x20f0e0,_0x3c564c){const _0x7e3ee1=_0x231d,_0x1e37a7={};if(!_0x20f0e0[_0x7e3ee1(0x1d8)]||!_0x3c564c[_0x7e3ee1(0x1d8)])return _0x1e37a7;for(const {id:_0x5cb3f9,createdAt:_0x2bb864,authorId:_0x5d0ac5,attributes:_0x3c0b16}of _0x20f0e0){const _0x45dd87=_0x3c0b16&&_0x3c0b16[_0x7e3ee1(0x1a9)],_0x10b203=_0x45dd87?_0x45dd87[_0x7e3ee1(0x1a8)]:_0x3c564c[_0x7e3ee1(0x1b8)](_0x5d0ac5)[_0x7e3ee1(0x1c7)];_0x1e37a7[_0x5cb3f9]={'author':_0x10b203,'created':_0x2bb864};}return _0x1e37a7;}function _0x231d(_0x20b535,_0x42ea38){const _0x3be62f=_0x3be6();return _0x231d=function(_0x231dd5,_0xadc3c3){_0x231dd5=_0x231dd5-0x1a5;let _0x2a131f=_0x3be62f[_0x231dd5];return _0x2a131f;},_0x231d(_0x20b535,_0x42ea38);}export function getConverterOptionsV2(_0xd8a1fc,_0x481f87={}){const _0x3fd918=_0x231d,_0x5f44e0=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1c3)](_0x3fd918(0x1c4)),_0x5dd0f7=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1c3)](_0x3fd918(0x1b0)),_0x21825d=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1c3)](_0x3fd918(0x1dd)),_0x140755=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1c3)](_0x3fd918(0x1aa)),_0x5e61cf=_0xd8a1fc[_0x3fd918(0x1d2)][_0x3fd918(0x1c6)],_0x4f019f=_0x481f87,_0x14e551={};if(_0x4f019f[_0x3fd918(0x1b7)]=_0x4f019f[_0x3fd918(0x1b7)]||{},_0x4f019f[_0x3fd918(0x1b7)][_0x3fd918(0x1ac)]=_0x4f019f[_0x3fd918(0x1b7)][_0x3fd918(0x1ac)]||_0x5e61cf,_0x5f44e0&&_0x5dd0f7){const _0x1abf88=getCommentsV2(_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1b8)](_0x3fd918(0x1b0))[_0x3fd918(0x1cd)]({'skipNotAttached':!0x0,'skipEmpty':!0x0}));_0x1abf88[_0x3fd918(0x1d8)]&&(_0x14e551[_0x3fd918(0x1de)]=_0x1abf88);}if(_0x5f44e0&&_0x21825d){const _0x2239fb=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1b8)](_0x3fd918(0x1dd)),_0x149d16=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1b8)](_0x3fd918(0x1c4)),_0x5c3327=getSuggestionsV2(_0x2239fb[_0x3fd918(0x1b4)]({'toJSON':!0x0}),_0x149d16[_0x3fd918(0x1ca)]);_0x5c3327[_0x3fd918(0x1d8)]&&(_0x14e551[_0x3fd918(0x1ba)]=_0x5c3327);}if(_0x140755){const _0x41f9a1=_0xd8a1fc[_0x3fd918(0x1db)][_0x3fd918(0x1b8)](_0x3fd918(0x1bf)),_0x45aa16=_0x41f9a1[_0x3fd918(0x1be)],{prefix:_0xef8734,suffix:_0x528191}=_0xd8a1fc[_0x3fd918(0x1d1)][_0x3fd918(0x1b8)](_0x3fd918(0x1b2));if(_0x4f019f[_0x3fd918(0x1d4)]={'prefix':_0xef8734,'suffix':_0x528191},_0x3fd918(0x1b1)!==_0x45aa16){_0x4f019f[_0x3fd918(0x1d4)][_0x3fd918(0x1c8)]={};const _0x1d5d24=_0x3fd918(0x1a6),_0x3239e8=_0x3fd918(0x1ae)===_0x45aa16?_0x41f9a1[_0x3fd918(0x1da)]():_0x41f9a1[_0x3fd918(0x1a5)](_0x45aa16,!0x0);for(const _0x1aee4a of Object[_0x3fd918(0x1cf)](_0x3239e8)){const [_0x4b2d70,_0x3d8337]=_0x1aee4a;_0x3fd918(0x1b9)===_0x41f9a1[_0x3fd918(0x1d0)](_0x4b2d70)?_0x4f019f[_0x3fd918(0x1d4)][_0x3fd918(0x1c8)][_0x4b2d70]=null!==_0x3d8337?_0x3d8337:_0x1d5d24:_0x4f019f[_0x3fd918(0x1d4)][_0x3fd918(0x1c8)][_0x4b2d70]=null!==_0x3d8337?_0x3d8337:_0x41f9a1[_0x3fd918(0x1cb)](_0x4b2d70)||_0x4b2d70;}}}return(_0x14e551[_0x3fd918(0x1de)]||_0x14e551[_0x3fd918(0x1ba)])&&(_0x4f019f[_0x3fd918(0x1af)]=new Intl[(_0x3fd918(0x1d5))]()[_0x3fd918(0x1c9)]()[_0x3fd918(0x1d9)],_0x4f019f[_0x3fd918(0x1bc)]=_0x14e551),_0x4f019f;}export function getCommentsV2(_0x3102e1){const _0x337e7f=_0x231d,_0x7e83c4=[];if(!_0x3102e1[_0x337e7f(0x1d8)])return _0x7e83c4;for(const _0x1134f0 of _0x3102e1){const _0x45dee1=_0x1134f0[_0x337e7f(0x1d7)][_0x337e7f(0x1c1)](_0x1b44fc=>({'author':_0x1b44fc[_0x337e7f(0x1b5)][_0x337e7f(0x1c7)],'content':_0x1b44fc[_0x337e7f(0x1b3)],'created_at':_0x1b44fc[_0x337e7f(0x1c2)]}));_0x7e83c4[_0x337e7f(0x1ab)]({'thread_id':_0x1134f0['id'],'is_resolved':_0x1134f0[_0x337e7f(0x1dc)],'comments':_0x45dee1});}return _0x7e83c4;}export function getSuggestionsV2(_0x3c929d,_0x21b445){const _0x5355e8=_0x231d;return _0x3c929d[_0x5355e8(0x1d8)]&&_0x21b445[_0x5355e8(0x1d8)]?_0x3c929d[_0x5355e8(0x1c1)](({id:_0xc98514,createdAt:_0x30f1f9,authorId:_0xb8128e,attributes:_0x9639b})=>{const _0x34323c=_0x5355e8,_0x1d84fc=_0x9639b&&_0x9639b[_0x34323c(0x1a9)];return{'id':_0xc98514,'author':_0x1d84fc?_0x1d84fc[_0x34323c(0x1a8)]:_0x21b445[_0x34323c(0x1b8)](_0xb8128e)[_0x34323c(0x1c7)],'created_at':_0x30f1f9};}):[];}function _0x3be6(){const _0x3e990b=['1984040byNtlb','$defaultValues','timezone','CommentsRepository','$labels','mergeFields','content','getSuggestions','author','2GuPPDq','document','get','image','suggestions','135468xzQMCX','collaboration_features','220362nULZsn','previewMode','MergeFieldsEditing','80XIPGlQ','map','createdAt','has','Users','keys','contentLanguage','name','data','resolvedOptions','users','getLabel','33798cuXJbu','getCommentThreads','719690CXGtrx','entries','getMergeFieldType','config','locale','2681CLitCI','merge_fields','DateTimeFormat','786OzpVyL','comments','length','timeZone','getDefaultValues','plugins','isResolved','TrackChanges','comment_threads','getDataSetValues','data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP88B8AAuUB8e2ujYwAAAAASUVORK5CYII=','959120yoYvHc','authorName','@external','MergeFields','push','language'];_0x3be6=function(){return _0x3e990b;};return _0x3be6();}
|
package/dist/augmentation.d.ts
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
import type { ExportWordConfig, ExportWord, ExportWordCommand } from './index.js';
|
|
10
|
-
declare module '@ckeditor/ckeditor5-core' {
|
|
11
|
-
interface EditorConfig {
|
|
12
|
-
/**
|
|
13
|
-
* The configuration of the {@link module:export-word/exportword~ExportWord export to Word feature}.
|
|
14
|
-
*
|
|
15
|
-
* Read more in {@link module:export-word/exportword~ExportWordConfig}.
|
|
16
|
-
*/
|
|
17
|
-
exportWord?: ExportWordConfig;
|
|
18
|
-
}
|
|
19
|
-
interface PluginsMap {
|
|
20
|
-
[ExportWord.pluginName]: ExportWord;
|
|
21
|
-
}
|
|
22
|
-
interface CommandsMap {
|
|
23
|
-
exportWord: ExportWordCommand;
|
|
24
|
-
}
|
|
25
|
-
}
|
package/dist/exportword.d.ts
DELETED
|
@@ -1,364 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
/**
|
|
10
|
-
* @module export-word/exportword
|
|
11
|
-
* @publicApi
|
|
12
|
-
*/
|
|
13
|
-
import { Plugin, type Editor } from 'ckeditor5/src/core.js';
|
|
14
|
-
import { Notification } from 'ckeditor5/src/ui.js';
|
|
15
|
-
import type { InitializedToken, TokenUrl } from '@ckeditor/ckeditor5-cloud-services';
|
|
16
|
-
import ExportWordUI from './exportwordui.js';
|
|
17
|
-
/**
|
|
18
|
-
* The export to Word feature.
|
|
19
|
-
*
|
|
20
|
-
* It allows you to generate a Word file directly from the editor content.
|
|
21
|
-
*
|
|
22
|
-
* For a detailed overview, check the {@glink features/converters/export-word export to Word} feature documentation.
|
|
23
|
-
*/
|
|
24
|
-
export default class ExportWord extends Plugin {
|
|
25
|
-
/**
|
|
26
|
-
* @inheritDoc
|
|
27
|
-
*/
|
|
28
|
-
static get pluginName(): "ExportWord";
|
|
29
|
-
/**
|
|
30
|
-
* @inheritDoc
|
|
31
|
-
*/
|
|
32
|
-
static get isOfficialPlugin(): true;
|
|
33
|
-
/**
|
|
34
|
-
* @inheritDoc
|
|
35
|
-
*/
|
|
36
|
-
static get isPremiumPlugin(): true;
|
|
37
|
-
/**
|
|
38
|
-
* @inheritDoc
|
|
39
|
-
*/
|
|
40
|
-
static get requires(): readonly ["CloudServices", typeof Notification, typeof ExportWordUI];
|
|
41
|
-
/**
|
|
42
|
-
* @inheritDoc
|
|
43
|
-
*/
|
|
44
|
-
init(): void;
|
|
45
|
-
}
|
|
46
|
-
/**
|
|
47
|
-
* The configuration of the export to Word feature. It is used by the Word export features from
|
|
48
|
-
* the `@ckeditor/ckeditor5-export-word` package.
|
|
49
|
-
*
|
|
50
|
-
* ```ts
|
|
51
|
-
* ClassicEditor
|
|
52
|
-
* .create( editorElement, {
|
|
53
|
-
* exportWord: ... // Export to Word feature options.
|
|
54
|
-
* } )
|
|
55
|
-
* .then( ... )
|
|
56
|
-
* .catch( ... );
|
|
57
|
-
* ```
|
|
58
|
-
*
|
|
59
|
-
* See {@link module:core/editor/editorconfig~EditorConfig all editor options}.
|
|
60
|
-
*/
|
|
61
|
-
export interface ExportWordConfig {
|
|
62
|
-
/**
|
|
63
|
-
* Paths to the `.css` files containing additional styling for the editor's content (**the order of provided items matters**).
|
|
64
|
-
*
|
|
65
|
-
* ```ts
|
|
66
|
-
* const exportWordConfig = {
|
|
67
|
-
* stylesheets: [ './path/to/custom-style.css' ]
|
|
68
|
-
* }
|
|
69
|
-
* ```
|
|
70
|
-
*
|
|
71
|
-
* **Default editor's content styles**:
|
|
72
|
-
* {@glink getting-started/setup/css The default editor content styles}
|
|
73
|
-
* are applied to the generated Word file thanks to the `'EDITOR_STYLES'` token, which is provided to the `stylesheets` by default.
|
|
74
|
-
* If you don't want them to be applied, you have to omit the token:
|
|
75
|
-
*
|
|
76
|
-
* **NOTE:** The `'EDITOR_STYLES'` string is only supported in legacy custom builds with webpack or DLLs.
|
|
77
|
-
* In other setups you always need to pass the stylesheets.
|
|
78
|
-
*
|
|
79
|
-
* ```ts
|
|
80
|
-
* const exportWordConfig = {
|
|
81
|
-
* stylesheets: [ './path/to/custom-editor-styles.css' ]
|
|
82
|
-
* }
|
|
83
|
-
* ```
|
|
84
|
-
*
|
|
85
|
-
* **Custom styling:** For more advanced styling, your configuration should look like this:
|
|
86
|
-
*
|
|
87
|
-
* ```ts
|
|
88
|
-
* const exportWordConfig = {
|
|
89
|
-
* stylesheets: [
|
|
90
|
-
* './path/to/editor-styles.css',
|
|
91
|
-
* './path/to/custom-styles.css'
|
|
92
|
-
* ]
|
|
93
|
-
* }
|
|
94
|
-
* ```
|
|
95
|
-
*
|
|
96
|
-
* @default `[ 'EDITOR_STYLES' ]`
|
|
97
|
-
*/
|
|
98
|
-
stylesheets?: Array<string>;
|
|
99
|
-
/**
|
|
100
|
-
* The name of the generated Word file.
|
|
101
|
-
*
|
|
102
|
-
* ```ts
|
|
103
|
-
* // Static file name.
|
|
104
|
-
* const exportWordConfig = {
|
|
105
|
-
* fileName: 'my-document.docx'
|
|
106
|
-
* }
|
|
107
|
-
*
|
|
108
|
-
*
|
|
109
|
-
* // Dynamic file name.
|
|
110
|
-
* const exportWordConfig = {
|
|
111
|
-
* fileName: () => {
|
|
112
|
-
* const articleTitle = document.querySelector( '#title' );
|
|
113
|
-
*
|
|
114
|
-
* return `${ articleTitle.value }.docx`;
|
|
115
|
-
* }
|
|
116
|
-
* }
|
|
117
|
-
* ```
|
|
118
|
-
*
|
|
119
|
-
* **NOTE:** The file name must contain the `.docx` extension.
|
|
120
|
-
* Otherwise your operating system or device may have trouble identifying the file type.
|
|
121
|
-
*
|
|
122
|
-
* @default 'document.docx'
|
|
123
|
-
*/
|
|
124
|
-
fileName?: string | (() => string);
|
|
125
|
-
/**
|
|
126
|
-
* A URL to the Docx converter.
|
|
127
|
-
*
|
|
128
|
-
* ```ts
|
|
129
|
-
* const exportWordConfig = {
|
|
130
|
-
* converterUrl: 'https://myconverter.com/v2/'
|
|
131
|
-
* }
|
|
132
|
-
* ```
|
|
133
|
-
*
|
|
134
|
-
* **NOTE:** The plugin uses the default HTML to Word converter delivered by CKEditor Cloud Services.
|
|
135
|
-
* You can provide a URL to an on-premises converter instead.
|
|
136
|
-
*
|
|
137
|
-
* @default 'https://docx-converter.cke-cs.com/v2/convert/html-docx'
|
|
138
|
-
*/
|
|
139
|
-
converterUrl?: string;
|
|
140
|
-
/**
|
|
141
|
-
* The CKEditor Cloud Services HTML to DOCX Converter [configuration options](https://docx-converter.cke-cs.com/docs#section/Options).
|
|
142
|
-
*
|
|
143
|
-
* **NOTE:** Configuring the plugin is not mandatory.
|
|
144
|
-
*
|
|
145
|
-
* ```ts
|
|
146
|
-
* const exportWordConfig = {
|
|
147
|
-
* converterOptions: {
|
|
148
|
-
* ...
|
|
149
|
-
* }
|
|
150
|
-
* }
|
|
151
|
-
* ```
|
|
152
|
-
*
|
|
153
|
-
* @default `{
|
|
154
|
-
* document: {
|
|
155
|
-
* size: 'A4',
|
|
156
|
-
* orientation: 'portrait',
|
|
157
|
-
* language: editor.locale.contentLanguage,
|
|
158
|
-
* margin: {
|
|
159
|
-
* top: '1in',
|
|
160
|
-
* bottom: '1in',
|
|
161
|
-
* right: '1in',
|
|
162
|
-
* left: '1in'
|
|
163
|
-
* }
|
|
164
|
-
* }
|
|
165
|
-
* headers: undefined,
|
|
166
|
-
* footers: undefined,
|
|
167
|
-
* auto_pagination: false,
|
|
168
|
-
* base_url: undefined,
|
|
169
|
-
* extra_http_headers: undefined
|
|
170
|
-
* }`
|
|
171
|
-
*/
|
|
172
|
-
converterOptions?: ExportWordConverterOptions | ExportWordConverterOptionsV2;
|
|
173
|
-
/**
|
|
174
|
-
* A function to gather the HTML to be converted to Word.
|
|
175
|
-
*
|
|
176
|
-
* **NOTE:** This option may be useful when the editor does not have a `getData()` method,
|
|
177
|
-
* or if the HTML to be converted should be different than the edited one.
|
|
178
|
-
*
|
|
179
|
-
* ```ts
|
|
180
|
-
* const exportWordConfig = {
|
|
181
|
-
* dataCallback: ( editor ) => {
|
|
182
|
-
* return `
|
|
183
|
-
* <header id="header">${ editor.data.get( { rootName: 'header' } ) }</header>
|
|
184
|
-
* <div id="content">${ editor.data.get( { rootName: 'content' } ) }</div>
|
|
185
|
-
* `;
|
|
186
|
-
* }
|
|
187
|
-
* }
|
|
188
|
-
* ```
|
|
189
|
-
*
|
|
190
|
-
* @default `( editor ) => editor.getData( { pagination: true } )
|
|
191
|
-
*
|
|
192
|
-
* If using the {@glink features/pagination/pagination pagination} feature, the `pagination:true` option inserts additional markers into
|
|
193
|
-
* editor's data. Thanks to that, the Docx converter creates a Word document similar to what is displayed in the editor.
|
|
194
|
-
*/
|
|
195
|
-
dataCallback?: (editor: Editor) => string;
|
|
196
|
-
/**
|
|
197
|
-
* A token URL or a token request function. This field is optional and should be used only when a different `tokenUrl` is required for
|
|
198
|
-
* the export to Word feature.
|
|
199
|
-
*
|
|
200
|
-
* **Note:** The token can be disabled with the `false` value provided.
|
|
201
|
-
*
|
|
202
|
-
* See: {@link module:cloud-services/cloudservicesconfig~CloudServicesConfig#tokenUrl}
|
|
203
|
-
*/
|
|
204
|
-
tokenUrl?: TokenUrl | false;
|
|
205
|
-
/**
|
|
206
|
-
* The authentication token.
|
|
207
|
-
*
|
|
208
|
-
* See: {@link module:cloud-services/cloudservices~CloudServices#token}
|
|
209
|
-
*/
|
|
210
|
-
token?: InitializedToken;
|
|
211
|
-
/**
|
|
212
|
-
* The version of `Export to Word` API.
|
|
213
|
-
*
|
|
214
|
-
* @default '2'
|
|
215
|
-
*/
|
|
216
|
-
version?: 1 | 2;
|
|
217
|
-
/**
|
|
218
|
-
* The watermark configuration.
|
|
219
|
-
*
|
|
220
|
-
* ```ts
|
|
221
|
-
* converterOptions: {
|
|
222
|
-
* watermark: {
|
|
223
|
-
* source: 'https://via.placeholder.com/200',
|
|
224
|
-
* width: '500px',
|
|
225
|
-
* height: '600px',
|
|
226
|
-
* washout: 'false'
|
|
227
|
-
* }
|
|
228
|
-
* }
|
|
229
|
-
* ```
|
|
230
|
-
*
|
|
231
|
-
* The watermark configuration is represented as an object containing 4 properties:
|
|
232
|
-
*
|
|
233
|
-
* - `source`: A source of the image used for the watermark.
|
|
234
|
-
* - `width`: A string value representing the width of the watermark.
|
|
235
|
-
* - `height`: A string value representing the height of the watermark.
|
|
236
|
-
* - `washout`: Determines whether the washout effect should be applied. Optional - the default value is `false`.
|
|
237
|
-
*
|
|
238
|
-
*/
|
|
239
|
-
watermark?: ExportWordConverterWatermarkV2;
|
|
240
|
-
}
|
|
241
|
-
export type ExportWordConverterOptions = {
|
|
242
|
-
format?: ExportWordConverterFormatOption;
|
|
243
|
-
margin_top?: string;
|
|
244
|
-
margin_bottom?: string;
|
|
245
|
-
margin_right?: string;
|
|
246
|
-
margin_left?: string;
|
|
247
|
-
header?: ExportWordConverterHeaderFooterOption;
|
|
248
|
-
footer?: ExportWordConverterHeaderFooterOption;
|
|
249
|
-
comments?: ExportWordConverterCommentsOption;
|
|
250
|
-
suggestions?: ExportWordConverterSuggestionsOption;
|
|
251
|
-
orientation?: ExportWordConverterOrientationOption;
|
|
252
|
-
auto_pagination?: boolean;
|
|
253
|
-
base_url?: string;
|
|
254
|
-
};
|
|
255
|
-
export type ExportWordConverterFormatOption = 'Letter' | 'Legal' | 'Tabloid' | 'Statement' | 'Executive' | 'A3' | 'A4' | 'A5' | 'A6' | 'B4' | 'B5' | string & Record<never, never>;
|
|
256
|
-
export type ExportWordConverterOrientationOption = 'portrait' | 'landscape' | string & Record<never, never>;
|
|
257
|
-
export type ExportWordConverterHeaderFooterOption = Array<{
|
|
258
|
-
html?: string;
|
|
259
|
-
css?: string;
|
|
260
|
-
type?: 'default' | 'even' | 'odd' | 'first' | string & Record<never, never>;
|
|
261
|
-
}>;
|
|
262
|
-
export type ExportWordConverterCommentsOption = {
|
|
263
|
-
[id: string]: Array<{
|
|
264
|
-
author: string;
|
|
265
|
-
created: Date;
|
|
266
|
-
content?: string;
|
|
267
|
-
is_resolved: boolean;
|
|
268
|
-
}>;
|
|
269
|
-
};
|
|
270
|
-
export type ExportWordConverterSuggestionsOption = {
|
|
271
|
-
[id: string]: {
|
|
272
|
-
author: string;
|
|
273
|
-
created: Date | null;
|
|
274
|
-
};
|
|
275
|
-
};
|
|
276
|
-
export type ExportWordConverterOptionsV2 = {
|
|
277
|
-
document?: ExportWordConverterDocumentOptionsV2;
|
|
278
|
-
headers?: ExportWordConverterHeaderFooterOptionsV2;
|
|
279
|
-
footers?: ExportWordConverterHeaderFooterOptionsV2;
|
|
280
|
-
extra_http_headers?: ExportWordConverterExtraHttpHeaders;
|
|
281
|
-
base_url?: string;
|
|
282
|
-
auto_pagination?: boolean;
|
|
283
|
-
watermark?: ExportWordConverterWatermarkV2;
|
|
284
|
-
};
|
|
285
|
-
export type ExportWordConverterDocumentOptionsV2 = {
|
|
286
|
-
margins?: ExportWordConverterMarginsOptionsV2;
|
|
287
|
-
size?: ExportWordConverterFormatOptionsV2;
|
|
288
|
-
orientation?: ExportWordConverterOrientationOptionsV2;
|
|
289
|
-
language?: string;
|
|
290
|
-
};
|
|
291
|
-
export type ExportWordConverterMarginsOptionsV2 = {
|
|
292
|
-
top?: string;
|
|
293
|
-
right?: string;
|
|
294
|
-
bottom?: string;
|
|
295
|
-
left?: string;
|
|
296
|
-
};
|
|
297
|
-
export type ExportWordConverterHeaderFooterOptionsV2 = {
|
|
298
|
-
first?: ExportWordConverterHeaderFooterItemOptionsV2;
|
|
299
|
-
odd?: ExportWordConverterHeaderFooterItemOptionsV2;
|
|
300
|
-
even?: ExportWordConverterHeaderFooterItemOptionsV2;
|
|
301
|
-
default?: ExportWordConverterHeaderFooterItemOptionsV2;
|
|
302
|
-
};
|
|
303
|
-
export type ExportWordConverterWatermarkV2 = {
|
|
304
|
-
source?: string;
|
|
305
|
-
width?: string;
|
|
306
|
-
height?: string;
|
|
307
|
-
washout?: boolean;
|
|
308
|
-
};
|
|
309
|
-
/**
|
|
310
|
-
* If fetching some resources (e.g. images) used in a generated Word requires passing an additional
|
|
311
|
-
* authorization factor in the form of additional HTTP headers:
|
|
312
|
-
*
|
|
313
|
-
* ```
|
|
314
|
-
* extra_http_headers: {
|
|
315
|
-
* 'https://ckeditor.com': {
|
|
316
|
-
* authorization: 'Bearer xxx'
|
|
317
|
-
* },
|
|
318
|
-
* 'https://example.com': {
|
|
319
|
-
* authorization: 'Bearer xxx'
|
|
320
|
-
* },
|
|
321
|
-
* }
|
|
322
|
-
* ```
|
|
323
|
-
*/
|
|
324
|
-
export type ExportWordConverterExtraHttpHeaders = {
|
|
325
|
-
[domain: string]: ExportWordConverterExtraHttpHeadersHeader;
|
|
326
|
-
};
|
|
327
|
-
export type ExportWordConverterExtraHttpHeadersHeader = {
|
|
328
|
-
[header: string]: string;
|
|
329
|
-
};
|
|
330
|
-
export type ExportWordConverterHeaderFooterItemOptionsV2 = {
|
|
331
|
-
html?: string;
|
|
332
|
-
css?: string;
|
|
333
|
-
};
|
|
334
|
-
export type ExportWordConverterOrientationOptionsV2 = 'portrait' | 'landscape' | string & Record<never, never>;
|
|
335
|
-
export type ExportWordConverterFormatOptionsV2 = ExportWordConverterPredifinedFormatOptionsV2 | ExportWordConverterCustomFormatOptionsV2;
|
|
336
|
-
export type ExportWordConverterPredifinedFormatOptionsV2 = 'Letter' | 'Legal' | 'Tabloid' | 'Statement' | 'Executive' | 'A3' | 'A4' | 'A5' | 'A6' | 'B4' | 'B5' | string & Record<never, never>;
|
|
337
|
-
export type ExportWordConverterCustomFormatOptionsV2 = {
|
|
338
|
-
width?: string;
|
|
339
|
-
height?: string;
|
|
340
|
-
};
|
|
341
|
-
export type ExportWordConverterCollaborationFeaturesOptionsV2 = {
|
|
342
|
-
comment_threads?: ExportWordConverterCommentsThreadOptionsV2;
|
|
343
|
-
suggestions?: ExportWordConverterSuggestionsOptionsV2;
|
|
344
|
-
};
|
|
345
|
-
export type ExportWordConverterCommentsThreadOptionsV2 = Array<{
|
|
346
|
-
thread_id: string;
|
|
347
|
-
is_resolved: boolean;
|
|
348
|
-
comments: ExportWordConverterCommentsV2;
|
|
349
|
-
}>;
|
|
350
|
-
export type ExportWordConverterCommentsV2 = Array<{
|
|
351
|
-
author: string;
|
|
352
|
-
created_at: Date;
|
|
353
|
-
content: string;
|
|
354
|
-
}>;
|
|
355
|
-
export type ExportWordConverterSuggestionsOptionsV2 = Array<{
|
|
356
|
-
id: string;
|
|
357
|
-
author: string;
|
|
358
|
-
created_at: Date | null;
|
|
359
|
-
}>;
|
|
360
|
-
export type ExportWordConverterMergeFieldsOptionsV2 = {
|
|
361
|
-
prefix: string;
|
|
362
|
-
suffix: string;
|
|
363
|
-
data?: Record<string, string>;
|
|
364
|
-
};
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
/**
|
|
10
|
-
* @module export-word/exportwordcommand
|
|
11
|
-
* @publicApi
|
|
12
|
-
*/
|
|
13
|
-
import { Command, type Editor } from 'ckeditor5/src/core.js';
|
|
14
|
-
import type { ExportWordConfig } from './exportword.js';
|
|
15
|
-
/**
|
|
16
|
-
* The export to Word command.
|
|
17
|
-
*
|
|
18
|
-
* It takes the editor's HTML and CSS rules from the document and sends them to the HTML to Word converter.
|
|
19
|
-
* After processing, the converter will send back a Word file for download.
|
|
20
|
-
*/
|
|
21
|
-
export default class ExportWordCommand extends Command {
|
|
22
|
-
/**
|
|
23
|
-
* A command state that indicates if the command is currently executing.
|
|
24
|
-
*
|
|
25
|
-
* @observable
|
|
26
|
-
*/
|
|
27
|
-
isBusy: boolean;
|
|
28
|
-
/**
|
|
29
|
-
* @inheritDoc
|
|
30
|
-
*/
|
|
31
|
-
constructor(editor: Editor);
|
|
32
|
-
/**
|
|
33
|
-
* @inheritDoc
|
|
34
|
-
*/
|
|
35
|
-
refresh(): void;
|
|
36
|
-
/**
|
|
37
|
-
* @inheritDoc
|
|
38
|
-
*/
|
|
39
|
-
execute(options?: ExportWordConfig): Promise<void>;
|
|
40
|
-
}
|
package/dist/exportwordui.d.ts
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
/**
|
|
10
|
-
* @module export-word/exportwordui
|
|
11
|
-
*/
|
|
12
|
-
import { Plugin } from 'ckeditor5/src/core.js';
|
|
13
|
-
/**
|
|
14
|
-
* The export to Word UI feature.
|
|
15
|
-
*
|
|
16
|
-
* It introduces 'Export to Word' button in toolbar and menu bar.
|
|
17
|
-
*/
|
|
18
|
-
export default class ExportWordUI extends Plugin {
|
|
19
|
-
/**
|
|
20
|
-
* @inheritDoc
|
|
21
|
-
*/
|
|
22
|
-
static get pluginName(): "ExportWordUI";
|
|
23
|
-
/**
|
|
24
|
-
* @inheritDoc
|
|
25
|
-
*/
|
|
26
|
-
static get isOfficialPlugin(): true;
|
|
27
|
-
/**
|
|
28
|
-
* @inheritDoc
|
|
29
|
-
*/
|
|
30
|
-
static get isPremiumPlugin(): true;
|
|
31
|
-
/**
|
|
32
|
-
* @inheritDoc
|
|
33
|
-
*/
|
|
34
|
-
init(): void;
|
|
35
|
-
}
|
package/dist/index.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
/**
|
|
10
|
-
* @module export-word
|
|
11
|
-
*/
|
|
12
|
-
export { default as ExportWord, type ExportWordConfig } from './exportword.js';
|
|
13
|
-
export type { default as ExportWordCommand } from './exportwordcommand.js';
|
|
14
|
-
import './augmentation.js';
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
/**
|
|
10
|
-
* @module export-word/utils/common-translations
|
|
11
|
-
*/
|
|
12
|
-
import type { Locale } from 'ckeditor5/src/utils.js';
|
|
13
|
-
export declare function getTranslation(locale: Locale, id: string): string;
|
package/dist/utils.d.ts
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
|
7
|
-
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
8
|
-
*/
|
|
9
|
-
import type { Editor } from 'ckeditor5/src/core.js';
|
|
10
|
-
import type { Collection } from 'ckeditor5/src/utils.js';
|
|
11
|
-
import type { ExportWordConverterOptions, ExportWordConverterInternalOptions, ExportWordConverterCommentsOption, ExportWordConverterSuggestionsOption, ExportWordConverterCommentsThreadOptionsV2, ExportWordConverterOptionsV2, ExportWordConverterInternalOptionsV2, ExportWordConverterSuggestionsOptionsV2 } from './exportword.js';
|
|
12
|
-
import type { CommentThread } from '@ckeditor/ckeditor5-comments';
|
|
13
|
-
import type { SuggestionJSON } from '@ckeditor/ckeditor5-track-changes';
|
|
14
|
-
import type { User } from '@ckeditor/ckeditor5-collaboration-core';
|
|
15
|
-
/**
|
|
16
|
-
* A helper function for getting concatenated CSS rules from external stylesheets.
|
|
17
|
-
*
|
|
18
|
-
* @param stylesheets An array of stylesheet paths delivered by the user through the plugin configuration.
|
|
19
|
-
*/
|
|
20
|
-
export declare function getStyles(stylesheets?: Array<string>): Promise<string>;
|
|
21
|
-
/**
|
|
22
|
-
* A helper function for getting a proper options object containing
|
|
23
|
-
* comments, suggestions and the browser's timezone for the "Export to Word" converter.
|
|
24
|
-
*
|
|
25
|
-
* @param editor An editor instance.
|
|
26
|
-
* @param converterOptionsFromConfig Converter options passed through `editor.config.exportWord.converterOptions`.
|
|
27
|
-
*/
|
|
28
|
-
export declare function getConverterOptions(editor: Editor, converterOptionsFromConfig?: ExportWordConverterOptions): ExportWordConverterInternalOptions;
|
|
29
|
-
/**
|
|
30
|
-
* A helper function for getting a comments object for the converter options.
|
|
31
|
-
*
|
|
32
|
-
* @param threads The comment threads array.
|
|
33
|
-
*/
|
|
34
|
-
export declare function getComments(threads: Array<CommentThread>): ExportWordConverterCommentsOption;
|
|
35
|
-
/**
|
|
36
|
-
* A helper function for getting a suggestions object for the converter options.
|
|
37
|
-
*
|
|
38
|
-
* @param suggestions The suggestions array.
|
|
39
|
-
* @param users A list of all users in the editor.
|
|
40
|
-
*/
|
|
41
|
-
export declare function getSuggestions(suggestions: Array<SuggestionJSON>, users: Collection<User>): ExportWordConverterSuggestionsOption;
|
|
42
|
-
/**
|
|
43
|
-
* A helper function for getting a proper options object containing
|
|
44
|
-
* comments, suggestions and the browser's timezone for the "Export to Word" converter for V2 API.
|
|
45
|
-
*
|
|
46
|
-
* @param editor An editor instance.
|
|
47
|
-
* @param converterOptionsFromConfig Converter options passed through `editor.config.exportWord.converterOptions`.
|
|
48
|
-
*/
|
|
49
|
-
export declare function getConverterOptionsV2(editor: Editor, converterOptionsFromConfig?: ExportWordConverterOptionsV2): ExportWordConverterInternalOptionsV2;
|
|
50
|
-
/**
|
|
51
|
-
* A helper function for getting a comments object for the converter options in V2 API.
|
|
52
|
-
*
|
|
53
|
-
* @param threads The comment threads array.
|
|
54
|
-
*/
|
|
55
|
-
export declare function getCommentsV2(threads: Array<CommentThread>): ExportWordConverterCommentsThreadOptionsV2;
|
|
56
|
-
/**
|
|
57
|
-
* A helper function for getting a suggestions object for the converter options in V2 API.
|
|
58
|
-
*
|
|
59
|
-
* @param suggestions The suggestions array.
|
|
60
|
-
* @param users A list of all users in the editor.
|
|
61
|
-
*/
|
|
62
|
-
export declare function getSuggestionsV2(suggestions: Array<SuggestionJSON>, users: Collection<User>): ExportWordConverterSuggestionsOptionsV2;
|