mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 15:42:44 +00:00 
			
		
		
		
	LibWeb: Introduce the slottable concept for DOM elements and text nodes
A slottable is either a DOM element or a DOM text node. They may be assigned to slots (HTMLSlotElement) either automatically or manually. Automatic assignment occurs by matching a slot's `name` attribute to a slottable's `slot` attribute. Manual assignment occurs by using the slot's (not yet implemented) `assign` API. This commit does not perform the above assignments. It just sets up the slottable concept via IDL and hooks the slottable mixin into the element and text nodes.
This commit is contained in:
		
							parent
							
								
									b85a252753
								
							
						
					
					
						commit
						45b36bd08a
					
				
					 12 changed files with 116 additions and 1 deletions
				
			
		|  | @ -32,6 +32,8 @@ void Text::initialize(JS::Realm& realm) | |||
| void Text::visit_edges(Cell::Visitor& visitor) | ||||
| { | ||||
|     Base::visit_edges(visitor); | ||||
|     SlottableMixin::visit_edges(visitor); | ||||
| 
 | ||||
|     visitor.visit(dynamic_cast<JS::Cell*>(m_owner.ptr())); | ||||
| } | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Timothy Flynn
						Timothy Flynn