# `MingaEditor.State.ResourcePressure`
[🔗](https://github.com/jsmestad/minga/blob/main/lib/minga_editor/state/resource_pressure.ex#L1)

Tracks frontend-reported macOS low power mode and thermal pressure.

The BEAM owns render pacing, so this state converts resource-pressure signals from native frontends into a minimum render debounce. Normal operation remains at the caller-requested cadence.

# `t`

```elixir
@type t() :: %MingaEditor.State.ResourcePressure{
  low_power?: boolean(),
  thermal_state: thermal_state()
}
```

# `thermal_state`

```elixir
@type thermal_state() ::
  :nominal | :fair | :serious | :critical | {:unknown, non_neg_integer()}
```

Thermal pressure level reported by the native GUI frontend.

# `new`

```elixir
@spec new() :: t()
```

Returns the default no-pressure state.

# `render_delay_ms`

```elixir
@spec render_delay_ms(t()) :: non_neg_integer()
```

Returns the minimum render debounce in milliseconds for the current pressure level.

# `update`

```elixir
@spec update(t(), boolean(), thermal_state()) :: t()
```

Updates the current resource-pressure state.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
