bri-components 1.2.50 → 1.2.51

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 (39) hide show
  1. package/package.json +1 -1
  2. package/src/components/controls/BriControlInput.vue +9 -6
  3. package/src/components/controls/base/DshDate/DshDate.vue +1 -1
  4. package/src/components/controls/base/DshDate/DshDaterange.vue +55 -99
  5. package/src/components/controls/base/DshEditor.vue +1 -1
  6. package/src/components/controls/base/DshInput/DshInput.vue +1 -3
  7. package/src/components/controls/base/DshNumber/DshNumber.vue +2 -43
  8. package/src/components/controls/base/DshNumber/DshNumberange.vue +9 -9
  9. package/src/components/controls/base/DshSelect/selectMixin.js +1 -3
  10. package/src/components/controls/base/DshSwitch/DshSwitch.vue +0 -5
  11. package/src/components/controls/base/DshSwitch/switchMixin.js +4 -4
  12. package/src/components/controls/controlMixin.js +6 -2
  13. package/src/components/controls/special/DshBack.vue +1 -1
  14. package/src/components/controls/special/DshUndeveloped.vue +1 -1
  15. package/src/components/form/DshDefaultSearch.vue +43 -81
  16. package/src/components/unit/DshFormUnit.vue +11 -10
  17. package/src/styles/components/controls/base/DshInput.less +0 -16
  18. package/src/styles/index.less +5 -3
  19. package/src/styles/reset-iview-controls.less +104 -0
  20. package/src/styles/{reset-iview.less → reset-iview-variables.less} +1 -47
  21. package/src/abolish/BriTransfer.less +0 -65
  22. package/src/abolish/BriTransfer.vue +0 -71
  23. package/src/abolish/BriTree.less +0 -57
  24. package/src/abolish/DshCascaders.less +0 -11
  25. package/src/abolish/DshCascaders.vue +0 -151
  26. package/src/abolish/DshCrumbs.less +0 -0
  27. package/src/abolish/DshCrumbs.vue +0 -62
  28. package/src/abolish/DshCrumbsItem.vue +0 -109
  29. package/src/abolish/DshEditPanel.less +0 -70
  30. package/src/abolish/DshEditPanel.vue +0 -152
  31. package/src/abolish/DshFileShow.less +0 -61
  32. package/src/abolish/DshFileShow.vue +0 -0
  33. package/src/abolish/DshFlatTable.less +0 -93
  34. package/src/abolish/DshFlatTable.vue +0 -605
  35. package/src/abolish/DshMenu.less +0 -37
  36. package/src/abolish/DshMenu.vue +0 -133
  37. package/src/abolish/DshTexts.less +0 -13
  38. package/src/abolish/DshTexts.vue +0 -89
  39. /package/src/{abolish/DshCrumbItem.less → styles/reset-iview-other.less} +0 -0
@@ -1,10 +1,5 @@
1
1
  <template>
2
- <div
3
- class="DshDefaultSearch"
4
- :style="{
5
- 'margin-bottom': canUseFold ? '20px' : undefined
6
- }"
7
- >
2
+ <div class="DshDefaultSearch">
8
3
  <!-- 筛选表单 -->
9
4
  <div
10
5
  class="DshDefaultSearch-form"
@@ -15,34 +10,34 @@
15
10
  >
16
11
  <Row :gutter="10">
17
12
  <template v-for="conditionItem in conditionList">
18
- <Col
13
+ <i-col
19
14
  :key="conditionItem._id"
20
15
  :span="conditionItem.formItem._span"
21
16
  >
22
- <dsh-form-unit
23
- :key="conditionItem._id"
24
- class="item"
25
- :formData="conditionItem"
26
- :formItem="conditionItem.formItem"
27
- height="46"
28
- :labelStyle="labelStyle"
29
- :rowStyle="rowStyle"
30
- @change="change(conditionItem, arguments)"
31
- >
32
- <span
33
- slot="label"
34
- class="item-name"
17
+ <dsh-form-unit
18
+ :key="conditionItem._id"
19
+ class="DshDefaultSearch-form-item"
20
+ :formData="conditionItem"
21
+ :formItem="conditionItem.formItem"
22
+ height="46"
23
+ :labelStyle="labelStyle"
24
+ :rowStyle="rowStyle"
25
+ @change="change(conditionItem, arguments)"
35
26
  >
36
- {{ conditionItem.formItem._name }}
37
- </span>
38
- </dsh-form-unit>
39
- </Col>
27
+ <span
28
+ slot="label"
29
+ class="DshDefaultSearch-form-item-name"
30
+ >
31
+ {{ conditionItem.formItem._name }}
32
+ </span>
33
+ </dsh-form-unit>
34
+ </i-col>
40
35
 
