Socket
Socket
Sign inDemoInstall

@atlaskit/radio

Package Overview
Dependencies
91
Maintainers
1
Versions
125
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 6.0.0 to 6.0.1

6

CHANGELOG.md
# @atlaskit/radio
## 6.0.1
### Patch Changes
- [#61610](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/61610) [`6b5d817a38e9`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/6b5d817a38e9) - Expose a `testId` on `RadioGroup`. This applies `data-testid` to the root level element, as well as propagates the value to `Radio` children.
## 6.0.0

@@ -4,0 +10,0 @@

7

dist/cjs/radio-group.js

@@ -31,3 +31,4 @@ "use strict";

analyticsContext = props.analyticsContext,
ariaLabelledBy = props['aria-labelledby'];
ariaLabelledBy = props['aria-labelledby'],
testId = props.testId;
var _useState = (0, _react.useState)(propValue !== undefined ? propValue : defaultValue),

@@ -49,3 +50,4 @@ _useState2 = (0, _slicedToArray2.default)(_useState, 2),

role: "radiogroup",
"aria-labelledby": ariaLabelledBy
"aria-labelledby": ariaLabelledBy,
"data-testid": testId
}, options.map(function (_ref, index) {

@@ -64,2 +66,3 @@ var optionProps = (0, _extends2.default)({}, ((0, _objectDestructuringEmpty2.default)(_ref), _ref));

isChecked: isChecked,
testId: optionProps.testId || testId,
isRequired: isRequired,

@@ -66,0 +69,0 @@ analyticsContext: analyticsContext

@@ -20,3 +20,3 @@ "use strict";

var packageName = "@atlaskit/radio";
var packageVersion = "6.0.0";
var packageVersion = "6.0.1";
var fontFamily = (0, _constants.fontFamily)();

@@ -23,0 +23,0 @@ var noop = _noop.default;

@@ -18,3 +18,4 @@ import _extends from "@babel/runtime/helpers/extends";

analyticsContext,
['aria-labelledby']: ariaLabelledBy
['aria-labelledby']: ariaLabelledBy,
testId
} = props;

@@ -34,3 +35,4 @@ const [selectedValue, setSelectedValue] = useState(propValue !== undefined ? propValue : defaultValue);

role: "radiogroup",
"aria-labelledby": ariaLabelledBy
"aria-labelledby": ariaLabelledBy,
"data-testid": testId
}, options.map(({

@@ -50,2 +52,3 @@ ...optionProps

isChecked: isChecked,
testId: optionProps.testId || testId,
isRequired: isRequired,

@@ -52,0 +55,0 @@ analyticsContext: analyticsContext

@@ -11,3 +11,3 @@ import _extends from "@babel/runtime/helpers/extends";

const packageName = "@atlaskit/radio";
const packageVersion = "6.0.0";
const packageVersion = "6.0.1";
const fontFamily = getFontFamily();

@@ -14,0 +14,0 @@ const noop = __noop;

@@ -21,3 +21,4 @@ import _objectDestructuringEmpty from "@babel/runtime/helpers/objectDestructuringEmpty";

analyticsContext = props.analyticsContext,
ariaLabelledBy = props['aria-labelledby'];
ariaLabelledBy = props['aria-labelledby'],
testId = props.testId;
var _useState = useState(propValue !== undefined ? propValue : defaultValue),

@@ -39,3 +40,4 @@ _useState2 = _slicedToArray(_useState, 2),

role: "radiogroup",
"aria-labelledby": ariaLabelledBy
"aria-labelledby": ariaLabelledBy,
"data-testid": testId
}, options.map(function (_ref, index) {

@@ -54,2 +56,3 @@ var optionProps = _extends({}, (_objectDestructuringEmpty(_ref), _ref));

isChecked: isChecked,
testId: optionProps.testId || testId,
isRequired: isRequired,

@@ -56,0 +59,0 @@ analyticsContext: analyticsContext

@@ -13,3 +13,3 @@ import _extends from "@babel/runtime/helpers/extends";

var packageName = "@atlaskit/radio";
var packageVersion = "6.0.0";
var packageVersion = "6.0.1";
var fontFamily = getFontFamily();

@@ -16,0 +16,0 @@ var noop = __noop;

@@ -49,3 +49,11 @@ import React, { SyntheticEvent } from 'react';

'aria-labelledby'?: string;
/**
* A `testId` prop is provided for specified elements, which is a unique string that appears as a data attribute `data-testid` in the rendered code, serving as a hook for automated tests
* The specified `testId` is applied to the root element of `RadioGroup`. If no `testId` is supplied in the `options` prop, then the one supplied to `RadioGroup` will also be propagated to
* the `Radio` children. Otherwise, the `testId` supplied in the `options` prop will be used.
*
* See [here](/components/radio/code#testId) for details about how `testId` is used on `Radio`.
*/
testId?: string;
}
export default function RadioGroup(props: RadioGroupProps): JSX.Element;

@@ -49,3 +49,11 @@ import React, { SyntheticEvent } from 'react';

'aria-labelledby'?: string;
/**
* A `testId` prop is provided for specified elements, which is a unique string that appears as a data attribute `data-testid` in the rendered code, serving as a hook for automated tests
* The specified `testId` is applied to the root element of `RadioGroup`. If no `testId` is supplied in the `options` prop, then the one supplied to `RadioGroup` will also be propagated to
* the `Radio` children. Otherwise, the `testId` supplied in the `options` prop will be used.
*
* See [here](/components/radio/code#testId) for details about how `testId` is used on `Radio`.
*/
testId?: string;
}
export default function RadioGroup(props: RadioGroupProps): JSX.Element;
{
"name": "@atlaskit/radio",
"version": "6.0.0",
"version": "6.0.1",
"description": "A radio input allows users to select only one option from a number of choices. Radio is generally displayed in a radio group.",

@@ -47,3 +47,3 @@ "publishConfig": {

"@atlaskit/theme": "^12.6.0",
"@atlaskit/tokens": "^1.28.0",
"@atlaskit/tokens": "^1.30.0",
"@babel/runtime": "^7.0.0",

@@ -57,2 +57,3 @@ "@emotion/react": "^11.7.1"

"@af/accessibility-testing": "*",
"@af/integration-testing": "*",
"@atlaskit/ssr": "*",

@@ -59,0 +60,0 @@ "@atlaskit/visual-regression": "*",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc