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

SearchKit - Set button size default to btn-xs to match existing UI #24755

Merged
merged 1 commit into from
Oct 17, 2022

Conversation

colemanw
Copy link
Member

Overview

During the sprint one of the screens converted to SearchKit accidentally set the wrong button size, which is an easy mistake to make since the "wrong" size is the default. This fixes it and also changes the default to prevent more such accidents.

Before

Default of btn-sm which tends to make tables with lots of buttons feel crowded.

After

For buttons in a table, btn-xs generally fits the best, so let's make that the default.

@civibot
Copy link

civibot bot commented Oct 14, 2022

(Standard links)

@civibot civibot bot added the master label Oct 14, 2022
@colemanw
Copy link
Member Author

FYI @Damilare1

…elements

For buttons in a table, `xs` generally fits the best, so let's make that the default.
@Damilare1
Copy link
Contributor

Apologies @colemanw, I'm just seeing this. Looks like you've made the changes for relationship types. The Civigrant pages are already set to btn-xs.

@@ -108,7 +108,7 @@
'editable' => TRUE,
],
[
'size' => 'btn-sm',
'size' => 'btn-xs',
Copy link
Contributor

Choose a reason for hiding this comment

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

This doesn't seem to work on the test site as the contact type buttons still have the btn-sm class.

Copy link
Member Author

Choose a reason for hiding this comment

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

Seems to be some kind of caching issue on the demo site. Not sure what the problem is but I can't reproduce locally.

@@ -54,7 +54,7 @@
label: ts('Buttons'),
icon: 'fa-square-o',
defaults: {
size: 'btn-sm',
size: 'btn-xs',
Copy link
Contributor

Choose a reason for hiding this comment

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

I understand this would set the default button size when adding button to "Tiny" instead of "Small" in the searchkit table. Is this correct?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes that's right.

@colemanw colemanw merged commit f6f9ae3 into civicrm:master Oct 17, 2022
@colemanw colemanw deleted the btn-xs branch October 17, 2022 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants