You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
9.3 KiB
1 line
9.3 KiB
"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[78782],{98447:function(e,n,r){r.d(n,{C2:function(){return d}});var o=r(17313),t=r(37613),i=r(83116);const a=e=>{const{checkboxCls:n}=e,r=`${n}-wrapper`;return[{[`${n}-group`]:Object.assign(Object.assign({},(0,o.Wf)(e)),{display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}}),[r]:Object.assign(Object.assign({},(0,o.Wf)(e)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${r}`]:{marginInlineStart:0},[`&${r}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[n]:Object.assign(Object.assign({},(0,o.Wf)(e)),{position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",borderRadius:e.borderRadiusSM,alignSelf:"center",[`${n}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0,[`&:focus-visible + ${n}-inner`]:Object.assign({},(0,o.oN)(e))},[`${n}-inner`]:{boxSizing:"border-box",position:"relative",top:0,insetInlineStart:0,display:"block",width:e.checkboxSize,height:e.checkboxSize,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"21.5%",display:"table",width:e.checkboxSize/14*5,height:e.checkboxSize/14*8,border:`${e.lineWidthBold}px solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`}},"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}})},{[`\n ${r}:not(${r}-disabled),\n ${n}:not(${n}-disabled)\n `]:{[`&:hover ${n}-inner`]:{borderColor:e.colorPrimary}},[`${r}:not(${r}-disabled)`]:{[`&:hover ${n}-checked:not(${n}-disabled) ${n}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"},[`&:hover ${n}-checked:not(${n}-disabled):after`]:{borderColor:e.colorPrimaryHover}}},{[`${n}-checked`]:{[`${n}-inner`]:{backgroundColor:e.colorPrimary,borderColor:e.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`}}},[`\n ${r}-checked:not(${r}-disabled),\n ${n}-checked:not(${n}-disabled)\n `]:{[`&:hover ${n}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"}}},{[n]:{"&-indeterminate":{[`${n}-inner`]:{backgroundColor:e.colorBgContainer,borderColor:e.colorBorder,"&:after":{top:"50%",insetInlineStart:"50%",width:e.fontSizeLG/2,height:e.fontSizeLG/2,backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'}}}}},{[`${r}-disabled`]:{cursor:"not-allowed"},[`${n}-disabled`]:{[`&, ${n}-input`]:{cursor:"not-allowed",pointerEvents:"none"},[`${n}-inner`]:{background:e.colorBgContainerDisabled,borderColor:e.colorBorder,"&:after":{borderColor:e.colorTextDisabled}},"&:after":{display:"none"},"& + span":{color:e.colorTextDisabled},[`&${n}-indeterminate ${n}-inner::after`]:{background:e.colorTextDisabled}}}]};function d(e,n){const r=(0,t.TS)(n,{checkboxCls:`.${e}`,checkboxSize:n.controlInteractiveSize});return[a(r)]}n.ZP=(0,i.Z)("Checkbox",((e,n)=>{let{prefixCls:r}=n;return[d(r,e)]}))},90782:function(e,n,r){r.d(n,{S:function(){return d}});var o=r(48736),t=r(67841);function i(e,n){var r=new Set;return e.forEach((function(e){n.has(e)||r.add(e)})),r}function a(e){var n=e||{},r=n.disabled,o=n.disableCheckbox,t=n.checkable;return!(!r&&!o)||!1===t}function d(e,n,r,d){var c,l=[];c=d||a;var s,u=new Set(e.filter((function(e){var n=!!(0,t.Z)(r,e);return n||l.push(e),n}))),f=new Map,p=0;return Object.keys(r).forEach((function(e){var n=r[e],o=n.level,t=f.get(o);t||(t=new Set,f.set(o,t)),t.add(n),p=Math.max(p,o)})),(0,o.ZP)(!l.length,"Tree missing follow keys: ".concat(l.slice(0,100).map((function(e){return"'".concat(e,"'")})).join(", "))),s=!0===n?function(e,n,r,o){for(var t=new Set(e),a=new Set,d=0;d<=r;d+=1)(n.get(d)||new Set).forEach((function(e){var n=e.key,r=e.node,i=e.children,a=void 0===i?[]:i;t.has(n)&&!o(r)&&a.filter((function(e){return!o(e.node)})).forEach((function(e){t.add(e.key)}))}));for(var c=new Set,l=r;l>=0;l-=1)(n.get(l)||new Set).forEach((function(e){var n=e.parent,r=e.node;if(!o(r)&&e.parent&&!c.has(e.parent.key))if(o(e.parent.node))c.add(n.key);else{var i=!0,d=!1;(n.children||[]).filter((function(e){return!o(e.node)})).forEach((function(e){var n=e.key,r=t.has(n);i&&!r&&(i=!1),d||!r&&!a.has(n)||(d=!0)})),i&&t.add(n.key),d&&a.add(n.key),c.add(n.key)}}));return{checkedKeys:Array.from(t),halfCheckedKeys:Array.from(i(a,t))}}(u,f,p,c):function(e,n,r,o,t){for(var a=new Set(e),d=new Set(n),c=0;c<=o;c+=1)(r.get(c)||new Set).forEach((function(e){var n=e.key,r=e.node,o=e.children,i=void 0===o?[]:o;a.has(n)||d.has(n)||t(r)||i.filter((function(e){return!t(e.node)})).forEach((function(e){a.delete(e.key)}))}));d=new Set;for(var l=new Set,s=o;s>=0;s-=1)(r.get(s)||new Set).forEach((function(e){var n=e.parent,r=e.node;if(!t(r)&&e.parent&&!l.has(e.parent.key))if(t(e.parent.node))l.add(n.key);else{var o=!0,i=!1;(n.children||[]).filter((function(e){return!t(e.node)})).forEach((function(e){var n=e.key,r=a.has(n);o&&!r&&(o=!1),i||!r&&!d.has(n)||(i=!0)})),o||a.delete(n.key),i&&d.add(n.key),l.add(n.key)}}));return{checkedKeys:Array.from(a),halfCheckedKeys:Array.from(i(d,a))}}(u,n.halfCheckedKeys,f,p,c),s}},67841:function(e,n,r){function o(e,n){return e[n]}r.d(n,{Z:function(){return o}})},71430:function(e,n,r){r.d(n,{F:function(){return m},H8:function(){return g},I8:function(){return v},km:function(){return p},oH:function(){return k},w$:function(){return h},zn:function(){return y}});var o=r(26420),t=r(15142),i=r(98506),a=r(33346),d=r(11592),c=r(2738),l=r(48736),s=r(67841),u=["children"];function f(e,n){return"".concat(e,"-").concat(n)}function p(e,n){return null!=e?e:n}function h(e){var n=e||{},r=n.title||"title";return{title:r,_title:n._title||[r],key:n.key||"key",children:n.children||"children"}}function y(e){return function e(n){return(0,d.Z)(n).map((function(n){if(!function(e){return e&&e.type&&e.type.isTreeNode}(n))return(0,l.ZP)(!n,"Tree/TreeNode can only accept TreeNode as children."),null;var r=n.key,o=n.props,t=o.children,d=(0,a.Z)(o,u),c=(0,i.Z)({key:r},d),s=e(t);return s.length&&(c.children=s),c})).filter((function(e){return e}))}(e)}function k(e,n,r){var o=h(r),a=o._title,d=o.key,l=o.children,s=new Set(!0===n?[]:n),u=[];return function e(r){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return r.map((function(h,y){for(var k,b=f(o?o.pos:"0",y),v=p(h[d],b),g=0;g<a.length;g+=1){var m=a[g];if(void 0!==h[m]){k=h[m];break}}var $=(0,i.Z)((0,i.Z)({},(0,c.Z)(h,[].concat((0,t.Z)(a),[d,l]))),{},{title:k,key:v,parent:o,pos:b,children:null,data:h,isStart:[].concat((0,t.Z)(o?o.isStart:[]),[0===y]),isEnd:[].concat((0,t.Z)(o?o.isEnd:[]),[y===r.length-1])});return u.push($),!0===n||s.has(v)?$.children=e(h[l]||[],$):$.children=[],$}))}(e),u}function b(e,n,r){var i,a=("object"===(0,o.Z)(r)?r:{externalGetKey:r})||{},d=a.childrenPropName,c=a.externalGetKey,l=h(a.fieldNames),s=l.key,u=l.children,y=d||u;c?"string"==typeof c?i=function(e){return e[c]}:"function"==typeof c&&(i=function(e){return c(e)}):i=function(e,n){return p(e[s],n)},function r(o,a,d,c){var l=o?o[y]:e,s=o?f(d.pos,a):"0",u=o?[].concat((0,t.Z)(c),[o]):[];if(o){var p=i(o,s),h={node:o,index:a,pos:s,key:p,parentPos:d.node?d.pos:null,level:d.level+1,nodes:u};n(h)}l&&l.forEach((function(e,n){r(e,n,{node:o,pos:s,level:d?d.level+1:-1},u)}))}(null)}function v(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.initWrapper,o=n.processEntity,t=n.onProcessFinished,i=n.externalGetKey,a=n.childrenPropName,d=n.fieldNames,c=arguments.length>2?arguments[2]:void 0,l=i||c,s={},u={},f={posEntities:s,keyEntities:u};return r&&(f=r(f)||f),b(e,(function(e){var n=e.node,r=e.index,t=e.pos,i=e.key,a=e.parentPos,d=e.level,c={node:n,nodes:e.nodes,index:r,key:i,pos:t,level:d},l=p(i,t);s[t]=c,u[l]=c,c.parent=s[a],c.parent&&(c.parent.children=c.parent.children||[],c.parent.children.push(c)),o&&o(c,f)}),{externalGetKey:l,childrenPropName:a,fieldNames:d}),t&&t(f),f}function g(e,n){var r=n.expandedKeys,o=n.selectedKeys,t=n.loadedKeys,i=n.loadingKeys,a=n.checkedKeys,d=n.halfCheckedKeys,c=n.dragOverNodeKey,l=n.dropPosition,u=n.keyEntities,f=(0,s.Z)(u,e);return{eventKey:e,expanded:-1!==r.indexOf(e),selected:-1!==o.indexOf(e),loaded:-1!==t.indexOf(e),loading:-1!==i.indexOf(e),checked:-1!==a.indexOf(e),halfChecked:-1!==d.indexOf(e),pos:String(f?f.pos:""),dragOver:c===e&&0===l,dragOverGapTop:c===e&&-1===l,dragOverGapBottom:c===e&&1===l}}function m(e){var n=e.data,r=e.expanded,o=e.selected,t=e.checked,a=e.loaded,d=e.loading,c=e.halfChecked,s=e.dragOver,u=e.dragOverGapTop,f=e.dragOverGapBottom,p=e.pos,h=e.active,y=e.eventKey,k=(0,i.Z)((0,i.Z)({},n),{},{expanded:r,selected:o,checked:t,loaded:a,loading:d,halfChecked:c,dragOver:s,dragOverGapTop:u,dragOverGapBottom:f,pos:p,active:h,key:y});return"props"in k||Object.defineProperty(k,"props",{get:function(){return(0,l.ZP)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),e}}),k}}}]); |