[GH-DEV#2178] 2 questions

Tags: #<Tag:0x00007efc6b6c4dc8> #<Tag:0x00007efc6b6c4558>

Hi,im new here.I have 2 questions,but my English is poor.

  1. How to save whole table styles conveniently, and how to load styles setting saved before.
  2. When I change language to zh-CN, but datebox editor not changed

I translate it to Chinese

  1. 怎么保存整个表格的格式(包括单元格字体、颜色、背景色、边框颜色等等),然后怎么加载已保存的格式。我在网上找了些资料,他们建议我遍列所有单元格,获取所有单元格样式后保存到数组中。
  2. 我将需要设置为中文,菜单的需要是变了,日期编辑器如何显示为中文?

Hi @807222175,

welcome on out forum. I am Aleksandra from the Technical Support team and will do my best to help you solve the issues.

  1. Could you please tell me more about this requirement? How users are altering styling? In Handsontable v15.0.0 we introduced Themes. You can read more about them here in the tutorial https://handsontable.com/docs/javascript-data-grid/themes/. However, this functionality doesn’t come with a option to change the view/colors by users - it is a fixed setup.

  2. This is the fist time someone mentions that. But you are right. The date picker does not alter the language automatically. To handle dates we use our own fork of the Pikaday library. Reference: https://www.npmjs.com/package/@handsontable/pikaday that has its own translations mechanism built-in. Here https://github.com/Pikaday/Pikaday/blob/master/pikaday.js#L273 is an example on how to alter the names of days and months via 118n setting. I will also internally report a need to have this already built-in when you set up a language in Handsontable but as all new functionalities that may take some time.

Thinks so much.For instance:
When a user sets a series of styles, such as creating a table template using a handsontable, setting certain cell(s) borders and colors, background colors, and then saving these style settings.The next time the user opens the template, these styles will be automatically loaded. I hope Handsontable can provide two interfaces, one for saving styles and the other for loading styles.

Ah I see. Thank you for the clarification.

There is no one, single, general setup that we can ask for and load, meaning

  • columns/rows altered widths
  • columns/rows altered positions
  • added/removed/altered comments
  • added/removed/altered borders

have their own, separate setups. Each of them has to be treated separately.

If you could list me the options that you would like to use in your project I’ll do my best to guide you further with the mechanism to save and load the setup.

ps. could you please elaborate on how you would see the ultimate hook? What parameters it should have?