@vaadin/rich-text-editor 24.0.0-alpha1 → 24.0.0-alpha10

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/README.md CHANGED
@@ -58,7 +58,7 @@ Read the [contributing guide](https://vaadin.com/docs/latest/contributing/overvi
58
58
 
59
59
  ## License
60
60
 
61
- Commercial Vaadin Developer License 4.0 (CVDLv4). For license terms, see LICENSE.
61
+ This program is available under Vaadin Commercial License and Service Terms. For license terms, see LICENSE.
62
62
 
63
63
  Vaadin collects usage statistics at development time to improve this product.
64
64
  For details and to opt-out, see https://github.com/vaadin/vaadin-usage-statistics.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/rich-text-editor",
3
- "version": "24.0.0-alpha1",
3
+ "version": "24.0.0-alpha10",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -40,14 +40,14 @@
40
40
  ],
41
41
  "dependencies": {
42
42
  "@polymer/polymer": "^3.0.0",
43
- "@vaadin/button": "24.0.0-alpha1",
44
- "@vaadin/component-base": "24.0.0-alpha1",
45
- "@vaadin/confirm-dialog": "24.0.0-alpha1",
46
- "@vaadin/text-field": "24.0.0-alpha1",
47
- "@vaadin/tooltip": "24.0.0-alpha1",
48
- "@vaadin/vaadin-lumo-styles": "24.0.0-alpha1",
49
- "@vaadin/vaadin-material-styles": "24.0.0-alpha1",
50
- "@vaadin/vaadin-themable-mixin": "24.0.0-alpha1"
43
+ "@vaadin/button": "24.0.0-alpha10",
44
+ "@vaadin/component-base": "24.0.0-alpha10",
45
+ "@vaadin/confirm-dialog": "24.0.0-alpha10",
46
+ "@vaadin/text-field": "24.0.0-alpha10",
47
+ "@vaadin/tooltip": "24.0.0-alpha10",
48
+ "@vaadin/vaadin-lumo-styles": "24.0.0-alpha10",
49
+ "@vaadin/vaadin-material-styles": "24.0.0-alpha10",
50
+ "@vaadin/vaadin-themable-mixin": "24.0.0-alpha10"
51
51
  },
52
52
  "devDependencies": {
53
53
  "@esm-bundle/chai": "^4.3.4",
@@ -62,5 +62,5 @@
62
62
  "web-types.json",
63
63
  "web-types.lit.json"
64
64
  ],
65
- "gitHead": "427527c27c4b27822d61fd41d38d7b170134770b"
65
+ "gitHead": "2e04534d8b47bcd216f89b5f849bafef1a73b174"
66
66
  }
@@ -1,7 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright (c) 2018 - 2022 Vaadin Ltd.
4
- * This program is available under Commercial Vaadin Developer License 4.0, available at https://vaadin.com/license/cvdl-4.0.
3
+ * Copyright (c) 2000 - 2023 Vaadin Ltd.
4
+ *
5
+ * This program is available under Vaadin Commercial License and Service Terms.
6
+ *
7
+ *
8
+ * See https://vaadin.com/commercial-license-and-service-terms for the full
9
+ * license.
5
10
  */
6
11
  import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
7
12
 
@@ -1,7 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright (c) 2018 - 2022 Vaadin Ltd.
4
- * This program is available under Commercial Vaadin Developer License 4.0, available at https://vaadin.com/license/cvdl-4.0.
3
+ * Copyright (c) 2000 - 2023 Vaadin Ltd.
4
+ *
5
+ * This program is available under Vaadin Commercial License and Service Terms.
6
+ *
7
+ *
8
+ * See https://vaadin.com/commercial-license-and-service-terms for the full
9
+ * license.
5
10
  */
6
11
  import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
7
12
 
@@ -1,7 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright (c) 2018 - 2022 Vaadin Ltd.
4
- * This program is available under Commercial Vaadin Developer License 4.0, available at https://vaadin.com/license/cvdl-4.0.
3
+ * Copyright (c) 2000 - 2023 Vaadin Ltd.
4
+ *
5
+ * This program is available under Vaadin Commercial License and Service Terms.
6
+ *
7
+ *
8
+ * See https://vaadin.com/commercial-license-and-service-terms for the full
9
+ * license.
5
10
  */
6
11
  import { css } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
7
12
  import { contentStyles } from './vaadin-rich-text-editor-content-styles.js';
