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

Code improved #2

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Code improved #2

wants to merge 2 commits into from

Conversation

seel-channel
Copy link

No description provided.

Copy link
Owner

@deniscolak deniscolak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check comments, after changes i can accept your PR.

Thanks in advance!

Comment on lines +1 to +140
"name": "fake_async",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/fake_async-1.2.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "flutter",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/packages/flutter",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "flutter_test",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/packages/flutter_test",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "matcher",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/matcher-0.12.10",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "meta",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/meta-1.3.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "path",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/path-1.8.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "sky_engine",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/bin/cache/pkg/sky_engine",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "source_span",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/source_span-1.8.1",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "stack_trace",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/stack_trace-1.10.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "stream_channel",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/stream_channel-2.1.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "string_scanner",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/string_scanner-1.1.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "term_glyph",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/term_glyph-1.2.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "test_api",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/test_api-0.3.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "typed_data",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/typed_data-1.3.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "vector_math",
"rootUri": "file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/vector_math-2.1.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "colorize_text_avatar",
"rootUri": "../",
"packageUri": "lib/",
"languageVersion": "2.12"
}
],
"generated": "2021-06-02T22:17:32.541394Z",
"generator": "pub",
"generatorVersion": "2.13.0"
}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pls exclude this file from the package, respect to the .gitignore.

Comment on lines +1 to +89
colorize_text_avatar
2.12
file:///home/rosalinda/Downloads/colorize-text-avatar/
file:///home/rosalinda/Downloads/colorize-text-avatar/lib/
async
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/async-2.6.1/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/async-2.6.1/lib/
boolean_selector
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/boolean_selector-2.1.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/boolean_selector-2.1.0/lib/
characters
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/characters-1.1.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/characters-1.1.0/lib/
charcode
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/charcode-1.2.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/charcode-1.2.0/lib/
clock
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/clock-1.1.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/clock-1.1.0/lib/
collection
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/collection-1.15.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/collection-1.15.0/lib/
fake_async
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/fake_async-1.2.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/fake_async-1.2.0/lib/
matcher
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/matcher-0.12.10/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/matcher-0.12.10/lib/
meta
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/meta-1.3.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/meta-1.3.0/lib/
path
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/path-1.8.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/path-1.8.0/lib/
source_span
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/source_span-1.8.1/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/source_span-1.8.1/lib/
stack_trace
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/stack_trace-1.10.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/stack_trace-1.10.0/lib/
stream_channel
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/stream_channel-2.1.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/stream_channel-2.1.0/lib/
string_scanner
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/string_scanner-1.1.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/string_scanner-1.1.0/lib/
term_glyph
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/term_glyph-1.2.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/term_glyph-1.2.0/lib/
test_api
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/test_api-0.3.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/test_api-0.3.0/lib/
typed_data
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/typed_data-1.3.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/typed_data-1.3.0/lib/
vector_math
2.12
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/vector_math-2.1.0/
file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/vector_math-2.1.0/lib/
sky_engine
2.12
file:///home/rosalinda/snap/flutter/common/flutter/bin/cache/pkg/sky_engine/
file:///home/rosalinda/snap/flutter/common/flutter/bin/cache/pkg/sky_engine/lib/
flutter
2.12
file:///home/rosalinda/snap/flutter/common/flutter/packages/flutter/
file:///home/rosalinda/snap/flutter/common/flutter/packages/flutter/lib/
flutter_test
2.12
file:///home/rosalinda/snap/flutter/common/flutter/packages/flutter_test/
file:///home/rosalinda/snap/flutter/common/flutter/packages/flutter_test/lib/
2
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pls exclude this file from the package, respect to the .gitignore.

@@ -0,0 +1 @@
2.2.0
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pls exclude this file from the package, respect to the .gitignore.

test_api:file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/test_api-0.3.0/lib/
typed_data:file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/typed_data-1.3.0/lib/
vector_math:file:///home/rosalinda/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/vector_math-2.1.0/lib/
colorize_text_avatar:lib/
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pls exclude this file from the package, respect to the .gitignore.

],
),
]),
]),
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved.

example/pubspec.yaml Show resolved Hide resolved
@@ -1,5 +1,3 @@
library colorize_text_avatar;

export 'src/constants/colors.dart';
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WHY?

final FontWeight? fontWeight;
final String? fontFamily;
final bool? upperCase;
const TextAvatar({
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pls put const after class specifications

return '${arrayLeeters[0][0].trim()}${arrayLeeters[1][0].trim()}';
Color? _colorBackgroundConfig(String text) {
Color? background = backgroundColor;
if (RegExp(r'[A-Z]|').hasMatch(text)) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is statement should change in order to fix your issue #3

const TextAvatar({
Key? key,
required this.text,
this.numberLetters = 2,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why it's predefined to the 2?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants