@atlaskit/prosemirror-input-rules 2.4.3 → 2.4.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 +24 -18
- package/afm-cc/tsconfig.json +25 -0
- package/dist/cjs/constants.js +3 -6
- package/dist/cjs/handler.js +1 -2
- package/dist/cjs/utils.js +4 -5
- package/dist/esm/utils.js +2 -2
- package/package.json +3 -3
- package/tmp/api-report-tmp.d.ts +0 -63
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @atlaskit/prosemirror-input-rules
|
|
2
2
|
|
|
3
|
+
## 2.4.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
3
9
|
## 2.4.3
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -22,7 +28,7 @@
|
|
|
22
28
|
|
|
23
29
|
### Minor Changes
|
|
24
30
|
|
|
25
|
-
- [`1944b35b538`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1944b35b538) - move common utilities to editor-common, to help with decoupling block-type plugin
|
|
31
|
+
- [#37964](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/37964) [`1944b35b538`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1944b35b538) - move common utilities to editor-common, to help with decoupling block-type plugin
|
|
26
32
|
|
|
27
33
|
### Patch Changes
|
|
28
34
|
|
|
@@ -32,20 +38,20 @@
|
|
|
32
38
|
|
|
33
39
|
### Patch Changes
|
|
34
40
|
|
|
35
|
-
- [`d2ecb6bf1a3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d2ecb6bf1a3) - [ED-19203] Moved input rule types to editor-common to avoid circular dependencies
|
|
41
|
+
- [#37821](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/37821) [`d2ecb6bf1a3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d2ecb6bf1a3) - [ED-19203] Moved input rule types to editor-common to avoid circular dependencies
|
|
36
42
|
- Updated dependencies
|
|
37
43
|
|
|
38
44
|
## 2.3.1
|
|
39
45
|
|
|
40
46
|
### Patch Changes
|
|
41
47
|
|
|
42
|
-
- [`4e6f1bf8511`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4e6f1bf8511) - [ED-19233] Import prosemirror libraries from internal facade package
|
|
48
|
+
- [#37785](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/37785) [`4e6f1bf8511`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4e6f1bf8511) - [ED-19233] Import prosemirror libraries from internal facade package
|
|
43
49
|
|
|
44
50
|
## 2.3.0
|
|
45
51
|
|
|
46
52
|
### Minor Changes
|
|
47
53
|
|
|
48
|
-
- [`8b891bf3590`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8b891bf3590) - This change introduces `editor-plugin-hyperlink` which separates the hyperlink plugin from `editor-core`. In order to enable this change there are now new entry points on `editor-common` (such as `/link`, `/quick-insert`) in order to separate common code. Further `prosemirror-input-rules` now has new exports of `createPlugin` and `createRule` which are used in many plugins in `editor-core`.
|
|
54
|
+
- [#36631](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/36631) [`8b891bf3590`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8b891bf3590) - This change introduces `editor-plugin-hyperlink` which separates the hyperlink plugin from `editor-core`. In order to enable this change there are now new entry points on `editor-common` (such as `/link`, `/quick-insert`) in order to separate common code. Further `prosemirror-input-rules` now has new exports of `createPlugin` and `createRule` which are used in many plugins in `editor-core`.
|
|
49
55
|
|
|
50
56
|
### Patch Changes
|
|
51
57
|
|
|
@@ -55,39 +61,39 @@
|
|
|
55
61
|
|
|
56
62
|
### Patch Changes
|
|
57
63
|
|
|
58
|
-
- [`5f5ba16de66`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5f5ba16de66) - [ED-13910] Fix prosemirror types
|
|
64
|
+
- [#36241](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/36241) [`5f5ba16de66`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5f5ba16de66) - [ED-13910] Fix prosemirror types
|
|
59
65
|
|
|
60
66
|
## 2.2.4
|
|
61
67
|
|
|
62
68
|
### Patch Changes
|
|
63
69
|
|
|
64
|
-
- [`73b5128036b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/73b5128036b) - [ED-17082] Mark package as a singleton one
|
|
70
|
+
- [#35782](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/35782) [`73b5128036b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/73b5128036b) - [ED-17082] Mark package as a singleton one
|
|
65
71
|
- Updated dependencies
|
|
66
72
|
|
|
67
73
|
## 2.2.3
|
|
68
74
|
|
|
69
75
|
### Patch Changes
|
|
70
76
|
|
|
71
|
-
- [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
|
|
77
|
+
- [#33793](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33793) [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
|
|
72
78
|
|
|
73
79
|
## 2.2.2
|
|
74
80
|
|
|
75
81
|
### Patch Changes
|
|
76
82
|
|
|
77
|
-
- [`a142ba1aa28`](https://bitbucket.org/atlassian/atlassian-frontend/commits/a142ba1aa28) - [ED17172] Bump prosemirror-model to 1.16.0 and prosemirror-view to 1.23.7 and removed work-arounds for fixed issues
|
|
83
|
+
- [#33771](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33771) [`a142ba1aa28`](https://bitbucket.org/atlassian/atlassian-frontend/commits/a142ba1aa28) - [ED17172] Bump prosemirror-model to 1.16.0 and prosemirror-view to 1.23.7 and removed work-arounds for fixed issues
|
|
78
84
|
- Updated dependencies
|
|
79
85
|
|
|
80
86
|
## 2.2.1
|
|
81
87
|
|
|
82
88
|
### Patch Changes
|
|
83
89
|
|
|
84
|
-
- [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
|
|
90
|
+
- [#33649](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33649) [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
|
|
85
91
|
|
|
86
92
|
## 2.2.0
|
|
87
93
|
|
|
88
94
|
### Minor Changes
|
|
89
95
|
|
|
90
|
-
- [`56507598609`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56507598609) - Skip minor dependency bump
|
|
96
|
+
- [#33258](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33258) [`56507598609`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56507598609) - Skip minor dependency bump
|
|
91
97
|
|
|
92
98
|
### Patch Changes
|
|
93
99
|
|
|
@@ -97,14 +103,14 @@
|
|
|
97
103
|
|
|
98
104
|
### Patch Changes
|
|
99
105
|
|
|
100
|
-
- [`0ffb55018c9`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0ffb55018c9) - Revert "[ED-17172] Bumped prosemirror-view from 1.23.2 to 1.23.7 and removed work-around for fixed issues"
|
|
106
|
+
- [#33004](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33004) [`0ffb55018c9`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0ffb55018c9) - Revert "[ED-17172] Bumped prosemirror-view from 1.23.2 to 1.23.7 and removed work-around for fixed issues"
|
|
101
107
|
- Updated dependencies
|
|
102
108
|
|
|
103
109
|
## 2.1.11
|
|
104
110
|
|
|
105
111
|
### Patch Changes
|
|
106
112
|
|
|
107
|
-
- [`2e01c9c74b5`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2e01c9c74b5) - DUMMY remove before merging to master; dupe adf-schema via adf-utils
|
|
113
|
+
- [#32424](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/32424) [`2e01c9c74b5`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2e01c9c74b5) - DUMMY remove before merging to master; dupe adf-schema via adf-utils
|
|
108
114
|
- Updated dependencies
|
|
109
115
|
|
|
110
116
|
## 2.1.10
|
|
@@ -117,7 +123,7 @@
|
|
|
117
123
|
|
|
118
124
|
### Patch Changes
|
|
119
125
|
|
|
120
|
-
- [`0606572f9b8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0606572f9b8) - [ux] ED-15348 docs(changeset): ED-15348 Fix a bug preventing typeahead actions to be fired from a gap cursor. Typing a typeahead trigger key (/, : or @) should pop-up a typeahead menu. However, if the current selection is inside a gap cursor, the trigger character is inserted and the pop-up menu doesn't open. This changeset fixes that.
|
|
126
|
+
- [#26712](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/26712) [`0606572f9b8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0606572f9b8) - [ux] ED-15348 docs(changeset): ED-15348 Fix a bug preventing typeahead actions to be fired from a gap cursor. Typing a typeahead trigger key (/, : or @) should pop-up a typeahead menu. However, if the current selection is inside a gap cursor, the trigger character is inserted and the pop-up menu doesn't open. This changeset fixes that.
|
|
121
127
|
- Updated dependencies
|
|
122
128
|
|
|
123
129
|
## 2.1.8
|
|
@@ -160,7 +166,7 @@
|
|
|
160
166
|
|
|
161
167
|
### Patch Changes
|
|
162
168
|
|
|
163
|
-
- [`4e6fbaf5898`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4e6fbaf5898) - ED-14117 Change EditorState.apply type to receive readonly transaction
|
|
169
|
+
- [#18526](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/18526) [`4e6fbaf5898`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4e6fbaf5898) - ED-14117 Change EditorState.apply type to receive readonly transaction
|
|
164
170
|
|
|
165
171
|
Transactions should not be mutated after being dispatched as it can lead to
|
|
166
172
|
unexpected behaviour. This change patches the relevant types declared in
|
|
@@ -172,13 +178,13 @@
|
|
|
172
178
|
|
|
173
179
|
### Patch Changes
|
|
174
180
|
|
|
175
|
-
- [`19d72473dfb`](https://bitbucket.org/atlassian/atlassian-frontend/commits/19d72473dfb) - ED-13025 Bump prosemirror-view 1.23.1 -> 1.23.2
|
|
181
|
+
- [#16752](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/16752) [`19d72473dfb`](https://bitbucket.org/atlassian/atlassian-frontend/commits/19d72473dfb) - ED-13025 Bump prosemirror-view 1.23.1 -> 1.23.2
|
|
176
182
|
|
|
177
183
|
## 2.1.0
|
|
178
184
|
|
|
179
185
|
### Minor Changes
|
|
180
186
|
|
|
181
|
-
- [`b230f366971`](https://bitbucket.org/atlassian/atlassian-frontend/commits/b230f366971) - [ED-14008] Bump prosemirror-view from 1.20.2 to 1.23.1
|
|
187
|
+
- [#15998](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/15998) [`b230f366971`](https://bitbucket.org/atlassian/atlassian-frontend/commits/b230f366971) - [ED-14008] Bump prosemirror-view from 1.20.2 to 1.23.1
|
|
182
188
|
|
|
183
189
|
### Patch Changes
|
|
184
190
|
|
|
@@ -194,13 +200,13 @@
|
|
|
194
200
|
|
|
195
201
|
### Patch Changes
|
|
196
202
|
|
|
197
|
-
- [`312a2810b0b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/312a2810b0b) - [ux] ED-12931 Fix input rules replacing text outside of matched word in a long paragraph
|
|
203
|
+
- [#10943](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/10943) [`312a2810b0b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/312a2810b0b) - [ux] ED-12931 Fix input rules replacing text outside of matched word in a long paragraph
|
|
198
204
|
|
|
199
205
|
## 2.0.0
|
|
200
206
|
|
|
201
207
|
### Major Changes
|
|
202
208
|
|
|
203
|
-
- [`d989a24dd88`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d989a24dd88) - [ED-11915] New package to manage auto formatting rules without a undoInputRules
|
|
209
|
+
- [#10230](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/10230) [`d989a24dd88`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d989a24dd88) - [ED-11915] New package to manage auto formatting rules without a undoInputRules
|
|
204
210
|
|
|
205
211
|
### Minor Changes
|
|
206
212
|
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"extends": "../../../../tsconfig.entry-points.confluence.json",
|
|
3
|
+
"compilerOptions": {
|
|
4
|
+
"declaration": true,
|
|
5
|
+
"target": "es5",
|
|
6
|
+
"composite": true,
|
|
7
|
+
"outDir": "../dist",
|
|
8
|
+
"rootDir": "../",
|
|
9
|
+
"baseUrl": "../"
|
|
10
|
+
},
|
|
11
|
+
"include": [
|
|
12
|
+
"../src/**/*.ts",
|
|
13
|
+
"../src/**/*.tsx"
|
|
14
|
+
],
|
|
15
|
+
"exclude": [
|
|
16
|
+
"../src/**/__tests__/*",
|
|
17
|
+
"../src/**/*.test.*",
|
|
18
|
+
"../src/**/test.*"
|
|
19
|
+
],
|
|
20
|
+
"references": [
|
|
21
|
+
{
|
|
22
|
+
"path": "../../editor-common/afm-cc/tsconfig.json"
|
|
23
|
+
}
|
|
24
|
+
]
|
|
25
|
+
}
|
package/dist/cjs/constants.js
CHANGED
|
@@ -8,9 +8,6 @@ exports.leafNodeReplacementCharacter = exports.TEXT_INPUT_RULE_TRANSACTION_KEY =
|
|
|
8
8
|
// leaf nodes, i.e. nodes that don't have any content or text property (e.g. hardBreak, emoji, mention, rule)
|
|
9
9
|
// It was introduced because of https://github.com/ProseMirror/prosemirror/issues/262
|
|
10
10
|
// This can be used in an input rule regex to be able to include or exclude such nodes.
|
|
11
|
-
var leafNodeReplacementCharacter = "\uFFFC";
|
|
12
|
-
exports.
|
|
13
|
-
var
|
|
14
|
-
exports.TEXT_INPUT_RULE_TRANSACTION_KEY = TEXT_INPUT_RULE_TRANSACTION_KEY;
|
|
15
|
-
var MAX_REGEX_MATCH = 500;
|
|
16
|
-
exports.MAX_REGEX_MATCH = MAX_REGEX_MATCH;
|
|
11
|
+
var leafNodeReplacementCharacter = exports.leafNodeReplacementCharacter = "\uFFFC";
|
|
12
|
+
var TEXT_INPUT_RULE_TRANSACTION_KEY = exports.TEXT_INPUT_RULE_TRANSACTION_KEY = 'input_rule_plugin_transaction';
|
|
13
|
+
var MAX_REGEX_MATCH = exports.MAX_REGEX_MATCH = 500;
|
package/dist/cjs/handler.js
CHANGED
|
@@ -10,7 +10,7 @@ var _selection = require("@atlaskit/editor-common/selection");
|
|
|
10
10
|
var _constants = require("./constants");
|
|
11
11
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
12
12
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
13
|
-
var createInputEventHandler = function createInputEventHandler(_ref) {
|
|
13
|
+
var createInputEventHandler = exports.createInputEventHandler = function createInputEventHandler(_ref) {
|
|
14
14
|
var rules = _ref.rules,
|
|
15
15
|
pluginKey = _ref.pluginKey,
|
|
16
16
|
allowInsertTextOnDocument = _ref.allowInsertTextOnDocument,
|
|
@@ -62,7 +62,6 @@ var createInputEventHandler = function createInputEventHandler(_ref) {
|
|
|
62
62
|
return true;
|
|
63
63
|
};
|
|
64
64
|
};
|
|
65
|
-
exports.createInputEventHandler = createInputEventHandler;
|
|
66
65
|
function findMatchOnRules(_ref3) {
|
|
67
66
|
var rules = _ref3.rules,
|
|
68
67
|
textBefore = _ref3.textBefore,
|
package/dist/cjs/utils.js
CHANGED
|
@@ -25,7 +25,7 @@ var hasUnsupportedMarks = function hasUnsupportedMarks(state, start, end, marksN
|
|
|
25
25
|
return (marksInSelection || []).some(isUnsupportedMark);
|
|
26
26
|
};
|
|
27
27
|
var isCursorInsideUnsupportedMarks = function isCursorInsideUnsupportedMarks(state, marksNameUnsupported) {
|
|
28
|
-
var _$cursor$nodeBefore
|
|
28
|
+
var _$cursor$nodeBefore;
|
|
29
29
|
var selection = state.selection;
|
|
30
30
|
if (!(selection instanceof _state.TextSelection)) {
|
|
31
31
|
return false;
|
|
@@ -34,9 +34,9 @@ var isCursorInsideUnsupportedMarks = function isCursorInsideUnsupportedMarks(sta
|
|
|
34
34
|
var isUnsupportedMark = function isUnsupportedMark(node) {
|
|
35
35
|
return marksNameUnsupported.includes(node.type.name);
|
|
36
36
|
};
|
|
37
|
-
return Boolean($cursor === null || $cursor === void 0
|
|
37
|
+
return Boolean($cursor === null || $cursor === void 0 || (_$cursor$nodeBefore = $cursor.nodeBefore) === null || _$cursor$nodeBefore === void 0 || (_$cursor$nodeBefore = _$cursor$nodeBefore.marks) === null || _$cursor$nodeBefore === void 0 ? void 0 : _$cursor$nodeBefore.some(isUnsupportedMark));
|
|
38
38
|
};
|
|
39
|
-
var createPlugin = function createPlugin(pluginName, rules) {
|
|
39
|
+
var createPlugin = exports.createPlugin = function createPlugin(pluginName, rules) {
|
|
40
40
|
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
41
41
|
var _options$isBlockNodeR = options.isBlockNodeRule,
|
|
42
42
|
isBlockNodeRule = _options$isBlockNodeR === void 0 ? false : _options$isBlockNodeR,
|
|
@@ -60,5 +60,4 @@ var createPlugin = function createPlugin(pluginName, rules) {
|
|
|
60
60
|
(0, _history.closeHistory)(tr);
|
|
61
61
|
}
|
|
62
62
|
});
|
|
63
|
-
};
|
|
64
|
-
exports.createPlugin = createPlugin;
|
|
63
|
+
};
|
package/dist/esm/utils.js
CHANGED
|
@@ -13,7 +13,7 @@ var hasUnsupportedMarks = function hasUnsupportedMarks(state, start, end, marksN
|
|
|
13
13
|
return (marksInSelection || []).some(isUnsupportedMark);
|
|
14
14
|
};
|
|
15
15
|
var isCursorInsideUnsupportedMarks = function isCursorInsideUnsupportedMarks(state, marksNameUnsupported) {
|
|
16
|
-
var _$cursor$nodeBefore
|
|
16
|
+
var _$cursor$nodeBefore;
|
|
17
17
|
var selection = state.selection;
|
|
18
18
|
if (!(selection instanceof TextSelection)) {
|
|
19
19
|
return false;
|
|
@@ -22,7 +22,7 @@ var isCursorInsideUnsupportedMarks = function isCursorInsideUnsupportedMarks(sta
|
|
|
22
22
|
var isUnsupportedMark = function isUnsupportedMark(node) {
|
|
23
23
|
return marksNameUnsupported.includes(node.type.name);
|
|
24
24
|
};
|
|
25
|
-
return Boolean($cursor === null || $cursor === void 0
|
|
25
|
+
return Boolean($cursor === null || $cursor === void 0 || (_$cursor$nodeBefore = $cursor.nodeBefore) === null || _$cursor$nodeBefore === void 0 || (_$cursor$nodeBefore = _$cursor$nodeBefore.marks) === null || _$cursor$nodeBefore === void 0 ? void 0 : _$cursor$nodeBefore.some(isUnsupportedMark));
|
|
26
26
|
};
|
|
27
27
|
export var createPlugin = function createPlugin(pluginName, rules) {
|
|
28
28
|
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/prosemirror-input-rules",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.4",
|
|
4
4
|
"description": "A package that contains helpers to create autoformatting rules for ProseMirror",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
7
7
|
},
|
|
8
|
-
"repository": "https://bitbucket.org/atlassian/atlassian-frontend",
|
|
8
|
+
"repository": "https://bitbucket.org/atlassian/atlassian-frontend-mirror",
|
|
9
9
|
"author": "Atlassian Pty Ltd",
|
|
10
10
|
"license": "Apache-2.0",
|
|
11
11
|
"main": "dist/cjs/index.js",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"releaseModel": "continuous"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@atlaskit/editor-common": "^
|
|
31
|
+
"@atlaskit/editor-common": "^77.0.0",
|
|
32
32
|
"@atlaskit/editor-prosemirror": "1.1.0",
|
|
33
33
|
"@babel/runtime": "^7.0.0"
|
|
34
34
|
},
|
package/tmp/api-report-tmp.d.ts
DELETED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
## API Report File for "@atlaskit/prosemirror-input-rules"
|
|
2
|
-
|
|
3
|
-
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
|
|
4
|
-
|
|
5
|
-
```ts
|
|
6
|
-
|
|
7
|
-
import { createRule } from '@atlaskit/editor-common/utils';
|
|
8
|
-
import type { EditorState } from '@atlaskit/editor-prosemirror/state';
|
|
9
|
-
import type { InputRuleHandler } from '@atlaskit/editor-common/types';
|
|
10
|
-
import type { InputRuleWrapper } from '@atlaskit/editor-common/types';
|
|
11
|
-
import type { OnHandlerApply } from '@atlaskit/editor-common/types';
|
|
12
|
-
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
13
|
-
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
14
|
-
|
|
15
|
-
// @public (undocumented)
|
|
16
|
-
export function createInputRulePlugin(pluginName: string, rules: InputRuleWrapper[], options?: Options): SafePlugin;
|
|
17
|
-
|
|
18
|
-
// @public (undocumented)
|
|
19
|
-
export const createPlugin: (pluginName: string, rules: Array<InputRuleWrapper>, options?: Options_2) => SafePlugin;
|
|
20
|
-
|
|
21
|
-
export { createRule }
|
|
22
|
-
|
|
23
|
-
export { InputRuleHandler }
|
|
24
|
-
|
|
25
|
-
export { InputRuleWrapper }
|
|
26
|
-
|
|
27
|
-
// @public (undocumented)
|
|
28
|
-
export const leafNodeReplacementCharacter = "\uFFFC";
|
|
29
|
-
|
|
30
|
-
// @public (undocumented)
|
|
31
|
-
export const MAX_REGEX_MATCH = 500;
|
|
32
|
-
|
|
33
|
-
// @public (undocumented)
|
|
34
|
-
type OnBeforeRegexMatch = (tr: Transaction) => void;
|
|
35
|
-
|
|
36
|
-
export { OnHandlerApply }
|
|
37
|
-
|
|
38
|
-
// @public (undocumented)
|
|
39
|
-
export type OnInputEvent = (props: {
|
|
40
|
-
state: EditorState;
|
|
41
|
-
from: number;
|
|
42
|
-
to: number;
|
|
43
|
-
}) => boolean;
|
|
44
|
-
|
|
45
|
-
// @public (undocumented)
|
|
46
|
-
type Options = {
|
|
47
|
-
allowInsertTextOnDocument?: boolean;
|
|
48
|
-
onInputEvent?: OnInputEvent;
|
|
49
|
-
onBeforeRegexMatch?: OnBeforeRegexMatch;
|
|
50
|
-
};
|
|
51
|
-
|
|
52
|
-
// @public (undocumented)
|
|
53
|
-
type Options_2 = {
|
|
54
|
-
isBlockNodeRule?: boolean;
|
|
55
|
-
allowInsertTextOnDocument?: boolean;
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
// @public (undocumented)
|
|
59
|
-
export const TEXT_INPUT_RULE_TRANSACTION_KEY = "input_rule_plugin_transaction";
|
|
60
|
-
|
|
61
|
-
// (No @packageDocumentation comment for this package)
|
|
62
|
-
|
|
63
|
-
```
|