Skip to content

onchange gives incorrect pixel values #3

@brmscheiner

Description

@brmscheiner

Reproduction steps:

  1. Set up the DOM as follows:
<div style={{ width: 400 }}>
    <div
            id="bbox-annotator-container"
            style={{ width: '100%', zIndex: 999999 }}
      />
</div>
  1. Create an annotation with the following config
bba.add_entry({
      label: '1',
      percent: {
        left: 10,
        top: 10,
        width: 80,
        height: 80,
      },
      angles: {
        theta: 0,
      },
      highlighted: true,
    });
  1. Add onchange: console.log
  2. Pixel values are incorrect as you translate the annotation; they will become correct after you resize the height

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions