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

[REVIEW ONLY] Add slot APIs to GroupHeader #720

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

hamen
Copy link
Collaborator

@hamen hamen commented Dec 9, 2024

Overview

  • Add slot APIs for start and end components
  • Add KDOC according to the new convention
  • Add a sample in Standalone to showcase a possible implementation of the current Swing solution
20241209-1414-57.3788581.mp4

Signed-off-by: Ivan Morgillo <[email protected]>
@hamen hamen self-assigned this Dec 9, 2024
@hamen hamen requested a review from rock3r December 9, 2024 15:15
@@ -88,4 +127,4 @@ internal fun Borders() {
.border(borderAlignment, width, borderColor, RoundedCornerShape(4.dp, 0.dp, 4.dp, 0.dp), expand)
)
}
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you restore the empty line at EOF?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Somewhere over the rainbow 🌈, my settings get lost

verticalAlignment = Alignment.CenterVertically,
horizontalArrangement = Arrangement.spacedBy(8.dp),
) {
startComponent?.let { Box(Modifier.size(16.dp)) { it() } }
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please don't use let instead of if (thing != null)

Also, we likely need a spacer between the component and the text (same on the end component)

Copy link
Collaborator

Choose a reason for hiding this comment

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

Nevermind about the spacer, had not noticed the arrangement :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done in a63940c

}
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Empty line at EOF here too :)

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

Successfully merging this pull request may close these issues.

2 participants