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/dist/index.cjs +27 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +15 -0
- package/dist/index.css.map +1 -1
- package/dist/index.modern.js +27 -7
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +27 -7
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/domain/ContentEditor.js +2 -2
- package/src/html/textfield.js +1 -1
package/package.json
CHANGED
@@ -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
|
) : (
|
package/src/html/textfield.js
CHANGED
@@ -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} />
|