 			return
 
 		{node} = @
-		hasStyledChild = @children.length or node.query('[neft:style]')
-
-		if not hasStyledChild and (anchor = node.query('> a'))
-			node = anchor
-			href = node.getAttr('href')
-			if typeof href is 'string'
-				unless @isLinkUriSet
-					@isLinkUriSet = true
-					@baseLinkUri = @item.linkUri
-				@item.linkUri = href
-
+		isText = node instanceof Text
+
+		# linkUri
+		anchor = node
+		while anchor = anchor.parent
+			if anchor.style
+				break
+			if anchor.name is 'a'
+				href = anchor.getAttr('href')
+				if typeof href is 'string'
+					unless @isLinkUriSet
+						@isLinkUriSet = true
+						@baseLinkUri = @item.linkUri
+					@item.linkUri = href
+				break
+
+		# text
 		obj = @getTextObject()
-		if obj and not hasStyledChild
-			text = node.stringifyChildren()
-
-			if text.length > 0 or @isTextSet
-				@isTextSet = true
-				obj.text = text
+		if obj
+			# break if already has a parent with text
+			hasParentWithText = false
+			parent = node
+			while parent = parent.parent
+				if parent._documentStyle?.isTextSet
+					hasParentWithText = true
+					break
+
+			if hasParentWithText
+				if isText
+					@item.visible = false
+			else
+				if isText
+					text = node.text
+					@item.visible = text.length > 0
+				else
+					text = node.stringifyChildren()
+
+				if text.length > 0 or @isTextSet
+					@isTextSet = true
+					obj.text = text
 		return
 
 	getVisibility: ->

			for elem in queries
				nodes = file.node.queryAll elem.query
				for node in nodes
					unless node.hasAttr('neft:style')
						node.setAttr 'neft:style', elem.style


		{item} = @
		unless item
			return
		if @node instanceof Text
			item
		else if item._$ and 'text' of item._$
			item._$
		else if 'text' of item
			item
