Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@omnedia/ngx-gradient-text

Package Overview
Dependencies
Maintainers
0
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@omnedia/ngx-gradient-text

A simple component library to animate text.

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
13
increased by18.18%
Maintainers
0
Weekly downloads
 
Created
Source

ngx-gradient-text

@omnedia/ngx-gradient-text is an Angular library that provides a dynamic gradient animation effect for text. This component allows you to display text with a smooth, animated gradient that transitions between two customizable colors.

Features

  • Animated gradient effect for text.
  • Customizable gradient start and end colors.
  • Lightweight and easy to integrate as a standalone component.

Installation

Install the library using npm:

npm install @omnedia/ngx-gradient-text

Usage

Import the NgxGradientTextComponent in your Angular module or component:

import { NgxGradientTextComponent } from '@omnedia/ngx-gradient-text';

@Component({
  ...
  imports: [
    ...
    NgxGradientTextComponent,
  ],
  ...
})

Use the component in your template:

<om-gradient-text
  [text]="'Gradient Text Effect!'"
  [gradientStart]="'#ff7f50'"
  [gradientEnd]="'#6495ed'"
  styleClass="custom-gradient-text"
></om-gradient-text>

API

<om-gradient-text
  [text]="text"
  [gradientStart]="gradientStart"
  [gradientEnd]="gradientEnd"
  styleClass="your-custom-class"
></om-gradient-text>
  • text (required): The text content to be displayed with the gradient effect.
  • gradientStart (optional): The starting color of the gradient. Accepts any valid CSS color value.
  • gradientEnd (optional): The ending color of the gradient. Accepts any valid CSS color value.
  • styleClass (optional): A custom CSS class to apply to the gradient text element.

Example

<om-gradient-text
  [text]="'Hello World!'"
  [gradientStart]="'#ff69b4'"
  [gradientEnd]="'#8a2be2'"
  styleClass="gradient-text-style"
></om-gradient-text>

This will create an animated gradient text effect where the text "Hello World!" smoothly transitions between pink and blue-violet.

Styling

To customize the appearance of the gradient text, use the styleClass input to apply your own CSS classes.

.gradient-text-style {
  font-size: 48px;
  font-weight: bold;
  font-family: 'Verdana', sans-serif;
}

This will style the gradient text with a custom font size, weight, and font family.

Contributing

Contributions are welcome. Please submit a pull request or open an issue to discuss your ideas.

License

This project is licensed under the MIT License.

Keywords

FAQs

Package last updated on 20 Aug 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc