dev
liuyongli 3 years ago
parent 32842fa73a
commit 71cc2fd4af

@ -1,54 +1,37 @@
<wxs src="../wxs/utils.wxs" module="utils" />
<view class="custom-class {{ utils.bem('steps', [direction]) }}">
<view class="van-step__wrapper">
<view
wx:for="{{ steps }}"
wx:key="index"
bindtap="onClick"
data-index="{{ index }}"
class="{{ utils.bem('step', [direction, status(index, active)]) }} van-hairline"
style="{{ status(index, active) === 'inactive' ? 'color: ' + inactiveColor: '' }}"
>
<view class="van-step__title" style="{{ index === active ? 'color: ' + activeColor : '' }}">
<view>{{ item.text }}</view>
<view class="desc-class">{{ item.desc }}</view>
</view>
<view class="van-step__circle-container">
<block wx:if="{{ index !== active }}">
<van-icon
wx:if="{{ item.inactiveIcon || inactiveIcon }}"
color="{{ status(index, active) === 'inactive' ? inactiveColor: activeColor }}"
name="{{ item.inactiveIcon || inactiveIcon }}"
custom-class="van-step__icon"
/>
<view
wx:else
class="van-step__circle"
style="{{ 'background-color: ' + (index < active ? activeColor : inactiveColor) }}"
/>
</block>
<view class="van-step__wrapper">
<view wx:for="{{ steps }}" wx:key="index" bindtap="onClick" data-index="{{ index }}" class="{{ utils.bem('step', [direction, status(index, active)]) }} van-hairline" style="{{ status(index, active) === 'inactive' ? 'color: ' + inactiveColor: '' }}">
<view class="van-step__title" style="{{ index === active ? 'color: ' + activeColor : '' }}">
<view>{{ item.text }}</view>
<view class="desc-class">
<rich-text nodes="{{ item.desc }}"></rich-text>
</view>
</view>
<view class="van-step__circle-container">
<block wx:if="{{ index !== active }}">
<van-icon wx:if="{{ item.inactiveIcon || inactiveIcon }}" color="{{ status(index, active) === 'inactive' ? inactiveColor: activeColor }}" name="{{ item.inactiveIcon || inactiveIcon }}" custom-class="van-step__icon" />
<view wx:else class="van-step__circle" style="{{ 'background-color: ' + (index < active ? activeColor : inactiveColor) }}" />
</block>
<van-icon wx:else name="{{ item.activeIcon || activeIcon }}" color="{{ activeColor }}" custom-class="van-step__icon" />
</view>
<view
wx:if="{{ index !== steps.length - 1 }}"
class="van-step__line" style="{{ 'background-color: ' + (index < active ? activeColor : inactiveColor) }}"
/>
<van-icon wx:else name="{{ item.activeIcon || activeIcon }}" color="{{ activeColor }}" custom-class="van-step__icon" />
</view>
<view wx:if="{{ index !== steps.length - 1 }}" class="van-step__line" style="{{ 'background-color: ' + (index < active ? activeColor : inactiveColor) }}" />
</view>
</view>
</view>
</view>
<wxs module="status">
function get(index, active) {
if (index < active) {
return 'finish';
} else if (index === active) {
return 'process';
}
function get(index, active) {
if (index < active) {
return 'finish';
} else if (index === active) {
return 'process';
}
return 'inactive';
}
return 'inactive';
}
module.exports = get;
</wxs>
module.exports = get;
</wxs>

