diff options
Diffstat (limited to 'lib/public/Dashboard')
-rw-r--r-- | lib/public/Dashboard/IAPIWidget.php | 4 | ||||
-rw-r--r-- | lib/public/Dashboard/IButtonWidget.php | 2 | ||||
-rw-r--r-- | lib/public/Dashboard/Model/WidgetItem.php | 10 |
3 files changed, 12 insertions, 4 deletions
diff --git a/lib/public/Dashboard/IAPIWidget.php b/lib/public/Dashboard/IAPIWidget.php index 8fec40cf1b1..c8f98290a0e 100644 --- a/lib/public/Dashboard/IAPIWidget.php +++ b/lib/public/Dashboard/IAPIWidget.php @@ -9,6 +9,8 @@ declare(strict_types=1); namespace OCP\Dashboard; +use OCP\Dashboard\Model\WidgetItem; + /** * interface IAPIWidget * @@ -16,7 +18,7 @@ namespace OCP\Dashboard; */ interface IAPIWidget extends IWidget { /** - * @return \OCP\Dashboard\Model\WidgetItem[] The widget items + * @return list<WidgetItem> The widget items * @since 22.0.0 */ public function getItems(string $userId, ?string $since = null, int $limit = 7): array; diff --git a/lib/public/Dashboard/IButtonWidget.php b/lib/public/Dashboard/IButtonWidget.php index fa8d6bc36a6..f4ebd9253c7 100644 --- a/lib/public/Dashboard/IButtonWidget.php +++ b/lib/public/Dashboard/IButtonWidget.php @@ -19,7 +19,7 @@ interface IButtonWidget extends IWidget { * Get the buttons to show on the widget * * @param string $userId - * @return WidgetButton[] + * @return list<WidgetButton> * @since 25.0.0 */ public function getWidgetButtons(string $userId): array; diff --git a/lib/public/Dashboard/Model/WidgetItem.php b/lib/public/Dashboard/Model/WidgetItem.php index be5fba82323..680daf1b114 100644 --- a/lib/public/Dashboard/Model/WidgetItem.php +++ b/lib/public/Dashboard/Model/WidgetItem.php @@ -134,8 +134,14 @@ final class WidgetItem implements JsonSerializable { /** * @since 22.0.0 - * - * @return array + * @return array{ + * subtitle: string, + * title: string, + * link: string, + * iconUrl: string, + * overlayIconUrl: string, + * sinceId: string, + * } */ public function jsonSerialize(): array { return [ |