41
36
  <!-- 换行 -->
42
37
  <div
43
38
  v-if="conditionItem.formItem._wrap"
44
39
  :key="conditionItem._id + '_wrap'"
45
- style="width:100%"
40
+ style="width: 100%"
46
41
  ></div>
47
42
  </template>
48
43
  </Row>
@@ -55,8 +50,8 @@
55
50
  >
56
51
  <Icon
57
52
  :class="[
58
- 'icon',
59
- isSpreadStatus ? 'icon-arrow-up' : 'icon-arrow-down'
53
+ 'DshDefaultSearch-fold-icon',
54
+ `DshDefaultSearch-fold-icon-${isSpreadStatus ? 'up' : 'down'}`
60
55
  ]"
61
56
  custom="bico-font bico-shuangjiantou"
62
57
  @click="toggleSpreadStatus"
@@ -98,16 +93,16 @@
98
93
  width: "calc(100% - 12px)"
99
94
  },
100
95
  labelStyle: {
101
- textAlign: "center",
96
+ width: this.labelWidth + "px",
97
+ height: "32px",
102
98
  margin: 0,
103
- color: "#666666",
104
- border: "1px solid rgba(229, 229, 229, 1)",
105
- background: "rgba(245, 245, 245, 1)",
106
99
  padding: "5px 10px",
100
+ border: "1px solid rgba(229, 229, 229, 1)",
107
101
  borderRight: "none",
108
- height: "32px",
102
+ backgroundColor: "rgba(245, 245, 245, 1)",
109
103
  boxSizing: "border-box",
110
- width: this.labelWidth + "px"
104
+ textAlign: "center",
105
+ color: "#666666"
111
106
  }
112
107
  };
113
108
  },
@@ -140,7 +135,7 @@
140
135
  },
141
136
  // 判断是否符合折叠情形,showRowNum为null时候不使用展开/收合,为0时候就是一行不露出来
142
137
  canUseFold () {
143
- return this.showRowNum == null
138
+ return this.showRowNum == undefined
144
139
  ? false
145
140
  : this.allRowNum > this.showRowNum;
146
141
  }
@@ -164,7 +159,7 @@
164
159
  getFormItem (formItem) {
165
160
  return {
166
161
  ...this.formatFormItem(formItem),
167
- isOnDftSearch: true,
162
+ onDftSearch: true,
168
163
 
169
164
  _line: true,
170
165
  _useColor: false,
@@ -199,48 +194,40 @@
199
194
 
200
195
  <style lang="less" scoped>
201
196
  .DshDefaultSearch {
202
- position: relative;
203
197
  background: #fff;
198
+ .dsh-flex-col-start-stretch();
204
199
 
205
200
  &-form {
206
- position: relative;
207
201
  z-index: 2;
208
202
 
209
- .item {
210
- padding: 0 !important;
211
- padding-bottom: 6px !important;
212
- padding-top: 6px !important;
213
- margin-top: 0px !important;
214
- margin-bottom: 0px !important;
203
+ &-item {
204
+ padding: 6px 0px;
205
+ margin-top: 0px;
206
+ margin-bottom: 0px;
215
207
 
216
208
  &-name {}
217
209
  }
218
210
  }
219
211
 
220
- //展开图标
221
212
  &-fold {
222
- width: 100%;
223
213
  text-align: center;
224
- position: absolute;
225
- bottom: -24px;
226
- left: 0px;
227
214
 
228
- .icon {
215
+ &-icon {
229
216
  width: 48px;
230
217
  height: 20px;
231
- text-align: center;
232
- line-height: 20px;
233
218
  background: #fff;
234
219
  box-shadow: 0 0 16px 0 rgba(51, 51, 51, 0.1);
220
+ text-align: center;
221
+ line-height: 20px;
235
222
  font-size: 14px;
236
223
  color: #999999;
237
224
  cursor: pointer;
238
225
 
239
- &-arrow-up {
226
+ &-up {
240
227
  transform: rotate(180deg);
241
228
  }
242
229
 
243
- &-arrow-down {
230
+ &-down {
244
231
 
245
232
  }
246
233
  }
@@ -249,37 +236,12 @@
249
236
  </style>
250
237
  <style lang="less">
251
238
  .DshDefaultSearch {
252
- // 输入框/下拉框
253
239
  input,
254
240
  .ivu-select-selection,
255
- .ivu-cascader-size-default,
256
- .DshCascader-multiple-input,
241
+ .ivu-input-number,
242
+ .BriControlInput,
257
243
  .DshDaterange-item {
258
- border-radius: 0;
259
-
260
- .ivu-select-input {
261
- top: 0px!important;
262
- }
263
- }
264
-
265
- .DshCascader-multiple-input {
266
- height: 32px;
267
- padding: 1px 6px;
268
- overflow: hidden!important;
269
- }
270
-
271
- .DshFormUnit-label {
272
- width: 80px;
273
- margin-right: 16px;
274
- text-align: right;
275
-
276
- &-right {
277
- text-align: left;
278
- }
279
-
280
- &-name {
281
- font-family: "Microsoft YaHei";
282
- }
244
+ border-radius: 0px!important;
283
245
  }
284
246
  }
285
247
  </style>
@@ -59,12 +59,13 @@
59
59
  >
60
60
  <slot name="extra">
61
61
  <bri-tooltip
62
+ v-if="formItem._description"
62
63
  :content="formItem._description"
63
64
  transfer
64
65
  style="height: 14px;"
65
66
  >
66
- <span class="DshFormUnit-label-description dsh-ellipsis">
67
- {{ formItem._description && `* ${formItem._description}` }}
67
+ <span class="DshFormUnit-label-description">
68
+ {{ `* ${formItem._description}` }}
68
69
  </span>
69
70
  </bri-tooltip>
70
71
  </slot>
@@ -161,8 +162,8 @@
161
162
 
162
163
  <style lang="less" scoped>
163
164
  .DshFormUnit {
164
- margin: 3px 6px;
165
- padding: 2px 10px 8px;
165
+ margin: 3px 6px; // 不可轻易改margin的左右值,上面style的width根据他calc
166
+ padding: 0px 10px 10px;
166
167
 
167
168
  &-label {
168
169
  min-width: 0px;
@@ -202,6 +203,7 @@
202
203
  }
203
204
 
204
205
  &-description {
206
+ .dsh-ellipsis();
205
207
  color: #60c0ec;
206
208
  }
207
209
  }
@@ -217,7 +219,6 @@
217
219
 
218
220
  .DshFormUnit-label {
219
221
  max-width: 280px;
220
- // min-width: 100px;
221
222
  font-size: @textSize;
222
223
  overflow: hidden;
223
224
  margin: 0px;
@@ -251,17 +252,17 @@
251
252
 
252
253
  &-required {
253
254
  .DshFormUnit-label-name:before {
255
+ position: absolute;
256
+ left: -10px;
257
+
254
258
  content: '*';
255
259
  display: inline-block;
260
+ width: 6px;
256
261
  line-height: 1.5;
257
262
  font-family: SimSun;
258
- font-size: @smallTitleSize;
259
263
  font-weight: 500;
260
- color: #E94829;
261
- position: absolute;
262
- left: -10px;
263
- width: 6px;
264
264
  font-size: @textSize;
265
+ color: #E94829;
265
266
  }
266
267
  }
267
268
  }
@@ -10,20 +10,4 @@
10
10
  min-height: 32px;
11
11
  }
12
12
  }
13
- }
14
-
15
- .ivu-input {
16
- .bri-control-edit();
17
- cursor: text;
18
-
19
- &[disabled] {
20
- .bri-control-disabled();
21
- &:hover {
22
- border-color: @border-disabled;
23
- }
24
- &::-webkit-input-placeholder {
25
- color: @placeholder-disabled-color;
26
- }
27
- }
28
-
29
13
  }
@@ -1,10 +1,12 @@
1
1
  @import "~vue-easytable/packages/theme-default/index.less"; // 引入官方提供的less样式入口文件
2
2
  @import "~view-design/src/styles/index.less"; // 第三方组件库样式
3
+
3
4
  @import "./reset-easytable.less"; // 重置easytable样式
4
- @import "./reset-iview.less"; // 重置iview样式
5
+ @import "./reset-iview-variables.less"; // 重置iview样式-变量
6
+ @import "./reset-iview-controls.less"; // 重置iview样式-控件相关
7
+ @import "./reset-iview-other.less"; // 重置iview样式-其它
5
8
  @import "./reset.less"; // 重置样式
6
-
7
9
  // @import "./global/global.less"; // 全局公共css
8
- @import "./iconfont/iconfont.css"; // 字体图标样式
9
10
 
11
+ @import "./iconfont/iconfont.css"; // 字体图标样式
10
12
  @import "./components/index.less"; // 组件样式
@@ -0,0 +1,104 @@
1
+ .ivu-input {
2
+ .bri-control-edit();
3
+ cursor: text;
4
+
5
+ &[disabled] {
6
+ .bri-control-disabled();
7
+ &:hover {
8
+ border-color: @border-disabled;
9
+ }
10
+ &::-webkit-input-placeholder {
11
+ color: @placeholder-disabled-color;
12
+ }
13
+ }
14
+
15
+ }
16
+
17
+ .ivu-input-number {
18
+ width: 100%;
19
+
20
+ .ivu-input-number-input {
21
+ color: @textColor;
22
+ }
23
+
24
+ &-disabled {
25
+ .ivu-input-number-input {
26
+ opacity: 1;
27
+ background: @inputBg-disabled;
28
+ color: @textColor;
29
+ &::-webkit-input-placeholder {
30
+ color: @placeholder-disabled-color;
31
+ }
32
+ }
33
+ }
34
+
35
+ &-handler {
36
+ &-wrap {
37
+ border-left: none;
38
+ }
39
+
40
+ &-down {
41
+ border: none;
42
+ }
43
+
44
+ &-down-inner,
45
+ &-up-inner {
46
+ color: @contentColor;
47
+ }
48
+
49
+ &:hover {
50
+ background-color: @hoverBg;
51
+
52
+ .ivu-input-number-handler-down-inner,
53
+ .ivu-input-number-handler-up-inner {
54
+ color: @textColor;
55
+ }
56
+ }
57
+ }
58
+ }
59
+
60
+ .ivu-select {
61
+ .ivu-select-selection {
62
+
63
+ }
64
+
65
+ &-disabled {
66
+ .ivu-select-selection {
67
+ .bri-control-disabled();
68
+
69
+ &:hover {
70
+ border-color: @border-disabled;
71
+ }
72
+ }
73
+
74
+ .ivu-select-input[disabled] {
75
+ color: @textColor;
76
+ -webkit-text-fill-color: @placeholder-disabled-color;
77
+ }
78
+ }
79
+
80
+ &-item {
81
+ margin: 4px 8px;
82
+ border-radius: @borderRadius;
83
+
84
+ &:hover {
85
+ background: @bgColor;
86
+ }
87
+
88
+ &-selected {
89
+ background-color: @theme-focus;
90
+ color: @themeColor;
91
+ }
92
+
93
+ &-disabled {
94
+ .ivu-select-selection {
95
+ .bri-control-disabled();
96
+ }
97
+ }
98
+
99
+ &-input[disabled] {
100
+ color: @textColor-disabled;
101
+ -webkit-text-fill-color: @textColor-disabled;
102
+ }
103
+ }
104
+ }
@@ -32,50 +32,4 @@
32
32
  // @btn-padding-base : 0 @padding-md - 1px;
33
33
  // @btn-padding-large : @btn-padding-base;
34
34
  // @btn-padding-small : 0 @padding-xs - 1px;
35
-
36
-
37
- .ivu-select {
38
- .ivu-select-selection {
39
-
40
- }
41
-
42
- &-disabled {
43
- .ivu-select-selection {
44
- .bri-control-disabled();
45
-
46
- &:hover {
47
- border-color: @border-disabled;
48
- }
49
- }
50
-
51
- .ivu-select-input[disabled] {
52
- color: @textColor;
53
- -webkit-text-fill-color: @placeholder-disabled-color;
54
- }
55
- }
56
-
57
- &-item {
58
- margin: 4px 8px;
59
- border-radius: @borderRadius;
60
-
61
- &:hover {
62
- background: @bgColor;
63
- }
64
-
65
- &-selected {
66
- background-color: @theme-focus;
67
- color: @themeColor;
68
- }
69
-
70
- &-disabled {
71
- .ivu-select-selection {
72
- .bri-control-disabled();
73
- }
74
- }
75
-
76
- &-input[disabled] {
77
- color: @textColor-disabled;
78
- -webkit-text-fill-color: @textColor-disabled;
79
- }
80
- }
81
- }
35
+
@@ -1,65 +0,0 @@
1
- .BriTransfer {
2
- .ivu-transfer {
3
- &-list {
4
- width: 200px;
5
- height: 346px;
6
-
7
- &-header {
8
- background-color: #fff;
9
- border-radius: 4px 4px 0 0;
10
- }
11
-
12
- &-body {
13
- border-radius: 0 0 4px 4px;
14
- }
15
-
16
- &-content-not-found {
17
- margin-top: 138px;
18
- }
19
-
20
- &-content-item {
21
- display: flex;
22
- margin: 4px 8px;
23
- padding: 5px 12px;
24
- border-radius: 4px;
25
-
26
- &:hover {
27
- background-color: #E8F3FD;
28
- }
29
-
30
- &:has(.ivu-checkbox-wrapper-checked) {
31
- background-color: @theme-focus ;
32
- }
33
-
34
- >span {
35
- word-break: normal;
36
- display: block;
37
- white-space: pre-wrap;
38
- word-wrap: break-word;
39
- overflow: hidden;
40
- }
41
- }
42
- }
43
-
44
- &-operation {
45
- .ivu-btn-primary {
46
- width: 24px;
47
- height: 24px;
48
- border-radius: 4px;
49
- display: flex;
50
- justify-content: center;
51
- align-items: center;
52
-
53
- .ivu-icon {
54
- font-size: 16px;
55
- }
56
- }
57
-
58
- .ivu-btn-primary[disabled] {
59
- border: 1px solid #CCCCCC;
60
- background: @borderColor;
61
- color: @textColor-disabled;
62
- }
63
- }
64
- }
65
- }
@@ -1,71 +0,0 @@
1
- <template>
2
- <div class="BriTransfer">
3
- <Transfer
4
- :data="selfData"
5
- :target-keys="targetKeys"
6
- :filterable="filterable"
7
- :filter-method="filterMethod"
8
- :titles="titles"
9
- not-found-text="暂无内容"
10
- @on-change="handleChange"
11
- ></Transfer>
12
- </div>
13
- </template>
14
-
15
- <script>
16
- export default {
17
- name: "BriTransfer",
18
- props: {
19
- data: {
20
- type: Array,
21
- default: () => {
22
- return [];
23
- }
24
- },
25
- value: {
26
- type: Array,
27
- default: () => {
28
- return [];
29
- }
30
- },
31
- filterMethod: {
32
- type: Function,
33
- default: () => {
34
- return {};
35
- }
36
- },
37
- titles: {
38
- type: Array,
39
- default: () => {
40
- return ["源列表", "目的列表"];
41
- }
42
- },
43
- filterable: Boolean
44
- },
45
- data () {
46
- return {
47
- targetKeys: []
48
- };
49
- },
50
- computed: {
51
- selfData () {
52
- return this.data.map(item => {
53
- return {
54
- key: item._key,
55
- label: item._name || item.name || item.realname
56
- };
57
- });
58
- }
59
- },
60
- created () {
61
- this.targetKeys = this.value;
62
- },
63
- methods: {
64
- handleChange (newTargetKeys) {
65
- this.targetKeys = newTargetKeys;
66
- this.$emit("input", this.targetKeys);
67
- this.$emit("change", this.targetKeys);
68
- }
69
- }
70
- };
71
- </script>
@@ -1,57 +0,0 @@
1
-
2
- .BriTree {
3
- border: 1px solid @btnCancelBg;
4
- border-radius: @borderRadius;
5
- width: 336px;
6
- overflow: auto;
7
- padding: 8px;
8
- user-select: none;
9
- max-width: 100%;
10
-
11
- }
12
- .ivu-tree {
13
- .ivu-icon-ios-arrow-forward {
14
- display: inline-block;
15
- width: 16px;
16
- height: 16px;
17
- border-radius: @borderRadius;
18
- &:before {
19
- content: "\F341";
20
- width: 100%;
21
- height: 100%;
22
- .dsh-flex-row-center-center();
23
- }
24
- &:hover {
25
- background-color: @btnCancelBgDisabled;
26
- }
27
- }
28
- &-arrow {
29
- width: auto;
30
- color: @placeholderColor;
31
- margin-top: 4px;
32
- &-open {
33
- color: @themeColor;
34
- }
35
- }
36
- &-title {
37
- color: @textColor;
38
- padding: 3px 8px 4px;
39
- border-radius: @borderRadius;
40
- display: inline-flex;
41
- width: calc(100% - 20px);
42
- &:hover {
43
- background-color: @bgColor;
44
- }
45
- &-selected {
46
- color: @themeColor;
47
- background-color: @theme-focus;
48
- }
49
- }
50
- .ivu-checkbox-wrapper+.ivu-tree-title {
51
- margin-left: -30px;
52
- padding-left: 30px;
53
- }
54
- .ivu-load-loop {
55
- color: @themeColor;
56
- }
57
- }
@@ -1,11 +0,0 @@
1
- .DshCascaders {
2
- width: 100%;
3
- &-control {
4
- display: inline-block;
5
- width: calc(100% - 65px);
6
- }
7
- &-create {
8
- display: inline-block;
9
- width: 60px;
10
- }
11
- }