UNPKG

rete-kit

Version:

Rete.js Kit ==== [![Made in Ukraine](https://img.shields.io/badge/made_in-ukraine-ffd700.svg?labelColor=0057b7)](https://stand-with-ukraine.pp.ua) [![Discord](https://img.shields.io/discord/1081223198055604244?color=%237289da&label=Discord)](https://disco

36 lines (31 loc) 685 B
import { css, html, LitElement } from 'lit' export class CustomSocketElement extends LitElement { static get properties() { return { data: { type: Object } } } declare data: { name: string } static styles = css` :host { --socket-size: 16px; display: inline-block; cursor: pointer; border: 1px solid grey; width: var(--socket-size); height: calc(var(--socket-size) * 2); vertical-align: middle; background: #fff; z-index: 2; box-sizing: border-box; &:hover { background: #ddd; } } ` render() { return html` <div title="${this.data?.name}"></div> ` } }