Commit d3a314af authored by baiyaaaaa's avatar baiyaaaaa

fixed fix upload/tabs/progress

parent a75627cf
...@@ -12,9 +12,10 @@ ...@@ -12,9 +12,10 @@
- 修复 TimePicker 图标样式被默认图标样式覆盖 - 修复 TimePicker 图标样式被默认图标样式覆盖
- 修复 在 mounted 钩子函数中改变 Select 绑定值不生效的问题 - 修复 在 mounted 钩子函数中改变 Select 绑定值不生效的问题
- 修复 在多个依次出现的 Dialog 或 Message Box 全部关闭后页面有几率不可滚动的问题 - 修复 在多个依次出现的 Dialog 或 Message Box 全部关闭后页面有几率不可滚动的问题
- 修复 Table 初次渲染时宽度重新计算 #78
- 新增 时间、日期选择器增加 align 属性,可设置对齐方式 - 新增 时间、日期选择器增加 align 属性,可设置对齐方式
- 新增 TableColumn 的 align 属性 - 新增 TableColumn 的 align 属性
- 修复 Table 初次渲染时宽度重新计算 #78 - 新增 autocomplete 的 select 事件
#### 非兼容性更新 #### 非兼容性更新
- Select 组件样式的 `display` 属性默认值修改为 `block` - Select 组件样式的 `display` 属性默认值修改为 `block`
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
## Docs ## Docs
Coming soon <a href="http://element.eleme.io/">http://element.eleme.io/</a>
## Demo ## Demo
Demo will come with the documentation. Here is a preview of what a page based on Element looks like: Demo will come with the documentation. Here is a preview of what a page based on Element looks like:
......
...@@ -16,11 +16,6 @@ ...@@ -16,11 +16,6 @@
} }
} }
</script> </script>
<style>
.el-tabs {
margin-bottom: 30px;
}
</style>
## Tabs 标签页 ## Tabs 标签页
分隔内容上有关联但属于不同类别的数据集合。 分隔内容上有关联但属于不同类别的数据集合。
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
::: demo 通过 slot 你可以传入自定义的上传按钮类型和文字提示。 ::: demo 通过 slot 你可以传入自定义的上传按钮类型和文字提示。
```html ```html
<el-upload <el-upload
action="http://127.0.0.1:9000/upload" action="http://jsonplaceholder.typicode.com/"
:on-preview="handlePreview" :on-preview="handlePreview"
:on-remove="handleRemove"> :on-remove="handleRemove">
<el-button size="small" type="primary">点击上传</el-button> <el-button size="small" type="primary">点击上传</el-button>
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
::: demo 将 `type` 属性指定为 'drag' 可以将上传控件变为支持拖拽的形式,并且你可以通过 `multiple` 属性来控制是否支持多选,`on-preview``on-remove` 是一个钩子函数,分别在点击上传后的文件链接和点击移除上传后的文件后被调用。 ::: demo 将 `type` 属性指定为 'drag' 可以将上传控件变为支持拖拽的形式,并且你可以通过 `multiple` 属性来控制是否支持多选,`on-preview``on-remove` 是一个钩子函数,分别在点击上传后的文件链接和点击移除上传后的文件后被调用。
```html ```html
<el-upload <el-upload
action="http://127.0.0.1:9000/upload" action="http://jsonplaceholder.typicode.com/"
type="drag" type="drag"
:multiple="true" :multiple="true"
:on-preview="handlePreview" :on-preview="handlePreview"
...@@ -108,7 +108,7 @@ ...@@ -108,7 +108,7 @@
::: demo `thumbnail-mode` 属性允许你将上传组件强制只允许图片上传,并支持展示上传文件的缩略图。 ::: demo `thumbnail-mode` 属性允许你将上传组件强制只允许图片上传,并支持展示上传文件的缩略图。
```html ```html
<el-upload <el-upload
action="http://127.0.0.1:9000/upload" action="http://jsonplaceholder.typicode.com/"
type="drag" type="drag"
:thumbnail-mode="true" :thumbnail-mode="true"
:on-preview="handlePreview" :on-preview="handlePreview"
......
...@@ -82,9 +82,9 @@ ...@@ -82,9 +82,9 @@
return (this.strokeWidth / this.width * 100).toFixed(1); return (this.strokeWidth / this.width * 100).toFixed(1);
}, },
trackPath() { trackPath() {
var radius = 50 - parseFloat(this.relativeStrokeWidth) / 2; var radius = parseInt(50 - parseFloat(this.relativeStrokeWidth) / 2, 10);
return `M 50,50 m 0,-${radius} a ${radius},${radius} 0 1 1 0,${radius * 2} a ${radius},${radius} 0 1 1 0,-${radius * 2}`; return `M 50 50 m 0 -${radius} a ${radius} ${radius} 0 1 1 0 ${radius * 2} a ${radius} ${radius} 0 1 1 0 -${radius * 2}`;
}, },
perimeter() { perimeter() {
var radius = 50 - parseFloat(this.relativeStrokeWidth) / 2; var radius = 50 - parseFloat(this.relativeStrokeWidth) / 2;
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
</script> </script>
<template> <template>
<div class="el-tab-pane" v-if="show"> <div class="el-tab-pane" v-if="show && $slots.default">
<slot></slot> <slot></slot>
</div> </div>
</template> </template>
...@@ -24,19 +24,17 @@ ...@@ -24,19 +24,17 @@
.el-progress__text { .el-progress__text {
position: absolute; position: absolute;
top: 0; top: 50%;
left: 0; left: 0;
width: 100%; width: 100%;
height: 100%;
text-align: center; text-align: center;
margin: 0; margin: 0;
transform: translate(0, -50%);
i { i {
vertical-align: middle; vertical-align: middle;
display: inline-block; display: inline-block;
} }
@utils-vertical-center;
} }
} }
@m without-text { @m without-text {
......
...@@ -160,7 +160,7 @@ export default { ...@@ -160,7 +160,7 @@ export default {
render(h) { render(h) {
var uploadList; var uploadList;
if (this.showUploadList && !this.thumbnailMode) { if (this.showUploadList && !this.thumbnailMode && this.uploadedFiles.length) {
uploadList = ( uploadList = (
<UploadList <UploadList
files={this.uploadedFiles} files={this.uploadedFiles}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment