view-design / viewuiplus Goto Github PK
View Code? Open in Web Editor NEWAn enterprise-level UI component library and front-end solution based on Vue.js 3
Home Page: https://www.iviewui.com
License: Other
An enterprise-level UI component library and front-end solution based on Vue.js 3
Home Page: https://www.iviewui.com
License: Other
win11 edge vue3
https://run.iviewui.com/uNt3f9MK
官方的 View Design Run 运行 InputNumber 都有问题
InputNumber 能正常使用
InputNumber 不能正常使用,InputNumber 丢失箭头样式,不能点击切换数字
Windows 10 企业版 19042.1526 / chrome: 103.0.5060.114(正式版本) (64 位) / vue: 3.2.36
https://run.iviewui.com/jjuk9Eqx
1、添加一个表格
2、最后一列设置为固定列
3、普通列内容不要产生换行,固定列内容产生换行
普通列的行高被撑开,与固定列保持一致
普通列的行高未被撑开
仅在 windows 环境下, chrome 103 版本测试,其他操作系统未做测试
按回车快速选择选项。
逻辑:Select 激活,并没有键盘选中项时,候选项不为空时,按回车,直接选中第一个候选项。
新增 props:quick-confirm 默认 false
vue ^2.6.10, "view-design": "^4.2.0",
http://iviewui.com/view-ui-plus/component/view/modal
在modal内部,使用了表单,点确认的时候会去验证表单,如果表单报错,此时不想关闭modal。但由于view-design 的modal组键on-ok源码:
if (this.loading) {
this.buttonLoading = true;
} else {
this.visible = false;
this.$emit('input', false);
}
this.$emit('on-ok');
代码中this.visible = false;自动关闭了modal。虽然loading控制可以控制,但并不完美。需要使用者做这样的代码:
this.loading = false;
setTimeout(() => {
this.loading = true;
}, 100);这样modal才不会关闭,并且有loading状态。
期望能在on-ok方法中去掉this.visible = false,由使用者自己控制onOk事件modal的显隐控制。
虽然loading控制可以控制,但并不完美。
谷歌浏览器
https://www.iviewui.com/view-ui-plus/component/form/table#csv
点击Export custom data按钮
点击只后能根据过滤下载
点击没有反应
这将在ts环境下使用Layout组件报类型检查错误。
exportData (type) {
if (type === 1) {
this.$refs.table.exportCsv({
filename: 'The original data'
});
} else if (type === 2) {
this.$refs.table.exportCsv({
filename: 'Sorting and filtering data',
original: false
});
} else if (type === 3) {
this.$refs.table.exportCsv({
filename: 'Custom data',
columns: this.columns8.filter((col, index) => index < 4),
data: this.data7.filter((data, index) => index < 4)
});
}
}
上面的this.columns8.filter应该是this.columns.filter
不想再自己写这个收缩展开菜单,三级菜单,
如ant design vue 的菜单
https://www.antdv.com/components/menu-cn
window10、chrome102.0.5005.63、Vue3.2.13
https://www.iviewui.com/view-ui-plus/component/form/select
1.iview官方文档链接
2.Select-远程搜索的示例
3.例子中的选项是美国的州名,输入搜索会自动清空已输入的字符,例如无法正常搜索到new york
连续输入new,remote-method方法中分三次得到n、ne、new
连续输入new,在remote-method方法中分三次得到n、e、w
官方文档中的示例与我在本地使用遇到同样的问题,每次输入触发remote-method后自动清空已输入的字符,完整的单词最终只能得到分开的单个字符
都可以重现
https://www.iviewui.com/view-ui-plus/component/form/upload
ImagePreview组件预览时,不显示文件名,不知道浏览的哪个文件,预览到非图片时显示失败,建议显示文件类型的预设图片
ImagePreview组件预览时,可以显示文件名,方便查看是哪个文件,同时预览到非图片文件时,比如pdf就显示一个预设的pdf图片,文档就显示一个doc图片,等等按类型区分显示文件图片,注意图片要小,否则占带宽,用icon也行,总比现在显示失败好
ImagePreview组件预览时,不显示文件名,不知道浏览的哪个文件,预览到非图片时显示失败,建议显示文件类型的预设图片
macOS 12.1/Chrome 102
https://www.iviewui.com/view-ui-plus/component/form/date-picker
不管几次回车都保正常结果
参考重现步骤
应该是picker.vue里面handleKeydown的处理逻辑问题。
另外,这个库打算长期更新吗?还是像https://github.com/view-design/ViewUI/issues 完全废弃了
If you set ssr: true mode in Nuxt 3, ...
import { defineNuxtConfig } from 'nuxt';
export default defineNuxtConfig({
ssr: true,
});
... you get the following message in the console.
[Vue warn]: Failed to resolve component: Button
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
[nitro] [dev] [unhandledRejection] TypeError: Invalid value used as weak map key
at WeakMap.set (<anonymous>)
at normalizePropsOptions (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/runtime-core/dist/runtime-core.cjs.js:3966:11)
at createComponentInstance (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/runtime-core/dist/runtime-core.cjs.js:6952:23)
at renderComponentVNode (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/server-renderer/dist/server-renderer.cjs.js:171:22)
at Module.ssrRenderComponent (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/server-renderer/dist/server-renderer.cjs.js:608:12)
at _sfc_ssrRender (file:///home/projects/nuxt-starter-7kmya5/.nuxt/dist/server/server.mjs:3388:31)
at renderComponentSubTree (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/server-renderer/dist/server-renderer.cjs.js:253:13)
at renderComponentVNode (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/server-renderer/dist/server-renderer.cjs.js:188:16)
at Module.ssrRenderComponent (/home/projects/nuxt-starter-7kmya5/node_modules/@vue/server-renderer/dist/server-renderer.cjs.js:608:12)
at default (file:///home/projects/nuxt-starter-7kmya5/.nuxt/dist/server/server.mjs:2658:37)
//---
How do I get rid of this message?
版本 101.0.4951.67(正式版本) (64 位)
https://run.iviewui.com/7E8S0Qi8
https://run.iviewui.com/7E8S0Qi8
布局有效
布局无效
都可以重现
https://www.iviewui.com/view-ui-plus/component/form/table
1.当模式为多选时,只要勾选了,table就会出现横向滚动条,即使内容不超出也会出现,做ui前端的,这点影响非常不好
2.单选,但是需要多选模式的勾选框来明确标记哪一行被勾选了,当我点击勾选时,同时我需要取消其他勾选,我的做法是先调用全部取消按钮,再手动调用勾选函数时,然后在勾选函数中调用勾选函数,造成了死循环,希望可以像jqgrid一样增加手动调用不触发函数的参数,所有函数都应该有此选项,静默调用,而不重复触发事件
3.树形数据结构设计太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太太差!其他成熟表格都是根据数组列表里的parentId,自动解析为树形表格,而iview的table却需要转换为children结构后才可以被table组件识别,第一,严重影响开发效率,后端一般直接获取非树形列表数据比较方便,第二,无法兼容很多场景,比如,index序号显示都不正常,还要自定义修复,勾选第一行,第三行也会被勾选,因为两行index一样,这都是树形数据的兼容性差所致,一定要自动识别原始列表数据,自动解析才好,第三,树形数据太难维护,我现在是做了vue监听,自动转换数据类型,再做相应的crud,综上所述,希望可以支持直接列表数据解析为树形table,同时兼容之前的树形数据,因为已经在使用了,加个属性标记就好
其他不再列举,希望iview越来越好
修复以上3个问题bug
都不好用
都可以重现
https://www.iviewui.com/view-ui-plus/component/form/upload
qq截图后,ctrl v粘贴,无效,必须先点击一下组件,弹出文件选择框,然后关闭文件选择框才能粘贴,非常不人性化,希望可以鼠标移上去触发监听粘贴事件,mouterenter时组件就开始监听粘贴事件,这样,鼠标移动上去后,就可以粘贴了
截图后可以直接粘贴,不需要先点击一下组件,或者鼠标移动到组件上就可以粘贴
必须先点击一下组件,弹出文件选择框,然后关闭文件选择框才能粘贴,非常不人性化
win11,谷歌浏览器,vue3
https://run.iviewui.com/LcqAlfjJ
按住分割线拖动
按住分割线能够左右拖动
分割线固定住,无法左右拖动
部分组件文档没有英文翻译
widow/Chrome版本 96.0.4664.45(正式版本) (64 位)/vue3
https://run.iviewui.com/BYfe32sV
控制台
正确显示
页面报错,组件不显示
https://run.iviewui.com/evJ4Um15
可细分disabled属性禁用复选框或item
https://ant.design/components/tree-cn/
https://www.naiveui.com/zh-CN/light/components/tree
新增checkboxDisabled属性
disabled属性增加禁用样式
color: var(--color-disabled);
cursor: not-allowed;
参考Ant Design https://ant.design/components/tree-cn/
参考Naive UI https://www.naiveui.com/zh-CN/light/components/tree
Vue3
https://www.iviewui.com/view-ui-plus/component/form/select;http://v4.iviewui.com/components/select
vue3中select组件开启filterable,重选后只显示过滤后的信息。vue2则显示全部的item。vue3版本是特意此设置吗?
vue3中select组件开启filterable,重选后显示全部item信息。和vue2版本一致
vue3中select组件开启filterable,重选后只显示过滤后的信息。
都可以重现
https://www.iviewui.com/view-ui-plus/component/form/input-number
新环境拖一个inputnumber组件出来就可以重现,你们没测试过吧?错误太低级了
输入框右边的上下按钮正常显示
输入框右边的上下按钮显示空白,不能点击
如题
提供 VS Code,可以识别 View UI Plus 的标签和 props 快速创建节点。
所有版本
https://run.iviewui.com/p8IXJyAQ
1.将select设置为多选
2.选择一个值之后,不要点击其他位置,使下拉列表保持展开的状态
3.点击表单submit按钮
当下拉列表展开的时候,第一次点击submit按钮应该触发表单校验
当下拉列表展开的时候,第一次点击submit按钮没有触发表单校验,需要等待下拉列表折叠后,也就是第二次点击才能触发表单校验
mscos 11.6.1 / chrome100 / vue3.0
https://iviewui.com/view-ui-plus/component/form/table
1.进去官方文档
2.搜索table组件
3.查看自定义render相关代码
h(resolveComponent('Button'), {
props: {
type: 'primary',
size: 'small'
},
style: {
marginRight: '5px'
},
onClick: () => {
this.show(params.index)
}
},
table render Button props传递的 的type属性可以获取到
未获取到props传递的参数
为用户显示文件上传失败记录
https://ant.design/components/upload-cn/
https://www.naiveui.com/zh-CN/os-theme/components/upload
fileList支持status配置
参考Ant Design https://ant.design/components/upload-cn/
参考Naive UI https://www.naiveui.com/zh-CN/os-theme/components/upload
vue ^2.6.10, "view-design": "^4.2.0",
https://run.iviewui.com/PChDwDQh
导给设置了icon的Input,添加clearable,输入内容以后icon消失
hover时显示close,其他时候显示原icon
hover时显示close,其他时候原icon消失
macos 12.4/chrom 103.0.5060.53/vue3
https://run.iviewui.com/Jy83V5OO
props传值未生效
安装文档写的 h("div", [
h(
resolveComponent("Button"),
{
props: {
type: "text",
size: "small",
},
onClick: () => {
this.showDeleteModal(params.row);
},
},
"移除"
),
]);组件props传值应该生效
props传值未生效
vue3文档中写的h函数的传参如下
h(
// {String | Object | Function} tag
// 一个 HTML 标签名、一个组件、一个异步组件、或
// 一个函数式组件。
//
// 必需的。
'div',
// {Object} props
// 与 attribute、prop 和事件相对应的对象。
// 这会在模板中用到。
//
// 可选的。
{},
// {String | Array | Object} children
// 子 VNodes, 使用 h()
构建,
// 或使用字符串获取 "文本 VNode" 或者
// 有插槽的对象。
//
// 可选的。
[
'Some text comes first.',
h('h1', 'A headline'),
h(MyComponent, {
someProp: 'foobar'
})
]
)
源码中的函数定义是第二个参数不是传children就是props 所以应该直接传属性名 包括style和html的原生属性
我提供的代码的VIEW按钮是我的写法 是可以正确显示的 DELETE按钮是文档写法 不能正确显示
Table event on-select-all-cancel return selected rows' data array.
So, it return empty array. It doesn't help
方便用户查找
大数据下查找到需要的数据
Microsoft Edge 版本 101.0.1210.53 (正式版本) (64 位)
https://run.iviewui.com/Ty3SCMh1
Modal,大量数据出现滚动条时,顶部内容被遮挡
不遮挡
遮挡
引用就报错了:
Argument of type 'ViewUIPlus' is not assignable to parameter of type 'Plugin_2'.
import { createApp } from 'vue';
import ViewUIPlus from 'view-ui-plus';
import 'view-ui-plus/dist/styles/viewuiplus.css';
import App from '@/App.vue';
const app = createApp(App);
app.use(ViewUIPlus).mount('#app');
"vue": "^3.2.33",
"view-ui-plus": "^1.0.0",
提供更多的图标支持
无
(1)《Input》
《template #append》
《span》com《/span》
《/template》
《/Input》
(2)《Input》
《span slot="append"》com《/span》
《/Input》
上面(英文状态下展示有问题,换成中文的《》)(1)是iview的vue3官网的写法,(2)是iview的vue2的写法,vue2可以直接写标签,给个slot=“suffix”,就可以显示出来,现在要加上template的#prepend,这个要怎么render出来?希望有大佬能解答
vite搭建的项目,按照文档用法定制主题,设置了新的less变量,没有报错信息,但是定制的样式并没有生效。
win11/edge102/vue3.2
https://github.com/view-design/view-ui-project-vuecli
1、下载官方提供的项目源码(view-ui-project-vuecli)
2、在views/Home.vue中加入
3、在本地运行后页面输入框中没有上下箭头图标,只显示一条竖向分割线
正常显示数字及上下箭头图标,并且点击点击可以改变数字。
鼠标经过后只显示一条竖向分割线没有上下箭头,并且点击后数字无法改变。
操作系统版本: Windows 11 / 浏览器版本: Chrome 103.0.5060.114 / Vue 版本: Vue 3 或 Vue 2 / UI 框架版本: View UI Plus / View UI
https://run.iviewui.com/jMi7dee1
固定列不应覆盖掉表格的横向滚动条,Fixed 层应当只覆盖表头及内容部分。
固定列覆盖掉了表格的横向滚动条导致被覆盖了的横向滚动条无法点击,若需横向滚动,只能点击非固定列下方的横向滚动条来达到滚动的目的。
该 Bug 在 View UI(Vue 2)及 View UI Plus(Vue 3)均可重现。
1.比如我想导出一个部门的数据,在选择了最顶级的部门之后,其子部门也应当全部被导出,所以子节点也应当被全部选中;
2.如果所有子节点不是全部选中状态,则相应父节点以待定状态表示;
3.子节点全部未选中,则父节点也应当是未选中状态
childs-select,开启子节点根据父节点状态变更
mac / chrome 101.0.4951.64 / vue 3.2.20
https://run.iviewui.com/WIeCe4dp
使用vite vue ,main.js 中 import 'view-ui-plus/src/styles/index.less' ,控制台提示 fonts/ionicons.ttf?v=3.0.0 not found,并且页面中icon看不见。
定制主题后,icon正常显示。
定制主题后,icon不显示。
操作系统版本 / 浏览器版本 / Vue 版本等等信息
操作系统版本 / 浏览器版本 / Vue 版本等等信息
操作系统版本 / 浏览器版本 / Vue 版本等等信息
操作系统版本 / 浏览器版本 / Vue 版本等等信息
都可以重现
https://www.iviewui.com/view-ui-plus/component/form/upload
新增加的ImagePreview组件很好用,但是点击下载的时候文件名是unnamed,请取文件名
新增加的ImagePreview组件很好用,但是点击下载的时候文件名是unnamed,请取文件名
新增加的ImagePreview组件很好用,但是点击下载的时候文件名是unnamed,请取文件名
win11/edge/vue3.0
https://run.iviewui.com/JaNTdh1E
ColorPicker开启 transfer 点击确定后,颜色能正常修改
ColorPicker开启 transfer 点击确定后,无任何反应
1.3.0
https://run.iviewui.com/dL8IHevT
都可以重现
https://www.iviewui.com/view-ui-plus/component/form/upload
比如最大允许上传5个文件,只要已上传列表个数小于5,那么一次性多选任意多个文件上传,都是允许的,因为该组件只根据已上传列表uploadlist的个数来判断,没有考虑即将上传后的文件个数,所以这就导致了上传后的个数没有限制,远远大于5,这是非常低级的bug,居然没有考虑到。。。
增加一个属性prop来设置max-files-number,当已上传列表+即将上传的文件个数大于max-files-number时,回调提示错误
完全无效
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.