Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add input and all inputable components prop size #2463

Conversation

yvmunayev
Copy link
Contributor

fix: #2462

Changes proposed in this PR:

@nexxtway/react-rainbow

@commit-lint
Copy link

commit-lint bot commented Oct 1, 2022

Features

  • add input component prop size (dc25d9b)
  • add password input component prop size (2b5b73e)
  • add date picker component prop size (40938d2)
  • add date time picker component prop size (79ef194)
  • add time picker component prop size (b7fefb2)
  • add checkbox component prop size (4416818)
  • add radio input component prop size (f5e8fac)
  • add checkbox group component prop size (d87e038)
  • add radio group component prop size (eb8360b)

Bug Fixes

  • remove size to checkbox and radio button (bc41024)
  • size description (391fd84)

Contributors

yvmunayev

Commit-Lint commands

You can trigger Commit-Lint actions by commenting on this PR:

  • @Commit-Lint merge patch will merge dependabot PR on "patch" versions (X.X.Y - Y change)
  • @Commit-Lint merge minor will merge dependabot PR on "minor" versions (X.Y.Y - Y change)
  • @Commit-Lint merge major will merge dependabot PR on "major" versions (Y.Y.Y - Y change)
  • @Commit-Lint merge disable will desactivate merge dependabot PR
  • @Commit-Lint review will approve dependabot PR
  • @Commit-Lint stop review will stop approve dependabot PR

@github-actions
Copy link

github-actions bot commented Oct 1, 2022

Visit the preview URL for this PR (updated for commit 391fd84):

https://react-rainbow--pr2463-feat-add-input-and-a-9r6pk514.web.app

(expires Fri, 14 Oct 2022 00:41:46 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

…to feat-add-input-and-all-inputable-components-prop-size
@@ -7,7 +7,7 @@ import StyledItemDescription from '../RadioGroup/styled/itemDescription';
import RenderIf from '../RenderIf';

export default function CheckboxList(props) {
const { values, options, onChange, describedBy, name, error } = props;
const { values, options, onChange, describedBy, name, error, size } = props;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here in this component we will not add this for now

@@ -219,6 +221,8 @@ DatePicker.propTypes = {
disabledDays: PropTypes.arrayOf(
PropTypes.oneOfType([PropTypes.string, PropTypes.instanceOf(Date)]),
),
/** The size of the input. Valid values are small, and large. */

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are small, medium, and large.

@@ -222,6 +224,8 @@ DateTimePicker.propTypes = {
disabledDays: PropTypes.arrayOf(
PropTypes.oneOfType([PropTypes.string, PropTypes.instanceOf(Date)]),
),
/** The size of the input. Valid values are small, and large. */

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^

@@ -18,7 +18,9 @@ export default function Label(props) {
return (
<label htmlFor={inputId} id={id}>
<span className="rainbow-input_faux" />
<StyledLabelText disabled={disabled}>{label}</StyledLabelText>
<StyledLabelText disabled={disabled} size={size}>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^ I think we don't need this here for now

props.size === 'small' &&
`
font-size: ${FONT_SIZE_TEXT_MEDIUM};
`};

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^

@@ -147,6 +147,8 @@ Input.propTypes = {
*
* For a detailed list, go to: https://www.w3.org/TR/WCAG21/#input-purposes */
autoComplete: PropTypes.string,
/** The size of the input. Valid values are small, and large. */

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small, medium, and large

@@ -75,13 +76,15 @@ export default class Checkbox extends Component {
aria-describedby={ariaDescribedBy}
ref={this.inputRef}
error={error}
size={size}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not for now here in checkbox

@@ -96,6 +97,7 @@ export default class InputCheckbox extends Component {
error={error}
label={label}
hideLabel={hideLabel}
size={size}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not now

`
width: 18px;
height: 18px;
`};

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^

@@ -74,6 +74,7 @@ export default class InputRadio extends Component {
name,
checked,
hideLabel,
size,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^

@@ -75,13 +76,15 @@ export default class Radio extends Component {
aria-describedby={ariaDescribedBy}
ref={this.inputRef}
error={error}
size={size}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^

height: 25px;
`};

${props =>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same ^^

@codeclimate
Copy link

codeclimate bot commented Oct 7, 2022

Code Climate has analyzed commit 391fd84 and detected 6 issues on this pull request.

Here's the issue category breakdown:

Category Count
Duplication 6

View more on Code Climate.

@LeandroTorresSicilia LeandroTorresSicilia merged commit e010800 into master Oct 7, 2022
@LeandroTorresSicilia LeandroTorresSicilia deleted the feat-add-input-and-all-inputable-components-prop-size branch October 7, 2022 16:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: add input and all inputable components prop size
2 participants