@@ -1,7 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright (c) 2018 - 2022 Vaadin Ltd.
4
- * This program is available under Commercial Vaadin Developer License 4.0, available at https://vaadin.com/license/cvdl-4.0.
3
+ * Copyright (c) 2000 - 2023 Vaadin Ltd.
4
+ *
5
+ * This program is available under Vaadin Commercial License and Service Terms.
6
+ *
7
+ *
8
+ * See https://vaadin.com/commercial-license-and-service-terms for the full
9
+ * license.
5
10
  */
6
11
  import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
7
12
  import { iconsStyles } from './vaadin-rich-text-editor-icons.js';
@@ -1,7 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright (c) 2018 - 2022 Vaadin Ltd.
4
- * This program is available under Commercial Vaadin Developer License 4.0, available at https://vaadin.com/license/cvdl-4.0.
3
+ * Copyright (c) 2000 - 2023 Vaadin Ltd.
4
+ *
5
+ * This program is available under Vaadin Commercial License and Service Terms.
6
+ *
7
+ *
8
+ * See https://vaadin.com/commercial-license-and-service-terms for the full
9
+ * license.
5
10
  */
6
11
  import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
7
12
  import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
@@ -1,7 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright (c) 2018 - 2022 Vaadin Ltd.
4
- * This program is available under Commercial Vaadin Developer License 4.0, available at https://vaadin.com/license/cvdl-4.0.
3
+ * Copyright (c) 2000 - 2023 Vaadin Ltd.
4
+ *
5
+ * This program is available under Vaadin Commercial License and Service Terms.
6
+ *
7
+ *
8
+ * See https://vaadin.com/commercial-license-and-service-terms for the full
9
+ * license.
5
10
  */
6
11
  import '@vaadin/button/src/vaadin-button.js';
7
12
  import '@vaadin/confirm-dialog/src/vaadin-confirm-dialog.js';
@@ -506,6 +511,13 @@ class RichTextEditor extends ElementMixin(ThemableMixin(PolymerElement)) {
506
511
  return ['_valueChanged(value, _editor)', '_disabledChanged(disabled, readonly, _editor)'];
507
512
  }
508
513
 
514
+ /** @private */
515
+ get _toolbarButtons() {
516
+ return Array.from(this.shadowRoot.querySelectorAll('[part="toolbar"] button')).filter((btn) => {
517
+ return btn.clientHeight > 0;
518
+ });
519
+ }
520
+
509
521
  /**
510
522
  * @param {string} prop
511
523
  * @param {?string} oldVal
@@ -901,17 +913,17 @@ class RichTextEditor extends ElementMixin(ThemableMixin(PolymerElement)) {
901
913
  let content = editor.innerHTML;
902
914
 
903
915
  // Remove Quill classes, e.g. ql-syntax, except for align
904
- content = content.replace(/\s*ql-(?!align)[\w-]*\s*/g, '');
916
+ content = content.replace(/\s*ql-(?!align)[\w-]*\s*/gu, '');
905
917
 
906
918
  // Replace Quill align classes with inline styles
907
919
  [this.__dir === 'rtl' ? 'left' : 'right', 'center', 'justify'].forEach((align) => {
908
920
  content = content.replace(
909
- new RegExp(` class=[\\\\]?"\\s?ql-align-${align}[\\\\]?"`, 'g'),
921
+ new RegExp(` class=[\\\\]?"\\s?ql-align-${align}[\\\\]?"`, 'gu'),
910
922
  ` style="text-align: ${align}"`,
911
923
  );
912
924
  });
913
925
 
914
- content = content.replace(/ class=""/g, '');
926
+ content = content.replace(/ class=""/gu, '');
915
927
 
916
928
  this._setHtmlValue(content);
917
929
  }
@@ -953,13 +965,6 @@ class RichTextEditor extends ElementMixin(ThemableMixin(PolymerElement)) {
953
965
  );
954
966
  }
955
967
 
956
- /** @private */
957
- get _toolbarButtons() {
958
- return Array.from(this.shadowRoot.querySelectorAll('[part="toolbar"] button')).filter((btn) => {
959
- return btn.clientHeight > 0;
960
- });
961
- }
962
-
963
968
  /** @private */
964
969
  _clear() {
965
970
  this._editor.deleteText(0, this._editor.getLength(), SOURCE.SILENT);
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/rich-text-editor",
4
- "version": "24.0.0-alpha1",
4
+ "version": "24.0.0-alpha10",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/rich-text-editor",
4
- "version": "24.0.0-alpha1",
4
+ "version": "24.0.0-alpha10",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {