MCPcopy
hub / github.com/autobrr/qui / getBetweenDurationDisplay

Function getBetweenDurationDisplay

web/src/components/query-builder/LeafCondition.tsx:331–337  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

329
330 // BETWEEN duration display - convert seconds to display unit
331 const getBetweenDurationDisplay = (): { minValue: string; maxValue: string; unit: number } => {
332 return {
333 minValue: condition.minValue === undefined ? "" : formatNumericInput(condition.minValue / betweenDurationUnit, 2),
334 maxValue: condition.maxValue === undefined ? "" : formatNumericInput(condition.maxValue / betweenDurationUnit, 2),
335 unit: betweenDurationUnit,
336 };
337 };
338
339 const handleBetweenDurationChange = (minVal: string, maxVal: string, unit: number) => {
340 setBetweenDurationUnit(unit);

Callers 1

LeafConditionFunction · 0.85

Calls 1

formatNumericInputFunction · 0.85

Tested by

no test coverage detected