Skip to content

the AI crashes or it pops up a window that you cant use it for some kind of promt #5712

@Athena-IO

Description

@Athena-IO

Environment

npx nuxt info

Is this bug related to Nuxt or Vue?

Nuxt

Package

v4.x

Version

v4.0.0

Reproduction

i dont have this

Description

so i ran into a problem when i wanted to ask Nuxt ui AI something about my code
but when i inserted my code it stoped working because of a page that is poping up on the screen and its because of the way the Ai shows the elements

انتخاب برند

like this promt that will just disable the AI and it wont let the AI answer i dont know which part causes that but this is what i ran into

Additional context

the full code is this

انتخاب برند

    <div class="p-4 overflow-y-auto">
      <div v-if="loading" class="text-center py-8 text-muted">
        در حال بارگذاری برندها...
      </div>

      <div v-else-if="brands.length === 0" class="text-center py-8 text-muted">
        برندی ثبت نشده است.
      </div>

      <div v-else class="grid grid-cols-2 md:grid-cols-4 gap-4">
        <button
          v-for="brand in brands"
          :key="brand.id"
          type="button"
          class="flex flex-col items-center p-3 rounded-lg border border-default hover:border-primary hover:bg-primary/5 transition"
          @click="selectBrand(brand)"
        >
          <div class="w-16 h-16 rounded-full overflow-hidden border border-default mb-2">
            <img
              :src="brand.image"
              :alt="brand.name"
              class="w-full h-full object-cover"
            >
          </div>
          <span class="text-sm font-medium">{{ brand.name }}</span>
          <span class="text-[11px] text-muted mt-1">
            /product_brand/{{ brand.slug }}
          </span>
        </button>
      </div>
    </div>
  </div>
</div>
<script setup> import { onMounted } from 'vue' import { useBrands } from '~/composables/useBrands' const props = defineProps({ modelValue: { type: Boolean, default: false } }) const emit = defineEmits(['update:modelValue', 'select']) const { brands, loading, fetchBrands } = useBrands() onMounted(() => { fetchBrands() }) function selectBrand(brand) { emit('select', brand) emit('update:modelValue', false) } </script>

Logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriageAwaiting initial review and prioritizationv4#4488

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions