ados-rcm 1.0.81 → 1.0.82

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.
@@ -102,7 +102,6 @@ export interface IASelectProps<T> extends IABaseProps, IAWrapProps {
102
102
  * AComponent : ASelect
103
103
  *
104
104
  * Description : ASelect is a select component. give options and useSelect to select an option.
105
- * if useSelect is given for I[], it will act as a multi select, otherwise it will act as a single select.
106
105
  *
107
106
  * Basic Usage :
108
107
  *
@@ -110,29 +109,25 @@ export interface IASelectProps<T> extends IABaseProps, IAWrapProps {
110
109
  * const [selected, setSelected] = useState<typeof options[0]>(options[0]);
111
110
  * const OptionRenderer = ({option}) => <div>{option.name}</div>;
112
111
  * const SelectedRenderer = ({selected, placeholder}) => selected ? selected.name : placeholder;
113
- * const [multiSelected, setMultiSelected] = useState<(typeof options[0])[]>([options[0]]);
114
- * const MultiSelectedRenderer = ({selected, placeholder}) => selected.length > 0 ? string.join(selected.map(e => e.name), ', ') : placeholder;
112
+ *
113
+ * const [num, setNum] = useState<number | null>(null);
114
+ *
115
115
  *
116
116
  * if (case 1)
117
- * <ASelect options={strOptions}
117
+ * <ASelect options={options}
118
118
  * useSelect={[selected, setSelected]}/>
119
119
  *
120
120
  * if (case 2)
121
121
  * <ASelect options={options}
122
122
  * useSelect={[selected, setSelected]}
123
- * OptionRenderer={OptionRenderer}/>
124
- *
125
- * if (case 3)
126
- * <ASelect options={options}
127
- * useSelect={[selected, setSelected]}
128
123
  * OptionRenderer={OptionRenderer}
129
- * SelectedRenderer={SelectedRenderer}/>
124
+ * SelectedRenderer={SelectedRenderer}
125
+ * />
130
126
  *
131
- * if (case 4)
132
- * <ASelect options={options}
133
- * useSelect={[multiSelected, setMultiSelected]}
134
- * OptionRenderer={OptionRenderer}
135
- * SelectedRenderer={MultiSelectedRenderer}/>
127
+ * if (case 3)
128
+ * <ASelect options={[1, 2, 3]}
129
+ * useSelect={[num, setNum]}
130
+ * OptionRenderer={p => p.option !== null ? p.option : 'Select'}/> *
136
131
  *
137
132
  */
138
133
  export declare const ASelect: <T>(props: IASelectProps<T>) => React.ReactNode;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ados-rcm",
3
- "version": "1.0.81",
3
+ "version": "1.0.82",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "type": "module",