Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

problem when including the widget in a row #3

Closed
dealfonso opened this issue Oct 25, 2022 · 1 comment
Closed

problem when including the widget in a row #3

dealfonso opened this issue Oct 25, 2022 · 1 comment

Comments

@dealfonso
Copy link

Hi,

there is a problem when including the item in a row:

The example code is:

@override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Row(
        children: [
          TagEditor(
            delimiters: const [ ',', '\n'],...

The error:

RenderBox was not laid out: RenderFlex#4bc99 relayoutBoundary=up1 NEEDS-PAINT NEEDS-COMPOSITING-BITS-UPDATE
'package:flutter/src/rendering/box.dart':
package:flutter/…/rendering/box.dart:1
Failed assertion: line 2001 pos 12: 'hasSize'
@dealfonso
Copy link
Author

Solved by wrapping TagEditor in a Container with a fixed size:

 body: LayoutBuilder(
        builder: (context, constraints) {
         return Column(
          children: [
            Row(
              children: [
                SizedBox(
                  width: constraints.maxWidth,
                  child: TagEditor(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant