@ultraviolet/plus 0.5.8 → 0.5.10

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.
@@ -50,6 +50,14 @@ const StyledPriceCell = /*#__PURE__*/_styled(Cell.withComponent('th', {
50
50
  theme
51
51
  }) => PriceCell(theme), " padding:0;");
52
52
  const DEFAULT_UNIT_LIST = ['hours', 'days', 'months'];
53
+ const DescriptionComponent = ({
54
+ description,
55
+ locales
56
+ }) => description === undefined || typeof description === 'string' ? jsx(Text, {
57
+ as: "span",
58
+ variant: "body",
59
+ children: description || locales['estimate.cost.description']
60
+ }) : description;
53
61
  const EstimateCostContent = ({
54
62
  description,
55
63
  alert,
@@ -162,11 +170,10 @@ const EstimateCostContent = ({
162
170
  discount: discount,
163
171
  unit: overlayUnit ?? 'hours',
164
172
  children: children
165
- }) : null, typeof description === 'string' || !description ? jsx(Text, {
166
- as: "span",
167
- variant: "body",
168
- children: description || locales['estimate.cost.description']
169
- }) : description, alert ? jsx(Alert, {
173
+ }) : null, description === false ? null : jsx(DescriptionComponent, {
174
+ description: description,
175
+ locales: locales
176
+ }), alert ? jsx(Alert, {
170
177
  sentiment: alertVariant,
171
178
  title: alertTitle,
172
179
  children: alert
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ultraviolet/plus",
3
- "version": "0.5.8",
3
+ "version": "0.5.10",
4
4
  "description": "Ultraviolet Plus",
5
5
  "homepage": "https://github.com/scaleway/ultraviolet#readme",
6
6
  "repository": {
@@ -33,21 +33,21 @@
33
33
  "default": "./dist/src/index.js"
34
34
  },
35
35
  "peerDependencies": {
36
- "@emotion/react": "11.11.1",
36
+ "@emotion/react": "11.11.3",
37
37
  "@emotion/styled": "11.11.0",
38
38
  "react": "18.2.0",
39
39
  "react-dom": "18.2.0"
40
40
  },
41
41
  "devDependencies": {
42
- "@babel/core": "7.23.6",
42
+ "@babel/core": "7.23.7",
43
43
  "@emotion/babel-plugin": "11.11.0",
44
- "@emotion/react": "11.11.1",
44
+ "@emotion/react": "11.11.3",
45
45
  "@emotion/styled": "11.11.0",
46
46
  "@types/react": "18.2.45",
47
47
  "@types/react-dom": "18.2.18",
48
48
  "react": "18.2.0",
49
49
  "react-dom": "18.2.0",
50
- "@ultraviolet/icons": "2.7.3"
50
+ "@ultraviolet/icons": "2.7.5"
51
51
  },
52
52
  "dependencies": {
53
53
  "@uiw/codemirror-extensions-langs": "4.21.21",
@@ -56,9 +56,10 @@
56
56
  "react-flatten-children": "1.1.2",
57
57
  "react-intersection-observer": "9.5.3",
58
58
  "@ultraviolet/themes": "1.6.0",
59
- "@ultraviolet/ui": "1.29.2"
59
+ "@ultraviolet/ui": "1.29.4"
60
60
  },
61
61
  "scripts": {
62
- "build": "rollup -c ../../rollup.config.mjs"
62
+ "build": "rollup -c ../../rollup.config.mjs",
63
+ "typecheck": "tsc --noEmit"
63
64
  }
64
65
  }