Socket
Socket
Sign inDemoInstall

@moefy-canvas/theme-meteor

Package Overview
Dependencies
3
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @moefy-canvas/theme-meteor

<img alt="npm" src="htt


Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

@moefy-canvas/theme-meteor

type npm downloads downloads GitHub license

:stars: 晃动下鼠标~

Install

pnpm add @moefy-canvas/theme-meteor

Usage

<canvas id="moefy-canvas"></canvas>
import {
   Meteor,
   type MeteorConfig,
   type CanvasOptions,
   MAX_Z_INDEX,
} from '@moefy-canvas/theme-meteor'

const themeConfig: MeteorConfig = {
   numParticles: null,
   particleColor: {
      light: 'rgba(102, 175, 239, .2)',
      dark: 'rgba(245, 236, 66, .2)',
   },
}

const canvasOptions: CanvasOptions = {
   opacity: 1,
   zIndex: MAX_Z_INDEX,
}

const el = document.getElementById('moefy-canvas')
const meteor = new Meteor(themeConfig, canvasOptions)
meteor.mount(el as HTMLCanvasElement)

ThemeConfig

export interface ColorTheme {
   light: string
   dark: string
}

export interface MeteorConfig extends ThemeConfig {
   numParticles?: number | null
   particleColor?: string | ColorTheme
}

Keywords

FAQs

Last updated on 12 Sep 2022

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc