open-index/open-npm huggingface dataset:
npm package: @signalplus/params-about
Description: A description for the module
Author: 2631541504@qq.com
Latest version: 1.0.26

# @signalplus/params-about

[![NPM Version](http://img.shields.io/npm/v/@signalplus/params-about.svg?style=flat-square)](https://www.npmjs.com/package/@signalplus/params-about) [![Download Month](http://img.shields.io/npm/dm/@signalplus/params-about.svg?style=flat-square)](https://www.npmjs.com/package/@signalplus/params-about) ![gzip with dependencies: kb](https://img.shields.io/badge/gzip--with--dependencies-kb-brightgreen.svg 'gzip with dependencies: kb') ![typescript](https://img.shields.io/badge/typescript-supported-blue.svg 'typescript') ![pkg.module](https://img.shields.io/badge/pkg.module-supported-blue.svg 'pkg.module')

> `pkg.module supported`, which means that you can apply tree-shaking in you project

[中文文档](./README-CN.md)

A description for the module

## repository

## Demo

## Run Example

you can see the usage by run the example of the module, here is the step:

1. Clone the library `git clone `
2. Go to the directory `cd [the-module-directory]`
3. Install npm dependencies `npm i`(use taobao registry: `npm i --registry=http://registry.npm.taobao.org`)
4. Open service `npm run dev`
5. See the example(usually is `http://127.0.0.1:3000/examples/test.html`) in your browser

## Installation

```bash
npm i -S @signalplus/params-about
```

## Global name - The variable the module exported in `umd` bundle

`ParamsAbout`

## Interface

See what method or params you can use in [index.d.ts](./index.d.ts)

## Usage

```js
import * as ParamsAbout from '@signalplus/params-about';
```

## CDN

Use in html, see what you can use in [CDN: unpkg](https://unpkg.com/@signalplus/params-about/lib/umd/)

```html
<-- use what you want -->
<script src="https://unpkg.com/@signalplus/params-about/lib/umd/<--module-->.js"></script>
```

Or，see what you can use in [CDN: jsdelivr](https://cdn.jsdelivr.net/npm/@signalplus/params-about/lib/umd/)

```html
<script src="https://cdn.jsdelivr.net/npm/@signalplus/params-about/lib/umd/<--module-->.js"></script>
```

## style

For building style, you may need to import the css or scss file:

```js
// scss
import '@signalplus/params-about/lib/css/index.scss';

// css
import '@signalplus/params-about/lib/css/index.css';
```

Or

```scss
// scss
@import '~@signalplus/params-about/lib/css/index.scss' // css
  @import '~@signalplus/params-about/lib/css/index.css';
```

Or, you can build your custom style by copying, editing and importing `node_modules/@signalplus/params-about/lib/css/index.scss`

## QA

1. Error `Error: spawn node-sass ENOENT`

> You may need install node-sass globally, `npm i -g node-sass`
npm package: @signals-protocol/v1-sdk
Description: Signals v1 SDK for CLMSR market calculations and utilities
Author: Signals Team
Latest version: 1.3.0

# Signals v1 SDK

Contract-aligned TypeScript SDK for Signals v1 CLMSR market math. Quote open and
close costs, compute inverse quantities, and map subgraph data into calculation
types.

## Install

```bash
npm install @signals-protocol/v1-sdk
```

## Quick start

```ts
import {
  CLMSRSDK,
  mapMarket,
  mapDistribution,
  toMicroUSDC,
} from "@signals-protocol/v1-sdk";

const sdk = new CLMSRSDK();

// Raw data from your subgraph (strings)
const rawMarket = {
  liquidityParameter: "1000000000000000000",
  minTick: -500,
  maxTick: 500,
  tickSpacing: 10,
};

const rawDistribution = {
  totalSum: "1000000000000000000",
  binFactors: ["1000000000000000000", "1000000000000000000"],
};

const market = mapMarket(rawMarket);
const distribution = mapDistribution(rawDistribution);

const quantity = toMicroUSDC(10); // 10 USDC in 6 decimals
const quote = sdk.calculateOpenCost(-100, 100, quantity, distribution, market);

console.log(quote.cost.toString());
```

## Common tasks

### Quote sell proceeds

```ts
import { CLMSRSDK, toMicroUSDC } from "@signals-protocol/v1-sdk";

const sdk = new CLMSRSDK();

const position = {
  lowerTick: -100,
  upperTick: 100,
  quantity: toMicroUSDC(10),
};

const proceeds = sdk.calculateDecreaseProceeds(
  position,
  toMicroUSDC(5),
  distribution,
  market
);

console.log(proceeds.proceeds.toString());
```

### Inverse: budget to quantity

```ts
const result = sdk.calculateQuantityFromCost(
  -100,
  100,
  toMicroUSDC(50),
  distribution,
  market,
  true
);

console.log(result.quantity.toString());
```

## Exports

- `CLMSRSDK` / `SignalsSDK` for pricing and inverse functions
- `createCLMSRSDK`, `createSignalsSDK` convenience constructors
- `mapMarket`, `mapDistribution` for GraphQL-to-SDK conversions
- `MathUtils` for WAD/USDC helpers and math utilities
- Types in `types.ts` (e.g. `Market`, `MarketDistribution`, `Position`, `FeeInfo`)

## Notes

- Amounts are `big.js` values (USDC uses 6 decimals, WAD uses 18 decimals).
- Fee overlays follow the contract fee policy descriptor when provided.
- The SDK mirrors contract math and overflow guards for compatibility.