@fishawack/lab-velocity 0.9.1 → 0.9.3

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.
@@ -13,4 +13,10 @@
13
13
  .el-input-group__append, .el-input-group__prepend {
14
14
  padding: 0 2 * $spacing;
15
15
  }
16
+ }
17
+
18
+ .vel-basic {
19
+ &__error {
20
+ color: $colorAlert !important;
21
+ }
16
22
  }
@@ -25,6 +25,7 @@
25
25
  &__error {
26
26
  order: 3;
27
27
  flex-basis: 100%;
28
+ color: $colorAlert !important;
28
29
  }
29
30
  }
30
31
 
@@ -6,6 +6,10 @@
6
6
  // &.el-input--large {
7
7
  --el-input-height:46px;
8
8
  // }
9
+
10
+ &__error {
11
+ color: $colorAlert !important;
12
+ }
9
13
  }
10
14
 
11
15
  .vel-popper {
@@ -3,6 +3,7 @@
3
3
  label {
4
4
  margin-bottom: $spacing;
5
5
  display: inline-block;
6
+ font-weight: 500;
6
7
  }
7
8
 
8
9
  &:not(:last-child) {
@@ -13,9 +14,9 @@
13
14
  .form__group--error {
14
15
 
15
16
  .el-select__wrapper, .el-select__wrapper:hover, .el-input__wrapper, .el-input__wrapper:hover {
16
- box-shadow: 0 0 0 1px $color9 inset;
17
+ box-shadow: 0 0 0 1px $colorAlert inset;
17
18
  .el-select__icon {
18
- color: $color9;
19
+ color: $colorAlert;
19
20
  }
20
21
  }
21
22
  }
@@ -14,4 +14,8 @@
14
14
  .el-input-group__append, .el-input-group__prepend {
15
15
  padding: 0 2 * $spacing;
16
16
  }
17
+
18
+ &__error {
19
+ color: $colorAlert !important;
20
+ }
17
21
  }
@@ -22,4 +22,7 @@
22
22
  .el-select__selection.is-near {
23
23
  margin-left: 0px;
24
24
  }
25
+ &__error {
26
+ color: $colorAlert !important;
27
+ }
25
28
  }
@@ -1 +1,7 @@
1
- @import "element-plus/theme-chalk/el-switch";
1
+ @import "element-plus/theme-chalk/el-switch";
2
+
3
+ .vel-switch {
4
+ &__error {
5
+ color: $colorAlert !important;
6
+ }
7
+ }
@@ -1 +1,12 @@
1
- @import "element-plus/theme-chalk/el-upload";
1
+ @import "element-plus/theme-chalk/el-upload";
2
+
3
+ .vel-upload {
4
+ &.form__group--error {
5
+ .el-upload__tip {
6
+ color: $colorAlert !important;
7
+ }
8
+ }
9
+ &__error {
10
+ color: $colorAlert !important;
11
+ }
12
+ }
@@ -16,12 +16,19 @@
16
16
  v-model="content"
17
17
  @change="handleInput"
18
18
  :value-format="valueFormat"
19
+ :date-format="dateFormat"
20
+ :time-format="timeFormat"
19
21
  :format="format"
20
- popper-class="vel-popper"
22
+ :popper-class="popperClass"
23
+ :prefix-icon="prefixIcon"
21
24
  />
22
25
  </XInput>
23
26
  </template>
24
-
27
+ <style>
28
+ .vel-popper--custom {
29
+ border: 1px solid red !important;
30
+ }
31
+ </style>
25
32
  <script>
26
33
  import dayjs from "dayjs";
27
34
  import { ElDatePicker } from "element-plus";
@@ -44,6 +51,12 @@ export default {
44
51
  valueFormat: {
45
52
  type: String
46
53
  },
54
+ dateFormat: {
55
+ type: String
56
+ },
57
+ timeFormat: {
58
+ type: String
59
+ },
47
60
  baseClass: {
48
61
  type: String,
49
62
  default: "vel-datepicker",
@@ -62,6 +75,13 @@ export default {
62
75
  type: String,
63
76
  default: "default",
64
77
  },
78
+ popperClass: {
79
+ type: String,
80
+ default: "vel-popper",
81
+ },
82
+ prefixIcon: {
83
+ type: String,
84
+ },
65
85
  },
66
86
  components: {
67
87
  XInput,
package/form/Select.vue CHANGED
@@ -17,11 +17,12 @@
17
17
  @change="handleInput"
18
18
  @clear="this.$emit('clear')"
19
19
  @blur="this.$emit('blur')"
20
+ :empty-values="[null, undefined]"
20
21
  >
21
22
  <template #default>
22
23
  <slot name="default">
23
24
  <el-option
24
- v-if="!options[0]?.value"
25
+ v-if="!options[0]?.label"
25
26
  v-for="(label, value) in options"
26
27
  :key="value"
27
28
  :label="label"
@@ -93,12 +94,13 @@ export default {
93
94
  emits: ['change', 'clear', 'blur'],
94
95
  methods: {
95
96
  castValue(value) {
96
- if (
97
+ if (
97
98
  !_.isNull(value) &&
98
99
  typeof value === "string" &&
99
- !isNaN(Number(value))
100
- ) {
101
- return parseInt(value);
100
+ value !== "" &&
101
+ !isNaN(Number(value))
102
+ ) {
103
+ return parseInt(value);
102
104
  }
103
105
  return value;
104
106
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fishawack/lab-velocity",
3
- "version": "0.9.1",
3
+ "version": "0.9.3",
4
4
  "description": "Avalere Health branded style system",
5
5
  "scripts": {
6
6
  "setup": "npm ci || npm i && npm run content",