Comments (3)
Hello!
I want to use slideable on a list of cards, but since the Card Widget has a rounder border than the slidable Widget, it looks very odd. I originally wanted to make a fork that had the correct border with elevation and more "round" edges, but I can't find the lines where you define the border of the slidable. I therefore do not know what to change. I know it is a small issue, but any help is still greatly appreciated. Thanks in advance.
Hi!
I think I found solution. Check Delegate class that you use in your slidable.dart and just tweak the value of extent in ctx.getMaxExtent:
class SlidableBehindDelegate extends SlidableStackDelegate {
const SlidableBehindDelegate({
double fastThreshold,
}) : super(
fastThreshold: fastThreshold,
);
@override
Widget buildStackActions(BuildContext context, SlidableDelegateContext ctx) {
return new Positioned.fill(
child: new LayoutBuilder(builder: (context, constraints) {
return new Stack(
children: <Widget>[
ctx.createPositioned(
position: 0.0,
extent:
ctx.getMaxExtent(constraints) * ctx.state.totalActionsExtent + 10.0, // TWEAK THIS TO FIND THE BEST OFFSET FOR YOUR UI (Add double value)
child: new Flex(
direction: ctx.state.widget.direction,
children: ctx
.buildActions(context)
.map((a) => Expanded(child: a))
.toList(),
),
),
],
);
}),
);
}
}
from flutter_slidable.
For the refactoring:
Make sure action panes are clipped
from flutter_slidable.
This is now possible in 1.0.0. I will close this ticket. If you have any issue, please open a new one.
from flutter_slidable.
Related Issues (20)
- How to provide border radius to it ?
- The icon of SlidableAction will not be displayed in the center when padding is not set
- Style problem HOT 2
- How do I add a remove animation?
- How to open panes when creating widgets in Flutter slideable package
- When SlidableAction slides to the left to open, close the current page.
- Slidable open Not effective ?
- Doesn't work inside a PageView HOT 1
- how to dismiss slidableAction when using other widget HOT 1
- Want notification when automatically turning off sideslip
- Selection of text inside `TextField` triggers slidable
- how to open slidable in InitState HOT 1
- How to define custom height? HOT 1
- Edit label style and icons size
- Secondary deletion
- How to set the slider extent? HOT 1
- Subsequent row is open after Slidable row is dismissed.
- Focus on flutter web HOT 1
- Query: Smooth DismissiblePane Implementation within ActionPane?
- Slidable widget not closing properly HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flutter_slidable.