@energie360/ui-library 0.1.23 → 0.1.25

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 (50) hide show
  1. package/components/badge/u-badge.vue +2 -2
  2. package/components/card-amount/card-amount.scss +7 -0
  3. package/components/card-amount/u-card-amount.vue +21 -0
  4. package/components/card-amount-illustrated/card-amount-illustrated.scss +35 -0
  5. package/components/card-amount-illustrated/u-card-amount-illustrated.vue +80 -0
  6. package/components/card-contact/card-contact.scss +5 -3
  7. package/components/card-contact/u-card-contact.vue +15 -10
  8. package/components/card-footer/u-card-footer.vue +6 -2
  9. package/components/card-group/card-group.scss +25 -11
  10. package/components/card-group/u-card-group.vue +59 -4
  11. package/components/chip/chip.scss +31 -4
  12. package/components/chip/u-chip.vue +5 -2
  13. package/components/index.js +4 -0
  14. package/components/progress-bar/progress-bar.scss +5 -9
  15. package/components/progress-bar/u-progress-bar.vue +3 -6
  16. package/components/richtext/_wizard.scss +1 -1
  17. package/components/richtext/richtext.scss +2 -0
  18. package/components/skeleton-loader/u-skeleton-loader.vue +1 -1
  19. package/components/slider/slider.scss +1 -0
  20. package/components/slider/u-slider.vue +26 -15
  21. package/components/slider-progress-animation/slider-progress-animation.scss +25 -0
  22. package/components/slider-progress-animation/u-slider-progress-animation.vue +65 -0
  23. package/components/sprite-animation/sprite-animation.scss +7 -0
  24. package/components/sprite-animation/u-sprite-animation.vue +169 -0
  25. package/components/table/cell-progress-bar.scss +4 -0
  26. package/components/table/u-cell-icon-group.vue +12 -7
  27. package/components/table/u-cell-progress-bar.vue +5 -5
  28. package/components/text-block/text-block.scss +18 -14
  29. package/components/text-block/u-text-block.vue +17 -11
  30. package/dist/elements/text.css +749 -0
  31. package/dist/elements/text.css.map +1 -0
  32. package/dist/layout/container.css +29 -0
  33. package/dist/layout/container.css.map +1 -0
  34. package/dist/layout/grid.css +3253 -0
  35. package/dist/layout/grid.css.map +1 -0
  36. package/elements/index.js +0 -1
  37. package/elements/select-chip/select-chip.scss +1 -1
  38. package/elements/select-chip/u-select-chip.vue +7 -6
  39. package/modules/feedback/feedback-vote-buttons.scss +10 -0
  40. package/modules/feedback/types/feedback.type.ts +4 -2
  41. package/modules/feedback/u-feedback-vote-buttons.vue +26 -12
  42. package/modules/feedback/u-feedback.vue +2 -1
  43. package/package.json +3 -1
  44. package/utility/elements/text.scss +61 -0
  45. package/utility/layout/container.scss +1 -0
  46. package/utility/layout/grid.scss +1 -0
  47. package/utils/functions/animate.js +258 -0
  48. package/wizard/wizard-layout/u-wizard-layout-block.vue +2 -2
  49. package/wizard/wizard-top-bar/u-wizard-top-bar.vue +0 -8
  50. package/elements/range-slider/u-range-slider.vue +0 -138
@@ -1,138 +0,0 @@
1
- <script setup lang="ts">
2
- // NOTE: URangeSlider as a base widget was a good idea.
3
- // But at the moment not really usable.
4
- // Maybe deprecate it.
5
-
6
- import { useTemplateRef, onMounted, useId, watch } from 'vue'
7
- import { scaleValue } from '../../utils/math/scale-value'
8
-
9
- export interface RangeSlider {
10
- label: string
11
- min?: number
12
- max?: number
13
- }
14
-
15
- const { min = 0, max = 100 } = defineProps<RangeSlider>()
16
-
17
- const id = useId()
18
- const model = defineModel<number>()
19
- const thumbEl = useTemplateRef('thumb')
20
- const lowerFillEl = useTemplateRef('lower-fill')
21
- let thumbWidth
22
-
23
- const setThumbPosition = () => {
24
- const position = scaleValue(Number(model.value), Number(min), Number(max), 0, 100, 2)
25
- thumbEl.value.style.left = `${position}%`
26
-
27
- lowerFillEl.value.style.width = `calc(${position}% + ${thumbWidth / 2}px)`
28
- }
29
-
30
- onMounted(() => {
31
- // Store thumb width. We'll judt assume that this won't change during runtime.
32
- thumbWidth = thumbEl.value.getBoundingClientRect().width
33
-
34
- setThumbPosition()
35
- })
36
-
37
- watch(model, () => {
38
- setThumbPosition()
39
- })
40
- </script>
41
-
42
- <template>
43
- <div class="range-slider">
44
- <label class="visually-hidden" :for="id">{{ label }}</label>
45
- <div class="range-slider__input">
46
- <input
47
- :id
48
- v-model="model"
49
- type="range"
50
- :min
51
- :max
52
- @input="setThumbPosition"
53
- @change="setThumbPosition"
54
- />
55
- </div>
56
- <div class="range-slider__slider">
57
- <div class="range-slider__track">
58
- <div ref="lower-fill" class="range-slider__lower-fill"></div>
59
- <div ref="thumb" class="range-slider__thumb"></div>
60
- </div>
61
- </div>
62
- </div>
63
- </template>
64
-
65
- <style lang="scss" scoped>
66
- @use '../../base/abstracts' as a;
67
-
68
- .range-slider {
69
- --range-height: 24px;
70
- --range-width: 100%;
71
- --range-border-radius: 0;
72
- --range-upper-fill-color: rgba(150, 150, 150);
73
- --range-lower-fill-color: rgb(0, 150, 0);
74
- --range-thumb-height: 24px;
75
- --range-thumb-width: 12px;
76
- --range-thumb-border-radius: 0;
77
- --range-thumb-background-color: rgb(0, 0, 0);
78
- --range-thumb-transform: none;
79
- --range-thumb-transition: none;
80
-
81
- /* "display: contents" would be better, but it still has some accessiblity issues -> https://ericwbailey.website/published/display-contents-considered-harmful/ */
82
- position: relative;
83
- display: inline-flex;
84
- width: var(--range-width);
85
- height: var(--range-height);
86
- }
87
-
88
- .range-slider__input {
89
- display: flex;
90
- width: 100%;
91
-
92
- input {
93
- width: 100%;
94
- }
95
- }
96
-
97
- .range-slider__slider {
98
- position: absolute;
99
- top: 0;
100
- left: 0;
101
- width: 100%;
102
- height: 100%;
103
- pointer-events: none;
104
- background-color: var(--range-upper-fill-color);
105
- border-radius: var(--range-border-radius);
106
- }
107
-
108
- .range-slider__thumb {
109
- position: relative;
110
- height: var(--range-thumb-height);
111
- width: var(--range-thumb-width);
112
- background-color: var(--range-thumb-background-color);
113
- border-radius: var(--range-thumb-border-radius);
114
- transform: var(--range-thumb-transform);
115
- transition: var(--range-thumb-transition);
116
- }
117
-
118
- .range-slider__track {
119
- position: relative;
120
- width: calc(100% - var(--range-thumb-width));
121
- height: 100%;
122
- }
123
-
124
- .range-slider__lower-fill {
125
- position: absolute;
126
- top: 0;
127
- left: 0;
128
- height: 100%;
129
- border-top-left-radius: var(--range-border-radius);
130
- border-bottom-left-radius: var(--range-border-radius);
131
- background-color: var(--range-lower-fill-color);
132
- min-width: var(--range-thumb-width);
133
- }
134
-
135
- .visually-hidden {
136
- @include a.visually-hidden;
137
- }
138
- </style>