@eturnity/eturnity_reusable_components 8.16.9-SLD.2 → 8.16.9-qa-16-03-26.1

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": "8.16.9-SLD.2",
3
+ "version": "8.16.9-qa-16-03-26.1",
4
4
  "files": [
5
5
  "dist",
6
6
  "src"
@@ -0,0 +1,234 @@
1
+ <template>
2
+ <div
3
+ style="
4
+ margin-top: 100px;
5
+ margin-left: 80px;
6
+ padding-bottom: 100px;
7
+ display: flex;
8
+ flex-direction: column;
9
+ "
10
+ >
11
+ <!-- Simple bar chart -->
12
+ <BarChart
13
+ :data="monthlyData"
14
+ width="700px"
15
+ height="400px"
16
+ :valueFormatter="valueFormatter"
17
+ :barWidth="60"
18
+ :isScrollable="false"
19
+ chartControlsPosition="bottom"
20
+ :isBottomFieldsShown="true"
21
+ :isSelectionEnabled="true"
22
+ :selectionSize="3"
23
+ @selection-change="handleSelectionChange"
24
+ >
25
+ </BarChart>
26
+ <br />
27
+ <br />
28
+
29
+ <!-- Stacked bar chart -->
30
+ <BarChart
31
+ yAxisTitle="Energy (kWh)"
32
+ :data="monthLabels"
33
+ :series="tariffZones"
34
+ width="700px"
35
+ height="400px"
36
+ :barWidth="60"
37
+ :valueFormatter="valueFormatter"
38
+ :legendsItemPerRow="4"
39
+ :splitButtonOptions="options"
40
+ :selectedSplitButton="selectedTimeFrame"
41
+ :showPercentageOnTooltip="true"
42
+ :isBottomFieldsShown="true"
43
+ :isLegendShown="true"
44
+ @select-split-button="handleSelectSplitButton"
45
+ @input-blur="handleInputBlur"
46
+ >
47
+ </BarChart>
48
+
49
+ <!-- Stacked bar chart -->
50
+ <BarChart
51
+ :data="monthLabels"
52
+ :series="tariffZones"
53
+ width="700px"
54
+ height="400px"
55
+ :barWidth="60"
56
+ :valueFormatter="valueFormatter"
57
+ :legendsItemPerRow="4"
58
+ :isBottomFieldsShown="true"
59
+ :isLegendShown="false"
60
+ fieldMode="percentage"
61
+ @select-split-button="handleSelectSplitButton"
62
+ @input-blur="handleInputBlur"
63
+ >
64
+ <!-- <template #tooltip="{ item, segment }">
65
+ <div style="display: flex; flex-direction: column">
66
+ {{ $c.log(item, segment) }}
67
+ <div>{{ item.label }}</div>
68
+ <div>{{ item.segments[0].value }} kWh</div>
69
+ </div>
70
+ </template> -->
71
+ </BarChart>
72
+ </div>
73
+ </template>
74
+
75
+ <script setup>
76
+ import { ref } from 'vue'
77
+ import BarChart from '@/components/barchart/index.vue'
78
+
79
+ const options = [
80
+ { label: 'Day', value: 'day' },
81
+ { label: 'Month', value: 'month' },
82
+ { label: 'Year', value: 'year' },
83
+ ]
84
+
85
+ const selectedTimeFrame = ref('day')
86
+
87
+ const handleSelectSplitButton = (value) => {
88
+ selectedTimeFrame.value = value
89
+ }
90
+
91
+ const monthlyData = [
92
+ { label: 'Jan', value: 300 },
93
+ { label: 'Feb', value: 600 },
94
+ { label: 'Mar', value: 1000 },
95
+ { label: 'Apr', value: 1200 },
96
+ { label: 'May', value: 1400 },
97
+ { label: 'Jun', value: 1810 },
98
+ { label: 'Jul', value: 1400 },
99
+ { label: 'Aug', value: 1200 },
100
+ { label: 'Sep', value: 1000 },
101
+ // { label: 'Oct', value: 800 },
102
+ // { label: 'Nov', value: 600 },
103
+ // { label: 'Dec', value: 400 },
104
+ // { label: 'Jan', value: 300 },
105
+ // { label: 'Feb', value: 600 },
106
+ // { label: 'Mar', value: 1000 },
107
+ // { label: 'Apr', value: 1200 },
108
+ // { label: 'May', value: 1400 },
109
+ // { label: 'Jun', value: 1810 },
110
+ // { label: 'Jul', value: 1400 },
111
+ // { label: 'Aug', value: 1200 },
112
+ // { label: 'Sep', value: 1000 },
113
+ // { label: 'Oct', value: 800 },
114
+ // { label: 'Nov', value: 600 },
115
+ // { label: 'Dec', value: 400 },
116
+
117
+ // ... more months
118
+ ]
119
+
120
+ const monthLabels = [
121
+ { label: 'Jan' },
122
+ { label: 'Feb' },
123
+ { label: 'Mar' },
124
+ { label: 'Apr' },
125
+ { label: 'May' },
126
+ { label: 'Jun' },
127
+ // ... more months
128
+ ]
129
+
130
+ const tariffZones = ref([
131
+ {
132
+ name: 'Tariff Zone 1',
133
+ data: [
134
+ { label: 'Jan', value: 200 },
135
+ { label: 'Feb', value: 130 },
136
+ { label: 'Mar', value: 220 },
137
+ { label: 'Apr', value: 230 },
138
+ { label: 'May', value: 200 },
139
+ { label: 'Jun', value: 210 },
140
+ // ... more months
141
+ ],
142
+ },
143
+ {
144
+ name: 'Tariff Zone 2',
145
+ data: [
146
+ { label: 'Jan', value: 200 },
147
+ { label: 'Feb', value: 100 },
148
+ { label: 'Mar', value: 270 },
149
+ { label: 'Apr', value: 180 },
150
+ { label: 'May', value: 300 },
151
+ { label: 'Jun', value: 250 },
152
+ // ... more months
153
+ ],
154
+ },
155
+ {
156
+ name: 'Tariff Zone 3',
157
+ data: [
158
+ { label: 'Jan', value: 200 },
159
+ { label: 'Feb', value: 100 },
160
+ { label: 'Mar', value: 210 },
161
+ { label: 'Apr', value: 220 },
162
+ { label: 'May', value: 300 },
163
+ { label: 'Jun', value: 190 },
164
+ // ... more months
165
+ ],
166
+ },
167
+ {
168
+ name: 'Tariff Zone 4',
169
+ data: [
170
+ { label: 'Jan', value: 200 },
171
+ { label: 'Feb', value: 100 },
172
+ { label: 'Mar', value: 210 },
173
+ { label: 'Apr', value: 220 },
174
+ { label: 'May', value: 300 },
175
+ { label: 'Jun', value: 190 },
176
+ // ... more months
177
+ ],
178
+ },
179
+ {
180
+ name: 'Tariff Zone 5',
181
+ data: [
182
+ { label: 'Jan', value: 200 },
183
+ { label: 'Feb', value: 100 },
184
+ { label: 'Mar', value: 210 },
185
+ { label: 'Apr', value: 220 },
186
+ { label: 'May', value: 300 },
187
+ { label: 'Jun', value: 190 },
188
+ // ... more months
189
+ ],
190
+ },
191
+ {
192
+ name: 'Tariff Zone 6',
193
+ data: [
194
+ { label: 'Jan', value: 200 },
195
+ { label: 'Feb', value: 100 },
196
+ { label: 'Mar', value: 210 },
197
+ { label: 'Apr', value: 220 },
198
+ { label: 'May', value: 300 },
199
+ { label: 'Jun', value: 190 },
200
+ // ... more months
201
+ ],
202
+ },
203
+ // ... more tariff zones
204
+ ])
205
+
206
+ const valueFormatter = (value) => {
207
+ return `${value} kWh`
208
+ }
209
+
210
+ const handleSelectionChange = (selectedBars) => {
211
+ console.log('selectedBars', selectedBars)
212
+ }
213
+
214
+ const handleInputBlur = (payload) => {
215
+ console.log({ payload })
216
+ const newVal = [...tariffZones.value].map((zone) => {
217
+ if (zone.name === payload.seriesName) {
218
+ zone.data = zone.data.map((item) => {
219
+ if (item.label === payload.label) {
220
+ item.value = payload.value
221
+ }
222
+ return item
223
+ })
224
+ }
225
+ return zone
226
+ })
227
+
228
+ console.log({ newVal })
229
+
230
+ tariffZones.value = newVal
231
+ }
232
+ </script>
233
+
234
+ <style lang="scss" scoped></style>
@@ -1,3 +1,4 @@
1
- <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path fill-rule="evenodd" clip-rule="evenodd" d="M10.5 0.874878C11.3284 0.874878 12 1.54645 12 2.37488V3.87488H13.5C14.3284 3.87488 15 4.54645 15 5.37488V13.3749C15 14.2033 14.3284 14.8749 13.5 14.8749H5.5C4.67157 14.8749 4 14.2033 4 13.3749V11.8749H2.5C1.67157 11.8749 1 11.2033 1 10.3749V2.37488C1 1.54645 1.67157 0.874878 2.5 0.874878H10.5ZM4 10.8749H2.5C2.22386 10.8749 2 10.651 2 10.3749V2.37488C2 2.09874 2.22386 1.87488 2.5 1.87488H10.5C10.7761 1.87488 11 2.09874 11 2.37488V3.87488H5.5C4.67157 3.87488 4 4.54645 4 5.37488V10.8749ZM14 5.37488C14 5.09874 13.7761 4.87488 13.5 4.87488H5.5C5.22386 4.87488 5 5.09874 5 5.37488V13.3749C5 13.651 5.22386 13.8749 5.5 13.8749H13.5C13.7761 13.8749 14 13.651 14 13.3749V5.37488Z" fill="black"/>
1
+ <svg fill="none" height="16" viewbox="12 12 16 16" width="16" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M27 17.8751V25.8749C27 26.4374 26.5625 26.8749 26 26.8749H18.0626C17.5001 26.8749 17.0626 26.4374 17.0626 25.8749V17.8751C17.0626 17.3126 17.5001 16.8751 18.0626 16.8751H26.0625C26.5625 16.9376 27 17.3751 27 17.8751Z" fill="#B2B9C5"></path>
3
+ <path d="M22.9374 14.1251V16.3126H18.0624C17.1874 16.3126 16.4375 17.0626 16.4375 17.9376V23.125H14C13.4375 23.125 13 22.6875 13 22.125V14.1251C13 13.5626 13.4375 13.1251 14 13.1251H21.9999C22.4999 13.1251 22.9374 13.5626 22.9374 14.1251Z" fill="#B2B9C5"></path>
3
4
  </svg>
@@ -1,3 +1,3 @@
1
- <svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path fill-rule="evenodd" clip-rule="evenodd" d="M1.5 1C1.22386 1 1 1.22386 1 1.5V2.5C1 2.77614 0.776142 3 0.5 3C0.223858 3 0 2.77614 0 2.5V1.5C0 0.671573 0.671573 0 1.5 0H6H10.5C11.3284 0 12 0.671573 12 1.5V2.5C12 2.77614 11.7761 3 11.5 3C11.2239 3 11 2.77614 11 2.5V1.5C11 1.22386 10.7761 1 10.5 1H6.5V11H8.5C8.77614 11 9 11.2239 9 11.5C9 11.7761 8.77614 12 8.5 12H6H3.5C3.22386 12 3 11.7761 3 11.5C3 11.2239 3.22386 11 3.5 11H5.5V1H1.5Z" fill="black"/>
1
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M3.5 3C3.22386 3 3 3.22386 3 3.5V4.5C3 4.77614 2.77614 5 2.5 5C2.22386 5 2 4.77614 2 4.5V3.5C2 2.67157 2.67157 2 3.5 2H8H12.5C13.3284 2 14 2.67157 14 3.5V4.5C14 4.77614 13.7761 5 13.5 5C13.2239 5 13 4.77614 13 4.5V3.5C13 3.22386 12.7761 3 12.5 3H8.5V13H10.5C10.7761 13 11 13.2239 11 13.5C11 13.7761 10.7761 14 10.5 14H8H5.5C5.22386 14 5 13.7761 5 13.5C5 13.2239 5.22386 13 5.5 13H7.5V3H3.5Z" fill="white"/>
3
3
  </svg>
@@ -1,13 +1,13 @@
1
1
  <template>
2
2
  <Container :is-chart-controls-shown-in-bottom="isChartControlsShownInBottom">
3
3
  <LabelsColumn :width="yAxisWidth">
4
- <LabelRow v-for="series in props.series" :key="series.name">
4
+ <LabelRow v-for="series in seriesData" :key="series.name">
5
5
  {{ series.name }}
6
6
  </LabelRow>
7
- <TotalRow v-if="props.series.length && fieldMode === 'percentage'">
7
+ <TotalRow v-if="seriesData.length && fieldMode === 'percentage'">
8
8
  {{ $gettext ? $gettext('Total (%)') : 'Total (%)' }}
9
9
  </TotalRow>
10
- <TotalRow v-if="props.series.length">
10
+ <TotalRow v-if="seriesData.length">
11
11
  {{ $gettext ? $gettext('Total (kWh)') : 'Total (kWh)' }}
12
12
  </TotalRow>
13
13
  </LabelsColumn>
@@ -18,9 +18,9 @@
18
18
  >
19
19
  <FieldsWrapper>
20
20
  <!-- For stacked bar chart -->
21
- <template v-if="props.series.length">
21
+ <template v-if="seriesData.length">
22
22
  <InputRow
23
- v-for="series in props.series"
23
+ v-for="series in seriesData"
24
24
  :key="series.name"
25
25
  :data-series-name="series.name"
26
26
  >
@@ -32,7 +32,14 @@
32
32
  >
33
33
  <InputNumber
34
34
  :allow-negative="false"
35
+ :error-message="null"
35
36
  input-height="36px"
37
+ :is-border-error-only="true"
38
+ :is-error="
39
+ fieldMode === 'percentage'
40
+ ? calculatePercentageTotal(item.label) !== 100
41
+ : false
42
+ "
36
43
  :number-precision="0"
37
44
  :min-decimals="0"
38
45
  text-align="center"
@@ -61,6 +68,7 @@
61
68
  :unit-name="fieldMode === 'percentage' ? '%' : ''"
62
69
  :value="calculatePercentageTotal(item.label)"
63
70
  />
71
+ {{ $c.log(calculatePercentageTotal(item.label)) }}
64
72
  </InputGroup>
65
73
  </TotalInputRow>
66
74
 
@@ -72,12 +80,19 @@
72
80
  :key="index"
73
81
  >
74
82
  <InputNumber
83
+ error-message="The entered values don’t add up to 100% so we will automatically scale the total kWh"
75
84
  input-height="36px"
85
+ :is-border-error-only="true"
86
+ :is-error="
87
+ fieldMode === 'percentage'
88
+ ? calculatePercentageTotal(item.label) !== 100
89
+ : false
90
+ "
76
91
  :is-read-only="true"
77
92
  :number-precision="2"
78
93
  :min-decimals="0"
79
94
  text-align="center"
80
- :value="calculateTotal(item.label)"
95
+ :value="calculateTotalValue(item.label)"
81
96
  />
82
97
  </InputGroup>
83
98
  </TotalInputRow>
@@ -110,7 +125,8 @@
110
125
  </template>
111
126
 
112
127
  <script setup>
113
- import { ref } from 'vue'
128
+ import { ref, watch, onMounted } from 'vue'
129
+ import styled from 'vue3-styled-components'
114
130
  import InputNumber from '../inputs/inputNumber'
115
131
 
116
132
  import {
@@ -161,6 +177,43 @@
161
177
  },
162
178
  })
163
179
 
180
+ const seriesData = ref([])
181
+
182
+ onMounted(() => {
183
+ seriesData.value = props.series.map((item) => {
184
+ const data = item.data.map((d) => ({
185
+ label: d.label,
186
+ value: d.value,
187
+ originalValue: d.value,
188
+ }))
189
+
190
+ return {
191
+ name: item.name,
192
+ data,
193
+ }
194
+ })
195
+ })
196
+
197
+ watch(props.series, () => {
198
+ const currentSeriesData = [...seriesData.value]
199
+ const newSeriesData = []
200
+
201
+ props.series.forEach((item, itemIndex) => {
202
+ const data = item.data.map((d, dIndex) => ({
203
+ label: d.label,
204
+ value: d.value,
205
+ originalValue: currentSeriesData[itemIndex].data[dIndex].originalValue,
206
+ }))
207
+
208
+ newSeriesData.push({
209
+ name: item.name,
210
+ data,
211
+ })
212
+ })
213
+
214
+ seriesData.value = [...newSeriesData]
215
+ })
216
+
164
217
  const emit = defineEmits([
165
218
  'sync-scroll',
166
219
  'input-blur',
@@ -175,11 +228,13 @@
175
228
  emit('input-focus', { seriesName, label })
176
229
  }
177
230
 
178
- const calculateTotal = (label) => {
179
- return props.series.reduce((sum, series) => {
231
+ const calculateTotalValue = (label) => {
232
+ const total = seriesData.value.reduce((sum, series) => {
180
233
  const value = series.data.find((d) => d.label === label)?.value || 0
181
234
  return sum + value
182
235
  }, 0)
236
+
237
+ return Math.round(total)
183
238
  }
184
239
 
185
240
  const syncScroll = (scrollLeft) => {
@@ -190,30 +245,59 @@
190
245
  container.scrollLeft = scrollLeft
191
246
  }
192
247
  }
193
- const getDisplayValue = (seriesData, label) => {
248
+
249
+ const calculateTotalOriginalValue = (label) => {
250
+ return seriesData.value.reduce((sum, series) => {
251
+ const value =
252
+ series.data.find((d) => d.label === label)?.originalValue || 0
253
+ return sum + value
254
+ }, 0)
255
+ }
256
+
257
+ const getDisplayValue = (data, label) => {
194
258
  if (props.fieldMode === 'absolute') {
195
- return seriesData.find((d) => d.label === label)?.value || ''
259
+ return data.find((d) => d.label === label)?.value || ''
196
260
  }
197
261
 
198
- const value = seriesData.find((d) => d.label === label)?.value || 0
199
- const total = calculateTotal(label)
200
- return total ? Number(((value / total) * 100).toFixed(0)) : 0
262
+ const value = data.find((d) => d.label === label)?.value || 0
263
+
264
+ const total = seriesData.value.reduce((sum, series) => {
265
+ const value =
266
+ series.data.find((d) => d.label === label)?.originalValue || 0
267
+ return sum + value
268
+ }, 0)
269
+
270
+ return Math.round((value / total) * 100)
201
271
  }
202
272
 
203
273
  const calculatePercentageTotal = (label) => {
204
- return props.series.reduce((sum, series) => {
274
+ const originalTotal = seriesData.value.reduce((sum, series) => {
275
+ const originalValue =
276
+ series.data.find((d) => d.label === label)?.originalValue || 0
277
+ return sum + originalValue
278
+ }, 0)
279
+
280
+ const totalPercentage = seriesData.value.reduce((sum, series) => {
205
281
  const value = series.data.find((d) => d.label === label)?.value || 0
206
- const total = calculateTotal(label)
207
- const percentage = total ? Number(((value / total) * 100).toFixed(0)) : 0
282
+ const percentage = originalTotal
283
+ ? Number((value / originalTotal) * 100)
284
+ : 0
208
285
  return sum + percentage
209
286
  }, 0)
287
+
288
+ return Math.round(totalPercentage)
210
289
  }
211
290
 
212
291
  const handleInputBlur = (_value, seriesName, label) => {
213
292
  let value = Number(_value)
214
293
 
215
294
  if (props.fieldMode === 'percentage') {
216
- const total = calculateTotal(label)
295
+ const total = seriesData.value.reduce((sum, series) => {
296
+ const value =
297
+ series.data.find((d) => d.label === label)?.originalValue || 0
298
+ return sum + value
299
+ }, 0)
300
+
217
301
  value = (value / 100) * total
218
302
  }
219
303
 
@@ -18,6 +18,18 @@ export function useTooltip(chartId, normalizedData) {
18
18
  }
19
19
  if (isObjectEqual(item, tooltipData.value)) return
20
20
 
21
+ const totalValue = item.segments.reduce((acc, segment) => {
22
+ return acc + segment.value
23
+ }, 0)
24
+
25
+ const segments = item.segments.map((segment) => {
26
+ let valuePercentage = (segment.value / totalValue) * 100
27
+ segment.valuePercentage = Math.round(valuePercentage)
28
+
29
+ return segment
30
+ })
31
+ item.segments = segments
32
+
21
33
  tooltipData.value = { ...item }
22
34
 
23
35
  const targetElement = series.length
@@ -30,7 +30,7 @@
30
30
  )
31
31
  "
32
32
  >
33
- <YAxisLabel>{{ label }}</YAxisLabel>
33
+ <YAxisLabel>{{ getYAxisLabel(label) }}</YAxisLabel>
34
34
  <YAxisLine :y-axis-width="yAxisWidth" />
35
35
  </YAxisRow>
36
36
  </YAxis>
@@ -128,7 +128,11 @@
128
128
  :gradient-to="segment.gradientTo"
129
129
  />
130
130
  <TooltipText>
131
- {{ handleValueFormatter(segment.value) }}
131
+ {{
132
+ fieldMode === 'absolute' && showPercentageOnTooltip
133
+ ? `${segment.valuePercentage}%`
134
+ : handleValueFormatter(segment.value)
135
+ }}
132
136
  </TooltipText>
133
137
  </TooltipRow>
134
138
  </template>
@@ -171,12 +175,13 @@
171
175
  </template>
172
176
 
173
177
  <script setup>
174
- import { useSlots, computed } from 'vue'
178
+ import { useSlots, computed, ref } from 'vue'
175
179
 
176
180
  import ChartControls from './ChartControls'
177
181
  import BottomFields from './BottomFields'
178
182
  import SelectionBox from './SelectionBox'
179
183
  import Spinner from '../spinner'
184
+ import { numberToString } from '../../helpers/numberConverter'
180
185
 
181
186
  import {
182
187
  useTooltip,
@@ -296,6 +301,10 @@
296
301
  type: Boolean,
297
302
  default: false,
298
303
  },
304
+ showPercentageOnTooltip: {
305
+ type: Boolean,
306
+ default: false,
307
+ },
299
308
  })
300
309
 
301
310
  const generateChartId = () =>
@@ -378,8 +387,20 @@
378
387
  }
379
388
 
380
389
  const handleValueFormatter = (value) => {
381
- return props.valueFormatter
382
- ? props.valueFormatter(Math.round(value))
383
- : value
390
+ value = numberToString({
391
+ value,
392
+ numberPrecision: 0,
393
+ minDecimals: 0,
394
+ })
395
+
396
+ return props.valueFormatter ? props.valueFormatter(value) : value
397
+ }
398
+
399
+ const getYAxisLabel = (label) => {
400
+ return numberToString({
401
+ value: label,
402
+ numberPrecision: 0,
403
+ minDecimals: 0,
404
+ })
384
405
  }
385
406
  </script>
@@ -28,7 +28,6 @@ export const TotalRow = styled(LabelRow)``
28
28
 
29
29
  export const FieldsContainer = styled.div`
30
30
  flex: 1;
31
- overflow-x: auto;
32
31
  scrollbar-width: none;
33
32
 
34
33
  &::-webkit-scrollbar {
@@ -63,4 +62,9 @@ export const InputGroup = styled('div', {
63
62
  props.barWidth}px;
64
63
  display: flex;
65
64
  justify-content: center;
65
+ position: relative;
66
+
67
+ input[readonly] {
68
+ border: 1px solid ${(props) => props.theme.colors.grey4} !important;
69
+ }
66
70
  `
@@ -50,6 +50,7 @@
50
50
  :has-slot="hasSlot"
51
51
  :has-unit="unitName && !!unitName.length"
52
52
  :input-height="inputHeight"
53
+ :is-border-error-only="isBorderErrorOnly"
53
54
  :is-disabled="disabled"
54
55
  :is-error="isError"
55
56
  :is-interactive="isInteractive"
@@ -57,11 +58,12 @@
57
58
  :no-border="noBorder"
58
59
  :placeholder="displayedPlaceholder"
59
60
  :read-only="isReadOnly"
61
+ :readonly="isReadOnly"
60
62
  :show-arrow-controls="showArrowControls"
61
63
  :show-linear-unit-name="showLinearUnitName"
62
64
  :slot-size="slotSize"
63
65
  :text-align="textAlign"
64
- :value="formatWithCurrency(value)"
66
+ :value="formattedValue"
65
67
  @blur="onInputBlur($event)"
66
68
  @focus="focusInput()"
67
69
  @input="onInput($event)"
@@ -75,12 +77,12 @@
75
77
 
76
78
  <UnitContainer
77
79
  v-if="unitName && showLinearUnitName && !hasSlot"
78
- :has-length="!!textInput.length"
80
+ :has-length="hasLength"
79
81
  :is-error="isError"
80
82
  >{{ unitName }}</UnitContainer
81
83
  >
82
84
  <IconWrapper
83
- v-if="isError && !showLinearUnitName"
85
+ v-if="isError && !showLinearUnitName && !isBorderErrorOnly"
84
86
  :margin-right="showSelect ? selectWidth : 0"
85
87
  size="16px"
86
88
  >
@@ -92,7 +94,7 @@
92
94
  :disabled="isSelectDisabled"
93
95
  :select-width="`${selectWidth}px`"
94
96
  :show-border="false"
95
- @input-change="$emit('select-change', $event)"
97
+ @input-change="handleSelectChange"
96
98
  >
97
99
  <template #selector>
98
100
  <SelectText>{{ getSelectValue }}</SelectText>
@@ -134,7 +136,9 @@
134
136
  </ArrowButton>
135
137
  </ArrowControls>
136
138
  </InputWrapper>
137
- <ErrorMessage v-if="isError">{{ errorMessage }}</ErrorMessage>
139
+ <ErrorMessage v-if="isError && errorMessage">{{
140
+ errorMessage
141
+ }}</ErrorMessage>
138
142
  </Container>
139
143
  </template>
140
144
 
@@ -205,6 +209,7 @@
205
209
  colorMode: String,
206
210
  showArrowControls: Boolean,
207
211
  readOnly: Boolean,
212
+ isBorderErrorOnly: Boolean,
208
213
  }
209
214
 
210
215
  const Container = styled('div', inputProps)`
@@ -236,16 +241,17 @@
236
241
  showLinearUnitName,
237
242
  colorMode,
238
243
  showArrowControls,
244
+ isBorderErrorOnly,
239
245
  }) =>
240
246
  showArrowControls
241
247
  ? '40px'
242
248
  : colorMode === 'transparent'
243
249
  ? '0'
244
250
  : slotSize
245
- ? isError && !showLinearUnitName
251
+ ? isError && !showLinearUnitName && !isBorderErrorOnly
246
252
  ? 'calc(' + slotSize + ' + 24px)'
247
253
  : 'calc(' + slotSize + ' + 10px)'
248
- : isError && !showLinearUnitName
254
+ : isError && !showLinearUnitName && !isBorderErrorOnly
249
255
  ? '24px'
250
256
  : '5px'};
251
257
  border-radius: ${(props) =>
@@ -457,8 +463,18 @@
457
463
  background-color: ${({ theme }) => theme.colors.grey4};
458
464
  `
459
465
 
466
+ const EVENT_TYPES = {
467
+ INPUT_FOCUS: 'input-focus',
468
+ INPUT_CHANGE: 'input-change',
469
+ INPUT_BLUR: 'input-blur',
470
+ PRESS_ENTER: 'on-enter-click',
471
+ INPUT_DRAG: 'on-input-drag',
472
+ SELECT_CHANGE: 'select-change',
473
+ }
474
+
460
475
  export default {
461
476
  name: 'InputNumber',
477
+ emits: [...Object.values(EVENT_TYPES)],
462
478
  components: {
463
479
  Container,
464
480
  InputContainer,
@@ -698,12 +714,17 @@
698
714
  type: Boolean,
699
715
  default: false,
700
716
  },
717
+ isBorderErrorOnly: {
718
+ type: Boolean,
719
+ default: false,
720
+ },
701
721
  },
702
722
  data() {
703
723
  return {
704
- textInput: '',
705
724
  isFocused: false,
706
725
  warningIcon: warningIcon,
726
+ inputValue: null,
727
+ enteredValue: null,
707
728
  }
708
729
  },
709
730
  computed: {
@@ -726,6 +747,14 @@
726
747
 
727
748
  return item ? item.label : '-'
728
749
  },
750
+ formattedValue() {
751
+ return this.isFocused
752
+ ? this.enteredValue
753
+ : this.formatWithCurrency(this.value)
754
+ },
755
+ hasLength() {
756
+ return this.formattedValue !== null && this.formattedValue.length > 0
757
+ },
729
758
  },
730
759
  watch: {
731
760
  focus(value) {
@@ -736,30 +765,19 @@
736
765
  clearInput: function (value) {
737
766
  if (value) {
738
767
  // If the value is typed, then we should clear the textInput on Continue
739
- this.textInput = ''
768
+ this.inputValue = ''
769
+ this.enteredValue = ''
740
770
  }
741
771
  },
742
- },
743
- created() {
744
- if (this.value) {
745
- this.textInput = numberToString({
746
- value: this.value,
747
- numberPrecision: this.numberPrecision,
748
- minDecimals: this.minDecimals,
749
- })
750
- } else if (this.defaultNumber !== null) {
751
- this.textInput = numberToString({
752
- value: this.defaultNumber,
753
- numberPrecision: this.numberPrecision,
754
- minDecimals: this.minDecimals,
755
- })
756
- } else if (this.minNumber !== null) {
757
- this.textInput = numberToString({
758
- value: this.minNumber,
759
- numberPrecision: this.numberPrecision,
760
- minDecimals: this.minDecimals,
761
- })
762
- }
772
+ value: {
773
+ immediate: true,
774
+ handler(val) {
775
+ if (this.value !== this.inputValue && !Number.isNaN(this.value)) {
776
+ this.inputValue = this.value
777
+ this.enteredValue = Number(this.value.toFixed(this.numberPrecision))
778
+ }
779
+ },
780
+ },
763
781
  },
764
782
  mounted() {
765
783
  if (this.focus) {
@@ -798,32 +816,28 @@
798
816
  }
799
817
  },
800
818
  onEnterPress() {
801
- this.$emit('on-enter-click')
819
+ this.$emit(EVENT_TYPES.PRESS_ENTER)
802
820
  this.$refs.inputField1.$el.blur()
803
821
  },
804
- onChangeHandler(event) {
805
- if (isNaN(event) || event === '') {
806
- event = this.defaultNumber
822
+ onChangeHandler(value) {
823
+ if (isNaN(value) || value === '') {
824
+ value = this.defaultNumber
807
825
  ? this.defaultNumber
808
826
  : this.minNumber || this.minNumber === 0
809
827
  ? this.minNumber
810
- : event
828
+ : value
811
829
  }
812
830
  if (!this.allowNegative) {
813
- event = Math.abs(event)
814
- }
815
- if (this.minNumber && this.minNumber > event) {
816
- event = this.minNumber
831
+ value = Math.abs(value)
817
832
  }
818
- event = parseFloat(event)
833
+ value = parseFloat(value)
819
834
  // Need to return an integer rather than a string
820
- this.$emit('input-change', event)
835
+ return parseFloat(value)
821
836
  },
822
- onEvaluateCode(event) {
837
+ onEvaluateCode(value) {
823
838
  // function to perform math on the code
824
839
  // filter the string in case of any malicious content
825
- const val = event.target.value
826
- let filtered = val.replace('(auto)', '').replace(/[^-()\d/*+.,]/g, '')
840
+ let filtered = value.replace('(auto)', '').replace(/[^-()\d/*+.,]/g, '')
827
841
  filtered = filtered.split(/([-+*/()])/)
828
842
  let formatted = filtered.map((item) => {
829
843
  if (
@@ -881,48 +895,32 @@
881
895
  return array
882
896
  },
883
897
  onInput(event) {
884
- if (!this.isFocused) {
898
+ console.log('onInput', event.target.value)
899
+ this.enteredValue = event.target.value
900
+ if (!this.isFocused || this.enteredValue === this.inputValue) {
885
901
  return
886
902
  }
887
- if (event.target.value === '') {
888
- this.$emit('on-input', '')
889
- }
890
903
  let evaluatedVal
891
904
  try {
892
- evaluatedVal = this.onEvaluateCode(event)
905
+ evaluatedVal = this.onEvaluateCode(String(this.enteredValue))
893
906
  } finally {
894
- if (evaluatedVal && this.value != evaluatedVal) {
895
- this.$emit('on-input', evaluatedVal)
907
+ this.inputValue = this.onChangeHandler(evaluatedVal)
908
+
909
+ if (this.isFocused && typeof this.enteredValue !== 'number') {
910
+ this.$emit(EVENT_TYPES.INPUT_CHANGE, this.inputValue)
896
911
  }
897
912
  }
898
913
  this.textInput = evaluatedVal
899
914
  },
900
915
  onInputBlur(e) {
901
916
  this.isFocused = false
902
- let value = e.target.value
903
- let evaluatedInput = this.onEvaluateCode(e)
904
- this.onChangeHandler(evaluatedInput ? evaluatedInput : value)
905
- if ((evaluatedInput && value.length) || this.minNumber !== null) {
906
- this.textInput = numberToString({
907
- value:
908
- evaluatedInput && value.length
909
- ? evaluatedInput
910
- : this.defaultNumber
911
- ? this.defaultNumber
912
- : this.minNumber,
913
- numberPrecision: this.numberPrecision,
914
- minDecimals: this.minDecimals,
915
- })
917
+ if (!Number.isNaN(this.inputValue)) {
918
+ this.enteredValue = this.inputValue
916
919
  }
917
- let adjustedMinValue =
918
- evaluatedInput && evaluatedInput.length
919
- ? evaluatedInput
920
- : this.defaultNumber
921
- ? this.defaultNumber
922
- : this.minNumber || this.minNumber === 0
923
- ? this.minNumber
924
- : ''
925
- this.$emit('input-blur', adjustedMinValue)
920
+ this.$emit(
921
+ EVENT_TYPES.INPUT_BLUR,
922
+ Number(this.onEvaluateCode(String(this.inputValue)))
923
+ )
926
924
  },
927
925
  focusInput() {
928
926
  if (this.disabled) {
@@ -932,7 +930,7 @@
932
930
  this.$nextTick(() => {
933
931
  this.$refs.inputField1.$el.select()
934
932
  })
935
- this.$emit('input-focus')
933
+ this.$emit(EVENT_TYPES.INPUT_FOCUS, this.inputValue)
936
934
  },
937
935
  blurInput() {
938
936
  if (this.disabled) {
@@ -952,7 +950,7 @@
952
950
  : this.minNumber || this.minNumber === 0
953
951
  ? this.minNumber
954
952
  : ''
955
- if ((adjustedMinValue || adjustedMinValue === 0) && !this.isFocused) {
953
+ if (adjustedMinValue || adjustedMinValue === 0) {
956
954
  let input = this.numberToStringEnabled
957
955
  ? numberToString({
958
956
  value: adjustedMinValue,
@@ -965,6 +963,8 @@
965
963
  return input + ' ' + unit
966
964
  } else if (!adjustedMinValue && adjustedMinValue !== 0) {
967
965
  return ''
966
+ } else if (this.isFocused) {
967
+ return value
968
968
  } else {
969
969
  return this.numberToStringEnabled
970
970
  ? numberToString({
@@ -985,14 +985,7 @@
985
985
  e.preventDefault()
986
986
  let value = parseFloat(this.value || 0)
987
987
  value += parseFloat(this.interactionStep) * parseInt(e.movementX)
988
- this.$emit('on-input-drag', value)
989
-
990
- this.textInput = numberToString({
991
- value: value && value.length ? value : this.minNumber,
992
- numberPrecision: this.numberPrecision,
993
- minDecimals: this.minDecimals,
994
- })
995
- //this.value=value
988
+ this.$emit(EVENT_TYPES.INPUT_DRAG, this.onChangeHandler(value))
996
989
  },
997
990
  stopInteract(e) {
998
991
  e.preventDefault()
@@ -1000,6 +993,9 @@
1000
993
  window.removeEventListener('mouseup', this.stopInteract, false)
1001
994
  this.blurInput()
1002
995
  },
996
+ handleSelectChange(value) {
997
+ this.$emit(EVENT_TYPES.SELECT_CHANGE, value)
998
+ },
1003
999
  },
1004
1000
  }
1005
1001
  </script>
@@ -2,19 +2,18 @@
2
2
  <OptionContainer
3
3
  :background-color="
4
4
  colorMode == 'dark'
5
- ? theme.semanticColors.teal[900]
5
+ ? '#000000'
6
6
  : colorMode == 'transparent'
7
7
  ? 'black'
8
8
  : backgroundColor
9
9
  "
10
- :color-mode="colorMode"
11
10
  :cursor-type="cursorType"
12
11
  :data-value="value"
13
12
  :disabled-bg-color="disabledBgColor"
14
13
  :disabled-text-color="disabledTextColor"
15
14
  :hovered-bg-color="
16
15
  colorMode == 'dark'
17
- ? theme.semanticColors.teal[800]
16
+ ? '#000000'
18
17
  : colorMode == 'transparent'
19
18
  ? 'grey6'
20
19
  : hoveredBgColor
@@ -37,7 +36,6 @@
37
36
  // import selectButton from './selectButton'
38
37
  // import selectDropdown from './selectDropDown'
39
38
  import styled from 'vue3-styled-components'
40
- import theme from '@/assets/theme'
41
39
  const optionProps = {
42
40
  isDisabled: Boolean,
43
41
  hoveredBgColor: String,
@@ -48,7 +46,6 @@
48
46
  disabledTextColor: String,
49
47
  padding: String,
50
48
  textColor: String,
51
- colorMode: String,
52
49
  }
53
50
  const OptionContainer = styled('div', optionProps)`
54
51
  display: flex;
@@ -80,8 +77,6 @@
80
77
  ? props.theme.colors[props.disabledTextColor]
81
78
  : props.disabledTextColor
82
79
  : props.theme.colors.grey3
83
- : props.colorMode == 'dark'
84
- ? props.theme.colors['white']
85
80
  : props.theme.colors[props.textColor]
86
81
  ? props.theme.colors[props.textColor]
87
82
  : props.textColor};
@@ -150,9 +145,7 @@
150
145
  },
151
146
  emits: ['option-hovered', 'option-selected'],
152
147
  data() {
153
- return {
154
- theme,
155
- }
148
+ return {}
156
149
  },
157
150
  computed: {},
158
151
  methods: {
@@ -33,18 +33,8 @@
33
33
  :is-active="selectedValue == item.value"
34
34
  :primary-color="primaryColor"
35
35
  :secondary-color="secondaryColor"
36
- :size="size"
37
36
  @click="selectItem(item.value)"
38
37
  >
39
- <OptionIconContainer v-if="item.icon">
40
- <RCIcon
41
- :color="
42
- selectedValue == item.value ? primaryColor : inactiveColor
43
- "
44
- :name="item.icon"
45
- :size="item.iconSize"
46
- />
47
- </OptionIconContainer>
48
38
  {{ item.content }}
49
39
  </SwitchOption>
50
40
  </SwitchWrapper>
@@ -80,12 +70,6 @@
80
70
  import styled from 'vue3-styled-components'
81
71
  import InfoText from '../../infoText'
82
72
  import theme from '../../../assets/theme'
83
- import RCIcon from '../../icon'
84
- const OptionIconContainer = styled.div`
85
- display: flex;
86
- align-items: center;
87
- margin-right: 5px;
88
- `
89
73
  const Container = styled.div``
90
74
 
91
75
  const flexAttrs = {
@@ -105,6 +89,7 @@
105
89
  `
106
90
 
107
91
  const toggleAttrs = {
92
+ size: String,
108
93
  fontColor: String,
109
94
  disabled: Boolean,
110
95
  backgroundColor: String,
@@ -120,16 +105,20 @@
120
105
 
121
106
  const SwitchWrapper = styled('span', toggleAttrs)`
122
107
  display: flex;
123
- align-items: center
124
108
  position: relative;
125
109
  cursor: ${(props) => (props.disabled ? 'not-allowed' : 'pointer')};
110
+ height: ${(props) =>
111
+ props.size === 'medium'
112
+ ? '24px'
113
+ : props.size === 'small'
114
+ ? '16px'
115
+ : '24px'};
126
116
  `
127
117
  const optionAttrs = {
128
118
  isActive: Boolean,
129
119
  primaryColor: String,
130
120
  secondaryColor: String,
131
121
  inactiveColor: String,
132
- size: String,
133
122
  }
134
123
  const SwitchOption = styled('div', optionAttrs)`
135
124
  color: ${(props) =>
@@ -146,13 +135,7 @@
146
135
  font-size: 13px;
147
136
  line-height: 1;
148
137
  text-align: center;
149
- height: ${(props) =>
150
- props.size === 'medium'
151
- ? '24px'
152
- : props.size === 'small'
153
- ? '16px'
154
- : '24px'};
155
- padding: 0 10px;
138
+ padding: 10px;
156
139
  margin-right: -1px;
157
140
  transition: all 0.1s ease-in-out;
158
141
  overflow: hidden;
@@ -186,8 +169,6 @@
186
169
  InfoText,
187
170
  LabelContainer,
188
171
  SwitchOption,
189
- OptionIconContainer,
190
- RCIcon,
191
172
  },
192
173
  props: {
193
174
  label: {
@@ -124,7 +124,6 @@
124
124
  : props.size === 'small'
125
125
  ? '13px'
126
126
  : '16px'};
127
- font-weight: 700;
128
127
  `
129
128
 
130
129
  const ToggleWrapper = styled('span', toggleAttrs)`
@@ -94,7 +94,7 @@ export const stringToNumber = ({
94
94
 
95
95
  export const numberToString = ({ value, numberPrecision, minDecimals }) => {
96
96
  const minimumRounding = minDecimals ? minDecimals : 0
97
- value = parseFloat(value)
97
+ value = !Number.isNaN(parseFloat(value)) ? parseFloat(value) : 0
98
98
  return value.toLocaleString(langForLocaleString(), {
99
99
  minimumFractionDigits: minimumRounding, // removing this for now. Why do we need this to be a minimum amount?
100
100
  maximumFractionDigits:
@@ -1,3 +0,0 @@
1
- <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path d="M2.1068 13.2607L2.95525 10.7154C2.97979 10.6418 3.02115 10.5748 3.07603 10.52L11.5353 2.06066C11.7306 1.8654 12.0472 1.8654 12.2424 2.06066L13.9393 3.75756C14.1346 3.95282 14.1346 4.2694 13.9393 4.46466L5.48004 12.924C5.42515 12.9789 5.35824 13.0202 5.2846 13.0448L2.73925 13.8932C2.34837 14.0235 1.9765 13.6516 2.1068 13.2607Z" stroke="black"/>
3
- </svg>
@@ -1,3 +0,0 @@
1
- <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path fill-rule="evenodd" clip-rule="evenodd" d="M2 2H6V4H2L2 2ZM1 2C1 1.44772 1.44772 1 2 1H6C6.55228 1 7 1.44772 7 2V4C7 4.55228 6.55228 5 6 5H2C1.44772 5 1 4.55228 1 4V2ZM2 7H6V9H2L2 7ZM1 7C1 6.44772 1.44772 6 2 6H6C6.55228 6 7 6.44772 7 7V9C7 9.55228 6.55228 10 6 10H2C1.44772 10 1 9.55228 1 9V7ZM6 12H2L2 14H6V12ZM2 11C1.44772 11 1 11.4477 1 12V14C1 14.5523 1.44772 15 2 15H6C6.55228 15 7 14.5523 7 14V12C7 11.4477 6.55228 11 6 11H2ZM9.5 2.5C9.22386 2.5 9 2.72386 9 3C9 3.27614 9.22386 3.5 9.5 3.5H14.5C14.7761 3.5 15 3.27614 15 3C15 2.72386 14.7761 2.5 14.5 2.5H9.5ZM9 8C9 7.72386 9.22386 7.5 9.5 7.5H14.5C14.7761 7.5 15 7.72386 15 8C15 8.27614 14.7761 8.5 14.5 8.5H9.5C9.22386 8.5 9 8.27614 9 8ZM9.5 12.5C9.22386 12.5 9 12.7239 9 13C9 13.2761 9.22386 13.5 9.5 13.5H14.5C14.7761 13.5 15 13.2761 15 13C15 12.7239 14.7761 12.5 14.5 12.5H9.5Z" fill="white"/>
3
- </svg>
@@ -1,3 +0,0 @@
1
- <svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path fill-rule="evenodd" clip-rule="evenodd" d="M0 1.5C0 0.671573 0.671573 0 1.5 0H3C3.27614 0 3.5 0.223858 3.5 0.5C3.5 0.776142 3.27614 1 3 1H1.5C1.22386 1 1 1.22386 1 1.5V3C1 3.27614 0.776142 3.5 0.5 3.5C0.223858 3.5 0 3.27614 0 3V1.5ZM4.02559 5.17721C3.23749 5.79381 2.68702 6.51738 2.4096 6.92917C2.39111 6.9566 2.37828 6.97568 2.36758 6.99221L2.3632 6.99901L2.36758 7.00581C2.37828 7.02234 2.39112 7.04142 2.4096 7.06885C2.68702 7.48064 3.23749 8.20421 4.02559 8.82081C4.81186 9.43598 5.81038 9.92657 6.99907 9.92657C8.18776 9.92657 9.18628 9.43598 9.97255 8.82081C10.7606 8.20421 11.3111 7.48064 11.5885 7.06885C11.607 7.04142 11.6199 7.02234 11.6306 7.00581L11.6349 6.99901L11.6306 6.99221C11.6199 6.97568 11.607 6.9566 11.5885 6.92917C11.3111 6.51738 10.7606 5.79381 9.97255 5.17721C9.18628 4.56204 8.18776 4.07145 6.99907 4.07145C5.81038 4.07145 4.81186 4.56204 4.02559 5.17721ZM3.40939 4.38962C4.31159 3.68375 5.52122 3.07145 6.99907 3.07145C8.47692 3.07145 9.68655 3.68375 10.5888 4.38962C11.4891 5.09407 12.1075 5.90967 12.4179 6.37043L12.4308 6.38953C12.4917 6.47928 12.5738 6.6004 12.6155 6.77086C12.6496 6.91004 12.6496 7.08798 12.6155 7.22716C12.5738 7.39763 12.4917 7.51874 12.4308 7.60849L12.4179 7.62759C12.1075 8.08835 11.4891 8.90395 10.5888 9.6084C9.68655 10.3143 8.47692 10.9266 6.99907 10.9266C5.52122 10.9266 4.31159 10.3143 3.40939 9.6084C2.509 8.90395 1.89067 8.08835 1.58025 7.62759L1.56733 7.60849C1.50645 7.51874 1.4243 7.39763 1.38262 7.22716C1.34859 7.08798 1.34859 6.91004 1.38262 6.77086C1.4243 6.60039 1.50645 6.47928 1.56733 6.38953L1.58025 6.37043C1.89067 5.90967 2.509 5.09407 3.40939 4.38962ZM6.99907 6.03006C6.37885 6.03006 5.93206 6.49382 5.93206 6.99901C5.93206 7.5042 6.37885 7.96797 6.99907 7.96797C7.61929 7.96797 8.06608 7.5042 8.06608 6.99901C8.06608 6.49382 7.61929 6.03006 6.99907 6.03006ZM4.93206 6.99901C4.93206 5.88164 5.88842 5.03006 6.99907 5.03006C8.10972 5.03006 9.06608 5.88164 9.06608 6.99901C9.06608 8.11638 8.10972 8.96797 6.99907 8.96797C5.88842 8.96797 4.93206 8.11638 4.93206 6.99901ZM12.5 0C13.3284 0 14 0.671573 14 1.5V3C14 3.27614 13.7761 3.5 13.5 3.5C13.2239 3.5 13 3.27614 13 3V1.5C13 1.22386 12.7761 1 12.5 1H11C10.7239 1 10.5 0.776142 10.5 0.5C10.5 0.223858 10.7239 0 11 0H12.5ZM14 12.5C14 13.3284 13.3284 14 12.5 14H11C10.7239 14 10.5 13.7761 10.5 13.5C10.5 13.2239 10.7239 13 11 13H12.5C12.7761 13 13 12.7761 13 12.5V11C13 10.7239 13.2239 10.5 13.5 10.5C13.7761 10.5 14 10.7239 14 11V12.5ZM1.5 14C0.671573 14 0 13.3284 0 12.5V11C0 10.7239 0.223858 10.5 0.5 10.5C0.776142 10.5 1 10.7239 1 11V12.5C1 12.7761 1.22386 13 1.5 13H3C3.27614 13 3.5 13.2239 3.5 13.5C3.5 13.7761 3.27614 14 3 14H1.5Z" fill="#263238"/>
3
- </svg>
@@ -1,7 +0,0 @@
1
- <?xml version="1.0" encoding="utf-8"?><!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
2
- <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
3
- <path d="M5 5.75C5 5.33579 5.33579 5 5.75 5H18.25C18.6642 5 19 5.33579 19 5.75C19 6.16421 18.6642 6.5 18.25 6.5H5.75C5.33579 6.5 5 6.16421 5 5.75Z" fill="white"/>
4
- <path d="M5 9.75C5 9.33579 5.33579 9 5.75 9H18.25C18.6642 9 19 9.33579 19 9.75C19 10.1642 18.6642 10.5 18.25 10.5H5.75C5.33579 10.5 5 10.1642 5 9.75Z" fill="white"/>
5
- <path d="M5 13.75C5 13.3358 5.33579 13 5.75 13H18.25C18.6642 13 19 13.3358 19 13.75C19 14.1642 18.6642 14.5 18.25 14.5H5.75C5.33579 14.5 5 14.1642 5 13.75Z" fill="white"/>
6
- <path d="M5 17.75C5 17.3358 5.33579 17 5.75 17H18.25C18.6642 17 19 17.3358 19 17.75C19 18.1642 18.6642 18.5 18.25 18.5H5.75C5.33579 18.5 5 18.1642 5 17.75Z" fill="white"/>
7
- </svg>
@@ -1,15 +0,0 @@
1
- <?xml version="1.0" encoding="utf-8"?><!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
2
- <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
3
- <path d="M3 6C3 5.44772 3.44772 5 4 5H7C7.55228 5 8 5.44772 8 6C8 6.55228 7.55228 7 7 7H4C3.44772 7 3 6.55228 3 6Z" fill="#212121"/>
4
- <path d="M9.58 6C9.58 5.44772 10.0277 5 10.58 5H13.58C14.1323 5 14.58 5.44772 14.58 6C14.58 6.55228 14.1323 7 13.58 7H10.58C10.0277 7 9.58 6.55228 9.58 6Z" fill="#212121"/>
5
- <path d="M16 6C16 5.44772 16.4477 5 17 5H20C20.5523 5 21 5.44772 21 6C21 6.55228 20.5523 7 20 7H17C16.4477 7 16 6.55228 16 6Z" fill="#212121"/>
6
- <path d="M3 10C3 9.44772 3.44772 9 4 9H7C7.55228 9 8 9.44772 8 10C8 10.5523 7.55228 11 7 11H4C3.44772 11 3 10.5523 3 10Z" fill="#212121"/>
7
- <path d="M9.58 10C9.58 9.44772 10.0277 9 10.58 9H13.58C14.1323 9 14.58 9.44772 14.58 10C14.58 10.5523 14.1323 11 13.58 11H10.58C10.0277 11 9.58 10.5523 9.58 10Z" fill="#212121"/>
8
- <path d="M16 10C16 9.44772 16.4477 9 17 9H20C20.5523 9 21 9.44772 21 10C21 10.5523 20.5523 11 20 11H17C16.4477 11 16 10.5523 16 10Z" fill="#212121"/>
9
- <path d="M3 14C3 13.4477 3.44772 13 4 13H7C7.55228 13 8 13.4477 8 14C8 14.5523 7.55228 15 7 15H4C3.44772 15 3 14.5523 3 14Z" fill="#212121"/>
10
- <path d="M9.58 14C9.58 13.4477 10.0277 13 10.58 13H13.58C14.1323 13 14.58 13.4477 14.58 14C14.58 14.5523 14.1323 15 13.58 15H10.58C10.0277 15 9.58 14.5523 9.58 14Z" fill="#212121"/>
11
- <path d="M16 14C16 13.4477 16.4477 13 17 13H20C20.5523 13 21 13.4477 21 14C21 14.5523 20.5523 15 20 15H17C16.4477 15 16 14.5523 16 14Z" fill="#212121"/>
12
- <path d="M3 18C3 17.4477 3.44772 17 4 17H7C7.55228 17 8 17.4477 8 18C8 18.5523 7.55228 19 7 19H4C3.44772 19 3 18.5523 3 18Z" fill="#212121"/>
13
- <path d="M9.58 18C9.58 17.4477 10.0277 17 10.58 17H13.58C14.1323 17 14.58 17.4477 14.58 18C14.58 18.5523 14.1323 19 13.58 19H10.58C10.0277 19 9.58 18.5523 9.58 18Z" fill="#212121"/>
14
- <path d="M16 18C16 17.4477 16.4477 17 17 17H20C20.5523 17 21 17.4477 21 18C21 18.5523 20.5523 19 20 19H17C16.4477 19 16 18.5523 16 18Z" fill="#212121"/>
15
- </svg>
@@ -1,11 +0,0 @@
1
- <?xml version="1.0" encoding="utf-8"?><!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
2
- <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
3
- <path d="M3 6C3 5.44772 3.44772 5 4 5H10C10.5523 5 11 5.44772 11 6C11 6.55228 10.5523 7 10 7H4C3.44772 7 3 6.55228 3 6Z" fill="white"/>
4
- <path d="M3 10C3 9.44772 3.44772 9 4 9H10C10.5523 9 11 9.44772 11 10C11 10.5523 10.5523 11 10 11H4C3.44772 11 3 10.5523 3 10Z" fill="white"/>
5
- <path d="M3 14C3 13.4477 3.44772 13 4 13H10C10.5523 13 11 13.4477 11 14C11 14.5523 10.5523 15 10 15H4C3.44772 15 3 14.5523 3 14Z" fill="white"/>
6
- <path d="M3 18C3 17.4477 3.44772 17 4 17H10C10.5523 17 11 17.4477 11 18C11 18.5523 10.5523 19 10 19H4C3.44772 19 3 18.5523 3 18Z" fill="white"/>
7
- <path d="M13 6C13 5.44772 13.4477 5 14 5H20C20.5523 5 21 5.44772 21 6C21 6.55228 20.5523 7 20 7H14C13.4477 7 13 6.55228 13 6Z" fill="white"/>
8
- <path d="M13 10C13 9.44772 13.4477 9 14 9H20C20.5523 9 21 9.44772 21 10C21 10.5523 20.5523 11 20 11H14C13.4477 11 13 10.5523 13 10Z" fill="white"/>
9
- <path d="M13 14C13 13.4477 13.4477 13 14 13H20C20.5523 13 21 13.4477 21 14C21 14.5523 20.5523 15 20 15H14C13.4477 15 13 14.5523 13 14Z" fill="white"/>
10
- <path d="M13 18C13 17.4477 13.4477 17 14 17H20C20.5523 17 21 17.4477 21 18C21 18.5523 20.5523 19 20 19H14C13.4477 19 13 18.5523 13 18Z" fill="white"/>
11
- </svg>