@univerjs-pro/sheets-chart 1.0.0-alpha.1 → 1.0.0-alpha.3

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 (105) hide show
  1. package/README.md +8 -2
  2. package/lib/cjs/facade.js +1 -1
  3. package/lib/cjs/index.js +1 -1
  4. package/lib/cjs/locale/ar-SA.js +1 -1
  5. package/lib/cjs/locale/ca-ES.js +1 -1
  6. package/lib/cjs/locale/de-DE.js +1 -1
  7. package/lib/cjs/locale/en-US.js +1 -1
  8. package/lib/cjs/locale/es-ES.js +1 -1
  9. package/lib/cjs/locale/fa-IR.js +1 -1
  10. package/lib/cjs/locale/fr-FR.js +1 -1
  11. package/lib/cjs/locale/id-ID.js +1 -1
  12. package/lib/cjs/locale/it-IT.js +1 -1
  13. package/lib/cjs/locale/ja-JP.js +1 -1
  14. package/lib/cjs/locale/ko-KR.js +1 -1
  15. package/lib/cjs/locale/pl-PL.js +1 -1
  16. package/lib/cjs/locale/pt-BR.js +1 -1
  17. package/lib/cjs/locale/ru-RU.js +1 -1
  18. package/lib/cjs/locale/sk-SK.js +1 -1
  19. package/lib/cjs/locale/vi-VN.js +1 -1
  20. package/lib/cjs/locale/zh-CN.js +1 -1
  21. package/lib/cjs/locale/zh-HK.js +1 -1
  22. package/lib/cjs/locale/zh-TW.js +1 -1
  23. package/lib/es/facade.js +1 -1
  24. package/lib/es/index.js +1 -1
  25. package/lib/es/locale/ar-SA.js +1 -1
  26. package/lib/es/locale/ca-ES.js +1 -1
  27. package/lib/es/locale/de-DE.js +1 -1
  28. package/lib/es/locale/en-US.js +1 -1
  29. package/lib/es/locale/es-ES.js +1 -1
  30. package/lib/es/locale/fa-IR.js +1 -1
  31. package/lib/es/locale/fr-FR.js +1 -1
  32. package/lib/es/locale/id-ID.js +1 -1
  33. package/lib/es/locale/it-IT.js +1 -1
  34. package/lib/es/locale/ja-JP.js +1 -1
  35. package/lib/es/locale/ko-KR.js +1 -1
  36. package/lib/es/locale/pl-PL.js +1 -1
  37. package/lib/es/locale/pt-BR.js +1 -1
  38. package/lib/es/locale/ru-RU.js +1 -1
  39. package/lib/es/locale/sk-SK.js +1 -1
  40. package/lib/es/locale/vi-VN.js +1 -1
  41. package/lib/es/locale/zh-CN.js +1 -1
  42. package/lib/es/locale/zh-HK.js +1 -1
  43. package/lib/es/locale/zh-TW.js +1 -1
  44. package/lib/facade.js +1 -1
  45. package/lib/index.js +1 -1
  46. package/lib/locale/ar-SA.js +1 -1
  47. package/lib/locale/ca-ES.js +1 -1
  48. package/lib/locale/de-DE.js +1 -1
  49. package/lib/locale/en-US.js +1 -1
  50. package/lib/locale/es-ES.js +1 -1
  51. package/lib/locale/fa-IR.js +1 -1
  52. package/lib/locale/fr-FR.js +1 -1
  53. package/lib/locale/id-ID.js +1 -1
  54. package/lib/locale/it-IT.js +1 -1
  55. package/lib/locale/ja-JP.js +1 -1
  56. package/lib/locale/ko-KR.js +1 -1
  57. package/lib/locale/pl-PL.js +1 -1
  58. package/lib/locale/pt-BR.js +1 -1
  59. package/lib/locale/ru-RU.js +1 -1
  60. package/lib/locale/sk-SK.js +1 -1
  61. package/lib/locale/vi-VN.js +1 -1
  62. package/lib/locale/zh-CN.js +1 -1
  63. package/lib/locale/zh-HK.js +1 -1
  64. package/lib/locale/zh-TW.js +1 -1
  65. package/lib/types/chart-source/chart-source.d.ts +0 -1
  66. package/lib/types/commands/commands/sheets-chart.command.d.ts +4 -4
  67. package/lib/types/commands/mutations/sheets-chart.mutation.d.ts +15 -5
  68. package/lib/types/common/util.d.ts +1 -1
  69. package/lib/types/config/config.d.ts +5 -0
  70. package/lib/types/facade/chart-facade-adapter.d.ts +68 -0
  71. package/lib/types/facade/chart-facade-builders.d.ts +67 -0
  72. package/lib/types/facade/chart-facade-types.d.ts +212 -0
  73. package/lib/types/facade/f-chart.d.ts +36 -2
  74. package/lib/types/facade/f-worksheet-charts.d.ts +93 -0
  75. package/lib/types/facade/f-worksheet.d.ts +3 -0
  76. package/lib/types/facade/index.d.ts +6 -0
  77. package/lib/types/index.d.ts +5 -6
  78. package/lib/types/models/chart-model.d.ts +3 -3
  79. package/lib/types/models/types.d.ts +4 -1
  80. package/lib/types/plugin.d.ts +1 -0
  81. package/lib/types/services/chart-model.service.d.ts +2 -0
  82. package/lib/types/services/sheet-chart-range-watcher.d.ts +22 -0
  83. package/lib/types/services/sheets-chart.service.d.ts +8 -8
  84. package/lib/umd/facade.js +1 -1
  85. package/lib/umd/index.js +1 -1
  86. package/lib/umd/locale/ar-SA.js +1 -1
  87. package/lib/umd/locale/ca-ES.js +1 -1
  88. package/lib/umd/locale/de-DE.js +1 -1
  89. package/lib/umd/locale/en-US.js +1 -1
  90. package/lib/umd/locale/es-ES.js +1 -1
  91. package/lib/umd/locale/fa-IR.js +1 -1
  92. package/lib/umd/locale/fr-FR.js +1 -1
  93. package/lib/umd/locale/id-ID.js +1 -1
  94. package/lib/umd/locale/it-IT.js +1 -1
  95. package/lib/umd/locale/ja-JP.js +1 -1
  96. package/lib/umd/locale/ko-KR.js +1 -1
  97. package/lib/umd/locale/pl-PL.js +1 -1
  98. package/lib/umd/locale/pt-BR.js +1 -1
  99. package/lib/umd/locale/ru-RU.js +1 -1
  100. package/lib/umd/locale/sk-SK.js +1 -1
  101. package/lib/umd/locale/vi-VN.js +1 -1
  102. package/lib/umd/locale/zh-CN.js +1 -1
  103. package/lib/umd/locale/zh-HK.js +1 -1
  104. package/lib/umd/locale/zh-TW.js +1 -1
  105. package/package.json +10 -10
@@ -1 +1 @@
1
- const _0x260ddf=_0x5ba2;function _0x5ba2(_0x51b7f8,_0x133085){_0x51b7f8=_0x51b7f8-0xef;const _0xedff47=_0xedff();let _0x5ba259=_0xedff47[_0x51b7f8];return _0x5ba259;}(function(_0x4af275,_0x5dec7d){const _0x3fb6ba=_0x5ba2,_0x1384c0=_0x4af275();while(!![]){try{const _0x38417f=-parseInt(_0x3fb6ba(0xf3))/0x1+-parseInt(_0x3fb6ba(0xf1))/0x2+parseInt(_0x3fb6ba(0xf2))/0x3*(parseInt(_0x3fb6ba(0xff))/0x4)+parseInt(_0x3fb6ba(0xf9))/0x5+parseInt(_0x3fb6ba(0xf8))/0x6*(parseInt(_0x3fb6ba(0x105))/0x7)+-parseInt(_0x3fb6ba(0xef))/0x8*(parseInt(_0x3fb6ba(0xf6))/0x9)+parseInt(_0x3fb6ba(0x102))/0xa*(parseInt(_0x3fb6ba(0x107))/0xb);if(_0x38417f===_0x5dec7d)break;else _0x1384c0['push'](_0x1384c0['shift']());}catch(_0x2b00a5){_0x1384c0['push'](_0x1384c0['shift']());}}}(_0xedff,0x742b0));const e={'sheets-chart':{'category':_0x260ddf(0xfb),'series':_0x260ddf(0xf4),'seriesDefaultName':'Серия\x20{0}','categoryDefaultName':_0x260ddf(0xfa),'blank':_0x260ddf(0xfe),'msg':{'emptyTips':_0x260ddf(0xfc),'sankeyCircularTips':_0x260ddf(0x100)},'bubble':{'emptyTips':_0x260ddf(0x104)},'relation':{'emptyTips':_0x260ddf(0xf7)},'cloud':{'word':_0x260ddf(0xf5),'frequency':_0x260ddf(0xf0)},'waterfall':{'positive':'Положительное','negative':'Отрицательное','subtotal':_0x260ddf(0xfd)},'pareto':{'lineName':'Накопительный\x20процент'},'boxplot':{'min':_0x260ddf(0x103),'q1':'Первый\x20квартиль','median':_0x260ddf(0x106),'q3':_0x260ddf(0x101),'max':_0x260ddf(0x108)}}};function _0xedff(){const _0x43a303=['Слово','180uhKVus','Источником\x20данных\x20для\x20графика\x20взаимоотношений\x20является\x20матрица\x20сопутствующих\x20слов\x20с\x20дополнительным\x20столбцом\x20типа\x20во\x20втором\x20столбце.','162798yXNRzF','4242090jrtxjR','Категория\x20{0}','Category','Добавьте\x20серию,\x20чтобы\x20начать\x20визуализацию\x20данных','Промежуточный\x20итог','Пусто','37688gZjTpl','Диаграмма\x20Санки\x20не\x20может\x20содержать\x20циклические\x20данные','Третий\x20квартиль','20WpOaXq','Минимум','Диаграмма\x20пузырей\x20требует\x20как\x20минимум\x202\x20столбца:\x20ось\x20X,\x20ось\x20Y','224TOtwau','Медиана','1708619iFeYaj','Максимум','376928Uzcxms','Частота','671998rAxmlF','123TMykzv','659491FkGFWN','Series'];_0xedff=function(){return _0x43a303;};return _0xedff();}export{e as default};
1
+ const _0x220468=_0x5469;function _0x1ebb(){const _0x7f0121=['Отрицательное','Третий\x20квартиль','3188584wjrQkP','2352DgKEOa','116WOHxFh','Добавьте\x20серию,\x20чтобы\x20начать\x20визуализацию\x20данных','Слово','Минимум','Ряд\x20данных','Положительное','Накопительный\x20процент','Первый\x20квартиль','48788bjIXFj','Промежуточный\x20итог','4896120APDsJP','5yMqPDJ','Медиана','Максимум','15645tKryXU','Источником\x20данных\x20для\x20графика\x20взаимоотношений\x20является\x20матрица\x20сопутствующих\x20слов\x20с\x20дополнительным\x20столбцом\x20типа\x20во\x20втором\x20столбце.','9VnLeQM','Серия\x20{0}','13106071nTubQQ','Частота','4753AyBUwY','8035460pzBnxA','Категория'];_0x1ebb=function(){return _0x7f0121;};return _0x1ebb();}(function(_0x37ea83,_0x55adbf){const _0x2539d4=_0x5469,_0x697830=_0x37ea83();while(!![]){try{const _0x52a2c3=-parseInt(_0x2539d4(0x177))/0x1*(-parseInt(_0x2539d4(0x174))/0x2)+-parseInt(_0x2539d4(0x17a))/0x3*(-parseInt(_0x2539d4(0x187))/0x4)+parseInt(_0x2539d4(0x176))/0x5+parseInt(_0x2539d4(0x186))/0x6*(parseInt(_0x2539d4(0x180))/0x7)+parseInt(_0x2539d4(0x185))/0x8*(-parseInt(_0x2539d4(0x17c))/0x9)+parseInt(_0x2539d4(0x181))/0xa+-parseInt(_0x2539d4(0x17e))/0xb;if(_0x52a2c3===_0x55adbf)break;else _0x697830['push'](_0x697830['shift']());}catch(_0x4c3f07){_0x697830['push'](_0x697830['shift']());}}}(_0x1ebb,0xb2bcd));function _0x5469(_0x131191,_0x31be6f){_0x131191=_0x131191-0x16f;const _0x1ebb52=_0x1ebb();let _0x5469df=_0x1ebb52[_0x131191];return _0x5469df;}const e={'sheets-chart':{'category':_0x220468(0x182),'series':_0x220468(0x170),'seriesDefaultName':_0x220468(0x17d),'categoryDefaultName':'Категория\x20{0}','blank':'Пусто','msg':{'emptyTips':_0x220468(0x188),'sankeyCircularTips':'Диаграмма\x20Санки\x20не\x20может\x20содержать\x20циклические\x20данные'},'bubble':{'emptyTips':'Диаграмма\x20пузырей\x20требует\x20как\x20минимум\x202\x20столбца:\x20ось\x20X,\x20ось\x20Y'},'relation':{'emptyTips':_0x220468(0x17b)},'cloud':{'word':_0x220468(0x189),'frequency':_0x220468(0x17f)},'waterfall':{'positive':_0x220468(0x171),'negative':_0x220468(0x183),'subtotal':_0x220468(0x175)},'pareto':{'lineName':_0x220468(0x172)},'boxplot':{'min':_0x220468(0x16f),'q1':_0x220468(0x173),'median':_0x220468(0x178),'q3':_0x220468(0x184),'max':_0x220468(0x179)}}};export{e as default};
@@ -1 +1 @@
1
- const _0x45b312=_0x1054;(function(_0x41e23c,_0x4ac829){const _0x4fd0dc=_0x1054,_0x2284ac=_0x41e23c();while(!![]){try{const _0x496f0a=parseInt(_0x4fd0dc(0x148))/0x1+parseInt(_0x4fd0dc(0x140))/0x2*(-parseInt(_0x4fd0dc(0x143))/0x3)+parseInt(_0x4fd0dc(0x135))/0x4+-parseInt(_0x4fd0dc(0x138))/0x5+parseInt(_0x4fd0dc(0x13f))/0x6*(-parseInt(_0x4fd0dc(0x136))/0x7)+parseInt(_0x4fd0dc(0x13d))/0x8*(parseInt(_0x4fd0dc(0x13c))/0x9)+-parseInt(_0x4fd0dc(0x146))/0xa;if(_0x496f0a===_0x4ac829)break;else _0x2284ac['push'](_0x2284ac['shift']());}catch(_0x192314){_0x2284ac['push'](_0x2284ac['shift']());}}}(_0x44ff,0x34980));const e={'sheets-chart':{'category':'Category','series':_0x45b312(0x13b),'seriesDefaultName':'Séria\x20{0}','categoryDefaultName':_0x45b312(0x142),'blank':_0x45b312(0x139),'msg':{'emptyTips':_0x45b312(0x144),'sankeyCircularTips':_0x45b312(0x141)},'bubble':{'emptyTips':_0x45b312(0x13e)},'relation':{'emptyTips':_0x45b312(0x134)},'cloud':{'word':'Slovo','frequency':_0x45b312(0x145)},'waterfall':{'positive':'Pozitívne','negative':_0x45b312(0x13a),'subtotal':'Medzisúčet'},'pareto':{'lineName':_0x45b312(0x147)},'boxplot':{'min':'Minimum','q1':'Prvý\x20kvartil','median':'Medián','q3':_0x45b312(0x137),'max':'Maximum'}}};function _0x44ff(){const _0x541f72=['(Prázdne)','Negatívne','Series','27RhnEae','521336pyLtFM','Bublinový\x20graf\x20vyžaduje\x20aspoň\x202\x20stĺpce:\x20os\x20X,\x20os\x20Y','954VstpUP','2MuMTzM','Sankeyho\x20graf\x20nemôže\x20obsahovať\x20cyklické\x20údaje','Kategória\x20{0}','18075BIfdNO','Pridajte\x20sériu\x20a\x20začnite\x20vizualizovať\x20údaje','Frekvencia','1754630yBfbND','Kumulatívne\x20percento','106938tkNnti','Zdrojové\x20dáta\x20pre\x20graf\x20vzťahov\x20sú\x20ko-slovná\x20matica\x20s\x20dodatočným\x20typovým\x20stĺpcom\x20v\x20druhom\x20stĺpci','1463856yrbhHd','581gtwMVw','Tretí\x20kvartil','1291470nNkfqj'];_0x44ff=function(){return _0x541f72;};return _0x44ff();}function _0x1054(_0x12f975,_0x5a55d4){_0x12f975=_0x12f975-0x134;const _0x44ff64=_0x44ff();let _0x105486=_0x44ff64[_0x12f975];return _0x105486;}export{e as default};
1
+ function _0x566b(){const _0x5d2dca=['Bublinový\x20graf\x20vyžaduje\x20aspoň\x202\x20stĺpce:\x20os\x20X,\x20os\x20Y','Tretí\x20kvartil','1142940OhMkrJ','Frekvencia','636020GPPgcc','Kumulatívne\x20percento','Séria\x20{0}','1065750aoiXkZ','Pozitívne','593224zkXcNA','118680yYposc','Kategória','429891cVNDyQ','Pridajte\x20sériu\x20a\x20začnite\x20vizualizovať\x20údaje','Slovo','Prvý\x20kvartil','Zdrojové\x20dáta\x20pre\x20graf\x20vzťahov\x20sú\x20ko-slovná\x20matica\x20s\x20dodatočným\x20typovým\x20stĺpcom\x20v\x20druhom\x20stĺpci','Maximum','Sankeyho\x20graf\x20nemôže\x20obsahovať\x20cyklické\x20údaje','80297EIlbmW','Medián','(Prázdne)','472pPaNXL'];_0x566b=function(){return _0x5d2dca;};return _0x566b();}const _0x2aaf3a=_0x553d;(function(_0x5b4881,_0x41cc9a){const _0x324214=_0x553d,_0x4b01c1=_0x5b4881();while(!![]){try{const _0x117715=-parseInt(_0x324214(0x8d))/0x1+parseInt(_0x324214(0x9c))/0x2+-parseInt(_0x324214(0x8b))/0x3+-parseInt(_0x324214(0x8a))/0x4+parseInt(_0x324214(0x9f))/0x5+-parseInt(_0x324214(0x9a))/0x6+parseInt(_0x324214(0x94))/0x7*(parseInt(_0x324214(0x97))/0x8);if(_0x117715===_0x41cc9a)break;else _0x4b01c1['push'](_0x4b01c1['shift']());}catch(_0x241a66){_0x4b01c1['push'](_0x4b01c1['shift']());}}}(_0x566b,0x61956));function _0x553d(_0x675671,_0x4e676e){_0x675671=_0x675671-0x8a;const _0x566b08=_0x566b();let _0x553d33=_0x566b08[_0x675671];return _0x553d33;}const e={'sheets-chart':{'category':_0x2aaf3a(0x8c),'series':'Séria','seriesDefaultName':_0x2aaf3a(0x9e),'categoryDefaultName':'Kategória\x20{0}','blank':_0x2aaf3a(0x96),'msg':{'emptyTips':_0x2aaf3a(0x8e),'sankeyCircularTips':_0x2aaf3a(0x93)},'bubble':{'emptyTips':_0x2aaf3a(0x98)},'relation':{'emptyTips':_0x2aaf3a(0x91)},'cloud':{'word':_0x2aaf3a(0x8f),'frequency':_0x2aaf3a(0x9b)},'waterfall':{'positive':_0x2aaf3a(0xa0),'negative':'Negatívne','subtotal':'Medzisúčet'},'pareto':{'lineName':_0x2aaf3a(0x9d)},'boxplot':{'min':'Minimum','q1':_0x2aaf3a(0x90),'median':_0x2aaf3a(0x95),'q3':_0x2aaf3a(0x99),'max':_0x2aaf3a(0x92)}}};export{e as default};
@@ -1 +1 @@
1
- const _0x4445f0=_0xc334;(function(_0x425597,_0x3abd31){const _0x15e526=_0xc334,_0x5a2714=_0x425597();while(!![]){try{const _0x468ddd=-parseInt(_0x15e526(0x7e))/0x1*(-parseInt(_0x15e526(0x82))/0x2)+parseInt(_0x15e526(0x8b))/0x3+parseInt(_0x15e526(0x8d))/0x4*(-parseInt(_0x15e526(0x90))/0x5)+-parseInt(_0x15e526(0x8e))/0x6*(parseInt(_0x15e526(0x86))/0x7)+-parseInt(_0x15e526(0x87))/0x8+parseInt(_0x15e526(0x8a))/0x9*(parseInt(_0x15e526(0x8f))/0xa)+parseInt(_0x15e526(0x94))/0xb;if(_0x468ddd===_0x3abd31)break;else _0x5a2714['push'](_0x5a2714['shift']());}catch(_0x13c59b){_0x5a2714['push'](_0x5a2714['shift']());}}}(_0x1005,0x769e3));function _0x1005(){const _0x1385d9=['Loạt\x20{0}','1749820NStPbh','5898UySync','11250tvfOfj','5ZXlZGy','Giá\x20trị\x20âm','Tổng\x20phụ','Phần\x20tư\x20thứ\x20ba','16497173LkoNib','Series','374924XfRZUS','Phần\x20tư\x20thứ\x20nhất','Giá\x20trị\x20dương','Không\x20có\x20dữ\x20liệu\x20để\x20hiển\x20thị.','2PdxArQ','Category','Biểu\x20đồ\x20bong\x20bóng\x20yêu\x20cầu\x20ít\x20nhất\x202\x20cột:\x20trục\x20X,\x20trục\x20Y','Trung\x20vị','3563wnobvt','7238912YExXCL','Giá\x20trị\x20lớn\x20nhất','(Trống)','423sGWoeo','1202949kvspve'];_0x1005=function(){return _0x1385d9;};return _0x1005();}const e={'sheets-chart':{'category':_0x4445f0(0x83),'series':_0x4445f0(0x95),'seriesDefaultName':_0x4445f0(0x8c),'categoryDefaultName':'Danh\x20mục\x20{0}','blank':_0x4445f0(0x89),'msg':{'emptyTips':_0x4445f0(0x81),'sankeyCircularTips':'Biểu\x20đồ\x20Sankey\x20không\x20thể\x20chứa\x20dữ\x20liệu\x20vòng\x20lặp'},'bubble':{'emptyTips':_0x4445f0(0x84)},'relation':{'emptyTips':'Nguồn\x20dữ\x20liệu\x20cho\x20biểu\x20đồ\x20quan\x20hệ\x20là\x20ma\x20trận\x20đồng\x20từ\x20với\x20cột\x20loại\x20bổ\x20sung\x20ở\x20cột\x20thứ\x20hai'},'cloud':{'word':'Từ','frequency':'Tần\x20suất'},'waterfall':{'positive':_0x4445f0(0x80),'negative':_0x4445f0(0x91),'subtotal':_0x4445f0(0x92)},'pareto':{'lineName':'Tỷ\x20lệ\x20tích\x20lũy'},'boxplot':{'min':'Giá\x20trị\x20nhỏ\x20nhất','q1':_0x4445f0(0x7f),'median':_0x4445f0(0x85),'q3':_0x4445f0(0x93),'max':_0x4445f0(0x88)}}};function _0xc334(_0x239766,_0x5745dc){_0x239766=_0x239766-0x7e;const _0x100501=_0x1005();let _0xc334e1=_0x100501[_0x239766];return _0xc334e1;}export{e as default};
1
+ function _0x3579(){const _0xc3e89=['Trung\x20vị','11hApFdF','180860McghQm','3wryHSl','Biểu\x20đồ\x20bong\x20bóng\x20yêu\x20cầu\x20ít\x20nhất\x202\x20cột:\x20trục\x20X,\x20trục\x20Y','Loạt\x20{0}','1014416qdLXCm','406287CdkvwN','Giá\x20trị\x20âm','Tổng\x20phụ','(Trống)','Giá\x20trị\x20nhỏ\x20nhất','6457761JlMCsC','Tỷ\x20lệ\x20tích\x20lũy','222GGfzAo','40540860PJgmXW','Biểu\x20đồ\x20Sankey\x20không\x20thể\x20chứa\x20dữ\x20liệu\x20vòng\x20lặp','2129060FkbrSd','Tần\x20suất','Danh\x20mục\x20{0}','3535364JnyVTt','Chuỗi','24cAPQpb','Nguồn\x20dữ\x20liệu\x20cho\x20biểu\x20đồ\x20quan\x20hệ\x20là\x20ma\x20trận\x20đồng\x20từ\x20với\x20cột\x20loại\x20bổ\x20sung\x20ở\x20cột\x20thứ\x20hai'];_0x3579=function(){return _0xc3e89;};return _0x3579();}function _0x43ce(_0x4c9d1e,_0x207aed){_0x4c9d1e=_0x4c9d1e-0x118;const _0x357966=_0x3579();let _0x43cebd=_0x357966[_0x4c9d1e];return _0x43cebd;}const _0x49e3e6=_0x43ce;(function(_0x1ce286,_0x186edc){const _0x59411d=_0x43ce,_0x4c68bf=_0x1ce286();while(!![]){try{const _0x460643=parseInt(_0x59411d(0x11a))/0x1+parseInt(_0x59411d(0x125))/0x2+-parseInt(_0x59411d(0x12f))/0x3*(-parseInt(_0x59411d(0x128))/0x4)+parseInt(_0x59411d(0x12e))/0x5*(parseInt(_0x59411d(0x122))/0x6)+-parseInt(_0x59411d(0x11b))/0x7*(parseInt(_0x59411d(0x12a))/0x8)+parseInt(_0x59411d(0x120))/0x9+-parseInt(_0x59411d(0x123))/0xa*(parseInt(_0x59411d(0x12d))/0xb);if(_0x460643===_0x186edc)break;else _0x4c68bf['push'](_0x4c68bf['shift']());}catch(_0x4d92bc){_0x4c68bf['push'](_0x4c68bf['shift']());}}}(_0x3579,0xc0fc7));const e={'sheets-chart':{'category':'Danh\x20mục','series':_0x49e3e6(0x129),'seriesDefaultName':_0x49e3e6(0x119),'categoryDefaultName':_0x49e3e6(0x127),'blank':_0x49e3e6(0x11e),'msg':{'emptyTips':'Không\x20có\x20dữ\x20liệu\x20để\x20hiển\x20thị.','sankeyCircularTips':_0x49e3e6(0x124)},'bubble':{'emptyTips':_0x49e3e6(0x118)},'relation':{'emptyTips':_0x49e3e6(0x12b)},'cloud':{'word':'Từ','frequency':_0x49e3e6(0x126)},'waterfall':{'positive':'Giá\x20trị\x20dương','negative':_0x49e3e6(0x11c),'subtotal':_0x49e3e6(0x11d)},'pareto':{'lineName':_0x49e3e6(0x121)},'boxplot':{'min':_0x49e3e6(0x11f),'q1':'Phần\x20tư\x20thứ\x20nhất','median':_0x49e3e6(0x12c),'q3':'Phần\x20tư\x20thứ\x20ba','max':'Giá\x20trị\x20lớn\x20nhất'}}};export{e as default};
@@ -1 +1 @@
1
- const _0x1d2310=_0x4789;function _0x4789(_0x45620a,_0x15886b){_0x45620a=_0x45620a-0xa7;const _0x377d8d=_0x377d();let _0x4789f6=_0x377d8d[_0x45620a];return _0x4789f6;}(function(_0x45b448,_0x42c6cf){const _0x274217=_0x4789,_0x581a95=_0x45b448();while(!![]){try{const _0x20908d=-parseInt(_0x274217(0xa7))/0x1*(-parseInt(_0x274217(0xab))/0x2)+-parseInt(_0x274217(0xb3))/0x3+parseInt(_0x274217(0xa8))/0x4+-parseInt(_0x274217(0xb6))/0x5+-parseInt(_0x274217(0xb7))/0x6+-parseInt(_0x274217(0xb1))/0x7*(parseInt(_0x274217(0xac))/0x8)+parseInt(_0x274217(0xa9))/0x9;if(_0x20908d===_0x42c6cf)break;else _0x581a95['push'](_0x581a95['shift']());}catch(_0x1dcfc9){_0x581a95['push'](_0x581a95['shift']());}}}(_0x377d,0x6a9d2));function _0x377d(){const _0x4d2aff=['类别\x20{0}','累积占比','112112cVIshs','关系图数据源为额外添加类型列在第二列的共词矩阵','92280jBWFYS','Series','()','3137310XDCwZc','3088452HnnIFi','第一四分位数','1vPxUdJ','992180pyfadt','14997447rykvvP','气泡图至少需要2列,X轴、Y轴。','639700NmGuMr','312gfKTRn','最大值','桑基图不能包含循环数据'];_0x377d=function(){return _0x4d2aff;};return _0x377d();}const e={'sheets-chart':{'category':'Category','series':_0x1d2310(0xb4),'seriesDefaultName':'系列\x20{0}','categoryDefaultName':_0x1d2310(0xaf),'blank':_0x1d2310(0xb5),'msg':{'emptyTips':'请先添加系列开始数据可视化','sankeyCircularTips':_0x1d2310(0xae)},'bubble':{'emptyTips':_0x1d2310(0xaa)},'relation':{'emptyTips':_0x1d2310(0xb2)},'cloud':{'word':'词语','frequency':'频率'},'waterfall':{'positive':'正值','negative':'负值','subtotal':'小计'},'pareto':{'lineName':_0x1d2310(0xb0)},'boxplot':{'min':'最小值','q1':_0x1d2310(0xb8),'median':'中位数','q3':'第三四分位数','max':_0x1d2310(0xad)}}};export{e as default};
1
+ const _0x2d7ce1=_0x38cd;function _0x81f4(){const _0x353fab=['类别\x20{0}','桑基图不能包含循环数据','()','411152BlXXMo','最大值','314enjyuT','2207532otFlko','2280644DAzGJe','气泡图至少需要2列,X轴、Y轴。','5562448eSFfJb','3043845AkeeGf','1542191vIfuFO','第一四分位数','第三四分位数','系列\x20{0}','累积占比','3mBvhQW'];_0x81f4=function(){return _0x353fab;};return _0x81f4();}(function(_0x50e067,_0x5201cd){const _0x2fcb43=_0x38cd,_0x3ec98c=_0x50e067();while(!![]){try{const _0x7a4a5f=-parseInt(_0x2fcb43(0x105))/0x1+parseInt(_0x2fcb43(0x103))/0x2+-parseInt(_0x2fcb43(0xff))/0x3*(parseInt(_0x2fcb43(0xf6))/0x4)+-parseInt(_0x2fcb43(0xf9))/0x5+parseInt(_0x2fcb43(0xf5))/0x6+parseInt(_0x2fcb43(0xfa))/0x7+parseInt(_0x2fcb43(0xf8))/0x8;if(_0x7a4a5f===_0x5201cd)break;else _0x3ec98c['push'](_0x3ec98c['shift']());}catch(_0x58ea23){_0x3ec98c['push'](_0x3ec98c['shift']());}}}(_0x81f4,0x4ba71));function _0x38cd(_0x556ed3,_0x453f28){_0x556ed3=_0x556ed3-0xf5;const _0x81f43a=_0x81f4();let _0x38cd9d=_0x81f43a[_0x556ed3];return _0x38cd9d;}const e={'sheets-chart':{'category':'类别','series':'系列','seriesDefaultName':_0x2d7ce1(0xfd),'categoryDefaultName':_0x2d7ce1(0x100),'blank':_0x2d7ce1(0x102),'msg':{'emptyTips':'请先添加系列开始数据可视化','sankeyCircularTips':_0x2d7ce1(0x101)},'bubble':{'emptyTips':_0x2d7ce1(0xf7)},'relation':{'emptyTips':'关系图数据源为额外添加类型列在第二列的共词矩阵'},'cloud':{'word':'词语','frequency':'频率'},'waterfall':{'positive':'正值','negative':'负值','subtotal':'小计'},'pareto':{'lineName':_0x2d7ce1(0xfe)},'boxplot':{'min':'最小值','q1':_0x2d7ce1(0xfb),'median':'中位数','q3':_0x2d7ce1(0xfc),'max':_0x2d7ce1(0x104)}}};export{e as default};
@@ -1 +1 @@
1
- const _0x2692c6=_0x254c;function _0x254c(_0x265f35,_0x2c7ee5){_0x265f35=_0x265f35-0xfc;const _0x5632c0=_0x5632();let _0x254c85=_0x5632c0[_0x265f35];return _0x254c85;}(function(_0x18d761,_0x9925b4){const _0x40fc5f=_0x254c,_0x3f11b1=_0x18d761();while(!![]){try{const _0x124847=-parseInt(_0x40fc5f(0x111))/0x1*(-parseInt(_0x40fc5f(0x109))/0x2)+parseInt(_0x40fc5f(0x10b))/0x3+parseInt(_0x40fc5f(0x102))/0x4+parseInt(_0x40fc5f(0x103))/0x5+-parseInt(_0x40fc5f(0x10d))/0x6*(-parseInt(_0x40fc5f(0x108))/0x7)+-parseInt(_0x40fc5f(0xfe))/0x8*(-parseInt(_0x40fc5f(0xff))/0x9)+-parseInt(_0x40fc5f(0x107))/0xa;if(_0x124847===_0x9925b4)break;else _0x3f11b1['push'](_0x3f11b1['shift']());}catch(_0x3a8d50){_0x3f11b1['push'](_0x3f11b1['shift']());}}}(_0x5632,0xd7138));const e={'sheets-chart':{'category':_0x2692c6(0x105),'series':_0x2692c6(0xfd),'seriesDefaultName':_0x2692c6(0x10e),'categoryDefaultName':_0x2692c6(0x104),'blank':_0x2692c6(0x10a),'msg':{'emptyTips':_0x2692c6(0x101),'sankeyCircularTips':_0x2692c6(0x10f)},'bubble':{'emptyTips':_0x2692c6(0xfc)},'relation':{'emptyTips':'關係圖資料來源為額外新增類型欄在第二欄的共詞矩陣'},'cloud':{'word':'詞','frequency':'頻率'},'waterfall':{'positive':'正值','negative':'負值','subtotal':'小計'},'pareto':{'lineName':_0x2692c6(0x106)},'boxplot':{'min':_0x2692c6(0x110),'q1':_0x2692c6(0x10c),'median':'中位數','q3':_0x2692c6(0x112),'max':_0x2692c6(0x100)}}};export{e as default};function _0x5632(){const _0xf85716=['189XqUyqr','4wEECJG','(空)','960975AFYnAU','第一四分位數','203304rMUcxD','系列\x20{0}','桑基圖不能包含循環數據','最小值','851619AJpjof','第三四分位數','氣泡圖至少需要2欄,X軸、Y軸。','Series','7360dmvLSs','13617GJxSAM','最大值','請先添加系列開始數據可視化','6236044zcjYJk','2043310bsTyAW','類別\x20{0}','Category','累積占比','54171120vZnnhO'];_0x5632=function(){return _0xf85716;};return _0x5632();}
1
+ function _0x19c4(_0xdeac7a,_0x5c8c4f){_0xdeac7a=_0xdeac7a-0x11d;const _0x5ce57e=_0x5ce5();let _0x19c483=_0x5ce57e[_0xdeac7a];return _0x19c483;}const _0x5180fe=_0x19c4;(function(_0x4a082b,_0x2b0306){const _0x3751bb=_0x19c4,_0x1cb8ea=_0x4a082b();while(!![]){try{const _0x25104e=parseInt(_0x3751bb(0x11f))/0x1*(parseInt(_0x3751bb(0x12a))/0x2)+-parseInt(_0x3751bb(0x123))/0x3+-parseInt(_0x3751bb(0x12d))/0x4+-parseInt(_0x3751bb(0x122))/0x5+-parseInt(_0x3751bb(0x12b))/0x6*(parseInt(_0x3751bb(0x120))/0x7)+-parseInt(_0x3751bb(0x129))/0x8*(-parseInt(_0x3751bb(0x121))/0x9)+parseInt(_0x3751bb(0x127))/0xa;if(_0x25104e===_0x2b0306)break;else _0x1cb8ea['push'](_0x1cb8ea['shift']());}catch(_0x36dd79){_0x1cb8ea['push'](_0x1cb8ea['shift']());}}}(_0x5ce5,0x4250d));const e={'sheets-chart':{'category':'類別','series':'系列','seriesDefaultName':_0x5180fe(0x11d),'categoryDefaultName':_0x5180fe(0x125),'blank':_0x5180fe(0x12f),'msg':{'emptyTips':'請先添加系列開始數據可視化','sankeyCircularTips':_0x5180fe(0x126)},'bubble':{'emptyTips':_0x5180fe(0x12e)},'relation':{'emptyTips':'關係圖資料來源為額外新增類型欄在第二欄的共詞矩陣'},'cloud':{'word':'詞','frequency':'頻率'},'waterfall':{'positive':'正值','negative':'負值','subtotal':'小計'},'pareto':{'lineName':_0x5180fe(0x12c)},'boxplot':{'min':'最小值','q1':'第一四分位數','median':_0x5180fe(0x124),'q3':_0x5180fe(0x128),'max':_0x5180fe(0x11e)}}};export{e as default};function _0x5ce5(){const _0x545081=['1933765CRrNin','1108929ACCiXJ','中位數','類別\x20{0}','桑基圖不能包含循環數據','13490690dmhiLL','第三四分位數','2000sOsyEG','294776KiNaNU','1158hEVKTh','累積占比','2085868CTViHF','氣泡圖至少需要2欄,X軸、Y軸。','(空)','系列\x20{0}','最大值','2darkGO','18347pJPsBu','14814WfycuX'];_0x5ce5=function(){return _0x545081;};return _0x5ce5();}
@@ -1 +1 @@
1
- function _0x5b67(_0x5c2402,_0x378d1a){_0x5c2402=_0x5c2402-0x1bc;const _0x5348e7=_0x5348();let _0x5b6708=_0x5348e7[_0x5c2402];return _0x5b6708;}const _0x1274f6=_0x5b67;function _0x5348(){const _0x9dee=['關係圖資料來源為額外新增類型欄在第二欄的共詞矩陣','2782gTYoAU','系列\x20{0}','最大值','930662RApRlA','2188pNYSKW','2765WImomC','9ZVghGp','1TpOfnm','801196jBnnHD','133428tlPziL','最小值','桑基圖不能包含循環數據','中位數','18pxdKMn','1240740LtNXqC','2922563YpDBaX','氣泡圖至少需要2欄,X軸、Y軸。','第三四分位數','20tkohpf','累積占比','請先添加系列開始數據可視化','4476184qjkgDG','Series','類別\x20{0}'];_0x5348=function(){return _0x9dee;};return _0x5348();}(function(_0x5c9ee6,_0x28177f){const _0x40f709=_0x5b67,_0xeccaa6=_0x5c9ee6();while(!![]){try{const _0x7f9999=-parseInt(_0x40f709(0x1c2))/0x1*(parseInt(_0x40f709(0x1be))/0x2)+-parseInt(_0x40f709(0x1c9))/0x3+-parseInt(_0x40f709(0x1bf))/0x4*(parseInt(_0x40f709(0x1c0))/0x5)+parseInt(_0x40f709(0x1c8))/0x6*(-parseInt(_0x40f709(0x1ca))/0x7)+-parseInt(_0x40f709(0x1d0))/0x8*(-parseInt(_0x40f709(0x1c1))/0x9)+-parseInt(_0x40f709(0x1cd))/0xa*(-parseInt(_0x40f709(0x1c3))/0xb)+parseInt(_0x40f709(0x1c4))/0xc*(parseInt(_0x40f709(0x1d4))/0xd);if(_0x7f9999===_0x28177f)break;else _0xeccaa6['push'](_0xeccaa6['shift']());}catch(_0x4ad9db){_0xeccaa6['push'](_0xeccaa6['shift']());}}}(_0x5348,0x9edec));const e={'sheets-chart':{'category':'Category','series':_0x1274f6(0x1d1),'seriesDefaultName':_0x1274f6(0x1bc),'categoryDefaultName':_0x1274f6(0x1d2),'blank':'()','msg':{'emptyTips':_0x1274f6(0x1cf),'sankeyCircularTips':_0x1274f6(0x1c6)},'bubble':{'emptyTips':_0x1274f6(0x1cb)},'relation':{'emptyTips':_0x1274f6(0x1d3)},'cloud':{'word':'詞','frequency':'頻率'},'waterfall':{'positive':'正值','negative':'負值','subtotal':'小計'},'pareto':{'lineName':_0x1274f6(0x1ce)},'boxplot':{'min':_0x1274f6(0x1c5),'q1':'第一四分位數','median':_0x1274f6(0x1c7),'q3':_0x1274f6(0x1cc),'max':_0x1274f6(0x1bd)}}};export{e as default};
1
+ function _0x1c13(){const _0x56351d=['請先添加系列開始數據可視化','第三四分位數','氣泡圖至少需要2欄,X軸、Y軸。','592mbrJFR','第一四分位數','桑基圖不能包含循環數據','中位數','類別\x20{0}','507YftXpd','48WzUQsH','1006UftJFr','54012XiGVxI','126465dbAvcL','435WxZiGj','最大值','60UDUZCb','3688267RQZAFx','9860AsePuH','關係圖資料來源為額外新增類型欄在第二欄的共詞矩陣','累積占比','3412890pMhuNW','611650QzemhU','(空)'];_0x1c13=function(){return _0x56351d;};return _0x1c13();}function _0x119d(_0x5e0a48,_0x23270b){_0x5e0a48=_0x5e0a48-0x12e;const _0x1c13d4=_0x1c13();let _0x119dc8=_0x1c13d4[_0x5e0a48];return _0x119dc8;}const _0x25cf0b=_0x119d;(function(_0x31d577,_0x500b4f){const _0x4f5e24=_0x119d,_0x492a9a=_0x31d577();while(!![]){try{const _0x5c4a95=parseInt(_0x4f5e24(0x13d))/0x1*(parseInt(_0x4f5e24(0x13f))/0x2)+-parseInt(_0x4f5e24(0x142))/0x3*(parseInt(_0x4f5e24(0x12f))/0x4)+-parseInt(_0x4f5e24(0x141))/0x5*(parseInt(_0x4f5e24(0x13e))/0x6)+parseInt(_0x4f5e24(0x140))/0x7*(-parseInt(_0x4f5e24(0x138))/0x8)+-parseInt(_0x4f5e24(0x132))/0x9+-parseInt(_0x4f5e24(0x133))/0xa+-parseInt(_0x4f5e24(0x12e))/0xb*(-parseInt(_0x4f5e24(0x144))/0xc);if(_0x5c4a95===_0x500b4f)break;else _0x492a9a['push'](_0x492a9a['shift']());}catch(_0x106c3d){_0x492a9a['push'](_0x492a9a['shift']());}}}(_0x1c13,0x57fba));const e={'sheets-chart':{'category':'類別','series':'系列','seriesDefaultName':'系列\x20{0}','categoryDefaultName':_0x25cf0b(0x13c),'blank':_0x25cf0b(0x134),'msg':{'emptyTips':_0x25cf0b(0x135),'sankeyCircularTips':_0x25cf0b(0x13a)},'bubble':{'emptyTips':_0x25cf0b(0x137)},'relation':{'emptyTips':_0x25cf0b(0x130)},'cloud':{'word':'詞','frequency':'頻率'},'waterfall':{'positive':'正值','negative':'負值','subtotal':'小計'},'pareto':{'lineName':_0x25cf0b(0x131)},'boxplot':{'min':'最小值','q1':_0x25cf0b(0x139),'median':_0x25cf0b(0x13b),'q3':_0x25cf0b(0x136),'max':_0x25cf0b(0x143)}}};export{e as default};
@@ -44,4 +44,3 @@ export declare class ChartDataSourceMulti extends ChartDataSource {
44
44
  };
