diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 61d6de5..e74d70a 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -16,7 +16,7 @@ jobs: java-version: "12.x" - uses: subosito/flutter-action@v1.5.3 with: - flutter-version: 2.0.4 + flutter-version: 3.19.3 - name: Install dependencies run: flutter pub get - name: Run tests diff --git a/README.md b/README.md index 3ba21fe..a6f4757 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # linkfy_text -A lightweight flutter package that linkifies a text containing urls, emails, mentions and hashtag like twitter does. +Lightweight flutter package that detects linkable patterns(urls, emails, hashtags, etc) in a text and makes them clickable. It also allows you to customize the style of the linkified text and the link itself. It also allows you to choose what type of link to linkify in a text.¬ [](https://pub.dev/packages/linkfy_text) -[](https://github.com/Iamstanlee/linkfy_text/actions?query=CI) +[](https://github.com/Iamstanlee/linkfy_text/actions/workflows/main.yml) [](https://coveralls.io/github/Iamstanlee/linkfy_text?branch=main)
diff --git a/analysis_options.yaml b/analysis_options.yaml
index 8acb3fd..2f9c3d7 100644
--- a/analysis_options.yaml
+++ b/analysis_options.yaml
@@ -5,7 +5,5 @@ analyzer:
todo: info
linter:
rules:
- always-specify-types: true
- prefer-relative-imports: true
sort_pub_dependencies: false
unnecessary_raw_strings: false
diff --git a/example/.metadata b/example/.metadata
index 92f6487..aa90aa8 100644
--- a/example/.metadata
+++ b/example/.metadata
@@ -4,7 +4,42 @@
# This file should be version controlled and should not be manually edited.
version:
- revision: b1395592de68cc8ac4522094ae59956dd21a91db
- channel: stable
+ revision: "ba393198430278b6595976de84fe170f553cc728"
+ channel: "stable"
project_type: app
+
+# Tracks metadata for the flutter migrate command
+migration:
+ platforms:
+ - platform: root
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+ - platform: android
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+ - platform: ios
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+ - platform: linux
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+ - platform: macos
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+ - platform: web
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+ - platform: windows
+ create_revision: ba393198430278b6595976de84fe170f553cc728
+ base_revision: ba393198430278b6595976de84fe170f553cc728
+
+ # User provided section
+
+ # List of Local paths (relative to this file) that should be
+ # ignored by the migrate tool.
+ #
+ # Files that are not part of the templates will be ignored by default.
+ unmanaged_files:
+ - 'lib/main.dart'
+ - 'ios/Runner.xcodeproj/project.pbxproj'
diff --git a/example/analysis_options.yaml b/example/analysis_options.yaml
new file mode 100644
index 0000000..0d29021
--- /dev/null
+++ b/example/analysis_options.yaml
@@ -0,0 +1,28 @@
+# This file configures the analyzer, which statically analyzes Dart code to
+# check for errors, warnings, and lints.
+#
+# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
+# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
+# invoked from the command line by running `flutter analyze`.
+
+# The following line activates a set of recommended lints for Flutter apps,
+# packages, and plugins designed to encourage good coding practices.
+include: package:flutter_lints/flutter.yaml
+
+linter:
+ # The lint rules applied to this project can be customized in the
+ # section below to disable rules from the `package:flutter_lints/flutter.yaml`
+ # included above or to enable additional rules. A list of all available lints
+ # and their documentation is published at https://dart.dev/lints.
+ #
+ # Instead of disabling a lint rule for the entire project in the
+ # section below, it can also be suppressed for a single line of code
+ # or a specific dart file by using the `// ignore: name_of_lint` and
+ # `// ignore_for_file: name_of_lint` syntax on the line or in the file
+ # producing the lint.
+ rules:
+ # avoid_print: false # Uncomment to disable the `avoid_print` rule
+ # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
+
+# Additional information about this file can be found at
+# https://dart.dev/guides/language/analysis-options
diff --git a/example/android/.gitignore b/example/android/.gitignore
index 0a741cb..6f56801 100644
--- a/example/android/.gitignore
+++ b/example/android/.gitignore
@@ -9,3 +9,5 @@ GeneratedPluginRegistrant.java
# Remember to never publicly share your keystore.
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
key.properties
+**/*.keystore
+**/*.jks
diff --git a/example/android/app/build.gradle b/example/android/app/build.gradle
index 86d5ab4..e28b4e7 100644
--- a/example/android/app/build.gradle
+++ b/example/android/app/build.gradle
@@ -1,3 +1,9 @@
+plugins {
+ id "com.android.application"
+ id "kotlin-android"
+ id "dev.flutter.flutter-gradle-plugin"
+}
+
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
@@ -6,11 +12,6 @@ if (localPropertiesFile.exists()) {
}
}
-def flutterRoot = localProperties.getProperty('flutter.sdk')
-if (flutterRoot == null) {
- throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
-}
-
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
@@ -21,12 +22,19 @@ if (flutterVersionName == null) {
flutterVersionName = '1.0'
}
-apply plugin: 'com.android.application'
-apply plugin: 'kotlin-android'
-apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
-
android {
- compileSdkVersion 31
+ namespace "com.example.example"
+ compileSdk flutter.compileSdkVersion
+ ndkVersion flutter.ndkVersion
+
+ compileOptions {
+ sourceCompatibility JavaVersion.VERSION_1_8
+ targetCompatibility JavaVersion.VERSION_1_8
+ }
+
+ kotlinOptions {
+ jvmTarget = '1.8'
+ }
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
@@ -35,8 +43,10 @@ android {
defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "com.example.example"
- minSdkVersion 16
- targetSdkVersion 31
+ // You can update the following values to match your application needs.
+ // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
+ minSdkVersion flutter.minSdkVersion
+ targetSdkVersion flutter.targetSdkVersion
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
@@ -54,6 +64,4 @@ flutter {
source '../..'
}
-dependencies {
- implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
-}
+dependencies {}
diff --git a/example/android/app/src/debug/AndroidManifest.xml b/example/android/app/src/debug/AndroidManifest.xml
index c208884..399f698 100644
--- a/example/android/app/src/debug/AndroidManifest.xml
+++ b/example/android/app/src/debug/AndroidManifest.xml
@@ -1,6 +1,6 @@
-