@atlaskit/editor-plugin-placeholder-text 1.0.2 → 1.0.4
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/CHANGELOG.md +12 -0
- package/dist/cjs/fake-text-cursor/cursor.js +1 -1
- package/dist/cjs/ui/FloatingToolbar/index.js +41 -59
- package/dist/cjs/ui/PlaceholderFloatingToolbar/index.js +3 -3
- package/dist/es2019/ui/FloatingToolbar/index.js +36 -41
- package/dist/esm/fake-text-cursor/cursor.js +1 -1
- package/dist/esm/ui/FloatingToolbar/index.js +37 -60
- package/dist/esm/ui/PlaceholderFloatingToolbar/index.js +1 -1
- package/dist/types/ui/FloatingToolbar/index.d.ts +3 -4
- package/dist/types/ui/PlaceholderFloatingToolbar/index.d.ts +1 -0
- package/dist/types-ts4.5/ui/FloatingToolbar/index.d.ts +3 -4
- package/dist/types-ts4.5/ui/PlaceholderFloatingToolbar/index.d.ts +1 -0
- package/package.json +7 -9
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-placeholder-text
|
|
2
2
|
|
|
3
|
+
## 1.0.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#82109](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/82109) [`2ab37a71220d`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/2ab37a71220d) - Setup react 18 types for @atlaskit/editor-plugin-placeholder-text
|
|
8
|
+
|
|
9
|
+
## 1.0.3
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#80679](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/80679) [`104eb9443b7e`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/104eb9443b7e) - ED-22553 Updating adf-schema version to 35.6.0
|
|
14
|
+
|
|
3
15
|
## 1.0.2
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
|
@@ -15,7 +15,7 @@ var _model = require("@atlaskit/editor-prosemirror/model");
|
|
|
15
15
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
16
16
|
var _view = require("@atlaskit/editor-prosemirror/view");
|
|
17
17
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
18
|
-
function _isNativeReflectConstruct() {
|
|
18
|
+
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
19
19
|
var FakeTextCursorBookmark = exports.FakeTextCursorBookmark = /*#__PURE__*/function () {
|
|
20
20
|
function FakeTextCursorBookmark(pos) {
|
|
21
21
|
(0, _classCallCheck2.default)(this, FakeTextCursorBookmark);
|
|
@@ -4,7 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.default =
|
|
7
|
+
exports.default = FloatingToolbar;
|
|
8
8
|
Object.defineProperty(exports, "getNearestNonTextNode", {
|
|
9
9
|
enumerable: true,
|
|
10
10
|
get: function get() {
|
|
@@ -23,66 +23,48 @@ Object.defineProperty(exports, "handlePositionCalculatedWith", {
|
|
|
23
23
|
return _utils.handlePositionCalculatedWith;
|
|
24
24
|
}
|
|
25
25
|
});
|
|
26
|
-
var
|
|
27
|
-
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
28
|
-
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
29
|
-
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
|
|
30
|
-
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
31
|
-
var _react = require("react");
|
|
26
|
+
var _react = _interopRequireDefault(require("react"));
|
|
32
27
|
var _react2 = require("@emotion/react");
|
|
33
28
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
34
29
|
var _styles = require("./styles");
|
|
35
30
|
var _utils = require("./utils");
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
31
|
+
/* eslint-disable @atlaskit/design-system/prefer-primitives */
|
|
32
|
+
/** @jsx jsx */
|
|
33
|
+
|
|
34
|
+
function FloatingToolbar(_ref) {
|
|
35
|
+
var children = _ref.children,
|
|
36
|
+
target = _ref.target,
|
|
37
|
+
offset = _ref.offset,
|
|
38
|
+
fitWidth = _ref.fitWidth,
|
|
39
|
+
_ref$fitHeight = _ref.fitHeight,
|
|
40
|
+
fitHeight = _ref$fitHeight === void 0 ? 40 : _ref$fitHeight,
|
|
41
|
+
onPositionCalculated = _ref.onPositionCalculated,
|
|
42
|
+
popupsMountPoint = _ref.popupsMountPoint,
|
|
43
|
+
popupsBoundariesElement = _ref.popupsBoundariesElement,
|
|
44
|
+
className = _ref.className,
|
|
45
|
+
absoluteOffset = _ref.absoluteOffset,
|
|
46
|
+
alignX = _ref.alignX,
|
|
47
|
+
alignY = _ref.alignY,
|
|
48
|
+
zIndex = _ref.zIndex;
|
|
49
|
+
if (!target) {
|
|
50
|
+
return null;
|
|
45
51
|
}
|
|
46
|
-
(0,
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
return null;
|
|
66
|
-
}
|
|
67
|
-
return (0, _react2.jsx)(_ui.Popup, {
|
|
68
|
-
absoluteOffset: absoluteOffset,
|
|
69
|
-
alignX: alignX,
|
|
70
|
-
alignY: alignY,
|
|
71
|
-
target: target,
|
|
72
|
-
zIndex: zIndex,
|
|
73
|
-
mountTo: popupsMountPoint,
|
|
74
|
-
boundariesElement: popupsBoundariesElement,
|
|
75
|
-
offset: offset,
|
|
76
|
-
fitWidth: fitWidth,
|
|
77
|
-
fitHeight: fitHeight,
|
|
78
|
-
onPositionCalculated: onPositionCalculated
|
|
79
|
-
}, (0, _react2.jsx)("div", {
|
|
80
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
81
|
-
css: (0, _styles.container)(fitHeight),
|
|
82
|
-
"data-testid": "popup-container",
|
|
83
|
-
className: className
|
|
84
|
-
}, children));
|
|
85
|
-
}
|
|
86
|
-
}]);
|
|
87
|
-
return FloatingToolbar;
|
|
88
|
-
}(_react.PureComponent);
|
|
52
|
+
return (0, _react2.jsx)(_ui.Popup, {
|
|
53
|
+
absoluteOffset: absoluteOffset,
|
|
54
|
+
alignX: alignX,
|
|
55
|
+
alignY: alignY,
|
|
56
|
+
target: target,
|
|
57
|
+
zIndex: zIndex,
|
|
58
|
+
mountTo: popupsMountPoint,
|
|
59
|
+
boundariesElement: popupsBoundariesElement,
|
|
60
|
+
offset: offset,
|
|
61
|
+
fitWidth: fitWidth,
|
|
62
|
+
fitHeight: fitHeight,
|
|
63
|
+
onPositionCalculated: onPositionCalculated
|
|
64
|
+
}, (0, _react2.jsx)("div", {
|
|
65
|
+
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
66
|
+
css: (0, _styles.container)(fitHeight),
|
|
67
|
+
"data-testid": "popup-container",
|
|
68
|
+
className: className
|
|
69
|
+
}, children));
|
|
70
|
+
}
|
|
@@ -18,10 +18,10 @@ var _reactIntlNext = require("react-intl-next");
|
|
|
18
18
|
var _messages = require("@atlaskit/editor-common/messages");
|
|
19
19
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
20
20
|
var _FloatingToolbar = _interopRequireWildcard(require("../FloatingToolbar"));
|
|
21
|
-
function _getRequireWildcardCache(
|
|
22
|
-
function _interopRequireWildcard(
|
|
21
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
22
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
23
23
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
24
|
-
function _isNativeReflectConstruct() {
|
|
24
|
+
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
25
25
|
// eslint-disable-next-line @repo/internal/react/no-class-components
|
|
26
26
|
var PlaceholderFloatingToolbar = /*#__PURE__*/function (_React$Component) {
|
|
27
27
|
(0, _inherits2.default)(PlaceholderFloatingToolbar, _React$Component);
|
|
@@ -1,49 +1,44 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/design-system/prefer-primitives */
|
|
2
2
|
/** @jsx jsx */
|
|
3
|
-
import
|
|
3
|
+
import React from 'react';
|
|
4
4
|
import { jsx } from '@emotion/react';
|
|
5
5
|
import { Popup } from '@atlaskit/editor-common/ui';
|
|
6
6
|
import { container } from './styles';
|
|
7
7
|
export { handlePositionCalculatedWith, getOffsetParent, getNearestNonTextNode } from './utils';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
zIndex
|
|
26
|
-
} = this.props;
|
|
27
|
-
if (!target) {
|
|
28
|
-
return null;
|
|
29
|
-
}
|
|
30
|
-
return jsx(Popup, {
|
|
31
|
-
absoluteOffset: absoluteOffset,
|
|
32
|
-
alignX: alignX,
|
|
33
|
-
alignY: alignY,
|
|
34
|
-
target: target,
|
|
35
|
-
zIndex: zIndex,
|
|
36
|
-
mountTo: popupsMountPoint,
|
|
37
|
-
boundariesElement: popupsBoundariesElement,
|
|
38
|
-
offset: offset,
|
|
39
|
-
fitWidth: fitWidth,
|
|
40
|
-
fitHeight: fitHeight,
|
|
41
|
-
onPositionCalculated: onPositionCalculated
|
|
42
|
-
}, jsx("div", {
|
|
43
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
44
|
-
css: container(fitHeight),
|
|
45
|
-
"data-testid": "popup-container",
|
|
46
|
-
className: className
|
|
47
|
-
}, children));
|
|
8
|
+
export default function FloatingToolbar({
|
|
9
|
+
children,
|
|
10
|
+
target,
|
|
11
|
+
offset,
|
|
12
|
+
fitWidth,
|
|
13
|
+
fitHeight = 40,
|
|
14
|
+
onPositionCalculated,
|
|
15
|
+
popupsMountPoint,
|
|
16
|
+
popupsBoundariesElement,
|
|
17
|
+
className,
|
|
18
|
+
absoluteOffset,
|
|
19
|
+
alignX,
|
|
20
|
+
alignY,
|
|
21
|
+
zIndex
|
|
22
|
+
}) {
|
|
23
|
+
if (!target) {
|
|
24
|
+
return null;
|
|
48
25
|
}
|
|
26
|
+
return jsx(Popup, {
|
|
27
|
+
absoluteOffset: absoluteOffset,
|
|
28
|
+
alignX: alignX,
|
|
29
|
+
alignY: alignY,
|
|
30
|
+
target: target,
|
|
31
|
+
zIndex: zIndex,
|
|
32
|
+
mountTo: popupsMountPoint,
|
|
33
|
+
boundariesElement: popupsBoundariesElement,
|
|
34
|
+
offset: offset,
|
|
35
|
+
fitWidth: fitWidth,
|
|
36
|
+
fitHeight: fitHeight,
|
|
37
|
+
onPositionCalculated: onPositionCalculated
|
|
38
|
+
}, jsx("div", {
|
|
39
|
+
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
40
|
+
css: container(fitHeight),
|
|
41
|
+
"data-testid": "popup-container",
|
|
42
|
+
className: className
|
|
43
|
+
}, children));
|
|
49
44
|
}
|
|
@@ -5,7 +5,7 @@ import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
|
5
5
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
6
6
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
7
7
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
8
|
-
function _isNativeReflectConstruct() {
|
|
8
|
+
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
9
9
|
import { Slice } from '@atlaskit/editor-prosemirror/model';
|
|
10
10
|
import { Selection, TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
11
11
|
import { Decoration, DecorationSet } from '@atlaskit/editor-prosemirror/view';
|
|
@@ -1,67 +1,44 @@
|
|
|
1
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
4
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
5
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
6
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
7
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
8
1
|
/* eslint-disable @atlaskit/design-system/prefer-primitives */
|
|
9
2
|
/** @jsx jsx */
|
|
10
|
-
import
|
|
3
|
+
import React from 'react';
|
|
11
4
|
import { jsx } from '@emotion/react';
|
|
12
5
|
import { Popup } from '@atlaskit/editor-common/ui';
|
|
13
6
|
import { container } from './styles';
|
|
14
7
|
export { handlePositionCalculatedWith, getOffsetParent, getNearestNonTextNode } from './utils';
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
8
|
+
export default function FloatingToolbar(_ref) {
|
|
9
|
+
var children = _ref.children,
|
|
10
|
+
target = _ref.target,
|
|
11
|
+
offset = _ref.offset,
|
|
12
|
+
fitWidth = _ref.fitWidth,
|
|
13
|
+
_ref$fitHeight = _ref.fitHeight,
|
|
14
|
+
fitHeight = _ref$fitHeight === void 0 ? 40 : _ref$fitHeight,
|
|
15
|
+
onPositionCalculated = _ref.onPositionCalculated,
|
|
16
|
+
popupsMountPoint = _ref.popupsMountPoint,
|
|
17
|
+
popupsBoundariesElement = _ref.popupsBoundariesElement,
|
|
18
|
+
className = _ref.className,
|
|
19
|
+
absoluteOffset = _ref.absoluteOffset,
|
|
20
|
+
alignX = _ref.alignX,
|
|
21
|
+
alignY = _ref.alignY,
|
|
22
|
+
zIndex = _ref.zIndex;
|
|
23
|
+
if (!target) {
|
|
24
|
+
return null;
|
|
23
25
|
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
return null;
|
|
44
|
-
}
|
|
45
|
-
return jsx(Popup, {
|
|
46
|
-
absoluteOffset: absoluteOffset,
|
|
47
|
-
alignX: alignX,
|
|
48
|
-
alignY: alignY,
|
|
49
|
-
target: target,
|
|
50
|
-
zIndex: zIndex,
|
|
51
|
-
mountTo: popupsMountPoint,
|
|
52
|
-
boundariesElement: popupsBoundariesElement,
|
|
53
|
-
offset: offset,
|
|
54
|
-
fitWidth: fitWidth,
|
|
55
|
-
fitHeight: fitHeight,
|
|
56
|
-
onPositionCalculated: onPositionCalculated
|
|
57
|
-
}, jsx("div", {
|
|
58
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
59
|
-
css: container(fitHeight),
|
|
60
|
-
"data-testid": "popup-container",
|
|
61
|
-
className: className
|
|
62
|
-
}, children));
|
|
63
|
-
}
|
|
64
|
-
}]);
|
|
65
|
-
return FloatingToolbar;
|
|
66
|
-
}(PureComponent);
|
|
67
|
-
export { FloatingToolbar as default };
|
|
26
|
+
return jsx(Popup, {
|
|
27
|
+
absoluteOffset: absoluteOffset,
|
|
28
|
+
alignX: alignX,
|
|
29
|
+
alignY: alignY,
|
|
30
|
+
target: target,
|
|
31
|
+
zIndex: zIndex,
|
|
32
|
+
mountTo: popupsMountPoint,
|
|
33
|
+
boundariesElement: popupsBoundariesElement,
|
|
34
|
+
offset: offset,
|
|
35
|
+
fitWidth: fitWidth,
|
|
36
|
+
fitHeight: fitHeight,
|
|
37
|
+
onPositionCalculated: onPositionCalculated
|
|
38
|
+
}, jsx("div", {
|
|
39
|
+
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
40
|
+
css: container(fitHeight),
|
|
41
|
+
"data-testid": "popup-container",
|
|
42
|
+
className: className
|
|
43
|
+
}, children));
|
|
44
|
+
}
|
|
@@ -6,7 +6,7 @@ import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstruct
|
|
|
6
6
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
9
|
-
function _isNativeReflectConstruct() {
|
|
9
|
+
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
10
10
|
import React from 'react';
|
|
11
11
|
import { injectIntl } from 'react-intl-next';
|
|
12
12
|
import { placeholderTextMessages as messages } from '@atlaskit/editor-common/messages';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
-
import
|
|
2
|
+
import React from 'react';
|
|
3
3
|
import { jsx } from '@emotion/react';
|
|
4
4
|
export type Coordinates = {
|
|
5
5
|
left?: number;
|
|
@@ -9,6 +9,7 @@ export type Coordinates = {
|
|
|
9
9
|
};
|
|
10
10
|
export type PositionOffset = Coordinates;
|
|
11
11
|
export interface Props {
|
|
12
|
+
children?: React.ReactNode;
|
|
12
13
|
zIndex?: number;
|
|
13
14
|
className?: string;
|
|
14
15
|
target?: HTMLElement;
|
|
@@ -23,6 +24,4 @@ export interface Props {
|
|
|
23
24
|
onPositionCalculated?: (position: Coordinates) => Coordinates;
|
|
24
25
|
}
|
|
25
26
|
export { handlePositionCalculatedWith, getOffsetParent, getNearestNonTextNode, } from './utils';
|
|
26
|
-
export default
|
|
27
|
-
render(): jsx.JSX.Element | null;
|
|
28
|
-
}
|
|
27
|
+
export default function FloatingToolbar({ children, target, offset, fitWidth, fitHeight, onPositionCalculated, popupsMountPoint, popupsBoundariesElement, className, absoluteOffset, alignX, alignY, zIndex, }: Props): jsx.JSX.Element | null;
|
|
@@ -11,6 +11,7 @@ export interface Props {
|
|
|
11
11
|
editorViewDOM: HTMLElement;
|
|
12
12
|
popupsMountPoint?: HTMLElement;
|
|
13
13
|
popupsBoundariesElement?: HTMLElement;
|
|
14
|
+
children?: React.ReactNode;
|
|
14
15
|
}
|
|
15
16
|
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps<"intl">>> & {
|
|
16
17
|
WrappedComponent: React.ComponentType<Props & WrappedComponentProps<"intl">>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
-
import
|
|
2
|
+
import React from 'react';
|
|
3
3
|
import { jsx } from '@emotion/react';
|
|
4
4
|
export type Coordinates = {
|
|
5
5
|
left?: number;
|
|
@@ -9,6 +9,7 @@ export type Coordinates = {
|
|
|
9
9
|
};
|
|
10
10
|
export type PositionOffset = Coordinates;
|
|
11
11
|
export interface Props {
|
|
12
|
+
children?: React.ReactNode;
|
|
12
13
|
zIndex?: number;
|
|
13
14
|
className?: string;
|
|
14
15
|
target?: HTMLElement;
|
|
@@ -23,6 +24,4 @@ export interface Props {
|
|
|
23
24
|
onPositionCalculated?: (position: Coordinates) => Coordinates;
|
|
24
25
|
}
|
|
25
26
|
export { handlePositionCalculatedWith, getOffsetParent, getNearestNonTextNode, } from './utils';
|
|
26
|
-
export default
|
|
27
|
-
render(): jsx.JSX.Element | null;
|
|
28
|
-
}
|
|
27
|
+
export default function FloatingToolbar({ children, target, offset, fitWidth, fitHeight, onPositionCalculated, popupsMountPoint, popupsBoundariesElement, className, absoluteOffset, alignX, alignY, zIndex, }: Props): jsx.JSX.Element | null;
|
|
@@ -11,6 +11,7 @@ export interface Props {
|
|
|
11
11
|
editorViewDOM: HTMLElement;
|
|
12
12
|
popupsMountPoint?: HTMLElement;
|
|
13
13
|
popupsBoundariesElement?: HTMLElement;
|
|
14
|
+
children?: React.ReactNode;
|
|
14
15
|
}
|
|
15
16
|
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps<"intl">>> & {
|
|
16
17
|
WrappedComponent: React.ComponentType<Props & WrappedComponentProps<"intl">>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-placeholder-text",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "placeholder text plugin for @atlaskit/editor-core",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -28,15 +28,15 @@
|
|
|
28
28
|
}
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@atlaskit/adf-schema": "^35.
|
|
32
|
-
"@atlaskit/editor-common": "^78.
|
|
31
|
+
"@atlaskit/adf-schema": "^35.6.0",
|
|
32
|
+
"@atlaskit/editor-common": "^78.14.0",
|
|
33
33
|
"@atlaskit/editor-plugin-analytics": "^1.0.0",
|
|
34
34
|
"@atlaskit/editor-plugin-type-ahead": "^1.0.0",
|
|
35
35
|
"@atlaskit/editor-prosemirror": "3.0.0",
|
|
36
36
|
"@atlaskit/editor-shared-styles": "^2.9.0",
|
|
37
37
|
"@atlaskit/icon": "^22.1.0",
|
|
38
38
|
"@atlaskit/theme": "^12.6.0",
|
|
39
|
-
"@atlaskit/tokens": "^1.
|
|
39
|
+
"@atlaskit/tokens": "^1.41.0",
|
|
40
40
|
"@babel/runtime": "^7.0.0",
|
|
41
41
|
"@emotion/react": "^11.7.1"
|
|
42
42
|
},
|
|
@@ -79,11 +79,9 @@
|
|
|
79
79
|
"ui-components": [
|
|
80
80
|
"lite-mode"
|
|
81
81
|
],
|
|
82
|
-
"deprecation":
|
|
83
|
-
"no-deprecated-imports"
|
|
84
|
-
],
|
|
82
|
+
"deprecation": "no-deprecated-imports",
|
|
85
83
|
"styling": [
|
|
86
|
-
"
|
|
84
|
+
"emotion",
|
|
87
85
|
"emotion"
|
|
88
86
|
],
|
|
89
87
|
"imports": [
|
|
@@ -104,4 +102,4 @@
|
|
|
104
102
|
"./styles": "./src/styles.ts"
|
|
105
103
|
},
|
|
106
104
|
"prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.0"
|
|
107
|
-
}
|
|
105
|
+
}
|