Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix enum #55

Merged
merged 3 commits into from
Mar 12, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
100 changes: 70 additions & 30 deletions .idea/libraries/Dart_Packages.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
## 3.0.1

- Patch changes

Fixed `Undefined name 'Units'` bug

Swedish locale `sv` contributed by [Erik Carlsson](https://github.com/ercadev)

## 3.0.0

- Major changes
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
[![Build Status](https://travis-ci.org/jama5262/jiffy.svg?branch=master)](https://travis-ci.org/jama5262/jiffy)
[![Coverage Status](https://coveralls.io/repos/github/jama5262/jiffy/badge.svg?branch=master)](https://coveralls.io/github/jama5262/jiffy?branch=master)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Pub Version](https://img.shields.io/badge/pub-v3.0.0-blue)](https://pub.dev/packages/jiffy)
[![Pub Version](https://img.shields.io/badge/pub-v3.0.1-blue)](https://pub.dev/packages/jiffy)
[![Platform](https://img.shields.io/badge/platform-flutter%7Cweb%7Cdart%20vm-orange)](https://github.com/jama5262/jiffy)

Jiffy is a Flutter (Android, IOS and Web) date time package inspired by [momentjs](https://momentjs.com/) for parsing, manipulating, querying and formatting dates

### [Full Documentation](https://github.com/jama5262/jiffy/tree/v3.0.0/doc) | [Installation](https://pub.dev/packages/jiffy#-installing-tab-) | [ChangeLog](https://pub.dev/packages/jiffy#-changelog-tab-) | [Examples](https://pub.dev/packages/jiffy#-example-tab-)
### [Full Documentation](https://github.com/jama5262/jiffy/tree/v3.0.1/doc) | [Installation](https://pub.dev/packages/jiffy#-installing-tab-) | [ChangeLog](https://pub.dev/packages/jiffy#-changelog-tab-) | [Examples](https://pub.dev/packages/jiffy#-example-tab-)

# Usage

Expand Down
4 changes: 2 additions & 2 deletions doc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
[![Build Status](https://travis-ci.org/jama5262/jiffy.svg?branch=master)](https://travis-ci.org/jama5262/jiffy)
[![Coverage Status](https://coveralls.io/repos/github/jama5262/jiffy/badge.svg?branch=master)](https://coveralls.io/github/jama5262/jiffy?branch=master)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Pub Version](https://img.shields.io/badge/pub-v3.0.0-blue)](https://pub.dev/packages/jiffy)
[![Pub Version](https://img.shields.io/badge/pub-v3.0.1-blue)](https://pub.dev/packages/jiffy)
[![Platform](https://img.shields.io/badge/platform-flutter%7Cweb%7Cdart%20vm-orange)](https://github.com/jama5262/jiffy)


Expand Down Expand Up @@ -461,7 +461,7 @@ var jiffy2 = Jiffy("2010-10-19", "yyyy-MM-dd");
jiffy1.isAfter(jiffy2); // true
```

You can also check in terms of units of measurement. The below example checks if year is before.
You can also check in terms of units of measurement. The below example checks if year is after.
```dart
var jiffy1 = Jiffy("2010-10-20", "yyyy-MM-dd");

Expand Down
1 change: 1 addition & 0 deletions lib/jiffy.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
library jiffy;

export 'src/jiffy.dart';
export 'src/enums/units.dart';
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: jiffy
description: Jiffy is a date dart package inspired by momentjs for parsing, manipulating and formatting dates
version: 3.0.0
version: 3.0.1
homepage: https://github.com/jama5262/jiffy
repository: https://github.com/jama5262/jiffy
issue_tracker: https://github.com/jama5262/jiffy/issues
Expand Down
2 changes: 1 addition & 1 deletion test/jiffy_display_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ void main() {
'test Jiffy().format get method with parsing date time should return correct date time string',
() {
expect(Jiffy('20191016').format('MMMM dd, yyyy'), 'October 16, 2019');
expect(Jiffy('2019-10-16 12:00').format("[Today is] dd MMM"),
expect(Jiffy('2019-10-16 12:00').format('[Today is] dd MMM'),
'Today is 16 Oct');
expect(Jiffy('2019-10-16T00:00:00.000').format('MMMMEEEEd'),
'Wednesday, October 16');
Expand Down
2 changes: 1 addition & 1 deletion test/jiffy_relative_locale_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ void main() {
expect(jiffy13.fromNow(), '10 yıl önce');
});
test(
'test Jiffy.locale() method with parsing en locale should return correct date time in sv locale',
'test Jiffy.locale() method with parsing sv locale should return correct date time in sv locale',
() async {
await Jiffy.locale('sv');
expect(jiffy1.fromNow(), 'några sekunder sedan');
Expand Down