mirror of
https://github.com/Dr-Blank/Vaani.git
synced 2026-07-07 09:51:34 +00:00
Compare commits
5 commits
4663ff9094
...
f569041ab3
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f569041ab3 | ||
|
|
39d051746b | ||
|
|
4ebf46d2fd | ||
|
|
4af16ac5b4 | ||
|
|
28ceca5408 |
27 changed files with 214 additions and 169 deletions
8
.github/release-drafter.yml
vendored
8
.github/release-drafter.yml
vendored
|
|
@ -40,7 +40,7 @@ template: |
|
||||||
**Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION
|
**Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION
|
||||||
|
|
||||||
exclude-labels:
|
exclude-labels:
|
||||||
- "skip-changelog"
|
- "skip changelog"
|
||||||
|
|
||||||
exclude-contributors:
|
exclude-contributors:
|
||||||
- "Dr-Blank"
|
- "Dr-Blank"
|
||||||
|
|
@ -55,15 +55,15 @@ autolabeler:
|
||||||
branch:
|
branch:
|
||||||
- '/feature\/.+/'
|
- '/feature\/.+/'
|
||||||
title:
|
title:
|
||||||
- "/feat(ure)?/i"
|
- "/^feat(ure)?/i"
|
||||||
body:
|
body:
|
||||||
- "/JIRA-[0-9]{1,4}/"
|
- "/JIRA-[0-9]{1,4}/"
|
||||||
- label: "chore"
|
- label: "chore"
|
||||||
title:
|
title:
|
||||||
- "/chore/i"
|
- "/^chore\b/i"
|
||||||
- label: "ui"
|
- label: "ui"
|
||||||
title:
|
title:
|
||||||
- "/^ui\b/i"
|
- "/^ui\b/i"
|
||||||
- label: "refactor"
|
- label: "refactor"
|
||||||
title:
|
title:
|
||||||
- "/refactor/i"
|
- "/^refactor/i"
|
||||||
|
|
|
||||||
4
.github/workflows/flutter-ci.yaml
vendored
4
.github/workflows/flutter-ci.yaml
vendored
|
|
@ -48,6 +48,10 @@ jobs:
|
||||||
# - name: Run static analysis
|
# - name: Run static analysis
|
||||||
# run: flutter analyze
|
# run: flutter analyze
|
||||||
|
|
||||||
|
- name: Check formatting
|
||||||
|
run: |
|
||||||
|
dart format -o none --set-exit-if-changed lib/
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: flutter test
|
run: flutter test
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,5 +10,4 @@ class HeroTagPrefixes {
|
||||||
static const String bookTitle = 'book_title_';
|
static const String bookTitle = 'book_title_';
|
||||||
static const String narratorName = 'narrator_name_';
|
static const String narratorName = 'narrator_name_';
|
||||||
static const String libraryItemPlayButton = 'library_item_play_button_';
|
static const String libraryItemPlayButton = 'library_item_play_button_';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -98,8 +98,10 @@ class MySearchBar extends HookConsumerWidget {
|
||||||
// opacity: 0.5 for the hint text
|
// opacity: 0.5 for the hint text
|
||||||
hintStyle: WidgetStatePropertyAll(
|
hintStyle: WidgetStatePropertyAll(
|
||||||
Theme.of(context).textTheme.bodyMedium!.copyWith(
|
Theme.of(context).textTheme.bodyMedium!.copyWith(
|
||||||
color:
|
color: Theme.of(context)
|
||||||
Theme.of(context).colorScheme.onSurface.withOpacity(0.5),
|
.colorScheme
|
||||||
|
.onSurface
|
||||||
|
.withValues(alpha: 0.5),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
textInputAction: TextInputAction.search,
|
textInputAction: TextInputAction.search,
|
||||||
|
|
|
||||||
|
|
@ -199,8 +199,10 @@ class _LibraryItemProgressIndicator extends HookConsumerWidget {
|
||||||
'${remainingTime.smartBinaryFormat} left',
|
'${remainingTime.smartBinaryFormat} left',
|
||||||
|
|
||||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
||||||
color:
|
color: Theme.of(context)
|
||||||
Theme.of(context).colorScheme.onSurface.withOpacity(0.75),
|
.colorScheme
|
||||||
|
.onSurface
|
||||||
|
.withValues(alpha: 0.75),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
@ -227,7 +229,7 @@ class _HeroSectionSubLabelWithIcon extends HookConsumerWidget {
|
||||||
ref.watch(appSettingsProvider).themeSettings.useMaterialThemeOnItemPage;
|
ref.watch(appSettingsProvider).themeSettings.useMaterialThemeOnItemPage;
|
||||||
final color = useMaterialThemeOnItemPage
|
final color = useMaterialThemeOnItemPage
|
||||||
? themeData.colorScheme.primary
|
? themeData.colorScheme.primary
|
||||||
: themeData.colorScheme.onSurface.withOpacity(0.75);
|
: themeData.colorScheme.onSurface.withValues(alpha: 0.75);
|
||||||
return Padding(
|
return Padding(
|
||||||
padding: const EdgeInsets.only(bottom: 8.0),
|
padding: const EdgeInsets.only(bottom: 8.0),
|
||||||
child: Row(
|
child: Row(
|
||||||
|
|
@ -443,7 +445,7 @@ class _BookTitle extends StatelessWidget {
|
||||||
? const SizedBox.shrink()
|
? const SizedBox.shrink()
|
||||||
: Text(
|
: Text(
|
||||||
style: themeData.textTheme.titleSmall?.copyWith(
|
style: themeData.textTheme.titleSmall?.copyWith(
|
||||||
color: themeData.colorScheme.onSurface.withOpacity(0.8),
|
color: themeData.colorScheme.onSurface.withValues(alpha: 0.8),
|
||||||
),
|
),
|
||||||
itemBookMetadata?.subtitle ?? '',
|
itemBookMetadata?.subtitle ?? '',
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -96,7 +96,10 @@ class LibraryItemMetadata extends HookConsumerWidget {
|
||||||
return VerticalDivider(
|
return VerticalDivider(
|
||||||
indent: 6,
|
indent: 6,
|
||||||
endIndent: 6,
|
endIndent: 6,
|
||||||
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.6),
|
color: Theme.of(context)
|
||||||
|
.colorScheme
|
||||||
|
.onSurface
|
||||||
|
.withValues(alpha: 0.6),
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|
@ -125,7 +128,7 @@ class _MetadataItem extends StatelessWidget {
|
||||||
children: [
|
children: [
|
||||||
Text(
|
Text(
|
||||||
style: themeData.textTheme.titleMedium?.copyWith(
|
style: themeData.textTheme.titleMedium?.copyWith(
|
||||||
color: themeData.colorScheme.onSurface.withOpacity(0.90),
|
color: themeData.colorScheme.onSurface.withValues(alpha: 0.90),
|
||||||
),
|
),
|
||||||
value,
|
value,
|
||||||
maxLines: 1,
|
maxLines: 1,
|
||||||
|
|
@ -133,7 +136,7 @@ class _MetadataItem extends StatelessWidget {
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
style: themeData.textTheme.bodySmall?.copyWith(
|
style: themeData.textTheme.bodySmall?.copyWith(
|
||||||
color: themeData.colorScheme.onSurface.withOpacity(0.7),
|
color: themeData.colorScheme.onSurface.withValues(alpha: 0.7),
|
||||||
),
|
),
|
||||||
title,
|
title,
|
||||||
maxLines: 1,
|
maxLines: 1,
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,37 @@ class OnboardingSinglePage extends HookConsumerWidget {
|
||||||
super.key,
|
super.key,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context, WidgetRef ref) {
|
||||||
|
return Scaffold(
|
||||||
|
body: LayoutBuilder(
|
||||||
|
builder: (BuildContext context, BoxConstraints constraints) {
|
||||||
|
return Center(
|
||||||
|
child: SingleChildScrollView(
|
||||||
|
child: ConstrainedBox(
|
||||||
|
constraints: BoxConstraints(
|
||||||
|
maxWidth: 600,
|
||||||
|
minWidth:
|
||||||
|
constraints.maxWidth < 600 ? constraints.maxWidth : 0,
|
||||||
|
),
|
||||||
|
child: const Padding(
|
||||||
|
padding: EdgeInsets.symmetric(vertical: 20.0),
|
||||||
|
child: SafeArea(child: OnboardingBody()),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
class OnboardingBody extends HookConsumerWidget {
|
||||||
|
const OnboardingBody({
|
||||||
|
super.key,
|
||||||
|
});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context, WidgetRef ref) {
|
Widget build(BuildContext context, WidgetRef ref) {
|
||||||
final apiSettings = ref.watch(apiSettingsProvider);
|
final apiSettings = ref.watch(apiSettingsProvider);
|
||||||
|
|
@ -39,65 +70,65 @@ class OnboardingSinglePage extends HookConsumerWidget {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return Scaffold(
|
return Column(
|
||||||
body: SingleChildScrollView(
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
child: Column(
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
children: [
|
||||||
children: [
|
Padding(
|
||||||
Padding(
|
padding: const EdgeInsets.all(8.0),
|
||||||
padding: const EdgeInsets.all(8.0),
|
child: Text(
|
||||||
child: Text(
|
'Welcome to Vaani',
|
||||||
'Welcome to Vaani',
|
style: Theme.of(context).textTheme.headlineSmall,
|
||||||
style: Theme.of(context).textTheme.headlineSmall,
|
),
|
||||||
),
|
|
||||||
),
|
|
||||||
const SizedBox.square(
|
|
||||||
dimension: 16.0,
|
|
||||||
),
|
|
||||||
Padding(
|
|
||||||
padding: const EdgeInsets.all(8.0),
|
|
||||||
child: AnimatedSwitcher(
|
|
||||||
duration: 500.ms,
|
|
||||||
transitionBuilder: fadeSlideTransitionBuilder,
|
|
||||||
child: canUserLogin.value
|
|
||||||
? Text(
|
|
||||||
'Server connected, please login',
|
|
||||||
key: const ValueKey('connected'),
|
|
||||||
style: Theme.of(context).textTheme.bodyMedium,
|
|
||||||
)
|
|
||||||
: Text(
|
|
||||||
'Please enter the URL of your AudiobookShelf Server',
|
|
||||||
key: const ValueKey('not_connected'),
|
|
||||||
style: Theme.of(context).textTheme.bodyMedium,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Padding(
|
|
||||||
padding: const EdgeInsets.all(8.0),
|
|
||||||
child: AddNewServer(
|
|
||||||
controller: serverUriController,
|
|
||||||
allowEmpty: true,
|
|
||||||
onPressed: () {
|
|
||||||
canUserLogin.value = serverUriController.text.isNotEmpty;
|
|
||||||
},
|
|
||||||
),
|
|
||||||
),
|
|
||||||
AnimatedSwitcher(
|
|
||||||
duration: 500.ms,
|
|
||||||
transitionBuilder: fadeSlideTransitionBuilder,
|
|
||||||
child: canUserLogin.value
|
|
||||||
? UserLoginWidget(
|
|
||||||
server: audiobookshelfUri,
|
|
||||||
)
|
|
||||||
// ).animate().fade(duration: 600.ms).slideY(begin: 0.3, end: 0)
|
|
||||||
: const RedirectToABS().animate().fadeIn().slideY(
|
|
||||||
curve: Curves.easeInOut,
|
|
||||||
duration: 500.ms,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
const SizedBox.square(
|
||||||
|
dimension: 16.0,
|
||||||
|
),
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: AnimatedSwitcher(
|
||||||
|
duration: 500.ms,
|
||||||
|
transitionBuilder: fadeSlideTransitionBuilder,
|
||||||
|
child: canUserLogin.value
|
||||||
|
? Text(
|
||||||
|
'Server connected, please login',
|
||||||
|
key: const ValueKey('connected'),
|
||||||
|
style: Theme.of(context).textTheme.bodyMedium,
|
||||||
|
)
|
||||||
|
: Text(
|
||||||
|
'Please enter the URL of your AudiobookShelf Server',
|
||||||
|
key: const ValueKey('not_connected'),
|
||||||
|
style: Theme.of(context).textTheme.bodyMedium,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: AddNewServer(
|
||||||
|
controller: serverUriController,
|
||||||
|
allowEmpty: true,
|
||||||
|
onPressed: () {
|
||||||
|
canUserLogin.value = serverUriController.text.isNotEmpty;
|
||||||
|
},
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const SizedBox.square(
|
||||||
|
dimension: 16.0,
|
||||||
|
),
|
||||||
|
AnimatedSwitcher(
|
||||||
|
duration: 500.ms,
|
||||||
|
transitionBuilder: fadeSlideTransitionBuilder,
|
||||||
|
child: canUserLogin.value
|
||||||
|
? UserLoginWidget(
|
||||||
|
server: audiobookshelfUri,
|
||||||
|
)
|
||||||
|
// ).animate().fade(duration: 600.ms).slideY(begin: 0.3, end: 0)
|
||||||
|
: const RedirectToABS().animate().fadeIn().slideY(
|
||||||
|
curve: Curves.easeInOut,
|
||||||
|
duration: 500.ms,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -130,11 +130,11 @@ class UserLoginMultipleAuth extends HookConsumerWidget {
|
||||||
return Center(
|
return Center(
|
||||||
child: InactiveFocusScopeObserver(
|
child: InactiveFocusScopeObserver(
|
||||||
child: AutofillGroup(
|
child: AutofillGroup(
|
||||||
child: Padding(
|
child: Column(
|
||||||
padding: const EdgeInsets.all(8.0),
|
children: [
|
||||||
child: Column(
|
Padding(
|
||||||
children: [
|
padding: const EdgeInsets.all(8.0),
|
||||||
Wrap(
|
child: Wrap(
|
||||||
// mainAxisAlignment: MainAxisAlignment.center,
|
// mainAxisAlignment: MainAxisAlignment.center,
|
||||||
spacing: 10,
|
spacing: 10,
|
||||||
runAlignment: WrapAlignment.center,
|
runAlignment: WrapAlignment.center,
|
||||||
|
|
@ -174,10 +174,10 @@ class UserLoginMultipleAuth extends HookConsumerWidget {
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
const SizedBox.square(
|
),
|
||||||
dimension: 8,
|
Padding(
|
||||||
),
|
padding: const EdgeInsets.all(8.0),
|
||||||
switch (methodChoice.value) {
|
child: switch (methodChoice.value) {
|
||||||
AuthMethodChoice.authToken => UserLoginWithToken(
|
AuthMethodChoice.authToken => UserLoginWithToken(
|
||||||
server: server,
|
server: server,
|
||||||
addServer: addServer,
|
addServer: addServer,
|
||||||
|
|
@ -192,8 +192,8 @@ class UserLoginMultipleAuth extends HookConsumerWidget {
|
||||||
openIDButtonText: openIDButtonText,
|
openIDButtonText: openIDButtonText,
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -29,6 +29,7 @@ class UserLoginWithPassword extends HookConsumerWidget {
|
||||||
final usernameController = useTextEditingController();
|
final usernameController = useTextEditingController();
|
||||||
final passwordController = useTextEditingController();
|
final passwordController = useTextEditingController();
|
||||||
final isPasswordVisibleAnimationController = useAnimationController(
|
final isPasswordVisibleAnimationController = useAnimationController(
|
||||||
|
initialValue: 1,
|
||||||
duration: const Duration(milliseconds: 500),
|
duration: const Duration(milliseconds: 500),
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -92,76 +93,76 @@ class UserLoginWithPassword extends HookConsumerWidget {
|
||||||
return Center(
|
return Center(
|
||||||
child: InactiveFocusScopeObserver(
|
child: InactiveFocusScopeObserver(
|
||||||
child: AutofillGroup(
|
child: AutofillGroup(
|
||||||
child: Padding(
|
child: Column(
|
||||||
padding: const EdgeInsets.all(8.0),
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
child: Column(
|
children: [
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
TextFormField(
|
||||||
children: [
|
controller: usernameController,
|
||||||
TextFormField(
|
autofocus: true,
|
||||||
controller: usernameController,
|
autofillHints: const [AutofillHints.username],
|
||||||
autofocus: true,
|
textInputAction: TextInputAction.next,
|
||||||
autofillHints: const [AutofillHints.username],
|
decoration: InputDecoration(
|
||||||
textInputAction: TextInputAction.next,
|
labelText: 'Username',
|
||||||
decoration: InputDecoration(
|
labelStyle: TextStyle(
|
||||||
labelText: 'Username',
|
color: Theme.of(context)
|
||||||
labelStyle: TextStyle(
|
.colorScheme
|
||||||
color: Theme.of(context)
|
.onSurface
|
||||||
.colorScheme
|
.withValues(alpha: 0.8),
|
||||||
.onSurface
|
|
||||||
.withOpacity(0.8),
|
|
||||||
),
|
|
||||||
border: const OutlineInputBorder(),
|
|
||||||
),
|
),
|
||||||
|
border: const OutlineInputBorder(),
|
||||||
),
|
),
|
||||||
const SizedBox(height: 10),
|
),
|
||||||
TextFormField(
|
const SizedBox(height: 10),
|
||||||
controller: passwordController,
|
TextFormField(
|
||||||
autofillHints: const [AutofillHints.password],
|
controller: passwordController,
|
||||||
textInputAction: TextInputAction.done,
|
autofillHints: const [AutofillHints.password],
|
||||||
obscureText: !isPasswordVisible.value,
|
textInputAction: TextInputAction.done,
|
||||||
onFieldSubmitted: (_) {
|
obscureText: !isPasswordVisible.value,
|
||||||
loginAndSave();
|
onFieldSubmitted: (_) {
|
||||||
},
|
loginAndSave();
|
||||||
decoration: InputDecoration(
|
},
|
||||||
labelText: 'Password',
|
decoration: InputDecoration(
|
||||||
labelStyle: TextStyle(
|
labelText: 'Password',
|
||||||
color: Theme.of(context)
|
labelStyle: TextStyle(
|
||||||
|
color: Theme.of(context)
|
||||||
|
.colorScheme
|
||||||
|
.onSurface
|
||||||
|
.withValues(alpha: 0.8),
|
||||||
|
),
|
||||||
|
border: const OutlineInputBorder(),
|
||||||
|
suffixIcon: ColorFiltered(
|
||||||
|
colorFilter: ColorFilter.mode(
|
||||||
|
Theme.of(context)
|
||||||
.colorScheme
|
.colorScheme
|
||||||
.onSurface
|
.primary
|
||||||
.withOpacity(0.8),
|
.withValues(alpha: 0.8),
|
||||||
|
BlendMode.srcIn,
|
||||||
),
|
),
|
||||||
border: const OutlineInputBorder(),
|
child: InkWell(
|
||||||
suffixIcon: ColorFiltered(
|
borderRadius: BorderRadius.circular(50),
|
||||||
colorFilter: ColorFilter.mode(
|
onTap: () {
|
||||||
Theme.of(context).colorScheme.primary.withOpacity(0.8),
|
isPasswordVisible.value = !isPasswordVisible.value;
|
||||||
BlendMode.srcIn,
|
},
|
||||||
),
|
child: Container(
|
||||||
child: InkWell(
|
margin: const EdgeInsets.only(left: 8, right: 8),
|
||||||
borderRadius: BorderRadius.circular(50),
|
child: Lottie.asset(
|
||||||
onTap: () {
|
'assets/animations/Animation - 1714930099660.json',
|
||||||
isPasswordVisible.value = !isPasswordVisible.value;
|
controller: isPasswordVisibleAnimationController,
|
||||||
},
|
|
||||||
child: Container(
|
|
||||||
margin: const EdgeInsets.only(left: 8, right: 8),
|
|
||||||
child: Lottie.asset(
|
|
||||||
'assets/animations/Animation - 1714930099660.json',
|
|
||||||
controller: isPasswordVisibleAnimationController,
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
suffixIconConstraints: const BoxConstraints(
|
),
|
||||||
maxHeight: 45,
|
suffixIconConstraints: const BoxConstraints(
|
||||||
),
|
maxHeight: 45,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
const SizedBox(height: 30),
|
),
|
||||||
ElevatedButton(
|
const SizedBox(height: 30),
|
||||||
onPressed: loginAndSave,
|
ElevatedButton(
|
||||||
child: const Text('Login'),
|
onPressed: loginAndSave,
|
||||||
),
|
child: const Text('Login'),
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -84,7 +84,10 @@ class UserLoginWithToken extends HookConsumerWidget {
|
||||||
decoration: InputDecoration(
|
decoration: InputDecoration(
|
||||||
labelText: 'API Token',
|
labelText: 'API Token',
|
||||||
labelStyle: TextStyle(
|
labelStyle: TextStyle(
|
||||||
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.8),
|
color: Theme.of(context)
|
||||||
|
.colorScheme
|
||||||
|
.onSurface
|
||||||
|
.withValues(alpha: 0.8),
|
||||||
),
|
),
|
||||||
border: const OutlineInputBorder(),
|
border: const OutlineInputBorder(),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -104,8 +104,10 @@ class PlayerWhenExpanded extends HookConsumerWidget {
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
boxShadow: [
|
boxShadow: [
|
||||||
BoxShadow(
|
BoxShadow(
|
||||||
color:
|
color: Theme.of(context)
|
||||||
Theme.of(context).colorScheme.primary.withOpacity(0.1),
|
.colorScheme
|
||||||
|
.primary
|
||||||
|
.withValues(alpha: 0.1),
|
||||||
blurRadius: 32 * earlyPercentage,
|
blurRadius: 32 * earlyPercentage,
|
||||||
spreadRadius: 8 * earlyPercentage,
|
spreadRadius: 8 * earlyPercentage,
|
||||||
// offset: Offset(0, 16 * earlyPercentage),
|
// offset: Offset(0, 16 * earlyPercentage),
|
||||||
|
|
@ -171,7 +173,7 @@ class PlayerWhenExpanded extends HookConsumerWidget {
|
||||||
color: Theme.of(context)
|
color: Theme.of(context)
|
||||||
.colorScheme
|
.colorScheme
|
||||||
.onSurface
|
.onSurface
|
||||||
.withOpacity(0.7),
|
.withValues(alpha: 0.7),
|
||||||
),
|
),
|
||||||
maxLines: 1,
|
maxLines: 1,
|
||||||
overflow: TextOverflow.ellipsis,
|
overflow: TextOverflow.ellipsis,
|
||||||
|
|
|
||||||
|
|
@ -93,7 +93,7 @@ class PlayerWhenMinimized extends HookConsumerWidget {
|
||||||
color: Theme.of(context)
|
color: Theme.of(context)
|
||||||
.colorScheme
|
.colorScheme
|
||||||
.onSurface
|
.onSurface
|
||||||
.withOpacity(0.7),
|
.withValues(alpha: 0.7),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,6 @@ import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||||||
import 'package:list_wheel_scroll_view_nls/list_wheel_scroll_view_nls.dart';
|
import 'package:list_wheel_scroll_view_nls/list_wheel_scroll_view_nls.dart';
|
||||||
import 'package:vaani/features/player/providers/audiobook_player.dart';
|
import 'package:vaani/features/player/providers/audiobook_player.dart';
|
||||||
import 'package:vaani/settings/app_settings_provider.dart';
|
import 'package:vaani/settings/app_settings_provider.dart';
|
||||||
import 'package:vaani/shared/hooks.dart';
|
|
||||||
|
|
||||||
const double itemExtent = 25;
|
const double itemExtent = 25;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,6 @@ import 'package:vaani/features/sleep_timer/providers/sleep_timer_provider.dart'
|
||||||
import 'package:vaani/main.dart';
|
import 'package:vaani/main.dart';
|
||||||
import 'package:vaani/settings/app_settings_provider.dart';
|
import 'package:vaani/settings/app_settings_provider.dart';
|
||||||
import 'package:vaani/shared/extensions/duration_format.dart';
|
import 'package:vaani/shared/extensions/duration_format.dart';
|
||||||
import 'package:vaani/shared/hooks.dart';
|
|
||||||
|
|
||||||
class SleepTimerButton extends HookConsumerWidget {
|
class SleepTimerButton extends HookConsumerWidget {
|
||||||
const SleepTimerButton({
|
const SleepTimerButton({
|
||||||
|
|
|
||||||
|
|
@ -261,9 +261,7 @@ class ServerManagerPage extends HookConsumerWidget {
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
MiniPlayerBottomPadding(),
|
MiniPlayerBottomPadding(),
|
||||||
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -76,7 +76,7 @@ class HomePage extends HookConsumerWidget {
|
||||||
child: ListView.separated(
|
child: ListView.separated(
|
||||||
itemBuilder: (context, index) => shelvesToDisplay[index],
|
itemBuilder: (context, index) => shelvesToDisplay[index],
|
||||||
separatorBuilder: (context, index) => Divider(
|
separatorBuilder: (context, index) => Divider(
|
||||||
color: Theme.of(context).dividerColor.withOpacity(0.1),
|
color: Theme.of(context).dividerColor.withValues(alpha: 0.1),
|
||||||
indent: 16,
|
indent: 16,
|
||||||
endIndent: 16,
|
endIndent: 16,
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ class LibraryPage extends HookConsumerWidget {
|
||||||
child: ListView.separated(
|
child: ListView.separated(
|
||||||
itemBuilder: (context, index) => shelvesToDisplay[index],
|
itemBuilder: (context, index) => shelvesToDisplay[index],
|
||||||
separatorBuilder: (context, index) => Divider(
|
separatorBuilder: (context, index) => Divider(
|
||||||
color: Theme.of(context).dividerColor.withOpacity(0.1),
|
color: Theme.of(context).dividerColor.withValues(alpha: 0.1),
|
||||||
indent: 16,
|
indent: 16,
|
||||||
endIndent: 16,
|
endIndent: 16,
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -16,5 +16,4 @@ class LibraryItemExtras with _$LibraryItemExtras {
|
||||||
BookMinified? book,
|
BookMinified? book,
|
||||||
@Default('') String heroTagSuffix,
|
@Default('') String heroTagSuffix,
|
||||||
}) = _LibraryItemExtras;
|
}) = _LibraryItemExtras;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
import 'package:flutter/foundation.dart' show immutable;
|
import 'package:flutter/foundation.dart' show immutable;
|
||||||
|
|
||||||
|
|
||||||
@immutable
|
@immutable
|
||||||
class AppMetadata {
|
class AppMetadata {
|
||||||
const AppMetadata._();
|
const AppMetadata._();
|
||||||
|
|
|
||||||
|
|
@ -40,7 +40,7 @@ class NavigationWithSwitchTile extends AbstractSettingsTile {
|
||||||
child: Row(
|
child: Row(
|
||||||
children: [
|
children: [
|
||||||
VerticalDivider(
|
VerticalDivider(
|
||||||
color: Theme.of(context).dividerColor.withOpacity(0.5),
|
color: Theme.of(context).dividerColor.withValues(alpha: 0.5),
|
||||||
indent: 8.0,
|
indent: 8.0,
|
||||||
endIndent: 8.0,
|
endIndent: 8.0,
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:url_launcher/url_launcher.dart';
|
import 'package:url_launcher/url_launcher.dart';
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@ class AddNewServer extends HookConsumerWidget {
|
||||||
decoration: InputDecoration(
|
decoration: InputDecoration(
|
||||||
labelText: 'Server URI',
|
labelText: 'Server URI',
|
||||||
labelStyle: TextStyle(
|
labelStyle: TextStyle(
|
||||||
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.8),
|
color: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.8),
|
||||||
),
|
),
|
||||||
border: const OutlineInputBorder(),
|
border: const OutlineInputBorder(),
|
||||||
prefixText:
|
prefixText:
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@ import 'package:go_router/go_router.dart';
|
||||||
import 'package:vaani/features/you/view/server_manager.dart';
|
import 'package:vaani/features/you/view/server_manager.dart';
|
||||||
import 'package:vaani/router/router.dart';
|
import 'package:vaani/router/router.dart';
|
||||||
|
|
||||||
|
|
||||||
class MyDrawer extends StatelessWidget {
|
class MyDrawer extends StatelessWidget {
|
||||||
const MyDrawer({
|
const MyDrawer({
|
||||||
super.key,
|
super.key,
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ class ExpandableDescription extends HookWidget {
|
||||||
// header with carrot icon is tapable
|
// header with carrot icon is tapable
|
||||||
InkWell(
|
InkWell(
|
||||||
borderRadius: BorderRadius.circular(8),
|
borderRadius: BorderRadius.circular(8),
|
||||||
|
|
||||||
onTap: () {
|
onTap: () {
|
||||||
isDescExpanded.value = !isDescExpanded.value;
|
isDescExpanded.value = !isDescExpanded.value;
|
||||||
if (isDescExpanded.value) {
|
if (isDescExpanded.value) {
|
||||||
|
|
|
||||||
|
|
@ -255,8 +255,10 @@ class _BookOnShelfPlayButton extends HookConsumerWidget {
|
||||||
child: CircularProgressIndicator(
|
child: CircularProgressIndicator(
|
||||||
value: userProgress.progress,
|
value: userProgress.progress,
|
||||||
strokeWidth: strokeWidth,
|
strokeWidth: strokeWidth,
|
||||||
backgroundColor:
|
backgroundColor: Theme.of(context)
|
||||||
Theme.of(context).colorScheme.onPrimary.withOpacity(0.8),
|
.colorScheme
|
||||||
|
.onPrimary
|
||||||
|
.withValues(alpha: 0.8),
|
||||||
valueColor: AlwaysStoppedAnimation<Color>(
|
valueColor: AlwaysStoppedAnimation<Color>(
|
||||||
Theme.of(context).colorScheme.primary,
|
Theme.of(context).colorScheme.primary,
|
||||||
),
|
),
|
||||||
|
|
@ -274,7 +276,10 @@ class _BookOnShelfPlayButton extends HookConsumerWidget {
|
||||||
const Size(size, size),
|
const Size(size, size),
|
||||||
),
|
),
|
||||||
backgroundColor: WidgetStateProperty.all(
|
backgroundColor: WidgetStateProperty.all(
|
||||||
Theme.of(context).colorScheme.onPrimary.withOpacity(0.9),
|
Theme.of(context)
|
||||||
|
.colorScheme
|
||||||
|
.onPrimary
|
||||||
|
.withValues(alpha: 0.9),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
onPressed: () async {
|
onPressed: () async {
|
||||||
|
|
@ -316,9 +321,10 @@ class BookCoverSkeleton extends StatelessWidget {
|
||||||
child: SizedBox(
|
child: SizedBox(
|
||||||
width: 150,
|
width: 150,
|
||||||
child: Shimmer.fromColors(
|
child: Shimmer.fromColors(
|
||||||
baseColor: Theme.of(context).colorScheme.surface.withOpacity(0.3),
|
baseColor:
|
||||||
|
Theme.of(context).colorScheme.surface.withValues(alpha: 0.3),
|
||||||
highlightColor:
|
highlightColor:
|
||||||
Theme.of(context).colorScheme.onSurface.withOpacity(0.1),
|
Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.1),
|
||||||
child: Container(
|
child: Container(
|
||||||
color: Theme.of(context).colorScheme.surface,
|
color: Theme.of(context).colorScheme.surface,
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ publish_to: "none" # Remove this line if you wish to publish to pub.dev
|
||||||
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
||||||
# In Windows, build-name is used as the major, minor, and patch parts
|
# In Windows, build-name is used as the major, minor, and patch parts
|
||||||
# of the product and file versions while build-number is used as the build suffix.
|
# of the product and file versions while build-number is used as the build suffix.
|
||||||
version: 0.0.16+7
|
version: 0.0.17+8
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: ">=3.3.4 <4.0.0"
|
sdk: ">=3.3.4 <4.0.0"
|
||||||
|
|
|
||||||
2
shelfsdk
2
shelfsdk
|
|
@ -1 +1 @@
|
||||||
Subproject commit ac8e94df7b28c4334165a11c3b445cd0cc497495
|
Subproject commit 5cc545ca87c05615473ab9c363cfa29e341d1e2a
|
||||||
Loading…
Add table
Add a link
Reference in a new issue