ywana-core8 0.0.624 → 0.0.627

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ywana-core8",
3
- "version": "0.0.624",
3
+ "version": "0.0.627",
4
4
  "description": "ywana-core8",
5
5
  "homepage": "https://ywana.github.io/workspace",
6
6
  "author": "Ernesto Roldan Garcia",
@@ -270,7 +270,7 @@ const EntityEditor = ({ field, value = {}, onChange }) => {
270
270
  * String Editor
271
271
  */
272
272
  export const StringEditor = ({ field, value = '', onChange, content, outlined }) => {
273
- const { id, format, options, required=false, editable = true, predictive = false, multivalue = false, Editor } = field
273
+ const { id, format, options, required=false, editable = true, predictive = false, multivalue = false, freeValue = false, Editor } = field
274
274
 
275
275
  function change(id, value) {
276
276
  if (onChange) onChange(id, value)
@@ -301,7 +301,7 @@ export const StringEditor = ({ field, value = '', onChange, content, outlined })
301
301
  return <TokenField id={id} label={label} onChange={change} options={buildOptions()} tokens={value} />
302
302
  default:
303
303
  return options ? (
304
- <DropDown outlined={outlined} id={id} label={label} value={value} onChange={change} options={buildOptions()} readOnly={!editable} predictive={predictive} />
304
+ <DropDown outlined={outlined} id={id} label={label} value={value} onChange={change} options={buildOptions()} readOnly={!editable} predictive={predictive} editable={freeValue} />
305
305
  ) : multivalue ? (
306
306
  <TokenField id={id} label={label} onChange={change} readOnly={!editable} />
307
307
  ) : (
@@ -183,7 +183,7 @@ export const DropDown = (props) => {
183
183
  }
184
184
  }
185
185
 
186
- const title = editable ? <div className='row'>{props.label}<Icon className="decorator" icon="edit" size="small" /></div> : props.label}
186
+ const title = editable ? <div className='row'>{props.label}<Icon className="decorator" icon="edit" size="small" /></div> : props.label
187
187
  return (
188
188
  <div className="dropdown">
189
189
  <TextField {...props} label={title} onClick={onFocus} value={label} onChange={change} onBlur={blur} readOnly={!predictive && !editable} />