~repos /only-bible-app

#kotlin#android#ios

git clone https://pyrossh.dev/repos/only-bible-app.git
Discussions: https://groups.google.com/g/rust-embed-devs

The only bible app you will ever need. No ads. No in-app purchases. No distractions.


2ea165f8 pyrossh

2 years ago
add ActionsBar
Files changed (1) hide show
  1. lib/widgets/actions_bar.dart +31 -0
lib/widgets/actions_bar.dart ADDED
@@ -0,0 +1,31 @@
1
+ import "package:flutter/material.dart";
2
+ import "package:only_bible_app/state.dart";
3
+ import "package:only_bible_app/widgets/play_button.dart";
4
+
5
+ class ActionsBar extends StatelessWidget {
6
+ const ActionsBar({super.key});
7
+
8
+ @override
9
+ Widget build(BuildContext context) {
10
+ final isDesktop = isWide(context);
11
+ final showPlay = ChapterViewModel.of(context).hasSelectedVerses();
12
+ if (isDesktop || !showPlay) {
13
+ // TODO: hack fix this
14
+ return const ColoredBox(color: Colors.transparent);
15
+ }
16
+ return BottomSheet(
17
+ enableDrag: false,
18
+ onClosing: () {},
19
+ builder: (BuildContext ctx) => Container(
20
+ // TODO: check if this is needed
21
+ // padding: const EdgeInsets.only(bottom: 0),
22
+ child: const Row(
23
+ mainAxisAlignment: MainAxisAlignment.center,
24
+ children: [
25
+ PlayButton(),
26
+ ],
27
+ ),
28
+ ),
29
+ );
30
+ }
31
+ }