Questions tagged [lightninginput]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1
vote
1answer
27 views

Radio button requires two clicks to “check” even though conditional template renders

I am working on a component that has a simple 2 option radio group. I want to show and hide a div (template if:true) based on the selected radio option. What I have here almost works but I have to ...
0
votes
0answers
22 views

updateRecord working very slow/inconsistently on conditional input text

I have an lightning-input text box and I'm trying to add the input value to one of multiple fields using updateRecord of the uiRecordApi, depending on if it has a value already or not. It either works ...
1
vote
1answer
19 views

Pass Lightning input iteration value by index of String array

I have a lightning component where I dynamically generate some columns and some input fields. I have a String Array as attribute. How do I get the index of the array to pass the value. I tried below ...
2
votes
0answers
25 views

Aura component and LWC are not supporting Nepal locale

I have a requirement where I need to show date in Nepal locale in both Lightning Web and Aura components. This shows the date in, for example - २०२१/२/१७ format in Salesforce but on LWC and Aura, it ...
0
votes
1answer
47 views

lightning:input type=“time” displays millisecond value when editing object

I am building a lightning component to create/edit custom objects. I've been able to do this with force:inputFields in the past but unfortunately ran into a component error that the new recommended ...
1
vote
1answer
213 views

Clearing validation errors on clicking clear filters icon not working on LWC lightning-input

The validation errors are cleared only on the second click of the button. But i need this to be working on the first click. Kindly help. My current code is as follows : HTML CODE : <div class="...
2
votes
1answer
488 views

Lightning-input currency not working properly as of Spring 20'?

Hi I refreshed my org in order to have the latest changes from Spring 20' release, and I noticed a change in the input type currency when I try to type the decimal value separated by a dot ('.'), it's ...
0
votes
0answers
5 views

Community Screen Flow Date Input Error Message wrong?

A client I am working with has a 'registration' screen flow that captures customer information and is on a Salesforce Community behind a login wall. For some reason the Date Input shows a funky error ...
0
votes
1answer
13 views

lightning:input update time value

I have two time inputs for start and end times: <lightning:input type="time" name="startTime" label="Start Time" min="05:30:00.000Z" max="19:00:00.000Z&...
0
votes
2answers
37 views

lightning-record-edit-form with lightning-input-address show-address-lookup to true to create an Address record

I am creating a custom LWC component to create a new Address record. I've used the lightning-record-edit-form like below, <template> <lightning-record-edit-form record-id={currenRecordId} ...
0
votes
0answers
15 views

Highlight the Validation Error on the corresponding Field

Can anyone tell how the implementation of highlighting the validation error at field level can be achieved using Lightning Aura Components? I have tried using validity functionality option in my code ...
0
votes
1answer
39 views

Understanding regex behavior with Lightning Input [closed]

I'm new with all the LWC topic. But for now I'm having issues with some regex. To Begin with I have my own LWC created with a few fields some of them are type number such this one: <lightning-input ...
2
votes
1answer
1k views

Question about pattern of lightning:input

how i can have a field (lightning:input) in which i can write 3 integer and 3 decimal? Something like 123.456 (max 3 integer and max 3 decimal, with "." or "," between integer and decimal). I try to ...
1
vote
1answer
9k views

Using lightning:input with type=“number” and formatter=“currency”

Is there a way to use lightning:input with formatter="currency" to show whole number instead of Decimal number <lightning:input aura:id="{!item.Id + 'CY_Tile_Budget__c' }" type="number" name="...
14
votes
1answer
472 views

Cannot read property '$$OwnerKey$$' of null

I have a Visualforce Lightning Out page that's rendering some <lightning:input type="date"> elements. Since the Winter '19 release in the dev sandbox I'm working in, whenever I select a date ...
0
votes
1answer
67 views

how to manipulate lightning:input type=“toggle” so that it worked as a Radio button

I want a controller logic for aura component so that my lightning:input type="toggle" worked as a radio button. <aura:component> <aura:iteration items="{!v.ebpEmpType}"...
0
votes
3answers
2k views

