open-index/open-npm huggingface dataset:
npm package: @okonomi-gmbh/dms
Description: Vanilla JavaScript Client for the Okonomi Document Management Service.
Author: Okonomi GmbH
Latest version: 0.0.3

## Okonomi Document Management Service JS Client

Vanilla JS client to interact with the Okonomi Document Management Service.

The Okonomi Document Management Service is a headless, application level microservice 
to manage files on common cloud storage services like S3. It can be used to add document management capabilities to existing applications.

Core features of the Okonomi Document Management Service are:
* Documented REST API (openApi 3)
* Metadata for files
* Metadata based Access Control
* Metadata based search
* PDF Preview
* Image Resizing and Cropping
* Webhooks
* Admin UI

### Getting started

Install the client lirary:

```
$ npm install --save @okonomi-gmbh/dms
# or
$ yarn add @okonomi-gmbh/dms
```

Create a client instance:

```
import {client} from "@okonomi-gmbh/dms/src";

const dmsClient = client({
  url,
  token,
});

```

Use the client to search for existing documents:

```
dmsClient.search().then(result => {
    console.log(result);
});
```

Okonomi GmbH 2021
npm package: @okou/action-yml
Description: Define & Generate `action.yml` in TS, parse typed input with it.
Author: okou
Latest version: 1.0.2

# action-yml

Define & Generate `action.yml` in TS, parse typed input with it.

# Install

```sh
npm i @okou/action-yml
```

# Example

```ts
import { defineActionYml, generateYaml, parseInput, parseOutput } from "@okou/action-yml";
import { arrayP, numberP, stringP } from "@okou/action-yml/parser";
import { arrayS, booleanS } from "@okou/action-yml/serializer";

// define action.yml
const action = defineActionYml({
	name: "Your Action Name",
	description: "This is awesome.",

	inputs: {
		stringArray: {
			description: "string[]",
			required: true,
			// inter type from return type
			parser: arrayP(stringP),
		},
		number: {
			description: "number",
			required: true,
			parser: numberP,
		},
	},

	outputs: {
		booleanArray: {
			description: "boolean[]",
			// infer type from parameter type
			serializer: arrayS(booleanS),
		},
	},

	runs: {...},
	branding: {...},
});

// generate action.yml
generateYaml("action.yml", action);

// get input
const input = parseInput(action.inputs);
const strArr: string[] = input.stringArray;
const num: number = input.number;

// set output
const output = parseOutput(action.outputs);
output.booleanArray = [true, false];
```
npm package: @okou/react-webext-menu
Description: React for browser extension contextmenu
Latest version: 1.0.1

# @okou/react-webext-menu

React renderer for the browser extension's context menu.

## Install

```sh
npm i @okou/react-webext-menu react@18
```

> [!WARNING]
> react-webext-menu is not compatible with React 19.

## Usage

```jsx
import { render, Normal, Separator } from "@okou/react-webext-menu";
import { useState } from "react";

function MyMenu() {
  const [count, setCount] = useState(0);
  return (
    <Normal title="Counter Example">
      <Normal title={count.toString()} onClick={() => setCount((i) => i + 1)} />
      <Separator />
      <Normal title="Reset" onClick={() => setCount(0)} />
    </Normal>
  );
}

render(<MyMenu />, chrome.contextMenus);
```

<img src="media/demo.gif">
npm package: @okou/regex-compose
Description: Template literal for composing RegExp.
Author: okou
Latest version: 1.0.1

# regex-compose

Simple Reusable Typed RegExp

## Features

### Basic Usage

```ts
import { r, maybe, or, seq } from "@okou/regex-compose";

// URL
const short = r`youtu\.be`;
const long = r`${maybe(r`www\.`)}youtube\.com`;
const host = r`https?://${or(short, long)}`;
const url = r`${host}/watch\?v=([\w-]+)`;

// Number
const digits = r`[0-9]+`;
const oneNine = r`[1-9]`;
const int = r`${maybe("-")}${maybe(oneNine)}${digits}`;
const fract = r`\.${digits}${oneNine}`;
const number = seq(int, maybe(fract));
```

### Typed named-capture

```ts
import { r, ncap } from "@okou/regex-compose";

const a = ncap("aaa", "a+");
const b = r`${a}${ncap("bbb", b+)}`;
const c = ncap("ccc", a, b);

c.exec("")?.groups.| // = RegExpT<"aaa"|"bbb"|"ccc">
                    _____________________________
                    | aaa?    string | undefined
                    | bbb?    string | undefined
                    | ccc?    string | undefined
```

### Helpers

```ts
// Core
seq(...expr)               // abc
or(...expr)                // (?:a|b|c)
flag(flags, regexp)         // /regexp/flags

// Quantifiers
quantity(suffix, ...expr)  // (?:...)suffix
maybe(...expr)             // ?
maybeL(...expr)            // ??
many0(...expr)             // *
many0L(...expr)            // *?
many1(...expr)             // +
many1(...expr)             // +?
releat(count, ...expr)     // {1}  {2,}  {0,3}
releatL(count, ...expr)    // {1}? {2,}? {0,3}?

// Captures & Refs
cap(...expr)               // (...)
ncap(...expr)              // (?<group>...)
ref(number or label)       // \1  \k<label>
modifier(flag, ...expr)    // (?ims-ims:...)

// Assertions
lookAhead(...expr)            // (?=...)
notAhead(...expr)             // (?!...)
lookBehind(...expr)           // (?<=...)
notBehind(...expr)            // (?<!...)
hasPrefix(prefix, ...expr)    // (?<=prefix)...
hasNoPrefix(prefix, ...expr)  // (?<!prefix)...
hasSuffix(suffix, ...expr)    // ...(?=suffix)
hasNoSuffix(suffix, ...expr)  // ...(?!suffix)

// Utils
sepBy(sep, ...expr)           // ...(?:sep...)+
between(wrapper, ...expr)     // wrapper...wrapper
```
npm package: @okou/typed-env
Description: Simple typed-parser of `process.env`.
Author: okou
Latest version: 1.0.0

# About

Simple typed-parser of `process.env` .  
This is NOT a loader of `.env` such as Dotenv.

# Usage

```env
STR = hogehoge
NUM = 1234.5
BOOL = true, false, 0, 1
INT = 123456789
```

```ts
import { load } from 'env-typed';

// env-name: type
const Env = load({
  STR: 'string',
  NUM: 'number',
  BOOL: 'boolean[]',
  INT: 'bigint',
});

/*
Env:{
  STR: 'hogehoge',
  NUM: 1234.5,
  BOOL: [ true, false, true, false ],
  INT: 123456789n
}

typeof Env = {
  STR: string;
  NUM: number;
  BOOL: boolean[];
  INT: bigint;
}
*/
```

# Note

- Strings `'false'`, `'0'` and `''` (blank) are parsed as `boolean` when specified boolean.

## Usabel types

- `string`
- `number`
- `boolean`
- `bigint`
- Array of these