get ticker ui config
This commit is contained in:
parent
ccbac0a455
commit
1f2b5a9607
1 changed files with 11 additions and 1 deletions
|
@ -15,7 +15,7 @@ from typing import Iterator
|
|||
from fastapi import APIRouter, Depends
|
||||
from markdown import markdown
|
||||
|
||||
from ..config import Config
|
||||
from ..config import Config, TickerUIConfig
|
||||
from ..dav_common import webdav_ensure_path
|
||||
from ..dav_file import DavFile
|
||||
from .text import text_lister, text_unique
|
||||
|
@ -82,3 +82,13 @@ async def get_raw_ticker(
|
|||
ticker_content: str = Depends(get_ticker_content),
|
||||
) -> str:
|
||||
return ticker_content
|
||||
|
||||
|
||||
@ router.get(
|
||||
"/config",
|
||||
response_model=TickerUIConfig,
|
||||
)
|
||||
async def get_ui_config(
|
||||
cfg: Config = Depends(Config.get),
|
||||
) -> TickerUIConfig:
|
||||
return cfg.ticker.ui
|
||||
|
|
Loading…
Reference in a new issue