Grabbed dndbeyond's source code
``` ~/go/bin/sourcemapper -output ddb -jsurl https://media.dndbeyond.com/character-app/static/js/main.90aa78c5.js ```
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
import * as React from "react";
|
||||
|
||||
import { SvgConstantDarkTheme } from "../SvgConstants";
|
||||
import { InjectedSvgProps } from "./hocTypings";
|
||||
import { getDisplayName } from "./utils";
|
||||
|
||||
export function asDarkSvg<
|
||||
C extends React.ComponentType<React.ComponentProps<C> & InjectedSvgProps>,
|
||||
ResolvedProps = JSX.LibraryManagedAttributes<C, React.ComponentProps<C>>
|
||||
>(WrappedComponent: C) {
|
||||
return class AsDarkSvg extends React.PureComponent<
|
||||
ResolvedProps & InjectedSvgProps
|
||||
> {
|
||||
static displayName = `asDarkSvg(${getDisplayName(WrappedComponent)})`;
|
||||
|
||||
static defaultProps = {
|
||||
fillColor: SvgConstantDarkTheme.fill,
|
||||
secondaryFillColor: SvgConstantDarkTheme.secondaryFill,
|
||||
className: "ddbc-svg--dark",
|
||||
};
|
||||
|
||||
render() {
|
||||
return <WrappedComponent {...(this.props as any)} />;
|
||||
}
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user