fix style nesting

This commit is contained in:
2022-05-24 20:48:26 -04:00
parent e614518987
commit ff96ccae44
10 changed files with 192 additions and 188 deletions
+1 -1
View File
@@ -9,7 +9,7 @@ const Block = styled("div", {
margin: "1em auto",
color: "$codeText",
[`${Code}`]: {
[`& ${Code}`]: {
display: "block",
overflowX: "auto",
padding: "1em",
+10 -6
View File
@@ -45,12 +45,16 @@ const Menu = ({ ...rest }: MenuProps) => {
return (
<Wrapper {...rest}>
{menuItems.map((item, index) => (
<Item key={index}>
{/* kinda weird/hacky way to determine if the *first part* of the current path matches this href */}
<MenuItem {...item} current={item.href === `/${router.pathname.split("/")[1]}`} />
</Item>
))}
{menuItems.map((item, index) => {
// kinda weird/hacky way to determine if the *first part* of the current path matches this href
const isCurrent = item.href === `/${router.pathname.split("/")[1]}`;
return (
<Item key={index}>
<MenuItem {...item} current={isCurrent} />
</Item>
);
})}
<Item>
<MenuItem icon={ThemeToggle} />
+1 -1
View File
@@ -9,7 +9,7 @@ const Title = styled("h1", {
lineHeight: 1.3,
fontWeight: 700,
code: {
"& code": {
margin: "0 0.075em",
},
+2 -2
View File
@@ -12,10 +12,10 @@ const Display = styled(
maxWidth: "800px",
// these are injected by noVNC after connection, so we can't target them directly:
div: {
"& div": {
background: "none !important",
canvas: {
"& canvas": {
cursor: "inherit !important",
},
},
+1 -1
View File
@@ -13,7 +13,7 @@ const Player = styled(ReactPlayer, {
top: 0,
left: 0,
video: {
"& video": {
borderRadius: "$rounded",
},
});
+1 -1
View File
@@ -14,7 +14,7 @@ const Player = styled(ReactPlayer, {
left: 0,
// target both the lazy thumbnail preview *and* the actual YouTube embed
".react-player__preview, iframe": {
"& .react-player__preview, & iframe": {
borderRadius: "$rounded",
},
});