// SPDX-FileCopyrightText: Politik im Blick developers
// SPDX-FileCopyrightText: Wolfgang Silbermayr <wolfgang@silbermayr.at>
//
// SPDX-License-Identifier: AGPL-3.0-or-later OR EUPL-1.2

use serde::{Deserialize, Serialize};

#[derive(
    Default, Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Serialize, Deserialize,
)]
pub struct Page(usize);

impl Page {
    pub const DEFAULT: Self = Self(0);
}

impl From<usize> for Page {
    fn from(value: usize) -> Self {
        Self(value)
    }
}

impl From<Page> for usize {
    fn from(Page(value): Page) -> Self {
        value
    }
}
