The docs mention the dragStart, dragEnd, and reorder events for tabs are cancelable however with the following handlers I am unable to prevent tabs from being reordered. I am able to prevent closing a tab via the closing event but not reording a tab.
Note: omitted for simplicity from the sample below is the logic on which tabs are to be prevented from re-ordering. The intent is that only some tabs will not able to re-ordered
HTML
<smart-tabs #tabs
(closing)="onTabClosing($event)"
(close)="onTabClosed($event)"
(reorder)="cancel($event)"
(onDragStart)="cancel($event)"
(onDragEnd)="cancel($event)"
[reorder]="true">
</smart-tabs>
Angular component
cancel(event: CustomEvent) {
event.preventDefault();
event.stopPropagation();
return false;
}
Is there another preferred way of accomplishing this?