Skip to content

Component: colorPicker - inline=true property doesn't set the appropriate color #16169

@vmuresanu

Description

@vmuresanu

Describe the bug

When setting inline = true to p-colorpicker, the colorpicker defaults to black.

Environment

Mac OS

Reproducer

https://stackblitz.com/edit/github-4fz6wx-5sc5by?file=src%2Fapp%2Fapp.component.ts,src%2Fapp%2Fapp.component.html

Angular version

17.3.4

PrimeNG version

17.13.0

Build / Runtime

Angular CLI App

Language

TypeScript

Node version (for AoT issues node --version)

22.0.0

Browser(s)

No response

Steps to reproduce the behavior

  1. Set <p-colorPicker [inline]="true" /> and attach a reactive form control to it
  2. Default the control to some hex value
  3. Render the app

Expected behavior

  1. Colorpicker has to be defaulted to the specified color

ACTUAL Behavior:

  1. Colorpicker default to black color

NOTE: With inline = false or with ngModel + inline true - colorpicker works as expected

Metadata

Metadata

Labels

LTS-PORTABLEIssue's fix will be ported to supported LTS versionsType: BugIssue contains a bug related to a specific component. Something about the component is not working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions