@progress/kendo-react-indicators
Version:
React Indicators offer an interface to represent a visual indication for their UI elements. KendoReact Indicators package
9 lines (8 loc) • 1.34 kB
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 p=require("react"),o=require("prop-types"),i=require("@progress/kendo-react-common");function g(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const s=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,s.get?s:{enumerable:!0,get:()=>e[n]})}}return r.default=e,Object.freeze(r)}const t=g(p),a=t.forwardRef((e,r)=>{const{children:n,className:s,style:l}=e,c=t.useRef(null),u=t.useCallback(()=>{c.current&&c.current.focus()},[]);t.useImperativeHandle(r,()=>({element:c.current,focus:u}));const d=i.useDir(c,e.dir),m=t.useMemo(()=>i.classNames("k-badge-container",s),[s]),f=t.useMemo(()=>({display:"inline-block",...l}),[l]);return t.createElement("span",{className:m,style:f,dir:d},n)});a.propTypes={className:o.string,dir:o.string,style:o.object};a.displayName="KendoBadgeContainer";exports.BadgeContainer=a;