浏览代码

typecheck

Michael Wang 4 年之前
父节点
当前提交
ad83a37f13

+ 1 - 0
package.json

@@ -6,6 +6,7 @@
     "start": "vite",
     "start": "vite",
     "dev": "vite --force",
     "dev": "vite --force",
     "build": "vue-tsc --noEmit && vite build",
     "build": "vue-tsc --noEmit && vite build",
+    "typecheck": "vue-tsc --noEmit",
     "serve": "vite preview"
     "serve": "vite preview"
   },
   },
   "dependencies": {
   "dependencies": {

+ 8 - 12
src/components/inspect/MarkHeader.vue

@@ -16,41 +16,37 @@
     <ul class="tw-flex tw-gap-2 tw-mb-0">
     <ul class="tw-flex tw-gap-2 tw-mb-0">
       <li @click="upScale" title="放大" style="line-height: 20px">
       <li @click="upScale" title="放大" style="line-height: 20px">
         <PlusCircleOutlined
         <PlusCircleOutlined
+          style="font-size: 20px"
           :style="{
           :style="{
-            'font-size': '20px',
             color: greaterThanOneScale ? 'red' : 'white',
             color: greaterThanOneScale ? 'red' : 'white',
           }"
           }"
         />
         />
       </li>
       </li>
       <li @click="downScale" title="缩小" style="line-height: 20px">
       <li @click="downScale" title="缩小" style="line-height: 20px">
         <MinusCircleOutlined
         <MinusCircleOutlined
+          style="font-size: 20px"
           :style="{
           :style="{
-            'font-size': '20px',
             color: lessThanOneScale ? 'red' : 'white',
             color: lessThanOneScale ? 'red' : 'white',
           }"
           }"
         />
         />
       </li>
       </li>
       <li @click="normalScale" title="适应" style="line-height: 20px">
       <li @click="normalScale" title="适应" style="line-height: 20px">
-        <FullscreenOutlined :style="{ 'font-size': '20px' }" />
+        <FullscreenOutlined style="font-size: 20px" />
       </li>
       </li>
     </ul>
     </ul>
     <div @click="toggleSettingMode" style="line-height: 20px">
     <div @click="toggleSettingMode" style="line-height: 20px">
       {{ modeName }} {{ store.setting.forceMode ? "" : "(切换)" }}
       {{ modeName }} {{ store.setting.forceMode ? "" : "(切换)" }}
     </div>
     </div>
     <div @click="toggleHistory" style="line-height: 20px" title="回看">
     <div @click="toggleHistory" style="line-height: 20px" title="回看">
-      <HistoryOutlined :style="{ 'font-size': '20px' }" />
+      <HistoryOutlined style="font-size: 20px" />
     </div>
     </div>
     <div class="tw-flex tw-place-items-center">
     <div class="tw-flex tw-place-items-center">
-      <UserOutlined
-        :style="{ 'font-size': '18px' }"
-        style="line-height: 18px"
-      />{{ store.setting.userName }}
+      <UserOutlined style="font-size: 18px; line-height: 18px" />{{
+        store.setting.userName
+      }}
     </div>
     </div>
     <div class="tw-flex tw-place-items-center">
     <div class="tw-flex tw-place-items-center">
-      <PoweroffOutlined
-        :style="{ 'font-size': '18px' }"
-        style="line-height: 18px"
-      />退出
+      <PoweroffOutlined style="font-size: 18px; line-height: 18px" />退出
     </div>
     </div>
   </div>
   </div>
 </template>
 </template>

+ 1 - 1
src/components/inspect/store.ts

@@ -10,7 +10,7 @@ const obj = {
     sheetConfig: [],
     sheetConfig: [],
     enableAllZero: false,
     enableAllZero: false,
     fileServer: "",
     fileServer: "",
-    marker: <Setting["marker"]>{},
+    userName: "",
     subject: <Setting["subject"]>{},
     subject: <Setting["subject"]>{},
     forceSpecialTag: false,
     forceSpecialTag: false,
     uiSetting: {
     uiSetting: {

+ 1 - 1
src/components/mark/Mark.vue

@@ -92,7 +92,7 @@ export default defineComponent({
     // TODO: 后续改掉,不需要
     // TODO: 后续改掉,不需要
     addInterval(() => {
     addInterval(() => {
       updateStatus();
       updateStatus();
-    }, 30 * 1000);
+    }, 5 * 60 * 1000);
 
 
     onMounted(async () => {
     onMounted(async () => {
       await updateMarkTask();
       await updateMarkTask();

+ 10 - 17
src/components/mark/MarkHeader.vue

@@ -41,7 +41,7 @@
         :title="`问题卷${store.status.problemCount}\n待仲裁${store.status.arbitrateCount}`"
         :title="`问题卷${store.status.problemCount}\n待仲裁${store.status.arbitrateCount}`"
         style="line-height: 20px"
         style="line-height: 20px"
       >
       >
-        <QuestionCircleOutlined :style="{ 'font-size': '20px' }" />
+        <QuestionCircleOutlined style="font-size: 20px" />
       </li>
       </li>
       <li>
       <li>
         进度<span class="highlight-text">{{ progress }}%</span>
         进度<span class="highlight-text">{{ progress }}%</span>
@@ -50,29 +50,29 @@
     <ul class="tw-flex tw-gap-2 tw-mb-0">
     <ul class="tw-flex tw-gap-2 tw-mb-0">
       <li @click="upScale" title="放大" style="line-height: 20px">
       <li @click="upScale" title="放大" style="line-height: 20px">
         <PlusCircleOutlined
         <PlusCircleOutlined
+          style="font-size: 20px"
           :style="{
           :style="{
-            'font-size': '20px',
             color: greaterThanOneScale ? 'red' : 'white',
             color: greaterThanOneScale ? 'red' : 'white',
           }"
           }"
         />
         />
       </li>
       </li>
       <li @click="downScale" title="缩小" style="line-height: 20px">
       <li @click="downScale" title="缩小" style="line-height: 20px">
         <MinusCircleOutlined
         <MinusCircleOutlined
+          style="font-size: 20px"
           :style="{
           :style="{
-            'font-size': '20px',
             color: lessThanOneScale ? 'red' : 'white',
             color: lessThanOneScale ? 'red' : 'white',
           }"
           }"
         />
         />
       </li>
       </li>
       <li @click="normalScale" title="适应" style="line-height: 20px">
       <li @click="normalScale" title="适应" style="line-height: 20px">
-        <FullscreenOutlined :style="{ 'font-size': '20px' }" />
+        <FullscreenOutlined style="font-size: 20px" />
       </li>
       </li>
     </ul>
     </ul>
     <div @click="toggleSettingMode" style="line-height: 20px">
     <div @click="toggleSettingMode" style="line-height: 20px">
       {{ modeName }} {{ store.setting.forceMode ? "" : "(切换)" }}
       {{ modeName }} {{ store.setting.forceMode ? "" : "(切换)" }}
     </div>
     </div>
     <div @click="toggleHistory" style="line-height: 20px" title="回看">
     <div @click="toggleHistory" style="line-height: 20px" title="回看">
-      <HistoryOutlined :style="{ 'font-size': '20px' }" />
+      <HistoryOutlined style="font-size: 20px" />
     </div>
     </div>
     <div
     <div
       class="tw-flex tw-place-items-center"
       class="tw-flex tw-place-items-center"
@@ -83,23 +83,16 @@
         $filters.datetimeFilter(store.setting.startTime)
         $filters.datetimeFilter(store.setting.startTime)
       "
       "
     >
     >
-      <ClockCircleOutlined
-        :style="{ 'font-size': '20px' }"
-        style="line-height: 20px"
-      />
+      <ClockCircleOutlined style="font-size: 20px; line-height: 20px" />
     </div>
     </div>
     <div @click="switchGroupDialog">{{ group?.title }}(切换)</div>
     <div @click="switchGroupDialog">{{ group?.title }}(切换)</div>
     <div class="tw-flex tw-place-items-center">
     <div class="tw-flex tw-place-items-center">
-      <UserOutlined
-        :style="{ 'font-size': '18px' }"
-        style="line-height: 18px"
-      />{{ store.setting.userName }}
+      <UserOutlined style="font-size: 18px; line-height: 18px" />{{
+        store.setting.userName
+      }}
     </div>
     </div>
     <div class="tw-flex tw-place-items-center">
     <div class="tw-flex tw-place-items-center">
-      <PoweroffOutlined
-        :style="{ 'font-size': '18px' }"
-        style="line-height: 18px"
-      />退出
+      <PoweroffOutlined style="font-size: 18px; line-height: 18px" />退出
     </div>
     </div>
   </div>
   </div>
 </template>
 </template>

+ 2 - 1
src/components/mark/store.ts

@@ -11,7 +11,7 @@ const obj = {
     sheetConfig: [],
     sheetConfig: [],
     enableAllZero: false,
     enableAllZero: false,
     fileServer: "",
     fileServer: "",
-    marker: <Setting["marker"]>{},
+    userName: "",
     subject: <Setting["subject"]>{},
     subject: <Setting["subject"]>{},
     forceSpecialTag: false,
     forceSpecialTag: false,
     uiSetting: {
     uiSetting: {
@@ -70,6 +70,7 @@ export function markScore() {}
 
 
 export const store = reactive(obj);
 export const store = reactive(obj);
 
 
+// 切换currentTask的同时,切换currentMarkResult
 watch(
 watch(
   () => store.currentTask,
   () => store.currentTask,
   () => {
   () => {