open-index/open-npm huggingface dataset:
npm package: @neo4j-antora/aliases-redirects
Description: Help with redirects and page aliases
Author: Neo4j
Latest version: 0.2.7

# aliases-redirects

Use the `aliases-redirects` extension to modify the default Antora sitemap generation.

## Usage

Add the extension in a playbook

```
antora:
  extensions:
  - require: "@neo4j-antora/aliases-redirects.js"
    redirect_format: 'nginx'
    alias_log_level: 'error'
    log_found_aliases: true
```

## Options

| Name | Type | Description | Default
| ---- | ---- | ----------- | -------
| `redirect_format` | string | [Optional] The style of redirect declarations that Antora generates. If set to `neo4j`, the default Antora static meta refresh pages are not generated | `neo4j`
| `alias_log_level` | string | [Optional] The level of log messages when a page is moved or deleted in a new version, but no page-aliases are defined. | `info`
| `log_found_aliases` | boolean | [Optional] Add a message to the log when a page-alias is defined | `false`


## Using the CLI to add the extension

Although you will usually want to add the extension to a playbook, you can add it by using the Antora CLI.
You can do this with the `--extension` option:

```
--extension <PATH TO EXTENSION> --attribute aliasLogLevel='warn' --attribute logFoundAliases
```
npm package: @neo4j-antora/antora-add-notes
Description: Add asciidoc blocks into the top of pages based on page attributes
Author: Neo4j
Latest version: 0.3.2

# antora-add-notes

Use the `antora-add-notes` extension to add asciidoc into the top of pages.

