@vixoniccom/footbal-score 1.0.2-beta.2 → 1.0.2-beta.4
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 +9 -0
- package/build.zip +0 -0
- package/configuration.json +26 -0
- package/package.json +2 -1
- package/src/App.tsx +12 -3
- package/src/components/table-fixture/Results.tsx +3 -6
- package/src/contex/configureContext/ConfigureProvider.tsx +3 -1
- package/src/contex/configureContext/configureReducer.ts +2 -1
- package/src/parameters.d.ts +2 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
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
|
+
### [1.0.2-beta.4](https://gitlab.com/mandomedio/vixonic/football-score/compare/v1.0.2-beta.3...v1.0.2-beta.4) (2022-12-07)
|
|
6
|
+
|
|
7
|
+
### [1.0.2-beta.3](https://gitlab.com/mandomedio/vixonic/football-score/compare/v1.0.2-beta.2...v1.0.2-beta.3) (2022-12-06)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Bug Fixes
|
|
11
|
+
|
|
12
|
+
* **release:** isNumber method was added to check if match is on penalties phase or not ([d7174d4](https://gitlab.com/mandomedio/vixonic/football-score/commit/d7174d448aad330f5ca2d9dcaef44ebc1975ea63))
|
|
13
|
+
|
|
5
14
|
### [1.0.2-beta.2](https://gitlab.com/mandomedio/vixonic/football-score/compare/v1.0.2-beta.1...v1.0.2-beta.2) (2022-12-06)
|
|
6
15
|
|
|
7
16
|
### [1.0.2-beta.1](https://gitlab.com/mandomedio/vixonic/football-score/compare/v1.0.2-beta.0...v1.0.2-beta.1) (2022-12-05)
|
package/build.zip
CHANGED
|
Binary file
|
package/configuration.json
CHANGED
|
@@ -140,6 +140,32 @@
|
|
|
140
140
|
"id": "msj0",
|
|
141
141
|
"label": "Sin Partidos",
|
|
142
142
|
"description": "Mensaje que se muestra cuando no hay partidos."
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"type": "text-format",
|
|
146
|
+
"id": "formatMjs",
|
|
147
|
+
"label": "Formato Status"
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
"id": "alignVerticalMsj",
|
|
151
|
+
"type": "select-input",
|
|
152
|
+
"required": true,
|
|
153
|
+
"label": "Alineación vertical texto sin partidos",
|
|
154
|
+
"defaultValue": "center",
|
|
155
|
+
"items": [
|
|
156
|
+
{
|
|
157
|
+
"label": "Arriba",
|
|
158
|
+
"value": "flex-start"
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
"label": "Centro",
|
|
162
|
+
"value": "center"
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
"label": "Abajo",
|
|
166
|
+
"value": "flex-end"
|
|
167
|
+
}
|
|
168
|
+
]
|
|
143
169
|
}
|
|
144
170
|
]
|
|
145
171
|
},
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vixoniccom/footbal-score",
|
|
3
3
|
"alias": "Resultados Deportivos",
|
|
4
|
-
"version": "1.0.2-beta.
|
|
4
|
+
"version": "1.0.2-beta.4",
|
|
5
5
|
"description": "Muestra resultados en vivo de fútbol.",
|
|
6
6
|
"main": "main.js",
|
|
7
7
|
"author": "",
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
"axios": "^0.27.2",
|
|
21
21
|
"jquery": "^3.6.0",
|
|
22
22
|
"localforage": "^1.10.0",
|
|
23
|
+
"lodash": "^4.17.21",
|
|
23
24
|
"moment": "^2.29.3",
|
|
24
25
|
"prop-types": "^15.8.1",
|
|
25
26
|
"react": "^17.0.2",
|
package/src/App.tsx
CHANGED
|
@@ -113,11 +113,20 @@ export const App = ({ data, start }: Props) => {
|
|
|
113
113
|
right: 0,
|
|
114
114
|
backgroundImage: backgroundImageState,
|
|
115
115
|
backgroundSize: '100% 100%',
|
|
116
|
-
padding: padding
|
|
116
|
+
padding: padding,
|
|
117
|
+
display: 'flex',
|
|
118
|
+
alignItems: parameters.alignVerticalMsj,
|
|
117
119
|
}}
|
|
118
120
|
>
|
|
119
|
-
<FontLoader paths={['nameFormat.font', 'descriptionFormat.font', 'dateDayFormat.font', 'dateMonthFormat.font']} parameters={parameters} downloadsPath={downloadsPath} />
|
|
120
|
-
<
|
|
121
|
+
<FontLoader paths={['nameFormat.font', 'descriptionFormat.font', 'dateDayFormat.font', 'dateMonthFormat.font', 'formatMjs.font']} parameters={parameters} downloadsPath={downloadsPath} />
|
|
122
|
+
<div style={{
|
|
123
|
+
display: 'flex',
|
|
124
|
+
position: 'relative',
|
|
125
|
+
flex: '1 1 0%',
|
|
126
|
+
flexDirection: 'column',
|
|
127
|
+
}}>
|
|
128
|
+
<FormattedText text={msj0 || "Sin partidos"} format={parameters.formatMjs} />
|
|
129
|
+
</div>
|
|
121
130
|
</div>
|
|
122
131
|
|
|
123
132
|
)
|
|
@@ -1,28 +1,25 @@
|
|
|
1
1
|
import React, { useContext } from 'react'
|
|
2
2
|
import { ConfigureContext } from '../../contex/configureContext/ConfigureContext'
|
|
3
3
|
import { FormattedText } from '../FormattedText'
|
|
4
|
+
import { isNumber } from 'lodash'
|
|
4
5
|
|
|
5
6
|
export const Results = ({ goals, score }: any) => {
|
|
6
7
|
|
|
7
8
|
const { configureState } = useContext(ConfigureContext)
|
|
8
9
|
const { parameters } = configureState
|
|
9
|
-
|
|
10
|
-
|
|
11
10
|
return (
|
|
12
11
|
<div style={{
|
|
13
12
|
display: 'flex',
|
|
14
13
|
justifyContent: 'center',
|
|
15
14
|
}}>
|
|
16
15
|
{
|
|
17
|
-
( score.penalty.home
|
|
18
|
-
<FormattedText text={`(${score.penalty.home})`} format={parameters.goalsFormat} />
|
|
16
|
+
isNumber(score.penalty.home) ? <FormattedText text={`(${score.penalty.home})`} format={parameters.goalsFormat} /> : ''
|
|
19
17
|
}
|
|
20
18
|
<FormattedText text={goals.home ? goals.home : 0} format={parameters.goalsFormat} />
|
|
21
19
|
<FormattedText text={"-"} format={parameters.goalsFormat} />
|
|
22
20
|
<FormattedText text={goals.away ? goals.away : 0} format={parameters.goalsFormat} />
|
|
23
21
|
{
|
|
24
|
-
(score.penalty.away
|
|
25
|
-
<FormattedText text={`(${score.penalty.away})`} format={parameters.goalsFormat} />
|
|
22
|
+
isNumber(score.penalty.away) ? <FormattedText text={`(${score.penalty.away})`} format={parameters.goalsFormat} /> : ''
|
|
26
23
|
}
|
|
27
24
|
</div>
|
|
28
25
|
)
|
|
@@ -65,7 +65,9 @@ const INITIAL_STATE: VixonicData = {
|
|
|
65
65
|
widthTime: "200px",
|
|
66
66
|
timeEnd: "7pm",
|
|
67
67
|
timeStart: "6am",
|
|
68
|
-
|
|
68
|
+
formatMjs: { font: { filename: '', id: '', _isAsset: true }, fontSize: 3.8, alignment: { horizontal: "center" }, fontColor: "" },
|
|
69
|
+
alignVerticalMsj: "center",
|
|
70
|
+
}
|
|
69
71
|
}
|
|
70
72
|
|
|
71
73
|
interface props {
|
|
@@ -52,7 +52,8 @@ export const parameterReducer = (state: VixonicData, action: ConfigureAction) =>
|
|
|
52
52
|
widthStatus: parameters.widthStatus,
|
|
53
53
|
timeStart: parameters.timeStart,
|
|
54
54
|
timeEnd: parameters.timeEnd,
|
|
55
|
-
|
|
55
|
+
formatMjs: parameters.formatMjs,
|
|
56
|
+
alignVerticalMsj: parameters.alignVerticalMsj
|
|
56
57
|
}
|
|
57
58
|
}
|
|
58
59
|
default:
|