Skip to content

Commit 2b2da66

Browse files
committed
feat(ui): add latest release notes component and update homepage content
1 parent d19668c commit 2b2da66

5 files changed

Lines changed: 58 additions & 3 deletions

File tree

bun.lock

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<template>
2+
<div v-if="isLoading">Loading release notes...</div>
3+
<div v-else-if="isError">Error fetching release notes.</div>
4+
<div v-else>
5+
<h1 class="text-2xl font-bold">Latest Release Notes</h1>
6+
<div v-html="marked(releaseNotes)"></div>
7+
</div>
8+
</template>
9+
10+
<script lang="ts" setup>
11+
import { marked } from 'marked';
12+
const isLoading = ref(true);
13+
const releaseNotes = ref('');
14+
const isError = ref(false);
15+
16+
fetch('https://api.github.com/repos/iDescriptor/iDescriptor/releases/latest')
17+
.then((response) => response.json())
18+
.then((data) => {
19+
console.log('Latest release:', data);
20+
if (!data || !data.body || typeof data.body !== 'string') {
21+
throw new Error('Invalid release data');
22+
}
23+
releaseNotes.value = data.body;
24+
})
25+
.finally(() => {
26+
isLoading.value = false;
27+
})
28+
.catch((error) => {
29+
console.error('Error fetching latest release:', error);
30+
isError.value = true;
31+
});
32+
</script>

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
"dependencies": {
1313
"@nuxtjs/tailwindcss": "^6.14.0",
1414
"copy-to-clipboard": "^3.3.3",
15+
"marked": "^18.0.0",
1516
"nuxt": "^4.2.0",
1617
"typescript": "^5.9.3",
1718
"vue": "^3.5.22",

pages/index.vue

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,24 @@
22
<div class="flex flex-col">
33
<div class="flex flex-col items-center justify-center gap-2">
44
<h1 class="text-3xl font-bold">iDescriptor</h1>
5-
<span
6-
>A free, open-source, and cross-platform iDevice management tool
7-
</span>
5+
<div>
6+
Cross-platform, open-source and free idevice management tool written in
7+
Rust
8+
<img
9+
class="inline-flex items-center gap-1"
10+
src="https://rustacean.net/assets/rustacean-orig-noshadow.svg"
11+
width="25"
12+
/>
13+
and Qt
14+
</div>
815
</div>
16+
<h1 class="text-2xl font-bold m-auto mt-10">Win 11</h1>
17+
<Img
18+
aspectRatio="529/389"
19+
maxWidth="1058px"
20+
src="https://github.com/iDescriptor/iDescriptor/blob/main/resources/repo/win-11-mica-dark.png?raw=true"
21+
/>
22+
<h1 class="text-2xl font-bold m-auto mt-10">Other Platforms</h1>
923
<Img
1024
aspectRatio="529/389"
1125
maxWidth="1058px"
@@ -44,6 +58,7 @@
4458
alt="Platform"
4559
src="https://img.shields.io/badge/Platform-Windows%20%7C%20macOS%20%7C%20Linux-blue.svg"
4660
/>
61+
<img src="https://shields.io/badge/-Rust-3776AB?style=flat&logo=rust" />
4762
<img
4863
alt="Language"
4964
src="https://img.shields.io/badge/C++-20-hotpink.svg"
@@ -71,6 +86,9 @@
7186
Get iDescriptor
7287
</a>
7388
</div>
89+
90+
<LatestReleaseNotes class="m-auto mt-[5rem]" />
91+
7492
<div class="mt-[30rem]">//TODO</div>
7593
</div>
7694
</template>

public/favicon.ico

47.2 KB
Binary file not shown.

0 commit comments

Comments
 (0)