import 'package:json_annotation/json_annotation.dart';

import '../view/pages/files/data/sort_options.dart';

part 'file_settings.g.dart';

@JsonSerializable()
class FileSettings {
  bool sortFoldersToTop;

  bool ascending;
  SortOption sortBy;

  FileSettings({
    required this.sortFoldersToTop,
    required this.ascending,
    required this.sortBy,
  });

  factory FileSettings.fromJson(Map<String, dynamic> json) =>
      _$FileSettingsFromJson(json);
  Map<String, dynamic> toJson() => _$FileSettingsToJson(this);
}
