@app-studio/web 0.1.0
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/LICENSE +448 -0
- package/README.md +50 -0
- package/dist/App.d.ts +3 -0
- package/dist/components/Button/Button/Button.props.d.ts +77 -0
- package/dist/components/Button/Button/Button.state.d.ts +5 -0
- package/dist/components/Button/Button/Button.style.d.ts +5 -0
- package/dist/components/Button/Button/Button.view.d.ts +4 -0
- package/dist/components/Button/Button.d.ts +6 -0
- package/dist/components/Button/examples/AutoFocusButton.d.ts +2 -0
- package/dist/components/Button/examples/BorderedButtons.d.ts +2 -0
- package/dist/components/Button/examples/ColoredButtons.d.ts +2 -0
- package/dist/components/Button/examples/DefaultButton.d.ts +2 -0
- package/dist/components/Button/examples/DisabledButton.d.ts +2 -0
- package/dist/components/Button/examples/IconButtons.d.ts +2 -0
- package/dist/components/Button/examples/LoadingButtons.d.ts +2 -0
- package/dist/components/Button/examples/ShadowButton.d.ts +2 -0
- package/dist/components/Button/examples/SizeButtons.d.ts +2 -0
- package/dist/components/Button/examples/VariantButtons.d.ts +2 -0
- package/dist/components/Button/examples/index.d.ts +9 -0
- package/dist/components/Form/Checkbox/Checkbox/Checkbox.props.d.ts +97 -0
- package/dist/components/Form/Checkbox/Checkbox/Checkbox.state.d.ts +8 -0
- package/dist/components/Form/Checkbox/Checkbox/Checkbox.style.d.ts +4 -0
- package/dist/components/Form/Checkbox/Checkbox/Checkbox.view.d.ts +4 -0
- package/dist/components/Form/Checkbox/Checkbox.d.ts +6 -0
- package/dist/components/Form/Checkbox/examples/ColorScheme.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/Default.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/DisabledInput.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/ErrorCheckbox.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/FormCheckout.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/IconCheckbox.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/IndeterminateCheckbox.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/Shadow.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/Checkbox/examples/index.d.ts +11 -0
- package/dist/components/Form/CountryPicker/CountryPicker/CountryPicker.props.d.ts +173 -0
- package/dist/components/Form/CountryPicker/CountryPicker/CountryPicker.state.d.ts +15 -0
- package/dist/components/Form/CountryPicker/CountryPicker/CountryPicker.style.d.ts +3 -0
- package/dist/components/Form/CountryPicker/CountryPicker/CountryPicker.view.d.ts +6 -0
- package/dist/components/Form/CountryPicker/CountryPicker.d.ts +6 -0
- package/dist/components/Form/CountryPicker/examples/Color.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Default.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Disabled.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Error.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Form.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Formik.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/HelperText.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Shadow.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Shape.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/Variant.d.ts +2 -0
- package/dist/components/Form/CountryPicker/examples/index.d.ts +12 -0
- package/dist/components/Form/DatePicker/DatePicker/DatePicker.props.d.ts +103 -0
- package/dist/components/Form/DatePicker/DatePicker/DatePicker.state.d.ts +9 -0
- package/dist/components/Form/DatePicker/DatePicker/DatePicker.style.d.ts +3 -0
- package/dist/components/Form/DatePicker/DatePicker/DatePicker.view.d.ts +4 -0
- package/dist/components/Form/DatePicker/DatePicker.d.ts +6 -0
- package/dist/components/Form/DatePicker/examples/ColorScheme.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/Default.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/DisabledInput.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/ErrorCheckbox.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/FormCheckout.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/Formik.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/Shadow.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/helperTextDatePicker.d.ts +2 -0
- package/dist/components/Form/DatePicker/examples/index.d.ts +11 -0
- package/dist/components/Form/Label/Label/Label.props.d.ts +36 -0
- package/dist/components/Form/Label/Label/Label.style.d.ts +2 -0
- package/dist/components/Form/Label/Label/Label.type.d.ts +3 -0
- package/dist/components/Form/Label/Label/Label.view.d.ts +4 -0
- package/dist/components/Form/Label/Label.d.ts +3 -0
- package/dist/components/Form/Password/Password/Password.props.d.ts +34 -0
- package/dist/components/Form/Password/Password/Password.state.d.ts +5 -0
- package/dist/components/Form/Password/Password/Password.view.d.ts +4 -0
- package/dist/components/Form/Password/Password.d.ts +6 -0
- package/dist/components/Form/Password/example/Default.d.ts +2 -0
- package/dist/components/Form/Password/example/DisabledInput.d.ts +2 -0
- package/dist/components/Form/Password/example/ErrorInput.d.ts +2 -0
- package/dist/components/Form/Password/example/FormikErrorInput.d.ts +2 -0
- package/dist/components/Form/Password/example/FormikHelperText.d.ts +2 -0
- package/dist/components/Form/Password/example/HelperText.d.ts +2 -0
- package/dist/components/Form/Select/Select/Select.props.d.ts +234 -0
- package/dist/components/Form/Select/Select/Select.state.d.ts +16 -0
- package/dist/components/Form/Select/Select/Select.style.d.ts +4 -0
- package/dist/components/Form/Select/Select/Select.view.d.ts +5 -0
- package/dist/components/Form/Select/Select.d.ts +6 -0
- package/dist/components/Form/Select/examples/Color.d.ts +2 -0
- package/dist/components/Form/Select/examples/Default.d.ts +2 -0
- package/dist/components/Form/Select/examples/Disabled.d.ts +2 -0
- package/dist/components/Form/Select/examples/Error.d.ts +2 -0
- package/dist/components/Form/Select/examples/Form.d.ts +2 -0
- package/dist/components/Form/Select/examples/Formik.d.ts +2 -0
- package/dist/components/Form/Select/examples/HelperText.d.ts +2 -0
- package/dist/components/Form/Select/examples/Multiple.d.ts +2 -0
- package/dist/components/Form/Select/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/Select/examples/Shadow.d.ts +2 -0
- package/dist/components/Form/Select/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/Select/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/Switch/Switch/Switch.props.d.ts +72 -0
- package/dist/components/Form/Switch/Switch/Switch.state.d.ts +8 -0
- package/dist/components/Form/Switch/Switch/Switch.style.d.ts +5 -0
- package/dist/components/Form/Switch/Switch/Switch.view.d.ts +4 -0
- package/dist/components/Form/Switch/Switch.d.ts +3 -0
- package/dist/components/Form/Switch/examples/ChildSwitch.d.ts +2 -0
- package/dist/components/Form/Switch/examples/ColorScheme.d.ts +2 -0
- package/dist/components/Form/Switch/examples/Default.d.ts +2 -0
- package/dist/components/Form/Switch/examples/DisabledInput.d.ts +2 -0
- package/dist/components/Form/Switch/examples/FormSwitch.d.ts +2 -0
- package/dist/components/Form/Switch/examples/Formik.d.ts +2 -0
- package/dist/components/Form/Switch/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/Switch/examples/Shadow.d.ts +2 -0
- package/dist/components/Form/Switch/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/Switch/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/TextArea/TextArea/TextArea.props.d.ts +144 -0
- package/dist/components/Form/TextArea/TextArea/TextArea.state.d.ts +12 -0
- package/dist/components/Form/TextArea/TextArea/TextArea.type.d.ts +11 -0
- package/dist/components/Form/TextArea/TextArea/TextArea.view.d.ts +4 -0
- package/dist/components/Form/TextArea/TextArea.d.ts +6 -0
- package/dist/components/Form/TextArea/examples/ColorScheme.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/Default.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/DisabledInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/ErrorInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/FormikErrorInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/FormikHelperText.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/HelperText.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/LabelInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/MaxRowCol.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/Placeholder.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/ShadowArea.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/ShapeInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/VariantsInputs.d.ts +2 -0
- package/dist/components/Form/TextArea/examples/index.d.ts +15 -0
- package/dist/components/Form/TextField/TextField/TextField.props.d.ts +124 -0
- package/dist/components/Form/TextField/TextField/TextField.state.d.ts +12 -0
- package/dist/components/Form/TextField/TextField/TextField.view.d.ts +4 -0
- package/dist/components/Form/TextField/TextField.d.ts +6 -0
- package/dist/components/Form/TextField/examples/ClearInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/ColorScheme.d.ts +2 -0
- package/dist/components/Form/TextField/examples/Default.d.ts +2 -0
- package/dist/components/Form/TextField/examples/DisabledInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/ErrorInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/FormikErrorInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/FormikHelperText.d.ts +2 -0
- package/dist/components/Form/TextField/examples/HelperText.d.ts +2 -0
- package/dist/components/Form/TextField/examples/LabelInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/LeftChild.d.ts +2 -0
- package/dist/components/Form/TextField/examples/Placeholder.d.ts +2 -0
- package/dist/components/Form/TextField/examples/ReadOnlyInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/RightChild.d.ts +2 -0
- package/dist/components/Form/TextField/examples/ShapeInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/SizeInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/StylesInput.d.ts +2 -0
- package/dist/components/Form/TextField/examples/VariantsInputs.d.ts +2 -0
- package/dist/components/Form/TextField/examples/index.d.ts +17 -0
- package/dist/components/Layout/Center/Center/Center.props.d.ts +16 -0
- package/dist/components/Layout/Center/Center/Center.view.d.ts +4 -0
- package/dist/components/Layout/Center/Center.d.ts +3 -0
- package/dist/components/Layout/Horizontal/Horizontal/Horizontal.props.d.ts +24 -0
- package/dist/components/Layout/Horizontal/Horizontal/Horizontal.view.d.ts +4 -0
- package/dist/components/Layout/Horizontal/Horizontal.d.ts +3 -0
- package/dist/components/Layout/Horizontal/examples/Default.d.ts +2 -0
- package/dist/components/Layout/Horizontal/examples/Justify.d.ts +2 -0
- package/dist/components/Layout/Horizontal/examples/Reversed.d.ts +2 -0
- package/dist/components/Layout/Horizontal/examples/Wrap.d.ts +2 -0
- package/dist/components/Layout/Horizontal/examples/index.d.ts +4 -0
- package/dist/components/Layout/Input/FieldContainer/FieldContainer/FieldContainer.props.d.ts +24 -0
- package/dist/components/Layout/Input/FieldContainer/FieldContainer.d.ts +3 -0
- package/dist/components/Layout/Input/FieldContent/FieldContent/FieldContent.props.d.ts +74 -0
- package/dist/components/Layout/Input/FieldContent/FieldContent.d.ts +3 -0
- package/dist/components/Layout/Input/FieldIcons/FieldIcons/FieldIcons.props.d.ts +11 -0
- package/dist/components/Layout/Input/FieldIcons/FieldIcons.d.ts +3 -0
- package/dist/components/Layout/Input/FieldLabel/FieldLabel/FieldLabel.props.d.ts +30 -0
- package/dist/components/Layout/Input/FieldLabel/FieldLabel.d.ts +3 -0
- package/dist/components/Layout/Input/FieldLayout/FieldLayout/FieldLayout.props.d.ts +28 -0
- package/dist/components/Layout/Input/FieldLayout/FieldLayout.d.ts +3 -0
- package/dist/components/Layout/Input/FieldWrapper/FieldWrapper.d.ts +3 -0
- package/dist/components/Layout/Input/FieldWrapper/FieldWrapper.props.d.ts +11 -0
- package/dist/components/Layout/Input/HelperText/HelperText.d.ts +3 -0
- package/dist/components/Layout/Input/HelperText/HelperText.props.d.ts +20 -0
- package/dist/components/Layout/Input/index.d.ts +7 -0
- package/dist/components/Layout/Vertical/Vertical/Vertical.props.d.ts +24 -0
- package/dist/components/Layout/Vertical/Vertical/Vertical.type.d.ts +2 -0
- package/dist/components/Layout/Vertical/Vertical/Vertical.view.d.ts +4 -0
- package/dist/components/Layout/Vertical/Vertical.d.ts +3 -0
- package/dist/components/Layout/Vertical/examples/Default.d.ts +2 -0
- package/dist/components/Layout/Vertical/examples/Justify.d.ts +2 -0
- package/dist/components/Layout/Vertical/examples/Reversed.d.ts +2 -0
- package/dist/components/Layout/Vertical/examples/Wrap.d.ts +2 -0
- package/dist/components/Layout/Vertical/examples/index.d.ts +5 -0
- package/dist/components/Layout/View/View.d.ts +2 -0
- package/dist/components/Layout/configs/Input.style.d.ts +16 -0
- package/dist/components/Layout/configs/Input.type.d.ts +12 -0
- package/dist/components/Link/Link/Link.props.d.ts +47 -0
- package/dist/components/Link/Link/Link.state.d.ts +5 -0
- package/dist/components/Link/Link/Link.style.d.ts +2 -0
- package/dist/components/Link/Link/Link.view.d.ts +4 -0
- package/dist/components/Link/Link.d.ts +6 -0
- package/dist/components/Link/examples/Default.d.ts +2 -0
- package/dist/components/Link/examples/IsExternal.d.ts +2 -0
- package/dist/components/Link/examples/Underline.d.ts +2 -0
- package/dist/components/Loader/Loader/Loader.props.d.ts +93 -0
- package/dist/components/Loader/Loader/Loader.style.d.ts +4 -0
- package/dist/components/Loader/Loader/Loader.view.d.ts +4 -0
- package/dist/components/Loader/Loader.d.ts +6 -0
- package/dist/components/Loader/examples/ColorLoader.d.ts +2 -0
- package/dist/components/Loader/examples/DefaultLoader.d.ts +2 -0
- package/dist/components/Loader/examples/PositionLoader.d.ts +2 -0
- package/dist/components/Loader/examples/SizeLoader.d.ts +2 -0
- package/dist/components/Loader/examples/SpeedLoader.d.ts +2 -0
- package/dist/components/Loader/examples/TextLoader.d.ts +2 -0
- package/dist/components/Loader/examples/VariantLoader.d.ts +2 -0
- package/dist/components/Loader/examples/index.d.ts +7 -0
- package/dist/components/Modal/Examples/BlurModal.d.ts +2 -0
- package/dist/components/Modal/Examples/CloseButtonModal.d.ts +2 -0
- package/dist/components/Modal/Examples/DefaultModal.d.ts +2 -0
- package/dist/components/Modal/Examples/FullScreenModal.d.ts +2 -0
- package/dist/components/Modal/Examples/ModalPosition.d.ts +2 -0
- package/dist/components/Modal/Examples/PreventCloseModal.d.ts +2 -0
- package/dist/components/Modal/Examples/ScrollModal.d.ts +2 -0
- package/dist/components/Modal/Examples/ShadowModal.d.ts +2 -0
- package/dist/components/Modal/Examples/VariantModal.d.ts +2 -0
- package/dist/components/Modal/Examples/index.d.ts +9 -0
- package/dist/components/Modal/Modal/Modal.props.d.ts +178 -0
- package/dist/components/Modal/Modal/Modal.style.d.ts +5 -0
- package/dist/components/Modal/Modal/Modal.view.d.ts +7 -0
- package/dist/components/Modal/Modal.d.ts +6 -0
- package/dist/components/Svg/ArrowDown.d.ts +8 -0
- package/dist/components/Svg/ArrowUp.d.ts +8 -0
- package/dist/components/Svg/Check.d.ts +8 -0
- package/dist/components/Svg/Close.d.ts +8 -0
- package/dist/components/Svg/CloseEye.d.ts +8 -0
- package/dist/components/Svg/DustBin.d.ts +7 -0
- package/dist/components/Svg/Edit.d.ts +8 -0
- package/dist/components/Svg/ExternalLink.d.ts +8 -0
- package/dist/components/Svg/Indeterminate.d.ts +8 -0
- package/dist/components/Svg/OpenEye.d.ts +8 -0
- package/dist/components/Svg/Profile.d.ts +8 -0
- package/dist/components/Svg/RightArrow.d.ts +8 -0
- package/dist/components/Svg/index.d.ts +12 -0
- package/dist/components/Text/Text/Text.props.d.ts +77 -0
- package/dist/components/Text/Text/Text.style.d.ts +2 -0
- package/dist/components/Text/Text/Text.view.d.ts +4 -0
- package/dist/components/Text/Text.d.ts +6 -0
- package/dist/components/Wrapper.d.ts +6 -0
- package/dist/components/index.d.ts +18 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +8 -0
- package/dist/web.cjs.development.js +27 -0
- package/dist/web.cjs.development.js.map +1 -0
- package/dist/web.cjs.production.min.js +2 -0
- package/dist/web.cjs.production.min.js.map +1 -0
- package/dist/web.esm.js +23 -0
- package/dist/web.esm.js.map +1 -0
- package/package.json +153 -0
- package/src/components/Button/Button/Button.props.ts +79 -0
- package/src/components/Button/Button/Button.state.ts +7 -0
- package/src/components/Button/Button/Button.style.ts +95 -0
- package/src/components/Button/Button/Button.type.d.ts +11 -0
- package/src/components/Button/Button/Button.view.tsx +116 -0
- package/src/components/Button/Button.md +165 -0
- package/src/components/Button/Button.tsx +24 -0
- package/src/components/Button/examples/AutoFocusButton.tsx +13 -0
- package/src/components/Button/examples/BorderedButtons.tsx +14 -0
- package/src/components/Button/examples/ColoredButtons.tsx +12 -0
- package/src/components/Button/examples/DefaultButton.tsx +4 -0
- package/src/components/Button/examples/DisabledButton.tsx +13 -0
- package/src/components/Button/examples/IconButtons.tsx +23 -0
- package/src/components/Button/examples/LoadingButtons.tsx +28 -0
- package/src/components/Button/examples/ShadowButton.tsx +6 -0
- package/src/components/Button/examples/SizeButtons.tsx +16 -0
- package/src/components/Button/examples/VariantButtons.tsx +20 -0
- package/src/components/Button/examples/index.ts +9 -0
- package/src/components/Form/Checkbox/Checkbox/Checkbox.props.ts +118 -0
- package/src/components/Form/Checkbox/Checkbox/Checkbox.state.ts +15 -0
- package/src/components/Form/Checkbox/Checkbox/Checkbox.style.ts +29 -0
- package/src/components/Form/Checkbox/Checkbox/Checkbox.type.d.ts +8 -0
- package/src/components/Form/Checkbox/Checkbox/Checkbox.view.tsx +98 -0
- package/src/components/Form/Checkbox/Checkbox.md +128 -0
- package/src/components/Form/Checkbox/Checkbox.tsx +15 -0
- package/src/components/Form/Checkbox/examples/ColorScheme.tsx +12 -0
- package/src/components/Form/Checkbox/examples/Default.tsx +5 -0
- package/src/components/Form/Checkbox/examples/DisabledInput.tsx +5 -0
- package/src/components/Form/Checkbox/examples/ErrorCheckbox.tsx +5 -0
- package/src/components/Form/Checkbox/examples/FormCheckout.tsx +46 -0
- package/src/components/Form/Checkbox/examples/IconCheckbox.tsx +8 -0
- package/src/components/Form/Checkbox/examples/IndeterminateCheckbox.tsx +5 -0
- package/src/components/Form/Checkbox/examples/ReadOnlyInput.tsx +5 -0
- package/src/components/Form/Checkbox/examples/Shadow.tsx +11 -0
- package/src/components/Form/Checkbox/examples/SizeInput.tsx +18 -0
- package/src/components/Form/Checkbox/examples/StylesInput.tsx +22 -0
- package/src/components/Form/Checkbox/examples/index.ts +11 -0
- package/src/components/Form/CountryPicker/CountryPicker/CountryPicker.props.ts +187 -0
- package/src/components/Form/CountryPicker/CountryPicker/CountryPicker.state.ts +28 -0
- package/src/components/Form/CountryPicker/CountryPicker/CountryPicker.style.ts +17 -0
- package/src/components/Form/CountryPicker/CountryPicker/CountryPicker.type.d.ts +22 -0
- package/src/components/Form/CountryPicker/CountryPicker/CountryPicker.view.tsx +234 -0
- package/src/components/Form/CountryPicker/CountryPicker.md +206 -0
- package/src/components/Form/CountryPicker/CountryPicker.tsx +16 -0
- package/src/components/Form/CountryPicker/countries.json +1453 -0
- package/src/components/Form/CountryPicker/examples/Color.tsx +12 -0
- package/src/components/Form/CountryPicker/examples/Default.tsx +4 -0
- package/src/components/Form/CountryPicker/examples/Disabled.tsx +5 -0
- package/src/components/Form/CountryPicker/examples/Error.tsx +4 -0
- package/src/components/Form/CountryPicker/examples/Form.tsx +23 -0
- package/src/components/Form/CountryPicker/examples/Formik.tsx +39 -0
- package/src/components/Form/CountryPicker/examples/HelperText.tsx +5 -0
- package/src/components/Form/CountryPicker/examples/ReadOnlyInput.tsx +5 -0
- package/src/components/Form/CountryPicker/examples/Shadow.tsx +4 -0
- package/src/components/Form/CountryPicker/examples/Shape.tsx +13 -0
- package/src/components/Form/CountryPicker/examples/SizeInput.tsx +16 -0
- package/src/components/Form/CountryPicker/examples/StylesInput.tsx +19 -0
- package/src/components/Form/CountryPicker/examples/Variant.tsx +13 -0
- package/src/components/Form/CountryPicker/examples/index.ts +12 -0
- package/src/components/Form/CountryPicker/styles.css +7 -0
- package/src/components/Form/DatePicker/DatePicker/DatePicker.props.ts +113 -0
- package/src/components/Form/DatePicker/DatePicker/DatePicker.state.ts +17 -0
- package/src/components/Form/DatePicker/DatePicker/DatePicker.style.ts +17 -0
- package/src/components/Form/DatePicker/DatePicker/DatePicker.type.d.ts +15 -0
- package/src/components/Form/DatePicker/DatePicker/DatePicker.view.tsx +118 -0
- package/src/components/Form/DatePicker/DatePicker.md +115 -0
- package/src/components/Form/DatePicker/DatePicker.tsx +15 -0
- package/src/components/Form/DatePicker/examples/ColorScheme.tsx +12 -0
- package/src/components/Form/DatePicker/examples/Default.tsx +4 -0
- package/src/components/Form/DatePicker/examples/DisabledInput.tsx +5 -0
- package/src/components/Form/DatePicker/examples/ErrorCheckbox.tsx +4 -0
- package/src/components/Form/DatePicker/examples/FormCheckout.tsx +23 -0
- package/src/components/Form/DatePicker/examples/Formik.tsx +35 -0
- package/src/components/Form/DatePicker/examples/ReadOnlyInput.tsx +5 -0
- package/src/components/Form/DatePicker/examples/Shadow.tsx +10 -0
- package/src/components/Form/DatePicker/examples/SizeInput.tsx +16 -0
- package/src/components/Form/DatePicker/examples/StylesInput.tsx +14 -0
- package/src/components/Form/DatePicker/examples/helperTextDatePicker.tsx +6 -0
- package/src/components/Form/DatePicker/examples/index.ts +11 -0
- package/src/components/Form/Label/Label/Label.props.ts +36 -0
- package/src/components/Form/Label/Label/Label.style.ts +35 -0
- package/src/components/Form/Label/Label/Label.type.ts +14 -0
- package/src/components/Form/Label/Label/Label.view.tsx +35 -0
- package/src/components/Form/Label/Label.tsx +8 -0
- package/src/components/Form/Password/Password/Password.props.ts +36 -0
- package/src/components/Form/Password/Password/Password.state.ts +6 -0
- package/src/components/Form/Password/Password/Password.type.d.ts +14 -0
- package/src/components/Form/Password/Password/Password.view.tsx +32 -0
- package/src/components/Form/Password/Password.md +108 -0
- package/src/components/Form/Password/Password.tsx +15 -0
- package/src/components/Form/Password/example/Default.tsx +9 -0
- package/src/components/Form/Password/example/DisabledInput.tsx +17 -0
- package/src/components/Form/Password/example/ErrorInput.tsx +66 -0
- package/src/components/Form/Password/example/FormikErrorInput.tsx +61 -0
- package/src/components/Form/Password/example/FormikHelperText.tsx +65 -0
- package/src/components/Form/Password/example/HelperText.tsx +65 -0
- package/src/components/Form/Select/Select/Select.props.ts +262 -0
- package/src/components/Form/Select/Select/Select.state.ts +19 -0
- package/src/components/Form/Select/Select/Select.style.ts +19 -0
- package/src/components/Form/Select/Select/Select.type.d.ts +15 -0
- package/src/components/Form/Select/Select/Select.view.tsx +342 -0
- package/src/components/Form/Select/Select.md +165 -0
- package/src/components/Form/Select/Select.tsx +16 -0
- package/src/components/Form/Select/examples/Color.tsx +12 -0
- package/src/components/Form/Select/examples/Default.tsx +4 -0
- package/src/components/Form/Select/examples/Disabled.tsx +5 -0
- package/src/components/Form/Select/examples/Error.tsx +4 -0
- package/src/components/Form/Select/examples/Form.tsx +23 -0
- package/src/components/Form/Select/examples/Formik.tsx +41 -0
- package/src/components/Form/Select/examples/HelperText.tsx +7 -0
- package/src/components/Form/Select/examples/Multiple.tsx +6 -0
- package/src/components/Form/Select/examples/ReadOnlyInput.tsx +5 -0
- package/src/components/Form/Select/examples/Shadow.tsx +11 -0
- package/src/components/Form/Select/examples/SizeInput.tsx +16 -0
- package/src/components/Form/Select/examples/StylesInput.tsx +15 -0
- package/src/components/Form/Switch/Switch/Switch.props.ts +91 -0
- package/src/components/Form/Switch/Switch/Switch.state.ts +11 -0
- package/src/components/Form/Switch/Switch/Switch.style.ts +72 -0
- package/src/components/Form/Switch/Switch/Switch.type.d.ts +6 -0
- package/src/components/Form/Switch/Switch/Switch.view.tsx +78 -0
- package/src/components/Form/Switch/Switch.md +148 -0
- package/src/components/Form/Switch/Switch.tsx +12 -0
- package/src/components/Form/Switch/examples/ChildSwitch.tsx +20 -0
- package/src/components/Form/Switch/examples/ColorScheme.tsx +5 -0
- package/src/components/Form/Switch/examples/Default.tsx +4 -0
- package/src/components/Form/Switch/examples/DisabledInput.tsx +7 -0
- package/src/components/Form/Switch/examples/FormSwitch.tsx +22 -0
- package/src/components/Form/Switch/examples/Formik.tsx +30 -0
- package/src/components/Form/Switch/examples/ReadOnlyInput.tsx +7 -0
- package/src/components/Form/Switch/examples/Shadow.tsx +11 -0
- package/src/components/Form/Switch/examples/SizeInput.tsx +21 -0
- package/src/components/Form/Switch/examples/StylesInput.tsx +34 -0
- package/src/components/Form/TextArea/TextArea/TextArea.props.ts +154 -0
- package/src/components/Form/TextArea/TextArea/TextArea.state.ts +21 -0
- package/src/components/Form/TextArea/TextArea/TextArea.type.ts +15 -0
- package/src/components/Form/TextArea/TextArea/TextArea.view.tsx +143 -0
- package/src/components/Form/TextArea/TextArea.md +169 -0
- package/src/components/Form/TextArea/TextArea.tsx +15 -0
- package/src/components/Form/TextArea/examples/ColorScheme.tsx +13 -0
- package/src/components/Form/TextArea/examples/Default.tsx +5 -0
- package/src/components/Form/TextArea/examples/DisabledInput.tsx +7 -0
- package/src/components/Form/TextArea/examples/ErrorInput.tsx +50 -0
- package/src/components/Form/TextArea/examples/FormikErrorInput.tsx +52 -0
- package/src/components/Form/TextArea/examples/FormikHelperText.tsx +51 -0
- package/src/components/Form/TextArea/examples/HelperText.tsx +49 -0
- package/src/components/Form/TextArea/examples/LabelInput.tsx +23 -0
- package/src/components/Form/TextArea/examples/MaxRowCol.tsx +7 -0
- package/src/components/Form/TextArea/examples/Placeholder.tsx +23 -0
- package/src/components/Form/TextArea/examples/ReadOnlyInput.tsx +7 -0
- package/src/components/Form/TextArea/examples/ShadowArea.tsx +28 -0
- package/src/components/Form/TextArea/examples/ShapeInput.tsx +15 -0
- package/src/components/Form/TextArea/examples/SizeInput.tsx +16 -0
- package/src/components/Form/TextArea/examples/StylesInput.tsx +34 -0
- package/src/components/Form/TextArea/examples/VariantsInputs.tsx +15 -0
- package/src/components/Form/TextArea/examples/index.ts +15 -0
- package/src/components/Form/TextArea/styles.css +7 -0
- package/src/components/Form/TextField/TextField/TextField.props.ts +134 -0
- package/src/components/Form/TextField/TextField/TextField.state.ts +21 -0
- package/src/components/Form/TextField/TextField/TextField.type.d.ts +15 -0
- package/src/components/Form/TextField/TextField/TextField.view.tsx +170 -0
- package/src/components/Form/TextField/TextField.md +193 -0
- package/src/components/Form/TextField/TextField.tsx +14 -0
- package/src/components/Form/TextField/examples/ClearInput.tsx +13 -0
- package/src/components/Form/TextField/examples/ColorScheme.tsx +13 -0
- package/src/components/Form/TextField/examples/Default.tsx +23 -0
- package/src/components/Form/TextField/examples/DisabledInput.tsx +7 -0
- package/src/components/Form/TextField/examples/ErrorInput.tsx +74 -0
- package/src/components/Form/TextField/examples/FormikErrorInput.tsx +76 -0
- package/src/components/Form/TextField/examples/FormikHelperText.tsx +62 -0
- package/src/components/Form/TextField/examples/HelperText.tsx +60 -0
- package/src/components/Form/TextField/examples/LabelInput.tsx +23 -0
- package/src/components/Form/TextField/examples/LeftChild.tsx +8 -0
- package/src/components/Form/TextField/examples/Placeholder.tsx +23 -0
- package/src/components/Form/TextField/examples/ReadOnlyInput.tsx +7 -0
- package/src/components/Form/TextField/examples/RightChild.tsx +8 -0
- package/src/components/Form/TextField/examples/ShapeInput.tsx +15 -0
- package/src/components/Form/TextField/examples/SizeInput.tsx +16 -0
- package/src/components/Form/TextField/examples/StylesInput.tsx +35 -0
- package/src/components/Form/TextField/examples/VariantsInputs.tsx +15 -0
- package/src/components/Form/TextField/examples/index.ts +17 -0
- package/src/components/Form/TextField/styles.css +7 -0
- package/src/components/Layout/Center/Center/Center.props.ts +18 -0
- package/src/components/Layout/Center/Center/Center.view.tsx +12 -0
- package/src/components/Layout/Center/Center.md +17 -0
- package/src/components/Layout/Center/Center.tsx +11 -0
- package/src/components/Layout/Horizontal/Horizontal/Horizontal.props.ts +26 -0
- package/src/components/Layout/Horizontal/Horizontal/Horizontal.view.tsx +24 -0
- package/src/components/Layout/Horizontal/Horizontal.md +107 -0
- package/src/components/Layout/Horizontal/Horizontal.tsx +11 -0
- package/src/components/Layout/Horizontal/examples/Default.tsx +11 -0
- package/src/components/Layout/Horizontal/examples/Justify.tsx +25 -0
- package/src/components/Layout/Horizontal/examples/Reversed.tsx +11 -0
- package/src/components/Layout/Horizontal/examples/Wrap.tsx +29 -0
- package/src/components/Layout/Horizontal/examples/index.ts +4 -0
- package/src/components/Layout/Input/FieldContainer/FieldContainer/FieldContainer.props.ts +25 -0
- package/src/components/Layout/Input/FieldContainer/FieldContainer.tsx +17 -0
- package/src/components/Layout/Input/FieldContent/FieldContent/FieldContent.props.ts +75 -0
- package/src/components/Layout/Input/FieldContent/FieldContent.tsx +55 -0
- package/src/components/Layout/Input/FieldIcons/FieldIcons/FieldIcons.props.ts +12 -0
- package/src/components/Layout/Input/FieldIcons/FieldIcons.tsx +19 -0
- package/src/components/Layout/Input/FieldLabel/FieldLabel/FieldLabel.props.ts +31 -0
- package/src/components/Layout/Input/FieldLabel/FieldLabel.tsx +30 -0
- package/src/components/Layout/Input/FieldLayout/FieldLayout/FieldLayout.props.ts +29 -0
- package/src/components/Layout/Input/FieldLayout/FieldLayout.tsx +33 -0
- package/src/components/Layout/Input/FieldWrapper/FieldWrapper.props.ts +12 -0
- package/src/components/Layout/Input/FieldWrapper/FieldWrapper.tsx +11 -0
- package/src/components/Layout/Input/HelperText/HelperText.props.ts +21 -0
- package/src/components/Layout/Input/HelperText/HelperText.tsx +22 -0
- package/src/components/Layout/Input/index.ts +7 -0
- package/src/components/Layout/Vertical/Vertical/Vertical.props.ts +26 -0
- package/src/components/Layout/Vertical/Vertical/Vertical.type.ts +3 -0
- package/src/components/Layout/Vertical/Vertical/Vertical.view.tsx +23 -0
- package/src/components/Layout/Vertical/Vertical.md +120 -0
- package/src/components/Layout/Vertical/Vertical.tsx +12 -0
- package/src/components/Layout/Vertical/examples/Default.tsx +11 -0
- package/src/components/Layout/Vertical/examples/Justify.tsx +26 -0
- package/src/components/Layout/Vertical/examples/Reversed.tsx +11 -0
- package/src/components/Layout/Vertical/examples/Wrap.tsx +30 -0
- package/src/components/Layout/Vertical/examples/index.tsx +5 -0
- package/src/components/Layout/View/View.tsx +2 -0
- package/src/components/Layout/configs/Input.style.ts +45 -0
- package/src/components/Layout/configs/Input.type.ts +18 -0
- package/src/components/Link/Link/Link.props.ts +50 -0
- package/src/components/Link/Link/Link.state.ts +6 -0
- package/src/components/Link/Link/Link.style.ts +14 -0
- package/src/components/Link/Link/Link.type.d.ts +8 -0
- package/src/components/Link/Link/Link.view.tsx +44 -0
- package/src/components/Link/Link.md +61 -0
- package/src/components/Link/Link.tsx +15 -0
- package/src/components/Link/examples/Default.tsx +5 -0
- package/src/components/Link/examples/IsExternal.tsx +10 -0
- package/src/components/Link/examples/Underline.tsx +23 -0
- package/src/components/Loader/Loader/Loader.props.ts +105 -0
- package/src/components/Loader/Loader/Loader.style.ts +25 -0
- package/src/components/Loader/Loader/Loader.type.d.ts +4 -0
- package/src/components/Loader/Loader/Loader.view.tsx +138 -0
- package/src/components/Loader/Loader.md +111 -0
- package/src/components/Loader/Loader.tsx +11 -0
- package/src/components/Loader/examples/ColorLoader.tsx +13 -0
- package/src/components/Loader/examples/DefaultLoader.tsx +4 -0
- package/src/components/Loader/examples/PositionLoader.tsx +19 -0
- package/src/components/Loader/examples/SizeLoader.tsx +12 -0
- package/src/components/Loader/examples/SpeedLoader.tsx +12 -0
- package/src/components/Loader/examples/TextLoader.tsx +8 -0
- package/src/components/Loader/examples/VariantLoader.tsx +12 -0
- package/src/components/Loader/examples/index.ts +7 -0
- package/src/components/Modal/Examples/BlurModal.tsx +38 -0
- package/src/components/Modal/Examples/CloseButtonModal.tsx +44 -0
- package/src/components/Modal/Examples/DefaultModal.tsx +38 -0
- package/src/components/Modal/Examples/FullScreenModal.tsx +28 -0
- package/src/components/Modal/Examples/ModalPosition.tsx +61 -0
- package/src/components/Modal/Examples/PreventCloseModal.tsx +27 -0
- package/src/components/Modal/Examples/ScrollModal.tsx +41 -0
- package/src/components/Modal/Examples/ShadowModal.tsx +29 -0
- package/src/components/Modal/Examples/VariantModal.tsx +48 -0
- package/src/components/Modal/Examples/index.ts +9 -0
- package/src/components/Modal/Modal/Modal.props.ts +202 -0
- package/src/components/Modal/Modal/Modal.style.ts +23 -0
- package/src/components/Modal/Modal/Modal.type.d.ts +7 -0
- package/src/components/Modal/Modal/Modal.view.tsx +169 -0
- package/src/components/Modal/Modal.md +509 -0
- package/src/components/Modal/Modal.tsx +18 -0
- package/src/components/Svg/ArrowDown.tsx +32 -0
- package/src/components/Svg/ArrowUp.tsx +32 -0
- package/src/components/Svg/Check.tsx +28 -0
- package/src/components/Svg/Close.tsx +31 -0
- package/src/components/Svg/CloseEye.tsx +26 -0
- package/src/components/Svg/DustBin.tsx +29 -0
- package/src/components/Svg/Edit.tsx +34 -0
- package/src/components/Svg/ExternalLink.tsx +31 -0
- package/src/components/Svg/Indeterminate.tsx +21 -0
- package/src/components/Svg/OpenEye.tsx +26 -0
- package/src/components/Svg/Profile.tsx +40 -0
- package/src/components/Svg/RightArrow.tsx +44 -0
- package/src/components/Svg/index.tsx +12 -0
- package/src/components/Text/Text/Text.props.ts +84 -0
- package/src/components/Text/Text/Text.style.ts +34 -0
- package/src/components/Text/Text/Text.type.d.ts +14 -0
- package/src/components/Text/Text/Text.view.tsx +96 -0
- package/src/components/Text/Text.md +163 -0
- package/src/components/Text/Text.tsx +13 -0
- package/src/components/Wrapper.tsx +19 -0
- package/src/components/index.tsx +18 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Field, Form, Formik } from 'formik';
|
|
3
|
+
import { Button } from 'src/components';
|
|
4
|
+
import { Horizontal } from 'src/components';
|
|
5
|
+
|
|
6
|
+
import { DatePicker } from '../DatePicker';
|
|
7
|
+
|
|
8
|
+
export const FormikDatePicker = () => {
|
|
9
|
+
const initialValues = {
|
|
10
|
+
selectdate: '2023-05-30',
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
const onSubmit = (values: any) => {
|
|
14
|
+
alert(`${values.selectdate}`);
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
return (
|
|
18
|
+
<Formik initialValues={initialValues} onSubmit={onSubmit}>
|
|
19
|
+
{({ values, handleChange }) => (
|
|
20
|
+
<Form>
|
|
21
|
+
<Horizontal gap={10}>
|
|
22
|
+
<Field
|
|
23
|
+
id="selectdate"
|
|
24
|
+
name="selectdate"
|
|
25
|
+
as={DatePicker}
|
|
26
|
+
value={values.selectdate}
|
|
27
|
+
onChange={handleChange}
|
|
28
|
+
/>
|
|
29
|
+
<Button type="submit">Submit</Button>
|
|
30
|
+
</Horizontal>
|
|
31
|
+
</Form>
|
|
32
|
+
)}
|
|
33
|
+
</Formik>
|
|
34
|
+
);
|
|
35
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Vertical } from 'src/components/Layout/Vertical/examples';
|
|
3
|
+
|
|
4
|
+
import { DatePicker } from '../DatePicker';
|
|
5
|
+
|
|
6
|
+
export const SizeDatePicker = () => {
|
|
7
|
+
return (
|
|
8
|
+
<Vertical gap={10}>
|
|
9
|
+
<DatePicker name="xs" size="xs" />
|
|
10
|
+
<DatePicker name="sm" size="sm" />
|
|
11
|
+
<DatePicker name="md" size="md" />
|
|
12
|
+
<DatePicker name="lg" size="lg" />
|
|
13
|
+
<DatePicker name="xl" size="xl" />
|
|
14
|
+
</Vertical>
|
|
15
|
+
);
|
|
16
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import { DatePicker } from '../DatePicker';
|
|
4
|
+
|
|
5
|
+
export const StyledDatePicker = () => (
|
|
6
|
+
<DatePicker
|
|
7
|
+
colorScheme="theme.primary"
|
|
8
|
+
shadow={{ boxShadow: 'rgba(93, 37, 85, 0.3) 0px 3px 8px' }}
|
|
9
|
+
styles={{
|
|
10
|
+
box: { borderRadius: 10, borderColor: 'theme.primary' },
|
|
11
|
+
label: { color: 'theme.primary' },
|
|
12
|
+
}}
|
|
13
|
+
/>
|
|
14
|
+
);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from 'src/components/Form/DatePicker/examples/ColorScheme';
|
|
2
|
+
export * from 'src/components/Form/DatePicker/examples/Default';
|
|
3
|
+
export * from 'src/components/Form/DatePicker/examples/DisabledInput';
|
|
4
|
+
export * from 'src/components/Form/DatePicker/examples/ErrorCheckbox';
|
|
5
|
+
export * from 'src/components/Form/DatePicker/examples/FormCheckout';
|
|
6
|
+
export * from 'src/components/Form/DatePicker/examples/Formik';
|
|
7
|
+
export * from 'src/components/Form/DatePicker/examples/helperTextDatePicker';
|
|
8
|
+
export * from 'src/components/Form/DatePicker/examples/ReadOnlyInput';
|
|
9
|
+
export * from 'src/components/Form/DatePicker/examples/Shadow';
|
|
10
|
+
export * from 'src/components/Form/DatePicker/examples/SizeInput';
|
|
11
|
+
export * from 'src/components/Form/DatePicker/examples/StylesInput';
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Headings, Sizes, TextWeights } from './Label.type';
|
|
2
|
+
|
|
3
|
+
export interface LabelProps {
|
|
4
|
+
/**
|
|
5
|
+
* The text content
|
|
6
|
+
*/
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
/**
|
|
9
|
+
* Specify a heading html tag.
|
|
10
|
+
*/
|
|
11
|
+
heading?: Headings;
|
|
12
|
+
/**
|
|
13
|
+
* If true, the text is styled in italic
|
|
14
|
+
*/
|
|
15
|
+
isItalic?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Marks up a text to indicate that it is no longer valid
|
|
18
|
+
*/
|
|
19
|
+
isStriked?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* If true, it underline the text
|
|
22
|
+
*/
|
|
23
|
+
isUnderlined?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Changes the text-size
|
|
26
|
+
*/
|
|
27
|
+
size?: Sizes | number;
|
|
28
|
+
/**
|
|
29
|
+
* Changes the font weight of the text
|
|
30
|
+
*/
|
|
31
|
+
weight?: TextWeights;
|
|
32
|
+
/**
|
|
33
|
+
* Other properties
|
|
34
|
+
*/
|
|
35
|
+
[x: string]: any;
|
|
36
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
|
|
2
|
+
import { Headings } from './Label.type';
|
|
3
|
+
|
|
4
|
+
export const HeadingSizes: Record<Headings, Record<string, number | string>> = {
|
|
5
|
+
h1: {
|
|
6
|
+
fontSize: 96,
|
|
7
|
+
lineHeight: 112,
|
|
8
|
+
letterSpacing: -1.5,
|
|
9
|
+
},
|
|
10
|
+
h2: {
|
|
11
|
+
fontSize: 60,
|
|
12
|
+
lineHeight: 71,
|
|
13
|
+
letterSpacing: -0.5,
|
|
14
|
+
},
|
|
15
|
+
h3: {
|
|
16
|
+
fontSize: 48,
|
|
17
|
+
lineHeight: 57,
|
|
18
|
+
letterSpacing: 0,
|
|
19
|
+
},
|
|
20
|
+
h4: {
|
|
21
|
+
fontSize: 34,
|
|
22
|
+
lineHeight: 40,
|
|
23
|
+
letterSpacing: 0.25,
|
|
24
|
+
},
|
|
25
|
+
h5: {
|
|
26
|
+
fontSize: 24,
|
|
27
|
+
lineHeight: 28,
|
|
28
|
+
letterSpacing: 0,
|
|
29
|
+
},
|
|
30
|
+
h6: {
|
|
31
|
+
fontSize: 20,
|
|
32
|
+
lineHeight: 24,
|
|
33
|
+
letterSpacing: 0.15,
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export type TextWeights =
|
|
2
|
+
| 'hairline'
|
|
3
|
+
| 'thin'
|
|
4
|
+
| 'light'
|
|
5
|
+
| 'normal'
|
|
6
|
+
| 'medium'
|
|
7
|
+
| 'semiBold'
|
|
8
|
+
| 'bold'
|
|
9
|
+
| 'extraBold'
|
|
10
|
+
| 'black';
|
|
11
|
+
|
|
12
|
+
export type Sizes = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl' | '4xl' | '5xl' | '6xl';
|
|
13
|
+
|
|
14
|
+
export type Headings = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Element,Typography } from 'app-studio';
|
|
3
|
+
|
|
4
|
+
import { LabelProps } from './Label.props';
|
|
5
|
+
import { HeadingSizes } from './Label.style';
|
|
6
|
+
|
|
7
|
+
const LabelView: React.FC<LabelProps> = ({
|
|
8
|
+
children,
|
|
9
|
+
heading,
|
|
10
|
+
isItalic = false,
|
|
11
|
+
isUnderlined = false,
|
|
12
|
+
isStriked = false,
|
|
13
|
+
weight = 'normal',
|
|
14
|
+
size = 'sm',
|
|
15
|
+
...props
|
|
16
|
+
}) => {
|
|
17
|
+
const headingStyles = heading ? HeadingSizes[heading] : {};
|
|
18
|
+
|
|
19
|
+
return (
|
|
20
|
+
<Element
|
|
21
|
+
as="label"
|
|
22
|
+
width="100%"
|
|
23
|
+
fontSize={size}
|
|
24
|
+
fontStyle={isItalic ? 'italic' : 'normal'}
|
|
25
|
+
fontWeight={Typography.fontWeights[weight]}
|
|
26
|
+
textDecoration={isStriked ? 'line-through' : isUnderlined ? 'underline' : 'none'}
|
|
27
|
+
{...headingStyles}
|
|
28
|
+
{...props}
|
|
29
|
+
>
|
|
30
|
+
{children}
|
|
31
|
+
</Element>
|
|
32
|
+
);
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
export default LabelView;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { TextFieldProps } from 'src/components/Form/TextField/TextField/TextField.props';
|
|
3
|
+
|
|
4
|
+
export interface PasswordProps extends TextFieldProps {
|
|
5
|
+
/**
|
|
6
|
+
* The name of the input field
|
|
7
|
+
*/
|
|
8
|
+
name?: string;
|
|
9
|
+
/**
|
|
10
|
+
* If true, the Input will be unusable
|
|
11
|
+
*/
|
|
12
|
+
isDisabled?: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Icon to Indicate that the password is visible
|
|
15
|
+
*/
|
|
16
|
+
visibleIcon?: React.ReactNode;
|
|
17
|
+
/**
|
|
18
|
+
* Icon to Indicate that the password is hidden
|
|
19
|
+
*/
|
|
20
|
+
hiddenIcon?: React.ReactNode;
|
|
21
|
+
/**
|
|
22
|
+
* other properties
|
|
23
|
+
*/
|
|
24
|
+
[x: string]: any;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface PasswordViewProps extends PasswordProps {
|
|
28
|
+
/**
|
|
29
|
+
* Optional prop to determine if the password is visible
|
|
30
|
+
*/
|
|
31
|
+
isVisible?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* Optional callback prop to update the visibility state
|
|
34
|
+
*/
|
|
35
|
+
setIsVisible?: Function;
|
|
36
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
2
|
+
|
|
3
|
+
export type Variant = 'outline' | 'default' | 'unStyled';
|
|
4
|
+
|
|
5
|
+
export type Shape = 'default' | 'sharp' | 'rounded' | 'pillShaped';
|
|
6
|
+
|
|
7
|
+
export type Size = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl' | '4xl' | '5xl' | '6xl';
|
|
8
|
+
|
|
9
|
+
export type PasswordStyles = {
|
|
10
|
+
box?: CSSProperties;
|
|
11
|
+
Password?: CSSProperties;
|
|
12
|
+
label?: CSSProperties;
|
|
13
|
+
helperText?: CSSProperties;
|
|
14
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { TextField, View } from 'src/components';
|
|
3
|
+
|
|
4
|
+
import { PasswordViewProps } from './Password.props';
|
|
5
|
+
|
|
6
|
+
const PasswordView: React.FC<PasswordViewProps> = ({
|
|
7
|
+
name,
|
|
8
|
+
visibleIcon,
|
|
9
|
+
hiddenIcon,
|
|
10
|
+
isDisabled = false,
|
|
11
|
+
isVisible = false,
|
|
12
|
+
setIsVisible = () => {},
|
|
13
|
+
...props
|
|
14
|
+
}) => (
|
|
15
|
+
<TextField
|
|
16
|
+
name={name}
|
|
17
|
+
type={isVisible ? 'text' : 'password'}
|
|
18
|
+
rightChild={
|
|
19
|
+
<View
|
|
20
|
+
onPress={() => {
|
|
21
|
+
if (!isDisabled) setIsVisible(!isVisible);
|
|
22
|
+
}}
|
|
23
|
+
>
|
|
24
|
+
{isVisible ? visibleIcon : hiddenIcon}
|
|
25
|
+
</View>
|
|
26
|
+
}
|
|
27
|
+
isClearable={false}
|
|
28
|
+
{...props}
|
|
29
|
+
/>
|
|
30
|
+
);
|
|
31
|
+
|
|
32
|
+
export default PasswordView;
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
### **Import**
|
|
2
|
+
|
|
3
|
+
```tsx static
|
|
4
|
+
import { Password } from "app-studio";
|
|
5
|
+
```
|
|
6
|
+
|
|
7
|
+
### **Default**
|
|
8
|
+
|
|
9
|
+
It has type equals to “password” and isClearable set to false. It has all the props of the TextField component.
|
|
10
|
+
|
|
11
|
+
```tsx
|
|
12
|
+
<Password label="Password" value="123456" />
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
### **Disabled**
|
|
16
|
+
|
|
17
|
+
“**_isDisabled_**” makes the field unusable.
|
|
18
|
+
|
|
19
|
+
```tsx
|
|
20
|
+
<Password value="password" isDisabled />
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
### **Icon**
|
|
24
|
+
|
|
25
|
+
“**_visibleIcon_**” and “**_hiddenIcon_**” are icons indicating whether the password is visible or hidden.
|
|
26
|
+
|
|
27
|
+
```tsx
|
|
28
|
+
import { OpenEyeSvg } from "../../Svg/OpenEye";
|
|
29
|
+
import { CloseEyeSvg } from "../../Svg/CloseEye";
|
|
30
|
+
|
|
31
|
+
<Password
|
|
32
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
33
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
34
|
+
/>;
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
### **Error**
|
|
38
|
+
|
|
39
|
+
“**_error_**” if true, indicates that the text field value failed the validation criteria.
|
|
40
|
+
|
|
41
|
+
```tsx
|
|
42
|
+
import { Vertical } from "../../Layout/Vertical/Vertical";
|
|
43
|
+
import { Button } from "../../Button/Button";
|
|
44
|
+
import { OpenEyeSvg } from "../../Svg/OpenEye";
|
|
45
|
+
import { CloseEyeSvg } from "../../Svg/CloseEye";
|
|
46
|
+
|
|
47
|
+
<Password
|
|
48
|
+
placeholder="Password"
|
|
49
|
+
colorScheme="theme.secondary"
|
|
50
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
51
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
52
|
+
error
|
|
53
|
+
/>;
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### **HelperText**
|
|
57
|
+
|
|
58
|
+
“**_helperText_**” is a string text used to inform the user that the content of the field is invalid.
|
|
59
|
+
|
|
60
|
+
```tsx
|
|
61
|
+
import { Vertical } from "../../Layout/Vertical/Vertical";
|
|
62
|
+
import { Button } from "../../Button/Button";
|
|
63
|
+
import { OpenEyeSvg } from "../../Svg/OpenEye";
|
|
64
|
+
import { CloseEyeSvg } from "../../Svg/CloseEye";
|
|
65
|
+
|
|
66
|
+
<Password
|
|
67
|
+
placeholder="Password"
|
|
68
|
+
helperText="Incorrect password"
|
|
69
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
70
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
71
|
+
error
|
|
72
|
+
/>;
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
## **Default Values**
|
|
76
|
+
|
|
77
|
+
```tsx static
|
|
78
|
+
const Shapes: Record<Shape, number | string> = {
|
|
79
|
+
default: "6px 6px 0 0",
|
|
80
|
+
sharp: 0,
|
|
81
|
+
rounded: 4,
|
|
82
|
+
pillShaped: 24,
|
|
83
|
+
};
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
## Types
|
|
87
|
+
|
|
88
|
+
```tsx static
|
|
89
|
+
type Variant = "outline" | "default" | "unStyled";
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
```tsx static
|
|
93
|
+
type Shape = "default" | "sharp" | "rounded" | "pillShaped";
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
```tsx static
|
|
97
|
+
type Size = "xs" | "sm" | "md" | "lg" | "xl";
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
```tsx static
|
|
101
|
+
type TextFieldStyles = {
|
|
102
|
+
box?: CSSProperties;
|
|
103
|
+
field?: CSSProperties;
|
|
104
|
+
label?: CSSProperties;
|
|
105
|
+
helperText?: CSSProperties;
|
|
106
|
+
text?: CSSProperties;
|
|
107
|
+
};
|
|
108
|
+
```
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import { PasswordProps } from './Password/Password.props';
|
|
4
|
+
import { usePasswordState } from './Password/Password.state';
|
|
5
|
+
import PasswordView from './Password/Password.view';
|
|
6
|
+
|
|
7
|
+
const PasswordComponent: React.FC<PasswordProps> = (props) => {
|
|
8
|
+
const passwordState = usePasswordState();
|
|
9
|
+
return <PasswordView {...passwordState} {...props} />;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* To allow users to securely enter sensitive information
|
|
14
|
+
*/
|
|
15
|
+
export const Password = PasswordComponent;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { CloseEyeSvg } from 'src/components/Svg/CloseEye';
|
|
3
|
+
import { OpenEyeSvg } from 'src/components/Svg/OpenEye';
|
|
4
|
+
|
|
5
|
+
import { Password } from '../Password';
|
|
6
|
+
|
|
7
|
+
export const DefaultPassword = () => (
|
|
8
|
+
<Password visibleIcon={<OpenEyeSvg size={14} />} hiddenIcon={<CloseEyeSvg size={14} />} />
|
|
9
|
+
);
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { CloseEyeSvg } from 'src/components/Svg/CloseEye';
|
|
3
|
+
import { OpenEyeSvg } from 'src/components/Svg/OpenEye';
|
|
4
|
+
|
|
5
|
+
import { Password } from '../Password';
|
|
6
|
+
|
|
7
|
+
export const DisabledPassword = () => {
|
|
8
|
+
return (
|
|
9
|
+
<Password
|
|
10
|
+
name="disabled"
|
|
11
|
+
value="disabled"
|
|
12
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
13
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
14
|
+
isDisabled
|
|
15
|
+
/>
|
|
16
|
+
);
|
|
17
|
+
};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { useState } from 'react';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Button } from 'src/components';
|
|
4
|
+
import { Password, TextField } from 'src/components';
|
|
5
|
+
import { Vertical } from 'src/components';
|
|
6
|
+
import { CloseEyeSvg } from 'src/components/Svg/CloseEye';
|
|
7
|
+
import { OpenEyeSvg } from 'src/components/Svg/OpenEye';
|
|
8
|
+
|
|
9
|
+
export const ErrorPassword = () => {
|
|
10
|
+
const initialValues = {
|
|
11
|
+
name: '',
|
|
12
|
+
password: '',
|
|
13
|
+
};
|
|
14
|
+
const [formValues, setFormValues] = useState(initialValues);
|
|
15
|
+
const [formErrors, setFormErrors] = useState(initialValues);
|
|
16
|
+
|
|
17
|
+
const validate = (values: any) => {
|
|
18
|
+
const errors: any = {};
|
|
19
|
+
|
|
20
|
+
if (!values.name) {
|
|
21
|
+
errors.name = 'Required';
|
|
22
|
+
}
|
|
23
|
+
if (!values.password) {
|
|
24
|
+
errors.password = 'Required';
|
|
25
|
+
}
|
|
26
|
+
setFormErrors(errors);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
const handleChange = (event: any) => {
|
|
30
|
+
setFormValues({ ...formValues, [event.target.name]: event.target.value });
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
const handleSubmit = (event: any) => {
|
|
34
|
+
event.preventDefault();
|
|
35
|
+
validate(formValues);
|
|
36
|
+
if (Object.values(formErrors).length === 0) {
|
|
37
|
+
alert(`Hello, ${formValues.name} ${formValues.password}`);
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
return (
|
|
41
|
+
<form onSubmit={handleSubmit}>
|
|
42
|
+
<Vertical gap={10} wrap="nowrap">
|
|
43
|
+
<TextField
|
|
44
|
+
name="name"
|
|
45
|
+
placeholder="Name"
|
|
46
|
+
error={!!formErrors.name}
|
|
47
|
+
onChange={handleChange}
|
|
48
|
+
colorScheme="theme.secondary"
|
|
49
|
+
isClearable={true}
|
|
50
|
+
/>
|
|
51
|
+
<Password
|
|
52
|
+
name="password"
|
|
53
|
+
placeholder="Password"
|
|
54
|
+
error={!!formErrors.password}
|
|
55
|
+
onChange={handleChange}
|
|
56
|
+
colorScheme="theme.secondary"
|
|
57
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
58
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
59
|
+
/>
|
|
60
|
+
<Button type="submit" height="40px">
|
|
61
|
+
Submit
|
|
62
|
+
</Button>
|
|
63
|
+
</Vertical>
|
|
64
|
+
</form>
|
|
65
|
+
);
|
|
66
|
+
};
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Field, Form, Formik } from 'formik';
|
|
3
|
+
import { Button } from 'src/components';
|
|
4
|
+
import { Password, TextField } from 'src/components';
|
|
5
|
+
import { Vertical } from 'src/components';
|
|
6
|
+
import { CloseEyeSvg } from 'src/components/Svg/CloseEye';
|
|
7
|
+
import { OpenEyeSvg } from 'src/components/Svg/OpenEye';
|
|
8
|
+
|
|
9
|
+
export const FormikErrorPassword = () => {
|
|
10
|
+
const initialValues = {
|
|
11
|
+
name: '',
|
|
12
|
+
password: '',
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
const validate = (values: any) => {
|
|
16
|
+
const errors: any = {};
|
|
17
|
+
|
|
18
|
+
if (!values.name) {
|
|
19
|
+
errors.name = 'Required';
|
|
20
|
+
}
|
|
21
|
+
if (!values.password) {
|
|
22
|
+
errors.password = 'Required';
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
return errors;
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
return (
|
|
29
|
+
<Formik
|
|
30
|
+
initialValues={initialValues}
|
|
31
|
+
validate={validate}
|
|
32
|
+
onSubmit={(values, { setSubmitting }) => {
|
|
33
|
+
setTimeout(() => {
|
|
34
|
+
alert(JSON.stringify(values, null, 2));
|
|
35
|
+
setSubmitting(false);
|
|
36
|
+
}, 400);
|
|
37
|
+
}}
|
|
38
|
+
>
|
|
39
|
+
{({ errors, touched, isSubmitting }) => (
|
|
40
|
+
<Form>
|
|
41
|
+
<Vertical gap={10}>
|
|
42
|
+
<Field as={TextField} name="name" label="Name" error={touched.name && errors.name} colorScheme="theme.secondary" />
|
|
43
|
+
<Field
|
|
44
|
+
as={Password}
|
|
45
|
+
name="password"
|
|
46
|
+
label="Password"
|
|
47
|
+
colorScheme="theme.secondary"
|
|
48
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
49
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
50
|
+
error={touched.password && errors.password}
|
|
51
|
+
/>
|
|
52
|
+
|
|
53
|
+
<Button type="submit" isDisabled={isSubmitting}>
|
|
54
|
+
Submit
|
|
55
|
+
</Button>
|
|
56
|
+
</Vertical>
|
|
57
|
+
</Form>
|
|
58
|
+
)}
|
|
59
|
+
</Formik>
|
|
60
|
+
);
|
|
61
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Field, Form, Formik } from 'formik';
|
|
3
|
+
import { Button } from 'src/components';
|
|
4
|
+
import { Password, TextField } from 'src/components';
|
|
5
|
+
import { Vertical } from 'src/components';
|
|
6
|
+
import { CloseEyeSvg } from 'src/components/Svg/CloseEye';
|
|
7
|
+
import { OpenEyeSvg } from 'src/components/Svg/OpenEye';
|
|
8
|
+
|
|
9
|
+
export const FormikHelperTextPassword = () => {
|
|
10
|
+
const initialValues = {
|
|
11
|
+
firstName: '',
|
|
12
|
+
password: '',
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
const validate = (values: any) => {
|
|
16
|
+
const errors: any = {};
|
|
17
|
+
|
|
18
|
+
if (!values.firstName) {
|
|
19
|
+
errors.firstName = 'Required';
|
|
20
|
+
}
|
|
21
|
+
if (!values.password) {
|
|
22
|
+
errors.password = 'Required';
|
|
23
|
+
}
|
|
24
|
+
return errors;
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
return (
|
|
28
|
+
<Formik
|
|
29
|
+
initialValues={initialValues}
|
|
30
|
+
validate={validate}
|
|
31
|
+
onSubmit={(values, { setSubmitting }) => {
|
|
32
|
+
setTimeout(() => {
|
|
33
|
+
alert(JSON.stringify(values, null, 2));
|
|
34
|
+
setSubmitting(false);
|
|
35
|
+
}, 400);
|
|
36
|
+
}}
|
|
37
|
+
>
|
|
38
|
+
{({ errors, touched, isSubmitting }) => (
|
|
39
|
+
<Form>
|
|
40
|
+
<Vertical gap={10}>
|
|
41
|
+
<Field
|
|
42
|
+
as={TextField}
|
|
43
|
+
name="firstName"
|
|
44
|
+
value="First Name"
|
|
45
|
+
error={touched.firstName && errors.firstName}
|
|
46
|
+
helperText={touched.firstName && errors.firstName}
|
|
47
|
+
/>
|
|
48
|
+
<Field
|
|
49
|
+
as={Password}
|
|
50
|
+
name="password"
|
|
51
|
+
placeholder="Password"
|
|
52
|
+
error={touched.password && errors.password}
|
|
53
|
+
helperText={touched.password && errors.password}
|
|
54
|
+
visibleIcon={<OpenEyeSvg size={14} />}
|
|
55
|
+
hiddenIcon={<CloseEyeSvg size={14} />}
|
|
56
|
+
/>
|
|
57
|
+
<Button type="submit" isDisabled={isSubmitting}>
|
|
58
|
+
Submit
|
|
59
|
+
</Button>
|
|
60
|
+
</Vertical>
|
|
61
|
+
</Form>
|
|
62
|
+
)}
|
|
63
|
+
</Formik>
|
|
64
|
+
);
|
|
65
|
+
};
|