How to use the full screen function of fullscreen in the dialog component of element-ui

if you want to click, you can turn on or off the full screen:

<el-button type="text" @click="dialogVisible = true"> Dialog</el-button>  
<el-dialog fullscreen :visible.sync="dialogVisible ">
    <el-button class="fullscreen">
      <i class="full"></i>

</el-button>

{{testInfo}}

</el-dialog>

the vue,element-ui you just learned is also in the beginner stage. Ask God to teach you how to use the Attributes of the component

.

in fact, the crux of the problem is that if fullscreen uses api, it must be event-driven. What do you mean, you have to click on it, just like you watch the full screen of LVB, so you should write this attribute in the wrong way.


store = {
    isfullscreen: false
}

<el-button type="text" @click="dialogVisible = true"> Dialog</el-button>  
<el-dialog :fullscreen="isfullscreen" :visible.sync="dialogVisible ">
    <el-button class="fullscreen">
      <i class="full"></i>

</el-button>

{{testInfo}}

</el-dialog>

must be obtained through getters, so I won't write. The idea of
is to define global variables. Click isfullscreen =! isfullscreen , so that every dialog is controlled by this variable on the full screen, but every dialog should write the value of the fullscreen attribute as isfullscreen

.
Menu