@ -1 +1,160 @@
@import '../common/index.wxss';.van-steps{background-color:var(--steps-background-color,#fff);overflow:hidden}.van-steps--horizontal{padding:10px}.van-steps--horizontal .van-step__wrapper{display:flex;overflow:hidden;position:relative}.van-steps--vertical{padding-left:10px}.van-steps--vertical .van-step__wrapper{padding:0 0 0 20px}.van-step{color:var(--step-text-color,#969799);flex:1;font-size:var(--step-font-size,14px);position:relative}.van-step--finish{color:var(--step-finish-text-color,#323233)}.van-step__circle{background-color:var(--step-circle-color,#969799);border-radius:50%;height:var(--step-circle-size,5px);width:var(--step-circle-size,5px)}.van-step--horizontal{padding-bottom:14px}.van-step--horizontal:first-child .van-step__title{transform:none}.van-step--horizontal:first-child .van-step__circle-container{padding:0 8px 0 0;transform:translate3d(0,50%,0)}.van-step--horizontal:last-child{position:absolute;right:0;width:auto}.van-step--horizontal:last-child .van-step__title{text-align:right;transform:none}.van-step--horizontal:last-child .van-step__circle-container{padding:0 0 0 8px;right:0;transform:translate3d(0,50%,0)}.van-step--horizontal .van-step__circle-container{background-color:#fff;bottom:6px;padding:0 var(--padding-xs,8px);position:absolute;transform:translate3d(-50%,50%,0);z-index:1}.van-step--horizontal .van-step__title{display:inline-block;font-size:var(--step-horizontal-title-font-size,12px);transform:translate3d(-50%,0,0)}.van-step--horizontal .van-step__line{background-color:var(--step-line-color,#ebedf0);bottom:6px;height:1px;left:0;position:absolute;right:0;transform:translate3d(0,50%,0)}.van-step--horizontal.van-step--process{color:var(--step-process-text-color,#323233)}.van-step--horizontal.van-step--process .van-step__icon{display:block;font-size:var(--step-icon-size,12px);line-height:1}.van-step--vertical{line-height:18px;padding:10px 10px 10px 0}.van-step--vertical:after{border-bottom-width:1px}.van-step--vertical:last-child:after{border-bottom-width:none}.van-step--vertical:first-child:before{background-color:#fff;content:"";height:20px;left:-15px;position:absolute;top:0;width:1px;z-index:1}.van-step--vertical .van-step__circle,.van-step--vertical .van-step__icon,.van-step--vertical .van-step__line{left:-14px;position:absolute;top:19px;transform:translate3d(-50%,-50%,0);z-index:2}.van-step--vertical .van-step__icon{font-size:var(--step-icon-size,12px);line-height:1}.van-step--vertical .van-step__line{background-color:var(--step-line-color,#ebedf0);height:100%;transform:translate3d(-50%,0,0);width:1px;z-index:1}
@import '../common/index.wxss';
.van-steps {
background-color: var(--steps-background-color, #fff);
overflow: hidden
}
.van-steps--horizontal {
padding: 10px
}
.van-steps--horizontal .van-step__wrapper {
display: flex;
overflow: hidden;
position: relative
}
.van-steps--vertical {
padding-left: 10px
}
.van-steps--vertical .van-step__wrapper {
padding: 0 0 0 20px
}
.van-step {
color: var(--step-text-color, #969799);
flex: 1;
font-size: var(--step-font-size, 14px);
position: relative
}
.van-step--finish {
color: var(--step-finish-text-color, #323233)
}
.van-step__circle {
background-color: var(--step-circle-color, #969799);
border-radius: 50%;
height: var(--step-circle-size, 5px);
width: var(--step-circle-size, 5px)
}
.van-step--horizontal {
padding-bottom: 14px
}
.van-step--horizontal:first-child .van-step__title {
transform: none
}
.van-step--horizontal:first-child .van-step__circle-container {
padding: 0 8px 0 0;
transform: translate3d(0, 50%, 0)
}
.van-step--horizontal:last-child {
position: absolute;
right: 0;
width: auto
}
.van-step--horizontal:last-child .van-step__title {
text-align: right;
transform: none
}
.van-step--horizontal:last-child .van-step__circle-container {
padding: 0 0 0 8px;
right: 0;
transform: translate3d(0, 50%, 0)
}
.van-step--horizontal .van-step__circle-container {
background-color: #fff;
bottom: 6px;
padding: 0 var(--padding-xs, 8px);
position: absolute;
transform: translate3d(-50%, 50%, 0);
z-index: 1
}
.van-step--horizontal .van-step__title {
display: inline-block;
font-size: var(--step-horizontal-title-font-size, 12px);
transform: translate3d(-50%, 0, 0)
}
.van-step--horizontal .van-step__line {
background-color: var(--step-line-color, #ebedf0);
bottom: 6px;
height: 1px;
left: 0;
position: absolute;
right: 0;
transform: translate3d(0, 50%, 0)
}
.van-step--horizontal.van-step--process {
color: var(--step-process-text-color, #323233)
}
.van-step--horizontal.van-step--process .van-step__icon {
display: block;
font-size: var(--step-icon-size, 12px);
line-height: 1
}
.van-step--vertical {
line-height: 18px;
padding: 10px 10px 10px 0
}
.van-step--vertical:after {
border-bottom-width: 1px
}
.van-step--vertical:last-child:after {
border-bottom-width: none
}
.van-step--vertical:first-child:before {
background-color: #fff;
content: "";
height: 20px;
left: -15px;
position: absolute;
top: 0;
width: 1px;
z-index: 1
}
.van-step--vertical .van-step__circle,
.van-step--vertical .van-step__icon,
.van-step--vertical .van-step__line {
left: -14px;
position: absolute;
top: 19px;
transform: translate3d(-50%, -50%, 0);
z-index: 2
}
.van-step--vertical .van-step__icon {
font-size: var(--step-icon-size, 12px);
line-height: 1
}
.van-step--vertical .van-step__line {
background-color: var(--step-line-color, #ebedf0);
height: 100%;
transform: translate3d(-50%, 0, 0);
width: 1px;
z-index: 1
}
.desc-class{
font-size: 14px;
font-weight: 600;
color: #333333;
margin: 0 32rpx 0 32rpx
}

@ -25,8 +25,6 @@
<view style="height: 60rpx;margin-top: 10px;">
<van-dropdown-menu custom-class="dropdown-menu" active-color="#027AFF;">
<van-dropdown-item value="{{ grade_value1 }}" options="{{ grades1 }}" bind:change="mySelect1" >
<view>fw
</view>
</van-dropdown-item>
<van-dropdown-item value="{{ grade_value2 }}" options="{{ grades2 }}" bind:change="mySelect2" />
<van-dropdown-item value="{{ grade_value3 }}" options="{{ grades3}}" bind:change="mySelect3" />

@ -302,7 +302,6 @@ Component({
dPositive.push((ele.value[0].value * 100 / total).toFixed(0));
dNegative.push((ele.value[2].value * 100 / total).toFixed(0));
}
console.log('0000', dName)
});
this.setData({

@ -86,7 +86,8 @@
<view class="kol-content">
<view class="kol-item" wx:for="{{kolData}}" wx:key="index" wx:if="{{index >= 3}}">
<image style="width: 64rpx;height: 64rpx;margin-top: 20rpx;" src="{{item._source.profileimgurl}}" />
<view class="kol-user-name">{{item._source.user_author.length > 7 ? item._source.user_author.slice(0,7)+'...':item._source.user_author}}</view>
<!-- <view class="kol-user-name">{{item._source.user_author.length > 7 ? item._source.user_author.slice(0,7)+'...':item._source.user_author}}</view> -->
<view class="kol-user-name">{{item._source.user_author}}</view>
<view style="display: flex;justify-content: space-between;padding: 24rpx 24rpx 0rpx 24rpx">
<view class="kol-value">影响力</view>
<view class="kol-value-number">{{item._source.volume}}</view>

@ -108,9 +108,14 @@
text-align: center;
}
.kol-user-name {
width: 100%;
margin: 0 auto;
font-size: 12px;
font-weight: 400;
color: #333333;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
/* line-height: 12px; */
}
.kol-value {

@ -117,7 +117,7 @@ Page({
res.forEach(ele => {
let obj = {
text: ele._source.firsttime+' '+ele._source.category,
desc: ele._source.title
desc: ele._source.title.replace(/<em>/g, '<em style="color: red">'),// .replace(/<\/em>/g,'')
};
arr.push(obj);
});

@ -3,8 +3,6 @@
<view class="ppt" wx:for="{{list}}" wx:key="index" data-row="{{item}}" bindtap="openFile">
<van-image width="64rpx" height="64rpx" fit='cover' src="{{imageUrl}}/my_ppt.png"
custom-class='img1'/>
<van-image width="64rpx" height="64rpx" fit='cover' wx:if="path.lastIndexOf('/')" src="./image/xlsx.png"
custom-class='img1'/>
<view class="ppt_cneter">
<view style="font-size: 28rpx;font-weight: bold;" class="title">{{item.Folder}}</view>
<view style="font-size: 24rpx; color: #9d9d9d;">{{item.AddTime}}</view>

Loading…
Cancel
Save