@duskmoon-dev/components 0.5.7 → 0.6.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 +85 -2
- package/dist/chunk-b1jnq16e.js +727 -0
- package/dist/chunk-kg46s2vk.js +238 -0
- package/dist/components/chat/Chat.types.d.ts +8 -0
- package/dist/components/chat/ChatAuthoritativeQueue.d.ts +4 -0
- package/dist/components/chat/ChatSessionComposer.d.ts +4 -0
- package/dist/components/chat/ChatSessionComposer.types.d.ts +42 -0
- package/dist/components/chat/ComposerAttachment.types.d.ts +80 -0
- package/dist/components/chat/ComposerDraft.types.d.ts +89 -0
- package/dist/components/chat/ComposerProvider.types.d.ts +66 -0
- package/dist/components/chat/ComposerQueue.types.d.ts +64 -0
- package/dist/components/chat/ComposerSession.types.d.ts +78 -0
- package/dist/components/chat/ComposerSettings.d.ts +4 -0
- package/dist/components/chat/composer/CompletionList.d.ts +10 -0
- package/dist/components/chat/composer/ComposerShell.d.ts +19 -4
- package/dist/components/chat/composer/DraftLifecycle.d.ts +17 -0
- package/dist/components/chat/composer/EditorAdapter.types.d.ts +36 -0
- package/dist/components/chat/composer/PlainEditor.d.ts +2 -0
- package/dist/components/chat/composer/PlainSemanticEditor.d.ts +6 -0
- package/dist/components/chat/composer/PreservedDraft.d.ts +7 -0
- package/dist/components/chat/composer/SemanticComposer.d.ts +10 -0
- package/dist/components/chat/composer/attachments.d.ts +4 -0
- package/dist/components/chat/composer/document.d.ts +3 -1
- package/dist/components/chat/composer/drafts.d.ts +2 -0
- package/dist/components/chat/composer/providers.d.ts +40 -0
- package/dist/components/chat/composer/session.d.ts +30 -0
- package/dist/components/chat/composer/useComposerAttachments.d.ts +3 -0
- package/dist/components/chat/composer/useComposerDraft.d.ts +3 -0
- package/dist/components/chat/composer/useComposerProviders.d.ts +7 -0
- package/dist/components/chat/composer/useComposerSession.d.ts +16 -0
- package/dist/components/chat/index.d.ts +17 -0
- package/dist/components/chat/index.js +4386 -1074
- package/dist/components/chat/rich/LexicalEditor.d.ts +10 -0
- package/dist/components/chat/rich/RichChatComposer.d.ts +4 -0
- package/dist/components/chat/rich/index.d.ts +2 -0
- package/dist/components/chat/rich/index.js +3437 -0
- package/dist/components/chat/rich/nodes.d.ts +49 -0
- package/dist/generated/version.d.ts +1 -1
- package/dist/index.js +7107 -4252
- package/dist/infrastructure.js +1 -1
- package/package.json +25 -4
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { TextNode, type NodeKey, type SerializedTextNode } from "lexical";
|
|
2
|
+
import type { ComposerCommand, ComposerDocument, ComposerQuoteNode, ComposerReferenceNode } from "../Composer.types";
|
|
3
|
+
import type { ComposerProviderSelection, ComposerProviderSelectionEffect } from "../ComposerProvider.types";
|
|
4
|
+
type Atom = {
|
|
5
|
+
readonly kind: "reference";
|
|
6
|
+
readonly value: ComposerReferenceNode;
|
|
7
|
+
} | {
|
|
8
|
+
readonly kind: "quote";
|
|
9
|
+
readonly value: ComposerQuoteNode;
|
|
10
|
+
} | {
|
|
11
|
+
readonly kind: "command";
|
|
12
|
+
readonly value: ComposerCommand;
|
|
13
|
+
readonly source: string;
|
|
14
|
+
};
|
|
15
|
+
type SerializedAtom = SerializedTextNode & {
|
|
16
|
+
readonly atom: Atom;
|
|
17
|
+
};
|
|
18
|
+
/** Private Lexical token. Portable types contain no editor classes, keys or JSON. */
|
|
19
|
+
export declare class ComposerAtomNode extends TextNode {
|
|
20
|
+
readonly __atom: Atom;
|
|
21
|
+
static getType(): string;
|
|
22
|
+
static clone(node: ComposerAtomNode): ComposerAtomNode;
|
|
23
|
+
static importJSON(serialized: SerializedAtom): ComposerAtomNode;
|
|
24
|
+
constructor(atom: Atom, key?: NodeKey);
|
|
25
|
+
exportJSON(): SerializedAtom;
|
|
26
|
+
createDOM(): HTMLElement;
|
|
27
|
+
updateDOM(previous: this): boolean;
|
|
28
|
+
getDOMSlot(element: HTMLElement): import("lexical").DOMSlot<HTMLElement>;
|
|
29
|
+
isTextEntity(): boolean;
|
|
30
|
+
canInsertTextBefore(): boolean;
|
|
31
|
+
canInsertTextAfter(): boolean;
|
|
32
|
+
}
|
|
33
|
+
/** Explicit host replacements preserve occurrence IDs and start a new history policy. */
|
|
34
|
+
export declare function $replaceComposerDocument(value: ComposerDocument): void;
|
|
35
|
+
export declare function $exportComposerDocument(): ComposerDocument;
|
|
36
|
+
/** Caret/range data stays local to this adapter and is relative to semantic text. */
|
|
37
|
+
export declare function $composerSelection(): ComposerProviderSelection | null;
|
|
38
|
+
/** A command only has meaning in the first position; moving it elsewhere leaves source text. */
|
|
39
|
+
export declare function $normalizeComposerCommands(): void;
|
|
40
|
+
/** Pasted occurrences are always new. Programmatic insertion also avoids existing IDs. */
|
|
41
|
+
export declare function $insertComposerDocument(value: ComposerDocument, fresh?: boolean): void;
|
|
42
|
+
export declare function $insertComposerReference(reference: ComposerReferenceNode): void;
|
|
43
|
+
export declare function $insertComposerQuote(quote: ComposerQuoteNode): void;
|
|
44
|
+
export declare function $claimComposerCommand(command: ComposerCommand, source: string): void;
|
|
45
|
+
/** Validates both the live caret and captured semantic range before one editor transaction. */
|
|
46
|
+
export declare function $applyComposerProvider(effect: ComposerProviderSelectionEffect): boolean;
|
|
47
|
+
/** Copy the semantic range without splitting/mutating the live editor merely to copy. */
|
|
48
|
+
export declare function $composerClipboardDocument(): ComposerDocument | null;
|
|
49
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.
|
|
1
|
+
export declare const version = "0.6.0";
|