@collabchron/notiq 1.1.3 → 1.1.4
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/index.d.mts +145 -0
- package/dist/index.d.ts +145 -0
- package/dist/index.js +10 -12
- package/dist/index.mjs +10 -12
- package/dist/styles/fonts/KaTeX_AMS-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_AMS-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_AMS-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Caligraphic-Bold.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Caligraphic-Bold.woff +0 -0
- package/dist/styles/fonts/KaTeX_Caligraphic-Bold.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Caligraphic-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Caligraphic-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Caligraphic-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Fraktur-Bold.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Fraktur-Bold.woff +0 -0
- package/dist/styles/fonts/KaTeX_Fraktur-Bold.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Fraktur-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Fraktur-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Fraktur-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Main-Bold.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Main-Bold.woff +0 -0
- package/dist/styles/fonts/KaTeX_Main-Bold.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Main-BoldItalic.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Main-BoldItalic.woff +0 -0
- package/dist/styles/fonts/KaTeX_Main-BoldItalic.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Main-Italic.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Main-Italic.woff +0 -0
- package/dist/styles/fonts/KaTeX_Main-Italic.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Main-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Main-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Main-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Math-BoldItalic.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Math-BoldItalic.woff +0 -0
- package/dist/styles/fonts/KaTeX_Math-BoldItalic.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Math-Italic.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Math-Italic.woff +0 -0
- package/dist/styles/fonts/KaTeX_Math-Italic.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Bold.ttf +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Bold.woff +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Bold.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Italic.ttf +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Italic.woff +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Italic.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_SansSerif-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Script-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Script-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Script-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Size1-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Size1-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Size1-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Size2-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Size2-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Size2-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Size3-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Size3-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Size3-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Size4-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Size4-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Size4-Regular.woff2 +0 -0
- package/dist/styles/fonts/KaTeX_Typewriter-Regular.ttf +0 -0
- package/dist/styles/fonts/KaTeX_Typewriter-Regular.woff +0 -0
- package/dist/styles/fonts/KaTeX_Typewriter-Regular.woff2 +0 -0
- package/dist/styles/notiq.css +2 -0
- package/package.json +2 -1
- package/src/styles/notiq.css +272 -366
- package/src/styles/tailwind-plugin.ts +2 -2
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import React__default, { ReactNode } from 'react';
|
|
3
|
+
import { ElementFormatType } from 'lexical';
|
|
4
|
+
import { HistoryState } from '@lexical/react/LexicalHistoryPlugin';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Configuration for AI features in the Notiq editor.
|
|
8
|
+
*/
|
|
9
|
+
interface AIConfig {
|
|
10
|
+
/**
|
|
11
|
+
* The API endpoint for AI completions. Defaults to "/api/ai".
|
|
12
|
+
*/
|
|
13
|
+
apiEndpoint?: string;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Hook to access the current AI configuration.
|
|
17
|
+
*/
|
|
18
|
+
declare const useAI: () => AIConfig;
|
|
19
|
+
/**
|
|
20
|
+
* Provider component for AI configuration.
|
|
21
|
+
*/
|
|
22
|
+
declare const AIProvider: ({ config, children }: {
|
|
23
|
+
config?: AIConfig;
|
|
24
|
+
children: ReactNode;
|
|
25
|
+
}) => React__default.JSX.Element;
|
|
26
|
+
|
|
27
|
+
interface UploadResponse {
|
|
28
|
+
url: string;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* A function that handles file uploads.
|
|
32
|
+
* @param file The file to upload.
|
|
33
|
+
* @param onProgress Callback to report upload progress (0-100).
|
|
34
|
+
* @returns A promise that resolves to an object containing the uploaded file's URL.
|
|
35
|
+
*/
|
|
36
|
+
type UploadHandler = (file: File, onProgress?: (progress: number) => void) => Promise<UploadResponse>;
|
|
37
|
+
interface UploadConfig {
|
|
38
|
+
/**
|
|
39
|
+
* Custom upload handler. If not provided, the editor will attempt to use its default
|
|
40
|
+
* (which currently depends on EdgeStore if configured).
|
|
41
|
+
*/
|
|
42
|
+
uploadHandler?: UploadHandler;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Hook to access the current Upload configuration.
|
|
46
|
+
*/
|
|
47
|
+
declare const useUpload: () => UploadConfig | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* Provider component for Upload configuration.
|
|
50
|
+
*/
|
|
51
|
+
declare const UploadProvider: ({ config, children }: {
|
|
52
|
+
config?: UploadConfig;
|
|
53
|
+
children: ReactNode;
|
|
54
|
+
}) => React__default.JSX.Element;
|
|
55
|
+
|
|
56
|
+
type ToolbarItem = "undo" | "redo" | "block-format" | "font-family" | "font-size" | "bold" | "italic" | "underline" | "code" | "link" | "color" | "bg-color" | "text-format" | "insert" | "align" | "speech" | "template" | "download" | "export-md" | "export-pdf" | "separator";
|
|
57
|
+
type ToolbarConfig = {
|
|
58
|
+
items?: ToolbarItem[];
|
|
59
|
+
className?: string;
|
|
60
|
+
itemClassName?: string;
|
|
61
|
+
activeItemClassName?: string;
|
|
62
|
+
mobileClassName?: string;
|
|
63
|
+
mobileItemClassName?: string;
|
|
64
|
+
};
|
|
65
|
+
declare function Editor({ isEditable, content, aiConfig, uploadConfig, toolbarConfig, }: {
|
|
66
|
+
isEditable: boolean;
|
|
67
|
+
content?: unknown;
|
|
68
|
+
aiConfig?: AIConfig;
|
|
69
|
+
uploadConfig?: UploadConfig;
|
|
70
|
+
toolbarConfig?: ToolbarConfig;
|
|
71
|
+
}): React__default.JSX.Element;
|
|
72
|
+
|
|
73
|
+
declare const MIN_ALLOWED_FONT_SIZE = 8;
|
|
74
|
+
declare const MAX_ALLOWED_FONT_SIZE = 72;
|
|
75
|
+
declare const DEFAULT_FONT_SIZE = 15;
|
|
76
|
+
declare const rootTypeToRootName: {
|
|
77
|
+
root: string;
|
|
78
|
+
table: string;
|
|
79
|
+
};
|
|
80
|
+
declare const blockTypeToBlockName: {
|
|
81
|
+
bullet: string;
|
|
82
|
+
check: string;
|
|
83
|
+
code: string;
|
|
84
|
+
h1: string;
|
|
85
|
+
h2: string;
|
|
86
|
+
h3: string;
|
|
87
|
+
h4: string;
|
|
88
|
+
h5: string;
|
|
89
|
+
h6: string;
|
|
90
|
+
number: string;
|
|
91
|
+
paragraph: string;
|
|
92
|
+
quote: string;
|
|
93
|
+
};
|
|
94
|
+
declare const INITIAL_TOOLBAR_STATE: {
|
|
95
|
+
bgColor: string;
|
|
96
|
+
blockType: keyof typeof blockTypeToBlockName;
|
|
97
|
+
canRedo: boolean;
|
|
98
|
+
canUndo: boolean;
|
|
99
|
+
codeLanguage: string;
|
|
100
|
+
elementFormat: ElementFormatType;
|
|
101
|
+
fontColor: string;
|
|
102
|
+
fontFamily: string;
|
|
103
|
+
fontSize: string;
|
|
104
|
+
fontSizeInputValue: string;
|
|
105
|
+
isBold: boolean;
|
|
106
|
+
isCode: boolean;
|
|
107
|
+
isImageCaption: boolean;
|
|
108
|
+
isItalic: boolean;
|
|
109
|
+
isLink: boolean;
|
|
110
|
+
isRTL: boolean;
|
|
111
|
+
isStrikethrough: boolean;
|
|
112
|
+
isSubscript: boolean;
|
|
113
|
+
isSuperscript: boolean;
|
|
114
|
+
isUnderline: boolean;
|
|
115
|
+
isLowercase: boolean;
|
|
116
|
+
isUppercase: boolean;
|
|
117
|
+
isCapitalize: boolean;
|
|
118
|
+
rootType: keyof typeof rootTypeToRootName;
|
|
119
|
+
};
|
|
120
|
+
type ToolbarState = typeof INITIAL_TOOLBAR_STATE;
|
|
121
|
+
type ToolbarStateKey = keyof ToolbarState;
|
|
122
|
+
type ToolbarStateValue<Key extends ToolbarStateKey> = ToolbarState[Key];
|
|
123
|
+
type ContextShape$1 = {
|
|
124
|
+
toolbarState: ToolbarState;
|
|
125
|
+
updateToolbarState<Key extends ToolbarStateKey>(key: Key, value: ToolbarStateValue<Key>): void;
|
|
126
|
+
};
|
|
127
|
+
declare const ToolbarContext: ({ children, }: {
|
|
128
|
+
children: ReactNode;
|
|
129
|
+
}) => React__default.JSX.Element;
|
|
130
|
+
declare const useToolbarState: () => ContextShape$1;
|
|
131
|
+
|
|
132
|
+
type ContextShape = {
|
|
133
|
+
historyState?: HistoryState;
|
|
134
|
+
};
|
|
135
|
+
declare const SharedHistoryContext: ({ children, }: {
|
|
136
|
+
children: ReactNode;
|
|
137
|
+
}) => React.JSX.Element;
|
|
138
|
+
declare const useSharedHistoryContext: () => ContextShape;
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* A Tailwind CSS plugin that adds Notiq's custom theme variables and styles.
|
|
142
|
+
*/
|
|
143
|
+
declare const notiqPlugin: any;
|
|
144
|
+
|
|
145
|
+
export { type AIConfig, AIProvider, type ContextShape$1 as ContextShape, DEFAULT_FONT_SIZE, Editor, MAX_ALLOWED_FONT_SIZE, MIN_ALLOWED_FONT_SIZE, SharedHistoryContext, type ToolbarConfig, ToolbarContext, type ToolbarItem, type UploadConfig, type UploadHandler, UploadProvider, type UploadResponse, blockTypeToBlockName, notiqPlugin, useAI, useSharedHistoryContext, useToolbarState, useUpload };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import React__default, { ReactNode } from 'react';
|
|
3
|
+
import { ElementFormatType } from 'lexical';
|
|
4
|
+
import { HistoryState } from '@lexical/react/LexicalHistoryPlugin';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Configuration for AI features in the Notiq editor.
|
|
8
|
+
*/
|
|
9
|
+
interface AIConfig {
|
|
10
|
+
/**
|
|
11
|
+
* The API endpoint for AI completions. Defaults to "/api/ai".
|
|
12
|
+
*/
|
|
13
|
+
apiEndpoint?: string;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Hook to access the current AI configuration.
|
|
17
|
+
*/
|
|
18
|
+
declare const useAI: () => AIConfig;
|
|
19
|
+
/**
|
|
20
|
+
* Provider component for AI configuration.
|
|
21
|
+
*/
|
|
22
|
+
declare const AIProvider: ({ config, children }: {
|
|
23
|
+
config?: AIConfig;
|
|
24
|
+
children: ReactNode;
|
|
25
|
+
}) => React__default.JSX.Element;
|
|
26
|
+
|
|
27
|
+
interface UploadResponse {
|
|
28
|
+
url: string;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* A function that handles file uploads.
|
|
32
|
+
* @param file The file to upload.
|
|
33
|
+
* @param onProgress Callback to report upload progress (0-100).
|
|
34
|
+
* @returns A promise that resolves to an object containing the uploaded file's URL.
|
|
35
|
+
*/
|
|
36
|
+
type UploadHandler = (file: File, onProgress?: (progress: number) => void) => Promise<UploadResponse>;
|
|
37
|
+
interface UploadConfig {
|
|
38
|
+
/**
|
|
39
|
+
* Custom upload handler. If not provided, the editor will attempt to use its default
|
|
40
|
+
* (which currently depends on EdgeStore if configured).
|
|
41
|
+
*/
|
|
42
|
+
uploadHandler?: UploadHandler;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Hook to access the current Upload configuration.
|
|
46
|
+
*/
|
|
47
|
+
declare const useUpload: () => UploadConfig | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* Provider component for Upload configuration.
|
|
50
|
+
*/
|
|
51
|
+
declare const UploadProvider: ({ config, children }: {
|
|
52
|
+
config?: UploadConfig;
|
|
53
|
+
children: ReactNode;
|
|
54
|
+
}) => React__default.JSX.Element;
|
|
55
|
+
|
|
56
|
+
type ToolbarItem = "undo" | "redo" | "block-format" | "font-family" | "font-size" | "bold" | "italic" | "underline" | "code" | "link" | "color" | "bg-color" | "text-format" | "insert" | "align" | "speech" | "template" | "download" | "export-md" | "export-pdf" | "separator";
|
|
57
|
+
type ToolbarConfig = {
|
|
58
|
+
items?: ToolbarItem[];
|
|
59
|
+
className?: string;
|
|
60
|
+
itemClassName?: string;
|
|
61
|
+
activeItemClassName?: string;
|
|
62
|
+
mobileClassName?: string;
|
|
63
|
+
mobileItemClassName?: string;
|
|
64
|
+
};
|
|
65
|
+
declare function Editor({ isEditable, content, aiConfig, uploadConfig, toolbarConfig, }: {
|
|
66
|
+
isEditable: boolean;
|
|
67
|
+
content?: unknown;
|
|
68
|
+
aiConfig?: AIConfig;
|
|
69
|
+
uploadConfig?: UploadConfig;
|
|
70
|
+
toolbarConfig?: ToolbarConfig;
|
|
71
|
+
}): React__default.JSX.Element;
|
|
72
|
+
|
|
73
|
+
declare const MIN_ALLOWED_FONT_SIZE = 8;
|
|
74
|
+
declare const MAX_ALLOWED_FONT_SIZE = 72;
|
|
75
|
+
declare const DEFAULT_FONT_SIZE = 15;
|
|
76
|
+
declare const rootTypeToRootName: {
|
|
77
|
+
root: string;
|
|
78
|
+
table: string;
|
|
79
|
+
};
|
|
80
|
+
declare const blockTypeToBlockName: {
|
|
81
|
+
bullet: string;
|
|
82
|
+
check: string;
|
|
83
|
+
code: string;
|
|
84
|
+
h1: string;
|
|
85
|
+
h2: string;
|
|
86
|
+
h3: string;
|
|
87
|
+
h4: string;
|
|
88
|
+
h5: string;
|
|
89
|
+
h6: string;
|
|
90
|
+
number: string;
|
|
91
|
+
paragraph: string;
|
|
92
|
+
quote: string;
|
|
93
|
+
};
|
|
94
|
+
declare const INITIAL_TOOLBAR_STATE: {
|
|
95
|
+
bgColor: string;
|
|
96
|
+
blockType: keyof typeof blockTypeToBlockName;
|
|
97
|
+
canRedo: boolean;
|
|
98
|
+
canUndo: boolean;
|
|
99
|
+
codeLanguage: string;
|
|
100
|
+
elementFormat: ElementFormatType;
|
|
101
|
+
fontColor: string;
|
|
102
|
+
fontFamily: string;
|
|
103
|
+
fontSize: string;
|
|
104
|
+
fontSizeInputValue: string;
|
|
105
|
+
isBold: boolean;
|
|
106
|
+
isCode: boolean;
|
|
107
|
+
isImageCaption: boolean;
|
|
108
|
+
isItalic: boolean;
|
|
109
|
+
isLink: boolean;
|
|
110
|
+
isRTL: boolean;
|
|
111
|
+
isStrikethrough: boolean;
|
|
112
|
+
isSubscript: boolean;
|
|
113
|
+
isSuperscript: boolean;
|
|
114
|
+
isUnderline: boolean;
|
|
115
|
+
isLowercase: boolean;
|
|
116
|
+
isUppercase: boolean;
|
|
117
|
+
isCapitalize: boolean;
|
|
118
|
+
rootType: keyof typeof rootTypeToRootName;
|
|
119
|
+
};
|
|
120
|
+
type ToolbarState = typeof INITIAL_TOOLBAR_STATE;
|
|
121
|
+
type ToolbarStateKey = keyof ToolbarState;
|
|
122
|
+
type ToolbarStateValue<Key extends ToolbarStateKey> = ToolbarState[Key];
|
|
123
|
+
type ContextShape$1 = {
|
|
124
|
+
toolbarState: ToolbarState;
|
|
125
|
+
updateToolbarState<Key extends ToolbarStateKey>(key: Key, value: ToolbarStateValue<Key>): void;
|
|
126
|
+
};
|
|
127
|
+
declare const ToolbarContext: ({ children, }: {
|
|
128
|
+
children: ReactNode;
|
|
129
|
+
}) => React__default.JSX.Element;
|
|
130
|
+
declare const useToolbarState: () => ContextShape$1;
|
|
131
|
+
|
|
132
|
+
type ContextShape = {
|
|
133
|
+
historyState?: HistoryState;
|
|
134
|
+
};
|
|
135
|
+
declare const SharedHistoryContext: ({ children, }: {
|
|
136
|
+
children: ReactNode;
|
|
137
|
+
}) => React.JSX.Element;
|
|
138
|
+
declare const useSharedHistoryContext: () => ContextShape;
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* A Tailwind CSS plugin that adds Notiq's custom theme variables and styles.
|
|
142
|
+
*/
|
|
143
|
+
declare const notiqPlugin: any;
|
|
144
|
+
|
|
145
|
+
export { type AIConfig, AIProvider, type ContextShape$1 as ContextShape, DEFAULT_FONT_SIZE, Editor, MAX_ALLOWED_FONT_SIZE, MIN_ALLOWED_FONT_SIZE, SharedHistoryContext, type ToolbarConfig, ToolbarContext, type ToolbarItem, type UploadConfig, type UploadHandler, UploadProvider, type UploadResponse, blockTypeToBlockName, notiqPlugin, useAI, useSharedHistoryContext, useToolbarState, useUpload };
|
package/dist/index.js
CHANGED
|
@@ -57547,7 +57547,7 @@ function Core({
|
|
|
57547
57547
|
});
|
|
57548
57548
|
return unregister;
|
|
57549
57549
|
}, [editor]);
|
|
57550
|
-
return /* @__PURE__ */ React.createElement(
|
|
57550
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, isEditable && /* @__PURE__ */ React.createElement(
|
|
57551
57551
|
ToolbarPlugin2,
|
|
57552
57552
|
{
|
|
57553
57553
|
editor,
|
|
@@ -57557,7 +57557,8 @@ function Core({
|
|
|
57557
57557
|
toolbarConfig
|
|
57558
57558
|
}
|
|
57559
57559
|
), isEditable && /* @__PURE__ */ React.createElement(ContentAnalyticsPlugin, null), /* @__PURE__ */ React.createElement("div", { className: cn(
|
|
57560
|
-
"flex justify-center w-full transition-all duration-300",
|
|
57560
|
+
"flex justify-center w-full min-h-screen transition-all duration-300",
|
|
57561
|
+
"dark:md:from-gray-900/50 dark:md:to-gray-800/30",
|
|
57561
57562
|
"pt-20 md:pt-10"
|
|
57562
57563
|
) }, /* @__PURE__ */ React.createElement(
|
|
57563
57564
|
import_framer_motion9.motion.div,
|
|
@@ -57567,11 +57568,11 @@ function Core({
|
|
|
57567
57568
|
"prose prose-lg dark:prose-invert lg:prose-xl leading-relaxed",
|
|
57568
57569
|
"md:rounded-2xl md:shadow-2xl md:shadow-black/5",
|
|
57569
57570
|
"md:dark:shadow-black/20",
|
|
57570
|
-
"bg-
|
|
57571
|
+
"bg-white dark:bg-gray-900",
|
|
57571
57572
|
"md:border md:border-gray-200/50 dark:md:border-gray-800/50"
|
|
57572
57573
|
)
|
|
57573
57574
|
},
|
|
57574
|
-
/* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 rounded-2xl overflow-hidden pointer-events-none" }, /* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 bg-gradient-to-br from-blue-50/
|
|
57575
|
+
/* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 rounded-2xl overflow-hidden pointer-events-none" }, /* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 bg-gradient-to-br from-blue-50/30 via-transparent to-purple-50/30 dark:from-blue-900/10 dark:to-purple-900/10" }), /* @__PURE__ */ React.createElement("div", { className: "absolute top-0 left-0 w-full h-px bg-gradient-to-r from-transparent via-gray-200 to-transparent dark:via-gray-700" })),
|
|
57575
57576
|
/* @__PURE__ */ React.createElement(
|
|
57576
57577
|
import_LexicalRichTextPlugin4.RichTextPlugin,
|
|
57577
57578
|
{
|
|
@@ -57583,9 +57584,9 @@ function Core({
|
|
|
57583
57584
|
className: cn(
|
|
57584
57585
|
"editor-content relative z-20 outline-none",
|
|
57585
57586
|
"px-4 md:px-12 py-8 md:py-16",
|
|
57586
|
-
"min-h-[
|
|
57587
|
+
"min-h-[80vh] md:min-h-[70vh]",
|
|
57587
57588
|
"focus:outline-none focus:ring-0",
|
|
57588
|
-
"text-
|
|
57589
|
+
"text-foreground selection:bg-blue-100 dark:selection:bg-blue-900/30",
|
|
57589
57590
|
"font-['Inter',_system-ui,_sans-serif] antialiased",
|
|
57590
57591
|
"leading-relaxed tracking-wide",
|
|
57591
57592
|
"transition-all duration-200 ease-in-out",
|
|
@@ -57678,7 +57679,7 @@ function Editor({
|
|
|
57678
57679
|
editable: isEditable
|
|
57679
57680
|
};
|
|
57680
57681
|
console.log("Editor content:", content);
|
|
57681
|
-
return /* @__PURE__ */ import_react96.default.createElement(import_LexicalComposer.LexicalComposer, { initialConfig }, /* @__PURE__ */ import_react96.default.createElement(AIProvider, { config: aiConfig }, /* @__PURE__ */ import_react96.default.createElement(UploadProvider, { config: uploadConfig }, /* @__PURE__ */ import_react96.default.createElement(SharedHistoryContext, null, /* @__PURE__ */ import_react96.default.createElement(ToolbarContext, null, /* @__PURE__ */ import_react96.default.createElement(Core, { toolbarConfig }))))));
|
|
57682
|
+
return /* @__PURE__ */ import_react96.default.createElement("div", { className: "notiq-root" }, /* @__PURE__ */ import_react96.default.createElement(import_LexicalComposer.LexicalComposer, { initialConfig }, /* @__PURE__ */ import_react96.default.createElement(AIProvider, { config: aiConfig }, /* @__PURE__ */ import_react96.default.createElement(UploadProvider, { config: uploadConfig }, /* @__PURE__ */ import_react96.default.createElement(SharedHistoryContext, null, /* @__PURE__ */ import_react96.default.createElement(ToolbarContext, null, /* @__PURE__ */ import_react96.default.createElement(Core, { toolbarConfig })))))));
|
|
57682
57683
|
}
|
|
57683
57684
|
|
|
57684
57685
|
// src/index.ts
|
|
@@ -57706,7 +57707,7 @@ var u = g2;
|
|
|
57706
57707
|
// src/styles/tailwind-plugin.ts
|
|
57707
57708
|
var notiqPlugin = u(function({ addBase, theme: theme2 }) {
|
|
57708
57709
|
addBase({
|
|
57709
|
-
"
|
|
57710
|
+
":root": {
|
|
57710
57711
|
"--background": "oklch(1 0 0)",
|
|
57711
57712
|
"--foreground": "oklch(0.145 0 0)",
|
|
57712
57713
|
"--card": "oklch(1 0 0)",
|
|
@@ -57746,7 +57747,7 @@ var notiqPlugin = u(function({ addBase, theme: theme2 }) {
|
|
|
57746
57747
|
"--background-pink": "#f4dfeb",
|
|
57747
57748
|
"--background-red": "#fbe4e4"
|
|
57748
57749
|
},
|
|
57749
|
-
".dark
|
|
57750
|
+
".dark": {
|
|
57750
57751
|
"--background": "oklch(0.145 0 0)",
|
|
57751
57752
|
"--foreground": "oklch(0.985 0 0)",
|
|
57752
57753
|
"--card": "oklch(0.145 0 0)",
|
|
@@ -57832,9 +57833,6 @@ var notiqPlugin = u(function({ addBase, theme: theme2 }) {
|
|
|
57832
57833
|
}
|
|
57833
57834
|
}
|
|
57834
57835
|
});
|
|
57835
|
-
|
|
57836
|
-
// src/index.ts
|
|
57837
|
-
var import_notiq = require("./styles/notiq.css");
|
|
57838
57836
|
// Annotate the CommonJS export names for ESM import in node:
|
|
57839
57837
|
0 && (module.exports = {
|
|
57840
57838
|
AIProvider,
|
package/dist/index.mjs
CHANGED
|
@@ -1492,7 +1492,7 @@ function Core({
|
|
|
1492
1492
|
});
|
|
1493
1493
|
return unregister;
|
|
1494
1494
|
}, [editor]);
|
|
1495
|
-
return /* @__PURE__ */ React.createElement(
|
|
1495
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, isEditable && /* @__PURE__ */ React.createElement(
|
|
1496
1496
|
ToolbarPlugin,
|
|
1497
1497
|
{
|
|
1498
1498
|
editor,
|
|
@@ -1502,7 +1502,8 @@ function Core({
|
|
|
1502
1502
|
toolbarConfig
|
|
1503
1503
|
}
|
|
1504
1504
|
), isEditable && /* @__PURE__ */ React.createElement(ContentAnalyticsPlugin, null), /* @__PURE__ */ React.createElement("div", { className: cn(
|
|
1505
|
-
"flex justify-center w-full transition-all duration-300",
|
|
1505
|
+
"flex justify-center w-full min-h-screen transition-all duration-300",
|
|
1506
|
+
"dark:md:from-gray-900/50 dark:md:to-gray-800/30",
|
|
1506
1507
|
"pt-20 md:pt-10"
|
|
1507
1508
|
) }, /* @__PURE__ */ React.createElement(
|
|
1508
1509
|
motion.div,
|
|
@@ -1512,11 +1513,11 @@ function Core({
|
|
|
1512
1513
|
"prose prose-lg dark:prose-invert lg:prose-xl leading-relaxed",
|
|
1513
1514
|
"md:rounded-2xl md:shadow-2xl md:shadow-black/5",
|
|
1514
1515
|
"md:dark:shadow-black/20",
|
|
1515
|
-
"bg-
|
|
1516
|
+
"bg-white dark:bg-gray-900",
|
|
1516
1517
|
"md:border md:border-gray-200/50 dark:md:border-gray-800/50"
|
|
1517
1518
|
)
|
|
1518
1519
|
},
|
|
1519
|
-
/* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 rounded-2xl overflow-hidden pointer-events-none" }, /* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 bg-gradient-to-br from-blue-50/
|
|
1520
|
+
/* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 rounded-2xl overflow-hidden pointer-events-none" }, /* @__PURE__ */ React.createElement("div", { className: "absolute inset-0 bg-gradient-to-br from-blue-50/30 via-transparent to-purple-50/30 dark:from-blue-900/10 dark:to-purple-900/10" }), /* @__PURE__ */ React.createElement("div", { className: "absolute top-0 left-0 w-full h-px bg-gradient-to-r from-transparent via-gray-200 to-transparent dark:via-gray-700" })),
|
|
1520
1521
|
/* @__PURE__ */ React.createElement(
|
|
1521
1522
|
RichTextPlugin,
|
|
1522
1523
|
{
|
|
@@ -1528,9 +1529,9 @@ function Core({
|
|
|
1528
1529
|
className: cn(
|
|
1529
1530
|
"editor-content relative z-20 outline-none",
|
|
1530
1531
|
"px-4 md:px-12 py-8 md:py-16",
|
|
1531
|
-
"min-h-[
|
|
1532
|
+
"min-h-[80vh] md:min-h-[70vh]",
|
|
1532
1533
|
"focus:outline-none focus:ring-0",
|
|
1533
|
-
"text-
|
|
1534
|
+
"text-foreground selection:bg-blue-100 dark:selection:bg-blue-900/30",
|
|
1534
1535
|
"font-['Inter',_system-ui,_sans-serif] antialiased",
|
|
1535
1536
|
"leading-relaxed tracking-wide",
|
|
1536
1537
|
"transition-all duration-200 ease-in-out",
|
|
@@ -1620,7 +1621,7 @@ function Editor({
|
|
|
1620
1621
|
editable: isEditable
|
|
1621
1622
|
};
|
|
1622
1623
|
console.log("Editor content:", content);
|
|
1623
|
-
return /* @__PURE__ */ React3.createElement(LexicalComposer, { initialConfig }, /* @__PURE__ */ React3.createElement(AIProvider, { config: aiConfig }, /* @__PURE__ */ React3.createElement(UploadProvider, { config: uploadConfig }, /* @__PURE__ */ React3.createElement(SharedHistoryContext, null, /* @__PURE__ */ React3.createElement(ToolbarContext, null, /* @__PURE__ */ React3.createElement(Core, { toolbarConfig }))))));
|
|
1624
|
+
return /* @__PURE__ */ React3.createElement("div", { className: "notiq-root" }, /* @__PURE__ */ React3.createElement(LexicalComposer, { initialConfig }, /* @__PURE__ */ React3.createElement(AIProvider, { config: aiConfig }, /* @__PURE__ */ React3.createElement(UploadProvider, { config: uploadConfig }, /* @__PURE__ */ React3.createElement(SharedHistoryContext, null, /* @__PURE__ */ React3.createElement(ToolbarContext, null, /* @__PURE__ */ React3.createElement(Core, { toolbarConfig })))))));
|
|
1624
1625
|
}
|
|
1625
1626
|
|
|
1626
1627
|
// src/styles/tailwind-plugin.ts
|
|
@@ -1642,7 +1643,7 @@ var u = g;
|
|
|
1642
1643
|
// src/styles/tailwind-plugin.ts
|
|
1643
1644
|
var notiqPlugin = u(function({ addBase, theme: theme2 }) {
|
|
1644
1645
|
addBase({
|
|
1645
|
-
"
|
|
1646
|
+
":root": {
|
|
1646
1647
|
"--background": "oklch(1 0 0)",
|
|
1647
1648
|
"--foreground": "oklch(0.145 0 0)",
|
|
1648
1649
|
"--card": "oklch(1 0 0)",
|
|
@@ -1682,7 +1683,7 @@ var notiqPlugin = u(function({ addBase, theme: theme2 }) {
|
|
|
1682
1683
|
"--background-pink": "#f4dfeb",
|
|
1683
1684
|
"--background-red": "#fbe4e4"
|
|
1684
1685
|
},
|
|
1685
|
-
".dark
|
|
1686
|
+
".dark": {
|
|
1686
1687
|
"--background": "oklch(0.145 0 0)",
|
|
1687
1688
|
"--foreground": "oklch(0.985 0 0)",
|
|
1688
1689
|
"--card": "oklch(0.145 0 0)",
|
|
@@ -1768,9 +1769,6 @@ var notiqPlugin = u(function({ addBase, theme: theme2 }) {
|
|
|
1768
1769
|
}
|
|
1769
1770
|
}
|
|
1770
1771
|
});
|
|
1771
|
-
|
|
1772
|
-
// src/index.ts
|
|
1773
|
-
import "./styles/notiq.css";
|
|
1774
1772
|
export {
|
|
1775
1773
|
AIProvider,
|
|
1776
1774
|
DEFAULT_FONT_SIZE,
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|