diff --git a/.claude/settings.local.json b/.claude/settings.local.json
new file mode 100644
index 0000000..1c8270f
--- /dev/null
+++ b/.claude/settings.local.json
@@ -0,0 +1,10 @@
+{
+ "permissions": {
+ "allow": [
+ "Bash(mkdir:*)",
+ "Bash(git add:*)"
+ ],
+ "deny": [],
+ "ask": []
+ }
+}
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..29a3a50
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,43 @@
+# Miscellaneous
+*.class
+*.log
+*.pyc
+*.swp
+.DS_Store
+.atom/
+.buildlog/
+.history
+.svn/
+migrate_working_dir/
+
+# IntelliJ related
+*.iml
+*.ipr
+*.iws
+.idea/
+
+# The .vscode folder contains launch configuration and tasks you configure in
+# VS Code which you may wish to be included in version control, so this line
+# is commented out by default.
+#.vscode/
+
+# Flutter/Dart/Pub related
+**/doc/api/
+**/ios/Flutter/.last_build_id
+.dart_tool/
+.flutter-plugins
+.flutter-plugins-dependencies
+.pub-cache/
+.pub/
+/build/
+
+# Symbolication related
+app.*.symbols
+
+# Obfuscation related
+app.*.map.json
+
+# Android Studio will place build artifacts here
+/android/app/debug
+/android/app/profile
+/android/app/release
diff --git a/.metadata b/.metadata
new file mode 100644
index 0000000..5eba523
--- /dev/null
+++ b/.metadata
@@ -0,0 +1,33 @@
+# This file tracks properties of this Flutter project.
+# Used by Flutter tool to assess capabilities and perform upgrades etc.
+#
+# This file should be version controlled and should not be manually edited.
+
+version:
+ revision: "67457e669f79e9f8d13d7a68fe09775fefbb79f4"
+ channel: "stable"
+
+project_type: app
+
+# Tracks metadata for the flutter migrate command
+migration:
+ platforms:
+ - platform: root
+ create_revision: 67457e669f79e9f8d13d7a68fe09775fefbb79f4
+ base_revision: 67457e669f79e9f8d13d7a68fe09775fefbb79f4
+ - platform: android
+ create_revision: 67457e669f79e9f8d13d7a68fe09775fefbb79f4
+ base_revision: 67457e669f79e9f8d13d7a68fe09775fefbb79f4
+ - platform: ios
+ create_revision: 67457e669f79e9f8d13d7a68fe09775fefbb79f4
+ base_revision: 67457e669f79e9f8d13d7a68fe09775fefbb79f4
+
+ # User provided section
+
+ # List of Local paths (relative to this file) that should be
+ # ignored by the migrate tool.
+ #
+ # Files that are not part of the templates will be ignored by default.
+ unmanaged_files:
+ - 'lib/main.dart'
+ - 'ios/Runner.xcodeproj/project.pbxproj'
diff --git a/analysis_options.yaml b/analysis_options.yaml
new file mode 100644
index 0000000..0d29021
--- /dev/null
+++ b/analysis_options.yaml
@@ -0,0 +1,28 @@
+# This file configures the analyzer, which statically analyzes Dart code to
+# check for errors, warnings, and lints.
+#
+# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
+# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
+# invoked from the command line by running `flutter analyze`.
+
+# The following line activates a set of recommended lints for Flutter apps,
+# packages, and plugins designed to encourage good coding practices.
+include: package:flutter_lints/flutter.yaml
+
+linter:
+ # The lint rules applied to this project can be customized in the
+ # section below to disable rules from the `package:flutter_lints/flutter.yaml`
+ # included above or to enable additional rules. A list of all available lints
+ # and their documentation is published at https://dart.dev/lints.
+ #
+ # Instead of disabling a lint rule for the entire project in the
+ # section below, it can also be suppressed for a single line of code
+ # or a specific dart file by using the `// ignore: name_of_lint` and
+ # `// ignore_for_file: name_of_lint` syntax on the line or in the file
+ # producing the lint.
+ rules:
+ # avoid_print: false # Uncomment to disable the `avoid_print` rule
+ # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
+
+# Additional information about this file can be found at
+# https://dart.dev/guides/language/analysis-options
diff --git a/android/.gitignore b/android/.gitignore
new file mode 100644
index 0000000..6f56801
--- /dev/null
+++ b/android/.gitignore
@@ -0,0 +1,13 @@
+gradle-wrapper.jar
+/.gradle
+/captures/
+/gradlew
+/gradlew.bat
+/local.properties
+GeneratedPluginRegistrant.java
+
+# Remember to never publicly share your keystore.
+# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
+key.properties
+**/*.keystore
+**/*.jks
diff --git a/android/app/build.gradle b/android/app/build.gradle
new file mode 100644
index 0000000..4dfcc0b
--- /dev/null
+++ b/android/app/build.gradle
@@ -0,0 +1,67 @@
+plugins {
+ id "com.android.application"
+ id "kotlin-android"
+ id "dev.flutter.flutter-gradle-plugin"
+}
+
+def localProperties = new Properties()
+def localPropertiesFile = rootProject.file('local.properties')
+if (localPropertiesFile.exists()) {
+ localPropertiesFile.withReader('UTF-8') { reader ->
+ localProperties.load(reader)
+ }
+}
+
+def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
+if (flutterVersionCode == null) {
+ flutterVersionCode = '1'
+}
+
+def flutterVersionName = localProperties.getProperty('flutter.versionName')
+if (flutterVersionName == null) {
+ flutterVersionName = '1.0'
+}
+
+android {
+ namespace "com.readful.daodaoshi.readful"
+ compileSdkVersion flutter.compileSdkVersion
+ ndkVersion flutter.ndkVersion
+
+ compileOptions {
+ sourceCompatibility JavaVersion.VERSION_1_8
+ targetCompatibility JavaVersion.VERSION_1_8
+ }
+
+ kotlinOptions {
+ jvmTarget = '1.8'
+ }
+
+ sourceSets {
+ main.java.srcDirs += 'src/main/kotlin'
+ }
+
+ defaultConfig {
+ // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
+ applicationId "com.readful.daodaoshi.readful"
+ // You can update the following values to match your application needs.
+ // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
+ minSdkVersion flutter.minSdkVersion
+ targetSdkVersion flutter.targetSdkVersion
+ versionCode flutterVersionCode.toInteger()
+ versionName flutterVersionName
+ }
+
+ buildTypes {
+ release {
+ // TODO: Add your own signing config for the release build.
+ // Signing with the debug keys for now, so `flutter run --release` works.
+ signingConfig signingConfigs.debug
+ }
+ }
+}
+
+flutter {
+ source '../..'
+}
+
+dependencies {}
diff --git a/android/app/src/debug/AndroidManifest.xml b/android/app/src/debug/AndroidManifest.xml
new file mode 100644
index 0000000..399f698
--- /dev/null
+++ b/android/app/src/debug/AndroidManifest.xml
@@ -0,0 +1,7 @@
+
+
+
+
diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml
new file mode 100644
index 0000000..9c8de5a
--- /dev/null
+++ b/android/app/src/main/AndroidManifest.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/android/app/src/main/kotlin/com/readful/daodaoshi/readful/MainActivity.kt b/android/app/src/main/kotlin/com/readful/daodaoshi/readful/MainActivity.kt
new file mode 100644
index 0000000..5816097
--- /dev/null
+++ b/android/app/src/main/kotlin/com/readful/daodaoshi/readful/MainActivity.kt
@@ -0,0 +1,6 @@
+package com.readful.daodaoshi.readful
+
+import io.flutter.embedding.android.FlutterActivity
+
+class MainActivity: FlutterActivity() {
+}
diff --git a/android/app/src/main/res/drawable-v21/launch_background.xml b/android/app/src/main/res/drawable-v21/launch_background.xml
new file mode 100644
index 0000000..f74085f
--- /dev/null
+++ b/android/app/src/main/res/drawable-v21/launch_background.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
diff --git a/android/app/src/main/res/drawable/launch_background.xml b/android/app/src/main/res/drawable/launch_background.xml
new file mode 100644
index 0000000..304732f
--- /dev/null
+++ b/android/app/src/main/res/drawable/launch_background.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
diff --git a/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
new file mode 100644
index 0000000..db77bb4
Binary files /dev/null and b/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ
diff --git a/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
new file mode 100644
index 0000000..17987b7
Binary files /dev/null and b/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ
diff --git a/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
new file mode 100644
index 0000000..09d4391
Binary files /dev/null and b/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ
diff --git a/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
new file mode 100644
index 0000000..d5f1c8d
Binary files /dev/null and b/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ
diff --git a/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
new file mode 100644
index 0000000..4d6372e
Binary files /dev/null and b/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ
diff --git a/android/app/src/main/res/values-night/styles.xml b/android/app/src/main/res/values-night/styles.xml
new file mode 100644
index 0000000..06952be
--- /dev/null
+++ b/android/app/src/main/res/values-night/styles.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
diff --git a/android/app/src/main/res/values/styles.xml b/android/app/src/main/res/values/styles.xml
new file mode 100644
index 0000000..cb1ef88
--- /dev/null
+++ b/android/app/src/main/res/values/styles.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
diff --git a/android/app/src/profile/AndroidManifest.xml b/android/app/src/profile/AndroidManifest.xml
new file mode 100644
index 0000000..399f698
--- /dev/null
+++ b/android/app/src/profile/AndroidManifest.xml
@@ -0,0 +1,7 @@
+
+
+
+
diff --git a/android/build.gradle b/android/build.gradle
new file mode 100644
index 0000000..5e9099c
--- /dev/null
+++ b/android/build.gradle
@@ -0,0 +1,36 @@
+buildscript {
+ ext.kotlin_version = '1.7.10'
+ repositories {
+ maven { url 'https://maven.aliyun.com/repository/google' }
+ maven { url 'https://maven.aliyun.com/repository/gradle-plugin' }
+ maven { url 'https://maven.aliyun.com/repository/jcenter' }
+ google()
+ mavenCentral()
+ }
+
+ dependencies {
+ classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
+ }
+}
+
+allprojects {
+ repositories {
+ maven { url 'https://maven.aliyun.com/repository/google' }
+ maven { url 'https://maven.aliyun.com/repository/public' }
+ maven { url 'https://maven.aliyun.com/repository/jcenter' }
+ google()
+ mavenCentral()
+ }
+}
+
+rootProject.buildDir = '../build'
+subprojects {
+ project.buildDir = "${rootProject.buildDir}/${project.name}"
+}
+subprojects {
+ project.evaluationDependsOn(':app')
+}
+
+tasks.register("clean", Delete) {
+ delete rootProject.buildDir
+}
diff --git a/android/gradle.properties b/android/gradle.properties
new file mode 100644
index 0000000..598d13f
--- /dev/null
+++ b/android/gradle.properties
@@ -0,0 +1,3 @@
+org.gradle.jvmargs=-Xmx4G
+android.useAndroidX=true
+android.enableJetifier=true
diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties
new file mode 100644
index 0000000..b5228c6
--- /dev/null
+++ b/android/gradle/wrapper/gradle-wrapper.properties
@@ -0,0 +1,5 @@
+distributionBase=GRADLE_USER_HOME
+distributionPath=wrapper/dists
+zipStoreBase=GRADLE_USER_HOME
+zipStorePath=wrapper/dists
+distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-7.5-all.zip
diff --git a/android/settings.gradle b/android/settings.gradle
new file mode 100644
index 0000000..7cd7128
--- /dev/null
+++ b/android/settings.gradle
@@ -0,0 +1,29 @@
+pluginManagement {
+ def flutterSdkPath = {
+ def properties = new Properties()
+ file("local.properties").withInputStream { properties.load(it) }
+ def flutterSdkPath = properties.getProperty("flutter.sdk")
+ assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
+ return flutterSdkPath
+ }
+ settings.ext.flutterSdkPath = flutterSdkPath()
+
+ includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle")
+
+ repositories {
+ google()
+ mavenCentral()
+ gradlePluginPortal()
+ }
+
+ plugins {
+ id "dev.flutter.flutter-gradle-plugin" version "1.0.0" apply false
+ }
+}
+
+plugins {
+ id "dev.flutter.flutter-plugin-loader" version "1.0.0"
+ id "com.android.application" version "7.3.0" apply false
+}
+
+include ":app"
diff --git a/ios/.gitignore b/ios/.gitignore
new file mode 100644
index 0000000..7a7f987
--- /dev/null
+++ b/ios/.gitignore
@@ -0,0 +1,34 @@
+**/dgph
+*.mode1v3
+*.mode2v3
+*.moved-aside
+*.pbxuser
+*.perspectivev3
+**/*sync/
+.sconsign.dblite
+.tags*
+**/.vagrant/
+**/DerivedData/
+Icon?
+**/Pods/
+**/.symlinks/
+profile
+xcuserdata
+**/.generated/
+Flutter/App.framework
+Flutter/Flutter.framework
+Flutter/Flutter.podspec
+Flutter/Generated.xcconfig
+Flutter/ephemeral/
+Flutter/app.flx
+Flutter/app.zip
+Flutter/flutter_assets/
+Flutter/flutter_export_environment.sh
+ServiceDefinitions.json
+Runner/GeneratedPluginRegistrant.*
+
+# Exceptions to above rules.
+!default.mode1v3
+!default.mode2v3
+!default.pbxuser
+!default.perspectivev3
diff --git a/ios/Flutter/AppFrameworkInfo.plist b/ios/Flutter/AppFrameworkInfo.plist
new file mode 100644
index 0000000..7c56964
--- /dev/null
+++ b/ios/Flutter/AppFrameworkInfo.plist
@@ -0,0 +1,26 @@
+
+
+
+
+ CFBundleDevelopmentRegion
+ en
+ CFBundleExecutable
+ App
+ CFBundleIdentifier
+ io.flutter.flutter.app
+ CFBundleInfoDictionaryVersion
+ 6.0
+ CFBundleName
+ App
+ CFBundlePackageType
+ FMWK
+ CFBundleShortVersionString
+ 1.0
+ CFBundleSignature
+ ????
+ CFBundleVersion
+ 1.0
+ MinimumOSVersion
+ 12.0
+
+
diff --git a/ios/Flutter/Debug.xcconfig b/ios/Flutter/Debug.xcconfig
new file mode 100644
index 0000000..592ceee
--- /dev/null
+++ b/ios/Flutter/Debug.xcconfig
@@ -0,0 +1 @@
+#include "Generated.xcconfig"
diff --git a/ios/Flutter/Release.xcconfig b/ios/Flutter/Release.xcconfig
new file mode 100644
index 0000000..592ceee
--- /dev/null
+++ b/ios/Flutter/Release.xcconfig
@@ -0,0 +1 @@
+#include "Generated.xcconfig"
diff --git a/ios/Runner.xcodeproj/project.pbxproj b/ios/Runner.xcodeproj/project.pbxproj
new file mode 100644
index 0000000..d95b0f3
--- /dev/null
+++ b/ios/Runner.xcodeproj/project.pbxproj
@@ -0,0 +1,614 @@
+// !$*UTF8*$!
+{
+ archiveVersion = 1;
+ classes = {
+ };
+ objectVersion = 54;
+ objects = {
+
+/* Begin PBXBuildFile section */
+ 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
+ 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
+ 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
+ 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
+ 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
+ 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
+ 331C808B294A63AB00263BE5 /* RunnerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 331C807B294A618700263BE5 /* RunnerTests.swift */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXContainerItemProxy section */
+ 331C8085294A63A400263BE5 /* PBXContainerItemProxy */ = {
+ isa = PBXContainerItemProxy;
+ containerPortal = 97C146E61CF9000F007C117D /* Project object */;
+ proxyType = 1;
+ remoteGlobalIDString = 97C146ED1CF9000F007C117D;
+ remoteInfo = Runner;
+ };
+/* End PBXContainerItemProxy section */
+
+/* Begin PBXCopyFilesBuildPhase section */
+ 9705A1C41CF9048500538489 /* Embed Frameworks */ = {
+ isa = PBXCopyFilesBuildPhase;
+ buildActionMask = 2147483647;
+ dstPath = "";
+ dstSubfolderSpec = 10;
+ files = (
+ );
+ name = "Embed Frameworks";
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXCopyFilesBuildPhase section */
+
+/* Begin PBXFileReference section */
+ 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; };
+ 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; };
+ 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; };
+ 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; };
+ 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
+ 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; };
+ 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; };
+ 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; };
+ 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
+ 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
+ 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
+ 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
+ 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
+ 331C807B294A618700263BE5 /* RunnerTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RunnerTests.swift; sourceTree = ""; };
+ 331C8081294A63A400263BE5 /* RunnerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RunnerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+ 97C146EB1CF9000F007C117D /* Frameworks */ = {
+ isa = PBXFrameworksBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+ 9740EEB11CF90186004384FC /* Flutter */ = {
+ isa = PBXGroup;
+ children = (
+ 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
+ 9740EEB21CF90195004384FC /* Debug.xcconfig */,
+ 7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
+ 9740EEB31CF90195004384FC /* Generated.xcconfig */,
+ );
+ name = Flutter;
+ sourceTree = "";
+ };
+ 331C8082294A63A400263BE5 /* RunnerTests */ = {
+ isa = PBXGroup;
+ children = (
+ 331C807B294A618700263BE5 /* RunnerTests.swift */,
+ );
+ path = RunnerTests;
+ sourceTree = "";
+ };
+ 97C146E51CF9000F007C117D = {
+ isa = PBXGroup;
+ children = (
+ 9740EEB11CF90186004384FC /* Flutter */,
+ 97C146F01CF9000F007C117D /* Runner */,
+ 97C146EF1CF9000F007C117D /* Products */,
+ 331C8082294A63A400263BE5 /* RunnerTests */,
+ );
+ sourceTree = "";
+ };
+ 97C146EF1CF9000F007C117D /* Products */ = {
+ isa = PBXGroup;
+ children = (
+ 97C146EE1CF9000F007C117D /* Runner.app */,
+ 331C8081294A63A400263BE5 /* RunnerTests.xctest */,
+ );
+ name = Products;
+ sourceTree = "";
+ };
+ 97C146F01CF9000F007C117D /* Runner */ = {
+ isa = PBXGroup;
+ children = (
+ 97C146FA1CF9000F007C117D /* Main.storyboard */,
+ 97C146FD1CF9000F007C117D /* Assets.xcassets */,
+ 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
+ 97C147021CF9000F007C117D /* Info.plist */,
+ 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
+ 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
+ 74858FAE1ED2DC5600515810 /* AppDelegate.swift */,
+ 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */,
+ );
+ path = Runner;
+ sourceTree = "";
+ };
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+ 331C8080294A63A400263BE5 /* RunnerTests */ = {
+ isa = PBXNativeTarget;
+ buildConfigurationList = 331C8087294A63A400263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */;
+ buildPhases = (
+ 331C807D294A63A400263BE5 /* Sources */,
+ 331C807E294A63A400263BE5 /* Frameworks */,
+ 331C807F294A63A400263BE5 /* Resources */,
+ );
+ buildRules = (
+ );
+ dependencies = (
+ 331C8086294A63A400263BE5 /* PBXTargetDependency */,
+ );
+ name = RunnerTests;
+ productName = RunnerTests;
+ productReference = 331C8081294A63A400263BE5 /* RunnerTests.xctest */;
+ productType = "com.apple.product-type.bundle.unit-test";
+ };
+ 97C146ED1CF9000F007C117D /* Runner */ = {
+ isa = PBXNativeTarget;
+ buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
+ buildPhases = (
+ 9740EEB61CF901F6004384FC /* Run Script */,
+ 97C146EA1CF9000F007C117D /* Sources */,
+ 97C146EB1CF9000F007C117D /* Frameworks */,
+ 97C146EC1CF9000F007C117D /* Resources */,
+ 9705A1C41CF9048500538489 /* Embed Frameworks */,
+ 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
+ );
+ buildRules = (
+ );
+ dependencies = (
+ );
+ name = Runner;
+ productName = Runner;
+ productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
+ productType = "com.apple.product-type.application";
+ };
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+ 97C146E61CF9000F007C117D /* Project object */ = {
+ isa = PBXProject;
+ attributes = {
+ BuildIndependentTargetsInParallel = YES;
+ LastUpgradeCheck = 1430;
+ ORGANIZATIONNAME = "";
+ TargetAttributes = {
+ 331C8080294A63A400263BE5 = {
+ CreatedOnToolsVersion = 14.0;
+ TestTargetID = 97C146ED1CF9000F007C117D;
+ };
+ 97C146ED1CF9000F007C117D = {
+ CreatedOnToolsVersion = 7.3.1;
+ LastSwiftMigration = 1100;
+ };
+ };
+ };
+ buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
+ compatibilityVersion = "Xcode 9.3";
+ developmentRegion = en;
+ hasScannedForEncodings = 0;
+ knownRegions = (
+ en,
+ Base,
+ );
+ mainGroup = 97C146E51CF9000F007C117D;
+ productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
+ projectDirPath = "";
+ projectRoot = "";
+ targets = (
+ 97C146ED1CF9000F007C117D /* Runner */,
+ 331C8080294A63A400263BE5 /* RunnerTests */,
+ );
+ };
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+ 331C807F294A63A400263BE5 /* Resources */ = {
+ isa = PBXResourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+ 97C146EC1CF9000F007C117D /* Resources */ = {
+ isa = PBXResourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
+ 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
+ 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
+ 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXShellScriptBuildPhase section */
+ 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
+ isa = PBXShellScriptBuildPhase;
+ alwaysOutOfDate = 1;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ inputPaths = (
+ "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}",
+ );
+ name = "Thin Binary";
+ outputPaths = (
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ shellPath = /bin/sh;
+ shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
+ };
+ 9740EEB61CF901F6004384FC /* Run Script */ = {
+ isa = PBXShellScriptBuildPhase;
+ alwaysOutOfDate = 1;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ inputPaths = (
+ );
+ name = "Run Script";
+ outputPaths = (
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ shellPath = /bin/sh;
+ shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
+ };
+/* End PBXShellScriptBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+ 331C807D294A63A400263BE5 /* Sources */ = {
+ isa = PBXSourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 331C808B294A63AB00263BE5 /* RunnerTests.swift in Sources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+ 97C146EA1CF9000F007C117D /* Sources */ = {
+ isa = PBXSourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */,
+ 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXTargetDependency section */
+ 331C8086294A63A400263BE5 /* PBXTargetDependency */ = {
+ isa = PBXTargetDependency;
+ target = 97C146ED1CF9000F007C117D /* Runner */;
+ targetProxy = 331C8085294A63A400263BE5 /* PBXContainerItemProxy */;
+ };
+/* End PBXTargetDependency section */
+
+/* Begin PBXVariantGroup section */
+ 97C146FA1CF9000F007C117D /* Main.storyboard */ = {
+ isa = PBXVariantGroup;
+ children = (
+ 97C146FB1CF9000F007C117D /* Base */,
+ );
+ name = Main.storyboard;
+ sourceTree = "";
+ };
+ 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = {
+ isa = PBXVariantGroup;
+ children = (
+ 97C147001CF9000F007C117D /* Base */,
+ );
+ name = LaunchScreen.storyboard;
+ sourceTree = "";
+ };
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+ 249021D3217E4FDB00AE95B9 /* Profile */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ CLANG_ANALYZER_NONNULL = YES;
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+ CLANG_CXX_LIBRARY = "libc++";
+ CLANG_ENABLE_MODULES = YES;
+ CLANG_ENABLE_OBJC_ARC = YES;
+ CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
+ CLANG_WARN_BOOL_CONVERSION = YES;
+ CLANG_WARN_COMMA = YES;
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
+ CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
+ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
+ CLANG_WARN_EMPTY_BODY = YES;
+ CLANG_WARN_ENUM_CONVERSION = YES;
+ CLANG_WARN_INFINITE_RECURSION = YES;
+ CLANG_WARN_INT_CONVERSION = YES;
+ CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
+ CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
+ CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
+ CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
+ CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
+ CLANG_WARN_STRICT_PROTOTYPES = YES;
+ CLANG_WARN_SUSPICIOUS_MOVE = YES;
+ CLANG_WARN_UNREACHABLE_CODE = YES;
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ COPY_PHASE_STRIP = NO;
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
+ ENABLE_NS_ASSERTIONS = NO;
+ ENABLE_STRICT_OBJC_MSGSEND = YES;
+ GCC_C_LANGUAGE_STANDARD = gnu99;
+ GCC_NO_COMMON_BLOCKS = YES;
+ GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
+ GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
+ GCC_WARN_UNDECLARED_SELECTOR = YES;
+ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
+ MTL_ENABLE_DEBUG_INFO = NO;
+ SDKROOT = iphoneos;
+ SUPPORTED_PLATFORMS = iphoneos;
+ TARGETED_DEVICE_FAMILY = "1,2";
+ VALIDATE_PRODUCT = YES;
+ };
+ name = Profile;
+ };
+ 249021D4217E4FDB00AE95B9 /* Profile */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
+ buildSettings = {
+ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+ CLANG_ENABLE_MODULES = YES;
+ CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ ENABLE_BITCODE = NO;
+ INFOPLIST_FILE = Runner/Info.plist;
+ LD_RUNPATH_SEARCH_PATHS = (
+ "$(inherited)",
+ "@executable_path/Frameworks",
+ );
+ PRODUCT_BUNDLE_IDENTIFIER = com.readful.daodaoshi.readful;
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
+ SWIFT_VERSION = 5.0;
+ VERSIONING_SYSTEM = "apple-generic";
+ };
+ name = Profile;
+ };
+ 331C8088294A63A400263BE5 /* Debug */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = AE0B7B92F70575B8D7E0D07E /* Pods-RunnerTests.debug.xcconfig */;
+ buildSettings = {
+ BUNDLE_LOADER = "$(TEST_HOST)";
+ CODE_SIGN_STYLE = Automatic;
+ CURRENT_PROJECT_VERSION = 1;
+ GENERATE_INFOPLIST_FILE = YES;
+ MARKETING_VERSION = 1.0;
+ PRODUCT_BUNDLE_IDENTIFIER = com.readful.daodaoshi.readful.RunnerTests;
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
+ SWIFT_OPTIMIZATION_LEVEL = "-Onone";
+ SWIFT_VERSION = 5.0;
+ TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner";
+ };
+ name = Debug;
+ };
+ 331C8089294A63A400263BE5 /* Release */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 89B67EB44CE7B6631473024E /* Pods-RunnerTests.release.xcconfig */;
+ buildSettings = {
+ BUNDLE_LOADER = "$(TEST_HOST)";
+ CODE_SIGN_STYLE = Automatic;
+ CURRENT_PROJECT_VERSION = 1;
+ GENERATE_INFOPLIST_FILE = YES;
+ MARKETING_VERSION = 1.0;
+ PRODUCT_BUNDLE_IDENTIFIER = com.readful.daodaoshi.readful.RunnerTests;
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ SWIFT_VERSION = 5.0;
+ TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner";
+ };
+ name = Release;
+ };
+ 331C808A294A63A400263BE5 /* Profile */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 640959BDD8F10B91D80A66BE /* Pods-RunnerTests.profile.xcconfig */;
+ buildSettings = {
+ BUNDLE_LOADER = "$(TEST_HOST)";
+ CODE_SIGN_STYLE = Automatic;
+ CURRENT_PROJECT_VERSION = 1;
+ GENERATE_INFOPLIST_FILE = YES;
+ MARKETING_VERSION = 1.0;
+ PRODUCT_BUNDLE_IDENTIFIER = com.readful.daodaoshi.readful.RunnerTests;
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ SWIFT_VERSION = 5.0;
+ TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner";
+ };
+ name = Profile;
+ };
+ 97C147031CF9000F007C117D /* Debug */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ CLANG_ANALYZER_NONNULL = YES;
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+ CLANG_CXX_LIBRARY = "libc++";
+ CLANG_ENABLE_MODULES = YES;
+ CLANG_ENABLE_OBJC_ARC = YES;
+ CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
+ CLANG_WARN_BOOL_CONVERSION = YES;
+ CLANG_WARN_COMMA = YES;
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
+ CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
+ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
+ CLANG_WARN_EMPTY_BODY = YES;
+ CLANG_WARN_ENUM_CONVERSION = YES;
+ CLANG_WARN_INFINITE_RECURSION = YES;
+ CLANG_WARN_INT_CONVERSION = YES;
+ CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
+ CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
+ CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
+ CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
+ CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
+ CLANG_WARN_STRICT_PROTOTYPES = YES;
+ CLANG_WARN_SUSPICIOUS_MOVE = YES;
+ CLANG_WARN_UNREACHABLE_CODE = YES;
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ COPY_PHASE_STRIP = NO;
+ DEBUG_INFORMATION_FORMAT = dwarf;
+ ENABLE_STRICT_OBJC_MSGSEND = YES;
+ ENABLE_TESTABILITY = YES;
+ GCC_C_LANGUAGE_STANDARD = gnu99;
+ GCC_DYNAMIC_NO_PIC = NO;
+ GCC_NO_COMMON_BLOCKS = YES;
+ GCC_OPTIMIZATION_LEVEL = 0;
+ GCC_PREPROCESSOR_DEFINITIONS = (
+ "DEBUG=1",
+ "$(inherited)",
+ );
+ GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
+ GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
+ GCC_WARN_UNDECLARED_SELECTOR = YES;
+ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
+ MTL_ENABLE_DEBUG_INFO = YES;
+ ONLY_ACTIVE_ARCH = YES;
+ SDKROOT = iphoneos;
+ TARGETED_DEVICE_FAMILY = "1,2";
+ };
+ name = Debug;
+ };
+ 97C147041CF9000F007C117D /* Release */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ CLANG_ANALYZER_NONNULL = YES;
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+ CLANG_CXX_LIBRARY = "libc++";
+ CLANG_ENABLE_MODULES = YES;
+ CLANG_ENABLE_OBJC_ARC = YES;
+ CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
+ CLANG_WARN_BOOL_CONVERSION = YES;
+ CLANG_WARN_COMMA = YES;
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
+ CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
+ CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
+ CLANG_WARN_EMPTY_BODY = YES;
+ CLANG_WARN_ENUM_CONVERSION = YES;
+ CLANG_WARN_INFINITE_RECURSION = YES;
+ CLANG_WARN_INT_CONVERSION = YES;
+ CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
+ CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
+ CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
+ CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
+ CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
+ CLANG_WARN_STRICT_PROTOTYPES = YES;
+ CLANG_WARN_SUSPICIOUS_MOVE = YES;
+ CLANG_WARN_UNREACHABLE_CODE = YES;
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ COPY_PHASE_STRIP = NO;
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
+ ENABLE_NS_ASSERTIONS = NO;
+ ENABLE_STRICT_OBJC_MSGSEND = YES;
+ GCC_C_LANGUAGE_STANDARD = gnu99;
+ GCC_NO_COMMON_BLOCKS = YES;
+ GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
+ GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
+ GCC_WARN_UNDECLARED_SELECTOR = YES;
+ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
+ MTL_ENABLE_DEBUG_INFO = NO;
+ SDKROOT = iphoneos;
+ SUPPORTED_PLATFORMS = iphoneos;
+ SWIFT_COMPILATION_MODE = wholemodule;
+ SWIFT_OPTIMIZATION_LEVEL = "-O";
+ TARGETED_DEVICE_FAMILY = "1,2";
+ VALIDATE_PRODUCT = YES;
+ };
+ name = Release;
+ };
+ 97C147061CF9000F007C117D /* Debug */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
+ buildSettings = {
+ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+ CLANG_ENABLE_MODULES = YES;
+ CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ ENABLE_BITCODE = NO;
+ INFOPLIST_FILE = Runner/Info.plist;
+ LD_RUNPATH_SEARCH_PATHS = (
+ "$(inherited)",
+ "@executable_path/Frameworks",
+ );
+ PRODUCT_BUNDLE_IDENTIFIER = com.readful.daodaoshi.readful;
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
+ SWIFT_OPTIMIZATION_LEVEL = "-Onone";
+ SWIFT_VERSION = 5.0;
+ VERSIONING_SYSTEM = "apple-generic";
+ };
+ name = Debug;
+ };
+ 97C147071CF9000F007C117D /* Release */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
+ buildSettings = {
+ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+ CLANG_ENABLE_MODULES = YES;
+ CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ ENABLE_BITCODE = NO;
+ INFOPLIST_FILE = Runner/Info.plist;
+ LD_RUNPATH_SEARCH_PATHS = (
+ "$(inherited)",
+ "@executable_path/Frameworks",
+ );
+ PRODUCT_BUNDLE_IDENTIFIER = com.readful.daodaoshi.readful;
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
+ SWIFT_VERSION = 5.0;
+ VERSIONING_SYSTEM = "apple-generic";
+ };
+ name = Release;
+ };
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+ 331C8087294A63A400263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 331C8088294A63A400263BE5 /* Debug */,
+ 331C8089294A63A400263BE5 /* Release */,
+ 331C808A294A63A400263BE5 /* Profile */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+ 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 97C147031CF9000F007C117D /* Debug */,
+ 97C147041CF9000F007C117D /* Release */,
+ 249021D3217E4FDB00AE95B9 /* Profile */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+ 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 97C147061CF9000F007C117D /* Debug */,
+ 97C147071CF9000F007C117D /* Release */,
+ 249021D4217E4FDB00AE95B9 /* Profile */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+/* End XCConfigurationList section */
+ };
+ rootObject = 97C146E61CF9000F007C117D /* Project object */;
+}
diff --git a/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata
new file mode 100644
index 0000000..919434a
--- /dev/null
+++ b/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata
@@ -0,0 +1,7 @@
+
+
+
+
+
diff --git a/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
new file mode 100644
index 0000000..18d9810
--- /dev/null
+++ b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
@@ -0,0 +1,8 @@
+
+
+
+
+ IDEDidComputeMac32BitWarning
+
+
+
diff --git a/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
new file mode 100644
index 0000000..f9b0d7c
--- /dev/null
+++ b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
@@ -0,0 +1,8 @@
+
+
+
+
+ PreviewsEnabled
+
+
+
diff --git a/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
new file mode 100644
index 0000000..87131a0
--- /dev/null
+++ b/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ios/Runner.xcworkspace/contents.xcworkspacedata b/ios/Runner.xcworkspace/contents.xcworkspacedata
new file mode 100644
index 0000000..1d526a1
--- /dev/null
+++ b/ios/Runner.xcworkspace/contents.xcworkspacedata
@@ -0,0 +1,7 @@
+
+
+
+
+
diff --git a/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
new file mode 100644
index 0000000..18d9810
--- /dev/null
+++ b/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
@@ -0,0 +1,8 @@
+
+
+
+
+ IDEDidComputeMac32BitWarning
+
+
+
diff --git a/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
new file mode 100644
index 0000000..f9b0d7c
--- /dev/null
+++ b/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
@@ -0,0 +1,8 @@
+
+
+
+
+ PreviewsEnabled
+
+
+
diff --git a/ios/Runner/AppDelegate.swift b/ios/Runner/AppDelegate.swift
new file mode 100644
index 0000000..70693e4
--- /dev/null
+++ b/ios/Runner/AppDelegate.swift
@@ -0,0 +1,13 @@
+import UIKit
+import Flutter
+
+@UIApplicationMain
+@objc class AppDelegate: FlutterAppDelegate {
+ override func application(
+ _ application: UIApplication,
+ didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
+ ) -> Bool {
+ GeneratedPluginRegistrant.register(with: self)
+ return super.application(application, didFinishLaunchingWithOptions: launchOptions)
+ }
+}
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json
new file mode 100644
index 0000000..d36b1fa
--- /dev/null
+++ b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json
@@ -0,0 +1,122 @@
+{
+ "images" : [
+ {
+ "size" : "20x20",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-20x20@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "20x20",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-20x20@3x.png",
+ "scale" : "3x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-29x29@1x.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-29x29@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-29x29@3x.png",
+ "scale" : "3x"
+ },
+ {
+ "size" : "40x40",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-40x40@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "40x40",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-40x40@3x.png",
+ "scale" : "3x"
+ },
+ {
+ "size" : "60x60",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-60x60@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "60x60",
+ "idiom" : "iphone",
+ "filename" : "Icon-App-60x60@3x.png",
+ "scale" : "3x"
+ },
+ {
+ "size" : "20x20",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-20x20@1x.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "20x20",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-20x20@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-29x29@1x.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-29x29@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "40x40",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-40x40@1x.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "40x40",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-40x40@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "76x76",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-76x76@1x.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "76x76",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-76x76@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "83.5x83.5",
+ "idiom" : "ipad",
+ "filename" : "Icon-App-83.5x83.5@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "1024x1024",
+ "idiom" : "ios-marketing",
+ "filename" : "Icon-App-1024x1024@1x.png",
+ "scale" : "1x"
+ }
+ ],
+ "info" : {
+ "version" : 1,
+ "author" : "xcode"
+ }
+}
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png
new file mode 100644
index 0000000..dc9ada4
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
new file mode 100644
index 0000000..7353c41
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
new file mode 100644
index 0000000..797d452
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png
new file mode 100644
index 0000000..6ed2d93
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
new file mode 100644
index 0000000..4cd7b00
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png
new file mode 100644
index 0000000..fe73094
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png
new file mode 100644
index 0000000..321773c
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
new file mode 100644
index 0000000..797d452
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png
new file mode 100644
index 0000000..502f463
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png
new file mode 100644
index 0000000..0ec3034
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png
new file mode 100644
index 0000000..0ec3034
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png
new file mode 100644
index 0000000..e9f5fea
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png
new file mode 100644
index 0000000..84ac32a
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png
new file mode 100644
index 0000000..8953cba
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
new file mode 100644
index 0000000..0467bf1
Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json
new file mode 100644
index 0000000..0bedcf2
--- /dev/null
+++ b/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json
@@ -0,0 +1,23 @@
+{
+ "images" : [
+ {
+ "idiom" : "universal",
+ "filename" : "LaunchImage.png",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "universal",
+ "filename" : "LaunchImage@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "universal",
+ "filename" : "LaunchImage@3x.png",
+ "scale" : "3x"
+ }
+ ],
+ "info" : {
+ "version" : 1,
+ "author" : "xcode"
+ }
+}
diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
new file mode 100644
index 0000000..9da19ea
Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ
diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
new file mode 100644
index 0000000..9da19ea
Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ
diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png
new file mode 100644
index 0000000..9da19ea
Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ
diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md
new file mode 100644
index 0000000..89c2725
--- /dev/null
+++ b/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md
@@ -0,0 +1,5 @@
+# Launch Screen Assets
+
+You can customize the launch screen with your own desired assets by replacing the image files in this directory.
+
+You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images.
\ No newline at end of file
diff --git a/ios/Runner/Base.lproj/LaunchScreen.storyboard b/ios/Runner/Base.lproj/LaunchScreen.storyboard
new file mode 100644
index 0000000..f2e259c
--- /dev/null
+++ b/ios/Runner/Base.lproj/LaunchScreen.storyboard
@@ -0,0 +1,37 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ios/Runner/Base.lproj/Main.storyboard b/ios/Runner/Base.lproj/Main.storyboard
new file mode 100644
index 0000000..f3c2851
--- /dev/null
+++ b/ios/Runner/Base.lproj/Main.storyboard
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ios/Runner/Info.plist b/ios/Runner/Info.plist
new file mode 100644
index 0000000..56cdf6d
--- /dev/null
+++ b/ios/Runner/Info.plist
@@ -0,0 +1,49 @@
+
+
+
+
+ CFBundleDevelopmentRegion
+ $(DEVELOPMENT_LANGUAGE)
+ CFBundleDisplayName
+ Readful
+ CFBundleExecutable
+ $(EXECUTABLE_NAME)
+ CFBundleIdentifier
+ $(PRODUCT_BUNDLE_IDENTIFIER)
+ CFBundleInfoDictionaryVersion
+ 6.0
+ CFBundleName
+ readful
+ CFBundlePackageType
+ APPL
+ CFBundleShortVersionString
+ $(FLUTTER_BUILD_NAME)
+ CFBundleSignature
+ ????
+ CFBundleVersion
+ $(FLUTTER_BUILD_NUMBER)
+ LSRequiresIPhoneOS
+
+ UILaunchStoryboardName
+ LaunchScreen
+ UIMainStoryboardFile
+ Main
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ CADisableMinimumFrameDurationOnPhone
+
+ UIApplicationSupportsIndirectInputEvents
+
+
+
diff --git a/ios/Runner/Runner-Bridging-Header.h b/ios/Runner/Runner-Bridging-Header.h
new file mode 100644
index 0000000..308a2a5
--- /dev/null
+++ b/ios/Runner/Runner-Bridging-Header.h
@@ -0,0 +1 @@
+#import "GeneratedPluginRegistrant.h"
diff --git a/ios/RunnerTests/RunnerTests.swift b/ios/RunnerTests/RunnerTests.swift
new file mode 100644
index 0000000..86a7c3b
--- /dev/null
+++ b/ios/RunnerTests/RunnerTests.swift
@@ -0,0 +1,12 @@
+import Flutter
+import UIKit
+import XCTest
+
+class RunnerTests: XCTestCase {
+
+ func testExample() {
+ // If you add code to the Runner application, consider adding tests here.
+ // See https://developer.apple.com/documentation/xctest for more information about using XCTest.
+ }
+
+}
diff --git a/learning_docs/01_项目结构与环境配置.md b/learning_docs/01_项目结构与环境配置.md
new file mode 100644
index 0000000..4ba2bd7
--- /dev/null
+++ b/learning_docs/01_项目结构与环境配置.md
@@ -0,0 +1,198 @@
+# Flutter 电子书阅读器项目 - 01:项目结构与环境配置
+
+## 一、项目创建与验证
+### 1. 执行命令
+```bash
+flutter create readful # 创建项目
+cd readful # 进入项目目录
+flutter run # 运行项目
+```
+
+### 2. 成功标志
+- 终端显示「Connected device」或检测到模拟器/真机
+- 能看到Flutter默认的计数器界面
+- `flutter doctor` 中所有检查项都是绿色对勾
+
+---
+
+## 二、Flutter项目核心结构解析
+| 目录/文件 | 作用说明 | 是否经常修改 |
+|-----------|---------|-------------|
+| `lib/main.dart` | 应用入口文件,所有Flutter程序的起点 | ✅ 经常修改 |
+| `pubspec.yaml` | 项目配置文件,管理依赖、资源、版本号 | ✅ 经常修改 |
+| `lib/` | 存放所有Dart源代码的核心目录 | ✅ 经常修改 |
+| `assets/` | 静态资源目录(图片、字体、电子书文件) | ✅ 经常修改 |
+| `android/` | Android平台原生代码 | ⚠️ 偶尔修改 |
+| `ios/` | iOS平台原生代码 | ⚠️ 偶尔修改 |
+| `test/` | 单元测试文件 | ⚠️ 开发后期使用 |
+
+> 💡 **小白提示**:作为Flutter初学者,你主要关注 `lib/` 目录、`pubspec.yaml` 文件和 `assets/` 目录即可。
+
+---
+
+## 三、pubspec.yaml 配置文件详解
+### 1. 基础配置说明
+```yaml
+name: readful # 项目名称(小写+下划线)
+description: 电子书阅读器 # 项目描述
+version: 1.0.0+1 # 版本号(1.0.0是版本,+1是构建号)
+
+environment: # Flutter和Dart版本要求
+ sdk: '>=3.0.0 <4.0.0' # Dart SDK版本范围
+
+dependencies: # 生产环境依赖(用户安装的包)
+ flutter:
+ sdk: flutter # Flutter框架核心(必须)
+ cupertino_icons: ^1.0.2 # iOS风格图标库
+
+dev_dependencies: # 开发环境依赖(开发工具)
+ flutter_test:
+ sdk: flutter # 测试框架
+ flutter_lints: ^2.0.0 # 代码规范检查工具
+
+flutter: # Flutter特定配置
+ uses-material-design: true # 启用Material Design图标库
+ # assets: # 资源配置(后续添加)
+ # - assets/images/
+ # - assets/books/
+```
+
+### 2. 依赖管理常用命令
+```bash
+flutter pub get # 下载pubspec.yaml中的依赖
+flutter pub add # 添加新依赖包
+flutter pub upgrade # 升级所有依赖包
+```
+
+---
+
+## 四、main.dart 入口代码详细解析
+### 1. 核心概念
+**Flutter的一切都是Widget(组件)**:
+- **StatelessWidget(无状态组件)**:UI不随数据变化,如静态文本、图标
+- **StatefulWidget(有状态组件)**:UI随数据变化,如计数器、电子书阅读进度
+
+### 2. 关键代码逐行解释
+```dart
+import 'package:flutter/material.dart'; // 引入Material Design组件库
+
+void main() { // Dart程序入口点(固定写法)
+ runApp(const MyApp()); // 启动Flutter应用,传入根组件
+}
+
+class MyApp extends StatelessWidget { // 定义根组件(无状态)
+ const MyApp({super.key}); // 构造函数
+
+ @override // 重写父类方法
+ Widget build(BuildContext context) { // 构建UI的核心方法(自动调用)
+ return MaterialApp( // Material Design应用容器
+ title: 'Readful', // 应用标题(在任务管理器显示)
+ theme: ThemeData( // 应用主题配置
+ primarySwatch: Colors.blue, // 主题颜色
+ ),
+ home: const MyHomePage(title: 'Readful 电子书阅读器'), // 首页组件
+ );
+ }
+}
+
+class MyHomePage extends StatefulWidget { // 首页组件(有状态)
+ const MyHomePage({super.key, required this.title}); // 构造函数
+
+ final String title; // 组件属性(从外部传入)
+
+ @override
+ State createState() => _MyHomePageState(); // 创建状态管理对象
+}
+
+class _MyHomePageState extends State { // 状态管理类
+ int _counter = 0; // 状态变量(存储组件数据)
+
+ void _incrementCounter() { // 状态更新方法
+ setState(() { // 关键!调用setState更新状态
+ _counter++; // 修改状态变量
+ }); // 会自动触发build()重新构建UI
+ }
+
+ @override
+ Widget build(BuildContext context) { // 构建UI方法
+ return Scaffold( // 页面基础布局组件
+ appBar: AppBar( // 顶部导航栏
+ title: Text(widget.title), // 使用父组件传入的title属性
+ ),
+ body: Center( // 页面主体内容
+ child: Column( // 垂直排列组件
+ mainAxisAlignment: MainAxisAlignment.center, // 垂直居中
+ children: [ // 子组件列表
+ const Text(
+ '点击次数:', // 静态文本
+ ),
+ Text(
+ '$_counter', // 显示状态变量(动态变化)
+ style: Theme.of(context).textTheme.headlineMedium, // 使用主题字体
+ ),
+ ],
+ ),
+ ),
+ floatingActionButton: FloatingActionButton( // 悬浮操作按钮
+ onPressed: _incrementCounter, // 点击事件绑定
+ tooltip: '增加', // 长按提示文本
+ child: const Icon(Icons.add), // 按钮图标
+ ),
+ );
+ }
+}
+```
+
+### 3. 关键API和组件说明
+| 组件/API | 作用 | 使用场景 |
+|---------|------|---------|
+| `MaterialApp` | Material Design应用容器 | 几乎所有Flutter应用的根组件 |
+| `Scaffold` | 页面基础布局 | 提供导航栏、主体、浮动按钮等页面结构 |
+| `AppBar` | 顶部导航栏 | 显示页面标题和操作按钮 |
+| `Center` | 居中布局 | 让子组件在父组件中居中显示 |
+| `Column` | 垂直布局 | 子组件从上到下排列 |
+| `Text` | 文本显示 | 显示各种文字内容 |
+| `FloatingActionButton` | 悬浮按钮 | 页面右下角的圆形操作按钮 |
+| `setState()` | 状态更新 | 更新StatefulWidget的状态数据 |
+| `Theme.of(context)` | 获取主题 | 访问应用的颜色、字体等主题配置 |
+
+---
+
+## 五、学习要点总结
+### 1. Flutter开发特点
+- **声明式UI**:描述UI应该长什么样,而不是如何操作DOM
+- **Widget组合**:复杂界面由简单Widget组合而成
+- **热重载**:修改代码后可立即看到效果,无需重新编译
+
+### 2. 常用开发命令
+```bash
+flutter run # 运行应用
+flutter devices # 查看可用设备
+flutter clean # 清理构建缓存
+flutter pub get # 获取依赖
+```
+
+### 3. 调试技巧
+- 使用 `print()` 输出调试信息
+- 利用热重载(按R键)快速测试UI修改
+- 通过 `debugPrint()` 输出性能相关的调试信息
+
+---
+
+## 下一步学习重点
+1. **数据模型设计**:如何表示电子书、章节、阅读进度等
+2. **本地存储**:使用Hive或SharedPreferences存储数据
+3. **UI组件**:学习更多Flutter内置组件构建电子书界面
+4. **状态管理**:学习更复杂的状态管理方案
+
+---
+
+## 常见问题解答
+**Q:为什么要区分StatelessWidget和StatefulWidget?**
+A:StatelessWidget性能更好,适用于静态内容;StatefulWidget适用于需要根据用户交互或数据变化更新UI的场景。
+
+**Q:setState()的作用是什么?**
+A:通知Flutter框架"这个组件的状态发生了变化,需要重新构建UI"。如果不调用setState(),即使修改了状态变量,UI也不会更新。
+
+**Q:MaterialApp和Scaffold有什么区别?**
+A:MaterialApp是整个应用的容器,提供路由、主题等全局功能;Scaffold是单个页面的基础布局,提供导航栏、主体区域等页面结构。
\ No newline at end of file
diff --git a/learning_docs/02_数据模型设计思路.md b/learning_docs/02_数据模型设计思路.md
new file mode 100644
index 0000000..659a262
--- /dev/null
+++ b/learning_docs/02_数据模型设计思路.md
@@ -0,0 +1,76 @@
+# Flutter 数据模型设计学习笔记
+
+## 一、数据模型设计的重要性
+在Flutter应用开发中,数据模型是整个应用的"地基":
+- **决定UI结构**:数据结构直接影响界面显示方式
+- **影响状态管理**:数据复杂度决定了状态管理方案的选型
+- **指导存储设计**:数据结构决定了如何进行本地存储和网络传输
+
+## 二、Flutter数据模型设计原则
+
+### 1. 不可变性原则(Immutability)
+**为什么需要不可变性?**
+- Flutter的Widget重建机制基于状态比较
+- 不可变对象更容易进行状态比较和更新检测
+- 避免"意外修改"导致的bug
+
+**实现方式:**
+- 所有字段使用`final`修饰
+- 提供`copyWith()`方法创建新对象
+- 不要提供修改字段的方法
+
+### 2. 序列化支持
+**为什么需要序列化?**
+- 本地存储需要将对象转换为可存储格式
+- 网络传输需要JSON格式
+- 状态管理工具需要状态保存功能
+
+**必需方法:**
+- `toMap()` - 将对象转换为Map
+- `fromMap()` - 从Map创建对象
+
+### 3. 空值安全
+**实践原则:**
+- 引用类型字段要有默认空值(如空列表、空Map)
+- 使用`?`表示可为null的字段
+- 构造函数中使用required标记必需字段
+
+## 三、电子书阅读器核心实体分析
+
+### 核心需求分析:
+1. **支持导入epub、mobi、txt文件** → 需要Book模型
+2. **划线(不同颜色)** → 需要Highlight模型
+3. **批注** → 需要Annotation模型
+4. **书签** → 需要Bookmark模型
+5. **书架管理** → 需要Bookshelf模型
+6. **阅读进度** → 需要ReadingProgress模型
+
+### 实体关系:
+- 一个书架包含多本书
+- 一本书属于多个书架
+- 一本书有多个章节、批注、高亮、书签
+- 一本书有一个阅读进度
+
+## 四、学习步骤
+
+### 第一步:创建Book模型(最核心的实体)
+包含字段:
+- 基本信息:id, title, author, publisher
+- 文件信息:filePath, format, fileSize
+- 阅读信息:status, addedDate, totalPages
+- 扩展信息:tags, rating, description
+
+### 第二步:创建书架相关模型
+- Bookshelf:书架信息
+- BookshelfBook:书架与书籍的关联
+
+### 第三步:创建阅读相关模型
+- ReadingProgress:阅读进度
+- Annotation:批注
+- Highlight:高亮
+- Bookmark:书签
+
+### 第四步:学习本地存储方案
+- 选择Hive数据库
+- 实现Repository模式
+- 配置数据持久化
\ No newline at end of file
diff --git a/learning_docs/03_数据模型实践与技巧.md b/learning_docs/03_数据模型实践与技巧.md
new file mode 100644
index 0000000..35935ed
--- /dev/null
+++ b/learning_docs/03_数据模型实践与技巧.md
@@ -0,0 +1,258 @@
+# Flutter 数据模型实践与技巧
+
+## 一、已完成的数据模型
+
+### 1. Book(书籍模型)✅
+**核心功能:**
+- 电子书基本信息管理(书名、作者、文件格式等)
+- 阅读状态跟踪(阅读中、已完成、待阅读)
+- 文件信息存储(路径、大小、格式)
+- 扩展信息支持(标签、评分、简介)
+
+**设计亮点:**
+- 使用`BookFormat`和`ReadingStatus`枚举确保类型安全
+- 提供`Book.create()`工厂方法简化对象创建
+- 完整的序列化支持(toMap/fromMap)
+- 不可变对象设计,所有字段使用final
+
+### 2. Highlight(高亮模型)✅
+**核心功能:**
+- 文本高亮记录(选中文本、位置范围)
+- 多颜色分类支持(5种颜色对应不同用途)
+- 章节关联(chapterId可选)
+- 时间戳记录
+
+**设计亮点:**
+- `HighlightColor`枚举提供语义化颜色分类
+- `Highlight.create()`工厂方法提供默认颜色
+- `textLength`计算属性获取高亮长度
+- `isInRange()`方法检查高亮范围
+
+## 二、Flutter数据模型设计最佳实践
+
+### 1. 不可变对象模式
+```dart
+class Book {
+ final String title; // 所有字段都是final
+
+ // 通过copyWith创建新对象,而不是修改原对象
+ Book copyWith({String? title}) {
+ return Book(title: title ?? this.title);
+ }
+}
+```
+
+**优势:**
+- 🔒 线程安全
+- 🔄 状态管理友好(Flutter状态管理依赖对象比较)
+- 🐛 减少意外修改bug
+
+### 2. 空值安全设计
+```dart
+final String title; // 必需字段
+final String? author; // 可为null的字段
+final List tags = const []; // 默认空列表,避免null
+```
+
+**关键符号:**
+- `final`:字段只能在构造函数中赋值
+- `?`:字段可以为null
+- `required`:构造函数必需参数
+- `const []`:不可变空列表
+
+### 3. 枚举的正确使用
+```dart
+enum BookFormat { epub, mobi, txt, pdf }
+
+// 存储时:枚举 → 字符串
+'format': format.name, // "epub"
+
+// 读取时:字符串 → 枚举
+format: BookFormat.values.firstWhere((e) => e.name == "epub")
+```
+
+### 4. 工厂构造函数模式
+```dart
+// 便利构造函数
+factory Book.create({
+ required String title,
+ required String filePath,
+ // 自动生成字段
+}) {
+ return Book(
+ id: _generateId(), // 自动生成ID
+ addedDate: DateTime.now(), // 自动设置时间
+ status: ReadingStatus.pending, // 默认状态
+ title: title,
+ filePath: filePath,
+ // ...
+ );
+}
+```
+
+**设计原则:**
+- 自动生成ID和时间戳
+- 为常用参数提供默认值
+- 封装复杂的创建逻辑
+
+### 5. 完整的对象生命周期管理
+```dart
+class Book {
+ // 构造函数
+ const Book({required this.title});
+
+ // 创建便利方法
+ factory Book.create({...}) { ... }
+
+ // 修改方法
+ Book copyWith({...}) { ... }
+
+ // 序列化方法
+ Map toMap() { ... }
+ factory Book.fromMap(Map map) { ... }
+
+ // 调试方法
+ String toString() { ... }
+
+ // 比较方法
+ bool operator ==(Object other) { ... }
+ int get hashCode => ...;
+}
+```
+
+## 三、常见陷阱与解决方案
+
+### 1. 枚举序列化错误
+```dart
+// ❌ 错误:直接存储枚举对象
+'format': format, // 会导致序列化失败
+
+// ✅ 正确:转换为字符串
+'format': format.name,
+
+// 读取时反向转换
+format: BookFormat.values.firstWhere((e) => e.name == map['format'])
+```
+
+### 2. copyWith方法遗漏字段
+```dart
+// ❌ 错误:遗漏了chapterId参数
+Highlight copyWith({String? bookId, ...}) {
+ return Highlight(
+ bookId: bookId ?? this.bookId,
+ // 缺少 chapterId 参数
+ );
+}
+
+// ✅ 正确:包含所有字段
+Highlight copyWith({String? bookId, String? chapterId, ...}) {
+ return Highlight(
+ bookId: bookId ?? this.bookId,
+ chapterId: chapterId ?? this.chapterId, // 确保完整性
+ );
+}
+```
+
+### 3. 工厂方法参数设计错误
+```dart
+// ❌ 错误:要求用户传入自动生成的字段
+factory Highlight.create({
+ required String id, // 用户不应该手动传入ID
+ required DateTime createdTime, // 应该自动生成
+ // ...
+});
+
+// ✅ 正确:只要求用户必须提供的字段
+factory Highlight.create({
+ required String bookId,
+ required String selectedText,
+ HighlightColor color = HighlightColor.yellow, // 提供默认值
+ String? chapterId,
+}) {
+ return Highlight(
+ id: _generateId(), // 自动生成
+ createdTime: DateTime.now(), // 自动设置
+ // ...
+ );
+}
+```
+
+## 四、性能优化技巧
+
+### 1. 字符串插值优于字符串拼接
+```dart
+// ❌ 性能较差
+return 'Book(id: ' + id + ', title: ' + title + ')';
+
+// ✅ 性能更好
+return 'Book(id: $id, title: $title)';
+```
+
+### 2. 避免重复计算
+```dart
+class Highlight {
+ // ❌ 每次调用都重新计算
+ int getTextLength() => endIndex - startIndex;
+
+ // ✅ 使用getter缓存计算结果
+ int get textLength => endIndex - startIndex;
+}
+```
+
+### 3. 合理使用const构造函数
+```dart
+// 对于常量值使用const
+static const List emptyList = [];
+
+// 构造函数标记为const
+const Book({required this.title});
+```
+
+## 五、调试与测试技巧
+
+### 1. 有意义的toString实现
+```dart
+@override
+String toString() {
+ return 'Book(id: $id, title: $title, format: $format)';
+}
+```
+
+### 2. 完整的对象比较
+```dart
+@override
+bool operator ==(Object other) {
+ if (identical(this, other)) return true; // 先检查引用相等
+ return other is Book && other.id == id; // 再检查关键字段
+}
+
+@override
+int get hashCode => id.hashCode; // 基于相同字段生成
+```
+
+## 六、下一步计划
+
+### 待完成的模型:
+1. **Annotation(批注模型)** - 处理用户笔记和感想
+2. **Bookmark(书签模型)** - 管理阅读位置标记
+3. **Bookshelf(书架模型)** - 书籍分类管理
+4. **ReadingProgress(阅读进度模型)** - 跟踪阅读进度
+
+### 待学习的技术:
+1. **本地存储方案** - Hive数据库集成
+2. **Repository模式** - 数据访问层设计
+3. **状态管理** - Provider/Riverpod集成
+4. **文件处理** - EPUB/MOBI解析
+
+## 七、代码质量检查清单
+
+### ✅ 数据模型检查清单:
+- [ ] 所有字段使用final
+- [ ] 正确使用空值安全语法(?和required)
+- [ ] 实现copyWith方法并包含所有字段
+- [ ] 正确的序列化(枚举转换)
+- [ ] 提供工厂方法简化创建
+- [ ] 重写toString、equals、hashCode
+- [ ] 添加有意义的文档注释
+- [ ] 提供默认值避免null
+- [ ] 使用计算属性优化性能
\ No newline at end of file
diff --git a/lib/main.dart b/lib/main.dart
new file mode 100644
index 0000000..9afb33f
--- /dev/null
+++ b/lib/main.dart
@@ -0,0 +1,22 @@
+import "package:flutter/material.dart";
+
+void main() {
+ runApp(const Myapp());
+}
+
+
+class Myapp extends StatelessWidget{
+ const Myapp({super.key});
+
+ @override
+ Widget build(BuildContext context) {
+ return MaterialApp(
+ title: "Readful",
+ theme: ThemeData(primarySwatch: Colors.blue),
+ home: Scaffold(
+ appBar: AppBar(title: const Text('readful 电子书阅读器')),
+ body: const Center(child: Text('欢迎使用 readful')),
+ ),
+ );
+ }
+}
\ No newline at end of file
diff --git a/lib/models/book.dart b/lib/models/book.dart
new file mode 100644
index 0000000..fefffe7
--- /dev/null
+++ b/lib/models/book.dart
@@ -0,0 +1,236 @@
+// 电子书数据模型
+// 这是Flutter中数据模型的标准写法,后续其他模型都可以参考这个结构
+
+/// 书籍文件格式枚举
+/// 使用enum提供类型安全的枚举值
+enum BookFormat {
+ epub, // EPUB格式电子书
+ mobi, // Kindle MOBI格式
+ txt, // 纯文本格式
+ pdf // PDF格式
+}
+
+/// 阅读状态枚举
+enum ReadingStatus {
+ reading, // 阅读中
+ completed, // 已完成
+ pending // 待阅读
+}
+
+/// 书籍数据模型
+///
+/// 设计原则:
+/// 1. 所有字段都是final(不可变性)
+/// 2. 提供copyWith方法创建新对象
+/// 3. 提供序列化和反序列化方法
+/// 4. 使用空值安全语法
+class Book {
+ /// 唯一标识符 - 使用UUID确保全局唯一
+ final String id;
+
+ /// 书名 - 必需字段
+ final String title;
+
+ /// 作者 - 可为null(因为有些书籍可能没有作者信息)
+ final String? author;
+
+ /// 出版社 - 可选字段
+ final String? publisher;
+
+ /// 书籍简介 - 可选字段
+ final String? description;
+
+ /// 封面图片路径 - 可选字段
+ final String? coverImagePath;
+
+ /// 文件路径 - 必需字段,指向实际的电子书文件
+ final String filePath;
+
+ /// 文件格式 - 必需字段
+ final BookFormat format;
+
+ /// 文件大小(字节)- 必需字段
+ final int fileSize;
+
+ /// 添加到书架的时间 - 必需字段
+ final DateTime addedDate;
+
+ /// 阅读状态 - 必需字段
+ final ReadingStatus status;
+
+ /// 评分(1-5星)- 可选字段
+ final double? rating;
+
+ /// 标签列表 - 使用空列表作为默认值,避免null指针
+ final List tags;
+
+ /// 总页数 - 必需字段
+ final int totalPages;
+
+ /// 构造函数
+ ///
+ /// 使用required关键字标记必需字段,这是Flutter的空值安全特性
+ const Book({
+ required this.id, // 必需
+ required this.title, // 必需
+ this.author, // 可选
+ this.publisher, // 可选
+ this.description, // 可选
+ this.coverImagePath, // 可选
+ required this.filePath, // 必需
+ required this.format, // 必需
+ required this.fileSize, // 必需
+ required this.addedDate, // 必需
+ required this.status, // 必需
+ this.rating, // 可选
+ this.tags = const [], // 默认空列表,避免null
+ required this.totalPages, // 必需
+ });
+
+ /// copyWith方法 - 创建对象的副本
+ ///
+ /// 这是Flutter中不可变对象的标准模式
+ /// 当需要修改对象时,不是直接修改原对象,而是创建一个新对象
+ ///
+ /// 使用示例:
+ /// ```dart
+ /// final newBook = book.copyWith(
+ /// title: "新书名",
+ /// status: ReadingStatus.completed,
+ /// );
+ /// ```
+ Book copyWith({
+ String? id,
+ String? title,
+ String? author,
+ String? publisher,
+ String? description,
+ String? coverImagePath,
+ String? filePath,
+ BookFormat? format,
+ int? fileSize,
+ DateTime? addedDate,
+ ReadingStatus? status,
+ double? rating,
+ List? tags,
+ int? totalPages,
+ }) {
+ return Book(
+ id: id ?? this.id, // 如果id不为null就使用新值,否则保持原值
+ title: title ?? this.title,
+ author: author ?? this.author,
+ publisher: publisher ?? this.publisher,
+ description: description ?? this.description,
+ coverImagePath: coverImagePath ?? this.coverImagePath,
+ filePath: filePath ?? this.filePath,
+ format: format ?? this.format,
+ fileSize: fileSize ?? this.fileSize,
+ addedDate: addedDate ?? this.addedDate,
+ status: status ?? this.status,
+ rating: rating ?? this.rating,
+ tags: tags ?? this.tags,
+ totalPages: totalPages ?? this.totalPages,
+ );
+ }
+
+ /// toMap方法 - 将对象转换为Map
+ ///
+ /// 这个方法用于:
+ /// 1. 本地存储(如Hive数据库)
+ /// 2. 网络传输(转换为JSON)
+ /// 3. 状态保存
+ Map toMap() {
+ return {
+ 'id': id,
+ 'title': title,
+ 'author': author,
+ 'publisher': publisher,
+ 'description': description,
+ 'coverImagePath': coverImagePath,
+ 'filePath': filePath,
+ 'format': format.name, // 枚举值转换为字符串
+ 'fileSize': fileSize,
+ 'addedDate': addedDate.toIso8601String(), // DateTime转换为字符串
+ 'status': status.name,
+ 'rating': rating,
+ 'tags': tags, // List直接存储
+ 'totalPages': totalPages,
+ };
+ }
+
+ /// fromMap构造函数 - 从Map创建Book对象
+ ///
+ /// 这是toMap的逆操作,用于:
+ /// 1. 从本地存储中读取数据
+ /// 2. 从网络请求中解析数据
+ /// 3. 从保存的状态中恢复对象
+ factory Book.fromMap(Map map) {
+ return Book(
+ id: map['id'],
+ title: map['title'],
+ author: map['author'],
+ publisher: map['publisher'],
+ description: map['description'],
+ coverImagePath: map['coverImagePath'],
+ filePath: map['filePath'],
+ format: BookFormat.values.firstWhere(
+ // 字符串转换回枚举
+ (e) => e.name == map['format'],
+ ),
+ fileSize: map['fileSize'],
+ addedDate: DateTime.parse(map['addedDate']),
+ status: ReadingStatus.values.firstWhere(
+ (e) => e.name == map['status'],
+ ),
+ rating: map['rating'],
+ tags: List.from(map['tags'] ?? []), // 确保返回List
+ totalPages: map['totalPages'],
+ );
+ }
+
+ /// 创建一个新Book实例的工厂方法
+ ///
+ /// 这是一个便利方法,用于创建基本的Book对象
+ /// 通常在用户导入新书籍时使用
+ factory Book.create({
+ required String title,
+ required String filePath,
+ required BookFormat format,
+ required int fileSize,
+ String? author,
+ int totalPages = 0,
+ }) {
+ return Book(
+ id: _generateId(), // 生成唯一ID
+ title: title,
+ author: author,
+ filePath: filePath,
+ format: format,
+ fileSize: fileSize,
+ totalPages: totalPages,
+ addedDate: DateTime.now(), // 当前时间作为添加时间
+ status: ReadingStatus.pending, // 默认状态为待阅读
+ );
+ }
+
+ /// 生成唯一ID的私有方法
+ static String _generateId() {
+ return '${DateTime.now().millisecondsSinceEpoch}_${(DateTime.now().microsecond).toString()}';
+ }
+
+ /// 重写toString方法,便于调试
+ @override
+ String toString() {
+ return 'Book(id: $id, title: $title, author: $author, format: $format)';
+ }
+
+ /// 重写equals和hashCode,用于对象比较
+ @override
+ bool operator ==(Object other) {
+ if (identical(this, other)) return true;
+ return other is Book && other.id == id;
+ }
+
+ @override
+ int get hashCode => id.hashCode;
+}
diff --git a/lib/models/highlight.dart b/lib/models/highlight.dart
new file mode 100644
index 0000000..678cdad
--- /dev/null
+++ b/lib/models/highlight.dart
@@ -0,0 +1,140 @@
+///高亮模型
+
+//不同颜色的高亮
+enum HighlightColor { yellow, orange, green, blue, pink }
+
+///高亮模型
+// 关联书籍和章节
+// 记录选中的文本范围
+// 支持不同颜色的高亮
+// 记录创建时间
+class Highlight {
+ //唯一标识符 - 使用UUID确保全局唯一
+ final String id;
+
+ //对应的书籍id
+ final String bookId;
+
+// 对应章节id
+ final String? chapterId;
+
+// 选中文本
+ final String selectedText;
+
+// 开始索引
+ final int startIndex;
+
+// 结尾索引
+ final int endIndex;
+
+// 高亮颜色
+ final HighlightColor color;
+
+// 创建时间
+ final DateTime createdTime;
+
+ const Highlight(
+ {required this.id,
+ required this.bookId,
+ this.chapterId,
+ required this.selectedText,
+ required this.startIndex,
+ required this.endIndex,
+ required this.color,
+ required this.createdTime});
+
+ /// copyWith方法 - 创建对象的副本
+ Highlight copyWith({
+ String? id,
+ String? bookId,
+ String? chapterId,
+ String? selectedText,
+ int? startIndex,
+ int? endIndex,
+ HighlightColor? color,
+ DateTime? createdTime,
+ }) {
+ return Highlight(
+ id: id ?? this.id,
+ bookId: bookId ?? this.bookId,
+ chapterId: chapterId ?? this.chapterId, // 修复:添加缺失的参数
+ selectedText: selectedText ?? this.selectedText,
+ startIndex: startIndex ?? this.startIndex,
+ endIndex: endIndex ?? this.endIndex,
+ color: color ?? this.color,
+ createdTime: createdTime ?? this.createdTime,
+ );
+ }
+
+ /// toMap方法 - 将对象转换为Map
+ Map toMap() {
+ return {
+ 'id': id,
+ 'bookId': bookId,
+ 'chapterId': chapterId,
+ 'selectedText': selectedText,
+ 'startIndex': startIndex,
+ 'endIndex': endIndex,
+ 'color': color.name, // 枚举值转换为字符串
+ 'createdTime': createdTime.toIso8601String(), // DateTime转换为字符串
+ };
+ }
+
+ /// fromMap构造函数 - 从Map创建Highlight对象
+ factory Highlight.fromMap(Map map) {
+ return Highlight(
+ id: map['id'],
+ bookId: map['bookId'],
+ chapterId: map['chapterId'],
+ selectedText: map['selectedText'],
+ startIndex: map['startIndex'],
+ endIndex: map['endIndex'],
+ color: HighlightColor.values.firstWhere((e) => e.name == map['color']),
+ createdTime: DateTime.parse(map['createdTime']),
+ );
+ }
+
+ /// 创建一个新Highlight实例的工厂方法
+ /// 这是一个便利方法,用于创建基本的高亮对象
+ /// 通常在用户选中文本时使用
+ factory Highlight.create({
+ required String bookId,
+ required String selectedText,
+ required int startIndex,
+ required int endIndex,
+ HighlightColor color = HighlightColor.yellow, // 默认颜色
+ String? chapterId,
+ }) {
+ return Highlight(
+ id: _generateId(), // 生成唯一ID
+ bookId: bookId,
+ chapterId: chapterId,
+ selectedText: selectedText,
+ startIndex: startIndex,
+ endIndex: endIndex,
+ color: color,
+ createdTime: DateTime.now(), // 当前时间作为创建时间
+ );
+ }
+
+ /// 生成唯一ID的私有方法
+ static String _generateId() {
+ return '${DateTime.now().millisecondsSinceEpoch}_${(DateTime.now().microsecond).toString()}';
+ }
+
+ /// 重写toString方法,便于调试
+ @override
+ String toString() {
+ return 'Highlight(id: $id, bookId: $bookId, chapterId: $chapterId, selectedText: $selectedText)';
+ }
+
+ /// 重写equals和hashCode,用于对象比较
+ @override
+ bool operator ==(Object other) {
+ if (identical(this, other)) return true;
+ return other is Highlight && other.id == id;
+ }
+
+ @override
+ int get hashCode => id.hashCode;
+}
diff --git a/pubspec.lock b/pubspec.lock
new file mode 100644
index 0000000..58f638c
--- /dev/null
+++ b/pubspec.lock
@@ -0,0 +1,188 @@
+# Generated by pub
+# See https://dart.dev/tools/pub/glossary#lockfile
+packages:
+ async:
+ dependency: transitive
+ description:
+ name: async
+ sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "2.11.0"
+ boolean_selector:
+ dependency: transitive
+ description:
+ name: boolean_selector
+ sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "2.1.1"
+ characters:
+ dependency: transitive
+ description:
+ name: characters
+ sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.3.0"
+ clock:
+ dependency: transitive
+ description:
+ name: clock
+ sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.1.1"
+ collection:
+ dependency: transitive
+ description:
+ name: collection
+ sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.18.0"
+ cupertino_icons:
+ dependency: "direct main"
+ description:
+ name: cupertino_icons
+ sha256: ba631d1c7f7bef6b729a622b7b752645a2d076dba9976925b8f25725a30e1ee6
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.0.8"
+ fake_async:
+ dependency: transitive
+ description:
+ name: fake_async
+ sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.3.1"
+ flutter:
+ dependency: "direct main"
+ description: flutter
+ source: sdk
+ version: "0.0.0"
+ flutter_lints:
+ dependency: "direct dev"
+ description:
+ name: flutter_lints
+ sha256: a25a15ebbdfc33ab1cd26c63a6ee519df92338a9c10f122adda92938253bef04
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "2.0.3"
+ flutter_test:
+ dependency: "direct dev"
+ description: flutter
+ source: sdk
+ version: "0.0.0"
+ lints:
+ dependency: transitive
+ description:
+ name: lints
+ sha256: "0a217c6c989d21039f1498c3ed9f3ed71b354e69873f13a8dfc3c9fe76f1b452"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "2.1.1"
+ matcher:
+ dependency: transitive
+ description:
+ name: matcher
+ sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "0.12.16"
+ material_color_utilities:
+ dependency: transitive
+ description:
+ name: material_color_utilities
+ sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "0.5.0"
+ meta:
+ dependency: transitive
+ description:
+ name: meta
+ sha256: a6e590c838b18133bb482a2745ad77c5bb7715fb0451209e1a7567d416678b8e
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.10.0"
+ path:
+ dependency: transitive
+ description:
+ name: path
+ sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.8.3"
+ sky_engine:
+ dependency: transitive
+ description: flutter
+ source: sdk
+ version: "0.0.99"
+ source_span:
+ dependency: transitive
+ description:
+ name: source_span
+ sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.10.0"
+ stack_trace:
+ dependency: transitive
+ description:
+ name: stack_trace
+ sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.11.1"
+ stream_channel:
+ dependency: transitive
+ description:
+ name: stream_channel
+ sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "2.1.2"
+ string_scanner:
+ dependency: transitive
+ description:
+ name: string_scanner
+ sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.2.0"
+ term_glyph:
+ dependency: transitive
+ description:
+ name: term_glyph
+ sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "1.2.1"
+ test_api:
+ dependency: transitive
+ description:
+ name: test_api
+ sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "0.6.1"
+ vector_math:
+ dependency: transitive
+ description:
+ name: vector_math
+ sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803"
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "2.1.4"
+ web:
+ dependency: transitive
+ description:
+ name: web
+ sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152
+ url: "https://mirrors.tuna.tsinghua.edu.cn/dart-pub/"
+ source: hosted
+ version: "0.3.0"
+sdks:
+ dart: ">=3.2.5 <4.0.0"
diff --git a/pubspec.yaml b/pubspec.yaml
new file mode 100644
index 0000000..9d50dce
--- /dev/null
+++ b/pubspec.yaml
@@ -0,0 +1,90 @@
+name: readful
+description: "Thoughtful read"
+# The following line prevents the package from being accidentally published to
+# pub.dev using `flutter pub publish`. This is preferred for private packages.
+publish_to: 'none' # Remove this line if you wish to publish to pub.dev
+
+# The following defines the version and build number for your application.
+# A version number is three numbers separated by dots, like 1.2.43
+# followed by an optional build number separated by a +.
+# Both the version and the builder number may be overridden in flutter
+# build by specifying --build-name and --build-number, respectively.
+# In Android, build-name is used as versionName while build-number used as versionCode.
+# Read more about Android versioning at https://developer.android.com/studio/publish/versioning
+# In iOS, build-name is used as CFBundleShortVersionString while build-number is used as CFBundleVersion.
+# Read more about iOS versioning at
+# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
+# In Windows, build-name is used as the major, minor, and patch parts
+# of the product and file versions while build-number is used as the build suffix.
+version: 1.0.0+1
+
+environment:
+ sdk: '>=3.2.5 <4.0.0'
+
+# Dependencies specify other packages that your package needs in order to work.
+# To automatically upgrade your package dependencies to the latest versions
+# consider running `flutter pub upgrade --major-versions`. Alternatively,
+# dependencies can be manually updated by changing the version numbers below to
+# the latest version available on pub.dev. To see which dependencies have newer
+# versions available, run `flutter pub outdated`.
+dependencies:
+ flutter:
+ sdk: flutter
+
+
+ # The following adds the Cupertino Icons font to your application.
+ # Use with the CupertinoIcons class for iOS style icons.
+ cupertino_icons: ^1.0.2 # iOS 风格图标库
+
+dev_dependencies:
+ flutter_test:
+ sdk: flutter
+
+ # The "flutter_lints" package below contains a set of recommended lints to
+ # encourage good coding practices. The lint set provided by the package is
+ # activated in the `analysis_options.yaml` file located at the root of your
+ # package. See that file for information about deactivating specific lint
+ # rules and activating additional ones.
+ flutter_lints: ^2.0.0
+
+# For information on the generic Dart part of this file, see the
+# following page: https://dart.dev/tools/pub/pubspec
+
+# The following section is specific to Flutter packages.
+flutter: # 资源配置(图片、字体、音频等)
+
+ # The following line ensures that the Material Icons font is
+ # included with your application, so that you can use the icons in
+ # the material Icons class.
+ uses-material-design: true
+
+ # To add assets to your application, add an assets section, like this:
+ # assets:
+ # - images/a_dot_burr.jpeg
+ # - images/a_dot_ham.jpeg
+
+ # An image asset can refer to one or more resolution-specific "variants", see
+ # https://flutter.dev/assets-and-images/#resolution-aware
+
+ # For details regarding adding assets from package dependencies, see
+ # https://flutter.dev/assets-and-images/#from-packages
+
+ # To add custom fonts to your application, add a fonts section here,
+ # in this "flutter" section. Each entry in this list should have a
+ # "family" key with the font family name, and a "fonts" key with a
+ # list giving the asset and other descriptors for the font. For
+ # example:
+ # fonts:
+ # - family: Schyler
+ # fonts:
+ # - asset: fonts/Schyler-Regular.ttf
+ # - asset: fonts/Schyler-Italic.ttf
+ # style: italic
+ # - family: Trajan Pro
+ # fonts:
+ # - asset: fonts/TrajanPro.ttf
+ # - asset: fonts/TrajanPro_Bold.ttf
+ # weight: 700
+ #
+ # For details regarding fonts from package dependencies,
+ # see https://flutter.dev/custom-fonts/#from-packages
diff --git a/test/widget_test.dart b/test/widget_test.dart
new file mode 100644
index 0000000..ea04c48
--- /dev/null
+++ b/test/widget_test.dart
@@ -0,0 +1,30 @@
+// This is a basic Flutter widget test.
+//
+// To perform an interaction with a widget in your test, use the WidgetTester
+// utility in the flutter_test package. For example, you can send tap and scroll
+// gestures. You can also use WidgetTester to find child widgets in the widget
+// tree, read text, and verify that the values of widget properties are correct.
+
+import 'package:flutter/material.dart';
+import 'package:flutter_test/flutter_test.dart';
+
+import 'package:readful/main.dart';
+
+void main() {
+ testWidgets('Counter increments smoke test', (WidgetTester tester) async {
+ // Build our app and trigger a frame.
+ await tester.pumpWidget(const MyApp());
+
+ // Verify that our counter starts at 0.
+ expect(find.text('0'), findsOneWidget);
+ expect(find.text('1'), findsNothing);
+
+ // Tap the '+' icon and trigger a frame.
+ await tester.tap(find.byIcon(Icons.add));
+ await tester.pump();
+
+ // Verify that our counter has incremented.
+ expect(find.text('0'), findsNothing);
+ expect(find.text('1'), findsOneWidget);
+ });
+}