WidgetbookState class
- Inheritance
-
- Object
- ChangeNotifier
- WidgetbookState
Constructors
-
WidgetbookState.new({String? path, String? query, bool previewMode = false, Map<
String, String> queryParams = const {}, AppBuilder appBuilder = widgetsAppBuilder, List<WidgetbookAddon> ? addons, List<WidgetbookIntegration> ? integrations, required WidgetbookRoot root})
Properties
-
addons
→ List<
WidgetbookAddon> ? -
final
- appBuilder → AppBuilder
-
final
-
directories
→ List<
WidgetbookNode> -
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListeners → bool
-
Whether any listeners are currently registered.
no setterinherited
-
integrations
→ List<
WidgetbookIntegration> ? -
final
- isNext → bool
-
Return
true
if SAM (Story-Arg-Mode) structure is used.no setter - knobs ↔ KnobsRegistry
-
latefinal
- path ↔ String?
-
getter/setter pair
- previewMode ↔ bool
-
getter/setter pair
- query ↔ String?
-
getter/setter pair
-
queryParams
↔ Map<
String, String> -
getter/setter pair
- root → WidgetbookRoot
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
story
→ Story<
Widget, StoryArgs< ?Widget> > -
Returns the current active Story.
no setter
- uri → Uri
-
A Uri representation of the current state.
no setter
- useCase → WidgetbookUseCase?
-
no setter
Methods
-
addListener(
VoidCallback listener) → void -
Register a closure to be called when the object changes.
inherited
-
dispose(
) → void -
Discards any resources used by the object. After this is called, the
object is not in a usable state and should be discarded (calls to
addListener will throw after the object is disposed).
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeListener(
VoidCallback listener) → void -
Remove a previously registered closure from the list of closures that are
notified when the object changes.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
updateKnobValue<
T> (String label, T value) → void -
Updates Knob.value using the
label
to find the Knob. -
updateQueryField(
{required String group, required String field, required String value}) → void -
Update the field within the query
group
with the givenvalue
.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
of(
BuildContext context) → WidgetbookState -
Gets the current state using
context
.