1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- <view class="{{classPrefix}} {{prefix}}-class {{classPrefix}}--{{align}}">
- <!-- 图标 -->
- <view
- class="{{classPrefix}}__icon {{classPrefix}}__icon--{{align}} {{prefix}}-class-icon"
- data-target="icon"
- bind:tap="handleTap"
- >
- <view wx:if="{{customIcon}}" class="{{classPrefix}}__image">
- <image src="{{active ? iconVal[0] : iconVal[1]}}" class="{{classPrefix}}-icon__image" webp />
- </view>
- <t-icon
- wx:else
- color="{{active && !disabled ? color : ''}}"
- name="{{active ? iconVal[0] : iconVal[1]}}"
- class="{{classPrefix}}__btn {{disabled ? classPrefix + '-is-disabled' : ''}} {{active ? classPrefix + '-is-checked' : ''}}"
- />
- </view>
- <!-- 文本内容 -->
- <view
- class="{{classPrefix}}__content {{disabled ? classPrefix + '__content--disabled' : ''}}"
- data-target="text"
- bind:tap="handleTap"
- >
- <!-- 主文本 -->
- <view
- class="{{classPrefix}}__title {{prefix}}-class-label"
- style="-webkit-line-clamp:{{maxLabelRow}}"
- >
- {{label}}
- </view>
- <!-- content -->
- <view
- class="{{classPrefix}}__description {{prefix}}-class-content "
- style="-webkit-line-clamp:{{maxContentRow}}"
- >
- {{content}}
- <slot />
- </view>
- </view>
- <!-- 预制下边框 -->
- <view
- class="{{classPrefix}}__border {{classPrefix}}__border--{{align}} {{prefix}}-class-border"
- ></view>
- </view>
|