-
Notifications
You must be signed in to change notification settings - Fork 92
Try adding simple search + file button styles #235
Conversation
@@ -25,7 +25,7 @@ function twentytwentytwo_support() { | |||
add_theme_support( 'wp-block-styles' ); | |||
|
|||
// Enqueue editor styles. | |||
add_editor_style( get_template_directory_uri() . '/style.css' ); | |||
add_editor_style( 'style.css' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This undoes the commit here: #220 (comment)
In my testing, this prevented the stylesheet from loading in the editor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't recreate this but I'm fine with the change, based on the docs for this function.
text-decoration-thickness: 1px; | ||
text-underline-offset: 0.25ch; | ||
text-decoration-thickness: 1px; | ||
text-underline-offset: 0.25ch; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changing spaces to tabs. 😉
border: none; | ||
color: var(--wp--preset--color--background); | ||
font-size: var(--wp--preset--typography--font-size--normal); | ||
padding: calc(.667em + 2px) calc(1.333em + 2px); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could leave this padding line out to keep this even more minimal — it makes this mirror the normal button padding, but I'm a little indifferent about it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think let's keep it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor comments but LGTM.
@@ -25,7 +25,7 @@ function twentytwentytwo_support() { | |||
add_theme_support( 'wp-block-styles' ); | |||
|
|||
// Enqueue editor styles. | |||
add_editor_style( get_template_directory_uri() . '/style.css' ); | |||
add_editor_style( 'style.css' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't recreate this but I'm fine with the change, based on the docs for this function.
border: none; | ||
color: var(--wp--preset--color--background); | ||
font-size: var(--wp--preset--typography--font-size--normal); | ||
padding: calc(.667em + 2px) calc(1.333em + 2px); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think let's keep it.
background-color: var(--wp--preset--color--primary); | ||
border-radius: 0; | ||
border: none; | ||
color: var(--wp--preset--color--background); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you think about adding this line:
color: var(--wp--preset--color--background); | |
color: var(--wp--preset--color--background); | |
cursor: pointer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I recall there being a major discussion around this cursor behavior at some point in Core. I think we should leave it to be the default behavior for right now — if that gets changed it should happen in Gutenberg.
Co-authored-by: Jeff Ong <[email protected]>
Alternate to #202.
This takes a purely CSS approach to styling the file and search block buttons.
Something like this is required until the following Gutenberg issues are resolved:
Test data:
https://gist.github.com/jffng/263436360988105ab73c35effd494fe0