ysyt-react-agent-lib 1.0.4 → 1.0.5
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/ConsultModel-D6HzOo3Z.mjs +50 -0
- package/dist/{ConsultModel-DSUS4oAZ.js → ConsultModel-D7Pe95Lx.js} +1 -1
- package/dist/{TransferModel-DA1McTfO.mjs → TransferModel-CyiVAM2a.mjs} +12 -12
- package/dist/{TransferModel-B0wM8RRP.js → TransferModel-D9LWoOdD.js} +2 -2
- package/dist/components/{IconSvg → YsytIconSvg}/index.d.ts +1 -1
- package/dist/{index-rGtROgVw.mjs → index-C85xzHuN.mjs} +1 -1
- package/dist/{index-DQqM3Rj7.mjs → index-CSZ70qrC.mjs} +636 -636
- package/dist/{index-DX9HJNYe.js → index-CVQq3wZ4.js} +1 -1
- package/dist/{index-CA2K8i3v.js → index-Pw6U12iw.js} +1 -1
- package/dist/ysyt-react-agent-lib.cjs.js +1 -1
- package/dist/ysyt-react-agent-lib.es.js +1 -1
- package/package.json +1 -1
- package/dist/ConsultModel-DljDMfEI.mjs +0 -50
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { M as c, T as l } from "./index-C85xzHuN.mjs";
|
|
2
|
+
import { j as s, M as i, S as d, Y as g } from "./index-CSZ70qrC.mjs";
|
|
3
|
+
import { memo as m, useState as x, useEffect as j } from "react";
|
|
4
|
+
const h = m(({
|
|
5
|
+
open: a,
|
|
6
|
+
onCallBack: t,
|
|
7
|
+
queryFetch: n
|
|
8
|
+
}) => {
|
|
9
|
+
const [o, r] = x([]);
|
|
10
|
+
return j(() => {
|
|
11
|
+
(async () => {
|
|
12
|
+
try {
|
|
13
|
+
await n({
|
|
14
|
+
success: (e) => {
|
|
15
|
+
r(e.data || []);
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
} catch (e) {
|
|
19
|
+
console.log(e);
|
|
20
|
+
}
|
|
21
|
+
})();
|
|
22
|
+
}, [a]), /* @__PURE__ */ s.jsx(s.Fragment, {
|
|
23
|
+
children: /* @__PURE__ */ s.jsx(c, {
|
|
24
|
+
open: a,
|
|
25
|
+
title: "咨询",
|
|
26
|
+
footer: !1,
|
|
27
|
+
onCancel: () => t(),
|
|
28
|
+
children: /* @__PURE__ */ s.jsx(i, {
|
|
29
|
+
children: /* @__PURE__ */ s.jsx(d, {
|
|
30
|
+
wrap: !0,
|
|
31
|
+
children: o.map((e) => /* @__PURE__ */ s.jsxs(l, {
|
|
32
|
+
color: "processing",
|
|
33
|
+
onClick: () => t(e.agent_no),
|
|
34
|
+
children: [/* @__PURE__ */ s.jsxs("span", {
|
|
35
|
+
style: {
|
|
36
|
+
marginRight: 10
|
|
37
|
+
},
|
|
38
|
+
children: ["咨询坐席: ", e.agent_name]
|
|
39
|
+
}), /* @__PURE__ */ s.jsx(g, {
|
|
40
|
+
name: "zixun"
|
|
41
|
+
})]
|
|
42
|
+
}, e.agent_no))
|
|
43
|
+
})
|
|
44
|
+
})
|
|
45
|
+
})
|
|
46
|
+
});
|
|
47
|
+
});
|
|
48
|
+
export {
|
|
49
|
+
h as default
|
|
50
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-CVQq3wZ4.js"),e=require("./index-Pw6U12iw.js"),s=require("react"),x=s.memo(({open:n,onCallBack:r,queryFetch:a})=>{const[i,c]=s.useState([]);return s.useEffect(()=>{(async()=>{try{await a({success:t=>{c(t.data||[])}})}catch(t){console.log(t)}})()},[n]),e.jsxRuntimeExports.jsx(e.jsxRuntimeExports.Fragment,{children:e.jsxRuntimeExports.jsx(o.Modal,{open:n,title:"咨询",footer:!1,onCancel:()=>r(),children:e.jsxRuntimeExports.jsx(e.ModelBody,{children:e.jsxRuntimeExports.jsx(e.Space,{wrap:!0,children:i.map(t=>e.jsxRuntimeExports.jsxs(o.Tag,{color:"processing",onClick:()=>r(t.agent_no),children:[e.jsxRuntimeExports.jsxs("span",{style:{marginRight:10},children:["咨询坐席: ",t.agent_name]}),e.jsxRuntimeExports.jsx(e.YsytIconSvg,{name:"zixun"})]},t.agent_no))})})})})});exports.default=x;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { g as ie, m as le, u as D, r as W, a as
|
|
2
|
-
import { M as Re, T as we } from "./index-
|
|
1
|
+
import { g as ie, m as le, u as D, r as W, a as K, _ as se, b as Q, c as de, d as q, e as X, f as ce, h as Y, w as U, C as A, i as ue, F as be, k as pe, l as Z, D as ge, W as fe, T as he, n as Ce, o as ve, p as me, j as w, M as Se, q as ye, S as ke, Y as xe, I as $e } from "./index-CSZ70qrC.mjs";
|
|
2
|
+
import { M as Re, T as we } from "./index-C85xzHuN.mjs";
|
|
3
3
|
import * as a from "react";
|
|
4
|
-
import Ee, { forwardRef as Ie, useRef as
|
|
4
|
+
import Ee, { forwardRef as Ie, useRef as J, useImperativeHandle as Pe, memo as Be, useState as V, useEffect as Oe } from "react";
|
|
5
5
|
const je = (e) => {
|
|
6
6
|
const {
|
|
7
7
|
componentCls: r,
|
|
@@ -102,7 +102,7 @@ const je = (e) => {
|
|
|
102
102
|
&:hover ${S}`]: {
|
|
103
103
|
borderColor: o
|
|
104
104
|
},
|
|
105
|
-
[`${r}-input:focus-visible + ${S}`]: Object.assign({},
|
|
105
|
+
[`${r}-input:focus-visible + ${S}`]: Object.assign({}, K(e)),
|
|
106
106
|
[`${r}:hover::after, ${r}-wrapper:hover &::after`]: {
|
|
107
107
|
visibility: "visible"
|
|
108
108
|
},
|
|
@@ -318,7 +318,7 @@ const je = (e) => {
|
|
|
318
318
|
position: "relative",
|
|
319
319
|
color: u
|
|
320
320
|
},
|
|
321
|
-
"&:has(:focus-visible)": Object.assign({},
|
|
321
|
+
"&:has(:focus-visible)": Object.assign({}, K(e)),
|
|
322
322
|
[`${o}-inner, input[type='checkbox'], input[type='radio']`]: {
|
|
323
323
|
width: 0,
|
|
324
324
|
height: 0,
|
|
@@ -443,7 +443,7 @@ const je = (e) => {
|
|
|
443
443
|
}
|
|
444
444
|
}), oe = /* @__PURE__ */ a.createContext(null), Te = oe.Provider, te = /* @__PURE__ */ a.createContext(null), Ne = te.Provider;
|
|
445
445
|
var Me = ["prefixCls", "className", "style", "checked", "disabled", "defaultChecked", "type", "title", "onChange"], Le = /* @__PURE__ */ Ie(function(e, r) {
|
|
446
|
-
var n = e.prefixCls, o = n === void 0 ? "rc-checkbox" : n, t = e.className, i = e.style, f = e.checked, p = e.disabled, s = e.defaultChecked, x = s === void 0 ? !1 : s, g = e.type, l = g === void 0 ? "checkbox" : g, I = e.title, k = e.onChange, E = se(e, Me), m =
|
|
446
|
+
var n = e.prefixCls, o = n === void 0 ? "rc-checkbox" : n, t = e.className, i = e.style, f = e.checked, p = e.disabled, s = e.defaultChecked, x = s === void 0 ? !1 : s, g = e.type, l = g === void 0 ? "checkbox" : g, I = e.title, k = e.onChange, E = se(e, Me), m = J(null), c = J(null), $ = Q(x, {
|
|
447
447
|
value: f
|
|
448
448
|
}), h = de($, 2), S = h[0], y = h[1];
|
|
449
449
|
Pe(r, function() {
|
|
@@ -462,7 +462,7 @@ var Me = ["prefixCls", "className", "style", "checked", "disabled", "defaultChec
|
|
|
462
462
|
});
|
|
463
463
|
var P = q(o, t, X(X({}, "".concat(o, "-checked"), S), "".concat(o, "-disabled"), p)), d = function(v) {
|
|
464
464
|
p || ("checked" in e || y(v.target.checked), k == null || k({
|
|
465
|
-
target:
|
|
465
|
+
target: Y(Y({}, e), {}, {
|
|
466
466
|
type: l,
|
|
467
467
|
checked: v.target.checked
|
|
468
468
|
}),
|
|
@@ -493,10 +493,10 @@ var Me = ["prefixCls", "className", "style", "checked", "disabled", "defaultChec
|
|
|
493
493
|
});
|
|
494
494
|
function Ve(e) {
|
|
495
495
|
const r = Ee.useRef(null), n = () => {
|
|
496
|
-
|
|
496
|
+
U.cancel(r.current), r.current = null;
|
|
497
497
|
};
|
|
498
498
|
return [() => {
|
|
499
|
-
n(), r.current =
|
|
499
|
+
n(), r.current = U(() => {
|
|
500
500
|
r.current = null;
|
|
501
501
|
});
|
|
502
502
|
}, (i) => {
|
|
@@ -590,7 +590,7 @@ const We = /* @__PURE__ */ a.forwardRef((e, r) => {
|
|
|
590
590
|
onMouseLeave: d,
|
|
591
591
|
onFocus: j,
|
|
592
592
|
onBlur: v
|
|
593
|
-
} = e, [u, _] =
|
|
593
|
+
} = e, [u, _] = Q($, {
|
|
594
594
|
value: h
|
|
595
595
|
}), b = a.useCallback((C) => {
|
|
596
596
|
const ae = u, F = C.target.value;
|
|
@@ -667,7 +667,7 @@ const Fe = (e, r) => {
|
|
|
667
667
|
G.Button = Xe;
|
|
668
668
|
G.Group = Ae;
|
|
669
669
|
G.__ANT_RADIO = !0;
|
|
670
|
-
const
|
|
670
|
+
const Ke = Be(({
|
|
671
671
|
open: e,
|
|
672
672
|
onCallBack: r,
|
|
673
673
|
queryFetch: n
|
|
@@ -743,5 +743,5 @@ const Qe = Be(({
|
|
|
743
743
|
});
|
|
744
744
|
});
|
|
745
745
|
export {
|
|
746
|
-
|
|
746
|
+
Ke as default
|
|
747
747
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-
|
|
2
|
-
&:hover ${S}`]:{borderColor:t},[`${n}-input:focus-visible + ${S}`]:Object.assign({},r.genFocusOutline(e)),[`${n}:hover::after, ${n}-wrapper:hover &::after`]:{visibility:"visible"},[`${n}-inner`]:{"&::after":{boxSizing:"border-box",position:"absolute",insetBlockStart:"50%",insetInlineStart:"50%",display:"block",width:c,height:c,marginBlockStart:h(1).mul(o).div(-2).equal({unit:!0}),marginInlineStart:h(1).mul(o).div(-2).equal({unit:!0}),backgroundColor:u,borderBlockStart:0,borderInlineStart:0,borderRadius:c,transform:"scale(0)",opacity:0,transition:`all ${l} ${g}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:c,height:c,backgroundColor:d,borderColor:$,borderStyle:"solid",borderWidth:f,borderRadius:"50%",transition:`all ${C}`},[`${n}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0},[`${n}-checked`]:{[S]:{borderColor:t,backgroundColor:R,"&::after":{transform:`scale(${e.calc(e.dotSize).div(o).equal()})`,opacity:1,transition:`all ${l} ${g}`}}},[`${n}-disabled`]:{cursor:"not-allowed",[S]:{backgroundColor:s,borderColor:$,cursor:"not-allowed","&::after":{backgroundColor:w}},[`${n}-input`]:{cursor:"not-allowed"},[`${n}-disabled + span`]:{color:O,cursor:"not-allowed"},[`&${n}-checked`]:{[S]:{"&::after":{transform:`scale(${h(P).div(o).equal()})`}}}},[`span${n} + *`]:{paddingInlineStart:k,paddingInlineEnd:k}})}},Z=e=>{const{buttonColor:n,controlHeight:i,componentCls:t,lineWidth:o,lineType:l,colorBorder:C,motionDurationSlow:g,motionDurationMid:d,buttonPaddingInline:$,fontSize:f,buttonBg:s,fontSizeLG:O,controlHeightLG:k,controlHeightSM:w,paddingXS:x,borderRadius:u,borderRadiusSM:R,borderRadiusLG:h,buttonCheckedBg:S,buttonSolidCheckedColor:y,colorTextDisabled:P,colorBgContainerDisabled:c,buttonCheckedBgDisabled:_,buttonCheckedColorDisabled:v,colorPrimary:b,colorPrimaryHover:z,colorPrimaryActive:p,buttonSolidCheckedBg:I,buttonSolidCheckedHoverBg:B,buttonSolidCheckedActiveBg:N,calc:E}=e;return{[`${t}-button-wrapper`]:{position:"relative",display:"inline-block",height:i,margin:0,paddingInline:$,paddingBlock:0,color:n,fontSize:f,lineHeight:r.unit(E(i).sub(E(o).mul(2)).equal()),background:s,border:`${r.unit(o)} ${l} ${C}`,borderBlockStartWidth:E(o).add(.02).equal(),borderInlineStartWidth:0,borderInlineEndWidth:o,cursor:"pointer",transition:[`color ${d}`,`background ${d}`,`box-shadow ${d}`].join(","),a:{color:n},[`> ${t}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:first-child)":{"&::before":{position:"absolute",insetBlockStart:E(o).mul(-1).equal(),insetInlineStart:E(o).mul(-1).equal(),display:"block",boxSizing:"content-box",width:1,height:"100%",paddingBlock:o,paddingInline:0,backgroundColor:C,transition:`background-color ${g}`,content:'""'}},"&:first-child":{borderInlineStart:`${r.unit(o)} ${l} ${C}`,borderStartStartRadius:u,borderEndStartRadius:u},"&:last-child":{borderStartEndRadius:u,borderEndEndRadius:u},"&:first-child:last-child":{borderRadius:u},[`${t}-group-large &`]:{height:k,fontSize:O,lineHeight:r.unit(E(k).sub(E(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:h,borderEndStartRadius:h},"&:last-child":{borderStartEndRadius:h,borderEndEndRadius:h}},[`${t}-group-small &`]:{height:w,paddingInline:E(x).sub(o).equal(),paddingBlock:0,lineHeight:r.unit(E(w).sub(E(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:R,borderEndStartRadius:R},"&:last-child":{borderStartEndRadius:R,borderEndEndRadius:R}},"&:hover":{position:"relative",color:b},"&:has(:focus-visible)":Object.assign({},r.genFocusOutline(e)),[`${t}-inner, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${t}-button-wrapper-disabled)`]:{zIndex:1,color:b,background:S,borderColor:b,"&::before":{backgroundColor:b},"&:first-child":{borderColor:b},"&:hover":{color:z,borderColor:z,"&::before":{backgroundColor:z}},"&:active":{color:p,borderColor:p,"&::before":{backgroundColor:p}}},[`${t}-group-solid &-checked:not(${t}-button-wrapper-disabled)`]:{color:y,background:I,borderColor:I,"&:hover":{color:y,background:B,borderColor:B},"&:active":{color:y,background:N,borderColor:N}},"&-disabled":{color:P,backgroundColor:c,borderColor:C,cursor:"not-allowed","&:first-child, &:hover":{color:P,backgroundColor:c,borderColor:C}},[`&-disabled${t}-button-wrapper-checked`]:{color:v,backgroundColor:_,borderColor:C,boxShadow:"none"},"&-block":{flex:1,textAlign:"center"}}}},ee=e=>{const{wireframe:n,padding:i,marginXS:t,lineWidth:o,fontSizeLG:l,colorText:C,colorBgContainer:g,colorTextDisabled:d,controlItemBgActiveDisabled:$,colorTextLightSolid:f,colorPrimary:s,colorPrimaryHover:O,colorPrimaryActive:k,colorWhite:w}=e,x=4,u=l,R=n?u-x*2:u-(x+o)*2;return{radioSize:u,dotSize:R,dotColorDisabled:d,buttonSolidCheckedColor:f,buttonSolidCheckedBg:s,buttonSolidCheckedHoverBg:O,buttonSolidCheckedActiveBg:k,buttonBg:g,buttonCheckedBg:g,buttonColor:C,buttonCheckedBgDisabled:$,buttonCheckedColorDisabled:d,buttonPaddingInline:i-o,wrapperMarginInlineEnd:t,radioColor:n?s:w,radioBgColor:n?g:s}},H=r.genStyleHooks("Radio",e=>{const{controlOutline:n,controlOutlineWidth:i}=e,t=`0 0 0 ${r.unit(i)} ${n}`,o=t,l=r.merge(e,{radioFocusShadow:t,radioButtonFocusShadow:o});return[Q(l),Y(l),Z(l)]},ee,{unitless:{radioSize:!0,dotSize:!0}}),W=a.createContext(null),te=W.Provider,F=a.createContext(null),oe=F.Provider;var re=["prefixCls","className","style","checked","disabled","defaultChecked","type","title","onChange"],ne=j.forwardRef(function(e,n){var i=e.prefixCls,t=i===void 0?"rc-checkbox":i,o=e.className,l=e.style,C=e.checked,g=e.disabled,d=e.defaultChecked,$=d===void 0?!1:d,f=e.type,s=f===void 0?"checkbox":f,O=e.title,k=e.onChange,w=r._objectWithoutProperties(e,re),x=j.useRef(null),u=j.useRef(null),R=r.useMergedState($,{value:C}),h=r._slicedToArray(R,2),S=h[0],y=h[1];j.useImperativeHandle(n,function(){return{focus:function(v){var b;(b=x.current)===null||b===void 0||b.focus(v)},blur:function(){var v;(v=x.current)===null||v===void 0||v.blur()},input:x.current,nativeElement:u.current}});var P=r.classNames(t,o,r._defineProperty(r._defineProperty({},"".concat(t,"-checked"),S),"".concat(t,"-disabled"),g)),c=function(v){g||("checked"in e||y(v.target.checked),k==null||k({target:r._objectSpread2(r._objectSpread2({},e),{},{type:s,checked:v.target.checked}),stopPropagation:function(){v.stopPropagation()},preventDefault:function(){v.preventDefault()},nativeEvent:v.nativeEvent}))};return a.createElement("span",{className:P,title:O,style:l,ref:u},a.createElement("input",r._extends({},w,{className:"".concat(t,"-input"),ref:x,onChange:c,disabled:g,checked:!!S,type:s})),a.createElement("span",{className:"".concat(t,"-inner")}))});function ie(e){const n=j.useRef(null),i=()=>{r.wrapperRaf.cancel(n.current),n.current=null};return[()=>{i(),n.current=r.wrapperRaf(()=>{n.current=null})},l=>{n.current&&(l.stopPropagation(),i()),e==null||e(l)}]}var ae=function(e,n){var i={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(i[t]=e[t]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,t=Object.getOwnPropertySymbols(e);o<t.length;o++)n.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(i[t[o]]=e[t[o]]);return i};const le=(e,n)=>{var i,t;const o=a.useContext(W),l=a.useContext(F),{getPrefixCls:C,direction:g,radio:d}=a.useContext(r.ConfigContext),$=a.useRef(null),f=r.composeRef(n,$),{isFormItemInput:s}=a.useContext(r.FormItemInputContext);if(process.env.NODE_ENV!=="production"){const D=r.devUseWarning("Radio");process.env.NODE_ENV!=="production"&&D(!("optionType"in e),"usage","`optionType` is only support in Radio.Group.")}const O=D=>{var M,T;(M=e.onChange)===null||M===void 0||M.call(e,D),(T=o==null?void 0:o.onChange)===null||T===void 0||T.call(o,D)},{prefixCls:k,className:w,rootClassName:x,children:u,style:R,title:h}=e,S=ae(e,["prefixCls","className","rootClassName","children","style","title"]),y=C("radio",k),P=((o==null?void 0:o.optionType)||l)==="button",c=P?`${y}-button`:y,_=r.useCSSVarCls(y),[v,b,z]=H(y,_),p=Object.assign({},S),I=a.useContext(r.DisabledContext);o&&(p.name=o.name,p.onChange=O,p.checked=e.value===o.value,p.disabled=(i=p.disabled)!==null&&i!==void 0?i:o.disabled),p.disabled=(t=p.disabled)!==null&&t!==void 0?t:I;const B=r.classNames(`${c}-wrapper`,{[`${c}-wrapper-checked`]:p.checked,[`${c}-wrapper-disabled`]:p.disabled,[`${c}-wrapper-rtl`]:g==="rtl",[`${c}-wrapper-in-form-item`]:s,[`${c}-wrapper-block`]:!!(o!=null&&o.block)},d==null?void 0:d.className,w,x,b,z,_),[N,E]=ie(p.onClick);return v(a.createElement(r.Wave,{component:"Radio",disabled:p.disabled},a.createElement("label",{className:B,style:Object.assign(Object.assign({},d==null?void 0:d.style),R),onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,title:h,onClick:N},a.createElement(ne,Object.assign({},p,{className:r.classNames(p.className,{[r.TARGET_CLS]:!P}),type:"radio",prefixCls:c,ref:f,onClick:E})),u!==void 0?a.createElement("span",{className:`${c}-label`},u):null)))},V=a.forwardRef(le);process.env.NODE_ENV!=="production"&&(V.displayName="Radio");const se=a.forwardRef((e,n)=>{const{getPrefixCls:i,direction:t}=a.useContext(r.ConfigContext),o=r.useId(),{prefixCls:l,className:C,rootClassName:g,options:d,buttonStyle:$="outline",disabled:f,children:s,size:O,style:k,id:w,optionType:x,name:u=o,defaultValue:R,value:h,block:S=!1,onChange:y,onMouseEnter:P,onMouseLeave:c,onFocus:_,onBlur:v}=e,[b,z]=r.useMergedState(R,{value:h}),p=a.useCallback(m=>{const J=b,G=m.target.value;"value"in e||z(G),G!==J&&(y==null||y(m))},[b,z,y]),I=i("radio",l),B=`${I}-group`,N=r.useCSSVarCls(I),[E,D,M]=H(I,N);let T=s;d&&d.length>0&&(T=d.map(m=>typeof m=="string"||typeof m=="number"?a.createElement(V,{key:m.toString(),prefixCls:I,disabled:f,value:m,checked:b===m},m):a.createElement(V,{key:`radio-group-value-options-${m.value}`,prefixCls:I,disabled:m.disabled||f,value:m.value,checked:b===m.value,title:m.title,style:m.style,id:m.id,required:m.required},m.label)));const L=r.useSize(O),X=r.classNames(B,`${B}-${$}`,{[`${B}-${L}`]:L,[`${B}-rtl`]:t==="rtl",[`${B}-block`]:S},C,g,D,M,N),U=a.useMemo(()=>({onChange:p,value:b,disabled:f,name:u,optionType:x,block:S}),[p,b,f,u,x,S]);return E(a.createElement("div",Object.assign({},r.pickAttrs(e,{aria:!0,data:!0}),{className:X,style:k,onMouseEnter:P,onMouseLeave:c,onFocus:_,onBlur:v,id:w,ref:n}),a.createElement(te,{value:U},T)))}),de=a.memo(se);var ce=function(e,n){var i={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(i[t]=e[t]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,t=Object.getOwnPropertySymbols(e);o<t.length;o++)n.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(i[t[o]]=e[t[o]]);return i};const ue=(e,n)=>{const{getPrefixCls:i}=a.useContext(r.ConfigContext),{prefixCls:t}=e,o=ce(e,["prefixCls"]),l=i("radio",t);return a.createElement(oe,{value:"button"},a.createElement(V,Object.assign({prefixCls:l},o,{type:"radio",ref:n})))},be=a.forwardRef(ue),q=V;q.Button=be;q.Group=de;q.__ANT_RADIO=!0;const pe=j.memo(({open:e,onCallBack:n,queryFetch:i})=>{const[t,o]=j.useState([]),[l,C]=j.useState(0),[g,d]=j.useState(""),[$,f]=j.useState(!1);return j.useEffect(()=>{(async()=>{f(!0);try{await i({success:s=>{o(s.data||[])}})}catch(s){console.log(s)}f(!1)})()},[e]),r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:r.jsxRuntimeExports.jsx(A.Modal,{open:e,title:"转接",footer:!1,onCancel:()=>n(),children:r.jsxRuntimeExports.jsxs(r.ModelBody,{children:[r.jsxRuntimeExports.jsx("div",{children:r.jsxRuntimeExports.jsx(q.Group,{options:[{label:"转接坐席",value:0},{label:"转接技能组",value:1}],value:l,onChange:s=>C(s.target.value)})}),r.jsxRuntimeExports.jsx(r.Spin,{spinning:$,children:r.jsxRuntimeExports.jsxs("div",{style:{borderTop:"1px solid #eee",marginTop:10,paddingTop:10},children:[l===0&&r.jsxRuntimeExports.jsx(r.Space,{wrap:!0,children:t.map(s=>r.jsxRuntimeExports.jsxs(A.Tag,{color:"processing",onClick:()=>n(s.agent_no),children:[r.jsxRuntimeExports.jsxs("span",{style:{marginRight:10},children:["咨询坐席: ",s.agent_name]}),r.jsxRuntimeExports.jsx(r.IconSvg,{name:"zixun"})]},s.agent_no))}),l===1&&r.jsxRuntimeExports.jsx(r.Input,{value:g,onChange:s=>d(s.target.value),placeholder:"请输入外线号码, 回车转接",onPressEnter:()=>{n(g)}})]})})]})})})});exports.default=pe;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-Pw6U12iw.js"),A=require("./index-CVQq3wZ4.js"),j=require("react");function J(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const i in e)if(i!=="default"){const t=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(n,i,t.get?t:{enumerable:!0,get:()=>e[i]})}}return n.default=e,Object.freeze(n)}const a=J(j),K=e=>{const{componentCls:n,antCls:i}=e,t=`${n}-group`;return{[t]:Object.assign(Object.assign({},r.resetComponent(e)),{display:"inline-block",fontSize:0,[`&${t}-rtl`]:{direction:"rtl"},[`&${t}-block`]:{display:"flex"},[`${i}-badge ${i}-badge-count`]:{zIndex:1},[`> ${i}-badge:not(:first-child) > ${i}-button-wrapper`]:{borderInlineStart:"none"}})}},Q=e=>{const{componentCls:n,wrapperMarginInlineEnd:i,colorPrimary:t,radioSize:o,motionDurationSlow:l,motionDurationMid:C,motionEaseInOutCirc:g,colorBgContainer:d,colorBorder:$,lineWidth:f,colorBgContainerDisabled:s,colorTextDisabled:O,paddingXS:k,dotColorDisabled:w,lineType:x,radioColor:u,radioBgColor:R,calc:h}=e,S=`${n}-inner`,P=h(o).sub(h(4).mul(2)),c=h(1).mul(o).equal({unit:!0});return{[`${n}-wrapper`]:Object.assign(Object.assign({},r.resetComponent(e)),{display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:i,cursor:"pointer","&:last-child":{marginInlineEnd:0},[`&${n}-wrapper-rtl`]:{direction:"rtl"},"&-disabled":{cursor:"not-allowed",color:e.colorTextDisabled},"&::after":{display:"inline-block",width:0,overflow:"hidden",content:'"\\a0"'},"&-block":{flex:1,justifyContent:"center"},[`${n}-checked::after`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:"100%",height:"100%",border:`${r.unit(f)} ${x} ${t}`,borderRadius:"50%",visibility:"hidden",opacity:0,content:'""'},[n]:Object.assign(Object.assign({},r.resetComponent(e)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center",borderRadius:"50%"}),[`${n}-wrapper:hover &,
|
|
2
|
+
&:hover ${S}`]:{borderColor:t},[`${n}-input:focus-visible + ${S}`]:Object.assign({},r.genFocusOutline(e)),[`${n}:hover::after, ${n}-wrapper:hover &::after`]:{visibility:"visible"},[`${n}-inner`]:{"&::after":{boxSizing:"border-box",position:"absolute",insetBlockStart:"50%",insetInlineStart:"50%",display:"block",width:c,height:c,marginBlockStart:h(1).mul(o).div(-2).equal({unit:!0}),marginInlineStart:h(1).mul(o).div(-2).equal({unit:!0}),backgroundColor:u,borderBlockStart:0,borderInlineStart:0,borderRadius:c,transform:"scale(0)",opacity:0,transition:`all ${l} ${g}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:c,height:c,backgroundColor:d,borderColor:$,borderStyle:"solid",borderWidth:f,borderRadius:"50%",transition:`all ${C}`},[`${n}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0},[`${n}-checked`]:{[S]:{borderColor:t,backgroundColor:R,"&::after":{transform:`scale(${e.calc(e.dotSize).div(o).equal()})`,opacity:1,transition:`all ${l} ${g}`}}},[`${n}-disabled`]:{cursor:"not-allowed",[S]:{backgroundColor:s,borderColor:$,cursor:"not-allowed","&::after":{backgroundColor:w}},[`${n}-input`]:{cursor:"not-allowed"},[`${n}-disabled + span`]:{color:O,cursor:"not-allowed"},[`&${n}-checked`]:{[S]:{"&::after":{transform:`scale(${h(P).div(o).equal()})`}}}},[`span${n} + *`]:{paddingInlineStart:k,paddingInlineEnd:k}})}},Z=e=>{const{buttonColor:n,controlHeight:i,componentCls:t,lineWidth:o,lineType:l,colorBorder:C,motionDurationSlow:g,motionDurationMid:d,buttonPaddingInline:$,fontSize:f,buttonBg:s,fontSizeLG:O,controlHeightLG:k,controlHeightSM:w,paddingXS:x,borderRadius:u,borderRadiusSM:R,borderRadiusLG:h,buttonCheckedBg:S,buttonSolidCheckedColor:y,colorTextDisabled:P,colorBgContainerDisabled:c,buttonCheckedBgDisabled:_,buttonCheckedColorDisabled:v,colorPrimary:b,colorPrimaryHover:z,colorPrimaryActive:p,buttonSolidCheckedBg:I,buttonSolidCheckedHoverBg:B,buttonSolidCheckedActiveBg:N,calc:E}=e;return{[`${t}-button-wrapper`]:{position:"relative",display:"inline-block",height:i,margin:0,paddingInline:$,paddingBlock:0,color:n,fontSize:f,lineHeight:r.unit(E(i).sub(E(o).mul(2)).equal()),background:s,border:`${r.unit(o)} ${l} ${C}`,borderBlockStartWidth:E(o).add(.02).equal(),borderInlineStartWidth:0,borderInlineEndWidth:o,cursor:"pointer",transition:[`color ${d}`,`background ${d}`,`box-shadow ${d}`].join(","),a:{color:n},[`> ${t}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:first-child)":{"&::before":{position:"absolute",insetBlockStart:E(o).mul(-1).equal(),insetInlineStart:E(o).mul(-1).equal(),display:"block",boxSizing:"content-box",width:1,height:"100%",paddingBlock:o,paddingInline:0,backgroundColor:C,transition:`background-color ${g}`,content:'""'}},"&:first-child":{borderInlineStart:`${r.unit(o)} ${l} ${C}`,borderStartStartRadius:u,borderEndStartRadius:u},"&:last-child":{borderStartEndRadius:u,borderEndEndRadius:u},"&:first-child:last-child":{borderRadius:u},[`${t}-group-large &`]:{height:k,fontSize:O,lineHeight:r.unit(E(k).sub(E(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:h,borderEndStartRadius:h},"&:last-child":{borderStartEndRadius:h,borderEndEndRadius:h}},[`${t}-group-small &`]:{height:w,paddingInline:E(x).sub(o).equal(),paddingBlock:0,lineHeight:r.unit(E(w).sub(E(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:R,borderEndStartRadius:R},"&:last-child":{borderStartEndRadius:R,borderEndEndRadius:R}},"&:hover":{position:"relative",color:b},"&:has(:focus-visible)":Object.assign({},r.genFocusOutline(e)),[`${t}-inner, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${t}-button-wrapper-disabled)`]:{zIndex:1,color:b,background:S,borderColor:b,"&::before":{backgroundColor:b},"&:first-child":{borderColor:b},"&:hover":{color:z,borderColor:z,"&::before":{backgroundColor:z}},"&:active":{color:p,borderColor:p,"&::before":{backgroundColor:p}}},[`${t}-group-solid &-checked:not(${t}-button-wrapper-disabled)`]:{color:y,background:I,borderColor:I,"&:hover":{color:y,background:B,borderColor:B},"&:active":{color:y,background:N,borderColor:N}},"&-disabled":{color:P,backgroundColor:c,borderColor:C,cursor:"not-allowed","&:first-child, &:hover":{color:P,backgroundColor:c,borderColor:C}},[`&-disabled${t}-button-wrapper-checked`]:{color:v,backgroundColor:_,borderColor:C,boxShadow:"none"},"&-block":{flex:1,textAlign:"center"}}}},ee=e=>{const{wireframe:n,padding:i,marginXS:t,lineWidth:o,fontSizeLG:l,colorText:C,colorBgContainer:g,colorTextDisabled:d,controlItemBgActiveDisabled:$,colorTextLightSolid:f,colorPrimary:s,colorPrimaryHover:O,colorPrimaryActive:k,colorWhite:w}=e,x=4,u=l,R=n?u-x*2:u-(x+o)*2;return{radioSize:u,dotSize:R,dotColorDisabled:d,buttonSolidCheckedColor:f,buttonSolidCheckedBg:s,buttonSolidCheckedHoverBg:O,buttonSolidCheckedActiveBg:k,buttonBg:g,buttonCheckedBg:g,buttonColor:C,buttonCheckedBgDisabled:$,buttonCheckedColorDisabled:d,buttonPaddingInline:i-o,wrapperMarginInlineEnd:t,radioColor:n?s:w,radioBgColor:n?g:s}},H=r.genStyleHooks("Radio",e=>{const{controlOutline:n,controlOutlineWidth:i}=e,t=`0 0 0 ${r.unit(i)} ${n}`,o=t,l=r.merge(e,{radioFocusShadow:t,radioButtonFocusShadow:o});return[K(l),Q(l),Z(l)]},ee,{unitless:{radioSize:!0,dotSize:!0}}),W=a.createContext(null),te=W.Provider,F=a.createContext(null),oe=F.Provider;var re=["prefixCls","className","style","checked","disabled","defaultChecked","type","title","onChange"],ne=j.forwardRef(function(e,n){var i=e.prefixCls,t=i===void 0?"rc-checkbox":i,o=e.className,l=e.style,C=e.checked,g=e.disabled,d=e.defaultChecked,$=d===void 0?!1:d,f=e.type,s=f===void 0?"checkbox":f,O=e.title,k=e.onChange,w=r._objectWithoutProperties(e,re),x=j.useRef(null),u=j.useRef(null),R=r.useMergedState($,{value:C}),h=r._slicedToArray(R,2),S=h[0],y=h[1];j.useImperativeHandle(n,function(){return{focus:function(v){var b;(b=x.current)===null||b===void 0||b.focus(v)},blur:function(){var v;(v=x.current)===null||v===void 0||v.blur()},input:x.current,nativeElement:u.current}});var P=r.classNames(t,o,r._defineProperty(r._defineProperty({},"".concat(t,"-checked"),S),"".concat(t,"-disabled"),g)),c=function(v){g||("checked"in e||y(v.target.checked),k==null||k({target:r._objectSpread2(r._objectSpread2({},e),{},{type:s,checked:v.target.checked}),stopPropagation:function(){v.stopPropagation()},preventDefault:function(){v.preventDefault()},nativeEvent:v.nativeEvent}))};return a.createElement("span",{className:P,title:O,style:l,ref:u},a.createElement("input",r._extends({},w,{className:"".concat(t,"-input"),ref:x,onChange:c,disabled:g,checked:!!S,type:s})),a.createElement("span",{className:"".concat(t,"-inner")}))});function ie(e){const n=j.useRef(null),i=()=>{r.wrapperRaf.cancel(n.current),n.current=null};return[()=>{i(),n.current=r.wrapperRaf(()=>{n.current=null})},l=>{n.current&&(l.stopPropagation(),i()),e==null||e(l)}]}var ae=function(e,n){var i={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(i[t]=e[t]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,t=Object.getOwnPropertySymbols(e);o<t.length;o++)n.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(i[t[o]]=e[t[o]]);return i};const le=(e,n)=>{var i,t;const o=a.useContext(W),l=a.useContext(F),{getPrefixCls:C,direction:g,radio:d}=a.useContext(r.ConfigContext),$=a.useRef(null),f=r.composeRef(n,$),{isFormItemInput:s}=a.useContext(r.FormItemInputContext);if(process.env.NODE_ENV!=="production"){const D=r.devUseWarning("Radio");process.env.NODE_ENV!=="production"&&D(!("optionType"in e),"usage","`optionType` is only support in Radio.Group.")}const O=D=>{var M,T;(M=e.onChange)===null||M===void 0||M.call(e,D),(T=o==null?void 0:o.onChange)===null||T===void 0||T.call(o,D)},{prefixCls:k,className:w,rootClassName:x,children:u,style:R,title:h}=e,S=ae(e,["prefixCls","className","rootClassName","children","style","title"]),y=C("radio",k),P=((o==null?void 0:o.optionType)||l)==="button",c=P?`${y}-button`:y,_=r.useCSSVarCls(y),[v,b,z]=H(y,_),p=Object.assign({},S),I=a.useContext(r.DisabledContext);o&&(p.name=o.name,p.onChange=O,p.checked=e.value===o.value,p.disabled=(i=p.disabled)!==null&&i!==void 0?i:o.disabled),p.disabled=(t=p.disabled)!==null&&t!==void 0?t:I;const B=r.classNames(`${c}-wrapper`,{[`${c}-wrapper-checked`]:p.checked,[`${c}-wrapper-disabled`]:p.disabled,[`${c}-wrapper-rtl`]:g==="rtl",[`${c}-wrapper-in-form-item`]:s,[`${c}-wrapper-block`]:!!(o!=null&&o.block)},d==null?void 0:d.className,w,x,b,z,_),[N,E]=ie(p.onClick);return v(a.createElement(r.Wave,{component:"Radio",disabled:p.disabled},a.createElement("label",{className:B,style:Object.assign(Object.assign({},d==null?void 0:d.style),R),onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,title:h,onClick:N},a.createElement(ne,Object.assign({},p,{className:r.classNames(p.className,{[r.TARGET_CLS]:!P}),type:"radio",prefixCls:c,ref:f,onClick:E})),u!==void 0?a.createElement("span",{className:`${c}-label`},u):null)))},V=a.forwardRef(le);process.env.NODE_ENV!=="production"&&(V.displayName="Radio");const se=a.forwardRef((e,n)=>{const{getPrefixCls:i,direction:t}=a.useContext(r.ConfigContext),o=r.useId(),{prefixCls:l,className:C,rootClassName:g,options:d,buttonStyle:$="outline",disabled:f,children:s,size:O,style:k,id:w,optionType:x,name:u=o,defaultValue:R,value:h,block:S=!1,onChange:y,onMouseEnter:P,onMouseLeave:c,onFocus:_,onBlur:v}=e,[b,z]=r.useMergedState(R,{value:h}),p=a.useCallback(m=>{const Y=b,G=m.target.value;"value"in e||z(G),G!==Y&&(y==null||y(m))},[b,z,y]),I=i("radio",l),B=`${I}-group`,N=r.useCSSVarCls(I),[E,D,M]=H(I,N);let T=s;d&&d.length>0&&(T=d.map(m=>typeof m=="string"||typeof m=="number"?a.createElement(V,{key:m.toString(),prefixCls:I,disabled:f,value:m,checked:b===m},m):a.createElement(V,{key:`radio-group-value-options-${m.value}`,prefixCls:I,disabled:m.disabled||f,value:m.value,checked:b===m.value,title:m.title,style:m.style,id:m.id,required:m.required},m.label)));const L=r.useSize(O),X=r.classNames(B,`${B}-${$}`,{[`${B}-${L}`]:L,[`${B}-rtl`]:t==="rtl",[`${B}-block`]:S},C,g,D,M,N),U=a.useMemo(()=>({onChange:p,value:b,disabled:f,name:u,optionType:x,block:S}),[p,b,f,u,x,S]);return E(a.createElement("div",Object.assign({},r.pickAttrs(e,{aria:!0,data:!0}),{className:X,style:k,onMouseEnter:P,onMouseLeave:c,onFocus:_,onBlur:v,id:w,ref:n}),a.createElement(te,{value:U},T)))}),de=a.memo(se);var ce=function(e,n){var i={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(i[t]=e[t]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,t=Object.getOwnPropertySymbols(e);o<t.length;o++)n.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(i[t[o]]=e[t[o]]);return i};const ue=(e,n)=>{const{getPrefixCls:i}=a.useContext(r.ConfigContext),{prefixCls:t}=e,o=ce(e,["prefixCls"]),l=i("radio",t);return a.createElement(oe,{value:"button"},a.createElement(V,Object.assign({prefixCls:l},o,{type:"radio",ref:n})))},be=a.forwardRef(ue),q=V;q.Button=be;q.Group=de;q.__ANT_RADIO=!0;const pe=j.memo(({open:e,onCallBack:n,queryFetch:i})=>{const[t,o]=j.useState([]),[l,C]=j.useState(0),[g,d]=j.useState(""),[$,f]=j.useState(!1);return j.useEffect(()=>{(async()=>{f(!0);try{await i({success:s=>{o(s.data||[])}})}catch(s){console.log(s)}f(!1)})()},[e]),r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:r.jsxRuntimeExports.jsx(A.Modal,{open:e,title:"转接",footer:!1,onCancel:()=>n(),children:r.jsxRuntimeExports.jsxs(r.ModelBody,{children:[r.jsxRuntimeExports.jsx("div",{children:r.jsxRuntimeExports.jsx(q.Group,{options:[{label:"转接坐席",value:0},{label:"转接技能组",value:1}],value:l,onChange:s=>C(s.target.value)})}),r.jsxRuntimeExports.jsx(r.Spin,{spinning:$,children:r.jsxRuntimeExports.jsxs("div",{style:{borderTop:"1px solid #eee",marginTop:10,paddingTop:10},children:[l===0&&r.jsxRuntimeExports.jsx(r.Space,{wrap:!0,children:t.map(s=>r.jsxRuntimeExports.jsxs(A.Tag,{color:"processing",onClick:()=>n(s.agent_no),children:[r.jsxRuntimeExports.jsxs("span",{style:{marginRight:10},children:["咨询坐席: ",s.agent_name]}),r.jsxRuntimeExports.jsx(r.YsytIconSvg,{name:"zixun"})]},s.agent_no))}),l===1&&r.jsxRuntimeExports.jsx(r.Input,{value:g,onChange:s=>d(s.target.value),placeholder:"请输入外线号码, 回车转接",onPressEnter:()=>{n(g)}})]})})]})})})});exports.default=pe;
|
|
@@ -8,4 +8,4 @@ export interface IIconSvgProps {
|
|
|
8
8
|
color?: string;
|
|
9
9
|
[x: string]: any;
|
|
10
10
|
}
|
|
11
|
-
export default function
|
|
11
|
+
export default function YsytIconSvg({ name, prefix, size, color, styles, className, ...props }: IIconSvgProps): React.JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { s as Ft, K as Ne, g as re, m as fe, u as N, t as Dt, r as nt, v as kt, x as K, y as At, z as _t, B as Pe, A as ot, E as Vt, h as R, d as O, G as De, p as je, f as Y, c as Ie, H as at, J as ke, n as Wt, L as Ae, N as _e, P as qt, R as Te, O as Gt, C as q, Q as ge, U as Xt, V as Ut, X as Me, Z as Kt, $ as lt, k as Ce, l as rt, a0 as Qt, a1 as Zt, a2 as Yt, a3 as ue, a4 as Re, a5 as Jt, a6 as st, a7 as en, a8 as tn, a9 as nn, aa as on, ab as an, ac as ln, ad as rn, ae as sn, af as cn, ag as it, ah as dn, ai as un, aj as mn, ak as fn, al as gn, am as Cn, W as pn } from "./index-CSZ70qrC.mjs";
|
|
2
2
|
import * as r from "react";
|
|
3
3
|
import $, { useContext as se, useRef as Z, useMemo as vn, useEffect as Ve } from "react";
|
|
4
4
|
const bn = new Ne("antFadeIn", {
|