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

Angular support for reactive forms #8249

Closed
2 of 6 tasks
martinbojnansky opened this issue Nov 22, 2023 · 4 comments
Closed
2 of 6 tasks

Angular support for reactive forms #8249

martinbojnansky opened this issue Nov 22, 2023 · 4 comments
Assignees
Labels
1 - assigned Issues that are assigned to a sprint and a team member. enhancement Issues tied to a new feature or request. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive spike Issues that need quick investigations for time estimations, prioritization, or a quick assessment.

Comments

@martinbojnansky
Copy link

Check existing issues

Description

When it comes to Angular, it would be great to add support for native reactive forms. Reactive forms are used to write dynamic forms with two-way data bindings, validations and more.
It is quite simple to extend the stencil generated directives and I made an example for couple of components I used already.

Acceptance Criteria

Components that are used for user input should:

  1. Implement ControlValueAccessor interface.
  2. Update its value on form value change.
  3. Emit "touched" event on blur and value change.
  4. Emit "changed" event, so the form value is updated.
  5. Be enabled/disabled when form value is enabled/disabled.

Relevant Info

I (reporter) would be willing to work on this and support the implementation with unit tests.

Which Component

  • Checkbox
  • ColorPicker
  • Combobox
  • DatePicker
  • Input
  • PickList
  • RadioButton
  • RadioButtonGroup
  • Rating
  • SegmentedControl
  • Select
  • Slider
  • TileSelectGroup

Example Use Case

<form [formGroup]="form">
  <calcite-label>
    ...
    <calcite-input-text
      [formControl]="form.controls.text"
    ></calcite-input-text>
    <calcite-input-message
      *ngIf="form.controls.text.invalid"
      icon="frown"
      status="invalid"
    >
      Title must be at least 5 characters long.
    </calcite-input-message>
  </calcite-label>
</form>

Priority impact

p4 - not time sensitive

Calcite package

  • @esri/calcite-components
  • @esri/calcite-components-angular
  • @esri/calcite-components-react
  • @esri/calcite-design-tokens
  • @esri/eslint-plugin-calcite-components

Esri team

N/A

@martinbojnansky martinbojnansky added 0 - new New issues that need assignment. enhancement Issues tied to a new feature or request. needs triage Planning workflow - pending design/dev review. labels Nov 22, 2023
@github-actions github-actions bot added impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive calcite-components-angular labels Nov 22, 2023
@geospatialem geospatialem added the spike Issues that need quick investigations for time estimations, prioritization, or a quick assessment. label Nov 22, 2023
@geospatialem geospatialem removed the needs triage Planning workflow - pending design/dev review. label Nov 22, 2023
@geospatialem
Copy link
Member

A spike will be conducted in early 2024, however @martinbojnansky we'd love your expertise if you are willing to tackle this prior to the new year, too. Thanks for filing! 💪🏻

@geospatialem
Copy link
Member

geospatialem commented Sep 13, 2024

Blocked by #10310

@benelan
Copy link
Member

benelan commented Nov 6, 2024

Closing this as unplanned.

We are migrating from Stencil to Lit, which doesn't provide the same tools for creating Angular wrapper components. Therefore, the @esri/calcite-components-angular package is being removed as part of the upcoming v3 breaking change release.

For reference, the angular example has been updated to use @esri/calcite-components directly.

@benelan benelan closed this as not planned Won't fix, can't repro, duplicate, stale Nov 6, 2024
Copy link
Contributor

Issue #10310 has been closed, this issue is ready for re-evaluation.

cc @geospatialem,@DitwanP

@github-actions github-actions bot removed the blocked This issue is blocked by another issue. label Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1 - assigned Issues that are assigned to a sprint and a team member. enhancement Issues tied to a new feature or request. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive spike Issues that need quick investigations for time estimations, prioritization, or a quick assessment.
Projects
None yet
Development

No branches or pull requests

3 participants