仲裁视频会议H5

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. import LinkedList from '../../collection/linked-list';
  2. import LinkedNode from '../../collection/linked-node';
  3. export interface Blot extends LinkedNode {
  4. scroll: Parent;
  5. parent: Parent;
  6. prev: Blot;
  7. next: Blot;
  8. domNode: Node;
  9. attach(): void;
  10. clone(): Blot;
  11. detach(): void;
  12. insertInto(parentBlot: Parent, refBlot?: Blot): void;
  13. isolate(index: number, length: number): Blot;
  14. offset(root?: Blot): number;
  15. remove(): void;
  16. replace(target: Blot): void;
  17. replaceWith(name: string, value: any): Blot;
  18. replaceWith(replacement: Blot): Blot;
  19. split(index: number, force?: boolean): Blot;
  20. wrap(name: string, value: any): Parent;
  21. wrap(wrapper: Parent): Parent;
  22. deleteAt(index: number, length: number): void;
  23. formatAt(index: number, length: number, name: string, value: any): void;
  24. insertAt(index: number, value: string, def?: any): void;
  25. optimize(context: { [key: string]: any }): void;
  26. optimize(mutations: MutationRecord[], context: { [key: string]: any }): void;
  27. update(mutations: MutationRecord[], context: { [key: string]: any }): void;
  28. }
  29. export interface Parent extends Blot {
  30. children: LinkedList<Blot>;
  31. domNode: HTMLElement;
  32. appendChild(child: Blot): void;
  33. descendant<T>(type: { new (): T }, index: number): [T, number];
  34. descendant<T>(matcher: (blot: Blot) => boolean, index: number): [T, number];
  35. descendants<T>(type: { new (): T }, index: number, length: number): T[];
  36. descendants<T>(matcher: (blot: Blot) => boolean, index: number, length: number): T[];
  37. insertBefore(child: Blot, refNode?: Blot): void;
  38. moveChildren(parent: Parent, refNode?: Blot): void;
  39. path(index: number, inclusive?: boolean): [Blot, number][];
  40. removeChild(child: Blot): void;
  41. unwrap(): void;
  42. }
  43. export interface Formattable extends Blot {
  44. format(name: string, value: any): void;
  45. formats(): { [index: string]: any };
  46. }
  47. export interface Leaf extends Blot {
  48. index(node: Node, offset: number): number;
  49. position(index: number, inclusive: boolean): [Node, number];
  50. value(): any;
  51. }