Обработка переполнения горизонтального степпера - PullRequest
0 голосов
/ 31 августа 2018

Я реализовал очень простой горизонтальный степпер с несколькими шагами. Однако я получаю баннер переполнения, заявляющий, что мои шаги не соответствуют виду

Как сделать панель с прокруткой по шагам?

import 'package:flutter/material.dart';

class SetupPage extends StatefulWidget {
  @override
  _SetupPageState createState() => _SetupPageState();
}

class _SetupPageState extends State<SetupPage> {

  List<Step> steps = [
    new Step(title: Text('Step 1'), content: new Container()),
    new Step(title: Text('Step 2'), content: new Container()),
    new Step(title: Text('Step 3'), content: new Container()),
    new Step(title: Text('Step 4'), content: new Container()),
    new Step(title: Text('Step 5'), content: new Container()),
    new Step(title: Text('Step 6'), content: new Container()),
    new Step(title: Text('Step 7'), content: new Container()),
  ];

  @override
  Widget build(BuildContext context) {
    return new Scaffold(
      appBar: AppBar(title: Text('Setup'),),
      body: new Stepper(steps: steps, type: StepperType.horizontal, currentStep: 0,),
    );
  }
}
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...