Skip to content

Commit

Permalink
[EuiPopover] Deprecate initialFocus={false} as an option
Browse files Browse the repository at this point in the history
  • Loading branch information
cee-chen committed Aug 3, 2022
1 parent c6ae0cd commit 2c223c5
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ export function ChangeDataView({
isOpen={isPopoverOpen}
closePopover={() => setPopoverIsOpen(false)}
panelPaddingSize="none"
initialFocus={!isTextBasedLangSelected ? `#${searchListInputId}` : false}
initialFocus={!isTextBasedLangSelected ? `#${searchListInputId}` : undefined}
display="block"
buffer={8}
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ export const SwitchModePopover = ({ onModeChange, useKibanaIndices }: PopoverPro
isOpen={isPopoverOpen}
closePopover={closePopover}
style={{ height: 'auto' }}
initialFocus={false}
>
<div
style={{ width: '360px' }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,6 @@ export function Popover({
isOpen={isOpen}
ref={popoverRef}
style={popoverStyle}
initialFocus={false}
>
<EuiFlexGroup
direction="column"
Expand Down
7 changes: 1 addition & 6 deletions x-pack/plugins/osquery/public/packs/packs_table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,7 @@ export const AgentPoliciesPopover = ({ agentPolicyIds = [] }: { agentPolicyIds?:
}

return (
<EuiPopover
button={button}
isOpen={isPopoverOpen}
closePopover={closePopover}
initialFocus={false}
>
<EuiPopover button={button} isOpen={isPopoverOpen} closePopover={closePopover}>
<EuiText size="s">
{agentPolicyIds?.map((policyId) => (
<div key={policyId}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,6 @@ export const ActionBar = ({
{/* Popover is used instead of EuiTooltip until the resolution of https://github.com/elastic/eui/issues/5604 */}
<EuiPopover
repositionOnScroll={true}
initialFocus={false}
button={
<EuiButton
css={{ width: '100%' }}
Expand Down

0 comments on commit 2c223c5

Please sign in to comment.