Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "patch",
"comment": "fix: Arrow was 1px offset and incorrect box-sizing",
"packageName": "@fluentui/react-teaching-popover",
"email": "edwardwang.94@gmail.com",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,32 +7,34 @@ export const teachingPopoverBodyClassNames: SlotClassNames<TeachingPopoverBodySl
media: 'fui-TeachingPopoverBody__media',
};

const popoverBodyDimension = 288;

export const useMediaStyles = makeStyles({
base: {
...shorthands.gridArea('media'),
...shorthands.overflow('hidden'),
width: '288px',
width: `${popoverBodyDimension}px`,
marginBottom: '12px',
verticalAlign: 'middle',
justifyContent: 'center',
display: 'flex',
},
short: {
aspectRatio: 288 / 117,
aspectRatio: popoverBodyDimension / 117,
'@supports not (aspect-ratio)': {
height: '117px',
},
},
medium: {
aspectRatio: 288 / 176,
aspectRatio: popoverBodyDimension / 176,
'@supports not (aspect-ratio)': {
height: '176px',
},
},
tall: {
aspectRatio: 288 / 288,
aspectRatio: popoverBodyDimension / popoverBodyDimension,
'@supports not (aspect-ratio)': {
height: '288px',
height: `${popoverBodyDimension}px`,
},
},
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,8 @@ const useStyles = makeStyles({
root: {
...shorthands.padding(tokens.spacingVerticalL, tokens.spacingVerticalL),
...shorthands.borderRadius(tokens.borderRadiusXLarge),
...shorthands.borderWidth('0px'),
width: '320px',
boxSizing: 'border-box',
width: '288px',
boxSizing: 'content-box',
},
});

Expand Down