vue-editify 0.1.41 → 0.1.42

Sign up to get free protection for your applications and to get access to all the features.
package/lib/index.d.ts CHANGED
@@ -8,7 +8,7 @@ export type { MenuButtonType, MenuSelectButtonType, MenuDisplayButtonType, MenuI
8
8
  export type { ElementMatchConfig } from './core/function';
9
9
  export { elementIsMatch, getMatchElementByElement, getMatchElementsByRange, elementIsInList, elementIsInTask, isList, isTask, hasPreInRange, isRangeInPre, hasQuoteInRange, isRangeInQuote, hasListInRange, isRangeInList, hasTaskInRange, isRangeInTask, hasLinkInRange, hasTableInRange, hasImageInRange, hasVideoInRange, queryTextStyle, queryTextMark, getRangeText, setIndentIncrease, setIndentDecrease, setQuote, setAlign, setList, setTask, setTextStyle, setTextMark, removeTextStyle, removeTextMark, setLineHeight, insertLink, insertImage, insertVideo, insertTable, insertCodeBlock } from './core/function';
10
10
  declare const install: FunctionPlugin;
11
- declare const version = "0.1.41";
11
+ declare const version = "0.1.42";
12
12
  export { AlexElement } from 'alex-editor';
13
13
  export type { AttachmentOptionsType } from './plugins/attachment';
14
14
  export type { InsertAttachmentUploadErrorType } from './plugins/attachment/insertAttachment/props';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vue-editify",
3
- "version": "0.1.41",
3
+ "version": "0.1.42",
4
4
  "private": false,
5
5
  "sideEffects": [
6
6
  "*.css"
@@ -19,14 +19,10 @@ export type ElementMatchConfig = {
19
19
  * @returns
20
20
  */
21
21
  export const elementIsMatch = (element: AlexElement, config: ElementMatchConfig) => {
22
- //如果是文本元素直接返回false
23
- if (element.isText()) {
24
- return false
25
- }
26
22
  //默认是符合的
27
23
  let isMatch = true
28
24
  //如果存在parsedom判断并且parsedom不一样
29
- if (config.parsedom && config.parsedom != element.parsedom) {
25
+ if (config.parsedom && element.parsedom && config.parsedom != element.parsedom) {
30
26
  isMatch = false
31
27
  }
32
28
  //如果存在marks判断
package/src/index.ts CHANGED
@@ -19,7 +19,7 @@ const install: FunctionPlugin = (app: App) => {
19
19
  app.component(Editify.name!, Editify)
20
20
  }
21
21
  //版本号
22
- const version = '0.1.41'
22
+ const version = '0.1.42'
23
23
 
24
24
  //导出AlexElement元素
25
25
  export { AlexElement } from 'alex-editor'