TappableActionConfig.search constructor

const TappableActionConfig.search({
  1. bool requireNetwork = true,
  2. bool debounceTaps = true,
  3. Duration? coolDownDuration = const Duration(milliseconds: 300),
  4. Duration? delayBeforeFirstTapDuration,
  5. bool disableVisuallyDuringFirstDelay = true,
  6. Duration? minDisabledDuration,
  7. String? groupId,
  8. bool disableVisuallyDuringDebouncing = false,
  9. TapExecutionMode executionMode = TapExecutionMode.debounce,
  10. bool executeOnLeadingEdge = false,
  11. bool executeOnTrailingEdge = true,
  12. TapConcurrencyMode concurrencyMode = TapConcurrencyMode.drop,
  13. int rateLimitMaxTokens = 10,
  14. Duration rateLimitRefillInterval = const Duration(seconds: 1),
  15. int rateLimitTokensPerRefill = 5,
  16. void onMetrics(
    1. TapMetrics
    )?,
  17. bool enabled = true,
  18. Duration? maxDuration,
  19. String? debugName,
})

For search inputs - debounce with trailing edge.

Implementation

const TappableActionConfig.search({
  this.requireNetwork = true,
  this.debounceTaps = true,
  this.coolDownDuration = const Duration(milliseconds: 300),
  this.delayBeforeFirstTapDuration,
  this.disableVisuallyDuringFirstDelay = true,
  this.minDisabledDuration,
  this.groupId,
  this.disableVisuallyDuringDebouncing = false,
  // Search-specific: debounce, trailing edge only
  this.executionMode = TapExecutionMode.debounce,
  this.executeOnLeadingEdge = false,
  this.executeOnTrailingEdge = true,
  this.concurrencyMode = TapConcurrencyMode.drop,
  this.rateLimitMaxTokens = 10,
  this.rateLimitRefillInterval = const Duration(seconds: 1),
  this.rateLimitTokensPerRefill = 5,
  this.onMetrics,
  this.enabled = true,
  this.maxDuration,
  this.debugName,
});