Skip to content

grabAttributeFrom returns just a part of element attribute #5371

@dalibormusil-ui

Description

@dalibormusil-ui

I'm trying to return and assert the element style, which looks like that:
<div class="carousel-slides" style="transform: translateX(-200%);">
... but the call
styleBefore = await I.grabAttributeFrom(selectors.index.homeSection.carouselSlides, 'style');
... finishes with value 'transform' and everything behind, including ":", is not returned, exactly the call of
console.log('LOG: styleBefore:', styleBefore );
... produces this:
> LOG: styleBefore: { '0': 'transform' }
... so I cannot get to the value and am practically unable to scan what picture is displayed on the carousel.

As I control the codebase, I added an attribute slide="" for testability, which reflects the slide number... and this works well, but complicated values with ":" or space make a problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions