line.d.ts 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. import { IGroup } from '@antv/g-base';
  2. import GroupComponent from '../abstract/group-component';
  3. import { ILocation } from '../interfaces';
  4. import { LineAnnotationCfg, RegionLocationCfg } from '../types';
  5. declare class LineAnnotation extends GroupComponent<LineAnnotationCfg> implements ILocation<RegionLocationCfg> {
  6. /**
  7. * @protected
  8. * 默认的配置项
  9. * @returns {object} 默认的配置项
  10. */
  11. getDefaultCfg(): {
  12. name: string;
  13. type: string;
  14. locationType: string;
  15. start: any;
  16. end: any;
  17. style: {};
  18. text: any;
  19. defaultCfg: {
  20. style: {
  21. fill: string;
  22. fontSize: number;
  23. textAlign: string;
  24. textBaseline: string;
  25. fontFamily: string;
  26. };
  27. text: {
  28. position: string;
  29. autoRotate: boolean;
  30. content: any;
  31. offsetX: number;
  32. offsetY: number;
  33. style: {
  34. stroke: string;
  35. lineWidth: number;
  36. };
  37. };
  38. };
  39. container: any;
  40. shapesMap: {};
  41. group: any;
  42. capture: boolean;
  43. isRegister: boolean;
  44. isUpdating: boolean;
  45. isInit: boolean;
  46. id: string;
  47. offsetX: number;
  48. offsetY: number;
  49. animate: boolean;
  50. updateAutoRender: boolean;
  51. animateOption: {
  52. appear: any;
  53. update: {
  54. duration: number;
  55. easing: string;
  56. };
  57. enter: {
  58. duration: number;
  59. easing: string;
  60. };
  61. leave: {
  62. duration: number;
  63. easing: string;
  64. };
  65. };
  66. events: any;
  67. visible: boolean;
  68. };
  69. protected renderInner(group: IGroup): void;
  70. private renderLine;
  71. private getLabelPoint;
  72. private renderLabel;
  73. }
  74. export default LineAnnotation;