public function getSchemaMessage()
    {
        $message = $this->getMessage();
        if (!$message) {
            return null;
        }
        // Form schema messages treat simple strings as plain text, so nest for html messages
        if ($this->getMessageCast() === ValidationResult::CAST_HTML) {
            $message = ['html' => $message];
        }
        return [
            'value' => $message,
            'type' => $this->getMessageType(),
        ];
    }