ywana-core8 0.0.726 → 0.0.728

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.726",
3
+ "version": "0.0.728",
4
4
  "description": "ywana-core8",
5
5
  "homepage": "https://ywana.github.io/workspace",
6
6
  "author": "Ernesto Roldan Garcia",
@@ -11,7 +11,7 @@ export const CollectionFilters = (props) => {
11
11
 
12
12
  const { schema, children } = props
13
13
  const context = useContext(CollectionContext)
14
- const { filters } = context
14
+ const { filters, selected } = context
15
15
  const [open, setOpen] = useState(false)
16
16
 
17
17
  useEffect(() => {
@@ -37,8 +37,10 @@ export const CollectionFilters = (props) => {
37
37
  return acc
38
38
  }, {})
39
39
 
40
+ const style = selected ? 'selected' : ''
41
+
40
42
  return (
41
- <div className="collection-filters">
43
+ <div className={`collection-filters ${style}`}>
42
44
  <header>
43
45
  <div className='custom-filters'>
44
46
  {children}
package/src/html/table.js CHANGED
@@ -256,6 +256,7 @@ const StringCellViewer = ({ id, value, format, options }) => {
256
256
 
257
257
  const option = options ? buildOptions().find(o => o.value === value) : null
258
258
  let text = option ? option.label : value
259
+ const className = option ? option.className : ''
259
260
  const locale = window.navigator.userLanguage || window.navigator.language;
260
261
  switch (format) {
261
262
  case FORMATS.COLOR:
@@ -275,7 +276,7 @@ const StringCellViewer = ({ id, value, format, options }) => {
275
276
  text = new Date(text).toLocaleString(locale, { year: 'hour', month: 'minute', day: 'second' });
276
277
  break;
277
278
  }
278
- return (<div className="field-editor string-viewer">{text}</div>)
279
+ return (<div className={`field-editor string-viewer ${className}`}>{text}</div>)
279
280
  }
280
281
 
281
282
  /**