01 / Overview
cu-promo-heart-price
心跳价与折线价两档,上下各三个角位文案。
券与营销
参考件 heartcurve
2 档
已上线
02 / Demo
档位与实时预览
| 档位数 | 演示页 | 平台 |
|---|---|---|
| 2 | /pages/promo/marketing?name=cu-promo-heart-price | App / H5 / 微信 |
右侧的预览由站点脚本把 H5 演示页装进 iframe;切档位与主题在演示页顶部操作,不在此处留静态截图。
03 / Props · Events · Slots
全量契约
props
| 参数 | 说明 | 类型 | 默认值 |
|---|---|---|---|
| type | 只允许 bight / line;broken 按 line 处理且不告警(参考件旧名);其它值 → bight + cuWarn 一次 | String | 'bight' |
| size | 只允许 small / normal / big;其它值 → normal + cuWarn 一次 | String | 'normal' |
| price | 中心价格;仅 bight 渲染;负数按 0 | Number | 0 |
| top | 上排文案对象,键 left / center / right,值按字符串取;缺键 / 非字符串 → 空串 | Object | {} |
| bottom | 下排文案对象,键同上 | Object | {} |
events
本件不派发事件。
slots
| 插槽 | 说明 |
|---|---|
| default | 整卡替换 |
| top-left | 上排左角文案 |
| top-center | 上排中角文案 |
| top-right | 上排右角文案 |
| bottom-left | 下排左角文案 |
| bottom-center | 下排中角文案 |
| bottom-right | 下排右角文案 |
04 / Example
代码示例
<cu-promo-heart-price type="bight" size="normal" :price="99.9" />
05 / Notes
注意事项
不发任何事件。
心形与折线均由 CSS 节点拼成,不用位图。
line 档不显示价格。
安装 colorui-promo 全量包与安装任意 cu-promo-* 单件包二选一,不要同时装。单件包的前提是已安装完整 colorui-x。