Skip to content

Commit

Permalink
fix: fix the default value of props
Browse files Browse the repository at this point in the history
  • Loading branch information
anncwb committed Apr 25, 2021
1 parent 6a88205 commit 8b2e0f6
Show file tree
Hide file tree
Showing 19 changed files with 87 additions and 71 deletions.
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"@logicflow/extension": "^0.3.4",
"@vueuse/core": "^4.9.0",
"@zxcvbn-ts/core": "^0.3.0",
"ant-design-vue": "^2.1.2",
"ant-design-vue": "^2.1.3",
"axios": "^0.21.1",
"codemirror": "^5.61.0",
"cropperjs": "^1.5.11",
Expand Down Expand Up @@ -78,7 +78,7 @@
"@typescript-eslint/eslint-plugin": "^4.22.0",
"@typescript-eslint/parser": "^4.22.0",
"@vitejs/plugin-legacy": "^1.3.2",
"@vitejs/plugin-vue": "^1.2.1",
"@vitejs/plugin-vue": "^1.2.2",
"@vitejs/plugin-vue-jsx": "^1.1.3",
"@vue/compiler-sfc": "3.0.11",
"autoprefixer": "^10.2.5",
Expand All @@ -87,7 +87,7 @@
"cross-env": "^7.0.3",
"dotenv": "^8.2.0",
"eslint": "^7.25.0",
"eslint-config-prettier": "^8.2.0",
"eslint-config-prettier": "^8.3.0",
"eslint-define-config": "^1.0.8",
"eslint-plugin-prettier": "^3.4.0",
"eslint-plugin-vue": "^7.9.0",
Expand All @@ -104,9 +104,9 @@
"pretty-quick": "^3.1.0",
"rimraf": "^3.0.2",
"rollup-plugin-visualizer": "5.3.4",
"stylelint": "^13.12.0",
"stylelint": "^13.13.0",
"stylelint-config-prettier": "^8.0.2",
"stylelint-config-standard": "^21.0.0",
"stylelint-config-standard": "^22.0.0",
"stylelint-order": "^4.1.0",
"ts-node": "^9.1.1",
"typescript": "4.2.4",
Expand Down
4 changes: 2 additions & 2 deletions src/components/Cropper/src/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@
},
imageStyle: {
type: Object as PropType<CSSProperties>,
default: () => {},
default: () => ({}),
},
options: {
type: Object as PropType<Options>,
default: () => {},
default: () => ({}),
},
},
emits: ['cropperedInfo'],
Expand Down
4 changes: 2 additions & 2 deletions src/components/FlowChart/src/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@
props: {
flowOptions: {
type: Object as PropType<Definition>,
default: () => {},
default: () => ({}),
},
data: {
type: Object as PropType<any>,
default: () => {},
default: () => ({}),
},
toolbar: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Form/src/components/ApiSelect.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
// api params
params: {
type: Object as PropType<Recordable>,
default: () => {},
default: () => ({}),
},
// support xxx.xxx.xx
resultField: propTypes.string.def(''),
Expand Down
6 changes: 3 additions & 3 deletions src/components/Form/src/components/FormAction.vue
Original file line number Diff line number Diff line change
Expand Up @@ -67,15 +67,15 @@
showAdvancedButton: propTypes.bool.def(true),
resetButtonOptions: {
type: Object as PropType<ButtonOptions>,
default: () => {},
default: () => ({}),
},
submitButtonOptions: {
type: Object as PropType<ButtonOptions>,
default: () => {},
default: () => ({}),
},
actionColOptions: {
type: Object as PropType<Partial<ColEx>>,
default: () => {},
default: () => ({}),
},
actionSpan: propTypes.number.def(6),
isAdvanced: propTypes.bool,
Expand Down
8 changes: 4 additions & 4 deletions src/components/Form/src/components/FormItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,19 @@
props: {
schema: {
type: Object as PropType<FormSchema>,
default: () => {},
default: () => ({}),
},
formProps: {
type: Object as PropType<FormProps>,
default: () => {},
default: () => ({}),
},
allDefaultValues: {
type: Object as PropType<Recordable>,
default: () => {},
default: () => ({}),
},
formModel: {
type: Object as PropType<Recordable>,
default: () => {},
default: () => ({}),
},
setFormModel: {
type: Function as PropType<(key: string, value: any) => void>,
Expand Down
2 changes: 1 addition & 1 deletion src/components/SimpleMenu/src/SimpleMenuTag.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
props: {
item: {
type: Object as PropType<Menu>,
default: () => {},
default: () => ({}),
},
dot: propTypes.bool,
collapseParent: propTypes.bool,
Expand Down
2 changes: 1 addition & 1 deletion src/components/SimpleMenu/src/SimpleSubMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
props: {
item: {
type: Object as PropType<Menu>,
default: () => {},
default: () => ({}),
},
parent: propTypes.bool,
collapsedShowTitle: propTypes.bool,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Table/src/components/HeaderCell.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
props: {
column: {
type: Object as PropType<BasicColumn>,
default: () => {},
default: () => ({}),
},
},
setup(props) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
},
column: {
type: Object as PropType<BasicColumn>,
default: () => {},
default: () => ({}),
},
index: propTypes.number,
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/Table/src/components/settings/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
props: {
setting: {
type: Object as PropType<TableSetting>,
default: () => {},
default: () => ({}),
},
},
setup(props) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@
&:hover {
background-color: @header-light-bg-hover-color;
}
.@{prefix-cls}__name {
color: @text-color-base;
}
Expand Down
1 change: 0 additions & 1 deletion src/layouts/default/setting/components/InputNumberItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
props: {
event: {
type: Number as PropType<HandlerEnum>,
default: () => {},
},
title: {
type: String,
Expand Down
1 change: 0 additions & 1 deletion src/layouts/default/setting/components/SelectItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
props: {
event: {
type: Number as PropType<HandlerEnum>,
default: () => {},
},
disabled: {
type: Boolean,
Expand Down
1 change: 0 additions & 1 deletion src/layouts/default/setting/components/SwitchItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
props: {
event: {
type: Number as PropType<HandlerEnum>,
default: () => {},
},
disabled: {
type: Boolean,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
},
event: {
type: Number as PropType<HandlerEnum>,
default: () => {},
},
def: {
type: String,
Expand Down
2 changes: 1 addition & 1 deletion src/layouts/default/setting/components/TypePicker.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
},
handler: {
type: Function as PropType<Fn>,
default: () => {},
default: () => ({}),
},
def: {
type: String,
Expand Down
2 changes: 1 addition & 1 deletion src/views/sys/login/Login.vue
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@
min-width: 160px;
}
}
.@{countdown-prefix-cls} input {
min-width: unset;
}
Expand Down
Loading

0 comments on commit 8b2e0f6

Please sign in to comment.