Files
YG_FT/frontend/dist/assets/usePolling-C71_cNpk.js
wuyongtao 2b10c013ce feat: 更新后端平台模块、前端组件及构建产物,新增工作计划文档
- 更新 backend 平台 API endpoints 及 platform_store
- 更新前端 ComputeNodesView、DataProcessCreateView、FineTuneCreateView 等组件
- 更新前端 API 模块(compute、fineTune)
- 重构 frontend/dist 构建产物(新 hash)
- 新增 docs/2026-07-24-work-plan.md 工作计划文档

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-24 10:27:52 +08:00

2 lines
792 B
JavaScript

import{G as g,H as p,y as d}from"./index-CD29OCdJ.js";function T(m,a=5e3,v={}){const{immediate:h=!0,pauseWhenHidden:o=!0,onError:r}=v,e=d(!1),n=d(!1);let t=null;function i(){t&&(clearTimeout(t),t=null)}function s(){if(i(),!e.value||o&&document.hidden)return;const l=typeof a=="function"?a():a;t=setTimeout(()=>void u(),Math.max(0,l))}async function u(){if(i(),!(!e.value||n.value)&&!(o&&document.hidden)){n.value=!0;try{await m()}catch(l){r==null||r(l)}finally{n.value=!1,s()}}}function c(){e.value=!1,i()}function y(){e.value||(e.value=!0,h?u():s())}function f(){!o||!e.value||(document.hidden?i():u())}return g(()=>document.addEventListener("visibilitychange",f)),p(()=>{c(),document.removeEventListener("visibilitychange",f)}),{start:y,stop:c,run:u,isActive:e,isRunning:n}}export{T as u};