feat(search): search feature via modrinth api for current project

This commit is contained in:
RafayAhmad7548 2026-09-01 19:46:24 +05:00
parent 1092071968
commit 10e3ca2efb
Signed by: RafayAhmad
SSH key fingerprint: SHA256:WURX8viobA1uawb4dWM3LqYrY+XPcZcXhAXAlrYdhtE
8 changed files with 226 additions and 32 deletions

17
src/models/search.rs Normal file
View file

@ -0,0 +1,17 @@
use serde::Deserialize;
#[derive(Deserialize)]
pub struct SearchResult {
pub hits: Vec<SearchHit>,
pub offset: u32,
pub limit: u32,
pub total_hits: u32,
}
#[derive(Deserialize)]
pub struct SearchHit {
pub slug: String,
pub author: String,
pub title: String,
pub description: String,
}