SintAppBar class

A Sint-aware AppBar that integrates with Sint's routing stack.

Inherits AppBarChild's benefits:

  • Custom height (default 50.0, matching AppTheme.appBarHeight)
  • Auto-capitalize title (toggleable via capitalize)
  • Consistent dark elevated background color

Sint-specific benefits:

  • Back button uses Sint.back() (updates browser URL on web)
  • Fallback route when no back history exists
  • Auto-detects root routes to hide back button
  • Supports bottom: widget (TabBar)

Usage:

SintAppBar(title: 'Dashboard ERP')
SintAppBar(title: 'shop', actions: [...], fallbackRoute: '/home')
Inheritance
Implemented types

Constructors

SintAppBar({Key? key, String title = '', Widget? preTitle, Color? backgroundColor, List<Widget>? actions, bool? centerTitle, Widget? leading, double? titleSpacing, String fallbackRoute = '/', double elevation = 0, TextStyle? titleStyle, bool? showBackButton, PreferredSizeWidget? bottom, bool capitalize = true, double height = 50.0})
const

Properties

actions List<Widget>?
Action widgets on the right side of the AppBar.
final
backgroundColor Color?
Background color. If null, uses the app's elevated surface color. Pass Colors.transparent for modal/sheet pages.
final
bottom PreferredSizeWidget?
Bottom widget (e.g., TabBar).
final
capitalize bool
Whether to auto-capitalize the first letter of the title. Defaults to true (matching AppBarChild behavior).
final
centerTitle bool?
Whether to center the title. Defaults to null (platform default).
final
elevation double
AppBar elevation. Defaults to 0.
final
fallbackRoute String
Route to navigate to when there's no back history in the Sint stack. Defaults to '/'.
final
hashCode int
The hash code for this object.
no setterinherited
height double
Custom AppBar height. Defaults to 50.0 (matching AppTheme.appBarHeight).
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
leading Widget?
Custom leading widget. If provided, overrides the Sint back button.
final
preferredSize Size
The size this widget would prefer if it were otherwise unconstrained.
no setteroverride
preTitle Widget?
Optional widget displayed before the title (e.g., an icon or avatar).
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showBackButton bool?
Whether to show the back button. If null, automatically determined based on the current route and Sint stack.
final
title String
The title text displayed in the AppBar.
final
titleSpacing double?
Title spacing override.
final
titleStyle TextStyle?
Title text style override. If null, uses white bold text.
final

Methods

build(BuildContext context) Widget
Describes the part of the user interface represented by this widget.
override
createElement() StatelessElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited