New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

ts-tooltip

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-tooltip

tooltip package

latest
npmnpm
Version
1.0.6
Version published
Maintainers
1
Created
Source

ts-tooltip

Development based on webstorm2023 and volar plugin

Install

pnpm add ts-tooltip

Preview

color

Example

# main.js

// code...

import tooltip from 'ts-tooltip';
import 'ts-tooltip/dist/index.css';

app.use(tooltip);
<script setup lang="ts">
function onChange(show: boolean) {
  console.log('组件是否展示:', show)
}

function clickOutside(outside: boolean) {
  console.log('组件外发生点击:', outside)
}
</script>

<template>
  <div class="demo">
    <tooltip
      content="向上展示"
      @on-change="onChange"
    >
      <button>默认配置</button>
    </tooltip>
    
    <tooltip
      content="插槽优先级高"
      trigger="click"
      placement="bottom"
      @click-outside="clickOutside"
    >
      <button>嵌套扩展</button>
      <template #content>
        <ul class="selector">
          <li>请选择</li>
          <li>北京</li>
          <li>天津</li>
          <li>上海</li>
          <li>重庆</li>
        </ul>
      </template>
    </tooltip>
  </div>
</template>

Keywords

tooltip

FAQs

Package last updated on 05 Apr 2025

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