1.3.2 fix has caused dismissal pane to overflow now

Abierto
#366 2 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
28/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
dart, flutter
Área
frontend, mobile

Línea de trabajo

The body quotes a snippet that wraps an Align in a ClipRect and switches on value == 1; find that code in the repository by searching for clipBehavior, then read the git history of the 1.3.2 change that removed the conditional. Reproduce the left-side overflow by dragging a dismissible tile outside its ListView. Done means the tile stays clipped in that case and the change does not reintroduce the problem the 1.3.2 fix addressed.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

A fix was recently implemented in 1.3.2 to remove clipBehavior: value == 1 ? Clip.none : Clip.hardEdge

But this has now resulted in the tile overflowing on the left when dragged outside of the ListView it's placed inside - I think we need to use Clip.hardEdge to prevent this.

Is there an issue with just doing this?

final align = Align(
      alignment: alignment,
      heightFactor: axis == Axis.vertical ? value : null,
      widthFactor: axis == Axis.horizontal ? value : null,
      child: child,
    );

    // if (value == 1) {
    //   // We don't want to clip our child in normal conditions.
    //   return align;
    // }

    // We can't use ClipBehavior.none on Flutter versions < 3.
    return ClipRect(
      clipBehavior: Clip.hardEdge, <------ THIS SOLVES THE ISSUE
      child: align,
    );
Lenguaje dominante
Dart
Estrellas
2.9k
Forks
646
Merge medio
5 min
PR fusionados (30 d)
9

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de letsar/flutter_slidable

Todos los issues de letsar/flutter_slidable

Issues similares

Más issues de Dart

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.