mirror of
https://github.com/immich-app/immich.git
synced 2025-01-01 08:31:59 +00:00
wip
This commit is contained in:
parent
5818197c10
commit
9e99973c18
1 changed files with 97 additions and 7 deletions
|
@ -34,7 +34,7 @@ class OnboardingPage extends HookConsumerWidget {
|
||||||
body: SafeArea(
|
body: SafeArea(
|
||||||
child: PageView(
|
child: PageView(
|
||||||
controller: pageController,
|
controller: pageController,
|
||||||
physics: const NeverScrollableScrollPhysics(),
|
// physics: const NeverScrollableScrollPhysics(),
|
||||||
children: [
|
children: [
|
||||||
OnboardingWelcome(
|
OnboardingWelcome(
|
||||||
onNextPage: () => toNextPage(),
|
onNextPage: () => toNextPage(),
|
||||||
|
@ -197,8 +197,8 @@ class AnimatedHeroImageState extends State<AnimatedHeroImage>
|
||||||
image: AssetImage(widget.imagePath),
|
image: AssetImage(widget.imagePath),
|
||||||
filterQuality: FilterQuality.high,
|
filterQuality: FilterQuality.high,
|
||||||
isAntiAlias: true,
|
isAntiAlias: true,
|
||||||
color: widget.color,
|
// color: widget.color,
|
||||||
colorBlendMode: widget.colorBlendMode,
|
// colorBlendMode: widget.colorBlendMode,
|
||||||
),
|
),
|
||||||
builder: (context, child) {
|
builder: (context, child) {
|
||||||
return Transform.scale(
|
return Transform.scale(
|
||||||
|
@ -223,10 +223,100 @@ class OnboardingGalleryPermission extends StatelessWidget {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Center(
|
return ListView(
|
||||||
child: ElevatedButton(
|
padding: const EdgeInsets.all(24.0),
|
||||||
onPressed: onNextPage,
|
physics: const ClampingScrollPhysics(),
|
||||||
child: const Text("to location permission"),
|
children: [
|
||||||
|
Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Icon(
|
||||||
|
Icons.perm_media_outlined,
|
||||||
|
size: 48,
|
||||||
|
color: context.primaryColor.withAlpha(250),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
const SizedBox(height: 32),
|
||||||
|
Text(
|
||||||
|
"Gallery Permission",
|
||||||
|
style: context.textTheme.headlineMedium?.copyWith(
|
||||||
|
fontWeight: FontWeight.w600,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const SizedBox(height: 8),
|
||||||
|
Text(
|
||||||
|
"We need the read and write permission of the media gallery for the following actions",
|
||||||
|
style: context.textTheme.headlineSmall?.copyWith(
|
||||||
|
fontWeight: FontWeight.w400,
|
||||||
|
color: context.colorScheme.onSurface.withAlpha(220),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const SizedBox(height: 40),
|
||||||
|
const BulletList([
|
||||||
|
'Display the local videos and images',
|
||||||
|
'Read the file content to upload to your Immich instance',
|
||||||
|
'Remove the media from the device on your request',
|
||||||
|
]),
|
||||||
|
const SizedBox(height: 64),
|
||||||
|
SizedBox(
|
||||||
|
height: 48,
|
||||||
|
child: ElevatedButton(
|
||||||
|
onPressed: onNextPage,
|
||||||
|
child: const Text(
|
||||||
|
'OK',
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 18,
|
||||||
|
fontWeight: FontWeight.w600,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
class BulletList extends StatelessWidget {
|
||||||
|
final List<String> strings;
|
||||||
|
|
||||||
|
const BulletList(this.strings, {super.key});
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return Container(
|
||||||
|
alignment: Alignment.centerLeft,
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: strings.map((textString) {
|
||||||
|
return Padding(
|
||||||
|
padding: const EdgeInsets.only(top: 8.0),
|
||||||
|
child: Row(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
const Text(
|
||||||
|
'\u2022',
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 20,
|
||||||
|
height: 1.25,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const SizedBox(width: 8),
|
||||||
|
Expanded(
|
||||||
|
child: Text(
|
||||||
|
textString,
|
||||||
|
textAlign: TextAlign.left,
|
||||||
|
softWrap: true,
|
||||||
|
style: context.textTheme.headlineSmall?.copyWith(
|
||||||
|
fontSize: 20,
|
||||||
|
fontWeight: FontWeight.w400,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}).toList(),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue