@weni/unnnic-system 1.3.1 → 1.3.2
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/dist/unnnic.common.js +51 -25
- package/dist/unnnic.common.js.map +1 -1
- package/dist/unnnic.css +1 -1
- package/dist/unnnic.umd.js +51 -25
- package/dist/unnnic.umd.js.map +1 -1
- package/dist/unnnic.umd.min.js +5 -5
- package/dist/unnnic.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/assets/icons/graph-stats-descend-2.svg +4 -0
- package/src/components/Card/Card.vue +5 -0
- package/src/components/Card/DashCard.vue +9 -1
- package/src/utils/icons.js +2 -0
package/package.json
CHANGED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:bx="https://boxy-svg.com">
|
|
3
|
+
<path d="M 5.937 11.563 C 6.187 11.563 6.424 11.66 6.6 11.838 L 15.587 20.824 C 15.764 21 16 21.098 16.25 21.098 C 16.501 21.098 16.736 21 16.913 20.824 L 20.824 16.913 C 21.354 16.382 22.06 16.09 22.811 16.09 C 23.564 16.09 24.27 16.382 24.801 16.913 L 33.125 25.237 L 33.125 19.063 C 33.125 18.545 33.545 18.125 34.063 18.125 C 34.58 18.125 35 18.545 35 19.063 L 35 27.5 C 35 27.612 34.98 27.723 34.943 27.824 C 34.939 27.835 34.934 27.847 34.93 27.857 C 34.835 28.087 34.649 28.273 34.429 28.363 C 34.416 28.368 34.403 28.373 34.389 28.378 C 34.283 28.418 34.174 28.438 34.063 28.438 L 25.625 28.438 C 25.108 28.438 24.688 28.018 24.688 27.5 C 24.688 26.983 25.108 26.563 25.625 26.563 L 31.801 26.563 L 23.478 18.239 C 23.3 18.062 23.064 17.964 22.814 17.964 C 22.564 17.964 22.328 18.062 22.15 18.239 L 18.24 22.149 C 17.71 22.679 17.004 22.972 16.251 22.972 C 15.499 22.972 14.792 22.68 14.261 22.149 L 5.275 13.163 C 5.097 12.987 5 12.75 5 12.5 C 5 12.25 5.097 12.014 5.275 11.838 C 5.451 11.66 5.687 11.563 5.937 11.563 Z" fill="#3B414D" class="primary" bx:origin="0.5 0.49997"/>
|
|
4
|
+
</svg>
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
:button-action="buttonAction"
|
|
15
15
|
:value="value"
|
|
16
16
|
:percent="percent"
|
|
17
|
+
:inverted-percentage="invertedPercentage"
|
|
17
18
|
:status="status"
|
|
18
19
|
:description="description"
|
|
19
20
|
:info-position="infoPosition"
|
|
@@ -77,6 +78,10 @@ export default {
|
|
|
77
78
|
type: Number,
|
|
78
79
|
default: 0,
|
|
79
80
|
},
|
|
81
|
+
invertedPercentage: {
|
|
82
|
+
type: Boolean,
|
|
83
|
+
default: false,
|
|
84
|
+
},
|
|
80
85
|
rating: {
|
|
81
86
|
type: Number,
|
|
82
87
|
default: 0,
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
|
|
16
16
|
<div v-if="percent" :class="['percent', `unnnic-card-scheme--feedback-${color}`]">
|
|
17
17
|
<unnnic-icon
|
|
18
|
-
icon="graph-stats
|
|
18
|
+
:icon="`graph-stats-${percent >= 0 ? 'ascend' : 'descend'}-2`"
|
|
19
19
|
:scheme="`feedback-${color}`"
|
|
20
20
|
size="sm"
|
|
21
21
|
class="icon"
|
|
@@ -56,6 +56,10 @@ export default {
|
|
|
56
56
|
type: Number,
|
|
57
57
|
default: 0,
|
|
58
58
|
},
|
|
59
|
+
invertedPercentage: {
|
|
60
|
+
type: Boolean,
|
|
61
|
+
default: false,
|
|
62
|
+
},
|
|
59
63
|
scheme: {
|
|
60
64
|
type: String,
|
|
61
65
|
default: null,
|
|
@@ -64,6 +68,10 @@ export default {
|
|
|
64
68
|
|
|
65
69
|
computed: {
|
|
66
70
|
color() {
|
|
71
|
+
if (this.invertedPercentage) {
|
|
72
|
+
return this.percent < 0 ? 'green' : 'red';
|
|
73
|
+
}
|
|
74
|
+
|
|
67
75
|
return this.percent < 0 ? 'red' : 'green';
|
|
68
76
|
},
|
|
69
77
|
},
|
package/src/utils/icons.js
CHANGED
|
@@ -87,6 +87,7 @@ import alarmBell3 from '!!svg-inline-loader!../assets/icons/alarm-bell-3.svg';
|
|
|
87
87
|
import alertCircle1 from '!!svg-inline-loader!../assets/icons/alert-circle-1.svg';
|
|
88
88
|
import bookAddress2 from '!!svg-inline-loader!../assets/icons/book-address-2.svg';
|
|
89
89
|
import graphStatsAscend2 from '!!svg-inline-loader!../assets/icons/graph-stats-ascend-2.svg';
|
|
90
|
+
import graphStatsDescend2 from '!!svg-inline-loader!../assets/icons/graph-stats-descend-2.svg';
|
|
90
91
|
import synchronizeArrowClock5 from '!!svg-inline-loader!../assets/icons/synchronize-arrow-clock-5.svg';
|
|
91
92
|
import emailActionUnread1 from '!!svg-inline-loader!../assets/icons/email-action-unread-1.svg';
|
|
92
93
|
import synchronizeArrowClock4 from '!!svg-inline-loader!../assets/icons/synchronize-arrow-clock-4.svg';
|
|
@@ -229,6 +230,7 @@ export default {
|
|
|
229
230
|
'alert-circle-1': alertCircle1,
|
|
230
231
|
'book-address-2': bookAddress2,
|
|
231
232
|
'graph-stats-ascend-2': graphStatsAscend2,
|
|
233
|
+
'graph-stats-descend-2': graphStatsDescend2,
|
|
232
234
|
'synchronize-arrow-clock-5': synchronizeArrowClock5,
|
|
233
235
|
'email-action-unread-1': emailActionUnread1,
|
|
234
236
|
'synchronize-arrow-clock-4': synchronizeArrowClock4,
|