Chapter comments.

This commit is contained in:
角砂糖
2025-11-01 00:56:49 +08:00
parent 09a1d2821c
commit a9e76201f3
10 changed files with 935 additions and 74 deletions

View File

@@ -194,6 +194,7 @@ class Settings with ChangeNotifier {
'readerScrollSpeed': 1.0, // 0.5 - 3.0
'localFavoritesFirst': true,
'autoCloseFavoritePanel': false,
'showChapterComments': true, // show chapter comments in reader
};
operator [](String key) {
@@ -207,7 +208,11 @@ class Settings with ChangeNotifier {
}
}
void setEnabledComicSpecificSettings(String comicId, String sourceKey, bool enabled) {
void setEnabledComicSpecificSettings(
String comicId,
String sourceKey,
bool enabled,
) {
setReaderSetting(comicId, sourceKey, "enabled", enabled);
}
@@ -215,7 +220,8 @@ class Settings with ChangeNotifier {
if (comicId == null || sourceKey == null) {
return false;
}
return _data['comicSpecificSettings']["$comicId@$sourceKey"]?["enabled"] == true;
return _data['comicSpecificSettings']["$comicId@$sourceKey"]?["enabled"] ==
true;
}
dynamic getReaderSetting(String comicId, String sourceKey, String key) {