App.vue 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. <template>
  2. <div class="m3 m3graph" v-if="auth && global">
  3. <Header :auth="auth" class="header" v-if="layout.header.show"></Header>
  4. <div :class="layout.header.show ? 'main' : 'main-fullscreen'">
  5. <SideBar class="sidebar" :auth="auth" :global="global" v-if="layout.sidebar.show" ></SideBar>
  6. <MainView :global="global" class="content" v-if="global"></MainView>
  7. </div>
  8. <Footer :auth="auth" class="footer" v-if="layout.footer.show"></Footer>
  9. </div>
  10. </template>
  11. <script>
  12. import MainView from './components/MainView';
  13. import Header from './components/layout/Header';
  14. import SideBar from './components/layout/SideBar';
  15. import Footer from './components/layout/Footer';
  16. export default {
  17. name: 'app',
  18. components: {
  19. Header,
  20. SideBar,
  21. Footer,
  22. MainView//: resolve => {require(['./components/MainView.vue'], resolve)}
  23. },
  24. data(){
  25. return {
  26. global:null,
  27. auth: null,
  28. layout: {
  29. header: {
  30. show: true
  31. },
  32. sidebar: {
  33. show: true
  34. },
  35. footer: {
  36. show: true
  37. }
  38. }
  39. }
  40. },
  41. created(){
  42. this.global = this.m3.global;
  43. this.auth = this.m3.auth.signedUser;
  44. this.eventHub.$on("layout-change",(data)=>{
  45. this.layout = data;
  46. })
  47. }
  48. }
  49. </script>
  50. <style>
  51. body{
  52. font-size: 12px;
  53. font-family: "PingFang SC",Arial,"Microsoft YaHei",sans-serif;
  54. margin: 0px;
  55. padding: 0px;
  56. overflow: hidden;
  57. }
  58. .el-menu .svg-icon{
  59. width: 1.2em!important;
  60. height: 1.2em!important;
  61. padding: 0px 5px 0 0;
  62. }
  63. .main{
  64. padding-top: 50px;
  65. display: flex;
  66. }
  67. .main-fullscreen{
  68. display: flex;
  69. }
  70. .el-table .el-table__body td {
  71. padding: 3px;
  72. }
  73. /* mxgraph contextmenu style */
  74. td.mxPopupMenuIcon div {
  75. width:16px;
  76. height:16px;
  77. }
  78. html div.mxPopupMenu {
  79. -webkit-box-shadow:2px 2px 3px #d5d5d5;
  80. -moz-box-shadow:2px 2px 3px #d5d5d5;
  81. box-shadow:2px 2px 3px #d5d5d5;
  82. _filter:progid:DXImageTransform.Microsoft.DropShadow(OffX=2, OffY=2, Color='#d0d0d0', Positive='true');
  83. background:white;
  84. position:absolute;
  85. border:1px solid #e7e7e7;
  86. padding:3px;
  87. }
  88. html table.mxPopupMenu {
  89. border-collapse:collapse;
  90. margin:0px;
  91. }
  92. html td.mxPopupMenuItem {
  93. padding:7px 30px 7px 30px;
  94. font-family: "微软雅黑";/* Microsoft YaHei,Helvetica Neue,Helvetica,Arial Unicode MS,Arial;*/
  95. font-size:12px;
  96. }
  97. html td.mxPopupMenuIcon {
  98. background-color:white;
  99. padding:0px;
  100. }
  101. td.mxPopupMenuIcon .geIcon {
  102. padding:2px;
  103. padding-bottom:4px;
  104. margin:2px;
  105. border:1px solid transparent;
  106. opacity:0.5;
  107. _width:26px;
  108. _height:26px;
  109. }
  110. td.mxPopupMenuIcon .geIcon:hover {
  111. border:1px solid gray;
  112. border-radius:2px;
  113. opacity:1;
  114. }
  115. html tr.mxPopupMenuItemHover {
  116. background-color: #f5f5f5;
  117. color: black;
  118. }
  119. table.mxPopupMenu hr {
  120. color:#cccccc;
  121. background-color:#f5f5f5;
  122. border:none;
  123. height:1px;
  124. }
  125. table.mxPopupMenu tr {
  126. font-size:4pt;
  127. }
  128. .el-dialog{
  129. width: 90vw!important;
  130. height:auto;
  131. margin-top: 0!important;
  132. }
  133. /* el-checkbox */
  134. .el-checkbox__label {
  135. font-size: 12px!important;
  136. }
  137. /* el-tabs */
  138. .el-tabs--border-card>.el-tabs__header {
  139. background-color: #f2f2f2!important;
  140. border-bottom: unset!important;
  141. border-top: 1px solid #dddddd;
  142. }
  143. .el-menu .svg-icon{
  144. width: 1.2em!important;
  145. height: 1.2em!important;
  146. padding: 0px 5px 0 0;
  147. }
  148. </style>