vueComponent / ant-design-vue

🌈 An enterprise-class UI components based on Ant Design and Vue. 🐜
https://antdv.com/
Other
20.29k stars 3.79k forks source link

[typography-paragraph]editable没有穿透传递onSave方法 #7896

Closed aov2005 closed 3 weeks ago

aov2005 commented 3 weeks ago
          ![image](https://github.com/vueComponent/ant-design-vue/assets/82451257/d8eed138-ab18-4306-a51d-eb52cefa241c)

然后这里其实也只是传了一个 onSave 方法,实际并没有做什么操作

Originally posted by @kovsu in https://github.com/vueComponent/ant-design-vue/issues/6887#issuecomment-1767550939

https://github.com/vueComponent/ant-design-vue/blob/6c13c964c5a56a440cf47aba9a8484ebbb2f3a1f/components/typography/Editable.tsx#L116C13-L116C17

这里有执行了save方法吧,只是typography-paragraph组件没有把onSave传过来

github-actions[bot] commented 3 weeks ago

Hello @aov2005, your issue has been closed because it does not conform to our issue requirements. Please use the Issue Helper to create an issue, thank you!

你好 @aov2005,为了能够进行高效沟通,我们对 issue 有一定的格式要求,你的 issue 因为不符合要求而被自动关闭。你可以通过 issue 助手 来创建 issue 以方便我们定位错误。谢谢配合!

kovsu commented 3 weeks ago

刚刚看了一下,他这里的 onSave,就是每次输入后的保存

https://github.com/vueComponent/ant-design-vue/blob/e46d537d45e7741aedef795e620ad7c82ed8d7f7/components/typography/Base.tsx#L476

kovsu commented 3 weeks ago

好像只有一个 onEnd 的 api

aov2005 commented 3 weeks ago

好像只有一个 onEnd 的 api

是的,时间有点久远了,具体使用场景好像是按下回车和blur就保存内容到后端