GeoPickerTheme class
Comprehensive theme configuration shared by StatePicker and
CityPicker.
Every visual aspect (colors, borders, radii, typography, icons) can be overridden. Omitted fields fall back to sensible defaults pulled from the ambient ThemeData.
StatePicker(
countryIso2: 'US',
theme: GeoPickerTheme(
backgroundColor: Colors.white,
headerTextStyle: TextStyle(fontWeight: FontWeight.w700),
itemSelectedColor: Colors.blue.shade50,
),
)
- Annotations
Constructors
- GeoPickerTheme({Color? backgroundColor, Color? headerColor, TextStyle? headerTextStyle, Color? headerIconColor, Color? searchBarColor, TextStyle? searchTextStyle, TextStyle? searchHintStyle, Color? searchIconColor, Color? searchBarBorderColor, BorderRadius? searchBarBorderRadius, Color? searchCursorColor, Color? searchFocusedBorderColor, EdgeInsetsGeometry? searchContentPadding, InputDecoration? searchInputDecoration, Color? itemBackgroundColor, Color? itemSelectedColor, Color? itemSelectedBorderColor, Color? itemSelectedIconColor, BorderRadius? itemBorderRadius, EdgeInsetsGeometry? itemContentPadding, TextStyle? itemNameTextStyle, TextStyle? itemSelectedNameTextStyle, TextStyle? itemSubtitleTextStyle, TextStyle? dialogOptionTextStyle, Color? borderColor, BorderRadius? borderRadius, double? scrollbarThickness, Radius? scrollbarRadius, Color? shadowColor, double? elevation, IconData? closeIcon, IconData? searchIcon, IconData? clearIcon, IconData? selectedIcon, Widget? selectedIconWidget, double? selectedIconSize, IconData? emptyStateIcon, TextStyle? emptyStateTextStyle})
-
Comprehensive theme configuration shared by
StatePickerandCityPicker.const - GeoPickerTheme.dark()
-
A dark-theme default.
factory
- GeoPickerTheme.light()
-
A light-theme default that matches Material 3 surface colors.
factory
Properties
- backgroundColor → Color?
-
Background color of the picker surface.
final
- borderColor → Color?
-
Border color of the picker surface.
final
- borderRadius → BorderRadius?
-
Border radius of the picker surface.
final
- clearIcon → IconData?
-
Trailing icon shown when the search field has content.
final
- closeIcon → IconData?
-
Icon shown in the top-right of the header to dismiss the picker.
final
- dialogOptionTextStyle → TextStyle?
-
Text style applied to option labels inside the dialog variant.
final
- elevation → double?
-
Shadow elevation of the picker surface.
final
- emptyStateIcon → IconData?
-
Icon shown on the empty-results state.
final
- emptyStateTextStyle → TextStyle?
-
Text style used by the empty-results state.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- headerColor → Color?
-
Background color of the title / header row.
final
- headerIconColor → Color?
-
Color applied to the close / dismiss icon in the header.
final
- headerTextStyle → TextStyle?
-
Text style of the header title.
final
- itemBackgroundColor → Color?
-
Background color of an individual item row.
final
- itemBorderRadius → BorderRadius?
-
Border radius applied to item rows.
final
- itemContentPadding → EdgeInsetsGeometry?
-
Content padding inside an item row.
final
- itemNameTextStyle → TextStyle?
-
Text style of the primary label inside an item row.
final
- itemSelectedBorderColor → Color?
-
Border color drawn around the currently selected row.
final
- itemSelectedColor → Color?
-
Background color of the currently selected row.
final
- itemSelectedIconColor → Color?
-
Color of the trailing check icon shown on the selected row.
final
- itemSelectedNameTextStyle → TextStyle?
-
Text style of the primary label when the row is selected.
final
- itemSubtitleTextStyle → TextStyle?
-
Text style of the secondary label (subtitle) inside an item row.
final
- resolvedClearIcon → IconData
-
Returns the clear icon with a sensible default.
no setter
- resolvedCloseIcon → IconData
-
Returns the close icon with a sensible default.
no setter
- resolvedEmptyStateIcon → IconData
-
Returns the empty-state icon with a sensible default.
no setter
- resolvedSearchIcon → IconData
-
Returns the search icon with a sensible default.
no setter
- resolvedSelectedIcon → IconData
-
Returns the selected icon with a sensible default.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scrollbarRadius → Radius?
-
Corner radius of the list scrollbar.
final
- scrollbarThickness → double?
-
Thickness of the list scrollbar.
final
- searchBarBorderColor → Color?
-
Border color of the search field when idle.
final
- searchBarBorderRadius → BorderRadius?
-
Border radius of the search field.
final
- searchBarColor → Color?
-
Fill color of the search field.
final
- searchContentPadding → EdgeInsetsGeometry?
-
Content padding inside the search field.
final
- searchCursorColor → Color?
-
Cursor color of the search field.
final
- searchFocusedBorderColor → Color?
-
Border color of the search field when focused.
final
- searchHintStyle → TextStyle?
-
Hint text style of the search field.
final
- searchIcon → IconData?
-
Leading icon inside the search field.
final
- searchIconColor → Color?
-
Color of the leading search icon / trailing clear icon.
final
- searchInputDecoration → InputDecoration?
-
Fully-custom InputDecoration override for the search field. When
provided, takes precedence over the other
search*properties.final - searchTextStyle → TextStyle?
-
Text style of the search field input.
final
- selectedIcon → IconData?
-
Icon shown next to the currently selected row.
final
- selectedIconSize → double?
-
Size of the default selected icon. Defaults to 20.
final
- selectedIconWidget → Widget?
-
Custom widget shown next to the currently selected row.
Takes precedence over selectedIcon when provided.
final
- shadowColor → Color?
-
Shadow color beneath the picker surface.
final
Methods
-
copyWith(
{Color? backgroundColor, Color? headerColor, TextStyle? headerTextStyle, Color? headerIconColor, Color? searchBarColor, TextStyle? searchTextStyle, TextStyle? searchHintStyle, Color? searchIconColor, Color? searchBarBorderColor, BorderRadius? searchBarBorderRadius, Color? searchCursorColor, Color? searchFocusedBorderColor, EdgeInsetsGeometry? searchContentPadding, InputDecoration? searchInputDecoration, Color? itemBackgroundColor, Color? itemSelectedColor, Color? itemSelectedBorderColor, Color? itemSelectedIconColor, BorderRadius? itemBorderRadius, EdgeInsetsGeometry? itemContentPadding, TextStyle? itemNameTextStyle, TextStyle? itemSelectedNameTextStyle, TextStyle? itemSubtitleTextStyle, TextStyle? dialogOptionTextStyle, Color? borderColor, BorderRadius? borderRadius, double? scrollbarThickness, Radius? scrollbarRadius, Color? shadowColor, double? elevation, IconData? closeIcon, IconData? searchIcon, IconData? clearIcon, IconData? selectedIcon, Widget? selectedIconWidget, double? selectedIconSize, IconData? emptyStateIcon, TextStyle? emptyStateTextStyle}) → GeoPickerTheme - Returns a copy of this theme with the given fields replaced.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited