Skip to content

Commit

Permalink
Fix asset card missing ripple effect
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeDoctorDE committed Jan 2, 2024
1 parent abd4dba commit 1da7619
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 41 deletions.
2 changes: 1 addition & 1 deletion app/lib/dialogs/import/add.dart
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ class AddDialog extends StatelessWidget {
),
Expanded(
child: Material(
color: Colors.transparent,
type: MaterialType.transparency,
child: ValueListenableBuilder(
valueListenable: _searchController,
builder: (context, value, _) {
Expand Down
2 changes: 1 addition & 1 deletion app/lib/settings/connections.dart
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class ConnectionsSettingsPage extends StatelessWidget {
);
}
return Material(
color: Colors.transparent,
type: MaterialType.transparency,
child: ListView.builder(
itemCount: state.connections.length,
itemBuilder: (context, index) {
Expand Down
8 changes: 5 additions & 3 deletions app/lib/settings/home.dart
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ class _SettingsPageState extends State<SettingsPage> {
Widget build(BuildContext context) {
return SafeArea(
child: Material(
color: widget.isDialog ? Colors.transparent : null,
type: widget.isDialog ? MaterialType.transparency : MaterialType.canvas,
child: LayoutBuilder(builder: (context, constraints) {
final isMobile = constraints.maxWidth < 600;

Expand All @@ -93,7 +93,9 @@ class _SettingsPageState extends State<SettingsPage> {
),
Flexible(
child: Material(
color: widget.isDialog ? Colors.transparent : null,
type: widget.isDialog
? MaterialType.transparency
: MaterialType.canvas,
child: ListView(
controller: _scrollController,
shrinkWrap: true,
Expand Down Expand Up @@ -123,7 +125,7 @@ class _SettingsPageState extends State<SettingsPage> {
}),
mode: LaunchMode.externalApplication),
child: Material(
color: Colors.transparent,
type: MaterialType.transparency,
child: SizedBox(
height: 50,
child: SvgPicture.asset(
Expand Down
71 changes: 38 additions & 33 deletions app/lib/views/files/view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -672,43 +672,48 @@ class AssetCard extends StatelessWidget {
child: Card(
elevation: 5,
clipBehavior: Clip.hardEdge,
child: InkWell(
onTap: onTap,
child: Stack(
children: [
if (thumbnail?.isNotEmpty ?? false)
Align(
child: Image.memory(
thumbnail!,
fit: BoxFit.cover,
width: 640,
alignment: Alignment.center,
),
child: Stack(
children: [
if (thumbnail?.isNotEmpty ?? false)
Align(
child: Image.memory(
thumbnail!,
fit: BoxFit.cover,
width: 640,
alignment: Alignment.center,
),
if ((metadata?.name.isNotEmpty ?? false) ||
(name?.isNotEmpty ?? false))
Align(
alignment: Alignment.bottomLeft,
child: Tooltip(
message: name ?? metadata!.name,
child: Container(
padding: const EdgeInsets.all(8),
margin: const EdgeInsets.all(8),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(8),
color: colorScheme.primaryContainer.withAlpha(200),
),
child: Text(
(metadata?.name.isNotEmpty ?? false)
? metadata!.name
: name!,
style: textStyle,
),
),
if ((metadata?.name.isNotEmpty ?? false) ||
(name?.isNotEmpty ?? false))
Align(
alignment: Alignment.bottomLeft,
child: Tooltip(
message: name ?? metadata!.name,
child: Container(
padding: const EdgeInsets.all(8),
margin: const EdgeInsets.all(8),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(8),
color: colorScheme.primaryContainer.withAlpha(200),
),
child: Text(
(metadata?.name.isNotEmpty ?? false)
? metadata!.name
: name!,
style: textStyle,
),
),
),
],
),
),
Positioned.fill(
child: Material(
type: MaterialType.transparency,
child: InkWell(
onTap: onTap,
),
),
),
],
),
),
));
Expand Down
2 changes: 1 addition & 1 deletion app/lib/views/navigator/components.dart
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class _ComponentsViewState extends State<ComponentsView> {
const SizedBox(height: 8),
Expanded(
child: Material(
color: Colors.transparent,
type: MaterialType.transparency,
child: Wrap(
children: pack
?.getComponents()
Expand Down
2 changes: 1 addition & 1 deletion app/lib/views/navigator/pages.dart
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class PagesView extends StatelessWidget {
}).toSet();
final all = [...folders, ...files];
return Material(
color: Colors.transparent,
type: MaterialType.transparency,
child: ReorderableListView.builder(
itemCount: all.length,
onReorder: (oldIndex, newIndex) {
Expand Down
3 changes: 2 additions & 1 deletion fastlane/metadata/android/en-US/changelogs/87.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
* Fix markdown label editing
* Fix not working new line
* Fix not working new line
* Fix asset card missing ripple effect

0 comments on commit 1da7619

Please sign in to comment.