mirror of
https://github.com/lnbits/lnbits.git
synced 2025-10-10 20:42:32 +02:00
change prettier and reformat stuff
This commit is contained in:
5
.github/workflows/formatting.yml
vendored
5
.github/workflows/formatting.yml
vendored
@@ -27,12 +27,11 @@ jobs:
|
|||||||
- name: Install packages
|
- name: Install packages
|
||||||
run: |
|
run: |
|
||||||
poetry install
|
poetry install
|
||||||
|
npm install prettier
|
||||||
- name: Check black
|
- name: Check black
|
||||||
run: make checkblack
|
run: make checkblack
|
||||||
- name: Check isort
|
- name: Check isort
|
||||||
run: make checkisort
|
run: make checkisort
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@v3
|
||||||
- name: Check prettier
|
- name: Check prettier
|
||||||
run: |
|
run: make checkprettier
|
||||||
npm install prettier
|
|
||||||
make checkprettier
|
|
||||||
|
8
.prettierignore
Normal file
8
.prettierignore
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
**/.git
|
||||||
|
**/.svn
|
||||||
|
**/.hg
|
||||||
|
**/node_modules
|
||||||
|
|
||||||
|
*.yml
|
||||||
|
|
||||||
|
**/lnbits/static
|
8
Makefile
8
Makefile
@@ -6,8 +6,8 @@ format: prettier isort black
|
|||||||
|
|
||||||
check: mypy pyright pylint flake8 checkisort checkblack checkprettier
|
check: mypy pyright pylint flake8 checkisort checkblack checkprettier
|
||||||
|
|
||||||
prettier: $(shell find lnbits -name "*.js" -o -name ".html")
|
prettier:
|
||||||
./node_modules/.bin/prettier --write lnbits/static/js/*.js lnbits/core/static/js/*.js lnbits/extensions/*/templates/*/*.html ./lnbits/core/templates/core/*.html lnbits/templates/*.html lnbits/extensions/*/static/js/*.js lnbits/extensions/*/static/components/*/*.js lnbits/extensions/*/static/components/*/*.html
|
poetry run ./node_modules/.bin/prettier --write lnbits
|
||||||
|
|
||||||
pyright:
|
pyright:
|
||||||
poetry run ./node_modules/.bin/pyright
|
poetry run ./node_modules/.bin/pyright
|
||||||
@@ -27,8 +27,8 @@ isort:
|
|||||||
pylint:
|
pylint:
|
||||||
poetry run pylint *.py lnbits/ tools/ tests/
|
poetry run pylint *.py lnbits/ tools/ tests/
|
||||||
|
|
||||||
checkprettier: $(shell find lnbits -name "*.js" -o -name ".html")
|
checkprettier:
|
||||||
./node_modules/.bin/prettier --check lnbits/static/js/*.js lnbits/core/static/js/*.js lnbits/extensions/*/templates/*/*.html ./lnbits/core/templates/core/*.html lnbits/templates/*.html lnbits/extensions/*/static/js/*.js lnbits/extensions/*/static/components/*/*.js lnbits/extensions/*/static/components/*/*.html
|
poetry run ./node_modules/.bin/prettier --check lnbits
|
||||||
|
|
||||||
checkblack:
|
checkblack:
|
||||||
poetry run black --check .
|
poetry run black --check .
|
||||||
|
@@ -58,6 +58,5 @@
|
|||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
</q-tab-panel>
|
</q-tab-panel>
|
||||||
|
@@ -395,14 +395,23 @@
|
|||||||
addExtensionsManifest() {
|
addExtensionsManifest() {
|
||||||
const addManifest = this.formAddExtensionsManifest.trim()
|
const addManifest = this.formAddExtensionsManifest.trim()
|
||||||
const manifests = this.formData.lnbits_extensions_manifests
|
const manifests = this.formData.lnbits_extensions_manifests
|
||||||
if (addManifest && addManifest.length && !manifests.includes(addManifest)) {
|
if (
|
||||||
this.formData.lnbits_extensions_manifests = [...manifests, addManifest]
|
addManifest &&
|
||||||
|
addManifest.length &&
|
||||||
|
!manifests.includes(addManifest)
|
||||||
|
) {
|
||||||
|
this.formData.lnbits_extensions_manifests = [
|
||||||
|
...manifests,
|
||||||
|
addManifest
|
||||||
|
]
|
||||||
this.formAddExtensionsManifest = ''
|
this.formAddExtensionsManifest = ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
removeExtensionsManifest(manifest) {
|
removeExtensionsManifest(manifest) {
|
||||||
const manifests = this.formData.lnbits_extensions_manifests
|
const manifests = this.formData.lnbits_extensions_manifests
|
||||||
this.formData.lnbits_extensions_manifests = manifests.filter(m => m !== manifest)
|
this.formData.lnbits_extensions_manifests = manifests.filter(
|
||||||
|
m => m !== manifest
|
||||||
|
)
|
||||||
},
|
},
|
||||||
restartServer() {
|
restartServer() {
|
||||||
LNbits.api
|
LNbits.api
|
||||||
|
@@ -24,17 +24,19 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@media print {
|
@media print {
|
||||||
* {
|
* {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
header, button, #payButtonContainer {
|
header,
|
||||||
|
button,
|
||||||
|
#payButtonContainer {
|
||||||
display: none !important;
|
display: none !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
main, .q-page-container {
|
main,
|
||||||
|
.q-page-container {
|
||||||
padding-top: 0px !important;
|
padding-top: 0px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user