This commit is contained in:
zk
2023-12-15 18:33:04 +08:00
parent d614f10bb5
commit 2cc8886c2d
31 changed files with 820 additions and 582 deletions
@@ -1,5 +1,5 @@
<template>
<div class="terminal-container">
<div class="terminal-container self">
<public-title title="睡眠" />
<div class="inner">
<div class="title">
@@ -21,12 +21,16 @@
type: String,
});
const sleepChart = ref<HTMLElement>();
onMounted(() => {
init();
});
watch(props, () => {
init();
});
// onMounted(() => {
// init();
// });
watch(
props,
() => {
init();
},
{ immediate: true }
);
const nums = ref({
avgShort: '',
avgLong: '',
@@ -68,13 +72,19 @@
}
</script>
<style scoped lang="less">
.terminal-container.self {
position: relative;
padding-bottom: 0 !important;
}
.inner {
height: calc(100% - 40px);
height: calc(100% - 20px);
.title {
color: #cfcfcf;
text-align: left;
padding: 1% 6%;
height: 30px;
line-height: 30px;
.count {
font-size: 28px;
@@ -82,7 +92,7 @@
}
.lightSleep {
padding-left: 2%;
padding: 3px 0 3px 2%;
}
}