import 'package:equatable/equatable.dart';

class LoadCommunitiesParam extends Equatable {
  const LoadCommunitiesParam({
    this.page = 1,
    this.size = 25,
    this.search = '',
    this.includeSpaces = true,
  });

  final int page;
  final int size;
  final String search;
  final bool includeSpaces;

  LoadCommunitiesParam copyWith({
    int? page,
    int? size,
    String? search,
    bool? includeSpaces,
  }) {
    return LoadCommunitiesParam(
      page: page ?? this.page,
      size: size ?? this.size,
      search: search ?? this.search,
      includeSpaces: includeSpaces ?? this.includeSpaces,
    );
  }

  @override
  List<Object?> get props => [page, size, search, includeSpaces];
}
