@lambo-design/pro-layout 1.0.0-beta.47 → 1.0.0-beta.470

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 (41) hide show
  1. package/package.json +11 -4
  2. package/src/components/pro-layout-header/index.vue +224 -0
  3. package/src/components/pro-layout-header/pro-layout-logo/index.vue +206 -0
  4. package/src/components/pro-layout-header/pro-layout-nav/components/pro-layout-nav-slide-menu.vue +398 -0
  5. package/src/components/pro-layout-header/pro-layout-nav/index-slide.vue +226 -0
  6. package/src/components/pro-layout-header/pro-layout-nav/index.vue +564 -0
  7. package/src/components/pro-layout-header/pro-layout-slogan/index.vue +40 -0
  8. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-collect.vue +79 -0
  9. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-document.vue +116 -0
  10. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-fullscreen.vue +144 -0
  11. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-icons.vue +104 -0
  12. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-intl.vue +110 -0
  13. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-notice.vue +133 -0
  14. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-search.vue +305 -0
  15. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-todo.vue +145 -0
  16. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-quick-todoCenter.vue +177 -0
  17. package/src/components/pro-layout-header/pro-layout-tools/components/pro-layout-tools-user.vue +86 -0
  18. package/src/components/pro-layout-header/pro-layout-tools/index.vue +32 -0
  19. package/src/components/pro-layout-header/pro-layout-trigger/index.vue +84 -0
  20. package/src/components/{pro-layout-sider-collapsed-menu.vue → pro-layout-sider/components/pro-layout-sider-collapsed-menu.vue} +30 -11
  21. package/src/components/{pro-layout-sider-icon.vue → pro-layout-sider/components/pro-layout-sider-icon.vue} +2 -2
  22. package/src/components/pro-layout-sider/components/pro-layout-sider-menu-item.vue +137 -0
  23. package/src/components/pro-layout-sider/components/pro-layout-sider-other-menu.vue +140 -0
  24. package/src/components/pro-layout-sider/components/pro-layout-sider-search.vue +345 -0
  25. package/src/components/pro-layout-sider/index.vue +484 -0
  26. package/src/components/{pro-layout-tabs.vue → pro-layout-tabs/index.vue} +118 -23
  27. package/src/index.vue +309 -42
  28. package/src/styles/color.less +267 -0
  29. package/src/styles/images/xiaoxitongzhi.png +0 -0
  30. package/src/styles/other-menu.less +63 -111
  31. package/src/utils/menuItem.js +10 -0
  32. package/src/utils/sider.js +16 -1
  33. package/src/components/pro-layout-header.vue +0 -52
  34. package/src/components/pro-layout-logo.vue +0 -79
  35. package/src/components/pro-layout-nav.vue +0 -150
  36. package/src/components/pro-layout-other-menu.vue +0 -137
  37. package/src/components/pro-layout-sider-menu-item.vue +0 -37
  38. package/src/components/pro-layout-sider.vue +0 -240
  39. package/src/components/pro-layout-tools-user.vue +0 -84
  40. package/src/components/pro-layout-tools.vue +0 -21
  41. package/src/components/pro-layout-trigger.vue +0 -48
@@ -0,0 +1,305 @@
1
+ <template>
2
+ <div class="pro-layout-tools-quick-search">
3
+ <Tooltip :content="t('pro-layout.header.search-menu')" placement="bottom">
4
+ <Icon v-show="showSearchIcon" @click="handleIconClick" type="ios-search-outline" size="16" style="cursor: pointer" id="searchIcon"/>
5
+ </Tooltip>
6
+ <transition name="slide">
7
+ <div class="topInput" id="modalTopInput" v-show="showTopInput" @click="handleTopInput">
8
+ <Input v-model="searchTopText" clearable :placeholder="t('pro-layout.header.search-menu')" ref="topInput"
9
+ :border="false" style="width: 200px;" @on-clear="handleTopInput"
10
+ @on-change="handleTopInput" @on-blur="handleTopBlur">
11
+ <template #prefix>
12
+ <Icon type="ios-search" size="23"/>
13
+ </template>
14
+ </Input>
15
+ </div>
16
+ </transition>
17
+ <Modal v-model="searchTopModal" class="quick-search-fast-con-modal" footer-hide :closable="false" :mask="false" id="topModalId"
18
+ :styles="{top: '55px',width: '420px',float:'right'}">
19
+ <div v-if="spinShowTop">
20
+ <Spin size="large" v-if="spinShowTop" :show="spinShowTop">
21
+ <Icon type="ios-loading" size=18 class="demo-spin-icon-load"></Icon>
22
+ <div>{{ t('pro-layout.header.search-loading') }}</div>
23
+ </Spin>
24
+ </div>
25
+ <div v-else class="modal-content">
26
+ <Tabs value="menu" :animated="false" @on-click="tabLabel" style="width:100%;height:100%">
27
+ <TabPane :label="t('pro-layout.header.search-type-menu')" name="menu">
28
+ <div v-if="tab==='menu'">
29
+ <div v-for="(item,index) in menuData" :key="index">
30
+ <div class="menu-style" @click="handleMenuClick(item)">
31
+ <Icon :type="item.icon"/>
32
+ <span class="label-style">{{ item.label }}</span>
33
+ </div>
34
+ </div>
35
+ </div>
36
+ </TabPane>
37
+ <TabPane :label="t('pro-layout.header.search-type-notice')" name="notice">
38
+ <div v-if="tab==='notice'">
39
+ <div v-for="(item,index) in noticeData" :key="index">
40
+ <div class="menu-style" @click="handleNoticeClick(item)">
41
+ <Icon :type="item.icon"/>
42
+ <span class="label-style">{{ item.noticeTitle }}</span>
43
+ </div>
44
+ </div>
45
+ </div>
46
+ </TabPane>
47
+ <TabPane :label="t('pro-layout.header.search-type-message')" name="message">
48
+ <div v-if="tab==='message'">
49
+ <div v-for="(item,index) in messageData" :key="index">
50
+ <div class="menu-style" @click="handleMessageClick(item)">
51
+ <Icon :type="item.icon"/>
52
+ <span class="label-style">{{ item.noticeTitle }}</span>
53
+ </div>
54
+ </div>
55
+ </div>
56
+ </TabPane>
57
+ </Tabs>
58
+
59
+ <Row type="flex" align="middle" justify="center" class="more" >
60
+ <Col><a @click="searchMore">{{ t('pro-layout.header.search-more') }}</a></Col>
61
+ </Row>
62
+ <div v-if="menuData.length === 0">
63
+ <span class="no-result">{{ t('pro-layout.header.search-no-data') }}</span>
64
+ </div>
65
+ </div>
66
+ </Modal>
67
+ </div>
68
+ </template>
69
+
70
+ <script>
71
+ import Bus from '@lambo-design/shared/utils/bus'
72
+ import {arraysEqual, getAllElements, getSessionStorage} from '@lambo-design/shared/utils/platform'
73
+ import { mapActions } from 'vuex'
74
+ import generatorMenuList from "@lambo-design/shared/utils/menu";
75
+ import Locale from "@lambo-design/core/src/mixins/locale";
76
+
77
+ export default {
78
+ name: 'pro-layout-tools-quick-search',
79
+ mixins: [Locale],
80
+ data() {
81
+ return {
82
+ menuList: [],
83
+ showSearchIcon:true,
84
+ searchTopModal:false,
85
+ searchTopText:'',
86
+ showTopInput:false,
87
+ spinShowTop:false,
88
+ menuData:[],
89
+ tab:'menu',
90
+ noticeData:[],
91
+ messageData:[],
92
+ perSearchMap:new Map(),
93
+ originalAllMenuList:[]
94
+ }
95
+ },
96
+ watch:{
97
+ searchTopText(keyword){
98
+ if (this.tab === 'notice'){
99
+ this.perSearchMap.set('notice',keyword)
100
+ Bus.$emit('change-search-keyword',keyword,this.tab)
101
+ }else if (this.tab === 'message'){
102
+ Bus.$emit('change-search-keyword',keyword,this.tab)
103
+ this.perSearchMap.set('message',keyword)
104
+ }
105
+ },
106
+ tab(val){
107
+ if (val === 'notice' && this.perSearchMap.get('notice') !== this.searchTopText){
108
+ this.perSearchMap.set('notice',this.searchTopText)
109
+ Bus.$emit('change-search-tab',this.searchTopText,val)
110
+ }else if (val === 'message' && this.perSearchMap.get('message') !== this.searchTopText){
111
+ Bus.$emit('change-search-tab',this.searchTopText,val)
112
+ this.perSearchMap.set('message',this.searchTopText)
113
+ }
114
+ }
115
+ },
116
+ methods: {
117
+ ...mapActions([
118
+ 'getNoticeListData'
119
+ ]),
120
+ initListener() {
121
+ Bus.$on('other-datas',(data)=>{
122
+ this.initNoticeAndMessage(data)
123
+ });
124
+ Bus.$on('origin-all-menu-list',(data)=>{
125
+ this.initCanSearchMenu(data)
126
+ })
127
+ },
128
+ destroyListener() {
129
+ Bus.$off('other-datas')
130
+ Bus.$off('origin-all-menu-list')
131
+ },
132
+ initNoticeAndMessage(data){
133
+ if (data){
134
+ if(data.noticeList && data.noticeList.length > 0){
135
+ this.noticeData = data.noticeList
136
+ }
137
+ if (data.messageList && data.messageList.length > 0){
138
+ this.messageData = data.messageList
139
+ }
140
+ }
141
+ },
142
+ initCanSearchMenu(data){
143
+ if (arraysEqual(this.originalAllMenuList, data)) {
144
+ return;
145
+ }
146
+ let appList = getSessionStorage('appList')
147
+ let appIds = '';
148
+ let appIdList = [];
149
+ if (appList && appList.length > 0) {
150
+ for(let app of appList) {
151
+ appIdList.push(app.appId);
152
+ }
153
+ appIds = appIdList.join(",");
154
+ }
155
+ let treeMenuList = generatorMenuList(data,appIds,'menu');
156
+ let result = []
157
+ getAllElements(treeMenuList,result)
158
+ this.originalAllMenuList = data;
159
+ this.menuList = data.filter(menuItem => menuItem.type == '2' && menuItem.permissionId && result.includes(menuItem.permissionId))
160
+ },
161
+ filterMenu(){
162
+ if (this.searchTopText){
163
+ const regex = new RegExp(this.searchTopText, "i");
164
+ this.menuData = this.menuList.filter(menuItem => {
165
+ return menuItem.label.match(regex) && menuItem.type === 2;
166
+ });
167
+ return
168
+ }
169
+ },
170
+ async handleTopInput(){
171
+ this.searchTopModal = true
172
+ this.spinShowTop = true
173
+ if (this.tab === 'menu'){
174
+ this.filterMenu()
175
+ }
176
+ this.spinShowTop = false
177
+ },
178
+ handleTopBlur(){
179
+ this.searchTopModal = false
180
+ this.showTopInput = false
181
+ this.showSearchIcon = true
182
+ },
183
+ handleIconClick(){
184
+ this.showTopInput = true
185
+ this.showSearchIcon = false
186
+ this.searchTopModal = true
187
+ },
188
+ handleOutsideClick(event) {
189
+ if(document.getElementById("topModalId") && !document.getElementById("topModalId").contains(event.target)
190
+ && document.getElementById("modalTopInput") && !document.getElementById("modalTopInput").contains(event.target)
191
+ && document.getElementById("searchIcon") && !document.getElementById("searchIcon").contains(event.target)){
192
+ let clearButton = event.target.closest(".ivu-icon-ios-close-circle");
193
+ if (event.target.parentNode) {
194
+ if(clearButton){
195
+ this.searchTopModal = true;
196
+ this.showTopInput = true;
197
+ this.showSearchIcon = false;
198
+ } else {
199
+ setTimeout(() => {
200
+ this.searchTopModal = false;
201
+ this.showTopInput = false;
202
+ this.showSearchIcon = true
203
+ }, 525);
204
+ }
205
+ }
206
+ }
207
+ },
208
+ handleMenuClick(item){
209
+ Bus.$emit('select-menu',item.name,item)
210
+ },
211
+ handleNoticeClick(item){
212
+ Bus.$emit('other-operate','select-notice',item.noticeId)
213
+ },
214
+ handleMessageClick(item){
215
+ Bus.$emit('other-operate','select-message',item.noticeId)
216
+ },
217
+ searchMore(){
218
+ this.searchTopModal = false
219
+ this.showTopInput = false
220
+ this.showSearchIcon = true
221
+ Bus.$emit('other-operate','search-more',this.searchTopText)
222
+ },
223
+ async tabLabel(e){
224
+ this.tab = e
225
+ if (e === 'menu') {
226
+ this.filterMenu()
227
+ }
228
+ },
229
+ },
230
+ created() {
231
+ this.initListener()
232
+ },
233
+ mounted() {
234
+ window.addEventListener("click", this.handleOutsideClick);
235
+ },
236
+ beforeDestroy() {
237
+ this.destroyListener()
238
+ window.removeEventListener("click", this.handleOutsideClick);
239
+ }
240
+ }
241
+ </script>
242
+ <style lang="less" scoped>
243
+ .pro-layout-tools-quick-search{
244
+ .topInput{
245
+ float: right;
246
+ position: relative;
247
+ z-index: 1000;
248
+ margin-top: 0px;
249
+ margin-left: 10px;
250
+ }
251
+ .slide-enter-active,
252
+ .slide-leave-active{
253
+ transition: transform 0.5s;
254
+ }
255
+ .slide-enter{
256
+ transform: translateX(100%);
257
+ }
258
+ .slide-leave-to{
259
+ transform: translateX(175px);
260
+ }
261
+ }
262
+ </style>
263
+ <style lang="less">
264
+ @import '@lambo-design/core/src/styles/default.less';
265
+ .quick-search-fast-con-modal {
266
+ .ivu-modal-body{
267
+ position: relative;
268
+ padding: 16px 16px 40px 16px;
269
+ font-size: var(--font-size-base, 14px);
270
+ line-height: 1.5;
271
+ }
272
+ .modal-content {
273
+ height: 300px;
274
+ overflow-x: hidden;
275
+ overflow-y: auto;
276
+ -ms-overflow-style: none; /* Internet Explorer 10+ */
277
+ scrollbar-width: none; /* Firefox */
278
+ &::-webkit-scrollbar {
279
+ display: none; /* Chrome, Safari 和 Opera */
280
+ }
281
+ .menu-style {
282
+ margin : 5px;
283
+ font-size : 16px;
284
+ display : inline-block;
285
+ cursor : pointer;
286
+ &:hover{
287
+ color: var(--primary-color,@_primary-color);
288
+ }
289
+ }
290
+ .label-style {
291
+ height : 13px;
292
+ font-size : 14px;
293
+ font-weight : 500;
294
+ margin-left : 5px;
295
+ line-height : 18px;
296
+ }
297
+ }
298
+ }
299
+ .more{
300
+ position: absolute;
301
+ bottom: 0;
302
+ width: 100%;
303
+ padding: 10px 0;
304
+ }
305
+ </style>
@@ -0,0 +1,145 @@
1
+ <template>
2
+ <div class="pro-layout-tools-quick-todo">
3
+ <Dropdown >
4
+ <Badge :count="todoDatas.length" class-name="badge-count">
5
+ <Icon type="ios-alarm-outline" size="18" style="cursor: pointer"/>
6
+ </Badge>
7
+ <template #list>
8
+ <DropdownMenu slot="list" class="todo-dropdown-menu">
9
+ <DropdownItem v-for="(item, index) in displayedTodos" :key="index" class="dropdown-item" @click.native="getDetail(item)" >
10
+ <div class="item-title" :title="item.procName">
11
+ {{ item.procName }}
12
+ </div>
13
+ <div class="item-time">
14
+ {{ formatTimestamp(item.createTime,'YYYY-MM-DD HH:mm:ss') }}
15
+ </div>
16
+ <div class="item-des">
17
+ {{ item.busKeyDes }}
18
+ </div>
19
+ </DropdownItem>
20
+ <div class="dropdown-footer" :class="[todoDatas.length == 0 ? 'no-line' : '']">
21
+ <Button type="text" v-if="todoDatas.length > 0" @click="getMore" >{{ t('pro-layout.header.todo-more') }}</Button>
22
+ <div class="no-data" v-if="todoDatas.length == 0" >{{ t('pro-layout.header.todo-no-data') }}</div>
23
+ </div>
24
+ </DropdownMenu>
25
+ </template>
26
+ </Dropdown>
27
+ </div>
28
+ </template>
29
+
30
+ <script>
31
+ import Bus from '@lambo-design/shared/utils/bus';
32
+ import {deepCopy} from '@lambo-design/shared/utils/assist';
33
+ import {formatTimestamp} from '@lambo-design/shared/utils/date'
34
+ import Locale from "@lambo-design/core/src/mixins/locale";
35
+
36
+ export default {
37
+ name: "pro-layout-tools-quick-todo",
38
+ mixins: [Locale],
39
+ data() {
40
+ return {
41
+ formatTimestamp: formatTimestamp,
42
+ todoDatas:[],
43
+ displayedTodos:[]
44
+ }
45
+ },
46
+ methods: {
47
+ initListener() {
48
+ Bus.$on('other-datas',(data) => {
49
+ this.initTodoList(data);
50
+ })
51
+ },
52
+ destroyListener() {
53
+ Bus.$off('other-datas')
54
+ },
55
+ initTodoList(data) {
56
+ if (data && data.todoDatas) {
57
+ this.todoDatas = deepCopy(data.todoDatas);
58
+ this.displayedTodos = this.todoDatas.slice(0, 10);
59
+ }
60
+ },
61
+ getDetail(item){
62
+ Bus.$emit('other-operate','todo-detail',item)
63
+ },
64
+ getMore() {
65
+ Bus.$emit('other-operate','todo-more')
66
+ }
67
+ },
68
+ created() {
69
+ this.initListener()
70
+ },
71
+ beforeDestroy() {
72
+ this.destroyListener()
73
+ }
74
+ }
75
+ </script>
76
+
77
+ <style lang="less">
78
+ @import "@lambo-design/core/src/styles/default";
79
+ .pro-layout-tools-quick-todo{
80
+ .badge-count{
81
+ top:12px;
82
+ height: 10px;
83
+ line-height: 8px;
84
+ min-width: 8px;
85
+ padding: 0;
86
+ font-size: 8px;
87
+ width: 10px;
88
+ }
89
+ }
90
+ .todo-dropdown-menu {
91
+ max-height: 300px;
92
+ width: 300px;
93
+ overflow-y: auto;
94
+ &::-webkit-scrollbar {
95
+ width: 0;
96
+ height: 0;
97
+ }
98
+ .dropdown-item {
99
+ overflow: hidden;
100
+ padding: 8px;
101
+ display: flex;
102
+ flex-wrap: wrap;
103
+ align-items: flex-start;
104
+ .item-title{
105
+ font-family: "黑体", Arial, sans-serif;
106
+ margin-left: 5px;
107
+ flex: 1 0 auto;
108
+ width: 100%;
109
+ margin-right: auto;
110
+ white-space:nowrap;
111
+ overflow:hidden;
112
+ text-overflow: ellipsis;
113
+ }
114
+ .item-time{
115
+ font-family: "黑体", Arial, sans-serif;
116
+ font-weight: normal;
117
+ flex: 0 0 auto;
118
+ margin-top: 3px;
119
+ margin-left: auto;
120
+ color: #808695;
121
+ }
122
+ .item-des{
123
+ flex: 1 0 80%;
124
+ height: auto;
125
+ margin: 3px 20px 0;
126
+ font-size: 12px;
127
+ color: #808695;
128
+ white-space: normal;
129
+ word-wrap: break-word;
130
+ }
131
+ }
132
+ .dropdown-footer{
133
+ line-height: 24px;
134
+ border-top: 1px solid var(--layout-sider-line-color,@_layout-sider-line-color);
135
+ padding: 8px;
136
+ text-align: center;
137
+ &.no-line{
138
+ border: 0;
139
+ }
140
+ .no-data{
141
+ text-align: center;
142
+ }
143
+ }
144
+ }
145
+ </style>
@@ -0,0 +1,177 @@
1
+ <template>
2
+ <div class="pro-layout-tools-quick-todo">
3
+ <Dropdown>
4
+ <Badge :count="todoCenterDatas.length" class-name="badge-count">
5
+ <Icon type="ios-list-box-outline" size="18" style="cursor: pointer"/>
6
+ </Badge>
7
+ <template #list>
8
+ <DropdownMenu slot="list" class="todo-dropdown-menu">
9
+ <!-- 滚动区域 -->
10
+ <div class="todo-list-scroll">
11
+ <DropdownItem v-for="(item, index) in displayedTodos" :key="index" class="dropdown-item" @click.native="getDetail(item)">
12
+ <div class="item-title" :title="item.taskTitle">
13
+ {{ item.taskTitle }}
14
+ </div>
15
+ <div class="item-time">
16
+ {{ formatTimestamp(item.taskInitTime,'YYYY-MM-DD HH:mm:ss') }}
17
+ </div>
18
+ </DropdownItem>
19
+ </div>
20
+ <!-- 固定的底部区域 -->
21
+ <div class="dropdown-footer" :class="[todoCenterDatas.length == 0 ? 'no-line' : '']">
22
+ <Button type="text" v-if="todoCenterDatas.length > 0" @click="getMore">{{ t('pro-layout.header.todo-more') }}</Button>
23
+ <div class="no-data" v-if="todoCenterDatas.length == 0">{{ t('pro-layout.header.todo-no-data') }}</div>
24
+ </div>
25
+ </DropdownMenu>
26
+ </template>
27
+ </Dropdown>
28
+ </div>
29
+ </template>
30
+
31
+ <script>
32
+ import Bus from '@lambo-design/shared/utils/bus';
33
+ import {deepCopy} from '@lambo-design/shared/utils/assist';
34
+ import {formatTimestamp} from '@lambo-design/shared/utils/date'
35
+ import Locale from "@lambo-design/core/src/mixins/locale";
36
+
37
+ export default {
38
+ name: "pro-layout-tools-quick-todo",
39
+ mixins: [Locale],
40
+ data() {
41
+ return {
42
+ formatTimestamp: formatTimestamp,
43
+ todoCenterDatas:[],
44
+ displayedTodos:[]
45
+ }
46
+ },
47
+ methods: {
48
+ initListener() {
49
+ Bus.$on('other-datas',(data) => {
50
+ this.initTodoList(data);
51
+ })
52
+ },
53
+ destroyListener() {
54
+ Bus.$off('other-datas')
55
+ },
56
+ initTodoList(data) {
57
+ if (data && data.todoCenterDatas) {
58
+ this.todoCenterDatas = deepCopy(data.todoCenterDatas);
59
+ this.displayedTodos = this.todoCenterDatas.slice(0, 10);
60
+ }
61
+ },
62
+ getDetail(item){
63
+ Bus.$emit('other-operate','todoCenter-detail',item)
64
+ },
65
+ getMore() {
66
+ Bus.$emit('other-operate','todoCenter-more')
67
+ }
68
+ },
69
+ created() {
70
+ this.initListener()
71
+ },
72
+ beforeDestroy() {
73
+ this.destroyListener()
74
+ }
75
+ }
76
+ </script>
77
+
78
+ <style lang="less">
79
+ @import "@lambo-design/core/src/styles/default";
80
+ .pro-layout-tools-quick-todo{
81
+ .badge-count{
82
+ top:12px;
83
+ height: 10px;
84
+ line-height: 8px;
85
+ min-width: 8px;
86
+ padding: 0;
87
+ font-size: 8px;
88
+ width: 10px;
89
+ }
90
+ }
91
+ .todo-dropdown-menu {
92
+ width: 300px;
93
+ display: flex;
94
+ flex-direction: column;
95
+ max-height: 300px;
96
+ padding: 0;
97
+
98
+ // 滚动区域
99
+ .todo-list-scroll {
100
+ flex: 1;
101
+ overflow-y: auto;
102
+ max-height: 260px; // 根据实际需要调整,留出底部footer的空间
103
+
104
+ &::-webkit-scrollbar {
105
+ width: 4px;
106
+ height: 0;
107
+ }
108
+
109
+ &::-webkit-scrollbar-thumb {
110
+ background-color: #c1c1c1;
111
+ border-radius: 2px;
112
+ }
113
+
114
+ .dropdown-item {
115
+ overflow: hidden;
116
+ padding: 8px;
117
+ display: flex;
118
+ flex-wrap: wrap;
119
+ align-items: flex-start;
120
+ cursor: pointer;
121
+
122
+ &:hover {
123
+ background-color: #f5f5f5;
124
+ }
125
+
126
+ .item-title {
127
+ font-family: "黑体", Arial, sans-serif;
128
+ margin-left: 5px;
129
+ flex: 1 0 auto;
130
+ width: 100%;
131
+ margin-right: auto;
132
+ white-space: nowrap;
133
+ overflow: hidden;
134
+ text-overflow: ellipsis;
135
+ }
136
+
137
+ .item-time {
138
+ font-family: "黑体", Arial, sans-serif;
139
+ font-weight: normal;
140
+ flex: 0 0 auto;
141
+ margin-top: 3px;
142
+ margin-left: auto;
143
+ color: #808695;
144
+ font-size: 12px;
145
+ }
146
+
147
+ .item-des {
148
+ flex: 1 0 80%;
149
+ height: auto;
150
+ margin: 3px 20px 0;
151
+ font-size: 12px;
152
+ color: #808695;
153
+ white-space: normal;
154
+ word-wrap: break-word;
155
+ }
156
+ }
157
+ }
158
+
159
+ // 固定的底部
160
+ .dropdown-footer {
161
+ flex-shrink: 0;
162
+ line-height: 24px;
163
+ border-top: 1px solid var(--layout-sider-line-color, @_layout-sider-line-color);
164
+ padding: 8px;
165
+ text-align: center;
166
+ background-color: #fff;
167
+
168
+ &.no-line {
169
+ border-top: 0;
170
+ }
171
+
172
+ .no-data {
173
+ text-align: center;
174
+ }
175
+ }
176
+ }
177
+ </style>