@wonderflow/react-components 3.0.0-beta.10 → 3.0.0-beta.11

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.
@@ -35,6 +35,8 @@ export declare type DrawerProps = PropsWithChildren<PropsWithClass> & {
35
35
  side?: 'left' | 'right';
36
36
  /**
37
37
  * Disable the modal behavior of the drawer.
38
+ * If `false`, disable the prop `closeOnClickOutside` and
39
+ * the page is not blocked when the drawer is open.
38
40
  */
39
41
  isModal?: boolean;
40
42
  };
@@ -76,6 +78,8 @@ export declare const Drawer: import("react").ForwardRefExoticComponent<PropsWith
76
78
  side?: "left" | "right" | undefined;
77
79
  /**
78
80
  * Disable the modal behavior of the drawer.
81
+ * If `false`, disable the prop `closeOnClickOutside` and
82
+ * the page is not blocked when the drawer is open.
79
83
  */
80
84
  isModal?: boolean | undefined;
81
85
  } & import("react").RefAttributes<HTMLDivElement>>;
package/list/list.js CHANGED
@@ -19,5 +19,5 @@ export const List = forwardRef(({ as: Wrapper = 'ul', children, marker = 'circle
19
19
  }
20
20
  };
21
21
  const isUnordered = useMemo(() => Wrapper === 'ul', [Wrapper]);
22
- return (_jsx(Wrapper, { ref: forwardedRef, className: clsx(ListClass, className), "data-list-size": dimension, "data-list-ordered": !isUnordered, "data-list-no-marker": hideMarker, ...otherProps, children: Children.map(children, (child) => (_jsxs(Text, { as: "li", size: sizes[dimension].text, children: [isUnordered && (_jsx(Icon, { name: marker, className: Marker, fill: markerColor, dimension: marker !== 'circle' ? sizes[dimension].icon : 16 }, void 0)), child.props.children] }, void 0))) }, void 0));
22
+ return (_jsx(Wrapper, { ref: forwardedRef, className: clsx(ListClass, className), "data-list-size": dimension, "data-list-ordered": !isUnordered, "data-list-no-marker": hideMarker, ...otherProps, children: Children.map(children, (child) => (_jsxs(Text, { as: "li", size: sizes[dimension].text, children: [(isUnordered && !hideMarker) && (_jsx(Icon, { name: marker, className: Marker, fill: markerColor, "data-list-default-marker": marker === 'circle', dimension: marker !== 'circle' ? sizes[dimension].icon : 16 }, void 0)), child.props.children] }, void 0))) }, void 0));
23
23
  });
@@ -1 +1 @@
1
- .List{--marker-size:0.89rem;--marker-gap:0.44rem}.List[data-list-no-marker=true]{--marker-size:0;--marker-gap:0;list-style:none;padding:0}.List[data-list-ordered=false]{list-style:none;padding:0}.List[data-list-ordered=false] li{padding-inline-start:calc(var(--marker-size) + var(--marker-gap));position:relative}.List[data-list-ordered=true] li{padding-inline-start:var(--marker-gap)}.List[data-list-ordered=true] li::marker{color:var(--dimmed-5)}.List[data-list-size=small]{--marker-size:0.77rem;--marker-gap:0.44rem}.List[data-list-size=big]{--marker-size:1.11rem;--marker-gap:0.89rem}.Marker{block-size:var(--marker-size);inline-size:var(--marker-size);left:0;position:absolute;top:calc(var(--marker-size)/2.4)}.List[data-list-size=small] .Marker{top:3px}.List[data-list-size=big] .Marker{top:calc(var(--marker-size)/3)}
1
+ .List{--marker-size:0.89rem;--marker-gap:0.44rem}.List[data-list-ordered=false]{list-style:none;padding:0}.List[data-list-ordered=false] li{padding-inline-start:calc(var(--marker-size) + var(--marker-gap));position:relative}.List[data-list-ordered=true] li{padding-inline-start:var(--marker-gap)}.List[data-list-ordered=true] li::marker{color:var(--dimmed-5)}.List[data-list-size=small]{--marker-size:0.77rem;--marker-gap:0.44rem}.List[data-list-size=big]{--marker-size:1.11rem;--marker-gap:0.89rem}.List[data-list-no-marker=true]{--marker-size:0;--marker-gap:0;list-style:none;padding:0}.Marker{block-size:var(--marker-size);inline-size:var(--marker-size);left:0;position:absolute;top:calc(var(--marker-size)/2.4)}.Marker[data-list-default-marker=true]{transform:scale(.7)}.List[data-list-size=small] .Marker{top:3px}.List[data-list-size=big] .Marker{top:calc(var(--marker-size)/3)}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@wonderflow/react-components",
3
3
  "description": "UI components from Wonderflow's Wanda design system",
4
- "version": "3.0.0-beta.10",
4
+ "version": "3.0.0-beta.11",
5
5
  "author": "Wonderflow",
6
6
  "license": "MIT",
7
7
  "main": "index.js",
@@ -25,7 +25,7 @@
25
25
  "bugs": {
26
26
  "url": "https://github.com/wonderflow-bv/react-components/issues"
27
27
  },
28
- "homepage": "https://github.com/wonderflow-bv/react-components#readme",
28
+ "homepage": "https://design.wonderflow.ai/",
29
29
  "browserslist": [
30
30
  "last 2 Chrome versions",
31
31
  "last 2 Firefox versions",
@@ -65,7 +65,7 @@
65
65
  },
66
66
  "dependencies": {
67
67
  "@wonderflow/tokens": "1.3.7",
68
- "ahooks": "3.1.1",
68
+ "ahooks": "3.1.2",
69
69
  "clsx": "1.1.1",
70
70
  "framer-motion": "4.1.17",
71
71
  "postcss": "^8.4.5",
@@ -73,7 +73,7 @@
73
73
  "react-data-table-component": "7.4.6",
74
74
  "react-dom": "^17.0",
75
75
  "react-focus-on": "3.5.4",
76
- "react-loading-skeleton": "3.0.1",
76
+ "react-loading-skeleton": "3.0.2",
77
77
  "react-masonry-css": "1.0.16",
78
78
  "react-paginate": "8.1.0",
79
79
  "react-popper-tooltip": "4.3.1",
@@ -89,8 +89,8 @@
89
89
  },
90
90
  "devDependencies": {
91
91
  "@babel/core": "7.16.5",
92
- "@commitlint/cli": "15.0.0",
93
- "@commitlint/config-conventional": "15.0.0",
92
+ "@commitlint/cli": "16.0.0",
93
+ "@commitlint/config-conventional": "16.0.0",
94
94
  "@semantic-release/exec": "6.0.3",
95
95
  "@semantic-release/git": "10.0.1",
96
96
  "@semantic-release/github": "8.0.2",
@@ -132,15 +132,15 @@
132
132
  "semantic-release": "18.0.1",
133
133
  "storybook-addon-themes": "6.1.0",
134
134
  "storybook-css-modules-preset": "1.1.1",
135
- "style-dictionary": "3.0.3",
135
+ "style-dictionary": "3.1.1",
136
136
  "styled-components": "5.3.3",
137
- "stylelint": "14.1.0",
137
+ "stylelint": "14.2.0",
138
138
  "svgo": "2.8.0",
139
139
  "svgstore": "3.0.1",
140
140
  "typescript": "4.5.4",
141
141
  "typescript-plugin-css-modules": "3.4.0",
142
142
  "webpack": "5.65.0",
143
- "yargs": "17.3.0"
143
+ "yargs": "17.3.1"
144
144
  },
