-
Notifications
You must be signed in to change notification settings - Fork 95
feat:added location field #270
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
base: develop
Are you sure you want to change the base?
Changes from 1 commit
920339c
8e43d60
6fa947c
c22957b
c072f70
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,7 @@ | ||
| <div class="field"> | ||
| <label for={{@for}}>{{@label}}:</label> | ||
| <Input | ||
| <div class="field"> | ||
| <Input | ||
| @id={{@id}} | ||
| @type={{@type}} | ||
| @value={{@value}} | ||
|
|
@@ -9,6 +10,13 @@ | |
| @class={{if @showError 'input errorBorder' 'input'}} | ||
| {{on 'input' (fn this.inputFieldChanged)}} | ||
| /> | ||
| {{#if @buttonupload }} | ||
| <button class="upload" type="submit">update location</button> | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. update location -> Update, as the user already knows they are updating the location from the Input Label |
||
| {{/if}} | ||
| </div> | ||
|
|
||
|
|
||
|
|
||
|
Comment on lines
+18
to
+19
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we please remove these extra spaces? |
||
| {{#if @helpMsg}} | ||
| <em class="help-msg">{{@helpMsg}}</em> | ||
| {{/if}} | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -70,6 +70,14 @@ export default class ProfileController extends Controller { | |
| showError: false, | ||
| disabled: true, | ||
| }, | ||
| { | ||
| id: 'location', | ||
| label: 'Location', | ||
| type: 'text', | ||
| placeholder: 'bangalore', | ||
| buttonupload: true, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we please follow CamelCase here? |
||
| disabled: true, | ||
| }, | ||
| { | ||
| id: 'email', | ||
| label: 'Email', | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,6 +28,7 @@ h1 { | |
| flex-direction: column; | ||
| justify-content: center; | ||
| align-items: flex-start; | ||
| position: relative; | ||
| } | ||
|
|
||
| .field label { | ||
|
|
@@ -153,3 +154,11 @@ h1 { | |
| width: 70%; | ||
| } | ||
| } | ||
| .upload{ | ||
| position: absolute; | ||
| top:0; | ||
| right: 0; | ||
| height: 100%; | ||
| color: blue; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
| font-weight: bold; | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -16,7 +16,10 @@ | |
| @helpMsg={{field.helpMsg}} | ||
| @onChange={{this.handleFieldChange}} | ||
| @validator={{field.validator}} | ||
| @disabled={{field.disabled}} /> | ||
| @disabled={{field.disabled}} | ||
| @buttonupload={{field.buttonupload}} | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we please follow CamelCase here? |
||
| /> | ||
|
|
||
| {{/each}} | ||
|
|
||
| <button class='submitButton' type="submit" {{on 'click' (fn this.handleSubmit)}}> | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this div
fieldfor each input, can we put a separate if statement which check if the field is location, and then renders a different form input which is inside a div and contains a buttonThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vinayak-trivedi If we are doing this it is breaking whole form css of the form