@vixoniccom/kpi-chart 0.0.2-dev.11 → 0.0.2-dev.12

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/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.0.2-dev.12](https://github.com/Vixonic/store-sheets-kpi/compare/v0.0.2-dev.11...v0.0.2-dev.12) (2026-10-30)
6
+
7
+
8
+ ### Features
9
+
10
+ * VXD-545 organize appearance configuration into sections and blocks ([d5cc6f6](https://github.com/Vixonic/store-sheets-kpi/commit/d5cc6f63e08609856489fbb97056dab070d74503))
11
+
5
12
  ### [0.0.2-dev.11](https://github.com/Vixonic/store-sheets-kpi/compare/v0.0.2-dev.8...v0.0.2-dev.11) (2026-10-28)
6
13
 
7
14
 
package/build.zip CHANGED
Binary file
@@ -1,73 +1,143 @@
1
1
  import {
2
+ Block,
2
3
  ColorPicker,
3
4
  Group,
4
- Label,
5
- NumberInput,
5
+ MarginInput,
6
+ Section,
6
7
  SelectAssetKna,
8
+ SelectInput,
7
9
  Switch,
8
10
  TextFormat,
9
11
  } from "@vixoniccom/modules";
12
+ import { ShowValidations } from "../utils";
10
13
 
11
14
  export const appearanceGroup = new Group({
12
15
  id: "appearanceGroup",
13
16
  label: "Apariencia",
14
17
  items: [
15
- new Label({ label: 'Diseño' }),
16
- new ColorPicker({
17
- id: 'backgroundColor',
18
- label: 'Color de fondo',
19
- description: 'Si subes una imagen de fondo, esta tapa el color.'
18
+ new Section({
19
+ id: 'designSection',
20
+ label: 'Diseño',
21
+ muiIcon: 'Brush',
22
+ items: [
23
+ new Block({
24
+ id: 'designBlock',
25
+ items: [
26
+ new ColorPicker({
27
+ id: 'backgroundColor',
28
+ label: 'Color de fondo',
29
+ description: 'Si subes una imagen de fondo, esta tapa el color.',
30
+ inLine: true,
31
+ }),
32
+ new SelectAssetKna({
33
+ id: 'backgroundImage',
34
+ label: 'Imagen de fondo',
35
+ extensions: ['jpg', 'png'],
36
+ multiple: false,
37
+ description: 'JPG o PNG 16:9. Usa imágenes sobrias para que el gráfico se lea.',
38
+ }),
39
+ ],
40
+ }),
41
+ ],
20
42
  }),
21
- new SelectAssetKna({
22
- id: 'backgroundImage',
23
- label: 'Imagen de fondo',
24
- extensions: ['jpg', 'png'],
25
- multiple: false,
26
- description: 'JPG o PNG 16:9. Usa imágenes sobrias para que el gráfico se lea.',
43
+ new Section({
44
+ id: 'colorsSection',
45
+ label: 'Colores',
46
+ muiIcon: 'ColorLens',
47
+ items: [
48
+ new Block({
49
+ id: 'colorsBlock',
50
+ items: [
51
+ new Switch({
52
+ id: 'showGuidelines',
53
+ label: 'Mostrar líneas guía y eje',
54
+ defaultValue: false
55
+ }),
56
+ new ColorPicker({
57
+ id: 'guidelineColor',
58
+ label: 'Líneas guía',
59
+ show: ShowValidations.showGuidelines
60
+ }),
61
+ ],
62
+ }),
63
+ ],
27
64
  }),
28
- new Label({ label: 'Colores' }),
29
- new Switch({
30
- id: 'showGuidelines',
31
- label: 'Mostrar líneas guía y eje',
32
- defaultValue: false
65
+ new Section({
66
+ id: 'textSection',
67
+ label: 'Texto',
68
+ muiIcon: 'Title',
69
+ items: [
70
+ new Block({
71
+ id: 'titleTextBlock',
72
+ label: 'Título',
73
+ description: 'Nombre del gráfico, arriba.',
74
+ items: [
75
+ new TextFormat({
76
+ id: 'titleTypography',
77
+ label: 'Tipografía',
78
+ hidePicker: true,
79
+ }),
80
+ new SelectInput({
81
+ id: 'titleAlignment',
82
+ label: 'Alineación',
83
+ items: [{ label: 'Izquierda', value: 'right' }, { label: 'Derecha', value: 'left'}],
84
+ inLine: true,
85
+ }),
86
+ new ColorPicker({
87
+ id: 'titleFontColor',
88
+ label: 'Color',
89
+ inLine: true,
90
+ }),
91
+ ],
92
+ }),
93
+ new Block({
94
+ id: 'tagTextBlock',
95
+ label: 'Etiquetas',
96
+ description: 'Categorías, leyenda y n´mero de los ejes.',
97
+ items: [
98
+ new TextFormat({
99
+ id: 'tagsTypography',
100
+ label: 'Tipografía',
101
+ hidePicker: true,
102
+ }),
103
+ new ColorPicker({
104
+ id: 'legendFontColor',
105
+ label: 'Color',
106
+ inLine: true,
107
+ }),
108
+ ],
109
+ divider: true,
110
+ }),
111
+ new Block({
112
+ id: 'valuesTextBlock',
113
+ label: 'Valores',
114
+ description: 'Cifra de cada barra, punto o porción.',
115
+ items: [
116
+ new TextFormat({
117
+ id: 'valuesTypography',
118
+ label: 'Tipografía',
119
+ hidePicker: true,
120
+ }),
121
+ ],
122
+ divider: true,
123
+ }),
124
+ ],
33
125
  }),
34
- new Label({ label: 'Texto' }),
35
- new TextFormat({
36
- id: 'titleTypography',
37
- label: 'Tipografía del título'
126
+ new Section({
127
+ id: 'marginSection',
128
+ label: 'Márgenes',
129
+ muiIcon: 'FitScreen',
130
+ items: [
131
+ new Block({
132
+ id: 'marginBlock',
133
+ items: [
134
+ new MarginInput({
135
+ id: 'appMargin',
136
+ defaultValue: { top: 0, left: 0, bottom: 0, right: 0 }
137
+ }),
138
+ ],
139
+ }),
140
+ ],
38
141
  }),
39
- new TextFormat({
40
- id: 'tagsTypography',
41
- label: 'Tipografía de las etiquetas'
42
- }),
43
- new ColorPicker({
44
- id: 'legendFontColor',
45
- label: 'Color de fuente de la leyenda'
46
- }),
47
- new TextFormat({
48
- id: 'valuesTypography',
49
- label: 'Tipografía de los valores',
50
- }),
51
- new Label({ label: 'Márgenes' }),
52
- new NumberInput({
53
- id: 'marginTop',
54
- label: 'Superior',
55
- description: 'En px.',
56
- }),
57
- new NumberInput({
58
- id: 'marginLeft',
59
- label: 'Izquierdo',
60
- description: 'En px.',
61
- }),
62
- new NumberInput({
63
- id: 'marginRight',
64
- label: 'Derecho',
65
- description: 'En px.',
66
- }),
67
- new NumberInput({
68
- id: 'marginBottom',
69
- label: 'Inferior',
70
- description: 'En px.',
71
- }),
72
- ]
142
+ ],
73
143
  })
@@ -2,18 +2,16 @@ import {
2
2
  Group,
3
3
  ServiceInput,
4
4
  } from "@vixoniccom/modules";
5
- import { SheetSelectionId } from "../utils";
6
5
 
7
6
  export const chartGroup = new Group({
8
7
  id: "chartGroup",
9
8
  label: "Gráficos",
9
+ groupType: "sheetSelection",
10
10
  items: [
11
- SheetSelectionId,
12
11
  new ServiceInput({
13
12
  id: 'documentServices',
14
13
  label: 'Planillas',
15
14
  serviceType: 'SheetsReaderService',
16
- required: true,
17
15
  }),
18
16
  ],
19
17
  })
@@ -1,14 +1,5 @@
1
- import { Switch } from "@vixoniccom/modules"
2
-
3
1
  const showGuidelines = "{{showGuidelines}} === true"
4
2
 
5
3
  export const ShowValidations = {
6
4
  showGuidelines,
7
5
  }
8
-
9
- //Identificador para vista de configuración de planillas. Esconder siempre.
10
- export const SheetSelectionId = new Switch({
11
- id: 'isSheetSelection',
12
- label: 'isSheetSelection',
13
- show: 'false'
14
- })
@@ -5,20 +5,14 @@
5
5
  "label": "Gráficos",
6
6
  "type": "group",
7
7
  "items": [
8
- {
9
- "id": "isSheetSelection",
10
- "label": "isSheetSelection",
11
- "show": "false",
12
- "type": "switch"
13
- },
14
8
  {
15
9
  "id": "documentServices",
16
10
  "label": "Planillas",
17
11
  "type": "service-input",
18
- "serviceType": "SheetsReaderService",
19
- "required": true
12
+ "serviceType": "SheetsReaderService"
20
13
  }
21
- ]
14
+ ],
15
+ "groupType": "sheetSelection"
22
16
  },
23
17
  {
24
18
  "id": "appearanceGroup",
@@ -26,89 +20,181 @@
26
20
  "type": "group",
27
21
  "items": [
28
22
  {
29
- "type": "label",
30
- "label": "Diseño"
31
- },
32
- {
33
- "id": "backgroundColor",
34
- "label": "Color de fondo",
35
- "type": "color-picker",
36
- "description": "Si subes una imagen de fondo, esta tapa el color.",
37
- "output": "auto"
38
- },
39
- {
40
- "id": "backgroundImage",
41
- "label": "Imagen de fondo",
42
- "type": "select-asset-kna-input",
43
- "description": "JPG o PNG 16:9. Usa imágenes sobrias para que el gráfico se lea.",
44
- "extensions": [
45
- "jpg",
46
- "png"
47
- ],
48
- "multiple": false
49
- },
50
- {
51
- "type": "label",
52
- "label": "Colores"
53
- },
54
- {
55
- "id": "showGuidelines",
56
- "label": "Mostrar líneas guía y eje",
57
- "type": "switch",
58
- "defaultValue": false
59
- },
60
- {
61
- "type": "label",
62
- "label": "Texto"
63
- },
64
- {
65
- "id": "titleTypography",
66
- "label": "Tipografía del título",
67
- "type": "text-format"
68
- },
69
- {
70
- "id": "tagsTypography",
71
- "label": "Tipografía de las etiquetas",
72
- "type": "text-format"
73
- },
74
- {
75
- "id": "legendFontColor",
76
- "label": "Color de fuente de la leyenda",
77
- "type": "color-picker",
78
- "output": "auto"
79
- },
80
- {
81
- "id": "valuesTypography",
82
- "label": "Tipografía de los valores",
83
- "type": "text-format"
84
- },
85
- {
86
- "type": "label",
87
- "label": "Márgenes"
88
- },
89
- {
90
- "id": "marginTop",
91
- "label": "Superior",
92
- "type": "number-input",
93
- "description": "En px."
23
+ "id": "designSection",
24
+ "label": "Diseño",
25
+ "type": "section",
26
+ "labelContent": false,
27
+ "muiIcon": "Brush",
28
+ "items": [
29
+ {
30
+ "type": "block",
31
+ "id": "designBlock",
32
+ "divider": false,
33
+ "items": [
34
+ {
35
+ "id": "backgroundColor",
36
+ "label": "Color de fondo",
37
+ "type": "color-picker",
38
+ "description": "Si subes una imagen de fondo, esta tapa el color.",
39
+ "output": "auto",
40
+ "inLine": true
41
+ },
42
+ {
43
+ "id": "backgroundImage",
44
+ "label": "Imagen de fondo",
45
+ "type": "select-asset-kna-input",
46
+ "description": "JPG o PNG 16:9. Usa imágenes sobrias para que el gráfico se lea.",
47
+ "extensions": [
48
+ "jpg",
49
+ "png"
50
+ ],
51
+ "multiple": false
52
+ }
53
+ ]
54
+ }
55
+ ]
94
56
  },
95
57
  {
96
- "id": "marginLeft",
97
- "label": "Izquierdo",
98
- "type": "number-input",
99
- "description": "En px."
58
+ "id": "colorsSection",
59
+ "label": "Colores",
60
+ "type": "section",
61
+ "labelContent": false,
62
+ "muiIcon": "ColorLens",
63
+ "items": [
64
+ {
65
+ "type": "block",
66
+ "id": "colorsBlock",
67
+ "divider": false,
68
+ "items": [
69
+ {
70
+ "id": "showGuidelines",
71
+ "label": "Mostrar líneas guía y eje",
72
+ "type": "switch",
73
+ "defaultValue": false
74
+ },
75
+ {
76
+ "id": "guidelineColor",
77
+ "label": "Líneas guía",
78
+ "show": "{{showGuidelines}} === true",
79
+ "type": "color-picker",
80
+ "output": "auto",
81
+ "inLine": true
82
+ }
83
+ ]
84
+ }
85
+ ]
100
86
  },
101
87
  {
102
- "id": "marginRight",
103
- "label": "Derecho",
104
- "type": "number-input",
105
- "description": "En px."
88
+ "id": "textSection",
89
+ "label": "Texto",
90
+ "type": "section",
91
+ "labelContent": false,
92
+ "muiIcon": "Title",
93
+ "items": [
94
+ {
95
+ "type": "block",
96
+ "id": "titleTextBlock",
97
+ "label": "Título",
98
+ "description": "Nombre del gráfico, arriba.",
99
+ "divider": false,
100
+ "items": [
101
+ {
102
+ "id": "titleTypography",
103
+ "label": "Tipografía",
104
+ "type": "text-format",
105
+ "hidePicker": true
106
+ },
107
+ {
108
+ "id": "titleAlignment",
109
+ "label": "Alineación",
110
+ "type": "select-input",
111
+ "items": [
112
+ {
113
+ "label": "Izquierda",
114
+ "value": "right"
115
+ },
116
+ {
117
+ "label": "Derecha",
118
+ "value": "left"
119
+ }
120
+ ],
121
+ "inLine": true
122
+ },
123
+ {
124
+ "id": "titleFontColor",
125
+ "label": "Color",
126
+ "type": "color-picker",
127
+ "output": "auto",
128
+ "inLine": true
129
+ }
130
+ ]
131
+ },
132
+ {
133
+ "type": "block",
134
+ "id": "tagTextBlock",
135
+ "label": "Etiquetas",
136
+ "description": "Categorías, leyenda y n´mero de los ejes.",
137
+ "divider": true,
138
+ "items": [
139
+ {
140
+ "id": "tagsTypography",
141
+ "label": "Tipografía",
142
+ "type": "text-format",
143
+ "hidePicker": true
144
+ },
145
+ {
146
+ "id": "legendFontColor",
147
+ "label": "Color",
148
+ "type": "color-picker",
149
+ "output": "auto",
150
+ "inLine": true
151
+ }
152
+ ]
153
+ },
154
+ {
155
+ "type": "block",
156
+ "id": "valuesTextBlock",
157
+ "label": "Valores",
158
+ "description": "Cifra de cada barra, punto o porción.",
159
+ "divider": true,
160
+ "items": [
161
+ {
162
+ "id": "valuesTypography",
163
+ "label": "Tipografía",
164
+ "type": "text-format",
165
+ "hidePicker": true
166
+ }
167
+ ]
168
+ }
169
+ ]
106
170
  },
107
171
  {
108
- "id": "marginBottom",
109
- "label": "Inferior",
110
- "type": "number-input",
111
- "description": "En px."
172
+ "id": "marginSection",
173
+ "label": "Márgenes",
174
+ "type": "section",
175
+ "labelContent": false,
176
+ "muiIcon": "FitScreen",
177
+ "items": [
178
+ {
179
+ "type": "block",
180
+ "id": "marginBlock",
181
+ "divider": false,
182
+ "items": [
183
+ {
184
+ "id": "appMargin",
185
+ "label": "",
186
+ "type": "margin-input",
187
+ "unit": "px",
188
+ "defaultValue": {
189
+ "top": 0,
190
+ "left": 0,
191
+ "bottom": 0,
192
+ "right": 0
193
+ }
194
+ }
195
+ ]
196
+ }
197
+ ]
112
198
  }
113
199
  ]
114
200
  }
package/package.json CHANGED
@@ -8,7 +8,7 @@
8
8
  "author": {
9
9
  "name": "Lorenzo Alfaro Bravo"
10
10
  },
11
- "version": "0.0.2-dev.11",
11
+ "version": "0.0.2-dev.12",
12
12
  "scripts": {
13
13
  "prepublish": "vixonic-module-packager --mode=build",
14
14
  "watch": "vixonic-module-packager --mode=watch",
@@ -27,8 +27,8 @@
27
27
  "devDependencies": {
28
28
  "@types/react": "^17.0.2",
29
29
  "@types/react-dom": "^17.0.11",
30
- "@vixoniccom/module-packager": "2.15.0-dev.7",
31
- "@vixoniccom/modules": "^2.26.4",
30
+ "@vixoniccom/module-packager": "2.15.0-dev.8",
31
+ "@vixoniccom/modules": "2.27.0-dev.7",
32
32
  "standard-version": "^9.5.0"
33
33
  }
34
34
  }