修改$t为$tn

修改部分函数api的名称
This commit is contained in:
jaylen
2022-11-27 16:58:51 +08:00
parent 72d0c5872a
commit fa70ad608a
92 changed files with 1475 additions and 1461 deletions
+12 -12
View File
@@ -34,9 +34,9 @@
!value ? 'tn-switch__icon--show' : ''
]"
:style="[iconStyle]"></view>
</view>
</template>
</view>
</template>
<script>
export default {
name: 'tn-switch',
@@ -105,7 +105,7 @@
computed: {
switchStyle() {
let style = {}
style.fontSize = this.$t.string.getLengthUnitValue(this.size)
style.fontSize = this.$tn.string.getLengthUnitValue(this.size)
style.backgroundColor = this.value ?
this.activeColor ? this.activeColor : '#01BEFF' :
this.inactiveColor ? this.inactiveColor : '#AAAAAA'
@@ -113,14 +113,14 @@
},
switchNodeStyle() {
let style = {}
style.width = this.$t.string.getLengthUnitValue(this.size)
style.width = this.$tn.string.getLengthUnitValue(this.size)
style.height = style.width
return style
},
iconStyle() {
let style = {}
style.fontSize = this.$t.string.getLengthUnitValue(this.size - 20)
style.lineHeight = this.$t.string.getLengthUnitValue(this.size)
style.fontSize = this.$tn.string.getLengthUnitValue(this.size - 20)
style.lineHeight = this.$tn.string.getLengthUnitValue(this.size)
return style
},
loadingColor() {
@@ -144,9 +144,9 @@
}
}
}
}
</script>
}
</script>
<style lang="scss" scoped>
.tn-switch {
@@ -237,5 +237,5 @@
&--disabled {
opacity: 0.4;
}
}
</style>
}
</style>