ywana-core8 0.0.528 → 0.0.531
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 +16 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +16 -2
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +16 -2
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/domain/CollectionPage.js +2 -2
- package/src/domain/ContentEditor.js +8 -1
package/package.json
CHANGED
@@ -64,13 +64,13 @@ export const CollectionPage = (props) => {
|
|
64
64
|
<Button icon="refresh" label="Reload" action={reload} />
|
65
65
|
{renderActions()}
|
66
66
|
</Header>
|
67
|
-
<menu className=
|
67
|
+
<menu className={`collection-page ${className}`}>
|
68
68
|
<Header title={<Text>Lista de {name}</Text>} >
|
69
69
|
</Header>
|
70
70
|
{canFilter ? <CollectionFilters schema={schema}/> : null }
|
71
71
|
{levels ? <CollectionTree icon={icon} levels={levels} onSelect={onSelect} sorter={sorter}/> : <CollectionList groupBy={groupBy} onSelect={onSelect}/>}
|
72
72
|
</menu>
|
73
|
-
<main key={id} className=
|
73
|
+
<main key={id} className={`collection-page ${className}`}>
|
74
74
|
<CollectionEditor icon={icon} schema={schema} layout={editor} autosave={autosave} delay={delay} />
|
75
75
|
{children ? <article>{children}</article> : null}
|
76
76
|
</main>
|
@@ -270,10 +270,17 @@ export const StringEditor = ({ field, value = '', onChange, content, outlined })
|
|
270
270
|
|
271
271
|
function renderFormat(format, options) {
|
272
272
|
switch (format) {
|
273
|
+
case FORMATS.IMG:
|
274
|
+
return (
|
275
|
+
<div className='img-field'>
|
276
|
+
<img src={value} />
|
277
|
+
<TextField outlined={outlined} id={id} label={label} value={value} onChange={change} readOnly={!editable} />
|
278
|
+
</div>
|
279
|
+
)
|
273
280
|
case FORMATS.COLOR: return <ColorField id={id} onChange={change} value={value} />
|
274
281
|
case FORMATS.HTML: return <Editor id={id} value={value} onChange={change} content={content} />
|
275
282
|
case FORMATS.DATE: return <TextField outlined={outlined} id={id} type="date" label={label} value={value} onChange={change} readOnly={!editable} />
|
276
|
-
case FORMATS.DATERANGE: return <DateRange id={id} label={label} value={value} onChange={change} readOnly={!editable}/>
|
283
|
+
case FORMATS.DATERANGE: return <DateRange id={id} label={label} value={value} onChange={change} readOnly={!editable} />
|
277
284
|
case FORMATS.TOKENS:
|
278
285
|
return <TokenField id={id} label={label} onChange={change} options={buildOptions()} tokens={value} />
|
279
286
|
default:
|