@ckeditor/ckeditor5-widget 0.0.0-nightly-20250610.0 → 0.0.0-nightly-20250611.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.
Potentially problematic release.
This version of @ckeditor/ckeditor5-widget might be problematic. Click here for more details.
- package/dist/index.js +11 -1
- package/dist/index.js.map +1 -1
- package/package.json +8 -8
- package/src/index.d.ts +2 -0
- package/src/index.js +2 -0
- package/src/widgetresize/sizeview.d.ts +2 -0
- package/src/widgetresize/sizeview.js +2 -0
- package/src/widgettypearound/utils.d.ts +8 -0
- package/src/widgettypearound/utils.js +8 -0
package/dist/index.js
CHANGED
@@ -504,6 +504,8 @@ import { throttle } from 'es-toolkit/compat';
|
|
504
504
|
/**
|
505
505
|
* The name of the type around model selection attribute responsible for
|
506
506
|
* displaying a fake caret next to a selected widget.
|
507
|
+
*
|
508
|
+
* @internal
|
507
509
|
*/ const TYPE_AROUND_SELECTION_ATTRIBUTE = 'widget-type-around';
|
508
510
|
/**
|
509
511
|
* Checks if an element is a widget that qualifies to get the widget type around UI.
|
@@ -512,6 +514,8 @@ import { throttle } from 'es-toolkit/compat';
|
|
512
514
|
}
|
513
515
|
/**
|
514
516
|
* For the passed HTML element, this helper finds the closest widget type around button ancestor.
|
517
|
+
*
|
518
|
+
* @internal
|
515
519
|
*/ function getClosestTypeAroundDomButton(domElement) {
|
516
520
|
return domElement.closest('.ck-widget__type-around__button');
|
517
521
|
}
|
@@ -520,12 +524,15 @@ import { throttle } from 'es-toolkit/compat';
|
|
520
524
|
* the paragraph would be inserted into the content if, for instance, the button was
|
521
525
|
* clicked by the user.
|
522
526
|
*
|
527
|
+
* @internal
|
523
528
|
* @returns The position of the button.
|
524
529
|
*/ function getTypeAroundButtonPosition(domElement) {
|
525
530
|
return domElement.classList.contains('ck-widget__type-around__button_before') ? 'before' : 'after';
|
526
531
|
}
|
527
532
|
/**
|
528
533
|
* For the passed HTML element, this helper returns the closest view widget ancestor.
|
534
|
+
*
|
535
|
+
* @internal
|
529
536
|
*/ function getClosestWidgetViewElement(domElement, domConverter) {
|
530
537
|
const widgetDomElement = domElement.closest('.ck-widget');
|
531
538
|
return domConverter.mapDomToView(widgetDomElement);
|
@@ -535,6 +542,7 @@ import { throttle } from 'es-toolkit/compat';
|
|
535
542
|
*
|
536
543
|
* **Note**: If the fake caret is not currently displayed, `null` is returned.
|
537
544
|
*
|
545
|
+
* @internal
|
538
546
|
* @returns The position of the fake caret or `null` when none is present.
|
539
547
|
*/ function getTypeAroundFakeCaretPosition(selection) {
|
540
548
|
return selection.getAttribute(TYPE_AROUND_SELECTION_ATTRIBUTE);
|
@@ -2470,6 +2478,8 @@ function isWidgetSelected(selection) {
|
|
2470
2478
|
|
2471
2479
|
/**
|
2472
2480
|
* A view displaying the proposed new element size during the resizing.
|
2481
|
+
*
|
2482
|
+
* @internal
|
2473
2483
|
*/ class SizeView extends View {
|
2474
2484
|
constructor(){
|
2475
2485
|
super();
|
@@ -3052,5 +3062,5 @@ function existsInDom(element) {
|
|
3052
3062
|
}
|
3053
3063
|
}
|
3054
3064
|
|
3055
|
-
export { WIDGET_CLASS_NAME, WIDGET_SELECTED_CLASS_NAME, Widget, WidgetResize, WidgetToolbarRepository, WidgetTypeAround, calculateResizeHostAncestorWidth, calculateResizeHostPercentageWidth, findOptimalInsertionRange, getLabel, isWidget, setHighlightHandling, setLabel, toWidget, toWidgetEditable, viewToModelPositionOutsideModelElement };
|
3065
|
+
export { WIDGET_CLASS_NAME, WIDGET_SELECTED_CLASS_NAME, Widget, WidgetResize, WidgetToolbarRepository, WidgetTypeAround, TYPE_AROUND_SELECTION_ATTRIBUTE as _WIDGET_TYPE_AROUND_SELECTION_ATTRIBUTE, SizeView as _WidgetSizeView, getClosestTypeAroundDomButton as _getClosestWidgetTypeAroundDomButton, getClosestWidgetViewElement as _getClosestWidgetViewElement, getTypeAroundButtonPosition as _getWidgetTypeAroundButtonPosition, getTypeAroundFakeCaretPosition as _getWidgetTypeAroundFakeCaretPosition, calculateResizeHostAncestorWidth, calculateResizeHostPercentageWidth, findOptimalInsertionRange, getLabel, isWidget, setHighlightHandling, setLabel, toWidget, toWidgetEditable, viewToModelPositionOutsideModelElement };
|
3056
3066
|
//# sourceMappingURL=index.js.map
|