@oneblink/apps-react 5.12.0-beta.11 → 5.12.0-beta.13
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.
@@ -12,7 +12,7 @@ function OneBlinkFormStoreColumnsButton(props) {
|
|
12
12
|
const hasRepeatableSets = React.useMemo(() => parameters.unwindRepeatableSets ||
|
13
13
|
allColumns.some((c) => c.formElementType === 'repeatableSet'), [allColumns, parameters.unwindRepeatableSets]);
|
14
14
|
return (React.createElement(React.Fragment, null,
|
15
|
-
React.createElement(Button, { className: "ob-form-store-columns-button", startIcon:
|
15
|
+
React.createElement(Button, { className: "ob-form-store-columns-button", startIcon: React.createElement(MaterialIcon, null, "settings"), onClick: showColumnConfiguration,
|
16
16
|
// eslint-disable-next-line react/no-children-prop
|
17
17
|
children: React.createElement(React.Fragment, null, "Columns"), ...props }),
|
18
18
|
React.createElement(Dialog, { open: isConfiguringColumns, maxWidth: "sm", fullWidth: true, onClose: hideColumnConfiguration },
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"OneBlinkFormStoreColumnsButton.js","sourceRoot":"","sources":["../../../src/components/formStore/OneBlinkFormStoreColumnsButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EACL,KAAK,EACL,UAAU,EACV,GAAG,EACH,MAAM,EACN,QAAQ,EACR,QAAQ,EACR,MAAM,EACN,aAAa,EACb,aAAa,EACb,WAAW,EACX,OAAO,EACP,gBAAgB,EAChB,SAAS,EACT,IAAI,EACJ,UAAU,EACV,UAAU,GACX,MAAM,eAAe,CAAA;AACtB,OAAO,eAAe,MAAM,6BAA6B,CAAA;AACzD,OAAO,wBAAwB,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAClD,OAAO,YAAY,MAAM,iBAAiB,CAAA;AAE1C,SAAS,8BAA8B,CACrC,KAA0C;IAE1C,MAAM,EACJ,4BAA4B,EAC5B,UAAU,EACV,UAAU,EACV,kBAAkB,GACnB,GAAG,wBAAwB,EAAE,CAAA;IAC9B,MAAM,CACJ,oBAAoB,EACpB,uBAAuB,EACvB,uBAAuB,EACxB,GAAG,eAAe,CAAC,KAAK,CAAC,CAAA;IAC1B,MAAM,CAAC,UAAU,EAAE,AAAD,EAAG,AAAD,EAAG,UAAU,CAAC,GAAG,eAAe,CAAC,KAAK,CAAC,CAAA;IAE3D,MAAM,yBAAyB,GAAG,4BAA4B,EAAE,CAAA;IAEhE,MAAM,iBAAiB,GAAG,KAAK,CAAC,OAAO,CACrC,GAAG,EAAE,CACH,UAAU,CAAC,oBAAoB;QAC/B,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,eAAe,KAAK,eAAe,CAAC,EAC/D,CAAC,UAAU,EAAE,UAAU,CAAC,oBAAoB,CAAC,CAC9C,CAAA;IAED,OAAO,CACL;QACE,oBAAC,MAAM,IACL,SAAS,EAAC,8BAA8B,EACxC,SAAS,EAAE,
|
1
|
+
{"version":3,"file":"OneBlinkFormStoreColumnsButton.js","sourceRoot":"","sources":["../../../src/components/formStore/OneBlinkFormStoreColumnsButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EACL,KAAK,EACL,UAAU,EACV,GAAG,EACH,MAAM,EACN,QAAQ,EACR,QAAQ,EACR,MAAM,EACN,aAAa,EACb,aAAa,EACb,WAAW,EACX,OAAO,EACP,gBAAgB,EAChB,SAAS,EACT,IAAI,EACJ,UAAU,EACV,UAAU,GACX,MAAM,eAAe,CAAA;AACtB,OAAO,eAAe,MAAM,6BAA6B,CAAA;AACzD,OAAO,wBAAwB,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAClD,OAAO,YAAY,MAAM,iBAAiB,CAAA;AA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D,KAAK,EACH;oCACG,MAAM,CAAC,UAAU;oCACjB,MAAM,CAAC,OAAO,IAAI,CACjB,oBAAC,UAAU,IAAC,SAAS,EAAC,MAAM,EAAC,KAAK,EAAC,eAAe;wCAC/C,GAAG;;wCACF,MAAM,CAAC,OAAO;4CACL,CACd,CACA,GAEL,CACa,CAClB,CAAA;oBACH,CAAC,CAAC,CACQ,CACE;YAChB,oBAAC,aAAa;gBACZ,oBAAC,MAAM,IACL,OAAO,EAAE,uBAAuB,EAChC,KAAK,EAAC,SAAS,EACf,OAAO,EAAC,WAAW,WAGZ,CACK,CACT,CACR,CACJ,CAAA;AACH,CAAC;AAED;;;;GAIG;AACH,eAAe,KAAK,CAAC,IAAI,CAAC,8BAA8B,CAAC,CAAA","sourcesContent":["import * as React from 'react'\nimport {\n Alert,\n AlertTitle,\n Box,\n Button,\n Checkbox,\n Collapse,\n Dialog,\n DialogActions,\n DialogContent,\n DialogTitle,\n Divider,\n FormControlLabel,\n FormGroup,\n Grid,\n IconButton,\n Typography,\n} from '@mui/material'\nimport useBooleanState from '../../hooks/useBooleanState'\nimport useFormStoreTableContext from './useFormStoreTableContext'\nimport { ListItem, UnorderedList } from '../Lists'\nimport MaterialIcon from '../MaterialIcon'\n\nfunction OneBlinkFormStoreColumnsButton(\n props: React.ComponentProps<typeof Button>,\n) {\n const {\n getToggleHideAllColumnsProps,\n allColumns,\n parameters,\n onChangeParameters,\n } = useFormStoreTableContext()\n const [\n isConfiguringColumns,\n showColumnConfiguration,\n hideColumnConfiguration,\n ] = useBooleanState(false)\n const [isHelpOpen, , , toggleHelp] = useBooleanState(false)\n\n const toggleHideAllColumnsProps = getToggleHideAllColumnsProps()\n\n const hasRepeatableSets = React.useMemo(\n () =>\n parameters.unwindRepeatableSets ||\n allColumns.some((c) => c.formElementType === 'repeatableSet'),\n [allColumns, parameters.unwindRepeatableSets],\n )\n\n return (\n <>\n <Button\n className=\"ob-form-store-columns-button\"\n startIcon={<MaterialIcon>settings</MaterialIcon>}\n onClick={showColumnConfiguration}\n // eslint-disable-next-line react/no-children-prop\n children={<>Columns</>}\n {...props}\n />\n <Dialog\n open={isConfiguringColumns}\n maxWidth=\"sm\"\n fullWidth\n onClose={hideColumnConfiguration}\n >\n <DialogTitle>Column Configuration</DialogTitle>\n <DialogContent dividers>\n {hasRepeatableSets && (\n <>\n <Grid container>\n <Grid item>\n <FormGroup>\n <FormControlLabel\n control={\n <Checkbox checked={!!parameters.unwindRepeatableSets} />\n }\n onChange={(e, checked) => {\n onChangeParameters(\n (currentParameters) => ({\n ...currentParameters,\n sorting: checked\n ? currentParameters.sorting\n : [\n {\n property: 'dateTimeSubmitted',\n direction: 'descending',\n },\n ],\n unwindRepeatableSets: checked,\n }),\n false,\n )\n }}\n label=\"Output a row per repeatable set entry\"\n />\n </FormGroup>\n </Grid>\n <Grid item>\n <IconButton onClick={toggleHelp}>\n <MaterialIcon>help</MaterialIcon>\n </IconButton>\n </Grid>\n </Grid>\n <Collapse in={isHelpOpen}>\n <Alert severity=\"info\">\n <AlertTitle>When this setting is enabled:</AlertTitle>\n <UnorderedList>\n <ListItem>\n Repeatable set columns will be expanded and create\n duplicate rows per entry\n </ListItem>\n <ListItem>\n Columns inside repeatable set entries can be sorted and\n filtered\n </ListItem>\n <ListItem>\n Columns inside repeatable set entries will be included in\n the CSV download\n </ListItem>\n </UnorderedList>\n </Alert>\n </Collapse>\n <Box marginY={2}>\n <Divider />\n </Box>\n </>\n )}\n <FormGroup>\n <FormControlLabel\n control={\n <Checkbox\n {...toggleHideAllColumnsProps}\n indeterminate={!!toggleHideAllColumnsProps.indeterminate}\n />\n }\n label={<b>Toggle All</b>}\n />\n {allColumns.map((column) => {\n return (\n <React.Fragment key={column.id}>\n <FormControlLabel\n control={<Checkbox {...column.getToggleHiddenProps()} />}\n label={\n <>\n {column.headerText}\n {column.tooltip && (\n <Typography component=\"span\" color=\"textSecondary\">\n {' '}\n ({column.tooltip})\n </Typography>\n )}\n </>\n }\n />\n </React.Fragment>\n )\n })}\n </FormGroup>\n </DialogContent>\n <DialogActions>\n <Button\n onClick={hideColumnConfiguration}\n color=\"primary\"\n variant=\"contained\"\n >\n Done\n </Button>\n </DialogActions>\n </Dialog>\n </>\n )\n}\n\n/**\n * @param props\n * @returns\n * @group Components\n */\nexport default React.memo(OneBlinkFormStoreColumnsButton)\n"]}
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@oneblink/apps-react",
|
3
3
|
"description": "Helper functions for OneBlink apps in ReactJS.",
|
4
|
-
"version": "5.12.0-beta.
|
4
|
+
"version": "5.12.0-beta.13",
|
5
5
|
"author": "OneBlink <developers@oneblink.io> (https://oneblink.io)",
|
6
6
|
"bugs": {
|
7
7
|
"url": "https://github.com/oneblink/apps-react/issues"
|
@@ -10,7 +10,7 @@
|
|
10
10
|
"@arcgis/core": "^4.28.10",
|
11
11
|
"@emotion/react": "^11.11.3",
|
12
12
|
"@emotion/styled": "^11.11.0",
|
13
|
-
"@oneblink/sdk-core": "^6.0.1-beta.
|
13
|
+
"@oneblink/sdk-core": "^6.0.1-beta.2",
|
14
14
|
"@react-google-maps/api": "2.19.2",
|
15
15
|
"blueimp-load-image": "^5.16.0",
|
16
16
|
"bulma": "^0.9.4",
|