lingee-ui 0.0.12 → 0.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- 'use strict';var chunkDFNZUZOR_js=require('../chunk-DFNZUZOR.js');require('../chunk-6CZCNLSW.js'),require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Input",{enumerable:true,get:function(){return chunkDFNZUZOR_js.a}});
1
+ 'use strict';var chunkXOVQPZCB_js=require('../chunk-XOVQPZCB.js');require('../chunk-FTEVUZKX.js'),require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Input",{enumerable:true,get:function(){return chunkXOVQPZCB_js.a}});
@@ -1 +1 @@
1
- export{a as Input}from'../chunk-D7Q5GNWC.mjs';import'../chunk-BUZQBHJH.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
1
+ export{a as Input}from'../chunk-M37T4ADR.mjs';import'../chunk-DHCCF3XI.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
@@ -1 +1 @@
1
- 'use strict';var chunkTNJGV4D3_js=require('../chunk-TNJGV4D3.js');require('../chunk-HYN4Y4AW.js'),require('../chunk-6CZCNLSW.js'),require('../chunk-T534AXC3.js'),require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Tabs",{enumerable:true,get:function(){return chunkTNJGV4D3_js.b}});Object.defineProperty(exports,"tabsVariants",{enumerable:true,get:function(){return chunkTNJGV4D3_js.a}});
1
+ 'use strict';var chunkLSZ4P7R5_js=require('../chunk-LSZ4P7R5.js');require('../chunk-HYN4Y4AW.js'),require('../chunk-FTEVUZKX.js'),require('../chunk-T534AXC3.js'),require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Tabs",{enumerable:true,get:function(){return chunkLSZ4P7R5_js.b}});Object.defineProperty(exports,"tabsVariants",{enumerable:true,get:function(){return chunkLSZ4P7R5_js.a}});
@@ -1 +1 @@
1
- export{b as Tabs,a as tabsVariants}from'../chunk-3ZYHG7I2.mjs';import'../chunk-B6CAD73P.mjs';import'../chunk-BUZQBHJH.mjs';import'../chunk-FRXQG2XX.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
1
+ export{b as Tabs,a as tabsVariants}from'../chunk-56AGGSSV.mjs';import'../chunk-B6CAD73P.mjs';import'../chunk-DHCCF3XI.mjs';import'../chunk-FRXQG2XX.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
@@ -1 +1 @@
1
- 'use strict';var chunk6CZCNLSW_js=require('../chunk-6CZCNLSW.js');require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Toaster",{enumerable:true,get:function(){return chunk6CZCNLSW_js.b}});Object.defineProperty(exports,"toast",{enumerable:true,get:function(){return chunk6CZCNLSW_js.c}});
1
+ 'use strict';var chunkFTEVUZKX_js=require('../chunk-FTEVUZKX.js');require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Toaster",{enumerable:true,get:function(){return chunkFTEVUZKX_js.b}});Object.defineProperty(exports,"toast",{enumerable:true,get:function(){return chunkFTEVUZKX_js.c}});
@@ -1 +1 @@
1
- export{b as Toaster,c as toast}from'../chunk-BUZQBHJH.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
1
+ export{b as Toaster,c as toast}from'../chunk-DHCCF3XI.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
@@ -1 +1 @@
1
- 'use strict';var chunk4O2YPPA7_js=require('../chunk-4O2YPPA7.js');require('../chunk-6CZCNLSW.js'),require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Tree",{enumerable:true,get:function(){return chunk4O2YPPA7_js.d}});
1
+ 'use strict';var chunkTL6FYFGR_js=require('../chunk-TL6FYFGR.js');require('../chunk-FTEVUZKX.js'),require('../chunk-YSWFM6ML.js'),require('../chunk-DCDWEVW4.js');Object.defineProperty(exports,"Tree",{enumerable:true,get:function(){return chunkTL6FYFGR_js.d}});
@@ -1 +1 @@
1
- export{d as Tree}from'../chunk-2HFIPOFV.mjs';import'../chunk-BUZQBHJH.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
1
+ export{d as Tree}from'../chunk-6QCL57T5.mjs';import'../chunk-DHCCF3XI.mjs';import'../chunk-VV2IBN64.mjs';import'../chunk-DN2VKVCV.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lingee-ui",
3
- "version": "0.0.12",
3
+ "version": "0.0.13",
4
4
  "description": "Kingdee Lingee UI 基础组件库 — React 18+ 轻量级企业 UI 组件",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -2,7 +2,7 @@
2
2
 
3
3
  > **本文件由 `packages/lingee-ui/scripts/gen-skill.mjs` 自动生成,禁止手工编辑。**
4
4
  > 供根 `AGENTS.md` 引用,避免手写清单随组件库迭代脱节。
5
- > 组件库 `0.0.12` | 图标库 `1.0.18`
5
+ > 组件库 `0.0.13` | 图标库 `1.0.18`
6
6
 
7
7
  ## 可用组件(39)
8
8
 
package/skill/SKILL.md CHANGED
@@ -2,7 +2,7 @@
2
2
  name: lingee-ui-usage
3
3
  description: 使用 lingee-ui 组件库与 lingee-icon 图标库开发 React 界面。当需要编写含按钮、表单、弹窗、表格、下拉、页签、图标等 UI 的 React/TypeScript 代码,或需要查询 lingee-ui 组件 API、Design Token 语义变量、可用图标名时触发。关键词:lingee-ui、lingee-icon、组件库、图标库、Design Token、语义变量、lg- 前缀、UI 组件。
4
4
  metadata:
5
- lingeeUi: "0.0.12"
5
+ lingeeUi: "0.0.13"
6
6
  lingeeIcon: "1.0.18"
7
7
  generatedBy: "gen-skill.mjs"
8
8
  ---
@@ -12,7 +12,7 @@ metadata:
12
12
  Kingdee Lingee 设计体系的 React 组件库(39 个组件)与图标库(969 个图标)。
13
13
  本技能面向**消费方项目**,只覆盖「如何用」,不含组件库内部开发约定。
14
14
 
