We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
2.35.0
3.3.7
Microsoft Edge 版本 118.0.2088.76
win11
https://www.naiveui.com/zh-CN/os-theme/components/menu
按照https://www.naiveui.com/zh-CN/os-theme/components/menu的说明随便写的demo
期望能控制图标是否在菜单名字的前面或者后面
例如,帮助? ?帮助 这两种都能设置
只能让图标在菜单文字前面,例如?帮助
The text was updated successfully, but these errors were encountered:
//MenuOption { label: renderSearch(inputstr.value), key: 'search' },
function renderSearch (num:string) { return () => h(NInput, { style:{ width:'30vw' }, props:{ value:num, }, class:"h-input", placeholder:'搜索', onInput:(value)=>{console.log('input', value)}, onFocus:()=>{historyTabVisible.value = true}, onBlur:()=>{historyTabVisible.value = false} }, { //icon渲染 suffix:renderIcon(Search) } ) } function renderIcon (icon: Component) { return () => h(NIcon, null, { default: () => h(icon) }) }
或许你可以试试用h渲染函数实现
Sorry, something went wrong.
No branches or pull requests
TuSimple/naive-ui version (版本)
2.35.0
Vue version (Vue 版本)
3.3.7
Browser and its version (浏览器及其版本)
Microsoft Edge 版本 118.0.2088.76
System and its version (系统及其版本)
win11
Node version (Node 版本)
Reappearance link (重现链接)
https://www.naiveui.com/zh-CN/os-theme/components/menu
Reappearance steps (重现步骤)
按照https://www.naiveui.com/zh-CN/os-theme/components/menu的说明随便写的demo
Expected results (期望的结果)
期望能控制图标是否在菜单名字的前面或者后面
例如,帮助? ?帮助 这两种都能设置
Actual results (实际的结果)
只能让图标在菜单文字前面,例如?帮助
Remarks (补充说明)
The text was updated successfully, but these errors were encountered: