@supernova-studio/client 0.48.27 → 0.48.28

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/dist/index.mjs CHANGED
@@ -956,14 +956,18 @@ var PageBlockTableProperties = z38.object({
956
956
  showHeaderColumn: z38.boolean(),
957
957
  columns: z38.array(PageBlockTableColumn)
958
958
  });
959
- var PageBlockTextSpanAttributeType = z38.enum(["Bold", "Italic", "Link", "Strikethrough", "Code"]);
959
+ var PageBlockTextSpanAttributeType = z38.enum(["Bold", "Italic", "Link", "Strikethrough", "Code", "Comment"]);
960
960
  var PageBlockTextSpanAttribute = z38.object({
961
961
  type: PageBlockTextSpanAttributeType,
962
+ // Link attributes
962
963
  link: nullishToOptional(z38.string()),
963
964
  documentationItemId: nullishToOptional(z38.string()),
964
965
  openInNewWindow: nullishToOptional(z38.boolean()),
965
966
  // deprecated. use openInNewTab
966
- openInNewTab: nullishToOptional(z38.boolean())
967
+ openInNewTab: nullishToOptional(z38.boolean()),
968
+ // Comment attributes
969
+ commentHighlightId: nullishToOptional(z38.string()),
970
+ commentIsResolved: nullishToOptional(z38.boolean())
967
971
  });
968
972
  var PageBlockTextSpan = z38.object({
969
973
  text: z38.string(),
@@ -7066,7 +7070,7 @@ var newSchema = {
7066
7070
  name: "link",
7067
7071
  rank: 0,
7068
7072
  spec: {
7069
- inclusive: true,
7073
+ inclusive: false,
7070
7074
  attrs: {
7071
7075
  href: {
7072
7076
  default: null
@@ -7078,10 +7082,7 @@ var newSchema = {
7078
7082
  default: "noopener noreferrer nofollow"
7079
7083
  },
7080
7084
  class: {
7081
- default: null
7082
- },
7083
- itemId: {
7084
- default: null
7085
+ default: "tiptap-link"
7085
7086
  }
7086
7087
  },
7087
7088
  parseDOM: [
@@ -7105,11 +7106,7 @@ var newSchema = {
7105
7106
  },
7106
7107
  class: {
7107
7108
  hasDefault: true,
7108
- default: null
7109
- },
7110
- itemId: {
7111
- hasDefault: true,
7112
- default: null
7109
+ default: "tiptap-link"
7113
7110
  }
7114
7111
  },
7115
7112
  instance: {
@@ -7118,47 +7115,65 @@ var newSchema = {
7118
7115
  href: null,
7119
7116
  target: "_blank",
7120
7117
  rel: "noopener noreferrer nofollow",
7121
- class: null,
7122
- itemId: null
7118
+ class: "tiptap-link"
7123
7119
  }
7124
7120
  }
7125
7121
  },
7126
- bold: {
7127
- name: "bold",
7122
+ commentHighlight: {
7123
+ name: "commentHighlight",
7128
7124
  rank: 1,
7129
7125
  spec: {
7130
- parseDOM: [
7131
- {
7132
- tag: "strong"
7133
- },
7134
- {
7135
- tag: "b"
7126
+ attrs: {
7127
+ highlightId: {
7128
+ default: null
7136
7129
  },
7130
+ resolved: {
7131
+ default: false
7132
+ }
7133
+ },
7134
+ parseDOM: [
7137
7135
  {
7138
- style: "font-weight"
7136
+ tag: "commenthighlight"
7139
7137
  }
7140
7138
  ]
7141
7139
  },
7142
- attrs: {},
7140
+ attrs: {
7141
+ highlightId: {
7142
+ hasDefault: true,
7143
+ default: null
7144
+ },
7145
+ resolved: {
7146
+ hasDefault: true,
7147
+ default: false
7148
+ }
7149
+ },
7143
7150
  instance: {
7144
- type: "bold"
7151
+ type: "commentHighlight",
7152
+ attrs: {
7153
+ highlightId: null,
7154
+ resolved: false
7155
+ }
7145
7156
  }
7146
7157
  },
7147
- code: {
7148
- name: "code",
7158
+ bold: {
7159
+ name: "bold",
7149
7160
  rank: 2,
7150
7161
  spec: {
7151
- excludes: "_",
7152
- code: true,
7153
7162
  parseDOM: [
7154
7163
  {
7155
- tag: "code"
7164
+ tag: "strong"
7165
+ },
7166
+ {
7167
+ tag: "b"
7168
+ },
7169
+ {
7170
+ style: "font-weight"
7156
7171
  }
7157
7172
  ]
7158
7173
  },
7159
7174
  attrs: {},
7160
7175
  instance: {
7161
- type: "code"
7176
+ type: "bold"
7162
7177
  }
7163
7178
  },
7164
7179
  italic: {
@@ -7206,6 +7221,23 @@ var newSchema = {
7206
7221
  instance: {
7207
7222
  type: "strike"
7208
7223
  }
7224
+ },
7225
+ code: {
7226
+ name: "code",
7227
+ rank: 5,
7228
+ spec: {
7229
+ excludes: "bold code italic strike link",
7230
+ code: true,
7231
+ parseDOM: [
7232
+ {
7233
+ tag: "code"
7234
+ }
7235
+ ]
7236
+ },
7237
+ attrs: {},
7238
+ instance: {
7239
+ type: "code"
7240
+ }
7209
7241
  }
7210
7242
  }
7211
7243
  };
@@ -7813,6 +7845,14 @@ function serializeTextSpanAttribute(spanAttribute) {
7813
7845
  return { type: "strike", attrs: {} };
7814
7846
  case "Code":
7815
7847
  return { type: "code", attrs: {} };
7848
+ case "Comment":
7849
+ return {
7850
+ type: "commentHighlight",
7851
+ attrs: {
7852
+ highlightId: spanAttribute.commentHighlightId,
7853
+ resolved: spanAttribute.commentIsResolved
7854
+ }
7855
+ };
7816
7856
  case "Link":
7817
7857
  if (spanAttribute.link) {
7818
7858
  return serializeLinkMark(
@@ -10543,6 +10583,8 @@ function parseRichTextAttribute(mark) {
10543
10583
  return { type: "Code" };
10544
10584
  case "link":
10545
10585
  return parseProsemirrorLink(mark);
10586
+ case "commentHighlight":
10587
+ return parseProsemirrorCommentHighlight(mark);
10546
10588
  }
10547
10589
  return null;
10548
10590
  }
@@ -10568,6 +10610,17 @@ function parseProsemirrorLink(mark) {
10568
10610
  };
10569
10611
  }
10570
10612
  }
10613
+ function parseProsemirrorCommentHighlight(mark) {
10614
+ const highlightId = getProsemirrorAttribute(mark, "highlightId", z223.string().optional());
10615
+ if (!highlightId)
10616
+ return null;
10617
+ const isResolved = getProsemirrorAttribute(mark, "resolved", z223.boolean().optional()) ?? false;
10618
+ return {
10619
+ type: "Comment",
10620
+ commentHighlightId: highlightId,
10621
+ commentIsResolved: isResolved
10622
+ };
10623
+ }
10571
10624
  function parseAsTable(prosemirrorNode, definition, property) {
10572
10625
  const id = getProsemirrorBlockId(prosemirrorNode);
10573
10626
  if (!id)