 			if @isScope
 				@item.document.hide()
 			@item.parent = null
+		@item.visible = false
 
 		for child in @children
 			child.revert()

					log.warn "Style file `#{id}` can't be find"
				return
		else
			parent = @parent
			while parent and not scope = parent.scope
				parent = parent.parent

			scope ?= windowStyle
			@item = scope.ids[id] or scope.mainItem.$?[id]
			@item ?= scope.styles(id)

			unless @item
				unless File.Input.test id

		if 'text' of @item or (@item.$ isnt null and 'text' of @item.$)
			@updateText()

		@item.visible = @visible
		@updateVisibility()
		
		for name of @attrs
