diff options
| author | 2026-02-18 15:08:40 +0800 | |
|---|---|---|
| committer | 2026-02-18 15:08:40 +0800 | |
| commit | 1a103de2f1ef75cd73347953cbe27e14606df871 (patch) | |
| tree | eecb01f025bd9941aaa42ccebee02109cb5c7942 /packages/ui-new/src/components/instance-editor-modal.tsx | |
| parent | 2c3de3ac5ab1ab59f7245ab9cbdfda9b4e96dcb0 (diff) | |
| download | DropOut-1a103de2f1ef75cd73347953cbe27e14606df871.tar.gz DropOut-1a103de2f1ef75cd73347953cbe27e14606df871.zip | |
refactor(client): rewrite macros to generate client
Diffstat (limited to 'packages/ui-new/src/components/instance-editor-modal.tsx')
| -rw-r--r-- | packages/ui-new/src/components/instance-editor-modal.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/ui-new/src/components/instance-editor-modal.tsx b/packages/ui-new/src/components/instance-editor-modal.tsx index 012e62c..74e0873 100644 --- a/packages/ui-new/src/components/instance-editor-modal.tsx +++ b/packages/ui-new/src/components/instance-editor-modal.tsx @@ -196,7 +196,7 @@ export function InstanceEditorModal({ open, instance, onOpenChange }: Props) { const k = 1024; const sizes = ["B", "KB", "MB", "GB", "TB"]; const i = Math.floor(Math.log(bytes) / Math.log(k)); - return `${Math.round((bytes / Math.pow(k, i)) * 100) / 100} ${sizes[i]}`; + return `${Math.round((bytes / k ** i) * 100) / 100} ${sizes[i]}`; } function formatDate( |