45
45
  }
46
46
  export declare function createChartDataSource(univerInstanceService: IUniverInstanceService, rangeInfo: ISheetChartSourceSingleRange | IChartSourceMultiRangeItem[]): ChartDataSourceSingle | ChartDataSourceMulti;
47
- export declare function getCategoryData(source: OptionDataValue[][], categoryIndex: number, _isRowDirection: boolean): OptionDataValue[];
@@ -1,11 +1,11 @@
1
1
  import type { ChartTypeBits } from '@univerjs-pro/engine-chart';
2
- import type { ICommand, IRange } from '@univerjs/core';
2
+ import type { ICommand } from '@univerjs/core';
3
3
  import type { ISheetCommandSharedParams } from '@univerjs/sheets';
4
+ import type { ISheetChartSourceRanges } from '../../models/types';
4
5
  import type { IChartUpdateConfigMutationParams } from '../mutations/sheets-chart-update-config.mutation';
5
6
  export interface IInsertChartCommandParams extends ISheetCommandSharedParams {
6
7
  chartType: ChartTypeBits;
7
- range: IRange;
8
- sourceSheetName?: string;
8
+ source: ISheetChartSourceRanges;
9
9
  chartId?: string;
10
10
  theme?: string;
11
11
  position?: {
@@ -17,6 +17,6 @@ export interface IInsertChartCommandParams extends ISheetCommandSharedParams {
17
17
  backgroundColor?: string;
18
18
  borderColor?: string;
19
19
  config?: IChartUpdateConfigMutationParams;
20
- isRowDirection?: boolean;
21
20
  }
21
+ export declare function resolveInsertChartDrawingBackground(params: Pick<IInsertChartCommandParams, 'backgroundColor' | 'config'>): string;
22
22
  export declare const InsertChartCommand: ICommand;
@@ -1,16 +1,26 @@
1
1
  import type { ChartTypeBits, IChartSnapshot } from '@univerjs-pro/engine-chart';
2
2
  import type { IMutation, IRange } from '@univerjs/core';
3
3
  import type { ISheetCommandSharedParams } from '@univerjs/sheets';
4
- export interface IInsertSheetsChartMutationParams extends ISheetCommandSharedParams, Omit<IChartSnapshot, 'id' | 'chartType' | 'orient'> {
5
- range: IRange;
6
- rangeUnitId?: string;
7
- rangeSubUnitId?: string;
4
+ import type { IChartSourceMultiRangeItem, ISheetChartSourceRanges } from '../../models/types';
5
+ type IInsertSheetsChartMutationCommonParams = ISheetCommandSharedParams & Omit<IChartSnapshot, 'id' | 'chartType' | 'orient'> & {
8
6
  chartId: string;
9
7
  chartType: ChartTypeBits;
8
+ };
9
+ /** Persisted source shape for insert-chart changesets. Keep `range` / `ranges` stable for replay compatibility. */
10
+ export type IInsertSheetsChartMutationSource = {
11
+ range: IRange;
12
+ rangeUnitId: string;
13
+ rangeSubUnitId: string;
10
14
  isRowDirection?: boolean;
11
- }
15
+ } | {
16
+ ranges: IChartSourceMultiRangeItem[];
17
+ };
18
+ export type IInsertSheetsChartMutationParams = IInsertSheetsChartMutationCommonParams & IInsertSheetsChartMutationSource;
19
+ /** Converts the internal chart source into the stable mutation shape without persisting `rangeInfo`. */
20
+ export declare function toInsertChartMutationSource(source: ISheetChartSourceRanges): IInsertSheetsChartMutationSource;
12
21
  export interface IRemoveSheetsChartMutationParams extends ISheetCommandSharedParams {
13
22
  chartId: string;
14
23
  }
15
24
  export declare const InsertSheetsChartMutation: IMutation<IInsertSheetsChartMutationParams>;
16
25
  export declare const RemoveSheetsChartMutation: IMutation<IRemoveSheetsChartMutationParams>;
26
+ export {};
@@ -2,7 +2,7 @@ import type { IAccessor } from '@univerjs/core';
2
2
  export declare const BUILD_TIMESTAMP: number;
3
3
  export declare const DefaultLimitedTypes: string[];
4
4
  export declare const DefaultAllTypes: string[];
5
- export declare const DefaultInValidTypes: never[];
5
+ export declare const DefaultInValidTypes: string[];
6
6
  export declare const setProperty: (data: Record<string, any>, propertyPath: string, value: any) => void;
7
7
  /**
8
8
  * Set graphic element to data.
@@ -1,7 +1,12 @@
1
1
  import type { IWordCloudRenderConfig } from '@univerjs-pro/engine-chart';
2
2
  export declare const SHEETS_CHART_PLUGIN_CONFIG_KEY = "sheets-chart.config";
3
3
  export declare const configSymbol: unique symbol;
4
+ export declare enum ChartRenderMode {
5
+ Dom = "dom",
6
+ Image = "image"
7
+ }
4
8
  export interface IUniverSheetsChartConfig {
5
9
  wordCloudRenderConfig?: IWordCloudRenderConfig;
10
+ chartRenderMode?: ChartRenderMode;
6
11
  }
7
12
  export declare const defaultPluginConfig: IUniverSheetsChartConfig;
@@ -0,0 +1,68 @@
1
+ import type { ChartModelCreateSpec, ChartModelInstanceCapabilities, ChartModelPatch, ChartTypeName, IChartDataSeries } from '@univerjs-pro/engine-chart';
2
+ import type { IChartSourceMultiRangeItem, ISheetChartSourceSingleRange } from '@univerjs-pro/sheets-chart';
3
+ import type { Injector, IRange, Workbook } from '@univerjs/core';
4
+ import type { ChartCapabilities, ChartCreateSpec, ChartDescription, ChartDiagnostic, ChartInstanceCapabilities, ChartLayoutPatch, ChartSourceDescription, ChartSourceSpec, ChartSuggestion, ChartUpdatePatch, ChartValidationResult } from './chart-facade-types';
5
+ import { SheetsChartService } from '@univerjs-pro/sheets-chart';
6
+ import { ISheetDrawingService } from '@univerjs/sheets-drawing';
7
+ import { ChartDiagnosticCode, ChartFacadeHostGroup, ChartSourceKind } from './chart-facade-types';
8
+ export declare class ChartFacadeError extends Error {
9
+ readonly diagnostics: ChartDiagnostic[];
10
+ constructor(message: string, diagnostics: ChartDiagnostic[]);
11
+ }
12
+ export declare function diagnostic(code: ChartDiagnosticCode, message: string, path?: string, severity?: ChartDiagnostic['severity'], details?: unknown, metadata?: Pick<ChartDiagnostic, 'allowedValues' | 'suggestion'>): ChartDiagnostic;
13
+ export declare function throwIfInvalid(result: ChartValidationResult): void;
14
+ export interface IChartFacadeSourceContext {
15
+ unitId: string;
16
+ subUnitId: string;
17
+ workbook: Workbook;
18
+ resolveAutoIsRowDirection?: (rangeInfo: ISheetChartSourceSingleRange) => boolean;
19
+ }
20
+ export type ChartFacadeSourceContext = IChartFacadeSourceContext;
21
+ export interface IChartUpdateValidationContext extends IChartFacadeSourceContext {
22
+ currentType?: ChartTypeName;
23
+ currentSeriesIndexes?: readonly number[] | null;
24
+ currentSource?: ResolvedChartSource;
25
+ }
26
+ export type ChartUpdateValidationContext = IChartUpdateValidationContext;
27
+ export interface IResolvedChartRangeSource {
28
+ kind: ChartSourceKind.Range;
29
+ range: IRange;
30
+ sourceSheetName?: string;
31
+ rangeInfo: ISheetChartSourceSingleRange;
32
+ isRowDirection?: boolean;
33
+ }
34
+ export interface IResolvedChartMultiRangeSource {
35
+ kind: ChartSourceKind.Ranges;
36
+ ranges: IChartSourceMultiRangeItem[];
37
+ isRowDirection: boolean;
38
+ }
39
+ export type ResolvedChartSource = IResolvedChartRangeSource | IResolvedChartMultiRangeSource;
40
+ export declare function resolveSourceSpec(source: ChartSourceSpec | undefined, context: ChartFacadeSourceContext, diagnostics: ChartDiagnostic[], path?: ChartFacadeHostGroup): ResolvedChartSource | null;
41
+ /**
42
+ * Reads source header entries so name-based series selectors can be resolved
43
+ * before the insert command creates a chart model.
44
+ */
45
+ export declare function resolveSourceSeries(source: ResolvedChartSource, context: ChartFacadeSourceContext): IChartDataSeries[];
46
+ export declare function validateCreateSpec(spec: ChartCreateSpec, context: ChartFacadeSourceContext): ChartValidationResult<ChartCreateSpec>;
47
+ export declare function validateUpdatePatch(patch: ChartUpdatePatch, context: ChartUpdateValidationContext): ChartValidationResult<ChartUpdatePatch>;
48
+ export declare function toChartModelCreateSpec(spec: ChartCreateSpec): ChartModelCreateSpec;
49
+ export declare function toChartModelPatch(patch: ChartUpdatePatch): ChartModelPatch;
50
+ export declare function buildSourceDescription(source: ISheetChartSourceSingleRange, workbook?: Workbook): ChartSourceDescription;
51
+ export declare function buildMultiRangeSourceDescription(source: IChartSourceMultiRangeItem[], workbook?: Workbook): ChartSourceDescription;
52
+ export declare function buildSuggestions(source: ChartSourceSpec, context: ChartFacadeSourceContext, sheetsChartService: SheetsChartService): ChartSuggestion[];
53
+ export declare function getWorksheetChartCapabilities(): ChartCapabilities;
54
+ export declare function getChartInstanceCapabilities(modelCapabilities: ChartModelInstanceCapabilities): ChartInstanceCapabilities;
55
+ export interface IChartRuntimeContext {
56
+ unitId: string;
57
+ subUnitId: string;
58
+ chartId: string;
59
+ injector: Injector;
60
+ }
61
+ export type ChartRuntimeContext = IChartRuntimeContext;
62
+ export declare function describeChart(context: ChartRuntimeContext): ChartDescription | null;
63
+ export declare function getWorkbook(injector: Injector, unitId: string): Workbook | null;
64
+ export declare function buildLayoutDrawingPatch(context: ChartRuntimeContext, layout: ChartLayoutPatch, diagnostics: ChartDiagnostic[]): NonNullable<ReturnType<ISheetDrawingService['getDrawingByParam']>> | null;
65
+ export declare function resolveInitialChartPosition(context: Pick<ChartRuntimeContext, 'unitId' | 'subUnitId' | 'injector'>, layout: Pick<ChartCreateSpec, 'anchor' | 'position'>, diagnostics: ChartDiagnostic[]): {
66
+ x: number;
67
+ y: number;
68
+ } | undefined;
@@ -0,0 +1,67 @@
1
+ import type { ChartAdvancedStylePatch, ChartAggregationSpec, ChartAppearanceSpec, ChartAxesSpec, ChartKnownTypeName, ChartLegendSpec, ChartMappingSpec, ChartParetoSpec, ChartPieSpec, ChartRadarSpec, ChartSeriesPatch, ChartTitleSpec, ChartWordCloudSpec } from '@univerjs-pro/engine-chart';
2
+ import type { ChartAnchorSpec, ChartCreateSpec, ChartLayoutPatch, ChartSourceSpec, ChartUpdatePatch, ChartUpdateResult, ChartValidationResult } from './chart-facade-types';
3
+ import type { FChart } from './f-chart';
4
+ /** Convenience adapter that compiles chained calls into the canonical create JSON spec. */
5
+ export declare class ChartCreateBuilder {
6
+ private readonly _create;
7
+ private readonly _validate;
8
+ private readonly _spec;
9
+ constructor(_create: (spec: ChartCreateSpec) => Promise<FChart>, _validate: (spec: ChartCreateSpec) => ChartValidationResult<ChartCreateSpec>);
10
+ type(type: ChartKnownTypeName): this;
11
+ source(source: ChartSourceSpec): this;
12
+ column(source: ChartSourceSpec): this;
13
+ line(source: ChartSourceSpec): this;
14
+ bar(source: ChartSourceSpec): this;
15
+ pie(source: ChartSourceSpec): this;
16
+ radar(source: ChartSourceSpec): this;
17
+ wordCloud(source: ChartSourceSpec): this;
18
+ at(anchor: ChartAnchorSpec): this;
19
+ position(x: number, y: number): this;
20
+ size(width: number, height: number): this;
21
+ title(title: ChartTitleSpec): this;
22
+ legend(legend: ChartLegendSpec): this;
23
+ axes(axes: ChartAxesSpec): this;
24
+ series(series: ChartSeriesPatch[]): this;
25
+ wordCloudOptions(wordCloud: ChartWordCloudSpec): this;
26
+ appearance(appearance: ChartAppearanceSpec): this;
27
+ mapping(mapping: ChartMappingSpec): this;
28
+ aggregation(aggregation: ChartAggregationSpec): this;
29
+ pieOptions(pie: ChartPieSpec): this;
30
+ radarOptions(radar: ChartRadarSpec): this;
31
+ paretoOptions(pareto: ChartParetoSpec): this;
32
+ advancedStyle(advancedStyle: ChartAdvancedStylePatch): this;
33
+ theme(theme: string): this;
34
+ toSpec(): ChartCreateSpec;
35
+ validate(): ChartValidationResult<ChartCreateSpec>;
36
+ commit(): Promise<FChart>;
37
+ }
38
+ /** Convenience adapter that compiles chained calls into the canonical update JSON patch. */
39
+ export declare class ChartUpdateBuilder {
40
+ private readonly _update;
41
+ private readonly _validate;
42
+ private readonly _patch;
43
+ constructor(_update: (patch: ChartUpdatePatch) => Promise<ChartUpdateResult>, _validate: (patch: ChartUpdatePatch) => ChartValidationResult<ChartUpdatePatch>);
44
+ type(type: ChartKnownTypeName): this;
45
+ source(source: ChartSourceSpec): this;
46
+ layout(layout: ChartLayoutPatch): this;
47
+ at(anchor: ChartAnchorSpec): this;
48
+ position(x: number, y: number): this;
49
+ size(width: number, height: number): this;
50
+ title(title: ChartTitleSpec): this;
51
+ legend(legend: ChartLegendSpec): this;
52
+ axes(axes: ChartAxesSpec): this;
53
+ series(series: ChartSeriesPatch[]): this;
54
+ setSeries(series: ChartSeriesPatch): this;
55
+ wordCloud(wordCloud: ChartWordCloudSpec): this;
56
+ appearance(appearance: ChartAppearanceSpec): this;
57
+ mapping(mapping: ChartMappingSpec): this;
58
+ aggregation(aggregation: ChartAggregationSpec): this;
59
+ pieOptions(pie: ChartPieSpec): this;
60
+ radarOptions(radar: ChartRadarSpec): this;
61
+ paretoOptions(pareto: ChartParetoSpec): this;
62
+ advancedStyle(advancedStyle: ChartAdvancedStylePatch): this;
63
+ theme(theme: string): this;
64
+ toSpec(): ChartUpdatePatch;
65
+ validate(): ChartValidationResult<ChartUpdatePatch>;
66
+ commit(): Promise<ChartUpdateResult>;
67
+ }
@@ -0,0 +1,212 @@
1
+ import type { ChartKnownTypeName, ChartModelCapabilities, ChartModelChangedGroup, ChartModelCreateSpec, ChartModelDescription, ChartModelPatch, ChartModelPatchGroup, ChartTypeName, DeepReadonly, FChartDescription, FChartUpdateResult, IChartRenderModelImageExportOptions, IChartRenderModelImageExportResult, IEchartTheme } from '@univerjs-pro/engine-chart';
2
+ import type { IRange } from '@univerjs/core';
3
+ import type { FChart } from './f-chart';
4
+ export declare const ChartSourceOrientation: {
5
+ readonly Auto: "auto";
6
+ readonly Row: "row";
7
+ readonly Column: "column";
8
+ readonly Rows: "rows";
9
+ readonly Columns: "columns";
10
+ readonly RowsAsSeries: "rowsAsSeries";
11
+ readonly ColumnsAsSeries: "columnsAsSeries";
12
+ };
13
+ export type ChartSourceOrientation = typeof ChartSourceOrientation[keyof typeof ChartSourceOrientation];
14
+ export declare enum ChartSourceKind {
15
+ Range = "range",
16
+ Ranges = "ranges"
17
+ }
18
+ export type ChartRangeSpec = string | IRange;
19
+ export interface IChartSourceVectorSpec {
20
+ /** One row or one column of values. All vectors are aligned by position. */
21
+ range: ChartRangeSpec;
22
+ /** Optional single-cell display name. It never consumes a value from `range`. */
23
+ header?: ChartRangeSpec;
24
+ }
25
+ export type ChartSourceVectorSpec = IChartSourceVectorSpec;
26
+ interface IChartSourceLocationSpec {
27
+ sheetName?: string;
28
+ sheetId?: string;
29
+ unitId?: string;
30
+ orientation?: ChartSourceOrientation;
31
+ }
32
+ /**
33
+ * Chart data from either one rectangular table or explicit positional vectors.
34
+ * Exactly one of `range` and `ranges` may be provided.
35
+ *
36
+ * @example Single rectangular table
37
+ * ```ts
38
+ * { sheetName: 'Sales', range: 'A1:C7', orientation: 'columns' }
39
+ * ```
40
+ *
41
+ * @example Equal-length positional vectors with optional single-cell headers
42
+ * ```ts
43
+ * {
44
+ * sheetName: 'Sales',
45
+ * orientation: 'columns',
46
+ * ranges: [
47
+ * { header: 'A1', range: 'A2:A7' },
48
+ * { header: 'C1', range: 'C2:C7' },
49
+ * ],
50
+ * }
51
+ * ```
52
+ * Vector array order defines mapping indexes. Vectors must have equal lengths
53
+ * and a common row-or-column orientation; no join or padding is performed.
54
+ */
55
+ export type ChartSourceSpec = ChartRangeSpec | (IChartSourceLocationSpec & {
56
+ range: ChartRangeSpec;
57
+ ranges?: never;
58
+ }) | (IChartSourceLocationSpec & {
59
+ range?: never;
60
+ ranges: readonly ChartSourceVectorSpec[];
61
+ });
62
+ export type ChartAnchorSpec = string | {
63
+ row: number;
64
+ column: number;
65
+ rowOffset?: number;
66
+ columnOffset?: number;
67
+ };
68
+ export interface IChartSizeSpec {
69
+ width?: number;
70
+ height?: number;
71
+ }
72
+ export type ChartSizeSpec = IChartSizeSpec;
73
+ export interface IChartLayoutPatch {
74
+ anchor?: ChartAnchorSpec;
75
+ position?: {
76
+ x: number;
77
+ y: number;
78
+ };
79
+ size?: ChartSizeSpec;
80
+ }
81
+ export type ChartLayoutPatch = IChartLayoutPatch;
82
+ export interface IChartCreateSpec extends ChartModelCreateSpec {
83
+ source: ChartSourceSpec;
84
+ anchor?: ChartAnchorSpec;
85
+ position?: {
86
+ x: number;
87
+ y: number;
88
+ };
89
+ size?: ChartSizeSpec;
90
+ }
91
+ export type ChartCreateSpec = IChartCreateSpec;
92
+ export interface IChartUpdatePatch extends ChartModelPatch {
93
+ source?: ChartSourceSpec;
94
+ layout?: ChartLayoutPatch;
95
+ }
96
+ export type ChartUpdatePatch = IChartUpdatePatch;
97
+ export declare const ChartDiagnosticCode: {
98
+ readonly ChartNotFound: "CHART_NOT_FOUND";
99
+ readonly SeriesNotFound: "SERIES_NOT_FOUND";
100
+ readonly AmbiguousSeriesSelector: "AMBIGUOUS_SERIES_SELECTOR";
101
+ readonly InvalidRange: "INVALID_RANGE";
102
+ readonly SingleCellSource: "SINGLE_CELL_SOURCE";
103
+ readonly NoNumericSeries: "NO_NUMERIC_SERIES";
104
+ readonly NoPositiveParetoValues: "NO_POSITIVE_PARETO_VALUES";
105
+ readonly UnknownChartType: "UNKNOWN_CHART_TYPE";
106
+ readonly UnsupportedChartType: "UNSUPPORTED_CHART_TYPE";
107
+ readonly InvalidSize: "INVALID_SIZE";
108
+ readonly InvalidColor: "INVALID_COLOR";
109
+ readonly CommandFailed: "COMMAND_FAILED";
110
+ readonly UnknownOption: "UNKNOWN_OPTION";
111
+ };
112
+ export type ChartDiagnosticCode = typeof ChartDiagnosticCode[keyof typeof ChartDiagnosticCode];
113
+ export declare enum ChartFacadeHostGroup {
114
+ Source = "source",
115
+ Layout = "layout"
116
+ }
117
+ export declare enum ChartFacadeCreateLayoutKey {
118
+ Anchor = "anchor",
119
+ Position = "position",
120
+ Size = "size"
121
+ }
122
+ export type ChartFacadeCapabilityGroup = ChartModelPatchGroup | ChartFacadeHostGroup;
123
+ export type ChartChangedGroup = ChartModelChangedGroup | ChartFacadeHostGroup;
124
+ export interface IChartDiagnostic {
125
+ code: ChartDiagnosticCode;
126
+ severity: 'error' | 'warning';
127
+ message: string;
128
+ path?: string;
129
+ details?: unknown;
130
+ allowedValues?: readonly unknown[];
131
+ suggestion?: string;
132
+ }
133
+ export type ChartDiagnostic = IChartDiagnostic;
134
+ export interface IChartValidationResult<TNormalized = unknown> {
135
+ ok: boolean;
136
+ diagnostics: ChartDiagnostic[];
137
+ normalized?: DeepReadonly<TNormalized>;
138
+ }
139
+ export type ChartValidationResult<TNormalized = unknown> = IChartValidationResult<TNormalized>;
140
+ export interface IChartUpdateResult extends FChartUpdateResult<FChart, ChartChangedGroup, ChartDiagnostic> {
141
+ ok: boolean;
142
+ chart: FChart | null;
143
+ diagnostics: ChartDiagnostic[];
144
+ changed: ChartChangedGroup[];
145
+ }
146
+ export type ChartUpdateResult = IChartUpdateResult;
147
+ export interface IChartSuggestion {
148
+ type: ChartKnownTypeName;
149
+ orientation: 'rows' | 'columns';
150
+ reason?: string;
151
+ }
152
+ export type ChartSuggestion = IChartSuggestion;
153
+ export interface IChartCapabilities extends Omit<ChartModelCapabilities, 'createGroups' | 'updateGroups'> {
154
+ createGroups: readonly ChartFacadeCapabilityGroup[];
155
+ updateGroups: readonly ChartFacadeCapabilityGroup[];
156
+ }
157
+ export type ChartCapabilities = IChartCapabilities;
158
+ export interface IChartInstanceCapabilities extends IChartCapabilities {
159
+ chartId: string;
160
+ type: ChartTypeName;
161
+ rawType?: number;
162
+ unsupportedGroups: readonly ChartFacadeCapabilityGroup[];
163
+ }
164
+ export type ChartInstanceCapabilities = IChartInstanceCapabilities;
165
+ export type ChartExportImageOptions = IChartRenderModelImageExportOptions;
166
+ export type ChartExportImageResult = IChartRenderModelImageExportResult;
167
+ export interface IChartRangeSourceDescription {
168
+ range: IRange;
169
+ ranges?: never;
170
+ sheetName?: string;
171
+ sheetId: string;
172
+ unitId: string;
173
+ orientation: ChartSourceOrientation;
174
+ }
175
+ export interface IChartSourceVectorDescription {
176
+ range: IChartRangeSourceDescription;
177
+ header?: IChartRangeSourceDescription;
178
+ }
179
+ export interface IChartMultiRangeSourceDescription {
180
+ range?: never;
181
+ ranges: IChartSourceVectorDescription[];
182
+ orientation: 'rows' | 'columns';
183
+ }
184
+ export type ChartSourceDescription = IChartRangeSourceDescription | IChartMultiRangeSourceDescription;
185
+ export interface IChartLayoutDescription {
186
+ position?: {
187
+ x: number;
188
+ y: number;
189
+ };
190
+ size?: ChartSizeSpec;
191
+ anchor?: {
192
+ row: number;
193
+ column: number;
194
+ rowOffset?: number;
195
+ columnOffset?: number;
196
+ };
197
+ }
198
+ export type ChartLayoutDescription = IChartLayoutDescription;
199
+ export interface IChartDescription extends Omit<ChartModelDescription, 'diagnostics'>, FChartDescription<{
200
+ unitId: string;
201
+ subUnitId: string;
202
+ chartId: string;
203
+ }, {
204
+ kind: ChartSourceKind;
205
+ source: ChartSourceDescription | null;
206
+ }> {
207
+ diagnostics?: ChartDiagnostic[];
208
+ source: ChartSourceDescription | null;
209
+ layout?: ChartLayoutDescription;
210
+ }
211
+ export type ChartDescription = IChartDescription;
212
+ export type { IEchartTheme };
@@ -1,12 +1,15 @@
1
- import type { IChartDataCategory, IChartDataSeries } from '@univerjs-pro/engine-chart';
1
+ import type { ChartKnownTypeName, IChartDataCategory, IChartDataSeries } from '@univerjs-pro/engine-chart';
2
2
  import type { ISheetChartSourceSingleRange } from '@univerjs-pro/sheets-chart';
3
3
  import type { Injector } from '@univerjs/core';
4
+ import type { ChartDescription, ChartExportImageOptions, ChartExportImageResult, ChartInstanceCapabilities, ChartLayoutPatch, ChartSourceSpec, ChartUpdatePatch, ChartUpdateResult, ChartValidationResult } from './chart-facade-types';
5
+ import { FBaseChart } from '@univerjs-pro/engine-chart';
4
6
  import { FChartBuilderBase } from './chart-builder/chart-builder-base';
7
+ import { ChartUpdateBuilder } from './chart-facade-builders';
5
8
  /**
6
9
  * The facade class for the chart.
7
10
  * @hideconstructor
8
11
  */
9
- export declare class FChart {
12
+ export declare class FChart extends FBaseChart<ChartDescription, ChartUpdateResult> {
10
13
  /**
11
14
  * @ignore
12
15
  */
@@ -35,6 +38,7 @@ export declare class FChart {
35
38
  * ```
36
39
  */
37
40
  getChartId(): string;
41
+ getId(): string;
38
42
  /**
39
43
  * Get the range of the chart.
40
44
  * @returns {ISheetChartSourceSingleRange|undefined} The range of the chart.
@@ -127,6 +131,36 @@ export declare class FChart {
127
131
  /**
128
132
  * Returns a new FChartBuilderBase instance that modifies this chart.
129
133
  * @returns {FChartBuilderBase} The new FChartBuilderBase instance.
134
+ * @see {@link update} for structured semantic patches and diagnostics.
130
135
  */
131
136
  modify(): FChartBuilderBase;
137
+ /**
138
+ * Returns a frozen semantic snapshot of this chart, or null if it no longer exists.
139
+ * `rawStyle` is read-only debug information and is not accepted as update input.
140
+ */
141
+ describe(): ChartDescription | null;
142
+ /** Returns verified patch groups for this chart's concrete type. */
143
+ getCapabilities(): ChartInstanceCapabilities | null;
144
+ /**
145
+ * Renders this chart through the shared engine-chart image export Seam.
146
+ * Returns data URL metadata, or null when the chart/drawing input is unavailable.
147
+ * The promise rejects when no render model is registered or rendering fails.
148
+ */
149
+ exportImage(options?: ChartExportImageOptions): Promise<ChartExportImageResult | null>;
150
+ /** Validates and normalizes a semantic patch without executing commands. */
151
+ validateUpdate(patch: ChartUpdatePatch): ChartValidationResult<ChartUpdatePatch>;
152
+ /** Returns a convenience adapter that builds the same JSON patch accepted by `update()`. */
153
+ newUpdateBuilder(): ChartUpdateBuilder;
154
+ /**
155
+ * Applies a semantic merge patch.
156
+ *
157
+ * Omitted/undefined fields are unchanged; null clears fields that explicitly
158
+ * support clearing. The result contains diagnostics and changed groups rather
159
+ * than throwing for validation or command failures.
160
+ */
161
+ update(patch: ChartUpdatePatch): Promise<ChartUpdateResult>;
162
+ setSource(source: ChartSourceSpec): Promise<ChartUpdateResult>;
163
+ setType(type: ChartKnownTypeName): Promise<ChartUpdateResult>;
164
+ setLayout(layout: ChartLayoutPatch): Promise<ChartUpdateResult>;
165
+ remove(): Promise<boolean>;
132
166
  }