@eturnity/eturnity_reusable_components 1.0.40 → 1.0.41

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eturnity/eturnity_reusable_components",
3
- "version": "1.0.40",
3
+ "version": "1.0.41",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "dev": "vue-cli-service serve",
@@ -12,6 +12,7 @@
12
12
  @focus="focusInput()"
13
13
  @keyup.enter="$emit('on-enter-click')"
14
14
  :disabled="disabled"
15
+ :isDisabled="disabled"
15
16
  :noBorder="noBorder"
16
17
  :textAlign="textAlign"
17
18
  />
@@ -36,6 +37,7 @@
36
37
  // inputWidth="150px" //by default, this is 100%
37
38
  // :numberPrecision="3"
38
39
  // unitName="pc"
40
+ // :numberPrecision="4"
39
41
  // :value="inputValue" //required -- String
40
42
  // @input-change="onInputChange($event)" //required
41
43
  // @on-enter-click="onInputSubmit()"
@@ -61,7 +63,7 @@ const inputProps = {
61
63
  hasUnit: Boolean,
62
64
  inputWidth: String,
63
65
  hasLength: Boolean,
64
- disabled: Boolean,
66
+ isDisabled: Boolean,
65
67
  noBorder: Boolean,
66
68
  textAlign: String,
67
69
  }
@@ -78,13 +80,13 @@ const InputContainer = styled("input", inputProps)`
78
80
  props.hasUnit ? "11px 40px 11px 10px" : "11px 5px 11px 10px"};
79
81
  border-radius: 4px;
80
82
  text-align: ${(props) => props.textAlign};
81
- cursor: ${(props) => (props.disabled ? "not-allowed" : "auto")};
83
+ cursor: ${(props) => (props.isDisabled ? "not-allowed" : "auto")};
82
84
  font-size: 16px;
83
85
  color: ${(props) =>
84
86
  props.isError ? props.theme.colors.red : props.theme.colors.black};
85
87
  width: ${(props) => (props.inputWidth ? props.inputWidth : "100%")};
86
88
  background-color: ${(props) =>
87
- props.disabled
89
+ props.isDisabled
88
90
  ? props.theme.colors.grey5 + " !important"
89
91
  : "#fff !important"};
90
92
 
@@ -240,6 +242,9 @@ export default {
240
242
  }
241
243
  },
242
244
  focusInput() {
245
+ if (this.disabled) {
246
+ return
247
+ }
243
248
  this.isFocused = true
244
249
  },
245
250
  formatWithCurrency(value) {
@@ -193,8 +193,8 @@ const TableContainer = styled.table`
193
193
  }
194
194
 
195
195
  &:hover {
196
- input {
197
- background-color: ${(props) => props.theme.colors.grey5};
196
+ input:disabled {
197
+ background-color: ${(props) => props.theme.colors.grey5 + "!important"};
198
198
  }
199
199
 
200
200
  .drag-icon {
@@ -253,6 +253,7 @@ const TableContainer = styled.table`
253
253
  input {
254
254
  font-size: 13px;
255
255
  padding: 5px 10px;
256
+ background: #fff !important;
256
257
  }
257
258
 
258
259
  .open-container {