The extension uses [Page Attributes](https://docs.antora.org/antora/2.3/page/page-attributes/) to define content to be added to the top of a page, immediately below the title.

## Usage

Define attributes in an Antora playbook, _antora.yml_, or asciidoc page header.

### page-add-notes-module

Use the `page-add-notes-module` attribute to specify the name of the module that contains the asciidoc you want to add. If `page-add-notes-module` is not specified, the `ROOT` module is used.

```
page-add-notes-module: my-notes@
```

### page-add-notes-tags

```
page-add-notes-tags: tag-1;tag-2@
```

Tagged sections are read from `{page-add-notes-module}:partial$/notes.adoc`.

To include multiple tags, add the tags as a list, for example `page-add-notes-tags: review;preview`.


### page-add-notes-versions

By default the note is displayed in all versions of all pages.
Use the `page-add-notes-versions` attribute to specify which versions of the HTML pages you want the note to be displayed on.
If you do not include this attribute, notes will be added to pages in all versions. 

```
page-add-notes-versions: ['5', '4.4']
```

## Example

1. Create _modules/my-notes/partials/notes.adoc_ with the following content:

    ```
    # tag::preview[]
    [NOTE]
    ====
    This is preview content
    ====
    # end::preview[]
    ```

2. In your Antora playbook file, add an asciidoc attribute - `page-add-notes-module: my-notes`
3. In your Antora playbook file, add an asciidoc attribute - `page-add-notes-tags: preview`
3. Use Antora to generate HTML.
npm package: @neo4j-antora/antora-modify-sitemaps
Description: Override default Antora sitemap generator to include only pages for the current versions of components, and optionally move sitemaps into the component folders for the current versions
Author: Neo4j
Latest version: 0.7.2

# antora-modify-sitemaps

Use the `antora-modify-sitemaps` extension to modify the default Antora sitemap generation.

## Usage

Add the extension in a playbook

```
antora:
  extensions:
  - require: "@neo4j-antora/antora-modify-sitemaps"
    sitemap_version: '1.0'
    sitemap_loc_version: 'current'
    move_sitemaps_to_components: true
    data:
      components:
        my-component: 'my-version'
```

## Configuration

### sitemap_version

Optional.

Specifies a version that will be used for the sitemap for all components in the site catalog. If you do not provide a value, by default the version that Antora considers to be the latest version for a given component is used. For details on how Antora determines the 'latest' version, see [Antora version ordering rules](https://docs.antora.org/antora/latest/how-component-versions-are-sorted/#determine-version-order).

You might want to override this value if, for example, you publish prerelease or preview documentation of a component but you do not mark it as `prerelease: true` in the component descriptor (`antora.yml`).

If you are generating output for a single component you can use `sitemap_version` to specify the version of that component that you want to generate a sitemap for. If you are generating output for multiple components, you need to override this value for specific components by using the `data` property.

### sitemap_loc_version

Optional. The default value is `current`.

If this is specified, the paths in the entries in each generated sitemap file are updated by replacing the version as it appears in the path with the value of `sitemap_loc_version`.

For example, with `sitemap_loc_version: 'current'`

```
<loc>https://example.com/my-component/my-version/path/to/page/</loc>
```

is updated to:

```
<loc>https://example.com/my-component/current/path/to/page/</loc>
```

**Note:** If your content is versionless only, you do not need to specify a value for sitemap_loc_version, and any value you do specify is ignored for any versionless content.

### move_sitemaps_to_components

Optional. The default value is `true`.

The sitemap for each component will be moved to _site/\<component>/\<sitemap_version>/sitemap.xml_ unless this attribute is set to `false`.

### data

Optional.

If you want to generate a sitemap from a component by using a version that is not the latest version (as determined by Antora), you can specify the components and versions with this option.

For example, if you have a component, `my-component` and your playbook will generate output for versions `1.0` and `1.1`, you can generate a sitemap for the `1.0` content at _my-component/1.0/sitemap.xml_ with the following:

```
 data:
      components:
        my-component: '1.0'
```
npm package: @neo4j-antora/antora-page-list
Description: Create JSON mapping source files to HTML URLs
Author: Neo4j
Latest version: 0.1.2

# antora-page-list

Adds a file containing information relating source and output files.

## Usage

Add the extension in a playbook

```
antora:
  extensions:
  - require: "@neo4j-antora/antora-page-list"
```
npm package: @neo4j-antora/antora-page-roles
Description: Add classes to body based on page roles
Author: Neo4j
Latest version: 0.3.2

# antora-page-roles

Adds classes to the `<body>` tag of a page, based on roles specified before the document header.

Use any valid asciidoc format:

* `[role="role-one role-two"]`
* `[role=role-one role-two]`
* `[.role-one.role-two]`

**Note:** Any roles specified in this way are overwritten by the values in the `:page-role:` header attribute if it is present.
npm package: @neo4j-antora/antora-unlisted-pages
Description: An Antora 3 extension to detect pages not found in the navigation
Author: Neo4j
Latest version: 0.1.0

# antora-unlisted-pages

Detects pages that are not included in your site's navigation, and adds them to a new section at the end of the navigation, or removes them from the output.


## Usage

Add as an antora extension in a playbook. For example:

```
antora:
  extensions:
  - require: "@neo4j-antora/antora-unlisted-pages"
    add_to_navigation: true
    unlisted_pages_heading: 'Additional pages'
    log_level: 'warn'

```


## Options

| Name | Type | Description | Default
| ---- | ---- | ----------- | -------
| `add_to_navigation` | boolean | If set to `true`, the unlisted pages are appended as a new section in the table of contents. If set to `false`, the unlisted pages are removed from the output | `false`
| `unlisted_pages_heading` | string | The text that is displayed for the section appended to the navigation if `add_to_navigation` is set to `true`. | `Unlisted Pages`
| `log_level` | string | The level of log output. Valid values are: `info`, `warn`, `error`. | `info`
npm package: @neo4j-antora/mark-terms
Description: Asciidoc extension to mark the first instance of a term on a page, typically with a copyright symbol
Author: Neo4j Documentation
Latest version: 1.1.4

# mark-terms

Marks the first usage of a term or terms on a page by appending asciidoc after the term. Typically, this is used to add a registered trademark.

## Usage

Add the extension to a playbook:

```
asciidoc:
  extensions:
  - ./extensions/mark-terms/mark-terms.js
```

Add a comma-separated list of terms to be marked:

```
asciidoc:
  attributes:
    page-terms-to-mark: Term1, Term2
```

Optionally, specify an HTML entity to be appended to the first instance of the term:

```
asciidoc:
  attributes:
    page-terms-marker: '&copy;'
```

If you don't specify a value for `page-terms-marker`, the default value is used.
The default value is `&reg;`
npm package: @neo4j-antora/roles-labels
Description: Convert roles on a block to a labels div, add dataset info to a block based on roles and inline labels
Author: Neo4j
Latest version: 0.1.8

# roles-labels

Add a labels div based on `label--` roles on a block.

## Usage

Add the extension in a playbook

```
antora:
  extensions:
  - require: "@neo4j-antora/roles-labels"
npm package: @neo4j-antora/selector-labels
Description: Add text to component versions in a version selector
Author: Neo4j
Latest version: 0.1.1

# selector-labels

Use the `selector-labels` extension to add text to component versions in the version selector.


## Usage


1. Install the extension: `npm i @neo4j-antora/selector-labels`
2. Add the extension in a playbook

    ```
    antora:
      extensions:
      - require: "@neo4j-antora/selector-labels.js"
    ```

3. Add `lts: true` to a component descriptor file (_antora.yml_). The ui-bundle will display the corresponding text, `(LTS)` after the component name and version in the version selector for LTS releases, and `(Current)` for the latest release.

> Note that by default the latest release is determined using Antora's semantic [version ordering rules](https://docs.antora.org/antora/latest/how-component-versions-are-sorted/#determine-version-order). If you want to override this behaviour and manually mark a version as current you can do this by adding `current: true` to _antora.yml_ and providing your own extension config in the playbook. In the config, include `current:` and set `use_semantic: false` to prevent the latest version (as determined by Antora) from automatically being labeled as the current version.


## Config

You can define a custom list of attributes in the playbook.

If you do not define any attributes, the default values are used.
The default values are equivalent to adding the following to the playbook:

```
antora:
  extensions:
  - require: "@neo4j-antora/selector-labels.js"
    current:
      selector_text: '(Current)'
      unique: true
      use_semantic: true
    lts:
      selector_text: '(LTS)'
```

In the default configuration, text is added in the version selector, after the component name and version, to 'Current' and 'LTS' releases.

By default, `current` is given the attribute value `unique: true`, meaning that for a given component, only one version can be considered 'Current'. An error is logged for a component if more than one version has a unique attribute defined in its _antora.yml_ file. The extension uses Antora's semantic [version ordering rules](https://docs.antora.org/antora/latest/how-component-versions-are-sorted/#determine-version-order) to determine the latest version to mark as 'current'.


## Using the CLI to add the extension

Although you will usually want to add the extension to a playbook, you can add it by using the Antora CLI.
You can do this with the `--extension` option:

```
--extension <PATH TO EXTENSION>
```
npm package: @neo4j-antora/table-footnotes
Description: Move table footnotes from the end of a page to a footer row in the table
Author: Neo4j
Latest version: 1.0.1

# table-footnotes

When footnotes appear in a table, move the footnotes from the div that is added to the end of the page, and place the footnotes in a table footer row.

## Usage

Add the extension in a playbook

```
antora:
  extensions:
  - require: "@neo4j-antora/table-footnotes"
npm package: @neo4j-antora/xref-hash-validator
Description: Validate xrefs in the source that target a section of a page in the same docset
Author: Neo4j
Latest version: 0.1.4

# xref-hash-validator

Validates xrefs where the target is in the same docset and includes a hash, specifying a section of a page (ex. `xref:functions/temporal/index.adoc#functions-date`).

## Usage

Add the extension in a playbook

```
antora:
  extensions:
  - require: "@neo4j-antora/xref-hash-validator"
```