added config option for preview scroll tolerance

This commit is contained in:
Daniel Fichtinger 2025-07-13 17:31:25 -04:00
parent fe0f338803
commit 10d1772a2d
5 changed files with 217 additions and 175 deletions

View file

@ -58,6 +58,17 @@ class BuildConfig:
include_drafts: bool = False
@dataclass
class ReloadConfig:
enabled: bool = True
scroll_tolerance: int = 100
@dataclass
class ServerConfig:
reload: ReloadConfig = field(default_factory=ReloadConfig)
IGNORELIST = [".marksman.toml"]
@ -71,6 +82,7 @@ class ZonaConfig:
markdown: MarkdownConfig = field(default_factory=MarkdownConfig)
build: BuildConfig = field(default_factory=BuildConfig)
blog: BlogConfig = field(default_factory=BlogConfig)
server: ServerConfig = field(default_factory=ServerConfig)
@classmethod
def from_file(cls, path: Path) -> "ZonaConfig":