Problem with table borders v22.2.7

HI there , i was testing last version of Document Editor (22.2.7)  and i found an issue with tables

Steps

  1. -Create table in document  so far component in the example is using Spanish Locale
  2. Set properties for the Table's borders
  3. Apply changes
  4. Select individual cells or whole table and Border is set to NONE "ninguno"
  5. i repeat steps 1-3 for cells or whole table and always the border is set to none
  6. Exporting to WORD doc (JS only) and open the word file and the table is Without borders
Any pointers , or i have to chenge some kind of settings on the component ?

I leave a link for a VIDEO so you can check the issue



12 Replies

KM Kavitha Muralitharan Syncfusion Team August 7, 2023 12:52 PM UTC

Hi carlos,


Please find the attached video and details below. Please cross-check that and let us know if you need any other assistance.

The exported document with Table 1 looks with the dot (punto) border.

 

Repeating (cell border style as None)

 

The exported document with Table 2 looks with the empty border.

 

setting (Table border style as None)

 

In MS Word, when setting the border style as None and applying it to the Table, it will remove the border. The Document Editor also follows the same.


Regards,

Kavitha M



Attachment: Table_cell_border_b78fa778.zip


CM carlos mendez August 7, 2023 08:24 PM UTC

HI Kavitha, checking your video against mine and making more tests it turns out that if I remove language and leave document editor with plain english, it works .!

BUt if i set spanish or other language then its the same issue the border its not applied or after change then the border is set as "NONE"


syncfusion_es_locale_github.js :

var localeEs = {
"es": {
"grid": {
......
} ,
............
}
}
export { localeEs }

in this case im using quasar 1.22.9 with vue 2.7.14
and the values for locales are copied from https://github.com/syncfusion/ej2-locale




CM carlos mendez August 7, 2023 10:56 PM UTC

Checking the source code files in debugger i found the issue

on file

node_modules/@syncfusion/ej2-documenteditor/src/document-editor/implementation/dialogs/borders-and-shading-dialog.js   in the getBorder  function


BordersAndShadingDialog.prototype.getBorder = function (type) {

        var border = new WBorder();

        border.color = this.borderColorPicker.value;

        border.lineStyle = this.borderStyle.text;   // this line is wrong due its taking the translated TEXT instead the proper value

        border.lineWidth = this.borderWidth.value;

        if (type === 'left' || type === 'right') {

            border.space = 4;

        } else {

            border.space = 1;

        }

        return border;

    };


the line :

border.lineStyle = this.borderStyle.text;  

its taking the Translated Value / Text for apply to the borderStyle  so in my case im using spanish its trying to SET 

border.lineStyle = "Punto"   instead   border.lineStyle = "Dot" 


so manually Setting each time the function is called to border.lineStyle = "Dot"  in the DEBUG CONSOLE   it works but its an issue

See the image

Image_1958_1691449013527








KM Kavitha Muralitharan Syncfusion Team August 8, 2023 04:08 AM UTC

carlos, we can reproduce the reported issue "None as a default option in style and Exported document in word file and the table is Without borders ". Currently, we are validating and will get back to you by August 10, 2023.



CM carlos mendez August 8, 2023 07:31 AM UTC

HI,  thanks for the update

But mainly I mean:  I create table and set borders as solid, dotted etc but  these styles are not applied due the translation  Value/NAME  and when click OK to apply the changes and the code what applies is "NONE" as border style 

ALSO WHEN going back to change a style on the table appears as "NONE" cause the border style was not applied correctly in code and it has NO border by that time



SM Suriya Murugan Syncfusion Team August 22, 2023 03:06 AM UTC

Carlos, Please check the reported issue in below sample: In latest release, we have added some fix related to table border.

https://stackblitz.com/edit/i5dvj4?file=index.html

In Document editor, if you select the any border style, it will applied as Solid and you can see difference in exported document.



CM carlos mendez August 22, 2023 06:16 PM UTC

Hi , after upgrading the library @syncfusion/ej2-vue-documenteditor  and @syncfusion/ej2-vue-splitbuttons

