vuetify 提示中的 HTML

And*_*rew 2 vuetify.js

以前(我想?)可以将 HTML 放入 vuetify 提示中,但对我来说这不再有效。例如,在我的一个组件中,我有:

<v-checkbox
   v-model="create"
   label="Nice label"
   persistent-hint
   hint="<span class=&quot;red--text&quot;>Red hint</span>"
/>
Run Code Online (Sandbox Code Playgroud)

这个提示过去显示为红色,但现在我看到了完整的 HTML 代码。有什么改变还是我做错了什么?

And*_*rew 5

在 Vuetify 论坛中,MajesticPotatoe 向我指出了错误报告https://github.com/vuetifyjs/vuetify/issues/9647。这提供了以下插槽解决方法,适用于我的代码:

<v-checkbox
   v-model="create"
   label="Nice label"
   persistent-hint
   hint="<span class=&quot;red--text&quot;>Red hint</span>"
>
<template v-slot:message="{ message, key }">
 <span v-html="message"></span>
</template>
</v-checkbox>
Run Code Online (Sandbox Code Playgroud)

似乎在补丁https://github.com/haggys22/vuetify/commit/f0d5edd7ddf7e01ba057b7f3d14604199b6db68d被合并之前,这曾经在没有插槽的情况下工作。