@atlaskit/adf-schema 35.6.0 → 35.8.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/adf-schema
2
2
 
3
+ ## 35.8.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 39eba61: [ED-22607] - Remove `maxFrames` attribute from `multiBodiedExtension`
8
+
9
+ ## 35.7.0
10
+
11
+ ### Minor Changes
12
+
13
+ - 1502335: Added annotation mark to media and mediaInline
14
+
3
15
  ## 35.6.0
4
16
 
5
17
  ### Minor Changes
@@ -16,7 +16,7 @@ var mediaGroup = {
16
16
  group: 'block',
17
17
  content: '(media|unsupportedBlock)+',
18
18
  attrs: {},
19
- marks: 'unsupportedMark unsupportedNodeAttribute border link',
19
+ marks: 'unsupportedMark unsupportedNodeAttribute annotation border link',
20
20
  selectable: false,
21
21
  parseDOM: [{
22
22
  tag: 'div[data-node-type="mediaGroup"]'
@@ -108,7 +108,7 @@ var mediaSingleSpec = function mediaSingleSpec(_ref) {
108
108
  default: null
109
109
  }
110
110
  }) : defaultAttrs,
111
- marks: 'unsupportedMark unsupportedNodeAttribute border link',
111
+ marks: 'unsupportedMark unsupportedNodeAttribute annotation border link',
112
112
  parseDOM: [{
113
113
  tag: 'div[data-node-type="mediaSingle"]',
114
114
  getAttrs: getAttrs
@@ -62,9 +62,6 @@ var createMultiBodiedExtensionNodeSpec = function createMultiBodiedExtensionNode
62
62
  extensionType: {
63
63
  default: ''
64
64
  },
65
- maxFrames: {
66
- default: 5
67
- },
68
65
  parameters: {
69
66
  default: null
70
67
  },
@@ -10,7 +10,7 @@ export const mediaGroup = {
10
10
  group: 'block',
11
11
  content: '(media|unsupportedBlock)+',
12
12
  attrs: {},
13
- marks: 'unsupportedMark unsupportedNodeAttribute border link',
13
+ marks: 'unsupportedMark unsupportedNodeAttribute annotation border link',
14
14
  selectable: false,
15
15
  parseDOM: [{
16
16
  tag: 'div[data-node-type="mediaGroup"]'
@@ -102,7 +102,7 @@ export const mediaSingleSpec = ({
102
102
  default: null
103
103
  }
104
104
  } : defaultAttrs,
105
- marks: 'unsupportedMark unsupportedNodeAttribute border link',
105
+ marks: 'unsupportedMark unsupportedNodeAttribute annotation border link',
106
106
  parseDOM: [{
107
107
  tag: 'div[data-node-type="mediaSingle"]',
108
108
  getAttrs
@@ -57,9 +57,6 @@ const createMultiBodiedExtensionNodeSpec = () => {
57
57
  extensionType: {
58
58
  default: ''
59
59
  },
60
- maxFrames: {
61
- default: 5
62
- },
63
60
  parameters: {
64
61
  default: null
65
62
  },
@@ -10,7 +10,7 @@ export var mediaGroup = {
10
10
  group: 'block',
11
11
  content: '(media|unsupportedBlock)+',
12
12
  attrs: {},
13
- marks: 'unsupportedMark unsupportedNodeAttribute border link',
13
+ marks: 'unsupportedMark unsupportedNodeAttribute annotation border link',
14
14
  selectable: false,
15
15
  parseDOM: [{
16
16
  tag: 'div[data-node-type="mediaGroup"]'
@@ -101,7 +101,7 @@ export var mediaSingleSpec = function mediaSingleSpec(_ref) {
101
101
  default: null
102
102
  }
103
103
  }) : defaultAttrs,
104
- marks: 'unsupportedMark unsupportedNodeAttribute border link',
104
+ marks: 'unsupportedMark unsupportedNodeAttribute annotation border link',
105
105
  parseDOM: [{
106
106
  tag: 'div[data-node-type="mediaSingle"]',
107
107
  getAttrs: getAttrs
@@ -57,9 +57,6 @@ var createMultiBodiedExtensionNodeSpec = function createMultiBodiedExtensionNode
57
57
  extensionType: {
58
58
  default: ''
59
59
  },
60
- maxFrames: {
61
- default: 5
62
- },
63
60
  parameters: {
64
61
  default: null
65
62
  },
@@ -983,6 +983,9 @@
983
983
  {
984
984
  "$ref": "#/definitions/link_mark"
985
985
  },
986
+ {
987
+ "$ref": "#/definitions/annotation_mark"
988
+ },
986
989
  {
987
990
  "$ref": "#/definitions/border_mark"
988
991
  }
@@ -1049,6 +1052,9 @@
1049
1052
  {
1050
1053
  "$ref": "#/definitions/link_mark"
1051
1054
  },
1055
+ {
1056
+ "$ref": "#/definitions/annotation_mark"
1057
+ },
1052
1058
  {
1053
1059
  "$ref": "#/definitions/border_mark"
1054
1060
  }
@@ -989,6 +989,9 @@
989
989
  {
990
990
  "$ref": "#/definitions/link_mark"
991
991
  },
992
+ {
993
+ "$ref": "#/definitions/annotation_mark"
994
+ },
992
995
  {
993
996
  "$ref": "#/definitions/border_mark"
994
997
  }
@@ -1055,6 +1058,9 @@
1055
1058
  {
1056
1059
  "$ref": "#/definitions/link_mark"
1057
1060
  },
1061
+ {
1062
+ "$ref": "#/definitions/annotation_mark"
1063
+ },
1058
1064
  {
1059
1065
  "$ref": "#/definitions/border_mark"
1060
1066
  }
@@ -2937,10 +2943,6 @@
2937
2943
  "attrs": {
2938
2944
  "type": "object",
2939
2945
  "properties": {
2940
- "maxFrames": {
2941
- "type": "number",
2942
- "default": 5
2943
- },
2944
2946
  "extensionKey": {
2945
2947
  "type": "string",
2946
2948
  "minLength": 1
@@ -2965,11 +2967,11 @@
2965
2967
  "minLength": 1
2966
2968
  }
2967
2969
  },
2968
- "additionalProperties": false,
2969
2970
  "required": [
2970
2971
  "extensionKey",
2971
2972
  "extensionType"
2972
- ]
2973
+ ],
2974
+ "additionalProperties": false
2973
2975
  },
2974
2976
  "marks": {
2975
2977
  "type": "array"
@@ -2,6 +2,7 @@ import { NodeSpec } from '@atlaskit/editor-prosemirror/model';
2
2
  import { LinkDefinition } from '../marks/link';
3
3
  import { MediaBaseAttributes } from './media';
4
4
  import { BorderMarkDefinition } from '../marks/border';
5
+ import { AnnotationMarkDefinition } from '../marks/annotation';
5
6
  export interface MediaInlineAttributes extends MediaBaseAttributes {
6
7
  data?: object;
7
8
  type?: 'file' | 'link' | 'image';
@@ -12,6 +13,6 @@ export interface MediaInlineAttributes extends MediaBaseAttributes {
12
13
  export interface MediaInlineDefinition {
13
14
  type: 'mediaInline';
14
15
  attrs: MediaInlineAttributes;
15
- marks?: Array<LinkDefinition | BorderMarkDefinition>;
16
+ marks?: Array<LinkDefinition | BorderMarkDefinition | AnnotationMarkDefinition>;
16
17
  }
17
18
  export declare const mediaInline: NodeSpec;
@@ -1,6 +1,7 @@
1
1
  import { NodeSpec, Node as PMNode } from '@atlaskit/editor-prosemirror/model';
2
2
  import { BorderMarkDefinition } from '../marks/border';
3
3
  import { LinkDefinition } from '../marks/link';
4
+ import { AnnotationMarkDefinition } from '../marks/annotation';
4
5
  export type MediaType = 'file' | 'link' | 'external';
5
6
  export type DisplayType = 'file' | 'thumbnail';
6
7
  export type DefaultAttributes<T> = {
@@ -17,7 +18,7 @@ export interface MediaDefinition {
17
18
  * @minItems 1
18
19
  */
19
20
  attrs: MediaADFAttrs;
20
- marks?: Array<LinkDefinition | BorderMarkDefinition>;
21
+ marks?: Array<LinkDefinition | BorderMarkDefinition | AnnotationMarkDefinition>;
21
22
  }
22
23
  export interface MediaBaseAttributes {
23
24
  /**
@@ -1,5 +1,5 @@
1
1
  import { NodeSpec } from '@atlaskit/editor-prosemirror/model';
2
- import { MultiBodiedExtensionAttributes } from './types/extensions';
2
+ import { ExtensionAttributes } from './types/extensions';
3
3
  import { BodiedExtensionDefinition as BodiedExtension } from './bodied-extension';
4
4
  import { PanelDefinition as Panel } from './panel';
5
5
  import { ParagraphDefinition as Paragraph } from './paragraph';
@@ -42,7 +42,7 @@ export declare const extensionFrame: NodeSpec;
42
42
  */
43
43
  export interface MultiBodiedExtensionDefinition {
44
44
  type: 'multiBodiedExtension';
45
- attrs: MultiBodiedExtensionAttributes;
45
+ attrs: ExtensionAttributes;
46
46
  marks?: Array<any>;
47
47
  /**
48
48
  * @minLength 1
@@ -32,9 +32,3 @@ export interface InlineExtensionAttributes {
32
32
  */
33
33
  localId?: string;
34
34
  }
35
- export interface MultiBodiedExtensionAttributes extends ExtensionAttributes {
36
- /**
37
- * @default 5
38
- */
39
- maxFrames?: number;
40
- }
@@ -983,6 +983,9 @@
983
983
  {
984
984
  "$ref": "#/definitions/link_mark"
985
985
  },
986
+ {
987
+ "$ref": "#/definitions/annotation_mark"
988
+ },
986
989
  {
987
990
  "$ref": "#/definitions/border_mark"
988
991
  }
@@ -1049,6 +1052,9 @@
1049
1052
  {
1050
1053
  "$ref": "#/definitions/link_mark"
1051
1054
  },
1055
+ {
1056
+ "$ref": "#/definitions/annotation_mark"
1057
+ },
1052
1058
  {
1053
1059
  "$ref": "#/definitions/border_mark"
1054
1060
  }
@@ -989,6 +989,9 @@
989
989
  {
990
990
  "$ref": "#/definitions/link_mark"
991
991
  },
992
+ {
993
+ "$ref": "#/definitions/annotation_mark"
994
+ },
992
995
  {
993
996
  "$ref": "#/definitions/border_mark"
994
997
  }
@@ -1055,6 +1058,9 @@
1055
1058
  {
1056
1059
  "$ref": "#/definitions/link_mark"
1057
1060
  },
1061
+ {
1062
+ "$ref": "#/definitions/annotation_mark"
1063
+ },
1058
1064
  {
1059
1065
  "$ref": "#/definitions/border_mark"
1060
1066
  }
@@ -2937,10 +2943,6 @@
2937
2943
  "attrs": {
2938
2944
  "type": "object",
2939
2945
  "properties": {
2940
- "maxFrames": {
2941
- "type": "number",
2942
- "default": 5
2943
- },
2944
2946
  "extensionKey": {
2945
2947
  "type": "string",
2946
2948
  "minLength": 1
@@ -2965,11 +2967,11 @@
2965
2967
  "minLength": 1
2966
2968
  }
2967
2969
  },
2968
- "additionalProperties": false,
2969
2970
  "required": [
2970
2971
  "extensionKey",
2971
2972
  "extensionType"
2972
- ]
2973
+ ],
2974
+ "additionalProperties": false
2973
2975
  },
2974
2976
  "marks": {
2975
2977
  "type": "array"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/adf-schema",
3
- "version": "35.6.0",
3
+ "version": "35.8.0",
4
4
  "description": "Shared package that contains the ADF-schema (json) and ProseMirror node/mark specs",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -41,7 +41,7 @@
41
41
  "memoize-one": "^6.0.0"
42
42
  },
43
43
  "devDependencies": {
44
- "@atlassian/adf-schema-json": "^1.6.0",
44
+ "@atlassian/adf-schema-json": "^1.7.0",
45
45
  "@babel/cli": "^7.22.9",
46
46
  "@babel/core": "^7.22.9",
47
47
  "@babel/plugin-proposal-class-properties": "^7.18.6",