Questions tagged [angular-formly]
angular-formly is an AngularJS module which has a directive to help customize and render JavaScript/JSON configured forms. The formly-form directive and the formlyConfig service are very powerful and bring unmatched maintainability to your application's forms.
440
questions
0
votes
0
answers
21
views
JSON Powered Formly Form - Conditionally disabling form fields without using expressionProperties or parsing the entire form object [closed]
I have a fairly complex Formly form that's generated via JSON. There are several fields that need to conditionally be disabled (or required) depending on formState. Previously I was using ...
0
votes
0
answers
21
views
Ng-Mask with formly for SSN in Angular
Basically I'm trying to populate hyphens in ssn and also trying to mask first 5 numbers with *.
Output expected
SSN Formly
I have built a custom type called mask and also given maskstring. You can ...
0
votes
0
answers
16
views
Autosaving working for entire form, only need to autosave after selecting a component in form
I have an Angular form that is saving the entire form instead of one component (Copy Schedule from Site) in the form. Is there a way to do that? My form setup is using formly in typescript and the ...
1
vote
1
answer
84
views
How to hide fields of Formly form, due another model's fields
I have 2 Formly forms in my app.
I need to hide a field of one form, due the value of a field in the another one.
Formly documentation gives this option (https://formly.dev/examples/field-options/hide-...
0
votes
0
answers
49
views
how can I enable only certain dates with formly date-mask
We are working on an Angular application that uses formly forms. I have a requirement to create a date-mask or datemask-input field that, under certain conditions, the user can select only the first ...
1
vote
0
answers
109
views
how to add icon button and click event in formly form for material UI?
I have a select field which contains file name, i want a eye button above select field on right.
I am using formly form and UI is angular material. how can i add eye button on right side above select ...
0
votes
0
answers
45
views
We are using Material UI for the whole Angular project, can we use Formly with Bootstrap UI ? Does it create any problem?
We are using Material UI for the whole Angular project. Now we have to use Formly (https://formly.dev/) for forms. Can I use bootstrap theme in my project for styling the form fields ?
0
votes
0
answers
147
views
Angular Formly - Clearing Array Property of Model Based on Value of Another Field
I am using Formly for Angular in my app. The model of the form looks like this:
// ins-submission.ts
export class InsSubmission {
id: number | undefined;
empID: string = "";
...
0
votes
0
answers
50
views
has-error not removed for fields having ng-touched class when removing validator using clearValidators()?
Dependencies used
"@angular/cli": "^11.2.10",
"@ngx-formly/bootstrap": "^5.10.22",
"@ngx-formly/core": "^5.10.22"
There is an issue with ...
0
votes
0
answers
140
views
ngx-formly queries related to expression properties
In our angular application we are using the ngx-formly version 5.10.23
I have few question related to that
Are formly fields rendered synchronously? If it is happening asynchronously can we make this ...
0
votes
0
answers
26
views
How to add sorting and searching functionality in dynamically added table using ngx-formly in angular
I have just started using ngx-formly and added some dynamic controls to a page. I was wondering if there is a way to add sorting and searching functionality on a table dynamically created using ...
0
votes
0
answers
83
views
Disabled checkbox(es) in Angular formyl
How can I disable the checkbox without displaying this warning message?
"It looks like you're using the disabled attribute with a reactive form directive.
If you set disabled to true. when you ...
-1
votes
1
answer
125
views
Angular Formly - Focus on the first editable element
In our project, we used Angular Formly to generate complex forms (with complex grouping). I checked the component documentation, but I couldn't find any sample or solution for finding the first ...
1
vote
0
answers
109
views
how to get which field clicked in formly-form?
I have a formly-form with icon addon wrapper. i want to get fields value when user clicked icon of that field.
Look in Addon wrapper there is icon and onClick call showFile funtion and there want to ...
0
votes
0
answers
34
views
How to set max value dependent on other fields in Angular Formly?
I have two fields, e.g. x and y. I want the third field to have max value set to sum of the others. How to achieve this? max option doesn't work with this expression
{
"className"...
0
votes
0
answers
57
views
How to focus first invalid ngx-formly field
I am using ngx-formly for creating dynamic form from field configuration. On submitting form, validation is showed correctly. I want to focus first invalid formly field.
0
votes
0
answers
66
views
Angular Formly options value causes Placeholder bug
My options dropdown has a boolean value in this Formly field. Whenever the value is false, this causes the placeholder and the options label to be overlayed over each other.
I don't have this issues ...
0
votes
1
answer
35
views
JSON value into FormlyFirldConfig of Formly Form
I am trying to add a json file formatted to fit the formlyconfig file but unable to do so
Here is my HTML
<div class="row">
<div class="col-md-4 mb-4">
<...
0
votes
0
answers
34
views
Get field key inside bootstart resultFormatter ngx-formly custom field
I have created a custom type for my autocomplete field, which is using bootstrap typeahead. This is to search for say "users".
This class extends FieldType and works perfectly.
Now, I want ...
0
votes
0
answers
262
views
ngx formly: how to add onchange event to each field inside array type in json schema
I have a requirement like one item depends on other item inside array type field config.
I am adding a change event to one field dynamically but its not adding. Code is like below, when I am adding ...
0
votes
0
answers
164
views
JSON Schema / Formly dependent sub-schemas
This issue is a bit tricky to describe so bear with me and please ask questions if I am missing anything...
Say you have a json object that defines a list of features, each feature has a the same ...
0
votes
0
answers
39
views
matDatePicker in angular formly description hiding when we clear the input
I am using matDatePicker in my angular formly. Here is its formlyFieldConfig
type: 'matDatepicker',
key: 'dateOfPurchase',
defaultValue: new Date(),
templateOptions: {
...
0
votes
0
answers
71
views
Custom Model in Formly
Is it possible to have a custom formly model?
For example, for the following formly config:
[
{
"key": "g1",
"type": "repeat",
"...
1
vote
0
answers
68
views
Ion-select multiple options but with one exclusive options
So I would like to create a ion-select with multiple options but with one option that is exclusive.
Example :
In this image, if I select Nowhere the other options deselect themselves and if I select ...
0
votes
0
answers
266
views
Angular Formly File Upload - File Path, Not Contents Being Displayed
I am attempting to build a form that allows for file uploads using Angular (v12) and Formly (v5). I have referenced Formly File Input example and implemented my solution accordingly.
In app.module the ...
2
votes
0
answers
97
views
Why formly-field doesn't render the component?
I made input component and render component in formly.
This is simple thing: the app component is render the render-component and render-component is render the input component.
But the input ...
0
votes
0
answers
91
views
Creating a formly form inside of a ngb-modal
The form displays anywhere outside the modal window but disappears once in the modal. I reckon I'm supposed to call it, but how?
The Modal Window:
open(content) {
this.modalService.open(content, {...
0
votes
0
answers
98
views
How to create custom ngx formly component to support a multivalue autocomplete component
I'm working on an app that needs to support multivalue component in angular formly.
I'm creating a custom component which uses an autocomplete with chips to show the multiple values selected/entered.
...
0
votes
1
answer
361
views
How to change color of Angular Formly description?
I am working with angular formly.
Here below is the Image of the Input Field and Its description.
What issue I am facing?
Initially the description attribute have some default color but I want to ...
0
votes
0
answers
43
views
Is it possible to have a "warning" level validation using Angular Formly?
When using Formly, I would like to display a warning message under a field, but not mark the field as errored.
I haven't been able to find any documentation on how to achieve this.
Is it possible? If ...
0
votes
0
answers
31
views
Angular formly- what is the difference between expressionProperties and hideExpression
I have a scenario for clicking the chick box to show and hide the text field based on the check box value. my question is what is the difference between this two code
expressionProperties: {
'hide':...
0
votes
0
answers
84
views
How to create stepper forms using angular formly
I need to create reactive angilar forms using FormlyConfig, based on the router params(travel-information, immigration) i need to create dynamic forms and final submission need to pass the model value....
0
votes
1
answer
50
views
Force other components to run (change) before my button's (mousedown)
I have a button on formly with mousedown that has a method called "analyzeClick()"
<button *ngIf="show" (mousedown)="analyzeClick()" id={{htmlID}}>
{{label}}
<...
1
vote
1
answer
566
views
How to unit test ngx-formly?
I am trying to unit test ngx formly but I am getting the following error:
[Formly Error] The validator "emailValidator" could not be found.
Please make sure that is registered through the ...
1
vote
0
answers
25
views
How to create a custom typeahead using angular-formly which should be generic, any suggestions?
I am new to formly, I tried creating typeahead but got stuck. Please help me out in creating typeahead.
0
votes
0
answers
41
views
Why is TypeScript not setting JSON response data to model for some fields when using Spring Boot REST Back end
I am working in application. Where I am using Angular 8 in front with fromly, Spring Boot in Back End.
model = {
id: null,
nameEn: null,
nameBn: null,
locationEn: null,
...
1
vote
0
answers
111
views
How to translate the Month and Day in Date-picker pop-out calendar for Angular Formly?
I have integrated Date picker into my angular version 8 and it is working as expected. My form uses internationalization to which ngx-formly supports with the help of ngx-translate. I would like to ...
0
votes
1
answer
383
views
Angular-Formly - Access Model names for calculated fields with key names containing dot(.)
I have a config json with 3 fields, the 3rd field being a calculated field from data in the previous 2 fields.
Now the catch here is I have dot(.) in their key names. e.g. "something.someone"...
0
votes
1
answer
93
views
angular, Java : HTTP request not going to server, while URL is valid
I am working in an application : Java Backend and Angular frontend. I am using angular Fromly, data is coming to service, but from the service it is not going to server.
lets share the code snipts:
...
0
votes
0
answers
65
views
Formly Form loading hanging site performance
I have implemented complex custom wrapper.
If the FORM contain 10+ custom wrapper it is hanging HTML UI page for some seconds.
For example when ng-if is true, 5+ seconds HTML hanged.
<form [...
1
vote
0
answers
94
views
Why hintEnd not render in formly with material?
I try to use the hintEnd from material with formly option:
<mat-hint *ngIf="to.hintEnd as hintEnd" align="end">
<ng-container [ngTemplateOutlet]="stringOrTemplate&...
-2
votes
1
answer
495
views
How can we create JSON schema to build a angular formly based forms on basis of plain JSON?
We have a requirement in which we are planning to build a form according to the JSON received and convert it to JSON schema which is supported by formlyJsonschema, is there any way of achieving this?
...
0
votes
0
answers
106
views
How to include the leaflet map in angular formly with custom component
I have to create the leaflet map where I have used the angular formly .
and I have created the custom component for leaflet map as
leaflet.component.ts
import { Component, OnInit } from '@angular/core'...
0
votes
0
answers
121
views
How to integrate the leaflet map in angular
I want to show the leaflet map in angular application
As I have used the angular formly for application with tabs because In my application I have to create the dynamic forms
In third tab I have to ...
0
votes
1
answer
253
views
How to create a custom validadtion in formly with calendar
I implemented a calendar, create a custom template but i i dont have idea how to create, validators nad message.
I see a lot of examples with input but not elemente wasn't input.
app.modules.ts
...
0
votes
2
answers
766
views
Angular 12 lazy loading module with Formly
I have problem with lazy loading module. Every time when I want to do it Formly thow me Error
ERROR Error: [Formly Error] The type "input" could not be found. Please make sure that is ...
0
votes
1
answer
141
views
How to create the leaflet map in angular formly
My requirement is to create the leaflet map in angular formly,but I am new to this formly
and I know how to use integrate the map with normal html in angular as below
map.component.ts
ngOnInit() {
...
0
votes
2
answers
749
views
how place the select (dropdown) elements from backend in angular formly
I am new to the angular formly .My requirement is to place the cities (coming from the backend )in dropdown but I have tried but I am unable to do this.
.service.ts
getcitiNames(): Observable<any&...
1
vote
1
answer
425
views
Bind to template of formly field on click of other field in angular formly
I have been using a formly form that has a section in which I display dynamic HTML, I made use of the template field in which I am initializing HTML on load. When I click the other field value I need ...
0
votes
1
answer
181
views
Angular 10 Formly + material vertical multicheckbox
I want to create formly multicheckbox with a vertical view. But when I created a field like this I still display it same line.
{
label: 'Zgody marketingowe',
fields: [
{
key: '...