@ckeditor/ckeditor5-ui 31.1.0 → 32.0.0

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 (145) hide show
  1. package/LICENSE.md +2 -2
  2. package/lang/translations/ar.po +2 -2
  3. package/lang/translations/ast.po +1 -1
  4. package/lang/translations/az.po +1 -1
  5. package/lang/translations/cs.po +1 -1
  6. package/lang/translations/da.po +1 -1
  7. package/lang/translations/de-ch.po +1 -1
  8. package/lang/translations/de.po +1 -1
  9. package/lang/translations/el.po +2 -2
  10. package/lang/translations/en-au.po +1 -1
  11. package/lang/translations/en-gb.po +1 -1
  12. package/lang/translations/en.po +1 -1
  13. package/lang/translations/eo.po +1 -1
  14. package/lang/translations/es.po +1 -1
  15. package/lang/translations/et.po +1 -1
  16. package/lang/translations/eu.po +1 -1
  17. package/lang/translations/fa.po +1 -1
  18. package/lang/translations/fi.po +1 -1
  19. package/lang/translations/fr.po +1 -1
  20. package/lang/translations/gl.po +1 -1
  21. package/lang/translations/he.po +1 -1
  22. package/lang/translations/hi.po +1 -1
  23. package/lang/translations/hr.po +1 -1
  24. package/lang/translations/hu.po +1 -1
  25. package/lang/translations/id.po +1 -1
  26. package/lang/translations/it.po +1 -1
  27. package/lang/translations/ja.po +1 -1
  28. package/lang/translations/km.po +1 -1
  29. package/lang/translations/kn.po +1 -1
  30. package/lang/translations/ko.po +1 -1
  31. package/lang/translations/ku.po +1 -1
  32. package/lang/translations/lt.po +1 -1
  33. package/lang/translations/lv.po +1 -1
  34. package/lang/translations/nb.po +1 -1
  35. package/lang/translations/ne.po +1 -1
  36. package/lang/translations/nl.po +2 -2
  37. package/lang/translations/no.po +1 -1
  38. package/lang/translations/pl.po +1 -1
  39. package/lang/translations/pt-br.po +1 -1
  40. package/lang/translations/pt.po +1 -1
  41. package/lang/translations/ro.po +1 -1
  42. package/lang/translations/ru.po +1 -1
  43. package/lang/translations/sk.po +1 -1
  44. package/lang/translations/sl.po +1 -1
  45. package/lang/translations/sq.po +1 -1
  46. package/lang/translations/sr-latn.po +1 -1
  47. package/lang/translations/sr.po +1 -1
  48. package/lang/translations/sv.po +1 -1
  49. package/lang/translations/th.po +1 -1
  50. package/lang/translations/tk.po +1 -1
  51. package/lang/translations/tr.po +1 -1
  52. package/lang/translations/ug.po +2 -2
  53. package/lang/translations/uk.po +1 -1
  54. package/lang/translations/uz.po +1 -1
  55. package/lang/translations/vi.po +1 -1
  56. package/lang/translations/zh-cn.po +1 -1
  57. package/lang/translations/zh.po +1 -1
  58. package/package.json +20 -20
  59. package/src/bindings/clickoutsidehandler.js +1 -1
  60. package/src/bindings/injectcsstransitiondisabler.js +1 -1
  61. package/src/bindings/preventdefault.js +1 -1
  62. package/src/bindings/submithandler.js +1 -1
  63. package/src/button/button.jsdoc +1 -1
  64. package/src/button/buttonview.js +1 -1
  65. package/src/button/switchbuttonview.js +1 -1
  66. package/src/colorgrid/colorgridview.js +1 -1
  67. package/src/colorgrid/colortileview.js +1 -1
  68. package/src/colorgrid/utils.js +1 -1
  69. package/src/componentfactory.js +1 -1
  70. package/src/dropdown/button/dropdownbutton.jsdoc +1 -1
  71. package/src/dropdown/button/dropdownbuttonview.js +1 -1
  72. package/src/dropdown/button/splitbuttonview.js +1 -1
  73. package/src/dropdown/dropdownpanelfocusable.jsdoc +1 -1
  74. package/src/dropdown/dropdownpanelview.js +1 -1
  75. package/src/dropdown/dropdownview.js +1 -1
  76. package/src/dropdown/utils.js +1 -1
  77. package/src/editableui/editableuiview.js +1 -1
  78. package/src/editableui/inline/inlineeditableuiview.js +1 -1
  79. package/src/editorui/bodycollection.js +1 -1
  80. package/src/editorui/boxed/boxededitoruiview.js +1 -1
  81. package/src/editorui/editoruiview.js +1 -1
  82. package/src/focuscycler.js +19 -4
  83. package/src/formheader/formheaderview.js +1 -1
  84. package/src/icon/iconview.js +1 -1
  85. package/src/iframe/iframeview.js +1 -1
  86. package/src/index.js +3 -1
  87. package/src/input/inputview.js +216 -0
  88. package/src/inputnumber/inputnumberview.js +71 -0
  89. package/src/inputtext/inputtextview.js +7 -181
  90. package/src/label/labelview.js +1 -1
  91. package/src/labeledfield/labeledfieldview.js +1 -1
  92. package/src/labeledfield/utils.js +54 -5
  93. package/src/labeledinput/labeledinputview.js +1 -1
  94. package/src/list/listitemview.js +1 -1
  95. package/src/list/listseparatorview.js +1 -1
  96. package/src/list/listview.js +1 -1
  97. package/src/model.js +1 -1
  98. package/src/notification/notification.js +1 -1
  99. package/src/panel/balloon/balloonpanelview.js +1 -1
  100. package/src/panel/balloon/contextualballoon.js +1 -1
  101. package/src/panel/sticky/stickypanelview.js +1 -1
  102. package/src/template.js +1 -1
  103. package/src/toolbar/balloon/balloontoolbar.js +1 -1
  104. package/src/toolbar/block/blockbuttonview.js +1 -1
  105. package/src/toolbar/block/blocktoolbar.js +1 -1
  106. package/src/toolbar/enabletoolbarkeyboardfocus.js +1 -1
  107. package/src/toolbar/normalizetoolbarconfig.js +1 -1
  108. package/src/toolbar/toolbarlinebreakview.js +1 -1
  109. package/src/toolbar/toolbarseparatorview.js +1 -1
  110. package/src/toolbar/toolbarview.js +3 -2
  111. package/src/tooltip/tooltipview.js +1 -1
  112. package/src/view.js +1 -1
  113. package/src/viewcollection.js +1 -1
  114. package/theme/components/button/button.css +1 -1
  115. package/theme/components/button/switchbutton.css +1 -1
  116. package/theme/components/colorgrid/colorgrid.css +1 -1
  117. package/theme/components/dropdown/dropdown.css +1 -1
  118. package/theme/components/dropdown/listdropdown.css +1 -1
  119. package/theme/components/dropdown/splitbutton.css +1 -1
  120. package/theme/components/dropdown/toolbardropdown.css +1 -1
  121. package/theme/components/editorui/editorui.css +1 -1
  122. package/theme/components/formheader/formheader.css +1 -1
  123. package/theme/components/icon/icon.css +1 -1
  124. package/theme/components/{inputtext/inputtext.css → input/input.css} +1 -1
  125. package/theme/components/label/label.css +1 -1
  126. package/theme/components/labeledfield/labeledfieldview.css +1 -1
  127. package/theme/components/labeledinput/labeledinput.css +1 -1
  128. package/theme/components/list/list.css +1 -1
  129. package/theme/components/panel/balloonpanel.css +1 -1
  130. package/theme/components/panel/balloonrotator.css +1 -1
  131. package/theme/components/panel/fakepanel.css +1 -1
  132. package/theme/components/panel/stickypanel.css +1 -1
  133. package/theme/components/responsive-form/responsiveform.css +1 -1
  134. package/theme/components/toolbar/blocktoolbar.css +1 -1
  135. package/theme/components/toolbar/toolbar.css +1 -1
  136. package/theme/components/tooltip/mixins/_tooltip.css +1 -1
  137. package/theme/components/tooltip/tooltip.css +1 -1
  138. package/theme/globals/_hidden.css +1 -1
  139. package/theme/globals/_reset.css +1 -1
  140. package/theme/globals/_transition.css +1 -1
  141. package/theme/globals/_zindex.css +1 -1
  142. package/theme/globals/globals.css +1 -1
  143. package/theme/mixins/_dir.css +1 -1
  144. package/theme/mixins/_rwd.css +1 -1
  145. package/theme/mixins/_unselectable.css +1 -1
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -7,201 +7,27 @@
7
7
  * @module ui/inputtext/inputtextview
8
8
  */
9
9
 
10
- import View from '../view';
11
- import FocusTracker from '@ckeditor/ckeditor5-utils/src/focustracker';
12
- import '../../theme/components/inputtext/inputtext.css';
10
+ import InputView from '../input/inputview';
13
11
 
14
12
  /**
15
13
  * The text input view class.
16
14
  *
17
- * @extends module:ui/view~View
15
+ * @extends module:ui/input/inputview~InputView
18
16
  */
19
- export default class InputTextView extends View {
17
+ export default class InputTextView extends InputView {
20
18
  /**
21
19
  * @inheritDoc
22
20
  */
23
21
  constructor( locale ) {
24
22
  super( locale );
25
23
 
26
- /**
27
- * The value of the input.
28
- *
29
- * @observable
30
- * @member {String} #value
31
- */
32
- this.set( 'value' );
33
-
34
- /**
35
- * The `id` attribute of the input (i.e. to pair with a `<label>` element).
36
- *
37
- * @observable
38
- * @member {String} #id
39
- */
40
- this.set( 'id' );
41
-
42
- /**
43
- * The `placeholder` attribute of the input.
44
- *
45
- * @observable
46
- * @member {String} #placeholder
47
- */
48
- this.set( 'placeholder' );
49
-
50
- /**
51
- * Controls whether the input view is in read-only mode.
52
- *
53
- * @observable
54
- * @member {Boolean} #isReadOnly
55
- */
56
- this.set( 'isReadOnly', false );
57
-
58
- /**
59
- * Set to `true` when the field has some error. Usually controlled via
60
- * {@link module:ui/labeledinput/labeledinputview~LabeledInputView#errorText}.
61
- *
62
- * @observable
63
- * @member {Boolean} #hasError
64
- */
65
- this.set( 'hasError', false );
66
-
67
- /**
68
- * The `id` of the element describing this field, e.g. when it has
69
- * some error, it helps screen readers read the error text.
70
- *
71
- * @observable
72
- * @member {Boolean} #ariaDescribedById
73
- */
74
- this.set( 'ariaDescribedById' );
75
-
76
- /**
77
- * Stores information about the editor UI focus and propagates it so various plugins and components
78
- * are unified as a focus group.
79
- *
80
- * @readonly
81
- * @member {module:utils/focustracker~FocusTracker} #focusTracker
82
- */
83
- this.focusTracker = new FocusTracker();
84
-
85
- /**
86
- * An observable flag set to `true` when the input is currently focused by the user.
87
- * Set to `false` otherwise.
88
- *
89
- * @readonly
90
- * @observable
91
- * @member {Boolean} #isFocused
92
- * @default false
93
- */
94
- this.bind( 'isFocused' ).to( this.focusTracker );
95
-
96
- /**
97
- * An observable flag set to `true` when the input contains no text, i.e.
98
- * when {@link #value} is `''`, `null`, or `false`.
99
- *
100
- * @readonly
101
- * @observable
102
- * @member {Boolean} #isEmpty
103
- * @default true
104
- */
105
- this.set( 'isEmpty', true );
106
-
107
- const bind = this.bindTemplate;
108
-
109
- this.setTemplate( {
110
- tag: 'input',
24
+ this.extendTemplate( {
111
25
  attributes: {
112
26
  type: 'text',
113
27
  class: [
114
- 'ck',
115
- 'ck-input',
116
- 'ck-input-text',
117
- bind.if( 'isFocused', 'ck-input_focused' ),
118
- bind.if( 'isEmpty', 'ck-input-text_empty' ),
119
- bind.if( 'hasError', 'ck-error' )
120
- ],
121
- id: bind.to( 'id' ),
122
- placeholder: bind.to( 'placeholder' ),
123
- readonly: bind.to( 'isReadOnly' ),
124
- 'aria-invalid': bind.if( 'hasError', true ),
125
- 'aria-describedby': bind.to( 'ariaDescribedById' )
126
- },
127
- on: {
128
- input: bind.to( ( ...args ) => {
129
- this.fire( 'input', ...args );
130
- this._updateIsEmpty();
131
- } ),
132
- change: bind.to( this._updateIsEmpty.bind( this ) )
28
+ 'ck-input-text'
29
+ ]
133
30
  }
134
31
  } );
135
-
136
- /**
137
- * Fired when the user types in the input. Corresponds to the native
138
- * DOM `input` event.
139
- *
140
- * @event input
141
- */
142
- }
143
-
144
- /**
145
- * @inheritDoc
146
- */
147
- render() {
148
- super.render();
149
-
150
- this.focusTracker.add( this.element );
151
-
152
- this._setDomElementValue( this.value );
153
- this._updateIsEmpty();
154
-
155
- // Bind `this.value` to the DOM element's value.
156
- // We cannot use `value` DOM attribute because removing it on Edge does not clear the DOM element's value property.
157
- this.on( 'change:value', ( evt, name, value ) => {
158
- this._setDomElementValue( value );
159
- this._updateIsEmpty();
160
- } );
161
- }
162
-
163
- /**
164
- * @inheritDoc
165
- */
166
- destroy() {
167
- super.destroy();
168
-
169
- this.focusTracker.destroy();
170
- }
171
-
172
- /**
173
- * Moves the focus to the input and selects the value.
174
- */
175
- select() {
176
- this.element.select();
177
- }
178
-
179
- /**
180
- * Focuses the input.
181
- */
182
- focus() {
183
- this.element.focus();
184
- }
185
-
186
- /**
187
- * Updates the {@link #isEmpty} property value on demand.
188
- *
189
- * @private
190
- */
191
- _updateIsEmpty() {
192
- this.isEmpty = isInputElementEmpty( this.element );
193
32
  }
194
-
195
- /**
196
- * Sets the `value` property of the {@link #element DOM element} on demand.
197
- *
198
- * @private
199
- */
200
- _setDomElementValue( value ) {
201
- this.element.value = ( !value && value !== 0 ) ? '' : value;
202
- }
203
- }
204
-
205
- function isInputElementEmpty( domElement ) {
206
- return !domElement.value;
207
33
  }
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -8,6 +8,7 @@
8
8
  */
9
9
 
10
10
  import InputTextView from '../inputtext/inputtextview';
11
+ import InputNumberView from '../inputnumber/inputnumberview';
11
12
  import { createDropdown } from '../dropdown/utils';
12
13
 
13
14
  /**
@@ -21,12 +22,12 @@ import { createDropdown } from '../dropdown/utils';
21
22
  * * It sets input's `id` and `ariaDescribedById` attributes.
22
23
  * * It binds input's `isReadOnly` to the labeled view.
23
24
  * * It binds input's `hasError` to the labeled view.
24
- * * It enables a logic that cleans up the error when user starts typing in the input..
25
+ * * It enables a logic that cleans up the error when user starts typing in the input.
25
26
  *
26
27
  * Usage:
27
28
  *
28
- * const labeledInputView = new LabeledFieldView( locale, createLabeledDropdown );
29
- * console.log( labeledInputView.view ); // An input instance.
29
+ * const labeledInputView = new LabeledFieldView( locale, createLabeledInputText );
30
+ * console.log( labeledInputView.fieldView ); // A text input instance.
30
31
  *
31
32
  * @param {module:ui/labeledfield/labeledfieldview~LabeledFieldView} labeledFieldView The instance of the labeled field view.
32
33
  * @param {String} viewUid An UID string that allows DOM logical connection between the
@@ -57,6 +58,54 @@ export function createLabeledInputText( labeledFieldView, viewUid, statusUid ) {
57
58
  return inputView;
58
59
  }
59
60
 
61
+ /**
62
+ * A helper for creating labeled number inputs.
63
+ *
64
+ * It creates an instance of a {@link module:ui/inputnumber/inputnumberview~InputNumberView input number} that is
65
+ * logically related to a {@link module:ui/labeledfield/labeledfieldview~LabeledFieldView labeled view} in DOM.
66
+ *
67
+ * The helper does the following:
68
+ *
69
+ * * It sets input's `id` and `ariaDescribedById` attributes.
70
+ * * It binds input's `isReadOnly` to the labeled view.
71
+ * * It binds input's `hasError` to the labeled view.
72
+ * * It enables a logic that cleans up the error when user starts typing in the input.
73
+ *
74
+ * Usage:
75
+ *
76
+ * const labeledInputView = new LabeledFieldView( locale, createLabeledInputNumber );
77
+ * console.log( labeledInputView.fieldView ); // A number input instance.
78
+ *
79
+ * @param {module:ui/labeledfield/labeledfieldview~LabeledFieldView} labeledFieldView The instance of the labeled field view.
80
+ * @param {String} viewUid An UID string that allows DOM logical connection between the
81
+ * {@link module:ui/labeledfield/labeledfieldview~LabeledFieldView#labelView labeled view's label} and the input.
82
+ * @param {String} statusUid An UID string that allows DOM logical connection between the
83
+ * {@link module:ui/labeledfield/labeledfieldview~LabeledFieldView#statusView labeled view's status} and the input.
84
+ * @returns {module:ui/inputnumber/inputnumberview~InputNumberView} The input number view instance.
85
+ */
86
+ export function createLabeledInputNumber( labeledFieldView, viewUid, statusUid ) {
87
+ const inputView = new InputNumberView( labeledFieldView.locale );
88
+
89
+ inputView.set( {
90
+ id: viewUid,
91
+ ariaDescribedById: statusUid,
92
+ inputMode: 'numeric'
93
+ } );
94
+
95
+ inputView.bind( 'isReadOnly' ).to( labeledFieldView, 'isEnabled', value => !value );
96
+ inputView.bind( 'hasError' ).to( labeledFieldView, 'errorText', value => !!value );
97
+
98
+ inputView.on( 'input', () => {
99
+ // UX: Make the error text disappear and disable the error indicator as the user
100
+ // starts fixing the errors.
101
+ labeledFieldView.errorText = null;
102
+ } );
103
+
104
+ labeledFieldView.bind( 'isEmpty', 'isFocused', 'placeholder' ).to( inputView );
105
+
106
+ return inputView;
107
+ }
108
+
60
109
  /**
61
110
  * A helper for creating labeled dropdowns.
62
111
  *
@@ -71,7 +120,7 @@ export function createLabeledInputText( labeledFieldView, viewUid, statusUid ) {
71
120
  * Usage:
72
121
  *
73
122
  * const labeledInputView = new LabeledFieldView( locale, createLabeledDropdown );
74
- * console.log( labeledInputView.view ); // A dropdown instance.
123
+ * console.log( labeledInputView.fieldView ); // A dropdown instance.
75
124
  *
76
125
  * @param {module:ui/labeledfield/labeledfieldview~LabeledFieldView} labeledFieldView The instance of the labeled field view.
77
126
  * @param {String} viewUid An UID string that allows DOM logical connection between the
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
package/src/model.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
package/src/template.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -16,6 +16,7 @@ import ToolbarLineBreakView from './toolbarlinebreakview';
16
16
  import ResizeObserver from '@ckeditor/ckeditor5-utils/src/dom/resizeobserver';
17
17
  import preventDefault from '../bindings/preventdefault.js';
18
18
  import Rect from '@ckeditor/ckeditor5-utils/src/dom/rect';
19
+ import isVisible from '@ckeditor/ckeditor5-utils/src/dom/isvisible';
19
20
  import global from '@ckeditor/ckeditor5-utils/src/dom/global';
20
21
  import { createDropdown, addToolbarToDropdown } from '../dropdown/utils';
21
22
  import { logWarning } from '@ckeditor/ckeditor5-utils/src/ckeditorerror';
@@ -758,7 +759,7 @@ class DynamicGrouping {
758
759
  // the toolbar is visible (the next ResizeObserver callback execution). This is handy because
759
760
  // the grouping could be caused by increasing the #maxWidth when the toolbar was invisible and the next
760
761
  // time it shows up, some items could actually be ungrouped (https://github.com/ckeditor/ckeditor5/issues/6575).
761
- if ( !this.viewElement.offsetParent ) {
762
+ if ( !isVisible( this.viewElement ) ) {
762
763
  this.shouldUpdateGroupingOnNextResize = true;
763
764
 
764
765
  return;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
package/src/view.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.
2
+ * Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
4
  */
5
5