Make lightning:inputRichText length longer

Is there a way for the lightning:inputRichText to make its size and length longer? Updated: I've already put a style of .THIS .lightningInputRichText { height: 500px; } But as you can see, ...
1
vote
1answer
19 views

Is there a way to make the lightning-input placeholder text appear smaller

I'd like to make the placeholder text to appear smaller in the lightning-input component. Is it possible? and if yes, how can I achieve that? Thanks!
0
votes
2answers
1k views

Unable to set Text Alignment for lightning-input (Number) LWC component

I am using lightning-input of type number (LWC) and trying to have input text center aligned. At the end, element's class is being set to "slds-input", So I cannot use custom class to add css. I am ...
1
vote
5answers
3k views

Change the color of Lightning-input label

I have below code for input text <lightning-input label="Email" class="textInput" value={rec.Name} onchange={handleNameChange}></lightning-input> Here I want to change the color of the ...
0
votes
1answer
35 views

Display lightning-icon in lightning-input and add onclick action

I'm trying to add icon inside input and that's fine, but when i try to add some action like onclick it doesn't work. On front when i try to click on the icon i can not do this, cuz input hover it ;/ &...
0
votes
1answer
18 views

lightning-input loses alignment on display of error/validation msges with other form elements

Trying to make this work <template> <p>This example creates a simple layout with field headers.</p> <lightning-layout vertical-align="end" class="slds-form&...
1
vote
2answers
111 views

Are pre built lightning web components (example lightning-input) available for use in open source?

I just tried using LWC on my local, but not able to use <lightning-input />. Is it available for open source? Is there any way to bring prebuilt lightning web components with lightning namespace ...
0
votes
0answers
39 views

LWC lightnig input type date max value dynamically

LWC lightnig input type date max value dynamically I'm trying to add max Date as 2 years from now. Getting the error ass add_years is not defined Any suggestion would be great.. Html: <lightning-...
0
votes
0answers
59 views

Style lightning-input like lightning-input-field

I'm using lightning-inputs in the middle of my record-edit-form to provide greater flexibility. Unfortunately their styling is different than that of the lightning-input-field which means they are not ...
2
votes
1answer
238 views

Restrict past dates in lightning-input

I would like to block my user from selecting a date that happened in the past in a lightning-input of type date. For this I would like to use the min attribute of the type date. This is the html code ...
0
votes
0answers
23 views

Email pattern not working

Hi this pattern is not working in an Aura component and i've no idea why... <lightning:input aura:id="Eemail" name="email" value="{!v....
0
votes
1answer
28 views

optional file upload in <lightning:input …> [closed]

I'm using <lightning:input ... type="file"> to allow file upload on the UI. Is there any way I could make it optional in the component itself? instead of taking care of the check ...
8
votes
1answer
2k views

How to handle percentage factor of 100 problems when using lightning:input and lightning:datatable?

When working on a bug, I just noticed that lighting:input now supports two percentage formatters, where the older one percent expects the user to know to enter e.g. 0.5 for 50%: <lightning:input ...
0
votes
1answer
366 views

Get value of lightning-input and lightning-combobox from for loop in LWC

I am displaying data in LWC from an array in a for loop. The loop is using both lightning-input and lightning-combobox for inputs. <template for:each={tobeOppProduct} for:item="data"> ...
1
vote
0answers
114 views

lightning input type = date, max attribute behaviour not similar in production and lower enviornment

I used max attribute of lightning input type date to disable the future dates in date picker. It was working in lower environments, but not working in production. In Lower Environments: It shows the ...
0
votes
0answers
22 views

switching from force:input to lightning:input causing styling and functionality errors

switching from force:input to lighting:input and have run into a few errors. first, my styling is off and I'm not sure why. here's my code for these sections- <div class="slds-grid"> ...
1
vote
1answer
254 views

How to allow decimal input whose number of decimal places is lower than the step value of input component

I have a lightning input component with the attributes as type="number", formatter="decimal",and step="0.01". However, this seems to restrict the decimal input to be of exactly 2 decimal places. Is ...
0
votes
1answer
236 views

Drag Drop from Popup not working on Mozilla Firefox and Internet Explorer for lightning-input type=“file” in LWC

I have the following code for File input in LWC. The drag-drop works fine for chrome, edge browser. But for Mozilla Firefox browser and Internet Explorer, If we select the button and open the popup ...
0
votes
1answer
155 views

Changing the UI and text display of lightning-input type=“file”

I want to change the UI of lightning-input type=" file". Current UI Look something like this: But, I want the UI to be something like this: Is it possible to change the styling and apply ...
0
votes
0answers
223 views

Reset invalid value in lightning-input date to a blank value on click of a button

I have a lightning-input of type date. When I enter an invalid value in this field, there is a validation displayed 'Your entry does not match the allowed format MMM d, yyyy.' I want to clear this ...
1
vote
1answer
62 views

lightning-input of type “toggle” - any way to change the Inactive/Active text?

For this component:: <lightning-input type="toggle" ...></lightning-input> the "Inactive" and "Active" text appears to be fixed: Is it? Is coding this up ...
0
votes
0answers
130 views

LWC styling for iOS - lightning input is going off the screen

I've experienced a strange problem on Salesforce app for iOS. I have LWC component with searchbox. It's a standard lightning-input and search result list as an ul element with li as options. On ...
0
votes
1answer
291 views

Get final Lightning input value in LWC JS

I have a lightning-input tag in my LWC HTML file and i want to get the final value of the text which user inputs. I have a onchange event but it gives me value on every change. for eg. if the user ...
0
votes
0answers
16 views

Get all lightning inputs with given type

Is it possible to access all of the lightning inputs of given type? I mean something more generic than getting them by aura:id
0
votes
0answers
88 views

Dropdown is not getting close in the Lightning Input box in LWC

Hi I have created the lightning input box which contains some value as a drop down but when i am clicking outside of the drop down anywhere on the page the values which are appearing as a drop down is ...
0
votes
1answer
270 views

Reformat LWC (Lightning Web Component) Input to Credit Card formatting

I have a Lightning Input that when a user types into I would like it to be reformatted to mirror CC Credit Card formatting. For example when I type in 1234567812345678 it updates as the user is typing ...
0
votes
0answers
153 views

Focusing on first lightning input with error in LWC

I have number of Lightning input fields in my component. If there is any error in input from user, On submit of form, I want to move the focus onto the first erroneous Lightning input. In the ...
1
vote
1answer
181 views

How to display account address field values in lightning:component

I'm having a custom lookup input field in my custom lightning component. When I select a contact from that lookup, it should display its related account field values like account name, account type ...
1
vote
1answer
249 views

Upload an image in lwc rich text component doesn't work

I'm using a lightning-input-rich-tex base component and I'm trying to upload an image but it doesn't work Code <lightning-input-rich-text formats={formats} ...
8
votes
4answers
21k views

Lightning:input type=“date”: how to change the date fomat - Summer'18

I'm trying to change date format of this component but I dont find any attribute (like ui:inputDate has) to change the date format. <lightning:input type="date" name="input8" label="Dates" value="...
2
votes
1answer
836 views

Issue with Lightning:input and currency formatter

I'm creating a lightning component with a lightning:input, but I have an issue with decimal places and currency formatter. This is my code: <lightning:input name="foo" value="foo" type="number" ...
0
votes
1answer
108 views

Accessing the string value of a date-type lightning-input

We're using the onchange event on text-type lightning-input components to apply formatting, so users can quickly enter numbers and have the punctuation applied automatically. For instance, a Social ...
0
votes
2answers
168 views

value not retaining when showing a different template

I am very new to LWC. And i am confused about why value is not coming in input text when i am going back to the same div(template). <template> <br/> <br/> <template if:true={...
0
votes
3answers
149 views

Disable a toggle if is checked

Is it possible to disable a toogle if is checked ? <lightning:input type="toggle" name="togglevalue" checked="false" messageToggleActive="ok" messageToggleInactive="not ok" disabled="{!if ...