Skip to content

Commit

Permalink
GH-38 [ADD] Data filter
Browse files Browse the repository at this point in the history
  • Loading branch information
Artkrygin committed Oct 12, 2021
1 parent 9df2db7 commit 4adc93b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/controls/AntdImageControl.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { withStoreToControlProps } from '../util/ContextToProps';

export const AntdImageControl = (props: any): JSX.Element => {
const { uiOptions, data } = props;
return <Image width={'100%'} src={data || ''} fallback={uiOptions.fallback} />;
return <Image width={'100%'} src={Array.isArray(data) ? data[0] || '' : ''} fallback={uiOptions.fallback} />;
};

export const antdImageControlTester: RankedTester = rankWith(3, uiTypeIs('aldkg:Image'));
Expand Down
4 changes: 4 additions & 0 deletions stories/FormWithColumns.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,10 @@ const viewKinds = [
'@type': 'aldkg:EntConstr',
schema: 'hs:ProductCardShape',
service: mktpSchemaRepoIri,
conditions: {
'@id': 'mktp:Cards_Coll_Ent0_con',
identifier: 'https://huntersales.ru/catalog/products/18279449',
},
},
],
//orderBy: [{ expression: variable('identifier0'), descending: false }],
Expand Down

0 comments on commit 4adc93b

Please sign in to comment.