@@ -122,16 +122,14 @@ class EventHandler(MacroElement):
122122 >>> g.add_child(EventHandler("mouseout", reset))
123123 '''
124124
125- _template = Template (
126- """
125+ _template = Template ("""
127126 {% macro script(this, kwargs) %}
128127 {{ this._parent.get_name()}}.{{ this.method }}(
129128 {{ this.event|tojson}},
130129 {{ this.handler.js_code }}
131130 );
132131 {% endmacro %}
133- """
134- )
132+ """ )
135133
136134 def __init__ (self , event : str , handler : JsCode , once : bool = False ):
137135 super ().__init__ ()
@@ -144,13 +142,11 @@ def __init__(self, event: str, handler: JsCode, once: bool = False):
144142class ElementAddToElement (MacroElement ):
145143 """Abstract class to add an element to another element."""
146144
147- _template = Template (
148- """
145+ _template = Template ("""
149146 {% macro script(this, kwargs) %}
150147 {{ this.element_name }}.addTo({{ this.element_parent_name }});
151148 {% endmacro %}
152- """
153- )
149+ """ )
154150
155151 def __init__ (self , element_name : str , element_parent_name : str ):
156152 super ().__init__ ()
@@ -161,13 +157,11 @@ def __init__(self, element_name: str, element_parent_name: str):
161157class IncludeStatement (MacroElement ):
162158 """Generate an include statement on a class."""
163159
164- _template = Template (
165- """
160+ _template = Template ("""
166161 {{ this.leaflet_class_name }}.include(
167162 {{ this.options | tojavascript }}
168163 )
169- """
170- )
164+ """ )
171165
172166 def __init__ (self , leaflet_class_name : str , ** kwargs ):
173167 super ().__init__ ()
@@ -181,8 +175,7 @@ def render(self, *args, **kwargs):
181175class MethodCall (MacroElement ):
182176 """Abstract class to add an element to another element."""
183177
184- _template = Template (
185- """
178+ _template = Template ("""
186179 {% macro script(this, kwargs) %}
187180 {{ this.target }}.{{ this.method }}(
188181 {% for arg in this.args %}
@@ -191,8 +184,7 @@ class MethodCall(MacroElement):
191184 {{ this.kwargs | tojavascript }}
192185 );
193186 {% endmacro %}
194- """
195- )
187+ """ )
196188
197189 def __init__ (self , target : MacroElement , method : str , * args , ** kwargs ):
198190 super ().__init__ ()
0 commit comments