mirror of
https://github.com/Nioux/AideDeJeu.git
synced 2025-12-15 22:59:39 +00:00
Localization
This commit is contained in:
parent
dece242a54
commit
6f3a87ac5e
15 changed files with 268 additions and 56 deletions
|
|
@ -1,12 +1,7 @@
|
|||
import 'package:aidedejeu_flutter/database.dart';
|
||||
import 'package:aidedejeu_flutter/models/filters.dart';
|
||||
import 'package:aidedejeu_flutter/widgets/filters.dart';
|
||||
import 'package:aidedejeu_flutter/models/items.dart';
|
||||
import 'package:aidedejeu_flutter/localization.dart';
|
||||
import 'package:aidedejeu_flutter/widgets/library.dart';
|
||||
import 'package:aidedejeu_flutter/widgets/pceditor.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_markdown/flutter_markdown.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
|
||||
class HomePage extends StatelessWidget {
|
||||
|
|
@ -15,52 +10,67 @@ class HomePage extends StatelessWidget {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(title: Text("Haches & Dés"),),
|
||||
appBar: AppBar(
|
||||
title: Text(
|
||||
AppLocalizations.of(context).title,
|
||||
),
|
||||
),
|
||||
body: Column(
|
||||
children: <Widget>[
|
||||
FlatButton.icon(
|
||||
label: Text("Bibliothèque"),
|
||||
icon: SvgPicture.asset(
|
||||
"assets/spell-book.svg",
|
||||
height: 100.0,
|
||||
width: 100.0,
|
||||
allowDrawingOutsideViewBox: true,
|
||||
),
|
||||
onPressed: () => Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => LibraryPage(id: 'index.md')),
|
||||
),
|
||||
),
|
||||
FlatButton.icon(
|
||||
label: Text("Personnages"),
|
||||
icon: SvgPicture.asset(
|
||||
"assets/swordman.svg",
|
||||
height: 100.0,
|
||||
width: 100.0,
|
||||
allowDrawingOutsideViewBox: true,
|
||||
),
|
||||
onPressed: () => Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => PCEditorPage()),
|
||||
),
|
||||
),
|
||||
FlatButton.icon(
|
||||
label: Text("A propos de..."),
|
||||
icon: SvgPicture.asset(
|
||||
"assets/wooden-sign.svg",
|
||||
height: 100.0,
|
||||
width: 100.0,
|
||||
allowDrawingOutsideViewBox: true,
|
||||
),
|
||||
onPressed: () => Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => LibraryPage(id: 'index.md')),
|
||||
),
|
||||
),
|
||||
],
|
||||
));
|
||||
children: <Widget>[
|
||||
FlatButton.icon(
|
||||
label: Text("Bibliothèque"),
|
||||
icon: SvgPicture.asset(
|
||||
"assets/spell-book.svg",
|
||||
height: 100.0,
|
||||
width: 100.0,
|
||||
allowDrawingOutsideViewBox: true,
|
||||
),
|
||||
onPressed: () => Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => LibraryPage(
|
||||
id: 'index.md',
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
FlatButton.icon(
|
||||
label: Text(
|
||||
"Personnages",
|
||||
),
|
||||
icon: SvgPicture.asset(
|
||||
"assets/swordman.svg",
|
||||
height: 100.0,
|
||||
width: 100.0,
|
||||
allowDrawingOutsideViewBox: true,
|
||||
),
|
||||
onPressed: () => Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => PCEditorPage(),
|
||||
),
|
||||
),
|
||||
),
|
||||
FlatButton.icon(
|
||||
label: Text(
|
||||
"A propos de...",
|
||||
),
|
||||
icon: SvgPicture.asset(
|
||||
"assets/wooden-sign.svg",
|
||||
height: 100.0,
|
||||
width: 100.0,
|
||||
allowDrawingOutsideViewBox: true,
|
||||
),
|
||||
onPressed: () => Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => LibraryPage(
|
||||
id: 'index.md',
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue