Fixes to #628 to help it pass typescript's type checking (#634)

* My best interpretation of what the typings should look like after merge of #464

* Apply variable name changes as per Juice10 review

Co-authored-by: Justin Halsall <Juice10@users.noreply.github.com>

* fix types

Co-authored-by: Eoghan Murray <eoghan@getthere.ie>
This commit is contained in:
Justin Halsall
2026-04-01 12:00:00 +08:00
committed by GitHub
parent 5de802912a
commit fd76a7bcd8
4 changed files with 44 additions and 22 deletions

8
typings/types.d.ts vendored
View File

@@ -211,16 +211,20 @@ export declare type textMutation = {
id: number;
value: string | null;
};
export declare type styleAttributeValue = {
[key: string]: styleValueWithPriority | string | false;
};
export declare type styleValueWithPriority = [string, string];
export declare type attributeCursor = {
node: Node;
attributes: {
[key: string]: string | null;
[key: string]: string | styleAttributeValue | null;
};
};
export declare type attributeMutation = {
id: number;
attributes: {
[key: string]: string | null;
[key: string]: string | styleAttributeValue | null;
};
};
export declare type removedNodeMutation = {