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

Update docs for the builtin components #17810

Merged
merged 3 commits into from
Mar 29, 2019

Conversation

wycats
Copy link
Member

@wycats wycats commented Mar 27, 2019

No description provided.

* form

When invoked with `{{input type="checkbox"}}`, you can only customize these attributes. When
invoked with `<Input @type="checkbox" />`, you can just use HTML attributes directly.
Copy link
Member

Choose a reason for hiding this comment

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

This is somewhat confusing, because it seems to suggest you can do <Input type="checkbox" />


```handlebars
Search:
{{input value=searchWord}}
```
<Input @value={{this.searchWord}}>`
Copy link
Member

Choose a reason for hiding this comment

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

Missing backticks

});
```
In most cases, if you want to pass an attribute to the underlying HTML `<input>` element, you
can pass the attribute directly, just like any other Ember component.
Copy link
Member

Choose a reason for hiding this comment

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

A short example would be good here

element. When left unquoted, these values will be bound to a property on the
template's current rendering context (most typically a controller instance).
A very common use of this helper is to bind the `value` of an input to an Object's attribute:
If no `type` argument is specified, a default of type 'text' is used.
Copy link
Member

Choose a reason for hiding this comment

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

do we want to say @type here?

Copy link
Member Author

Choose a reason for hiding this comment

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

You suggested to me to remove the @s 😛


### Extending `TextField`

Internally, `<Input @type="text" />` creates an instance of `TextField`, passing arguments from
Copy link
Member

Choose a reason for hiding this comment

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

TextField could use a link

classNames: ['my-app-checkbox']
});
```
Internally, `<Input @type="checkbox" />` creates an instance of `Ember.Checkbox`
Copy link
Member

Choose a reason for hiding this comment

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

Does this need the same text as above?


See more about [Ember components](/api/ember/release/classes/Component)
/**
See Ember.Templates.components.Textarea.
Copy link
Member

Choose a reason for hiding this comment

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

Seems like this is missing a link


Because HTML `textarea` elements do not contain inner HTML the `layout` and
`layoutName` properties will not be applied.
The internal representation used for `Textarea` invocations.

@class TextArea
Copy link
Member

Choose a reason for hiding this comment

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

did this get associated to @ember/component/text-area correctly? does it need a @for or something

Copy link
Member

@chancancode chancancode left a comment

Choose a reason for hiding this comment

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

this mostly look good to me

@rwjblue
Copy link
Member

rwjblue commented Mar 28, 2019

Looks like the CI failure is needing to add these to tests/docs/expected.js

[
  "Input",
  "LinkTo",
  "Textarea"
]

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.

3 participants