Skip to content

Commit

Permalink
perf: code style
Browse files Browse the repository at this point in the history
  • Loading branch information
anncwb committed Oct 20, 2020
1 parent 894b63b commit f96d6b2
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 7 deletions.
3 changes: 1 addition & 2 deletions src/components/Icon/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ export default defineComponent({
}
};

watch(() => props.icon, update, { flush: 'post' });

const wrapStyleRef = computed((): any => {
const { size, color } = props;
let fs = size;
Expand All @@ -68,6 +66,7 @@ export default defineComponent({
};
});

watch(() => props.icon, update, { flush: 'post' });
onMounted(update);

return () => (
Expand Down
2 changes: 0 additions & 2 deletions src/components/Loading/BasicLoading.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@
// components
import { defineComponent, computed } from 'vue';
// hook
import { SizeEnum, sizeMap } from '/@/enums/sizeEnum';
import { BasicLoadingProps } from './type';
Expand Down
2 changes: 1 addition & 1 deletion src/components/Loading/FullLoading.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
absolute: Boolean as PropType<boolean>,
},
setup(props) {
// 样式前缀
const getStyle = computed((): any => {
return props.absolute
? {
Expand All @@ -32,6 +31,7 @@
}
: {};
});
return { getStyle, SizeEnum };
},
});
Expand Down
1 change: 0 additions & 1 deletion src/components/Markdown/src/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
setup(props, { attrs, emit }) {
const wrapRef = ref<Nullable<HTMLDivElement>>(null);
const vditorRef = ref<Nullable<Vditor>>(null);
const initedRef = ref(false);
function init() {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Menu/src/BasicMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export default defineComponent({
offset += 54;
}
return {
height: `calc(100% - ${offset}px)`,
height: `calc(100% - ${offset - 30}px)`,
position: 'relative',
overflow: 'auto',
};
Expand Down
5 changes: 5 additions & 0 deletions src/layouts/default/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -417,3 +417,8 @@
padding: 0 16px;
flex-grow: 1;
}

.ant-layout-sider-trigger {
height: 30px;
line-height: 30px;
}

0 comments on commit f96d6b2

Please sign in to comment.