@progress/kendo-react-buttons
Version:
All you need in React Button in one package: disabled/enabled states, built-in styles and more. KendoReact Buttons package
9 lines (8 loc) • 838 B
JavaScript
/**
* @license
*-------------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the package root for more information
*-------------------------------------------------------------------------------------------
*/
;Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("@progress/kendo-react-common"),c=(t,n,a,s)=>{if(a)return t;const r=Math.min(s-1,Math.max(0,t));switch(n){case e.Keys.enter:case e.Keys.space:case e.Keys.esc:return-1;case e.Keys.up:case e.Keys.left:return r-1<0?s-1:r-1;case e.Keys.down:case e.Keys.right:return r+1>=s?0:r+1;case e.Keys.home:return 0;case e.Keys.end:return s-1;default:return t}};exports.navigate=c;