@progress/kendo-vue-editor 2.7.3 → 3.0.0-dev.202201141128

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.
Files changed (118) hide show
  1. package/dist/cdn/js/kendo-vue-editor.js +1 -1
  2. package/dist/es/Editor.d.ts +49 -131
  3. package/dist/es/Editor.js +51 -25
  4. package/dist/es/EditorProps.d.ts +11 -5
  5. package/dist/es/additionalTypes.ts +7 -1
  6. package/dist/es/config/toolsSettings.d.ts +4 -0
  7. package/dist/es/dialogs/FindReplace.d.ts +6 -7
  8. package/dist/es/dialogs/FindReplace.js +203 -131
  9. package/dist/es/dialogs/insertImage.d.ts +5 -6
  10. package/dist/es/dialogs/insertImage.js +23 -13
  11. package/dist/es/dialogs/insertLink.d.ts +5 -6
  12. package/dist/es/dialogs/insertLink.js +12 -8
  13. package/dist/es/dialogs/viewHtml.d.ts +5 -6
  14. package/dist/es/dialogs/viewHtml.js +3 -3
  15. package/dist/es/main.d.ts +19 -0
  16. package/dist/es/main.js +19 -0
  17. package/dist/es/package-metadata.js +1 -1
  18. package/dist/es/tools/align.d.ts +5 -6
  19. package/dist/es/tools/align.js +5 -5
  20. package/dist/es/tools/applyColor.d.ts +5 -6
  21. package/dist/es/tools/applyColor.js +9 -5
  22. package/dist/es/tools/cleanFormatting.d.ts +5 -6
  23. package/dist/es/tools/cleanFormatting.js +5 -5
  24. package/dist/es/tools/findReplace.d.ts +5 -6
  25. package/dist/es/tools/findReplace.js +7 -7
  26. package/dist/es/tools/fontStyle.d.ts +5 -6
  27. package/dist/es/tools/fontStyle.js +5 -5
  28. package/dist/es/tools/formatBlock.d.ts +5 -6
  29. package/dist/es/tools/formatBlock.js +5 -5
  30. package/dist/es/tools/indent.d.ts +5 -6
  31. package/dist/es/tools/indent.js +5 -5
  32. package/dist/es/tools/inlineFormat.d.ts +5 -6
  33. package/dist/es/tools/inlineFormat.js +5 -5
  34. package/dist/es/tools/insertImage.d.ts +5 -6
  35. package/dist/es/tools/insertImage.js +5 -5
  36. package/dist/es/tools/insertLink.d.ts +5 -6
  37. package/dist/es/tools/insertLink.js +5 -5
  38. package/dist/es/tools/insertTable/popup.d.ts +5 -6
  39. package/dist/es/tools/insertTable/popup.js +3 -3
  40. package/dist/es/tools/insertTable/popupGrid.d.ts +5 -6
  41. package/dist/es/tools/insertTable/popupGrid.js +3 -3
  42. package/dist/es/tools/insertTable/tool.d.ts +5 -6
  43. package/dist/es/tools/insertTable/tool.js +5 -5
  44. package/dist/es/tools/lists.d.ts +5 -6
  45. package/dist/es/tools/lists.js +5 -5
  46. package/dist/es/tools/outdent.d.ts +5 -6
  47. package/dist/es/tools/outdent.js +5 -5
  48. package/dist/es/tools/pdf.d.ts +5 -6
  49. package/dist/es/tools/pdf.js +5 -5
  50. package/dist/es/tools/print.d.ts +5 -6
  51. package/dist/es/tools/print.js +5 -5
  52. package/dist/es/tools/proseMirrorTool.d.ts +5 -6
  53. package/dist/es/tools/proseMirrorTool.js +5 -5
  54. package/dist/es/tools/selectAll.d.ts +5 -6
  55. package/dist/es/tools/selectAll.js +5 -5
  56. package/dist/es/tools/unlink.d.ts +5 -6
  57. package/dist/es/tools/unlink.js +5 -5
  58. package/dist/es/tools/viewHtml.d.ts +5 -6
  59. package/dist/es/tools/viewHtml.js +5 -5
  60. package/dist/npm/Editor.d.ts +49 -131
  61. package/dist/npm/Editor.js +52 -26
  62. package/dist/npm/EditorProps.d.ts +11 -5
  63. package/dist/npm/additionalTypes.ts +7 -1
  64. package/dist/npm/config/toolsSettings.d.ts +4 -0
  65. package/dist/npm/dialogs/FindReplace.d.ts +6 -7
  66. package/dist/npm/dialogs/FindReplace.js +206 -133
  67. package/dist/npm/dialogs/insertImage.d.ts +5 -6
  68. package/dist/npm/dialogs/insertImage.js +25 -15
  69. package/dist/npm/dialogs/insertLink.d.ts +5 -6
  70. package/dist/npm/dialogs/insertLink.js +14 -10
  71. package/dist/npm/dialogs/viewHtml.d.ts +5 -6
  72. package/dist/npm/dialogs/viewHtml.js +5 -5
  73. package/dist/npm/main.d.ts +19 -0
  74. package/dist/npm/main.js +38 -0
  75. package/dist/npm/package-metadata.js +1 -1
  76. package/dist/npm/tools/align.d.ts +5 -6
  77. package/dist/npm/tools/align.js +7 -7
  78. package/dist/npm/tools/applyColor.d.ts +5 -6
  79. package/dist/npm/tools/applyColor.js +11 -7
  80. package/dist/npm/tools/cleanFormatting.d.ts +5 -6
  81. package/dist/npm/tools/cleanFormatting.js +7 -7
  82. package/dist/npm/tools/findReplace.d.ts +5 -6
  83. package/dist/npm/tools/findReplace.js +9 -9
  84. package/dist/npm/tools/fontStyle.d.ts +5 -6
  85. package/dist/npm/tools/fontStyle.js +7 -7
  86. package/dist/npm/tools/formatBlock.d.ts +5 -6
  87. package/dist/npm/tools/formatBlock.js +7 -7
  88. package/dist/npm/tools/indent.d.ts +5 -6
  89. package/dist/npm/tools/indent.js +7 -7
  90. package/dist/npm/tools/inlineFormat.d.ts +5 -6
  91. package/dist/npm/tools/inlineFormat.js +7 -7
  92. package/dist/npm/tools/insertImage.d.ts +5 -6
  93. package/dist/npm/tools/insertImage.js +7 -7
  94. package/dist/npm/tools/insertLink.d.ts +5 -6
  95. package/dist/npm/tools/insertLink.js +7 -7
  96. package/dist/npm/tools/insertTable/popup.d.ts +5 -6
  97. package/dist/npm/tools/insertTable/popup.js +5 -5
  98. package/dist/npm/tools/insertTable/popupGrid.d.ts +5 -6
  99. package/dist/npm/tools/insertTable/popupGrid.js +5 -5
  100. package/dist/npm/tools/insertTable/tool.d.ts +5 -6
  101. package/dist/npm/tools/insertTable/tool.js +7 -7
  102. package/dist/npm/tools/lists.d.ts +5 -6
  103. package/dist/npm/tools/lists.js +7 -7
  104. package/dist/npm/tools/outdent.d.ts +5 -6
  105. package/dist/npm/tools/outdent.js +7 -7
  106. package/dist/npm/tools/pdf.d.ts +5 -6
  107. package/dist/npm/tools/pdf.js +7 -7
  108. package/dist/npm/tools/print.d.ts +5 -6
  109. package/dist/npm/tools/print.js +7 -7
  110. package/dist/npm/tools/proseMirrorTool.d.ts +5 -6
  111. package/dist/npm/tools/proseMirrorTool.js +7 -7
  112. package/dist/npm/tools/selectAll.d.ts +5 -6
  113. package/dist/npm/tools/selectAll.js +7 -7
  114. package/dist/npm/tools/unlink.d.ts +5 -6
  115. package/dist/npm/tools/unlink.js +7 -7
  116. package/dist/npm/tools/viewHtml.d.ts +5 -6
  117. package/dist/npm/tools/viewHtml.js +7 -7
  118. package/package.json +12 -12
@@ -2,6 +2,7 @@
2
2
  import * as Vue from 'vue';
3
3
  var allVue = Vue;
4
4
  var gh = allVue.h;
5
+ import { Button } from '@progress/kendo-vue-buttons';
5
6
  import { Window } from '@progress/kendo-vue-dialogs';
6
7
  import { TabStrip, TabStripTab } from '@progress/kendo-vue-layout';
7
8
  import { provideLocalizationService } from '@progress/kendo-vue-intl';
@@ -13,7 +14,7 @@ var enter = 13,
13
14
  esc = 27;
14
15
  var settings = EditorToolsSettings.findAndReplace; // tslint:enable:max-line-length
15
16
 
16
- var FindAndReplaceDialog = {
17
+ var FindAndReplaceDialogVue2 = {
17
18
  name: 'KendoFindAndReplaceDialog',
18
19
  props: {
19
20
  view: Object,
@@ -30,6 +31,10 @@ var FindAndReplaceDialog = {
30
31
  default: null
31
32
  }
32
33
  },
34
+ created: function created() {
35
+ this._prevMatch = undefined;
36
+ this.nextMatch = undefined;
37
+ },
33
38
  data: function data() {
34
39
  return {
35
40
  selectedTab: 0,
@@ -39,24 +44,26 @@ var FindAndReplaceDialog = {
39
44
  matchWord: false,
40
45
  matchCyclic: false,
41
46
  useRegExp: false,
42
- nextMatch: undefined
47
+ matches: [],
48
+ hasMounted: false
43
49
  };
44
50
  },
45
51
  mounted: function mounted() {
46
52
  if (this.$el) {
47
53
  document.body.append(this.$el);
48
54
  }
55
+
56
+ this.setNextState();
57
+ this.hasMounted = true;
49
58
  },
50
59
 
51
60
  /**
52
61
  * @hidden
53
62
  */
54
63
  updated: function updated() {
64
+ var matches = this.matches || [];
65
+ var nextMatch = this.nextMatch;
55
66
  var view = this.$props.view;
56
- var _a = this.$data,
57
- _b = _a.matches,
58
- matches = _b === void 0 ? [] : _b,
59
- nextMatch = _a.nextMatch;
60
67
 
61
68
  if (this._prevMatch !== nextMatch) {
62
69
  var state = view.state; // highlight selection
@@ -88,11 +95,6 @@ var FindAndReplaceDialog = {
88
95
  this.$el.remove();
89
96
  }
90
97
  },
91
- watch: {
92
- nextMatch: function nextMatch(_newNextMatch, oldMatch) {
93
- this._prevMatch = oldMatch;
94
- }
95
- },
96
98
  // @ts-ignore
97
99
  setup: !gh ? undefined : function () {
98
100
  var v3 = !!gh;
@@ -134,7 +136,7 @@ var FindAndReplaceDialog = {
134
136
  var checkboxes = h("div", {
135
137
  "class": "k-search-options"
136
138
  }, [h("span", [h("input", {
137
- "class": "k-checkbox",
139
+ "class": "k-checkbox k-checkbox-md k-rounded-md",
138
140
  type: "checkbox",
139
141
  attrs: this.v3 ? undefined : {
140
142
  type: "checkbox",
@@ -156,7 +158,7 @@ var FindAndReplaceDialog = {
156
158
  },
157
159
  "class": "k-checkbox-label"
158
160
  }, [localization.toLanguageString(findReplaceMatchCase, messages[findReplaceMatchCase])])]), h("span", [h("input", {
159
- "class": "k-checkbox",
161
+ "class": "k-checkbox k-checkbox-md k-rounded-md",
160
162
  type: "checkbox",
161
163
  attrs: this.v3 ? undefined : {
162
164
  type: "checkbox",
@@ -178,7 +180,7 @@ var FindAndReplaceDialog = {
178
180
  },
179
181
  "class": "k-checkbox-label"
180
182
  }, [localization.toLanguageString(findReplaceMatchWord, messages[findReplaceMatchWord])])]), h("span", [h("input", {
181
- "class": "k-checkbox",
183
+ "class": "k-checkbox k-checkbox-md k-rounded-md",
182
184
  type: "checkbox",
183
185
  attrs: this.v3 ? undefined : {
184
186
  type: "checkbox",
@@ -200,7 +202,7 @@ var FindAndReplaceDialog = {
200
202
  },
201
203
  "class": "k-checkbox-label"
202
204
  }, [localization.toLanguageString(findReplaceMatchCyclic, messages[findReplaceMatchCyclic])])]), h("span", [h("input", {
203
- "class": "k-checkbox",
205
+ "class": "k-checkbox k-checkbox-md k-rounded-md",
204
206
  type: "checkbox",
205
207
  attrs: this.v3 ? undefined : {
206
208
  type: "checkbox",
@@ -222,58 +224,95 @@ var FindAndReplaceDialog = {
222
224
  },
223
225
  "class": "k-checkbox-label"
224
226
  }, [localization.toLanguageString(findReplaceUseRegExp, messages[findReplaceUseRegExp])])])]);
225
- var navigation = h("div", {
226
- "class": "k-matches-container"
227
- }, [h("button", {
228
- "class": "k-button k-flat k-primary",
229
- onClick: this.onFindPrev,
230
- on: this.v3 ? undefined : {
231
- "click": this.onFindPrev
232
- }
233
- }, [h("span", {
234
- "class": "k-icon k-i-arrow-chevron-left"
235
- }), localization.toLanguageString(findReplacePrevMatch, messages[findReplacePrevMatch])]), h("span", [this.matchesMessage(localization.toLanguageString(findReplaceMatches, messages[findReplaceMatches]))]), h("button", {
236
- "class": "k-button k-flat k-primary",
237
- onClick: this.onFindNext,
238
- on: this.v3 ? undefined : {
239
- "click": this.onFindNext
240
- }
241
- }, [localization.toLanguageString(findReplaceNextMatch, messages[findReplaceNextMatch]), h("span", {
242
- "class": "k-icon k-i-arrow-chevron-right"
243
- })])]);
244
- var findWhatLabel = h("div", {
245
- "class": "k-edit-label"
246
- }, [h("label", {
247
- "for": "findWhat",
248
- attrs: this.v3 ? undefined : {
249
- "for": "findWhat"
250
- }
251
- }, [localization.toLanguageString(findReplaceFindWhat, messages[findReplaceFindWhat])])]);
252
- var findWhat = h("div", {
253
- "class": "k-edit-field"
254
- }, [h("input", {
255
- id: "findWhat",
256
- attrs: this.v3 ? undefined : {
257
- id: "findWhat",
227
+
228
+ var navigation = function navigation(findWhatRef) {
229
+ var isRtl = this.$props.dir === 'rtl';
230
+ var prevButton = // @ts-ignore function children
231
+ h(Button, {
232
+ fillMode: 'flat',
233
+ attrs: this.v3 ? undefined : {
234
+ fillMode: 'flat',
235
+ themeColor: 'primary'
236
+ },
237
+ themeColor: 'primary',
238
+ onClick: this.onFindPrev,
239
+ on: this.v3 ? undefined : {
240
+ "click": this.onFindPrev
241
+ }
242
+ }, this.v3 ? function () {
243
+ return [h("span", {
244
+ "class": "k-icon k-i-arrow-chevron-" + (isRtl ? 'right' : 'left')
245
+ }), localization.toLanguageString(findReplacePrevMatch, messages[findReplacePrevMatch])];
246
+ } : [h("span", {
247
+ "class": "k-icon k-i-arrow-chevron-" + (isRtl ? 'right' : 'left')
248
+ }), localization.toLanguageString(findReplacePrevMatch, messages[findReplacePrevMatch])]);
249
+ var nextButton = // @ts-ignore function children
250
+ h(Button, {
251
+ fillMode: 'flat',
252
+ attrs: this.v3 ? undefined : {
253
+ fillMode: 'flat',
254
+ themeColor: 'primary'
255
+ },
256
+ themeColor: 'primary',
257
+ onClick: this.onFindNext,
258
+ on: this.v3 ? undefined : {
259
+ "click": this.onFindNext
260
+ }
261
+ }, this.v3 ? function () {
262
+ return [localization.toLanguageString(findReplaceNextMatch, messages[findReplaceNextMatch]), h("span", {
263
+ "class": "k-icon k-i-arrow-chevron-" + (isRtl ? 'left' : 'right')
264
+ })];
265
+ } : [localization.toLanguageString(findReplaceNextMatch, messages[findReplaceNextMatch]), h("span", {
266
+ "class": "k-icon k-i-arrow-chevron-" + (isRtl ? 'left' : 'right')
267
+ })]);
268
+ return h("div", {
269
+ "class": "k-matches-container"
270
+ }, [prevButton, this.hasMounted && h("span", {
271
+ ref: findWhatRef
272
+ }, [this.matchesMessage(localization.toLanguageString(findReplaceMatches, messages[findReplaceMatches]))]), nextButton]);
273
+ };
274
+
275
+ var findWhatLabel = function findWhatLabel(findWhatId) {
276
+ return h("div", {
277
+ "class": "k-edit-label"
278
+ }, [h("label", {
279
+ ref: findWhatId,
280
+ "for": findWhatId,
281
+ attrs: this.v3 ? undefined : {
282
+ "for": findWhatId
283
+ }
284
+ }, [localization.toLanguageString(findReplaceFindWhat, messages[findReplaceFindWhat])])]);
285
+ };
286
+
287
+ var findWhat = function findWhat(findWhatId) {
288
+ return h("div", {
289
+ "class": "k-edit-field"
290
+ }, [h("span", {
291
+ "class": "k-textbox k-input k-input-md k-rounded-md k-input-solid"
292
+ }, [h("input", {
293
+ id: findWhatId,
294
+ attrs: this.v3 ? undefined : {
295
+ id: findWhatId,
296
+ type: "text"
297
+ },
298
+ ref: findWhatId,
258
299
  type: "text",
259
- autoFocus: true
260
- },
261
- type: "text",
262
- "class": "k-textbox",
263
- value: this.v3 ? searchText : null,
264
- domProps: this.v3 ? undefined : {
265
- "value": searchText
266
- },
267
- onInput: this.onSearchChange,
268
- on: this.v3 ? undefined : {
269
- "input": this.onSearchChange,
270
- "focus": this.onSearchChange,
271
- "keydown": this.onKeyDown
272
- },
273
- onFocus: this.onSearchChange,
274
- onKeydown: this.onKeyDown,
275
- autoFocus: true
276
- })]);
300
+ "class": "k-input-inner",
301
+ value: this.v3 ? searchText : null,
302
+ domProps: this.v3 ? undefined : {
303
+ "value": searchText
304
+ },
305
+ onInput: this.onSearchChange,
306
+ on: this.v3 ? undefined : {
307
+ "input": this.onSearchChange,
308
+ "focus": this.onSearchChange,
309
+ "keydown": this.onKeyDown
310
+ },
311
+ onFocus: this.onSearchChange,
312
+ onKeydown: this.onKeyDown
313
+ })])]);
314
+ };
315
+
277
316
  var replaceWithLabel = h("div", {
278
317
  "class": "k-edit-label"
279
318
  }, [h("label", {
@@ -284,13 +323,15 @@ var FindAndReplaceDialog = {
284
323
  }, [localization.toLanguageString(findReplaceReplaceWith, messages[findReplaceReplaceWith])])]);
285
324
  var replaceWith = h("div", {
286
325
  "class": "k-edit-field"
326
+ }, [h("span", {
327
+ "class": "k-textbox k-input k-input-md k-rounded-md k-input-solid"
287
328
  }, [h("input", {
288
329
  id: "replaceWith",
289
330
  attrs: this.v3 ? undefined : {
290
331
  id: "replaceWith",
291
332
  type: "text"
292
333
  },
293
- "class": "k-textbox",
334
+ "class": "k-input-inner",
294
335
  type: "text",
295
336
  value: this.v3 ? replaceText : null,
296
337
  domProps: this.v3 ? undefined : {
@@ -300,7 +341,7 @@ var FindAndReplaceDialog = {
300
341
  on: this.v3 ? undefined : {
301
342
  "input": this.onReplaceChange
302
343
  }
303
- })]);
344
+ })])]);
304
345
  return (// @ts-ignore function children
305
346
  h(Window, {
306
347
  title: localization.toLanguageString(findReplaceDialogTitle, messages[findReplaceDialogTitle]),
@@ -317,7 +358,8 @@ var FindAndReplaceDialog = {
317
358
  },
318
359
  maximizeButton: function maximizeButton() {
319
360
  return null;
320
- }
361
+ },
362
+ dir: this.$props.dir
321
363
  },
322
364
  onClose: this.onClose,
323
365
  on: this.v3 ? undefined : {
@@ -334,15 +376,18 @@ var FindAndReplaceDialog = {
334
376
  },
335
377
  maximizeButton: function maximizeButton() {
336
378
  return null;
337
- }
379
+ },
380
+ dir: this.$props.dir
338
381
  }, this.v3 ? function () {
339
382
  return [// @ts-ignore function children
340
383
  h(TabStrip, {
341
- selected: _this.selectedTab,
384
+ dir: _this.$props.dir,
342
385
  attrs: _this.v3 ? undefined : {
386
+ dir: _this.$props.dir,
343
387
  selected: _this.selectedTab,
344
388
  animation: false
345
389
  },
390
+ selected: _this.selectedTab,
346
391
  "class": "k-editor-find-replace",
347
392
  onSelect: _this.onTabSelect,
348
393
  on: _this.v3 ? undefined : {
@@ -359,10 +404,10 @@ var FindAndReplaceDialog = {
359
404
  }, _this.v3 ? function () {
360
405
  return [h("div", {
361
406
  "class": "k-edit-form-container"
362
- }, [findWhatLabel, findWhat]), checkboxes, navigation];
407
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')];
363
408
  } : [h("div", {
364
409
  "class": "k-edit-form-container"
365
- }, [findWhatLabel, findWhat]), checkboxes, navigation]), // @ts-ignore function children
410
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')]), // @ts-ignore function children
366
411
  h(TabStripTab, {
367
412
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace]),
368
413
  attrs: _this.v3 ? undefined : {
@@ -371,10 +416,10 @@ var FindAndReplaceDialog = {
371
416
  }, _this.v3 ? function () {
372
417
  return [h("div", {
373
418
  "class": "k-edit-form-container"
374
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
419
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
375
420
  "class": "k-actions k-hstack k-justify-content-end"
376
- }, [h("button", {
377
- "class": "k-button",
421
+ }, [// @ts-ignore function children
422
+ h(Button, {
378
423
  disabled: !Boolean(nextMatch),
379
424
  attrs: _this.v3 ? undefined : {
380
425
  disabled: !Boolean(nextMatch)
@@ -383,8 +428,10 @@ var FindAndReplaceDialog = {
383
428
  on: _this.v3 ? undefined : {
384
429
  "click": _this.onReplace
385
430
  }
386
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
387
- "class": "k-button",
431
+ }, _this.v3 ? function () {
432
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
433
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), // @ts-ignore function children
434
+ h(Button, {
388
435
  disabled: !Boolean(nextMatch),
389
436
  attrs: _this.v3 ? undefined : {
390
437
  disabled: !Boolean(nextMatch)
@@ -393,13 +440,14 @@ var FindAndReplaceDialog = {
393
440
  on: _this.v3 ? undefined : {
394
441
  "click": _this.onReplaceAll
395
442
  }
396
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation];
443
+ }, _this.v3 ? function () {
444
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
445
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')];
397
446
  } : [h("div", {
398
447
  "class": "k-edit-form-container"
399
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
448
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
400
449
  "class": "k-actions k-hstack k-justify-content-end"
401
- }, [h("button", {
402
- "class": "k-button",
450
+ }, [h(Button, {
403
451
  disabled: !Boolean(nextMatch),
404
452
  attrs: _this.v3 ? undefined : {
405
453
  disabled: !Boolean(nextMatch)
@@ -408,8 +456,9 @@ var FindAndReplaceDialog = {
408
456
  on: _this.v3 ? undefined : {
409
457
  "click": _this.onReplace
410
458
  }
411
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
412
- "class": "k-button",
459
+ }, _this.v3 ? function () {
460
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
461
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
413
462
  disabled: !Boolean(nextMatch),
414
463
  attrs: _this.v3 ? undefined : {
415
464
  disabled: !Boolean(nextMatch)
@@ -418,7 +467,9 @@ var FindAndReplaceDialog = {
418
467
  on: _this.v3 ? undefined : {
419
468
  "click": _this.onReplaceAll
420
469
  }
421
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation])];
470
+ }, _this.v3 ? function () {
471
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
472
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')])];
422
473
  } : [h(TabStripTab, {
423
474
  title: localization.toLanguageString(findReplaceTabFind, messages[findReplaceTabFind]),
424
475
  attrs: _this.v3 ? undefined : {
@@ -427,10 +478,10 @@ var FindAndReplaceDialog = {
427
478
  }, _this.v3 ? function () {
428
479
  return [h("div", {
429
480
  "class": "k-edit-form-container"
430
- }, [findWhatLabel, findWhat]), checkboxes, navigation];
481
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')];
431
482
  } : [h("div", {
432
483
  "class": "k-edit-form-container"
433
- }, [findWhatLabel, findWhat]), checkboxes, navigation]), h(TabStripTab, {
484
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')]), h(TabStripTab, {
434
485
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace]),
435
486
  attrs: _this.v3 ? undefined : {
436
487
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace])
@@ -438,10 +489,9 @@ var FindAndReplaceDialog = {
438
489
  }, _this.v3 ? function () {
439
490
  return [h("div", {
440
491
  "class": "k-edit-form-container"
441
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
492
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
442
493
  "class": "k-actions k-hstack k-justify-content-end"
443
- }, [h("button", {
444
- "class": "k-button",
494
+ }, [h(Button, {
445
495
  disabled: !Boolean(nextMatch),
446
496
  attrs: _this.v3 ? undefined : {
447
497
  disabled: !Boolean(nextMatch)
@@ -450,8 +500,9 @@ var FindAndReplaceDialog = {
450
500
  on: _this.v3 ? undefined : {
451
501
  "click": _this.onReplace
452
502
  }
453
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
454
- "class": "k-button",
503
+ }, _this.v3 ? function () {
504
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
505
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
455
506
  disabled: !Boolean(nextMatch),
456
507
  attrs: _this.v3 ? undefined : {
457
508
  disabled: !Boolean(nextMatch)
@@ -460,13 +511,14 @@ var FindAndReplaceDialog = {
460
511
  on: _this.v3 ? undefined : {
461
512
  "click": _this.onReplaceAll
462
513
  }
463
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation];
514
+ }, _this.v3 ? function () {
515
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
516
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')];
464
517
  } : [h("div", {
465
518
  "class": "k-edit-form-container"
466
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
519
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
467
520
  "class": "k-actions k-hstack k-justify-content-end"
468
- }, [h("button", {
469
- "class": "k-button",
521
+ }, [h(Button, {
470
522
  disabled: !Boolean(nextMatch),
471
523
  attrs: _this.v3 ? undefined : {
472
524
  disabled: !Boolean(nextMatch)
@@ -475,8 +527,9 @@ var FindAndReplaceDialog = {
475
527
  on: _this.v3 ? undefined : {
476
528
  "click": _this.onReplace
477
529
  }
478
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
479
- "class": "k-button",
530
+ }, _this.v3 ? function () {
531
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
532
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
480
533
  disabled: !Boolean(nextMatch),
481
534
  attrs: _this.v3 ? undefined : {
482
535
  disabled: !Boolean(nextMatch)
@@ -485,13 +538,17 @@ var FindAndReplaceDialog = {
485
538
  on: _this.v3 ? undefined : {
486
539
  "click": _this.onReplaceAll
487
540
  }
488
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation])])];
541
+ }, _this.v3 ? function () {
542
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
543
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')])])];
489
544
  } : [h(TabStrip, {
490
- selected: _this.selectedTab,
545
+ dir: _this.$props.dir,
491
546
  attrs: _this.v3 ? undefined : {
547
+ dir: _this.$props.dir,
492
548
  selected: _this.selectedTab,
493
549
  animation: false
494
550
  },
551
+ selected: _this.selectedTab,
495
552
  "class": "k-editor-find-replace",
496
553
  onSelect: _this.onTabSelect,
497
554
  on: _this.v3 ? undefined : {
@@ -507,10 +564,10 @@ var FindAndReplaceDialog = {
507
564
  }, _this.v3 ? function () {
508
565
  return [h("div", {
509
566
  "class": "k-edit-form-container"
510
- }, [findWhatLabel, findWhat]), checkboxes, navigation];
567
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')];
511
568
  } : [h("div", {
512
569
  "class": "k-edit-form-container"
513
- }, [findWhatLabel, findWhat]), checkboxes, navigation]), h(TabStripTab, {
570
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')]), h(TabStripTab, {
514
571
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace]),
515
572
  attrs: _this.v3 ? undefined : {
516
573
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace])
@@ -518,10 +575,9 @@ var FindAndReplaceDialog = {
518
575
  }, _this.v3 ? function () {
519
576
  return [h("div", {
520
577
  "class": "k-edit-form-container"
521
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
578
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
522
579
  "class": "k-actions k-hstack k-justify-content-end"
523
- }, [h("button", {
524
- "class": "k-button",
580
+ }, [h(Button, {
525
581
  disabled: !Boolean(nextMatch),
526
582
  attrs: _this.v3 ? undefined : {
527
583
  disabled: !Boolean(nextMatch)
@@ -530,8 +586,9 @@ var FindAndReplaceDialog = {
530
586
  on: _this.v3 ? undefined : {
531
587
  "click": _this.onReplace
532
588
  }
533
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
534
- "class": "k-button",
589
+ }, _this.v3 ? function () {
590
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
591
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
535
592
  disabled: !Boolean(nextMatch),
536
593
  attrs: _this.v3 ? undefined : {
537
594
  disabled: !Boolean(nextMatch)
@@ -540,13 +597,14 @@ var FindAndReplaceDialog = {
540
597
  on: _this.v3 ? undefined : {
541
598
  "click": _this.onReplaceAll
542
599
  }
543
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation];
600
+ }, _this.v3 ? function () {
601
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
602
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')];
544
603
  } : [h("div", {
545
604
  "class": "k-edit-form-container"
546
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
605
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
547
606
  "class": "k-actions k-hstack k-justify-content-end"
548
- }, [h("button", {
549
- "class": "k-button",
607
+ }, [h(Button, {
550
608
  disabled: !Boolean(nextMatch),
551
609
  attrs: _this.v3 ? undefined : {
552
610
  disabled: !Boolean(nextMatch)
@@ -555,8 +613,9 @@ var FindAndReplaceDialog = {
555
613
  on: _this.v3 ? undefined : {
556
614
  "click": _this.onReplace
557
615
  }
558
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
559
- "class": "k-button",
616
+ }, _this.v3 ? function () {
617
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
618
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
560
619
  disabled: !Boolean(nextMatch),
561
620
  attrs: _this.v3 ? undefined : {
562
621
  disabled: !Boolean(nextMatch)
@@ -565,7 +624,9 @@ var FindAndReplaceDialog = {
565
624
  on: _this.v3 ? undefined : {
566
625
  "click": _this.onReplaceAll
567
626
  }
568
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation])];
627
+ }, _this.v3 ? function () {
628
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
629
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')])];
569
630
  } : [h(TabStripTab, {
570
631
  title: localization.toLanguageString(findReplaceTabFind, messages[findReplaceTabFind]),
571
632
  attrs: _this.v3 ? undefined : {
@@ -574,10 +635,10 @@ var FindAndReplaceDialog = {
574
635
  }, _this.v3 ? function () {
575
636
  return [h("div", {
576
637
  "class": "k-edit-form-container"
577
- }, [findWhatLabel, findWhat]), checkboxes, navigation];
638
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')];
578
639
  } : [h("div", {
579
640
  "class": "k-edit-form-container"
580
- }, [findWhatLabel, findWhat]), checkboxes, navigation]), h(TabStripTab, {
641
+ }, [findWhatLabel.call(_this, 'findWhatFind'), findWhat.call(_this, 'findWhatFind')]), checkboxes, navigation.call(_this, 'findWhatFind')]), h(TabStripTab, {
581
642
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace]),
582
643
  attrs: _this.v3 ? undefined : {
583
644
  title: localization.toLanguageString(findReplaceTabReplace, messages[findReplaceTabReplace])
@@ -585,10 +646,9 @@ var FindAndReplaceDialog = {
585
646
  }, _this.v3 ? function () {
586
647
  return [h("div", {
587
648
  "class": "k-edit-form-container"
588
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
649
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
589
650
  "class": "k-actions k-hstack k-justify-content-end"
590
- }, [h("button", {
591
- "class": "k-button",
651
+ }, [h(Button, {
592
652
  disabled: !Boolean(nextMatch),
593
653
  attrs: _this.v3 ? undefined : {
594
654
  disabled: !Boolean(nextMatch)
@@ -597,8 +657,9 @@ var FindAndReplaceDialog = {
597
657
  on: _this.v3 ? undefined : {
598
658
  "click": _this.onReplace
599
659
  }
600
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
601
- "class": "k-button",
660
+ }, _this.v3 ? function () {
661
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
662
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
602
663
  disabled: !Boolean(nextMatch),
603
664
  attrs: _this.v3 ? undefined : {
604
665
  disabled: !Boolean(nextMatch)
@@ -607,13 +668,14 @@ var FindAndReplaceDialog = {
607
668
  on: _this.v3 ? undefined : {
608
669
  "click": _this.onReplaceAll
609
670
  }
610
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation];
671
+ }, _this.v3 ? function () {
672
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
673
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')];
611
674
  } : [h("div", {
612
675
  "class": "k-edit-form-container"
613
- }, [findWhatLabel, findWhat, replaceWithLabel, replaceWith]), h("div", {
676
+ }, [findWhatLabel.call(_this, 'findWhatReplace'), findWhat.call(_this, 'findWhatReplace'), replaceWithLabel, replaceWith]), h("div", {
614
677
  "class": "k-actions k-hstack k-justify-content-end"
615
- }, [h("button", {
616
- "class": "k-button",
678
+ }, [h(Button, {
617
679
  disabled: !Boolean(nextMatch),
618
680
  attrs: _this.v3 ? undefined : {
619
681
  disabled: !Boolean(nextMatch)
@@ -622,8 +684,9 @@ var FindAndReplaceDialog = {
622
684
  on: _this.v3 ? undefined : {
623
685
  "click": _this.onReplace
624
686
  }
625
- }, [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h("button", {
626
- "class": "k-button",
687
+ }, _this.v3 ? function () {
688
+ return [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])];
689
+ } : [localization.toLanguageString(findReplaceReplace, messages[findReplaceReplace])]), h(Button, {
627
690
  disabled: !Boolean(nextMatch),
628
691
  attrs: _this.v3 ? undefined : {
629
692
  disabled: !Boolean(nextMatch)
@@ -632,7 +695,9 @@ var FindAndReplaceDialog = {
632
695
  on: _this.v3 ? undefined : {
633
696
  "click": _this.onReplaceAll
634
697
  }
635
- }, [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation])])])
698
+ }, _this.v3 ? function () {
699
+ return [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])];
700
+ } : [localization.toLanguageString(findReplaceReplaceAll, messages[findReplaceReplaceAll])])]), checkboxes, navigation.call(_this, 'findWhatReplace')])])])
636
701
  ); // document.body);
637
702
  },
638
703
  methods: {
@@ -695,7 +760,12 @@ var FindAndReplaceDialog = {
695
760
  var transaction = view.state.tr.setSelection(selectionResult);
696
761
  transaction.scrollIntoView();
697
762
  view.updateState(view.state.apply(transaction));
763
+ this._prevMatch = this.nextMatch;
698
764
  this.nextMatch = selectionResult;
765
+
766
+ if (this._prevMatch !== this.nextMatch) {
767
+ this.$forceUpdate();
768
+ }
699
769
  }
700
770
  },
701
771
  onReplace: function onReplace() {
@@ -776,14 +846,16 @@ var FindAndReplaceDialog = {
776
846
  var nextMatch = !this.searchText && matches[0] || matches.find(function (match) {
777
847
  return match.from >= selection_1.from;
778
848
  }) || this.matchCyclic && matches[0] || undefined;
849
+ this._prevMatch = this.nextMatch;
779
850
  this.matches = matches;
780
851
  this.nextMatch = nextMatch;
781
852
  } else {
782
- this.matches = undefined;
853
+ this._prevMatch = this.nextMatch;
854
+ this.matches = [];
783
855
  this.nextMatch = undefined;
784
856
  }
785
857
  }
786
858
  }
787
859
  };
788
- var FindAndReplaceDialogVue3 = FindAndReplaceDialog;
789
- export { FindAndReplaceDialog, FindAndReplaceDialogVue3 };
860
+ var FindAndReplaceDialog = FindAndReplaceDialogVue2;
861
+ export { FindAndReplaceDialog, FindAndReplaceDialogVue2 };