├── .babelrc ├── .eslintignore ├── .eslintrc.json ├── .gitignore ├── .husky └── pre-commit ├── .lintstagedrc.json ├── .npmignore ├── .prettierignore ├── .prettierrc.json ├── README.md ├── commitlint.config.js ├── examples ├── .gitignore ├── index.html ├── index.ts ├── package-lock.json ├── package.json ├── src │ ├── App.tsx │ ├── blocks │ │ ├── checkbox.tsx │ │ ├── input.tsx │ │ └── inputAdapter.tsx │ ├── cases │ │ ├── field-group.tsx │ │ ├── field-list-manager-with-id.tsx │ │ ├── field-list-manager.tsx │ │ ├── field-list-with-id.tsx │ │ ├── field-list-with-validator.tsx │ │ ├── field-list.tsx │ │ ├── field-with-validator.tsx │ │ ├── field.tsx │ │ ├── index.tsx │ │ ├── one-of-field-group.tsx │ │ ├── passowrd.tsx │ │ └── picked-field-group.tsx │ ├── main.tsx │ ├── utils.ts │ └── vite-env.d.ts ├── tsconfig.json ├── tsconfig.node.json └── vite.config.ts ├── package.json ├── src ├── controlled-field-list.ts ├── counter.ts ├── field-group.ts ├── field-list-core.ts ├── field-list-manager.ts ├── field-list.ts ├── field.ts ├── hooks.ts ├── index.ts ├── types │ ├── field-group.ts │ ├── field-list-manager.ts │ ├── field-list.ts │ ├── field.ts │ ├── form-unit.ts │ ├── hooks.ts │ ├── index.ts │ ├── utils.ts │ └── validator.ts ├── unit.ts ├── utils.ts └── validator │ ├── common.ts │ ├── field-list-validator.ts │ ├── field-validator.ts │ └── index.ts ├── tests ├── controlled-field-list.test.ts ├── field-list-core.test.ts ├── field-list.test.ts ├── field.test.ts └── validator.test.ts ├── tsconfig.build.json ├── tsconfig.json └── vitest.config.ts /.babelrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/.babelrc -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/.eslintignore -------------------------------------------------------------------------------- /.eslintrc.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/.eslintrc.json -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist -------------------------------------------------------------------------------- /.husky/pre-commit: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/.husky/pre-commit -------------------------------------------------------------------------------- /.lintstagedrc.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/.lintstagedrc.json -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/.npmignore -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | dist 2 | node_modules -------------------------------------------------------------------------------- /.prettierrc.json: -------------------------------------------------------------------------------- 1 | {} 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/README.md -------------------------------------------------------------------------------- /commitlint.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { extends: ["@commitlint/config-conventional"] }; 2 | -------------------------------------------------------------------------------- /examples/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/.gitignore -------------------------------------------------------------------------------- /examples/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/index.html -------------------------------------------------------------------------------- /examples/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/index.ts -------------------------------------------------------------------------------- /examples/package-lock.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/package-lock.json -------------------------------------------------------------------------------- /examples/package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/package.json -------------------------------------------------------------------------------- /examples/src/App.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/App.tsx -------------------------------------------------------------------------------- /examples/src/blocks/checkbox.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/blocks/checkbox.tsx -------------------------------------------------------------------------------- /examples/src/blocks/input.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/blocks/input.tsx -------------------------------------------------------------------------------- /examples/src/blocks/inputAdapter.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/blocks/inputAdapter.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-group.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-group.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-list-manager-with-id.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-list-manager-with-id.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-list-manager.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-list-manager.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-list-with-id.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-list-with-id.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-list-with-validator.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-list-with-validator.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-list.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-list.tsx -------------------------------------------------------------------------------- /examples/src/cases/field-with-validator.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field-with-validator.tsx -------------------------------------------------------------------------------- /examples/src/cases/field.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/field.tsx -------------------------------------------------------------------------------- /examples/src/cases/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/index.tsx -------------------------------------------------------------------------------- /examples/src/cases/one-of-field-group.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/one-of-field-group.tsx -------------------------------------------------------------------------------- /examples/src/cases/passowrd.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/passowrd.tsx -------------------------------------------------------------------------------- /examples/src/cases/picked-field-group.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/cases/picked-field-group.tsx -------------------------------------------------------------------------------- /examples/src/main.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/main.tsx -------------------------------------------------------------------------------- /examples/src/utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/src/utils.ts -------------------------------------------------------------------------------- /examples/src/vite-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | -------------------------------------------------------------------------------- /examples/tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/tsconfig.json -------------------------------------------------------------------------------- /examples/tsconfig.node.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/tsconfig.node.json -------------------------------------------------------------------------------- /examples/vite.config.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/examples/vite.config.ts -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/package.json -------------------------------------------------------------------------------- /src/controlled-field-list.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/controlled-field-list.ts -------------------------------------------------------------------------------- /src/counter.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/counter.ts -------------------------------------------------------------------------------- /src/field-group.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/field-group.ts -------------------------------------------------------------------------------- /src/field-list-core.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/field-list-core.ts -------------------------------------------------------------------------------- /src/field-list-manager.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/field-list-manager.ts -------------------------------------------------------------------------------- /src/field-list.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/field-list.ts -------------------------------------------------------------------------------- /src/field.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/field.ts -------------------------------------------------------------------------------- /src/hooks.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/hooks.ts -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/index.ts -------------------------------------------------------------------------------- /src/types/field-group.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/field-group.ts -------------------------------------------------------------------------------- /src/types/field-list-manager.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/field-list-manager.ts -------------------------------------------------------------------------------- /src/types/field-list.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/field-list.ts -------------------------------------------------------------------------------- /src/types/field.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/field.ts -------------------------------------------------------------------------------- /src/types/form-unit.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/form-unit.ts -------------------------------------------------------------------------------- /src/types/hooks.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/hooks.ts -------------------------------------------------------------------------------- /src/types/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/index.ts -------------------------------------------------------------------------------- /src/types/utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/utils.ts -------------------------------------------------------------------------------- /src/types/validator.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/types/validator.ts -------------------------------------------------------------------------------- /src/unit.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/unit.ts -------------------------------------------------------------------------------- /src/utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/utils.ts -------------------------------------------------------------------------------- /src/validator/common.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/validator/common.ts -------------------------------------------------------------------------------- /src/validator/field-list-validator.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/validator/field-list-validator.ts -------------------------------------------------------------------------------- /src/validator/field-validator.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/validator/field-validator.ts -------------------------------------------------------------------------------- /src/validator/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/src/validator/index.ts -------------------------------------------------------------------------------- /tests/controlled-field-list.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tests/controlled-field-list.test.ts -------------------------------------------------------------------------------- /tests/field-list-core.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tests/field-list-core.test.ts -------------------------------------------------------------------------------- /tests/field-list.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tests/field-list.test.ts -------------------------------------------------------------------------------- /tests/field.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tests/field.test.ts -------------------------------------------------------------------------------- /tests/validator.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tests/validator.test.ts -------------------------------------------------------------------------------- /tsconfig.build.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tsconfig.build.json -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/tsconfig.json -------------------------------------------------------------------------------- /vitest.config.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AlexeyDuybo/formcraft/HEAD/vitest.config.ts --------------------------------------------------------------------------------