index.js 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", { value: true });
  3. exports.flow = exports.P = exports.WordCloud = exports.Waterfall = exports.Violin = exports.Venn = exports.Treemap = exports.TinyLine = exports.TinyColumn = exports.TinyArea = exports.Sunburst = exports.Stock = exports.Scatter = exports.Sankey = exports.Rose = exports.RingProgress = exports.RadialBar = exports.Radar = exports.Progress = exports.Pie = exports.MultiView = exports.Mix = exports.Liquid = exports.addWaterWave = exports.Line = exports.Histogram = exports.Heatmap = exports.Gauge = exports.FUNNEL_CONVERSATION_FIELD = exports.Funnel = exports.Facet = exports.DualAxes = exports.Column = exports.CirclePacking = exports.Chord = exports.Bullet = exports.Box = exports.BidirectionalBar = exports.Bar = exports.Area = exports.Lab = exports.Plot = exports.setGlobal = exports.schema = exports.polygon = exports.point = exports.line = exports.interval = exports.area = exports.version = void 0;
  4. exports.adaptors = exports.registerLocale = exports.G2 = exports.getCanvasPattern = exports.measureTextWidth = void 0;
  5. var tslib_1 = require("tslib");
  6. exports.version = '2.4.31';
  7. // G2 自定义能力透出
  8. var G2 = tslib_1.__importStar(require("@antv/g2"));
  9. exports.G2 = G2;
  10. /** 开放一些通用的 adaptor 通道方法,实验阶段:不保证稳定性 */
  11. var common_1 = require("./adaptor/common");
  12. // 国际化处理
  13. var locale_1 = require("./core/locale");
  14. Object.defineProperty(exports, "registerLocale", { enumerable: true, get: function () { return locale_1.registerLocale; } });
  15. var en_US_1 = require("./locales/en_US");
  16. var zh_CN_1 = require("./locales/zh_CN");
  17. /** 各个 geometry 的 adaptor,可以让开发者更快的构造图形 */
  18. var geometries_1 = require("./adaptor/geometries");
  19. Object.defineProperty(exports, "area", { enumerable: true, get: function () { return geometries_1.area; } });
  20. Object.defineProperty(exports, "interval", { enumerable: true, get: function () { return geometries_1.interval; } });
  21. Object.defineProperty(exports, "line", { enumerable: true, get: function () { return geometries_1.line; } });
  22. Object.defineProperty(exports, "point", { enumerable: true, get: function () { return geometries_1.point; } });
  23. Object.defineProperty(exports, "polygon", { enumerable: true, get: function () { return geometries_1.polygon; } });
  24. Object.defineProperty(exports, "schema", { enumerable: true, get: function () { return geometries_1.schema; } });
  25. /** 全局变量 */
  26. var global_1 = require("./core/global");
  27. Object.defineProperty(exports, "setGlobal", { enumerable: true, get: function () { return global_1.setGlobal; } });
  28. /** G2Plot 的 Plot 基类 */
  29. var plot_1 = require("./core/plot");
  30. Object.defineProperty(exports, "Plot", { enumerable: true, get: function () { return plot_1.Plot; } });
  31. /** 对于没有开发完成的图表,可以暂时先放到 Lab 下面,先做体验,稳定后放到根 export */
  32. var lab_1 = require("./lab");
  33. Object.defineProperty(exports, "Lab", { enumerable: true, get: function () { return lab_1.Lab; } });
  34. // 面积图及类型定义 | author by [hustcc](https://github.com/hustcc)
  35. var area_1 = require("./plots/area");
  36. Object.defineProperty(exports, "Area", { enumerable: true, get: function () { return area_1.Area; } });
  37. // 条形图及类型定义 | author by [BBSQQ](https://github.com/BBSQQ)
  38. var bar_1 = require("./plots/bar");
  39. Object.defineProperty(exports, "Bar", { enumerable: true, get: function () { return bar_1.Bar; } });
  40. // 对称条形图及类型定义 | author by [arcsin1](https://github.com/arcsin1)
  41. var bidirectional_bar_1 = require("./plots/bidirectional-bar");
  42. Object.defineProperty(exports, "BidirectionalBar", { enumerable: true, get: function () { return bidirectional_bar_1.BidirectionalBar; } });
  43. // 箱线图及类型定义 | author by [BBSQQ](https://github.com/BBSQQ), [visiky](https://github.com/visiky)
  44. var box_1 = require("./plots/box");
  45. Object.defineProperty(exports, "Box", { enumerable: true, get: function () { return box_1.Box; } });
  46. // 子弹图及类型定义 | author by [arcsin1](https://github.com/arcsin1)
  47. var bullet_1 = require("./plots/bullet");
  48. Object.defineProperty(exports, "Bullet", { enumerable: true, get: function () { return bullet_1.Bullet; } });
  49. // 弦图及类型定义 | author by [MrSmallLiu](https://github.com/MrSmallLiu), [visiky](https://github.com/visiky)
  50. var chord_1 = require("./plots/chord");
  51. Object.defineProperty(exports, "Chord", { enumerable: true, get: function () { return chord_1.Chord; } });
  52. // circle-packing 及类型定义 | author by [visiky](https://github.com/visiky), [Angeli](https://github.com/Angelii)
  53. var circle_packing_1 = require("./plots/circle-packing");
  54. Object.defineProperty(exports, "CirclePacking", { enumerable: true, get: function () { return circle_packing_1.CirclePacking; } });
  55. // 柱形图及类型定义 | author by [zqlu](https://github.com/zqlu)
  56. var column_1 = require("./plots/column");
  57. Object.defineProperty(exports, "Column", { enumerable: true, get: function () { return column_1.Column; } });
  58. // 混合图形 | author by [liuzhenying](https://github.com/liuzhenying)
  59. var dual_axes_1 = require("./plots/dual-axes");
  60. Object.defineProperty(exports, "DualAxes", { enumerable: true, get: function () { return dual_axes_1.DualAxes; } });
  61. // 分面图及类型定义 | author by [visiky](https://github.com/visiky)
  62. var facet_1 = require("./plots/facet");
  63. Object.defineProperty(exports, "Facet", { enumerable: true, get: function () { return facet_1.Facet; } });
  64. // 漏斗图及类型定义
  65. var funnel_1 = require("./plots/funnel");
  66. Object.defineProperty(exports, "Funnel", { enumerable: true, get: function () { return funnel_1.Funnel; } });
  67. Object.defineProperty(exports, "FUNNEL_CONVERSATION_FIELD", { enumerable: true, get: function () { return funnel_1.FUNNEL_CONVERSATION_FIELD; } });
  68. // 仪表盘及类型定义 | author by [hustcc](https://github.com/hustcc)
  69. var gauge_1 = require("./plots/gauge");
  70. Object.defineProperty(exports, "Gauge", { enumerable: true, get: function () { return gauge_1.Gauge; } });
  71. // 热力图及类型定义 | author by [jiazhewang](https://github.com/jiazhewang)
  72. var heatmap_1 = require("./plots/heatmap");
  73. Object.defineProperty(exports, "Heatmap", { enumerable: true, get: function () { return heatmap_1.Heatmap; } });
  74. // 直方图及类型定义 | author by [arcsin1](https://github.com/arcsin1), [visiky](https://github.com/visiky)
  75. var histogram_1 = require("./plots/histogram");
  76. Object.defineProperty(exports, "Histogram", { enumerable: true, get: function () { return histogram_1.Histogram; } });
  77. // 折线图及类型定义 | author by [hustcc](https://github.com/hustcc)
  78. var line_1 = require("./plots/line");
  79. Object.defineProperty(exports, "Line", { enumerable: true, get: function () { return line_1.Line; } });
  80. // 水波图及类型定义 | author by [CarisL](https://github.com/CarisL), [hustcc](https://github.com/hustcc), [pearmini](https://github.com/pearmini)
  81. var liquid_1 = require("./plots/liquid");
  82. Object.defineProperty(exports, "addWaterWave", { enumerable: true, get: function () { return liquid_1.addWaterWave; } });
  83. Object.defineProperty(exports, "Liquid", { enumerable: true, get: function () { return liquid_1.Liquid; } });
  84. // 已经废弃,更名为 Mix
  85. var mix_1 = require("./plots/mix");
  86. Object.defineProperty(exports, "Mix", { enumerable: true, get: function () { return mix_1.Mix; } });
  87. Object.defineProperty(exports, "MultiView", { enumerable: true, get: function () { return mix_1.Mix; } });
  88. // 饼图及类型定义 | author by [visiky](https://github.com/visiky)
  89. var pie_1 = require("./plots/pie");
  90. Object.defineProperty(exports, "Pie", { enumerable: true, get: function () { return pie_1.Pie; } });
  91. // 进度图及类型定义 | author by [connono](https://github.com/connono)
  92. var progress_1 = require("./plots/progress");
  93. Object.defineProperty(exports, "Progress", { enumerable: true, get: function () { return progress_1.Progress; } });
  94. // 雷达图及类型定义 | author by [visiky](https://github.com/visiky)
  95. var radar_1 = require("./plots/radar");
  96. Object.defineProperty(exports, "Radar", { enumerable: true, get: function () { return radar_1.Radar; } });
  97. // 玉珏图 | author by [yujs](https://github.com/yujs) | updated by [visiky](https://github.com/visiky)
  98. var radial_bar_1 = require("./plots/radial-bar");
  99. Object.defineProperty(exports, "RadialBar", { enumerable: true, get: function () { return radial_bar_1.RadialBar; } });
  100. // 环形进度图及类型定义 | author by [connono](https://github.com/connono)
  101. var ring_progress_1 = require("./plots/ring-progress");
  102. Object.defineProperty(exports, "RingProgress", { enumerable: true, get: function () { return ring_progress_1.RingProgress; } });
  103. // 玫瑰图及类型定义 | author by [zhangzhonghe](https://github.com/zhangzhonghe)
  104. var rose_1 = require("./plots/rose");
  105. Object.defineProperty(exports, "Rose", { enumerable: true, get: function () { return rose_1.Rose; } });
  106. // 桑基图及类型定义 | author by [hustcc](https://github.com/hustcc)
  107. var sankey_1 = require("./plots/sankey");
  108. Object.defineProperty(exports, "Sankey", { enumerable: true, get: function () { return sankey_1.Sankey; } });
  109. // 散点图及类型定义 | author by [lxfu1](https://github.com/lxfu1)
  110. var scatter_1 = require("./plots/scatter");
  111. Object.defineProperty(exports, "Scatter", { enumerable: true, get: function () { return scatter_1.Scatter; } });
  112. // K线图及类型定义 | author by [jhwong](https://github.com/jinhuiWong), [visiky](https://github.com/visiky)
  113. var stock_1 = require("./plots/stock");
  114. Object.defineProperty(exports, "Stock", { enumerable: true, get: function () { return stock_1.Stock; } });
  115. // 旭日图及类型定义 | author by [lxfu1](https://github.com/lxfu1), [visiky](https://github.com/visiky)
  116. var sunburst_1 = require("./plots/sunburst");
  117. Object.defineProperty(exports, "Sunburst", { enumerable: true, get: function () { return sunburst_1.Sunburst; } });
  118. // 迷你面积图及类型定义 | author by [connono](https://github.com/connono)
  119. var tiny_area_1 = require("./plots/tiny-area");
  120. Object.defineProperty(exports, "TinyArea", { enumerable: true, get: function () { return tiny_area_1.TinyArea; } });
  121. // 迷你柱形图及类型定义 | author by [connono](https://github.com/connono)
  122. var tiny_column_1 = require("./plots/tiny-column");
  123. Object.defineProperty(exports, "TinyColumn", { enumerable: true, get: function () { return tiny_column_1.TinyColumn; } });
  124. // 迷你折线图及类型定义 | author by [connono](https://github.com/connono)
  125. var tiny_line_1 = require("./plots/tiny-line");
  126. Object.defineProperty(exports, "TinyLine", { enumerable: true, get: function () { return tiny_line_1.TinyLine; } });
  127. // 矩形树图
  128. var treemap_1 = require("./plots/treemap");
  129. Object.defineProperty(exports, "Treemap", { enumerable: true, get: function () { return treemap_1.Treemap; } });
  130. // 韦恩图及类型定义 | author by [visiky](https://github.com/visiky)
  131. var venn_1 = require("./plots/venn");
  132. Object.defineProperty(exports, "Venn", { enumerable: true, get: function () { return venn_1.Venn; } });
  133. // 小提琴图及类型定义 | author by [YiSiWang](https://github.com/YiSiWang), [visiky](https://github.com/visiky)
  134. var violin_1 = require("./plots/violin");
  135. Object.defineProperty(exports, "Violin", { enumerable: true, get: function () { return violin_1.Violin; } });
  136. // 瀑布图 | author by [visiky](https://github.com/visiky)
  137. var waterfall_1 = require("./plots/waterfall");
  138. Object.defineProperty(exports, "Waterfall", { enumerable: true, get: function () { return waterfall_1.Waterfall; } });
  139. // 词云图及类型定义 | author by [zhangzhonghe](https://github.com/zhangzhonghe)
  140. var word_cloud_1 = require("./plots/word-cloud");
  141. Object.defineProperty(exports, "WordCloud", { enumerable: true, get: function () { return word_cloud_1.WordCloud; } });
  142. // 以下开放自定义图表开发的能力(目前仅仅是孵化中)
  143. /** 所有开放图表都使用 G2Plot.P 作为入口开发,理论上官方的所有图表都可以走 G2Plot.P 的入口(暂时不处理) */
  144. var plugin_1 = require("./plugin");
  145. Object.defineProperty(exports, "P", { enumerable: true, get: function () { return plugin_1.P; } });
  146. // 类型定义导出
  147. tslib_1.__exportStar(require("./types"), exports);
  148. /** 开发 adaptor 可能会用到的方法或一些工具方法,不强制使用 */
  149. var utils_1 = require("./utils");
  150. Object.defineProperty(exports, "flow", { enumerable: true, get: function () { return utils_1.flow; } });
  151. Object.defineProperty(exports, "measureTextWidth", { enumerable: true, get: function () { return utils_1.measureTextWidth; } });
  152. /** 开放 getCanvasPatterng 方法 */
  153. var pattern_1 = require("./utils/pattern");
  154. Object.defineProperty(exports, "getCanvasPattern", { enumerable: true, get: function () { return pattern_1.getCanvasPattern; } });
  155. /** default locale register */
  156. (0, locale_1.registerLocale)('en-US', en_US_1.EN_US_LOCALE);
  157. (0, locale_1.registerLocale)('zh-CN', zh_CN_1.ZH_CN_LOCALE);
  158. exports.adaptors = { scale: common_1.scale, legend: common_1.legend, tooltip: common_1.tooltip, annotation: common_1.annotation, interaction: common_1.interaction, theme: common_1.theme, animation: common_1.animation };
  159. //# sourceMappingURL=index.js.map