@crimson-education/helios-editor-renderer 1.1.4 → 1.1.5

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.
Files changed (2) hide show
  1. package/index.mjs +58 -25
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -86377,7 +86377,14 @@ const D$ = ({
86377
86377
  children: e,
86378
86378
  className: t,
86379
86379
  ...r
86380
- }) => /* @__PURE__ */ oe(Pt, { className: rt(t, "m-0 px-0 py-1"), ...r, children: e });
86380
+ }) => /* @__PURE__ */ oe(
86381
+ Pt,
86382
+ {
86383
+ className: rt(t, "m-0 px-0 leading-[1.6] mb-5"),
86384
+ ...r,
86385
+ children: e
86386
+ }
86387
+ );
86381
86388
  function SA({
86382
86389
  children: e,
86383
86390
  className: t,
@@ -86744,9 +86751,13 @@ const G$ = ({
86744
86751
  }
86745
86752
  }, L = (B, X) => {
86746
86753
  if (!B.text) return null;
86747
- if (!B.highlight || !B.highlightColor) return /* @__PURE__ */ oe("span", { children: B.text }, X);
86754
+ if (!B.highlight || !B.highlightColor)
86755
+ return /* @__PURE__ */ oe("span", { children: B.text }, X);
86748
86756
  if (!C(B).comment) return /* @__PURE__ */ oe("span", { children: B.text }, X);
86749
- const z = S[B.highlightColor] || { text: B.highlightColor, bg: "transparent" };
86757
+ const z = S[B.highlightColor] || {
86758
+ text: B.highlightColor,
86759
+ bg: "transparent"
86760
+ };
86750
86761
  return /* @__PURE__ */ oe(
86751
86762
  "span",
86752
86763
  {
@@ -86784,13 +86795,16 @@ const G$ = ({
86784
86795
  const ve = 500 - P, me = ne.text ?? "", V = r ? me : me.slice(0, Math.max(ve, 0));
86785
86796
  te.push(L({ ...ne, text: V }, ce)), P += V.length, !r && P >= 500 && (Q = !0);
86786
86797
  }), te.length > 0 && X.push(
86787
- /* @__PURE__ */ oe("p", { className: "mb-2", children: te }, z.id ?? K)
86798
+ /* @__PURE__ */ oe("p", { className: "mb-5 mt-0 leading-[1.6] ", children: te }, z.id ?? K)
86788
86799
  );
86789
86800
  }), X;
86790
86801
  }, U = () => {
86791
86802
  n((B) => {
86792
86803
  const X = !B;
86793
- return B && d.current && d.current.scrollIntoView({ behavior: "smooth", block: "start" }), X;
86804
+ return B && d.current && d.current.scrollIntoView({
86805
+ behavior: "smooth",
86806
+ block: "start"
86807
+ }), X;
86794
86808
  });
86795
86809
  };
86796
86810
  return /* @__PURE__ */ Mt(
@@ -86799,11 +86813,17 @@ const G$ = ({
86799
86813
  ...e,
86800
86814
  className: "essay-excerpt-body transition-all duration-300 border-t border-neutral01-25",
86801
86815
  children: [
86802
- /* @__PURE__ */ oe("div", { ref: d, className: "essay-excerpt-body-anchor h-0 w-0 overflow-hidden" }),
86803
86816
  /* @__PURE__ */ oe(
86804
86817
  "div",
86805
86818
  {
86806
- className: "overflow-hidden transition-all duration-300",
86819
+ ref: d,
86820
+ className: "essay-excerpt-body-anchor h-0 w-0 overflow-hidden"
86821
+ }
86822
+ ),
86823
+ /* @__PURE__ */ oe(
86824
+ "div",
86825
+ {
86826
+ className: "overflow-hidden transition-all duration-300 mt-4",
86807
86827
  style: {
86808
86828
  maskImage: A && !r ? "linear-gradient(to bottom, black 90%, transparent 100%)" : "none"
86809
86829
  },
@@ -86822,31 +86842,44 @@ const G$ = ({
86822
86842
  ${o ? "opacity-100 pointer-events-auto" : "opacity-0 pointer-events-none"}`,
86823
86843
  style: { top: l.top, left: l.left },
86824
86844
  children: [
86825
- /* @__PURE__ */ Mt("div", { className: `comment-tooltip-title mb-2 flex gap-2 ${a.color}`, children: [
86826
- a.icon,
86827
- /* @__PURE__ */ oe("span", { className: "text-[1.75rem]", children: a.title })
86828
- ] }),
86845
+ /* @__PURE__ */ Mt(
86846
+ "div",
86847
+ {
86848
+ className: `comment-tooltip-title mb-2 flex gap-2 ${a.color}`,
86849
+ children: [
86850
+ a.icon,
86851
+ /* @__PURE__ */ oe("span", { className: "text-[1.75rem]", children: a.title })
86852
+ ]
86853
+ }
86854
+ ),
86829
86855
  /* @__PURE__ */ oe("div", { className: a.commentStyle, children: a.comment }),
86830
86856
  /* @__PURE__ */ oe("div", { className: "absolute -top-1 left-6", children: /* @__PURE__ */ oe("div", { className: "border-gray-300 size-2 rotate-45 bg-white" }) })
86831
86857
  ]
86832
86858
  }
86833
86859
  ),
86834
- A && /* @__PURE__ */ oe("div", { className: "mt-4 essay-excerpt-expand-button", contentEditable: !1, children: /* @__PURE__ */ Mt(
86835
- "button",
86860
+ A && /* @__PURE__ */ oe(
86861
+ "div",
86836
86862
  {
86837
- className: "transition-colors duration-200 flex items-center gap-2 m-auto",
86838
- onClick: U,
86839
- children: [
86840
- r ? m : _,
86841
- /* @__PURE__ */ oe(
86842
- g$,
86843
- {
86844
- className: `mt-[3px] w-4 h-4 transition-transform duration-300 ${r ? "rotate-180" : "rotate-0"}`
86845
- }
86846
- )
86847
- ]
86863
+ className: "mt-4 essay-excerpt-expand-button",
86864
+ contentEditable: !1,
86865
+ children: /* @__PURE__ */ Mt(
86866
+ "button",
86867
+ {
86868
+ className: "transition-colors duration-200 flex items-center gap-2 m-auto",
86869
+ onClick: U,
86870
+ children: [
86871
+ r ? m : _,
86872
+ /* @__PURE__ */ oe(
86873
+ g$,
86874
+ {
86875
+ className: `mt-[3px] w-4 h-4 transition-transform duration-300 ${r ? "rotate-180" : "rotate-0"}`
86876
+ }
86877
+ )
86878
+ ]
86879
+ }
86880
+ )
86848
86881
  }
86849
- ) })
86882
+ )
86850
86883
  ]
86851
86884
  }
86852
86885
  );
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crimson-education/helios-editor-renderer",
3
- "version": "1.1.4",
3
+ "version": "1.1.5",
4
4
  "main": "./index.js",
5
5
  "types": "./index.d.ts",
6
6
  "exports": {