@coorax/react 0.0.0-canary.1 → 0.0.0-canary.10

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.
Files changed (198) hide show
  1. package/dist/components/commons/button.d.ts +8 -0
  2. package/dist/components/commons/youtube.d.ts +2 -0
  3. package/dist/components/corax-context-provider.d.ts +11 -0
  4. package/dist/components/corax-flow.d.ts +6 -0
  5. package/dist/components/errors/iframe.error.d.ts +2 -0
  6. package/dist/components/errors/image.error.d.ts +2 -0
  7. package/dist/components/errors/video.errors.d.ts +2 -0
  8. package/dist/components/fallbacks/iframe.fallback.d.ts +2 -0
  9. package/dist/components/fallbacks/image.fallback.d.ts +2 -0
  10. package/dist/components/fallbacks/link.fallback.d.ts +2 -0
  11. package/dist/components/fallbacks/video.fallback.d.ts +2 -0
  12. package/dist/components/slots/buttons/block-actions-button.d.ts +3 -0
  13. package/dist/components/slots/buttons/caption-button.d.ts +3 -0
  14. package/dist/components/slots/buttons/code-theme-button.d.ts +3 -0
  15. package/dist/components/slots/buttons/delete-button.d.ts +3 -0
  16. package/dist/components/slots/buttons/divider-style-button.d.ts +3 -0
  17. package/dist/components/slots/buttons/divider-width-button.d.ts +3 -0
  18. package/dist/components/slots/buttons/iframe-playback-button.d.ts +3 -0
  19. package/dist/components/slots/buttons/image-width-button.d.ts +3 -0
  20. package/dist/components/slots/buttons/paragraph-theme-button.d.ts +3 -0
  21. package/dist/components/slots/buttons/toolbar-button.d.ts +3 -0
  22. package/dist/components/slots/maps/block-actions.d.ts +1 -0
  23. package/dist/components/slots/maps/overlays.d.ts +1 -0
  24. package/dist/components/slots/maps/text-inspector.d.ts +2 -0
  25. package/dist/components/slots/maps/toolbar.d.ts +1 -0
  26. package/dist/components/slots/overlays/focus-overlay.d.ts +3 -0
  27. package/dist/components/slots/overlays/hover-overlay.d.ts +3 -0
  28. package/dist/components/slots/overlays/selection-overlay.d.ts +3 -0
  29. package/dist/components/slots/slot-button.d.ts +6 -0
  30. package/dist/components/slots/slot-component.d.ts +5 -0
  31. package/dist/components/slots/slots.d.ts +4 -0
  32. package/dist/constants/field.constants.d.ts +2 -0
  33. package/dist/hooks/custom/use-custom-ref.d.ts +1 -0
  34. package/dist/hooks/custom/use-isomorphic-layout-effect.d.ts +2 -0
  35. package/{src/hooks/index.ts → dist/hooks/index.d.ts} +1 -0
  36. package/dist/hooks/use-block-entry.d.ts +2 -0
  37. package/dist/hooks/use-block.d.ts +2 -0
  38. package/dist/hooks/use-flow.d.ts +17 -0
  39. package/dist/hooks/use-is-selected.d.ts +2 -0
  40. package/dist/hooks/use-keyboard.d.ts +10 -0
  41. package/dist/hooks/use-registry.d.ts +3 -0
  42. package/dist/hooks/use-renderer.d.ts +2 -0
  43. package/dist/hooks/use-slice.d.ts +2 -0
  44. package/dist/hooks/use-slots.d.ts +2 -0
  45. package/dist/hooks/use-tasks.d.ts +7 -0
  46. package/dist/hooks/use-text-input.d.ts +2 -0
  47. package/dist/hooks/use-ui-context.d.ts +2 -0
  48. package/dist/hooks/useSelection.d.ts +2 -0
  49. package/{src/index.ts → dist/index.d.ts} +8 -4
  50. package/dist/index.js +3575 -0
  51. package/dist/lib/comp.utils.d.ts +8 -0
  52. package/dist/lib/func.utils.d.ts +3 -0
  53. package/dist/lib/index.d.ts +4 -0
  54. package/dist/lib/selection.utils.d.ts +5 -0
  55. package/dist/lib/slots.utils.d.ts +4 -0
  56. package/dist/lifecycle/fields/common/focus.events/onblur.d.ts +3 -0
  57. package/dist/lifecycle/fields/common/focus.events/onfocus.d.ts +3 -0
  58. package/dist/lifecycle/fields/common/handlers.d.ts +13 -0
  59. package/dist/lifecycle/fields/common/mouse.events/onclick.d.ts +3 -0
  60. package/dist/lifecycle/fields/common/mouse.events/onmouseenter.d.ts +3 -0
  61. package/dist/lifecycle/fields/common/mouse.events/onmouseleave.d.ts +3 -0
  62. package/dist/lifecycle/fields/divider/handlers.d.ts +7 -0
  63. package/dist/lifecycle/fields/divider/keyboard.events/onkeydown.d.ts +3 -0
  64. package/dist/lifecycle/fields/editable/focus.events/onbeforeinput.d.ts +3 -0
  65. package/dist/lifecycle/fields/editable/handlers.d.ts +7 -0
  66. package/dist/lifecycle/fields/editable/keyboard.events/onkeydown.d.ts +3 -0
  67. package/dist/lifecycle/fields/editable/mouse.events/ondoubleclick.d.ts +4 -0
  68. package/dist/lifecycle/fields/editable/synthetic.events/onselect.d.ts +3 -0
  69. package/dist/lifecycle/fields/handlers.registry.d.ts +12 -0
  70. package/dist/lifecycle/fields/lifecycle.fields.d.ts +10 -0
  71. package/dist/lifecycle/fields/lifecycle.fields.types.d.ts +4 -0
  72. package/dist/lifecycle/fields/lifecycle.utils.d.ts +8 -0
  73. package/dist/lifecycle/fields/media/common/handlers.d.ts +7 -0
  74. package/dist/lifecycle/fields/media/common/keyboard.events/onkeydown.d.ts +3 -0
  75. package/dist/lifecycle/fields/media/common/synthetic.events/onerror.d.ts +3 -0
  76. package/dist/lifecycle/fields/media/iframe/handlers.d.ts +7 -0
  77. package/dist/lifecycle/fields/media/iframe/synthetic.events/onload.d.ts +3 -0
  78. package/dist/lifecycle/fields/media/image/handlers.d.ts +7 -0
  79. package/dist/lifecycle/fields/media/image/synthetic.events/onload.d.ts +3 -0
  80. package/dist/lifecycle/fields/media/video/handlers.d.ts +7 -0
  81. package/dist/lifecycle/fields/media/video/mouse.events/ondoubleclick.d.ts +4 -0
  82. package/dist/lifecycle/fields/media/video/synthetic.events/oncanplaythrough.d.ts +3 -0
  83. package/dist/lifecycle/index.d.ts +3 -0
  84. package/dist/modules/autosave.module.d.ts +41 -0
  85. package/dist/modules/errors.module.d.ts +7 -0
  86. package/dist/modules/fallbacks.module.d.ts +7 -0
  87. package/dist/modules/slots.module.d.ts +7 -0
  88. package/dist/modules/ui-primitives.module.d.ts +7 -0
  89. package/dist/primitives/fields/field.primitives.d.ts +2 -0
  90. package/dist/primitives/index.d.ts +3 -0
  91. package/dist/registry/index.d.ts +4 -0
  92. package/dist/registry/slots.registry.d.ts +4 -0
  93. package/{src/registry/ui.primitives.registry.tsx → dist/registry/ui.primitives.registry.d.ts} +4 -5
  94. package/dist/services/index.d.ts +2 -0
  95. package/dist/services/localdb/db/db.d.ts +78 -0
  96. package/dist/services/localdb/db/db.test.d.ts +1 -0
  97. package/dist/services/localdb/dbtest.d.ts +1 -0
  98. package/dist/services/localdb/lexer/lexer.d.ts +14 -0
  99. package/dist/services/localdb/lexer/lexer.test.d.ts +1 -0
  100. package/dist/services/localdb/lexer/lexer.types.d.ts +5 -0
  101. package/dist/services/localdb/operator/operator.d.ts +10 -0
  102. package/dist/services/localdb/parser/parser.constants.d.ts +3 -0
  103. package/dist/services/localdb/parser/parser.d.ts +15 -0
  104. package/dist/services/localdb/parser/parser.test.d.ts +1 -0
  105. package/dist/services/localdb/parser/parser.types.d.ts +49 -0
  106. package/dist/services/localdb/sheet/sheet.constants.d.ts +3 -0
  107. package/dist/services/localdb/sheet/sheet.d.ts +14 -0
  108. package/dist/services/localdb/sheet/sheet.types.d.ts +13 -0
  109. package/dist/styles.css +2 -0
  110. package/package.json +38 -15
  111. package/styles.css +2 -1
  112. package/.oxlintrc.json +0 -8
  113. package/src/components/commons/button.tsx +0 -59
  114. package/src/components/corax-context-provider.tsx +0 -47
  115. package/src/components/corax-flow.tsx +0 -44
  116. package/src/components/fallbacks/image.fallback.tsx +0 -23
  117. package/src/components/slots/buttons/block-actions-button.tsx +0 -85
  118. package/src/components/slots/buttons/toolbar-button.tsx +0 -40
  119. package/src/components/slots/maps/block-actions.tsx +0 -84
  120. package/src/components/slots/maps/overlays.tsx +0 -9
  121. package/src/components/slots/maps/text-inspector.tsx +0 -5
  122. package/src/components/slots/maps/toolbar.tsx +0 -79
  123. package/src/components/slots/overlays/focus-overlay.tsx +0 -30
  124. package/src/components/slots/overlays/hover-overlay.tsx +0 -18
  125. package/src/components/slots/overlays/selection-overlay.tsx +0 -20
  126. package/src/components/slots/slot-button.tsx +0 -20
  127. package/src/components/slots/slot-component.tsx +0 -17
  128. package/src/components/slots/slots.tsx +0 -29
  129. package/src/constants/field.constants.ts +0 -3
  130. package/src/hooks/custom/use-custom-ref.ts +0 -11
  131. package/src/hooks/use-block-entry.ts +0 -44
  132. package/src/hooks/use-block.ts +0 -11
  133. package/src/hooks/use-flow.ts +0 -83
  134. package/src/hooks/use-keyboard.ts +0 -66
  135. package/src/hooks/use-registry.ts +0 -18
  136. package/src/hooks/use-renderer.ts +0 -8
  137. package/src/hooks/use-slice.ts +0 -13
  138. package/src/hooks/use-slots.ts +0 -13
  139. package/src/hooks/use-tasks.ts +0 -33
  140. package/src/hooks/use-text-input.ts +0 -83
  141. package/src/hooks/use-ui-context.ts +0 -16
  142. package/src/hooks/useSelection.ts +0 -27
  143. package/src/lib/comp.utils.tsx +0 -44
  144. package/src/lib/func.utils.ts +0 -15
  145. package/src/lib/selection.utils.ts +0 -33
  146. package/src/lib/slots.utils.tsx +0 -23
  147. package/src/lifecycle/fields/focus.events/onbeforeinput.ts +0 -21
  148. package/src/lifecycle/fields/focus.events/onblur.ts +0 -19
  149. package/src/lifecycle/fields/focus.events/onfocus.ts +0 -16
  150. package/src/lifecycle/fields/keyboard.events/onkeydown.ts +0 -128
  151. package/src/lifecycle/fields/lifecycle.fields.ts +0 -116
  152. package/src/lifecycle/fields/lifecycle.fields.types.ts +0 -33
  153. package/src/lifecycle/fields/lifecycle.utils.ts +0 -26
  154. package/src/lifecycle/fields/mouse.events/onclick.ts +0 -79
  155. package/src/lifecycle/fields/mouse.events/ondoubleclick.ts +0 -27
  156. package/src/lifecycle/fields/mouse.events/onmouseenter.ts +0 -27
  157. package/src/lifecycle/fields/mouse.events/onmouseleave.ts +0 -21
  158. package/src/lifecycle/fields/synthetic.events/onload.ts +0 -16
  159. package/src/lifecycle/fields/synthetic.events/onselect.ts +0 -57
  160. package/src/lifecycle/index.ts +0 -1
  161. package/src/modules/autosave.module.ts +0 -238
  162. package/src/modules/fallbacks.module.tsx +0 -19
  163. package/src/modules/slots.module.tsx +0 -28
  164. package/src/modules/ui-primitives.module.tsx +0 -20
  165. package/src/primitives/fields/field.primitives.tsx +0 -86
  166. package/src/primitives/index.ts +0 -8
  167. package/src/registry/fallbacks.registry.tsx +0 -9
  168. package/src/registry/index.ts +0 -5
  169. package/src/registry/primitives.registry.tsx +0 -57
  170. package/src/registry/registry.ts +0 -44
  171. package/src/registry/slots.registry.tsx +0 -6
  172. package/src/renderer/renderer.test.ts +0 -34
  173. package/src/renderer/renderer.tsx +0 -164
  174. package/src/renderer/renderer.types.ts +0 -3
  175. package/src/renderer/renderer.utils.tsx +0 -139
  176. package/src/renderer/utils/divider.renderer.utils.tsx +0 -53
  177. package/src/services/localdb/db/db.test.ts +0 -351
  178. package/src/services/localdb/db/db.ts +0 -628
  179. package/src/services/localdb/lexer/lexer.test.ts +0 -123
  180. package/src/services/localdb/lexer/lexer.ts +0 -173
  181. package/src/services/localdb/lexer/lexer.types.ts +0 -34
  182. package/src/services/localdb/operator/operator.ts +0 -16
  183. package/src/services/localdb/parser/parser.constants.ts +0 -23
  184. package/src/services/localdb/parser/parser.test.ts +0 -172
  185. package/src/services/localdb/parser/parser.ts +0 -427
  186. package/src/services/localdb/parser/parser.types.ts +0 -56
  187. package/src/services/localdb/sheet/sheet.constants.ts +0 -32
  188. package/src/services/localdb/sheet/sheet.ts +0 -47
  189. package/src/services/localdb/sheet/sheet.types.ts +0 -38
  190. package/tsconfig.app.json +0 -26
  191. package/tsconfig.json +0 -9
  192. package/tsconfig.node.json +0 -9
  193. package/tsconfig.tsbuildinfo +0 -1
  194. package/vite.config.ts +0 -9
  195. /package/{src/components/index.ts → dist/components/index.d.ts} +0 -0
  196. /package/{src/components/slots/index.ts → dist/components/slots/index.d.ts} +0 -0
  197. /package/{src/components/slots/maps/index.ts → dist/components/slots/maps/index.d.ts} +0 -0
  198. /package/{src/modules/index.ts → dist/modules/index.d.ts} +0 -0
