Coder Social home page Coder Social logo

novapackages's Introduction

Nova Packages- Discover new packages. Build amazing things.

Nova Packages

Setting up Passport

  1. php artisan passport:keys
  2. php artisan passport:client --personal

Setting up Scout

  1. Make a new Algolia app
  2. From your Algolia app, copy the Admin API key and ID into your .env. If you see a "Not enough rights to update an object near line:1" error when seeding your database, you're using the Search-Only key—swap it out for the Admin key.
  3. In your Algolia app, create a new index called "packages".
  4. After seeding your database, run php artisan scout:import "App\Package"

Seeding the Database

  1. php artisan db:seed

Setting up GitHub Authentication

  1. Make a new GitHub OAuth application
  2. Set http://novapackages.test/login/github/callback as the Authorized Callback URL
  3. Copy the GitHub app id and secret to GITHUB_CLIENT_ID and GITHUB_CLIENT_SECRET in the .env file
  4. Create a new Personal Access Token with the public_repo scope enabled
  5. Copy the token to GITHUB_TOKEN in the .env file.

Setting up Slack Test Webhook

  1. Add the SLACK_URL variable to your .env to post to a Slack channel of your choosing.

Note: This webhook is hit when certain events are fired. If you are not testing this webhook specifically, you may want to consider commenting it out to avoid sending unnecessary Slack notifications.

Setting up the Filesystem for Screenshots

  1. Run php artisan storage:link

Testing

Some of the tests in this suite depend on an active internet connection, and will run by default. tests/Feature/RepoTest.php provides coverage for the ReadMe import feature, and tests/Feature/CheckPackageUrlsCommandTest.php provides coverage for the command that periodically validates package urls.

For convenience, these tests have been added to the integration group. If you would like to exlude these tests from running, you may do so by using phpunit's --exclude-group option:

phpunit --exclude-group=integration

novapackages's People

Contributors

abordage avatar ahinkle avatar andrewmile avatar andrewminion-luminfire avatar cameronscott137 avatar darkboywonder avatar dependabot[bot] avatar faxblaster avatar idetinkin avatar imanghafoori1 avatar imliam avatar jorqensen avatar laravel-shift avatar marcusmoore avatar mattstauffer avatar muetze42 avatar ordago avatar peter279k avatar rhyslees avatar sbine avatar sebdesign avatar sl0wzer avatar tammytee avatar techenby avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

novapackages's Issues

Fix broken pagination links

image

I set it to ask for one page on either side so we could keep the pagination narrow for mobile, but now we're getting this bug.

Back button breaks homepage in Safari.

When using Safari 13.02 if you navigate from the homepage by clicking on a package name, then click the back button (either the Browser or the link on the page) the filtering on the homepage no longer works.
The console does not show any errors. Clicking a filter link does nothing. Search does not trigger anything either.

filters are missing

in the package list, the sidebar with filters is not showing anymore (chrome , mac , desktop , no zoom)

Search not working DOM wire:id error

The search does not work all the time. This happens since you swapped to livewire.

Reproduce:
Go to the frontpage.
Click on "resource tools"
Enter something in the search input.
Check the console.

error:

Livewire Error:

Cannot find parent element in DOM tree containing attribute: [wire:id].

Usually this is caused by Livewire's DOM-differ not being able to properly track changes.

Reference the following guide for common causes: https://laravel-livewire.com/docs/troubleshooting 

Referenced element:

<g id="Page-1" stroke="none" stroke-width="1" fill-rule="evenodd">
                        <g id="icon-shape">
                            <polygon id="Combined-Shape" points="9.29289322 12.9497475 10 13.6568542 15.6568542 8 14.2426407 6.58578644 10 10.8284271 5.75735931 6.58578644 4.34314575 8"></polygon>
                        </g>
                    </g>
```

Enhancement Request - Star Ratings

From @vootrunner (tightenco/novapackages-issues#45):

Any chance of indicating the date of the last rating for a package (e.g. last rated 15-June-2001) under the rating count? Or perhaps something like "Last rated ** on 01-July-2016"

Packages still feel too much like a roll of the dice. Just bit by another 5 star rated package that just doesn't work.

Show if package is abandoned on the All Packages page

Hi,

Is it possible to show if a package is abandoned on the All Packages page?
Right I regularly stumble upon a nice package, that when clicking trough is abandoned.
It is probably a small thing, but avoids a lot of headache.

I've never really done a pull request, but if that might be the best and fastest way to go, I would love to give it a try :)

Thanks in advanced.

Not able to delete

Hi @mattstauffer

I got an email asking to remove a package if it is no longer maintained. There is not an option I can see to delete the package.

Happy to PR for this if it doesn't exist, but also, I could be dumb/not looking correctly/both and am missing it

Bring back infinite loading?

It's really a pain having to click next-next-next when you just want to browse through packages.
With 83 pages, it makes it really hard to browse and discover something new.

Recently updated packages

From @devmsh (tightenco/novapackages-issues#42):

Some packages are very helpful, but they are not ready to be used in early stage, so I feel that we need another sorting for the latest updated packages, so we can keep an eyes on them and give them another try?

Something wrong with login session handling - doesn't stick

There appears to be something wrong with the session handling of nova packages. Whenever I have closed by browser or stay away for a very short while, I have to log in again. It seems to stay logged in for only one browser session.

Not really sure how I to isolate, but I guess trying to investigate cookie lifetime?

The author id field is required

I can't submit a nova package. I get the message:

The author id field is required

But I have filled in all mandatory fields.

novapackages

add option for "exact matches only" search and/or respect quoted words as being "exact only"

I don't find it useful to be shown search results on "tabs" and "tab" when I search for "tags"

I really only care about seeing packages related to "tags"

I realize what's happening here.. but it's not actually helpful. On google there would be text saying "also showing results for 'tabs', click here to only see results for 'tags'"

Or, on many search engines if I wrapped tags in quotes, it would understand that I only want to see exact matches

Would be nice to see this added.

Thanks for this most useful resources in any case

Lost package ownership after changing github account type to organisation

Long time ago I created a nova package nemrutco/nova-filterable-metrics using a github personal account on novapackages. Then i converted that account type to an organizations on github (nemrutco) and assigned my another personal account (@MuzafferDede) as administrator. I lost ownership on novapackages now.

I think novapackages does not track account type changes on github side after initializing account. Not sure if there is a way to check these changes on github side or a way to link organisations to personal accounts.

Any solution for this issue?

ping @mattstauffer

Using laravel-nova I encountered an error

When I typed in the search box at the top, it reported an error。

[2020-08-27 08:13:36] local.ERROR: Call to a member function getKey() on array {"userId":1,"exception":"[object] (Error(code: 0): Call to a member function getKey() on array at /home/wwwroot/vendor/laravel/framework/src/Illuminate/Support/HigherOrderCollectionProxy.php:60)

Unable to upload audio files

Hi,
Thanks for this awesome package.
I encountered an issue while uploading files. I could successfully upload image files but when i attempted to upload an audio file, it threw an error. Kindly see attached screenshot. I had tried to use Media::make() instead of Files::make() but no headway.
What do I need to change?

Thanks

Resource

`public function fields(Request $request)
{
return [
ID::make(('ID'), 'id')->sortable(),
BelongsTo::make('Album')->showCreateRelationButton(function ($request) {
return true;
})->required(),
Text::make(
('Title'), 'title')->required(),
Markdown::make('Description'),
Text::make(__('Type'), 'type')->required(),
Files::make('Upload Song', 'songs')->required(),

    ];
}`

Model

`class Song extends Model implements HasMedia
{
use InteractsWithMedia;

protected $fillable = ['album_id','title', 'description', 'type'];


public function album()
{
    return $this->belongsTo(Album::class);
}




public function registerMediaCollections(): void
{
        $this
            ->addMediaCollection('songs')
            ->acceptsMimeTypes(['audio/mpeg','video/mpeg'])
            ->singleFile();

}

}
Screenshot at Jan 21 05-27-22
`

Improve handling of Github errors

This is rare but Github doesn't always return JSON when we're expecting it and throws an uncaught exception.

One place this happens is when the SyncPackageRepositoryData job is called. We end up calling app/GitHubRepo::latestRelease() which returns HTML that includes the string We had issues producing the response to your request. Sorry about that. Please try refreshing and contact us if the problem persists.

We can probably check to see if we got an error response and send another request to see if it was just bad luck.

Add to rating stars with github stars & used by

From @LorenzoSapora (tightenco/novapackages-issues#67):

Much like #6, the rating system is underused, and prone to initial gaming. I make a package, I 5 star it (or my puppet account does), and I have instant credibility.

If the cards included at least one of the metrics (used by, watch, star, fork), and possibly all of that information once on the package page itself, the ratings could be more authentic, at a glance.

Fix Scout so Chinese characters don't trigger UTF-8 error on import

This in the readme triggered the error in the Algolia client trying to json_encode:

# nova-amap
Laravel Nova高德地图



#Installation

~~~php
composer require invoice/nova-amap
~~~

~~~php
use Ofancn\Amap\Amap;

public function fields(Request $request) {
        $location = $request->user()->location;
        return [
            ID::make()->sortable(),
            BelongsTo::make(__('用户'), 'user', User::class)->searchable(),
            Text::make(__('名称'), 'name')->sortable()->rules('required', 'string', 'max:255'),
            Amap::make(__('位置'), 'amap')->initLocation($location->latitude ?? 22.56153, $location->longitude ?? 113.4911)->zoom(12)->rules('required', 'json'),
        ];
}
~~~

~~~json
{"lat": 22.097868, "lng": 113.536494, "address": "广东省珠海市香洲区横琴镇环岛东路85珠海长隆海洋王国"}
~~~

Develop a consistent style in the logged-in app

Right now the logged-in sections of the app are all just thrown together.

It'd be nice for them to have a single unified CSS style, general layout, and just ... presence. So they don't feel slapped together.

404 checker

As the ecosystem matures a number of older packages are starting to have issues. The one that could be auto detected are the ones that are giving 404s because links have not been maintained.

Perhaps there can be some kind of scraper on this site that runs through all the links and looks for 404s. If a 404 is found then either the owner is notified or a small minor badge is attached to the detail view of the package to indicate 404 issues.

It's a bit disheartening to look at a package only to find some key links one would rely on no longer exists.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.