第一次提交
This commit is contained in:
@@ -2,12 +2,12 @@
|
||||
<view class="uni-countdown">
|
||||
<text v-if="showDay" :style="timeStyle" class="uni-countdown__number">{{ d }}</text>
|
||||
<text v-if="showDay" :style="splitorStyle" class="uni-countdown__splitor">{{dayText}}</text>
|
||||
<text :style="timeStyle" class="uni-countdown__number">{{ h }}</text>
|
||||
<text :style="splitorStyle" class="uni-countdown__splitor">{{ showColon ? ':' : hourText }}</text>
|
||||
<text :style="timeStyle" class="uni-countdown__number">{{ i }}</text>
|
||||
<text :style="splitorStyle" class="uni-countdown__splitor">{{ showColon ? ':' : minuteText }}</text>
|
||||
<text :style="timeStyle" class="uni-countdown__number">{{ s }}</text>
|
||||
<text v-if="!showColon" :style="splitorStyle" class="uni-countdown__splitor">{{secondText}}</text>
|
||||
<text v-if="showHour" :style="timeStyle" class="uni-countdown__number">{{ h }}</text>
|
||||
<text v-if="showHour" :style="splitorStyle" class="uni-countdown__splitor">{{ showColon ? ':' : hourText }}</text>
|
||||
<text v-if="showMinute" :style="timeStyle" class="uni-countdown__number">{{ i }}</text>
|
||||
<text v-if="showMinute" :style="splitorStyle" class="uni-countdown__splitor">{{ showColon ? ':' : minuteText }}</text>
|
||||
<text v-if="showSecond" :style="timeStyle" class="uni-countdown__number">{{ s }}</text>
|
||||
<text v-if="!showColon" :style="splitorStyle" class="uni-countdown__splitor">{{secondText}}</text>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
@@ -39,6 +39,18 @@
|
||||
name: 'UniCountdown',
|
||||
emits: ['timeup'],
|
||||
props: {
|
||||
showSecond: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
showMinute: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
showHour: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
showDay: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
|
||||
Reference in New Issue
Block a user