MCPcopy
hub / github.com/AUTOMATIC1111/stable-diffusion-webui / on_after_component

Method on_after_component

modules/scripts.py:321–328  ·  view source on GitHub ↗

Calls callback after a component is created. The callback function is called with a single argument of type OnComponent.

(self, callback, *, elem_id)

Source from the content-addressed store, hash-verified

319 self.on_before_component_elem_id.append((elem_id, callback))
320
321 def on_after_component(self, callback, *, elem_id):
322 """
323 Calls callback after a component is created. The callback function is called with a single argument of type OnComponent.
324 """
325 if self.on_after_component_elem_id is None:
326 self.on_after_component_elem_id = []
327
328 self.on_after_component_elem_id.append((elem_id, callback))
329
330 def describe(self):
331 """unused"""

Callers 1

uiMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected