@everchron/ec-shards 0.7.45 → 0.7.48

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": "@everchron/ec-shards",
3
- "version": "0.7.45",
3
+ "version": "0.7.48",
4
4
  "private": false,
5
5
  "description": "Everchron Shards UI Library",
6
6
  "repository": "https://github.com/everchron/ec-shards.git",
@@ -66,7 +66,7 @@
66
66
 
67
67
  &.indent{
68
68
  .ecs-index-layout-table{
69
- padding: 15px;
69
+ padding: 15px 15px 0 15px;
70
70
  }
71
71
 
72
72
  .ecs-index-layout-pagination{
@@ -1,9 +1,9 @@
1
1
  <template>
2
- <div class="ecs-favorability" :class="typeClass" @click="$emit('click', $event)">
3
- <div class="ecs-favorability-button" :class="[css, loading ? 'loading' : '']" :title="rating">
2
+ <div class="ecs-favorability" :class="[typeClass, disabled ? 'disabled' : '']" @click="$emit('click', $event)">
3
+ <div class="ecs-favorability-button" :class="[css, loading ? 'loading' : '']" :title="labelText">
4
4
  <ecs-icon :type="iconType" />
5
5
  </div>
6
- <span v-if="label" class="label" :class="loading ? 'loading' : ''">{{ rating }}</span>
6
+ <span v-if="label" class="label" :class="loading ? 'loading' : ''">{{ labelText }}</span>
7
7
 
8
8
  <ecs-skeleton-loader v-if="loading" type="rect" :width="20" :height="20" />
9
9
  <ecs-skeleton-loader v-if="loading && label" type="single" style="width:calc(100% - 30px)" />
@@ -35,12 +35,10 @@
35
35
  loading: {
36
36
  type: Boolean,
37
37
  default: false
38
- }
39
- },
40
-
41
- data() {
42
- return {
43
-
38
+ },
39
+ disbaled: {
40
+ type: Boolean,
41
+ default: false
44
42
  }
45
43
  },
46
44
 
@@ -72,6 +70,25 @@
72
70
 
73
71
  css(){
74
72
  return this.rating ? this.rating.toLowerCase() : ''
73
+ },
74
+
75
+ labelText() {
76
+ switch (this.rating){
77
+ case 'good':
78
+ case 'Good':
79
+ return 'Favorable'
80
+ case 'mixed':
81
+ case 'Mixed':
82
+ return 'Mixed'
83
+ case 'bad':
84
+ case 'Bad':
85
+ return 'Not Favorable'
86
+ case 'unrated':
87
+ case 'Unrated':
88
+ return 'Unrated'
89
+ default:
90
+ return 'Unrated'
91
+ }
75
92
  }
76
93
  }
77
94
  }
@@ -199,6 +216,11 @@
199
216
  left: 28px;
200
217
  }
201
218
  }
219
+
220
+ &.disabled{
221
+ opacity: .4;
222
+ cursor: not-allowed;
223
+ }
202
224
  }
203
225
 
204
226
  .loading{