fix(demotools): update DeesDemoWrapper to handle multiple slotted elements in runAfterRender callback
This commit is contained in:
@ -34,11 +34,11 @@ The properties panel has timing issues detecting rendered elements because:
|
||||
## Created DeesDemoWrapper Component
|
||||
- Location: ts_demotools/demotools.ts
|
||||
- Allows wrapping demo elements with post-render functionality
|
||||
- Provides runAfterRender callback that receives the rendered element
|
||||
- Provides runAfterRender callback that receives ALL slotted elements as HTMLCollection
|
||||
- Uses display: contents to not affect layout
|
||||
- Handles timing automatically with 50ms delay after firstUpdated
|
||||
- Supports both sync and async callbacks
|
||||
- Exports available at @design.estate/dees-wcctools/demoTools
|
||||
- Exports available at @design.estate/dees-wcctools/demotools (lowercase)
|
||||
|
||||
# Documentation Update (COMPLETED)
|
||||
|
||||
@ -50,4 +50,13 @@ The properties panel has timing issues detecting rendered elements because:
|
||||
- Best practices and guidelines
|
||||
- API reference
|
||||
- Browser support information
|
||||
- Complete examples for all major features
|
||||
- Complete examples for all major features
|
||||
|
||||
# Enhanced DemoWrapper (COMPLETED)
|
||||
|
||||
## Modified runAfterRender callback:
|
||||
- Now receives HTMLCollection of ALL slotted elements instead of just the first one
|
||||
- Allows access to complete slotted DOM structure
|
||||
- Updated documentation with correct import path (lowercase 'demotools')
|
||||
- Examples show how to work with multiple slotted elements
|
||||
- Maintains backward compatibility by accessing elements via index
|
Reference in New Issue
Block a user