Skip to content

Commit

Permalink
typing fix in navbar_nav()
Browse files Browse the repository at this point in the history
  • Loading branch information
volfpeter committed Jun 17, 2019
1 parent a21c96f commit 8f45118
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions markyp_bootstrap4/navbars.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
See https://getbootstrap.com/docs/4.0/components/navbar/.
"""

from typing import Optional, Tuple
from typing import Optional, Tuple, Type

from markyp import ElementType, PropertyValue, elements
from markyp_html import block, forms, inline, join, text
Expand Down Expand Up @@ -133,8 +133,8 @@ def navbar(*args: ElementType,

def navbar_nav(*args: ElementType,
class_: Optional[str] = None,
factory: elements.Element = block.div,
**kwargs: PropertyValue) -> block.nav:
factory: Type[elements.Element] = block.div,
**kwargs: PropertyValue) -> elements.Element:
"""
Creates a `navbar-nav` element using the given factory.
Expand Down Expand Up @@ -168,8 +168,8 @@ def navbar_toggler(*,
inline.span(class_="navbar-toggler-icon"),
class_=join("navbar-toggler", class_),
type="button",
**kwargs,
**{
**kwargs,
"data-toggle": "collapse",
"data-target": f"#{collapse_id}",
"aria-controls": collapse_id,
Expand Down

0 comments on commit 8f45118

Please sign in to comment.