diff --git a/common/changes/office-ui-fabric-react/stanleyy-fillin_2018-03-26-22-09.json b/common/changes/office-ui-fabric-react/stanleyy-fillin_2018-03-26-22-09.json new file mode 100644 index 00000000000000..76b8c6cb63864f --- /dev/null +++ b/common/changes/office-ui-fabric-react/stanleyy-fillin_2018-03-26-22-09.json @@ -0,0 +1,11 @@ +{ + "changes": [ + { + "packageName": "office-ui-fabric-react", + "comment": "Remove a redundant property from the ComboBox example", + "type": "patch" + } + ], + "packageName": "office-ui-fabric-react", + "email": "stanleyy@microsoft.com" +} \ No newline at end of file diff --git a/packages/office-ui-fabric-react/src/components/ComboBox/examples/ComboBox.Basic.Example.tsx b/packages/office-ui-fabric-react/src/components/ComboBox/examples/ComboBox.Basic.Example.tsx index ad451151d4f40f..f66f68146c860e 100644 --- a/packages/office-ui-fabric-react/src/components/ComboBox/examples/ComboBox.Basic.Example.tsx +++ b/packages/office-ui-fabric-react/src/components/ComboBox/examples/ComboBox.Basic.Example.tsx @@ -279,7 +279,6 @@ export class ComboBoxBasicExample extends React.Component<{}, { allowFreeform={ true } autoComplete='on' options={ optionsMulti } - value={ valueMulti } onChanged={ this._onChangedMulti } onResolveOptions={ this._getOptionsMulti } onRenderOption={ this._onRenderFontOption } @@ -336,7 +335,7 @@ export class ComboBoxBasicExample extends React.Component<{}, { private _getOptionsMulti = (currentOptions: IComboBoxOption[]): IComboBoxOption[] => { - if (this.state.options.length > 0) { + if (this.state.optionsMulti.length > 0) { return this.state.optionsMulti; } @@ -350,6 +349,7 @@ export class ComboBoxBasicExample extends React.Component<{}, { } private _onChanged = (option: IComboBoxOption, index: number, value: string): void => { + console.log('_onChanged() is called: option = ' + JSON.stringify(option)); if (option !== undefined) { this.setState({ selectedOptionKey: option.key, @@ -372,6 +372,7 @@ export class ComboBoxBasicExample extends React.Component<{}, { } private _onChangedMulti = (option: IComboBoxOption, index: number, value: string) => { + console.log('_onChangedMulti() is called: option = ' + JSON.stringify(option)); if (option !== undefined) { // User selected/de-selected an existing option this.setState({