use a11y_dom::{Document, Rendering, Semantics, Tier};
use a11y_report::{Finding, Severity};
#[derive(Debug, Clone, Copy)]
pub struct Meta {
pub ids: &'static [&'static str],
pub tier: Tier,
pub wcag: &'static [&'static str],
pub severity: Severity,
pub help: &'static str,
}
pub struct StructureRule<D: Document> {
pub meta: Meta,
pub run: fn(&D, &mut Vec<Finding>),
}
impl<D: Document> Clone for StructureRule<D> {
fn clone(&self) -> Self {
*self
}
}
impl<D: Document> Copy for StructureRule<D> {}
pub struct SemanticsRule<D: Semantics> {
pub meta: Meta,
pub run: fn(&D, &mut Vec<Finding>),
}
impl<D: Semantics> Clone for SemanticsRule<D> {
fn clone(&self) -> Self {
*self
}
}
impl<D: Semantics> Copy for SemanticsRule<D> {}
pub struct RenderingRule<D: Rendering> {
pub meta: Meta,
pub run: fn(&D, &mut Vec<Finding>),
}
impl<D: Rendering> Clone for RenderingRule<D> {
fn clone(&self) -> Self {
*self
}
}
impl<D: Rendering> Copy for RenderingRule<D> {}