open-index/open-npm huggingface dataset:
npm package: @itkyk/accordion
Description: simple accordion logic module
Latest version: 1.0.6

# accordion  
  
## install
```shell
$ npm i @itkyk/accordion
```

## How to use @itkyk/accordion
```html
<div class="js-accordion">
  <div class="js-accordion-wrap">
    <div class="js-accordion-inner">
      <!--- Your Markup Contents --->
    </div>
  </div>
</div>
```

```typescript
import Accordion from "@itkyk/accordion";

// Initialize
const option = {};
const accordion = new Accordion(".js-accordion", option)
/* OR
const accordion = new Accordion(document.querySelector(".js-accordion"), option)
*/
// add callbacks
accordion.setOpenCallback(() => {
  // add function
  console.log("open");
})

accordion.setCloseCallback(()=>{
  // add function
  console.log("close");
})

// start acrodion
accordion.mount();

// desctoy event listener & remove height
accordion.destroy();
```

## Option
| key | default  | value |description |
|------|-----------|---------|---------------|
| type | "toggle" | "toggle" | "divide" | select button type. |
| button |".js-accordion-button" | `string or HTMLElement` | if type is `toggle`,  open or close torigger className of dom |
| buttons |{open: ".js-accordion-button-open", close: ".js-accordion-button-close"} | {open: `string or HTMLElement`, close: `string or HTMLElement`} | if type is ``,  open or close torigger of html elements className of each dom.  |
| wrapper | ".js-accordion-wrap" | `string of HTMLElement` | accordion wrapper hrml element or className of dom |
| inner | ".js-accordion-inner" | `string of HTMLElement` |  accordion inner html element or className of dom |
| initialHeight | null | `null` or `number` or `className` or `Element` | when be closing accordion, set height value. if setting null, `.style.height = "";`. |

## methods
| key | description |
|------|-----------|
| mount | set accordion logics | 
| destroy | remove addEventListeners | 
| setOpenCallback | added function of when opening the accordion |
| setCloseCallback | added function of when closing the accordion | 
| getOpenFlag | Getting open status. Return Value is `true` or `false` |

## vars
| key | description |
|------|-----------|
| target | when initialize, set target DOM | 
| button | when initialize, set button DOM or button DOMs | 
| wrap | when initialize, set wrapper DOM |
| inner | when initialize, set inner DOM | 


## Change Log
- v1.0.6
    -  Corrected to remove wrapper height when destroying.
- v1.0.5
  -  Fixed a bug when passing `HTMLElement` in option.
npm package: @itkyk/account-manager
Description: ## Use ```bash # install npm i -g @itkyk/account-manager
Latest version: 1.0.1

# @itkyk/accounts-manager

## Use
```bash
# install
npm i -g @itkyk/account-manager

# run
npx account
```

## Options
| key | description                                                                                                                               |
|------|-------------------------------------------------------------------------------------------------------------------------------------------|
| -w, --write | when want to add accont data, use this option.<br/>ex) `npx account -w`                                                                   |
| -d, --delete | when you want to delete registered data.<br/>ex) `npx account -d`                                                                         |
| -f, --filter | when you want to search and display a list. Valid in normal mode and `-d` mode.<br/>ex)`npx account -f hoge`<br/>`npx account -d -f hoge` |
| -v, --version | check package version<br/>ex) `npx account -v`                                                                                            | 
| -u, --update | update account data fromat<br/>ex) `npx account -u`                                                                                       |
| -o, --open | when you want to open a file that stores data. <br/>Open `~/.itkyk_accounts.json`.                                                        |
npm package: @itkyk/appsync
Description: ## Install ```bash npm i @itkyk/appsync ```
Latest version: 2.0.3

# @itkyk/appsync

## Install
```bash
npm i @itkyk/appsync
```

## Methods
### Setup
```typescript
// aws config file
import {AmplifyConfig} from "@itkyk/appsync";

export default AmplifyConfig({
  "aws_project_region": "us-east-1",
  "aws_appsync_graphqlEndpoint": "", // Your Appsync Endpoint
  "aws_appsync_region": "us-east-1", // AppSync region
  "aws_appsync_authenticationType": "API_KEY", // AppSync Auth type
  "aws_appsync_apiKey": "" // If auth type is API_KEY, copy api key from aws console.
})
```

### FrontEnd
#### Query
```typescript
import {query, configure, gql} from "@itkyk/appsync";
import Config from "aws config file path";
configure(Config);

const queryParam = gql`
query MyQuery($id: ID) {
    getID(id: $id) {
        id
    }
}`

const variable = {
  id: 1
}

const headers = {
  "x-sample-header": "ABC123"
}

const response = await query(queryParam, variable , headers);
```

#### mutation
```typescript
import {mutation, configure, gql} from "@itkyk/appsync";
import Config from "aws config file path";
configure(Config);

const queryParam = gql`
mutation MyMutation($id: ID) {
  addID(id: $id) {
    id
  }
}`

const variable = {
  id: 1
}

const headers = {
  "x-sample-header": "ABC123"
}

const response = await mutation(queryParam, variable, headers);
```

#### Subscription
```typescript
import {subscription, configure, gql} from "@itkyk/appsync";
import Config from "aws config file path";
configure(Config);

const queryParam = gql`
subscription MySubscribe($id: ID) {
  addedID(id: $id) {
    id
  }
}`

const variable = {
  id: 1
}

const onNext = (value, provider) => {
  console.log(value, provider);
}

const onError = (error) => {
  console.error(error)
}

const onComplete = () => {
  console.log("Subscription Complete");
}

const headers = {
  "x-sample-header": "ABC123"
}

const listener = subscription(
  queryParam, 
  variable, 
  {
  onNext,
  onError,
  onComplete
  },
  headers);

listener.unsubscribe()
consoe.log(listener.closed) // -> return boolean
```

## Global Headers

```typescript
import {getGlobalHeaders, setGlobalHeaders} from "@itkyk/appsync";

// In the subsequent `query`/` mutation`/`subScribe`, if you do not pass Header, this header will be used.
setGlobalHeaders({
  "x-sample-header": "ABC123"
});

const headers = getGlobalHeaders();
console.log(headers); // ->  {"x-sample-header": "ABC123"}
```

## Change Log
- 2024/11/03(version 2.0.3)
  - `Query` and` Mutation` have been set to `Promise`.
  - Some arguments have been removed or removed.
  - Header can be set in common as a whole.
- 2023/03/03 (version 1.0.2)
  - Added `headers` to the second argument of the `query`/`mutation`/`subscription` method.
- 2023/02/17 (version 1.0.1)
  - subscription return ZenObservable.Subscription
npm package: @itkyk/aws-s3-sync
Latest version: 2.0.0-alpha-2

# @itkyk/aws-s3-sync


## install
```shell
$ npm i -D @itkyk/aws-s3-sync
```

## Introduce
1. Add init command to script in package.json.

```json
{
  "script": {
    "init": "sync --init"
  }
}
```

2. Execute init command.<br/>This command makes `s3.config.ts` in `root`.
```shell
$ npm run init
```

3. Open `s3.config.ts`, then write AWS/S3 settings.

4. Add deploy command to script in package.json<br/>The location of "preview" will be the name you changed from template earlier.
```json
{
  "script": {
      "deploy": "sync --deploy example"
  }
}
```
6. If execute `npm run deploy`, sync s3 bucket.


## setting options
| key                       | description                                                            | default                     | 
|---------------------------|------------------------------------------------------------------------|-----------------------------|
| configure                 | `AWS.S3ClientConfig` & `AWS.CloudFrontClientConfig` settings.          |                             |
| localTarget               | Dir name of traget local files.                                        |                             |
| bucketName                | Name of Target Bucket.                                                 |                             |
| includes                  | Glob pattern of `localTarget`.                                         | `/**/*`                     |
| excludes                  | Glob pattern of excludes pattern.                                      |                       |
| maxAsyncS3                |                                                                        | 30                          |
| sync                      | Delete file when syncing.                                              | false                       |
| force                     | Upload all files without checking remote files.                        | false                       |
| exactTimestamps                     | When syncing, also check the TimeStamp.                                | false                       |
| outputLog                 | Log file settings.(`boolean` OR `{outDir: string, filename?: string}`) | false                       |
| outputLog.outDir          | Output log file directory.                                             | `./s3`                      | 
| outputLog.filename        | Output log filename.                                                   | `log-[yy-mm-dd-hh-mm-ss].json` | 
| clearCache.distributionId | Target CloudFront distoributionId.                                     |                        |
| clearCache.paths          | distoribution paths.`string[]`                                         |                |
npm package: @itkyk/emotion-reset-style
Description: ## Setup ```tsx // React import * as React from "react"; import {Global, css} from "@emotion/css"; import resetStyle from "@itkyk/emotion-reset-style";
Latest version: 0.0.2

# Reset Css works by @emotion

## Setup
```tsx
// React
import * as React from "react";
import {Global, css} from "@emotion/css";
import resetStyle from "@itkyk/emotion-reset-style";

const App: React.FC = () => {
  return (
    <>
      <Global styles={css(resetStyle)}/>
    </>
  )
}
```

```tsx
import {injectGlobal} from "@emotion/css";
import resetStyle from "@itkyk/emotion-reset-style";

injectGlobal(resetStyle);
```

## Contents of style
- The content of style adopts [destyle.css](https://github.com/nicolas-cusan/destyle.css).
npm package: @itkyk/esbuild-plugin-babel
Description: This package is for using babel with esbuild.   In the plugin, `babel.transfromSync` works.
Latest version: 0.0.3

# esbuild-plugin-babel

This package is for using babel with esbuild.  
In the plugin, `babel.transfromSync` works.

## Installation
To install the package, simply run the following command in your terminal:
```bash
npm i -D @itkyk/esbuild-plugin-babel
```


## Usage
```typescript
import * as esbuild from "esbuild";
import babelPlugin from "@itkyk/esbuild-plugin-babel";

await esbuild.build({
  //...
  plugins: [
    babelPlugin({
      presets:["@babel/preset-env"],
      plugins: ["@babel/plugin-transform-runtime"]
    })
  ]
  //...
})
```

## Options Reference

### filter

|             |      |
|-------------|------|
| default     | /.*/ |
| description | You can specify the pattern of files to be read. |

### babel
|             |                                                 |
|-------------|-------------------------------------------------|
| default     | {}                                              |
| description | babel settings can be added. |

## Dependencies
- @babel/core: ^7.20.12

## Change Log
- version 0.0.3 (2023/02/16)
  - Fixed `babel.transformSync` filename option to default to the path of the file loaded by esBuild.
npm package: @itlabs/ng-utils
Description: Angular utils is a collection of helpful functions, directives and components that can be used in angular projects.
Latest version: 2.0.0

# Angular Utils [![Build Status](https://travis-ci.org/swiss-itlabs/ng-utils.svg?branch=master)](https://travis-ci.org/swiss-itlabs/ng-utils) [![npm version](https://badge.fury.io/js/%40itlabs%2Fng-utils.svg)](https://badge.fury.io/js/%40itlabs%2Fng-utils)

Angular utils is a collection of helpful functions, directives and components that can be used in angular projects.

## API docs

[API docs](https://swiss-itlabs.github.io/ng-utils/) are generated by [TypeDoc](https://typedoc.org/).
npm package: @itlabs/ts-import-move
Description: move typescript imports from one package to another
Author: Admir Ramic
Latest version: 1.0.0-beta.6

# @itlabs/ts-import-move

It can be a lot of work to update all imports, if you moved a class, function, component or whatever from one library of your monorepo to another.
If you are using relative paths for the imports, tools like visual studio code would ask you to perform these import updates for you. But not if you are using typescript paths aliases in your monorepo e.g.

```json
"paths": {
    "@itlabs/my-package": ["packages/my-package/src/index.ts"],
    "@itlabs/my-new-package": ["packages/my-new-package/src/index.ts"]
}
```

In this case, you just found the tool that will helps you :)

## CLI

_A CLI is coming soon._

## Library

Just install those two packages `npm i -D @itlabs/ts-import-move ts-morph`. And copy and adapt this snippet somewhere to your tooling scripts.

```ts
import { Project } from 'ts-morph';
import { tsImportMove } from '@itlabs/ts-import-move';

async function move(): Promise<void> {
  const project = new Project({ tsConfigFilePath: 'path/to/tsconfig.json' });

  tsImportMove(project, {
    imports: ['ObjectToMove'],
    sourcePackage: '@itlabs/my-package',
    targetPackage: '@itlabs/my-new-package',
  });

  await project.save();
}
```

Check the [ts-morph docs](https://ts-morph.com/setup/) for further information how to load your typescript project.