@almadar/ui 2.53.0 → 2.55.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.
@@ -9211,7 +9211,8 @@ var CodeBlock = React90__namespace.default.memo(
9211
9211
  foldable: foldableProp,
9212
9212
  className,
9213
9213
  editable = false,
9214
- onChange
9214
+ onChange,
9215
+ errorLines
9215
9216
  }) => {
9216
9217
  const code = typeof rawCode === "string" ? rawCode : String(rawCode ?? "");
9217
9218
  const isOrb = language === "orb";
@@ -9243,6 +9244,28 @@ var CodeBlock = React90__namespace.default.memo(
9243
9244
  ov.scrollLeft = ta.scrollLeft;
9244
9245
  }
9245
9246
  }, []);
9247
+ const errorLineProps = React90.useMemo(() => {
9248
+ if (!errorLines || errorLines.size === 0) {
9249
+ return LINE_PROPS_FN;
9250
+ }
9251
+ return (lineNumber) => {
9252
+ const severity = errorLines.get(lineNumber);
9253
+ if (!severity) {
9254
+ return { "data-line": String(lineNumber - 1) };
9255
+ }
9256
+ return {
9257
+ "data-line": String(lineNumber - 1),
9258
+ style: {
9259
+ display: "block",
9260
+ backgroundColor: severity === "error" ? "rgba(248, 113, 113, 0.18)" : "rgba(251, 191, 36, 0.18)",
9261
+ // amber-400 @ 18%
9262
+ borderLeft: `3px solid ${severity === "error" ? "#ef4444" : "#f59e0b"}`,
9263
+ paddingLeft: "0.5rem",
9264
+ marginLeft: "-0.5rem"
9265
+ }
9266
+ };
9267
+ };
9268
+ }, [errorLines]);
9246
9269
  const isFoldable = foldableProp ?? (language === "orb" || language === "json");
9247
9270
  const [collapsed, setCollapsed] = React90.useState(() => /* @__PURE__ */ new Set());
9248
9271
  const foldRegions = React90.useMemo(
@@ -9403,24 +9426,40 @@ var CodeBlock = React90__namespace.default.memo(
9403
9426
  }
9404
9427
  ),
9405
9428
  editable ? (
9406
- /* GAP-77: editable mode = transparent Textarea on top + Prism-highlighted
9407
- overlay underneath. The textarea is uncontrolled (defaultValue + key)
9408
- to avoid cursor jumps; the overlay reads `editableValue` which is
9409
- mirrored from the textarea via onChange. Both elements share IDENTICAL
9410
- font / line-height / padding so the highlighted text aligns with the
9411
- textarea's invisible glyphs.
9429
+ /* GAP-77 / GAP-82 / GAP-83: editable mode = transparent textarea on
9430
+ top of a Prism-highlighted SyntaxHighlighter overlay.
9431
+
9432
+ Layout: BOTH children are `position: absolute, inset: 0` so neither
9433
+ contributes to flow. The parent Box has `height: 100%` so it fills
9434
+ whatever container the consumer provides (the consumer is
9435
+ responsible for giving the parent a real height — usually via flex
9436
+ column with `minHeight: 0`).
9437
+
9438
+ Stacking: the overlay is FIRST in DOM order so it paints first
9439
+ (behind), the textarea is SECOND so it paints second (on top). No
9440
+ explicit z-index — DOM order alone determines stacking inside the
9441
+ parent's stacking context. The textarea has `color: transparent`
9442
+ plus `WebkitTextFillColor: transparent` (Safari) so its glyphs
9443
+ never paint, but the caret stays visible via `caretColor`.
9412
9444
 
9413
- Scroll sync: the overlay has `pointer-events: none` and the textarea
9414
- scrolls; `handleEditableScroll` keeps the overlay's scroll matched. */
9445
+ Scroll sync: textarea scrolls naturally; `handleEditableScroll`
9446
+ mirrors its scrollTop/scrollLeft onto the overlay div so the
9447
+ highlighted spans stay aligned with the textarea content.
9448
+
9449
+ Error highlights (GAP-80): `errorLines` prop accepts a Map of
9450
+ 1-based line numbers → severity. The overlay's SyntaxHighlighter
9451
+ uses `wrapLines` + `lineProps` to paint a colored background on
9452
+ those lines. */
9415
9453
  /* @__PURE__ */ jsxRuntime.jsxs(
9416
9454
  Box,
9417
9455
  {
9418
9456
  style: {
9419
9457
  position: "relative",
9420
- backgroundColor: "#1e1e1e",
9421
- borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
9458
+ height: "100%",
9422
9459
  minHeight: "160px",
9423
9460
  maxHeight,
9461
+ backgroundColor: "#1e1e1e",
9462
+ borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
9424
9463
  overflow: "hidden"
9425
9464
  },
9426
9465
  children: [
@@ -9431,10 +9470,12 @@ var CodeBlock = React90__namespace.default.memo(
9431
9470
  "aria-hidden": true,
9432
9471
  style: {
9433
9472
  position: "absolute",
9434
- inset: 0,
9473
+ top: 0,
9474
+ left: 0,
9475
+ width: "100%",
9476
+ height: "100%",
9435
9477
  overflow: "hidden",
9436
- pointerEvents: "none",
9437
- maxHeight
9478
+ pointerEvents: "none"
9438
9479
  },
9439
9480
  children: /* @__PURE__ */ jsxRuntime.jsx(
9440
9481
  SyntaxHighlighter__default.default,
@@ -9442,6 +9483,8 @@ var CodeBlock = React90__namespace.default.memo(
9442
9483
  PreTag: "div",
9443
9484
  language,
9444
9485
  style: activeStyle,
9486
+ wrapLines: errorLines && errorLines.size > 0,
9487
+ lineProps: errorLineProps,
9445
9488
  customStyle: {
9446
9489
  backgroundColor: "transparent",
9447
9490
  borderRadius: 0,
@@ -9449,7 +9492,6 @@ var CodeBlock = React90__namespace.default.memo(
9449
9492
  margin: 0,
9450
9493
  whiteSpace: "pre",
9451
9494
  minWidth: "100%",
9452
- minHeight: "160px",
9453
9495
  fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
9454
9496
  fontSize: "13px",
9455
9497
  lineHeight: "1.5"
@@ -9478,23 +9520,23 @@ var CodeBlock = React90__namespace.default.memo(
9478
9520
  onScroll: handleEditableScroll,
9479
9521
  spellCheck: false,
9480
9522
  style: {
9481
- position: "relative",
9482
- zIndex: 1,
9483
- fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
9484
- fontSize: "13px",
9485
- lineHeight: "1.5",
9486
- backgroundColor: "transparent",
9487
- color: "transparent",
9488
- caretColor: "#e6e6e6",
9489
- borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
9490
- border: "none",
9491
- padding: "1rem",
9492
- resize: "none",
9493
- minHeight: "160px",
9494
- maxHeight,
9523
+ position: "absolute",
9524
+ top: 0,
9525
+ left: 0,
9495
9526
  width: "100%",
9496
9527
  height: "100%",
9528
+ padding: "1rem",
9529
+ margin: 0,
9530
+ border: "none",
9497
9531
  outline: "none",
9532
+ resize: "none",
9533
+ backgroundColor: "transparent",
9534
+ color: "transparent",
9535
+ caretColor: "#e6e6e6",
9536
+ WebkitTextFillColor: "transparent",
9537
+ fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
9538
+ fontSize: "13px",
9539
+ lineHeight: "1.5",
9498
9540
  whiteSpace: "pre",
9499
9541
  overflowWrap: "normal",
9500
9542
  overflow: "auto"
@@ -9525,7 +9567,7 @@ var CodeBlock = React90__namespace.default.memo(
9525
9567
  )
9526
9568
  ] });
9527
9569
  },
9528
- (prev, next) => prev.language === next.language && prev.code === next.code && prev.showCopyButton === next.showCopyButton && prev.maxHeight === next.maxHeight && prev.foldable === next.foldable && prev.editable === next.editable && prev.onChange === next.onChange
9570
+ (prev, next) => prev.language === next.language && prev.code === next.code && prev.showCopyButton === next.showCopyButton && prev.maxHeight === next.maxHeight && prev.foldable === next.foldable && prev.editable === next.editable && prev.onChange === next.onChange && prev.errorLines === next.errorLines
9529
9571
  );
9530
9572
  CodeBlock.displayName = "CodeBlock";
9531
9573
  init_Typography();
@@ -9166,7 +9166,8 @@ var CodeBlock = React90__default.memo(
9166
9166
  foldable: foldableProp,
9167
9167
  className,
9168
9168
  editable = false,
9169
- onChange
9169
+ onChange,
9170
+ errorLines
9170
9171
  }) => {
9171
9172
  const code = typeof rawCode === "string" ? rawCode : String(rawCode ?? "");
9172
9173
  const isOrb = language === "orb";
@@ -9198,6 +9199,28 @@ var CodeBlock = React90__default.memo(
9198
9199
  ov.scrollLeft = ta.scrollLeft;
9199
9200
  }
9200
9201
  }, []);
9202
+ const errorLineProps = useMemo(() => {
9203
+ if (!errorLines || errorLines.size === 0) {
9204
+ return LINE_PROPS_FN;
9205
+ }
9206
+ return (lineNumber) => {
9207
+ const severity = errorLines.get(lineNumber);
9208
+ if (!severity) {
9209
+ return { "data-line": String(lineNumber - 1) };
9210
+ }
9211
+ return {
9212
+ "data-line": String(lineNumber - 1),
9213
+ style: {
9214
+ display: "block",
9215
+ backgroundColor: severity === "error" ? "rgba(248, 113, 113, 0.18)" : "rgba(251, 191, 36, 0.18)",
9216
+ // amber-400 @ 18%
9217
+ borderLeft: `3px solid ${severity === "error" ? "#ef4444" : "#f59e0b"}`,
9218
+ paddingLeft: "0.5rem",
9219
+ marginLeft: "-0.5rem"
9220
+ }
9221
+ };
9222
+ };
9223
+ }, [errorLines]);
9201
9224
  const isFoldable = foldableProp ?? (language === "orb" || language === "json");
9202
9225
  const [collapsed, setCollapsed] = useState(() => /* @__PURE__ */ new Set());
9203
9226
  const foldRegions = useMemo(
@@ -9358,24 +9381,40 @@ var CodeBlock = React90__default.memo(
9358
9381
  }
9359
9382
  ),
9360
9383
  editable ? (
9361
- /* GAP-77: editable mode = transparent Textarea on top + Prism-highlighted
9362
- overlay underneath. The textarea is uncontrolled (defaultValue + key)
9363
- to avoid cursor jumps; the overlay reads `editableValue` which is
9364
- mirrored from the textarea via onChange. Both elements share IDENTICAL
9365
- font / line-height / padding so the highlighted text aligns with the
9366
- textarea's invisible glyphs.
9384
+ /* GAP-77 / GAP-82 / GAP-83: editable mode = transparent textarea on
9385
+ top of a Prism-highlighted SyntaxHighlighter overlay.
9386
+
9387
+ Layout: BOTH children are `position: absolute, inset: 0` so neither
9388
+ contributes to flow. The parent Box has `height: 100%` so it fills
9389
+ whatever container the consumer provides (the consumer is
9390
+ responsible for giving the parent a real height — usually via flex
9391
+ column with `minHeight: 0`).
9392
+
9393
+ Stacking: the overlay is FIRST in DOM order so it paints first
9394
+ (behind), the textarea is SECOND so it paints second (on top). No
9395
+ explicit z-index — DOM order alone determines stacking inside the
9396
+ parent's stacking context. The textarea has `color: transparent`
9397
+ plus `WebkitTextFillColor: transparent` (Safari) so its glyphs
9398
+ never paint, but the caret stays visible via `caretColor`.
9367
9399
 
9368
- Scroll sync: the overlay has `pointer-events: none` and the textarea
9369
- scrolls; `handleEditableScroll` keeps the overlay's scroll matched. */
9400
+ Scroll sync: textarea scrolls naturally; `handleEditableScroll`
9401
+ mirrors its scrollTop/scrollLeft onto the overlay div so the
9402
+ highlighted spans stay aligned with the textarea content.
9403
+
9404
+ Error highlights (GAP-80): `errorLines` prop accepts a Map of
9405
+ 1-based line numbers → severity. The overlay's SyntaxHighlighter
9406
+ uses `wrapLines` + `lineProps` to paint a colored background on
9407
+ those lines. */
9370
9408
  /* @__PURE__ */ jsxs(
9371
9409
  Box,
9372
9410
  {
9373
9411
  style: {
9374
9412
  position: "relative",
9375
- backgroundColor: "#1e1e1e",
9376
- borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
9413
+ height: "100%",
9377
9414
  minHeight: "160px",
9378
9415
  maxHeight,
9416
+ backgroundColor: "#1e1e1e",
9417
+ borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
9379
9418
  overflow: "hidden"
9380
9419
  },
9381
9420
  children: [
@@ -9386,10 +9425,12 @@ var CodeBlock = React90__default.memo(
9386
9425
  "aria-hidden": true,
9387
9426
  style: {
9388
9427
  position: "absolute",
9389
- inset: 0,
9428
+ top: 0,
9429
+ left: 0,
9430
+ width: "100%",
9431
+ height: "100%",
9390
9432
  overflow: "hidden",
9391
- pointerEvents: "none",
9392
- maxHeight
9433
+ pointerEvents: "none"
9393
9434
  },
9394
9435
  children: /* @__PURE__ */ jsx(
9395
9436
  SyntaxHighlighter,
@@ -9397,6 +9438,8 @@ var CodeBlock = React90__default.memo(
9397
9438
  PreTag: "div",
9398
9439
  language,
9399
9440
  style: activeStyle,
9441
+ wrapLines: errorLines && errorLines.size > 0,
9442
+ lineProps: errorLineProps,
9400
9443
  customStyle: {
9401
9444
  backgroundColor: "transparent",
9402
9445
  borderRadius: 0,
@@ -9404,7 +9447,6 @@ var CodeBlock = React90__default.memo(
9404
9447
  margin: 0,
9405
9448
  whiteSpace: "pre",
9406
9449
  minWidth: "100%",
9407
- minHeight: "160px",
9408
9450
  fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
9409
9451
  fontSize: "13px",
9410
9452
  lineHeight: "1.5"
@@ -9433,23 +9475,23 @@ var CodeBlock = React90__default.memo(
9433
9475
  onScroll: handleEditableScroll,
9434
9476
  spellCheck: false,
9435
9477
  style: {
9436
- position: "relative",
9437
- zIndex: 1,
9438
- fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
9439
- fontSize: "13px",
9440
- lineHeight: "1.5",
9441
- backgroundColor: "transparent",
9442
- color: "transparent",
9443
- caretColor: "#e6e6e6",
9444
- borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
9445
- border: "none",
9446
- padding: "1rem",
9447
- resize: "none",
9448
- minHeight: "160px",
9449
- maxHeight,
9478
+ position: "absolute",
9479
+ top: 0,
9480
+ left: 0,
9450
9481
  width: "100%",
9451
9482
  height: "100%",
9483
+ padding: "1rem",
9484
+ margin: 0,
9485
+ border: "none",
9452
9486
  outline: "none",
9487
+ resize: "none",
9488
+ backgroundColor: "transparent",
9489
+ color: "transparent",
9490
+ caretColor: "#e6e6e6",
9491
+ WebkitTextFillColor: "transparent",
9492
+ fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
9493
+ fontSize: "13px",
9494
+ lineHeight: "1.5",
9453
9495
  whiteSpace: "pre",
9454
9496
  overflowWrap: "normal",
9455
9497
  overflow: "auto"
@@ -9480,7 +9522,7 @@ var CodeBlock = React90__default.memo(
9480
9522
  )
9481
9523
  ] });
9482
9524
  },
9483
- (prev, next) => prev.language === next.language && prev.code === next.code && prev.showCopyButton === next.showCopyButton && prev.maxHeight === next.maxHeight && prev.foldable === next.foldable && prev.editable === next.editable && prev.onChange === next.onChange
9525
+ (prev, next) => prev.language === next.language && prev.code === next.code && prev.showCopyButton === next.showCopyButton && prev.maxHeight === next.maxHeight && prev.foldable === next.foldable && prev.editable === next.editable && prev.onChange === next.onChange && prev.errorLines === next.errorLines
9484
9526
  );
9485
9527
  CodeBlock.displayName = "CodeBlock";
9486
9528
  init_Typography();
@@ -40,5 +40,13 @@ export interface CodeBlockProps {
40
40
  * Consumers should debounce + parse downstream — `CodeBlock` does not.
41
41
  */
42
42
  onChange?: (code: string) => void;
43
+ /**
44
+ * GAP-80: line-level error/warning highlights for editable mode.
45
+ * Map of 1-based line number → severity. The overlay paints a colored
46
+ * background on each line: error = red, warning = yellow. Pass undefined
47
+ * (default) to disable. The consumer is responsible for computing the
48
+ * path → line map from the schema + validation results.
49
+ */
50
+ errorLines?: Map<number, 'error' | 'warning'>;
43
51
  }
44
52
  export declare const CodeBlock: React.NamedExoticComponent<CodeBlockProps>;
@@ -4096,7 +4096,8 @@ var CodeBlock = React114__namespace.default.memo(
4096
4096
  foldable: foldableProp,
4097
4097
  className,
4098
4098
  editable = false,
4099
- onChange
4099
+ onChange,
4100
+ errorLines
4100
4101
  }) => {
4101
4102
  const code = typeof rawCode === "string" ? rawCode : String(rawCode ?? "");
4102
4103
  const isOrb = language === "orb";
@@ -4128,6 +4129,28 @@ var CodeBlock = React114__namespace.default.memo(
4128
4129
  ov.scrollLeft = ta.scrollLeft;
4129
4130
  }
4130
4131
  }, []);
4132
+ const errorLineProps = React114.useMemo(() => {
4133
+ if (!errorLines || errorLines.size === 0) {
4134
+ return LINE_PROPS_FN;
4135
+ }
4136
+ return (lineNumber) => {
4137
+ const severity = errorLines.get(lineNumber);
4138
+ if (!severity) {
4139
+ return { "data-line": String(lineNumber - 1) };
4140
+ }
4141
+ return {
4142
+ "data-line": String(lineNumber - 1),
4143
+ style: {
4144
+ display: "block",
4145
+ backgroundColor: severity === "error" ? "rgba(248, 113, 113, 0.18)" : "rgba(251, 191, 36, 0.18)",
4146
+ // amber-400 @ 18%
4147
+ borderLeft: `3px solid ${severity === "error" ? "#ef4444" : "#f59e0b"}`,
4148
+ paddingLeft: "0.5rem",
4149
+ marginLeft: "-0.5rem"
4150
+ }
4151
+ };
4152
+ };
4153
+ }, [errorLines]);
4131
4154
  const isFoldable = foldableProp ?? (language === "orb" || language === "json");
4132
4155
  const [collapsed, setCollapsed] = React114.useState(() => /* @__PURE__ */ new Set());
4133
4156
  const foldRegions = React114.useMemo(
@@ -4288,24 +4311,40 @@ var CodeBlock = React114__namespace.default.memo(
4288
4311
  }
4289
4312
  ),
4290
4313
  editable ? (
4291
- /* GAP-77: editable mode = transparent Textarea on top + Prism-highlighted
4292
- overlay underneath. The textarea is uncontrolled (defaultValue + key)
4293
- to avoid cursor jumps; the overlay reads `editableValue` which is
4294
- mirrored from the textarea via onChange. Both elements share IDENTICAL
4295
- font / line-height / padding so the highlighted text aligns with the
4296
- textarea's invisible glyphs.
4314
+ /* GAP-77 / GAP-82 / GAP-83: editable mode = transparent textarea on
4315
+ top of a Prism-highlighted SyntaxHighlighter overlay.
4316
+
4317
+ Layout: BOTH children are `position: absolute, inset: 0` so neither
4318
+ contributes to flow. The parent Box has `height: 100%` so it fills
4319
+ whatever container the consumer provides (the consumer is
4320
+ responsible for giving the parent a real height — usually via flex
4321
+ column with `minHeight: 0`).
4322
+
4323
+ Stacking: the overlay is FIRST in DOM order so it paints first
4324
+ (behind), the textarea is SECOND so it paints second (on top). No
4325
+ explicit z-index — DOM order alone determines stacking inside the
4326
+ parent's stacking context. The textarea has `color: transparent`
4327
+ plus `WebkitTextFillColor: transparent` (Safari) so its glyphs
4328
+ never paint, but the caret stays visible via `caretColor`.
4297
4329
 
4298
- Scroll sync: the overlay has `pointer-events: none` and the textarea
4299
- scrolls; `handleEditableScroll` keeps the overlay's scroll matched. */
4330
+ Scroll sync: textarea scrolls naturally; `handleEditableScroll`
4331
+ mirrors its scrollTop/scrollLeft onto the overlay div so the
4332
+ highlighted spans stay aligned with the textarea content.
4333
+
4334
+ Error highlights (GAP-80): `errorLines` prop accepts a Map of
4335
+ 1-based line numbers → severity. The overlay's SyntaxHighlighter
4336
+ uses `wrapLines` + `lineProps` to paint a colored background on
4337
+ those lines. */
4300
4338
  /* @__PURE__ */ jsxRuntime.jsxs(
4301
4339
  Box,
4302
4340
  {
4303
4341
  style: {
4304
4342
  position: "relative",
4305
- backgroundColor: "#1e1e1e",
4306
- borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
4343
+ height: "100%",
4307
4344
  minHeight: "160px",
4308
4345
  maxHeight,
4346
+ backgroundColor: "#1e1e1e",
4347
+ borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
4309
4348
  overflow: "hidden"
4310
4349
  },
4311
4350
  children: [
@@ -4316,10 +4355,12 @@ var CodeBlock = React114__namespace.default.memo(
4316
4355
  "aria-hidden": true,
4317
4356
  style: {
4318
4357
  position: "absolute",
4319
- inset: 0,
4358
+ top: 0,
4359
+ left: 0,
4360
+ width: "100%",
4361
+ height: "100%",
4320
4362
  overflow: "hidden",
4321
- pointerEvents: "none",
4322
- maxHeight
4363
+ pointerEvents: "none"
4323
4364
  },
4324
4365
  children: /* @__PURE__ */ jsxRuntime.jsx(
4325
4366
  SyntaxHighlighter__default.default,
@@ -4327,6 +4368,8 @@ var CodeBlock = React114__namespace.default.memo(
4327
4368
  PreTag: "div",
4328
4369
  language,
4329
4370
  style: activeStyle,
4371
+ wrapLines: errorLines && errorLines.size > 0,
4372
+ lineProps: errorLineProps,
4330
4373
  customStyle: {
4331
4374
  backgroundColor: "transparent",
4332
4375
  borderRadius: 0,
@@ -4334,7 +4377,6 @@ var CodeBlock = React114__namespace.default.memo(
4334
4377
  margin: 0,
4335
4378
  whiteSpace: "pre",
4336
4379
  minWidth: "100%",
4337
- minHeight: "160px",
4338
4380
  fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
4339
4381
  fontSize: "13px",
4340
4382
  lineHeight: "1.5"
@@ -4363,23 +4405,23 @@ var CodeBlock = React114__namespace.default.memo(
4363
4405
  onScroll: handleEditableScroll,
4364
4406
  spellCheck: false,
4365
4407
  style: {
4366
- position: "relative",
4367
- zIndex: 1,
4368
- fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
4369
- fontSize: "13px",
4370
- lineHeight: "1.5",
4371
- backgroundColor: "transparent",
4372
- color: "transparent",
4373
- caretColor: "#e6e6e6",
4374
- borderRadius: hasHeader ? "0 0 0.5rem 0.5rem" : "0.5rem",
4375
- border: "none",
4376
- padding: "1rem",
4377
- resize: "none",
4378
- minHeight: "160px",
4379
- maxHeight,
4408
+ position: "absolute",
4409
+ top: 0,
4410
+ left: 0,
4380
4411
  width: "100%",
4381
4412
  height: "100%",
4413
+ padding: "1rem",
4414
+ margin: 0,
4415
+ border: "none",
4382
4416
  outline: "none",
4417
+ resize: "none",
4418
+ backgroundColor: "transparent",
4419
+ color: "transparent",
4420
+ caretColor: "#e6e6e6",
4421
+ WebkitTextFillColor: "transparent",
4422
+ fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
4423
+ fontSize: "13px",
4424
+ lineHeight: "1.5",
4383
4425
  whiteSpace: "pre",
4384
4426
  overflowWrap: "normal",
4385
4427
  overflow: "auto"
@@ -4410,7 +4452,7 @@ var CodeBlock = React114__namespace.default.memo(
4410
4452
  )
4411
4453
  ] });
4412
4454
  },
4413
- (prev, next) => prev.language === next.language && prev.code === next.code && prev.showCopyButton === next.showCopyButton && prev.maxHeight === next.maxHeight && prev.foldable === next.foldable && prev.editable === next.editable && prev.onChange === next.onChange
4455
+ (prev, next) => prev.language === next.language && prev.code === next.code && prev.showCopyButton === next.showCopyButton && prev.maxHeight === next.maxHeight && prev.foldable === next.foldable && prev.editable === next.editable && prev.onChange === next.onChange && prev.errorLines === next.errorLines
4414
4456
  );
4415
4457
  CodeBlock.displayName = "CodeBlock";
4416
4458