mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-11-18 07:38:45 +00:00
correctly destructure props
This commit is contained in:
@@ -34,8 +34,8 @@ const MetadataEditor = ({
|
|||||||
|
|
||||||
onChange = ()=>{},
|
onChange = ()=>{},
|
||||||
reportError = ()=>{},
|
reportError = ()=>{},
|
||||||
|
...props
|
||||||
}, ...props)=>{
|
})=>{
|
||||||
const [isOwner, setIsOwner] = useState(global.account?.username && global.account?.username === metadata?.authors[0]);
|
const [isOwner, setIsOwner] = useState(global.account?.username && global.account?.username === metadata?.authors[0]);
|
||||||
const [showThumbnail, setShowThumbnail] = useState(true);
|
const [showThumbnail, setShowThumbnail] = useState(true);
|
||||||
|
|
||||||
@@ -225,6 +225,7 @@ const MetadataEditor = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
const currentRenderer = metadata.renderer;
|
const currentRenderer = metadata.renderer;
|
||||||
|
console.log(props);
|
||||||
const currentThemeDisplay = props.themeBundle?.name ? `${props.themeBundle.author ?? currentRenderer} : ${props.themeBundle.name}` : 'No Theme Selected';
|
const currentThemeDisplay = props.themeBundle?.name ? `${props.themeBundle.author ?? currentRenderer} : ${props.themeBundle.name}` : 'No Theme Selected';
|
||||||
let dropdown;
|
let dropdown;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user