@superinterface/react 3.9.3 → 3.9.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/dist/index.js CHANGED
@@ -4054,55 +4054,99 @@ var AnnotationBase = function(_ref) {
4054
4054
  };
4055
4055
  // src/contexts/markdown/MarkdownContext/lib/components/Annotation/index.tsx
4056
4056
  import { jsx as _jsx42 } from "react/jsx-runtime";
4057
+ var _excluded = [
4058
+ "children"
4059
+ ];
4060
+ function _objectWithoutProperties(e, t) {
4061
+ if (null == e) return {};
4062
+ var o, r, i = _objectWithoutPropertiesLoose(e, t);
4063
+ if (Object.getOwnPropertySymbols) {
4064
+ var s = Object.getOwnPropertySymbols(e);
4065
+ for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
4066
+ }
4067
+ return i;
4068
+ }
4069
+ function _objectWithoutPropertiesLoose(r, e) {
4070
+ if (null == r) return {};
4071
+ var t = {};
4072
+ for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
4073
+ if (e.includes(n)) continue;
4074
+ t[n] = r[n];
4075
+ }
4076
+ return t;
4077
+ }
4057
4078
  var Annotation = function(t0) {
4058
- var $ = _c21(4);
4059
- var annotation = t0.annotation, children = t0.children;
4079
+ var $ = _c21(9);
4080
+ var children;
4081
+ var rest;
4082
+ if ($[0] !== t0) {
4083
+ var _t = t0;
4084
+ children = _t.children;
4085
+ rest = _objectWithoutProperties(_t, _excluded);
4086
+ _t;
4087
+ $[0] = t0;
4088
+ $[1] = children;
4089
+ $[2] = rest;
4090
+ } else {
4091
+ children = $[1];
4092
+ rest = $[2];
4093
+ }
4094
+ var t1;
4095
+ if ($[3] !== rest) {
4096
+ var _rest$dataAnnotation;
4097
+ t1 = JSON.parse((_rest$dataAnnotation = rest["data-annotation"]) !== null && _rest$dataAnnotation !== void 0 ? _rest$dataAnnotation : "{}");
4098
+ $[3] = rest;
4099
+ $[4] = t1;
4100
+ } else {
4101
+ t1 = $[4];
4102
+ }
4103
+ var annotation = t1;
4060
4104
  if (annotation.type === "file_citation") {
4061
- var t1;
4062
- if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
4063
- t1 = /* @__PURE__ */ _jsx42(AnnotationBase, {
4105
+ var t2;
4106
+ if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
4107
+ t2 = /* @__PURE__ */ _jsx42(AnnotationBase, {
4064
4108
  icon: /* @__PURE__ */ _jsx42(QuoteIcon, {}),
4065
4109
  content: "File cited."
4066
4110
  });
4067
- $[0] = t1;
4111
+ $[5] = t2;
4068
4112
  } else {
4069
- t1 = $[0];
4113
+ t2 = $[5];
4070
4114
  }
4071
- return t1;
4115
+ return t2;
4072
4116
  } else {
4073
4117
  if (annotation.type === "file_path") {
4074
- var _t;
4075
- if ($[1] !== annotation || $[2] !== children) {
4076
- _t = /* @__PURE__ */ _jsx42(FilePathAnnotation, {
4118
+ var _t2;
4119
+ if ($[6] !== annotation || $[7] !== children) {
4120
+ _t2 = /* @__PURE__ */ _jsx42(FilePathAnnotation, {
4077
4121
  annotation: annotation,
4078
4122
  children: children
4079
4123
  });
4080
- $[1] = annotation;
4081
- $[2] = children;
4082
- $[3] = _t;
4124
+ $[6] = annotation;
4125
+ $[7] = children;
4126
+ $[8] = _t2;
4083
4127
  } else {
4084
- _t = $[3];
4128
+ _t2 = $[8];
4085
4129
  }
4086
- return _t;
4130
+ return _t2;
4087
4131
  }
4088
4132
  }
4089
4133
  return null;
4090
4134
  };
4091
4135
  // src/contexts/markdown/MarkdownContext/lib/components/index.tsx
4092
4136
  import { jsx as _jsx43, Fragment as _Fragment, jsxs as _jsxs15 } from "react/jsx-runtime";
4093
- var _excluded = [
4137
+ var _excluded2 = [
4094
4138
  "width"
4095
4139
  ];
4096
- function _objectWithoutProperties(e, t) {
4140
+ function _objectWithoutProperties2(e, t) {
4097
4141
  if (null == e) return {};
4098
- var o, r, i = _objectWithoutPropertiesLoose(e, t);
4142
+ var o, r, i = _objectWithoutPropertiesLoose2(e, t);
4099
4143
  if (Object.getOwnPropertySymbols) {
4100
4144
  var s = Object.getOwnPropertySymbols(e);
4101
4145
  for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
4102
4146
  }
4103
4147
  return i;
4104
4148
  }
4105
- function _objectWithoutPropertiesLoose(r, e) {
4149
+ function _objectWithoutPropertiesLoose2(r, e) {
4106
4150
  if (null == r) return {};
4107
4151
  var t = {};
4108
4152
  for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
@@ -4229,7 +4273,7 @@ var components = {
4229
4273
  return /* @__PURE__ */ _jsx43(Table.Row, _objectSpread22({}, props));
4230
4274
  },
4231
4275
  td: function(_ref) {
4232
- var width2 = _ref.width, rest = _objectWithoutProperties(_ref, _excluded);
4276
+ var width2 = _ref.width, rest = _objectWithoutProperties2(_ref, _excluded2);
4233
4277
  return /* @__PURE__ */ _jsx43(Table.Cell, _objectSpread22(_objectSpread22({}, rest), {}, {
4234
4278
  width: width2
4235
4279
  }));
@@ -4437,9 +4481,7 @@ var createAnnotationNode = function(_ref6) {
4437
4481
  },
4438
4482
  data: {
4439
4483
  hName: "annotation",
4440
- hProperties: {
4441
- annotation: annotation
4442
- }
4484
+ hProperties: _define_property({}, "data-annotation", JSON.stringify(annotation))
4443
4485
  }
4444
4486
  };
4445
4487
  };
@@ -6343,7 +6385,7 @@ import { c as _c38 } from "react-compiler-runtime";
6343
6385
  import { forwardRef as forwardRef4 } from "react";
6344
6386
  import TextareaAutosize from "react-textarea-autosize";
6345
6387
  import { jsx as _jsx65, Fragment as _Fragment3, jsxs as _jsxs22 } from "react/jsx-runtime";
6346
- var _excluded2 = [
6388
+ var _excluded3 = [
6347
6389
  "style",
6348
6390
  "className"
6349
6391
  ];
@@ -6390,16 +6432,16 @@ function _toPrimitive29(t, r) {
6390
6432
  }
6391
6433
  return ("string" === r ? String : Number)(t);
6392
6434
  }
6393
- function _objectWithoutProperties2(e, t) {
6435
+ function _objectWithoutProperties3(e, t) {
6394
6436
  if (null == e) return {};
6395
- var o, r, i = _objectWithoutPropertiesLoose2(e, t);
6437
+ var o, r, i = _objectWithoutPropertiesLoose3(e, t);
6396
6438
  if (Object.getOwnPropertySymbols) {
6397
6439
  var s = Object.getOwnPropertySymbols(e);
6398
6440
  for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
6399
6441
  }
6400
6442
  return i;
6401
6443
  }
6402
- function _objectWithoutPropertiesLoose2(r, e) {
6444
+ function _objectWithoutPropertiesLoose3(r, e) {
6403
6445
  if (null == r) return {};
6404
6446
  var t = {};
6405
6447
  for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
@@ -6418,7 +6460,7 @@ var TextareaBase = /* @__PURE__ */ forwardRef4(function TextareaBase2(t0, ref) {
6418
6460
  var _t = t0;
6419
6461
  var _$ref;
6420
6462
  _$ref = _t, style = _$ref.style, className = _$ref.className, _$ref;
6421
- rest = _objectWithoutProperties2(_t, _excluded2);
6463
+ rest = _objectWithoutProperties3(_t, _excluded3);
6422
6464
  _t;
6423
6465
  $[0] = t0;
6424
6466
  $[1] = className;
@@ -7662,7 +7704,7 @@ function _temp7(toast_0, index) {
7662
7704
  }
7663
7705
  // src/components/threads/Thread/Root/index.tsx
7664
7706
  import { jsx as _jsx73 } from "react/jsx-runtime";
7665
- var _excluded3 = [
7707
+ var _excluded4 = [
7666
7708
  "children",
7667
7709
  "style",
7668
7710
  "className"
@@ -7710,16 +7752,16 @@ function _toPrimitive38(t, r) {
7710
7752
  }
7711
7753
  return ("string" === r ? String : Number)(t);
7712
7754
  }
7713
- function _objectWithoutProperties3(e, t) {
7755
+ function _objectWithoutProperties4(e, t) {
7714
7756
  if (null == e) return {};
7715
- var o, r, i = _objectWithoutPropertiesLoose3(e, t);
7757
+ var o, r, i = _objectWithoutPropertiesLoose4(e, t);
7716
7758
  if (Object.getOwnPropertySymbols) {
7717
7759
  var s = Object.getOwnPropertySymbols(e);
7718
7760
  for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
7719
7761
  }
7720
7762
  return i;
7721
7763
  }
7722
- function _objectWithoutPropertiesLoose3(r, e) {
7764
+ function _objectWithoutPropertiesLoose4(r, e) {
7723
7765
  if (null == r) return {};
7724
7766
  var t = {};
7725
7767
  for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
@@ -7729,7 +7771,7 @@ function _objectWithoutPropertiesLoose3(r, e) {
7729
7771
  return t;
7730
7772
  }
7731
7773
  var Root8 = function(_ref) {
7732
- var children = _ref.children, style = _ref.style, className = _ref.className, rest = _objectWithoutProperties3(_ref, _excluded3);
7774
+ var children = _ref.children, style = _ref.style, className = _ref.className, rest = _objectWithoutProperties4(_ref, _excluded4);
7733
7775
  return /* @__PURE__ */ _jsx73(ToastsProvider, {
7734
7776
  bottom: "var(--space-9)",
7735
7777
  children: /* @__PURE__ */ _jsx73(Provider2, _objectSpread38(_objectSpread38({}, rest), {}, {
@@ -9494,7 +9536,7 @@ function _temp11() {
9494
9536
  // src/components/threads/AudioThread/Root/index.tsx
9495
9537
  import { useQueryClient as useQueryClient6 } from "@tanstack/react-query";
9496
9538
  import { jsx as _jsx82 } from "react/jsx-runtime";
9497
- var _excluded4 = [
9539
+ var _excluded5 = [
9498
9540
  "children"
9499
9541
  ];
9500
9542
  function ownKeys46(e, r) {
@@ -9540,16 +9582,16 @@ function _toPrimitive46(t, r) {
9540
9582
  }
9541
9583
  return ("string" === r ? String : Number)(t);
9542
9584
  }
9543
- function _objectWithoutProperties4(e, t) {
9585
+ function _objectWithoutProperties5(e, t) {
9544
9586
  if (null == e) return {};
9545
- var o, r, i = _objectWithoutPropertiesLoose4(e, t);
9587
+ var o, r, i = _objectWithoutPropertiesLoose5(e, t);
9546
9588
  if (Object.getOwnPropertySymbols) {
9547
9589
  var s = Object.getOwnPropertySymbols(e);
9548
9590
  for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
9549
9591
  }
9550
9592
  return i;
9551
9593
  }
9552
- function _objectWithoutPropertiesLoose4(r, e) {
9594
+ function _objectWithoutPropertiesLoose5(r, e) {
9553
9595
  if (null == r) return {};
9554
9596
  var t = {};
9555
9597
  for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
@@ -9737,7 +9779,7 @@ var Content8 = function(t0) {
9737
9779
  return t10;
9738
9780
  };
9739
9781
  var Root12 = function(_ref) {
9740
- var children = _ref.children, rest = _objectWithoutProperties4(_ref, _excluded4);
9782
+ var children = _ref.children, rest = _objectWithoutProperties5(_ref, _excluded5);
9741
9783
  return /* @__PURE__ */ _jsx82(ToastsProvider, {
9742
9784
  children: /* @__PURE__ */ _jsx82(Content8, _objectSpread46(_objectSpread46({}, rest), {}, {
9743
9785
  children: children
@@ -10648,19 +10690,19 @@ AudioThreadDialog.Content = Content7;
10648
10690
  import { c as _c55 } from "react-compiler-runtime";
10649
10691
  import { useMemo as useMemo19 } from "react";
10650
10692
  import { jsx as _jsx92 } from "react/jsx-runtime";
10651
- var _excluded5 = [
10693
+ var _excluded6 = [
10652
10694
  "children"
10653
10695
  ];
10654
- function _objectWithoutProperties5(e, t) {
10696
+ function _objectWithoutProperties6(e, t) {
10655
10697
  if (null == e) return {};
10656
- var o, r, i = _objectWithoutPropertiesLoose5(e, t);
10698
+ var o, r, i = _objectWithoutPropertiesLoose6(e, t);
10657
10699
  if (Object.getOwnPropertySymbols) {
10658
10700
  var s = Object.getOwnPropertySymbols(e);
10659
10701
  for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
10660
10702
  }
10661
10703
  return i;
10662
10704
  }
10663
- function _objectWithoutPropertiesLoose5(r, e) {
10705
+ function _objectWithoutPropertiesLoose6(r, e) {
10664
10706
  if (null == r) return {};
10665
10707
  var t = {};
10666
10708
  for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
@@ -10676,7 +10718,7 @@ var MarkdownProvider = function(t0) {
10676
10718
  if ($[0] !== t0) {
10677
10719
  var _t = t0;
10678
10720
  children = _t.children;
10679
- rest = _objectWithoutProperties5(_t, _excluded5);
10721
+ rest = _objectWithoutProperties6(_t, _excluded6);
10680
10722
  _t;
10681
10723
  $[0] = t0;
10682
10724
  $[1] = children;
@@ -10943,19 +10985,19 @@ var useComponents = function() {
10943
10985
  };
10944
10986
  // src/components/components/ComponentsProvider.tsx
10945
10987
  import { jsx as _jsx96 } from "react/jsx-runtime";
10946
- var _excluded6 = [
10988
+ var _excluded7 = [
10947
10989
  "children"
10948
10990
  ];
10949
- function _objectWithoutProperties6(e, t) {
10991
+ function _objectWithoutProperties7(e, t) {
10950
10992
  if (null == e) return {};
10951
- var o, r, i = _objectWithoutPropertiesLoose6(e, t);
10993
+ var o, r, i = _objectWithoutPropertiesLoose7(e, t);
10952
10994
  if (Object.getOwnPropertySymbols) {
10953
10995
  var s = Object.getOwnPropertySymbols(e);
10954
10996
  for(r = 0; r < s.length; r++)o = s[r], t.includes(o) || ({}).propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
10955
10997
  }
10956
10998
  return i;
10957
10999
  }
10958
- function _objectWithoutPropertiesLoose6(r, e) {
11000
+ function _objectWithoutPropertiesLoose7(r, e) {
10959
11001
  if (null == r) return {};
10960
11002
  var t = {};
10961
11003
  for(var n in r)if (({}).hasOwnProperty.call(r, n)) {
@@ -10971,7 +11013,7 @@ var ComponentsProvider = function(t0) {
10971
11013
  if ($[0] !== t0) {
10972
11014
  var _t = t0;
10973
11015
  children = _t.children;
10974
- rest = _objectWithoutProperties6(_t, _excluded6);
11016
+ rest = _objectWithoutProperties7(_t, _excluded7);
10975
11017
  _t;
10976
11018
  $[0] = t0;
10977
11019
  $[1] = children;