MCPcopy
hub / github.com/streamlit/streamlit / setBoolValue

Method setBoolValue

frontend/lib/src/WidgetStateManager.ts:541–550  ·  view source on GitHub ↗
(
    widget: WidgetInfo,
    value: boolean,
    source: Source,
    fragmentId: string | undefined
  )

Source from the content-addressed store, hash-verified

539 }
540
541 public setBoolValue(
542 widget: WidgetInfo,
543 value: boolean,
544 source: Source,
545 fragmentId: string | undefined
546 ): void {
547 this.createWidgetState(widget, source).boolValue = value
548 this.onWidgetValueChanged(widget.formId, source, fragmentId)
549 this.maybeSyncValueToUrl(widget.id, source, value)
550 }
551
552 public getIntValue(widget: WidgetInfo): number | undefined {
553 const state = this.getWidgetState(widget)

Callers 4

updateWidgetMgrStateFunction · 0.80
ExpanderFunction · 0.80
PopoverFunction · 0.80

Calls 3

createWidgetStateMethod · 0.95
onWidgetValueChangedMethod · 0.95
maybeSyncValueToUrlMethod · 0.95

Tested by

no test coverage detected