Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add paged form, conditionals in schema
- Loading branch information
Showing
39 changed files
with
18,409 additions
and
7,054 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"type": "node", | ||
"request": "launch", | ||
"name": "Jest All", | ||
"program": "${workspaceFolder}/node_modules/.bin/jest", | ||
"args": ["--runInBand"], | ||
"console": "integratedTerminal", | ||
"internalConsoleOptions": "neverOpen", | ||
"disableOptimisticBPs": true, | ||
"windows": { | ||
"program": "${workspaceFolder}/node_modules/jest/bin/jest", | ||
} | ||
}, | ||
{ | ||
"type": "node", | ||
"request": "launch", | ||
"name": "Jest Current File", | ||
"program": "${workspaceFolder}/node_modules/.bin/jest", | ||
"args": [ | ||
"${fileBasenameNoExtension}", | ||
"--config", | ||
"jest.config.js" | ||
], | ||
"console": "integratedTerminal", | ||
"internalConsoleOptions": "neverOpen", | ||
"disableOptimisticBPs": true, | ||
"windows": { | ||
"program": "${workspaceFolder}/node_modules/jest/bin/jest", | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// babel.config.js | ||
module.exports = { | ||
presets: [ | ||
[ | ||
'@babel/preset-env', | ||
{ | ||
targets: { | ||
node: 'current', | ||
}, | ||
}, | ||
], | ||
'@babel/preset-typescript', | ||
] | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import React from 'react'; | ||
import { ISchemaFormProps } from 'components/schema-form'; | ||
export interface ISchemaPagedFormProps extends ISchemaFormProps { | ||
onSubmit?(value: object): void; | ||
onPage?(value: object, page: number): void; | ||
makeNextLink(nextPage: number, onClick: (page: number) => void): React.ReactNode; | ||
makePreviousLink(previousPage: number, onClick: (page: number) => void): React.ReactNode; | ||
makeSubmitLink(onClick: () => void): React.ReactNode; | ||
page: number; | ||
} | ||
export default function SchemaPagedForm(props: ISchemaPagedFormProps): JSX.Element; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
/// <reference types="react" /> | ||
import React from 'react'; | ||
import { ISchemaFormProps } from 'components/schema-form'; | ||
export interface ISchemaSubmitFormProps extends ISchemaFormProps { | ||
onSubmit?(value: object): void; | ||
submitLabel?: string; | ||
makeSubmitLink(onClick: () => void): React.ReactNode; | ||
} | ||
export default function SchemaSubmitForm(props: ISchemaSubmitFormProps): JSX.Element; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
import SchemaForm, { ISchemaFormProps } from "components/schema-form"; | ||
import SchemaSubmitForm, { ISchemaSubmitFormProps } from "components/schema-submit-form"; | ||
import SchemaPagedForm, { ISchemaPagedFormProps } from "components/schema-paged-form"; | ||
import { ActionType } from "components/schema-form-interfaces"; | ||
import { getByPath, setByPath } from 'utility'; | ||
import { ErrorObject } from 'error'; | ||
import "./scss/layout.scss"; | ||
export default SchemaForm; | ||
export { getByPath, setByPath, ISchemaFormProps, SchemaSubmitForm, ISchemaSubmitFormProps, ErrorObject }; | ||
export { getByPath, setByPath, ISchemaFormProps, SchemaSubmitForm, ISchemaSubmitFormProps, ErrorObject, ActionType, SchemaPagedForm, ISchemaPagedFormProps }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.