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

Component: InputSwitch | Not getting circular border #15214

Closed
jaygajera17 opened this issue Apr 2, 2024 · 1 comment
Closed

Component: InputSwitch | Not getting circular border #15214

jaygajera17 opened this issue Apr 2, 2024 · 1 comment
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible

Comments

@jaygajera17
Copy link

Describe the bug

Not getting circular border in input switch primeng component
image

Environment

Linux

Reproducer

No response

Angular version

17.3.2

PrimeNG version

17.10.0

Build / Runtime

Angular CLI App

Language

TypeScript

Node version (for AoT issues node --version)

21.7.1

Browser(s)

No response

Steps to reproduce the behavior

  • write the same code as mention in documentation
    .html:
    <p-inputSwitch [(ngModel)]="checked"></p-inputSwitch>

  • .ts:
    checked: boolean;

Expected behavior

circular border and circle should be visible as visible in the documentation
image

@jaygajera17 jaygajera17 added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Apr 2, 2024
@jaygajera17 jaygajera17 changed the title Component: InputSwitch Component: InputSwitch | Not getting circular border Apr 2, 2024
@jaygajera17
Copy link
Author

solved this by overriding the styles:

:host {
  ::ng-deep p-inputswitch .p-inputswitch-slider {
    border-radius: 30px;
  }
  ::ng-deep p-inputswitch .p-inputswitch-slider::before {
    border-radius: 50%;
  }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
Projects
None yet
Development

No branches or pull requests

1 participant