hero section added
hero article menagment implemented in admin UI
This commit is contained in:
1 parent
6d65d5975c
commit
add12b2fbf
10 files changed
+604
-217
No files matched your search
@@ -398,6 +398,15 @@ export async function fetchRecentLiveBlogs(): Promise<LiveBlog[]> {
|
||||
return response.json();
|
||||
}
|
||||
|
||||
export async function fetchHeroArticle(): Promise<Article | null> {
|
||||
const response = await authFetch(`${API_BASE_URL}/articles/hero`);
|
||||
if (!response.ok) {
|
||||
throw new Error('Failed to fetch hero article');
|
||||
}
|
||||
const article = await response.json();
|
||||
return article || null;
|
||||
}
|
||||
|
||||
export async function fetchPinnedLiveBlogs(): Promise<LiveBlog[]> {
|
||||
const response = await authFetch(`${API_BASE_URL}/live-blogs/featured`);
|
||||
if (!response.ok) {
|
||||
|
||||
Reference in new issue
Block a user