Skip to content

Clicks and passing arguments are sometimes non operational on component root level #4262

Open
@asvae

Description

@asvae

Vuestic-ui version: 1.9.10

Description

  • For VaCounter when I set data-testid - it's getting set on child input element (.va-input__content__input) instead of root element (.va-counter). This is problematic for automated tests as it makes it hard to select an element.
  • Some elements, like VaSwitch and VaCheckbox if you el.click() on root element - click doesn't trigger.

Actionable

This issue doesn't seem too pressing, but pretty crucial if we want to have unified automated testing. To make it work we would need the following, I believe:

  • For all components check that attributes pass-through to root level element by default (in many cases child components can pick specific attributest for themselves, i.e. for VaCounter - all input props - should go to input).
    • Same for classes and styles
  • For all clickable elements - el.click() should work.

Reproduction

This is repro only for data-testid case.

(https://ui.vuestic.dev/play#eNp9Uctu2zAQ/BWCF9mALR1yM2QDbZBDCzQtmqKXsgeWWjtMxUfJpepC0L93ScWOEwSBIECand2ZnR35O+/rIQHf8DaqoD2yCJj8TljGtPEuIBtZgP2KOfvJJYvQsYntgzOsor5K2MxUzkZkJh7YNpMXVbXMcH7PbYvFkm13bMwgy9x6kH0C6uicSgYs1n8ShH930INCFxbVj06iXCNE1N1W8F/S0iP4z2pZq17GeCsN5GkTibXNbJ+M0w+C8b1EKGu0fncARG0PGyb4OBaf0yR428x7EgGOnkQfKYNcq+I5XHC+y+sZY6+7Yg3x2uZCWVi+4nOGayN9/RCdpZxLAOKxEAXfnCIh4ZSnqnXSGRb8HtHHTdMknW+US3UHQ3OiuYSNkdrSZMFLEMJOpImR7rHXhxeKyhmvewifPWq61zNl2ffu78eCYUiwOuHqHtTvV/CHeJwtfgkQIQwg+LmGMlDec/nm7haO9H0uGtelnthvFL9CdH3KHmfa+2Q7sn3BK24/lADpZN/izRHBxtNS2WhJo/BLqtdvrP5k96q+Oqc4/QfEPQjC)

Metadata

Metadata

Assignees

No one assigned

    Labels

    BUGSomething isn't working

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions