1use schema_loader::{asset_notification_bg_schema, color_schema, webp_url_schema};
2use schemars::JsonSchema;
3
4use serde::{Deserialize, Serialize};
5use tsify_next::Tsify;
6
7#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq, Tsify, JsonSchema)]
8pub struct EventDescription {
9 #[schemars(title = "Название эвента")]
10 pub name: String,
11 #[schemars(title = "Описание эвента")]
12 pub description: i18n::I18nString,
13 #[schemars(title = "Цвет эвента", schema_with = "color_schema")]
14 pub color: String,
15 #[schemars(title = "URL картинки", schema_with = "webp_url_schema")]
16 pub icon_url: String,
17 #[schemars(title = "URL фона(ленты)", schema_with = "webp_url_schema")]
18 pub bg_url: String,
19 #[schemars(title = "Фон (лента)", schema_with = "asset_notification_bg_schema")]
20 pub bg_path: String,
21 #[schemars(title = "URL текста", schema_with = "webp_url_schema")]
22 pub text_url: String,
23 #[schemars(title = "URL эффекта", schema_with = "webp_url_schema")]
24 pub effect_url: String,
25 #[schemars(title = "Время жизни эвента в миллисекундах")]
26 pub ttl_milliseconds: u64,
27}