[improvement] add constant of border (#4078)
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { createNamespace } from '../utils';
|
||||
import { BORDER } from '../utils/constant';
|
||||
|
||||
const [createComponent, bem] = createNamespace('key');
|
||||
|
||||
@@ -54,7 +55,7 @@ export default createComponent({
|
||||
<i
|
||||
role="button"
|
||||
tabindex="0"
|
||||
class={['van-hairline', this.className]}
|
||||
class={[BORDER, this.className]}
|
||||
onClick={this.onClick}
|
||||
onTouchstart={this.onFocus}
|
||||
onTouchmove={onBlur}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { createNamespace } from '../utils';
|
||||
import { stopPropagation } from '../utils/dom/event';
|
||||
import { BORDER_TOP } from '../utils/constant';
|
||||
import { BindEventMixin } from '../mixins/bind-event';
|
||||
import Key from './Key';
|
||||
|
||||
@@ -137,7 +138,7 @@ export default createComponent({
|
||||
const showTitle = title || showTitleClose || titleLeftSlot;
|
||||
|
||||
const Title = showTitle && (
|
||||
<div class={[bem('title'), 'van-hairline--top']}>
|
||||
<div class={[bem('title'), BORDER_TOP]}>
|
||||
{titleLeftSlot && <span class={bem('title-left')}>{titleLeftSlot}</span>}
|
||||
{title && <span>{title}</span>}
|
||||
{showTitleClose && (
|
||||
|
||||
Reference in New Issue
Block a user