@fto-consult/expo-ui 2.36.1 → 2.36.3

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": "@fto-consult/expo-ui",
3
- "version": "2.36.1",
3
+ "version": "2.36.3",
4
4
  "description": "Bibliothèque de composants UI Expo,react-native",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -55,6 +55,7 @@ const AvatarImage = React.forwardRef(({
55
55
  borderRadius,
56
56
  },
57
57
  flattenedStyle,
58
+ !isRounded && {borderRadius:0},
58
59
  ]}
59
60
  {...rest}
60
61
  >
@@ -19,9 +19,13 @@ const defaultSize = 40;
19
19
  */
20
20
  const AvatarComponent = React.forwardRef((props,ref)=>{
21
21
  let Component = undefined;
22
- let {image,icon,testID,color,title,toolip,src,onPress,containerProps,useSuffix,suffix,size,children,label,source,text,...rest} = props;
23
- label = defaultVal(label,text,children);
24
- if(typeof label =='number') label = label+"";
22
+ let {image,icon,testID,color,title,toolip,src,onPress,containerProps,withLabel,useSuffix,suffix,size,children,label,source,text,...rest} = props;
23
+ if(withLabel === false){
24
+ label = null;
25
+ } else {
26
+ label = defaultVal(label,text,children);
27
+ if(typeof label =='number') label = label+"";
28
+ }
25
29
  rest = defaultObj(rest);
26
30
  containerProps = defaultObj(containerProps);
27
31
  size = defaultDecimal(size,defaultSize);
@@ -43,7 +43,7 @@ import notify from "$cnotify";
43
43
  import FileSystem from "$file-system";
44
44
  import sprintf from "$cutils/sprintf";
45
45
 
46
- export const TIMEOUT = 200;
46
+ export const TIMEOUT = 100;
47
47
 
48
48
  export const donutChart = {
49
49
  isChart : true,
@@ -1272,15 +1272,15 @@ export default class CommonDatagridComponent extends AppComponent {
1272
1272
  if(!isObj(this.state.sectionListColumns) || !Array.isArray(this.preparedColumns?.sectionListColumnsMenuItems))return;
1273
1273
  const menuItems = this.preparedColumns?.sectionListColumnsMenuItems;
1274
1274
  if(!menuItems.length) return;
1275
- const sectionListColumns = {...this.state.sectionListColumns};
1276
- if(enable !== true && isObj(sectionListColumns[columnName])){
1277
- delete sectionListColumns[columnName];
1278
- } else {
1279
- sectionListColumns[columnName] = {field:columnName};
1280
- }
1281
1275
  setTimeout(()=>{
1282
- const {sectionListColumns:pSListColumns} = this.prepareColumns({sectionListColumns});
1283
1276
  this.setIsLoading(true,()=>{
1277
+ const sectionListColumns = {...this.state.sectionListColumns};
1278
+ if(enable !== true && isObj(sectionListColumns[columnName])){
1279
+ delete sectionListColumns[columnName];
1280
+ } else {
1281
+ sectionListColumns[columnName] = {field:columnName};
1282
+ }
1283
+ const {sectionListColumns:pSListColumns} = this.prepareColumns({sectionListColumns});
1284
1284
  this.prepareData({data:this.INITIAL_STATE.data,sectionListColumns:pSListColumns},(state)=>{
1285
1285
  this.setState({...state,sectionListColumns:pSListColumns},()=>{
1286
1286
  this.setIsLoading(false,false);
@@ -67,7 +67,7 @@ export default function ImageComponent(props){
67
67
  disabled = defaultVal(disabled,false);
68
68
  readOnly = defaultBool(readOnly,false);
69
69
  menuProps = defaultObj(menuProps);
70
- round = defaultBool(round,rounded,true);
70
+ rounded = defaultBool(rounded,round,true);
71
71
  containerProps = defaultObj(containerProps);
72
72
  drawProps = defaultObj(drawProps);
73
73
  const flattenStyle = StyleSheet.flatten(props.style) || {};
@@ -271,7 +271,7 @@ export default function ImageComponent(props){
271
271
  imageProps = {imageProps}
272
272
  {...props}
273
273
  style = {[rest.style]}
274
- rounded = {round}
274
+ rounded = {rounded}
275
275
  image = {true}
276
276
  source = {source}
277
277
  />}