Skip to content
This repository was archived by the owner on Jul 27, 2023. It is now read-only.

Feature 7 - Input Component [Dev]#78

Open
danielvaldivv wants to merge 6 commits into
developfrom
feature-7
Open

Feature 7 - Input Component [Dev]#78
danielvaldivv wants to merge 6 commits into
developfrom
feature-7

Conversation

@danielvaldivv

@danielvaldivv danielvaldivv commented Nov 17, 2021

Copy link
Copy Markdown
Contributor

Checklist ✅

resolves [#7 ]

input

@kevfarid kevfarid linked an issue Nov 18, 2021 that may be closed by this pull request
2 tasks
@kevfarid kevfarid removed a link to an issue Nov 18, 2021
2 tasks
@kevfarid kevfarid linked an issue Nov 18, 2021 that may be closed by this pull request
2 tasks
@kevfarid kevfarid added this to the Sprint 5 - UI milestone Nov 18, 2021
@kevfarid kevfarid added components A components feature feature New feature or request labels Nov 18, 2021
@kevfarid

Copy link
Copy Markdown
Contributor

You remember add the info to Side Bar as: Reviewers, assigners, Labels, Projects, Milestone and Issue. too, add screenshot of the component in the PR.

@danielvaldivv danielvaldivv changed the title Feature 7 Feature 7 - Input Component Nov 18, 2021
@danielvaldivv danielvaldivv added the weight:2 weight:2 label Nov 18, 2021
Comment thread packages/components/package.json Outdated
}
},
"dependencies": {
"@lerna/bootstrap": "^4.0.0",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do we need this package?

Comment thread packages/components/src/Input/Input.js Outdated
const useStyleSheet = createStyleSheet(
(theme, { required, type }) => ({
inputDefault: {
width: 199,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This, and the height are givin issues with the checkbox type. They make it looks huge.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We could provide these styles conditionally.

Comment thread packages/components/src/Input/Input.js Outdated
inputDefault: {
width: 199,
height: 40,
borderRadius: 5,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Don't we have this in the theme?

Comment thread packages/components/src/Input/Input.js Outdated
width: 199,
height: 40,
borderRadius: 5,
display: 'flex',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I not gettin this one, I removed those styles and the input behave the same. What are you trying to achieve here?

Comment thread packages/components/src/Input/Input.js Outdated
height: 40,
borderRadius: 5,
display: 'flex',
alignContent: 'center',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This also applies to the point above.

Comment thread packages/components/src/Input/Input.js Outdated
borderRadius: 5,
display: 'flex',
alignContent: 'center',
alignItems: 'center',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

And this.

Comment thread packages/docs/components/Input/Input.js Outdated
inputStyle: {
padding: theme.spacing(2),
},
}), { key: 'padding' });

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Whe could use here DocsInput instead of padding

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The mean of the key is to give a classname prefix.

Comment thread packages/docs/components/Input/Input.js Outdated
const { required, type, placeholder, disabled, otherProps } = props;

return <Input
className={classes.inputStyle}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good use of the useStyleSheet hook 😁. We could change the classname to input instead.

Comment thread packages/docs/package.json Outdated
},
"dependencies": {
"@platzily-ui/icons": "0.1.0",
"@lerna/bootstrap": "^4.0.0",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why do we need this package?


const InputComponent = () => {

return <Input type="checkbox" />;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This is the one I'm talking that the weight and height are giving troubles. Making it looks huge.

Comment thread yarn.lock Outdated
semver "^7.3.4"

"@lerna/bootstrap@4.0.0":
"@lerna/bootstrap@4.0.0", "@lerna/bootstrap@^4.0.0":

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

👀

@danielvaldivv danielvaldivv changed the title Feature 7 - Input Component Feature 7 - Input Component [Dev] Nov 23, 2021
@danielvaldivv danielvaldivv added documentation Improvements or additions to documentation weight:1 something that is easy to do and removed documentation Improvements or additions to documentation weight:2 weight:2 labels Nov 23, 2021
const useStyleSheet = createStyleSheet(
(theme, { width, height }) => ({
inputDefault: {
width: width || 199,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Instead of doing this why dont we pass a new class when the button is of type checkbox? 🤔

(theme, { width, height }) => ({
inputDefault: {
width: width || 199,
height: height || 40,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Also here.

paper: {
backgroundColor: detectColor(theme, color || 'neutral-tertiary'),
padding: theme.spacing(),
padding: theme.spacing(1),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No needed when the value is one.

@edanfesi edanfesi modified the milestones: Sprint 5 - UI, Sprint 6 - UI Dec 1, 2021
@edanfesi edanfesi added the carry-over-5 task that started in sprint 5 but it's not finished. label Dec 1, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

carry-over-5 task that started in sprint 5 but it's not finished. components A components feature documentation Improvements or additions to documentation feature New feature or request weight:1 something that is easy to do

Projects

Status: In progress

Development

Successfully merging this pull request may close these issues.

Feature - Input Component [Dev]

4 participants