<template>
  <w-dialog
    ref="dialogRef"
    :persistent="true"
    :maximized="false"
    title="xxx"
    width="50%"
    height="50%"
    :can-maximize="false"
    :buttons="[
      {
        icon: IconEnum.保存,
        label: '保存',
        loading: false,
        click: async () => {},
      },
    ]"
    @maximized="dialogMaximize"
  ></w-dialog>
</template>
<script setup lang="ts">
// import { Environment, axios } from '@/platform';

// const response = await axios.get(Environment.apiContextPath('/api/sample/action1'));
// const message = response.data.message;

import { ref, reactive, onMounted } from 'vue';
import { IconEnum } from '@/platform';

const dialogRef = ref();

const dialogMaximize = (maximizedToggle: boolean) => {
  console.log(maximizedToggle);
};

onMounted(() => {
  dialogRef.value.show();
});
</script>
