@obosbbl/grunnmuren-react 2.0.0-canary.26 → 2.0.0-canary.27

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.
Files changed (2) hide show
  1. package/dist/index.mjs +8 -7
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -330,11 +330,12 @@ function ErrorMessage(props) {
330
330
  });
331
331
  }
332
332
 
333
+ const descriptionClasses = 'text-sm font-light leading-6';
333
334
  function Description(props) {
334
335
  const { className, ...restProps } = props;
335
336
  return /*#__PURE__*/ jsx(Text, {
336
337
  ...restProps,
337
- className: cx(className, 'text-sm font-light leading-6'),
338
+ className: cx(className, descriptionClasses),
338
339
  slot: "description"
339
340
  });
340
341
  }
@@ -394,12 +395,12 @@ function Checkbox(props, ref) {
394
395
  children
395
396
  ]
396
397
  }),
397
- description && /*#__PURE__*/ jsx(Description, {
398
- className: "block",
399
- children: /*#__PURE__*/ jsx("div", {
400
- id: descriptionId,
401
- children: description
402
- })
398
+ description && // {/* Use a div instead of the Description component to avoid infinite re-render loops in React until this bug in RAC is fixed: https://github.com/adobe/react-spectrum/issues/6229 */}
399
+ /*#__PURE__*/ jsx("div", {
400
+ id: descriptionId,
401
+ slot: "description",
402
+ className: cx('block', descriptionClasses),
403
+ children: description
403
404
  }),
404
405
  errorMessage && /*#__PURE__*/ jsx(ErrorMessage, {
405
406
  className: "mt-2 block",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@obosbbl/grunnmuren-react",
3
- "version": "2.0.0-canary.26",
3
+ "version": "2.0.0-canary.27",
4
4
  "description": "Grunnmuren components in React",
5
5
  "repository": {
6
6
  "url": "https://github.com/code-obos/grunnmuren"