Skip to content

Commit

Permalink
Updating docs
Browse files Browse the repository at this point in the history
  • Loading branch information
glennjacobs committed Dec 22, 2023
1 parent baff580 commit 6cfcd73
Show file tree
Hide file tree
Showing 12 changed files with 45 additions and 187 deletions.
9 changes: 3 additions & 6 deletions docs/.vitepress/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export default defineConfig({
items: [
{text: 'Changelog', link: '/core/upgrading'},
{text: 'Contributing', link: '/core/contributing'},
{text: 'Docs Next', link: 'https://docs-next.lunarphp.io/'}
{text: 'Roadmap', link: 'https://github.com/orgs/lunarphp/projects/8'}
]
}
],
Expand All @@ -67,7 +67,6 @@ export default defineConfig({
items: [
{text: 'Overview', link: '/core/overview'},
{text: 'Installation', link: '/core/installation'},
{text: 'Starter Kits', link: '/core/starter-kits'},
{text: 'Configuration', link: '/core/configuration'},
{text: 'Initial Set-Up', link: '/core/set-up'},
{text: 'Upgrade Guide', link: '/core/upgrading'},
Expand Down Expand Up @@ -111,7 +110,7 @@ export default defineConfig({
},
{
text: 'Extending',
collapsed: true,
collapsed: false,
items: [
{text: 'Carts', link: '/core/extending/carts'},
{text: 'Discounts', link: '/core/extending/discounts'},
Expand All @@ -131,13 +130,11 @@ export default defineConfig({
collapsed: false,
items: [
{text: 'Overview', link: '/admin/overview'},
{text: 'Installation', link: '/admin/installation'},
{text: 'Upgrading', link: '/admin/upgrading'}
]
},
{
text: 'Extending',
collapsed: true,
collapsed: false,
items: [
{text: 'Access Control', link: '/admin/extending/access-control'},
{text: 'Attributes', link: '/admin/extending/attributes'},
Expand Down
6 changes: 3 additions & 3 deletions docs/admin/extending/pages.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ class MyCreateExtension extends CreatePageExtension
}

// Typically placed in your AppServiceProvider file...
LunarPanel::registerExtension(new MyCreateExtension, CreateProduct::class);
LunarPanel::registerExtension(new MyCreateExtension, \Lunar\Admin\Filament\Resources\CustomerGroupResource\Pages\CreateCustomerGroup::class);
```

## EditPageExtension
Expand Down Expand Up @@ -139,7 +139,7 @@ class MyEditExtension extends EditPageExtension
}

// Typically placed in your AppServiceProvider file...
LunarPanel::registerExtension(new MyEditExtension, EditProduct::class);
LunarPanel::registerExtension(new MyEditExtension, \Lunar\Admin\Filament\Resources\ProductResource\Pages\EditProduct::class);
```

## ListPageExtension
Expand Down Expand Up @@ -171,7 +171,7 @@ class MyListExtension extends ListPageExtension
}

// Typically placed in your AppServiceProvider file...
LunarPanel::registerExtension(new MyListExtension, ListProducts::class);
LunarPanel::registerExtension(new MyListExtension, \Lunar\Admin\Filament\Resources\ProductResource\Pages\ListProducts::class);
```

## Extending Pages In Addons
Expand Down
2 changes: 2 additions & 0 deletions docs/admin/extending/panel.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ We provide a handy function which gives you direct access to the panel to change
For example, the following would change the panel's URL to `/admin` rather than the default `/lunar`.

```php
use Lunar\Admin\Support\Facades\LunarPanel;

LunarPanel::panel(fn($panel) => $panel->path('admin'))
->register();
```
4 changes: 3 additions & 1 deletion docs/admin/extending/resources.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ Much like extending pages, to extend a resource you need to create and register
For example, the code below will register a custom extension called `MyProductResourceExtension` for the `ProductResource` Filament resource.

```php
use Lunar\Admin\Support\Facades\LunarPanel;

LunarPanel::registerExtension(new MyProductResourceExtension, \Lunar\Panel\Filament\Resources\ProductResource::class);
```

Expand Down Expand Up @@ -50,4 +52,4 @@ class MyProductResourceExtension extends \Lunar\Panel\Support\Extending\Resource

// Typically placed in your AppServiceProvider file...
LunarPanel::registerExtension(new MyCreateExtension, CreateProduct::class);
```
```
62 changes: 0 additions & 62 deletions docs/admin/installation.md

This file was deleted.

15 changes: 10 additions & 5 deletions docs/admin/overview.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
# Introduction

::: danger Work In Progress
This package is very much in-development. It is incomplete and not production ready.
:::

Lunar's admin panel is powered by Filament v3. It allows you to easily extend the admin panel to suit your project.

With the panel you can administer your products, collections, orders, customers, discounts, settings and much more.

## Work In Progress (WIP)

This package is very much in-development. It is incomplete and not production ready.

## Contributing

If you wish to contribute to the project, please review the project at https://github.com/orgs/lunarphp/projects/8/views/8
If you wish to contribute to the project, please review the roadmap at https://github.com/orgs/lunarphp/projects/8/views/8

You can request to contribute on an issue in the backlog, or you can propose a new issue.

::: tip
Here's a guide on how to set-up your development environment ready for contributing to Lunar.
[Setting Up Lunar For Local Development](/core/local-development)
:::
6 changes: 0 additions & 6 deletions docs/admin/upgrading.md

This file was deleted.

4 changes: 2 additions & 2 deletions docs/core/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ Lunar uses a monorepo [lunarphp/lunar](https://github.com/lunarphp/lunar) approa

## Repository Branching

**Bug Fixes** should target the latest compatible branch version i.e `0.7`. The `main` branch should never have bug fix PR's unless they fix features that are in an upcoming release.
**Bug Fixes** should target the latest compatible branch version i.e `0.7`.

**Features** that bring new (or enhance current) functionality to Lunar should always target the `main` branch.
**Enhancements** should target either `0.8`, or `1.x` if for the new Filament admin panel.

## Contributing Code

Expand Down
23 changes: 18 additions & 5 deletions docs/core/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Server Requirements

- PHP ^8.1
- Laravel 9|10
- Laravel 10
- MySQL 8.0+ / PostgreSQL 9.2+
- exif PHP extension (on most systems it will be installed by default)
- intl PHP extension (on most systems it will be installed by default)
Expand All @@ -15,7 +15,7 @@
### Composer Require Package

```sh
composer require lunarphp/lunar
composer require lunarphp/lunar:1.0-dev -W
```

### Add the LunarUser Trait
Expand Down Expand Up @@ -51,9 +51,22 @@ This will take you through a set of questions to configure your Lunar install. T
- Seeding initial data
- Inviting you to star our repo on GitHub ⭐

::: tip
You are now installed! You can access the admin hub at `http://<yoursite>/hub`
:::
## Register the admin panel

The admin panel needs registering in your app service provider before you can use it.

```php
use Lunar\Admin\Support\Facades\LunarPanel;

class AppServiceProvider extends ServiceProvider
{
public function register(): void
{
LunarPanel::register();
}
```

You should now be able to access the panel at `https://<yoursite>/lunar`.

## Advanced Installation Options

Expand Down
6 changes: 3 additions & 3 deletions docs/core/local-development.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This guide is here to help you set-up Lunar locally so you can contribute to the

## Before your start

You will need a Laravel application to run Lunar in. You can either use a fresh install of [Laravel](https://laravel.com/docs/installation) or the [Lunar Livewire Starter Kit](https://github.com/lunarphp/livewire-starter-kit).
You will need a Laravel application to run Lunar in.

## Set-Up

Expand All @@ -31,7 +31,7 @@ Fork and then clone the [monorepo](https://github.com/lunarphp/lunar) to the `pa
git clone https://github.com/YOUR-USERNAME/lunar
````
Update your `composer.json` file similar to the following. Note we are targeting `lunar/lunar` and not `lunar/admin`.
Update your `composer.json` file similar to the following.
```json
"repositories": [{
Expand All @@ -41,7 +41,7 @@ Update your `composer.json` file similar to the following. Note we are targeting
}],
"require": {
"lunarphp/lunar": "dev-main",
"lunarphp/lunar": "*",
}
````
Expand Down
87 changes: 0 additions & 87 deletions docs/core/starter-kits.md

This file was deleted.

8 changes: 1 addition & 7 deletions docs/core/upgrading.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,11 @@ Run any migrations
php artisan migrate
```

Re-publish the admin hub assets

```sh
php artisan lunar:hub:install
```

## Support Policy

Lunar currently provides bug fixes and security updates for only the latest minor release, e.g. `0.7`.

## [UNRELEASED]
## 1.0

### High Impact

Expand Down

0 comments on commit 6cfcd73

Please sign in to comment.