Compare commits

...

23 Commits

Author SHA1 Message Date
Leopoldthecoder
95002f3d32 [release] 1.0.5 2016-12-06 18:47:04 +08:00
Leopoldthecoder
1ecb9d9e4e [build] 1.0.5 2016-12-06 18:47:04 +08:00
baiyaaaaa
bf9690bbcc Merge pull request #1579 from QingWei-Li/fix/deploy-script
CI: fix and test deploy script
2016-12-06 18:44:50 +08:00
Leopoldthecoder
2b3e48f82f Changelog: update for 1.0.5 2016-12-06 18:31:07 +08:00
baiyaaaaa
67a009b7a7 Merge pull request #1578 from QingWei-Li/fix/i18n-doc
doc: IgnorePlugin => NormalModuleReplacementPlugin, fixed #1315
2016-12-06 18:27:27 +08:00
baiyaaaaa
e9dcd105b3 Merge pull request #1574 from Leopoldthecoder/dev
add translation team members.
2016-12-06 18:24:57 +08:00
baiyaaaaa
8a245d6ba0 Merge pull request #1577 from QingWei-Li/timepicker/remove-flex
TimeSelect: remove flexbox style, fixed #1335
2016-12-06 18:24:30 +08:00
qingwei.li
1a5a6a6f24 CI: fix and test deploy script 2016-12-06 17:40:47 +08:00
qingwei.li
fcf412087c doc: IgnorePlugin => NormalModuleReplacementPlugin, fixed #1315 2016-12-06 17:19:47 +08:00
qingwei.li
929e7f2554 TimeSelect: remove flexbox style, fixed #1335 2016-12-06 17:16:09 +08:00
baiyaaaaa
8fe68e5385 Merge pull request #1559 from Leopoldthecoder/slider-click
Slider: avoid clicking triggering right after dragend
2016-12-06 16:56:28 +08:00
Leopoldthecoder
1c750dcec7 Slider: avoid clicking triggering right after dragend 2016-12-06 16:55:42 +08:00
baiyaaaaa
5ef3a8597b Merge pull request #1558 from Leopoldthecoder/select-fix
Select: show dropdown when options are given in remote mode
2016-12-06 16:38:08 +08:00
Leopoldthecoder
9cd6f36f1f add translation team members. 2016-12-06 16:05:38 +08:00
Jan Wirth
8a33e96eb0 Improve German locale (#1566)
German native speaker here,
did my best to improve the locale.
Could not see the actual usage of some items like select.noMatch so I hope it still matches the use case.
2016-12-06 13:15:32 +08:00
Leopoldthecoder
f3116acbbe Select: show dropdown when options are given in remote mode 2016-12-05 23:15:34 +08:00
杨奕
6e618b4c6d Select: fix async bug/fix object-typed value init issue (#1540) 2016-12-05 18:21:09 +08:00
Fábio Vedovelli
ea56806de7 Included pt-br locale (#1545) 2016-12-05 18:19:33 +08:00
baiyaaaaa
3d19de3cd5 fix steps style bug in ie9 2016-12-04 15:20:15 +08:00
baiyaaaaa
78a460ac9e make upload creat url for all file (#1530) 2016-12-04 10:21:53 +08:00
baiyaaaaa
7a85d55f31 normalize transition class name 2016-12-03 19:30:21 +08:00
杨奕
06a739ff22 Select: fix remote filter not showing dropdown issue (#1535) 2016-12-03 18:09:20 +08:00
Allen Walker
f508fd703e Col: fix a style bug about responsive layout 2016-12-03 14:01:15 +08:00
35 changed files with 278 additions and 184 deletions

View File

@@ -1,5 +1,17 @@
## Changelog
### 1.0.5
*2016-12-06*
- Fixed Select with async options and binding value displaying value instead of label, #1537
- Fixed Select reports an error when initial binding value is an empty object, #1533
- Fixed remote filtering Select not showing dropdown in some conditions, #1531
- Fixed Slider sometimes drifting a small distance after releasing dragging, #1546
- Fixed Steps style in IE9, #1543
- Added Upload generating URL for all file types, #1530
- Fixed TimeSelect style, removed flexbox, #1335
### 1.0.4
*2016-12-02*

View File

@@ -1,5 +1,16 @@
## 更新日志
### 1.0.5
*2016-12-06*
- 修复 Select 异步获取选项和绑定值时,输入框中显示 value 而不是 label 的问题,#1537
- 修复 Select 的初始值为一个空对象时会报错的问题,#1533
- 修复 Select 远程搜索有时不显示下拉框的问题,#1531
- 修复 Slider 拖动释放后,滑块有几率产生一小段位移的问题,#1546
- 修复 IE9 下 Steps 的样式问题,#1543
- 新增 Upload 对所有文件类型生成 URL 的功能,#1530
- 修复 TimeSelect 的样式,移除 flexbox, #1335
### 1.0.4
*2016-12-02*

View File

@@ -66,5 +66,18 @@ We have collected some [frequently asked questions](https://github.com/ElemeFE/e
## Contribution
Please make sure to read the [Contributing Guide](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.md) before making a pull request.
## Special Thanks
English documentation is brought to you by SwiftGG Translation Team. Our special thanks go to these fellows:
- [raychenfj](https://github.com/raychenfj)
- [kevin](http://thekevin.cn/)
- [曾小涛](https://github.com/zengxiaotao)
- [湾仔王二](https://github.com/wanzaiwanger)
- [BlooDLine](http://www.ibloodline.com/)
- [陈铭嘉](https://chenmingjia.github.io/)
- [千叶知风](http://mpc6.com/)
- [梁杰](http://numbbbbb.com)
- [Changing](https://github.com/sunzhuo11)
- [mmoaay](https://github.com/mmoaay)
## LICENSE
MIT

View File

@@ -38,8 +38,11 @@ if [ "$TRAVIS_TAG" ]; then
cd temp_web
git clone -b gh-pages https://$ROT_TOKEN@github.com/ElemeFE/element.git && cd element
# build sub folder
export SUB_FOLDER=$(echo $TRAVIS_TAG | grep -o -E '\d+\.\d+')
echo $TRAVIS_TAG
export SUB_FOLDER=$(echo "$TRAVIS_TAG" | grep -o -E "\d+\.\d+")
echo $SUB_FOLDER
SUB_FOLDER='1.0'
mkdir $SUB_FOLDER
rm -rf *.js *.css *.map static
rm -rf $SUB_FOLDER/**

View File

@@ -26,13 +26,13 @@ Vue.component(Button.name, Button)
Vue.component(Select.name, Select)
```
The Chinese language pack is imported by default, even if you're using another language. But with `IgnorePlugin` provided by webpack you can ignore it when building:
The Chinese language pack is imported by default, even if you're using another language. But with `NormalModuleReplacementPlugin` provided by webpack you can replace default locale:
webpack.config.js
```javascript
{
plugins: [
new webpack.IgnorePlugin(/element-ui\/lib\/locale\/lang\/zh-CN/)
new webpack.NormalModuleReplacementPlugin(/element-ui[\/\\]lib[\/\\]locale[\/\\]lang[\/\\]zh-CN/, 'element-ui/lib/locale/lang/en')
]
}
```
@@ -51,6 +51,11 @@ Currently Element ships with the following languages:
<li>Italian (it)</li>
<li>Korean (ko)</li>
<li>Japanese (ja)</li>
<li>Dutch (nl)</li>
<li>Vietnamese (vi)</li>
<li>Russian (ru-RU)</li>
<li>Turkish (tr-TR)</li>
<li>Brazilian Portuguese (pt-br)</li>
</ul>
If your target language is not included, you are more than welcome to contribute: just add another language config [here](https://github.com/ElemeFE/element/tree/master/src/locale/lang) and create a pull request.

View File

@@ -245,6 +245,7 @@ The corresponding methods are: `MessageBox`, `MessageBox.alert`, `MessageBox.con
| title | title of the MessageBox | string | — | — |
| message | content of the MessageBox | string | — | — |
| type | message type, used for icon display | string | success/info/<br>warning/error | — |
| callback | MessageBox closing callback if you don't prefer Promise | function(action), where action can be 'confirm' or 'cancel' | — | — |
| lockScroll | whether to lock body scroll when MessageBox prompts | boolean | — | true |
| showCancelButton | whether to show a cancel button | boolean | — | false (true when called with confirm and prompt) |
| showConfirmButton | whether to show a confirm button | boolean | — | true |

View File

@@ -38,13 +38,13 @@ Vue.component(Button.name, Button)
Vue.component(Select.name, Select)
```
如果使用其它语言,默认情况下中文语言包依旧是被引入的,可以使用 webpack 的 IgnorePlugin 忽略掉它以减少打包后的文件体积
如果使用其它语言,默认情况下中文语言包依旧是被引入的,可以使用 webpack 的 NormalModuleReplacementPlugin 替换默认语言包
**webpack.config.js**
```javascript
{
plugins: [
new webpack.IgnorePlugin(/element-ui\/lib\/locale\/lang\/zh-CN/)
new webpack.NormalModuleReplacementPlugin(/element-ui[\/\\]lib[\/\\]locale[\/\\]lang[\/\\]zh-CN/, 'element-ui/lib/locale/lang/en')
]
}
```
@@ -63,6 +63,11 @@ Vue.component(Select.name, Select)
<li>意大利语it</li>
<li>韩语ko</li>
<li>日语ja</li>
<li>荷兰语nl</li>
<li>越南语vi</li>
<li>俄语ru-RU</li>
<li>土耳其语tr-TR</li>
<li>巴西葡萄牙语pt-br</li>
</ul>
如果你需要使用其他的语言,欢迎贡献 PR只需在 [这里](https://github.com/ElemeFE/element/tree/master/src/locale/lang) 添加一个语言配置文件即可。

View File

@@ -242,6 +242,7 @@ import { MessageBox } from 'element-ui';
| title | MessageBox 标题 | string | — | — |
| message | MessageBox 消息正文内容 | string | — | — |
| type | 消息类型,用于显示图标 | string | success/info/<br>warning/error | — |
| callback | 若不使用 Promise可以使用此参数指定 MessageBox 关闭后的回调 | function(action)action 的值为'confirm'或'cancel' | — | — |
| lockScroll | 是否在 MessageBox 出现时将 body 滚动锁定 | boolean | — | true |
| showCancelButton | 是否显示取消按钮 | boolean | — | false以 confirm 和 prompt 方式调用时为 true |
| showConfirmButton | 是否显示确定按钮 | boolean | — | true |

View File

@@ -1,6 +1,6 @@
{
"name": "element-ui",
"version": "1.0.4",
"version": "1.0.5",
"description": "A Component Library for Vue.js.",
"main": "lib/element-ui.common.js",
"files": [

View File

@@ -19,7 +19,7 @@
<slot name="append"></slot>
</template>
</el-input>
<transition name="md-fade-bottom">
<transition name="el-zoom-in-top">
<ul
v-if="suggestionVisible"
class="el-autocomplete__suggestions"

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom" @after-leave="$emit('dodestroy')">
<transition name="el-zoom-in-top" @after-leave="$emit('dodestroy')">
<div
v-show="visible"
:style="{ width: width + 'px' }"

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom" @after-leave="$emit('dodestroy')">
<transition name="el-zoom-in-top" @after-leave="$emit('dodestroy')">
<div
v-show="visible"
:style="{

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom" @after-leave="$emit('dodestroy')">
<transition name="el-zoom-in-top" @after-leave="$emit('dodestroy')">
<div
v-show="visible"
:style="{ width: width + 'px' }"

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom" @after-leave="$emit('dodestroy')">
<transition name="el-zoom-in-top" @after-leave="$emit('dodestroy')">
<div
v-show="visible"
:style="{ width: width + 'px' }"

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom" @after-leave="$emit('dodestroy')">
<transition name="el-zoom-in-top" @after-leave="$emit('dodestroy')">
<div
v-show="currentVisible"
:style="{width: width + 'px'}"

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom" @after-leave="doDestroy">
<transition name="el-zoom-in-top" @after-leave="doDestroy">
<ul class="el-dropdown-menu" v-show="showPopper">
<slot></slot>
</ul>

View File

@@ -9,7 +9,7 @@
</label>
<div class="el-form-item__content" v-bind:style="contentStyle">
<slot></slot>
<transition name="md-fade-bottom">
<transition name="el-zoom-in-top">
<div class="el-form-item__error" v-if="validateState === 'error'">{{validateMessage}}</div>
</transition>
</div>

View File

@@ -16,7 +16,7 @@
}">
</i>
</div>
<transition :name="rootMenu.mode === 'horizontal' ? 'md-fade-bottom' : ''">
<transition :name="rootMenu.mode === 'horizontal' ? 'el-zoom-in-top' : ''">
<ul class="el-menu" v-show="opened"><slot></slot></ul>
</transition>
</li>

View File

@@ -59,7 +59,7 @@
@mouseleave.native="inputHovering = false"
:icon="iconClass">
</el-input>
<transition name="md-fade-bottom" @after-leave="doDestroy">
<transition name="el-zoom-in-top" @after-leave="doDestroy">
<el-select-menu
ref="popper"
v-show="visible && emptyText !== false">
@@ -129,11 +129,8 @@
if (this.loading) {
return this.t('el.select.loading');
} else {
if (this.voidRemoteQuery) {
this.voidRemoteQuery = false;
return false;
}
if (this.filterable && this.filteredOptionsCount === 0) {
if (this.remote && this.query === '' && this.options.length === 0) return false;
if (this.filterable && this.options.length > 0 && this.filteredOptionsCount === 0) {
return this.t('el.select.noMatch');
}
if (this.options.length === 0) {
@@ -198,7 +195,6 @@
selectedLabel: '',
hoverIndex: -1,
query: '',
voidRemoteQuery: false,
bottomOverflowBeforeHidden: 0,
topOverflowBeforeHidden: 0,
optionsAllDisabled: false,
@@ -215,7 +211,7 @@
value(val) {
if (this.multiple) {
this.resetInputHeight();
if (val.length > 0) {
if (val.length > 0 || (this.$refs.input && this.query !== '')) {
this.currentPlaceholder = '';
} else {
this.currentPlaceholder = this.cachedPlaceHolder;
@@ -238,7 +234,6 @@
if (this.remote && typeof this.remoteMethod === 'function') {
this.hoverIndex = -1;
this.remoteMethod(val);
this.voidRemoteQuery = val === '';
this.broadcast('ElOption', 'resetIndex');
} else if (typeof this.filterMethod === 'function') {
this.filterMethod(val);
@@ -259,9 +254,16 @@
this.query = '';
this.selectedLabel = '';
this.resetHoverIndex();
this.$nextTick(() => {
if (this.$refs.input &&
this.$refs.input.value === '' &&
this.selected.length === 0) {
this.currentPlaceholder = this.cachedPlaceHolder;
}
});
if (!this.multiple) {
this.getOverflows();
if (this.selected && this.selected.value) {
if (this.selected) {
this.selectedLabel = this.selected.currentLabel;
}
}
@@ -291,6 +293,10 @@
if (this.multiple) {
this.resetInputHeight();
}
let inputs = this.$el.querySelectorAll('input');
if ([].indexOf.call(inputs, document.activeElement) === -1) {
this.selected = this.getSelected();
}
}
},
@@ -330,26 +336,31 @@
}
},
getOption(value) {
const option = this.options.filter(option => option.value === value)[0];
if (option) return option;
const label = typeof value === 'string' || typeof value === 'number'
? value : '';
let newOption = {
value: value,
currentLabel: label
};
if (this.multiple) {
newOption.hitState = false;
}
return newOption;
},
getSelected() {
if (!this.multiple) {
let option = this.options.filter(option => option.value === this.value)[0] ||
{ value: this.value, currentLabel: this.value };
let option = this.getOption(this.value);
this.selectedLabel = option.currentLabel;
return option;
}
let result = [];
if (Array.isArray(this.value)) {
this.value.forEach(value => {
let option = this.options.filter(option => option.value === value)[0];
if (option) {
result.push(option);
} else {
result.push({
value: this.value,
currentLabel: value,
hitState: false
});
}
result.push(this.getOption(value));
});
}
return result;
@@ -560,12 +571,9 @@
if (this.multiple && !Array.isArray(this.value)) {
this.$emit('input', []);
}
if (!this.multiple && (!this.value || Array.isArray(this.value))) {
if (!this.multiple && Array.isArray(this.value)) {
this.$emit('input', '');
}
if (this.remote) {
this.voidRemoteQuery = true;
}
this.debouncedOnInputChange = debounce(this.debounce, () => {
this.onInputChange();

View File

@@ -157,7 +157,7 @@
},
onSliderClick(event) {
if (this.disabled) return;
if (this.disabled || this.dragging) return;
const sliderOffsetLeft = this.$refs.slider.getBoundingClientRect().left;
this.setPosition((event.clientX - sliderOffsetLeft) / this.$sliderWidth * 100);
},
@@ -189,7 +189,13 @@
onDragEnd() {
if (this.dragging) {
this.dragging = false;
/*
* 防止在 mouseup 后立即触发 click导致滑块有几率产生一小段位移
* 不使用 preventDefault 是因为 mouseup 和 click 没有注册在同一个 DOM 上
*/
setTimeout(() => {
this.dragging = false;
}, 0);
this.$refs.tooltip.showPopper = false;
this.setPosition(this.newPos);
window.removeEventListener('mousemove', this.onDragging);

View File

@@ -1,5 +1,5 @@
<template>
<transition name="md-fade-bottom">
<transition name="el-zoom-in-top">
<div class="el-table-filter" v-if="multiple" v-show="showPopper">
<div class="el-table-filter__content">
<el-checkbox-group class="el-table-filter__checkbox-group" v-model="filteredValue">

View File

@@ -1,5 +1,5 @@
<template>
<transition :name="closeTransition ? '' : 'md-fade-center'">
<transition :name="closeTransition ? '' : 'el-zoom-in-center'">
<span
class="el-tag"
:class="[type ? 'el-tag--' + type : '', {'is-hit': hit}]">

View File

@@ -1,6 +1,6 @@
{
"name": "element-theme-default",
"version": "1.0.4",
"version": "1.0.5",
"description": "Element component default theme.",
"main": "lib/index.css",
"style": "lib/index.css",

View File

@@ -32,14 +32,14 @@
.el-col-sm-$i {
width: calc(1 / 24 * $(i) * 100)%;
}
.el-col-xs-offset-$i {
.el-col-sm-offset-$i {
margin-left: calc(1 / 24 * $(i) * 100)%;
}
.el-col-xs-pull-$i {
.el-col-sm-pull-$i {
position: relative;
right: calc(1 / 24 * $(i) * 100)%;
}
.el-col-xs-push-$i {
.el-col-sm-push-$i {
position: relative;
left: calc(1 / 24 * $(i) * 100)%;
}
@@ -68,14 +68,14 @@
.el-col-lg-$i {
width: calc(1 / 24 * $(i) * 100)%;
}
.el-col-xs-offset-$i {
.el-col-lg-offset-$i {
margin-left: calc(1 / 24 * $(i) * 100)%;
}
.el-col-xs-pull-$i {
.el-col-lg-pull-$i {
position: relative;
right: calc(1 / 24 * $(i) * 100)%;
}
.el-col-xs-push-$i {
.el-col-lg-push-$i {
position: relative;
left: calc(1 / 24 * $(i) * 100)%;
}

View File

@@ -5,109 +5,53 @@
.fade-in-linear-leave-active {
transition: var(--fade-linear-transition);
}
.fade-in-linear-enter,
.fade-in-linear-leave,
.fade-in-linear-leave-active {
opacity: 0;
}
.fade-in-enter-active,
.fade-in-leave-active {
.el-fade-in-enter-active,
.el-fade-in-leave-active {
transition: all .3s cubic-bezier(.55,0,.1,1);
}
.fade-in-enter,
.fade-in-leave-active {
.el-fade-in-enter,
.el-fade-in-leave-active {
opacity: 0;
}
.md-fade-center-enter-active,
.md-fade-center-leave-active {
.el-zoom-in-center-enter-active,
.el-zoom-in-center-leave-active {
transition: all .3s cubic-bezier(.55,0,.1,1);
}
.md-fade-center-enter,
.md-fade-center-leave,
.md-fade-center-leave-active {
.el-zoom-in-center-enter,
.el-zoom-in-center-leave-active {
opacity: 0;
transform: scaleY(0);
transform: scaleX(0);
}
.md-fade-bottom-enter-active,
.md-fade-bottom-leave-active {
.el-zoom-in-top-enter-active,
.el-zoom-in-top-leave-active {
opacity: 1;
transform: scaleY(1);
transition: var(--md-fade-transition);
transform-origin: center top;
}
.md-fade-bottom-enter,
.md-fade-bottom-leave,
.md-fade-bottom-leave-active {
.el-zoom-in-top-enter,
.el-zoom-in-top-leave-active {
opacity: 0;
transform: scaleY(0);
}
.md-fade-top-enter-active,
.md-fade-top-leave-active {
.el-zoom-in-bottom-enter-active,
.el-zoom-in-bottom-leave-active {
opacity: 1;
transform: scaleY(1);
transition: var(--md-fade-transition);
transform-origin: center bottom;
}
.md-fade-top-enter,
.md-fade-top-leave,
.md-fade-top-leave-active {
.el-zoom-in-bottom-enter,
.el-zoom-in-bottom-leave-active {
opacity: 0;
transform: scaleY(0);
}
.md-fade-left-enter-active,
.md-fade-left-leave-active {
opacity: 1;
transform: scaleX(1);
transition: var(--md-fade-transition);
transform-origin: right center;
}
.md-fade-left-enter,
.md-fade-left-leave,
.md-fade-left-leave-active {
opacity: 0;
transform: scaleX(0);
}
.md-fade-right-enter-active,
.md-fade-right-leave-active {
opacity: 1;
transform: scaleX(1);
transition: var(--md-fade-transition);
transform-origin: left center;
}
.md-fade-right-enter,
.md-fade-right-leave,
.md-fade-right-leave-active {
opacity: 0;
transform: scaleX(0);
}
.fade-enter-active,
.fade-leave-active {
transition: opacity .3s cubic-bezier(.645,.045,.355,1);
}
.fade-enter,
.fade-leave-active {
opacity: 0;
}
.list-move, .list-enter-active, .list-leave-active {
transition: all .5s cubic-bezier(.55,0,.1,1);
}
.list-enter, .list-leave-active {
opacity: 0;
transform: translate(0, -30px);
}
/*.list-leave-active {
position: absolute;
opacity: 0;
transform: scaleY(0.01) translate(30px, 0);
}*/

View File

@@ -15,7 +15,6 @@
@e content {
font-size: 0;
display: flex;
position: relative;
overflow: hidden;

View File

@@ -9,14 +9,14 @@
position: relative;
text-align: center;
padding: 10px;
display: flex;
}
@e cell {
box-sizing: border-box;
margin: 0;
padding: 4px 7px 7px;
flex: 1;
width: 50%;
display: inline-block;
}
@e header {
@@ -26,7 +26,6 @@
}
@e body {
display: flex;
border-radius:2px;
border: 1px solid var(--datepicker-border-color);
}

View File

@@ -5,7 +5,8 @@
@e wrapper {
height: 190px;
overflow: hidden;
flex: 1;
display: inline-block;
width: calc(100% / 3);
vertical-align: top;
position: relative;
-ms-overflow-style: none;

View File

@@ -3,8 +3,8 @@
@component-namespace el {
@b time-spinner {
display: flex;
width: 100%;
white-space: nowrap;
}
@b spinner {

View File

@@ -36,20 +36,21 @@
@when horizontal {
top: 15px;
height: 2px;
left: 30px;
left: 32px;
right: 0;
}
@when vertical {
width: 2px;
box-sizing: border-box;
top: 30px;
top: 32px;
bottom: 0;
left: 15px;
}
}
@e line-inner {
display: inherit;
display: block;
border-width: 1px;
border-style: solid;
border-color: inherit;

View File

@@ -1,6 +1,6 @@
<template>
<div class="el-dragger__cover" @click.stop v-if="image">
<transition name="fade-in">
<transition name="el-fade-in">
<el-progress
class="el-dragger__cover__progress"
v-if="image.status === 'uploading'"
@@ -16,7 +16,7 @@
@mouseleave="mouseover = false"
>
<img :src="image.url">
<transition name="fade-in">
<transition name="el-fade-in">
<div v-show="mouseover" class="el-dragger__cover__interact">
<div class="el-draggeer__cover__btns">
<span class="btn" @click="$parent.handleClick()"><i class="el-icon-upload2"></i><span>{{ t('el.upload.continue') }}</span></span>
@@ -25,7 +25,7 @@
</div>
</div>
</transition>
<transition name="md-fade-top">
<transition name="el-zoom-in-bottom">
<h4 v-show="mouseover" class="el-dragger__cover__title">{{image.name}}</h4>
</transition>
</div>

View File

@@ -83,6 +83,20 @@ export default {
};
},
watch: {
defaultFileList: {
immediate: true,
handler(fileList) {
this.fileList = fileList.map(item => {
item.status = 'finished';
item.percentage = 100;
item.uid = Date.now() + this.tempIndex++;
return item;
});
}
}
},
methods: {
handleStart(file) {
file.uid = Date.now() + this.tempIndex++;
@@ -95,13 +109,11 @@ export default {
showProgress: true
};
if (this.thumbnailMode) {
try {
_file.url = URL.createObjectURL(file);
} catch (err) {
console.log(err);
return;
}
try {
_file.url = URL.createObjectURL(file);
} catch (err) {
console.error(err);
return;
}
this.fileList.push(_file);
@@ -158,20 +170,6 @@ export default {
}
},
watch: {
defaultFileList: {
immediate: true,
handler(fileList) {
this.fileList = fileList.map(item => {
item.status = 'finished';
item.percentage = 100;
item.uid = Date.now() + this.tempIndex++;
return item;
});
}
}
},
render(h) {
var uploadList;

View File

@@ -131,7 +131,7 @@ if (typeof window !== 'undefined' && window.Vue) {
};
module.exports = {
version: '1.0.4',
version: '1.0.5',
locale: locale.use,
install,
Loading,

View File

@@ -1,18 +1,21 @@
export default {
el: {
datepicker: {
now: 'jetzt',
today: 'heute',
cancel: 'abbrechen',
clear: 'leeren',
now: 'Jetzt',
today: 'Heute',
cancel: 'Abbrechen',
clear: 'Leeren',
confirm: 'OK',
selectDate: 'Datum wählen',
selectTime: 'Zeit wählen',
selectTime: 'Uhrzeit wählen',
startDate: 'Startdatum',
startTime: 'Startzeit',
endDate: 'Enddatum',
endTime: 'Endzeit',
year: '',
day: 'Tag',
week: 'Woche',
month: 'Monat',
year: 'Jahr',
month1: 'Januar',
month2: 'Februar',
month3: 'März',
@@ -24,8 +27,7 @@ export default {
month9: 'September',
month10: 'Oktober',
month11: 'November',
month12: 'Dezmeber',
// week: 'Woche',
month12: 'Dezember',
weeks: {
sun: 'So',
mon: 'Mo',
@@ -51,35 +53,35 @@ export default {
}
},
select: {
loading: 'es lädt',
noMatch: 'nicht gefunden',
noData: 'keine Datei',
placeholder: 'wählen'
loading: 'Lädt.',
noMatch: 'Nichts gefunden.',
noData: 'Keine Datei',
placeholder: 'Datei wählen'
},
pagination: {
goto: 'zu',
pagesize: '/Seite',
total: 'gesamt {total}',
goto: 'Gehe zu',
pagesize: 'pro Seite',
total: 'Gesamt {total}',
pageClassifier: ''
},
messagebox: {
confirm: 'OK',
cancel: 'abbrechen',
cancel: 'Abbrechen',
error: 'Fehler'
},
upload: {
delete: 'löschen',
preview: 'vorschauen',
continue: 'weiter hochzuladen'
delete: 'Löschen',
preview: 'Vorschau',
continue: 'Fortsetzen'
},
table: {
emptyText: 'keine Daten',
confirmFilter: 'filtern',
resetFilter: 'rücksetzen',
clearFilter: 'alles'
emptyText: 'Keine Daten',
confirmFilter: 'Anwenden',
resetFilter: 'Zurücksetzen',
clearFilter: 'Alles '
},
tree: {
emptyText: 'keine Daten'
emptyText: 'Keine Daten'
}
}
};

85
src/locale/lang/pt-br.js Normal file
View File

@@ -0,0 +1,85 @@
export default {
el: {
datepicker: {
now: 'Agora',
today: 'Hoje',
cancel: 'Cancelar',
clear: 'Limpar',
confirm: 'Confirmar',
selectDate: 'Selecione a data',
selectTime: 'Selecione a hora',
startDate: 'Data inicial',
startTime: 'Hora inicial',
endDate: 'Data final',
endTime: 'Hora final',
year: 'Ano',
month1: 'Janeiro',
month2: 'Fevereiro',
month3: 'Março',
month4: 'Abril',
month5: 'Maio',
month6: 'Junho',
month7: 'Julho',
month8: 'Agosto',
month9: 'Setembro',
month10: 'Outubro',
month11: 'Novembro',
month12: 'Dezembro',
// week: 'semana',
weeks: {
sun: 'Dom',
mon: 'Seg',
tue: 'Ter',
wed: 'Qua',
thu: 'Qui',
fri: 'Sex',
sat: 'Sab'
},
months: {
jan: 'Jan',
feb: 'Fev',
mar: 'Mar',
apr: 'Abr',
may: 'Mai',
jun: 'Jun',
jul: 'Jul',
aug: 'Ago',
sep: 'Set',
oct: 'Out',
nov: 'Nov',
dec: 'Dez'
}
},
select: {
loading: 'Carregando',
noMatch: 'Sem resultados',
noData: 'Sem dados',
placeholder: 'Selecione'
},
pagination: {
goto: 'Ir para',
pagesize: '/pagina',
total: 'Total {total}',
pageClassifier: ''
},
messagebox: {
confirm: 'Confirmar',
cancel: 'Cancelar',
error: 'Erro!'
},
upload: {
delete: 'Apagar',
preview: 'Previsualizar',
continue: 'Continuar'
},
table: {
emptyText: 'Sem dados',
confirmFilter: 'Confirmar',
resetFilter: 'Limpar',
clearFilter: 'Todos'
},
tree: {
emptyText: 'Sem dados'
}
}
};