From e84fe84688a2e962c5435296029f96d8d4f69cae Mon Sep 17 00:00:00 2001 From: zhengyiming <540361168@qq.com> Date: 星期一, 15 九月 2025 17:35:24 +0800 Subject: [PATCH] fix: nutui-taro radio --- patches/@nutui__nutui-taro@4.3.13.patch | 33 +++++++++++++++++++++++++++++++++ 1 files changed, 33 insertions(+), 0 deletions(-) diff --git a/patches/@nutui__nutui-taro@4.3.13.patch b/patches/@nutui__nutui-taro@4.3.13.patch index 08b3dbd..f3dcfec 100644 --- a/patches/@nutui__nutui-taro@4.3.13.patch +++ b/patches/@nutui__nutui-taro@4.3.13.patch @@ -48,6 +48,39 @@ }; }); const styles = computed(() => { +diff --git a/dist/packages/radiogroup/RadioGroup.js b/dist/packages/radiogroup/RadioGroup.js +index 861a0214fe5d148b9af468d7ed5c9720eeef2f74..df2cee2988945755ab5c6b6929693c3e77924874 100644 +--- a/dist/packages/radiogroup/RadioGroup.js ++++ b/dist/packages/radiogroup/RadioGroup.js +@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => { + return a; + }; + var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b)); +-import { defineComponent, provide, readonly, computed, watch, openBlock, createElementBlock, normalizeClass, renderSlot } from "vue"; ++import { defineComponent, provide, readonly, computed, watch, openBlock, createElementBlock, normalizeClass, renderSlot, nextTick } from "vue"; + import { R as RADIO_KEY } from "../types-BODurTjN.js"; + import { w as withInstall } from "../with-install-Ch3FF0uS.js"; + const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, { +@@ -35,18 +35,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({ + const emit = __emit; + const updateValue = (value) => { + emit("update:modelValue", value); ++ nextTick(()=>emit("change", value)); + }; + provide(RADIO_KEY, { + label: readonly(computed(() => props.modelValue)), + position: readonly(computed(() => props.textPosition)), + updateValue + }); +- watch( +- () => props.modelValue, +- (value) => { +- emit("change", value); +- } +- ); + return (_ctx, _cache) => { + return openBlock(), createElementBlock("view", { + class: normalizeClass(["nut-radio-group", `nut-radio-group--${_ctx.direction}`]) diff --git a/dist/packages/range/Range.js b/dist/packages/range/Range.js index 688b67464e4d05dc37996941d941033cea83ee2c..626db4d9889059aa08e1fd675e2333539efc766e 100644 --- a/dist/packages/range/Range.js -- Gitblit v1.9.1