145
145
  "resolutions": {
146
146
  "rc": "1.2.8"
@@ -162,7 +162,12 @@
162
162
  "plugins": [
163
163
  "commit-analyzer-fail-on-no-release",
164
164
  "@semantic-release/release-notes-generator",
165
- "@semantic-release/github",
165
+ [
166
+ "@semantic-release/github",
167
+ {
168
+ "addReleases": true
169
+ }
170
+ ],
166
171
  [
167
172
  "@semantic-release/npm",
168
173
  {
@@ -26,6 +26,10 @@ export declare type StarMeterProps = {
26
26
  * Set the size of the star meter.
27
27
  */
28
28
  dimension?: 'small' | 'regular' | 'big';
29
+ /**
30
+ * Hide the label indicator.
31
+ */
32
+ hideLabel?: boolean;
29
33
  };
30
34
  declare type PolymorphicStarMeter = Polymorphic.ForwardRefComponent<Polymorphic.IntrinsicElement<typeof Stack>, Polymorphic.OwnProps<typeof Stack> & StarMeterProps>;
31
35
  export declare const StarMeter: PolymorphicStarMeter;
@@ -1,10 +1,10 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
2
  import { forwardRef } from 'react';
3
3
  import clsx from 'clsx';
4
4
  import { useUIDSeed } from 'react-uid';
5
5
  import { Text, Stack, Icon } from '../';
6
6
  import { StarMeter as StarMeterClass, Gradient, Icon as IconClass } from './star-meter.module.css';
7
- export const StarMeter = forwardRef(({ className, value = 0, starCount = 5, label, dimension = 'regular', ...otherProps }, forwardedRef) => {
7
+ export const StarMeter = forwardRef(({ className, value = 0, starCount = 5, label, dimension = 'regular', hideLabel = false, ...otherProps }, forwardedRef) => {
8
8
  const uid = useUIDSeed();
9
9
  const labelSize = {
10
10
  small: 14,
@@ -40,5 +40,5 @@ export const StarMeter = forwardRef(({ className, value = 0, starCount = 5, labe
40
40
  return _jsx(Icon, { name: "star", className: IconClass, dimension: 16, fill: fillType }, starIndex);
41
41
  });
42
42
  };
43
- return (_jsxs(Stack, { inline: true, direction: "row", verticalAlign: "center", columnGap: 8, className: clsx(StarMeterClass, className), role: "meter", "aria-valuenow": clamp(value, 0, starCount), "aria-valuemin": 0, "aria-valuemax": starCount, "aria-labelledby": uid('star-meter'), "data-star-meter-dimension": dimension, ref: forwardedRef, ...otherProps, children: [_jsx("svg", { "aria-hidden": "true", className: Gradient, width: "100", height: "50", version: "1.1", xmlns: "http://www.w3.org/2000/svg", children: _jsx("defs", { children: _jsxs("linearGradient", { id: "HalfStar", children: [_jsx("stop", { offset: "0", style: { stopColor: 'var(--star-color)' } }, void 0), _jsx("stop", { offset: "50%", style: { stopColor: 'var(--star-color)' } }, void 0), _jsx("stop", { offset: "50.1%", style: { stopColor: 'var(--star-dimmed-color)' } }, void 0), _jsx("stop", { offset: "100%", style: { stopColor: 'var(--star-dimmed-color)' } }, void 0)] }, void 0) }, void 0) }, void 0), _jsx(Stack, { direction: "row", columnGap: 2, children: starType(starCount, value) }, void 0), _jsx(Text, { dimmed: 6, id: uid('star-meter'), size: labelSize[dimension], weight: "bold", children: label || value.toString() }, void 0)] }, void 0));
43
+ return (_jsxs(Stack, { inline: true, direction: "row", verticalAlign: "center", columnGap: 8, className: clsx(StarMeterClass, className), role: "meter", "aria-valuenow": clamp(value, 0, starCount), "aria-valuemin": 0, "aria-valuemax": starCount, "aria-labelledby": uid('star-meter'), "data-star-meter-dimension": dimension, ref: forwardedRef, ...otherProps, children: [_jsx("svg", { "aria-hidden": "true", className: Gradient, width: "100", height: "50", version: "1.1", xmlns: "http://www.w3.org/2000/svg", children: _jsx("defs", { children: _jsxs("linearGradient", { id: "HalfStar", children: [_jsx("stop", { offset: "0", style: { stopColor: 'var(--star-color)' } }, void 0), _jsx("stop", { offset: "50%", style: { stopColor: 'var(--star-color)' } }, void 0), _jsx("stop", { offset: "50.1%", style: { stopColor: 'var(--star-dimmed-color)' } }, void 0), _jsx("stop", { offset: "100%", style: { stopColor: 'var(--star-dimmed-color)' } }, void 0)] }, void 0) }, void 0) }, void 0), _jsx(Stack, { direction: "row", columnGap: 2, children: starType(starCount, value) }, void 0), _jsx(Text, { dimmed: 6, id: uid('star-meter'), size: labelSize[dimension], weight: "bold", children: !hideLabel && _jsx(_Fragment, { children: label || value.toString() }, void 0) }, void 0)] }, void 0));
44
44
  });
package/text/text.js CHANGED
@@ -7,5 +7,5 @@ export const Text = forwardRef(({ children, className, size, sentiment, dimmed,
7
7
  '--maxW': maxWidth,
8
8
  '--tAlign': textAlign
9
9
  };
10
- return (_jsx(Wrapper, { ref: forwardedRef, "data-text-size": size, "data-text-weight": weight, "data-text-sentiment": sentiment, "data-text-dimmed": dimmed, "data-text-responsive": responsive, className: clsx(TextClass, className), style: { ...dynamicStyle, ...style }, ...otherProps, children: children }, void 0));
10
+ return (_jsx(Wrapper, { ref: forwardedRef, "data-text-size": size, "data-text-weight": weight, "data-text-sentiment": sentiment, "data-text-dimmed": dimmed, "data-text-responsive": size === 14 ? 14 : responsive, className: clsx(TextClass, className), style: { ...dynamicStyle, ...style }, ...otherProps, children: children }, void 0));
11
11
  });
package/themes/dark.css CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Do not edit directly
3
- * Generated on Fri, 24 Dec 2021 14:26:38 GMT
3
+ * Generated on Tue, 28 Dec 2021 08:41:51 GMT
4
4
  */
5
5
 
6
6
  :root {
package/themes/light.css CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Do not edit directly
3
- * Generated on Fri, 24 Dec 2021 14:26:38 GMT
3
+ * Generated on Tue, 28 Dec 2021 08:41:51 GMT
4
4
  */
5
5
 
6
6
  :root {