@fixefy/fixefy-ui-utils 0.0.12 → 0.0.14

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.
@@ -0,0 +1,3 @@
1
+ export declare const parseInput: ({ client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args, ...rest }: {
2
+ [x: string]: any;
3
+ }) => any;
@@ -1,33 +1,33 @@
1
1
  "use strict";
2
- // import React from 'react'
3
- // import { ComponentTypes } from '../'
4
- // import { FxAsyncDropdown, FxButton, FxTextField } from '@fixefy/fixefy-ui-components'
5
- // export const parseInput = ({ client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args, ...rest }: { [x: string]: any }) => {
6
- // const { type, children } = structure
7
- // const { AsyncDropdown, Textfield, clear, dropdownOptions } = ComponentTypes
8
- // switch (type) {
9
- // case AsyncDropdown: {
10
- // return <FxAsyncDropdown classes={classes} structure={structure} fetcher={fetcher} onChange={() => {}} {...rest} />
11
- // }
12
- // case Textfield: {
13
- // return <FxTextField autoFocus={true} droppedItem={droppedItem} defaultValue={args && args.data && args.data.default_value} onChange={(e: any) => onInputChange({ structure, value: e.target.value })} structure={structure} {...rest} />
14
- // }
15
- // case dropdownOptions:
16
- // return children.map((child: any) => {
17
- // return parseInput({
18
- // client,
19
- // control,
20
- // structure: child,
21
- // droppedItem,
22
- // state,
23
- // onInputChange,
24
- // classes,
25
- // args,
26
- // ...rest,
27
- // })
28
- // })
29
- // case clear:
30
- // return <FxButton {...rest}>{structure.name}</FxButton>
31
- // }
32
- // }
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.parseInput = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const react_1 = tslib_1.__importDefault(require("react"));
6
+ const __1 = require("../");
7
+ const fixefy_ui_components_1 = require("@fixefy/fixefy-ui-components");
8
+ const parseInput = (_a) => {
9
+ var { client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args } = _a, rest = tslib_1.__rest(_a, ["client", "fetcher", "control", "structure", "droppedItem", "state", "onInputChange", "classes", "args"]);
10
+ const { type, children } = structure;
11
+ const { AsyncDropdown, Textfield, clear, dropdownOptions } = __1.ComponentTypes;
12
+ switch (type) {
13
+ case AsyncDropdown: {
14
+ return react_1.default.createElement(fixefy_ui_components_1.FxAsyncDropdown, Object.assign({ classes: classes, structure: structure, fetcher: fetcher, onChange: () => { } }, rest));
15
+ }
16
+ case Textfield: {
17
+ return react_1.default.createElement(fixefy_ui_components_1.FxTextField, Object.assign({ autoFocus: true, droppedItem: droppedItem, defaultValue: args && args.data && args.data.default_value, onChange: (e) => onInputChange({ structure, value: e.target.value }), structure: structure }, rest));
18
+ }
19
+ case dropdownOptions:
20
+ return children.map((child) => {
21
+ return (0, exports.parseInput)(Object.assign({ client,
22
+ control, structure: child, droppedItem,
23
+ state,
24
+ onInputChange,
25
+ classes,
26
+ args }, rest));
27
+ });
28
+ case clear:
29
+ return react_1.default.createElement(fixefy_ui_components_1.FxButton, Object.assign({}, rest), structure.name);
30
+ }
31
+ };
32
+ exports.parseInput = parseInput;
33
33
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/contents/index.tsx"],"names":[],"mappings":";AAAA,4BAA4B;AAE5B,uCAAuC;AACvC,wFAAwF;AAExF,4JAA4J;AAC5J,yCAAyC;AAEzC,gFAAgF;AAEhF,oBAAoB;AACpB,4BAA4B;AAC5B,2HAA2H;AAC3H,QAAQ;AAER,wBAAwB;AACxB,iPAAiP;AACjP,QAAQ;AAER,4BAA4B;AAC5B,8CAA8C;AAC9C,8BAA8B;AAC9B,oBAAoB;AACpB,qBAAqB;AACrB,8BAA8B;AAC9B,yBAAyB;AACzB,mBAAmB;AACnB,2BAA2B;AAC3B,qBAAqB;AACrB,kBAAkB;AAClB,qBAAqB;AACrB,aAAa;AACb,WAAW;AAEX,kBAAkB;AAClB,+DAA+D;AAC/D,MAAM;AACN,IAAI"}
1
+ {"version":3,"file":"index.js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;oBACL,aAAa;oBACb,OAAO;oBACP,IAAI,IACD,IAAI,EACP,CAAA;YACJ,CAAC,CAAC,CAAA;QAEJ,KAAK,KAAK;YACR,OAAO,8BAAC,+BAAQ,oBAAK,IAAI,GAAG,SAAS,CAAC,IAAI,CAAY,CAAA;KACzD;AACH,CAAC,CAAA;AAhCY,QAAA,UAAU,cAgCtB"}
@@ -10,3 +10,5 @@ export * from './page_context';
10
10
  export * from './redirect';
11
11
  export * from './types';
12
12
  export * from './validate';
13
+ import getPageContext from './page_context';
14
+ export { getPageContext };
package/dist-cjs/index.js CHANGED
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getPageContext = void 0;
3
4
  const tslib_1 = require("tslib");
4
5
  tslib_1.__exportStar(require("./auth"), exports);
5
6
  tslib_1.__exportStar(require("./aws"), exports);
@@ -15,4 +16,6 @@ tslib_1.__exportStar(require("./redirect"), exports);
15
16
  // export * from './renderer'
16
17
  tslib_1.__exportStar(require("./types"), exports);
17
18
  tslib_1.__exportStar(require("./validate"), exports);
19
+ const page_context_1 = tslib_1.__importDefault(require("./page_context"));
20
+ exports.getPageContext = page_context_1.default;
18
21
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,iDAAsB;AACtB,gDAAqB;AACrB,sDAA2B;AAC3B,sDAA2B;AAC3B,6BAA6B;AAC7B,oDAAyB;AACzB,oDAAyB;AACzB,mDAAwB;AACxB,iDAAsB;AACtB,yDAA8B;AAC9B,qDAA0B;AAC1B,6BAA6B;AAC7B,kDAAuB;AACvB,qDAA0B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;AAAA,iDAAsB;AACtB,gDAAqB;AACrB,sDAA2B;AAC3B,sDAA2B;AAC3B,6BAA6B;AAC7B,oDAAyB;AACzB,oDAAyB;AACzB,mDAAwB;AACxB,iDAAsB;AACtB,yDAA8B;AAC9B,qDAA0B;AAC1B,6BAA6B;AAC7B,kDAAuB;AACvB,qDAA0B;AAE1B,0EAA2C;AAClC,yBADF,sBAAc,CACE"}
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { Theme } from '@mui/material/styles';
2
3
  declare module '@mui/styles/defaultTheme' {
3
4
  interface DefaultTheme extends Theme {
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export declare const parseValue: ({ value, structure, onClick }: any) => any;
3
+ export declare const getValueComponentByComponentValue: ({ value, name, title, type, onClick, }: {
4
+ value?: any;
5
+ name?: string | undefined;
6
+ title?: string | undefined;
7
+ type?: any;
8
+ onClick?: any;
9
+ }) => React.JSX.Element | null;
@@ -1,78 +1,67 @@
1
1
  "use strict";
2
- // import React from 'react'
3
- // import { Typography, Link } from '@mui/material'
4
- // import { FxChip, FxShowMore } from '@fixefy/fixefy-ui-components'
5
- // import { ComponentTypes, getJPart, titleCase, getStringValueByValueType } from '../'
6
- // // helper function in order to extract and present the right value from recursive path - supermannnnnn
7
- // export const parseValue = ({ value, structure, onClick }: any) => {
8
- // //TODO: change active to enabled or disabled
9
- // const { extended, name, type, title } = structure
10
- // // extract path if exists
11
- // const path = extended && extended.title_path
12
- // let theTruth
13
- // if (path) {
14
- // // extract the object in the path
15
- // theTruth = getJPart(value, path, undefined)
16
- // }
17
- // const _value = theTruth === undefined || theTruth === null ? value[name] : theTruth
18
- // if (_value === undefined || _value === null) {
19
- // return getValueComponentByComponentValue({
20
- // value: 'No Value Found',
21
- // })
22
- // }
23
- // // get string value according to value type
24
- // let rv = getStringValueByValueType({ value: _value, name })
25
- // // parse wrapping component according to type
26
- // rv = getValueComponentByComponentValue({
27
- // value: rv,
28
- // name,
29
- // title,
30
- // type,
31
- // onClick: (e: any) => onClick(e, _value),
32
- // })
33
- // return rv
34
- // }
35
- // export const getValueComponentByComponentValue = ({ value, name, title, type, onClick }: { value?: any; name?: string; title?: string; type?: any; onClick?: any }) => {
36
- // let rv = null
37
- // switch (type) {
38
- // case ComponentTypes.Chip:
39
- // rv = <FxChip size="small" key={`${name}-Chip-3003`} style={{ marginBottom: '5px' }} status={value.toLowerCase()} label={value} />
40
- // break
41
- // case ComponentTypes.ClickableLabel:
42
- // rv = (
43
- // <Typography
44
- // key={`${name}-Link-2002`}
45
- // sx={{
46
- // marginBottom: '5px',
47
- // fontSize: '14px',
48
- // textDecoration: 'underline',
49
- // cursor: 'pointer',
50
- // }}
51
- // variant="body1"
52
- // >
53
- // <Link onClick={onClick}>{titleCase(value)}</Link>
54
- // </Typography>
55
- // )
56
- // break
57
- // case ComponentTypes.Label:
58
- // if (Array.isArray(value) && value?.length > 1) {
59
- // rv = (
60
- // <FxShowMore items={value} label={title ?? ''}>
61
- // <Typography key={`${name}-Label-1000`} lineHeight={'20px'} sx={{ fontSize: '14px' }} variant="body1">
62
- // {titleCase(value[0])}
63
- // </Typography>
64
- // </FxShowMore>
65
- // )
66
- // }
67
- // break
68
- // default:
69
- // rv = (
70
- // <Typography key={`${name}-Label-1000`} lineHeight={'20px'} sx={{ fontSize: '14px' }} variant="body1">
71
- // {titleCase(value)}
72
- // </Typography>
73
- // )
74
- // break
75
- // }
76
- // return rv
77
- // }
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getValueComponentByComponentValue = exports.parseValue = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const react_1 = tslib_1.__importDefault(require("react"));
6
+ const material_1 = require("@mui/material");
7
+ const fixefy_ui_components_1 = require("@fixefy/fixefy-ui-components");
8
+ const __1 = require("../");
9
+ // helper function in order to extract and present the right value from recursive path - supermannnnnn
10
+ const parseValue = ({ value, structure, onClick }) => {
11
+ //TODO: change active to enabled or disabled
12
+ const { extended, name, type, title } = structure;
13
+ // extract path if exists
14
+ const path = extended && extended.title_path;
15
+ let theTruth;
16
+ if (path) {
17
+ // extract the object in the path
18
+ theTruth = (0, __1.getJPart)(value, path, undefined);
19
+ }
20
+ const _value = theTruth === undefined || theTruth === null ? value[name] : theTruth;
21
+ if (_value === undefined || _value === null) {
22
+ return (0, exports.getValueComponentByComponentValue)({
23
+ value: 'No Value Found',
24
+ });
25
+ }
26
+ // get string value according to value type
27
+ let rv = (0, __1.getStringValueByValueType)({ value: _value, name });
28
+ // parse wrapping component according to type
29
+ rv = (0, exports.getValueComponentByComponentValue)({
30
+ value: rv,
31
+ name,
32
+ title,
33
+ type,
34
+ onClick: (e) => onClick(e, _value),
35
+ });
36
+ return rv;
37
+ };
38
+ exports.parseValue = parseValue;
39
+ const getValueComponentByComponentValue = ({ value, name, title, type, onClick, }) => {
40
+ let rv = null;
41
+ switch (type) {
42
+ case __1.ComponentTypes.Chip:
43
+ rv = (react_1.default.createElement(fixefy_ui_components_1.FxChip, { size: 'small', key: `${name}-Chip-3003`, style: { marginBottom: '5px' }, status: value.toLowerCase(), label: value }));
44
+ break;
45
+ case __1.ComponentTypes.ClickableLabel:
46
+ rv = (react_1.default.createElement(material_1.Typography, { key: `${name}-Link-2002`, sx: {
47
+ marginBottom: '5px',
48
+ fontSize: '14px',
49
+ textDecoration: 'underline',
50
+ cursor: 'pointer',
51
+ }, variant: 'body1' },
52
+ react_1.default.createElement(material_1.Link, { onClick: onClick }, (0, __1.titleCase)(value))));
53
+ break;
54
+ case __1.ComponentTypes.Label:
55
+ if (Array.isArray(value) && (value === null || value === void 0 ? void 0 : value.length) > 1) {
56
+ rv = (react_1.default.createElement(fixefy_ui_components_1.FxShowMore, { items: value, label: title !== null && title !== void 0 ? title : '' },
57
+ react_1.default.createElement(material_1.Typography, { key: `${name}-Label-1000`, lineHeight: '20px', sx: { fontSize: '14px' }, variant: 'body1' }, (0, __1.titleCase)(value[0]))));
58
+ }
59
+ break;
60
+ default:
61
+ rv = (react_1.default.createElement(material_1.Typography, { key: `${name}-Label-1000`, lineHeight: '20px', sx: { fontSize: '14px' }, variant: 'body1' }, (0, __1.titleCase)(value)));
62
+ break;
63
+ }
64
+ return rv;
65
+ };
66
+ exports.getValueComponentByComponentValue = getValueComponentByComponentValue;
78
67
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/renderer/index.tsx"],"names":[],"mappings":";AAAA,4BAA4B;AAE5B,mDAAmD;AACnD,oEAAoE;AACpE,uFAAuF;AAEvF,yGAAyG;AACzG,sEAAsE;AACtE,iDAAiD;AACjD,sDAAsD;AACtD,8BAA8B;AAC9B,iDAAiD;AACjD,iBAAiB;AACjB,gBAAgB;AAChB,wCAAwC;AACxC,kDAAkD;AAClD,MAAM;AACN,wFAAwF;AACxF,mDAAmD;AACnD,iDAAiD;AACjD,iCAAiC;AACjC,SAAS;AACT,MAAM;AACN,gDAAgD;AAChD,gEAAgE;AAChE,kDAAkD;AAClD,6CAA6C;AAC7C,iBAAiB;AACjB,YAAY;AACZ,aAAa;AACb,YAAY;AACZ,+CAA+C;AAC/C,OAAO;AAEP,cAAc;AACd,IAAI;AAEJ,2KAA2K;AAC3K,kBAAkB;AAElB,oBAAoB;AACpB,gCAAgC;AAChC,0IAA0I;AAC1I,cAAc;AAEd,0CAA0C;AAC1C,eAAe;AACf,sBAAsB;AACtB,sCAAsC;AACtC,kBAAkB;AAClB,mCAAmC;AACnC,gCAAgC;AAChC,2CAA2C;AAC3C,iCAAiC;AACjC,eAAe;AACf,4BAA4B;AAC5B,YAAY;AACZ,8DAA8D;AAC9D,wBAAwB;AACxB,UAAU;AACV,cAAc;AAEd,iCAAiC;AACjC,yDAAyD;AACzD,iBAAiB;AACjB,2DAA2D;AAC3D,oHAAoH;AACpH,sCAAsC;AACtC,4BAA4B;AAC5B,0BAA0B;AAC1B,YAAY;AACZ,UAAU;AACV,cAAc;AAEd,eAAe;AACf,eAAe;AACf,gHAAgH;AAChH,+BAA+B;AAC/B,wBAAwB;AACxB,UAAU;AACV,cAAc;AACd,MAAM;AAEN,cAAc;AACd,IAAI"}
1
+ {"version":3,"file":"index.js","sour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ACjG,IAAA,aAAS,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CACT,CACF,CACd,CAAA;aACF;YACD,MAAK;QAEP;YACE,EAAE,GAAG,CACH,8BAAC,qBAAU,IAAC,GAAG,EAAE,GAAG,IAAI,aAAa,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,OAAO,EAAC,OAAO,IACjG,IAAA,aAAS,EAAC,KAAK,CAAC,CACN,CACd,CAAA;YACD,MAAK;KACR;IAED,OAAO,EAAE,CAAA;AACX,CAAC,CAAA;AAnEY,QAAA,iCAAiC,qCAmE7C"}
@@ -0,0 +1,3 @@
1
+ export declare const parseInput: ({ client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args, ...rest }: {
2
+ [x: string]: any;
3
+ }) => any;
@@ -1,33 +1,32 @@
1
- "use strict";
2
- // import React from 'react'
3
- // import { ComponentTypes } from '../'
4
- // import { FxAsyncDropdown, FxButton, FxTextField } from '@fixefy/fixefy-ui-components'
5
- // export const parseInput = ({ client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args, ...rest }: { [x: string]: any }) => {
6
- // const { type, children } = structure
7
- // const { AsyncDropdown, Textfield, clear, dropdownOptions } = ComponentTypes
8
- // switch (type) {
9
- // case AsyncDropdown: {
10
- // return <FxAsyncDropdown classes={classes} structure={structure} fetcher={fetcher} onChange={() => {}} {...rest} />
11
- // }
12
- // case Textfield: {
13
- // return <FxTextField autoFocus={true} droppedItem={droppedItem} defaultValue={args && args.data && args.data.default_value} onChange={(e: any) => onInputChange({ structure, value: e.target.value })} structure={structure} {...rest} />
14
- // }
15
- // case dropdownOptions:
16
- // return children.map((child: any) => {
17
- // return parseInput({
18
- // client,
19
- // control,
20
- // structure: child,
21
- // droppedItem,
22
- // state,
23
- // onInputChange,
24
- // classes,
25
- // args,
26
- // ...rest,
27
- // })
28
- // })
29
- // case clear:
30
- // return <FxButton {...rest}>{structure.name}</FxButton>
31
- // }
32
- // }
1
+ import React from 'react';
2
+ import { ComponentTypes } from '../';
3
+ import { FxAsyncDropdown, FxButton, FxTextField } from '@fixefy/fixefy-ui-components';
4
+ export const parseInput = ({ client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args, ...rest }) => {
5
+ const { type, children } = structure;
6
+ const { AsyncDropdown, Textfield, clear, dropdownOptions } = ComponentTypes;
7
+ switch (type) {
8
+ case AsyncDropdown: {
9
+ return React.createElement(FxAsyncDropdown, { classes: classes, structure: structure, fetcher: fetcher, onChange: () => { }, ...rest });
10
+ }
11
+ case Textfield: {
12
+ return React.createElement(FxTextField, { autoFocus: true, droppedItem: droppedItem, defaultValue: args && args.data && args.data.default_value, onChange: (e) => onInputChange({ structure, value: e.target.value }), structure: structure, ...rest });
13
+ }
14
+ case dropdownOptions:
15
+ return children.map((child) => {
16
+ return parseInput({
17
+ client,
18
+ control,
19
+ structure: child,
20
+ droppedItem,
21
+ state,
22
+ onInputChange,
23
+ classes,
24
+ args,
25
+ ...rest,
26
+ });
27
+ });
28
+ case clear:
29
+ return React.createElement(FxButton, { ...rest }, structure.name);
30
+ }
31
+ };
33
32
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/contents/index.tsx"],"names":[],"mappings":";AAAA,4BAA4B;AAE5B,uCAAuC;AACvC,wFAAwF;AAExF,4JAA4J;AAC5J,yCAAyC;AAEzC,gFAAgF;AAEhF,oBAAoB;AACpB,4BAA4B;AAC5B,2HAA2H;AAC3H,QAAQ;AAER,wBAAwB;AACxB,iPAAiP;AACjP,QAAQ;AAER,4BAA4B;AAC5B,8CAA8C;AAC9C,8BAA8B;AAC9B,oBAAoB;AACpB,qBAAqB;AACrB,8BAA8B;AAC9B,yBAAyB;AACzB,mBAAmB;AACnB,2BAA2B;AAC3B,qBAAqB;AACrB,kBAAkB;AAClB,qBAAqB;AACrB,aAAa;AACb,WAAW;AAEX,kBAAkB;AAClB,+DAA+D;AAC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AG,CAAC,CAAC,KAAU,EAAE,EAAE;gBACjC,OAAO,UAAU,CAAC;oBAChB,MAAM;oBACN,OAAO;oBACP,SAAS,EAAE,KAAK;oBAChB,WAAW;oBACX,KAAK;oBACL,aAAa;oBACb,OAAO;oBACP,IAAI;oBACJ,GAAG,IAAI;iBACR,CAAC,CAAA;YACJ,CAAC,CAAC,CAAA;QAEJ,KAAK,KAAK;YACR,OAAO,oBAAC,QAAQ,OAAK,IAAI,IAAG,SAAS,CAAC,IAAI,CAAY,CAAA;KACzD;AACH,CAAC,CAAA"}
@@ -10,3 +10,5 @@ export * from './page_context';
10
10
  export * from './redirect';
11
11
  export * from './types';
12
12
  export * from './validate';
13
+ import getPageContext from './page_context';
14
+ export { getPageContext };
package/dist-es/index.js CHANGED
@@ -12,4 +12,6 @@ export * from './redirect';
12
12
  // export * from './renderer'
13
13
  export * from './types';
14
14
  export * from './validate';
15
+ import getPageContext from './page_context';
16
+ export { getPageContext };
15
17
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAA;AACtB,cAAc,OAAO,CAAA;AACrB,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA;AAC3B,6BAA6B;AAC7B,cAAc,WAAW,CAAA;AACzB,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,cAAc,QAAQ,CAAA;AACtB,cAAc,gBAAgB,CAAA;AAC9B,cAAc,YAAY,CAAA;AAC1B,6BAA6B;AAC7B,cAAc,SAAS,CAAA;AACvB,cAAc,YAAY,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAA;AACtB,cAAc,OAAO,CAAA;AACrB,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA;AAC3B,6BAA6B;AAC7B,cAAc,WAAW,CAAA;AACzB,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,cAAc,QAAQ,CAAA;AACtB,cAAc,gBAAgB,CAAA;AAC9B,cAAc,YAAY,CAAA;AAC1B,6BAA6B;AAC7B,cAAc,SAAS,CAAA;AACvB,cAAc,YAAY,CAAA;AAE1B,OAAO,cAAc,MAAM,gBAAgB,CAAA;AAC3C,OAAO,EAAE,cAAc,EAAE,CAAA"}
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { Theme } from '@mui/material/styles';
2
3
  declare module '@mui/styles/defaultTheme' {
3
4
  interface DefaultTheme extends Theme {
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export declare const parseValue: ({ value, structure, onClick }: any) => any;
3
+ export declare const getValueComponentByComponentValue: ({ value, name, title, type, onClick, }: {
4
+ value?: any;
5
+ name?: string | undefined;
6
+ title?: string | undefined;
7
+ type?: any;
8
+ onClick?: any;
9
+ }) => React.JSX.Element | null;
@@ -1,78 +1,61 @@
1
- "use strict";
2
- // import React from 'react'
3
- // import { Typography, Link } from '@mui/material'
4
- // import { FxChip, FxShowMore } from '@fixefy/fixefy-ui-components'
5
- // import { ComponentTypes, getJPart, titleCase, getStringValueByValueType } from '../'
6
- // // helper function in order to extract and present the right value from recursive path - supermannnnnn
7
- // export const parseValue = ({ value, structure, onClick }: any) => {
8
- // //TODO: change active to enabled or disabled
9
- // const { extended, name, type, title } = structure
10
- // // extract path if exists
11
- // const path = extended && extended.title_path
12
- // let theTruth
13
- // if (path) {
14
- // // extract the object in the path
15
- // theTruth = getJPart(value, path, undefined)
16
- // }
17
- // const _value = theTruth === undefined || theTruth === null ? value[name] : theTruth
18
- // if (_value === undefined || _value === null) {
19
- // return getValueComponentByComponentValue({
20
- // value: 'No Value Found',
21
- // })
22
- // }
23
- // // get string value according to value type
24
- // let rv = getStringValueByValueType({ value: _value, name })
25
- // // parse wrapping component according to type
26
- // rv = getValueComponentByComponentValue({
27
- // value: rv,
28
- // name,
29
- // title,
30
- // type,
31
- // onClick: (e: any) => onClick(e, _value),
32
- // })
33
- // return rv
34
- // }
35
- // export const getValueComponentByComponentValue = ({ value, name, title, type, onClick }: { value?: any; name?: string; title?: string; type?: any; onClick?: any }) => {
36
- // let rv = null
37
- // switch (type) {
38
- // case ComponentTypes.Chip:
39
- // rv = <FxChip size="small" key={`${name}-Chip-3003`} style={{ marginBottom: '5px' }} status={value.toLowerCase()} label={value} />
40
- // break
41
- // case ComponentTypes.ClickableLabel:
42
- // rv = (
43
- // <Typography
44
- // key={`${name}-Link-2002`}
45
- // sx={{
46
- // marginBottom: '5px',
47
- // fontSize: '14px',
48
- // textDecoration: 'underline',
49
- // cursor: 'pointer',
50
- // }}
51
- // variant="body1"
52
- // >
53
- // <Link onClick={onClick}>{titleCase(value)}</Link>
54
- // </Typography>
55
- // )
56
- // break
57
- // case ComponentTypes.Label:
58
- // if (Array.isArray(value) && value?.length > 1) {
59
- // rv = (
60
- // <FxShowMore items={value} label={title ?? ''}>
61
- // <Typography key={`${name}-Label-1000`} lineHeight={'20px'} sx={{ fontSize: '14px' }} variant="body1">
62
- // {titleCase(value[0])}
63
- // </Typography>
64
- // </FxShowMore>
65
- // )
66
- // }
67
- // break
68
- // default:
69
- // rv = (
70
- // <Typography key={`${name}-Label-1000`} lineHeight={'20px'} sx={{ fontSize: '14px' }} variant="body1">
71
- // {titleCase(value)}
72
- // </Typography>
73
- // )
74
- // break
75
- // }
76
- // return rv
77
- // }
1
+ import React from 'react';
2
+ import { Typography, Link } from '@mui/material';
3
+ import { FxChip, FxShowMore } from '@fixefy/fixefy-ui-components';
4
+ import { ComponentTypes, getJPart, titleCase, getStringValueByValueType } from '../';
5
+ // helper function in order to extract and present the right value from recursive path - supermannnnnn
6
+ export const parseValue = ({ value, structure, onClick }) => {
7
+ //TODO: change active to enabled or disabled
8
+ const { extended, name, type, title } = structure;
9
+ // extract path if exists
10
+ const path = extended && extended.title_path;
11
+ let theTruth;
12
+ if (path) {
13
+ // extract the object in the path
14
+ theTruth = getJPart(value, path, undefined);
15
+ }
16
+ const _value = theTruth === undefined || theTruth === null ? value[name] : theTruth;
17
+ if (_value === undefined || _value === null) {
18
+ return getValueComponentByComponentValue({
19
+ value: 'No Value Found',
20
+ });
21
+ }
22
+ // get string value according to value type
23
+ let rv = getStringValueByValueType({ value: _value, name });
24
+ // parse wrapping component according to type
25
+ rv = getValueComponentByComponentValue({
26
+ value: rv,
27
+ name,
28
+ title,
29
+ type,
30
+ onClick: (e) => onClick(e, _value),
31
+ });
32
+ return rv;
33
+ };
34
+ export const getValueComponentByComponentValue = ({ value, name, title, type, onClick, }) => {
35
+ let rv = null;
36
+ switch (type) {
37
+ case ComponentTypes.Chip:
38
+ rv = (React.createElement(FxChip, { size: 'small', key: `${name}-Chip-3003`, style: { marginBottom: '5px' }, status: value.toLowerCase(), label: value }));
39
+ break;
40
+ case ComponentTypes.ClickableLabel:
41
+ rv = (React.createElement(Typography, { key: `${name}-Link-2002`, sx: {
42
+ marginBottom: '5px',
43
+ fontSize: '14px',
44
+ textDecoration: 'underline',
45
+ cursor: 'pointer',
46
+ }, variant: 'body1' },
47
+ React.createElement(Link, { onClick: onClick }, titleCase(value))));
48
+ break;
49
+ case ComponentTypes.Label:
50
+ if (Array.isArray(value) && value?.length > 1) {
51
+ rv = (React.createElement(FxShowMore, { items: value, label: title ?? '' },
52
+ React.createElement(Typography, { key: `${name}-Label-1000`, lineHeight: '20px', sx: { fontSize: '14px' }, variant: 'body1' }, titleCase(value[0]))));
53
+ }
54
+ break;
55
+ default:
56
+ rv = (React.createElement(Typography, { key: `${name}-Label-1000`, lineHeight: '20px', sx: { fontSize: '14px' }, variant: 'body1' }, titleCase(value)));
57
+ break;
58
+ }
59
+ return rv;
60
+ };
78
61
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/renderer/index.tsx"],"names":[],"mappings":";AAAA,4BAA4B;AAE5B,mDAAmD;AACnD,oEAAoE;AACpE,uFAAuF;AAEvF,yGAAyG;AACzG,sEAAsE;AACtE,iDAAiD;AACjD,sDAAsD;AACtD,8BAA8B;AAC9B,iDAAiD;AACjD,iBAAiB;AACjB,gBAAgB;AAChB,wCAAwC;AACxC,kDAAkD;AAClD,MAAM;AACN,wFAAwF;AACxF,mDAAmD;AACnD,iDAAiD;AACjD,iCAAiC;AACjC,SAAS;AACT,MAAM;AACN,gDAAgD;AAChD,gEAAgE;AAChE,kDAAkD;AAClD,6CAA6C;AAC7C,iBAAiB;AACjB,YAAY;AACZ,aAAa;AACb,YAAY;AACZ,+CAA+C;AAC/C,OAAO;AAEP,cAAc;AACd,IAAI;AAEJ,2KAA2K;AAC3K,kBAAkB;AAElB,oBAAoB;AACpB,gCAAgC;AAChC,0IAA0I;AAC1I,cAAc;AAEd,0CAA0C;AAC1C,eAAe;AACf,sBAAsB;AACtB,sCAAsC;AACtC,kBAAkB;AAClB,mCAAmC;AACnC,gCAAgC;AAChC,2CAA2C;AAC3C,iCAAiC;AACjC,eAAe;AACf,4BAA4B;AAC5B,YAAY;AACZ,8DAA8D;AAC9D,wBAAwB;AACxB,UAAU;AACV,cAAc;AAEd,iCAAiC;AACjC,yDAAyD;AACzD,iBAAiB;AACjB,2DAA2D;AAC3D,oHAAoH;AACpH,sCAAsC;AACtC,4BAA4B;AAC5B,0BAA0B;AAC1B,YAAY;AACZ,UAAU;AACV,cAAc;AAEd,eAAe;AACf,eAAe;AACf,gHAAgH;AAChH,+BAA+B;AAC/B,wBAAwB;AACxB,UAAU;AACV,cAAc;AACd,MAAM;AAEN,cAAc;AACd,IAAI"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/renderer/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;AAChD,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAA;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AAU,IAAC,GAAG,EAAE,GAAG,IAAI,aAAa,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,OAAO,EAAC,OAAO,IACjG,SAAS,CAAC,KAAK,CAAC,CACN,CACd,CAAA;YACD,MAAK;KACR;IAED,OAAO,EAAE,CAAA;AACX,CAAC,CAAA"}
@@ -0,0 +1,3 @@
1
+ export declare const parseInput: ({ client, fetcher, control, structure, droppedItem, state, onInputChange, classes, args, ...rest }: {
2
+ [x: string]: any;
3
+ }) => any;
@@ -10,3 +10,5 @@ export * from './page_context';
10
10
  export * from './redirect';
11
11
  export * from './types';
12
12
  export * from './validate';
13
+ import getPageContext from './page_context';
14
+ export { getPageContext };
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { Theme } from '@mui/material/styles';
2
3
  declare module '@mui/styles/defaultTheme' {
3
4
  interface DefaultTheme extends Theme {
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export declare const parseValue: ({ value, structure, onClick }: any) => any;
3
+ export declare const getValueComponentByComponentValue: ({ value, name, title, type, onClick, }: {
4
+ value?: any;
5
+ name?: string | undefined;
6
+ title?: string | undefined;
7
+ type?: any;
8
+ onClick?: any;
9
+ }) => React.JSX.Element | null;
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "fs": false
5
5
  },
6
6
  "dependencies": {
7
- "@fixefy/fixefy-ui-components": "^0.0.9",
7
+ "@fixefy/fixefy-ui-components": "^0.0.15",
8
8
  "@mui/material": "^5.14.11",
9
9
  "@mui/styled-engine": "^5.14.11",
10
10
  "@mui/styles": "^5.14.11",
@@ -64,5 +64,5 @@
64
64
  }
65
65
  },
66
66
  "types": "./dist-types/index.d.ts",
67
- "version": "0.0.12"
67
+ "version": "0.0.14"
68
68
  }