| 
									
										
										
										
											2024-11-23 23:06:06 +01:00
										 |  |  | /*
 | 
					
						
							|  |  |  |  * Copyright (c) 2024, Nathan van der Kamp <nbvdkamp@gmail.com> | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * SPDX-License-Identifier: BSD-2-Clause | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #pragma once
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #include <LibGC/Ptr.h>
 | 
					
						
							|  |  |  | #include <LibJS/Heap/Cell.h>
 | 
					
						
							|  |  |  | #include <LibWeb/Forward.h>
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | namespace Web::HTML { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | class PopoverInvokerElement { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | public: | 
					
						
							|  |  |  |     PopoverInvokerElement() { } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-12-28 19:46:14 +09:00
										 |  |  |     GC::Ptr<DOM::Element> popover_target_element() { return m_popover_target_element; } | 
					
						
							| 
									
										
										
										
											2024-11-23 23:06:06 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  |     void set_popover_target_element(GC::Ptr<DOM::Element> value) { m_popover_target_element = value; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-01-14 15:15:38 +11:00
										 |  |  |     static void popover_target_activation_behaviour(GC::Ref<DOM::Node> node, GC::Ref<DOM::Node> event_target); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-11-23 23:06:06 +01:00
										 |  |  | protected: | 
					
						
							| 
									
										
										
										
											2024-12-12 19:53:04 +00:00
										 |  |  |     void visit_edges(JS::Cell::Visitor&); | 
					
						
							|  |  |  |     void associated_attribute_changed(FlyString const& name, Optional<String> const& value, Optional<FlyString> const& namespace_); | 
					
						
							| 
									
										
										
										
											2024-11-23 23:06:06 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | private: | 
					
						
							|  |  |  |     GC::Ptr<DOM::Element> m_popover_target_element; | 
					
						
							| 
									
										
										
										
											2025-01-14 15:15:38 +11:00
										 |  |  | 
 | 
					
						
							|  |  |  |     static GC::Ptr<HTMLElement> get_the_popover_target_element(GC::Ref<DOM::Node> node); | 
					
						
							| 
									
										
										
										
											2024-11-23 23:06:06 +01:00
										 |  |  | }; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | } |