import 'package:freezed_annotation/freezed_annotation.dart';

import '../../../../../api/marianumconnect/queries/get_ticker_page/get_ticker_page_response.dart';

part 'ticker_page_state.freezed.dart';
part 'ticker_page_state.g.dart';

/// Hydrated per-slug state of a single ticker page. PROXIED_FILE bytes are not
/// cached here — only [page] metadata persists; the PDF is fetched live.
@freezed
abstract class TickerPageState with _$TickerPageState {
  const factory TickerPageState({TickerPageResponse? page}) = _TickerPageState;

  factory TickerPageState.fromJson(Map<String, dynamic> json) =>
      _$TickerPageStateFromJson(json);
}
