Skip to content

Commit

Permalink
Revert "Remove round corner for search inputs"
Browse files Browse the repository at this point in the history
This reverts commit 84dc6e0.
  • Loading branch information
Charles committed Apr 30, 2024
1 parent 84dc6e0 commit 488658d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 3 additions & 0 deletions packages/core/src/components/forms/_common.scss
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ $control-group-stack: (
box-shadow: input-transition-shadow($input-shadow-color-focus, true), $input-box-shadow-focus;
}

&[type="search"],
&.#{$ns}-round {
border-radius: $pt-input-height;
// override normalize.css
Expand Down Expand Up @@ -151,6 +152,7 @@ $control-group-stack: (
height: $pt-input-height-large;
line-height: $pt-input-height-large;

&[type="search"],
&.#{$ns}-round {
padding: 0 ($input-padding-horizontal * 1.5);
}
Expand All @@ -163,6 +165,7 @@ $control-group-stack: (
padding-left: $input-small-padding;
padding-right: $input-small-padding;

&[type="search"],
&.#{$ns}-round {
padding: 0 ($input-small-padding * 1.5);
}
Expand Down
6 changes: 5 additions & 1 deletion packages/core/src/components/forms/input-group.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ For _multiline text_: use [**TextArea**](#core/components/text-area) instead.

@## Search input

Apply the attribute `type="search"` to enable a handler for the <kbd>esc</kbd> key to clear the text in a search field forå some browsers.
Apply the attribute `type="search"` to style a text input as a search field. This styling is equivalent
to what is applied using the `Classes.ROUND` modifier class&mdash;it is automatically applied for `[type="search"]`
inputs.

Note that some browsers also implement a handler for the <kbd>esc</kbd> key to clear the text in a search field.

@reactExample SearchInputExample

Expand Down

1 comment on commit 488658d

@svc-palantir-github
Copy link

Choose a reason for hiding this comment

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

Revert "Remove round corner for search inputs"

Build artifact links for this commit: documentation | landing | table | demo

This is an automated comment from the deploy-preview CircleCI job.

Please sign in to comment.