kui-vue 3.4.4-a → 3.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/avatar/AvatarGroup.jsx +1 -1
- package/components/base/input.jsx +2 -2
- package/components/button/button.jsx +6 -3
- package/components/button/demo/disabled.md +5 -5
- package/components/button/demo/light.md +0 -1
- package/components/button/demo/size.md +12 -13
- package/components/button/index.md +12 -9
- package/components/button/styles/index.less +5 -2
- package/components/datePicker/styles/datepicker.less +2 -0
- package/components/flex/demo/align.md +37 -0
- package/components/flex/demo/base.md +27 -0
- package/components/flex/demo/index.vue +23 -0
- package/components/flex/demo/info.md +14 -0
- package/components/flex/demo/size.md +46 -0
- package/components/flex/demo/wrap.md +26 -0
- package/components/flex/flex.jsx +50 -0
- package/components/flex/index.js +2 -0
- package/components/flex/index.md +8 -0
- package/components/flex/styles/index.less +54 -0
- package/components/form/styles/index.less +2 -4
- package/components/icon/demo/search.vue +18 -27
- package/components/index.js +4 -2
- package/components/input/demo/group.md +106 -0
- package/components/input/demo/index.vue +2 -0
- package/components/input/demo/suffix.md +5 -10
- package/components/input/index.js +2 -1
- package/components/input/inputGroup.jsx +63 -0
- package/components/input/styles/index.less +59 -5
- package/components/inputNumber/styles/index.less +0 -1
- package/components/radio/group.jsx +12 -0
- package/components/select/styles/index.less +2 -2
- package/components/slider/slider.jsx +6 -2
- package/components/space/demo/align.md +25 -23
- package/components/space/demo/compact-button-vertical.md +56 -0
- package/components/space/demo/compact-button.md +60 -0
- package/components/space/demo/compact.md +106 -0
- package/components/space/demo/custom-size.md +0 -2
- package/components/space/demo/index.vue +11 -3
- package/components/space/demo/split.md +15 -0
- package/components/space/demo/wrap.md +2 -2
- package/components/space/index.md +9 -6
- package/components/space/space.jsx +57 -35
- package/components/space/styles/index.less +67 -9
- package/components/styles/index.less +1 -0
- package/components/styles/sys.less +11 -1
- package/components/tooltip/styles/index.less +0 -1
- package/dist/k-ui.css +2 -2
- package/dist/k-ui.js +2 -2
- package/package.json +1 -1
|
@@ -117,9 +117,9 @@ export default {
|
|
|
117
117
|
},
|
|
118
118
|
getSuffix() {
|
|
119
119
|
let { $listeners, suffix } = this
|
|
120
|
-
const SearchNode = ('search' in $listeners) ? <Icon type={Search} class="k-input-icon
|
|
120
|
+
const SearchNode = ('search' in $listeners) ? <Icon type={Search} class="k-input-search-icon" onClick={this.searchEvent} /> : null
|
|
121
121
|
|
|
122
|
-
const Password = (this.type == 'password') ? <Icon type={!this.isPassword ? EyeOutline : EyeOffOutline} onClick={this.showPassword} /> : null
|
|
122
|
+
const Password = (this.type == 'password') ? <Icon class="k-input-password-icon" type={!this.isPassword ? EyeOutline : EyeOffOutline} onClick={this.showPassword} /> : null
|
|
123
123
|
|
|
124
124
|
return Password || SearchNode || this.$slots.suffix || (suffix ? <div class="k-input-suffix">{suffix}</div> : null)
|
|
125
125
|
},
|
|
@@ -35,7 +35,9 @@ export default {
|
|
|
35
35
|
return ['default', 'light', 'solid', 'normal', 'card'].indexOf(value) > -1
|
|
36
36
|
}
|
|
37
37
|
},
|
|
38
|
-
shape: String
|
|
38
|
+
shape: String,
|
|
39
|
+
href: String,
|
|
40
|
+
target: String
|
|
39
41
|
},
|
|
40
42
|
methods: {
|
|
41
43
|
click(e) {
|
|
@@ -46,7 +48,7 @@ export default {
|
|
|
46
48
|
},
|
|
47
49
|
|
|
48
50
|
render() {
|
|
49
|
-
const { $slots, $attrs, size, disabled, click, theme,
|
|
51
|
+
const { $slots, $attrs, size, disabled, click, theme, href, target,
|
|
50
52
|
shape, htmlType, icon, loading, $listeners, type, block } = this
|
|
51
53
|
const onlyIcon = !getChild($slots.default, 'Drop').length && icon
|
|
52
54
|
const classes = [
|
|
@@ -76,7 +78,8 @@ export default {
|
|
|
76
78
|
const childs = child.map(c => {
|
|
77
79
|
return typeof c.text == 'string' ? <span>{c.text.trim()}</span> : c
|
|
78
80
|
})
|
|
79
|
-
|
|
81
|
+
const is_link = type == 'link' && href
|
|
82
|
+
return is_link ? <a href={href} target={target} {...props}>{iconNode}{childs}</a> : <button {...props} >
|
|
80
83
|
{iconNode}
|
|
81
84
|
{childs}
|
|
82
85
|
</button >
|
|
@@ -7,31 +7,31 @@
|
|
|
7
7
|
<template>
|
|
8
8
|
<Space>
|
|
9
9
|
<Button type="primary">Primary</Button>
|
|
10
|
-
<Button disabled type="primary">disabled</Button>
|
|
10
|
+
<Button disabled type="primary">Primary(disabled)</Button>
|
|
11
11
|
</Space>
|
|
12
12
|
<br/>
|
|
13
13
|
<br/>
|
|
14
14
|
<Space>
|
|
15
15
|
<Button type="danger">Danger</Button>
|
|
16
|
-
<Button type="danger" disabled>Danger</Button>
|
|
16
|
+
<Button type="danger" disabled>Danger(disabled)</Button>
|
|
17
17
|
</Space>
|
|
18
18
|
<br/>
|
|
19
19
|
<br/>
|
|
20
20
|
<Space>
|
|
21
21
|
<Button>Default</Button>
|
|
22
|
-
<Button disabled>Default</Button>
|
|
22
|
+
<Button disabled>Default(disabled)</Button>
|
|
23
23
|
</Space>
|
|
24
24
|
<br/>
|
|
25
25
|
<br/>
|
|
26
26
|
<Space>
|
|
27
27
|
<Button type="dashed">Dashed</Button>
|
|
28
|
-
<Button disabled type="dashed">Dashed</Button>
|
|
28
|
+
<Button disabled type="dashed">Dashed(disabled)</Button>
|
|
29
29
|
</Space>
|
|
30
30
|
<br/>
|
|
31
31
|
<br/>
|
|
32
32
|
<Space>
|
|
33
33
|
<Button type="link">Link</Button>
|
|
34
|
-
<Button disabled type="link">Link</Button>
|
|
34
|
+
<Button disabled type="link">Link(disabled)</Button>
|
|
35
35
|
</Space>
|
|
36
36
|
</template>
|
|
37
37
|
```
|
|
@@ -5,24 +5,23 @@
|
|
|
5
5
|
|
|
6
6
|
```vue
|
|
7
7
|
<template>
|
|
8
|
-
<Space>
|
|
8
|
+
<Space vertical align="start">
|
|
9
9
|
<RadioGroup v-model="size">
|
|
10
10
|
<RadioButton value="large" label="Large"/>
|
|
11
11
|
<RadioButton value="default" label="Default"/>
|
|
12
12
|
<RadioButton value="small" label="Small"/>
|
|
13
13
|
</RadioGroup>
|
|
14
|
-
<
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
14
|
+
<Space>
|
|
15
|
+
<Button type="primary" :size="size">Primary</Button>
|
|
16
|
+
<Button :size="size">Default</Button>
|
|
17
|
+
<Button type="dashed" :size="size">Dashed</Button>
|
|
18
|
+
<Button type="link" :size="size">Link</Button>
|
|
19
|
+
<br/>
|
|
20
|
+
<Button type="primary" :size="size" :icon="CloudDownload"></Button>
|
|
21
|
+
<Button type="primary" shape="circle" :size="size" :icon="CloudDownload"></Button>
|
|
22
|
+
<Button type="primary" shape="circle" :size="size" :icon="CloudDownload">Download</Button>
|
|
23
|
+
<Button type="primary" :size="size" :icon="CloudDownload">Download</Button>
|
|
24
|
+
</Space>
|
|
26
25
|
</Space>
|
|
27
26
|
</template>
|
|
28
27
|
<script>
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
## API
|
|
2
2
|
|
|
3
|
-
| 属性 | 说明
|
|
4
|
-
| -------- |
|
|
5
|
-
| type |
|
|
6
|
-
| htmlType | 设置 button 原生的 type 值
|
|
7
|
-
|
|
|
8
|
-
|
|
|
9
|
-
|
|
|
10
|
-
|
|
|
11
|
-
|
|
|
3
|
+
| 属性 | 说明 | 类型 | 默认值 |
|
|
4
|
+
| -------- | ----------------------------------------------------- | ------------------------------------------ | ------ |
|
|
5
|
+
| type | 设置按钮类型 | `primary` \| `link`\| `dashed` \| `danger` | - |
|
|
6
|
+
| htmlType | 设置 button 原生的 type 值 | String | button |
|
|
7
|
+
| disabled | 按钮失效状态 ˚ | Boolean | - |
|
|
8
|
+
| size | 按钮尺寸, | `small`\|`large` | - |
|
|
9
|
+
| shape | shape=circle 呈现圆型按钮 | Boolean | false |
|
|
10
|
+
| theme | 按钮主题 | `solid` \| `light` \| `normal` | - |
|
|
11
|
+
| icon | 按钮的图标 | String | - |
|
|
12
|
+
| loading | 按钮是否进入加载模式 | Boolean | false |
|
|
13
|
+
| href | 点击跳转的地址,指定此属性 button 的行为和 a 链接一致 | String | - |
|
|
14
|
+
| target | 相当于 a 链接的 target 属性,href 存在时生效 | String | - |
|
|
@@ -272,7 +272,7 @@
|
|
|
272
272
|
|
|
273
273
|
.k-btn-group {
|
|
274
274
|
position: relative;
|
|
275
|
-
|
|
275
|
+
flex-shrink: 0;
|
|
276
276
|
display: inline-flex;
|
|
277
277
|
// vertical-align: middle;
|
|
278
278
|
align-items: center;
|
|
@@ -375,18 +375,21 @@
|
|
|
375
375
|
}
|
|
376
376
|
}
|
|
377
377
|
|
|
378
|
+
a.k-btn-link,
|
|
378
379
|
.k-btn-link {
|
|
379
380
|
background: none;
|
|
380
381
|
border: none;
|
|
381
382
|
color: var(--kui-color-main);
|
|
383
|
+
text-decoration: none;
|
|
382
384
|
|
|
383
385
|
&:hover {
|
|
386
|
+
text-decoration: none;
|
|
384
387
|
opacity: .8;
|
|
385
388
|
}
|
|
386
389
|
|
|
387
390
|
&:disabled {
|
|
391
|
+
background: 0 0;
|
|
388
392
|
|
|
389
|
-
&,
|
|
390
393
|
&:hover,
|
|
391
394
|
// &:focus,
|
|
392
395
|
&:active {
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<cn>
|
|
2
|
+
#### 对齐方式
|
|
3
|
+
设置对齐模式。
|
|
4
|
+
</cn>
|
|
5
|
+
|
|
6
|
+
```vue
|
|
7
|
+
<template>
|
|
8
|
+
<Flex vertical size="small" align="start">
|
|
9
|
+
<span>Justify</span>
|
|
10
|
+
<RadioGroup v-model="justify" theme="card" type="button">
|
|
11
|
+
<RadioButton v-for="(item,index) in justifyOps" :key="index" :value="item">{{item}}</RadioButton>
|
|
12
|
+
</RadioGroup>
|
|
13
|
+
<span>Align</span>
|
|
14
|
+
<RadioGroup v-model="align" theme="card" type="button">
|
|
15
|
+
<RadioButton v-for="(item,index) in alignOps" :key="index" :value="item">{{item}}</RadioButton>
|
|
16
|
+
</RadioGroup>
|
|
17
|
+
<Flex :align="align" :justify="justify" :style="{width:'100%',height:'120px',border:'1px solid var(--kui-color-main)','border-radius':'5px'}">
|
|
18
|
+
<Button>Button</Button>
|
|
19
|
+
<Button>Button</Button>
|
|
20
|
+
<Button>Button</Button>
|
|
21
|
+
<Button>Button</Button>
|
|
22
|
+
</Flex>
|
|
23
|
+
</Flex>
|
|
24
|
+
</template>
|
|
25
|
+
<script>
|
|
26
|
+
export default{
|
|
27
|
+
data() {
|
|
28
|
+
return {
|
|
29
|
+
justify:'flex-start',
|
|
30
|
+
align:'flex-start',
|
|
31
|
+
justifyOps:['flex-start','center','flex-end','space-between','space-around','space-evenly'],
|
|
32
|
+
alignOps:['flex-start','center','flex-end']
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
</script>
|
|
37
|
+
```
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<cn>
|
|
2
|
+
#### 基本布局
|
|
3
|
+
最简单的用法。
|
|
4
|
+
</cn>
|
|
5
|
+
|
|
6
|
+
```vue
|
|
7
|
+
<template>
|
|
8
|
+
<Flex vertical size="middle">
|
|
9
|
+
<RadioGroup v-model="value">
|
|
10
|
+
<Radio value="horizontal">horizontal</Radio>
|
|
11
|
+
<Radio value="vertical">vertical</Radio>
|
|
12
|
+
</RadioGroup>
|
|
13
|
+
<Flex :vertical="value=='vertical'">
|
|
14
|
+
<div v-for="x in 4" :style="{'background-color':'var(--kui-color-main)',opacity:(x%2?1:0.8),height:'40px',width:'25%'}"></div>
|
|
15
|
+
</Flex>
|
|
16
|
+
</Flex>
|
|
17
|
+
</template>
|
|
18
|
+
<script>
|
|
19
|
+
export default{
|
|
20
|
+
data() {
|
|
21
|
+
return {
|
|
22
|
+
value: 'horizontal',
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
</script>
|
|
27
|
+
```
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
import Info from "./info.md";
|
|
3
|
+
import Base from "./base.md";
|
|
4
|
+
import Align from "./align.md";
|
|
5
|
+
import Size from "./size.md";
|
|
6
|
+
import Wrap from "./wrap.md";
|
|
7
|
+
|
|
8
|
+
import CN from "../index.md";
|
|
9
|
+
export default {
|
|
10
|
+
render() {
|
|
11
|
+
return (
|
|
12
|
+
<div class="demo-space">
|
|
13
|
+
<Info />
|
|
14
|
+
<Base />
|
|
15
|
+
<Align />
|
|
16
|
+
<Size />
|
|
17
|
+
<Wrap />
|
|
18
|
+
<CN />
|
|
19
|
+
</div>
|
|
20
|
+
);
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
</script>
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<cn>
|
|
2
|
+
#### 间距大小
|
|
3
|
+
使用 size 设置元素之间的间距,预设了 small、middle、large 三种尺寸,也可以自定义间距。
|
|
4
|
+
</cn>
|
|
5
|
+
|
|
6
|
+
```vue
|
|
7
|
+
<template>
|
|
8
|
+
<Flex vertical size="middle">
|
|
9
|
+
<RadioGroup v-model="size" @change="sizeChange">
|
|
10
|
+
<Radio value="small" label="small" />
|
|
11
|
+
<Radio value="middle" label="middle" />
|
|
12
|
+
<Radio value="large" label="large" />
|
|
13
|
+
<Radio value="customize" label="customize" />
|
|
14
|
+
</RadioGroup>
|
|
15
|
+
<Slider v-model="gap" :step="1" :max="50" v-if="size==='customize'" @change="gapChange"/>
|
|
16
|
+
<Flex :size="flexSize">
|
|
17
|
+
<Button type="primary">Primary</Button>
|
|
18
|
+
<Button>Default</Button>
|
|
19
|
+
<Button type="dashed">Dashed</Button>
|
|
20
|
+
<Button type="link">Link</Button>
|
|
21
|
+
</Flex>
|
|
22
|
+
</Flex>
|
|
23
|
+
</template>
|
|
24
|
+
<script>
|
|
25
|
+
export default{
|
|
26
|
+
data() {
|
|
27
|
+
return {
|
|
28
|
+
size:'small',
|
|
29
|
+
flexSize:'small',
|
|
30
|
+
gap:8
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
methods:{
|
|
34
|
+
gapChange(){
|
|
35
|
+
this.flexSize=this.gap
|
|
36
|
+
// console.log(this.gap)
|
|
37
|
+
},
|
|
38
|
+
sizeChange({value}){
|
|
39
|
+
if(value!='customize'){
|
|
40
|
+
this.flexSize=value
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
</script>
|
|
46
|
+
```
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<cn>
|
|
2
|
+
#### 设置换行
|
|
3
|
+
当间距为水平方向时,可使用 wrap 设置是否自动换行,默认情况下为 false。
|
|
4
|
+
</cn>
|
|
5
|
+
|
|
6
|
+
```vue
|
|
7
|
+
<template>
|
|
8
|
+
<Flex size="middle" vertical align="flex-start" style="width:300px;">
|
|
9
|
+
<Slider v-model="x" :min="0" :max="100" :step="1" />
|
|
10
|
+
<Slider v-model="y" :min="0" :max="100" :step="1" />
|
|
11
|
+
<Flex :size="[x,y]" wrap >
|
|
12
|
+
<Button size="small" v-for="x in 10" :key="x">Wrap</Button>
|
|
13
|
+
</Flex>
|
|
14
|
+
</Flex>
|
|
15
|
+
</template>
|
|
16
|
+
<script>
|
|
17
|
+
export default{
|
|
18
|
+
data() {
|
|
19
|
+
return {
|
|
20
|
+
x: 12,
|
|
21
|
+
y: 15
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
</script>
|
|
26
|
+
```
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
name: 'Flex',
|
|
3
|
+
props: {
|
|
4
|
+
align: {
|
|
5
|
+
type: String,
|
|
6
|
+
validator(value) {
|
|
7
|
+
return value ? ["start", "flex-start", "end", "flex-end", "center", "baseline"].indexOf(value) >= 0 : true;
|
|
8
|
+
}
|
|
9
|
+
},
|
|
10
|
+
justify: {
|
|
11
|
+
type: String,
|
|
12
|
+
validator(value) {
|
|
13
|
+
return value ? ["flex-start", "center", "flex-end", "space-between", 'space-around', 'space-evenly'].indexOf(value) >= 0 : true;
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
vertical: Boolean,
|
|
17
|
+
wrap: Boolean,
|
|
18
|
+
size: {
|
|
19
|
+
type: [String, Number, Array],
|
|
20
|
+
// default: 'small',
|
|
21
|
+
validator(value) {
|
|
22
|
+
return (typeof value == 'number' || Array.isArray(value)) ? true : ["small", "middle", "large"].indexOf(value) >= 0;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
render() {
|
|
27
|
+
let { align, justify, vertical, $slots, size, wrap } = this
|
|
28
|
+
align = (!vertical && !align) ? 'center' : align
|
|
29
|
+
const props = {
|
|
30
|
+
style: {},
|
|
31
|
+
class: ['k-flex', {
|
|
32
|
+
[`k-flex-vertical`]: vertical,
|
|
33
|
+
[`k-flex-wrap`]: wrap,
|
|
34
|
+
[`k-flex-align-${align}`]: align,
|
|
35
|
+
[`k-flex-justify-${justify}`]: justify,
|
|
36
|
+
}]
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
if (Array.isArray(size)) {
|
|
40
|
+
props.style = { gap: `${size[1]}px ${size[0]}px` }
|
|
41
|
+
} else if (/small|middle|large/.test(size)) {
|
|
42
|
+
let sizes = { small: 8, middle: 16, large: 24 }
|
|
43
|
+
props.style.gap = sizes[size] + 'px'
|
|
44
|
+
} else if (size !== undefined && size !== null) {
|
|
45
|
+
props.style.gap = `${size}px`
|
|
46
|
+
}
|
|
47
|
+
let childs = $slots.default
|
|
48
|
+
return <div {...props}>{childs}</div>
|
|
49
|
+
}
|
|
50
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
## Space API
|
|
2
|
+
| 属性 | 说明 | 类型 | 默认值 |
|
|
3
|
+
| -------- | ------------------------------ | ---------------------------------------------------------------------------------------- | ------ |
|
|
4
|
+
| align | 对齐方式 | 参考 [align-items](https://developer.mozilla.org/zh-CN/docs/Web/CSS/align-items) | center |
|
|
5
|
+
| justify | 设置元素在主轴方向上的对齐方式 | 参考 [justify-content](https://developer.mozilla.org/zh-CN/docs/Web/CSS/justify-content) | center |
|
|
6
|
+
| vertical | 是否垂直显示 | Boolean | false |
|
|
7
|
+
| size | 间距大小 | small,middle,large,number,array | - |
|
|
8
|
+
| wrap | 是否换行 | Boolean | false |
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
.k-flex {
|
|
2
|
+
display: flex;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.k-flex-wrap {
|
|
6
|
+
flex-wrap: wrap;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.k-flex-align-start,
|
|
10
|
+
.k-flex-align-flex-start {
|
|
11
|
+
align-items: flex-start;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.k-flex-align-flex-end,
|
|
15
|
+
.k-flex-align-end {
|
|
16
|
+
align-items: flex-end;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.k-flex-align-center {
|
|
20
|
+
align-items: center;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.k-flex-align-baseline {
|
|
24
|
+
align-items: baseline;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.k-flex-justify-center {
|
|
28
|
+
justify-content: center;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.k-flex-justify-flex-start {
|
|
32
|
+
justify-content: flex-start;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.k-flex-justify-flex-end {
|
|
36
|
+
justify-content: flex-end;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.k-flex-justify-space-between {
|
|
40
|
+
justify-content: space-between;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.k-flex-justify-space-around {
|
|
44
|
+
justify-content: space-around;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.k-flex-justify-space-evenly {
|
|
48
|
+
justify-content: space-evenly;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
.k-flex-vertical {
|
|
53
|
+
flex-direction: column;
|
|
54
|
+
}
|
|
@@ -97,9 +97,7 @@
|
|
|
97
97
|
}
|
|
98
98
|
|
|
99
99
|
.k-select {
|
|
100
|
-
|
|
101
|
-
border-color: var(--kui-color-danger);
|
|
102
|
-
}
|
|
100
|
+
border-color: var(--kui-color-danger);
|
|
103
101
|
|
|
104
102
|
.k-select-arrow {
|
|
105
103
|
color: var(--kui-color-danger);
|
|
@@ -110,7 +108,7 @@
|
|
|
110
108
|
border-color: var(--kui-color-danger);
|
|
111
109
|
}
|
|
112
110
|
|
|
113
|
-
.k-select-open .k-select
|
|
111
|
+
.k-select-open .k-select {
|
|
114
112
|
box-shadow: 0 0 0 2px var(--kui-color-danger-90);
|
|
115
113
|
}
|
|
116
114
|
|
|
@@ -3,20 +3,15 @@
|
|
|
3
3
|
<h3>图标快速检索</h3>
|
|
4
4
|
<br />
|
|
5
5
|
<Affix :offsetTop="65">
|
|
6
|
-
<
|
|
7
|
-
:icon="LogoKui"
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
@
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
slot="suffix">
|
|
16
|
-
<RadioButton value="outline">Outline</RadioButton>
|
|
17
|
-
<RadioButton value="filled">Filled</RadioButton>
|
|
18
|
-
</RadioGroup>
|
|
19
|
-
</Input>
|
|
6
|
+
<Space size="large" compact style="width:80%">
|
|
7
|
+
<Input placeholder="输入英文关键字,搜索图标,点击图标即可复制" :icon="LogoKui" v-model="key" @input="search" clearable
|
|
8
|
+
style="background:var(--kui-color-back);">
|
|
9
|
+
</Input>
|
|
10
|
+
<RadioGroup v-model="type" @change="switchIcon">
|
|
11
|
+
<RadioButton value="outline">Outline</RadioButton>
|
|
12
|
+
<RadioButton value="filled">Filled</RadioButton>
|
|
13
|
+
</RadioGroup>
|
|
14
|
+
</Space>
|
|
20
15
|
</Affix>
|
|
21
16
|
|
|
22
17
|
<br />
|
|
@@ -28,37 +23,30 @@
|
|
|
28
23
|
</div>
|
|
29
24
|
<br />
|
|
30
25
|
<div class="icon-list">
|
|
31
|
-
<span @click.stop="copy(x)"
|
|
32
|
-
v-for="(x,y) in showIcons"
|
|
33
|
-
:key="y"
|
|
34
|
-
class="icon-item">
|
|
26
|
+
<span @click.stop="copy(x)" v-for="(x, y) in showIcons" :key="y" class="icon-item">
|
|
35
27
|
<Icon :type="icons[x]" />
|
|
36
28
|
<!-- <svg width="1em" height="1em">
|
|
37
29
|
<use :xlink:href="`${sprite}#${x}`"></use>
|
|
38
30
|
</svg> -->
|
|
39
|
-
<span class="item-text">{{x}}</span>
|
|
31
|
+
<span class="item-text">{{ x }}</span>
|
|
40
32
|
</span>
|
|
41
33
|
</div>
|
|
42
34
|
</template>
|
|
43
35
|
<template v-if="logo.length">
|
|
44
36
|
<h3>Logos</h3>
|
|
45
37
|
<div class="icon-list">
|
|
46
|
-
<span @click.stop="copy(x)"
|
|
47
|
-
v-for="(x,y) in logo"
|
|
48
|
-
:key="y"
|
|
49
|
-
class="icon-item">
|
|
38
|
+
<span @click.stop="copy(x)" v-for="(x, y) in logo" :key="y" class="icon-item">
|
|
50
39
|
<Icon :type="icons[x]" />
|
|
51
40
|
<!-- <svg width="1em"
|
|
52
41
|
height="1em">
|
|
53
42
|
<use :xlink:href="`${sprite}#${x}`"></use>
|
|
54
43
|
</svg> -->
|
|
55
|
-
<span class="item-text">{{x}}</span>
|
|
44
|
+
<span class="item-text">{{ x }}</span>
|
|
56
45
|
</span>
|
|
57
46
|
</div>
|
|
58
47
|
</template>
|
|
59
|
-
<h3 v-if="!showIcons.length && !logo.length"
|
|
60
|
-
|
|
61
|
-
No results for "{{key}}"
|
|
48
|
+
<h3 v-if="!showIcons.length && !logo.length" style="text-align:center;padding-bottom:50px;color:#888;">
|
|
49
|
+
No results for "{{ key }}"
|
|
62
50
|
</h3>
|
|
63
51
|
</div>
|
|
64
52
|
</div>
|
|
@@ -67,6 +55,7 @@
|
|
|
67
55
|
.icon-list {
|
|
68
56
|
// overflow: hidden;
|
|
69
57
|
display: inline-block;
|
|
58
|
+
|
|
70
59
|
.icon-item {
|
|
71
60
|
text-align: center;
|
|
72
61
|
width: 200px;
|
|
@@ -81,12 +70,14 @@
|
|
|
81
70
|
font-size: 32px;
|
|
82
71
|
cursor: pointer;
|
|
83
72
|
transition: color 0.3s ease-in-out;
|
|
73
|
+
|
|
84
74
|
&:hover {
|
|
85
75
|
color: #3a95ff;
|
|
86
76
|
// background: #f5f5f5;
|
|
87
77
|
box-shadow: 0 0 15px #ddd;
|
|
88
78
|
}
|
|
89
79
|
}
|
|
80
|
+
|
|
90
81
|
.item-text {
|
|
91
82
|
font-size: 12px;
|
|
92
83
|
line-height: 1;
|
package/components/index.js
CHANGED
|
@@ -17,9 +17,10 @@ import Dropdown from './dropdown'
|
|
|
17
17
|
import Divider from './divider'
|
|
18
18
|
import Empty from './empty'
|
|
19
19
|
import { Form, FormItem } from './form'
|
|
20
|
+
import Flex from './flex'
|
|
20
21
|
import { Image, ImageGroup } from './image'
|
|
21
22
|
import Icon from './icon'
|
|
22
|
-
import { Input, TextArea } from './input'
|
|
23
|
+
import { Input, TextArea ,InputGroup} from './input'
|
|
23
24
|
import InputNumber from './inputNumber'
|
|
24
25
|
import { Layout, Header, Footer, Content, Sider } from './layout'
|
|
25
26
|
import Loading from './loading'
|
|
@@ -74,9 +75,10 @@ const components = {
|
|
|
74
75
|
Divider,
|
|
75
76
|
Empty,
|
|
76
77
|
Form, FormItem,
|
|
78
|
+
Flex,
|
|
77
79
|
Icon,
|
|
78
80
|
ImageGroup,
|
|
79
|
-
Input, TextArea,
|
|
81
|
+
Input, TextArea, InputGroup,
|
|
80
82
|
InputNumber,
|
|
81
83
|
Menu, MenuGroup, MenuItem, MenuDivider, SubMenu,
|
|
82
84
|
Modal,
|