123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- <template>
- <i
- v-if="innerValue"
- class="el-icon-circle-close pl-1"
- style="cursor: pointer; font-weight: 600; transition: 500ms"
- @click="onHide"
- ></i>
- </template>
- <script>
- export default {
- name: "IconHide",
- components: {},
- props: {
- value: {
- type: Boolean,
- require: true,
- },
- },
- data() {
- return {};
- },
- computed: {
- innerValue: {
- get() {
- return this.$props.value;
- },
- set(value) {
- this.$emit("input", value);
- },
- },
- },
- watch: {},
- methods: {
- onHide() {
- this.innerValue = !this.innerValue;
- this.$emit("hide");
- },
- },
- created() {},
- mounted() {},
- destroyed() {},
- };
- </script>
- <style scoped></style>
|