Skip to content

Commit

Permalink
Fix: quadpoint CSS selectors (#163)
Browse files Browse the repository at this point in the history
  • Loading branch information
pramodsum authored Apr 11, 2018
1 parent e045619 commit f881b6e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/Annotator.scss
Original file line number Diff line number Diff line change
Expand Up @@ -490,15 +490,15 @@
}

// These helper divs allow us to calculate the quad points of an element
.bp-quad-corner-container {
.ba-quad-corner-container {
bottom: 0;
left: 0;
position: absolute;
right: 0;
top: 0;
}

.bp-quad-corner {
.ba-quad-corner {
background: none;
height: 0;
position: absolute;
Expand Down
4 changes: 3 additions & 1 deletion src/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ export const CLASS_ANNOTATION_POINT_MARKER = 'ba-point-annotation-marker';
export const SELECTOR_ANNOTATION_POINT_MARKER = `.${CLASS_ANNOTATION_POINT_MARKER}`;
export const CLASS_ANNOTATION_POINT_BUTTON = 'ba-point-annotation-btn';
export const SELECTOR_ANNOTATION_POINT_BUTTON = `.${CLASS_ANNOTATION_POINT_BUTTON}`;
export const CLASS_HIGHLIGHT_QUAD_CORNER = 'ba-quad-corner-container';
export const CLASS_HIGHLIGHT_QUAD_CORNER_CONTAINER = 'ba-quad-corner-container';
export const SELECTOR_HIGHLIGHT_QUAD_CORNER_CONTAINER = `.${CLASS_HIGHLIGHT_QUAD_CORNER_CONTAINER}`;
export const CLASS_HIGHLIGHT_QUAD_CORNER = 'ba-quad-corner';
export const SELECTOR_HIGHLIGHT_QUAD_CORNER = `.${CLASS_HIGHLIGHT_QUAD_CORNER}`;

// Dialog CSS constants
Expand Down
2 changes: 1 addition & 1 deletion src/doc/docUtil.js
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ export function getBrowserCoordinatesFromLocation(location, annotatedElement) {
*/
export function getQuadPoints(element, pageEl, scale) {
const quadCornerContainerEl = document.createElement('div');
quadCornerContainerEl.classList.add(constants.CLASS_HIGHLIGHT_QUAD_CORNER);
quadCornerContainerEl.classList.add(constants.CLASS_HIGHLIGHT_QUAD_CORNER_CONTAINER);

// Create zero-size elements that can be styled to the 4 corners of
// quadrilateral around element - using 4 divs is faster than using
Expand Down

0 comments on commit f881b6e

Please sign in to comment.