Skip to content

Commit

Permalink
chore: change package name + version
Browse files Browse the repository at this point in the history
Version number match with Angular, that is easier to follow-up
  • Loading branch information
Pierre Clavequin committed May 24, 2024
1 parent 7966249 commit 82dfb5c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 28 deletions.
27 changes: 7 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,12 @@

A [lightbox2](https://github.com/lokesh/lightbox2) implementation port to use with new Angular without the need for jQuery

## Version

- For Angular 5, 6, 7, please use ngx-lightbox 1.x.x. `npm install ngx-lightbox@1.2.0`
- For Angular >= 8, please use ngx-lightbox 2.x.x. `npm install ngx-lightbox@2.0.0`
- For Angular 2, 4, please use [angular2-lightbox](https://github.com/themyth92/angular2-lightbox)

## [Demo](https://themyth92.com/project/ngx-lightbox)

## Installation

`npm install --save ngx-lightbox`
`npm install --save @pierresh/ngx-lightbox`

Update your `angular.json`

Expand All @@ -31,10 +26,10 @@ Update your `angular.json`

### Module:

Import `LightboxModule` from `ngx-lightbox`
Import `LightboxModule` from `@pierresh/ngx-lightbox`

```javascript
import { LightboxModule } from 'ngx-lightbox';
import { LightboxModule } from '@pierresh/ngx-lightbox';

@NgModule({
imports: [ LightboxModule ]
Expand All @@ -54,7 +49,7 @@ import { LightboxModule } from 'ngx-lightbox';
2. Component method

```javascript
import { Lightbox } from 'ngx-lightbox';
import { Lightbox } from '@pierresh/ngx-lightbox';

export class AppComponent {
private _album: Array = [];
Expand Down Expand Up @@ -99,7 +94,7 @@ Each `object` of `album` array inside your component may contains 3 properties :
You can listen to 3 events, which are either **CHANGE_PAGE**, **CLOSE** or **OPEN**.

```javascript
import { LightboxEvent, LIGHTBOX_EVENT } from 'ngx-lightbox';
import { LightboxEvent, LIGHTBOX_EVENT } from '@pierresh/ngx-lightbox';
import { Subscription } from 'rxjs';

export class AppComponent {
Expand Down Expand Up @@ -160,7 +155,7 @@ Available options based on lightbox2 options
1. Override default config

```javascript
import { LightboxConfig } from 'ngx-lightbox';
import { LightboxConfig } from '@pierresh/ngx-lightbox';

export class AppComponent {
constructor(private _lightboxConfig: LightboxConfig) {
Expand All @@ -173,7 +168,7 @@ export class AppComponent {
2. Set config in a specific opening window

```javascript
import { LightboxConfig, Lightbox } from 'ngx-lightbox';
import { LightboxConfig, Lightbox } from '@pierresh/ngx-lightbox';

export class AppComponent {
constructor(private _lightboxConfig: LightboxConfig, private _lightbox: Lightbox) {}
Expand Down Expand Up @@ -211,12 +206,4 @@ This project works with universal out of the box with no additional configuratio
MIT
## Donation
Buy me a beer if you like
BTC: 1MFx5waJ7Sitn961DaXe3mQXrb7pEoSJct
ETH: 0x2211F3d683eB1C2d753aD21D9Bd9110729C80B72
NEO: ARrUrnbq1ogfsoabvCgJ5SHgknhzyUmtuS
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "ngx-lightbox",
"version": "3.0.0",
"description": "A port >= angular5 for lightbox2",
"name": "@pierresh/ngx-lightbox",
"version": "17.0.1",
"description": "A port >= Angular 17 for lightbox2",
"main": "index.js",
"dependencies": {
"file-saver": "^2.0.5",
Expand Down Expand Up @@ -39,7 +39,7 @@
"build": "./node_modules/.bin/ng build",
"test": " ./node_modules/.bin/ng lint && ./node_modules/.bin/ng test",
"lint": "./node_modules/.bin/ng lint",
"prepublishOnly": "./node_modules/.bin/ngc && ./node_modules/.bin/copyfiles -u 1 src/img/* src/*.js src/*.d.ts src/*.js.map src/*.metadata.json src/*.css .",
"prepublishOnly": "rm -r ./.angular && ./node_modules/.bin/ngc && ./node_modules/.bin/copyfiles -u 1 src/img/* src/*.js src/*.d.ts src/*.js.map src/*.metadata.json src/*.css .",
"postpublish": "./node_modules/.bin/del '*.{service,component,module,spec,ngfactory}.js' '*.{metadata,ngsummary}.json' index.js webpack.config.js '*.{ts,css,map}' '{compiled,img}' 'src/*.{d.ts,ngfactory.ts,js,map,json}'"
},
"repository": {
Expand Down

0 comments on commit 82dfb5c

Please sign in to comment.