Skip to content

Commit

Permalink
linter
Browse files Browse the repository at this point in the history
  • Loading branch information
hawkbee1 committed Aug 31, 2023
1 parent a0fa5bb commit 1dac209
Show file tree
Hide file tree
Showing 19 changed files with 47 additions and 47 deletions.
3 changes: 0 additions & 3 deletions lib/app/shared/constants/urls.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ class Urls {
static const String checkIssuerTalaoUrl =
'https://talao.co/trusted-issuers-registry/v1/issuers';

// TODO(all): update the issuer url for polygon
static const String checkIssuerPolygonTestnetUrl =
'https://issuer-demo.polygonid.me/';
static const String checkIssuerPolygonUrl = 'checkIssuerPolygonUrl';
Expand Down Expand Up @@ -91,15 +90,13 @@ class Urls {
static const objktUrl = 'https://objkt.com/';
static const raribleUrl = 'https://rarible.com/';

// TODO(all): remember to update all below urls.
static const String bunnyPassCardUrl = 'https://issuer.tezotopia.altme.io';
static const String dogamiPassCardUrl = 'https://issuer.tezotopia.altme.io';
static const String matterlightPassCardUrl =
'https://issuer.tezotopia.altme.io';
static const String pigsPassCardUrl = 'https://issuer.tezotopia.altme.io';
static const String trooperzPassCardUrl = 'https://issuer.tezotopia.altme.io';

//
static const over13AIValidationUrl = 'https://issuer.talao.co/ai/over13';
static const over15AIValidationUrl = 'https://issuer.talao.co/ai/over15';
static const over18AIValidationUrl = 'https://issuer.talao.co/ai/over18';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ enum ResponseString {
RESPONSE_STRING_successfullyGeneratingProof,
RESPONSE_STRING_pleaseAddXtoConnectToTheDapp,
RESPONSE_STRING_pleaseSwitchPolygonNetwork,
RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile,
RESPONSE_STRING_pleaseSwitchToRightOIDC4VCProfile,
RESPONSE_STRING_authenticationSuccess,
RESPONSE_STRING_youcanSelectOnlyXCredential,
}
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ extension ResponseStringX on ResponseString {
injectedMessage ?? '',
);

case ResponseString.RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile:
case ResponseString.RESPONSE_STRING_pleaseSwitchToRightOIDC4VCProfile:
return globalMessage
.RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile;

Expand Down
1 change: 0 additions & 1 deletion lib/app/shared/helper_functions/helper_functions.dart
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,6 @@ Future<bool> getStoragePermission() async {
if (await Permission.storage.request().isGranted) {
return true;
} else if (await Permission.storage.request().isPermanentlyDenied) {
// TODO(all): show dialog to choose this option
await openAppSettings();
} else if (await Permission.storage.request().isDenied) {
return false;
Expand Down
4 changes: 2 additions & 2 deletions lib/app/shared/message_handler/response_message.dart
Original file line number Diff line number Diff line change
Expand Up @@ -689,9 +689,9 @@ class ResponseMessage with MessageHandler {
injectedMessage: injectedMessage,
);

case ResponseString.RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile:
case ResponseString.RESPONSE_STRING_pleaseSwitchToRightOIDC4VCProfile:
return ResponseString
.RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile.localise(
.RESPONSE_STRING_pleaseSwitchToRightOIDC4VCProfile.localise(
context,
);

Expand Down
1 change: 1 addition & 0 deletions lib/app/shared/widget/base/page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ class _BasePageState extends State<BasePage> with WidgetsBindingObserver {
secureApplicationController.lock();
}

case AppLifecycleState.hidden:
case AppLifecycleState.detached:
break;
// TODO(all): Handle this case.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ class WalletSecurityView extends StatelessWidget {
builder: (context) => ConfirmDialog(
title: l10n.biometricsNotSupported,
subtitle: l10n
.yourDeviceDoseNotSupportBiometricsAuthentication, // ignore: lines_longer_than_80_chars
.deviceDoNotSupportBiometricsAuthentication, // ignore: lines_longer_than_80_chars
yes: l10n.ok,
),
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ class QRCodeScanCubit extends Cubit<QRCodeScanState> {
message: StateMessage.error(
messageHandler: ResponseMessage(
ResponseString
.RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile,
.RESPONSE_STRING_pleaseSwitchToRightOIDC4VCProfile,
),
showDialog: false,
duration: const Duration(seconds: 20),
Expand Down
6 changes: 3 additions & 3 deletions lib/l10n/arb/app_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@
"yourPinCodeChangedSuccessfully": "Your pin code changed successfully",
"advantagesCards": "Advantages cards",
"advantagesDiscoverCards": "Unlock exclusive rewards",
"identityCards": "Identity cards",
"identityCards": "Identity cards",
"identityDiscoverCards": "Simplify ID verification",
"contactInfoCredentials": "Contact information",
"contactInfoDiscoverCredentials": "Verify your contact information",
Expand Down Expand Up @@ -353,7 +353,7 @@
"termsOfUse": "Terms of Use & Confidentiality",
"scanFingerprintToAuthenticate": "Scan Fingerprint to Authenticate",
"biometricsNotSupported": "Biometrics not supported",
"yourDeviceDoseNotSupportBiometricsAuthentication": "Your device dose not supports biometrics authentication",
"deviceDoNotSupportBiometricsAuthentication": "Your device dose not supports biometrics authentication",
"biometricsEnabledMessage": "You can now unlock app with your biometrics.",
"biometricsDisabledMessage": "Your biometrics has been disabled.",
"exportSecretKey": "Export secret key",
Expand Down Expand Up @@ -560,7 +560,7 @@
"advantagesCredentialHomeSubtitle": "Benefit from exclusive advantages in Web3",
"advantagesCredentialDiscoverSubtitle": "Discover loyalty cards and exclusive passes",
"identityCredentialHomeSubtitle": "Prove things about yourself while protecting your data",
"identityCredentialDiscoverSubtitle": "Get reusable KYC and age verification credentials",
"identityCredentialDiscoverSubtitle": "Get reusable KYC and age verification credentials",
"myProfessionalCredentialDiscoverSubtitle": "Use your professional cards securely",
"blockchainAccountsCredentialHomeSubtitle": "Prove your blockchain accounts ownership",
"educationCredentialHomeSubtitle": "Prove your education background instantly",
Expand Down
2 changes: 1 addition & 1 deletion lib/l10n/arb/app_fr.arb
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@
"termsOfUse": "Conditions d'utilisation et confidentialité",
"scanFingerprintToAuthenticate": "Scanner l'empreinte digitale pour s'authentifier",
"biometricsNotSupported": "La biométrie n'est pas prise en charge",
"yourDeviceDoseNotSupportBiometricsAuthentication": "Votre appareil ne prend pas en charge l'authentification biométrique",
"deviceDoNotSupportBiometricsAuthentication": "Votre appareil ne prend pas en charge l'authentification biométrique",
"biometricsEnabledMessage": "Vous pouvez maintenant déverrouiller l'application avec vos données biométriques.",
"biometricsDisabledMessage": "Votre biométrie a été désactivée.",
"exportSecretKey": "Exporter la clé secrète",
Expand Down
6 changes: 3 additions & 3 deletions lib/l10n/untranslated.json
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@
"termsOfUse",
"scanFingerprintToAuthenticate",
"biometricsNotSupported",
"yourDeviceDoseNotSupportBiometricsAuthentication",
"deviceDoNotSupportBiometricsAuthentication",
"biometricsEnabledMessage",
"biometricsDisabledMessage",
"exportSecretKey",
Expand Down Expand Up @@ -1154,7 +1154,7 @@
"termsOfUse",
"scanFingerprintToAuthenticate",
"biometricsNotSupported",
"yourDeviceDoseNotSupportBiometricsAuthentication",
"deviceDoNotSupportBiometricsAuthentication",
"biometricsEnabledMessage",
"biometricsDisabledMessage",
"exportSecretKey",
Expand Down Expand Up @@ -2159,7 +2159,7 @@
"termsOfUse",
"scanFingerprintToAuthenticate",
"biometricsNotSupported",
"yourDeviceDoseNotSupportBiometricsAuthentication",
"deviceDoNotSupportBiometricsAuthentication",
"biometricsEnabledMessage",
"biometricsDisabledMessage",
"exportSecretKey",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,8 +156,8 @@ class ActivateBiometricsView extends StatelessWidget {
context: context,
builder: (context) => ConfirmDialog(
title: l10n.biometricsNotSupported,
subtitle: l10n
.yourDeviceDoseNotSupportBiometricsAuthentication,
subtitle:
l10n.deviceDoNotSupportBiometricsAuthentication,
yes: l10n.ok,
),
);
Expand Down
2 changes: 1 addition & 1 deletion lib/scan/cubit/scan_cubit.dart
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ class ScanCubit extends Cubit<ScanState> {
message: StateMessage.error(
messageHandler: ResponseMessage(
ResponseString
.RESPONSE_STRING_pleaseSwitchToCorrectOIDC4VCProfile,
.RESPONSE_STRING_pleaseSwitchToRightOIDC4VCProfile,
),
showDialog: false,
duration: const Duration(seconds: 20),
Expand Down
3 changes: 2 additions & 1 deletion packages/oidc4vc/lib/src/oidc4vc.dart
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,8 @@ class OIDC4VC {
}

Future<String> readTokenEndPoint(
Map<String, dynamic> openidConfigurationResponse) async {
Map<String, dynamic> openidConfigurationResponse,
) async {
late String tokenEndPoint;

final authorizationServer =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,4 @@ class IssuerTokenParameterTest extends TokenParameterTest {
final tokenParameters = IssuerTokenParameters(keyWithAlg, '', '', '');
expect(tokenParameters.alg, HS256Alg);
}

// @override
// void thumprintOfKey() {
// expect(tokenParameters.thumbprint, thumbprint);
// }

// @override
// void thumprintOfKeyForrfc7638() {
// final tokenParameters2 = IssuerTokenParameters(rfc7638Jwk, '', '', '', '');
// expect(tokenParameters2.thumbprint, expectedThumbprintForrfc7638Jwk);
// }
}
1 change: 1 addition & 0 deletions packages/oidc4vc/test/src/oidc4vc_test.dart
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// ignore_for_file: lines_longer_than_80_chars
// // Copyright (c) 2022, Very Good Ventures
// // https://verygood.ventures
// //
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.

// ignore_for_file: lines_longer_than_80_chars

import 'package:dio/dio.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:mocktail/mocktail.dart';
Expand Down
2 changes: 2 additions & 0 deletions packages/polygonid/lib/src/polygonid.dart
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,9 @@ class PolygonId {
final String to = body.transactionData.contractAddress;
final Iden3commProofEntity proof = response.first;

// ignore: lines_longer_than_80_chars
const ABI =
// ignore: lines_longer_than_80_chars
'[ { "inputs": [ { "internalType": "uint64", "name": "requestId", "type": "uint64" }, { "internalType": "uint256[]", "name": "inputs", "type": "uint256[]" }, { "internalType": "uint256[2]", "name": "a", "type": "uint256[2]" }, { "internalType": "uint256[2][2]", "name": "b", "type": "uint256[2][2]" }, { "internalType": "uint256[2]", "name": "c", "type": "uint256[2]" } ], "name": "submitZKPResponse", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "nonpayable", "type": "function" } ]';

final ContractAbi cAbi = ContractAbi.fromJson(ABI, to);
Expand Down
38 changes: 23 additions & 15 deletions pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -390,10 +390,10 @@ packages:
dependency: transitive
description:
name: collection
sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c"
sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687
url: "https://pub.dev"
source: hosted
version: "1.17.1"
version: "1.17.2"
confetti:
dependency: "direct main"
description:
Expand Down Expand Up @@ -1421,18 +1421,18 @@ packages:
dependency: transitive
description:
name: matcher
sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb"
sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e"
url: "https://pub.dev"
source: hosted
version: "0.12.15"
version: "0.12.16"
material_color_utilities:
dependency: transitive
description:
name: material_color_utilities
sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724
sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41"
url: "https://pub.dev"
source: hosted
version: "0.2.0"
version: "0.5.0"
matrix:
dependency: "direct main"
description:
Expand Down Expand Up @@ -2176,10 +2176,10 @@ packages:
dependency: transitive
description:
name: source_span
sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250
sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c"
url: "https://pub.dev"
source: hosted
version: "1.9.1"
version: "1.10.0"
sqflite:
dependency: transitive
description:
Expand Down Expand Up @@ -2264,26 +2264,26 @@ packages:
dependency: transitive
description:
name: test
sha256: "3dac9aecf2c3991d09b9cdde4f98ded7b30804a88a0d7e4e7e1678e78d6b97f4"
sha256: "13b41f318e2a5751c3169137103b60c584297353d4b1761b66029bae6411fe46"
url: "https://pub.dev"
source: hosted
version: "1.24.1"
version: "1.24.3"
test_api:
dependency: transitive
description:
name: test_api
sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb
sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8"
url: "https://pub.dev"
source: hosted
version: "0.5.1"
version: "0.6.0"
test_core:
dependency: transitive
description:
name: test_core
sha256: "5138dbffb77b2289ecb12b81c11ba46036590b72a64a7a90d6ffb880f1a29e93"
sha256: "99806e9e6d95c7b059b7a0fc08f07fc53fabe54a829497f0d9676299f1e8637e"
url: "https://pub.dev"
source: hosted
version: "0.5.1"
version: "0.5.3"
tezart:
dependency: "direct main"
description:
Expand Down Expand Up @@ -2509,6 +2509,14 @@ packages:
url: "https://pub.dev"
source: hosted
version: "1.0.2"
web:
dependency: transitive
description:
name: web
sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10
url: "https://pub.dev"
source: hosted
version: "0.1.4-beta"
web3dart:
dependency: "direct overridden"
description:
Expand Down Expand Up @@ -2638,5 +2646,5 @@ packages:
source: hosted
version: "2.1.1"
sdks:
dart: ">=3.0.0 <3.7.0"
dart: ">=3.1.0-185.0.dev <3.7.0"
flutter: ">=3.10.0"

0 comments on commit 1dac209

Please sign in to comment.