feat(directory): add color to fast navigation
This commit is contained in:
@@ -1 +1 @@
|
|||||||
1.2.16
|
1.2.17
|
||||||
@@ -55,6 +55,7 @@ export default function Dropdown(props) {
|
|||||||
props.onClick(item)
|
props.onClick(item)
|
||||||
toggleDropdown()
|
toggleDropdown()
|
||||||
}}
|
}}
|
||||||
|
style={item.color ? { color: item.color } : {}}
|
||||||
>
|
>
|
||||||
{
|
{
|
||||||
item.icon ? (
|
item.icon ? (
|
||||||
|
|||||||
@@ -110,18 +110,20 @@
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
padding: 0.5rem;
|
padding: 0.5rem;
|
||||||
font-size: 1rem;
|
font-size: 1rem;
|
||||||
transition: color cubic-bezier(0.65, 0.05, 0.36, 1) 0.3s;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
justify-content: space-between;
|
||||||
justify-content: flex-start;
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
flex-wrap: nowrap;
|
|
||||||
|
.text {
|
||||||
|
flex: 1;
|
||||||
|
transition: color cubic-bezier(0.65, 0.05, 0.36, 1) 0.3s;
|
||||||
|
margin-left: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
.item_icon {
|
.item_icon {
|
||||||
height: inherit;
|
|
||||||
width: 1rem;
|
width: 1rem;
|
||||||
fill: var(--text-color);
|
fill: var(--text-color);
|
||||||
margin-right: 0.5rem;
|
transition: fill cubic-bezier(0.65, 0.05, 0.36, 1) 0.3s;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover,
|
&:hover,
|
||||||
@@ -130,6 +132,9 @@
|
|||||||
.text {
|
.text {
|
||||||
color: currentColor;
|
color: currentColor;
|
||||||
}
|
}
|
||||||
|
.item_icon {
|
||||||
|
fill: currentColor;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -81,7 +81,8 @@ export default function Home() {
|
|||||||
dict[item.date].push({
|
dict[item.date].push({
|
||||||
codename: item.codename,
|
codename: item.codename,
|
||||||
link: item.link,
|
link: item.link,
|
||||||
type: item.type
|
type: item.type,
|
||||||
|
color: item.color
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
return dict
|
return dict
|
||||||
@@ -102,6 +103,7 @@ export default function Home() {
|
|||||||
name: item.codename[language],
|
name: item.codename[language],
|
||||||
value: item.link,
|
value: item.link,
|
||||||
type: "item",
|
type: "item",
|
||||||
|
color: item.color,
|
||||||
icon: <CharIcon
|
icon: <CharIcon
|
||||||
type={item.type}
|
type={item.type}
|
||||||
viewBox={
|
viewBox={
|
||||||
|
|||||||
Reference in New Issue
Block a user