-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Closed
Copy link
Labels
P3Issues that are less important to the Flutter projectIssues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to FlutterA detailed proposal for a change to Flutterp: flutter_adaptive_scaffoldThe flutter_adaptive_scaffold packageThe flutter_adaptive_scaffold packagepackageflutter/packages repository. See also p: labels.flutter/packages repository. See also p: labels.r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-ecosystemOwned by Ecosystem teamOwned by Ecosystem teamtriaged-ecosystemTriaged by Ecosystem teamTriaged by Ecosystem team
Description
Use case
Currently, AdaptiveScaffold takes only List<NavigationDestination> as destinations parameter, which is understandable, to make its type common. But, it results in us not being able to use other parameter exposed by NavigationRailDestination such as individual indicatorColor, indicatorShape and the most important one for me personally, padding.
Proposal
Expose a mapper method parameter to allow us customize individual NavigationRailDestination.
return AdaptiveScaffold(
mapNavigationRailDestination: (int index, NavigationDestination dest) {
return NavigationRailDestination(
icon: dest.icon,
label: Text(dest.label),
padding: newSections.contains(index)
? const EdgeInsets.only(top: 12)
: EdgeInsets.zero,
);
},
);esenmx, martijn00 and AZealDeveloper
Metadata
Metadata
Assignees
Labels
P3Issues that are less important to the Flutter projectIssues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to FlutterA detailed proposal for a change to Flutterp: flutter_adaptive_scaffoldThe flutter_adaptive_scaffold packageThe flutter_adaptive_scaffold packagepackageflutter/packages repository. See also p: labels.flutter/packages repository. See also p: labels.r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-ecosystemOwned by Ecosystem teamOwned by Ecosystem teamtriaged-ecosystemTriaged by Ecosystem teamTriaged by Ecosystem team