@enki-tek/fms-web-components 0.1.34 → 0.1.36

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.
@@ -1,42 +1,17 @@
1
1
  const colors = [
2
- "#D12771",
3
- "#CB459E",
4
- "#FA72C9",
5
- "#750E13",
6
- "#A2191F",
7
- "#DA1E28",
8
- "#FA4D56",
9
- "#FF8389",
10
- "#FFB3B8",
11
- "#003A6D",
12
- "#00539A",
13
- "#0072C3",
14
- "#1192E8",
15
- "#33B1FF",
16
- "#82CFFF",
17
- "#491D8B",
18
- "#6929C4",
19
- "#8A3FFC",
20
- "#A56EFF",
21
- "#BE95FF",
22
- "#D4BBFF",
23
- "#004144",
24
- "#005D5D",
25
- "#007D79",
26
- "#009D9A",
27
- "#08BDBA",
28
- "#3DDBD9",
29
- "#C18300",
30
- "#D79200",
31
- "#ECA206",
32
- "#F8B21E",
33
- "#FAC045",
34
- "#FFD16D",
35
- "#8BBC05",
36
- "#99CE08"
2
+ "#E02899",
3
+ "#FF8800",
4
+ "#93E028",
5
+ "#70B6F8",
6
+ "#7821F1",
7
+ "#F1C721"
37
8
  ];
38
9
 
39
10
  export const getChartColors = (number = 1) => {
11
+ if (number > 5) {
12
+ return colors;
13
+ }
14
+
40
15
  return colors.slice(0, number);
41
16
  }
42
17
 
@@ -15,7 +15,7 @@
15
15
  });
16
16
  </script>
17
17
 
18
- <div class="enki-sortable-grid" {id}>
18
+ <div class="enki-sortable-grid gap-3 mt-3" {id}>
19
19
  <slot />
20
20
  </div>
21
21
 
@@ -5,7 +5,7 @@
5
5
  export let icon = 'null';
6
6
  </script>
7
7
 
8
- <div class=" m-2 card">
8
+ <div class="card">
9
9
  <div class="row-flex">
10
10
  <SensorWidgetTitle sensorName={title} {icon} />
11
11
  <div class="col">
@@ -5,7 +5,7 @@
5
5
  export let sensor = false;
6
6
  </script>
7
7
 
8
- <div class="m-2 {sensor ? "col-12" : "col-12 col-md-6 col-sm-6 col-lg-6 col-xl-3" } ">
8
+ <div class=" {sensor ? "col-12" : "col-12 col-md-6 col-sm-6 col-lg-6 col-xl-3" } ">
9
9
  <div class="{notify ? 'blip' : ''} card {className} {small ? 'card-mini' : ''}">
10
10
  <slot />
11
11
  </div>
@@ -8,12 +8,18 @@
8
8
  <div class="mt-1">
9
9
  <Row>
10
10
  <Col>
11
- <div class={Number(index) > 0 ? 'box1 mb-1' : 'box2 mb-1'}>
12
- <div class={Number(index) > 0 ? 'p-1 px-2 text-success' : 'p-1 px-2 text-danger'}>
13
- <i class="material-icons index">{Number(index) > 0 ? 'call_made' : 'call_received'}</i>
14
- {Number(index) > 0 ? '+' + index : index}
11
+ {#if index === false}
12
+ <div class="box1 mb-1">
13
+ <div class="p-1 px-2 text-danger">NA</div>
15
14
  </div>
16
- </div>
15
+ {:else}
16
+ <div class={Number(index) > 0 ? 'box1 mb-1' : 'box2 mb-1'}>
17
+ <div class={Number(index) > 0 ? 'p-1 px-2 text-success' : 'p-1 px-2 text-danger'}>
18
+ <i class="material-icons index">{Number(index) > 0 ? 'call_made' : 'call_received'}</i>
19
+ {Number(index) > 0 ? '+' + index : index}
20
+ </div>
21
+ </div>
22
+ {/if}
17
23
  <div class="text fw-normal">{text}</div></Col
18
24
  >
19
25
  <Col><div class="float-end value fw-bold">{value}</div></Col>
@@ -26,7 +26,7 @@
26
26
  : cardLength} col-xl-{cardLength}"
27
27
  >
28
28
  <div bind:this={element}>
29
- <div class="m-2 card">
29
+ <div class="card">
30
30
  <Row>
31
31
  <Col md="10">
32
32
  <div class="title fw-normal">{title}</div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@enki-tek/fms-web-components",
3
- "version": "0.1.34",
3
+ "version": "0.1.36",
4
4
  "devDependencies": {
5
5
  "@storybook/addon-essentials": "^7.6.14",
6
6
  "@storybook/addon-interactions": "^7.6.14",