Various small changes
This commit is contained in:
parent
a44eea520a
commit
d9096b13e4
2 changed files with 6 additions and 4 deletions
|
|
@ -10,7 +10,7 @@ import { makeStyles } from "@material-ui/core/styles";
|
||||||
import Tooltip from "@material-ui/core/Tooltip";
|
import Tooltip from "@material-ui/core/Tooltip";
|
||||||
import IconButton from "@material-ui/core/IconButton";
|
import IconButton from "@material-ui/core/IconButton";
|
||||||
import ReactIcon from "@mdi/react";
|
import ReactIcon from "@mdi/react";
|
||||||
import { mdiMap, mdiGithub } from "@mdi/js";
|
import { mdiMap, mdiGithub, mdiMagnify } from "@mdi/js";
|
||||||
|
|
||||||
export type TopBarProps = {
|
export type TopBarProps = {
|
||||||
connected: boolean,
|
connected: boolean,
|
||||||
|
|
@ -77,7 +77,9 @@ const Search = (props: SearchBarProps) => {
|
||||||
const classes = useSearchStyles();
|
const classes = useSearchStyles();
|
||||||
return (
|
return (
|
||||||
<div className={classes.search}>
|
<div className={classes.search}>
|
||||||
<i className={`mdi mdi-magnify ${classes.searchIcon}`}></i>
|
<span className={classes.searchIcon}>
|
||||||
|
<ReactIcon path={mdiMagnify} size={1} />
|
||||||
|
</span>
|
||||||
<InputBase placeholder="Search…" type="search"
|
<InputBase placeholder="Search…" type="search"
|
||||||
onChange={(e) => props.onSearch(e.target.value)}
|
onChange={(e) => props.onSearch(e.target.value)}
|
||||||
classes={{
|
classes={{
|
||||||
|
|
|
||||||
|
|
@ -34,12 +34,12 @@ const iconChainUtils = <T> (cb: (x: T, p?: IconPropHelper) => Icon,
|
||||||
);
|
);
|
||||||
|
|
||||||
export const svg = (data: string, props?: IconPropHelper): Icon => {
|
export const svg = (data: string, props?: IconPropHelper): Icon => {
|
||||||
const propColor = ((c: Color | (State) => Color) => (state: State) => {
|
const propColor = ((c: ?Color | (State) => Color) => (state: State) => {
|
||||||
if (typeof c === "function") {
|
if (typeof c === "function") {
|
||||||
return c(state);
|
return c(state);
|
||||||
}
|
}
|
||||||
return c;
|
return c;
|
||||||
})(props?.color ?? "black");
|
})(props?.color);
|
||||||
return {
|
return {
|
||||||
render: (state) => (
|
render: (state) => (
|
||||||
<ReactIcon path={data} size={props?.size ?? 1.5}
|
<ReactIcon path={data} size={props?.size ?? 1.5}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue