mirror of
https://github.com/clash-verge-rev/clash-verge-rev
synced 2025-05-05 04:33:45 +08:00
fix: hide save button in readonly editor view (#1208)
This commit is contained in:
parent
455892b414
commit
44dc7fe24a
@ -171,12 +171,14 @@ export const EditorViewer = (props: Props) => {
|
|||||||
</DialogContent>
|
</DialogContent>
|
||||||
|
|
||||||
<DialogActions>
|
<DialogActions>
|
||||||
<Button onClick={onClose} variant="outlined">
|
<Button onClick={onClose} variant={readOnly ? "contained" : "outlined"}>
|
||||||
{t("Cancel")}
|
{t("Cancel")}
|
||||||
</Button>
|
</Button>
|
||||||
<Button onClick={onSave} variant="contained">
|
{readOnly ? null : (
|
||||||
{t("Save")}
|
<Button onClick={onSave} variant="contained">
|
||||||
</Button>
|
{t("Save")}
|
||||||
|
</Button>
|
||||||
|
)}
|
||||||
</DialogActions>
|
</DialogActions>
|
||||||
</Dialog>
|
</Dialog>
|
||||||
);
|
);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user