Skip to content

Commit

Permalink
Merge branch 'main' into focus-on-first-item-in-MH-dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
staxly[bot] authored Mar 5, 2025
2 parents 56efbb1 + 84f9d09 commit 7e25453
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 18 deletions.
5 changes: 2 additions & 3 deletions src/app/content/highlights/components/Confirmation.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,14 @@ export const Overlay = styled.div`
outline: none;
${cardBorder}
transition: background 200ms;
position: absolute;
display: flex;
flex-direction: column;
padding: 1.6rem;
top: 0;
left: 0;
overflow: visible;
min-height: 100%;
min-width: 100%;
position: static;
width: min-content;
label {
${labelStyle}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ exports[`Card matches snapshot when focused without note 1`] = `
padding: 0.8rem;
border-radius: 0.4rem;
box-shadow: 0 0 2px 0 rgba(0,0,0,0.14),0 2px 2px 0 rgba(0,0,0,0.12),0 1px 3px 0 rgba(0,0,0,0.2);
left: calc(100% - ((100% - 82.5rem) / 2) + 3rem);
right: unset;
left: unset;
right: 0;
top: 150px;
left: calc(100% - ((100% - 82.5rem) / 2) + 1rem);
left: calc(50% + (82.5rem / 2) + 1rem);
right: unset;
-webkit-transition: opacity 0.3s,top 0.3s,left 0.3s;
transition: opacity 0.3s,top 0.3s,left 0.3s;
}
Expand Down Expand Up @@ -128,10 +129,11 @@ exports[`Card matches snapshot when passed data without note 1`] = `
padding: 0.8rem;
border-radius: 0.4rem;
box-shadow: 0 0 2px 0 rgba(0,0,0,0.14),0 2px 2px 0 rgba(0,0,0,0.12),0 1px 3px 0 rgba(0,0,0,0.2);
left: calc(100% - ((100% - 82.5rem) / 2) + 3rem);
right: unset;
left: unset;
right: 0;
top: undefinedpx;
left: calc(100% - ((100% - 82.5rem) / 2) + 1rem);
left: calc(50% + (82.5rem / 2) + 1rem);
right: unset;
-webkit-transition: opacity 0.3s,top 0.3s,left 0.3s;
transition: opacity 0.3s,top 0.3s,left 0.3s;
}
Expand Down Expand Up @@ -221,10 +223,11 @@ exports[`Card matches snapshot without data 1`] = `
padding: 0.8rem;
border-radius: 0.4rem;
box-shadow: 0 0 2px 0 rgba(0,0,0,0.14),0 2px 2px 0 rgba(0,0,0,0.12),0 1px 3px 0 rgba(0,0,0,0.2);
left: calc(100% - ((100% - 82.5rem) / 2) + 3rem);
right: unset;
left: unset;
right: 0;
top: 200px;
left: calc(100% - ((100% - 82.5rem) / 2) + 1rem);
left: calc(50% + (82.5rem / 2) + 1rem);
right: unset;
-webkit-transition: opacity 0.3s,top 0.3s,left 0.3s;
transition: opacity 0.3s,top 0.3s,left 0.3s;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ exports[`Confirmation matches snapshot no selection 1`] = `
box-shadow: 0 0 2px 0 rgba(0,0,0,0.14),0 2px 2px 0 rgba(0,0,0,0.12),0 1px 3px 0 rgba(0,0,0,0.2);
-webkit-transition: background 200ms;
transition: background 200ms;
position: absolute;
display: -webkit-box;
display: -webkit-flex;
display: -ms-flexbox;
Expand All @@ -105,11 +104,13 @@ exports[`Confirmation matches snapshot no selection 1`] = `
-ms-flex-direction: column;
flex-direction: column;
padding: 1.6rem;
top: 0;
left: 0;
overflow: visible;
min-height: 100%;
min-width: 100%;
position: static;
width: -webkit-min-content;
width: -moz-min-content;
width: min-content;
}
.c0 label {
Expand Down
7 changes: 4 additions & 3 deletions src/app/content/highlights/components/cardStyles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,12 @@ const overlapDisplay = css`
`;

const rightSideDisplay = css`
left: calc(100% - ((100% - ${contentTextWidth}rem) / 2) + ${cardContentMargin}rem);
right: unset;
left: unset;
right: 0;
top: ${(props: CardProps) => `${props.topOffset || getHighlightBottomOffset(props.container, props.highlight)}px;`}
${(props: CardProps) => !!props.isActive && css`
left: calc(100% - ((100% - ${contentTextWidth}rem) / 2) + ${cardFocusedContentMargin}rem);
left: calc(50% + (${contentTextWidth}rem / 2) + ${cardFocusedContentMargin}rem);
right: unset;
`}
`;

Expand Down

0 comments on commit 7e25453

Please sign in to comment.