mirror of
https://github.com/fofolee/uTools-quickcommand.git
synced 2025-06-08 05:55:34 +08:00
修复搜索结果显示bug
This commit is contained in:
parent
2ae602d416
commit
01977ea873
@ -19,7 +19,7 @@
|
|||||||
<div class="row justify-end">
|
<div class="row justify-end">
|
||||||
<div
|
<div
|
||||||
class="text-ellipsis"
|
class="text-ellipsis"
|
||||||
v-text="commandInfo.features.explain"
|
v-html="purify(commandInfo.features.explain)"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -56,6 +56,7 @@
|
|||||||
import CommandTypeTag from "../CommandTypeTag.vue";
|
import CommandTypeTag from "../CommandTypeTag.vue";
|
||||||
import platformTypes from "js/options/platformTypes.js";
|
import platformTypes from "js/options/platformTypes.js";
|
||||||
import programs from "js/options/programs.js";
|
import programs from "js/options/programs.js";
|
||||||
|
import DOMPurify from "dompurify";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "DenseLayout",
|
name: "DenseLayout",
|
||||||
@ -87,6 +88,11 @@ export default {
|
|||||||
return this.program.shortName ?? this.program.name;
|
return this.program.shortName ?? this.program.name;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
methods: {
|
||||||
|
purify(content) {
|
||||||
|
return DOMPurify.sanitize(content);
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
<!-- 名称 -->
|
<!-- 名称 -->
|
||||||
<div
|
<div
|
||||||
class="text-ellipsis"
|
class="text-ellipsis"
|
||||||
v-text="commandInfo.features.explain"
|
v-html="purify(commandInfo.features.explain)"
|
||||||
/>
|
/>
|
||||||
<!-- 匹配模式 -->
|
<!-- 匹配模式 -->
|
||||||
<CommandTypeTag
|
<CommandTypeTag
|
||||||
@ -51,6 +51,7 @@
|
|||||||
import CommandTypeTag from "../CommandTypeTag.vue";
|
import CommandTypeTag from "../CommandTypeTag.vue";
|
||||||
import platformTypes from "js/options/platformTypes.js";
|
import platformTypes from "js/options/platformTypes.js";
|
||||||
import programs from "js/options/programs.js";
|
import programs from "js/options/programs.js";
|
||||||
|
import DOMPurify from "dompurify";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "ListLayout",
|
name: "ListLayout",
|
||||||
@ -79,6 +80,11 @@ export default {
|
|||||||
return this.programs[this.commandInfo.program];
|
return this.programs[this.commandInfo.program];
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
methods: {
|
||||||
|
purify(content) {
|
||||||
|
return DOMPurify.sanitize(content);
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
<div class="row justify-center w-100">
|
<div class="row justify-center w-100">
|
||||||
<div
|
<div
|
||||||
class="text-ellipsis text-center"
|
class="text-ellipsis text-center"
|
||||||
v-text="commandInfo.features.explain"
|
v-html="purify(commandInfo.features.explain)"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -35,6 +35,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import CommandTypeTag from "../CommandTypeTag.vue";
|
import CommandTypeTag from "../CommandTypeTag.vue";
|
||||||
import platformTypes from "js/options/platformTypes.js";
|
import platformTypes from "js/options/platformTypes.js";
|
||||||
|
import DOMPurify from "dompurify";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "MiniLayout",
|
name: "MiniLayout",
|
||||||
@ -49,6 +50,11 @@ export default {
|
|||||||
platformTypes,
|
platformTypes,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
methods: {
|
||||||
|
purify(content) {
|
||||||
|
return DOMPurify.sanitize(content);
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user