kwant-ui 3.17.0 → 3.17.1
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.
- package/dist/index.es.js +5 -1
- package/dist/index.js +5 -1
- package/dist/package.json +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -2059,6 +2059,8 @@ import{jsx as e,jsxs as t}from"react/jsx-runtime";import c,{css as r,createGloba
|
|
|
2059
2059
|
}
|
|
2060
2060
|
`;function On({size:t}){return e(En,{children:e("span",{className:`loader ${t||"large"}`})})}const Pn=c.div`
|
|
2061
2061
|
.badge {
|
|
2062
|
+
min-width: 24px;
|
|
2063
|
+
min-height: 24px;
|
|
2062
2064
|
display: inline-flex;
|
|
2063
2065
|
flex-direction: column;
|
|
2064
2066
|
justify-content: center;
|
|
@@ -3186,7 +3188,9 @@ import{jsx as e,jsxs as t}from"react/jsx-runtime";import c,{css as r,createGloba
|
|
|
3186
3188
|
height: ${e=>e.tabHeight};
|
|
3187
3189
|
color: ${e=>e.isActive?e.theme.secondary.secondary100:e.theme.grey.grey500};
|
|
3188
3190
|
|
|
3191
|
+
div,
|
|
3189
3192
|
span {
|
|
3193
|
+
min-width: 20px;
|
|
3190
3194
|
display: grid;
|
|
3191
3195
|
place-items: center;
|
|
3192
3196
|
${e=>e.fullWidth&&r`
|
|
@@ -3209,7 +3213,7 @@ import{jsx as e,jsxs as t}from"react/jsx-runtime";import c,{css as r,createGloba
|
|
|
3209
3213
|
width: ${e=>e.width};
|
|
3210
3214
|
left: ${e=>e.left};
|
|
3211
3215
|
background-color: ${e=>e.theme.secondary.secondary100};
|
|
3212
|
-
`,la=e=>e?.clientWidth,ia=({activeTab:c,tabs:r=[],tabHeight:n,fullWidth:a,showNeutralBorder:s=!0,onTabChange:l,onTabClick:o,onLeftIconClick:h,onRightIconClick:g,onUnreadCountClick:m})=>{const u=p([]),[d,_]=v((()=>c||r[0]?.id?.toString())),[w,f]=v({left:0,width:0}),b=e=>{_(e)},Z=e=>(e=>{let t=0;for(let c=0;c<e.length;c++)t+=la(e[c])||0;return t})(u.current.slice(0,e));return i((()=>{const e=r.findIndex((e=>e.id===d)),t=r[e];-1!==e&&(l?.(t),document.fonts.ready.then((()=>{var t;f({left:Z(e),width:(t=e,la(u.current[t]))})})))}),[d,r,a]),i((()=>{u.current=u.current.slice(0,r.length)}),[r]),i((()=>{_(c)}),[c]),t(ca,{children:[e(ra,{children:r.map(((c,r)=>t(na,{ref:e=>u.current[r]=e,onClick:e=>((e,t)=>{b(e.id?.toString()),o?.(e,t)})(c,e),isActive:d===c.id,tabHeight:n,fullWidth:a,children:[e("
|
|
3216
|
+
`,la=e=>e?.clientWidth,ia=({activeTab:c,tabs:r=[],tabHeight:n,fullWidth:a,showNeutralBorder:s=!0,onTabChange:l,onTabClick:o,onLeftIconClick:h,onRightIconClick:g,onUnreadCountClick:m})=>{const u=p([]),[d,_]=v((()=>c||r[0]?.id?.toString())),[w,f]=v({left:0,width:0}),b=e=>{_(e)},Z=e=>(e=>{let t=0;for(let c=0;c<e.length;c++)t+=la(e[c])||0;return t})(u.current.slice(0,e));return i((()=>{const e=r.findIndex((e=>e.id===d)),t=r[e];-1!==e&&(l?.(t),document.fonts.ready.then((()=>{var t;f({left:Z(e),width:(t=e,la(u.current[t]))})})))}),[d,r,a]),i((()=>{u.current=u.current.slice(0,r.length)}),[r]),i((()=>{_(c)}),[c]),t(ca,{children:[e(ra,{children:r.map(((c,r)=>t(na,{ref:e=>u.current[r]=e,onClick:e=>((e,t)=>{b(e.id?.toString()),o?.(e,t)})(c,e),isActive:d===c.id,tabHeight:n,fullWidth:a,children:[c.leftIcon&&e("div",{onClick:e=>((e,t)=>{t.stopPropagation(),h?.(e,t)})(c,e),children:c.leftIcon}),c.title,c.unreadCount&&e("span",{onClick:e=>((e,t)=>{t.stopPropagation(),m?.(e,t)})(c,e),children:e(yn,{label:c.unreadCount?.toString(),type:"secondary"})}),c.rightIcon&&e("div",{onClick:e=>((e,t)=>{t.stopPropagation(),g?.(e,t)})(c,e),children:c.rightIcon})]},c.id||c.title)))}),e(aa,{showNeutralBorder:s,children:e(sa,{width:`${w.width}px`,left:`${w.left}px`})})]})},oa=c.div`
|
|
3213
3217
|
.collapsed {
|
|
3214
3218
|
gap: 0px;
|
|
3215
3219
|
height: auto !important;
|