@ones-editor/editor 2.5.1-beta.1 → 2.5.1-beta.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.
@@ -24,7 +24,6 @@ export declare function continuousScroll(scrollElement: HTMLElement, { direction
24
24
  export declare class AutoScroll {
25
25
  private cancelScroll;
26
26
  private options;
27
- private scrollDomInfo;
28
27
  private scrolling;
29
28
  constructor(options: AutoScrollOptions);
30
29
  private getScrollDomInfo;
@@ -0,0 +1,5 @@
1
+ import { DocBox } from '../../../../../@ones-editor/core';
2
+ export interface ImageBoxData extends DocBox {
3
+ src: string;
4
+ }
5
+ export default function convertToMarkdown(converters: unknown, boxData: DocBox): string;
@@ -5,6 +5,7 @@ import MentionBoxToMarkdown from './mention';
5
5
  import TaskLinkBoxToMarkdown from './task-link';
6
6
  import KnownLinkBoxToMarkdown from './known-link';
7
7
  import DateBoxToMarkdown from './date';
8
+ import ImageBoxToMarkdown from './image';
8
9
  export declare function getBoxes(): {
9
10
  br: typeof BrBoxToMarkdown;
10
11
  file: typeof FileBoxToMarkdown;
@@ -13,4 +14,5 @@ export declare function getBoxes(): {
13
14
  date: typeof DateBoxToMarkdown;
14
15
  'task-link': typeof TaskLinkBoxToMarkdown;
15
16
  'known-link': typeof KnownLinkBoxToMarkdown;
17
+ image: typeof ImageBoxToMarkdown;
16
18
  };
@@ -0,0 +1,2 @@
1
+ import { DocEmbedBlock } from '../../../../../@ones-editor/core';
2
+ export default function convertToMarkdown(converters: unknown, blockData: DocEmbedBlock): string;
@@ -0,0 +1,14 @@
1
+ /// <reference types="node" />
2
+ export interface EncodingOpts {
3
+ /** Defaults to 24 */
4
+ chunkLength?: number;
5
+ /** If not provided, will check the start, beginning, and end */
6
+ chunkBegin?: number;
7
+ }
8
+ /**
9
+ * Get the encoding of a buffer.
10
+ * Checks the start, middle, and end of the buffer for characters that are unrecognized within UTF8 encoding.
11
+ * History has shown that inspection at all three locations is necessary.
12
+ * @returns Will be `null` if `buffer` was not provided. Otherwise will be either `'utf8'` or `'binary'`
13
+ */
14
+ export declare function getEncoding(buffer: Buffer | null, opts?: EncodingOpts): 'utf8' | 'binary' | null;