diff --git a/CHANGELOG.md b/CHANGELOG.md index e44f793..f6700c7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,13 @@ > [!IMPORTANT] > See the [Migration Guide](guides/migration_guide.md) for the details of breaking changes between versions. +## 3.1.0 + +### Improvements + +- Bump `sensors_plus` package from `6.0.0` to `6.1.0`. ([#20](https://github.com/fluttercandies/flutter_tilt/pull/20)) +- Migrate the example to Android Studio Ladybug (JDK 21). ([#19](https://github.com/fluttercandies/flutter_tilt/pull/19)) + ## 3.0.6 ### Improvements diff --git a/README-ZH.md b/README-ZH.md index 81f3328..cdacf8c 100644 --- a/README-ZH.md +++ b/README-ZH.md @@ -55,9 +55,11 @@ - [版本兼容](#版本兼容-) + - [平台兼容](#平台兼容-) + - [添加 flutter_tilt](#添加-flutter_tilt-) -- [传感器兼容](#传感器兼容-) +- [传感器兼容][] - [手势优先级](#手势优先级-) @@ -98,7 +100,7 @@ - 🔦 光照效果 - 💡 阴影效果 - 👀 视差效果 -- 📱 陀螺仪传感器支持([传感器兼容](#传感器兼容-)) +- 📱 陀螺仪传感器支持([传感器兼容][]) - 🧱 多种布局位置 - 👇 支持鼠标、触摸和传感器事件 - 🖼️ 流畅的动画 @@ -115,6 +117,13 @@ | flutter_tilt 1.0.0+ | ✅ | ❌ | ❌ | +### 平台兼容 📱 + +| Android | iOS | Web | macOS | Windows | Linux | +| :-----: | :---: | :---: | :---: | :-----: | :---: | +| ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | + + ### 添加 flutter_tilt 📦 使用 Flutter 运行以下指令, @@ -127,17 +136,18 @@ $ flutter pub add flutter_tilt ```yaml dependencies: - flutter_tilt: ^latest_version + flutter_tilt: ^最新版本 ``` -## 传感器兼容 📱 +## 传感器兼容 📱 -传感器仅在以下平台触发。 +传感器仅在以下平台触发。 +不支持传感器的平台不会影响其他功能的正常使用。 -| Android | iOS | Web (HTTPS) | macOS | Linux | Windows | -| :-----: | :---: | :------------------------------------------: | :---: | :---: | :-----: | -| ✅ | ✅ | [浏览器兼容][Gyroscope Browser compatibility] | ❌ | ❌ | ❌ | +| Android | iOS | Web (HTTPS) | macOS | Windows | Linux | +| :-----: | :---: | :------------------------------------------: | :---: | :-----: | :---: | +| ✅ | ✅ | [浏览器兼容][Gyroscope Browser compatibility] | ❌ | ❌ | ❌ | > [!NOTE] > 目前 Web 使用 [Sensor API - Gyroscope][],但它不兼容部分主流浏览器,比如 Safari、Firefox。 @@ -395,6 +405,7 @@ tiltStreamController.add( [在线示例]: https://amoshuke.github.io/flutter_tilt_book [迁移指南]: https://github.com/fluttercandies/flutter_tilt/blob/main/guides/migration_guide.md [flutter_tilt/example]: https://github.com/fluttercandies/flutter_tilt/tree/main/example +[传感器兼容]: #传感器兼容- [Tilt widget 参数]: #tilt-widget-参数- [TiltParallax widget 参数]: #tiltparallax-widget-参数- [ChildLayout]: #childlayout- diff --git a/README.md b/README.md index f44e9b1..1cd32aa 100644 --- a/README.md +++ b/README.md @@ -55,11 +55,13 @@ Check out the [Live Demo][]. - [Versions compatibility](#versions-compatibility-) + - [Platforms compatibility](#platforms-compatibility-) + - [Add package](#add-package-) -- [Sensors compatibility](#sensors-compatibility-) +- [Sensors compatibility][] -- [Gesture priority](#gesture-priority-) +- [Gestures priority](#gestures-priority-) - [Simple usage](#simple-usage-) @@ -98,7 +100,7 @@ Check out the [Live Demo][]. - 🔦 Light effect - 💡 Shadow effect - 👀 Parallax effect -- 📱 Gyroscope sensor support ([Sensors compatibility](#sensors-compatibility-)) +- 📱 Gyroscope sensor support ([Sensors compatibility][]) - 🧱 Multiple layouts - 👇 Supports hover, touch and sensors events - 🖼️ Smooth animation @@ -115,6 +117,13 @@ Check out the [Live Demo][]. | flutter_tilt 1.0.0+ | ✅ | ❌ | ❌ | +### Platforms compatibility 📱 + +| Android | iOS | Web | macOS | Windows | Linux | +| :-----: | :---: | :---: | :---: | :-----: | :---: | +| ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | + + ### Add package 📦 Run this command with Flutter, @@ -131,20 +140,21 @@ dependencies: ``` -## Sensors compatibility 📱 +## Sensors compatibility 📱 -Sensors are triggered only on these platforms. +Sensors will only trigger on these platforms. +Platforms without sensors support do not affect the normal use of other features. -| Android | iOS | Web (HTTPS) | macOS | Linux | Windows | -| :-----: | :---: | :------------------------------------------------------: | :---: | :---: | :-----: | -| ✅ | ✅ | [Browser compatibility][Gyroscope Browser compatibility] | ❌ | ❌ | ❌ | +| Android | iOS | Web (HTTPS) | macOS | Windows | Linux | +| :-----: | :---: | :------------------------------------------------------: | :---: | :-----: | :---: | +| ✅ | ✅ | [Browser compatibility][Gyroscope Browser compatibility] | ❌ | ❌ | ❌ | > [!NOTE] > Currently Web uses the [Sensor API - Gyroscope], but it is not compatible with some of the major browsers, such as Safari, Firefox. -## Gesture priority 📱 +## Gestures priority 📱 When multiple gestures are enabled, they are triggered based on priority: @@ -395,6 +405,7 @@ Open sourced under the MIT license. [Live Demo]: https://amoshuke.github.io/flutter_tilt_book [Migration Guide]: https://github.com/fluttercandies/flutter_tilt/blob/main/guides/migration_guide.md [flutter_tilt/example]: https://github.com/fluttercandies/flutter_tilt/tree/main/example +[Sensors compatibility]: #sensors-compatibility- [Tilt widget parameters]: #tilt-widget-parameters- [TiltParallax widget parameters]: #tiltparallax-widget-parameters- [ChildLayout]: #childlayout- diff --git a/pubspec.yaml b/pubspec.yaml index 6b4a47d..d371871 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -8,7 +8,7 @@ description: Easily apply tilt parallax hover effects for Flutter, which support # https://semver.org/spec/v2.0.0-rc.1.html # https://dart.dev/tools/pub/versioning#semantic-versions # https://dart.dev/tools/pub/dependencies#version-constraints -version: 3.0.6 +version: 3.1.0 homepage: https://amoshuke.github.io/flutter_tilt_book repository: https://github.com/fluttercandies/flutter_tilt issue_tracker: https://github.com/fluttercandies/flutter_tilt/issues @@ -28,7 +28,7 @@ dependencies: flutter: sdk: flutter stream_transform: ^2.1.0 - sensors_plus: ^6.0.0 + sensors_plus: ^6.1.0 dev_dependencies: flutter_test: