Skip to content

Optional properties: selectable, placeholderAlignment. #1191

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

Closed
wants to merge 2 commits into from

Conversation

darkstarx
Copy link

To eliminate the issue of using this widget inside the IntrinsicHeight, we must temporary discard of using baseline alignment. This PR makes this property bottom by default and still allows to customize the value to keep the widget ready to use when the Flutter issue flutter/flutter#65895 is solved (by configuring the placeholderAlignment property for specific tags in the style property). Also it makes the property selectable customizable as well.

@TDuffinNTU
Copy link

TDuffinNTU commented Nov 21, 2022

Can confirm the fix works on my project, at least to fix the layout issues :) I've noticed my table doesn't scroll (within its single child scroll view) which is another issue but I'll quickly confirm if that's on my end.

@TDuffinNTU
Copy link

Appears there are still some layout regressions with this fix, even though it does improve on laying out otherwise. Tables are now having large amounts of whitespace between columns instead of sizing themselves to match their content + padding. The scrolling behaviour also appears to be a regression, but oddly works slightly better if you add a scroll controller with an intialScrollOffset value.

I'll keep investigating but I think this is due to the lack of intrinsic width calculations of the columns with these changes.

@husainazkas
Copy link

This solve my issue👍 thanks @darkstarx

@ElDuderini
Copy link

I would love to see this pushed into the next alpha release. This issue in particular is what is preventing me from using the alpha releases of the HTML plugin.

@fondoger
Copy link

I tested this PR. It fixed the Intrinsic issue, and works pretty well. I would like to have it in the master branch, too.

@Sub6Resources Sub6Resources self-requested a review May 9, 2023 16:19
@Sub6Resources Sub6Resources self-assigned this May 9, 2023
@Sub6Resources Sub6Resources added this to the 3.0.0 milestone May 9, 2023
Copy link
Owner

@Sub6Resources Sub6Resources left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, we're not changing all the subpackages to reference your fork of the project 😉.

I haven't had a chance to test the placeholderAlignment changes, but the requested changes need to be made before we can even consider merging.

flutter_html:
git:
url: git@github.com:darkstarx/flutter_html.git
ref: master
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an issue

flutter_html:
git:
url: git@github.com:darkstarx/flutter_html.git
ref: master
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove all instances of referencing your own fork

@@ -62,6 +62,7 @@ class Html extends StatefulWidget {
this.onImageTap,
this.tagsList = const [],
this.style = const {},
this.selectable = false,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're moving away from SelectableHtml (see #1153). Please remove this selectable parameter from your changes so we can evaluate just the placeholderAlignment portion.

@Sub6Resources Sub6Resources removed this from the 3.0.0 milestone May 16, 2023
@darkstarx
Copy link
Author

Sorry, we're not changing all the subpackages to reference your fork of the project 😉.

I haven't had a chance to test the placeholderAlignment changes, but the requested changes need to be made before we can even consider merging.

If you're in charge of maintenance of this project, please, take an effort to do all of this changes you mentioned yourself in your repository to eliminate the bug. I won't remove anything from my fork since everything suits me in it.

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

Successfully merging this pull request may close these issues.

6 participants