-
Notifications
You must be signed in to change notification settings - Fork 14.6k
New issue
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
[Element Reborn] Announce our fork of element repo #19081
Conversation
…="false"` is specified
Instead of resetting this.value to minValue
Notably async-validator, now it has full support for Promise
Node we don't use `draggable` as its prop name because `draggable` is a native DOM attribute.
…y styles and DOM structure
Remote search text is cleared when blurred, but the filter is still effective
1. fix memory leak https://github.com/ElemeFE/element/pull/18115/files 2. don't resize if the column is not resizable https://github.com/ElemeFE/element/pull/18179/files 3. don't check select-all checkbox if there are no data available https://github.com/ElemeFE/element/pull/18083/files
1. set preview `:initial-index` to `0` if src is not in previewSrcList ElemeFE#18871 and also fix preview example 2. fix ESC won't close preview for the second time ElemeFE#19027 ElemeFE#18906 3. fix undesired `overflow: scroll` style ElemeFE#18967 4. fix a race condition if src changes too frequently ElemeFE#18837 5. add `close-on-click-modal` prop ElemeFE#18947
1. show usage of `show-overflow-tooltip` in example 2. fix handling `hoverRow` with nested tables ElemeFE#17381 3. fix finding parent table when destroying 4. don't use computed property with $refs Because $refs are not observable at all 5. reschedule layout when setting data 6. fix TypeScript definition
1. add `@change` event ElemeFE#17913 2. don't prevent when suggestions are not visible ElemeFE#17472 3. allow `fetchSuggestions` returns a promise or an array 4. add `show-all-on-focus` prop 5. use tab for selection like enter
1. correctly compute inputNumberDisabled https://github.com/ElemeFE/element/pull/18439/files 2. fix: docs size description 3. recalculate value when precision changed https://github.com/ElemeFE/element/pull/13749/files
And also show boolean values in table
make ElForm::validateField without callback parameter returns Promise
Please can you provide further information. |
As I have described, this fork mainly focuses on bugfixes, and provides a few usage enhancements. But I don't think it will create more features, nor will it support Vue 3. If you are about to start a new project, I'd suggest that you use other alive projects like ant-design-vue. If you have old projects that uses element-ui to maintain, and encountered some issues/bugs, you can try our fork. We have been using our fork in production code, and it worked very well. As long as we still need to maintain our old projects, we will maintain our element-ui fork. |
…arent `el-form`s are disabled
Welcome to 🎉🎉🎉 Element Plus - A Vue.js 3.0 UI library 🎉🎉🎉 |
off topic |
@JinPengGeng 没有合并。官方2.15.1只包含了很少量的修复,我们的fork还包含了不少功能扩展,除了PR中提到的还有drawer拖拽改变大小支持等等,你可以选择性使用。 注意我们公司内部已经转向 Vue3+antdv2,Element的fork已经不是主要维护对象。当然有bug还是会修的 |
@CarterLi 好的,谢谢 |
Element Reborns
This PR is NOT for merging, but for tracking our contributions.
ELEMENT IS DEAD. LONG LIVE ELEMENT
Integration instruction
NPM repo: https://www.npmjs.com/element-ui-eoi
The modification may or may not introduce unknown issues. USE IT AT YOUR OWN RISK!
What's changed:
clear
button inside the popover too if:clearable="false"
is specified设置
:clearable="false"
的时候同时隐藏下拉框中的清空按钮。这个清空按钮炒鸡恶心,会把value
至null
,引起无端TypeError。建议各位都设置成不允许清空this.value === null
instead of resettingthis.value
tominValue
( The main reason that I decided to fork element )当
this.value === null
时保持输入框为空,而不是重置为最小值。这个bug更恶心,对于某些可空的数据,你上传的时候是undefined,保存进数据库变成null,返回给前端的时候就是null,显示到页面上就变成了最小值,无法避免。step-strictly
doc typo [Input Number]: fix step-strictly docs typo #18705修复文档
step-strictly
属性取值错误修复
size
属性文档当
precision
属性变化的时候重新计算值input
event emit重构组件逻辑,使用单项数据流。移除重复的
input
事件default-value
, to specify the behavior when input is cleared添加
default-value
属性,用以指定当用户清空输入框后保留的默认值修复
el-transfer-panel__item
样式。当transfer放在form里面的时候第一条数据下面会出现蜜汁边距,line-height的锅。stack-button
andflexable
prop添加
stack-button
和flexable
属性。原来transfer的样式都是内部固定好的,大小风格都无法调整:to
property support ( likerouter-link
)添加
:to
属性。不直接用router-link
的原因是el-link
可以被disabled
。注意请不要把disabled
简单实现为pointer-events: none
type="native"
,icon-right
andinherit-fs
添加
type="native"
,icon-right
andinherit-fs
属性支持简化样式和dom结构
icon-right
添加
icon-right
属性支持简化dom结构
允许在
disabled
的表单下有enabled
组件。通过在组件上显式设置:disabled="false"
来启用组件required="validation message"
支持
required="验证信息提示"
使用方式,一种简单的必填验证movable
property, to make the dialog draggable添加
movable
属性,允许用户拖动对话框修复“全选”复选框蜜汁位置偏移。又一个css优先级的坑
修复内存泄漏
当某一列不允许改变大小时不要触发resize
当表格中没有数据时不允许选择“全选”框
show-overflow-tooltip
in example在示例中显示
show-overflow-tooltip
的使用。原本是放在多选里面的(不知道为什么),而且里面文字长度根本触发不了overflowhoverRow
with nested tables fix [el-table] el-table-column 'hover-row' class error when expend co… #17381修复
hoverRow
与嵌套表格的兼容性,比如展开详情是个新表格。正确查找el-table-column的父级
不要在计算属性中返回$refs的值,因为$refs根本就不是响应式的,永远不会触发更新
设置data后重新计算布局(footer的坑)
修复ts类型定义
formatter
accepts object and string value允许
formatter
属性接受对象(将当前单元格值作为对象的key取值)和字符串(将当前单元格的值作为指定过滤器的值)。后端管理界面80%的表格有updateTime或createTime,40%的表格有status或其他枚举值。前者你可以定义一个全局过滤器比如formatDate
,后者你可以直接在data里面放个对象(或者也定义成全局的过滤器)。这个功能可以减掉不少重复代码,你会喜欢的。修复显示布尔值。原本默认布尔值不会显示在表格里
添加
filter-icon
属性,用以指定过滤图标的类名(而非一个固定的下箭头):initial-index
to0
if src is not in previewSrcList fix: The first list is displayed by default when there is nosrc
in thepreviewSrcList
#18871如果
src
不在previewSrcList
列表里,显示第一个图片。不知道各位试过element官方文档的image示例没有,图片预览功能点出来空白一片修复第二次打开图片预览不能用ESC键关闭(因为在第一次关闭预览时事件已经被清除了)
overflow: scroll
style Image: don't show image-viewer when preview is false #18967修复没有
previewSrcList
时点击图片会给body
添加overflow: scroll
的bug。我至少搜索到四五个issue是说这个问题的。。。修复图片改变太快时事件触发混乱的问题
close-on-click-modal
prop image: 增加 close-on-click-modal props 控制点击mask 关闭预览图的功能 #18947添加
close-on-click-modal
属性,点击遮罩层关闭预览(一个静态的图片预览功能就不要让用户点叉了,关键那个叉还不好看)修复事件名称,别的地方事件名都是on加中划线,不知这里为何成了驼峰。
修复title的边距
textarea支持清空属性
删除无用代码
使用外部包依赖而不是过时的本地的popper.js拷贝
修复
filterable
时点击下箭头不能关闭下拉列表的bug修复远程过滤问题。当搜索框失去焦点时搜索文字会被清空,但是过滤效果还在
label-key
prop添加
label-key
属性,绑定对象时有用placement
prop添加
placement
属性,有用时就有用cachedOptions
, which can cause memleak删除
cachedOptions
,这个属性的作用是当用户选择了某项但是那一项被从选项列表中移除时,能保留用户选择的值。这个属性只在绑定对象时有效果,在添加label-key
之后就没用了小代码重构
option-max-width
prop添加
option-max-width
属性以限制下拉框的最大宽度。当绑定从后端获取的用户输入的值时有用(测试会给你提bug的)textarea
(#15013) #18478修复主控件是textarea时箭头丢失的问题
@change
event Autocomplete: add change event #17913添加
change
事件当下拉框隐藏时不要
preventDefault
,也是主控件是textarea时有用fetchSuggestions
returns a promise or an array允许
fetchSuggestions
返回promise或直接返回数组。这都0202年了是时候放弃callback了tab键和enter一样可以选择一项
input-controls-position
prop添加
input-controls-position
属性。原本slider自带的那个数字输入框,上下按钮的位置固定在两边不能改的(几乎)完全重写,现在
slider
是一个受控组件,更好的拆分代码input
event triggering on mounted移除不必要的
input
事件修复打开抽屉时乱指焦点的问题
size
description in doc修复
size
属性文档描述focus-first
prop to let users control the default behavior添加
focus-first
属性,可以让用户控制是否自动设置焦点修复在不设置
type
属性时class
上出现undefined
use-kw
添加属性
use-kw
,作用见文档修改实现为受控组件,代码清理
修复在某些特殊情况下文本不会自动折行,而会被截断
option-max-width
prop; exposecascader-menu-height
var添加
option-max-width
属性(类似el-select
),暴露SCSS的cascader-menu-height
变量(控制下拉框默认高度)使用
provide/inject
获取父级group
组件实例,简化实现使用函数式组件实现,修复文档样式
async-validator
, now it has full support for Promise.更新依赖至尽可能新的版本。值得注意的是
async-validator
,新版有完整的Promise支持,不用写callback了(0202年问题系列)utils/types
, which is full of shit.element/src/utils/types.js
Line 15 in 6ec5f8e
这是什么鬼代码?干掉
保证大部分(除了table)在UT里面创建的组件被正确销毁。原本在UT里创建的Vue实例好多都没有删,都绑定在页面上。不同UT之间会互相干扰。
修这个问题时确实发现了UT里面的bug。。。
src/utils/*
, add type comments代码清理,简化逻辑,添加类型注释
aria-disabled
values [Input Number] Correctly compute inputNumberDisabled when false #18439全局修复
aria-disabled
属性计算。(this.elForm || {}).disabled
是undefined
,绑定到页面上就是"undefined"
。这个字符串的"undefined"
对于aria-disabled
是个非法的值修改大多数布局组件(el-container、el-header、el-footer、el-aside)为函数式组件
el-scrollbar
will use native::-webkit-scrollbar
pseudo element to customize the scrollbar style when available (Chrome like browsers), which generally improves performance. The draw back is that there is no transition on style changing.内部组件
el-scrollbar
会在支持的浏览器中使用::-webkit-scrollbar
伪元素给原生滚动条加样式,以提升性能。More features / bug fixes will be added later
A small trick for modifying default property values
Element exposes very few global configuations other than
size
andzIndex
. It can be troublesome to set the same desired property values on every component usage.For example you want to set
controls-position
ofinput-number
toright
by default. Following code does the trick:Please make sure these boxes are checked before submitting your PR, thank you!
dev
branch.