@cascivo/editor 0.18.0 → 1.1.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/README.md +2 -2
- package/dist/index.d.ts +17 -0
- package/dist/index.js +10 -1515
- package/dist/node/index.js +10 -1516
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!-- generated by scripts/readme/generate.ts — edit readme.body.md, not this file -->
|
|
2
2
|
|
|
3
3
|
<div align="center">
|
|
4
|
-
<a href="https://cascivo.com"><img src="https://cascivo.com/
|
|
4
|
+
<a href="https://cascivo.com"><img src="https://cascivo.com/logo-mark-img-accent.svg" width="72" height="72" alt="cascivo logo"></a>
|
|
5
5
|
<h1>@cascivo/editor</h1>
|
|
6
6
|
<p><strong>Lightweight CSS-native code editor — native textarea overlay + owned zero-dependency tokenizer</strong></p>
|
|
7
7
|
|
|
@@ -120,4 +120,4 @@ pnpm add @cascivo/editor
|
|
|
120
120
|
|
|
121
121
|
[cascivo.com](https://cascivo.com) · [Docs](https://cascivo.com/docs) · [Storybook](https://storybook.cascivo.com) · [GitHub](https://github.com/cascivo/cascivo) · AI agents: read [`llms.txt`](https://cascivo.com/llms.txt) (install steps + component index, plain text) or use [`@cascivo/mcp`](https://github.com/cascivo/cascivo/tree/main/packages/mcp) and [`registry.json`](https://github.com/cascivo/cascivo/blob/main/registry.json) · MIT
|
|
122
122
|
|
|
123
|
-
<div align="center"><a href="https://cascivo.com"><img src="https://cascivo.com/
|
|
123
|
+
<div align="center"><a href="https://cascivo.com"><img src="https://cascivo.com/logo-mark-img.svg" width="28" height="28" alt="cascivo"></a></div>
|
package/dist/index.d.ts
CHANGED
|
@@ -254,6 +254,14 @@ interface CodeEditorProps extends Omit<TextareaHTMLAttributes<HTMLTextAreaElemen
|
|
|
254
254
|
virtualize?: boolean;
|
|
255
255
|
/** Accessible label for the editor (defaults to the i18n "Code editor"). */
|
|
256
256
|
label?: string;
|
|
257
|
+
/**
|
|
258
|
+
* Alias of `label` — the same invisible accessible name under the catalog's own spelling.
|
|
259
|
+
*
|
|
260
|
+
* `ariaLabel` is what the catalog calls a name nothing paints, so it is the guess an agent
|
|
261
|
+
* makes after reading one other component (2026-08-21 report item 1). This component
|
|
262
|
+
* predates the convention and shipped `label`; both work and neither is deprecated.
|
|
263
|
+
*/
|
|
264
|
+
ariaLabel?: string;
|
|
257
265
|
/** Called with the current value on `Mod-S` (the browser save dialog is suppressed). */
|
|
258
266
|
onSave?: (value: string) => void;
|
|
259
267
|
/** Extra key bindings, merged over the built-ins (user wins on the same chord). */
|
|
@@ -290,6 +298,14 @@ interface HighlightProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'
|
|
|
290
298
|
tabSize?: number;
|
|
291
299
|
/** Accessible label for the read-only code block. */
|
|
292
300
|
label?: string;
|
|
301
|
+
/**
|
|
302
|
+
* Alias of `label` — the same invisible accessible name under the catalog's own spelling.
|
|
303
|
+
*
|
|
304
|
+
* `ariaLabel` is what the catalog calls a name nothing paints, so it is the guess an agent
|
|
305
|
+
* makes after reading one other component (2026-08-21 report item 1). This component
|
|
306
|
+
* predates the convention and shipped `label`; both work and neither is deprecated.
|
|
307
|
+
*/
|
|
308
|
+
ariaLabel?: string;
|
|
293
309
|
/** Ref to the scrollable `<pre>` (used by `CodeEditor` for scroll-sync). */
|
|
294
310
|
preRef?: Ref<HTMLPreElement>;
|
|
295
311
|
/** Ref to the gutter column (used by `CodeEditor` for scroll-sync). */
|
|
@@ -307,6 +323,7 @@ declare function Highlight({
|
|
|
307
323
|
wrap,
|
|
308
324
|
tabSize,
|
|
309
325
|
label,
|
|
326
|
+
ariaLabel,
|
|
310
327
|
className,
|
|
311
328
|
preRef,
|
|
312
329
|
gutterRef,
|