vue2-client 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (132) hide show
  1. package/.eslintrc.js +81 -81
  2. package/README.md +4 -2
  3. package/babel.config.js +14 -14
  4. package/docs/index.md +29 -29
  5. package/{src/index.js → index.js} +8 -8
  6. package/jest.config.js +3 -3
  7. package/package.json +1 -1
  8. package/public/index.html +27 -27
  9. package/src/App.vue +93 -93
  10. package/src/base-client/all.js +26 -26
  11. package/src/base-client/components/common/CreateQuery/CreateQuery.vue +4 -4
  12. package/src/base-client/components/common/CreateQuery/index.md +42 -42
  13. package/src/base-client/components/common/CreateSimpleFormQuery/CreateSimpleFormQuery.vue +3 -3
  14. package/src/base-client/components/common/CreateSimpleFormQuery/index.md +42 -42
  15. package/src/base-client/components/common/CustomColumnsDrawer/index.md +46 -46
  16. package/src/base-client/components/common/FormGroupEdit/FormGroupEdit.vue +3 -3
  17. package/src/base-client/components/common/FormGroupEdit/index.md +43 -43
  18. package/src/base-client/components/common/FormGroupQuery/index.md +43 -43
  19. package/src/base-client/components/common/XAddForm/XAddForm.vue +3 -3
  20. package/src/base-client/components/common/XAddForm/index.md +60 -60
  21. package/src/base-client/components/common/XBadge/index.md +39 -39
  22. package/src/base-client/components/common/XCard/index.md +43 -43
  23. package/src/base-client/components/common/XForm/XForm.vue +2 -2
  24. package/src/base-client/components/common/XForm/XFormItem.vue +1 -1
  25. package/src/base-client/components/common/XForm/index.md +3 -3
  26. package/src/base-client/components/common/XFormCol/index.md +35 -35
  27. package/src/base-client/components/common/XFormTable/XFormTable.vue +6 -6
  28. package/src/base-client/components/common/XFormTable/index.md +89 -89
  29. package/src/base-client/components/common/XTable/XTable.vue +3 -3
  30. package/src/base-client/components/common/XTable/index.md +3 -3
  31. package/src/base-client/components/common/XTreeOne/XTreeOne.vue +105 -105
  32. package/src/base-client/components/iot/CustomerDetailsView/CustomerDetailsView.vue +3 -3
  33. package/src/base-client/components/iot/CustomerDetailsView/index.md +41 -41
  34. package/src/base-client/components/iot/DataAnalysisUser/DataAnalysisUser.vue +127 -127
  35. package/src/base-client/components/iot/DataAnalysisViewGD/DataAnalysisViewGD.vue +5 -5
  36. package/src/base-client/components/iot/DeviceBrandDetailsView/DeviceBrandDetailsView.vue +3 -3
  37. package/src/base-client/components/iot/DeviceDetailsView/DeviceDetailsView.vue +3 -3
  38. package/src/base-client/components/iot/DeviceDetailsView/index.md +43 -43
  39. package/src/base-client/components/iot/DeviceDetailsView/part/DeviceDetailsCount.vue +1 -1
  40. package/src/base-client/components/iot/DeviceDetailsView/part/DeviceDetailsException.vue +57 -57
  41. package/src/base-client/components/iot/DeviceDetailsView/part/DeviceDetailsInstruct.vue +122 -122
  42. package/src/base-client/components/iot/DeviceDetailsView/part/DeviceDetailsInstructOperate.vue +4 -4
  43. package/src/base-client/components/iot/DeviceDetailsView/part/DeviceDetailsMain.vue +225 -225
  44. package/src/base-client/components/iot/DeviceDetailsView/part/DeviceDetailsRead.vue +135 -135
  45. package/src/base-client/components/iot/DeviceTypeDetailsView/DeviceTypeDetailsView.vue +3 -3
  46. package/src/base-client/components/iot/InstructDetailsView/InstructDetailsView.vue +5 -5
  47. package/src/base-client/components/iot/InstructDetailsView/index.md +45 -45
  48. package/src/base-client/components/iot/LogDetailsView/LogDetailsView.vue +3 -3
  49. package/src/base-client/components/iot/LogDetailsView/index.md +43 -43
  50. package/src/base-client/components/iot/MeterDetailsView/MeterDetailsView.vue +3 -3
  51. package/src/base-client/components/iot/MeterDetailsView/index.md +43 -43
  52. package/src/base-client/components/iot/MeterDetailsView/part/MeterDetailsCount.vue +1 -1
  53. package/src/base-client/components/iot/MeterDetailsView/part/MeterDetailsException.vue +3 -3
  54. package/src/base-client/components/iot/MeterDetailsView/part/MeterDetailsHandPlan.vue +3 -3
  55. package/src/base-client/components/iot/MeterDetailsView/part/MeterDetailsInstruct.vue +4 -4
  56. package/src/base-client/components/iot/MeterDetailsView/part/MeterDetailsMain.vue +3 -3
  57. package/src/base-client/components/iot/MeterDetailsView/part/MeterDetailsSellGas.vue +3 -3
  58. package/src/base-client/components/iot/WebmeterAnalysisView/WebmeterAnalysisView.vue +4 -4
  59. package/src/base-client/components/iot/WebmeterAnalysisView/index.md +48 -48
  60. package/src/base-client/components/system/DictionaryDetailsView/DictionaryDetailsView.vue +4 -4
  61. package/src/base-client/components/system/DictionaryDetailsView/index.md +41 -41
  62. package/src/base-client/components/system/QueryParamsDetailsView/QueryParamsDetailsView.vue +3 -3
  63. package/src/base-client/components/ticket/EmployeeDetailsView/EmployeeDetailsView.vue +5 -5
  64. package/src/base-client/components/ticket/TicketDetailsView/TicketDetailsView.vue +5 -5
  65. package/src/base-client/components/ticket/TicketDetailsView/part/TicketDetailsFlow.vue +3 -3
  66. package/src/base-client/components/ticket/TicketSubmitSuccessView/TicketSubmitSuccessView.vue +6 -6
  67. package/src/base-client/plugins/AppData.js +3 -3
  68. package/src/base-client/plugins/GetLoginInfoService.js +2 -2
  69. package/src/base-client/plugins/index.js +4 -4
  70. package/src/bootstrap.js +4 -4
  71. package/src/components/Ellipsis/Ellipsis.vue +64 -64
  72. package/src/components/Ellipsis/index.md +38 -38
  73. package/src/components/NumberInfo/index.md +43 -43
  74. package/src/components/STable/README.md +341 -341
  75. package/src/components/Trend/index.md +45 -45
  76. package/src/components/cache/AKeepAlive.js +172 -172
  77. package/src/components/checkbox/index.js +7 -7
  78. package/src/components/index.js +36 -36
  79. package/src/components/menu/menu.js +273 -273
  80. package/src/components/setting/Setting.vue +237 -237
  81. package/src/components/table/advance/AdvanceTable.vue +275 -275
  82. package/src/components/transition/PageToggleTransition.vue +97 -97
  83. package/src/config/default/setting.config.js +33 -33
  84. package/src/layouts/CommonLayout.vue +42 -42
  85. package/src/layouts/ComponentLayoutOne.vue +47 -47
  86. package/src/layouts/PageLayout.vue +151 -151
  87. package/src/layouts/SinglePageView.vue +74 -74
  88. package/src/layouts/header/AdminHeader.vue +109 -109
  89. package/src/layouts/header/HeaderAvatar.vue +60 -60
  90. package/src/layouts/header/HeaderNotice.vue +1 -1
  91. package/src/layouts/tabs/TabsHead.vue +190 -190
  92. package/src/layouts/tabs/TabsView.vue +355 -355
  93. package/src/main.js +2 -2
  94. package/src/mock/common/reportData.js +20 -20
  95. package/src/mock/goods/index.js +108 -108
  96. package/src/mock/index.js +12 -12
  97. package/src/mock/project/index.js +17 -17
  98. package/src/mock/user/current.js +13 -13
  99. package/src/mock/user/login.js +39 -39
  100. package/src/mock/user/routes.js +61 -61
  101. package/src/mock/workplace/index.js +15 -15
  102. package/src/pages/exception/403.vue +2 -2
  103. package/src/pages/exception/404.vue +2 -2
  104. package/src/pages/exception/500.vue +2 -2
  105. package/src/pages/login/Login.vue +8 -8
  106. package/src/pages/report/ReportTable.js +125 -125
  107. package/src/pages/report/ReportTableHome.vue +2 -2
  108. package/src/pages/resourceManage/resourceManageMain.vue +1 -1
  109. package/src/pages/system/applyInstallView/Core.vue +570 -570
  110. package/src/pages/system/applyInstallView/index.vue +34 -34
  111. package/src/pages/system/dictionary/index.vue +41 -41
  112. package/src/pages/system/queryParams/index.vue +41 -41
  113. package/src/router/async/config.async.js +25 -25
  114. package/src/router/async/router.map.js +13 -13
  115. package/src/router/guards.js +104 -104
  116. package/src/router/index.js +2 -2
  117. package/src/services/api/common.js +1 -1
  118. package/src/services/api/restTools.js +1 -1
  119. package/src/services/dataSource.js +12 -12
  120. package/src/services/user.js +34 -34
  121. package/src/store/index.js +5 -5
  122. package/src/store/modules/setting.js +114 -114
  123. package/src/theme/index.less +5 -5
  124. package/src/theme/reportTable.less +58 -58
  125. package/src/utils/i18n.js +80 -80
  126. package/src/utils/indexedDB.js +1 -1
  127. package/src/utils/request.js +1 -1
  128. package/src/utils/routerUtil.js +3 -3
  129. package/tests/unit/ReportTable.spec.js +2 -2
  130. package/vue.config.js +1 -0
  131. package/webpack.config.js +1 -1
  132. package/src/router/config.js +0 -23
