main
use crate::parse::{EmbedRule, Platform};
use crate::Category;
pub struct Douyin;
impl Platform for Douyin {
fn id(&self) -> &'static str {
"douyin"
}
fn name(&self) -> &'static str {
"抖音"
}
fn category(&self) -> Category {
Category::Social
}
fn domains(&self) -> &'static [&'static str] {
&["douyin.com", "iesdouyin.com"]
}
fn embed_rule(&self) -> Option<EmbedRule> {
Some(EmbedRule::vertical(r"^/video/(\d+)", "https://open.douyin.com/player/video?vid={id}&autoplay=0"))
}
}
pub static PLATFORM: Douyin = Douyin;