(props1)
| 37290 | */ var ChoiceGroupOptionBase = /** @class */ function(_super) { |
| 37291 | (0, _tslib.__extends)(ChoiceGroupOptionBase1, _super); |
| 37292 | function ChoiceGroupOptionBase1(props1) { |
| 37293 | var _this = _super.call(this, props1) || this; |
| 37294 | _this._onChange = function(evt) { |
| 37295 | var onChange = _this.props.onChange; |
| 37296 | if (onChange) onChange(evt, _this.props); |
| 37297 | }; |
| 37298 | _this._onBlur = function(evt) { |
| 37299 | var onBlur = _this.props.onBlur; |
| 37300 | if (onBlur) onBlur(evt, _this.props); |
| 37301 | }; |
| 37302 | _this._onFocus = function(evt) { |
| 37303 | var onFocus = _this.props.onFocus; |
| 37304 | if (onFocus) onFocus(evt, _this.props); |
| 37305 | }; |
| 37306 | _this._onRenderField = function(props) { |
| 37307 | var id = props.id, imageSrc = props.imageSrc, _a = props.imageAlt, imageAlt = _a === void 0 ? "" : _a, selectedImageSrc = props.selectedImageSrc, iconProps = props.iconProps; |
| 37308 | var imageSize = props.imageSize ? props.imageSize : { |
| 37309 | width: 32, |
| 37310 | height: 32 |
| 37311 | }; |
| 37312 | var onRenderLabel = props.onRenderLabel ? (0, _utilities1.composeRenderFunction)(props.onRenderLabel, _this._onRenderLabel) : _this._onRenderLabel; |
| 37313 | var label = onRenderLabel(props); |
| 37314 | return _react.createElement("label", { |
| 37315 | htmlFor: id, |
| 37316 | className: _this._classNames.field |
| 37317 | }, imageSrc && _react.createElement("div", { |
| 37318 | className: _this._classNames.innerField |
| 37319 | }, _react.createElement("div", { |
| 37320 | className: _this._classNames.imageWrapper |
| 37321 | }, _react.createElement((0, _image.Image), { |
| 37322 | src: imageSrc, |
| 37323 | alt: imageAlt, |
| 37324 | width: imageSize.width, |
| 37325 | height: imageSize.height |
| 37326 | })), _react.createElement("div", { |
| 37327 | className: _this._classNames.selectedImageWrapper |
| 37328 | }, _react.createElement((0, _image.Image), { |
| 37329 | src: selectedImageSrc, |
| 37330 | alt: imageAlt, |
| 37331 | width: imageSize.width, |
| 37332 | height: imageSize.height |
| 37333 | }))), iconProps && _react.createElement("div", { |
| 37334 | className: _this._classNames.innerField |
| 37335 | }, _react.createElement("div", { |
| 37336 | className: _this._classNames.iconWrapper |
| 37337 | }, _react.createElement((0, _icon.Icon), (0, _tslib.__assign)({}, iconProps)))), imageSrc || iconProps ? _react.createElement("div", { |
| 37338 | className: _this._classNames.labelWrapper |
| 37339 | }, label) : label); |
| 37340 | }; |
| 37341 | _this._onRenderLabel = function(props) { |
| 37342 | return _react.createElement("span", { |
| 37343 | id: props.labelId, |
| 37344 | className: "ms-ChoiceFieldLabel" |
| 37345 | }, props.text); |
| 37346 | }; |
| 37347 | (0, _utilities.initializeComponentRef)(_this); |
| 37348 | return _this; |
| 37349 | } |
nothing calls this directly
no outgoing calls
no test coverage detected