@@ -1311,7 +1311,7 @@ public static function indexHtml(
13111311 bool $ includeContainer ,
13121312 bool $ selectable ,
13131313 bool $ sortable ,
1314- ): string {
1314+ ): string | Stringable {
13151315 $ request = Craft::$ app ->getRequest ();
13161316 $ static = $ viewState ['static ' ] ?? false ;
13171317 $ variables = [
@@ -3640,7 +3640,7 @@ protected function uiLabel(): ?string
36403640 /**
36413641 * {@inheritdoc}
36423642 */
3643- public function getChipLabelHtml (): string
3643+ public function getChipLabelHtml (): string | Stringable
36443644 {
36453645 return Html::encode ($ this ->getUiLabel ());
36463646 }
@@ -3878,7 +3878,7 @@ public function getPostEditUrl(): ?string
38783878 /**
38793879 * {@inheritdoc}
38803880 */
3881- public function getAdditionalButtons (): string
3881+ public function getAdditionalButtons (): string | Stringable
38823882 {
38833883 // Fire a 'defineAdditionalButtons' event
38843884 if ($ this ->hasEventHandlers (self ::EVENT_DEFINE_ADDITIONAL_BUTTONS )) {
@@ -5780,7 +5780,7 @@ public function getAttributeHtml(string $attribute): string|Stringable
57805780 /**
57815781 * {@inheritdoc}
57825782 */
5783- public function getInlineAttributeInputHtml (string $ attribute ): string
5783+ public function getInlineAttributeInputHtml (string $ attribute ): string | Stringable
57845784 {
57855785 // Fire a 'defineInlineAttributeInputHtml' event
57865786 if ($ this ->hasEventHandlers (self ::EVENT_DEFINE_INLINE_ATTRIBUTE_INPUT_HTML )) {
@@ -5996,7 +5996,7 @@ protected function attributeHtml(string $attribute): string|Stringable
59965996 }
59975997 }
59985998
5999- private function contentBlockAttributeHtml (string $ attribute ): string
5999+ private function contentBlockAttributeHtml (string $ attribute ): string | Stringable
60006000 {
60016001 $ parts = explode ('. ' , $ attribute );
60026002 $ uid = Str::after (array_shift ($ parts ), 'contentBlock: ' );
@@ -6021,7 +6021,7 @@ private function contentBlockAttributeHtml(string $attribute): string
60216021 return $ block ->getAttributeHtml (implode ('. ' , $ parts ));
60226022 }
60236023
6024- private function generatedFieldAttributeHtml (string $ attribute ): string
6024+ private function generatedFieldAttributeHtml (string $ attribute ): string | Stringable
60256025 {
60266026 $ uid = Str::after ($ attribute , 'generatedField: ' );
60276027
@@ -6076,7 +6076,7 @@ private function _getFieldFromAlternativeLayouts($layoutElementUid): ?FieldInter
60766076 * @see getInlineAttributeInputHtml()
60776077 * @since 5.0.0
60786078 */
6079- protected function inlineAttributeInputHtml (string $ attribute ): string
6079+ protected function inlineAttributeInputHtml (string $ attribute ): string | Stringable
60806080 {
60816081 // Is this a custom field?
60826082 $ field = null ;
@@ -6123,7 +6123,7 @@ protected function inlineAttributeInputHtml(string $attribute): string
61236123 /**
61246124 * {@inheritdoc}
61256125 */
6126- public function getSidebarHtml (bool $ static ): string
6126+ public function getSidebarHtml (bool $ static ): string | Stringable
61276127 {
61286128 $ components = [];
61296129
@@ -6162,7 +6162,7 @@ public function getSidebarHtml(bool $static): string
61626162 *
61636163 * @since 3.7.0
61646164 */
6165- protected function metaFieldsHtml (bool $ static ): string
6165+ protected function metaFieldsHtml (bool $ static ): string | Stringable
61666166 {
61676167 // Fire a 'defineMetaFieldsHtml' event
61686168 if ($ this ->hasEventHandlers (self ::EVENT_DEFINE_META_FIELDS_HTML )) {
@@ -6182,7 +6182,7 @@ protected function metaFieldsHtml(bool $static): string
61826182 *
61836183 * @since 3.7.0
61846184 */
6185- protected function slugFieldHtml (bool $ static ): string
6185+ protected function slugFieldHtml (bool $ static ): string | Stringable
61866186 {
61876187 $ slug = isset ($ this ->slug ) && ! ElementHelper::isTempSlug ($ this ->slug ) ? $ this ->slug : null ;
61886188
@@ -6219,7 +6219,7 @@ protected function showStatusField(): bool
62196219 *
62206220 * @since 4.0.0
62216221 */
6222- protected function statusFieldHtml (): string
6222+ protected function statusFieldHtml (): string | Stringable
62236223 {
62246224 $ supportedSites = ElementHelper::supportedSitesForElement ($ this , true );
62256225 $ allEditableSiteIds = Sites::getEditableSiteIds ()->all ();
@@ -6273,7 +6273,7 @@ protected function statusFieldHtml(): string
62736273 *
62746274 * @since 4.0.0
62756275 */
6276- protected function notesFieldHtml (): string
6276+ protected function notesFieldHtml (): string | Stringable
62776277 {
62786278 // todo: this should accept a $static arg
62796279 return Cp::textareaFieldHtml ([
0 commit comments