让企业管理更智慧、更快捷

Skip to content
源代码提交(4)
## [1.0.8](http://git.leadwaycloud.com/package/lwc-ui-components/compare/v1.0.7...v1.0.8) (2022-08-31)
### Bug Fixes
* 修复table插槽字段错误问题 ([9116570](http://git.leadwaycloud.com/package/lwc-ui-components/commits/91165702ae4e0e25d7d1936fb4c59861375cd85d))
### Features
* 增加下拉弹窗直接筛选功能 ([7043886](http://git.leadwaycloud.com/package/lwc-ui-components/commits/70438865ae6e4ed2846a0957c75730f819815e0c))
## [1.0.7](http://git.leadwaycloud.com/package/lwc-ui-components/compare/v1.0.6...v1.0.7) (2022-08-12)
......
{
"name": "@package/lwc-ui-components",
"version": "1.0.8",
"version": "1.0.9",
"private": false,
"description": "立威云UI组件库",
"author": "",
......
......@@ -209,7 +209,7 @@ if (typeof window !== 'undefined' && window.Vue) {
}
export default {
version: '1.0.7',
version: '1.0.8',
install,
LwcBasicButton,
LwcBasicButtonIcon,
......
......@@ -9,7 +9,18 @@
`非兼容性更新`
---
### **v1.0.6 20220812**
### **v1.0.8 20220831**
#### 新增
- 新增 lwc-select-down-table 组件 筛选功能
#### Bug修复
- 修复 lwc-table-basic 组件 slots插槽字段错误导致插槽不生效问题
---
### **v1.0.7 20220812**
#### Bug修复
......
function renderStepsList (h, _vm) {
const activeColor = "#21b799"
const borderColor = "rgba(0,0,0, 0.15)"
if(_vm.data && _vm.data.length > 0) {
let styleObj = {
......@@ -36,7 +35,7 @@ function renderStepsList (h, _vm) {
const isActive = step[_vm.dataConfig.value] === _vm.value
return h('div', {
class: ['flex-grow text-color-secondary relative step-div', {
'text-white bg-theme-primary': isActive
'text-theme-basic bg-theme-primary': isActive
}]
}, [
h("div", {
......@@ -62,10 +61,11 @@ function renderStepsList (h, _vm) {
}
}, step[_vm.dataConfig.name]),
(index < _vm.data.length - 1) ? h('span', {
class: isActive ? 'border-theme-primary' : "",
style: Object.assign({
right: `-${sizeStyle / 2}px`
}, styleObj, sizeWidth, {
"border-left-color": isActive ? activeColor : "#fff",
"border-left-color": isActive ? '' : "#fff",
"z-index": 2
})
}) : null
......
......@@ -64,9 +64,13 @@ export default {
render(h) {
const { status, color, inherit, name, size, spin } = this.$props
const sizes = { medium: 24, small: 20, mini: 16 } // 大小设置
let styleColor = textColor[color] || textColor[`theme-${status}`] || textColor['color-primary'];
if (inherit) {
styleColor = 'auto'
// let styleColor = textColor[color] || textColor[`theme-${status}`] || textColor['color-primary'];
// if (inherit) {
// styleColor = 'auto'
// }
let classColor = color || (status ? `text-theme-${status}` : 'text-color-primary' )
if (inherit) {
classColor = ''
}
/* 颜色设置 如果不设置fill属性,则可以跟随父级设置颜色 */
......@@ -80,9 +84,10 @@ export default {
strokeWidth: 3,
spin: spin
},
style: {
color: styleColor
}
class: classColor
// style: {
// color: styleColor
// }
}
);
}
......
......@@ -200,7 +200,7 @@ DefaultList.args = {
left: ({ $grid }, h) => {
const { $createElement } = $grid
return $createElement('div', {
class: ['left-4', 'absolute', 'top-2/4', '-translate-y-1/2'],
class: ['left-4', 'absolute' ],
style: { left: '12px' }
}, [
$createElement('el-button', {
......
......@@ -26,16 +26,18 @@ function renderTimeLineItem(h, _vm) {
class: "h-8 leading-8 overflow-hidden relative"
}, [
h("span", {
class: "relative align-middle",
class: "relative align-middle border-theme-primary",
style: {
"margin-left": "-1rem",
"font-size": 0,
border: "1rem solid",
"border-color": "transparent #21b799 transparent transparent"
"border-width": "1rem",
"border-left-color": "transparent",
"border-top-color": "transparent",
"border-bottom-color": "transparent"
}
}),
h("span", {
class: "inline-block leading-8 bg-theme-primary text-white text-sm h-full pl-2 pr-3"
class: "inline-block leading-8 bg-theme-primary text-theme-basic text-sm h-full pl-2 pr-3"
}, dayjsTime.format('YYYY') === dayjs().format('YYYY') ? dayjsTime.format('MM-DD') : dayjsTime.format('YYYY-MM-DD'))
])
}
......
......@@ -116,7 +116,7 @@ Action.args = {
export const ServerNew = Template.bind({});
ServerNew.storyName = "服务器上传(新)"
ServerNew.args = {
cropper: false,
cropper: true,
type: "action",
accept: "image/*",
limit: null,
......
import { Feiyu } from '@package/icon-park';
import { VueCropper } from 'vue-cropper';
/**
......@@ -358,7 +359,8 @@ export default {
imageUrl: "",
previewDialog: false,
previewUrl: null,
fileList: []
fileList: [],
customFile: null
}
},
/**
......@@ -390,7 +392,7 @@ export default {
} else {
self.fileList.push(file.file)
}
self.customFile = file
// 开启截图
if (self.cropper && !self.multiple) {
self.$nextTick(() => {
......@@ -462,7 +464,12 @@ export default {
// 上传服务器
this.$refs.cropper.getCropBlob((data) => {
if(this.type === 'action') {
this.sendToServer(data)
const { file, action } = this.customFile
this.sendToServer({
name: file.name,
action,
file: this.blobToFile(data, file.name)
})
} else {
this.$refs.cropper.getCropData((base) => {
this.$emit('change', {
......@@ -476,6 +483,10 @@ export default {
}
},
blobToFile(blob, fileName) {
let files = new window.File([blob], fileName, { type: blob.type })
return files
},
/**
* @Author: dy
* @Date: 2021-03-22 11:46:37
......@@ -488,7 +499,6 @@ export default {
let xhr = new XMLHttpRequest()
let fd = new FormData()
fd.append(name || 'image', blob, blob.name)
if (data) {
for(let key in data) {
fd.append(key, data[key])
......
......@@ -35,6 +35,7 @@ module.exports = {
colors: {
"theme-main": "#a24689",
'theme-primary': "#21b799",
'theme-basic': "#ffffff",
'theme-success': "#67C23A",
'theme-warning': "#E6A23C",
'theme-danger': "#F56C6C",
......