From f96222db8da16aa7c3a32455a4e7c20a57550ca6 Mon Sep 17 00:00:00 2001 From: Luckas Date: Sat, 3 Aug 2024 06:38:31 +0300 Subject: [PATCH] feat(vue): add `v-bind:class` support --- queries/vue/class.scm | 8 ++++++++ tests/queries/vue/test.vue | 2 +- tests/queries/vue_spec.lua | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/queries/vue/class.scm b/queries/vue/class.scm index 1f2129c..0a09163 100644 --- a/queries/vue/class.scm +++ b/queries/vue/class.scm @@ -1 +1,9 @@ ; inherits: html + +(directive_attribute + (directive_name) @directive.name + (#eq? @directive.name "v-bind") + (directive_value) @directive.value + (#eq? @directive.value "class") + (quoted_attribute_value + (attribute_value) @tailwind)) diff --git a/tests/queries/vue/test.vue b/tests/queries/vue/test.vue index ee30a4b..0c92665 100644 --- a/tests/queries/vue/test.vue +++ b/tests/queries/vue/test.vue @@ -1,5 +1,5 @@