portal view

This commit is contained in:
Brandon Fergerson 2022-04-30 11:52:56 +02:00
parent 6b0c20e2f5
commit 2a0a97e7d9
2 changed files with 7 additions and 18 deletions

View File

@ -33,6 +33,7 @@ let portalStyle = reactive({});
if (query["portal"] === "true") {
// eslint-disable-next-line no-undef
portalStyle = reactive({
"height": "100%",
"max-height": "375px",
"max-width": "800px",
});
@ -49,7 +50,7 @@ if (!appStore.utc) {
</script>
<style lang="scss" scoped>
.app-main {
height: 100%;
height: calc(100% - 40px);
background: #f7f9fa;
}
</style>

View File

@ -144,13 +144,10 @@ const dashboardStore = useDashboardStore();
const selectorStore = useSelectorStore();
const appStore = useAppStoreWithOut();
const params = useRoute().params;
const path = useRoute();
const router = useRouter();
if (!path.path.includes("fullview")) {
dashboardStore.setViewMode(false);
} else {
dashboardStore.setViewMode(true);
}
const { query } = useRoute();
dashboardStore.setViewMode(query["fullview"] === "true");
const toolIcons = ref<{ name: string; content: string; id: string }[]>(
EndpointRelationTools
);
@ -398,16 +395,7 @@ function changeDestPods(pod: any) {
selectorStore.setCurrentDestPod(null);
}
}
function toggleFullView(e) {
dashboardStore.setViewMode(e);
if (dashboardStore.fullView) {
const newPath = path.path.replace("dashboard", "fullview");
router.push(newPath);
} else {
const newPath = path.path.replace("fullview", "dashboard");
router.push(newPath);
}
}
function changeMode() {
if (dashboardStore.editMode) {
ElMessage.warning(t("editWarning"));