Skip to content

Commit

Permalink
Append/prepend style fixes
Browse files Browse the repository at this point in the history
- fix missing css`` on append class

- fix missing border-radius on append/prepend nodes that was less perceptible because of background color
  • Loading branch information
cee-chen committed Aug 10, 2024
1 parent af5978b commit b4616f1
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 7 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ exports[`EuiFieldPassword props dual dual type also renders append 1`] = `
class="euiFormControlLayout euiFormControlLayout--group emotion-euiFormControlLayout-group"
>
<div
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup"
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup-appendOnly"
style="--euiFormControlLeftIconsCount: 1;"
>
<div
Expand Down Expand Up @@ -131,7 +131,7 @@ exports[`EuiFieldPassword props dual dualToggleProps is rendered 1`] = `
class="euiFormControlLayout euiFormControlLayout--group emotion-euiFormControlLayout-group"
>
<div
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup"
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup-appendOnly"
style="--euiFormControlLeftIconsCount: 1;"
>
<div
Expand Down Expand Up @@ -346,7 +346,7 @@ exports[`EuiFieldPassword props type dual is rendered 1`] = `
class="euiFormControlLayout euiFormControlLayout--group emotion-euiFormControlLayout-group"
>
<div
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup"
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup-appendOnly"
style="--euiFormControlLeftIconsCount: 1;"
>
<div
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ exports[`EuiFormControlLayout props multiple appends are rendered 1`] = `
class="euiFormControlLayout euiFormControlLayout--group emotion-euiFormControlLayout-group"
>
<div
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup"
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup-appendOnly"
/>
<div
class="euiFormControlLayout__append emotion-euiFormControlLayout__side-append"
Expand Down Expand Up @@ -346,7 +346,7 @@ exports[`EuiFormControlLayout props one append node is rendered 1`] = `
class="euiFormControlLayout euiFormControlLayout--group emotion-euiFormControlLayout-group"
>
<div
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup"
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup-appendOnly"
/>
<div
class="euiFormControlLayout__append emotion-euiFormControlLayout__side-append"
Expand All @@ -363,7 +363,7 @@ exports[`EuiFormControlLayout props one append string is rendered 1`] = `
class="euiFormControlLayout euiFormControlLayout--group emotion-euiFormControlLayout-group"
>
<div
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup"
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper-inGroup-appendOnly"
/>
<div
class="euiFormControlLayout__append emotion-euiFormControlLayout__side-append"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export const euiFormControlLayoutStyles = (euiThemeContext: UseEuiTheme) => {
${logicalCSS('border-top-right-radius', 'inherit')}
${logicalCSS('border-bottom-right-radius', 'inherit')}
`,
appendOnly: `
appendOnly: css`
${logicalCSS('border-top-left-radius', 'inherit')}
${logicalCSS('border-bottom-left-radius', 'inherit')}
`,
Expand Down Expand Up @@ -154,6 +154,9 @@ export const euiFormControlLayoutSideNodeStyles = (
}
`,
append: css`
${logicalCSS('border-top-right-radius', 'inherit')}
${logicalCSS('border-bottom-right-radius', 'inherit')}
& > ${buttons}, & > * > ${buttons} {
${logicalCSS('border-top-left-radius', 0)}
${logicalCSS('border-bottom-left-radius', 0)}
Expand All @@ -166,6 +169,9 @@ export const euiFormControlLayoutSideNodeStyles = (
}
`,
prepend: css`
${logicalCSS('border-top-left-radius', 'inherit')}
${logicalCSS('border-bottom-left-radius', 'inherit')}
& > ${buttons}, & > * > ${buttons} {
${logicalCSS('border-top-right-radius', 0)}
${logicalCSS('border-bottom-right-radius', 0)}
Expand Down

0 comments on commit b4616f1

Please sign in to comment.