short_video 0.0.1

  • Readme
  • Changelog
  • Installing
  • 33

sg_video_player #

Video palyer which can be reused by reset datasource

Getting Started #

This project is a starting point for a Flutter plug-in package, a specialized package that includes platform-specific implementation code for Android and/or iOS.

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

0.0.1 #

  • TODO: Describe initial release.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  short_video: ^0.0.1

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:short_video/base/device_info.dart';
import 'package:short_video/base/i_log.dart';
import 'package:short_video/base/i_net_http.dart';
import 'package:short_video/base/i_store_db.dart';
import 'package:short_video/base/i_store_sp.dart';
import 'package:short_video/base/pair.dart';
import 'package:short_video/bean/heart_info.dart';
import 'package:short_video/bean/rsp_video_list.dart';
import 'package:short_video/bean/support_bean.dart';
import 'package:short_video/bean/video_item.dart';
import 'package:short_video/build_config.dart';
import 'package:short_video/debug/debug_s_common_action.dart';
import 'package:short_video/debug/debug_s_network.dart';
import 'package:short_video/debug/debug_s_proxy.dart';
import 'package:short_video/debug/debug_screen.dart';
import 'package:short_video/generated/i18n.dart';
import 'package:short_video/locale/localization.dart';
import 'package:short_video/locale/messages_all.dart';
import 'package:short_video/locale/messages_zh.dart';
import 'package:short_video/main.dart';
import 'package:short_video/main_screen.dart';
import 'package:short_video/model_item.dart';
import 'package:short_video/model_main.dart';
import 'package:short_video/network/i_json_codec.dart';
import 'package:short_video/network/i_req_base.dart';
import 'package:short_video/network/i_rsp_base.dart';
import 'package:short_video/network/net_const.dart';
import 'package:short_video/network/root_url.dart';
import 'package:short_video/network/sg_http_client.dart';
import 'package:short_video/network/sg_request.dart';
import 'package:short_video/platform/plf_device.dart';
import 'package:short_video/platform/sg_operation.dart';
import 'package:short_video/platform/sg_player.dart';
import 'package:short_video/player_pool.dart';
import 'package:short_video/sg_log.dart';
import 'package:short_video/storage/imp_base_store_sp.dart';
import 'package:short_video/test_screen.dart';
import 'package:short_video/util/constant.dart';
import 'package:short_video/util/crash_handler.dart';
import 'package:short_video/util/demo_util.dart';
import 'package:short_video/util/statistics_helper.dart';
import 'package:short_video/util/toast.dart';
import 'package:short_video/util/ui_tools.dart';
import 'package:short_video/util/validator.dart';
import 'package:short_video/widget/ad_text_widget.dart';
import 'package:short_video/widget/comment_count_widget.dart';
import 'package:short_video/widget/common/base_navi_screen.dart';
import 'package:short_video/widget/common/common_expansion_item.dart';
import 'package:short_video/widget/common/fadein_widget_switcher.dart';
import 'package:short_video/widget/common/positioned_tap_detector.dart';
import 'package:short_video/widget/common/sg_page_view.dart';
import 'package:short_video/widget/error_widget.dart';
import 'package:short_video/widget/givelike_anim_screen.dart';
import 'package:short_video/widget/image_button_widget.dart';
import 'package:short_video/widget/navi_bar_widget.dart';
import 'package:short_video/widget/page_control_widget.dart';
import 'package:short_video/widget/page_item_screen.dart';
import 'package:short_video/widget/popup_menu_widget.dart';
import 'package:short_video/widget/pure_text_widget.dart';
import 'package:short_video/widget/share_button_widget.dart';
import 'package:short_video/widget/touch_event_screen.dart';
import 'package:short_video/widget/user_guid_widget.dart';
import 'package:short_video/widget/write_comment_widget.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
0
Health:
Code health derived from static analysis. [more]
75
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
52
Overall:
Weighted score of the above. [more]
33
Learn more about scoring.

We analyzed this package on Feb 27, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.7.1
  • pana: 0.13.5
  • Flutter: 1.12.13+hotfix.8

Health suggestions

Fix lib/platform/sg_operation.dart. (-9.08 points)

Analysis of lib/platform/sg_operation.dart reported 19 hints, including:

line 38 col 3: Prefer using /// for doc comments.

line 52 col 3: Prefer using /// for doc comments.

line 73 col 3: Prefer using /// for doc comments.

line 105 col 3: Prefer using /// for doc comments.

line 119 col 3: Prefer using /// for doc comments.

Fix lib/network/net_const.dart. (-4.89 points)

Analysis of lib/network/net_const.dart reported 10 hints, including:

line 3 col 20: Name non-constant identifiers using lowerCamelCase.

line 6 col 20: Name non-constant identifiers using lowerCamelCase.

line 9 col 20: Name non-constant identifiers using lowerCamelCase.

line 12 col 20: Name non-constant identifiers using lowerCamelCase.

line 15 col 20: Name non-constant identifiers using lowerCamelCase.

Fix lib/bean/video_item.dart. (-4.41 points)

Analysis of lib/bean/video_item.dart reported 9 hints, including:

line 5 col 10: Name non-constant identifiers using lowerCamelCase.

line 17 col 17: Name non-constant identifiers using lowerCamelCase.

line 20 col 10: Name non-constant identifiers using lowerCamelCase.

line 26 col 7: Name non-constant identifiers using lowerCamelCase.