15
- - 组件库版本 `0.0.12` | 图标库版本 `1.0.18`
15
+ - 组件库版本 `0.0.13` | 图标库版本 `1.0.18`
16
16
  - 组件在线预览:https://kingdee.github.io/lingee-ui/
17
17
  - 图标在线预览:https://kingdee.github.io/lingee-icon/
18
18
 
@@ -1,7 +1,7 @@
1
1
  {
2
- "lingeeUi": "0.0.12",
2
+ "lingeeUi": "0.0.13",
3
3
  "lingeeIcon": "1.0.18",
4
4
  "componentCount": 39,
5
5
  "iconCount": 969,
6
- "sourceHash": "35b59f7fc5da06d3"
6
+ "sourceHash": "f2163ad2531e869c"
7
7
  }
@@ -45,6 +45,7 @@ export default function BasicDemo() {
45
45
  |------|------|------|--------|
46
46
  | `open` | 是否打开 | `boolean` | - |
47
47
  | `onOpenChange` | 打开状态变化回调 | `(open: boolean) => void` | - |
48
+ | `zIndex` | 遮罩层层级,内容层自动加 1;优先于 Provider 基线 | `number` | `LingeeProvider.dialog.zIndex` |
48
49
  | `title` | 标题 | `ReactNode` | - |
49
50
  | `description` | 描述文本 | `ReactNode` | - |
50
51
  | `width` | 宽度 | `number` | `460` |
@@ -66,3 +67,16 @@ export default function BasicDemo() {
66
67
  | `cancelText` | 取消按钮文本 | `string` | `"取消"` |
67
68
  | `okDanger` | 确认按钮是否为危险样式 | `boolean` | `false` |
68
69
  | `icon` | 自定义图标 | `ReactNode` | - |
70
+ | `zIndex` | 本次确认框层级,优先于 Provider 基线 | `number` | `LingeeProvider.dialog.zIndex` |
71
+
72
+ ### Dialog.closeConfirm()
73
+
74
+ 强制关闭确认弹窗的兜底 API:**当前显示的一项与队列中排队的全部**按 `false` 结算,与旧实现的无条件清场语义一致,不额外调用 `onCancel`。
75
+
76
+ 之所以连排队项一起清掉:调用方的意图是「确保某个弹窗不在了」,而目标弹窗可能还排在队里没显示,只关当前一项会关掉前面那个无关弹窗、目标弹窗随后照样弹出。
77
+
78
+ 需要精确关闭某一个弹窗时,不要依赖这个全局 API,改由调用方自己控制触发时机。
79
+
80
+ ### 宿主代理的兜底超时
81
+
82
+ 在客户端 webview 或被 iframe 嵌套的环境中,确认框会交由宿主渲染。若宿主受理后未回传结果(页面跳转、iframe 被卸载等),该次调用会在 5 分钟后按取消结算并放行队列,避免后续所有确认框失效。正常人工操作不会命中该超时。
@@ -1,6 +1,6 @@
1
1
  # 接入指南
2
2
 
3
- 组件库 `0.0.12` | 图标库 `1.0.18`
3
+ 组件库 `0.0.13` | 图标库 `1.0.18`
4
4
 
5
5
  ## 安装
6
6
 
@@ -1,6 +1,6 @@
1
1
  # 语义 Token 全表
2
2
 
3
- 组件库 `0.0.12`。仅列语义层(`--lg-g-*`)。
3
+ 组件库 `0.0.13`。仅列语义层(`--lg-g-*`)。
4
4
 
5
5
  亮色与暗色**变量名完全相同**,给 `<html>` 加 `data-theme="dark"` 即自动切换,业务代码只写一次。
6
6
 
@@ -1 +0,0 @@
1
- import {b}from'./chunk-B6CAD73P.mjs';import {h}from'./chunk-BUZQBHJH.mjs';import {a}from'./chunk-DN2VKVCV.mjs';import Bl,{useState,useRef,useCallback,useEffect,useLayoutEffect}from'react';import {cva}from'class-variance-authority';import*as s from'@radix-ui/react-tabs';import {ChevronLeft,ChevronRight}from'lingee-icon';import {jsxs,jsx}from'react/jsx-runtime';var C={arrows:true,step:200,fade:true,scrollIntoView:true},Sl=cva("lg-tabs",{variants:{variant:{segmented:"lg-tabs--segmented",rounded:"lg-tabs--rounded",solid:"lg-tabs--solid",outline:"lg-tabs--outline",underline:"lg-tabs--underline"},size:{sm:"lg-tabs--sm",md:"lg-tabs--md"}},defaultVariants:{variant:"segmented",size:"md"}}),ol=typeof window<"u"?useLayoutEffect:useEffect;function Ll({items:o,activeKey:d,defaultActiveKey:tl,onChange:N,variant:i="segmented",size:nl="md",overflow:sl,scrollOptions:y,wrap:il=false,scrollable:bl=false,glassy:cl=false,transparent:dl=false,animated:B=true,destroyInactivePanel:M=false,className:ul,dir:fl,...vl},pl){let V=h("Tabs"),O=sl??(bl?"scroll":il?"wrap":"none"),X=O==="wrap"&&(i==="segmented"||i==="rounded")?"none":O,a$1=X==="scroll",A=X==="wrap",P=y?.arrows??C.arrows,T=y?.step??C.step,H=y?.fade??C.fade,$=y?.scrollIntoView??C.scrollIntoView,u=d!==void 0,ml=o.find(l=>!l.disabled)?.key,W=u?void 0:tl??ml,[hl,wl]=useState(W),t=u?d:hl,k=useRef(o.findIndex(l=>l.key===t)),[j,x]=useState("right"),_l=useCallback(l=>{let g=o.findIndex(_=>_.key===l),r=k.current;g>r?x("right"):g<r&&x("left"),k.current=g,u||wl(l),N?.(l);},[u,N,o]);useEffect(()=>{if(u&&d){let l=o.findIndex(r=>r.key===d),g=k.current;l!==g&&(l>g?x("right"):x("left"),k.current=l);}},[u,d,o]);let q=o.some(l=>l.children!=null),n=useRef(null),E=useRef(new Map),[Fl,R]=useState({opacity:0}),h$1=useRef(false),U=useRef(0),yl=useCallback(l=>g=>{g?E.current.set(l,g):E.current.delete(l);},[]),w=useCallback(l=>{let g=n.current,r=t?E.current.get(t):void 0;if(!g||!r){R(al=>al.opacity===0?al:{opacity:0});return}let _=g.getBoundingClientRect(),v=(i==="underline"?r.querySelector(".lg-tabs__tab-label")??r:r).getBoundingClientRect(),rl=v.left-_.left+g.scrollLeft;if(!A){R({width:v.width,transform:`translateX(${rl}px)`,opacity:1,transition:l?"transform var(--_tabs-slider-duration) var(--lg-transition-timing), width var(--_tabs-slider-duration) var(--lg-transition-timing)":"none"});return}let S=i==="underline",Cl=S?r.getBoundingClientRect():v,L=S?Cl.bottom-_.top:v.top-_.top,Dl=l&&Math.abs(L-U.current)>1;U.current=L,R({width:v.width,...S?null:{height:v.height},top:0,bottom:"auto",transform:`translate(${rl}px, ${L}px)`,opacity:1,transition:Dl?"opacity var(--_tabs-slider-duration) var(--lg-transition-timing)":l?"transform var(--_tabs-slider-duration) var(--lg-transition-timing), width var(--_tabs-slider-duration) var(--lg-transition-timing)":"none"});},[t,i,A]),Y=useRef(w);Y.current=w;let G=useRef(0);ol(()=>{let l=h$1.current;w(l),l&&(G.current=Date.now()),h$1.current=true;},[w,t]);let J=o.map(l=>`${l.key}:${l.disabled?1:0}`).join("|");ol(()=>{let l=h$1.current;h$1.current=false,w(false),h$1.current=l;},[J]),useEffect(()=>{if(!n.current)return;let l=new ResizeObserver(()=>{Date.now()-G.current<350||Y.current(false);});return l.observe(n.current),()=>l.disconnect()},[]);let[kl,Q]=useState(false),[Z,xl]=useState(false),[K,El]=useState(false),f=useCallback(()=>{let l=n.current;!l||!a$1||(Q(l.scrollWidth>l.clientWidth+1),xl(l.scrollLeft>1),El(l.scrollLeft+l.clientWidth<l.scrollWidth-1));},[a$1]);useEffect(()=>{if(!a$1){Q(false);return}let l=n.current;if(l)return f(),l.addEventListener("scroll",f),()=>l.removeEventListener("scroll",f)},[a$1,f,J]),useEffect(()=>{let l=n.current;if(!a$1||!l)return;let g=new ResizeObserver(()=>f());return g.observe(l),()=>g.disconnect()},[a$1,f]),useEffect(()=>{if(!a$1||!$||!t)return;let l=E.current.get(t);typeof l?.scrollIntoView=="function"&&l.scrollIntoView({behavior:"smooth",inline:"nearest",block:"nearest"});},[a$1,$,t]);let ll=useCallback((l,g)=>{let r=n.current;r&&(r.scrollBy({left:l==="left"?-T:T,behavior:"smooth"}),g&&g.detail>0&&g.currentTarget.blur());},[T]),z=a$1&&kl&&P!==false,gl=jsxs(s.List,{className:a("lg-tabs__list",a$1&&"lg-tabs__list--scrollable"),ref:n,children:[jsx("span",{className:a(`lg-tabs__slider lg-tabs__slider--${i}`,cl&&"lg-tabs__slider--glassy"),style:Fl,"aria-hidden":true}),o.map(l=>jsxs(s.Trigger,{value:l.key,disabled:l.disabled,ref:yl(l.key),"aria-label":l.ariaLabel,className:a("lg-tabs__tab",l.disabled&&"lg-tabs__tab--disabled"),children:[l.icon&&jsx("span",{className:"lg-tabs__tab-icon",children:l.icon}),jsx("span",{className:"lg-tabs__tab-label",children:l.label}),l.suffix!=null&&jsx("span",{className:"lg-tabs__tab-suffix",children:l.suffix})]},l.key))]});return jsxs(s.Root,{ref:pl,className:a(Sl({variant:i,size:nl}),A&&"lg-tabs--wrap",a$1&&"lg-tabs--scrollable",dl&&"lg-tabs--transparent",q&&"lg-tabs--has-content",ul),value:d,defaultValue:W,onValueChange:_l,dir:fl,...vl,children:[a$1?jsxs("div",{className:a("lg-tabs__scroll-wrapper",P==="hover"&&"lg-tabs__scroll-wrapper--hover-controls",!z&&"lg-tabs__scroll-wrapper--no-arrows"),children:[z&&jsx(b,{shape:"circle",size:"sm",variant:"text",icon:jsx(ChevronLeft,{}),tooltip:V.scrollLeft,disabled:!Z,onClick:l=>ll("left",l),className:"lg-tabs__scroll-arrow lg-tabs__scroll-arrow--left"}),H&&Z&&jsx("span",{className:"lg-tabs__fade lg-tabs__fade--left","aria-hidden":true}),gl,H&&K&&jsx("span",{className:"lg-tabs__fade lg-tabs__fade--right","aria-hidden":true}),z&&jsx(b,{shape:"circle",size:"sm",variant:"text",icon:jsx(ChevronRight,{}),tooltip:V.scrollRight,disabled:!K,onClick:l=>ll("right",l),className:"lg-tabs__scroll-arrow lg-tabs__scroll-arrow--right"})]}):gl,q&&jsx("div",{className:"lg-tabs__content-wrapper",children:o.map(l=>{if(l.children==null)return null;let g=l.key===t;return M&&!g?null:jsx(s.Content,{value:l.key,forceMount:M?void 0:true,className:a("lg-tabs__panel",B&&"lg-tabs__panel--animated",g&&"lg-tabs__panel--active",!g&&"lg-tabs__panel--inactive",B&&j==="right"&&"lg-tabs__panel--slide-right",B&&j==="left"&&"lg-tabs__panel--slide-left"),children:l.children},l.key)})})]})}var ql=Bl.forwardRef(Ll);export{Sl as a,ql as b};
@@ -1 +0,0 @@
1
- 'use strict';var chunkYSWFM6ML_js=require('./chunk-YSWFM6ML.js'),chunkDCDWEVW4_js=require('./chunk-DCDWEVW4.js'),_e=require('react'),sonner=require('sonner'),lingeeIcon=require('lingee-icon'),jsxRuntime=require('react/jsx-runtime');function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var _e__default=/*#__PURE__*/_interopDefault(_e);var oe={locale:"zh-CN",Button:{},Breadcrumb:{more:"\u66F4\u591A",back:"\u8FD4\u56DE"},Select:{loading:"\u52A0\u8F7D\u4E2D",loadError:"\u52A0\u8F7D\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5",loadFailed:"\u52A0\u8F7D\u5931\u8D25",notFound:"\u641C\u7D22\u65E0\u7ED3\u679C",clear:"\u6E05\u7A7A"},Dropdown:{clear:"\u6E05\u9664",loading:"\u52A0\u8F7D\u4E2D",loadError:"\u52A0\u8F7D\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5",empty:"\u6682\u65E0\u6570\u636E"},Tabs:{scrollLeft:"\u5411\u5DE6\u6EDA\u52A8",scrollRight:"\u5411\u53F3\u6EDA\u52A8"},Carousel:{carousel:"\u8F6E\u64AD",prev:"\u4E0A\u4E00\u5F20",next:"\u4E0B\u4E00\u5F20",goToPage:"\u8DF3\u8F6C\u5230\u7B2C {page} \u5F20"},Form:{required:"{label}\u4E0D\u80FD\u4E3A\u7A7A",requiredNoLabel:"\u6B64\u9879\u4E0D\u80FD\u4E3A\u7A7A"},Tag:{close:"\u5173\u95ED"},Upload:{retry:"\u91CD\u65B0\u4E0A\u4F20",remove:"\u79FB\u9664\u6587\u4EF6",removeShort:"\u79FB\u9664",dragText:"\u62D6\u62FD\u6587\u4EF6\u5230\u6B64\u5904\uFF0C\u6216",clickUpload:"\u70B9\u51FB\u4E0A\u4F20"},ColorPicker:{placeholder:"\u8BF7\u9009\u62E9\u989C\u8272"},DatePicker:{placeholder:"\u5E74/\u6708/\u65E5",today:"\u4ECA\u5929",prevYear:"\u4E0A\u4E00\u5E74",nextYear:"\u4E0B\u4E00\u5E74",prevMonth:"\u4E0A\u4E00\u6708",nextMonth:"\u4E0B\u4E00\u6708",prevDecade:"\u4E0A\u4E00\u7EC4\u5E74\u4EFD",nextDecade:"\u4E0B\u4E00\u7EC4\u5E74\u4EFD",months:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],yearFormat:"{year}\u5E74",monthFormat:"{month}\u6708"},RangePicker:{startPlaceholder:"\u5E74/\u6708/\u65E5",endPlaceholder:"\u5E74/\u6708/\u65E5"},TimePicker:{now:"\u73B0\u5728",confirm:"\u786E\u5B9A",placeholder:"\u65F6:\u5206",placeholderFull:"\u65F6:\u5206:\u79D2"},Table:{empty:"\u6682\u65E0\u6570\u636E"},Tree:{empty:"\u6682\u65E0\u6570\u636E"},Pagination:{total:"\u5171 {total} \u6761",prevPage:"\u4E0A\u4E00\u9875",nextPage:"\u4E0B\u4E00\u9875",itemsPerPage:"{size}\u6761/\u9875",jumpTo:"\u8DF3\u81F3",page:"\u9875"},Dialog:{close:"\u5173\u95ED"},Drawer:{close:"\u5173\u95ED"},Input:{clear:"\u6E05\u7A7A",expand:"\u5C55\u5F00\u8F93\u5165\u6846"},Alert:{close:"\u5173\u95ED"},Toast:{close:"\u5173\u95ED\u6D88\u606F"},Spin:{loading:"\u52A0\u8F7D\u4E2D"},Empty:{retry:"\u91CD\u8BD5"}},x=oe;var C=new Map,M=0;function I(){return M+=1,{id:M}}function F(e,t,o){C.set(e.id,{site:t,depth:o});}function A(e){C.delete(e.id);}function ne(){let e;for(let t of C.values())(!e||t.depth>=e.depth)&&(e=t);return e?.site}function k(){return ne()==="lingee"}var re={locale:"en-US",Button:{},Breadcrumb:{more:"More",back:"Back"},Select:{loading:"Loading",loadError:"Failed to load, please retry",loadFailed:"Failed to load",notFound:"No results found",clear:"Clear"},Dropdown:{clear:"Clear",loading:"Loading",loadError:"Failed to load, please retry",empty:"No data"},Tabs:{scrollLeft:"Scroll left",scrollRight:"Scroll right"},Carousel:{carousel:"Carousel",prev:"Previous slide",next:"Next slide",goToPage:"Go to slide {page}"},Form:{required:"{label} is required",requiredNoLabel:"This field is required"},Tag:{close:"Close"},Upload:{retry:"Retry upload",remove:"Remove file",removeShort:"Remove",dragText:"Drag files here, or ",clickUpload:"click to upload"},ColorPicker:{placeholder:"Select a color"},DatePicker:{placeholder:"YYYY/MM/DD",today:"Today",prevYear:"Previous year",nextYear:"Next year",prevMonth:"Previous month",nextMonth:"Next month",prevDecade:"Previous decade",nextDecade:"Next decade",months:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],yearFormat:"{year}",monthFormat:"{month}"},RangePicker:{startPlaceholder:"Start date",endPlaceholder:"End date"},TimePicker:{now:"Now",confirm:"OK",placeholder:"HH:mm",placeholderFull:"HH:mm:ss"},Table:{empty:"No data"},Tree:{empty:"No data"},Pagination:{total:"{total} items",prevPage:"Previous page",nextPage:"Next page",itemsPerPage:"{size} / page",jumpTo:"Go to",page:""},Dialog:{close:"Close"},Drawer:{close:"Close"},Input:{clear:"Clear",expand:"Expand input"},Alert:{close:"Close"},Toast:{close:"Close message"},Spin:{loading:"Loading"},Empty:{retry:"Retry"}},ie=re;var B=_e.createContext(x),U=_e.createContext(void 0),z=_e.createContext(-1);function le({locale:e=x,site:t,children:o}){let n=_e.useContext(z)+1,s=_e.useRef();s.current||(s.current=I());let r=s.current;F(r,t,n),_e.useEffect(()=>()=>A(r),[r]);let i=jsxRuntime.jsx(z.Provider,{value:n,children:jsxRuntime.jsx(U.Provider,{value:t,children:jsxRuntime.jsxs(B.Provider,{value:e,children:[o,n===0&&jsxRuntime.jsx(Y,{})]})})});return n===0?jsxRuntime.jsx(chunkYSWFM6ML_js.c,{children:i}):i}le.displayName="LingeeProvider";function de(){return _e.useContext(B)}function G(e){return de()[e]}function Ye(){return _e.useContext(U)}var Te={info:jsxRuntime.jsx(lingeeIcon.ExclamationCircleFill,{size:20}),success:jsxRuntime.jsx(lingeeIcon.CheckCircleFill,{size:20}),warning:jsxRuntime.jsx(lingeeIcon.ExclamationCircleFill1,{size:20}),error:jsxRuntime.jsx(lingeeIcon.XCircleFill,{size:20})};function q({type:e,content:t,icon:o,closable:n,className:s,onClose:r}){let i=G("Toast"),a=()=>{if(o===null)return null;let l=o!==void 0?o:Te[e];return jsxRuntime.jsx("span",{className:"lg-toast__icon",children:l})};return jsxRuntime.jsxs("div",{className:chunkDCDWEVW4_js.a("lg-toast",`lg-toast--${e}`,s),children:[a(),jsxRuntime.jsx("span",{className:"lg-toast__content",children:t}),n&&jsxRuntime.jsx("button",{className:"lg-toast__close",onClick:r,"aria-label":i.close,type:"button",children:jsxRuntime.jsx(lingeeIcon.XLg,{size:16})})]})}var K="lingee-web-bridge",X="1.0.0",ye="host",ve="iframe",he="lingee-web-bridge:host-toast-show",be="lingee-web-bridge:host-toast-dismiss",we="lingee-web-bridge:host-toast-probe",Se="lingee-web-bridge:host-toast-ready";function J(){if(typeof crypto<"u"&&typeof crypto.randomUUID=="function")return crypto.randomUUID();let e=Date.now();return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{let o=(e+Math.random()*16)%16|0;return e=Math.floor(e/16),(t==="x"?o:o&3|8).toString(16)})}function Ce(e,t){return {_protocol:K,_version:X,_source:e,_nonce:J(),_traceId:"",payload:t}}function ke(e,t){if(typeof e!="object"||e===null)return false;let o=e;return o._protocol===K&&o._version===X&&o._source===t&&typeof o._nonce=="string"&&"payload"in o}function m(){return typeof window<"u"&&window.parent!==window}var g=false,u=new Map,j=false;function Pe(e){if(!ke(e,ye))return false;let t=e.payload;return !!t&&typeof t=="object"&&t.type===Se}function L(e){window.parent.postMessage(Ce(ve,e),"*");}function v(){j||!m()||(j=true,window.addEventListener("message",e=>{e.source===window.parent&&Pe(e.data)&&(g=true);}),window.addEventListener("pagehide",()=>{!g||u.size===0||h();}),L({type:we}));}function E(){return v(),g}function V(e){if(v(),!g||!e.content)return null;let t=J();L({type:he,toastId:t,content:e.content.slice(0,500),level:e.level,duration:e.duration,key:e.key});let o=e.duration??3e3,n=o>0?window.setTimeout(()=>u.delete(t),o+500):void 0;return u.set(t,n),t}function h(e){if(v(),!!g){if(e){let t=u.get(e);t!==void 0&&window.clearTimeout(t),u.delete(e);}else u.forEach(t=>{t!==void 0&&window.clearTimeout(t);}),u.clear();L({type:be,toastId:e});}}v();function N(){if(!(typeof window>"u"))return window.lingeeBridge}function W(e){if(typeof e=="string")return e;if(typeof e=="number")return String(e)}function $(e,t={}){return !(!(m()?E():k()&&typeof N()?.showToast=="function")||W(e.content)===void 0||e.icon!==void 0||e.className!==void 0||e.closable||t.getContainer!==void 0||t.top!==void 0||t.maxCount!==void 0)}function Q(e,t,o,n={}){let s=W(t.content);if(s===void 0)return null;let r={level:e,content:s,duration:o,key:t.key};if(m()){let d=V(r);return d?(n.onAccepted?.(),{dismiss:()=>h(d)}):null}let i=N(),a=i?.showToast;if(!a)return null;let l=null,f=null,T=false,R=false,D=()=>{T||R||f||(f=n.onFallback?.()??null);};return Promise.resolve().then(()=>a(r)).then(d=>{if(!d?.ok||!d.toastId){D();return}if(R=true,l=d.toastId,T){i?.dismissToast?.(l);return}n.onAccepted?.();}).catch(d=>{console.error("[lingee-ui] showToast failed:",d),D();}),{dismiss:()=>{if(!T){if(T=true,f){f(),f=null;return}l&&i?.dismissToast?.(l);}}}}function Z(){if(m())return E()?(h(),true):false;let e=N();return !k()||typeof e?.dismissToast!="function"?false:(e.dismissToast().catch(t=>{console.error("[lingee-ui] dismissToast failed:",t);}),true)}var p={};function Y(){let e=p.top??16;return jsxRuntime.jsx(sonner.Toaster,{position:"top-center",offset:e,gap:8,closeButton:false,toastOptions:{unstyled:true,className:"lg-toast-wrapper"},style:{"--width":"560px"}})}function Ee(e){let t=e[0];return typeof t=="object"&&t!==null&&!_e__default.default.isValidElement(t)?t:{content:t,duration:e[1],onClose:e[2]}}function ee(e,t,o,n=()=>t.onClose?.()){let s=o===0?1/0:o,r=false,i=()=>{r||(r=true,n());},a=sonner.toast.custom(l=>jsxRuntime.jsx(q,{type:e,content:t.content,icon:t.icon,closable:t.closable,className:t.className,onClose:()=>sonner.toast.dismiss(l)}),{...t.key!==void 0&&{id:t.key},duration:s,onAutoClose:i,onDismiss:i});return ()=>{sonner.toast.dismiss(a),i();}}var S=new Set;function Ne(e,t){let o=t.duration!==void 0?t.duration<0?p.duration??3e3:t.duration:p.duration??3e3;if($(t,p)){let n=false,s,r=()=>{},i=()=>{n||(n=true,s!==void 0&&clearTimeout(s),S.delete(r),t.onClose?.());},a=Q(e,t,o,{onAccepted:()=>{o>0&&!n&&(s=setTimeout(i,o));},onFallback:()=>ee(e,{...t,onClose:void 0},o,i)});if(a)return r=()=>{n||(a.dismiss(),i());},S.add(r),r}return ee(e,t,o)}function b(e){return (...t)=>{let o=Ee(t);return Ne(e,o)}}var at={info:b("info"),success:b("success"),warning:b("warning"),error:b("error"),destroy:()=>{Array.from(S).forEach(e=>e()),S.clear(),Z(),sonner.toast.dismiss();},config:e=>{p={...p,...e};}};exports.a=k;exports.b=Y;exports.c=at;exports.d=x;exports.e=ie;exports.f=le;exports.g=de;exports.h=G;exports.i=Ye;
@@ -1 +0,0 @@
1
- import {c}from'./chunk-VV2IBN64.mjs';import {a}from'./chunk-DN2VKVCV.mjs';import _e,{createContext,useContext,useRef,useEffect}from'react';import {Toaster,toast}from'sonner';import {XCircleFill,ExclamationCircleFill1,CheckCircleFill,ExclamationCircleFill,XLg}from'lingee-icon';import {jsx,jsxs}from'react/jsx-runtime';var oe={locale:"zh-CN",Button:{},Breadcrumb:{more:"\u66F4\u591A",back:"\u8FD4\u56DE"},Select:{loading:"\u52A0\u8F7D\u4E2D",loadError:"\u52A0\u8F7D\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5",loadFailed:"\u52A0\u8F7D\u5931\u8D25",notFound:"\u641C\u7D22\u65E0\u7ED3\u679C",clear:"\u6E05\u7A7A"},Dropdown:{clear:"\u6E05\u9664",loading:"\u52A0\u8F7D\u4E2D",loadError:"\u52A0\u8F7D\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5",empty:"\u6682\u65E0\u6570\u636E"},Tabs:{scrollLeft:"\u5411\u5DE6\u6EDA\u52A8",scrollRight:"\u5411\u53F3\u6EDA\u52A8"},Carousel:{carousel:"\u8F6E\u64AD",prev:"\u4E0A\u4E00\u5F20",next:"\u4E0B\u4E00\u5F20",goToPage:"\u8DF3\u8F6C\u5230\u7B2C {page} \u5F20"},Form:{required:"{label}\u4E0D\u80FD\u4E3A\u7A7A",requiredNoLabel:"\u6B64\u9879\u4E0D\u80FD\u4E3A\u7A7A"},Tag:{close:"\u5173\u95ED"},Upload:{retry:"\u91CD\u65B0\u4E0A\u4F20",remove:"\u79FB\u9664\u6587\u4EF6",removeShort:"\u79FB\u9664",dragText:"\u62D6\u62FD\u6587\u4EF6\u5230\u6B64\u5904\uFF0C\u6216",clickUpload:"\u70B9\u51FB\u4E0A\u4F20"},ColorPicker:{placeholder:"\u8BF7\u9009\u62E9\u989C\u8272"},DatePicker:{placeholder:"\u5E74/\u6708/\u65E5",today:"\u4ECA\u5929",prevYear:"\u4E0A\u4E00\u5E74",nextYear:"\u4E0B\u4E00\u5E74",prevMonth:"\u4E0A\u4E00\u6708",nextMonth:"\u4E0B\u4E00\u6708",prevDecade:"\u4E0A\u4E00\u7EC4\u5E74\u4EFD",nextDecade:"\u4E0B\u4E00\u7EC4\u5E74\u4EFD",months:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],yearFormat:"{year}\u5E74",monthFormat:"{month}\u6708"},RangePicker:{startPlaceholder:"\u5E74/\u6708/\u65E5",endPlaceholder:"\u5E74/\u6708/\u65E5"},TimePicker:{now:"\u73B0\u5728",confirm:"\u786E\u5B9A",placeholder:"\u65F6:\u5206",placeholderFull:"\u65F6:\u5206:\u79D2"},Table:{empty:"\u6682\u65E0\u6570\u636E"},Tree:{empty:"\u6682\u65E0\u6570\u636E"},Pagination:{total:"\u5171 {total} \u6761",prevPage:"\u4E0A\u4E00\u9875",nextPage:"\u4E0B\u4E00\u9875",itemsPerPage:"{size}\u6761/\u9875",jumpTo:"\u8DF3\u81F3",page:"\u9875"},Dialog:{close:"\u5173\u95ED"},Drawer:{close:"\u5173\u95ED"},Input:{clear:"\u6E05\u7A7A",expand:"\u5C55\u5F00\u8F93\u5165\u6846"},Alert:{close:"\u5173\u95ED"},Toast:{close:"\u5173\u95ED\u6D88\u606F"},Spin:{loading:"\u52A0\u8F7D\u4E2D"},Empty:{retry:"\u91CD\u8BD5"}},x=oe;var C=new Map,M=0;function I(){return M+=1,{id:M}}function F(e,t,o){C.set(e.id,{site:t,depth:o});}function A(e){C.delete(e.id);}function ne(){let e;for(let t of C.values())(!e||t.depth>=e.depth)&&(e=t);return e?.site}function k(){return ne()==="lingee"}var re={locale:"en-US",Button:{},Breadcrumb:{more:"More",back:"Back"},Select:{loading:"Loading",loadError:"Failed to load, please retry",loadFailed:"Failed to load",notFound:"No results found",clear:"Clear"},Dropdown:{clear:"Clear",loading:"Loading",loadError:"Failed to load, please retry",empty:"No data"},Tabs:{scrollLeft:"Scroll left",scrollRight:"Scroll right"},Carousel:{carousel:"Carousel",prev:"Previous slide",next:"Next slide",goToPage:"Go to slide {page}"},Form:{required:"{label} is required",requiredNoLabel:"This field is required"},Tag:{close:"Close"},Upload:{retry:"Retry upload",remove:"Remove file",removeShort:"Remove",dragText:"Drag files here, or ",clickUpload:"click to upload"},ColorPicker:{placeholder:"Select a color"},DatePicker:{placeholder:"YYYY/MM/DD",today:"Today",prevYear:"Previous year",nextYear:"Next year",prevMonth:"Previous month",nextMonth:"Next month",prevDecade:"Previous decade",nextDecade:"Next decade",months:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],yearFormat:"{year}",monthFormat:"{month}"},RangePicker:{startPlaceholder:"Start date",endPlaceholder:"End date"},TimePicker:{now:"Now",confirm:"OK",placeholder:"HH:mm",placeholderFull:"HH:mm:ss"},Table:{empty:"No data"},Tree:{empty:"No data"},Pagination:{total:"{total} items",prevPage:"Previous page",nextPage:"Next page",itemsPerPage:"{size} / page",jumpTo:"Go to",page:""},Dialog:{close:"Close"},Drawer:{close:"Close"},Input:{clear:"Clear",expand:"Expand input"},Alert:{close:"Close"},Toast:{close:"Close message"},Spin:{loading:"Loading"},Empty:{retry:"Retry"}},ie=re;var B=createContext(x),U=createContext(void 0),z=createContext(-1);function le({locale:e=x,site:t,children:o}){let n=useContext(z)+1,s=useRef();s.current||(s.current=I());let r=s.current;F(r,t,n),useEffect(()=>()=>A(r),[r]);let i=jsx(z.Provider,{value:n,children:jsx(U.Provider,{value:t,children:jsxs(B.Provider,{value:e,children:[o,n===0&&jsx(Y,{})]})})});return n===0?jsx(c,{children:i}):i}le.displayName="LingeeProvider";function de(){return useContext(B)}function G(e){return de()[e]}function Ye(){return useContext(U)}var Te={info:jsx(ExclamationCircleFill,{size:20}),success:jsx(CheckCircleFill,{size:20}),warning:jsx(ExclamationCircleFill1,{size:20}),error:jsx(XCircleFill,{size:20})};function q({type:e,content:t,icon:o,closable:n,className:s,onClose:r}){let i=G("Toast"),a$1=()=>{if(o===null)return null;let l=o!==void 0?o:Te[e];return jsx("span",{className:"lg-toast__icon",children:l})};return jsxs("div",{className:a("lg-toast",`lg-toast--${e}`,s),children:[a$1(),jsx("span",{className:"lg-toast__content",children:t}),n&&jsx("button",{className:"lg-toast__close",onClick:r,"aria-label":i.close,type:"button",children:jsx(XLg,{size:16})})]})}var K="lingee-web-bridge",X="1.0.0",ye="host",ve="iframe",he="lingee-web-bridge:host-toast-show",be="lingee-web-bridge:host-toast-dismiss",we="lingee-web-bridge:host-toast-probe",Se="lingee-web-bridge:host-toast-ready";function J(){if(typeof crypto<"u"&&typeof crypto.randomUUID=="function")return crypto.randomUUID();let e=Date.now();return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{let o=(e+Math.random()*16)%16|0;return e=Math.floor(e/16),(t==="x"?o:o&3|8).toString(16)})}function Ce(e,t){return {_protocol:K,_version:X,_source:e,_nonce:J(),_traceId:"",payload:t}}function ke(e,t){if(typeof e!="object"||e===null)return false;let o=e;return o._protocol===K&&o._version===X&&o._source===t&&typeof o._nonce=="string"&&"payload"in o}function m(){return typeof window<"u"&&window.parent!==window}var g=false,u=new Map,j=false;function Pe(e){if(!ke(e,ye))return false;let t=e.payload;return !!t&&typeof t=="object"&&t.type===Se}function L(e){window.parent.postMessage(Ce(ve,e),"*");}function v(){j||!m()||(j=true,window.addEventListener("message",e=>{e.source===window.parent&&Pe(e.data)&&(g=true);}),window.addEventListener("pagehide",()=>{!g||u.size===0||h();}),L({type:we}));}function E(){return v(),g}function V(e){if(v(),!g||!e.content)return null;let t=J();L({type:he,toastId:t,content:e.content.slice(0,500),level:e.level,duration:e.duration,key:e.key});let o=e.duration??3e3,n=o>0?window.setTimeout(()=>u.delete(t),o+500):void 0;return u.set(t,n),t}function h(e){if(v(),!!g){if(e){let t=u.get(e);t!==void 0&&window.clearTimeout(t),u.delete(e);}else u.forEach(t=>{t!==void 0&&window.clearTimeout(t);}),u.clear();L({type:be,toastId:e});}}v();function N(){if(!(typeof window>"u"))return window.lingeeBridge}function W(e){if(typeof e=="string")return e;if(typeof e=="number")return String(e)}function $(e,t={}){return !(!(m()?E():k()&&typeof N()?.showToast=="function")||W(e.content)===void 0||e.icon!==void 0||e.className!==void 0||e.closable||t.getContainer!==void 0||t.top!==void 0||t.maxCount!==void 0)}function Q(e,t,o,n={}){let s=W(t.content);if(s===void 0)return null;let r={level:e,content:s,duration:o,key:t.key};if(m()){let d=V(r);return d?(n.onAccepted?.(),{dismiss:()=>h(d)}):null}let i=N(),a=i?.showToast;if(!a)return null;let l=null,f=null,T=false,R=false,D=()=>{T||R||f||(f=n.onFallback?.()??null);};return Promise.resolve().then(()=>a(r)).then(d=>{if(!d?.ok||!d.toastId){D();return}if(R=true,l=d.toastId,T){i?.dismissToast?.(l);return}n.onAccepted?.();}).catch(d=>{console.error("[lingee-ui] showToast failed:",d),D();}),{dismiss:()=>{if(!T){if(T=true,f){f(),f=null;return}l&&i?.dismissToast?.(l);}}}}function Z(){if(m())return E()?(h(),true):false;let e=N();return !k()||typeof e?.dismissToast!="function"?false:(e.dismissToast().catch(t=>{console.error("[lingee-ui] dismissToast failed:",t);}),true)}var p={};function Y(){let e=p.top??16;return jsx(Toaster,{position:"top-center",offset:e,gap:8,closeButton:false,toastOptions:{unstyled:true,className:"lg-toast-wrapper"},style:{"--width":"560px"}})}function Ee(e){let t=e[0];return typeof t=="object"&&t!==null&&!_e.isValidElement(t)?t:{content:t,duration:e[1],onClose:e[2]}}function ee(e,t,o,n=()=>t.onClose?.()){let s=o===0?1/0:o,r=false,i=()=>{r||(r=true,n());},a=toast.custom(l=>jsx(q,{type:e,content:t.content,icon:t.icon,closable:t.closable,className:t.className,onClose:()=>toast.dismiss(l)}),{...t.key!==void 0&&{id:t.key},duration:s,onAutoClose:i,onDismiss:i});return ()=>{toast.dismiss(a),i();}}var S=new Set;function Ne(e,t){let o=t.duration!==void 0?t.duration<0?p.duration??3e3:t.duration:p.duration??3e3;if($(t,p)){let n=false,s,r=()=>{},i=()=>{n||(n=true,s!==void 0&&clearTimeout(s),S.delete(r),t.onClose?.());},a=Q(e,t,o,{onAccepted:()=>{o>0&&!n&&(s=setTimeout(i,o));},onFallback:()=>ee(e,{...t,onClose:void 0},o,i)});if(a)return r=()=>{n||(a.dismiss(),i());},S.add(r),r}return ee(e,t,o)}function b(e){return (...t)=>{let o=Ee(t);return Ne(e,o)}}var at={info:b("info"),success:b("success"),warning:b("warning"),error:b("error"),destroy:()=>{Array.from(S).forEach(e=>e()),S.clear(),Z(),toast.dismiss();},config:e=>{p={...p,...e};}};export{k as a,Y as b,at as c,x as d,ie as e,le as f,de as g,G as h,Ye as i};
@@ -1 +0,0 @@
1
- import {h}from'./chunk-BUZQBHJH.mjs';import {a}from'./chunk-DN2VKVCV.mjs';import G,{useState,useRef,useCallback,useEffect}from'react';import {XCircleFill}from'lingee-icon';import {jsxs,jsx}from'react/jsx-runtime';var U=G.forwardRef(({className:l,style:o,size:a$1="md",shape:M="default",prefix:d,suffix:s,allowClear:T=false,error:C=false,disabled:r=false,collapsed:t=false,value:g,defaultValue:L,onChange:c,onFocus:_,onBlur:f,onPressEnter:v,onKeyDown:h$1,onClick:b,...H},S)=>{let m=h("Input"),[N,x]=useState(false),[D,y]=useState(L?.toString()??""),e=useRef(null),F=Y(S,e),u=g!==void 0,w=u?g?.toString()??"":D,O=useCallback(n=>{u||y(n.target.value),c?.(n);},[u,c]),P=useCallback(()=>{if(r)return;u||y("");let n=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value")?.set;if(e.current&&n){n.call(e.current,"");let A=new Event("input",{bubbles:true});e.current.dispatchEvent(A);}e.current?.focus();},[r,u]),V=useCallback(n=>{x(true),_?.(n);},[_]),j=useCallback(n=>{x(false),f?.(n);},[f]),B=useCallback(n=>{n.key==="Enter"&&v?.(n),h$1?.(n);},[v,h$1]),K=T&&w.length>0&&!r&&!t,W=!!s&&!(t&&d),k=useRef(t);useEffect(()=>{let n=k.current;k.current=t,n!==t&&(t?e.current===document.activeElement&&e.current?.blur():r||e.current?.focus());},[t,r]);let X=useCallback(n=>{t||e.current?.focus(),b?.(n);},[t,b]),$=a("lg-input",`lg-input--${a$1}`,M==="round"&&"lg-input--round",N&&!t&&"lg-input--focused",C&&"lg-input--error",r&&"lg-input--disabled",t&&"lg-input--collapsed",l),q=t?{...o,width:void 0,minWidth:void 0,maxWidth:void 0}:o;return jsxs("div",{className:$,style:q,onClick:X,role:t?"button":void 0,tabIndex:t&&!r?0:void 0,"aria-expanded":t?false:void 0,"aria-label":t?m.expand:void 0,children:[d&&jsx("span",{className:"lg-input__prefix",children:d}),jsx("input",{ref:F,className:"lg-input__inner",disabled:r,value:w,onChange:O,onFocus:V,onBlur:j,onKeyDown:B,tabIndex:t?-1:void 0,"aria-hidden":t||void 0,...H}),K&&jsx("span",{className:"lg-input__clear",onMouseDown:n=>n.preventDefault(),onClick:P,role:"button","aria-label":m.clear,children:jsx(XCircleFill,{})}),W&&jsx("span",{className:"lg-input__suffix",children:s})]})});U.displayName="Input";function Y(...l){return useCallback(o=>{l.forEach(a=>{a&&(typeof a=="function"?a(o):a.current=o);});},l)}export{U as a};