@atlaskit/prosemirror-input-rules 2.2.2 → 2.2.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 CHANGED
@@ -1,5 +1,18 @@
1
1
  # @atlaskit/prosemirror-input-rules
2
2
 
3
+ ## 2.2.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [`73b5128036b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/73b5128036b) - [ED-17082] Mark package as a singleton one
8
+ - Updated dependencies
9
+
10
+ ## 2.2.3
11
+
12
+ ### Patch Changes
13
+
14
+ - [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
15
+
3
16
  ## 2.2.2
4
17
 
5
18
  ### Patch Changes
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/prosemirror-input-rules",
3
- "version": "2.2.2",
3
+ "version": "2.2.4",
4
4
  "sideEffects": false
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/prosemirror-input-rules",
3
- "version": "2.2.2",
3
+ "version": "2.2.4",
4
4
  "sideEffects": false
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/prosemirror-input-rules",
3
- "version": "2.2.2",
3
+ "version": "2.2.4",
4
4
  "sideEffects": false
5
5
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/prosemirror-input-rules",
3
- "version": "2.2.2",
3
+ "version": "2.2.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/"
@@ -24,16 +24,16 @@
24
24
  "atlaskit:src": "src/index.ts",
25
25
  "atlassian": {
26
26
  "team": "Editor",
27
- "releaseModel": "scheduled"
27
+ "singleton": true,
28
+ "releaseModel": "continuous"
28
29
  },
29
30
  "dependencies": {
30
- "@atlaskit/editor-common": "^74.1.0",
31
+ "@atlaskit/editor-common": "^74.9.0",
31
32
  "@babel/runtime": "^7.0.0",
32
33
  "prosemirror-state": "1.3.4"
33
34
  },
34
35
  "devDependencies": {
35
- "@atlaskit/adf-schema": "^25.6.0",
36
- "@atlaskit/editor-test-helpers": "^18.3.0",
36
+ "@atlaskit/editor-test-helpers": "^18.7.0",
37
37
  "@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",
38
38
  "@types/prosemirror-history": "^1.0.1",
39
39
  "@types/prosemirror-model": "^1.11.0",
@@ -0,0 +1,58 @@
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 type { EditorState } from 'prosemirror-state';
8
+ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
9
+ import type { Transaction } from 'prosemirror-state';
10
+
11
+ // @public (undocumented)
12
+ export function createInputRulePlugin(pluginName: string, rules: InputRuleWrapper[], options?: Options): SafePlugin;
13
+
14
+ // @public (undocumented)
15
+ export type InputRuleHandler = (state: EditorState, matchResult: RegExpExecArray, start: number, end: number) => Transaction | null;
16
+
17
+ // @public (undocumented)
18
+ export interface InputRuleWrapper {
19
+ // (undocumented)
20
+ handler: InputRuleHandler;
21
+ // (undocumented)
22
+ match: RegExp;
23
+ // (undocumented)
24
+ onHandlerApply?: OnHandlerApply;
25
+ }
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
+ // @public (undocumented)
37
+ export type OnHandlerApply = (state: EditorState, tr: Transaction, matchResult: RegExpExecArray) => void;
38
+
39
+ // @public (undocumented)
40
+ export type OnInputEvent = (props: {
41
+ state: EditorState;
42
+ from: number;
43
+ to: number;
44
+ }) => boolean;
45
+
46
+ // @public (undocumented)
47
+ type Options = {
48
+ allowInsertTextOnDocument?: boolean;
49
+ onInputEvent?: OnInputEvent;
50
+ onBeforeRegexMatch?: OnBeforeRegexMatch;
51
+ };
52
+
53
+ // @public (undocumented)
54
+ export const TEXT_INPUT_RULE_TRANSACTION_KEY = "input_rule_plugin_transaction";
55
+
56
+ // (No @packageDocumentation comment for this package)
57
+
58
+ ```