src/modules/inactive/commands/aryeh_implementation.js
function isCollapsedBlockProp(node) {
	if (isCollapsedLineBreak(node)
	&& !isExtraneousLineBreak(node)) {
		return true;
	}

	if (!isInlineNode(node)
	|| node.nodeType != Node.ELEMENT_NODE) {
		return false;
	}

	var hasCollapsedBlockPropChild = false;
	for (var i = 0; i < node.childNodes.length; i++) {
		if (!isInvisible(node.childNodes[i])
		&& !isCollapsedBlockProp(node.childNodes[i])) {
			return false;
		}
		if (isCollapsedBlockProp(node.childNodes[i])) {
			hasCollapsedBlockPropChild = true;
		}
	}

	return hasCollapsedBlockPropChild;
}
function isCollapsedBlockProp(node) {
	if (isCollapsedLineBreak(node)
	&& !isExtraneousLineBreak(node)) {
		return true;
	}

	if (!isInlineNode(node)
	|| node.nodeType != Node.ELEMENT_NODE) {
		return false;
	}

	var hasCollapsedBlockPropChild = false;
	for (var i = 0; i < node.childNodes.length; i++) {
		if (!isInvisible(node.childNodes[i])
		&& !isCollapsedBlockProp(node.childNodes[i])) {
			return false;
		}
		if (isCollapsedBlockProp(node.childNodes[i])) {
			hasCollapsedBlockPropChild = true;
		}
	}

	return hasCollapsedBlockPropChild;
}
function isCollapsedBlockProp ( node ) { if ( isCollapsedLineBreak ( node ) && ! isExtraneousLineBreak ( node ) ) { return true ; } if ( ! isInlineNode ( node ) || node . nodeType != Node . ELEMENT_NODE ) { return false ; } var hasCollapsedBlockPropChild = false ; for ( var i = 0 ; i < node . childNodes . length ; i ++ ) { if ( ! isInvisible ( node . childNodes [ i ] ) && ! isCollapsedBlockProp ( node . childNodes [ i ] ) ) { return false ; } if ( isCollapsedBlockProp ( node . childNodes [ i ] ) ) { hasCollapsedBlockPropChild = true ; } } return hasCollapsedBlockPropChild ; }
"A collapsed block prop is either a collapsed line break that is not an extraneous line break, or an Element that is an inline node and whose children are all either invisible or collapsed block props and that has at least one child that is a collapsed block prop."
A collapsed block prop is either a collapsed line break that is not an extraneous line break or an Element that is an inline node and whose children are all either invisible or collapsed block props and that has at least one child that is a collapsed block prop .