Halaman unblock user

Add:
- app/(application)/(user)/profile/[id]/blocked-list.tsx
app/(application)/(user)/profile/[id]/detail-blocked.tsx
components/_ShareComponent/ListEmptyComponent.tsx
components/_ShareComponent/ListLoaderFooterComponent.tsx
components/_ShareComponent/ListSkeletonComponent.tsx
hooks/use-paginated-api.ts
service/api-client/api-blocked.ts

Fix:
modified:   app/(application)/(user)/profile/_layout.tsx
modified:   components/_ShareComponent/NewWrapper.tsx
modified:   components/index.ts
modified:   screens/Profile/ListPage.tsx
modified:   styles/global-styles.ts

### No Issue
This commit is contained in:
2025-11-28 13:55:48 +08:00
parent d471682ae7
commit 8a900e9469
12 changed files with 474 additions and 3 deletions

View File

@@ -0,0 +1,45 @@
import { apiConfig } from "../api-config";
/**
* @param id | Profile ID
* @param search | Search Query
* @param page | Page Number
*/
export async function apiGetBlocked({
id,
search,
page,
}: {
id: string;
search?: string;
page?: string;
}) {
const pageQuery = page ? `&page=${page}` : "";
const searchQuery = search ? `&search=${search}` : "";
try {
const response = await apiConfig.get(
`/mobile/block-user?id=${id}${pageQuery}${searchQuery}`
);
return response.data;
} catch (error) {
throw error;
}
}
export async function apiGetBlockedById({ id }: { id: string }) {
try {
const response = await apiConfig.get(`/mobile/block-user/${id}`);
return response.data;
} catch (error) {
throw error;
}
}
export async function apiUnblock({ id }: { id: string }) {
try {
const response = await apiConfig.delete(`/mobile/block-user/${id}`);
return response.data;
} catch (error) {
throw error;
}
}