mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-22 09:37:17 +00:00
22 lines
524 B
TypeScript
22 lines
524 B
TypeScript
import React from "react";
|
|
import { connect } from "react-redux";
|
|
|
|
import CharacterString from "../CharacterString";
|
|
import { AppState } from "../../types";
|
|
import * as Selectors from "../../selectors";
|
|
|
|
interface StateProps {
|
|
khz: string | null;
|
|
}
|
|
|
|
const Khz = (props: StateProps) => (
|
|
<div id="khz">
|
|
<CharacterString>{props.khz || ""}</CharacterString>
|
|
</div>
|
|
);
|
|
|
|
function mapStateToProps(state: AppState): StateProps {
|
|
return { khz: Selectors.getKhz(state) };
|
|
}
|
|
|
|
export default connect(mapStateToProps)(Khz);
|