Skip to content

Commit

Permalink
fix(image): css standard
Browse files Browse the repository at this point in the history
  • Loading branch information
jin0209 committed Dec 16, 2021
1 parent 85ccd28 commit 707f9ec
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 27 deletions.
41 changes: 17 additions & 24 deletions src/image/image.less
Original file line number Diff line number Diff line change
@@ -1,28 +1,21 @@
// @import '../common/style/index.less';
@import '../common/style/index.less';

.t-image__mask {
display: flex;
align-items: center;
justify-content: center;
background-color: #f2f2f2;
color: #ccc;
}

// .t-image-icon {
// display: flex;
// align-items: center;
// justify-content: center;
// width: 100%;
// height: 100%;
// font-size: inherit;
// }
.@{prefix}-image {
&__mask {
display: flex;
align-items: center;
justify-content: center;
background-color: #f2f2f2;
color: #ccc;
}

.t-image-common {
width: 100%;
height: 100%;
}
&--loading-text {
width: 0px;
height: 0px;
}

.t-image-loading-text {
width: 0px;
height: 0px;
&__common {
width: 100%;
height: 100%;
}
}
6 changes: 3 additions & 3 deletions src/image/image.wxml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
size="40rpx"
loading
class="t-class-load"
t-class-text="{{classPrefix}}-loading-text"
t-class-text="{{classPrefix}}--loading-text"
></t-loading>
<view
wx:elif="{{loading !== 'slot' && loading !== ''}}"
class="{{classPrefix}}-common t-class-load"
class="{{classPrefix}}__common t-class-load"
>
{{loading}}
</view>
Expand All @@ -33,7 +33,7 @@
</view>
<view
wx:elif="{{loadFailed !== 'slot' && loadFailed !== ''}}"
class="{{classPrefix}}-common t-class-load"
class="{{classPrefix}}__common t-class-load"
>
{{loadFailed}}
</view>
Expand Down

0 comments on commit 707f9ec

Please sign in to comment.