Skip to content

Commit

Permalink
fix: Problem solved.
Browse files Browse the repository at this point in the history
  • Loading branch information
mathrunet committed Sep 5, 2022
1 parent 2114d27 commit e939687
Show file tree
Hide file tree
Showing 22 changed files with 16 additions and 30 deletions.
1 change: 0 additions & 1 deletion packages/katana_module/lib/katana_module.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
/// [YouTube]: https://www.youtube.com/c/mathrunetchannel
library katana_module;

import "package:flutter/material.dart";
import 'package:flutter/services.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:katana_routing/katana_routing.dart';
Expand Down
2 changes: 0 additions & 2 deletions packages/katana_routing/example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// ignore_for_file: public_member_api_docs
import 'package:flutter/material.dart';
import 'package:katana_routing/katana_routing.dart';

void main() {
Expand Down
4 changes: 2 additions & 2 deletions packages/masamune/lib/property/default_text_button_style.dart
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ class DefaultTextButtonStyle extends ButtonStyle {
return DefaultTextButtonStyle._(
TextButton.styleFrom(
padding: padding,
primary: color,
onSurface: color,
foregroundColor: color,
disabledForegroundColor: color,
backgroundColor: backgroundColor,
shape: RoundedRectangleBorder(
side: borderWidth <= 0 || borderColor == Colors.transparent
Expand Down
4 changes: 3 additions & 1 deletion packages/masamune/lib/property/mobile/asset.dart
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,9 @@ class ImageMemoryCache {
throw StateError('$file is empty and cannot be loaded as an image.');
}

return PaintingBinding.instance.instantiateImageCodec(bytes);
return PaintingBinding.instance.instantiateImageCodecFromBuffer(
await ImmutableBuffer.fromUint8List(bytes),
);
}

static ImageStreamCompleter? _getCache(String? key) {
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_cli/bin/command/appbuild/aab.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ class AppBuildAabCliCommand extends CliCommand {

@override
Future<void> exec(YamlMap yaml, List<String> args) async {
final build = yaml["build"] as YamlMap;
final bin = yaml["bin"] as YamlMap;
final flutter = bin["flutter"] as String?;
final generateProcess = await Process.start(
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_cli/bin/command/appbuild/apk.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ class AppBuildApkCliCommand extends CliCommand {

@override
Future<void> exec(YamlMap yaml, List<String> args) async {
final build = yaml["build"] as YamlMap;
final bin = yaml["bin"] as YamlMap;
final flutter = bin["flutter"] as String?;
final generateProcess = await Process.start(
Expand Down
2 changes: 0 additions & 2 deletions packages/masamune_media/lib/dialog/mobile/mobile.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
/// For mobile.
library masamune_media.dialog.mobile;

import 'package:flutter/material.dart';
import 'package:image_picker/image_picker.dart';
import 'package:masamune/masamune.dart';
import 'package:masamune_media/masamune_media.dart';

part 'ui_media_dialog.dart';
2 changes: 0 additions & 2 deletions packages/masamune_media/lib/dialog/others/others.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
/// For others.
library masamune_media.dialog.others;

import 'package:flutter/material.dart';
import 'package:image_picker/image_picker.dart';
import 'package:masamune/masamune.dart';
import 'package:masamune_media/masamune_media.dart';

part 'ui_media_dialog.dart';
4 changes: 2 additions & 2 deletions packages/masamune_module/lib/component/detail/detail.dart
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ class DetailModuleTagsWidget extends ModuleWidget<DetailModule> {
visualDensity: VisualDensity.compact,
padding: const EdgeInsets.fromLTRB(0, 8, 8, 8),
alignment: Alignment.centerLeft,
primary: context.theme.textColor.withOpacity(0.5),
foregroundColor: context.theme.textColor.withOpacity(0.5),
),
child: Text(
"#$e",
Expand Down Expand Up @@ -455,7 +455,7 @@ class DetailModuleActionWidget extends ModuleWidget<DetailModule> {
if (module.enableLike)
TextButton.icon(
style: TextButton.styleFrom(
primary:
foregroundColor:
like ? context.theme.primaryColor : context.theme.textColor,
),
icon: const Icon(Icons.thumb_up),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ class SingleMediaModuleHomePage extends PageModuleWidget<SingleMediaModule> {
? Center(
child: TextButton.icon(
style: TextButton.styleFrom(
primary: context.theme.textColorOnPrimary,
foregroundColor: context.theme.textColorOnPrimary,
backgroundColor: context.theme.primaryColor,
),
label: Text("Add".localize()),
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_module/lib/component/menu/menu.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import 'package:masamune/masamune.dart';
import 'package:masamune_module/masamune_module.dart';

@immutable
Expand Down
4 changes: 2 additions & 2 deletions packages/masamune_module/lib/component/user/user.dart
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ class UserModuleHomePage extends PageModuleWidget<UserModule> {
shape: StadiumBorder(
side: BorderSide(color: context.theme.textColor, width: 2),
),
primary: context.theme.textColor,
foregroundColor: context.theme.textColor,
backgroundColor: context.theme.scaffoldBackgroundColor,
),
)
Expand All @@ -264,7 +264,7 @@ class UserModuleHomePage extends PageModuleWidget<UserModule> {
shape: StadiumBorder(
side: BorderSide(color: context.theme.textColor, width: 2),
),
primary: context.theme.textColor,
foregroundColor: context.theme.textColor,
backgroundColor: context.theme.scaffoldBackgroundColor,
),
)
Expand Down
2 changes: 1 addition & 1 deletion packages/masamune_notion/lib/src/notion_block.dart
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ class _NotionBlockState extends State<NotionBlock> {
switch (block.type) {
case "divider":
return const Padding(
padding: const EdgeInsets.symmetric(vertical: 4),
padding: EdgeInsets.symmetric(vertical: 4),
child: Divid(),
);
case "bulleted_list_item":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class UIBottomCallAction extends StatelessWidget {
style: TextButton.styleFrom(
backgroundColor:
buttonBackgroundColor ?? context.theme.primaryColor,
primary: buttonColor ?? context.theme.textColorOnPrimary,
foregroundColor: buttonColor ?? context.theme.textColorOnPrimary,
elevation: 0.0,
padding: buttonPadding,
shape: RoundedRectangleBorder(
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_ui/lib/form/form.dart
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import 'package:flutter_rating_bar/flutter_rating_bar.dart';
import 'package:intl/intl.dart';
// ignore: import_of_legacy_library_into_null_safe
// import 'package:datetime_picker_formfield/datetime_picker_formfield.dart';
import 'package:masamune/masamune.dart';
import 'package:masamune_ui/masamune_ui.dart';
import 'package:multi_select_flutter/multi_select_flutter.dart';

Expand Down
1 change: 0 additions & 1 deletion packages/masamune_ui/lib/form/mobile/mobile.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ library masamune_ui.form.mobile;
import 'dart:convert';
import 'dart:io';

import 'package:masamune/masamune.dart';
import 'package:masamune_ui/masamune_ui.dart';

part 'form_item_media.dart';
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_ui/lib/form/others/others.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ library masamune_ui.form.others;

import 'dart:convert';

import 'package:masamune/masamune.dart';
import 'package:masamune_ui/masamune_ui.dart';

part 'form_item_media.dart';
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_ui/lib/list/list.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import 'package:collapsible/collapsible.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter_slidable/flutter_slidable.dart';
import 'package:loading_animations/loading_animations.dart';
import 'package:masamune/masamune.dart';
import 'package:masamune_ui/masamune_ui.dart';

export 'package:flutter_slidable/flutter_slidable.dart'
Expand Down
4 changes: 2 additions & 2 deletions packages/masamune_ui/lib/list/next_button.dart
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ class _NextButtonState extends State<NextButton> {
);
} else {
final style = TextButton.styleFrom(
primary: widget.primaryColor,
onSurface: widget.onSurfaceColor,
foregroundColor: widget.primaryColor,
disabledForegroundColor: widget.onSurfaceColor,
backgroundColor: widget.backgroundColor,
shadowColor: widget.shadowColor,
surfaceTintColor: widget.surfaceTintColor,
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_ui/lib/ui/ui.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import 'package:flutter/gestures.dart';
import 'package:flutter/scheduler.dart';
import 'package:flutter/services.dart';
import 'package:loading_animations/loading_animations.dart';
import 'package:masamune/masamune.dart';
import 'package:masamune_ui/masamune_ui.dart';

part 'ui_scaffold.dart';
Expand Down
4 changes: 2 additions & 2 deletions packages/masamune_ui/lib/ui/ui_scaffold.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1082,7 +1082,7 @@ class _WebMainAppBar extends StatelessWidget implements PreferredSizeWidget {
context.rootNavigator.pushNamed(e.path!);
},
style: TextButton.styleFrom(
primary: foregroundColor ??
foregroundColor: foregroundColor ??
context.theme.appBarTheme.foregroundColor ??
context.theme.textColorOnPrimary,
),
Expand All @@ -1097,7 +1097,7 @@ class _WebMainAppBar extends StatelessWidget implements PreferredSizeWidget {
context.rootNavigator.pushNamed(e.path!);
},
style: TextButton.styleFrom(
primary: foregroundColor ??
foregroundColor: foregroundColor ??
context.theme.appBarTheme.foregroundColor ??
context.theme.textColorOnPrimary,
),
Expand Down
1 change: 0 additions & 1 deletion packages/masamune_ui/lib/variable/variable.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ library masamune_ui.variable;

import 'dart:convert';

import 'package:masamune/masamune.dart';
import 'package:masamune_ui/masamune_ui.dart';

part 'form/text_form_config.dart';
Expand Down

0 comments on commit e939687

Please sign in to comment.