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

Implement non-lazy table component #471

Open
rock3r opened this issue Jul 22, 2024 · 5 comments · May be fixed by #735
Open

Implement non-lazy table component #471

rock3r opened this issue Jul 22, 2024 · 5 comments · May be fixed by #735
Assignees
Labels
in-progress This issue is being worked on new component A new component to implement

Comments

@rock3r
Copy link
Collaborator

rock3r commented Jul 22, 2024

We need a simple, non-lazy table component to use for Markdown tables.

  • Has a title column with separate styling
  • Does not scroll vertically
  • Does not support cell selection, cell editing, or any kind of interaction — it's only a layout
  • Horizontally, it takes up as much space as the content needs
  • Can scroll horizontally if needed; columns should take their IntrinsicSize.Min for width in that case
  • Title row cells' content is h-centered
  • Cell contents are vertically center-aligned, horizontally left/start-aligned
  • Nice to have: alternating BG for rows
@rock3r rock3r added the new component A new component to implement label Jul 22, 2024
@rock3r
Copy link
Collaborator Author

rock3r commented Sep 3, 2024

@jrlogsdon any updates on this?

@jrlogsdon
Copy link
Collaborator

This is my WIP branch

I have processing into our own TableBlock done and some basic rendering, but it doesn't look right yet so I'm going to have to spend more time learning/looking at docs to get this to look good in Compose.

I should be able to get back to this week but first have some 2024.2 platform tasks.

@rock3r rock3r added the in-progress This issue is being worked on label Sep 6, 2024
@rock3r
Copy link
Collaborator Author

rock3r commented Nov 24, 2024

@jrlogsdon I just realised we can take @halilozercan's Table implementation (with his permission!) and reuse it. Should save us a lot of time :)

See https://github.com/halilozercan/compose-richtext/blob/main/richtext-ui/src/commonMain/kotlin/com/halilibo/richtext/ui/Table.kt

@halilozercan
Copy link

It is not mine but Zach Klippenstein's implementation :) It is also rather outdated but seems to work still. I would just advise you to give it a review before adopting it. You are of course welcome to use it.

@rock3r
Copy link
Collaborator Author

rock3r commented Nov 24, 2024

Thanks! Hadn't looked at the blame... I'll check with Zach, too. And if course yeah we'll give it a proper dust off :)

@rock3r rock3r linked a pull request Dec 20, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in-progress This issue is being worked on new component A new component to implement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants