show.vue 909 B

12345678910111213141516171819202122232425262728293031323334353637
  1. <template>
  2. <ui-group :title="$t('am.path.list')" class="show-taggings">
  3. <template #icon>
  4. <ui-icon
  5. ctrl
  6. :type="selectPaths.all.value ? 'eye-s' : 'eye-n'"
  7. @click="selectPaths.all.value = !selectPaths.all.value"
  8. />
  9. </template>
  10. <PathSign
  11. v-for="path in filterPath"
  12. :key="path.id"
  13. :path="path"
  14. :edit="false"
  15. class="show-path"
  16. />
  17. </ui-group>
  18. </template>
  19. <script setup lang="ts">
  20. import { custom } from "@/env";
  21. import PathSign from "./sign.vue";
  22. import { paths, selectPaths } from "@/store";
  23. import { computed } from "vue";
  24. const props = withDefaults(defineProps<{ keyword?: string }>(), { keyword: "" });
  25. const filterPath = computed(() =>
  26. paths.value.filter((path) => path.name.includes(props.keyword))
  27. );
  28. </script>
  29. <style lang="scss" scoped>
  30. .show-path {
  31. border-bottom: 1px solid var(--colors-border-color);
  32. }
  33. </style>