Skip to content

Commit

Permalink
feat: vid
Browse files Browse the repository at this point in the history
  • Loading branch information
lisonge committed Dec 14, 2023
1 parent 25e7030 commit 566d5e4
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/components/AttrCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,11 @@ const attrDesc: Record<string, string> = {
_pid: `虚拟属性:父节点的 _id`,
depth: `在某些应用上可能造成无限节点错误`,
id: `可快速查找`,
vid: `可快速查找`,
text: `可快速查找`,
};
const qfAttrs = [`id`,`vid`, `text`];
</script>

<template>
Expand All @@ -61,8 +64,8 @@ const attrDesc: Record<string, string> = {
<div
v-if="attrx.name in attrDesc"
flex
flex-justify-between
flex-items-center
justify-between
items-center
>
<div>
{{ attrx.name }}
Expand All @@ -72,7 +75,7 @@ const attrDesc: Record<string, string> = {
<NIcon size="16">
<svg
viewBox="0 0 28 28"
v-if="attrx.name != `id` && attrx.name != `text`"
v-if="!qfAttrs.includes(attrx.name)"
>
<g fill="none">
<path
Expand All @@ -85,6 +88,7 @@ const attrDesc: Record<string, string> = {
v-else-if="
(focusNode.quickFind ||
(attrx.name == 'id' && focusNode.idQf) ||
(attrx.name == 'vid' && focusNode.idQf) ||
(attrx.name == 'text' && focusNode.textQf)) &&
JSON.parse(attrx.value)
"
Expand Down

0 comments on commit 566d5e4

Please sign in to comment.