Skip to content

Commit

Permalink
fix: Slight change to Code.
Browse files Browse the repository at this point in the history
  • Loading branch information
mathrunet committed Dec 16, 2022
1 parent 7ea5ec2 commit 6040f2b
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 12 deletions.
16 changes: 10 additions & 6 deletions packages/katana_cli/lib/code/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,15 @@ part '$baseName.localize.dart';
// TODO: Define the title of the application.
const title = "${1}";
/// Initial page query.
// TODO: Define the initial page query of the application.
final initialQuery = ${2:null};
/// App Model.
///
/// By replacing this with another adapter, the data storage location can be changed.
// TODO: Change the database.
const modelAdapter = ${2:RuntimeModelAdapter()};
const modelAdapter = ${3:RuntimeModelAdapter()};
/// App Theme.
///
Expand All @@ -70,7 +74,7 @@ final theme = AppThemeData(
// TODO: Set the design.
primary: Colors.blue,
secondary: Colors.cyan,
${3}
${4}
);
/// App Router.
Expand All @@ -82,8 +86,8 @@ final theme = AppThemeData(
@appRoute
final router = AppRouter(
// TODO: Please configure the initial routing and redirection settings.
boot: ${4:null},
initialQuery: ${5:null},
boot: ${5:null},
initialQuery: initialQuery,
redirect: [
${6}
],
Expand Down Expand Up @@ -117,12 +121,12 @@ const flavor = String.fromEnvironment("FLAVOR");
void main() {
runApp(
MasamuneApp(
title: _title,
title: title,
appRef: appRef,
routerConfig: router,
localize: l,
theme: theme,
modelAdapter: _modelAdapter,
modelAdapter: modelAdapter,
),
);
}
Expand Down
2 changes: 1 addition & 1 deletion packages/katana_cli/lib/code/page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class ${className}Page extends PageScopedWidget {
// Describes the structure of the page.
// TODO: Implement the view.
return \${5};
return \${5:Scaffold()};
}
}
""";
Expand Down
6 changes: 3 additions & 3 deletions packages/katana_cli/lib/code/tmp/basic.dart
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ class ${className}Page extends PageScopedWidget {
// Describes the structure of the page.
// TODO: Implement the view.
return \${3};
return \${3:Scaffold()};
}
}
Expand Down Expand Up @@ -137,7 +137,7 @@ class ${className}DetailPage extends PageScopedWidget {
// Describes the structure of the page.
// TODO: Implement the view.
return \${6};
return \${6:Scaffold()};
}
}
Expand Down Expand Up @@ -204,7 +204,7 @@ class ${className}Form extends FormScopedWidget {
// Describes the structure of the page.
// TODO: Implement the view.
return \${10};
return \${10:Scaffold()};
}
}
""";
Expand Down
2 changes: 1 addition & 1 deletion packages/katana_cli/lib/code/tmp/form.dart
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ class ${className}Form extends FormScopedWidget {
// Describes the structure of the page.
// TODO: Implement the view.
return \${5};
return \${5:Scaffold()};
}
}
""";
Expand Down
2 changes: 1 addition & 1 deletion packages/katana_cli/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ packages:
name: katana
url: "https://pub.dartlang.org"
source: hosted
version: "0.15.10"
version: "0.15.10+1"
lints:
dependency: "direct main"
description:
Expand Down

0 comments on commit 6040f2b

Please sign in to comment.