@@ -108,6 +108,13 @@ export default () => {
108108```
109109
110110
111+ ** NOTE :**
112+
113+ api Object will not be changed after re-rendering multiple times.
114+ Its value always refers to same reference.
115+
116+
117+
111118## Options
112119
113120### tabs
@@ -226,8 +233,10 @@ export default () => {
226233```
227234or
228235``` js
229- api .setOption (' direction' ,' ltr' );
230- api .refresh ();
236+ if ( api .getOption (' direction' ) !== ' ltr' ) {
237+ api .setOption (' direction' ,' ltr' );
238+ api .refresh ();
239+ }
231240```
232241
233242
@@ -345,10 +354,19 @@ api.refresh();
345354```
346355or
347356``` js
348- api .setOption (' accessibility' ,false ).refresh ();
357+ if ( api .getOption (' accessibility' ) == true ){
358+ api .setOption (' accessibility' ,false ).refresh ();
359+ }
349360```
350361
351362
363+ ** NOTE :**
364+
365+ This option assigns id attribute on panel element and text element inside the tab.
366+ for having elements without id attribute, set this option to false.
367+
368+
369+
352370### onLoad
353371
354372<table >
@@ -609,17 +627,19 @@ Parameters:
609627** Example**
610628
611629``` js
612- api .open ({
630+ if ( api .isOpen (' 2' ) == false ){
631+ api .open ({
613632 id: ' 2' ,
614633 title: ' contact' ,
615634 tooltip: ' contact' ,
616635 disable: false ,
617636 closable: true ,
618637 iconClass: ' ' ,
619638 panelComponent: < ContactPanel>< / ContactPanel>
620- }).then (()=> {
621- // do sth here
622- });
639+ }).then (()=> {
640+ // do sth here
641+ });
642+ }
623643```
624644
625645
@@ -649,9 +669,11 @@ Parameters:
649669** Example**
650670
651671``` js
652- api .select (' tab ID' ).then (()=> {
653- // do sth here
654- });
672+ if ( api .isSelected (' your tab id' ) == false ){
673+ api .select (' your tab id' ).then (()=> {
674+ // do sth here
675+ });
676+ }
655677```
656678
657679
@@ -666,9 +688,11 @@ Parameters:
666688** Example**
667689
668690``` js
669- api .close (' tab ID' ).then (()=> {
670- // do sth here
671- });
691+ if ( api .isOpen (' 2' ) == true ){
692+ api .close (' 2' ).then (()=> {
693+ // do sth here
694+ });
695+ }
672696```
673697
674698
@@ -807,7 +831,7 @@ Return value : api
807831Parameters:
808832
809833- ` event Name : String (can be either of of onSelect|onClose|onOpen|onInit|onChange|onDestroy) `
810- - ` function name `
834+ - ` handler : function (A handler function previously attached for the event) `
811835
812836** Example**
813837
0 commit comments