@@ -1,97 +1,97 @@
1
- <template>
2
- <transition
3
- v-if="!disabled"
4
- :enter-active-class="`animated ${enterAnimate} page-toggle-enter-active`"
5
- :leave-active-class="`animated ${leaveAnimate} page-toggle-leave-active`"
6
- >
7
- <slot></slot>
8
- </transition>
9
- <div v-else><slot></slot></div>
10
- </template>
11
-
12
- <script>
13
- import { preset as animates } from '@/config/default/animate.config'
14
-
15
- export default {
16
- name: 'PageToggleTransition',
17
- props: {
18
- disabled: {
19
- type: Boolean,
20
- default: false
21
- },
22
- animate: {
23
- type: String,
24
- validator (value) {
25
- return animates.findIndex(item => item.name == value) != -1
26
- },
27
- default: 'bounce'
28
- },
29
- // eslint-disable-next-line vue/require-default-prop
30
- direction: {
31
- type: String,
32
- validator (value) {
33
- return ['x', 'y', 'left', 'right', 'up', 'down', 'downLeft', 'upRight', 'downRight', 'upLeft', 'downBig',
34
- 'upBig', 'downLeft', 'downRight', 'topRight', 'bottomLeft', 'topLeft', 'bottomRight', 'default'].indexOf(value) > -1
35
- }
36
- },
37
- reverse: {
38
- type: Boolean,
39
- default: true
40
- }
41
- },
42
- computed: {
43
- enterAnimate () {
44
- return this.activeClass(false)
45
- },
46
- leaveAnimate () {
47
- return this.activeClass(true)
48
- }
49
- },
50
- methods: {
51
- activeClass (isLeave) {
52
- const animate = animates.find(item => this.animate == item.name)
53
- if (animate == undefined) {
54
- return ''
55
- }
56
- let direction = ''
57
- if (this.direction == undefined) {
58
- direction = animate.directions[0]
59
- } else {
60
- direction = animate.directions.find(item => item == this.direction)
61
- }
62
- direction = (direction == undefined || direction === 'default') ? '' : direction
63
- if (direction != '') {
64
- direction = isLeave && this.reverse ? this.reversePosition(direction, animate.directions) : direction
65
- direction = direction[0].toUpperCase() + direction.substring(1)
66
- }
67
- const t = isLeave ? 'Out' : 'In'
68
- return animate.name + t + direction
69
- },
70
- reversePosition (direction, directions) {
71
- if (direction.length == 0 || direction == 'x' || direction == 'y') {
72
- return direction
73
- }
74
- let index = directions.indexOf(direction)
75
- index = (index % 2 == 1) ? index - 1 : index + 1
76
- return directions[index]
77
- }
78
- }
79
- }
80
- </script>
81
-
82
- <style lang="less">
83
- .page-toggle-enter-active{
84
- position: absolute !important;
85
- animation-duration: 0.8s !important;
86
- width: calc(100%) !important;
87
- }
88
- .page-toggle-leave-active{
89
- position: absolute !important;
90
- animation-duration: 0.8s !important;
91
- width: calc(100%) !important;
92
- }
93
- .page-toggle-enter{
94
- }
95
- .page-toggle-leave-to{
96
- }
97
- </style>
1
+ <template>
2
+ <transition
3
+ v-if="!disabled"
4
+ :enter-active-class="`animated ${enterAnimate} page-toggle-enter-active`"
5
+ :leave-active-class="`animated ${leaveAnimate} page-toggle-leave-active`"
6
+ >
7
+ <slot></slot>
8
+ </transition>
9
+ <div v-else><slot></slot></div>
10
+ </template>
11
+
12
+ <script>
13
+ import { preset as animates } from '@vue2-client/config/default/animate.config'
14
+
15
+ export default {
16
+ name: 'PageToggleTransition',
17
+ props: {
18
+ disabled: {
19
+ type: Boolean,
20
+ default: false
21
+ },
22
+ animate: {
23
+ type: String,
24
+ validator (value) {
25
+ return animates.findIndex(item => item.name == value) != -1
26
+ },
27
+ default: 'bounce'
28
+ },
29
+ // eslint-disable-next-line vue/require-default-prop
30
+ direction: {
31
+ type: String,
32
+ validator (value) {
33
+ return ['x', 'y', 'left', 'right', 'up', 'down', 'downLeft', 'upRight', 'downRight', 'upLeft', 'downBig',
34
+ 'upBig', 'downLeft', 'downRight', 'topRight', 'bottomLeft', 'topLeft', 'bottomRight', 'default'].indexOf(value) > -1
35
+ }
36
+ },
37
+ reverse: {
38
+ type: Boolean,
39
+ default: true
40
+ }
41
+ },
42
+ computed: {
43
+ enterAnimate () {
44
+ return this.activeClass(false)
45
+ },
46
+ leaveAnimate () {
47
+ return this.activeClass(true)
48
+ }
49
+ },
50
+ methods: {
51
+ activeClass (isLeave) {
52
+ const animate = animates.find(item => this.animate == item.name)
53
+ if (animate == undefined) {
54
+ return ''
55
+ }
56
+ let direction = ''
57
+ if (this.direction == undefined) {
58
+ direction = animate.directions[0]
59
+ } else {
60
+ direction = animate.directions.find(item => item == this.direction)
61
+ }
62
+ direction = (direction == undefined || direction === 'default') ? '' : direction
63
+ if (direction != '') {
64
+ direction = isLeave && this.reverse ? this.reversePosition(direction, animate.directions) : direction
65
+ direction = direction[0].toUpperCase() + direction.substring(1)
66
+ }
67
+ const t = isLeave ? 'Out' : 'In'
68
+ return animate.name + t + direction
69
+ },
70
+ reversePosition (direction, directions) {
71
+ if (direction.length == 0 || direction == 'x' || direction == 'y') {
72
+ return direction
73
+ }
74
+ let index = directions.indexOf(direction)
75
+ index = (index % 2 == 1) ? index - 1 : index + 1
76
+ return directions[index]
77
+ }
78
+ }
79
+ }
80
+ </script>
81
+
82
+ <style lang="less">
83
+ .page-toggle-enter-active{
84
+ position: absolute !important;
85
+ animation-duration: 0.8s !important;
86
+ width: calc(100%) !important;
87
+ }
88
+ .page-toggle-leave-active{
89
+ position: absolute !important;
90
+ animation-duration: 0.8s !important;
91
+ width: calc(100%) !important;
92
+ }
93
+ .page-toggle-enter{
94
+ }
95
+ .page-toggle-leave-to{
96
+ }
97
+ </style>
@@ -1,33 +1,33 @@
1
- // 此配置为系统默认设置,需修改的设置项,在src/config/config.js中添加修改项即可。也可直接在此文件中修改。
2
- module.exports = {
3
- lang: 'CN', // 语言,可选 CN(简体)、HK(繁体)、US(英语),也可扩展其它语言
4
- theme: { // 主题
5
- color: '#1890ff', // 主题色
6
- mode: 'dark', // 主题模式 可选 dark、 light 和 night
7
- success: '#52c41a', // 成功色
8
- warning: '#faad14', // 警告色
9
- error: '#f5222f' // 错误色
10
- },
11
- layout: 'side', // 导航布局,可选 side 和 head,分别为侧边导航和顶部导航
12
- fixedHeader: false, // 固定头部状态栏,true:固定,false:不固定
13
- fixedSideBar: true, // 固定侧边栏,true:固定,false:不固定
14
- fixedTabs: false, // 固定页签头,true:固定,false:不固定
15
- pageWidth: 'fixed', // 内容区域宽度,fixed:固定宽度,fluid:流式宽度
16
- weekMode: false, // 色弱模式,true:开启,false:不开启
17
- multiPage: true, // 多页签模式,true:开启,false:不开启
18
- cachePage: true, // 是否缓存页面数据,仅多页签模式下生效,true 缓存, false 不缓存
19
- hideSetting: false, // 隐藏设置抽屉,true:隐藏,false:不隐藏
20
- homePage: '/system/dictionaryManage', // 首页路由, 登陆后默认打开
21
- systemName: '物联网监控平台', // 系统名称
22
- copyright: '2021 Mr.Jiang', // copyright
23
- asyncRoutes: true, // 异步加载路由,true:开启,false:不开启
24
- showPageTitle: true, // 是否显示页面标题(PageLayout 布局中的页面标题),true:显示,false:不显示
25
- filterMenu: true, // 根据权限过滤菜单,true:过滤,false:不过滤
26
- animate: { // 动画设置
27
- disabled: true, // 禁用动画,true:禁用,false:启用
28
- name: 'lightSpeed', // 动画效果,支持的动画效果可参考 ./animate.config.js
29
- direction: 'left' // 动画方向,切换页面时动画的方向,参考 ./animate.config.js
30
- },
31
- footerLinks: [ // 页面底部链接,{link: '链接地址', name: '名称/显示文字', icon: '图标,支持 ant design vue 图标库'}
32
- ]
33
- }
1
+ // 此配置为系统默认设置,需修改的设置项,在src/config/config.js中添加修改项即可。也可直接在此文件中修改。
2
+ module.exports = {
3
+ lang: 'CN', // 语言,可选 CN(简体)、HK(繁体)、US(英语),也可扩展其它语言
4
+ theme: { // 主题
5
+ color: '#1890ff', // 主题色
6
+ mode: 'dark', // 主题模式 可选 dark、 light 和 night
7
+ success: '#52c41a', // 成功色
8
+ warning: '#faad14', // 警告色
9
+ error: '#f5222f' // 错误色
10
+ },
11
+ layout: 'side', // 导航布局,可选 side 和 head,分别为侧边导航和顶部导航
12
+ fixedHeader: false, // 固定头部状态栏,true:固定,false:不固定
13
+ fixedSideBar: true, // 固定侧边栏,true:固定,false:不固定
14
+ fixedTabs: false, // 固定页签头,true:固定,false:不固定
15
+ pageWidth: 'fixed', // 内容区域宽度,fixed:固定宽度,fluid:流式宽度
16
+ weekMode: false, // 色弱模式,true:开启,false:不开启
17
+ multiPage: true, // 多页签模式,true:开启,false:不开启
18
+ cachePage: true, // 是否缓存页面数据,仅多页签模式下生效,true 缓存, false 不缓存
19
+ hideSetting: false, // 隐藏设置抽屉,true:隐藏,false:不隐藏
20
+ homePage: '/system/dictionaryManage', // 首页路由, 登陆后默认打开
21
+ systemName: '物联网监控平台', // 系统名称
22
+ copyright: '2021 Mr.Jiang', // copyright
23
+ asyncRoutes: true, // 异步加载路由,true:开启,false:不开启
24
+ showPageTitle: true, // 是否显示页面标题(PageLayout 布局中的页面标题),true:显示,false:不显示
25
+ filterMenu: true, // 根据权限过滤菜单,true:过滤,false:不过滤
26
+ animate: { // 动画设置
27
+ disabled: true, // 禁用动画,true:禁用,false:启用
28
+ name: 'lightSpeed', // 动画效果,支持的动画效果可参考 ./animate.config.js
29
+ direction: 'left' // 动画方向,切换页面时动画的方向,参考 ./animate.config.js
30
+ },
31
+ footerLinks: [ // 页面底部链接,{link: '链接地址', name: '名称/显示文字', icon: '图标,支持 ant design vue 图标库'}
32
+ ]
33
+ }
@@ -1,42 +1,42 @@
1
- <template>
2
- <div class="common-layout">
3
- <div class="content"><slot></slot></div>
4
- <page-footer :link-list="footerLinks" :copyright="copyright"></page-footer>
5
- </div>
6
- </template>
7
-
8
- <script>
9
- import PageFooter from '@/layouts/footer/PageFooter'
10
- import { mapState } from 'vuex'
11
-
12
- export default {
13
- name: 'CommonLayout',
14
- components: { PageFooter },
15
- computed: {
16
- ...mapState('setting', ['footerLinks', 'copyright'])
17
- }
18
- }
19
- </script>
20
-
21
- <style scoped lang="less">
22
- .common-layout{
23
- display: flex;
24
- flex-direction: column;
25
- height: 100vh;
26
- overflow: auto;
27
- background-color: @layout-body-background;
28
- background-image: url('https://gw.alipayobjects.com/zos/rmsportal/TVYTbAXWheQpRcWDaDMu.svg');
29
- background-repeat: no-repeat;
30
- background-position-x: center;
31
- background-position-y: 110px;
32
- background-size: 100%;
33
- .content{
34
- padding: 32px 0;
35
- flex: 1;
36
- @media (min-width: 768px){
37
-
38
- padding: 112px 0 24px;
39
- }
40
- }
41
- }
42
- </style>
1
+ <template>
2
+ <div class="common-layout">
3
+ <div class="content"><slot></slot></div>
4
+ <page-footer :link-list="footerLinks" :copyright="copyright"></page-footer>
5
+ </div>
6
+ </template>
7
+
8
+ <script>
9
+ import PageFooter from '@vue2-client/layouts/footer/PageFooter'
10
+ import { mapState } from 'vuex'
11
+
12
+ export default {
13
+ name: 'CommonLayout',
14
+ components: { PageFooter },
15
+ computed: {
16
+ ...mapState('setting', ['footerLinks', 'copyright'])
17
+ }
18
+ }
19
+ </script>
20
+
21
+ <style scoped lang="less">
22
+ .common-layout{
23
+ display: flex;
24
+ flex-direction: column;
25
+ height: 100vh;
26
+ overflow: auto;
27
+ background-color: @layout-body-background;
28
+ background-image: url('https://gw.alipayobjects.com/zos/rmsportal/TVYTbAXWheQpRcWDaDMu.svg');
29
+ background-repeat: no-repeat;
30
+ background-position-x: center;
31
+ background-position-y: 110px;
32
+ background-size: 100%;
33
+ .content{
34
+ padding: 32px 0;
35
+ flex: 1;
36
+ @media (min-width: 768px){
37
+
38
+ padding: 112px 0 24px;
39
+ }
40
+ }
41
+ }
42
+ </style>
@@ -1,47 +1,47 @@
1
- <template>
2
- <div id="ComponentLayoutOne">
3
- <a-layout>
4
- <a-layout-sider v-bind="siderProps">
5
- <slot name="left"></slot>
6
- </a-layout-sider>
7
- <a-layout>
8
- <slot></slot>
9
- </a-layout>
10
- </a-layout>
11
- </div>
12
- </template>
13
-
14
- <script>
15
- export default {
16
- name: 'ComponentLayoutOne',
17
- props: {
18
- // Layout.Sider props对象
19
- siderProps: {
20
- type: Object,
21
- default: () => {
22
- return {}
23
- }
24
- }
25
- },
26
- data () {
27
- return {}
28
- },
29
- created () {
30
- },
31
- mounted () {
32
- },
33
- methods: {}
34
- }
35
- </script>
36
-
37
- <style lang="less">
38
- @import '~ant-design-vue/../../src/theme/index';
39
- #ComponentLayoutOne {
40
- .ant-layout-sider {
41
- .ant-layout-sider-zero-width-trigger {
42
- top: 50%;
43
- background-color: @shadow-color;
44
- }
45
- }
46
- }
47
- </style>
1
+ <template>
2
+ <div id="ComponentLayoutOne">
3
+ <a-layout>
4
+ <a-layout-sider v-bind="siderProps">
5
+ <slot name="left"></slot>
6
+ </a-layout-sider>
7
+ <a-layout>
8
+ <slot></slot>
9
+ </a-layout>
10
+ </a-layout>
11
+ </div>
12
+ </template>
13
+
14
+ <script>
15
+ export default {
16
+ name: 'ComponentLayoutOne',
17
+ props: {
18
+ // Layout.Sider props对象
19
+ siderProps: {
20
+ type: Object,
21
+ default: () => {
22
+ return {}
23
+ }
24
+ }
25
+ },
26
+ data () {
27
+ return {}
28
+ },
29
+ created () {
30
+ },
31
+ mounted () {
32
+ },
33
+ methods: {}
34
+ }
35
+ </script>
36
+
37
+ <style lang="less">
38
+ @import '~ant-design-vue/../../src/theme/index';
39
+ #ComponentLayoutOne {
40
+ .ant-layout-sider {
41
+ .ant-layout-sider-zero-width-trigger {
42
+ top: 50%;
43
+ background-color: @shadow-color;
44
+ }
45
+ }
46
+ }
47
+ </style>