-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4b246aa
commit 782c3ad
Showing
36 changed files
with
1,452 additions
and
66 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
<template> | ||
<div> | ||
<vxe-table-select v-model="val1" :options="opts1" :columns="columns1"></vxe-table-select> | ||
<vxe-table-select v-model="val2" :options="opts2" :columns="columns2" multiple></vxe-table-select> | ||
</div> | ||
</template> | ||
|
||
<script lang="ts"> | ||
import Vue from 'vue' | ||
import { VxeTableSelectPropTypes } from '../../../types' | ||
export default Vue.extend({ | ||
data () { | ||
const columns1: VxeTableSelectPropTypes.Columns = [ | ||
{ field: 'name', title: 'Name' }, | ||
{ field: 'role', title: 'Role' }, | ||
{ field: 'sex', title: 'Sex' } | ||
] | ||
const opts1 = [ | ||
{ name: 'Test1', role: 'Test', sex: 'man', label: 'Test1', value: 1 }, | ||
{ name: 'Test2', role: 'Test', sex: 'man', label: 'Test2', value: 2 }, | ||
{ name: 'Test3', role: 'Test', sex: 'man', label: 'Test3', value: 3 }, | ||
{ name: 'Test4', role: 'Test', sex: 'man', label: 'Test4', value: 4 }, | ||
{ name: 'Test5', role: 'Test', sex: 'man', label: 'Test5', value: 5 }, | ||
{ name: 'Test6', role: 'Test', sex: 'man', label: 'Test6', value: 6 } | ||
] | ||
const columns2: VxeTableSelectPropTypes.Columns = [ | ||
{ field: 'name', title: 'Name' }, | ||
{ field: 'role', title: 'Role' }, | ||
{ field: 'sex', title: 'Sex' } | ||
] | ||
const opts2 = [ | ||
{ name: 'Test1', role: 'Test', sex: 'man', label: 'Test1', value: 1 }, | ||
{ name: 'Test2', role: 'Test', sex: 'man', label: 'Test2', value: 2 }, | ||
{ name: 'Test3', role: 'Test', sex: 'man', label: 'Test3', value: 3 }, | ||
{ name: 'Test4', role: 'Test', sex: 'man', label: 'Test4', value: 4 }, | ||
{ name: 'Test5', role: 'Test', sex: 'man', label: 'Test5', value: 5 }, | ||
{ name: 'Test6', role: 'Test', sex: 'man', label: 'Test6', value: 6 } | ||
] | ||
return { | ||
val1: '', | ||
columns1, | ||
opts1, | ||
val2: '', | ||
columns2, | ||
opts2 | ||
} | ||
}, | ||
methods: { | ||
tabToadEvent (params: any) { | ||
console.log(params) | ||
} | ||
} | ||
}) | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { VueConstructor } from 'vue' | ||
import { VxeUI } from '@vxe-ui/core' | ||
import VxeColorPickerComponent from './src/color-picker' | ||
import { dynamicApp } from '../dynamics' | ||
|
||
export const VxeColorPicker = Object.assign({}, VxeColorPickerComponent, { | ||
install (app: VueConstructor) { | ||
app.component(VxeColorPickerComponent.name as string, VxeColorPickerComponent) | ||
} | ||
}) | ||
|
||
dynamicApp.use(VxeColorPicker) | ||
VxeUI.component(VxeColorPickerComponent) | ||
|
||
export const ColorPicker = VxeColorPicker | ||
export default VxeColorPicker |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import { CreateElement, VNode } from 'vue' | ||
import { defineVxeComponent } from '../../ui/src/comp' | ||
import XEUtils from 'xe-utils' | ||
import { createEvent } from '../../ui' | ||
|
||
import type { ColorPickerReactData, VxeColorPickerEmits, ValueOf } from '../../../types' | ||
|
||
export default defineVxeComponent({ | ||
name: 'VxeColorPicker', | ||
props: { | ||
}, | ||
data () { | ||
const xID = XEUtils.uniqueId() | ||
const reactData: ColorPickerReactData = { | ||
} | ||
return { | ||
xID, | ||
reactData | ||
} | ||
}, | ||
methods: { | ||
// | ||
// Method | ||
// | ||
dispatchEvent (type: ValueOf<VxeColorPickerEmits>, params: Record<string, any>, evnt: Event | null) { | ||
const $xeColorPicker = this | ||
$xeColorPicker.$emit(type, createEvent(evnt, { $colorPicker: $xeColorPicker }, params)) | ||
}, | ||
|
||
// | ||
// Render | ||
// | ||
renderVN (h: CreateElement): VNode { | ||
const $xeColorPicker = this | ||
const slots = $xeColorPicker.$scopedSlots | ||
|
||
const defaultSlot = slots.default | ||
return h('div', { | ||
ref: 'refElem', | ||
class: 'vxe-color-picker' | ||
}, defaultSlot ? defaultSlot({}) : []) | ||
} | ||
}, | ||
render (this: any, h) { | ||
return this.renderVN(h) | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { VueConstructor } from 'vue' | ||
import { VxeUI } from '@vxe-ui/core' | ||
import VxeTableSelectComponent from './src/table-select' | ||
import { dynamicApp } from '../dynamics' | ||
|
||
export const VxeTableSelect = Object.assign({}, VxeTableSelectComponent, { | ||
install (app: VueConstructor) { | ||
app.component(VxeTableSelectComponent.name as string, VxeTableSelectComponent) | ||
} | ||
}) | ||
|
||
dynamicApp.use(VxeTableSelect) | ||
VxeUI.component(VxeTableSelectComponent) | ||
|
||
export const TableSelect = VxeTableSelect | ||
export default VxeTableSelect |
Oops, something went wrong.