Skip to content

Commit

Permalink
Merge pull request #237 from Tencent/style/components
Browse files Browse the repository at this point in the history
fix: resolve warning from invalid css selector
  • Loading branch information
LeeJim authored Mar 10, 2022
2 parents 8290596 + 91956ba commit 290cb56
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 19 deletions.
8 changes: 4 additions & 4 deletions src/avatar/avatar.less
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
color: #0052d9;
border-radius: 999rpx;

@{prefix}-badge {
position: absolute;
}

.@{prefix}-badge {
&-host {
position: absolute;
}

&__round {
top: -10%;
right: -10%;
Expand Down
2 changes: 1 addition & 1 deletion src/avatar/avatar.wxml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
</view>
</view>
<t-badge
class="{{prefix}}-badge__{{shape === 'circle' ? 'circle' : 'round'}}"
class="{{prefix}}-badge-host {{prefix}}-badge__{{shape === 'circle' ? 'circle' : 'round'}}"
wx:if="{{badgeProps.dot || badgeProps.count}}"
color="{{badgeProps.color}}"
count="{{badgeProps.count}}"
Expand Down
2 changes: 1 addition & 1 deletion src/dialog/dialog.less
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
@dialog-btn-border-color: #eee;
@dialog-input-bg-color: #f0f0f0;

page {
.@{dialog}__wrapper {
.@{dialog} {
overflow: hidden;
width: @dialog-width;
Expand Down
1 change: 1 addition & 0 deletions src/dialog/dialog.wxml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
<wxs src="./dialog.wxs" module="_" />

<t-popup
class="{{classPrefix}}__wrapper"
visible="{{visible}}"
showOverlay="{{showOverlay}}"
closeOnOverlayClick="{{closeOnOverlayClick}}"
Expand Down
5 changes: 0 additions & 5 deletions src/input/input.less
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,6 @@
color: @input-icon-color;
font-size: @input-icon-font-size;

i {
font-size: @input-icon-font-size;
color: @input-icon-color;
}

&:empty {
display: none;
}
Expand Down
2 changes: 1 addition & 1 deletion src/textarea/textarea.less
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
font-size: @textarea-font-size;
color: @textarea-text-color;

textarea {
&-textarea {
display: block;
box-sizing: border-box;
width: 100%;
Expand Down
10 changes: 3 additions & 7 deletions src/textarea/textarea.wxml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
maxlength="{{maxlength || -1}}"
disabled="{{disabled}}"
placeholder="{{placeholder}}"
class="t-class-textarea"
class="{{classPrefix}}__wrapper-textarea t-class-textarea"
placeholder-class="{{classPrefix}}__placeholder t-class-placeholder"
value="{{value}}"
auto-focus="{{autofocus}}"
Expand All @@ -22,11 +22,7 @@
bindconfirm="onConfirm"
bindlinechange="onLineChange"
/>
<view class="{{classPrefix}}__count" wx:if="{{maxlength}}">
{{inputValue.length}} / {{maxlength}}
</view>
<view class="{{classPrefix}}__count" wx:elif="{{maxcharacter}}">
{{characterLength}} / {{maxcharacter}}
</view>
<view class="{{classPrefix}}__count" wx:if="{{maxlength}}"> {{inputValue.length}} / {{maxlength}} </view>
<view class="{{classPrefix}}__count" wx:elif="{{maxcharacter}}"> {{characterLength}} / {{maxcharacter}} </view>
</view>
</view>

0 comments on commit 290cb56

Please sign in to comment.