mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-29 18:20:30 +08:00
Add short commit hash in about popup for macOS build
This commit is contained in:
@@ -1,8 +1,12 @@
|
||||
<script lang="ts">
|
||||
import type { ComponentProps } from "svelte";
|
||||
|
||||
import { onMount } from "svelte";
|
||||
import { invoke } from "@app/lib/invoke";
|
||||
|
||||
import AnnounceSwitch from "./AnnounceSwitch.svelte";
|
||||
import Border from "./Border.svelte";
|
||||
import CopyableId from "./CopyableId.svelte";
|
||||
import FontSizeSwitch from "./FontSizeSwitch.svelte";
|
||||
import Icon from "./Icon.svelte";
|
||||
import NakedButton from "./NakedButton.svelte";
|
||||
@@ -15,6 +19,12 @@
|
||||
popoverProps: Partial<ComponentProps<typeof Popover>>;
|
||||
}
|
||||
|
||||
let version = $state("");
|
||||
|
||||
onMount(async () => {
|
||||
version = await invoke<string>("version");
|
||||
});
|
||||
|
||||
const {
|
||||
compact = true,
|
||||
styleHeight = "2.5rem",
|
||||
@@ -39,6 +49,14 @@
|
||||
style:align-items="flex-start"
|
||||
style:gap="1rem"
|
||||
style:width="100%">
|
||||
<div
|
||||
class="global-flex"
|
||||
style:justify-content="space-between"
|
||||
style:width="100%"
|
||||
style:min-height="2rem">
|
||||
Version <CopyableId id={version} />
|
||||
</div>
|
||||
|
||||
<div
|
||||
class="global-flex"
|
||||
style:justify-content="space-between"
|
||||
|
||||
Reference in New Issue
Block a user