open-index/open-npm huggingface dataset:
npm package: @qgustavor/ass-parser
Description: Parse SSA/ASS subtitle format
Latest version: 0.5.3

# ass-parser

Parse SSA/ASS subtitle format. Forked from [eush77/ass-parser](https://github.com/eush77/ass-parser).

## Changes:

- All dependencies replaced with native modern JavaScript functions.
- ES Modules instead of CommonJS.
- Add `detectStringifyOptions` helper function.

## Demo

[https://codepen.io/qgustavor/full/YzaRXeX](https://codepen.io/qgustavor/full/YzaRXeX)

## API

### `assParser(text, [options])`

Default export. Returns the parse tree.

Comments are ignored unless `options.comments` is set.

| Option          | Type    | Required? | Default |
| :-------------- | :------ | :-------: | :------ |
| comments        | boolean | No        | `false` |
| parseTimestamps | boolean | No        | `false` |

## Format

Subtitle is a list of sections, each of them has `section`, `body` and `line` properties. The `body` is a list of key-value bindings (descriptors), with `key`, `value` and `line` properties (`type === 'comment'` and `value` for comments).

`value` can be one of the following:

- array if the descriptor key is `"Format"`;
- object if there is a `"Format"` descriptor above in the section;
- string otherwise.

When `parseTimestamps` is set to `true` timestamps on `Start` and `End` keys for `Dialogue` and `Comment` lines will be converted into numbers (in seconds).

At the moment override tags are not parsed. One alternative is parsing using [libjass](https://github.com/Arnavion/libjass/) like so: `libjass.parser.parse(descriptor.value.Text, 'dialogueParts')`.

The `line` property in sections and descriptors refer to the 0-indexed line where the section or descriptor was defined in the text.

### `detectStringifyOptions(text)`

Named export. Returns an options object to be passed to `stringify` in order to parse then stringify a subtitle with the minimal differences possible.

## References

- [Wikipedia page](http://en.wikipedia.org/wiki/SubStation_Alpha)
- [Format specification](http://www.perlfu.co.uk/projects/asa/ass-specs.doc)

## Related

- [@qgustavor/ass-stringify](https://www.npmjs.com/package/@qgustavor/ass-stringify) - stringify SSA/ASS parse tree.

## Install

```shell
npm install @qgustavor/ass-parser
```

## License

MIT
npm package: @qgustavor/ass-stringify
Description: Stringify ass-parser parse tree to plain SSA/ASS subtitle format
Author: Eugene Sharygin
Latest version: 0.3.1

# ass-stringify

Stringify [ass-parser](https://www.npmjs.com/package/@qgustavor/ass-parser) parse tree to plain SSA/ASS subtitle format. Forked from [eush77/ass-stringify](https://github.com/eush77/ass-stringify).

## Changes:

- All dependencies replaced with native modern JavaScript functions.
- ES Modules instead of CommonJS.
- Added options.
- Format numeric timestamps.

## Demo

[https://codepen.io/qgustavor/full/YzaRXeX](https://codepen.io/qgustavor/full/YzaRXeX)

## API

### `assStringify(ass, options)`

Returns a text string. See the demo or `test/sample.ass` for an example.

Options is an object with the following keys:

- `lineBreak`: defaults to `\n`, set to `\r\n` to use Windows' line breaks
- `formatJoiner`: defaults to `, `, some subtitles use `,` instead
- `sectionJoiner`: defaults to `lineBreak` repeated twice
- `timestampKeys`: defaults to `['Start', 'End']`, defines which keys can be formatted to timestamps when numbers are provided

## References

- [Wikipedia page](http://en.wikipedia.org/wiki/SubStation_Alpha)
- [format specification](http://www.perlfu.co.uk/projects/asa/ass-specs.doc)

## Related

- [@qgustavor/ass-parser](https://www.npmjs.com/package/@qgustavor/ass-parser) - SSA/ASS parser.

## Install

```shell
npm install @qgustavor/ass-stringify
```

## License

MIT
npm package: @qgustavor/later
Description: ES Modules fork of later. Determine later (or previous) occurrences of recurring schedules
Author: BunKat
Latest version: 5.0.2

# @qgustavor/later


This project is a ES Modules fork of Later. Later is a library for describing recurring schedules and calculating their future occurrences.  It supports a very flexible schedule definition including support for composite schedules and schedule exceptions. Create new schedules manually, via Cron expression, via natural language expressions, or using a fully chainable API.

This fork also removed benchmarks, tests and all the other fuss I don't plan to maintain. Also, removed global state generated by "later.date.UTC()".

## Table of Contents

* [Features](#features)
* [Documentation](#documentation)
* [Install](#install)
* [Usage](#usage)
  * [Node](#node)
  * [Browser](#browser)
* [Contributors](#contributors)
* [License](#license)

## Features

Types of schedules supported by *Later*:

* Run a report on the last day of every month at 12 AM except in December
* Install patches on the 2nd Tuesday of every month at 4 AM
* Gather CPU metrics every 10 mins Mon - Fri and every 30 mins Sat - Sun
* Send out a scary e-mail at 13:13:13 every Friday the 13th

## Documentation

WIP. In the meanwhile see [parent fork's documentation](https://breejs.github.io/later/), but check the code or the library on a REPL since A LOT of refactoring was done in order to convert the library to ES Modules and allow for tree shaking.

## Install

```sh
npm install @qgustavor/later
```

## Usage

### Node.js

```js
import * as later from '@qgustavor/later'

console.log(later)
```

### Browser

#### Vanilla JS

This is the solution for you if you're just using `<script>` tags everywhere!

```html
<script type="module">
import * as later from 'https://unpkg.com/@qgustavor/later'
</script>
```

#### Bundler

Assuming you are still using a bundler, you can simply follow Node.js usage above.

## License

[MIT](LICENSE) © BunKat
npm package: @qgustavor/leaflet-hash
Description: Modern version of leaflet-hash, which adds URL hashes to web pages with Leaflet maps.
Author: Michael Lawrence Evans
Latest version: 1.3.0

# Modern Leaflet Hash

This fork of [Leaflet-hash](https://github.com/mlevans/leaflet-hash), which lets you to add dynamic URL hashes to web pages with Leaflet maps, is made to be used with ES Module imports.

### Getting started

1. Prepare a basic leaflet map.

2. Include the plugin:

- `import { createHash } from '@qgustavor/leaflet-hash'` when using bundle tools (remember to install the library using npm or something else)
- `<script src="https://unpkg.com/@qgustavor/leaflet-hash/dist/leaflet-hash.global.js">` when loading directly on a browser

3. Initialize the plugin:

```javascript
// Assuming your map instance is in a variable called map
const map = L.map('example')
const hash = createHash(map)
```

### Author

[@mlevans](http://github.com/mlevans)

### Contributors

[@calvinmetcalf](http://github.com/calvinmetcalf)

[@jfirebaugh](http://github.com/jfirebaugh)

[@rsudekum](http://github.com/rsudekum)

[@tmcw](http://github.com/tmcw)

[@yohanboniface](http://github.com/yohanboniface)

[@qgustavor](http://github.com/qgustavor)

### License

MIT License. See [LICENSE](https://github.com/qgustavor/leaflet-hash/blob/master/LICENSE.md) for details.
npm package: @qgustavor/srt-parser
Description: Parse SRT into array
Latest version: 2.0.0

## @qgustavor/srt-parser

Just other SRT parser for JavaScript: it reads an `.srt` file into an array! Also, a fork of srt-parser-2 with so many changes that it will never be merged!

## Usage

If you are using Node or a bundler you need to install using the following command:

```bash
npm install @qgustavor/srt-parser
```

If you are not using npm but yarn, or pnpm or something else you probably know how to convert the npm command to the one your tool uses.

```javascript
import SrtParser from '@qgustavor/srt-parser'

const srt = `
1
00:00:11,544 --> 00:00:12,682
Hello
`

const parser = new SrtParser()
const parsed = parser.fromSrt(srt)
console.log(parsed)
```

If you are using Deno just add the `npm:` prefix to the import.

It will return something like this:

```json5
[{
  id: '1',
  startTime: '00:00:11,544',
  endTime: '00:00:12,682',
  text: 'Hello'
}]
```

To turn array back to SRT string, do the following:

```javascript
const stringified = parser.toSrt(parsed)
console.log(stringified)
```

If you want timestamps as numbers (in seconds) instead of strings use the following:

```javascript
const parser = new SrtParser({
  numericTimestamps: true
})
```

### Environment support

Since it only process text, it should work in most JavaScript environments.

## CLI

```
npx @qgustavor/srt-parser -i input.srt -o output.json --minify
```

Options:

| Option         | Required | Default     |
| -------------- | -------- | ----------- |
| --input or -i  | Yes      |             |
| --output or -o | No       | output.json |
| --minify       | No       | false       |

## License

MIT

## Why?

Besides the issues on other SRT parsers [listed by srt-parser-2](https://github.com/1c7/srt-parser-2#why), srt-parser-2 also have some issues:

- The developer does not have time to work on the project.
- The way it handles numeric timestamps is not clear, leads to foot guns and it's hard to fix without a major breaking change.
- I don't like the typos in the README, nor the mixed snake and camel cases, nor semicolons.
- I don't like the docs folder (looks like it came from a template, some of it was in Chinese), neither the examples folder (they differ from the README).
- I don't like the use of `var` neither the lack of a code style linter.
- To be fair I don't like the use of constructors since the parser is not stateful, but rewritting it is hard, so fixing it will be left as a task to the next fork.
npm package: @qhacks/devpost-stats-cli
Description: Get stats about your hackathon from the comfort of your terminal
Author: Zack Harley
Latest version: 1.0.0

# Devpost Stats CLI

> Get stats about your hackathon from the comfort of your terminal :rocket:

## Install

Ensure you have Node.js version 8+ installed. Then run the following:

```bash
$ npm install --global @qhacks/devpost-stats-cli
```
   
## Usage

```
$ devpost-stats --help

  Usage
    $ devpost-stats <csv>
      
  Options
    --output-file, -o  Specify a path and JSON file to save the statistics to
    
  Examples
    $ devpost-stats ../path/to.csv
      { ...someStats }
    
    $ devpost-stats ../path/to.csv -o ./path/to/output.json
      ✔ Statistics saved to file
```   

## License

MIT © QHacks