rx-compo 1.0.68 → 1.0.71
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/es/components/RxCheckboxGroup/index.js +1 -1
- package/es/components/RxRadio/index.d.ts +1 -1
- package/es/components/RxRadio/index.js +1 -1
- package/es/components/RxRadio/src/RxRadio.d.ts +1 -1
- package/es/components/RxRadioButton/index.d.ts +1 -1
- package/es/components/RxRadioButton/index.js +1 -1
- package/es/components/RxRadioButton/src/RxRadioButton.d.ts +1 -1
- package/es/components/RxRadioButton/src/RxRadioButton.vue.d.ts +1 -1
- package/es/components/RxRadioGroup/index.d.ts +1 -1
- package/es/components/RxRadioGroup/index.js +1 -1
- package/es/components/RxRadioGroup/src/RxRadioGroup.d.ts +62 -5
- package/es/components/RxRadioGroup/src/RxRadioGroup.vue.d.ts +275 -1
- package/es/components/RxRadioGroup/src/hooks/useController.d.ts +6 -0
- package/es/components/RxRadioGroup/src/hooks/useRadioGroup.d.ts +8 -0
- package/es/components/RxSelect/index.js +1 -1
- package/es/components/RxSuperCondition/index.css +1 -0
- package/es/components/RxSuperCondition/index.js +1 -1
- package/es/components/RxTooltip/index.js +1 -1
- package/es/utils/useTextOverflow.js +4 -0
- package/index.esm.js +1 -1
- package/index.js +1 -1
- package/lib/components/RxCheckboxGroup/index.js +1 -1
- package/lib/components/RxRadio/index.d.ts +1 -1
- package/lib/components/RxRadio/index.js +1 -1
- package/lib/components/RxRadio/src/RxRadio.d.ts +1 -1
- package/lib/components/RxRadioButton/index.d.ts +1 -1
- package/lib/components/RxRadioButton/index.js +1 -1
- package/lib/components/RxRadioButton/src/RxRadioButton.d.ts +1 -1
- package/lib/components/RxRadioButton/src/RxRadioButton.vue.d.ts +1 -1
- package/lib/components/RxRadioGroup/index.d.ts +1 -1
- package/lib/components/RxRadioGroup/index.js +1 -1
- package/lib/components/RxRadioGroup/src/RxRadioGroup.d.ts +62 -5
- package/lib/components/RxRadioGroup/src/RxRadioGroup.vue.d.ts +275 -1
- package/lib/components/RxRadioGroup/src/hooks/useController.d.ts +6 -0
- package/lib/components/RxRadioGroup/src/hooks/useRadioGroup.d.ts +8 -0
- package/lib/components/RxSelect/index.js +1 -1
- package/lib/components/RxSuperCondition/index.css +1 -0
- package/lib/components/RxSuperCondition/index.js +1 -1
- package/lib/components/RxTooltip/index.js +1 -1
- package/lib/utils/useTextOverflow.js +4 -0
- package/package.json +1 -1
- package/theme-chalk/components-style.css +1 -0
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/rx-checkbox.css +1 -1
- package/theme-chalk/rx-radio-group.css +1 -0
- package/theme-chalk/rx-radio.css +1 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{withInstall as e}from"rx-compo/es/utils/with-install";import{computed as o,ref as t,nextTick as l,defineComponent as n,resolveComponent as s,openBlock as r,createBlock as c,normalizeProps as a,mergeProps as u,createSlots as i,renderList as p,withCtx as h,renderSlot as x,guardReactiveProps as m,createElementBlock as d,Fragment as k,createCommentVNode as f,createVNode as C,resolveDynamicComponent as g,toDisplayString as b,normalizeClass as y,createElementVNode as T,normalizeStyle as v,createTextVNode as R}from"vue";import{IxPropTypes as B}from"rx-compo/es/utils";import{ElCheckboxGroup as A,ElRow as O,ElCol as $}from"element-plus";import{map as S}from"lodash-es";import{useVModel as _}from"@vueuse/core";import{RxTooltip as w}from"rx-compo/es/components/RxTooltip";import{RxScrollbar as V}from"rx-compo/es/components/RxScrollbar";import{useTextOverflow as j}from"rx-compo/es/utils/useTextOverflow";import{RxCheckbox as F,RxCheckboxButton as G}from"rx-compo/es/components";const M={modelValue:B.array(),rxCheckboxAll:B.bool.def(!1),rxCheckboxAllText:B.string.def("全选"),checkBoxOptions:{type:Array,default:[]},toolTipFormatter:{type:Function,default:null},checkAllSlotsFormatter:{type:Function,default:null},toolTipConfig:{type:Object,default:{placement:"top"}},gutter:B.number,justify:{type:String,default:"start"},baseColProps:{type:Object,default:()=>({xl:4,lg:6,md:8,sm:12,xs:24})},isButton:B.bool.def(!1),rxCheckBoxAttr:{type:Object,default:{}}};var I=n({name:"RxCheckboxComponents",components:{RxCheckbox:F,RxCheckboxButton:G},setup:(e,{slots:o})=>({rxCheckBoxSlots:Object.keys(o)})});I.render=function(e,o,t,l,n,d){const k=s("rx-checkbox-button"),f=s("rx-checkbox");return e.$attrs.isButton?(r(),c(k,a(u({key:0},e.$attrs.isButton)),i({_:2},[p(e.rxCheckBoxSlots,(o=>({name:o,fn:h((t=>[x(e.$slots,`${o}`,a(m(t)))]))})))]),1040)):(r(),c(f,a(u({key:1},e.$attrs)),i({_:2},[p(e.rxCheckBoxSlots,(o=>({name:o,fn:h((t=>[x(e.$slots,`${o}`,a(m(t)))]))})))]),1040))},I.__file="packages/components/RxCheckboxGroup/components/RxCheckboxComponents.vue";var H=n({name:"RxCheckboxGroup",components:{ElCheckboxGroup:A,ElRow:O,ElCol:$,RxCheckboxComponents:I,RxScrollbar:V,RxTooltip:w},props:M,setup(e,{emit:n}){const s=_(e,"modelValue",n),{isIndeterminate:r,checkAll:c,checkBoxOptionsComputed:a,itemsRef:u,setItemRef:i,handleCheckAllChange:p,handleCheckedChange:h}=function(e,l){const n=o((()=>e.checkBoxOptions||[])),s=t([]),r=t(!0),c=t(!1);return{isIndeterminate:r,checkAll:c,checkboxGroupValue:l,itemsRef:s,checkBoxOptionsComputed:n,setItemRef:e=>{e&&s.value.push(e)},handleCheckAllChange:e=>{l.value=e?S(n.value,(e=>e.label)):[],r.value=!1},handleCheckedChange:e=>{const o=e.length;c.value=o===n.value.length,r.value=o>0&&o<n.value.length}}}(e,s),{rxToolTipConfig:x,updateRxToolTipConfig:m}=function(e){const o=t();return{rxToolTipConfig:o,updateRxToolTipConfig:function(t){const{toolTipConfig:l}=e,{width:n}=t.getBoundingClientRect(),s={width:(null==l?void 0:l.tooltipWidth)?l.tooltipWidth:`${n}px`,maxHeight:(null==l?void 0:l.maxHeight)?l.maxHeight:"80px"};o.value=Object.assign(Object.assign({},l),{style:s})}}}(e),{isOverflowed:d,handleMouseenter:k}=function(e,o){const{isOverflowed:t,checkOverflowCustom:n}=j("RxCheckbox");return{itemsRef:e,isOverflowed:t,handleMouseenter:function(t){const s=e.value[t].$el;n(s),l((()=>o(s)))}}}(u,m);return{isIndeterminate:r,checkboxGroupValue:s,checkAll:c,rxToolTipConfig:x,isOverflowed:d,itemsRef:u,checkBoxOptionsComputed:a,setItemRef:i,handleMouseenter:k,handleCheckAllChange:p,handleCheckedChange:h}}});const E={key:0,class:"rx-checkbox-group"},P={key:2};H.render=function(e,o,t,l,n,i){const B=s("RxCheckboxComponents"),A=s("rx-scrollbar"),O=s("rx-tooltip"),$=s("el-col"),S=s("el-row"),_=s("el-checkbox-group");return r(),d(k,null,[e.rxCheckboxAll?(r(),d("div",E,[f(" 默认全选按钮 "),C(B,{modelValue:e.checkAll,"onUpdate:modelValue":o[0]||(o[0]=o=>e.checkAll=o),isButton:!1,indeterminate:e.isIndeterminate,onChange:e.handleCheckAllChange},{default:h((()=>[f(" 函数式 "),e.checkAllSlotsFormatter?(r(),c(g(e.checkAllSlotsFormatter.call(null,{})),{key:0})):e.$slots.checkAllSlots?(r(),d(k,{key:1},[f(" 插槽 "),x(e.$slots,"checkAllSlots")],2112)):(r(),d("span",P,b(e.rxCheckboxAllText),1))])),_:3},8,["modelValue","indeterminate","onChange"])])):f("v-if",!0),C(_,u({...e.$attrs,...e.$props},{modelValue:e.checkboxGroupValue,"onUpdate:modelValue":o[1]||(o[1]=o=>e.checkboxGroupValue=o),onChange:e.handleCheckedChange,class:"rx-checkbox-group"}),{default:h((()=>[f(" 模板默认插槽 "),e.$slots.default?x(e.$slots,"default",{key:0}):(r(),d(k,{key:1},[f(" 配置 "),C(S,{gutter:e.gutter,type:"flex",class:y(`justify-${e.justify}`)},{default:h((()=>[(r(!0),d(k,null,p(e.checkBoxOptionsComputed,((o,t)=>(r(),c($,u({key:
|
|
1
|
+
import{withInstall as e}from"rx-compo/es/utils/with-install";import{computed as o,ref as t,nextTick as l,defineComponent as n,resolveComponent as s,openBlock as r,createBlock as c,normalizeProps as a,mergeProps as u,createSlots as i,renderList as p,withCtx as h,renderSlot as x,guardReactiveProps as m,createElementBlock as d,Fragment as k,createCommentVNode as f,createVNode as C,resolveDynamicComponent as g,toDisplayString as b,normalizeClass as y,createElementVNode as T,normalizeStyle as v,createTextVNode as R}from"vue";import{IxPropTypes as B}from"rx-compo/es/utils";import{ElCheckboxGroup as A,ElRow as O,ElCol as $}from"element-plus";import{map as S}from"lodash-es";import{useVModel as _}from"@vueuse/core";import{RxTooltip as w}from"rx-compo/es/components/RxTooltip";import{RxScrollbar as V}from"rx-compo/es/components/RxScrollbar";import{useTextOverflow as j}from"rx-compo/es/utils/useTextOverflow";import{RxCheckbox as F,RxCheckboxButton as G}from"rx-compo/es/components";const M={modelValue:B.array(),rxCheckboxAll:B.bool.def(!1),rxCheckboxAllText:B.string.def("全选"),checkBoxOptions:{type:Array,default:[]},toolTipFormatter:{type:Function,default:null},checkAllSlotsFormatter:{type:Function,default:null},toolTipConfig:{type:Object,default:{placement:"top"}},gutter:B.number,justify:{type:String,default:"start"},baseColProps:{type:Object,default:()=>({xl:4,lg:6,md:8,sm:12,xs:24})},isButton:B.bool.def(!1),rxCheckBoxAttr:{type:Object,default:{}}};var I=n({name:"RxCheckboxComponents",components:{RxCheckbox:F,RxCheckboxButton:G},setup:(e,{slots:o})=>({rxCheckBoxSlots:Object.keys(o)})});I.render=function(e,o,t,l,n,d){const k=s("rx-checkbox-button"),f=s("rx-checkbox");return e.$attrs.isButton?(r(),c(k,a(u({key:0},e.$attrs.isButton)),i({_:2},[p(e.rxCheckBoxSlots,(o=>({name:o,fn:h((t=>[x(e.$slots,`${o}`,a(m(t)))]))})))]),1040)):(r(),c(f,a(u({key:1},e.$attrs)),i({_:2},[p(e.rxCheckBoxSlots,(o=>({name:o,fn:h((t=>[x(e.$slots,`${o}`,a(m(t)))]))})))]),1040))},I.__file="packages/components/RxCheckboxGroup/components/RxCheckboxComponents.vue";var H=n({name:"RxCheckboxGroup",components:{ElCheckboxGroup:A,ElRow:O,ElCol:$,RxCheckboxComponents:I,RxScrollbar:V,RxTooltip:w},props:M,setup(e,{emit:n}){const s=_(e,"modelValue",n),{isIndeterminate:r,checkAll:c,checkBoxOptionsComputed:a,itemsRef:u,setItemRef:i,handleCheckAllChange:p,handleCheckedChange:h}=function(e,l){const n=o((()=>e.checkBoxOptions||[])),s=t([]),r=t(!0),c=t(!1);return{isIndeterminate:r,checkAll:c,checkboxGroupValue:l,itemsRef:s,checkBoxOptionsComputed:n,setItemRef:e=>{e&&s.value.push(e)},handleCheckAllChange:e=>{l.value=e?S(n.value,(e=>e.label)):[],r.value=!1},handleCheckedChange:e=>{const o=e.length;c.value=o===n.value.length,r.value=o>0&&o<n.value.length}}}(e,s),{rxToolTipConfig:x,updateRxToolTipConfig:m}=function(e){const o=t();return{rxToolTipConfig:o,updateRxToolTipConfig:function(t){const{toolTipConfig:l}=e,{width:n}=t.getBoundingClientRect(),s={width:(null==l?void 0:l.tooltipWidth)?l.tooltipWidth:`${n}px`,maxHeight:(null==l?void 0:l.maxHeight)?l.maxHeight:"80px"};o.value=Object.assign(Object.assign({},l),{style:s})}}}(e),{isOverflowed:d,handleMouseenter:k}=function(e,o){const{isOverflowed:t,checkOverflowCustom:n}=j("RxCheckbox");return{itemsRef:e,isOverflowed:t,handleMouseenter:function(t){const s=e.value[t].$el;n(s),l((()=>o(s)))}}}(u,m);return{isIndeterminate:r,checkboxGroupValue:s,checkAll:c,rxToolTipConfig:x,isOverflowed:d,itemsRef:u,checkBoxOptionsComputed:a,setItemRef:i,handleMouseenter:k,handleCheckAllChange:p,handleCheckedChange:h}}});const E={key:0,class:"rx-checkbox-group"},P={key:2};H.render=function(e,o,t,l,n,i){const B=s("RxCheckboxComponents"),A=s("rx-scrollbar"),O=s("rx-tooltip"),$=s("el-col"),S=s("el-row"),_=s("el-checkbox-group");return r(),d(k,null,[e.rxCheckboxAll?(r(),d("div",E,[f(" 默认全选按钮 "),C(B,{modelValue:e.checkAll,"onUpdate:modelValue":o[0]||(o[0]=o=>e.checkAll=o),isButton:!1,indeterminate:e.isIndeterminate,onChange:e.handleCheckAllChange},{default:h((()=>[f(" 函数式 "),e.checkAllSlotsFormatter?(r(),c(g(e.checkAllSlotsFormatter.call(null,{})),{key:0})):e.$slots.checkAllSlots?(r(),d(k,{key:1},[f(" 插槽 "),x(e.$slots,"checkAllSlots")],2112)):(r(),d("span",P,b(e.rxCheckboxAllText),1))])),_:3},8,["modelValue","indeterminate","onChange"])])):f("v-if",!0),C(_,u({...e.$attrs,...e.$props},{modelValue:e.checkboxGroupValue,"onUpdate:modelValue":o[1]||(o[1]=o=>e.checkboxGroupValue=o),onChange:e.handleCheckedChange,class:"rx-checkbox-group"}),{default:h((()=>[f(" 模板默认插槽 "),e.$slots.default?x(e.$slots,"default",{key:0}):(r(),d(k,{key:1},[f(" 配置 "),C(S,{gutter:e.gutter,type:"flex",class:y(`justify-${e.justify}`)},{default:h((()=>[(r(!0),d(k,null,p(e.checkBoxOptionsComputed,((o,t)=>(r(),c($,u({key:o,ref_for:!0,ref:e.setItemRef,style:`${o.colStyle||""}`,class:`${o.colClass||""}`},o.colProps||e.baseColProps),{default:h((()=>[f(" 溢出隐藏 "),e.isOverflowed?(r(),c(O,a(u({key:0},e.rxToolTipConfig)),{content:h((()=>[f(" checkBoxOptions[index].slots options可自定义配置h函数模板 "),o.toolTipSlots?(r(),c(g(o.toolTipSlots.call(null,o)),a(u({key:0},o)),null,16)):e.toolTipFormatter?(r(),d(k,{key:1},[f(" props toolTipFormatter 通配h函数模板 "),(r(),c(g(e.toolTipFormatter.call(null,o)),a(m(o)),null,16))],2112)):(r(),d(k,{key:2},[f(" 默认渲染模板 "),T("div",{style:v(e.rxToolTipConfig.style)},[C(A,{"max-height":e.rxToolTipConfig.style.maxHeight},{default:h((()=>[R(b(o?.toolTipContent||o?.label),1)])),_:2},1032,["max-height"])],4)],2112))])),default:h((()=>[C(B,u({...e.rxCheckBoxAttr,...o},{isButton:e.isButton,onMouseenter:o=>e.handleMouseenter(t)}),null,16,["isButton","onMouseenter"])])),_:2},1040)):(r(),d(k,{key:1},[f(" 默认checkbox "),C(B,u({...e.rxCheckBoxAttr,...o},{isButton:e.isButton,onMouseenter:o=>e.handleMouseenter(t)}),null,16,["isButton","onMouseenter"])],2112))])),_:2},1040,["style","class"])))),128))])),_:1},8,["gutter","class"])],64))])),_:3},16,["modelValue","onChange"])],64)},H.__file="packages/components/RxCheckboxGroup/src/RxCheckboxGroup.vue";const U=e(H);export{U as RxCheckboxGroup,U as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{withInstall as o}from"rx-compo/es/utils/with-install";import{defineComponent as e,resolveComponent as l,openBlock as t,
|
|
1
|
+
import{withInstall as o}from"rx-compo/es/utils/with-install";import{defineComponent as e,resolveComponent as l,openBlock as t,createBlock as a,mergeProps as s,createSlots as r,withCtx as u,resolveDynamicComponent as d,normalizeProps as n,renderSlot as i}from"vue";import{ElRadio as m}from"element-plus";import{useVModel as p}from"@vueuse/core";var c=e({name:"RxRadio",components:{ElRadio:m},props:{modelValue:{type:[String,Number,Boolean],default:!1},slots:{type:Function,default:null}},setup:(o,{emit:e})=>({rxRadioLoacl:p(o,"modelValue",e)})});c.render=function(o,e,m,p,c,f){const R=l("el-radio");return t(),a(R,s({modelValue:o.rxRadioLoacl,"onUpdate:modelValue":e[0]||(e[0]=e=>o.rxRadioLoacl=e)},{...o.$attrs,...o.$props},{class:"rx-radio"}),r({_:2},[o.$slots.default||o.slots?{name:"default",fn:u((()=>[o.slots?(t(),a(d(o.slots.call(null,o.$attrs)),n(s({key:0},o.$attrs)),null,16)):i(o.$slots,"default",{key:1})]))}:void 0]),1040,["modelValue"])},c.__file="packages/components/RxRadio/src/RxRadio.vue";const f=o(c);export{f as RxRadio,f as default};
|
|
@@ -10,6 +10,6 @@ export declare const RxRadioProps: {
|
|
|
10
10
|
default: any;
|
|
11
11
|
};
|
|
12
12
|
};
|
|
13
|
-
export declare type
|
|
13
|
+
export declare type RxRadioPropsType = ExtractInnerPropTypes<typeof RxRadioProps>;
|
|
14
14
|
export declare type RxRadioPublicProps = ExtractPublicPropTypes<typeof RxRadioProps>;
|
|
15
15
|
export declare type RxRadioComponent = DefineComponent<keyof RxRadioPublicProps> & RxRadioPublicProps;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
declare const RxRadioButton: any;
|
|
2
2
|
export { RxRadioButton };
|
|
3
3
|
export default RxRadioButton;
|
|
4
|
-
export type {
|
|
4
|
+
export type { RxRadioButtonPropsType, RxRadioButtonPublicProps, RxRadioButtonComponent } from './src/RxRadioButton';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{withInstall as o}from"rx-compo/es/utils/with-install";import{defineComponent as t,resolveComponent as e,openBlock as l,createElementBlock as a,createVNode as
|
|
1
|
+
import{withInstall as o}from"rx-compo/es/utils/with-install";import{defineComponent as t,resolveComponent as e,openBlock as l,createElementBlock as a,createVNode as u,mergeProps as n,createSlots as s,withCtx as r,createBlock as d,resolveDynamicComponent as i,normalizeProps as m,renderSlot as p}from"vue";import{ElRadioButton as c}from"element-plus";import{useVModel as f}from"@vueuse/core";var R=t({name:"RxRadioButton",components:{ElRadioButton:c},props:{modelValue:{type:[String,Number,Boolean],default:!1},slots:{type:Function,default:null}},setup:(o,{emit:t})=>({rxRadioButtonLoacl:f(o,"modelValue",t)})});const x={class:"rx-radio-button"};R.render=function(o,t,c,f,R,B){const v=e("el-radio-button");return l(),a("div",x,[u(v,n({modelValue:o.rxRadioButtonLoacl,"onUpdate:modelValue":t[0]||(t[0]=t=>o.rxRadioButtonLoacl=t)},{...o.$attrs,...o.$props}),s({_:2},[o.$slots.default||o.slots?{name:"default",fn:r((()=>[o.slots?(l(),d(i(o.slots.call(null,o.$attrs)),m(n({key:0},o.$attrs)),null,16)):p(o.$slots,"default",{key:1})]))}:void 0]),1040,["modelValue"])])},R.__file="packages/components/RxRadioButton/src/RxRadioButton.vue";const B=o(R);export{B as RxRadioButton,B as default};
|
|
@@ -10,6 +10,6 @@ export declare const RxRadioButtonProps: {
|
|
|
10
10
|
default: any;
|
|
11
11
|
};
|
|
12
12
|
};
|
|
13
|
-
export declare type
|
|
13
|
+
export declare type RxRadioButtonPropsType = ExtractInnerPropTypes<typeof RxRadioButtonProps>;
|
|
14
14
|
export declare type RxRadioButtonPublicProps = ExtractPublicPropTypes<typeof RxRadioButtonProps>;
|
|
15
15
|
export declare type RxRadioButtonComponent = DefineComponent<keyof RxRadioButtonPublicProps> & RxRadioButtonPublicProps;
|
|
@@ -8,7 +8,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
8
8
|
default: any;
|
|
9
9
|
};
|
|
10
10
|
}, {
|
|
11
|
-
|
|
11
|
+
rxRadioButtonLoacl: import("vue").Ref<string | number | boolean> | import("vue").WritableComputedRef<string | number | boolean>;
|
|
12
12
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
13
|
modelValue: {
|
|
14
14
|
type: (BooleanConstructor | StringConstructor | NumberConstructor)[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
declare const RxRadioGroup: any;
|
|
2
2
|
export { RxRadioGroup };
|
|
3
3
|
export default RxRadioGroup;
|
|
4
|
-
export type {
|
|
4
|
+
export type { RxRadioGroupPropsType, RxRadioGroupInstance, RxRadioGroupComponent } from './src/RxRadioGroup';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{withInstall as o}from"rx-compo/es/utils/with-install";import{defineComponent as
|
|
1
|
+
import{withInstall as o}from"rx-compo/es/utils/with-install";import{defineComponent as t,resolveComponent as e,openBlock as r,createBlock as l,normalizeProps as n,mergeProps as s,createSlots as i,renderList as u,withCtx as a,renderSlot as p,guardReactiveProps as d,computed as m,ref as c,nextTick as x,createCommentVNode as f,createElementBlock as R,Fragment as g,createVNode as y,normalizeClass as T,resolveDynamicComponent as h,createElementVNode as C,normalizeStyle as O,createTextVNode as v,toDisplayString as b}from"vue";import{useVModel as k}from"@vueuse/core";import{ElRadioGroup as $,ElRow as G,ElCol as B}from"element-plus";import{RxTooltip as w}from"rx-compo/es/components/RxTooltip";import{RxScrollbar as _}from"rx-compo/es/components/RxScrollbar";import{IxPropTypes as S}from"rx-compo/es/utils";import{RxRadio as j}from"rx-compo/es/components/RxRadio";import{RxRadioButton as M}from"rx-compo/es/components/RxRadioButton";import{useTextOverflow as V}from"rx-compo/es/utils/useTextOverflow";const F={modelValue:{type:[String,Number,Boolean],default:!1},rxRadioGroupOptions:{type:Array,default:[]},toolTipFormatter:{type:Function,default:null},toolTipConfig:{type:Object,default:{placement:"top"}},gutter:S.number,justify:{type:String,default:"start"},baseColProps:{type:Object,default:()=>({xl:4,lg:6,md:8,sm:12,xs:24})},isButton:S.bool.def(!1),rxRadioAttr:{type:Object,default:{}}};var A=t({name:"RxRadioComponents",components:{RxRadio:j,RxRadioButton:M},setup:(o,{slots:t})=>({rxRadioSlots:Object.keys(t)})});A.render=function(o,t,m,c,x,f){const R=e("rx-radio-button"),g=e("rx-radio");return o.$attrs.isButton?(r(),l(R,n(s({key:0},o.$attrs.isButton)),i({_:2},[u(o.rxRadioSlots,(t=>({name:t,fn:a((e=>[p(o.$slots,`${t}`,n(d(e)))]))})))]),1040)):(r(),l(g,n(s({key:1},o.$attrs)),i({_:2},[u(o.rxRadioSlots,(t=>({name:t,fn:a((e=>[p(o.$slots,`${t}`,n(d(e)))]))})))]),1040))},A.__file="packages/components/RxRadioGroup/components/RxRadioComponents.vue";var H=t({name:"RxRadioGroup",components:{ElRadioGroup:$,ElRow:G,ElCol:B,RxRadioComponents:A,RxTooltip:w,RxScrollbar:_},props:F,setup(o,{emit:t}){const e=k(o,"modelValue",t),{rxRadioGroupOptionsComputed:r,itemsRef:l,setItemRef:n}=function(o,t){const e=m((()=>o.rxRadioGroupOptions||[])),r=c([]);return{checkboxGroupValue:t,itemsRef:r,rxRadioGroupOptionsComputed:e,setItemRef:o=>{o&&r.value.push(o)}}}(o,e),{rxToolTipConfig:s,updateRxToolTipConfig:i}=function(o){const t=c();return{rxToolTipConfig:t,updateRxToolTipConfig:function(e){const{toolTipConfig:r}=o,{width:l}=e.getBoundingClientRect(),n={width:(null==r?void 0:r.tooltipWidth)?r.tooltipWidth:`${l}px`,maxHeight:(null==r?void 0:r.maxHeight)?r.maxHeight:"80px"};t.value=Object.assign(Object.assign({},r),{style:n})}}}(o),{isOverflowed:u,handleMouseenter:a}=function(o,t){const{isOverflowed:e,checkOverflowCustom:r}=V("RxRadio");return{itemsRef:o,isOverflowed:e,handleMouseenter:function(e){const l=o.value[e].$el;r(l),x((()=>t(l)))}}}(l,i);return{rxRadioGroupValue:e,rxRadioGroupOptionsComputed:r,isOverflowed:u,rxToolTipConfig:s,setItemRef:n,handleMouseenter:a}}});H.render=function(o,t,i,m,c,x){const k=e("RxRadioComponents"),$=e("rx-scrollbar"),G=e("rx-tooltip"),B=e("el-col"),w=e("el-row"),_=e("el-radio-group");return r(),l(_,s({...o.$attrs,...o.$props},{modelValue:o.rxRadioGroupValue,"onUpdate:modelValue":t[0]||(t[0]=t=>o.rxRadioGroupValue=t),class:"rx-radio-group"}),{default:a((()=>[f(" 模板默认插槽 "),o.$slots.default?p(o.$slots,"default",{key:0}):(r(),R(g,{key:1},[f(" 配置 "),y(w,{gutter:o.gutter,type:"flex",class:T(`justify-${o.justify}`)},{default:a((()=>[(r(!0),R(g,null,u(o.rxRadioGroupOptionsComputed,((t,e)=>(r(),l(B,s({key:t,ref_for:!0,ref:o.setItemRef,style:`${t.colStyle||""}`,class:`${t.colClass||""}`},t.colProps||o.baseColProps),{default:a((()=>[f(" 溢出隐藏 "),o.isOverflowed?(r(),l(G,n(s({key:0},o.rxToolTipConfig)),{content:a((()=>[f(" checkBoxOptions[index].slots options可自定义配置h函数模板 "),t.toolTipSlots?(r(),l(h(t.toolTipSlots.call(null,t)),n(s({key:0},t)),null,16)):o.toolTipFormatter?(r(),R(g,{key:1},[f(" props toolTipFormatter 通配h函数模板 "),(r(),l(h(o.toolTipFormatter.call(null,t)),n(d(t)),null,16))],2112)):(r(),R(g,{key:2},[f(" 默认渲染模板 "),C("div",{style:O(o.rxToolTipConfig.style)},[y($,{"max-height":o.rxToolTipConfig.style.maxHeight},{default:a((()=>[v(b(t?.toolTipContent||t?.label),1)])),_:2},1032,["max-height"])],4)],2112))])),default:a((()=>[y(k,s({...o.rxRadioAttr,...t},{isButton:o.isButton,onMouseenter:t=>o.handleMouseenter(e)}),null,16,["isButton","onMouseenter"])])),_:2},1040)):(r(),R(g,{key:1},[f(" 默认checkbox "),y(k,s({...o.rxRadioAttr,...t},{isButton:o.isButton,onMouseenter:t=>o.handleMouseenter(e)}),null,16,["isButton","onMouseenter"])],2112))])),_:2},1040,["style","class"])))),128))])),_:1},8,["gutter","class"])],64))])),_:3},16,["modelValue"])},H.__file="packages/components/RxRadioGroup/src/RxRadioGroup.vue";const I=o(H);export{I as RxRadioGroup,I as default};
|
|
@@ -1,11 +1,68 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import {
|
|
1
|
+
import type { ExtractPropTypes, DefineComponent, PropType } from 'vue';
|
|
2
|
+
import type { RxRadioPropsType, RxRadioButtonPropsType, RxTooltipPropsType, ToolTipScrollbarCustomType } from 'rx-compo/es/components';
|
|
3
|
+
declare type RxRadioComponents = RxRadioPropsType & RxRadioButtonPropsType;
|
|
4
|
+
declare type RxRadioGroupToolTipConfig = RxTooltipPropsType & ToolTipScrollbarCustomType;
|
|
5
|
+
export interface ColObject {
|
|
6
|
+
span?: number;
|
|
7
|
+
offset?: number;
|
|
8
|
+
}
|
|
9
|
+
export interface ColProps {
|
|
10
|
+
tag?: string;
|
|
11
|
+
span?: number;
|
|
12
|
+
offset?: number;
|
|
13
|
+
pull?: number;
|
|
14
|
+
push?: number;
|
|
15
|
+
xs?: number | ColObject;
|
|
16
|
+
sm?: number | ColObject;
|
|
17
|
+
md?: number | ColObject;
|
|
18
|
+
lg?: number | ColObject;
|
|
19
|
+
xl?: number | ColObject;
|
|
20
|
+
}
|
|
21
|
+
export interface RadioType extends RxRadioComponents {
|
|
22
|
+
toolTipContent?: string;
|
|
23
|
+
toolTipSlots?: Function;
|
|
24
|
+
colProps?: ColProps;
|
|
25
|
+
colStyle?: string;
|
|
26
|
+
colClass?: string;
|
|
27
|
+
label: string;
|
|
28
|
+
}
|
|
3
29
|
export declare const RxRadioGroupProps: {
|
|
4
30
|
modelValue: {
|
|
5
31
|
type: (BooleanConstructor | StringConstructor | NumberConstructor)[];
|
|
6
32
|
default: boolean;
|
|
7
33
|
};
|
|
34
|
+
rxRadioGroupOptions: {
|
|
35
|
+
type: PropType<RadioType[]>;
|
|
36
|
+
default: any[];
|
|
37
|
+
};
|
|
38
|
+
toolTipFormatter: {
|
|
39
|
+
type: FunctionConstructor;
|
|
40
|
+
default: any;
|
|
41
|
+
};
|
|
42
|
+
toolTipConfig: {
|
|
43
|
+
type: PropType<RxRadioGroupToolTipConfig>;
|
|
44
|
+
default: {
|
|
45
|
+
placement: string;
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
gutter: import("vue-types").VueTypeValidableDef<number>;
|
|
49
|
+
justify: {
|
|
50
|
+
type: StringConstructor;
|
|
51
|
+
default: string;
|
|
52
|
+
};
|
|
53
|
+
baseColProps: {
|
|
54
|
+
type: PropType<ColProps>;
|
|
55
|
+
default: () => ColProps;
|
|
56
|
+
};
|
|
57
|
+
isButton: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
58
|
+
default: boolean;
|
|
59
|
+
};
|
|
60
|
+
rxRadioAttr: {
|
|
61
|
+
type: PropType<RxRadioComponents>;
|
|
62
|
+
default: {};
|
|
63
|
+
};
|
|
8
64
|
};
|
|
9
|
-
export declare type
|
|
10
|
-
export declare type
|
|
11
|
-
export declare type
|
|
65
|
+
export declare type RxRadioGroupPropsType = ExtractPropTypes<typeof RxRadioGroupProps>;
|
|
66
|
+
export declare type RxRadioGroupComponent = DefineComponent<typeof RxRadioGroupProps>;
|
|
67
|
+
export declare type RxRadioGroupInstance = InstanceType<DefineComponent<typeof RxRadioGroupProps>>;
|
|
68
|
+
export {};
|
|
@@ -3,14 +3,288 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
3
3
|
type: (BooleanConstructor | StringConstructor | NumberConstructor)[];
|
|
4
4
|
default: boolean;
|
|
5
5
|
};
|
|
6
|
+
rxRadioGroupOptions: {
|
|
7
|
+
type: import("vue").PropType<import("./RxRadioGroup").RadioType[]>;
|
|
8
|
+
default: any[];
|
|
9
|
+
};
|
|
10
|
+
toolTipFormatter: {
|
|
11
|
+
type: FunctionConstructor;
|
|
12
|
+
default: any;
|
|
13
|
+
};
|
|
14
|
+
toolTipConfig: {
|
|
15
|
+
type: import("vue").PropType<{} & {
|
|
16
|
+
readonly disabled?: boolean;
|
|
17
|
+
readonly onClick?: Function;
|
|
18
|
+
readonly style?: import("vue").StyleValue;
|
|
19
|
+
readonly id?: string;
|
|
20
|
+
readonly popperClass?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<string | {
|
|
21
|
+
[x: string]: boolean;
|
|
22
|
+
} | (string | {
|
|
23
|
+
[x: string]: boolean;
|
|
24
|
+
} | (string | {
|
|
25
|
+
[x: string]: boolean;
|
|
26
|
+
} | (string | {
|
|
27
|
+
[x: string]: boolean;
|
|
28
|
+
} | (string | {
|
|
29
|
+
[x: string]: boolean;
|
|
30
|
+
} | (string | {
|
|
31
|
+
[x: string]: boolean;
|
|
32
|
+
} | (string | {
|
|
33
|
+
[x: string]: boolean;
|
|
34
|
+
} | (string | {
|
|
35
|
+
[x: string]: boolean;
|
|
36
|
+
} | (string | {
|
|
37
|
+
[x: string]: boolean;
|
|
38
|
+
} | (string | {
|
|
39
|
+
[x: string]: boolean;
|
|
40
|
+
} | (string | any[] | {
|
|
41
|
+
[x: string]: boolean;
|
|
42
|
+
})[])[])[])[])[])[])[])[])[])[]>, unknown, unknown>;
|
|
43
|
+
readonly popperOptions?: unknown;
|
|
44
|
+
readonly zIndex?: number;
|
|
45
|
+
readonly onBlur?: Function;
|
|
46
|
+
readonly onFocus?: Function;
|
|
47
|
+
readonly onMouseleave?: Function;
|
|
48
|
+
readonly onMouseenter?: Function;
|
|
49
|
+
readonly onKeydown?: Function;
|
|
50
|
+
readonly visible?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<boolean>, unknown, unknown>;
|
|
51
|
+
readonly effect?: string;
|
|
52
|
+
readonly teleported?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
53
|
+
readonly persistent?: boolean;
|
|
54
|
+
openDelay?: number;
|
|
55
|
+
visibleArrow?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
56
|
+
readonly hideAfter?: number;
|
|
57
|
+
showArrow?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
58
|
+
readonly appendTo?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<string | HTMLElement>, unknown, unknown>;
|
|
59
|
+
readonly content?: string;
|
|
60
|
+
readonly rawContent?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
61
|
+
readonly ariaLabel?: string;
|
|
62
|
+
readonly transition?: string;
|
|
63
|
+
readonly className?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<string | {
|
|
64
|
+
[x: string]: boolean;
|
|
65
|
+
} | (string | {
|
|
66
|
+
[x: string]: boolean;
|
|
67
|
+
} | (string | {
|
|
68
|
+
[x: string]: boolean;
|
|
69
|
+
} | (string | {
|
|
70
|
+
[x: string]: boolean;
|
|
71
|
+
} | (string | {
|
|
72
|
+
[x: string]: boolean;
|
|
73
|
+
} | (string | {
|
|
74
|
+
[x: string]: boolean;
|
|
75
|
+
} | (string | {
|
|
76
|
+
[x: string]: boolean;
|
|
77
|
+
} | (string | {
|
|
78
|
+
[x: string]: boolean;
|
|
79
|
+
} | (string | {
|
|
80
|
+
[x: string]: boolean;
|
|
81
|
+
} | (string | {
|
|
82
|
+
[x: string]: boolean;
|
|
83
|
+
} | (string | any[] | {
|
|
84
|
+
[x: string]: boolean;
|
|
85
|
+
})[])[])[])[])[])[])[])[])[])[]>, unknown, unknown>;
|
|
86
|
+
readonly enterable?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
87
|
+
readonly pure?: boolean;
|
|
88
|
+
readonly popperStyle?: import("vue").StyleValue;
|
|
89
|
+
readonly referenceEl?: HTMLElement;
|
|
90
|
+
readonly stopPopperMouseEvent?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
91
|
+
readonly boundariesPadding?: number;
|
|
92
|
+
readonly fallbackPlacements?: import("element-plus").Placement;
|
|
93
|
+
readonly gpuAcceleration?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
94
|
+
readonly offset?: number;
|
|
95
|
+
readonly placement?: import("element-plus/es/utils").BuildPropType<StringConstructor, import("element-plus").Placement, unknown>;
|
|
96
|
+
readonly strategy?: import("element-plus/es/utils").BuildPropType<StringConstructor, "fixed" | "absolute", unknown>;
|
|
97
|
+
readonly showAfter?: number;
|
|
98
|
+
readonly trigger?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<"focus" | "hover" | "click" | "contextmenu" | ("focus" | "hover" | "click" | "contextmenu")[]>, unknown, unknown>;
|
|
99
|
+
readonly virtualRef?: import("element-plus").Measurable;
|
|
100
|
+
readonly virtualTriggering?: boolean;
|
|
101
|
+
readonly onContextmenu?: Function;
|
|
102
|
+
readonly open?: boolean;
|
|
103
|
+
} & import("rx-compo/es/components/RxTooltip").ToolTipScrollbarCustomType>;
|
|
104
|
+
default: {
|
|
105
|
+
placement: string;
|
|
106
|
+
};
|
|
107
|
+
};
|
|
108
|
+
gutter: import("vue-types").VueTypeValidableDef<number>;
|
|
109
|
+
justify: {
|
|
110
|
+
type: StringConstructor;
|
|
111
|
+
default: string;
|
|
112
|
+
};
|
|
113
|
+
baseColProps: {
|
|
114
|
+
type: import("vue").PropType<import("./RxRadioGroup").ColProps>;
|
|
115
|
+
default: () => import("./RxRadioGroup").ColProps;
|
|
116
|
+
};
|
|
117
|
+
isButton: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
118
|
+
default: boolean;
|
|
119
|
+
};
|
|
120
|
+
rxRadioAttr: {
|
|
121
|
+
type: import("vue").PropType<{
|
|
122
|
+
modelValue: string | number | boolean;
|
|
123
|
+
} & {
|
|
124
|
+
slots?: Function;
|
|
125
|
+
} & {
|
|
126
|
+
modelValue: string | number | boolean;
|
|
127
|
+
} & {
|
|
128
|
+
slots?: Function;
|
|
129
|
+
}>;
|
|
130
|
+
default: {};
|
|
131
|
+
};
|
|
6
132
|
}, {
|
|
7
|
-
|
|
133
|
+
rxRadioGroupValue: import("vue").Ref<string | number | boolean> | import("vue").WritableComputedRef<string | number | boolean>;
|
|
134
|
+
rxRadioGroupOptionsComputed: import("vue").ComputedRef<import("./RxRadioGroup").RadioType[]>;
|
|
135
|
+
isOverflowed: import("vue").Ref<boolean>;
|
|
136
|
+
rxToolTipConfig: import("vue").Ref<any>;
|
|
137
|
+
setItemRef: (el: any) => void;
|
|
138
|
+
handleMouseenter: (index: number) => void;
|
|
8
139
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
140
|
modelValue: {
|
|
10
141
|
type: (BooleanConstructor | StringConstructor | NumberConstructor)[];
|
|
11
142
|
default: boolean;
|
|
12
143
|
};
|
|
144
|
+
rxRadioGroupOptions: {
|
|
145
|
+
type: import("vue").PropType<import("./RxRadioGroup").RadioType[]>;
|
|
146
|
+
default: any[];
|
|
147
|
+
};
|
|
148
|
+
toolTipFormatter: {
|
|
149
|
+
type: FunctionConstructor;
|
|
150
|
+
default: any;
|
|
151
|
+
};
|
|
152
|
+
toolTipConfig: {
|
|
153
|
+
type: import("vue").PropType<{} & {
|
|
154
|
+
readonly disabled?: boolean;
|
|
155
|
+
readonly onClick?: Function;
|
|
156
|
+
readonly style?: import("vue").StyleValue;
|
|
157
|
+
readonly id?: string;
|
|
158
|
+
readonly popperClass?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<string | {
|
|
159
|
+
[x: string]: boolean;
|
|
160
|
+
} | (string | {
|
|
161
|
+
[x: string]: boolean;
|
|
162
|
+
} | (string | {
|
|
163
|
+
[x: string]: boolean;
|
|
164
|
+
} | (string | {
|
|
165
|
+
[x: string]: boolean;
|
|
166
|
+
} | (string | {
|
|
167
|
+
[x: string]: boolean;
|
|
168
|
+
} | (string | {
|
|
169
|
+
[x: string]: boolean;
|
|
170
|
+
} | (string | {
|
|
171
|
+
[x: string]: boolean;
|
|
172
|
+
} | (string | {
|
|
173
|
+
[x: string]: boolean;
|
|
174
|
+
} | (string | {
|
|
175
|
+
[x: string]: boolean;
|
|
176
|
+
} | (string | {
|
|
177
|
+
[x: string]: boolean;
|
|
178
|
+
} | (string | any[] | {
|
|
179
|
+
[x: string]: boolean;
|
|
180
|
+
})[])[])[])[])[])[])[])[])[])[]>, unknown, unknown>;
|
|
181
|
+
readonly popperOptions?: unknown;
|
|
182
|
+
readonly zIndex?: number;
|
|
183
|
+
readonly onBlur?: Function;
|
|
184
|
+
readonly onFocus?: Function;
|
|
185
|
+
readonly onMouseleave?: Function;
|
|
186
|
+
readonly onMouseenter?: Function;
|
|
187
|
+
readonly onKeydown?: Function;
|
|
188
|
+
readonly visible?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<boolean>, unknown, unknown>;
|
|
189
|
+
readonly effect?: string;
|
|
190
|
+
readonly teleported?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
191
|
+
readonly persistent?: boolean;
|
|
192
|
+
openDelay?: number;
|
|
193
|
+
visibleArrow?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
194
|
+
readonly hideAfter?: number;
|
|
195
|
+
showArrow?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
196
|
+
readonly appendTo?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<string | HTMLElement>, unknown, unknown>;
|
|
197
|
+
readonly content?: string;
|
|
198
|
+
readonly rawContent?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
199
|
+
readonly ariaLabel?: string;
|
|
200
|
+
readonly transition?: string;
|
|
201
|
+
readonly className?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<string | {
|
|
202
|
+
[x: string]: boolean;
|
|
203
|
+
} | (string | {
|
|
204
|
+
[x: string]: boolean;
|
|
205
|
+
} | (string | {
|
|
206
|
+
[x: string]: boolean;
|
|
207
|
+
} | (string | {
|
|
208
|
+
[x: string]: boolean;
|
|
209
|
+
} | (string | {
|
|
210
|
+
[x: string]: boolean;
|
|
211
|
+
} | (string | {
|
|
212
|
+
[x: string]: boolean;
|
|
213
|
+
} | (string | {
|
|
214
|
+
[x: string]: boolean;
|
|
215
|
+
} | (string | {
|
|
216
|
+
[x: string]: boolean;
|
|
217
|
+
} | (string | {
|
|
218
|
+
[x: string]: boolean;
|
|
219
|
+
} | (string | {
|
|
220
|
+
[x: string]: boolean;
|
|
221
|
+
} | (string | any[] | {
|
|
222
|
+
[x: string]: boolean;
|
|
223
|
+
})[])[])[])[])[])[])[])[])[])[]>, unknown, unknown>;
|
|
224
|
+
readonly enterable?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
225
|
+
readonly pure?: boolean;
|
|
226
|
+
readonly popperStyle?: import("vue").StyleValue;
|
|
227
|
+
readonly referenceEl?: HTMLElement;
|
|
228
|
+
readonly stopPopperMouseEvent?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
229
|
+
readonly boundariesPadding?: number;
|
|
230
|
+
readonly fallbackPlacements?: import("element-plus").Placement;
|
|
231
|
+
readonly gpuAcceleration?: import("element-plus/es/utils").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
232
|
+
readonly offset?: number;
|
|
233
|
+
readonly placement?: import("element-plus/es/utils").BuildPropType<StringConstructor, import("element-plus").Placement, unknown>;
|
|
234
|
+
readonly strategy?: import("element-plus/es/utils").BuildPropType<StringConstructor, "fixed" | "absolute", unknown>;
|
|
235
|
+
readonly showAfter?: number;
|
|
236
|
+
readonly trigger?: import("element-plus/es/utils").BuildPropType<import("element-plus/es/utils").PropWrapper<"focus" | "hover" | "click" | "contextmenu" | ("focus" | "hover" | "click" | "contextmenu")[]>, unknown, unknown>;
|
|
237
|
+
readonly virtualRef?: import("element-plus").Measurable;
|
|
238
|
+
readonly virtualTriggering?: boolean;
|
|
239
|
+
readonly onContextmenu?: Function;
|
|
240
|
+
readonly open?: boolean;
|
|
241
|
+
} & import("rx-compo/es/components/RxTooltip").ToolTipScrollbarCustomType>;
|
|
242
|
+
default: {
|
|
243
|
+
placement: string;
|
|
244
|
+
};
|
|
245
|
+
};
|
|
246
|
+
gutter: import("vue-types").VueTypeValidableDef<number>;
|
|
247
|
+
justify: {
|
|
248
|
+
type: StringConstructor;
|
|
249
|
+
default: string;
|
|
250
|
+
};
|
|
251
|
+
baseColProps: {
|
|
252
|
+
type: import("vue").PropType<import("./RxRadioGroup").ColProps>;
|
|
253
|
+
default: () => import("./RxRadioGroup").ColProps;
|
|
254
|
+
};
|
|
255
|
+
isButton: import("vue-types").VueTypeValidableDef<boolean> & {
|
|
256
|
+
default: boolean;
|
|
257
|
+
};
|
|
258
|
+
rxRadioAttr: {
|
|
259
|
+
type: import("vue").PropType<{
|
|
260
|
+
modelValue: string | number | boolean;
|
|
261
|
+
} & {
|
|
262
|
+
slots?: Function;
|
|
263
|
+
} & {
|
|
264
|
+
modelValue: string | number | boolean;
|
|
265
|
+
} & {
|
|
266
|
+
slots?: Function;
|
|
267
|
+
}>;
|
|
268
|
+
default: {};
|
|
269
|
+
};
|
|
13
270
|
}>>, {
|
|
14
271
|
modelValue: string | number | boolean;
|
|
272
|
+
toolTipConfig: {
|
|
273
|
+
placement: string;
|
|
274
|
+
};
|
|
275
|
+
justify: string;
|
|
276
|
+
baseColProps: import("./RxRadioGroup").ColProps;
|
|
277
|
+
toolTipFormatter: Function;
|
|
278
|
+
isButton: boolean;
|
|
279
|
+
rxRadioGroupOptions: import("./RxRadioGroup").RadioType[];
|
|
280
|
+
rxRadioAttr: {
|
|
281
|
+
modelValue: string | number | boolean;
|
|
282
|
+
} & {
|
|
283
|
+
slots?: Function;
|
|
284
|
+
} & {
|
|
285
|
+
modelValue: string | number | boolean;
|
|
286
|
+
} & {
|
|
287
|
+
slots?: Function;
|
|
288
|
+
};
|
|
15
289
|
}>;
|
|
16
290
|
export default _default;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { RxRadioGroupPropsType } from '../RxRadioGroup';
|
|
3
|
+
export declare function useRadioGroup(props: RxRadioGroupPropsType, checkboxGroupValue: Ref<any>): {
|
|
4
|
+
checkboxGroupValue: Ref<any>;
|
|
5
|
+
itemsRef: any;
|
|
6
|
+
rxRadioGroupOptionsComputed: import("vue").ComputedRef<import("../RxRadioGroup").RadioType[]>;
|
|
7
|
+
setItemRef: (el: any) => void;
|
|
8
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{withInstall as e}from"rx-compo/es/utils/with-install";import{ref as t,computed as o,unref as l,defineComponent as n,onMounted as r,resolveComponent as s,openBlock as c,createBlock as u,mergeProps as p,createSlots as a,withCtx as i,renderSlot as f,createElementBlock as x,Fragment as m,renderList as d,resolveDynamicComponent as S,normalizeProps as g,createCommentVNode as R}from"vue";import{useVModel as C}from"@vueuse/core";import{ElSelect as D}from"element-plus";import{RxOption as y}from"rx-compo/es/components/RxOption";var v=n({name:"RxSelect",components:{ElSelect:D,RxOption:y},props:{modelValue:{type:[Array,String,Number,Boolean,Object],default:""},options:{type:Array,default:[]},formatter:{type:Function,default:null}},setup(e,{attrs:n,emit:s,expose:c}){const u=t(),p=C(e,"modelValue",s),{rxSelectDropDownClass:a,updateRxSelectDropDown:i,getRxSelectDropDownConfig:f}=function(e,o){const l=t("rx-select-drop-option");return{rxSelectDropDownClass:l,updateRxSelectDropDown:function(){const{popperClass:e}=o;l.value=e?`rx-select-drop-option ${e}`:"rx-select-drop-option"},getRxSelectDropDownConfig:function(){return l.value}}}(0,n),{rxSelectConfig:x,updateRxSelectPlusConfig:m,getRxSelectPlusConfig:d}=function(e,n){const r=t();return{rxSelectConfig:r,updateRxSelectPlusConfig:function(){r.value={popperClass:o((()=>l(n)))}},getRxSelectPlusConfig:function(){return Object.assign(Object.assign({},e),r.value)}}}(n,a);return r((()=>{!function(e,t){e(),t()}(i,m)})),c({rxSelectRef:u,updateRxSelectPlusConfig:m,updateRxSelectDropDown:i,getRxSelectPlusConfig:d,getRxSelectDropDownConfig:f}),{rxSelectRef:u,rxSelectConfig:x,rxSelectModelValue:p}}});v.render=function(e,t,o,l,n,r){const C=s("rx-option"),D=s("el-select");return c(),u(D,p({modelValue:e.rxSelectModelValue,"onUpdate:modelValue":t[0]||(t[0]=t=>e.rxSelectModelValue=t),class:"rx-select",ref:"rxSelectRef"},{...e.$attrs,...e.rxSelectConfig}),a({default:i((()=>[e.$slots.default?f(e.$slots,"default",{key:0}):(c(!0),x(m,{key:1},d(e.options,(
|
|
1
|
+
import{withInstall as e}from"rx-compo/es/utils/with-install";import{ref as t,computed as o,unref as l,defineComponent as n,onMounted as r,resolveComponent as s,openBlock as c,createBlock as u,mergeProps as p,createSlots as a,withCtx as i,renderSlot as f,createElementBlock as x,Fragment as m,renderList as d,resolveDynamicComponent as S,normalizeProps as g,createCommentVNode as R}from"vue";import{useVModel as C}from"@vueuse/core";import{ElSelect as D}from"element-plus";import{RxOption as y}from"rx-compo/es/components/RxOption";var v=n({name:"RxSelect",components:{ElSelect:D,RxOption:y},props:{modelValue:{type:[Array,String,Number,Boolean,Object],default:""},options:{type:Array,default:[]},formatter:{type:Function,default:null}},setup(e,{attrs:n,emit:s,expose:c}){const u=t(),p=C(e,"modelValue",s),{rxSelectDropDownClass:a,updateRxSelectDropDown:i,getRxSelectDropDownConfig:f}=function(e,o){const l=t("rx-select-drop-option");return{rxSelectDropDownClass:l,updateRxSelectDropDown:function(){const{popperClass:e}=o;l.value=e?`rx-select-drop-option ${e}`:"rx-select-drop-option"},getRxSelectDropDownConfig:function(){return l.value}}}(0,n),{rxSelectConfig:x,updateRxSelectPlusConfig:m,getRxSelectPlusConfig:d}=function(e,n){const r=t();return{rxSelectConfig:r,updateRxSelectPlusConfig:function(){r.value={popperClass:o((()=>l(n)))}},getRxSelectPlusConfig:function(){return Object.assign(Object.assign({},e),r.value)}}}(n,a);return r((()=>{!function(e,t){e(),t()}(i,m)})),c({rxSelectRef:u,updateRxSelectPlusConfig:m,updateRxSelectDropDown:i,getRxSelectPlusConfig:d,getRxSelectDropDownConfig:f}),{rxSelectRef:u,rxSelectConfig:x,rxSelectModelValue:p}}});v.render=function(e,t,o,l,n,r){const C=s("rx-option"),D=s("el-select");return c(),u(D,p({modelValue:e.rxSelectModelValue,"onUpdate:modelValue":t[0]||(t[0]=t=>e.rxSelectModelValue=t),class:"rx-select",ref:"rxSelectRef"},{...e.$attrs,...e.rxSelectConfig}),a({default:i((()=>[e.$slots.default?f(e.$slots,"default",{key:0}):(c(!0),x(m,{key:1},d(e.options,(t=>(c(),u(C,p({key:t},t),{default:i((()=>[t.slots?(c(),u(S(t.slots.call(null,t)),g(p({key:0},t)),null,16)):e.formatter?(c(),u(S(e.formatter.call(null,t)),g(p({key:1},t)),null,16)):R("v-if",!0)])),_:2},1040)))),128))])),_:2},[e.$slots.prefix?{name:"prefix",fn:i((()=>[f(e.$slots,"prefix")]))}:void 0,e.$slots.empty?{name:"empty",fn:i((()=>[f(e.$slots,"empty")]))}:void 0]),1040,["modelValue"])},v.__file="packages/components/RxSelect/src/RxSelect.vue";const w=e(v);export{w as RxSelect,w as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.el-dialog__headerbtn[data-v-0a43c8c5]{outline:none}
|