added config option for preview scroll tolerance
This commit is contained in:
parent
fe0f338803
commit
10d1772a2d
5 changed files with 217 additions and 175 deletions
|
@ -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":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue