PHPackages                             nf/input - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. nf/input

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

nf/input
========

Input Package for NF Theme

1.0.3(6y ago)0117MITPHPCI failing

Since Sep 26Pushed 6y ago1 watchersCompare

[ Source](https://github.com/nf-theme/inputs)[ Packagist](https://packagist.org/packages/nf/input)[ RSS](/packages/nf-input/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependencies (1)Versions (5)Used By (0)

Extension Kit
=============

[](#extension-kit)

> It's an extension kit for our theme

- [Installation](#installation)
- [Configuration](#configuration)
- [Compile asset file](#compiler)
- [Service](#service)
- [Working with local repository](#local-reposoitory)
- [Extension Configuration](#extension-configuration)

Installation
------------

[](#installation)

### Clone repository

[](#clone-repository)

```
git clone https://github.com/hieu-pv/nf-extension-kit.git

```

### Update your information

[](#update-your-information)

If you want provide some function that is bootstrapped when wordpress start, we will register them in `src/ExtensionKitServiceProvider.php`

> For example: register css/js file

then in `config/app.php` of the theme we have to register service provider

```
  'providers'  => [
        // .... Others providers
        \NightFury\ExtensionKit\ExtensionKitServiceProvider::class,
    ],
```

Compile asset file
------------------

[](#compile-asset-file)

> {tip} You can write your own javascript in `/assets/scripts/app.js`and css in `/assets/styles/app.scss`

All compiled file will be located in `/assets/dist`

##### Install node module

[](#install-node-module)

```
npm install

```

##### Run asset compiler

[](#run-asset-compiler)

```
npm run build

```

##### Run asset compiler on production mode

[](#run-asset-compiler-on-production-mode)

```
npm run prod

```

##### Watch file change and compile

[](#watch-file-change-and-compile)

```
npm run watch

```

> {tip} You can write your own config in `webpack.config.js`

Service
-------

[](#service)

Blade is the simple, yet powerful templating engine provided with this kit. You can use it via NightFury\\ExtensionKit\\Facades\\View

> {tip} Blade file are located in `/resources/views`

For example we have a file `/resources/views/example.blade.php` then we can use this file by following code

```
echo NightFury\ExtensionKit\Facades\View::render('example', ['data' => 'some test data here']);

```

For more information about blade engine

Working with local repository
-----------------------------

[](#working-with-local-repository)

In addition to the artifact repository, you can use the path one, which allows you to depend on a local directory, either absolute or relative. This can be especially useful when dealing with monolithic repositories.

To add local repository to your project, add the following code to your composer.json then run command `composer install`

```
{
    "repositories": [
        {
            "type": "path",
            "url": "../../packages/my-package"
        }
    ],
    "require": {
        "my/package": "*"
    }
}

```

For example

```
    {
        "require": {
            "nf/extension-kit": "dev-master"
        },
        "repositories": [{
            "type": "path",
            "url": "../../../../nf-extension-kit" // use relative path here
        }]
    }

```

For more information

Extension Configuration
-----------------------

[](#extension-configuration)

In some case we need some configuration from user, we can use `nf/theme-option` package

Checkout package repository for install and supported field

##### Register option scheme in your service provider `src/ExtensionKitServiceProvider.php`

[](#register-option-scheme-in-your-service-provider-srcextensionkitserviceproviderphp)

```
use use NightFury\Option\Abstracts\Input;

\NightFury\Option\Facades\ThemeOptionManager::add([
    'name'   => 'Exetension Kit',
    'fields' => [
        [
            'label'    => 'Text',
            'name'     => 'theme_option_text',
            'type'     => Input::TEXT,
            'required' => true,
        ],
        [
            'label'    => 'Textarea',
            'name'     => 'theme_option_textarea',
            'type'     => Input::TEXTAREA,
            'required' => true,
        ],
        [
            'label'    => 'Email',
            'name'     => 'theme_option_email',
            'type'     => Input::EMAIL,
            'required' => true,
        ],
        [
            'label'       => 'Gallery',
            'name'        => 'theme_option_gallery',
            'type'        => Input::GALLERY,
            'description' => 'We can select multi file. Drag and Drop to re-order content',
        ],
        [
            'label'       => 'Gallery With Meta Field',
            'name'        => 'theme_option_gallery_with_meta',
            'type'        => Input::GALLERY,
            'description' => 'Gallery with meta field, for now we support text and textarea on meta field.',
            'meta'        => [
                [
                    'label' => 'Text',
                    'name'  => 'meta_text',
                    'type'  => Input::TEXT,
                ],
                [
                    'label' => 'Textarea',
                    'name'  => 'meta_textarea',
                    'type'  => Input::TEXTAREA,
                ],
            ],
        ], [
            'label'       => 'Image',
            'name'        => 'theme_option_image',
            'type'        => Input::IMAGE,
            'description' => 'Choose your image by clicking the button bellow',
        ],
        [
            'label'   => 'Select',
            'name'    => 'theme_option_select',
            'type'    => Input::SELECT,
            'options' => [
                [
                    'value'    => 'first',
                    'label'    => 'First Value',
                    'selected' => true,
                ],
                [
                    'value'    => 'second',
                    'label'    => 'Second Value',
                    'selected' => false,
                ],
            ],
        ],
    ],
]);
```

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~18 days

Total

3

Last Release

2433d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e33d35507ab7b489a96aac40b3cf04b6e653cd3beeac6a2fdd3d35902d98aa9f?d=identicon)[NightFury](/maintainers/NightFury)

---

Top Contributors

[![hieu-pv](https://avatars.githubusercontent.com/u/7848185?v=4)](https://github.com/hieu-pv "hieu-pv (9 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (8 commits)")[![tunghn123](https://avatars.githubusercontent.com/u/39963091?v=4)](https://github.com/tunghn123 "tunghn123 (7 commits)")[![nightfury-est](https://avatars.githubusercontent.com/u/20170474?v=4)](https://github.com/nightfury-est "nightfury-est (1 commits)")

### Embed Badge

![Health badge](/badges/nf-input/health.svg)

```
[![Health](https://phpackages.com/badges/nf-input/health.svg)](https://phpackages.com/packages/nf-input)
```

###  Alternatives

[phpoffice/phpvisio

PHPVisio - Read, Create and Write Diagrams documents in PHP

1803.8k](/packages/phpoffice-phpvisio)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
