@ixo/editor 1.21.0 → 1.23.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/dist/{chunk-XEZXD5ZV.mjs → chunk-22UP3RB4.mjs} +954 -566
- package/dist/chunk-22UP3RB4.mjs.map +1 -0
- package/dist/index.d.ts +119 -25
- package/dist/index.mjs +3 -1
- package/dist/mantine/index.d.ts +1 -1
- package/dist/mantine/index.mjs +3 -1
- package/package.json +1 -1
- package/dist/chunk-XEZXD5ZV.mjs.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -991,6 +991,68 @@ interface GetClaimsPerUserAddressParams {
|
|
|
991
991
|
collectionId: string;
|
|
992
992
|
userAddress: string;
|
|
993
993
|
}
|
|
994
|
+
interface FAQItem {
|
|
995
|
+
question: string;
|
|
996
|
+
answer: string;
|
|
997
|
+
}
|
|
998
|
+
interface ContactInfo {
|
|
999
|
+
email: string;
|
|
1000
|
+
location: string;
|
|
1001
|
+
socialLinks: string[];
|
|
1002
|
+
website: string;
|
|
1003
|
+
}
|
|
1004
|
+
interface Relationships {
|
|
1005
|
+
funders?: string[];
|
|
1006
|
+
memberOf?: string[];
|
|
1007
|
+
partners?: string[];
|
|
1008
|
+
}
|
|
1009
|
+
interface LogoUrl {
|
|
1010
|
+
alt: string;
|
|
1011
|
+
url: string;
|
|
1012
|
+
}
|
|
1013
|
+
interface AdditionalProperties {
|
|
1014
|
+
content_hashes?: Record<string, string>;
|
|
1015
|
+
content_summaries?: Record<string, string>;
|
|
1016
|
+
fetch_errors?: Array<{
|
|
1017
|
+
error: string;
|
|
1018
|
+
url: string;
|
|
1019
|
+
}>;
|
|
1020
|
+
last_fetch_date?: string;
|
|
1021
|
+
}
|
|
1022
|
+
interface Coordinates {
|
|
1023
|
+
type: string;
|
|
1024
|
+
coordinates: [number, number];
|
|
1025
|
+
}
|
|
1026
|
+
interface DomainCard {
|
|
1027
|
+
additional_properties?: AdditionalProperties;
|
|
1028
|
+
address?: string;
|
|
1029
|
+
alternate_names?: string[];
|
|
1030
|
+
area_served?: string;
|
|
1031
|
+
categories?: string[];
|
|
1032
|
+
contact?: ContactInfo;
|
|
1033
|
+
coordinates?: Coordinates;
|
|
1034
|
+
credential_type?: string[];
|
|
1035
|
+
description?: string;
|
|
1036
|
+
entity_type?: string[];
|
|
1037
|
+
faq?: FAQItem[];
|
|
1038
|
+
id: string;
|
|
1039
|
+
image_urls?: Array<Record<string, any>>;
|
|
1040
|
+
indexed_at?: string;
|
|
1041
|
+
issuer?: string;
|
|
1042
|
+
keywords?: string[];
|
|
1043
|
+
knows_about?: string[];
|
|
1044
|
+
location?: string;
|
|
1045
|
+
logo_url?: LogoUrl;
|
|
1046
|
+
name: string;
|
|
1047
|
+
overview?: string;
|
|
1048
|
+
relationships?: Relationships;
|
|
1049
|
+
same_as?: string[];
|
|
1050
|
+
schema_id?: string;
|
|
1051
|
+
summary?: string;
|
|
1052
|
+
updated_at?: string;
|
|
1053
|
+
url?: string;
|
|
1054
|
+
valid_from?: string;
|
|
1055
|
+
}
|
|
994
1056
|
interface AssetDetails extends Asset {
|
|
995
1057
|
actionSections: SelectionActionSection[];
|
|
996
1058
|
}
|
|
@@ -1089,6 +1151,7 @@ interface BlocknoteHandlers {
|
|
|
1089
1151
|
vote: ({ proposalId, rationale, vote, proposalContractAddress }: VoteParams) => Promise<void>;
|
|
1090
1152
|
createProposal: (params: CreateProposalParams) => Promise<string>;
|
|
1091
1153
|
getEntity: (did: string) => Promise<EntityResponse$1>;
|
|
1154
|
+
getDomainCard: () => Promise<DomainCard>;
|
|
1092
1155
|
getAssets: (collectionDid: string, page: number, ownerAddress?: string) => Promise<{
|
|
1093
1156
|
data: Asset[];
|
|
1094
1157
|
totalCount: number;
|
|
@@ -1239,6 +1302,14 @@ interface BlocknoteHandlers {
|
|
|
1239
1302
|
claimIds?: string[];
|
|
1240
1303
|
maxAmounts?: Coin[];
|
|
1241
1304
|
}) => Promise<void>;
|
|
1305
|
+
publicFileUpload: (file: File) => Promise<{
|
|
1306
|
+
encrypted: string;
|
|
1307
|
+
cid: string;
|
|
1308
|
+
proof: string;
|
|
1309
|
+
serviceEndpoint: string;
|
|
1310
|
+
url: string;
|
|
1311
|
+
mxc: string;
|
|
1312
|
+
}>;
|
|
1242
1313
|
}
|
|
1243
1314
|
type DocType = 'template' | 'page' | 'flow';
|
|
1244
1315
|
interface BlocknoteContextValue {
|
|
@@ -1278,9 +1349,6 @@ interface SelectionActionSection {
|
|
|
1278
1349
|
actions: SelectionActionItem[];
|
|
1279
1350
|
}
|
|
1280
1351
|
|
|
1281
|
-
interface OverviewBlockSettings {
|
|
1282
|
-
did: string;
|
|
1283
|
-
}
|
|
1284
1352
|
interface OverviewBlockProps {
|
|
1285
1353
|
block: any;
|
|
1286
1354
|
editor: any;
|
|
@@ -1288,20 +1356,12 @@ interface OverviewBlockProps {
|
|
|
1288
1356
|
declare const OverviewBlock: {
|
|
1289
1357
|
config: {
|
|
1290
1358
|
readonly type: "overview";
|
|
1291
|
-
readonly propSchema: {
|
|
1292
|
-
readonly did: {
|
|
1293
|
-
readonly default: "";
|
|
1294
|
-
};
|
|
1295
|
-
};
|
|
1359
|
+
readonly propSchema: {};
|
|
1296
1360
|
readonly content: "none";
|
|
1297
1361
|
};
|
|
1298
1362
|
implementation: _blocknote_core.TiptapBlockImplementation<{
|
|
1299
1363
|
readonly type: "overview";
|
|
1300
|
-
readonly propSchema: {
|
|
1301
|
-
readonly did: {
|
|
1302
|
-
readonly default: "";
|
|
1303
|
-
};
|
|
1304
|
-
};
|
|
1364
|
+
readonly propSchema: {};
|
|
1305
1365
|
readonly content: "none";
|
|
1306
1366
|
}, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
|
|
1307
1367
|
};
|
|
@@ -1645,20 +1705,12 @@ declare const blockSpecs: {
|
|
|
1645
1705
|
overview: {
|
|
1646
1706
|
config: {
|
|
1647
1707
|
readonly type: "overview";
|
|
1648
|
-
readonly propSchema: {
|
|
1649
|
-
readonly did: {
|
|
1650
|
-
readonly default: "";
|
|
1651
|
-
};
|
|
1652
|
-
};
|
|
1708
|
+
readonly propSchema: {};
|
|
1653
1709
|
readonly content: "none";
|
|
1654
1710
|
};
|
|
1655
1711
|
implementation: _blocknote_core.TiptapBlockImplementation<{
|
|
1656
1712
|
readonly type: "overview";
|
|
1657
|
-
readonly propSchema: {
|
|
1658
|
-
readonly did: {
|
|
1659
|
-
readonly default: "";
|
|
1660
|
-
};
|
|
1661
|
-
};
|
|
1713
|
+
readonly propSchema: {};
|
|
1662
1714
|
readonly content: "none";
|
|
1663
1715
|
}, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
|
|
1664
1716
|
};
|
|
@@ -2143,6 +2195,17 @@ interface FlowMetadata {
|
|
|
2143
2195
|
createdAt: string;
|
|
2144
2196
|
createdBy: string;
|
|
2145
2197
|
}
|
|
2198
|
+
/**
|
|
2199
|
+
* Image data returned from publicFileUpload handler
|
|
2200
|
+
*/
|
|
2201
|
+
interface ImageData {
|
|
2202
|
+
url: string;
|
|
2203
|
+
cid: string;
|
|
2204
|
+
encrypted: string;
|
|
2205
|
+
proof: string;
|
|
2206
|
+
serviceEndpoint: string;
|
|
2207
|
+
mxc: string;
|
|
2208
|
+
}
|
|
2146
2209
|
/**
|
|
2147
2210
|
* Extended editor type that augments BlockNoteEditor with IXO-specific properties
|
|
2148
2211
|
* and methods. This type should be used throughout the application instead of
|
|
@@ -2209,6 +2272,26 @@ interface IxoEditorType<BSchema extends IxoBlockSchema = IxoBlockSchema, ISchema
|
|
|
2209
2272
|
* @returns Array of flow blocks
|
|
2210
2273
|
*/
|
|
2211
2274
|
getFlow?: () => any[];
|
|
2275
|
+
/**
|
|
2276
|
+
* Set the document cover image
|
|
2277
|
+
* @param imageData - Image data from publicFileUpload handler, or undefined to remove
|
|
2278
|
+
*/
|
|
2279
|
+
setCoverImage?: (imageData?: ImageData) => void;
|
|
2280
|
+
/**
|
|
2281
|
+
* Get the document cover image
|
|
2282
|
+
* @returns Image data or undefined if not set
|
|
2283
|
+
*/
|
|
2284
|
+
getCoverImage?: () => ImageData | undefined;
|
|
2285
|
+
/**
|
|
2286
|
+
* Set the document logo
|
|
2287
|
+
* @param imageData - Image data from publicFileUpload handler, or undefined to remove
|
|
2288
|
+
*/
|
|
2289
|
+
setLogo?: (imageData?: ImageData) => void;
|
|
2290
|
+
/**
|
|
2291
|
+
* Get the document logo
|
|
2292
|
+
* @returns Image data or undefined if not set
|
|
2293
|
+
*/
|
|
2294
|
+
getLogo?: () => ImageData | undefined;
|
|
2212
2295
|
}
|
|
2213
2296
|
/**
|
|
2214
2297
|
* Re-map BlockNote renderer props to use IxoEditorType instead of BlockNoteEditor.
|
|
@@ -2360,11 +2443,22 @@ interface IxoEditorProps {
|
|
|
2360
2443
|
handlers?: BlocknoteHandlers;
|
|
2361
2444
|
blockRequirements?: BlockRequirements;
|
|
2362
2445
|
isPanelVisible?: boolean;
|
|
2446
|
+
coverImageUrl?: string;
|
|
2447
|
+
logoUrl?: string;
|
|
2363
2448
|
}
|
|
2364
2449
|
/**
|
|
2365
2450
|
* IxoEditor component - A customized BlockNote editor for IXO (Mantine UI)
|
|
2366
2451
|
*/
|
|
2367
|
-
declare function IxoEditor({ editor, editable, className, onChange, onSelectionChange, children, mantineTheme, handlers, blockRequirements, isPanelVisible, }: IxoEditorProps): React.ReactElement | null;
|
|
2452
|
+
declare function IxoEditor({ editor, editable, className, onChange, onSelectionChange, children, mantineTheme, handlers, blockRequirements, isPanelVisible, coverImageUrl, logoUrl, }: IxoEditorProps): React.ReactElement | null;
|
|
2453
|
+
|
|
2454
|
+
interface CoverImageProps {
|
|
2455
|
+
coverImageUrl?: string;
|
|
2456
|
+
logoUrl?: string;
|
|
2457
|
+
}
|
|
2458
|
+
/**
|
|
2459
|
+
* CoverImage component - Notion-like cover image with logo
|
|
2460
|
+
*/
|
|
2461
|
+
declare function CoverImage({ coverImageUrl, logoUrl }: CoverImageProps): React.ReactElement | null;
|
|
2368
2462
|
|
|
2369
2463
|
/**
|
|
2370
2464
|
* GraphQL queries and types for IXO network
|
|
@@ -2423,4 +2517,4 @@ declare class GraphQLClient {
|
|
|
2423
2517
|
}
|
|
2424
2518
|
declare const ixoGraphQLClient: GraphQLClient;
|
|
2425
2519
|
|
|
2426
|
-
export { type Addr, type ApiRequestBlockProps, ApiRequestBlockSpec, AuthzExecActionTypes, type BlockRequirements, type BlocknoteContextValue, type BlocknoteHandlers, BlocknoteProvider, type CheckboxBlockProps, CheckboxBlockSpec, type CosmosMsgForEmpty, type Entity, type EntityResponse, type EntityVariables, type Expiration, GraphQLClient, type GraphQLRequest, type GraphQLResponse, type HttpMethod, type IxoCollaborativeEditorOptions, type IxoCollaborativeUser, IxoEditor, type IxoEditorConfig, type IxoEditorOptions, type IxoEditorProps, type IxoEditorTheme, type KeyValuePair, type ListBlockProps, type ListBlockSettings, ListBlockSpec, OverviewBlock, type OverviewBlockProps, type
|
|
2520
|
+
export { type Addr, type ApiRequestBlockProps, ApiRequestBlockSpec, AuthzExecActionTypes, type BlockRequirements, type BlocknoteContextValue, type BlocknoteHandlers, BlocknoteProvider, type CheckboxBlockProps, CheckboxBlockSpec, type CosmosMsgForEmpty, CoverImage, type CoverImageProps, type Entity, type EntityResponse, type EntityVariables, type Expiration, GraphQLClient, type GraphQLRequest, type GraphQLResponse, type HttpMethod, type IxoCollaborativeEditorOptions, type IxoCollaborativeUser, IxoEditor, type IxoEditorConfig, type IxoEditorOptions, type IxoEditorProps, type IxoEditorTheme, type KeyValuePair, type ListBlockProps, type ListBlockSettings, ListBlockSpec, OverviewBlock, type OverviewBlockProps, type ProposalAction, type ProposalBlockProps, ProposalBlockSpec, type ProposalResponse, type SingleChoiceProposal, StakeType, StakeType as StakeTypeValue, type Status, type Threshold, type Timestamp, type Uint128, type User, ValidatorActionType, type Vote, type VoteInfo, type VoteResponse, type Votes, blockSpecs, getEntity, getExtraSlashMenuItems, ixoGraphQLClient, useBlocknoteContext, useBlocknoteHandlers, useCreateCollaborativeIxoEditor, useCreateIxoEditor };
|
package/dist/index.mjs
CHANGED
|
@@ -3,6 +3,7 @@ import {
|
|
|
3
3
|
AuthzExecActionTypes,
|
|
4
4
|
BlocknoteProvider,
|
|
5
5
|
CheckboxBlockSpec,
|
|
6
|
+
CoverImage,
|
|
6
7
|
GraphQLClient,
|
|
7
8
|
IxoEditor,
|
|
8
9
|
ListBlockSpec,
|
|
@@ -18,12 +19,13 @@ import {
|
|
|
18
19
|
useBlocknoteHandlers,
|
|
19
20
|
useCreateCollaborativeIxoEditor,
|
|
20
21
|
useCreateIxoEditor
|
|
21
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-22UP3RB4.mjs";
|
|
22
23
|
export {
|
|
23
24
|
ApiRequestBlockSpec,
|
|
24
25
|
AuthzExecActionTypes,
|
|
25
26
|
BlocknoteProvider,
|
|
26
27
|
CheckboxBlockSpec,
|
|
28
|
+
CoverImage,
|
|
27
29
|
GraphQLClient,
|
|
28
30
|
IxoEditor,
|
|
29
31
|
ListBlockSpec,
|
package/dist/mantine/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { Addr, ApiRequestBlockProps, ApiRequestBlockSpec, AuthzExecActionTypes, BlockRequirements, BlocknoteContextValue, BlocknoteHandlers, BlocknoteProvider, CheckboxBlockProps, CheckboxBlockSpec, CosmosMsgForEmpty, Entity, EntityResponse, EntityVariables, Expiration, GraphQLClient, GraphQLRequest, GraphQLResponse, HttpMethod, IxoCollaborativeEditorOptions, IxoCollaborativeUser, IxoEditor, IxoEditorConfig, IxoEditorOptions, IxoEditorProps, IxoEditorTheme, KeyValuePair, ListBlockProps, ListBlockSettings, ListBlockSpec, OverviewBlock, OverviewBlockProps,
|
|
1
|
+
export { Addr, ApiRequestBlockProps, ApiRequestBlockSpec, AuthzExecActionTypes, BlockRequirements, BlocknoteContextValue, BlocknoteHandlers, BlocknoteProvider, CheckboxBlockProps, CheckboxBlockSpec, CosmosMsgForEmpty, CoverImage, CoverImageProps, Entity, EntityResponse, EntityVariables, Expiration, GraphQLClient, GraphQLRequest, GraphQLResponse, HttpMethod, IxoCollaborativeEditorOptions, IxoCollaborativeUser, IxoEditor, IxoEditorConfig, IxoEditorOptions, IxoEditorProps, IxoEditorTheme, KeyValuePair, ListBlockProps, ListBlockSettings, ListBlockSpec, OverviewBlock, OverviewBlockProps, ProposalAction, ProposalBlockProps, ProposalBlockSpec, ProposalResponse, SingleChoiceProposal, StakeType, StakeType as StakeTypeValue, Status, Threshold, Timestamp, Uint128, User, ValidatorActionType, Vote, VoteInfo, VoteResponse, Votes, blockSpecs, getEntity, getExtraSlashMenuItems, ixoGraphQLClient, useBlocknoteContext, useBlocknoteHandlers, useCreateCollaborativeIxoEditor, useCreateIxoEditor } from '../index.mjs';
|
|
2
2
|
import * as zustand from 'zustand';
|
|
3
3
|
export { Block, BlockNoteEditor, BlockNoteSchema, DefaultBlockSchema, DefaultInlineContentSchema, DefaultStyleSchema, PartialBlock } from '@blocknote/core';
|
|
4
4
|
import 'matrix-js-sdk';
|
package/dist/mantine/index.mjs
CHANGED
|
@@ -3,6 +3,7 @@ import {
|
|
|
3
3
|
AuthzExecActionTypes,
|
|
4
4
|
BlocknoteProvider,
|
|
5
5
|
CheckboxBlockSpec,
|
|
6
|
+
CoverImage,
|
|
6
7
|
GraphQLClient,
|
|
7
8
|
IxoEditor,
|
|
8
9
|
ListBlockSpec,
|
|
@@ -20,12 +21,13 @@ import {
|
|
|
20
21
|
useCreateIxoEditor,
|
|
21
22
|
usePanel,
|
|
22
23
|
usePanelStore
|
|
23
|
-
} from "../chunk-
|
|
24
|
+
} from "../chunk-22UP3RB4.mjs";
|
|
24
25
|
export {
|
|
25
26
|
ApiRequestBlockSpec,
|
|
26
27
|
AuthzExecActionTypes,
|
|
27
28
|
BlocknoteProvider,
|
|
28
29
|
CheckboxBlockSpec,
|
|
30
|
+
CoverImage,
|
|
29
31
|
GraphQLClient,
|
|
30
32
|
IxoEditor,
|
|
31
33
|
ListBlockSpec,
|