Skip to content

Commit 49396f0

Browse files
Add get_presentation and get_image to Feature interface
Add the new getter methods to the Feature contract so PHPStan recognizes them when iterating features from the registry.
1 parent 158bf85 commit 49396f0

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

includes/Contracts/Feature.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,4 +106,22 @@ public function is_enabled(): bool;
106106
* }> Array of field definitions with full option names.
107107
*/
108108
public function get_settings_fields_metadata(): array;
109+
110+
/**
111+
* Gets the presentation style for the settings UI.
112+
*
113+
* @since x.x.x
114+
*
115+
* @return string The presentation style ('toggle' or 'visual-card').
116+
*/
117+
public function get_presentation(): string;
118+
119+
/**
120+
* Gets the image URL for visual-card presentation.
121+
*
122+
* @since x.x.x
123+
*
124+
* @return string The image URL, or empty string if not set.
125+
*/
126+
public function get_image(): string;
109127
}

0 commit comments

Comments
 (0)