@strictly/react-form 0.0.30 → 0.0.32
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/.out/.storybook/preview.js +7 -0
- package/.out/core/mobx/{field_adapter.d.ts → FieldAdapter.d.ts} +1 -1
- package/.out/core/mobx/{field_adapters_of_values.d.ts → FieldAdaptersOfValues.d.ts} +1 -1
- package/.out/core/mobx/{flattened_adapters_of_fields.d.ts → FlattenedAdaptersOfFields.d.ts} +2 -2
- package/.out/core/mobx/{form_fields_of_field_adapters.d.ts → FormFieldsOfFieldAdapters.d.ts} +2 -2
- package/.out/core/mobx/{form_model.d.ts → FormModel.d.ts} +6 -5
- package/.out/core/mobx/{form_model.js → FormModel.js} +47 -35
- package/.out/core/mobx/{field_adapter_builder.d.ts → fieldAdapterBuilder.d.ts} +2 -2
- package/.out/core/mobx/{field_adapter_builder.js → fieldAdapterBuilder.js} +6 -6
- package/.out/core/mobx/hooks.d.ts +1 -1
- package/.out/core/mobx/hooks.js +15 -6
- package/.out/core/mobx/{merge_field_adapters_with_two_way_converter.d.ts → mergeFieldAdaptersWithTwoWayConverter.d.ts} +2 -2
- package/.out/core/mobx/{merge_field_adapters_with_two_way_converter.js → mergeFieldAdaptersWithTwoWayConverter.js} +1 -1
- package/.out/core/mobx/{merge_field_adapters_with_validators.d.ts → mergeFieldAdaptersWithValidators.d.ts} +1 -1
- package/.out/core/mobx/{merge_field_adapters_with_validators.js → mergeFieldAdaptersWithValidators.js} +1 -1
- package/.out/core/mobx/peek.d.ts +5 -0
- package/.out/core/mobx/peek.js +16 -0
- package/.out/core/mobx/specs/{form_model.tests.js → FormModel.tests.js} +8 -8
- package/.out/core/mobx/specs/{merge_field_adapters_with_two_way_converter.tests.js → MergeFieldAdaptersWithTwoWayConverter.tests.js} +4 -4
- package/.out/core/mobx/specs/{merge_field_adapters_with_validators.tests.js → MergeFieldAdaptersWithValidators.tests.js} +3 -3
- package/.out/core/mobx/specs/fixtures.d.ts +2 -2
- package/.out/core/mobx/specs/{sub_form_field_adapters.tests.js → subFormFieldAdapters.tests.js} +2 -2
- package/.out/core/mobx/{sub_form_field_adapters.d.ts → subFormFieldAdapters.d.ts} +1 -1
- package/.out/core/props.d.ts +1 -1
- package/.out/field_converters/{integer_to_string_converter.d.ts → IntegerToStringConverter.d.ts} +1 -1
- package/.out/field_converters/{integer_to_string_converter.js → IntegerToStringConverter.js} +1 -1
- package/.out/field_converters/{maybe_identity_converter.d.ts → MaybeIdentityConverter.d.ts} +1 -1
- package/.out/field_converters/{nullable_to_boolean_converter.d.ts → NullableToBooleanConverter.d.ts} +1 -1
- package/.out/field_converters/{nullable_to_boolean_converter.js → NullableToBooleanConverter.js} +1 -1
- package/.out/field_converters/{select_value_type_converter.d.ts → SelectValueTypeConverter.d.ts} +1 -1
- package/.out/field_converters/{select_value_type_converter.js → SelectValueTypeConverter.js} +1 -1
- package/.out/field_converters/{trimming_string_converter.d.ts → TrimmingStringConverter.d.ts} +1 -1
- package/.out/field_converters/{trimming_string_converter.js → TrimmingStringConverter.js} +1 -1
- package/.out/field_converters/{chain_field_converter.d.ts → chainFieldConverter.d.ts} +1 -1
- package/.out/field_converters/{chain_field_converter.js → chainFieldConverter.js} +1 -1
- package/.out/field_converters/{identity_converter.d.ts → identityConverter.d.ts} +1 -1
- package/.out/field_converters/{identity_converter.js → identityConverter.js} +1 -1
- package/.out/field_converters/specs/{chain_field_converter.tests.js → chainFieldConverter.tests.js} +2 -2
- package/.out/field_converters/{validating_converter.d.ts → validatingConverter.d.ts} +1 -1
- package/.out/field_converters/{validating_converter.js → validatingConverter.js} +1 -1
- package/.out/field_value_factories/{prototyping_field_value_factory.d.ts → prototypingFieldValueFactory.d.ts} +1 -1
- package/.out/index.d.ts +23 -22
- package/.out/index.js +23 -22
- package/.out/mantine/{error_renderer.d.ts → ErrorRenderer.d.ts} +2 -2
- package/.out/mantine/{create_checkbox.d.ts → createCheckbox.d.ts} +3 -3
- package/.out/mantine/{create_checkbox.js → createCheckbox.js} +2 -2
- package/.out/mantine/{create_field_view.d.ts → createFieldView.d.ts} +4 -4
- package/.out/mantine/{create_field_view.js → createFieldView.js} +1 -1
- package/.out/mantine/{create_fields_view.d.ts → createFieldsView.d.ts} +3 -3
- package/.out/mantine/{create_form.d.ts → createForm.d.ts} +3 -3
- package/.out/mantine/{create_list.d.ts → createList.d.ts} +3 -3
- package/.out/mantine/{create_list.js → createList.js} +1 -1
- package/.out/mantine/{create_pill.d.ts → createPill.d.ts} +2 -2
- package/.out/mantine/{create_pill.js → createPill.js} +1 -1
- package/.out/mantine/{create_radio.d.ts → createRadio.d.ts} +3 -3
- package/.out/mantine/{create_radio.js → createRadio.js} +1 -1
- package/.out/mantine/{create_radio_group.d.ts → createRadioGroup.d.ts} +3 -3
- package/.out/mantine/{create_radio_group.js → createRadioGroup.js} +2 -2
- package/.out/mantine/{create_text_input.d.ts → createTextInput.d.ts} +3 -3
- package/.out/mantine/{create_text_input.js → createTextInput.js} +2 -2
- package/.out/mantine/{create_value_input.d.ts → createValueInput.d.ts} +4 -4
- package/.out/mantine/{create_value_input.js → createValueInput.js} +2 -2
- package/.out/mantine/hooks.d.ts +18 -18
- package/.out/mantine/hooks.js +10 -10
- package/.out/mantine/specs/{checkbox_hooks.stories.d.ts → checkboxHooks.stories.d.ts} +1 -1
- package/.out/mantine/specs/{checkbox_hooks.stories.js → checkboxHooks.stories.js} +1 -1
- package/.out/mantine/specs/{checkbox_hooks.tests.js → checkboxHooks.tests.js} +2 -2
- package/.out/mantine/specs/{field_view_hooks.stories.d.ts → fieldViewHooks.stories.d.ts} +1 -1
- package/.out/mantine/specs/{field_view_hooks.tests.js → fieldViewHooks.tests.js} +1 -1
- package/.out/mantine/specs/{fields_view_hooks.stories.d.ts → fieldsViewHooks.stories.d.ts} +1 -1
- package/.out/mantine/specs/{fields_view_hooks.tests.js → fieldsViewHooks.tests.js} +1 -1
- package/.out/mantine/specs/{form_hooks.stories.d.ts → formHooks.stories.d.ts} +1 -1
- package/.out/mantine/specs/{form_hooks.tests.js → formHooks.tests.js} +1 -1
- package/.out/mantine/specs/{list_hooks.stories.d.ts → listHooks.stories.d.ts} +1 -1
- package/.out/mantine/specs/{list_hooks.tests.js → listHooks.tests.js} +1 -1
- package/.out/mantine/specs/{radio_group_hooks.stories.d.ts → radioGroupHooks.stories.d.ts} +2 -2
- package/.out/mantine/specs/{radio_group_hooks.stories.js → radioGroupHooks.stories.js} +1 -1
- package/.out/mantine/specs/{radio_group_hooks.tests.js → radioGroupHooks.tests.js} +2 -2
- package/.out/mantine/specs/{select_hooks.stories.d.ts → selectHooks.stories.d.ts} +1 -1
- package/.out/mantine/specs/{select_hooks.stories.js → selectHooks.stories.js} +1 -1
- package/.out/mantine/specs/{select_hooks.tests.js → selectHooks.tests.js} +1 -1
- package/.out/mantine/specs/{text_input_hooks.stories.d.ts → textInputHooks.stories.d.ts} +2 -2
- package/.out/mantine/specs/{text_input_hooks.stories.js → textInputHooks.stories.js} +1 -1
- package/.out/mantine/specs/{text_input_hooks.tests.js → textInputHooks.tests.js} +2 -2
- package/.out/mantine/specs/{value_input_hooks.stories.d.ts → valueInputHooks.stories.d.ts} +2 -2
- package/.out/mantine/specs/{value_input_hooks.stories.js → valueInputHooks.stories.js} +1 -1
- package/.out/mantine/specs/{value_input_hooks.tests.js → valueInputHooks.tests.js} +1 -1
- package/.out/mantine/types.d.ts +3 -3
- package/.out/tsconfig.tsbuildinfo +1 -1
- package/.out/types/{all_fields_of_fields.d.ts → AllFieldsOfFields.d.ts} +2 -2
- package/.out/types/{boolean_fields_of_fields.d.ts → BooleanFieldsOfFields.d.ts} +2 -2
- package/.out/types/{error_of_field.d.ts → ErrorOfField.d.ts} +1 -1
- package/.out/types/{flattened_validators_of_fields.d.ts → FlattenedValidatorsOfFields.d.ts} +1 -1
- package/.out/types/{list_fields_of_fields.d.ts → ListFieldsOfFields.d.ts} +2 -2
- package/.out/types/{string_fields_of_fields.d.ts → StringFieldsOfFields.d.ts} +2 -2
- package/.out/types/{sub_form_fields.d.ts → SubFormFields.d.ts} +1 -1
- package/.out/types/{value_type_of_field.d.ts → ValueTypeOfField.d.ts} +1 -1
- package/.out/types/specs/{merge_validators.tests.js → MergeValidators.tests.js} +1 -1
- package/.out/vitest.workspace.js +4 -4
- package/.storybook/preview.tsx +8 -0
- package/.turbo/turbo-build.log +7 -7
- package/.turbo/turbo-check-types.log +1 -1
- package/.turbo/turbo-release$colon$exports.log +1 -1
- package/core/mobx/{field_adapter.ts → FieldAdapter.ts} +1 -1
- package/core/mobx/{field_adapters_of_values.ts → FieldAdaptersOfValues.ts} +1 -1
- package/core/mobx/{flattened_adapters_of_fields.ts → FlattenedAdaptersOfFields.ts} +2 -2
- package/core/mobx/{form_fields_of_field_adapters.ts → FormFieldsOfFieldAdapters.ts} +2 -2
- package/core/mobx/{form_model.ts → FormModel.ts} +33 -26
- package/core/mobx/{field_adapter_builder.ts → fieldAdapterBuilder.ts} +7 -7
- package/core/mobx/hooks.tsx +19 -7
- package/core/mobx/{merge_field_adapters_with_two_way_converter.ts → mergeFieldAdaptersWithTwoWayConverter.ts} +3 -3
- package/core/mobx/{merge_field_adapters_with_validators.ts → mergeFieldAdaptersWithValidators.ts} +2 -2
- package/core/mobx/peek.ts +17 -0
- package/core/mobx/specs/{flattened_adapters_of_fields.tests.ts → FlattenedAdaptersOfFields.tests.ts} +3 -3
- package/core/mobx/specs/{flattened_list_types_of_types.tests.ts → FlattenedListTypesOfTypes.tests.ts} +1 -1
- package/core/mobx/specs/{form_model.tests.ts → FormModel.tests.ts} +10 -10
- package/core/mobx/specs/{merge_field_adapters_with_two_way_converter.tests.ts → MergeFieldAdaptersWithTwoWayConverter.tests.ts} +5 -5
- package/core/mobx/specs/{merge_field_adapters_with_validators.tests.ts → MergeFieldAdaptersWithValidators.tests.ts} +4 -4
- package/core/mobx/specs/fixtures.ts +2 -2
- package/core/mobx/specs/{sub_form_field_adapters.tests.ts → subFormFieldAdapters.tests.ts} +3 -3
- package/core/mobx/{sub_form_field_adapters.ts → subFormFieldAdapters.ts} +1 -1
- package/core/props.ts +1 -1
- package/dist/index.cjs +161 -132
- package/dist/index.d.cts +19 -12
- package/dist/index.d.ts +19 -12
- package/dist/index.js +166 -136
- package/field_converters/{integer_to_string_converter.ts → IntegerToStringConverter.ts} +1 -1
- package/field_converters/{maybe_identity_converter.ts → MaybeIdentityConverter.ts} +1 -1
- package/field_converters/{nullable_to_boolean_converter.ts → NullableToBooleanConverter.ts} +1 -1
- package/field_converters/{select_value_type_converter.ts → SelectValueTypeConverter.ts} +1 -1
- package/field_converters/{trimming_string_converter.ts → TrimmingStringConverter.ts} +1 -1
- package/field_converters/{chain_field_converter.ts → chainFieldConverter.ts} +1 -1
- package/field_converters/{identity_converter.ts → identityConverter.ts} +1 -1
- package/field_converters/specs/{chain_field_converter.tests.ts → chainFieldConverter.tests.ts} +2 -2
- package/field_converters/{validating_converter.ts → validatingConverter.ts} +1 -1
- package/field_value_factories/{prototyping_field_value_factory.ts → prototypingFieldValueFactory.ts} +1 -1
- package/index.ts +23 -22
- package/mantine/{error_renderer.ts → ErrorRenderer.ts} +2 -2
- package/mantine/{create_checkbox.tsx → createCheckbox.tsx} +5 -5
- package/mantine/{create_field_view.tsx → createFieldView.tsx} +5 -5
- package/mantine/{create_fields_view.tsx → createFieldsView.tsx} +4 -4
- package/mantine/{create_form.tsx → createForm.tsx} +3 -3
- package/mantine/{create_list.tsx → createList.tsx} +4 -4
- package/mantine/{create_pill.tsx → createPill.tsx} +3 -3
- package/mantine/{create_radio.tsx → createRadio.tsx} +4 -4
- package/mantine/{create_radio_group.tsx → createRadioGroup.tsx} +5 -5
- package/mantine/{create_text_input.tsx → createTextInput.tsx} +5 -5
- package/mantine/{create_value_input.tsx → createValueInput.tsx} +6 -6
- package/mantine/hooks.tsx +22 -22
- package/mantine/specs/{create_fields_view.tests.ts → CreateFieldsView.tests.ts} +1 -1
- package/mantine/specs/{checkbox_hooks.stories.tsx → checkboxHooks.stories.tsx} +2 -2
- package/mantine/specs/{checkbox_hooks.tests.tsx → checkboxHooks.tests.tsx} +2 -2
- package/mantine/specs/{field_view_hooks.stories.tsx → fieldViewHooks.stories.tsx} +1 -1
- package/mantine/specs/{field_view_hooks.tests.tsx → fieldViewHooks.tests.tsx} +1 -1
- package/mantine/specs/{fields_view_hooks.stories.tsx → fieldsViewHooks.stories.tsx} +1 -1
- package/mantine/specs/{fields_view_hooks.tests.tsx → fieldsViewHooks.tests.tsx} +1 -1
- package/mantine/specs/{form_hooks.stories.tsx → formHooks.stories.tsx} +1 -1
- package/mantine/specs/{form_hooks.tests.tsx → formHooks.tests.tsx} +1 -1
- package/mantine/specs/{list_hooks.stories.tsx → listHooks.stories.tsx} +1 -1
- package/mantine/specs/{list_hooks.tests.tsx → listHooks.tests.tsx} +1 -1
- package/mantine/specs/{radio_group_hooks.stories.tsx → radioGroupHooks.stories.tsx} +3 -3
- package/mantine/specs/{radio_group_hooks.tests.tsx → radioGroupHooks.tests.tsx} +2 -2
- package/mantine/specs/{select_hooks.stories.tsx → selectHooks.stories.tsx} +2 -2
- package/mantine/specs/{select_hooks.tests.tsx → selectHooks.tests.tsx} +1 -1
- package/mantine/specs/{text_input_hooks.stories.tsx → textInputHooks.stories.tsx} +3 -3
- package/mantine/specs/{text_input_hooks.tests.tsx → textInputHooks.tests.tsx} +2 -2
- package/mantine/specs/{value_input_hooks.stories.tsx → valueInputHooks.stories.tsx} +3 -3
- package/mantine/specs/{value_input_hooks.tests.tsx → valueInputHooks.tests.tsx} +1 -1
- package/mantine/types.ts +3 -3
- package/package.json +1 -1
- package/types/{all_fields_of_fields.ts → AllFieldsOfFields.ts} +2 -2
- package/types/{boolean_fields_of_fields.ts → BooleanFieldsOfFields.ts} +2 -2
- package/types/{error_of_field.ts → ErrorOfField.ts} +1 -1
- package/types/{flattened_validators_of_fields.ts → FlattenedValidatorsOfFields.ts} +1 -1
- package/types/{list_fields_of_fields.ts → ListFieldsOfFields.ts} +2 -2
- package/types/{string_fields_of_fields.ts → StringFieldsOfFields.ts} +2 -2
- package/types/{sub_form_fields.ts → SubFormFields.ts} +1 -1
- package/types/{value_type_of_field.ts → ValueTypeOfField.ts} +1 -1
- package/types/specs/{boolean_fields_of_fields.tests.ts → BooleanFieldsOfFields.tests.ts} +2 -2
- package/types/specs/{error_of_field.tests.ts → ErrorOfField.tests.ts} +2 -2
- package/types/specs/{flattened_validators_of_fields.tests.ts → FlattenedValidatorsOfFields.tests.ts} +2 -2
- package/types/specs/{list_fields_of_fields.tests.ts → ListFieldsOfFields.tests.ts} +2 -2
- package/types/specs/{merge_validators.tests.ts → MergeValidators.tests.ts} +1 -1
- package/types/specs/{string_fields_of_fields.tests.ts → StringFieldsOfFields.tests.ts} +2 -2
- package/types/specs/{sub_form_fields.tests.ts → SubFormFields.tests.ts} +2 -2
- package/types/specs/{value_type_of_field.tests.ts → ValueTypeOfField.tests.ts} +2 -2
- package/util/specs/partial.tests.tsx +1 -1
- package/vitest.workspace.ts +4 -4
- /package/.out/.vitest/{install_deterministic_random.d.ts → installDeterministicRandom.d.ts} +0 -0
- /package/.out/.vitest/{install_deterministic_random.js → installDeterministicRandom.js} +0 -0
- /package/.out/.vitest/{install_storybook_preview.d.ts → installStorybookPreview.d.ts} +0 -0
- /package/.out/.vitest/{install_storybook_preview.js → installStorybookPreview.js} +0 -0
- /package/.out/.vitest/{match_media.d.ts → matchMedia.d.ts} +0 -0
- /package/.out/.vitest/{match_media.js → matchMedia.js} +0 -0
- /package/.out/.vitest/{resize_observer.d.ts → resizeObserver.d.ts} +0 -0
- /package/.out/.vitest/{resize_observer.js → resizeObserver.js} +0 -0
- /package/.out/core/mobx/{field_adapter.js → FieldAdapter.js} +0 -0
- /package/.out/core/mobx/{field_adapters_of_values.js → FieldAdaptersOfValues.js} +0 -0
- /package/.out/core/mobx/{flattened_adapters_of_fields.js → FlattenedAdaptersOfFields.js} +0 -0
- /package/.out/core/mobx/{flattened_list_types_of_type.d.ts → FlattenedListTypesOfType.d.ts} +0 -0
- /package/.out/core/mobx/{flattened_list_types_of_type.js → FlattenedListTypesOfType.js} +0 -0
- /package/.out/core/mobx/{form_fields_of_field_adapters.js → FormFieldsOfFieldAdapters.js} +0 -0
- /package/.out/core/mobx/specs/{flattened_adapters_of_fields.tests.d.ts → FlattenedAdaptersOfFields.tests.d.ts} +0 -0
- /package/.out/core/mobx/specs/{flattened_adapters_of_fields.tests.js → FlattenedAdaptersOfFields.tests.js} +0 -0
- /package/.out/core/mobx/specs/{flattened_list_types_of_types.tests.d.ts → FlattenedListTypesOfTypes.tests.d.ts} +0 -0
- /package/.out/core/mobx/specs/{flattened_list_types_of_types.tests.js → FlattenedListTypesOfTypes.tests.js} +0 -0
- /package/.out/core/mobx/specs/{form_model.tests.d.ts → FormModel.tests.d.ts} +0 -0
- /package/.out/core/mobx/specs/{merge_field_adapters_with_two_way_converter.tests.d.ts → MergeFieldAdaptersWithTwoWayConverter.tests.d.ts} +0 -0
- /package/.out/core/mobx/specs/{merge_field_adapters_with_validators.tests.d.ts → MergeFieldAdaptersWithValidators.tests.d.ts} +0 -0
- /package/.out/core/mobx/specs/{sub_form_field_adapters.tests.d.ts → subFormFieldAdapters.tests.d.ts} +0 -0
- /package/.out/core/mobx/{sub_form_field_adapters.js → subFormFieldAdapters.js} +0 -0
- /package/.out/field_converters/{maybe_identity_converter.js → MaybeIdentityConverter.js} +0 -0
- /package/.out/field_converters/specs/{chain_field_converter.tests.d.ts → chainFieldConverter.tests.d.ts} +0 -0
- /package/.out/field_value_factories/{prototyping_field_value_factory.js → prototypingFieldValueFactory.js} +0 -0
- /package/.out/mantine/{error_renderer.js → ErrorRenderer.js} +0 -0
- /package/.out/mantine/{create_fields_view.js → createFieldsView.js} +0 -0
- /package/.out/mantine/{create_form.js → createForm.js} +0 -0
- /package/.out/mantine/specs/{checkbox_hooks.tests.d.ts → CreateFieldsView.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{create_fields_view.tests.js → CreateFieldsView.tests.js} +0 -0
- /package/.out/mantine/specs/{checkbox_constants.d.ts → checkboxConstants.d.ts} +0 -0
- /package/.out/mantine/specs/{checkbox_constants.js → checkboxConstants.js} +0 -0
- /package/.out/mantine/specs/{create_fields_view.tests.d.ts → checkboxHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{field_view_hooks.stories.js → fieldViewHooks.stories.js} +0 -0
- /package/.out/mantine/specs/{field_view_hooks.tests.d.ts → fieldViewHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{fields_view_hooks.stories.js → fieldsViewHooks.stories.js} +0 -0
- /package/.out/mantine/specs/{fields_view_hooks.tests.d.ts → fieldsViewHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{form_hooks.stories.js → formHooks.stories.js} +0 -0
- /package/.out/mantine/specs/{form_hooks.tests.d.ts → formHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{list_hooks.stories.js → listHooks.stories.js} +0 -0
- /package/.out/mantine/specs/{list_hooks.tests.d.ts → listHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{radio_group_constants.d.ts → radioGroupConstants.d.ts} +0 -0
- /package/.out/mantine/specs/{radio_group_constants.js → radioGroupConstants.js} +0 -0
- /package/.out/mantine/specs/{radio_group_hooks.tests.d.ts → radioGroupHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{select_hooks.tests.d.ts → selectHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{select_hooks_constant.d.ts → selectHooksConstant.d.ts} +0 -0
- /package/.out/mantine/specs/{select_hooks_constant.js → selectHooksConstant.js} +0 -0
- /package/.out/mantine/specs/{text_input_constants.d.ts → textInputConstants.d.ts} +0 -0
- /package/.out/mantine/specs/{text_input_constants.js → textInputConstants.js} +0 -0
- /package/.out/mantine/specs/{text_input_hooks.tests.d.ts → textInputHooks.tests.d.ts} +0 -0
- /package/.out/mantine/specs/{value_input_constants.d.ts → valueInputConstants.d.ts} +0 -0
- /package/.out/mantine/specs/{value_input_constants.js → valueInputConstants.js} +0 -0
- /package/.out/mantine/specs/{value_input_hooks.tests.d.ts → valueInputHooks.tests.d.ts} +0 -0
- /package/.out/types/{all_fields_of_fields.js → AllFieldsOfFields.js} +0 -0
- /package/.out/types/{boolean_fields_of_fields.js → BooleanFieldsOfFields.js} +0 -0
- /package/.out/types/{error_of_field.js → ErrorOfField.js} +0 -0
- /package/.out/types/{field.d.ts → Field.d.ts} +0 -0
- /package/.out/types/{field.js → Field.js} +0 -0
- /package/.out/types/{field_converters.d.ts → FieldConverters.d.ts} +0 -0
- /package/.out/types/{field_converters.js → FieldConverters.js} +0 -0
- /package/.out/types/{flattened_validators_of_fields.js → FlattenedValidatorsOfFields.js} +0 -0
- /package/.out/types/{list_fields_of_fields.js → ListFieldsOfFields.js} +0 -0
- /package/.out/types/{specs/boolean_fields_of_fields.tests.d.ts → StringFieldsOfFields.js} +0 -0
- /package/.out/types/{specs/error_of_field.tests.d.ts → SubFormFields.js} +0 -0
- /package/.out/types/{specs/flattened_validators_of_fields.tests.d.ts → ValueTypeOfField.js} +0 -0
- /package/.out/types/{merge_validators.d.ts → mergeValidators.d.ts} +0 -0
- /package/.out/types/{merge_validators.js → mergeValidators.js} +0 -0
- /package/.out/types/specs/{list_fields_of_fields.tests.d.ts → BooleanFieldsOfFields.tests.d.ts} +0 -0
- /package/.out/types/specs/{boolean_fields_of_fields.tests.js → BooleanFieldsOfFields.tests.js} +0 -0
- /package/.out/types/specs/{merge_validators.tests.d.ts → ErrorOfField.tests.d.ts} +0 -0
- /package/.out/types/specs/{error_of_field.tests.js → ErrorOfField.tests.js} +0 -0
- /package/.out/types/specs/{string_fields_of_fields.tests.d.ts → FlattenedValidatorsOfFields.tests.d.ts} +0 -0
- /package/.out/types/specs/{flattened_validators_of_fields.tests.js → FlattenedValidatorsOfFields.tests.js} +0 -0
- /package/.out/types/specs/{sub_form_fields.tests.d.ts → ListFieldsOfFields.tests.d.ts} +0 -0
- /package/.out/types/specs/{list_fields_of_fields.tests.js → ListFieldsOfFields.tests.js} +0 -0
- /package/.out/types/specs/{value_type_of_field.tests.d.ts → MergeValidators.tests.d.ts} +0 -0
- /package/.out/types/{string_fields_of_fields.js → specs/StringFieldsOfFields.tests.d.ts} +0 -0
- /package/.out/types/specs/{string_fields_of_fields.tests.js → StringFieldsOfFields.tests.js} +0 -0
- /package/.out/types/{sub_form_fields.js → specs/SubFormFields.tests.d.ts} +0 -0
- /package/.out/types/specs/{sub_form_fields.tests.js → SubFormFields.tests.js} +0 -0
- /package/.out/types/{value_type_of_field.js → specs/ValueTypeOfField.tests.d.ts} +0 -0
- /package/.out/types/specs/{value_type_of_field.tests.js → ValueTypeOfField.tests.js} +0 -0
- /package/.out/util/{empty.d.ts → Empty.d.ts} +0 -0
- /package/.out/util/{empty.js → Empty.js} +0 -0
- /package/.out/util/{partial.d.ts → Partial.d.ts} +0 -0
- /package/.out/util/{partial.js → Partial.js} +0 -0
- /package/.vitest/{install_deterministic_random.ts → installDeterministicRandom.ts} +0 -0
- /package/.vitest/{install_storybook_preview.ts → installStorybookPreview.ts} +0 -0
- /package/.vitest/{match_media.ts → matchMedia.ts} +0 -0
- /package/.vitest/{resize_observer.ts → resizeObserver.ts} +0 -0
- /package/core/mobx/{flattened_list_types_of_type.ts → FlattenedListTypesOfType.ts} +0 -0
- /package/mantine/specs/__snapshots__/{checkbox_hooks.tests.tsx.snap → checkboxHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{field_view_hooks.tests.tsx.snap → fieldViewHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{fields_view_hooks.tests.tsx.snap → fieldsViewHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{form_hooks.tests.tsx.snap → formHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{list_hooks.tests.tsx.snap → listHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{radio_group_hooks.tests.tsx.snap → radioGroupHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{select_hooks.tests.tsx.snap → selectHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{text_input_hooks.tests.tsx.snap → textInputHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/__snapshots__/{value_input_hooks.tests.tsx.snap → valueInputHooks.tests.tsx.snap} +0 -0
- /package/mantine/specs/{checkbox_constants.ts → checkboxConstants.ts} +0 -0
- /package/mantine/specs/{radio_group_constants.ts → radioGroupConstants.ts} +0 -0
- /package/mantine/specs/{select_hooks_constant.ts → selectHooksConstant.ts} +0 -0
- /package/mantine/specs/{text_input_constants.ts → textInputConstants.ts} +0 -0
- /package/mantine/specs/{value_input_constants.ts → valueInputConstants.ts} +0 -0
- /package/types/{field.ts → Field.ts} +0 -0
- /package/types/{field_converters.ts → FieldConverters.ts} +0 -0
- /package/types/{merge_validators.ts → mergeValidators.ts} +0 -0
- /package/util/{empty.tsx → Empty.tsx} +0 -0
- /package/util/{partial.tsx → Partial.tsx} +0 -0
package/.out/field_converters/{trimming_string_converter.d.ts → TrimmingStringConverter.d.ts}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type AnnotatedFieldConversion, type TwoWayFieldConverter, type UnreliableFieldConversion } from 'types/
|
|
1
|
+
import { type AnnotatedFieldConversion, type TwoWayFieldConverter, type UnreliableFieldConversion } from 'types/FieldConverters';
|
|
2
2
|
export declare class TrimmingStringConverter<ValuePath extends string, Context> implements TwoWayFieldConverter<string, string, never, ValuePath, Context> {
|
|
3
3
|
constructor();
|
|
4
4
|
convert(to: string): AnnotatedFieldConversion<string>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { type AnnotatedFieldConverter, type UnreliableFieldConverter } from 'types/
|
|
1
|
+
import { type AnnotatedFieldConverter, type UnreliableFieldConverter } from 'types/FieldConverters';
|
|
2
2
|
export declare function chainUnreliableFieldConverter<From, Intermediate, To, E1, E2, ValuePath extends string, Context>(from: UnreliableFieldConverter<From, Intermediate, E1, ValuePath, Context>, to: UnreliableFieldConverter<Intermediate, To, E2, ValuePath, Context>): UnreliableFieldConverter<From, To, E1 | E2, ValuePath, Context>;
|
|
3
3
|
export declare function chainAnnotatedFieldConverter<From, Intermediate, To, ValuePath extends string, Context>(from: AnnotatedFieldConverter<From, Intermediate, ValuePath, Context>, to: AnnotatedFieldConverter<Intermediate, To, ValuePath, Context>): AnnotatedFieldConverter<From, To, ValuePath, Context>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { UnreachableError, } from '@strictly/base';
|
|
2
|
-
import { UnreliableFieldConversionType, } from 'types/
|
|
2
|
+
import { UnreliableFieldConversionType, } from 'types/FieldConverters';
|
|
3
3
|
export function chainUnreliableFieldConverter(from, to) {
|
|
4
4
|
return function (value, valuePath, context) {
|
|
5
5
|
const fromConversion = from(value, valuePath, context);
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { type AnnotatedFieldConverter, type UnreliableFieldConverter } from 'types/
|
|
1
|
+
import { type AnnotatedFieldConverter, type UnreliableFieldConverter } from 'types/FieldConverters';
|
|
2
2
|
export declare function annotatedIdentityConverter<V, ValuePath extends string, Context>(required?: boolean): AnnotatedFieldConverter<V, V, ValuePath, Context>;
|
|
3
3
|
export declare function unreliableIdentityConverter<V, ValuePath extends string, Context>(): UnreliableFieldConverter<V, V, never, ValuePath, Context>;
|
package/.out/field_converters/specs/{chain_field_converter.tests.js → chainFieldConverter.tests.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { chainAnnotatedFieldConverter, chainUnreliableFieldConverter, } from 'field_converters/
|
|
2
|
-
import { UnreliableFieldConversionType, } from 'types/
|
|
1
|
+
import { chainAnnotatedFieldConverter, chainUnreliableFieldConverter, } from 'field_converters/chainFieldConverter';
|
|
2
|
+
import { UnreliableFieldConversionType, } from 'types/FieldConverters';
|
|
3
3
|
const CONTEXT = 'ctx';
|
|
4
4
|
const ERROR1 = 'error 1';
|
|
5
5
|
const ERROR2 = 'error 2';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { type Validator } from '@strictly/define';
|
|
2
|
-
import { type UnreliableFieldConverter } from 'types/
|
|
2
|
+
import { type UnreliableFieldConverter } from 'types/FieldConverters';
|
|
3
3
|
export declare function validatingConverter<V, E, ValuePath extends string, Context>(validators?: readonly Validator<V, E, ValuePath, Context>[]): UnreliableFieldConverter<V, V, E, ValuePath, Context>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { validate, } from '@strictly/define';
|
|
2
|
-
import { UnreliableFieldConversionType, } from 'types/
|
|
2
|
+
import { UnreliableFieldConversionType, } from 'types/FieldConverters';
|
|
3
3
|
// delete this?
|
|
4
4
|
export function validatingConverter(validators = []) {
|
|
5
5
|
return function (value, valuePath, context) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type FieldValueFactory } from 'types/
|
|
1
|
+
import { type FieldValueFactory } from 'types/FieldConverters';
|
|
2
2
|
export declare function prototypingFieldValueFactory<V, ValuePath extends string, Context>(prototype: V): FieldValueFactory<V, ValuePath, Context>;
|
package/.out/index.d.ts
CHANGED
|
@@ -1,25 +1,26 @@
|
|
|
1
|
-
export * from './core/mobx/
|
|
2
|
-
export * from './core/mobx/
|
|
3
|
-
export * from './core/mobx/
|
|
4
|
-
export * from './core/mobx/
|
|
5
|
-
export * from './core/mobx/
|
|
6
|
-
export * from './core/mobx/
|
|
1
|
+
export * from './core/mobx/FieldAdapter';
|
|
2
|
+
export * from './core/mobx/fieldAdapterBuilder';
|
|
3
|
+
export * from './core/mobx/FieldAdaptersOfValues';
|
|
4
|
+
export * from './core/mobx/FlattenedAdaptersOfFields';
|
|
5
|
+
export * from './core/mobx/FormFieldsOfFieldAdapters';
|
|
6
|
+
export * from './core/mobx/FormModel';
|
|
7
7
|
export * from './core/mobx/hooks';
|
|
8
|
-
export * from './core/mobx/
|
|
9
|
-
export * from './core/mobx/
|
|
10
|
-
export * from './core/mobx/
|
|
8
|
+
export * from './core/mobx/mergeFieldAdaptersWithTwoWayConverter';
|
|
9
|
+
export * from './core/mobx/mergeFieldAdaptersWithValidators';
|
|
10
|
+
export * from './core/mobx/peek';
|
|
11
|
+
export * from './core/mobx/subFormFieldAdapters';
|
|
11
12
|
export * from './core/props';
|
|
12
|
-
export * from './field_converters/
|
|
13
|
-
export * from './field_converters/
|
|
14
|
-
export * from './field_converters/
|
|
15
|
-
export * from './field_converters/
|
|
16
|
-
export * from './field_converters/
|
|
17
|
-
export * from './field_value_factories/
|
|
18
|
-
export * from './mantine/
|
|
13
|
+
export * from './field_converters/IntegerToStringConverter';
|
|
14
|
+
export * from './field_converters/NullableToBooleanConverter';
|
|
15
|
+
export * from './field_converters/SelectValueTypeConverter';
|
|
16
|
+
export * from './field_converters/TrimmingStringConverter';
|
|
17
|
+
export * from './field_converters/validatingConverter';
|
|
18
|
+
export * from './field_value_factories/prototypingFieldValueFactory';
|
|
19
|
+
export * from './mantine/ErrorRenderer';
|
|
19
20
|
export * from './mantine/hooks';
|
|
20
|
-
export * from './types/
|
|
21
|
-
export * from './types/
|
|
22
|
-
export * from './types/
|
|
23
|
-
export * from './types/
|
|
24
|
-
export * from './util/
|
|
25
|
-
export * from './util/
|
|
21
|
+
export * from './types/ErrorOfField';
|
|
22
|
+
export * from './types/Field';
|
|
23
|
+
export * from './types/FieldConverters';
|
|
24
|
+
export * from './types/mergeValidators';
|
|
25
|
+
export * from './util/Empty';
|
|
26
|
+
export * from './util/Partial';
|
package/.out/index.js
CHANGED
|
@@ -1,25 +1,26 @@
|
|
|
1
|
-
export * from './core/mobx/
|
|
2
|
-
export * from './core/mobx/
|
|
3
|
-
export * from './core/mobx/
|
|
4
|
-
export * from './core/mobx/
|
|
5
|
-
export * from './core/mobx/
|
|
6
|
-
export * from './core/mobx/
|
|
1
|
+
export * from './core/mobx/FieldAdapter';
|
|
2
|
+
export * from './core/mobx/fieldAdapterBuilder';
|
|
3
|
+
export * from './core/mobx/FieldAdaptersOfValues';
|
|
4
|
+
export * from './core/mobx/FlattenedAdaptersOfFields';
|
|
5
|
+
export * from './core/mobx/FormFieldsOfFieldAdapters';
|
|
6
|
+
export * from './core/mobx/FormModel';
|
|
7
7
|
export * from './core/mobx/hooks';
|
|
8
|
-
export * from './core/mobx/
|
|
9
|
-
export * from './core/mobx/
|
|
10
|
-
export * from './core/mobx/
|
|
8
|
+
export * from './core/mobx/mergeFieldAdaptersWithTwoWayConverter';
|
|
9
|
+
export * from './core/mobx/mergeFieldAdaptersWithValidators';
|
|
10
|
+
export * from './core/mobx/peek';
|
|
11
|
+
export * from './core/mobx/subFormFieldAdapters';
|
|
11
12
|
export * from './core/props';
|
|
12
|
-
export * from './field_converters/
|
|
13
|
-
export * from './field_converters/
|
|
14
|
-
export * from './field_converters/
|
|
15
|
-
export * from './field_converters/
|
|
16
|
-
export * from './field_converters/
|
|
17
|
-
export * from './field_value_factories/
|
|
18
|
-
export * from './mantine/
|
|
13
|
+
export * from './field_converters/IntegerToStringConverter';
|
|
14
|
+
export * from './field_converters/NullableToBooleanConverter';
|
|
15
|
+
export * from './field_converters/SelectValueTypeConverter';
|
|
16
|
+
export * from './field_converters/TrimmingStringConverter';
|
|
17
|
+
export * from './field_converters/validatingConverter';
|
|
18
|
+
export * from './field_value_factories/prototypingFieldValueFactory';
|
|
19
|
+
export * from './mantine/ErrorRenderer';
|
|
19
20
|
export * from './mantine/hooks';
|
|
20
|
-
export * from './types/
|
|
21
|
-
export * from './types/
|
|
22
|
-
export * from './types/
|
|
23
|
-
export * from './types/
|
|
24
|
-
export * from './util/
|
|
25
|
-
export * from './util/
|
|
21
|
+
export * from './types/ErrorOfField';
|
|
22
|
+
export * from './types/Field';
|
|
23
|
+
export * from './types/FieldConverters';
|
|
24
|
+
export * from './types/mergeValidators';
|
|
25
|
+
export * from './util/Empty';
|
|
26
|
+
export * from './util/Partial';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ComponentType } from 'react';
|
|
2
|
-
import { type ErrorOfField } from 'types/
|
|
3
|
-
import { type Fields } from 'types/
|
|
2
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
3
|
+
import { type Fields } from 'types/Field';
|
|
4
4
|
type InternalErrorRendererProps<E> = {
|
|
5
5
|
error: E;
|
|
6
6
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type CheckboxProps } from '@mantine/core';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
import { type BooleanFieldsOfFields } from 'types/
|
|
4
|
-
import { type ErrorOfField } from 'types/
|
|
5
|
-
import { type Fields } from 'types/
|
|
3
|
+
import { type BooleanFieldsOfFields } from 'types/BooleanFieldsOfFields';
|
|
4
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
5
|
+
import { type Fields } from 'types/Field';
|
|
6
6
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
7
7
|
export type SuppliedCheckboxProps = Pick<CheckboxProps, 'name' | 'checked' | 'disabled' | 'required' | 'error' | 'onChange' | 'onFocus' | 'onBlur' | 'onKeyUp'>;
|
|
8
8
|
export declare function createCheckbox<F extends Fields, K extends keyof BooleanFieldsOfFields<F>, Props extends SuppliedCheckboxProps>(this: MantineForm<F>, valuePath: K, Checkbox: ComponentType<Props>): MantineFieldComponent<SuppliedCheckboxProps, Props, ErrorOfField<F[K]>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { createUnsafePartialObserverComponent } from 'util/
|
|
3
|
-
import { DefaultErrorRenderer, } from './
|
|
2
|
+
import { createUnsafePartialObserverComponent } from 'util/Partial';
|
|
3
|
+
import { DefaultErrorRenderer, } from './ErrorRenderer';
|
|
4
4
|
export function createCheckbox(valuePath, Checkbox) {
|
|
5
5
|
const onChange = (e) => {
|
|
6
6
|
var _a;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type ComponentType } from 'react';
|
|
2
|
-
import { type AllFieldsOfFields } from 'types/
|
|
3
|
-
import { type ErrorOfField } from 'types/
|
|
4
|
-
import { type Fields } from 'types/
|
|
5
|
-
import { type ValueTypeOfField } from 'types/
|
|
2
|
+
import { type AllFieldsOfFields } from 'types/AllFieldsOfFields';
|
|
3
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
4
|
+
import { type Fields } from 'types/Field';
|
|
5
|
+
import { type ValueTypeOfField } from 'types/ValueTypeOfField';
|
|
6
6
|
import { type MantineForm } from './types';
|
|
7
7
|
export type FieldViewProps<F extends Fields, K extends keyof F> = {
|
|
8
8
|
children: (props: {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { type StringConcatOf } from '@strictly/base';
|
|
2
2
|
import type { FieldsViewProps } from 'core/props';
|
|
3
3
|
import type { ComponentType } from 'react';
|
|
4
|
-
import type { AllFieldsOfFields } from 'types/
|
|
5
|
-
import type { Fields } from 'types/
|
|
6
|
-
import type { SubFormFields } from 'types/
|
|
4
|
+
import type { AllFieldsOfFields } from 'types/AllFieldsOfFields';
|
|
5
|
+
import type { Fields } from 'types/Field';
|
|
6
|
+
import type { SubFormFields } from 'types/SubFormFields';
|
|
7
7
|
import type { MantineFieldComponent } from './types';
|
|
8
8
|
export type SubPathsOf<ValuePath extends string, SubFormValuePath extends string> = SubFormValuePath extends StringConcatOf<ValuePath, infer Postfix> ? `$${Postfix}` : never;
|
|
9
9
|
export type CallbackMapper<ValuePath extends string> = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type FieldsViewProps, type FormProps } from 'core/props';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
import { type AllFieldsOfFields } from 'types/
|
|
4
|
-
import { type Fields } from 'types/
|
|
5
|
-
import { type ValueTypeOfField } from 'types/
|
|
3
|
+
import { type AllFieldsOfFields } from 'types/AllFieldsOfFields';
|
|
4
|
+
import { type Fields } from 'types/Field';
|
|
5
|
+
import { type ValueTypeOfField } from 'types/ValueTypeOfField';
|
|
6
6
|
import { type MantineFieldComponent } from './types';
|
|
7
7
|
export declare function createForm<F extends Fields, K extends keyof AllFieldsOfFields<F>, P extends FormProps<ValueTypeOfField<F[K]>> = FormProps<ValueTypeOfField<F[K]>>>(valuePath: K, Form: ComponentType<P>, observableProps: FieldsViewProps<F>): MantineFieldComponent<FormProps<ValueTypeOfField<F[K]>>, P, never>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type ElementOfArray } from '@strictly/base';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
import { type Fields } from 'types/
|
|
4
|
-
import { type ListFieldsOfFields } from 'types/
|
|
5
|
-
import { type ValueTypeOfField } from 'types/
|
|
3
|
+
import { type Fields } from 'types/Field';
|
|
4
|
+
import { type ListFieldsOfFields } from 'types/ListFieldsOfFields';
|
|
5
|
+
import { type ValueTypeOfField } from 'types/ValueTypeOfField';
|
|
6
6
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
7
7
|
export type SuppliedListProps<Value = any, ListPath extends string = string> = {
|
|
8
8
|
values: readonly Value[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { assertExistsAndReturn, } from '@strictly/base';
|
|
3
3
|
import { Fragment, } from 'react';
|
|
4
|
-
import { createUnsafePartialObserverComponent } from 'util/
|
|
4
|
+
import { createUnsafePartialObserverComponent } from 'util/Partial';
|
|
5
5
|
export function createList(valuePath, List) {
|
|
6
6
|
const propSource = () => {
|
|
7
7
|
const field = this.fields[valuePath];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type PillProps } from '@mantine/core';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
import { type AllFieldsOfFields } from 'types/
|
|
4
|
-
import { type Fields } from 'types/
|
|
3
|
+
import { type AllFieldsOfFields } from 'types/AllFieldsOfFields';
|
|
4
|
+
import { type Fields } from 'types/Field';
|
|
5
5
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
6
6
|
export type SuppliedPillProps = Pick<PillProps, 'children' | 'disabled'>;
|
|
7
7
|
export declare function createPill<F extends Fields, K extends keyof AllFieldsOfFields<F>, Props extends SuppliedPillProps>(this: MantineForm<F>, valuePath: K, Pill: ComponentType<Props>): MantineFieldComponent<SuppliedPillProps, Props, never>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type RadioProps } from '@mantine/core';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
import { type Fields } from 'types/
|
|
4
|
-
import { type StringFieldsOfFields } from 'types/
|
|
5
|
-
import { type ValueTypeOfField } from 'types/
|
|
3
|
+
import { type Fields } from 'types/Field';
|
|
4
|
+
import { type StringFieldsOfFields } from 'types/StringFieldsOfFields';
|
|
5
|
+
import { type ValueTypeOfField } from 'types/ValueTypeOfField';
|
|
6
6
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
7
7
|
export type SuppliedRadioProps = Pick<RadioProps, 'value' | 'disabled'>;
|
|
8
8
|
export declare function createRadio<F extends Fields, K extends keyof StringFieldsOfFields<F>, Props extends SuppliedRadioProps>(this: MantineForm<F>, valuePath: K, value: ValueTypeOfField<F[K]>, Radio: ComponentType<Props>): MantineFieldComponent<SuppliedRadioProps, Props, never>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type RadioGroupProps } from '@mantine/core';
|
|
2
2
|
import { type ComponentType } from 'react';
|
|
3
|
-
import { type ErrorOfField } from 'types/
|
|
4
|
-
import { type Fields } from 'types/
|
|
5
|
-
import { type StringFieldsOfFields } from 'types/
|
|
3
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
4
|
+
import { type Fields } from 'types/Field';
|
|
5
|
+
import { type StringFieldsOfFields } from 'types/StringFieldsOfFields';
|
|
6
6
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
7
7
|
export type SuppliedRadioGroupProps = Pick<RadioGroupProps, 'name' | 'value' | 'required' | 'error' | 'onChange' | 'onFocus' | 'onBlur' | 'onKeyUp'>;
|
|
8
8
|
export declare function createRadioGroup<F extends Fields, K extends keyof StringFieldsOfFields<F>, Props extends SuppliedRadioGroupProps>(this: MantineForm<F>, valuePath: K, RadioGroup: ComponentType<Props>): MantineFieldComponent<SuppliedRadioGroupProps, Props, ErrorOfField<F[K]>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { createUnsafePartialObserverComponent, } from 'util/
|
|
3
|
-
import { DefaultErrorRenderer, } from './
|
|
2
|
+
import { createUnsafePartialObserverComponent, } from 'util/Partial';
|
|
3
|
+
import { DefaultErrorRenderer, } from './ErrorRenderer';
|
|
4
4
|
export function createRadioGroup(valuePath, RadioGroup) {
|
|
5
5
|
const onChange = (value) => {
|
|
6
6
|
var _a;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type ErrorOfField } from 'types/
|
|
2
|
-
import { type Fields } from 'types/
|
|
3
|
-
import { type StringFieldsOfFields } from 'types/
|
|
1
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
2
|
+
import { type Fields } from 'types/Field';
|
|
3
|
+
import { type StringFieldsOfFields } from 'types/StringFieldsOfFields';
|
|
4
4
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
5
5
|
export type TextInputTarget = Element & {
|
|
6
6
|
value: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { createUnsafePartialObserverComponent } from 'util/
|
|
3
|
-
import { DefaultErrorRenderer, } from './
|
|
2
|
+
import { createUnsafePartialObserverComponent } from 'util/Partial';
|
|
3
|
+
import { DefaultErrorRenderer, } from './ErrorRenderer';
|
|
4
4
|
export function createTextInput(valuePath, TextInput) {
|
|
5
5
|
const onChange = (e) => {
|
|
6
6
|
var _a;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { type AllFieldsOfFields } from 'types/
|
|
2
|
-
import { type ErrorOfField } from 'types/
|
|
3
|
-
import { type Fields } from 'types/
|
|
4
|
-
import { type ValueTypeOfField } from 'types/
|
|
1
|
+
import { type AllFieldsOfFields } from 'types/AllFieldsOfFields';
|
|
2
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
3
|
+
import { type Fields } from 'types/Field';
|
|
4
|
+
import { type ValueTypeOfField } from 'types/ValueTypeOfField';
|
|
5
5
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
6
6
|
export type SuppliedValueInputProps<V, T extends Element = Element> = Partial<{
|
|
7
7
|
name: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { createUnsafePartialObserverComponent } from 'util/
|
|
3
|
-
import { DefaultErrorRenderer, } from './
|
|
2
|
+
import { createUnsafePartialObserverComponent } from 'util/Partial';
|
|
3
|
+
import { DefaultErrorRenderer, } from './ErrorRenderer';
|
|
4
4
|
export function createValueInput(valuePath, ValueInput) {
|
|
5
5
|
const onChange = (value) => {
|
|
6
6
|
var _a;
|
package/.out/mantine/hooks.d.ts
CHANGED
|
@@ -2,24 +2,24 @@ import { type CheckboxProps, type PillProps, type RadioGroupProps, type RadioPro
|
|
|
2
2
|
import { type ElementOfArray } from '@strictly/base';
|
|
3
3
|
import { type FieldsViewProps, type FormProps } from 'core/props';
|
|
4
4
|
import { type ComponentProps, type ComponentType } from 'react';
|
|
5
|
-
import { type AllFieldsOfFields } from 'types/
|
|
6
|
-
import { type BooleanFieldsOfFields } from 'types/
|
|
7
|
-
import { type ErrorOfField } from 'types/
|
|
8
|
-
import { type Fields } from 'types/
|
|
9
|
-
import { type ListFieldsOfFields } from 'types/
|
|
10
|
-
import { type StringFieldsOfFields } from 'types/
|
|
11
|
-
import { type SubFormFields } from 'types/
|
|
12
|
-
import { type ValueTypeOfField } from 'types/
|
|
13
|
-
import { type RefOfProps } from 'util/
|
|
14
|
-
import { type SuppliedCheckboxProps } from './
|
|
15
|
-
import { type
|
|
16
|
-
import { type
|
|
17
|
-
import { DefaultList, type SuppliedListProps } from './
|
|
18
|
-
import { type SuppliedPillProps } from './
|
|
19
|
-
import { type SuppliedRadioProps } from './
|
|
20
|
-
import { type SuppliedRadioGroupProps } from './
|
|
21
|
-
import { type SuppliedTextInputProps } from './
|
|
22
|
-
import { type SuppliedValueInputProps } from './
|
|
5
|
+
import { type AllFieldsOfFields } from 'types/AllFieldsOfFields';
|
|
6
|
+
import { type BooleanFieldsOfFields } from 'types/BooleanFieldsOfFields';
|
|
7
|
+
import { type ErrorOfField } from 'types/ErrorOfField';
|
|
8
|
+
import { type Fields } from 'types/Field';
|
|
9
|
+
import { type ListFieldsOfFields } from 'types/ListFieldsOfFields';
|
|
10
|
+
import { type StringFieldsOfFields } from 'types/StringFieldsOfFields';
|
|
11
|
+
import { type SubFormFields } from 'types/SubFormFields';
|
|
12
|
+
import { type ValueTypeOfField } from 'types/ValueTypeOfField';
|
|
13
|
+
import { type RefOfProps } from 'util/Partial';
|
|
14
|
+
import { type SuppliedCheckboxProps } from './createCheckbox';
|
|
15
|
+
import { type FieldsView } from './createFieldsView';
|
|
16
|
+
import { type FieldViewProps } from './createFieldView';
|
|
17
|
+
import { DefaultList, type SuppliedListProps } from './createList';
|
|
18
|
+
import { type SuppliedPillProps } from './createPill';
|
|
19
|
+
import { type SuppliedRadioProps } from './createRadio';
|
|
20
|
+
import { type SuppliedRadioGroupProps } from './createRadioGroup';
|
|
21
|
+
import { type SuppliedTextInputProps } from './createTextInput';
|
|
22
|
+
import { type SuppliedValueInputProps } from './createValueInput';
|
|
23
23
|
import { type MantineFieldComponent, type MantineForm } from './types';
|
|
24
24
|
declare function SimpleSelect(props: SelectProps & {
|
|
25
25
|
onChange?: (value: string | null) => void;
|
package/.out/mantine/hooks.js
CHANGED
|
@@ -48,16 +48,16 @@ import { Checkbox as CheckboxImpl, Pill as PillImpl, Radio as RadioImpl, Select,
|
|
|
48
48
|
import { Cache, } from '@strictly/base';
|
|
49
49
|
import { observable, runInAction, } from 'mobx';
|
|
50
50
|
import { useEffect, useMemo, } from 'react';
|
|
51
|
-
import { createCheckbox, } from './
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
import { createForm } from './
|
|
55
|
-
import { createList, DefaultList, } from './
|
|
56
|
-
import { createPill, } from './
|
|
57
|
-
import { createRadio, } from './
|
|
58
|
-
import { createRadioGroup, } from './
|
|
59
|
-
import { createTextInput, } from './
|
|
60
|
-
import { createValueInput, } from './
|
|
51
|
+
import { createCheckbox, } from './createCheckbox';
|
|
52
|
+
import { createFieldsView, } from './createFieldsView';
|
|
53
|
+
import { createFieldView, } from './createFieldView';
|
|
54
|
+
import { createForm } from './createForm';
|
|
55
|
+
import { createList, DefaultList, } from './createList';
|
|
56
|
+
import { createPill, } from './createPill';
|
|
57
|
+
import { createRadio, } from './createRadio';
|
|
58
|
+
import { createRadioGroup, } from './createRadioGroup';
|
|
59
|
+
import { createTextInput, } from './createTextInput';
|
|
60
|
+
import { createValueInput, } from './createValueInput';
|
|
61
61
|
function SimpleSelect(props) {
|
|
62
62
|
return _jsx(Select, Object.assign({}, props));
|
|
63
63
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type Meta, type StoryObj } from '@storybook/react';
|
|
2
2
|
import { type FieldsViewProps } from 'core/props';
|
|
3
3
|
import { type Ref } from 'react';
|
|
4
|
-
import { type Field } from 'types/
|
|
4
|
+
import { type Field } from 'types/Field';
|
|
5
5
|
declare function Component({ componentRef, ...props }: FieldsViewProps<{
|
|
6
6
|
$: Field<boolean, string>;
|
|
7
7
|
}> & {
|
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import { action } from '@storybook/addon-actions';
|
|
14
14
|
import { useMantineFormFields } from 'mantine/hooks';
|
|
15
|
-
import { CHECKBOX_LABEL } from './
|
|
15
|
+
import { CHECKBOX_LABEL } from './checkboxConstants';
|
|
16
16
|
function ErrorRenderer({ error }) {
|
|
17
17
|
return `Error ${error}`;
|
|
18
18
|
}
|
|
@@ -12,8 +12,8 @@ import { composeStories } from '@storybook/react';
|
|
|
12
12
|
import { toArray } from '@strictly/base';
|
|
13
13
|
import { fireEvent, render, } from '@testing-library/react';
|
|
14
14
|
import { vi, } from 'vitest';
|
|
15
|
-
import { CHECKBOX_LABEL } from './
|
|
16
|
-
import * as stories from './
|
|
15
|
+
import { CHECKBOX_LABEL } from './checkboxConstants';
|
|
16
|
+
import * as stories from './checkboxHooks.stories';
|
|
17
17
|
const composedStories = composeStories(stories);
|
|
18
18
|
const { Off, On, } = composedStories;
|
|
19
19
|
describe('mantine checkbox hooks', function () {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type Meta, type StoryObj } from '@storybook/react';
|
|
2
2
|
import { type FieldsViewProps } from 'core/props';
|
|
3
|
-
import { type Field } from 'types/
|
|
3
|
+
import { type Field } from 'types/Field';
|
|
4
4
|
declare function Component(props: FieldsViewProps<{
|
|
5
5
|
$: Field<string, string>;
|
|
6
6
|
}>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { composeStories } from '@storybook/react';
|
|
3
3
|
import { toArray } from '@strictly/base';
|
|
4
4
|
import { render, } from '@testing-library/react';
|
|
5
|
-
import * as stories from './
|
|
5
|
+
import * as stories from './fieldViewHooks.stories';
|
|
6
6
|
const composedStories = composeStories(stories);
|
|
7
7
|
describe('field view hooks', function () {
|
|
8
8
|
it.each(toArray(composedStories))('renders %s', function (_name, Story) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type Meta, type StoryObj } from '@storybook/react';
|
|
2
2
|
import { type FieldsViewProps } from 'core/props';
|
|
3
|
-
import { type Field } from 'types/
|
|
3
|
+
import { type Field } from 'types/Field';
|
|
4
4
|
export declare function ParentFieldLabel(): string;
|
|
5
5
|
export declare function SubFieldLabel(): string;
|
|
6
6
|
declare function Component({ onClickField: onClickFieldImpl, ...props }: FieldsViewProps<{
|
|
@@ -11,7 +11,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
11
11
|
import { composeStories } from '@storybook/react';
|
|
12
12
|
import { toArray } from '@strictly/base';
|
|
13
13
|
import { fireEvent, render, } from '@testing-library/react';
|
|
14
|
-
import * as stories from './
|
|
14
|
+
import * as stories from './fieldsViewHooks.stories';
|
|
15
15
|
const composedStories = composeStories(stories);
|
|
16
16
|
const { Empty, } = composedStories;
|
|
17
17
|
describe('field view hooks', function () {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type Meta, type StoryObj } from '@storybook/react';
|
|
2
2
|
import { type FieldsViewProps } from 'core/props';
|
|
3
|
-
import { type Field } from 'types/
|
|
3
|
+
import { type Field } from 'types/Field';
|
|
4
4
|
declare function Component(props: FieldsViewProps<{
|
|
5
5
|
$: Field<string, string>;
|
|
6
6
|
'$.a': Field<number, string>;
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { composeStories } from '@storybook/react';
|
|
3
3
|
import { toArray } from '@strictly/base';
|
|
4
4
|
import { render, } from '@testing-library/react';
|
|
5
|
-
import * as stories from './
|
|
5
|
+
import * as stories from './formHooks.stories';
|
|
6
6
|
const composedStories = composeStories(stories);
|
|
7
7
|
describe('form hooks', function () {
|
|
8
8
|
it.each(toArray(composedStories))('renders %s', function (_name, Story) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type Meta, type StoryObj } from '@storybook/react';
|
|
2
2
|
import { type FieldsViewProps } from 'core/props';
|
|
3
|
-
import { type Field } from 'types/
|
|
3
|
+
import { type Field } from 'types/Field';
|
|
4
4
|
declare function Component(props: FieldsViewProps<{
|
|
5
5
|
$: Field<string[], string>;
|
|
6
6
|
}>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { composeStories } from '@storybook/react';
|
|
3
3
|
import { toArray } from '@strictly/base';
|
|
4
4
|
import { render, } from '@testing-library/react';
|
|
5
|
-
import * as stories from './
|
|
5
|
+
import * as stories from './listHooks.stories';
|
|
6
6
|
const composedStories = composeStories(stories);
|
|
7
7
|
describe('mantine list hooks', function () {
|
|
8
8
|
it.each(toArray(composedStories))('renders %s', function (_name, Story) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type Meta, type StoryObj } from '@storybook/react';
|
|
2
2
|
import { type FieldsViewProps } from 'core/props';
|
|
3
|
-
import { type Field } from 'types/
|
|
4
|
-
import { type RadioValue } from './
|
|
3
|
+
import { type Field } from 'types/Field';
|
|
4
|
+
import { type RadioValue } from './radioGroupConstants';
|
|
5
5
|
declare function Component({ ...props }: FieldsViewProps<{
|
|
6
6
|
$: Field<RadioValue | null, string>;
|
|
7
7
|
}>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -13,7 +13,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
13
13
|
import { Stack, } from '@mantine/core';
|
|
14
14
|
import { action } from '@storybook/addon-actions';
|
|
15
15
|
import { useMantineFormFields } from 'mantine/hooks';
|
|
16
|
-
import { RADIO_GROUP_LABEL, RADIO_LABELS, RADIO_VALUES, } from './
|
|
16
|
+
import { RADIO_GROUP_LABEL, RADIO_LABELS, RADIO_VALUES, } from './radioGroupConstants';
|
|
17
17
|
function ErrorRenderer({ error }) {
|
|
18
18
|
return `custom error ${error}`;
|
|
19
19
|
}
|