diff --git a/example/pubspec.lock b/example/pubspec.lock index 94dccb4..f9cd52b 100644 --- a/example/pubspec.lock +++ b/example/pubspec.lock @@ -7,49 +7,49 @@ packages: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.5.0-nullsafety.3" + version: "2.8.2" boolean_selector: dependency: transitive description: name: boolean_selector url: "https://pub.dartlang.org" source: hosted - version: "2.1.0-nullsafety.3" + version: "2.1.0" characters: dependency: transitive description: name: characters url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.5" + version: "1.2.0" charcode: dependency: transitive description: name: charcode url: "https://pub.dartlang.org" source: hosted - version: "1.2.0-nullsafety.3" + version: "1.3.1" clock: dependency: transitive description: name: clock url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.3" + version: "1.1.0" collection: dependency: transitive description: name: collection url: "https://pub.dartlang.org" source: hosted - version: "1.15.0-nullsafety.5" + version: "1.16.0" cupertino_icons: dependency: "direct main" description: name: cupertino_icons url: "https://pub.dartlang.org" source: hosted - version: "1.0.0" + version: "1.0.5" draft_view: dependency: "direct main" description: @@ -63,7 +63,7 @@ packages: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.2.0-nullsafety.3" + version: "1.3.0" flutter: dependency: "direct main" description: flutter @@ -74,34 +74,53 @@ packages: description: flutter source: sdk version: "0.0.0" + flutter_web_plugins: + dependency: transitive + description: flutter + source: sdk + version: "0.0.0" + js: + dependency: transitive + description: + name: js + url: "https://pub.dartlang.org" + source: hosted + version: "0.6.4" matcher: dependency: transitive description: name: matcher url: "https://pub.dartlang.org" source: hosted - version: "0.12.10-nullsafety.3" + version: "0.12.11" + material_color_utilities: + dependency: transitive + description: + name: material_color_utilities + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.4" meta: dependency: transitive description: name: meta url: "https://pub.dartlang.org" source: hosted - version: "1.3.0-nullsafety.6" + version: "1.7.0" path: dependency: transitive description: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.0-nullsafety.3" + version: "1.8.1" plugin_platform_interface: dependency: transitive description: name: plugin_platform_interface url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.1" + version: "2.1.2" sky_engine: dependency: transitive description: flutter @@ -113,91 +132,105 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.8.0-nullsafety.4" + version: "1.8.2" stack_trace: dependency: transitive description: name: stack_trace url: "https://pub.dartlang.org" source: hosted - version: "1.10.0-nullsafety.6" + version: "1.10.0" stream_channel: dependency: transitive description: name: stream_channel url: "https://pub.dartlang.org" source: hosted - version: "2.1.0-nullsafety.3" + version: "2.1.0" string_scanner: dependency: transitive description: name: string_scanner url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.3" + version: "1.1.0" term_glyph: dependency: transitive description: name: term_glyph url: "https://pub.dartlang.org" source: hosted - version: "1.2.0-nullsafety.3" + version: "1.2.0" test_api: dependency: transitive description: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.2.19-nullsafety.6" - typed_data: + version: "0.4.9" + url_launcher: dependency: transitive description: - name: typed_data + name: url_launcher url: "https://pub.dartlang.org" source: hosted - version: "1.3.0-nullsafety.5" - url_launcher: + version: "6.1.4" + url_launcher_android: dependency: transitive description: - name: url_launcher + name: url_launcher_android + url: "https://pub.dartlang.org" + source: hosted + version: "6.0.17" + url_launcher_ios: + dependency: transitive + description: + name: url_launcher_ios url: "https://pub.dartlang.org" source: hosted - version: "6.0.0-nullsafety.4" + version: "6.0.17" url_launcher_linux: dependency: transitive description: name: url_launcher_linux url: "https://pub.dartlang.org" source: hosted - version: "0.1.0-nullsafety.3" + version: "3.0.1" url_launcher_macos: dependency: transitive description: name: url_launcher_macos url: "https://pub.dartlang.org" source: hosted - version: "0.1.0-nullsafety.2" + version: "3.0.1" url_launcher_platform_interface: dependency: transitive description: name: url_launcher_platform_interface url: "https://pub.dartlang.org" source: hosted - version: "2.0.0-nullsafety.1" + version: "2.1.0" + url_launcher_web: + dependency: transitive + description: + name: url_launcher_web + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.12" url_launcher_windows: dependency: transitive description: name: url_launcher_windows url: "https://pub.dartlang.org" source: hosted - version: "0.1.0-nullsafety.2" + version: "3.0.1" vector_math: dependency: transitive description: name: vector_math url: "https://pub.dartlang.org" source: hosted - version: "2.1.0-nullsafety.5" + version: "2.1.2" sdks: - dart: ">=2.12.0-0.0 <3.0.0" - flutter: ">=1.12.13+hotfix.5 <2.0.0" + dart: ">=2.17.0-0 <3.0.0" + flutter: ">=2.10.0" diff --git a/lib/draft_view/block/base_block.dart b/lib/draft_view/block/base_block.dart index 8a230b1..99aef60 100644 --- a/lib/draft_view/block/base_block.dart +++ b/lib/draft_view/block/base_block.dart @@ -55,7 +55,7 @@ class BaseBlock { ); /// If the range within the current block's range - bool withinRange(int start, int end) { + bool withInRange(int start, int end) { if (start == end) { return false; } @@ -281,9 +281,18 @@ class BaseBlock { : FontStyle.normal; /// Get decoration for each block based on their [inline styles] - TextDecoration get decoration => this.inlineStyles.contains("UNDERLINE") - ? TextDecoration.underline - : TextDecoration.none; + TextDecoration get decoration { + TextDecoration decoration = TextDecoration.none; + if (inlineStyles.contains("UNDERLINE")) { + decoration = + TextDecoration.combine([decoration, TextDecoration.underline]); + } + if (inlineStyles.contains("STRIKETHROUGH")) { + decoration = + TextDecoration.combine([decoration, TextDecoration.lineThrough]); + } + return decoration; + } /// Render style based on the block's type and inline styles TextStyle renderStyle(BuildContext context) { diff --git a/lib/draft_view/block/blocks/audio_block.dart b/lib/draft_view/block/blocks/audio_block.dart index b5fe0c4..bb4d0a6 100644 --- a/lib/draft_view/block/blocks/audio_block.dart +++ b/lib/draft_view/block/blocks/audio_block.dart @@ -1,7 +1,6 @@ import 'package:draft_view/draft_view/block/base_block.dart'; -import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; -import 'package:url_launcher/url_launcher.dart'; +import 'package:url_launcher/url_launcher_string.dart'; extension on Duration { String toAudioString() { @@ -14,8 +13,8 @@ extension on Duration { return "-${-this}"; } String twoDigitHours = twoDigits(inHours); - String twoDigitMinutes = twoDigits(inMinutes.remainder(60) as int); - String twoDigitSeconds = twoDigits(inSeconds.remainder(60) as int); + String twoDigitMinutes = twoDigits(inMinutes.remainder(60)); + String twoDigitSeconds = twoDigits(inSeconds.remainder(60)); return "$twoDigitHours:$twoDigitMinutes:$twoDigitSeconds"; } @@ -175,8 +174,8 @@ class _AudioComponentState extends State { WidgetSpan( child: InkWell( onTap: () async { - if (await canLaunch(widget.url)) { - await launch(widget.url); + if (await canLaunchUrlString(widget.url)) { + await launchUrlString(widget.url); } }, child: Text( diff --git a/lib/draft_view/block/blocks/header_block.dart b/lib/draft_view/block/blocks/header_block.dart index d1258a7..1bbef56 100644 --- a/lib/draft_view/block/blocks/header_block.dart +++ b/lib/draft_view/block/blocks/header_block.dart @@ -1,3 +1,4 @@ +import 'dart:convert'; import 'package:draft_view/draft_view/block/base_block.dart'; import 'package:flutter/material.dart'; @@ -29,7 +30,7 @@ class HeaderBlock extends BaseBlock { ); HeaderBlock copyWith({BaseBlock? block}) => HeaderBlock( - depth: block?.depth ?? depth, + depth: block?.depth ?? this.depth, start: block?.start ?? this.start, end: block?.end ?? this.end, inlineStyles: block?.inlineStyles ?? this.inlineStyles, @@ -38,7 +39,7 @@ class HeaderBlock extends BaseBlock { text: block?.text ?? this.text, blockType: block?.blockType ?? this.blockType, level: this.level, - children: block?.children ?? children ?? [], + children: block?.children ?? this.children ?? [], ); @override @@ -102,6 +103,6 @@ class HeaderBlock extends BaseBlock { @override InlineSpan render(BuildContext context, {List? children}) { - return TextSpan(text: "$textContent", style: renderStyle(context)); + return TextSpan(text: textContent, style: renderStyle(context)); } } diff --git a/lib/draft_view/block/blocks/image_block.dart b/lib/draft_view/block/blocks/image_block.dart index 51ea6f0..7efa69e 100644 --- a/lib/draft_view/block/blocks/image_block.dart +++ b/lib/draft_view/block/blocks/image_block.dart @@ -93,7 +93,7 @@ class _ImageComponentState extends State { ), ), Hero( - tag: Key("${widget.caption}"), + tag: Key("${widget.url}"), child: Text("${widget.caption}"), ), ], @@ -165,7 +165,7 @@ class _ImageDetailViewState extends State { child: Padding( padding: const EdgeInsets.all(8.0), child: Hero( - tag: Key("${widget.caption}"), + tag: Key("${widget.url}"), child: Text( "${widget.caption ?? ""}", style: TextStyle(color: Colors.white, fontSize: 20), diff --git a/lib/draft_view/block/blocks/link_block.dart b/lib/draft_view/block/blocks/link_block.dart index 58f2d35..fb3c31c 100644 --- a/lib/draft_view/block/blocks/link_block.dart +++ b/lib/draft_view/block/blocks/link_block.dart @@ -1,10 +1,8 @@ -import 'dart:io'; - import 'package:draft_view/draft_view/block/base_block.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/gestures.dart'; import 'package:flutter/material.dart'; -import 'package:url_launcher/url_launcher.dart'; +import 'package:url_launcher/url_launcher_string.dart'; class LinkBlock extends BaseBlock { LinkBlock({ @@ -30,7 +28,7 @@ class LinkBlock extends BaseBlock { ); LinkBlock copyWith({BaseBlock? block}) => LinkBlock( - depth: block?.depth ?? depth, + depth: block?.depth ?? this.depth, start: block?.start ?? this.start, end: block?.end ?? this.end, inlineStyles: block?.inlineStyles ?? this.inlineStyles, @@ -38,7 +36,7 @@ class LinkBlock extends BaseBlock { data: block?.data ?? this.data, text: block?.text ?? this.text, blockType: block?.blockType ?? this.blockType, - children: block?.children ?? children ?? [], + children: block?.children ?? this.children ?? [], ); @override TextDecoration get decoration => TextDecoration.underline; @@ -130,8 +128,8 @@ class LinkCard extends StatelessWidget { tooltip: "Open in browser", icon: Icon(Icons.launch), onPressed: () async { - if (await canLaunch(link)) { - await launch(link); + if (await canLaunchUrlString(link)) { + await launchUrlString(link); } }, ), diff --git a/lib/draft_view/block/blocks/list_block.dart b/lib/draft_view/block/blocks/list_block.dart index fad24d1..f48e891 100644 --- a/lib/draft_view/block/blocks/list_block.dart +++ b/lib/draft_view/block/blocks/list_block.dart @@ -1,5 +1,4 @@ import 'package:draft_view/draft_view/block/base_block.dart'; -import 'package:draft_view/draft_view/plugin/plugins/list_plugin.dart'; import 'package:flutter/material.dart'; class ListBlock extends BaseBlock { @@ -32,7 +31,7 @@ class ListBlock extends BaseBlock { ); ListBlock copyWith({BaseBlock? block}) => ListBlock( - depth: this.depth, + depth: block?.depth ?? this.depth, start: block?.start ?? this.start, end: block?.end ?? this.end, inlineStyles: block?.inlineStyles ?? this.inlineStyles, @@ -40,7 +39,7 @@ class ListBlock extends BaseBlock { data: block?.data ?? this.data, text: block?.text ?? this.text, blockType: block?.blockType ?? this.blockType, - isOrderedList: isOrderedList, + isOrderedList: this.isOrderedList, order: this.order, ); diff --git a/lib/draft_view/block/blocks/settings_block.dart b/lib/draft_view/block/blocks/settings_block.dart index bae96d9..8aaeaf4 100644 --- a/lib/draft_view/block/blocks/settings_block.dart +++ b/lib/draft_view/block/blocks/settings_block.dart @@ -11,8 +11,6 @@ import 'package:flutter/material.dart'; // final postSettings = postSettingsFromJson(jsonString); // final detailSettings = detailSettingsFromJson(jsonString); -import 'dart:convert'; - /// Post Settings object class Settings { Settings({ @@ -39,9 +37,7 @@ class Settings { ); Map toJson() => { - "settings": settings == null - ? null - : List.from(settings.map((x) => x.toJson())), + "settings": List.from(settings.map((x) => x.toJson())), }; } @@ -68,14 +64,13 @@ class _PostSettings { ? [] : List<_DetailSettings>.from( json["detailSettings"].map((x) => _DetailSettings.fromJson(x))), - id: json["id"] == null ? null : json["id"], + id: json["id"], ); Map toJson() => { - "detailSettings": detailSettings == null - ? null - : List.from(detailSettings.map((x) => x.toJson())), - "id": id == null ? null : id, + "detailSettings": + List.from(detailSettings.map((x) => x.toJson())), + "id": id, }; } @@ -103,13 +98,11 @@ class _DetailSettings { factory _DetailSettings.fromJson(Map json) => _DetailSettings( - description: json["description"] == null ? null : json["description"], - name: json["name"] == null ? null : json["name"], - id: json['id']); + description: json["description"], name: json["name"], id: json['id']); Map toJson() => { - "description": description == null ? null : description, - "name": name == null ? null : name, + "description": description, + "name": name, "id": id, }; } diff --git a/lib/draft_view/block/blocks/text_block.dart b/lib/draft_view/block/blocks/text_block.dart index 07d75f9..cb131f8 100644 --- a/lib/draft_view/block/blocks/text_block.dart +++ b/lib/draft_view/block/blocks/text_block.dart @@ -2,7 +2,6 @@ import 'package:draft_view/draft_view/block/base_block.dart'; import 'package:flutter/material.dart'; class TextBlock extends BaseBlock { - TextBlock({ required int depth, required int start, @@ -24,7 +23,7 @@ class TextBlock extends BaseBlock { ); TextBlock copyWith({BaseBlock? block}) => TextBlock( - depth: block?.depth ?? depth, + depth: block?.depth ?? this.depth, start: block?.start ?? this.start, end: block?.end ?? this.end, inlineStyles: block?.inlineStyles ?? this.inlineStyles, @@ -50,6 +49,6 @@ class NewlineBlock extends BaseBlock { @override InlineSpan render(BuildContext context, {List? children}) { - return TextSpan(text: "\n\n", style: renderStyle(context)); + return TextSpan(text: "\n", style: renderStyle(context)); } } diff --git a/lib/draft_view/converter/converter.dart b/lib/draft_view/converter/converter.dart index 58e783a..32bf15c 100644 --- a/lib/draft_view/converter/converter.dart +++ b/lib/draft_view/converter/converter.dart @@ -20,10 +20,10 @@ class Converter { List retBlocks = []; List draftBlocks = []; Map entityMap = {}; - - for (var block in this.draftData['blocks']) { - var draftBlock = RawDraftContentBlock.fromJson(block); - draftBlocks.add(draftBlock); + DraftObject draftObject = DraftObject.fromJson(draftData); + draftBlocks = draftObject.blocks; + entityMap = draftObject.entityMap; + for (var draftBlock in draftBlocks) { var hasAdded = false; var tmpB = BaseBlock( depth: draftBlock.depth.toInt(), @@ -49,11 +49,6 @@ class Converter { blocks.add(tmpB); } } - - (draftData['entityMap'] as Map).forEach((key, value) { - entityMap[key] = RawDraftEntityKeyStringAny.fromJson(value); - }); - int i = 0; while (i < draftBlocks.length) { @@ -122,7 +117,7 @@ class Converter { int i = 0; while (i < retBlocks.length) { var tmpBlock = retBlocks[i]; - if (tmpBlock.withinRange(start, end)) { + if (tmpBlock.withInRange(start, end)) { var entityData = entityMap[entity.key]; var newBlocks = tmpBlock.split( depth: tmpBlock.depth, @@ -152,7 +147,7 @@ class Converter { int i = 0; while (i < retBlocks.length) { var tmpBlock = retBlocks[i]; - if (tmpBlock.withinRange(start, end)) { + if (tmpBlock.withInRange(start, end)) { var newBlocks = tmpBlock.split( depth: tmpBlock.depth, start: start, diff --git a/lib/draft_view/plugin/plugins/blockquote_plugin.dart b/lib/draft_view/plugin/plugins/blockquote_plugin.dart index 25cbe4d..c594cc1 100644 --- a/lib/draft_view/plugin/plugins/blockquote_plugin.dart +++ b/lib/draft_view/plugin/plugins/blockquote_plugin.dart @@ -1,7 +1,5 @@ import 'package:draft_view/draft_view/block/base_block.dart'; import 'package:draft_view/draft_view/block/blocks/blockquote_block.dart'; -import 'package:draft_view/draft_view/block/blocks/header_block.dart'; -import 'package:draft_view/draft_view/block/blocks/text_block.dart'; import 'package:draft_view/draft_view/plugin/base_plugin.dart'; class BlockQuotePlugin extends BasePlugin { diff --git a/lib/draft_view/plugin/plugins/header_plugin.dart b/lib/draft_view/plugin/plugins/header_plugin.dart index 8c67662..5fdcac0 100644 --- a/lib/draft_view/plugin/plugins/header_plugin.dart +++ b/lib/draft_view/plugin/plugins/header_plugin.dart @@ -1,7 +1,3 @@ -import 'package:draft_view/draft_view/block/blocks/header_block.dart'; -import 'package:draft_view/draft_view/block/blocks/text_block.dart'; -import 'package:draft_view/draft_view/plugin/base_plugin.dart'; - import '../../../draft_view.dart'; class HeaderPlugin extends BasePlugin { diff --git a/lib/draft_view/plugin/plugins/image_plugin.dart b/lib/draft_view/plugin/plugins/image_plugin.dart index 239be5e..209a7ed 100644 --- a/lib/draft_view/plugin/plugins/image_plugin.dart +++ b/lib/draft_view/plugin/plugins/image_plugin.dart @@ -1,6 +1,4 @@ -import 'package:draft_view/draft_view/block/base_block.dart'; import 'package:draft_view/draft_view/block/blocks/image_block.dart'; -import 'package:draft_view/draft_view/block/blocks/text_block.dart'; import 'package:draft_view/draft_view/plugin/base_plugin.dart'; class ImagePlugin extends BasePlugin { diff --git a/lib/draft_view/plugin/plugins/link_plugin.dart b/lib/draft_view/plugin/plugins/link_plugin.dart index 92a9c04..39c9ae6 100644 --- a/lib/draft_view/plugin/plugins/link_plugin.dart +++ b/lib/draft_view/plugin/plugins/link_plugin.dart @@ -1,7 +1,4 @@ -import 'package:draft_view/draft_view/block/base_block.dart'; -import 'package:draft_view/draft_view/block/blocks/image_block.dart'; import 'package:draft_view/draft_view/block/blocks/link_block.dart'; -import 'package:draft_view/draft_view/block/blocks/text_block.dart'; import 'package:draft_view/draft_view/plugin/base_plugin.dart'; class LinkPlugin extends BasePlugin { diff --git a/lib/draft_view/plugin/plugins/list_plugin.dart b/lib/draft_view/plugin/plugins/list_plugin.dart index cfd0bc1..df06771 100644 --- a/lib/draft_view/plugin/plugins/list_plugin.dart +++ b/lib/draft_view/plugin/plugins/list_plugin.dart @@ -1,8 +1,3 @@ -import 'package:draft_view/draft_view/block/blocks/header_block.dart'; -import 'package:draft_view/draft_view/block/blocks/list_block.dart'; -import 'package:draft_view/draft_view/block/blocks/text_block.dart'; -import 'package:draft_view/draft_view/plugin/base_plugin.dart'; - import '../../../draft_view.dart'; class ListPlugin extends BasePlugin { diff --git a/pubspec.lock b/pubspec.lock index 3dd1c17..2baad47 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -7,140 +7,133 @@ packages: name: _fe_analyzer_shared url: "https://pub.dartlang.org" source: hosted - version: "12.0.0" + version: "41.0.0" analyzer: dependency: transitive description: name: analyzer url: "https://pub.dartlang.org" source: hosted - version: "0.40.6" + version: "4.2.0" args: dependency: transitive description: name: args url: "https://pub.dartlang.org" source: hosted - version: "1.6.0" + version: "2.3.1" async: dependency: transitive description: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.5.0-nullsafety.3" + version: "2.8.2" boolean_selector: dependency: transitive description: name: boolean_selector url: "https://pub.dartlang.org" source: hosted - version: "2.1.0-nullsafety.3" + version: "2.1.0" build: dependency: transitive description: name: build url: "https://pub.dartlang.org" source: hosted - version: "1.6.1" + version: "2.3.0" built_collection: dependency: transitive description: name: built_collection url: "https://pub.dartlang.org" source: hosted - version: "4.3.2" + version: "5.1.1" built_value: dependency: transitive description: name: built_value url: "https://pub.dartlang.org" source: hosted - version: "7.1.0" + version: "8.3.3" characters: dependency: transitive description: name: characters url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.5" + version: "1.2.0" charcode: dependency: transitive description: name: charcode url: "https://pub.dartlang.org" source: hosted - version: "1.2.0-nullsafety.3" - cli_util: - dependency: transitive - description: - name: cli_util - url: "https://pub.dartlang.org" - source: hosted - version: "0.2.0" + version: "1.3.1" clock: dependency: transitive description: name: clock url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.3" + version: "1.1.0" code_builder: dependency: transitive description: name: code_builder url: "https://pub.dartlang.org" source: hosted - version: "3.6.0" + version: "4.1.0" collection: dependency: transitive description: name: collection url: "https://pub.dartlang.org" source: hosted - version: "1.15.0-nullsafety.5" + version: "1.16.0" convert: dependency: transitive description: name: convert url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "3.0.2" crypto: dependency: transitive description: name: crypto url: "https://pub.dartlang.org" source: hosted - version: "2.1.5" + version: "3.0.2" dart_style: dependency: transitive description: name: dart_style url: "https://pub.dartlang.org" source: hosted - version: "1.3.10" + version: "2.2.3" fake_async: dependency: transitive description: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.2.0-nullsafety.3" + version: "1.3.0" file: dependency: transitive description: name: file url: "https://pub.dartlang.org" source: hosted - version: "5.2.1" + version: "6.1.2" fixnum: dependency: transitive description: name: fixnum url: "https://pub.dartlang.org" source: hosted - version: "0.10.11" + version: "1.0.1" flutter: dependency: "direct main" description: flutter @@ -151,111 +144,88 @@ packages: description: flutter source: sdk version: "0.0.0" + flutter_web_plugins: + dependency: transitive + description: flutter + source: sdk + version: "0.0.0" glob: dependency: transitive description: name: glob url: "https://pub.dartlang.org" source: hosted - version: "1.2.0" - intl: - dependency: transitive - description: - name: intl - url: "https://pub.dartlang.org" - source: hosted - version: "0.16.1" + version: "2.1.0" js: dependency: transitive description: name: js url: "https://pub.dartlang.org" source: hosted - version: "0.6.2" + version: "0.6.4" logging: dependency: transitive description: name: logging url: "https://pub.dartlang.org" source: hosted - version: "0.11.4" + version: "1.0.2" matcher: dependency: transitive description: name: matcher url: "https://pub.dartlang.org" source: hosted - version: "0.12.10-nullsafety.3" + version: "0.12.11" + material_color_utilities: + dependency: transitive + description: + name: material_color_utilities + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.4" meta: dependency: transitive description: name: meta url: "https://pub.dartlang.org" source: hosted - version: "1.3.0-nullsafety.6" + version: "1.7.0" mockito: dependency: "direct dev" description: name: mockito url: "https://pub.dartlang.org" source: hosted - version: "5.0.0-nullsafety.4" - node_interop: - dependency: transitive - description: - name: node_interop - url: "https://pub.dartlang.org" - source: hosted - version: "1.2.1" - node_io: - dependency: transitive - description: - name: node_io - url: "https://pub.dartlang.org" - source: hosted - version: "1.2.0" + version: "5.2.0" package_config: dependency: transitive description: name: package_config url: "https://pub.dartlang.org" source: hosted - version: "1.9.3" + version: "2.1.0" path: dependency: transitive description: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.0-nullsafety.3" - pedantic: - dependency: transitive - description: - name: pedantic - url: "https://pub.dartlang.org" - source: hosted - version: "1.9.2" + version: "1.8.1" plugin_platform_interface: dependency: transitive description: name: plugin_platform_interface url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.1" + version: "2.1.2" pub_semver: dependency: transitive description: name: pub_semver url: "https://pub.dartlang.org" source: hosted - version: "1.4.4" - quiver: - dependency: transitive - description: - name: quiver - url: "https://pub.dartlang.org" - source: hosted - version: "2.1.5" + version: "2.1.1" sky_engine: dependency: transitive description: flutter @@ -267,112 +237,133 @@ packages: name: source_gen url: "https://pub.dartlang.org" source: hosted - version: "0.9.10+1" + version: "1.2.2" source_span: dependency: transitive description: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.8.0-nullsafety.4" + version: "1.8.2" stack_trace: dependency: transitive description: name: stack_trace url: "https://pub.dartlang.org" source: hosted - version: "1.10.0-nullsafety.6" + version: "1.10.0" stream_channel: dependency: transitive description: name: stream_channel url: "https://pub.dartlang.org" source: hosted - version: "2.1.0-nullsafety.3" + version: "2.1.0" string_scanner: dependency: transitive description: name: string_scanner url: "https://pub.dartlang.org" source: hosted - version: "1.1.0-nullsafety.3" + version: "1.1.0" term_glyph: dependency: transitive description: name: term_glyph url: "https://pub.dartlang.org" source: hosted - version: "1.2.0-nullsafety.3" + version: "1.2.0" test_api: dependency: transitive description: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.2.19-nullsafety.6" + version: "0.4.9" typed_data: dependency: transitive description: name: typed_data url: "https://pub.dartlang.org" source: hosted - version: "1.3.0-nullsafety.5" + version: "1.3.1" url_launcher: dependency: "direct main" description: name: url_launcher url: "https://pub.dartlang.org" source: hosted - version: "6.0.0-nullsafety.4" + version: "6.1.4" + url_launcher_android: + dependency: transitive + description: + name: url_launcher_android + url: "https://pub.dartlang.org" + source: hosted + version: "6.0.17" + url_launcher_ios: + dependency: transitive + description: + name: url_launcher_ios + url: "https://pub.dartlang.org" + source: hosted + version: "6.0.17" url_launcher_linux: dependency: transitive description: name: url_launcher_linux url: "https://pub.dartlang.org" source: hosted - version: "0.1.0-nullsafety.3" + version: "3.0.1" url_launcher_macos: dependency: transitive description: name: url_launcher_macos url: "https://pub.dartlang.org" source: hosted - version: "0.1.0-nullsafety.2" + version: "3.0.1" url_launcher_platform_interface: dependency: transitive description: name: url_launcher_platform_interface url: "https://pub.dartlang.org" source: hosted - version: "2.0.0-nullsafety.1" + version: "2.1.0" + url_launcher_web: + dependency: transitive + description: + name: url_launcher_web + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.12" url_launcher_windows: dependency: transitive description: name: url_launcher_windows url: "https://pub.dartlang.org" source: hosted - version: "0.1.0-nullsafety.2" + version: "3.0.1" vector_math: dependency: transitive description: name: vector_math url: "https://pub.dartlang.org" source: hosted - version: "2.1.0-nullsafety.5" + version: "2.1.2" watcher: dependency: transitive description: name: watcher url: "https://pub.dartlang.org" source: hosted - version: "0.9.7+15" + version: "1.0.1" yaml: dependency: transitive description: name: yaml url: "https://pub.dartlang.org" source: hosted - version: "2.2.1" + version: "3.1.1" sdks: - dart: ">=2.12.0-0.0 <3.0.0" - flutter: ">=1.12.13+hotfix.5 <2.0.0" + dart: ">=2.17.0 <3.0.0" + flutter: ">=2.10.0" diff --git a/pubspec.yaml b/pubspec.yaml index 8088df2..b53ebed 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -4,17 +4,17 @@ version: 0.9.2-nullsafety.0 repository: https://github.com/sirily11/flutter_draftview environment: - sdk: ">=2.12.0-0 <3.0.0" + sdk: ">=2.16.1 <3.0.0" dependencies: flutter: sdk: flutter - url_launcher: any + url_launcher: ^6.1.4 dev_dependencies: flutter_test: sdk: flutter - mockito: 5.0.0-nullsafety.4 + mockito: ^5.2.0 # For information on the generic Dart part of this file, see the # following page: https://dart.dev/tools/pub/pubspec