This repository has been archived by the owner on Oct 26, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updating config and move package to organization
- Loading branch information
1 parent
64e2c65
commit cbe7c6a
Showing
17 changed files
with
3,858 additions
and
3,430 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,4 @@ | ||
{ | ||
"presets": [ | ||
"@babel/env", | ||
"@babel/preset-typescript" | ||
], | ||
"presets": ["@babel/env", "@babel/preset-typescript"], | ||
"plugins": ["@babel/plugin-transform-typescript"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
// https://eslint.org/docs/user-guide/configuring | ||
|
||
module.exports = { | ||
root: true, | ||
parser: "@typescript-eslint/parser", | ||
env: { | ||
browser: true, | ||
node: true, | ||
es6: true, | ||
jest: true | ||
jest: true, | ||
}, | ||
|
||
globals: { | ||
page: 'readonly', | ||
lightGallery: 'readonly' | ||
} | ||
// https://github.com/standard/standard/blob/master/docs/RULES-en.md | ||
extends: ["standard", "prettier"], | ||
plugins: ["@typescript-eslint"], | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
18 | ||
20 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
dist | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
{ | ||
"printWidth": 120 | ||
"printWidth": 120, | ||
"semi": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,28 @@ | ||
import { Controller } from '@hotwired/stimulus' | ||
import lightGallery from 'lightgallery' | ||
import { LightGallerySettings } from 'lightgallery/lg-settings' | ||
import { LightGallery } from 'lightgallery/lightgallery' | ||
import { Controller } from "@hotwired/stimulus" | ||
import lightGallery from "lightgallery" | ||
import { LightGallerySettings } from "lightgallery/lg-settings" | ||
import { LightGallery } from "lightgallery/lightgallery" | ||
|
||
export default class extends Controller { | ||
// @ts-ignore | ||
element: HTMLElement | ||
export default class Lightbox extends Controller<HTMLElement> { | ||
optionsValue: LightGallerySettings | ||
lightGallery: LightGallery | ||
|
||
static values = { | ||
options: Object | ||
options: Object, | ||
} | ||
|
||
connect (): void { | ||
connect(): void { | ||
this.lightGallery = lightGallery(this.element, { | ||
...this.defaultOptions, | ||
...this.optionsValue | ||
...this.optionsValue, | ||
}) | ||
} | ||
|
||
disconnect (): void { | ||
disconnect(): void { | ||
this.lightGallery.destroy() | ||
} | ||
|
||
get defaultOptions (): LightGallerySettings { | ||
get defaultOptions(): LightGallerySettings { | ||
return {} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,3 @@ | ||
module.exports = { | ||
content: [ | ||
"./index.html", | ||
"./src/**/*.{js,ts,jsx,tsx}", | ||
], | ||
export default { | ||
content: ["./index.html", "./src/**/*.{js,ts,jsx,tsx}"], | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
{ | ||
"compilerOptions": { | ||
"lib": ["dom", "es6"], | ||
"target": "ES6", | ||
"types": ["vite/client"], | ||
"skipLibCheck": true, | ||
"moduleResolution": "node" | ||
} | ||
"skipLibCheck": true | ||
}, | ||
"exclude": ["node_modules", "spec", "jest"] | ||
} |
Oops, something went wrong.