-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
rachana-egov
committed
Nov 21, 2024
1 parent
57edf6c
commit eab5c7a
Showing
7 changed files
with
1,571 additions
and
1 deletion.
There are no files selected for viewing
51 changes: 51 additions & 0 deletions
51
.../digit-ui-components/digit_components/lib/models/privacy_notice/privacy_notice_model.dart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
|
||
import 'package:freezed_annotation/freezed_annotation.dart'; | ||
|
||
part 'privacy_notice_model.freezed.dart'; | ||
part 'privacy_notice_model.g.dart'; | ||
|
||
@freezed | ||
class PrivacyNoticeModel with _$PrivacyNoticeModel { | ||
const factory PrivacyNoticeModel({ | ||
required String header, | ||
required String module, | ||
bool? active, | ||
List<ContentNoticeModel>? contents, | ||
}) = _PrivacyNoticeModel; | ||
|
||
factory PrivacyNoticeModel.fromJson(Map<String, dynamic> json) => _$PrivacyNoticeModelFromJson(json); | ||
} | ||
|
||
@freezed | ||
class ContentNoticeModel with _$ContentNoticeModel { | ||
const factory ContentNoticeModel({ | ||
String? header, | ||
List<DescriptionNoticeModel>? descriptions, | ||
}) = _ContentNoticeModel; | ||
|
||
factory ContentNoticeModel.fromJson(Map<String, dynamic> json) => _$ContentNoticeModelFromJson(json); | ||
} | ||
|
||
@freezed | ||
class DescriptionNoticeModel with _$DescriptionNoticeModel { | ||
const factory DescriptionNoticeModel({ | ||
String? text, | ||
String? type, | ||
bool? isBold, | ||
List<SubDescriptionNoticeModel>? subDescriptions, | ||
}) = _DescriptionNoticeModel; | ||
|
||
factory DescriptionNoticeModel.fromJson(Map<String, dynamic> json) => _$DescriptionNoticeModelFromJson(json); | ||
} | ||
|
||
@freezed | ||
class SubDescriptionNoticeModel with _$SubDescriptionNoticeModel { | ||
const factory SubDescriptionNoticeModel({ | ||
String? text, | ||
String? type, | ||
bool? isBold, | ||
bool? isSpaceRequired, | ||
}) = _SubDescriptionNoticeModel; | ||
|
||
factory SubDescriptionNoticeModel.fromJson(Map<String, dynamic> json) => _$SubDescriptionNoticeModelFromJson(json); | ||
} |
Oops, something went wrong.