Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: 6tail/lunar-flutter
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.3.12
Choose a base ref
...
head repository: 6tail/lunar-flutter
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 3 commits
  • 8 files changed
  • 1 contributor

Commits on Apr 29, 2024

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    a45d6c2 View commit details

Commits on Nov 12, 2024

  1. Copy the full SHA
    90e2663 View commit details

Commits on Feb 12, 2025

  1. Copy the full SHA
    19f0269 View commit details
Showing with 29 additions and 8 deletions.
  1. +11 −0 CHANGELOG.md
  2. +1 −1 README.md
  3. +1 −1 lib/calendar/NineStar.dart
  4. +5 −1 lib/calendar/Solar.dart
  5. +1 −1 lib/calendar/util/HolidayUtil.dart
  6. +2 −2 lib/calendar/util/LunarUtil.dart
  7. +2 −2 pubspec.yaml
  8. +6 −0 test/Holiday_test.dart
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -175,3 +175,14 @@

## 1.3.12
1. 修复八字转阳历存在遗漏的问题。

## 1.7.0
1. 请勿使用1.6.x版本!请勿使用1.6.x版本!请勿使用1.6.x版本!

## [1.7.1] - 2024-11-12
1. 新增2025年法定假日数据。

## [1.7.2] - 2025-02-12
1. 修复九星错别字。
2. 修复每日宜忌错别字。
3. 去除每日宜忌的重复项。
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@ lunar是一款无第三方依赖的日历工具,支持公历(阳历)、农历(
## 示例

dependencies:
lunar: ^1.3.12
lunar: ^1.7.1
import 'package:lunar/lunar.dart';
2 changes: 1 addition & 1 deletion lib/calendar/NineStar.dart
Original file line number Diff line number Diff line change
@@ -20,7 +20,7 @@ class NineStar {
/// 七色
static const List<String> COLOR = [
'白',
'',
'',
'碧',
'绿',
'黄',
6 changes: 5 additions & 1 deletion lib/calendar/Solar.dart
Original file line number Diff line number Diff line change
@@ -33,9 +33,13 @@ class Solar {
if (month < 1 || month > 12) {
throw 'wrong month $month';
}
if (day < 1 || day > 31) {
if (day < 1) {
throw 'wrong day $day';
}
int days = SolarUtil.getDaysOfMonth(year, month);
if (day > days) {
throw 'only $days days in solar year $year month $month';
}
if (hour < 0 || hour > 23) {
throw 'wrong hour $hour';
}
Loading