line 27 col 7: Name non-constant identifiers using lowerCamelCase.

Fix additional 52 files with analysis or formatting issues. (-39.21 points)

Additional issues in the following files:

  • lib/widget/ad_text_widget.dart (8 hints)
  • lib/model_main.dart (7 hints)
  • lib/util/validator.dart (6 hints)
  • lib/widget/givelike_anim_screen.dart (6 hints)
  • lib/util/constant.dart (5 hints)
  • lib/base/pair.dart (4 hints)
  • lib/debug/debug_s_common_action.dart (4 hints)
  • lib/widget/pure_text_widget.dart (4 hints)
  • lib/base/device_info.dart (3 hints)
  • lib/main.dart (3 hints)
  • lib/player_pool.dart (3 hints)
  • lib/widget/page_control_widget.dart (3 hints)
  • lib/base/i_net_http.dart (2 hints)
  • lib/build_config.dart (2 hints)
  • lib/network/root_url.dart (2 hints)
  • lib/util/ui_tools.dart (2 hints)
  • lib/widget/common/base_navi_screen.dart (2 hints)
  • lib/base/i_log.dart (1 hint)
  • lib/base/i_store_sp.dart (1 hint)
  • lib/debug/debug_s_network.dart (1 hint)
  • lib/main_screen.dart (1 hint)
  • lib/model_item.dart (1 hint)
  • lib/network/i_req_base.dart (1 hint)
  • lib/platform/sg_player.dart (1 hint)
  • lib/widget/comment_count_widget.dart (1 hint)
  • lib/widget/error_widget.dart (1 hint)
  • lib/widget/image_button_widget.dart (1 hint)
  • lib/widget/navi_bar_widget.dart (1 hint)
  • lib/widget/page_item_screen.dart (1 hint)
  • lib/widget/write_comment_widget.dart (1 hint)
  • lib/base/i_store_db.dart (Run flutter format to format lib/base/i_store_db.dart.)
  • lib/bean/heart_info.dart (Run flutter format to format lib/bean/heart_info.dart.)
  • lib/bean/rsp_video_list.dart (Run flutter format to format lib/bean/rsp_video_list.dart.)
  • lib/debug/debug_screen.dart (Run flutter format to format lib/debug/debug_screen.dart.)
  • lib/generated/i18n.dart (Run flutter format to format lib/generated/i18n.dart.)
  • lib/locale/localization.dart (Run flutter format to format lib/locale/localization.dart.)
  • lib/locale/messages_all.dart (Run flutter format to format lib/locale/messages_all.dart.)
  • lib/locale/messages_zh.dart (Run flutter format to format lib/locale/messages_zh.dart.)
  • lib/network/i_rsp_base.dart (Run flutter format to format lib/network/i_rsp_base.dart.)
  • lib/network/sg_http_client.dart (Run flutter format to format lib/network/sg_http_client.dart.)
  • lib/sg_log.dart (Run flutter format to format lib/sg_log.dart.)
  • lib/storage/imp_base_store_sp.dart (Run flutter format to format lib/storage/imp_base_store_sp.dart.)
  • lib/test_screen.dart (Run flutter format to format lib/test_screen.dart.)
  • lib/util/crash_handler.dart (Run flutter format to format lib/util/crash_handler.dart.)
  • lib/util/demo_util.dart (Run flutter format to format lib/util/demo_util.dart.)
  • lib/util/statistics_helper.dart (Run flutter format to format lib/util/statistics_helper.dart.)
  • lib/util/toast.dart (Run flutter format to format lib/util/toast.dart.)
  • lib/widget/common/common_expansion_item.dart (Run flutter format to format lib/widget/common/common_expansion_item.dart.)
  • lib/widget/common/positioned_tap_detector.dart (Run flutter format to format lib/widget/common/positioned_tap_detector.dart.)
  • lib/widget/common/sg_page_view.dart (Run flutter format to format lib/widget/common/sg_page_view.dart.)
  • lib/widget/popup_menu_widget.dart (Run flutter format to format lib/widget/popup_menu_widget.dart.)
  • lib/widget/share_button_widget.dart (Run flutter format to format lib/widget/share_button_widget.dart.)

Maintenance issues and suggestions

Support latest dependencies. (-20 points)

The version constraint in pubspec.yaml does not support the latest published versions for 2 dependencies (dio, like_button).

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package.

Common filename patterns include main.dart, example.dart, and short_video.dart. Packages with multiple examples should provide example/README.md.

For more information see the pub package layout conventions.

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.

The package description is too short. (-8 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
connectivity ^0.4.4 0.4.8+1
dio ^2.1.10 2.2.2 3.0.9
flutter 0.0.0
fluttertoast ^3.1.3 3.1.3
intl ^0.16.0 0.16.1
like_button ^0.1.9 0.1.9 0.2.0
logging ^0.11.3+2 0.11.4
scoped_model ^1.0.1 1.0.1
shared_preferences ^0.5.3+4 0.5.6+2
Transitive dependencies
collection 1.14.11 1.14.12
connectivity_macos 0.1.0+1
connectivity_platform_interface 1.0.3 2.0.0
cookie_jar 1.0.1
flutter_web_plugins 0.0.0
meta 1.1.8
path 1.6.4
plugin_platform_interface 1.0.2
shared_preferences_macos 0.0.1+6
shared_preferences_platform_interface 1.0.3
shared_preferences_web 0.1.2+4
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
flutter_test