Adjust padding on carousel items
This commit is contained in:
parent
f7f75ff81f
commit
c1c60ae56a
@ -8,14 +8,12 @@ class _CollapsingCarouselItem extends StatelessWidget {
|
|||||||
required this.child,
|
required this.child,
|
||||||
required this.indexOffset,
|
required this.indexOffset,
|
||||||
required this.width,
|
required this.width,
|
||||||
required this.bottom,
|
|
||||||
required this.onPressed,
|
required this.onPressed,
|
||||||
required this.title})
|
required this.title})
|
||||||
: super(key: key);
|
: super(key: key);
|
||||||
final Widget child;
|
final Widget child;
|
||||||
final int indexOffset;
|
final int indexOffset;
|
||||||
final double width;
|
final double width;
|
||||||
final double bottom;
|
|
||||||
final VoidCallback onPressed;
|
final VoidCallback onPressed;
|
||||||
final String title;
|
final String title;
|
||||||
@override
|
@override
|
||||||
@ -39,7 +37,7 @@ class _CollapsingCarouselItem extends StatelessWidget {
|
|||||||
// Center item is portrait, the others are square
|
// Center item is portrait, the others are square
|
||||||
height: indexOffset == 0 ? tallHeight : width,
|
height: indexOffset == 0 ? tallHeight : width,
|
||||||
width: width,
|
width: width,
|
||||||
padding: indexOffset == 0 ? EdgeInsets.all(0) : EdgeInsets.all(30),
|
padding: indexOffset == 0 ? EdgeInsets.all(0) : EdgeInsets.all(width * .1),
|
||||||
child: child,
|
child: child,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
|
|
||||||
|
import 'package:flutter/foundation.dart';
|
||||||
import 'package:wonders/common_libs.dart';
|
import 'package:wonders/common_libs.dart';
|
||||||
import 'package:wonders/logic/collectibles_logic.dart';
|
import 'package:wonders/logic/collectibles_logic.dart';
|
||||||
import 'package:wonders/logic/data/collectible_data.dart';
|
import 'package:wonders/logic/data/collectible_data.dart';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user