Skip to content

Popover on the EuiTour component doesn't respect the anchorPosition prop #5731

Closed

Description

@cauemarcondes

On APM I'm adding the EuiTour component on a new feature we implemented, service groups. One of the steps is to show the tour component on a EuiCard which is rendered inside an EuiFlexGrop. I'd like to position the popover on the leftside up of the card, but it automatically changes the popover to the top of the card, as it wouldn't have enough space to render on the side, but it has.

Screen.Recording.2022-03-17.at.4.26.49.PM.mov

I try adding a button to show the tour after the card was rendered but still got the same problem.

Screen.Recording.2022-03-17.at.4.41.24.PM.mov
<EuiTourStep
        content={
          <>
            <EuiText size="s" color="subdued">
              {i18n.translate(
                'xpack.apm.serviceGroups.tour.serviceGroups.content',
                {
                  defaultMessage:
                    "Now that you've created a service group, your All services inventory has moved here. This group cannot be edited or removed.",
                }
              )}
            </EuiText>
            <EuiSpacer />
            <EuiText size="s" color="subdued">
              {i18n.translate(
                'xpack.apm.serviceGroups.tour.createGroups.content.link',
                { defaultMessage: 'Learn more in our documentation' }
              )}
            </EuiText>
          </>
        }
        isStepOpen={isOpen}
        onFinish={() => setIsOpen(false)}
        maxWidth={300}
        minWidth={300}
        step={1}
        stepsTotal={1}
        title={i18n.translate(
          'xpack.apm.serviceGroups.tour.serviceGroups.title',
          { defaultMessage: 'All services group' }
        )}
        anchorPosition="leftUp"
        footerAction={<div>Dismiss</div>}
      >
        <div>{Card}</div>
      </EuiTourStep>

Activity

  1. elizabetdev commented on Mar 22, 2022

    @elizabetdev
    Contributor

    Hi @cauemarcondes,

    The following changes might help you to fix the issue you're facing: #5696. It will be part of EUI's next release.

    Let me know if that helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions