4.1.0 • Published 2 years ago

@donkeyclip/motorcortex-typewriting v4.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

MotorCortex-TypeWriting

Table of Contents

Demo

Check it out here

Intro / Features

MotorCortex-TypeWriting, adds the type-writing effect to your clips.

This Plugin exposes one incidents:

  • TypeWriting

Getting Started

Installation

$ npm install @donkeyclip/motorcortex-typewriting
# OR
$ yarn add @donkeyclip/motorcortex-typewriting

Importing and loading

import { loadPlugin } from "@donkeyclip/motorcortex";
import TypeWritingDefinition from "@donkeyclip/motorcortex-typewriting";
const TypeWriting = loadPlugin(TypeWritingDefinition);

Creating Incidents

TypeWriting

const typewrite = new TypeWriting.TypeWriting(
  {
    css: `color:#37ff00;font-size:20px;font-weight:bold`,
    showCursor: true,
    cursorCss: "color:#37ff00;font-size:20px;font-weight:bold;",
    blinkDelay: 3000,
    blinkhiatus: 2000,
    text: `Wake up, Neo...`,
  },
  { selector: ".container" }
);

const typewriteOne = new TypeWriting.TypeWriting(
  {
    css: `color:#37ff00;font-size:20px;font-weight:bold`,
    showCursor: true,
    cursorCss: "color:#37ff00;font-size:20px;font-weight:bold;",
    blinkDelay: 3000,
    blinkhiatus: 2000,
    text: `The Matrix has you...`,
  },
  { selector: ".container" }
);

TypeWriting Attrs

NameDescriptionDefaultType
cssThe CSS for the text""string
cursorCssThe CSS for the cursor""string
showCursorShow or hide cursorfalseboolean
blinkDelayBlink cursor duration in milliseconds before start typing0number
blinkhiatusBlink cursor duration in milliseconds after end of typing0number
textThe text to be typed""string

Adding Incidents in your clip

clipName.addIncident(incidentName,startTime);

Contributing

In general, we follow the "fork-and-pull" Git workflow, so if you want to submit patches and additions you should follow the next steps: 1. Fork the repo on GitHub 2. Clone the project to your own machine 3. Commit changes to your own branch 4. Push your work back up to your fork 5. Submit a Pull request so that we can review your changes

License

MIT License

Sponsored by

4.1.0

2 years ago

4.0.0

2 years ago

3.0.3

3 years ago

3.0.2

3 years ago