Skip to content

Commit

Permalink
chore: format
Browse files Browse the repository at this point in the history
  • Loading branch information
D-D-H committed Dec 15, 2023
1 parent 11e3766 commit 389084d
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 9 deletions.
2 changes: 1 addition & 1 deletion frontend/src/components/Analysis.vue
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ function analyze(options?) {
const value = pair.slice(index + 1);
// delete qouta on value if exists.
const cleanedValue = value.replace(/^'(.*)'$/, '$1');
options[key] = cleanedValue
options[key] = cleanedValue;
}
}
parameters = { options };
Expand Down
16 changes: 11 additions & 5 deletions frontend/src/components/heapdump/Setup.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const options = reactive({
function onConfirm() {
request('clean').then(() => {
analysis.leaveGuard = false;
analysis.setPhase(Phase.INIT)
analysis.setPhase(Phase.INIT);
analysis.setShowSetupPage(false);
emit('confirmAnalysisOptions', options);
});
Expand Down Expand Up @@ -154,15 +154,17 @@ const enableDiscard = computed(() => options.discard_objects);
clearable
class="discard-pattern-form-input"
@keydown.enter="(e) => e.preventDefault()"
> </el-input>
>
</el-input>
</el-form-item>
<el-form-item :label="hdt('option.labelOfDiscardObjectsRatio')" v-if="enableDiscard">
<el-input
v-model="options.discard_ratio"
placeholder="0~100"
class="discard-ratio-form-input"
@keydown.enter="(e) => e.preventDefault()"
> </el-input>
>
</el-input>
</el-form-item>
<!-- Discard Objects end -->
<el-form-item :label="hdt('option.labelAdditionalAnalyseOptions')">
Expand All @@ -172,7 +174,8 @@ const enableDiscard = computed(() => options.discard_objects);
class="additional-options-form-input"
clearable
@keydown.enter="(e) => e.preventDefault()"
> </el-input>
>
</el-input>
<el-popover
placement="top"
:width="600"
Expand All @@ -198,7 +201,10 @@ const enableDiscard = computed(() => options.discard_objects);
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onConfirm">{{ t('common.confirm') }}</el-button>
<el-button @click="onCancel" v-if="analysis.phase !== Phase.INIT && analysis.phase !== Phase.SETUP">
<el-button
@click="onCancel"
v-if="analysis.phase !== Phase.INIT && analysis.phase !== Phase.SETUP"
>
{{ t('common.cancel') }}
</el-button>
</el-form-item>
Expand Down
3 changes: 1 addition & 2 deletions frontend/src/components/heapdump/Toolbar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@ const { request } = useAnalysisApiRequester();
const analysis = useAnalysisStore();

function showSetup() {
analysis.setShowSetupPage(true)
analysis.setShowSetupPage(true);
}

</script>
<template>
<el-divider direction="vertical" />
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/stores/analysis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export const useAnalysisStore = defineStore('analysis', {
},

setShowSetupPage(showSetupPage: boolean) {
this.showSetupPage = showSetupPage
this.showSetupPage = showSetupPage;
}
}
});

0 comments on commit 389084d

Please sign in to comment.