/* 文字缩略 $line: 保留几行文章 */ @mixin ellipsis($line: 1) { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: $line; -webkit-box-orient: vertical; } // page { // -webkit-filter: grayscale(100%); // -moz-filter: grayscale(100%); // -o-filter: grayscale(100%); // filter: grayscale(100%); // filter: progid:DXImageTransform.Microsoft.BasicImage(grayscale=1); // } // flex布局 .cm-flex-center { display: flex; justify-content: center; align-items: center; } .cm-flex-between { display: flex; justify-content: space-between; align-items: center; } .cm-flex-around { display: flex; justify-content: space-around; align-items: center; } // 标签 .tags { .tag { display: inline-block; margin-right: 8rpx; height: 30rpx; text-align: center; line-height: 30rpx; font-size: 18rpx; padding: 0 4rpx; vertical-align: middle; &.cx { // 促销 自营标签 background: #f83c6c; border-radius: 4rpx; color: #ffffff; } &.hd { // 活动价标签 width: 80rpx; box-sizing: border-box; padding: 0; background: url(https://static.caimei365.com/app/mini-hehe/icon/icon-active.png) top center no-repeat; background-size: 80rpx 30rpx; color: #f83c6c; } &.pt { // 拼团价标签 background: linear-gradient(270deg, #ff457b 0%, #b03bb8 51%, #6431f2 100%); color: #fff; border-radius: 4rpx; } &.other { // 其他标签 border: 1rpx solid #f83c6c; height: 28rpx; line-height: 28rpx; color: #f83c6c; border-radius: 4rpx; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } } } // 图标默认颜色 .icon { font-size: 36rpx; color: #b2b2b2; &.icon-xuanze { color: #f83c6c; } } // 列表为空的提示语样式 .empty-tip { font-size: 24rpx; line-height: 1.6; color: #999; } .placeholder { font-size: 28rpx; color: #999999; } .hover-class { background-color: #eee !important; } // thorui 样式 .tui-nodata-fixed { transform: translate(-50%, -70%) !important; } .tui-divider { .tui-divider-line { background: #d4d4d4 !important; } } // 定位 .fixed-top { position: fixed; z-index: 90; width: 100%; left: 0; top: 0; } .fixed-bottom { position: fixed; z-index: 90; width: 100%; left: 0; bottom: 0; } .sticky-top { position: sticky; z-index: 90; width: 100%; left: 0; top: 0; } // 清除浮动 .clearfix::after { content: ''; display: block; clear: both; }