@@ -0,0 +1,8 @@
1
+ import * as React from "react";
2
+ import { type VariantProps } from "class-variance-authority";
3
+ declare const buttonVariants: (props?: ({
4
+ variant?: "link" | "default" | "outline" | "secondary" | "ghost" | "destructive" | null | undefined;
5
+ size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
6
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
+ declare function Button({ className, variant, size, ...props }: React.ComponentProps<"button"> & VariantProps<typeof buttonVariants>): React.JSX.Element;
8
+ export { Button };
@@ -0,0 +1,2 @@
1
+ import type React from "react";
2
+ export declare function YoutubeIcon({ className, ...props }: React.ComponentProps<"svg">): React.JSX.Element;
@@ -0,0 +1,11 @@
1
+ import { Engine } from "@coorax/core";
2
+ import React from "react";
3
+ declare global {
4
+ interface Window {
5
+ __cooraxEngine: Engine;
6
+ }
7
+ }
8
+ export declare function CoraxEngineProvider({ children }: {
9
+ children: React.ReactNode;
10
+ }): React.JSX.Element;
11
+ export declare function useEngine(): Engine;
@@ -0,0 +1,6 @@
1
+ import React from "react";
2
+ /** Gouttière horizontale (px) où les médias élargis débordent tout en restant visibles. */
3
+ export declare const IMAGE_BREAKOUT_GUTTER = 150;
4
+ export declare function CoraxFlow({ children, className, }: React.PropsWithChildren & {
5
+ className?: string;
6
+ }): React.JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { IFrameField } from "@coorax/core";
2
+ export declare function IFrameErrorComponent({ children, ...rest }: IFrameField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { MediaField } from "@coorax/core";
2
+ export declare function ImageErrorComponent({ children, ...rest }: MediaField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { MediaField } from "@coorax/core";
2
+ export declare function VideoErrorComponent({ children, ...rest }: MediaField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { MediaField } from "@coorax/core";
2
+ export declare function IFrameFallback({ children, ...rest }: MediaField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { MediaField } from "@coorax/core";
2
+ export declare function ImageFallback({ children, ...rest }: MediaField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { LinkField } from "@coorax/core";
2
+ export declare function LinkFallback({ ...rest }: LinkField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { MediaField } from "@coorax/core";
2
+ export declare function VideoFallback({ children, ...rest }: MediaField & React.PropsWithChildren): import("react").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const BlockActionButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"block-actions", "fields.change" | "actions.toggle", "BlockActionButton">>) => React.JSX.Element | null>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const CaptionButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "caption.add", "CaptionButton">>) => React.JSX.Element>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const CodeThemeButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "code.toggleTheme", "CodeThemeButton">>) => React.JSX.Element>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const DeleteButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "blocks.deleteSelection", "DeleteButton">>) => React.JSX.Element>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const DividerStyleButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "divider.setStyle", "DividerStyleButton">>) => React.JSX.Element | null>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const DividerWidthButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "divider.setWidth", "DividerWidthButton">>) => React.JSX.Element | null>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const IframePlaybackButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "iframe.playback", "IframePlaybackButton">>) => React.JSX.Element>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const ImageWidthButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "image.setWidth", "ImageWidthButton">>) => React.JSX.Element | null>;
@@ -0,0 +1,3 @@
1
+ import { type ButtonContribution, type SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const ParagraphThemeButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "paragraph.setTheme", "ParagraphThemeButton">>) => React.JSX.Element | null>;
@@ -0,0 +1,3 @@
1
+ import type { ButtonContribution, SlotBaseProps } from "@coorax/core";
2
+ import React from "react";
3
+ export declare const ToolbarButton: React.MemoExoticComponent<({ c, ui, ...rest }: SlotBaseProps<ButtonContribution<"toolbar", "text.format", "ToolBarButton">>) => React.JSX.Element | null>;
@@ -0,0 +1 @@
1
+ export declare function BlockActions({ className, children, ...rest }: React.ComponentProps<"div">): import("react").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare function Overlays(): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { SlotComponentMap } from "@coorax/core";
2
+ export declare function TextInspector({ blockId }: SlotComponentMap["TextInspector"]): import("react").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare function Toolbar({ className, children, ...rest }: React.ComponentProps<"div">): import("react").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import type { ComponentContribution, SlotBaseProps } from "@coorax/core";
2
+ declare module "@coorax/core" { }
3
+ export declare function FocusOverlay({ c, ui, }: SlotBaseProps<ComponentContribution<"overlay", "FocusOverlay">>): import("react").JSX.Element | null;
@@ -0,0 +1,3 @@
1
+ import type { ComponentContribution, SlotBaseProps } from "@coorax/core";
2
+ declare module "@coorax/core" { }
3
+ export declare function HoverOverlay({ c, ui, }: SlotBaseProps<ComponentContribution<"overlay", "HoverOverlay">>): import("react").JSX.Element | null;
@@ -0,0 +1,3 @@
1
+ import type { ComponentContribution, SlotBaseProps } from "@coorax/core";
2
+ declare module "@coorax/core" { }
3
+ export declare function SelectionOverlay({ c, ui, }: SlotBaseProps<ComponentContribution<"overlay", "SelectionOverlay">>): import("react").JSX.Element | null;
@@ -0,0 +1,6 @@
1
+ import type { ButtonContribution, UIContext } from "@coorax/core";
2
+ import React from "react";
3
+ export declare function SlotButton({ c, ui }: {
4
+ c: ButtonContribution;
5
+ ui: UIContext;
6
+ }): React.ReactElement<any, string | React.JSXElementConstructor<any>> | null;
@@ -0,0 +1,5 @@
1
+ import type { ComponentContribution, UIContext } from "@coorax/core";
2
+ export declare function SlotComponent({ c, ui }: {
3
+ c: ComponentContribution;
4
+ ui: UIContext;
5
+ }): import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | null;
@@ -0,0 +1,4 @@
1
+ import { type SlotName } from "@coorax/core";
2
+ export declare function Slots({ slotName }: {
3
+ slotName: SlotName;
4
+ }): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { FieldType } from "@coorax/core";
2
+ export declare const TEXT_FIELD_TYPE: FieldType[];
@@ -0,0 +1 @@
1
+ export declare function useCustomRef<T>(factory: T | (() => T)): import("react").RefObject<T | null>;
@@ -0,0 +1,2 @@
1
+ import { useEffect } from "react";
2
+ export declare const useIsomorphicLayoutEffect: typeof useEffect;
@@ -1,2 +1,3 @@
1
1
  export * from "./use-slice";
2
2
  export * from "./use-ui-context";
3
+ export * from "./custom/use-isomorphic-layout-effect";
@@ -0,0 +1,2 @@
1
+ import type { BlockId } from "@coorax/core";
2
+ export declare function useBlockEntry(id: BlockId): void;
@@ -0,0 +1,2 @@
1
+ import type { Block, BlockId } from "@coorax/core";
2
+ export declare function useBlock<T extends Block = Block>(id: BlockId): T;
@@ -0,0 +1,17 @@
1
+ export declare function editorRectFromDomElement(domElement: HTMLElement): {
2
+ scrollTop: number;
3
+ scrollLeft: number;
4
+ clientLeft: number;
5
+ clientTop: number;
6
+ top: number;
7
+ left: number;
8
+ bottom: number;
9
+ right: number;
10
+ width: number;
11
+ height: number;
12
+ offsetTop: number;
13
+ offsetLeft: number;
14
+ offsetWidth: number;
15
+ offsetHeight: number;
16
+ };
17
+ export declare function useFlow(): void;
@@ -0,0 +1,2 @@
1
+ import type { BlockId } from "@coorax/core";
2
+ export declare function useIsSelected(id: BlockId): boolean | undefined;
@@ -0,0 +1,10 @@
1
+ type KeyboardState = {
2
+ eventType: string | null;
3
+ ctrlKey: boolean;
4
+ metaKey: boolean;
5
+ altKey: boolean;
6
+ currentKey: string | null;
7
+ shiftKey: boolean;
8
+ };
9
+ export declare function useKeyboard(): KeyboardState | null;
10
+ export {};
@@ -0,0 +1,3 @@
1
+ import type { SlotKey } from "@coorax/core";
2
+ export declare function useRegistryComponent(name: SlotKey): import("react").JSXElementConstructor<any> | undefined;
3
+ export declare function useUIPrimitivesRegistry(name: SlotKey): import("..").UIPrimitivesComponent | undefined;
@@ -0,0 +1,2 @@
1
+ import { ReactRenderer } from "@coorax/render-react";
2
+ export declare function useRenderer(): ReactRenderer;
@@ -0,0 +1,2 @@
1
+ import type { SliceName, SliceValue } from "@coorax/core";
2
+ export declare function useSlice<T extends SliceName = SliceName>(sliceName: T): SliceValue<T> | undefined;
@@ -0,0 +1,2 @@
1
+ import type { Contribution, SlotName } from "@coorax/core";
2
+ export declare function useSlots(slotName: SlotName): readonly Contribution[];
@@ -0,0 +1,7 @@
1
+ import type { TaskFunction, TaskID, TaskName, TaskState } from "@coorax/core";
2
+ export interface UseTasksReturn extends TaskState {
3
+ flush: () => Promise<void>;
4
+ cancel: () => boolean;
5
+ schedule: (delay: number, fn: TaskFunction, taskId?: TaskID) => () => void;
6
+ }
7
+ export declare function useTasks<T extends TaskName = TaskName>(name: T): UseTasksReturn;
@@ -0,0 +1,2 @@
1
+ import type { Engine } from "@coorax/core";
2
+ export declare function useTextInput(engine: Engine): void;
@@ -0,0 +1,2 @@
1
+ import type { UIContext } from "@coorax/core";
2
+ export declare function useUIContext(): UIContext;
@@ -0,0 +1,2 @@
1
+ import type { Engine } from "@coorax/core";
2
+ export declare function useTextSelection(engine: Engine): void;
@@ -2,10 +2,14 @@ import type { FieldLifeCycleEvProps } from "./lifecycle/fields/lifecycle.fields.
2
2
  export * from "./modules";
3
3
  export * from "./components";
4
4
  export * from "./hooks";
5
+ export * from "./registry";
6
+ export * from "./lifecycle";
7
+ export * from "./services";
8
+ export * from "./lib";
5
9
  export * from "@coorax/core";
6
-
10
+ export * from "@coorax/render-react";
7
11
  declare module "@coorax/core" {
8
- interface TEventMap {
9
- "field:lifecycle": FieldLifeCycleEvProps;
10
- }
12
+ interface TEventMap {
13
+ "field:lifecycle": FieldLifeCycleEvProps;
14
+ }
11
15
  }