i got an error

JSON.parse: expected ',' or '}' after property value in object at line 1 column 206 of the JSON data

initToolBar  tool-bar.js:90

i uninstalled syncfusion libraries and reinstalled

Image_6421_1692728215313

it seems HelperMethods  is undefined , any pointers or i have to import another thing in order to initialize document editor ?




CM carlos mendez August 22, 2023 06:46 PM UTC

After testing it seems i cannot use an object to set custom buttons in the toolbar 

if i use this config

[
  'Undo', 'Redo', 'Separator', 'Image', 'Table',
  'Separator',
  'Header', 'Footer', 'PageSetup', 'PageNumber', 'Break',  
  'Separator', 'Find', 'Separator',
  'LocalClipboard'
]

works  fine

but if i use 

[{

    prefixIcon: "e-align-bottom-2",

    tooltipText: "Import document",

    text: "Import",

    id: "openCustom"

  },

  'Separator',

  {

    prefixIcon: "e-save",

    tooltipText: "Export document",

    text: 'Export <div class="e-de-text-wrap">as...</div>',

    id: "saveCustom"

  },

  'Separator',

  {

    prefixIcon: "e-named-set",

    tooltipText: "Insert variable in document",

    text: 'Insert <div class="e-de-text-wrap"> variable</div>',

    id: "insertVariable"

  },

  'Separator', 'Undo', 'Redo', 'Separator', 'Image', 'Table',

  'Separator',

  'Header', 'Footer', 'PageSetup', 'PageNumber', 'Break',

  'Separator', 'Find', 'Separator',

  'LocalClipboard'

]

it breaks.


Another issue i found was   using spanish locale

Image_8425_1692730015346

Got the texts from https://github.com/syncfusion/ej2-locale

and no appear the texts for border styles




CM carlos mendez August 22, 2023 07:38 PM UTC

SO far toolbar problem was solved, turns out that  CustomToolbarItemModel text property no longer accepts HTML

example 1:

{

    prefixIcon: "e-named-set",

    tooltipText: "Insert variable",

    text: 'Insert <div class="e-de-text-wrap"> variable</div>',

    id: "insertVariable"

},

it breaks 


Example 2:

{

  prefixIcon: "e-named-set",

  tooltipText: "Insertar variable de contratos",

  text: 'Insert<br>variable',

  id: "insertVariable",

  cssClass: 'canna_editor_customBtn'

},

<style>

  .canna_editor_customBtn .e-tbar-btn-text{

    line-height: 11px;

  }

</style>

works


And about borders and shading  removing the Spanish language and leaving plain english  happens the same

Image_6680_1692732870430


Tested Options :

1.- Removed node_modules and reinstall all

2.- Uninstalled syncfusion libraries and reinstall 

3.- cleared cache in browser


so far the installed in package json was

    "@syncfusion/ej2-pdf-export": "^22.2.5",
    "@syncfusion/ej2-vue-documenteditor": "^22.2.10",
    "@syncfusion/ej2-vue-splitbuttons": "^22.2.8",


using VUE .2.7.14 , quasar 1.22.9




CM carlos mendez August 22, 2023 11:53 PM UTC

After many tests  i saw that the problem is the CSS  version 22.2.10 , 22.2.9  

I use the CSS generated in theme studio with material design  comparing the full CSS (document editor) part with 

node_modules\@syncfusion\ej2-documenteditor\styles\material.css  

there is some missing CSS in the files generated by themestudio 





Attachment: settings_1fde82de.zip


CM carlos mendez August 23, 2023 05:42 PM UTC

After more testing and fixing temporary the CSS the 

table problem is fixed



SM Suriya Murugan Syncfusion Team August 24, 2023 04:17 AM UTC

## After testing it seems i cannot use an object to set custom buttons in the toolbar 

We will resolve the issue in upcoming weekly release which is expected by end of August 2023.

## table problem is fixed

You need to update the css(v22.2.10) to resolve this issue.




Loader.
Up arrow icon