profinansy-ui-lib 3.8.67 → 3.8.68

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.
@@ -7,6 +7,8 @@ export interface IDropdownProps {
7
7
  placement?: Placement;
8
8
  /** Контент*/
9
9
  children: ReactNode;
10
+ /** Время открытия и закрытия дропа */
11
+ openTime?: number;
10
12
  /** Ширина выпадашки*/
11
13
  width?: string;
12
14
  /** Максимальная высота выпадашки*/
@@ -5097,7 +5097,7 @@ Check the top-level render call using <`+q+">.")}return G}}function ql(L,G){{if(
5097
5097
  white-space: break-spaces;
5098
5098
  position: relative;
5099
5099
  ${bt}
5100
- `;function vM({placement:e="bottom-end",onOpenList:t}){const[n,r]=m.useState(!1),o=U1({placement:e,open:n,onOpenChange:r,whileElementsMounted:pr,middleware:[Jr(4),Qr({crossAxis:e.includes("-"),fallbackAxisSideDirection:"end",padding:{top:70,bottom:10,left:10,right:10}}),G1({padding:{top:70,bottom:10,left:10,right:10}})]});m.useEffect(()=>{t&&t(n)},[n]);const i=o.context,a=z1(i),l=X1(i),c=Q1(i),u=J1([l,c,a]);return m.useMemo(()=>({open:n,setOpen:r,...u,...o}),[n,r,u,o])}const ji=m.createContext(null),T1=m.forwardRef(({children:e,width:t,height:n,zIndex:r,padding:o,withoutPortal:i,appendElementId:a,...l},c)=>{const{mode:u}=te(),f=vM({...l});return m.useImperativeHandle(c,()=>({handleClose(){f.setOpen(!1)}})),s.jsx(h.ThemeProvider,{theme:X[u],children:s.jsxs(ji.Provider,{value:f,children:[s.jsx(bM,{targetElement:l.targetElement}),s.jsx(xM,{appendElementId:a,width:t,height:n,zIndex:r,padding:o,withoutPortal:i,children:e})]})})}),bM=({targetElement:e})=>{const t=m.useContext(ji),n=fn([t.refs.setReference]);return e&&m.isValidElement(e)?m.cloneElement(e,t.getReferenceProps({ref:n,...e.props,"data-state":t.open?"open":"closed"})):null},xM=({withoutPortal:e=!1,children:t,appendElementId:n,...r})=>{const{context:o}=m.useContext(ji);return o.open?e?s.jsx(_c,{...r,children:t}):s.jsx(Y1,{id:n,children:s.jsx(_c,{...r,children:t})}):null},_c=({children:e,width:t,height:n,zIndex:r,padding:o})=>{const{context:i,...a}=m.useContext(ji),l=fn([a.refs.setFloating]),{mode:c}=te(),{styles:u}=K1(i,{duration:{open:300,close:300},initial:{opacity:0}});return s.jsx(Ys,{context:i,modal:!1,children:s.jsx(mM,{ref:l,style:{zIndex:r||Rt.zIndex5,...a.floatingStyles},...a.getFloatingProps(),children:s.jsx(h.ThemeProvider,{theme:X[c],children:s.jsx("div",{style:u,children:s.jsx(gM,{width:t,height:n,mode:c,children:s.jsx(CM,{height:n,padding:o,children:e})})})})})})},yM=e=>d.createElement("svg",{width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},d.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.459 4.54291C13.7428 2.83401 10.9719 2.82975 9.26788 4.54102C7.56018 6.25602 7.56153 9.02768 9.26694 10.7331C9.51101 10.9772 9.51101 11.3729 9.26694 11.617C9.02286 11.861 8.62713 11.861 8.38305 11.617C6.18846 9.42237 6.18981 5.8607 8.38211 3.65903C10.5781 1.45364 14.1405 1.46604 16.341 3.65714C18.5464 5.85315 18.534 9.41556 16.3429 11.616C16.0993 11.8606 15.7036 11.8615 15.459 11.6179C15.2144 11.3744 15.2136 10.9786 15.4571 10.734C17.166 9.01783 17.1703 6.24691 15.459 4.54291ZM4.55125 8.67574C4.79479 8.92036 4.7939 9.31608 4.54928 9.55962C2.92147 11.1802 2.92556 13.8178 4.55125 15.4507C6.17183 17.0786 8.80942 17.0745 10.4424 15.4488C12.0714 13.8269 12.0729 11.1901 10.4414 9.55863C10.1973 9.31456 10.1973 8.91883 10.4414 8.67475C10.6855 8.43067 11.0812 8.43067 11.3253 8.67475C13.4438 10.7933 13.4452 14.2231 11.3243 16.3346C9.20724 18.4423 5.77816 18.4548 3.6654 16.3326C1.55776 14.2156 1.54518 10.7865 3.66737 8.67377C3.91199 8.43023 4.30772 8.43112 4.55125 8.67574Z",fill:"#242424"})),wM=({targetElement:e,link:t,linkCallback:n})=>{const r=o=>{o.stopPropagation(),navigator.clipboard.writeText(t),n&&n()};return s.jsxs(T1,{padding:"8px",targetElement:e,children:[s.jsx(V,{variant:"header6-SemiBold",tag:"span",colorName:"primary",marginBottom:"8px",children:"Поделиться"}),s.jsxs(hM,{onClick:r,children:[s.jsx(yM,{}),s.jsx(V,{variant:"description-Regular",tag:"span",colorName:"primary",children:"Скопировать ссылку"})]})]})},no=e=>d.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},d.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.19194 14.8829L6.19779 14.8888C6.48485 15.1758 6.95681 15.1759 7.24387 14.8888L11.5905 10.5421C11.8168 10.3159 12.1849 10.3159 12.4111 10.5421L16.7578 14.8888C17.0449 15.1759 17.5168 15.1759 17.8039 14.8888C18.0909 14.6017 18.0909 14.1298 17.8039 13.8427L13.4572 9.49605C12.6568 8.69565 11.3449 8.69565 10.5445 9.49605L6.19779 13.8427C6.05041 13.9901 5.98083 14.1789 5.98083 14.3658C5.98083 14.5597 6.06178 14.7435 6.19194 14.8829Z",fill:"#6553F5"})),kM=h.keyframes`
5100
+ `;function vM({placement:e="bottom-end",onOpenList:t}){const[n,r]=m.useState(!1),o=U1({placement:e,open:n,onOpenChange:r,whileElementsMounted:pr,middleware:[Jr(4),Qr({crossAxis:e.includes("-"),fallbackAxisSideDirection:"end",padding:{top:70,bottom:10,left:10,right:10}}),G1({padding:{top:70,bottom:10,left:10,right:10}})]});m.useEffect(()=>{t&&t(n)},[n]);const i=o.context,a=z1(i),l=X1(i),c=Q1(i),u=J1([l,c,a]);return m.useMemo(()=>({open:n,setOpen:r,...u,...o}),[n,r,u,o])}const ji=m.createContext(null),T1=m.forwardRef(({children:e,width:t,height:n,zIndex:r,padding:o,withoutPortal:i,appendElementId:a,openTime:l,...c},u)=>{const{mode:f}=te(),p=vM({...c});return m.useImperativeHandle(u,()=>({handleClose(){p.setOpen(!1)}})),s.jsx(h.ThemeProvider,{theme:X[f],children:s.jsxs(ji.Provider,{value:p,children:[s.jsx(bM,{targetElement:c.targetElement}),s.jsx(xM,{appendElementId:a,width:t,height:n,zIndex:r,padding:o,withoutPortal:i,openTime:l,children:e})]})})}),bM=({targetElement:e})=>{const t=m.useContext(ji),n=fn([t.refs.setReference]);return e&&m.isValidElement(e)?m.cloneElement(e,t.getReferenceProps({ref:n,...e.props,"data-state":t.open?"open":"closed"})):null},xM=({withoutPortal:e=!1,children:t,appendElementId:n,...r})=>{const{context:o}=m.useContext(ji);return o.open?e?s.jsx(_c,{...r,children:t}):s.jsx(Y1,{id:n,children:s.jsx(_c,{...r,children:t})}):null},_c=({children:e,width:t,height:n,zIndex:r,padding:o,openTime:i})=>{const{context:a,...l}=m.useContext(ji),c=fn([l.refs.setFloating]),{mode:u}=te(),f=typeof i=="number"?i:300,{styles:p}=K1(a,{duration:{open:f,close:f},initial:{opacity:0}});return s.jsx(Ys,{context:a,modal:!1,children:s.jsx(mM,{ref:c,style:{zIndex:r||Rt.zIndex5,...l.floatingStyles},...l.getFloatingProps(),children:s.jsx(h.ThemeProvider,{theme:X[u],children:s.jsx("div",{style:p,children:s.jsx(gM,{width:t,height:n,mode:u,children:s.jsx(CM,{height:n,padding:o,children:e})})})})})})},yM=e=>d.createElement("svg",{width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},d.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.459 4.54291C13.7428 2.83401 10.9719 2.82975 9.26788 4.54102C7.56018 6.25602 7.56153 9.02768 9.26694 10.7331C9.51101 10.9772 9.51101 11.3729 9.26694 11.617C9.02286 11.861 8.62713 11.861 8.38305 11.617C6.18846 9.42237 6.18981 5.8607 8.38211 3.65903C10.5781 1.45364 14.1405 1.46604 16.341 3.65714C18.5464 5.85315 18.534 9.41556 16.3429 11.616C16.0993 11.8606 15.7036 11.8615 15.459 11.6179C15.2144 11.3744 15.2136 10.9786 15.4571 10.734C17.166 9.01783 17.1703 6.24691 15.459 4.54291ZM4.55125 8.67574C4.79479 8.92036 4.7939 9.31608 4.54928 9.55962C2.92147 11.1802 2.92556 13.8178 4.55125 15.4507C6.17183 17.0786 8.80942 17.0745 10.4424 15.4488C12.0714 13.8269 12.0729 11.1901 10.4414 9.55863C10.1973 9.31456 10.1973 8.91883 10.4414 8.67475C10.6855 8.43067 11.0812 8.43067 11.3253 8.67475C13.4438 10.7933 13.4452 14.2231 11.3243 16.3346C9.20724 18.4423 5.77816 18.4548 3.6654 16.3326C1.55776 14.2156 1.54518 10.7865 3.66737 8.67377C3.91199 8.43023 4.30772 8.43112 4.55125 8.67574Z",fill:"#242424"})),wM=({targetElement:e,link:t,linkCallback:n})=>{const r=o=>{o.stopPropagation(),navigator.clipboard.writeText(t),n&&n()};return s.jsxs(T1,{padding:"8px",targetElement:e,children:[s.jsx(V,{variant:"header6-SemiBold",tag:"span",colorName:"primary",marginBottom:"8px",children:"Поделиться"}),s.jsxs(hM,{onClick:r,children:[s.jsx(yM,{}),s.jsx(V,{variant:"description-Regular",tag:"span",colorName:"primary",children:"Скопировать ссылку"})]})]})},no=e=>d.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},d.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.19194 14.8829L6.19779 14.8888C6.48485 15.1758 6.95681 15.1759 7.24387 14.8888L11.5905 10.5421C11.8168 10.3159 12.1849 10.3159 12.4111 10.5421L16.7578 14.8888C17.0449 15.1759 17.5168 15.1759 17.8039 14.8888C18.0909 14.6017 18.0909 14.1298 17.8039 13.8427L13.4572 9.49605C12.6568 8.69565 11.3449 8.69565 10.5445 9.49605L6.19779 13.8427C6.05041 13.9901 5.98083 14.1789 5.98083 14.3658C5.98083 14.5597 6.06178 14.7435 6.19194 14.8829Z",fill:"#6553F5"})),kM=h.keyframes`
5101
5101
  from {
5102
5102
  transform: scale(0);
5103
5103
  opacity: 0;