Skip to main content

RefreshIndicator

The Stac RefreshIndicator allows you to build a Flutter RefreshIndicator widget using JSON. To know more about the RefreshIndicator widget in Flutter, refer to the official documentation.

Properties​

PropertyTypeDescription
childMap<String, dynamic>?The widget below this widget in the tree.
displacementdoubleThe distance from the child's top or bottom edge to where the refresh indicator starts. Defaults to 40.
edgeOffsetdoubleThe offset where the indicator starts. Defaults to 0.
onRefreshMap<String, dynamic>?The callback that is called when the user has dragged the refresh indicator far enough to demonstrate that they want the app to refresh.
colorString?The color of the refresh indicator.
backgroundColorString?The background color of the refresh indicator.
semanticsLabelString?The semantic label for the refresh indicator.
semanticsValueString?The semantic value for the refresh indicator.
strokeWidthdoubleThe width of the refresh indicator's stroke. Defaults to RefreshProgressIndicator.defaultStrokeWidth.
triggerModeRefreshIndicatorTriggerModeThe mode that controls when the refresh indicator will be triggered. Defaults to RefreshIndicatorTriggerMode.onEdge.

Example JSON​

{
"type": "refreshIndicator",
"onRefresh": {
"actionType": "request",
"url": "https://raw.githubusercontent.com/StacDev/stac/main/examples/stac_gallery/assets/json/list_view_example.json",
"method": "get",
"contentType": "application/json"
}
}