improve missing block/shadow warning

This commit is contained in:
Loren Norman 2025-07-24 12:49:12 -04:00
parent 25ec0db569
commit 8adf43ed7b

View file

@ -123,9 +123,17 @@ class BlockDefinition {
}
const
definitionPropsToInputs = ({ inputValue, block, shadow }) => {
definitionPropsToInputs = input => {
const { block, shadow, type } = input
// bail unless this is a statement or value input
// (undefined implies value, for now)
if(![undefined, 'statement', 'value'].includes(type)) {
return
}
if(!block && !shadow) {
console.warn("Warning: no block or shadow specified for", inputValue)
console.warn("Warning: no block or shadow specified for input:", input)
return
}