🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis
Socket
Book a DemoInstallSign in
Socket

uxcore-user-guide

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

uxcore-user-guide

uxcore-user-guide component for uxcore.

Source
npmnpm
Version
0.1.1
Version published
Weekly downloads
5
Maintainers
1
Weekly downloads
 
Created
Source

uxcore-user-guide

React user guide

NPM version build status Test Coverage Dependency Status devDependency Status NPM downloads

Sauce Test Status

Development

git clone https://github.com/uxcore/uxcore-aito-user-guide
cd uxcore-aito-user-guide
npm install
npm run server

if you'd like to save your install time,you can use uxcore-tools globally.

npm install uxcore-tools -g
git clone https://github.com/uxcore/uxcore-aito-user-guide
cd uxcore-aito-user-guide
npm install
npm run dep
npm run start

Test Case

npm run test

Coverage

npm run coverage

Demo

http://uxcore.alibaba.net/components/uxcore-aito-user-guide?type=others

Contribute

Yes please! See the CONTRIBUTING for details.

使用方法

一个产品或者页面中可能有多个引导,需要给每个引导做一个key

const UserGuide = require('uxcore-user-guide').getWithKey('guide-key', {
  // config here
  // prefixCls,
  // className
});

然后给这个引导添加步骤,每个步骤可以有4种选择

  • 使用React HOC
const Step1 = UserGuide.addUserGuide({
  dom: 'button',
  step: 1,
  hint: '我是第一步提示',
  type: 'ReactComponent',
});
  • 使用DOM
const Step1 = UserGuide.addUserGuide({
  dom: document.getElementById('app'),
  step: 2,
  hint: '我是第二步提示',
  type: 'HTMLElement',
});
  • 使用一个函数返回DOM
const Step1 = UserGuide.addUserGuide({
  getDom() { return document.getElementById('app'); },
  step: 3,
  hint: '我是第三步提示',
  type: 'HTMLElementMaker',
});
  • 使用图片
UserGuide.addUserGuide({
  step: 4,
  hint: '我是第四步的提示,我也没有对应的DOM',
  type: 'Image',
  top: 1800,
  left: 1000,
  image: 'https://img.alicdn.com/tfs/TB1TRNAllfH8KJjy1XbXXbLdXXa-240-240.png',
  imageHeight: 120,
  imageWidth: 120,
});

需要开始引导时,需要

UserGuide.start('guide-key');

Keywords

react

FAQs

Package last updated on 08 Aug 2018

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