-
-
Notifications
You must be signed in to change notification settings - Fork 7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug Report] Failed to resolve directive: ripple #12224
Comments
The same issue. It comes from v-simple-checkbox, adding |
workaround: // main.js
import Ripple from 'vuetify/lib/directives/ripple';
Vue.use(Vuetify, {
directives: {
Ripple,
},
}); |
Potentially related: I had the same error, but it wasn't on a v-data-table. It happened because I was trying to use it in a functional component |
jacekkarczmarczyk workaround on main.js didn't work for me, |
This comment has been minimized.
This comment has been minimized.
I created a derivative of v-data-table which makes use of "vuedraggable" (SortableJS). If I use v-checkbox instead, I don't have that issue (but then styling is utterly broken). |
I'm also getting the ripple warning when using Setting Will this be fixed? |
|
I used for Vuetify 2.4.5: |
thank you so much, works just fine! |
fix(VSimpleCheckbox) vuetifyjs#12224
Is this still occurring as of v2.6? |
Yes, it's still here, just checked with v2.6.1 |
Can you provide me with your reproduction steps? |
sorry for the late reply, was busy and it's not too easy to reproduce outside of a real project |
vuejs/vue#12590 allows this to work with vue 2.7+ |
Had the same problem but adding the :ripple="false" to the simple checkbox fixed it...Super weird |
I'm having this issue with VTreeviewItem in a VTreeview, is there a workaround ? "nuxt": "^3.12.4",
"vue": "latest",
"vuetify-nuxt-module": "^0.16.1" export default defineNuxtConfig({
modules: [
'vuetify-nuxt-module',
],
} (Had to explicitly import it as it seems support is recent for vue3) import { VTreeview } from 'vuetify/labs/VTreeview';
export default {
components: { VTreeview },
} EDIT: fixed it with this import { createVuetify } from 'vuetify'
// import * as components from 'vuetify/components'
// import * as directives from 'vuetify/directives'
import { Ripple } from 'vuetify/directives';
import { VTreeview } from 'vuetify/labs/VTreeview'
const vuetify = createVuetify({
// directives,
// components: {
// ...components,
// VTreeview
// },
components: {
VTreeview,
},
directives: {
Ripple,
},
});
export default defineNuxtPlugin((nuxtApp) => {
nuxtApp.vueApp.use(vuetify)
}) |
@yuwu9145 #12224 (comment) can you look into this since you've been in treeview lately? |
TreeviewItem is just a ListItem, you may have two copies of vue loaded somehow. |
for now i've proceeded to make my own treeview with a custom recursive component, but i'll keep updated here so i can check back when vuetify treeview reaches stable status. Related to #19907 In case that helps someone else: <template>
<div class="tree">
<div
v-for="node in nodes"
:key="node.path"
class="group"
>
<div class="item" @click="select(node)" :class="{ selected: navigation.split(':')[1] === node.path }">
<div :style="{ width: 10 + level * 10 + 'px' }"></div>
<div class="prepend" @click.stop="open(node)">
<v-icon color="secondary" v-if="node.opened">
mdi-folder-open
</v-icon>
<v-icon color="secondary" v-else-if="!node.nodes">
mdi-folder-open
</v-icon>
<v-icon color="secondary" v-else>
mdi-folder
</v-icon>
</div>
<div class="label">
{{ node.label }}
</div>
<div class="append">
0
</div>
</div>
<div v-if="node.nodes && node.opened">
<treeview
:nodes="node.nodes"
:level="level + 1"
:navigation='navigation'
@list="$emit('list', $event)"
/>
</div>
</div>
</div>
</template>
<script>
export default {
props: ['nodes', 'level', 'navigation'],
methods: {
open(node) {
if (node.nodes) {
node.opened = !node.opened
} else {
this.select(node)
}
},
select(node) {
this.$emit('list', node.path)
}
},
}
</script> |
Environment
Vuetify Version: 2.3.10
Vue Version: 2.6.12
Browsers: Chrome 85.0.4183.102
OS: Mac OS 10.15.6
Steps to reproduce
Expected Behavior
No errors should be displayed
Actual Behavior
Vue displays a warning:
vue.runtime.esm.js?2b0e:619 [Vue warn]: Failed to resolve directive: ripple
Reproduction Link
https://gist.github.com/canassa/0688187cc157bd20d4a8c967c1157479
The text was updated successfully, but these errors were encountered: