mirror of
https://github.com/flutter/samples.git
synced 2025-11-09 06:18:49 +00:00
Add flutter_web samples (#75)
This commit is contained in:
committed by
Andrew Brogdon
parent
42f2dce01b
commit
3fe927cb29
14
web/github_dataviz/lib/data/contribution_data.dart
Normal file
14
web/github_dataviz/lib/data/contribution_data.dart
Normal file
@@ -0,0 +1,14 @@
|
||||
class ContributionData {
|
||||
int weekTime;
|
||||
int add;
|
||||
int delete;
|
||||
int change;
|
||||
|
||||
ContributionData(this.weekTime, this.add, this.delete, this.change);
|
||||
|
||||
static ContributionData fromJson(Map<String, dynamic> jsonMap) {
|
||||
ContributionData data = ContributionData(
|
||||
jsonMap["w"], jsonMap["a"], jsonMap["d"], jsonMap["c"]);
|
||||
return data;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user