diff --git a/packages/goods-action-icon/index.less b/packages/goods-action-icon/index.less index 19be80ec..9a93ad65 100644 --- a/packages/goods-action-icon/index.less +++ b/packages/goods-action-icon/index.less @@ -5,10 +5,10 @@ border: none !important; &__content { - height: 100%; display: flex; - line-height: 1; + height: 100%; font-size: 10px; + line-height: 1; color: @gray-darker; flex-direction: column; justify-content: center; diff --git a/packages/goods-action-icon/index.ts b/packages/goods-action-icon/index.ts index 3a3ea908..bc55dd1d 100644 --- a/packages/goods-action-icon/index.ts +++ b/packages/goods-action-icon/index.ts @@ -4,6 +4,8 @@ import { button } from '../mixins/button'; import { openType } from '../mixins/open-type'; VantComponent({ + classes: ['icon-class', 'text-class'], + mixins: [link, button, openType], props: { diff --git a/packages/goods-action-icon/index.wxml b/packages/goods-action-icon/index.wxml index 9801e3b7..9593ac88 100644 --- a/packages/goods-action-icon/index.wxml +++ b/packages/goods-action-icon/index.wxml @@ -26,7 +26,8 @@ name="{{ icon }}" info="{{ info }}" class="van-goods-action-icon__icon" + custom-class="icon-class" /> - {{ text }} + {{ text }} diff --git a/packages/goods-action/README.md b/packages/goods-action/README.md index 3968b794..355457a3 100644 --- a/packages/goods-action/README.md +++ b/packages/goods-action/README.md @@ -119,6 +119,19 @@ Page({ |-----------|-----------|-----------| | click | 按钮点击事件回调 | - | +### GoodsActionIcon 外部样式类 + +| 类名 | 说明 | +|-----------|-----------| +| icon-class | 图标样式类 | +| text-class | 文字样式类 | + +### GoodsActionButton 外部样式类 + +| 类名 | 说明 | +|-----------|-----------| +| custom-class | 根节点样式类 | + ### 更新日志 | 版本 | 类型 | 内容 |