mirror of
https://github.com/sharevb/it-tools.git
synced 2026-11-25 23:24:09 +03:00
Compare commits
133
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
38fce38ab5 | ||
|
|
632c68df20 | ||
|
|
95ed4e402b | ||
|
|
bcec4020a1 | ||
|
|
920de5b431 | ||
|
|
d7f266bfd7 | ||
|
|
44e81e3025 | ||
|
|
ba663a4fb1 | ||
|
|
8172562fe6 | ||
|
|
49288d0959 | ||
|
|
64a21197af | ||
|
|
a5d15b579e | ||
|
|
87878aa33e | ||
|
|
5882b6a714 | ||
|
|
5c68336170 | ||
|
|
c9b448ce64 | ||
|
|
f90a69c86c | ||
|
|
80a2fb78c3 | ||
|
|
a99744646a | ||
|
|
b489f3aa02 | ||
|
|
2355232aed | ||
|
|
48854592b0 | ||
|
|
e2a6580851 | ||
|
|
9eb888f49b | ||
|
|
648ef7bca6 | ||
|
|
3e1b05fa22 | ||
|
|
386b4fd7a2 | ||
|
|
009864506d | ||
|
|
4c600f0a6d | ||
|
|
3a11b592f3 | ||
|
|
dae5fe60b7 | ||
|
|
99f4f830bb | ||
|
|
8de053540a | ||
|
|
7a48c2fe41 | ||
|
|
665db9b9ec | ||
|
|
dd5ca6f693 | ||
|
|
eaa8b5b672 | ||
|
|
368d088c7e | ||
|
|
00053c3e83 | ||
|
|
6762677a94 | ||
|
|
3b21a6b60e | ||
|
|
58e2fb39b7 | ||
|
|
91f565f839 | ||
|
|
937ddc64c7 | ||
|
|
2593df0ef5 | ||
|
|
9c925ac711 | ||
|
|
2da9832fd9 | ||
|
|
4751417bf6 | ||
|
|
e073f3b99a | ||
|
|
77e76679b0 | ||
|
|
93532cec55 | ||
|
|
b982fa5e56 | ||
|
|
41d24a52e7 | ||
|
|
134a5e829b | ||
|
|
ca12661fa1 | ||
|
|
6cb20b76b1 | ||
|
|
ece277001f | ||
|
|
3564ccfb7d | ||
|
|
4089c6231f | ||
|
|
1829733f3b | ||
|
|
6eccfc126e | ||
|
|
68c56e4742 | ||
|
|
02e40dced8 | ||
|
|
7931c9ba3c | ||
|
|
40d90b94a2 | ||
|
|
bcf93f3824 | ||
|
|
0e9c33ddd3 | ||
|
|
f4d4de8cc3 | ||
|
|
2160e7a894 | ||
|
|
2c12e1e38c | ||
|
|
8efe340740 | ||
|
|
2037d14cd6 | ||
|
|
e99d7b4755 | ||
|
|
35e91b3008 | ||
|
|
af6ccec7ff | ||
|
|
06e4f84749 | ||
|
|
f01d56cd6b | ||
|
|
faaeeb28fa | ||
|
|
520d2cd77f | ||
|
|
2464f1ff3e | ||
|
|
ec865b7595 | ||
|
|
53aa948027 | ||
|
|
5a990ae515 | ||
|
|
4cc875f2d2 | ||
|
|
7ed2e419c6 | ||
|
|
9d0786f15e | ||
|
|
e94e67b8ca | ||
|
|
70194069b5 | ||
|
|
50581c2a36 | ||
|
|
60475933b4 | ||
|
|
a76d7500e6 | ||
|
|
40841c9518 | ||
|
|
2519cc05d1 | ||
|
|
b824880b21 | ||
|
|
74f3ab41bd | ||
|
|
795f713f5c | ||
|
|
c7ab527ccc | ||
|
|
b44367f3e8 | ||
|
|
9750ac5cea | ||
|
|
bf7f986bfd | ||
|
|
33cffc5d73 | ||
|
|
ed875a13b1 | ||
|
|
e63432883e | ||
|
|
ad213e082d | ||
|
|
a768896d43 | ||
|
|
9dd8412e57 | ||
|
|
1a0ab177db | ||
|
|
ce8fcdfa04 | ||
|
|
5b93531eec | ||
|
|
14abe98e07 | ||
|
|
d793d90b3c | ||
|
|
fcfb301bed | ||
|
|
7bc3f3bc18 | ||
|
|
4911afb7b7 | ||
|
|
4613423f01 | ||
|
|
4b9d7ab637 | ||
|
|
f47a9cd0b9 | ||
|
|
e61e3a7f11 | ||
|
|
b89b52d5fd | ||
|
|
bf65b101f6 | ||
|
|
d440fd841c | ||
|
|
08d76f3a83 | ||
|
|
b7d18ca418 | ||
|
|
27d19a6927 | ||
|
|
c64a5fda31 | ||
|
|
120e63601c | ||
|
|
6d868f9182 | ||
|
|
07eea0f484 | ||
|
|
a4ab7db9e4 | ||
|
|
fa7c89cb44 | ||
|
|
e88a2454a4 | ||
|
|
5035cb888c | ||
|
|
d45637cd4f |
No files matched your search
@@ -11,7 +11,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
- run: |
|
||||
echo "Before: corepack version => $(corepack --version || echo 'not installed')"
|
||||
npm install -g corepack@latest
|
||||
|
||||
@@ -37,7 +37,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
|
||||
# Initializes the CodeQL tools for scanning.
|
||||
- name: Initialize CodeQL
|
||||
@@ -55,7 +55,7 @@ jobs:
|
||||
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
||||
# If this step fails, then you should remove it and run the build manually (see below)
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@v2
|
||||
uses: github/codeql-action/autobuild@v3
|
||||
|
||||
# ℹ️ Command-line programs to run using the OS shell.
|
||||
# 📚 https://git.io/JvXDl
|
||||
@@ -69,4 +69,4 @@ jobs:
|
||||
# make release
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v2
|
||||
uses: github/codeql-action/analyze@v3
|
||||
@@ -12,7 +12,7 @@ jobs:
|
||||
outputs:
|
||||
should_run: ${{ steps.should_run.outputs.should_run }}
|
||||
steps:
|
||||
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
- name: print latest_commit
|
||||
run: echo ${{ github.sha }}
|
||||
|
||||
@@ -28,7 +28,7 @@ jobs:
|
||||
if: ${{ needs.check_date.outputs.should_run != 'false' }}
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
- run: |
|
||||
echo "Before: corepack version => $(corepack --version || echo 'not installed')"
|
||||
npm install -g corepack@latest
|
||||
@@ -60,7 +60,7 @@ jobs:
|
||||
steps:
|
||||
# Checkout the repository
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
|
||||
+2
-13
@@ -1,4 +1,4 @@
|
||||
name: Build and Push Docker Image
|
||||
name: Build and Push Docker Image (baseurl-it-tools)
|
||||
|
||||
on:
|
||||
push:
|
||||
@@ -41,7 +41,7 @@ jobs:
|
||||
steps:
|
||||
# Checkout the repository
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
@@ -75,17 +75,6 @@ jobs:
|
||||
sharevb/it-tools:baseurl-it-tools
|
||||
ghcr.io/sharevb/it-tools:baseurl-it-tools
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
file: ./Dockerfile
|
||||
platforms: linux/amd64,linux/arm64
|
||||
push: true
|
||||
tags: |
|
||||
sharevb/it-tools:latest
|
||||
ghcr.io/${{ github.repository_owner }}/it-tools:latest
|
||||
|
||||
# Optionally log out
|
||||
- name: Log out from GitHub Container Registry
|
||||
run: docker logout ghcr.io
|
||||
@@ -0,0 +1,78 @@
|
||||
name: Build and Push Docker Image (latest)
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- chore/all-my-stuffs
|
||||
|
||||
jobs:
|
||||
ci:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- run: |
|
||||
echo "Before: corepack version => $(corepack --version || echo 'not installed')"
|
||||
npm install -g corepack@latest
|
||||
echo "After : corepack version => $(corepack --version)"
|
||||
corepack enable
|
||||
pnpm --version
|
||||
- uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 20
|
||||
cache: 'pnpm'
|
||||
|
||||
- name: Install dependencies
|
||||
run: pnpm i
|
||||
|
||||
- name: Run linters
|
||||
run: pnpm lint
|
||||
|
||||
- name: Run unit tests
|
||||
run: pnpm test
|
||||
|
||||
- name: Build the app
|
||||
run: pnpm build
|
||||
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
- ci
|
||||
steps:
|
||||
# Checkout the repository
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||
|
||||
- name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.repository_owner }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v3
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
file: ./Dockerfile
|
||||
platforms: linux/amd64,linux/arm64
|
||||
push: true
|
||||
tags: |
|
||||
sharevb/it-tools:latest
|
||||
ghcr.io/${{ github.repository_owner }}/it-tools:latest
|
||||
|
||||
# Optionally log out
|
||||
- name: Log out from GitHub Container Registry
|
||||
run: docker logout ghcr.io
|
||||
@@ -12,7 +12,7 @@ jobs:
|
||||
matrix:
|
||||
shard: [1/3, 2/3, 3/3]
|
||||
steps:
|
||||
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
|
||||
- run: |
|
||||
echo "Before: corepack version => $(corepack --version || echo 'not installed')"
|
||||
@@ -37,7 +37,7 @@ jobs:
|
||||
run: pnpm build
|
||||
|
||||
- name: Restore Playwright browsers from cache
|
||||
uses: actions/cache@v3
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.cache/ms-playwright
|
||||
key: ${{ runner.os }}-playwright-${{ steps.playwright-version.outputs.PLAYWRIGHT_VERSION }}-${{ hashFiles('**/playwright.config.ts') }}
|
||||
|
||||
@@ -13,7 +13,7 @@ jobs:
|
||||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
@@ -70,7 +70,7 @@ jobs:
|
||||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
|
||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||
|
||||
- run: |
|
||||
echo "Before: corepack version => $(corepack --version || echo 'not installed')"
|
||||
|
||||
+1064
File diff suppressed because it is too large.
Load diff
@@ -33,6 +33,30 @@ services:
|
||||
- 8080:8080
|
||||
```
|
||||
|
||||
## Filter tools and add home custom content
|
||||
|
||||
You can add custom content in Home page by mounting a `home.custom.md` in `/usr/share/nginx/html`.
|
||||
|
||||
You can filter available tools by mounting `tools-filter.json` in `/usr/share/nginx/html`. It can contains the following filtering regex:
|
||||
```json
|
||||
{
|
||||
"excludeCategoryFilterRegex": "",
|
||||
"includeCategoryFilterRegex": "",
|
||||
"excludeToolsFilterRegex": "",
|
||||
"includeToolsFilterRegex": ""
|
||||
}
|
||||
```
|
||||
Category matches on category (English) names ; Tools matches on tools path/url.
|
||||
|
||||
See (docker-tools-filter-and-home-content)[https://github.com/sharevb/it-tools]
|
||||
|
||||
## To build using a custom default language:
|
||||
|
||||
```
|
||||
docker build -t it-tools-fr --build-arg VITE_LANGUAGE=fr .
|
||||
docker run -d --name it-tools-fr --restart unless-stopped -p 8080:8080 it-tools-fr
|
||||
```
|
||||
|
||||
## Build docker image for a custom subfolder
|
||||
|
||||
According to https://github.com/sharevb/it-tools/pull/461#issuecomment-1602506049 and https://github.com/CorentinTh/it-tools/pull/461:
|
||||
@@ -106,7 +130,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Node.js
|
||||
uses: actions/setup-node@v3
|
||||
@@ -129,7 +153,7 @@ jobs:
|
||||
uses: actions/configure-pages@v3
|
||||
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-pages-artifact@v1
|
||||
uses: actions/upload-pages-artifact@v3
|
||||
with:
|
||||
path: './dist'
|
||||
|
||||
|
||||
Vendored
+69
-24
@@ -11,6 +11,8 @@ declare module '@vue/runtime-core' {
|
||||
export interface GlobalComponents {
|
||||
'404.page': typeof import('./src/pages/404.page.vue')['default']
|
||||
About: typeof import('./src/pages/About.vue')['default']
|
||||
AdLdapSearcher: typeof import('./src/tools/ad-ldap-searcher/ad-ldap-searcher.vue')['default']
|
||||
AgeCrypto: typeof import('./src/tools/age-crypto/age-crypto.vue')['default']
|
||||
AiPromptSplitter: typeof import('./src/tools/ai-prompt-splitter/ai-prompt-splitter.vue')['default']
|
||||
AlarmSoundToggle: typeof import('./src/tools/pomodoro-timer/app/components/AlarmSoundToggle.vue')['default']
|
||||
AngleConverter: typeof import('./src/tools/angle-converter/angle-converter.vue')['default']
|
||||
@@ -25,11 +27,16 @@ declare module '@vue/runtime-core' {
|
||||
BarcodeReader: typeof import('./src/tools/barcode-reader/barcode-reader.vue')['default']
|
||||
'Base.layout': typeof import('./src/layouts/base.layout.vue')['default']
|
||||
Base64FileConverter: typeof import('./src/tools/base64-file-converter/base64-file-converter.vue')['default']
|
||||
Base64HexConverter: typeof import('./src/tools/base64-hex-converter/base64-hex-converter.vue')['default']
|
||||
Base64StringConverter: typeof import('./src/tools/base64-string-converter/base64-string-converter.vue')['default']
|
||||
BashMemo: typeof import('./src/tools/bash-memo/bash-memo.vue')['default']
|
||||
'BashMemo.content': typeof import('./src/tools/bash-memo/bash-memo.content.md')['default']
|
||||
BasicAuthGenerator: typeof import('./src/tools/basic-auth-generator/basic-auth-generator.vue')['default']
|
||||
Bcrypt: typeof import('./src/tools/bcrypt/bcrypt.vue')['default']
|
||||
BenchmarkBuilder: typeof import('./src/tools/benchmark-builder/benchmark-builder.vue')['default']
|
||||
BimiDnsGenerator: typeof import('./src/tools/bimi-dns-generator/bimi-dns-generator.vue')['default']
|
||||
Bip39Generator: typeof import('./src/tools/bip39-generator/bip39-generator.vue')['default']
|
||||
BmiCalculator: typeof import('./src/tools/bmi-calculator/bmi-calculator.vue')['default']
|
||||
BounceParser: typeof import('./src/tools/bounce-parser/bounce-parser.vue')['default']
|
||||
CAlert: typeof import('./src/ui/c-alert/c-alert.vue')['default']
|
||||
'CAlert.demo': typeof import('./src/ui/c-alert/c-alert.demo.vue')['default']
|
||||
@@ -76,15 +83,20 @@ declare module '@vue/runtime-core' {
|
||||
CommandPaletteOption: typeof import('./src/modules/command-palette/components/command-palette-option.vue')['default']
|
||||
CommonRegex: typeof import('./src/tools/common-regex-memo/common-regex.md')['default']
|
||||
CommonRegexMemo: typeof import('./src/tools/common-regex-memo/common-regex-memo.vue')['default']
|
||||
CookiesParser: typeof import('./src/tools/cookies-parser/cookies-parser.vue')['default']
|
||||
Countdown: typeof import('./src/tools/countdown/countdown.vue')['default']
|
||||
Counter: typeof import('./src/tools/pomodoro-timer/app/components/Counter.vue')['default']
|
||||
CrcCalculator: typeof import('./src/tools/crc-calculator/crc-calculator.vue')['default']
|
||||
CronAlarm: typeof import('./src/tools/cron-alarm/cron-alarm.vue')['default']
|
||||
CrontabGenerator: typeof import('./src/tools/crontab-generator/crontab-generator.vue')['default']
|
||||
CSelect: typeof import('./src/ui/c-select/c-select.vue')['default']
|
||||
'CSelect.demo': typeof import('./src/ui/c-select/c-select.demo.vue')['default']
|
||||
CsrGenerator: typeof import('./src/tools/csr-generator/csr-generator.vue')['default']
|
||||
CssPrettifier: typeof import('./src/tools/css-prettifier/css-prettifier.vue')['default']
|
||||
CssSelectorsMemo: typeof import('./src/tools/css-selectors-memo/css-selectors-memo.md')['default']
|
||||
CssSelectors: typeof import('./src/tools/css-selectors-memo/css-selectors.md')['default']
|
||||
CssSelectorsMemo: typeof import('./src/tools/css-selectors-memo/css-selectors-memo.vue')['default']
|
||||
CssXpathConverter: typeof import('./src/tools/css-xpath-converter/css-xpath-converter.vue')['default']
|
||||
CsvToData: typeof import('./src/tools/csv-to-data/csv-to-data.vue')['default']
|
||||
CsvToJson: typeof import('./src/tools/csv-to-json/csv-to-json.vue')['default']
|
||||
CTable: typeof import('./src/ui/c-table/c-table.vue')['default']
|
||||
'CTable.demo': typeof import('./src/ui/c-table/c-table.demo.vue')['default']
|
||||
@@ -93,7 +105,9 @@ declare module '@vue/runtime-core' {
|
||||
CTooltip: typeof import('./src/ui/c-tooltip/c-tooltip.vue')['default']
|
||||
'CTooltip.demo': typeof import('./src/ui/c-tooltip/c-tooltip.demo.vue')['default']
|
||||
CurlConverter: typeof import('./src/tools/curl-converter/curl-converter.vue')['default']
|
||||
CurlGenerator: typeof import('./src/tools/curl-generator/curl-generator.vue')['default']
|
||||
CurrencyConverter: typeof import('./src/tools/currency-converter/currency-converter.vue')['default']
|
||||
DataFaker: typeof import('./src/tools/data-faker/data-faker.vue')['default']
|
||||
DataStorageUnitConverter: typeof import('./src/tools/data-storage-unit-converter/data-storage-unit-converter.vue')['default']
|
||||
DataTransferRateConverter: typeof import('./src/tools/data-transfer-rate-converter/data-transfer-rate-converter.vue')['default']
|
||||
DateDurationCalculator: typeof import('./src/tools/date-duration-calculator/date-duration-calculator.vue')['default']
|
||||
@@ -104,14 +118,20 @@ declare module '@vue/runtime-core' {
|
||||
DeviceInformation: typeof import('./src/tools/device-information/device-information.vue')['default']
|
||||
DiceRoller: typeof import('./src/tools/dice-roller/dice-roller.vue')['default']
|
||||
DiffViewer: typeof import('./src/tools/json-diff/diff-viewer/diff-viewer.vue')['default']
|
||||
DistinctWords: typeof import('./src/tools/distinct-words/distinct-words.vue')['default']
|
||||
DkimDnsGenerator: typeof import('./src/tools/dkim-dns-generator/dkim-dns-generator.vue')['default']
|
||||
DmarcDnsGenerator: typeof import('./src/tools/dmarc-dns-generator/dmarc-dns-generator.vue')['default']
|
||||
DmarcReportAnalyzer: typeof import('./src/tools/dmarc-report-analyzer/dmarc-report-analyzer.vue')['default']
|
||||
DnsQueries: typeof import('./src/tools/dns-queries/dns-queries.vue')['default']
|
||||
Docker: typeof import('./src/tools/docker-memo/docker.md')['default']
|
||||
DockerComposeConverter: typeof import('./src/tools/docker-compose-converter/docker-compose-converter.vue')['default']
|
||||
DockerComposeToDockerRunConverter: typeof import('./src/tools/docker-compose-to-docker-run-converter/docker-compose-to-docker-run-converter.vue')['default']
|
||||
DockerComposeToKubernetes: typeof import('./src/tools/docker-compose-to-kubernetes/docker-compose-to-kubernetes.vue')['default']
|
||||
DockerComposeValidator: typeof import('./src/tools/docker-compose-validator/docker-compose-validator.vue')['default']
|
||||
DockerMemo: typeof import('./src/tools/docker-memo/docker-memo.vue')['default']
|
||||
DockerRunToDockerComposeConverter: typeof import('./src/tools/docker-run-to-docker-compose-converter/docker-run-to-docker-compose-converter.vue')['default']
|
||||
DockerRunToKubernetes: typeof import('./src/tools/docker-run-to-kubernetes/docker-run-to-kubernetes.vue')['default']
|
||||
DuplicateLineFinder: typeof import('./src/tools/duplicate-line-finder/duplicate-line-finder.vue')['default']
|
||||
DurationCalculator: typeof import('./src/tools/duration-calculator/duration-calculator.vue')['default']
|
||||
DynamicValues: typeof import('./src/tools/benchmark-builder/dynamic-values.vue')['default']
|
||||
EcdsaKeyPairGenerator: typeof import('./src/tools/ecdsa-key-pair-generator/ecdsa-key-pair-generator.vue')['default']
|
||||
@@ -126,20 +146,25 @@ declare module '@vue/runtime-core' {
|
||||
EnergyComputer: typeof import('./src/tools/energy-computer/energy-computer.vue')['default']
|
||||
EnergyConverter: typeof import('./src/tools/energy-converter/energy-converter.vue')['default']
|
||||
EtaCalculator: typeof import('./src/tools/eta-calculator/eta-calculator.vue')['default']
|
||||
ExcelToData: typeof import('./src/tools/excel-to-data/excel-to-data.vue')['default']
|
||||
ExtractTextFromHtml: typeof import('./src/tools/extract-text-from-html/extract-text-from-html.vue')['default']
|
||||
FavoriteButton: typeof import('./src/components/FavoriteButton.vue')['default']
|
||||
FileHasher: typeof import('./src/tools/file-hasher/file-hasher.vue')['default']
|
||||
FileType: typeof import('./src/tools/file-type/file-type.vue')['default']
|
||||
FinishedPopup: typeof import('./src/tools/pomodoro-timer/app/components/FinishedPopup.vue')['default']
|
||||
FirewalldGenerator: typeof import('./src/tools/firewalld-generator/firewalld-generator.vue')['default']
|
||||
FloatingPointNumberConverter: typeof import('./src/tools/floating-point-number-converter/floating-point-number-converter.vue')['default']
|
||||
FolderStructureDiagram: typeof import('./src/tools/folder-structure-diagram/folder-structure-diagram.vue')['default']
|
||||
Footer: typeof import('./src/tools/pomodoro-timer/app/components/Footer.vue')['default']
|
||||
ForceConverter: typeof import('./src/tools/force-converter/force-converter.vue')['default']
|
||||
FormatTransformer: typeof import('./src/components/FormatTransformer.vue')['default']
|
||||
FortuneWheel: typeof import('./src/tools/fortune-wheel/fortune-wheel.vue')['default']
|
||||
FstabGenerator: typeof import('./src/tools/fstab-generator/fstab-generator.vue')['default']
|
||||
GeoDistanceCalculator: typeof import('./src/tools/geo-distance-calculator/geo-distance-calculator.vue')['default']
|
||||
GitMemo: typeof import('./src/tools/git-memo/git-memo.vue')['default']
|
||||
'GitMemo.content': typeof import('./src/tools/git-memo/git-memo.content.md')['default']
|
||||
'GitSem.memo': typeof import('./src/tools/git-semantic-commit-memo/git-sem.memo.md')['default']
|
||||
GitSemanticCommitMemo: typeof import('./src/tools/git-semantic-commit-memo/git-semantic-commit-memo.vue')['default']
|
||||
GptTokenEstimator: typeof import('./src/tools/gpt-token-estimator/gpt-token-estimator.vue')['default']
|
||||
GzipConverter: typeof import('./src/tools/gzip-converter/gzip-converter.vue')['default']
|
||||
HarSanitizer: typeof import('./src/tools/har-sanitizer/har-sanitizer.vue')['default']
|
||||
@@ -152,6 +177,7 @@ declare module '@vue/runtime-core' {
|
||||
HmacGenerator: typeof import('./src/tools/hmac-generator/hmac-generator.vue')['default']
|
||||
Home: typeof import('./src/tools/pomodoro-timer/app/views/Home.vue')['default']
|
||||
'Home.page': typeof import('./src/pages/Home.page.vue')['default']
|
||||
HtaccessGenerator: typeof import('./src/tools/htaccess-generator/htaccess-generator.vue')['default']
|
||||
HtmlCleaner: typeof import('./src/tools/html-cleaner/html-cleaner.vue')['default']
|
||||
HtmlEntities: typeof import('./src/tools/html-entities/html-entities.vue')['default']
|
||||
HtmlPrettifier: typeof import('./src/tools/html-prettifier/html-prettifier.vue')['default']
|
||||
@@ -165,9 +191,7 @@ declare module '@vue/runtime-core' {
|
||||
IcalParser: typeof import('./src/tools/ical-parser/ical-parser.vue')['default']
|
||||
IcoConverter: typeof import('./src/tools/ico-converter/ico-converter.vue')['default']
|
||||
'IconMdi:brushVariant': typeof import('~icons/mdi/brush-variant')['default']
|
||||
'IconMdi:contentCopy': typeof import('~icons/mdi/content-copy')['default']
|
||||
'IconMdi:kettleSteamOutline': typeof import('~icons/mdi/kettle-steam-outline')['default']
|
||||
IconMdiArrowRightBottom: typeof import('~icons/mdi/arrow-right-bottom')['default']
|
||||
IconMdiChevronDown: typeof import('~icons/mdi/chevron-down')['default']
|
||||
IconMdiChevronRight: typeof import('~icons/mdi/chevron-right')['default']
|
||||
IconMdiClose: typeof import('~icons/mdi/close')['default']
|
||||
@@ -192,6 +216,7 @@ declare module '@vue/runtime-core' {
|
||||
IpGeoLocation: typeof import('./src/tools/ip-geo-location/ip-geo-location.vue')['default']
|
||||
IpIncludeExclude: typeof import('./src/tools/ip-include-exclude/ip-include-exclude.vue')['default']
|
||||
IpRangeToCidr: typeof import('./src/tools/ip-range-to-cidr/ip-range-to-cidr.vue')['default']
|
||||
IptablesGenerator: typeof import('./src/tools/iptables-generator/iptables-generator.vue')['default']
|
||||
Ipv4AddressConverter: typeof import('./src/tools/ipv4-address-converter/ipv4-address-converter.vue')['default']
|
||||
Ipv4RangeExpander: typeof import('./src/tools/ipv4-range-expander/ipv4-range-expander.vue')['default']
|
||||
Ipv4SubnetCalculator: typeof import('./src/tools/ipv4-subnet-calculator/ipv4-subnet-calculator.vue')['default']
|
||||
@@ -202,14 +227,16 @@ declare module '@vue/runtime-core' {
|
||||
Iso3166Searcher: typeof import('./src/tools/iso-3166-searcher/iso-3166-searcher.vue')['default']
|
||||
JavascriptPrettifier: typeof import('./src/tools/javascript-prettifier/javascript-prettifier.vue')['default']
|
||||
JavascriptToJson: typeof import('./src/tools/javascript-to-json/javascript-to-json.vue')['default']
|
||||
JqMemo: typeof import('./src/tools/jq-memo/jq-memo.md')['default']
|
||||
Jq: typeof import('./src/tools/jq-memo/jq.md')['default']
|
||||
JqMemo: typeof import('./src/tools/jq-memo/jq-memo.vue')['default']
|
||||
JqTester: typeof import('./src/tools/jq-tester/jq-tester.vue')['default']
|
||||
JsonDiff: typeof import('./src/tools/json-diff/json-diff.vue')['default']
|
||||
JsonEditor: typeof import('./src/tools/json-editor/json-editor.vue')['default']
|
||||
JsonEscaper: typeof import('./src/tools/json-escaper/json-escaper.vue')['default']
|
||||
JsonLinter: typeof import('./src/tools/json-linter/json-linter.vue')['default']
|
||||
JsonMinify: typeof import('./src/tools/json-minify/json-minify.vue')['default']
|
||||
JsonpathMemo: typeof import('./src/tools/jsonpath-memo/jsonpath-memo.md')['default']
|
||||
Jsonpath: typeof import('./src/tools/jsonpath-memo/jsonpath.md')['default']
|
||||
JsonpathMemo: typeof import('./src/tools/jsonpath-memo/jsonpath-memo.vue')['default']
|
||||
JsonSizeAnalyzer: typeof import('./src/tools/json-size-analyzer/json-size-analyzer.vue')['default']
|
||||
JsonSortMaster: typeof import('./src/tools/json-sort-master/json-sort-master.vue')['default']
|
||||
JsonStringConverter: typeof import('./src/tools/json-string-converter/json-string-converter.vue')['default']
|
||||
@@ -219,16 +246,24 @@ declare module '@vue/runtime-core' {
|
||||
JsonToJava: typeof import('./src/tools/json-to-java/json-to-java.vue')['default']
|
||||
JsonToJavascript: typeof import('./src/tools/json-to-javascript/json-to-javascript.vue')['default']
|
||||
JsonToObject: typeof import('./src/tools/json-to-object/json-to-object.vue')['default']
|
||||
JsonToPhp: typeof import('./src/tools/json-to-php/json-to-php.vue')['default']
|
||||
JsonToPhpArray: typeof import('./src/tools/json-to-php-array/json-to-php-array.vue')['default']
|
||||
JsonToProtobuf: typeof import('./src/tools/json-to-protobuf/json-to-protobuf.vue')['default']
|
||||
JsonToPython: typeof import('./src/tools/json-to-python/json-to-python.vue')['default']
|
||||
JsonToSchema: typeof import('./src/tools/json-to-schema/json-to-schema.vue')['default']
|
||||
JsonToSqlDdl: typeof import('./src/tools/json-to-sql-ddl/json-to-sql-ddl.vue')['default']
|
||||
JsonToSqlInsert: typeof import('./src/tools/json-to-sql-insert/json-to-sql-insert.vue')['default']
|
||||
JsonToToml: typeof import('./src/tools/json-to-toml/json-to-toml.vue')['default']
|
||||
JsonToTs: typeof import('./src/tools/json-to-ts/json-to-ts.vue')['default']
|
||||
JsonToTypescript: typeof import('./src/tools/json-to-typescript/json-to-typescript.vue')['default']
|
||||
JsonToXml: typeof import('./src/tools/json-to-xml/json-to-xml.vue')['default']
|
||||
JsonToYaml: typeof import('./src/tools/json-to-yaml-converter/json-to-yaml.vue')['default']
|
||||
JsonViewer: typeof import('./src/tools/json-viewer/json-viewer.vue')['default']
|
||||
JsUnobfuscator: typeof import('./src/tools/js-unobfuscator/js-unobfuscator.vue')['default']
|
||||
JwtGenerator: typeof import('./src/tools/jwt-generator/jwt-generator.vue')['default']
|
||||
JwtParser: typeof import('./src/tools/jwt-parser/jwt-parser.vue')['default']
|
||||
K8sMemo: typeof import('./src/tools/k8s-memo/k8s-memo.vue')['default']
|
||||
'K8sMemo.content': typeof import('./src/tools/k8s-memo/k8s-memo.content.md')['default']
|
||||
KeycodeInfo: typeof import('./src/tools/keycode-info/keycode-info.vue')['default']
|
||||
LengthConverter: typeof import('./src/tools/length-converter/length-converter.vue')['default']
|
||||
ListComparer: typeof import('./src/tools/list-comparer/list-comparer.vue')['default']
|
||||
@@ -253,7 +288,7 @@ declare module '@vue/runtime-core' {
|
||||
MenuBarItem: typeof import('./src/tools/html-wysiwyg-editor/editor/menu-bar-item.vue')['default']
|
||||
MenuIconItem: typeof import('./src/components/MenuIconItem.vue')['default']
|
||||
MenuLayout: typeof import('./src/components/MenuLayout.vue')['default']
|
||||
MermaidPreviewer: typeof import('./src/tools/mermaid-previewer/mermaid-previewer.vue')['default']
|
||||
MermaidExporter: typeof import('./src/tools/mermaid-exporter/mermaid-exporter.vue')['default']
|
||||
MetaTagGenerator: typeof import('./src/tools/meta-tag-generator/meta-tag-generator.vue')['default']
|
||||
MicTester: typeof import('./src/tools/mic-tester/mic-tester.vue')['default']
|
||||
MimeConverter: typeof import('./src/tools/mime-converter/mime-converter.vue')['default']
|
||||
@@ -272,25 +307,21 @@ declare module '@vue/runtime-core' {
|
||||
NButton: typeof import('naive-ui')['NButton']
|
||||
NCard: typeof import('naive-ui')['NCard']
|
||||
NCheckbox: typeof import('naive-ui')['NCheckbox']
|
||||
NCheckboxGroup: typeof import('naive-ui')['NCheckboxGroup']
|
||||
NCode: typeof import('naive-ui')['NCode']
|
||||
NCollapseTransition: typeof import('naive-ui')['NCollapseTransition']
|
||||
NColorPicker: typeof import('naive-ui')['NColorPicker']
|
||||
NConfigProvider: typeof import('naive-ui')['NConfigProvider']
|
||||
NDatePicker: typeof import('naive-ui')['NDatePicker']
|
||||
NDataTable: typeof import('naive-ui')['NDataTable']
|
||||
NDivider: typeof import('naive-ui')['NDivider']
|
||||
NDynamicInput: typeof import('naive-ui')['NDynamicInput']
|
||||
NEllipsis: typeof import('naive-ui')['NEllipsis']
|
||||
NForm: typeof import('naive-ui')['NForm']
|
||||
NFormItem: typeof import('naive-ui')['NFormItem']
|
||||
NGi: typeof import('naive-ui')['NGi']
|
||||
NginxFormatter: typeof import('./src/tools/nginx-formatter/nginx-formatter.vue')['default']
|
||||
NGrid: typeof import('naive-ui')['NGrid']
|
||||
NginxMemo: typeof import('./src/tools/nginx-memo/nginx-memo.vue')['default']
|
||||
'NginxMemo.content': typeof import('./src/tools/nginx-memo/nginx-memo.content.md')['default']
|
||||
NH1: typeof import('naive-ui')['NH1']
|
||||
NH3: typeof import('naive-ui')['NH3']
|
||||
NIcon: typeof import('naive-ui')['NIcon']
|
||||
NInput: typeof import('naive-ui')['NInput']
|
||||
NInputGroup: typeof import('naive-ui')['NInputGroup']
|
||||
NInputGroupLabel: typeof import('naive-ui')['NInputGroupLabel']
|
||||
NInputNumber: typeof import('naive-ui')['NInputNumber']
|
||||
NLayout: typeof import('naive-ui')['NLayout']
|
||||
NLayoutSider: typeof import('naive-ui')['NLayoutSider']
|
||||
@@ -300,16 +331,10 @@ declare module '@vue/runtime-core' {
|
||||
NRadio: typeof import('naive-ui')['NRadio']
|
||||
NRadioGroup: typeof import('naive-ui')['NRadioGroup']
|
||||
NScrollbar: typeof import('naive-ui')['NScrollbar']
|
||||
NSelect: typeof import('naive-ui')['NSelect']
|
||||
NSlider: typeof import('naive-ui')['NSlider']
|
||||
NSpace: typeof import('naive-ui')['NSpace']
|
||||
NSpin: typeof import('naive-ui')['NSpin']
|
||||
NStatistic: typeof import('naive-ui')['NStatistic']
|
||||
NSwitch: typeof import('naive-ui')['NSwitch']
|
||||
NTable: typeof import('naive-ui')['NTable']
|
||||
NTabPane: typeof import('naive-ui')['NTabPane']
|
||||
NTabs: typeof import('naive-ui')['NTabs']
|
||||
NText: typeof import('naive-ui')['NText']
|
||||
NTag: typeof import('naive-ui')['NTag']
|
||||
NTimePicker: typeof import('naive-ui')['NTimePicker']
|
||||
NumberInput: typeof import('./src/tools/pomodoro-timer/app/components/NumberInput.vue')['default']
|
||||
NumeronymGenerator: typeof import('./src/tools/numeronym-generator/numeronym-generator.vue')['default']
|
||||
OcrImage: typeof import('./src/tools/ocr-image/ocr-image.vue')['default']
|
||||
@@ -317,13 +342,18 @@ declare module '@vue/runtime-core' {
|
||||
OtpCodeGeneratorAndValidator: typeof import('./src/tools/otp-code-generator-and-validator/otp-code-generator-and-validator.vue')['default']
|
||||
OutlookParser: typeof import('./src/tools/outlook-parser/outlook-parser.vue')['default']
|
||||
ParquetsReader: typeof import('./src/tools/parquets-reader/parquets-reader.vue')['default']
|
||||
PasetoEncryption: typeof import('./src/tools/paseto-encryption/paseto-encryption.vue')['default']
|
||||
PasetoSigning: typeof import('./src/tools/paseto-signing/paseto-signing.vue')['default']
|
||||
PassphraseGenerator: typeof import('./src/tools/passphrase-generator/passphrase-generator.vue')['default']
|
||||
PasswordStrengthAnalyser: typeof import('./src/tools/password-strength-analyser/password-strength-analyser.vue')['default']
|
||||
PasteAsMarkdown: typeof import('./src/tools/paste-as-markdown/paste-as-markdown.vue')['default']
|
||||
PdfConcat: typeof import('./src/tools/pdf-concat/pdf-concat.vue')['default']
|
||||
PdfEncrypt: typeof import('./src/tools/pdf-encrypt/pdf-encrypt.vue')['default']
|
||||
PdfExtract: typeof import('./src/tools/pdf-extract/pdf-extract.vue')['default']
|
||||
PdfLinearize: typeof import('./src/tools/pdf-linearize/pdf-linearize.vue')['default']
|
||||
PdfSignatureChecker: typeof import('./src/tools/pdf-signature-checker/pdf-signature-checker.vue')['default']
|
||||
PdfSignatureDetails: typeof import('./src/tools/pdf-signature-checker/components/pdf-signature-details.vue')['default']
|
||||
PdfTextExtractor: typeof import('./src/tools/pdf-text-extractor/pdf-text-extractor.vue')['default']
|
||||
PdfUnlock: typeof import('./src/tools/pdf-unlock/pdf-unlock.vue')['default']
|
||||
PercentageCalculator: typeof import('./src/tools/percentage-calculator/percentage-calculator.vue')['default']
|
||||
PgpEncryption: typeof import('./src/tools/pgp-encryption/pgp-encryption.vue')['default']
|
||||
@@ -332,23 +362,27 @@ declare module '@vue/runtime-core' {
|
||||
PhpArrayToJson: typeof import('./src/tools/php-array-to-json/php-array-to-json.vue')['default']
|
||||
PinCodeGenerator: typeof import('./src/tools/pin-code-generator/pin-code-generator.vue')['default']
|
||||
PlayPauseBtn: typeof import('./src/tools/pomodoro-timer/app/components/PlayPauseBtn.vue')['default']
|
||||
PomodoroAbout: typeof import('./src/tools/pomodoro-timer/app/views/PomodoroAbout.vue')['default']
|
||||
PomodoroApp: typeof import('./src/tools/pomodoro-timer/app/PomodoroApp.vue')['default']
|
||||
PomodoroTimer: typeof import('./src/tools/pomodoro-timer/pomodoro-timer.vue')['default']
|
||||
PortNumbers: typeof import('./src/tools/port-numbers/port-numbers.vue')['default']
|
||||
Potrace: typeof import('./src/tools/potrace/potrace.vue')['default']
|
||||
PowerConverter: typeof import('./src/tools/power-converter/power-converter.vue')['default']
|
||||
PressureConverter: typeof import('./src/tools/pressure-converter/pressure-converter.vue')['default']
|
||||
ProgressBar: typeof import('./src/tools/pomodoro-timer/app/components/ProgressBar.vue')['default']
|
||||
PropertiesToYaml: typeof import('./src/tools/properties-to-yaml/properties-to-yaml.vue')['default']
|
||||
PropertiesConverter: typeof import('./src/tools/properties-converter/properties-converter.vue')['default']
|
||||
PunycodeConverter: typeof import('./src/tools/punycode-converter/punycode-converter.vue')['default']
|
||||
QrCodeDecoder: typeof import('./src/tools/qr-code-decoder/qr-code-decoder.vue')['default']
|
||||
QrCodeGenerator: typeof import('./src/tools/qr-code-generator/qr-code-generator.vue')['default']
|
||||
QrContactInfoGenerator: typeof import('./src/tools/qr-contact-info-generator/qr-contact-info-generator.vue')['default']
|
||||
QuoteConverter: typeof import('./src/tools/quote-converter/quote-converter.vue')['default']
|
||||
RaidCalculator: typeof import('./src/tools/raid-calculator/raid-calculator.vue')['default']
|
||||
RandomPortGenerator: typeof import('./src/tools/random-port-generator/random-port-generator.vue')['default']
|
||||
RegexMemo: typeof import('./src/tools/regex-memo/regex-memo.vue')['default']
|
||||
'RegexMemo.content': typeof import('./src/tools/regex-memo/regex-memo.content.md')['default']
|
||||
RegexTester: typeof import('./src/tools/regex-tester/regex-tester.vue')['default']
|
||||
RemoveExif: typeof import('./src/tools/remove-exif/remove-exif.vue')['default']
|
||||
RemPxConverter: typeof import('./src/tools/rem-px-converter/rem-px-converter.vue')['default']
|
||||
ResetDropup: typeof import('./src/tools/pomodoro-timer/app/components/ResetDropup.vue')['default']
|
||||
ResultRow: typeof import('./src/tools/ipv4-range-expander/result-row.vue')['default']
|
||||
RmbNumbers: typeof import('./src/tools/rmb-numbers/rmb-numbers.vue')['default']
|
||||
@@ -358,6 +392,8 @@ declare module '@vue/runtime-core' {
|
||||
RsaEcdsaSigning: typeof import('./src/tools/rsa-ecdsa-signing/rsa-ecdsa-signing.vue')['default']
|
||||
RsaEncryption: typeof import('./src/tools/rsa-encryption/rsa-encryption.vue')['default']
|
||||
RsaKeyPairGenerator: typeof import('./src/tools/rsa-key-pair-generator/rsa-key-pair-generator.vue')['default']
|
||||
RsyncGenerator: typeof import('./src/tools/rsync-generator/rsync-generator.vue')['default']
|
||||
RuneConverter: typeof import('./src/tools/rune-converter/rune-converter.vue')['default']
|
||||
SafelinkDecoder: typeof import('./src/tools/safelink-decoder/safelink-decoder.vue')['default']
|
||||
SensitiveDataMasker: typeof import('./src/tools/sensitive-data-masker/sensitive-data-masker.vue')['default']
|
||||
Settings: typeof import('./src/tools/pomodoro-timer/app/views/Settings.vue')['default']
|
||||
@@ -370,12 +406,16 @@ declare module '@vue/runtime-core' {
|
||||
SnowflakeIdExtractor: typeof import('./src/tools/snowflake-id-extractor/snowflake-id-extractor.vue')['default']
|
||||
SoftwareLicenceCompatibility: typeof import('./src/tools/software-licence-compatibility/software-licence-compatibility.vue')['default']
|
||||
SpanCopyable: typeof import('./src/components/SpanCopyable.vue')['default']
|
||||
SpfDnsGenerator: typeof import('./src/tools/spf-dns-generator/spf-dns-generator.vue')['default']
|
||||
SplashScreen: typeof import('./src/tools/pomodoro-timer/app/views/SplashScreen.vue')['default']
|
||||
SqlMinifier: typeof import('./src/tools/sql-minifier/sql-minifier.vue')['default']
|
||||
SqlPrettify: typeof import('./src/tools/sql-prettify/sql-prettify.vue')['default']
|
||||
SslCertConverter: typeof import('./src/tools/ssl-cert-converter/ssl-cert-converter.vue')['default']
|
||||
StacktracePrettier: typeof import('./src/tools/stacktrace-prettier/stacktrace-prettier.vue')['default']
|
||||
StringEscaper: typeof import('./src/tools/string-escaper/string-escaper.vue')['default']
|
||||
StringObfuscator: typeof import('./src/tools/string-obfuscator/string-obfuscator.vue')['default']
|
||||
SvgPlaceholderGenerator: typeof import('./src/tools/svg-placeholder-generator/svg-placeholder-generator.vue')['default']
|
||||
TcpdumpGenerator: typeof import('./src/tools/tcpdump-generator/tcpdump-generator.vue')['default']
|
||||
TemperatureConverter: typeof import('./src/tools/temperature-converter/temperature-converter.vue')['default']
|
||||
TextareaCopyable: typeof import('./src/components/TextareaCopyable.vue')['default']
|
||||
TextDiff: typeof import('./src/tools/text-diff/text-diff.vue')['default']
|
||||
@@ -384,6 +424,7 @@ declare module '@vue/runtime-core' {
|
||||
TextToNatoAlphabet: typeof import('./src/tools/text-to-nato-alphabet/text-to-nato-alphabet.vue')['default']
|
||||
TextToUnicode: typeof import('./src/tools/text-to-unicode/text-to-unicode.vue')['default']
|
||||
TextToUnicodeNames: typeof import('./src/tools/text-to-unicode-names/text-to-unicode-names.vue')['default']
|
||||
TimeAlarm: typeof import('./src/tools/time-alarm/time-alarm.vue')['default']
|
||||
TimezoneConverter: typeof import('./src/tools/timezone-converter/timezone-converter.vue')['default']
|
||||
TokenDisplay: typeof import('./src/tools/otp-code-generator-and-validator/token-display.vue')['default']
|
||||
'TokenGenerator.tool': typeof import('./src/tools/token-generator/token-generator.tool.vue')['default']
|
||||
@@ -392,6 +433,7 @@ declare module '@vue/runtime-core' {
|
||||
'Tool.layout': typeof import('./src/layouts/tool.layout.vue')['default']
|
||||
ToolCard: typeof import('./src/components/ToolCard.vue')['default']
|
||||
TorrentToMagnet: typeof import('./src/tools/torrent-to-magnet/torrent-to-magnet.vue')['default']
|
||||
TraefikComposeMaker: typeof import('./src/tools/traefik-compose-maker/traefik-compose-maker.vue')['default']
|
||||
TtlCalculator: typeof import('./src/tools/ttl-calculator/ttl-calculator.vue')['default']
|
||||
UlidGenerator: typeof import('./src/tools/ulid-generator/ulid-generator.vue')['default']
|
||||
UnicodeCharactersToJavaEntities: typeof import('./src/tools/unicode-characters-to-java-entities-converter/unicode-characters-to-java-entities.vue')['default']
|
||||
@@ -409,6 +451,8 @@ declare module '@vue/runtime-core' {
|
||||
UuidConverter: typeof import('./src/tools/uuid-converter/uuid-converter.vue')['default']
|
||||
UuidGenerator: typeof import('./src/tools/uuid-generator/uuid-generator.vue')['default']
|
||||
VatValidator: typeof import('./src/tools/vat-validator/vat-validator.vue')['default']
|
||||
VimMemo: typeof import('./src/tools/vim-memo/vim-memo.vue')['default']
|
||||
'VimMemo.content': typeof import('./src/tools/vim-memo/vim-memo.content.md')['default']
|
||||
VolumeConverter: typeof import('./src/tools/volume-converter/volume-converter.vue')['default']
|
||||
WebsocketTester: typeof import('./src/tools/websocket-tester/websocket-tester.vue')['default']
|
||||
WeekNumberConverter: typeof import('./src/tools/week-number-converter/week-number-converter.vue')['default']
|
||||
@@ -417,7 +461,8 @@ declare module '@vue/runtime-core' {
|
||||
X509CertificateGenerator: typeof import('./src/tools/x509-certificate-generator/x509-certificate-generator.vue')['default']
|
||||
XmlFormatter: typeof import('./src/tools/xml-formatter/xml-formatter.vue')['default']
|
||||
XmlToJson: typeof import('./src/tools/xml-to-json/xml-to-json.vue')['default']
|
||||
XpathMemo: typeof import('./src/tools/xpath-memo/xpath-memo.md')['default']
|
||||
Xpath: typeof import('./src/tools/xpath-memo/xpath.md')['default']
|
||||
XpathMemo: typeof import('./src/tools/xpath-memo/xpath-memo.vue')['default']
|
||||
XpathTester: typeof import('./src/tools/xpath-tester/xpath-tester.vue')['default']
|
||||
XsltTester: typeof import('./src/tools/xslt-tester/xslt-tester.vue')['default']
|
||||
XVrSpamcauseDecoder: typeof import('./src/tools/x-vr-spamcause-decoder/x-vr-spamcause-decoder.vue')['default']
|
||||
|
||||
+1
-1
@@ -5,4 +5,4 @@ services:
|
||||
pull_policy: always
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- 8080:80
|
||||
- 8080:8080 # Since Docker base image is now nginx-unpriviledged, docker image now listen to 8080 and no more 80.
|
||||
@@ -0,0 +1,10 @@
|
||||
services:
|
||||
it-tools:
|
||||
image: sharevb/it-tools:latest
|
||||
pull_policy: always
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ./tools-filter.json:/usr/share/nginx/html/tools-filter.json
|
||||
- ./home.custom.md:/usr/share/nginx/html/home.custom.md
|
||||
ports:
|
||||
- 8080:8080
|
||||
@@ -0,0 +1,9 @@
|
||||
### Some titles
|
||||
|
||||
Text
|
||||
|
||||
```
|
||||
code
|
||||
```
|
||||
|
||||
And [link](https://sharevb-it-tools.vercel.app/)
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"excludeCategoryFilterRegex": "^(Gaming|Maths|Physics)$",
|
||||
"includeCategoryFilterRegex": "",
|
||||
"excludeToolsFilterRegex": "ai-prompt-splitter",
|
||||
"includeToolsFilterRegex": "illuminance-converter"
|
||||
}
|
||||
+485
@@ -0,0 +1,485 @@
|
||||
home:
|
||||
categories:
|
||||
newestTools: أحدث الأدوات
|
||||
favoriteTools: 'أدواتك المفضلة'
|
||||
allTools: 'جميع الأدوات'
|
||||
favoritesDndToolTip: 'اسحب وأفلت لإعادة ترتيب المفضلة'
|
||||
subtitle: 'أدوات مفيدة للمطورين'
|
||||
toggleMenu: 'تبديل القائمة'
|
||||
home: الصفحة الرئيسية
|
||||
uiLib: 'UI Lib'
|
||||
support: 'ادعم تطوير IT-Tools'
|
||||
buyMeACoffee: 'ادعمنا بشراء قهوة'
|
||||
follow:
|
||||
title: 'هل يعجبك it-tools؟'
|
||||
p1: 'أعطنا نجمة على'
|
||||
githubRepository: 'مستودع IT-Tools على GitHub'
|
||||
p2: 'أو تابعنا على'
|
||||
twitterXAccount: 'حساب IT-Tools على X'
|
||||
thankYou: 'شكرًا لك!'
|
||||
nav:
|
||||
github: 'مستودع GitHub'
|
||||
githubRepository: 'مستودع IT-Tools على GitHub'
|
||||
twitterX: 'حساب X'
|
||||
twitterXAccount: 'حساب IT-Tools على X'
|
||||
about: 'حول IT-Tools'
|
||||
aboutLabel: 'نبذة عن التطبيق'
|
||||
darkMode: 'الوضع الليلي'
|
||||
lightMode: 'الوضع النهاري'
|
||||
mode: 'تبديل الوضع الليلي/النهاري'
|
||||
about:
|
||||
content: >
|
||||
# حول IT-Tools
|
||||
|
||||
هذا الموقع المميز، الذي تم إنشاؤه مع ❤ بواسطة [كورنتين توماسيت](https://corentin.tech?utm_source=it-tools&utm_medium=about)، يجمع أدوات مفيدة للمطورين والأشخاص الذين يعملون في مجال تكنولوجيا المعلومات. إذا وجدته مفيدًا، فلا تتردد في مشاركته مع الأشخاص الذين تعتقد أنهم قد يجدونه مفيدًا أيضًا، ولا تنسى وضع إشارة مرجعية عليه في شريط الاختصارات الخاص بك!
|
||||
|
||||
IT-Tools هو مشروع مجاني ومفتوح المصدر (تحت رخصة GPL-3.0)، وسيظل كذلك، ولكن استضافة الموقع وتجديد اسم النطاق يكلفني المال. إذا كنت ترغب في دعم عملي، وتشجيعي على إضافة المزيد من الأدوات، يرجى التفكير في الدعم من خلال [رعايتي](https://www.buymeacoffee.com/cthmsst).
|
||||
|
||||
## التقنيات المستخدمة
|
||||
|
||||
تم بناء IT Tools باستخدام الاصدار الثالث من Vue.js مع مكتبةNaive UI component ويتم استضافتها ونشرها باستمرار بواسطة Vercel. يتم استخدام مكتبات خارجية مفتوحة المصدر في بعض الأدوات، يمكنك العثور على القائمة الكاملة في ملف [package.json](https://github.com/sharevb/it-tools/blob/main/package.json) في المستودع.
|
||||
|
||||
## هل عثرت على خطأ؟ هل هناك أداة غير متوفرة؟
|
||||
|
||||
إذا كنت بحاجة إلى أداة غير متوفرة حاليًا هنا، وتعتقد أنها يمكن أن تكون مفيدة، فيمكنك إرسال طلب ميزة في [قسم المشكلات](https://github.com/sharevb/it-tools/issues/new/choose) في مستودع GitHub الخاص بنا.
|
||||
|
||||
وإذا اكتشفت وجود خطأ، أو أن شيئًا ما لا يعمل كما هو متوقع، يرجى تقديم تقرير عن الخطأ في [قسم المشكلات](https://github.com/sharevb/it-tools/issues/new/choose) في مستودع GitHub الخاص بنا.
|
||||
|
||||
404:
|
||||
notFound: '404 غير موجود'
|
||||
sorry: 'عذرًا، هذه الصفحة غير موجودة'
|
||||
maybe: 'قد يكون الكاش يعمل بشكل غير متوقع، جرب تحديث الصفحة يدويًا؟'
|
||||
backHome: 'العودة للصفحة الرئيسية'
|
||||
favoriteButton:
|
||||
remove: 'إزالة من المفضلة'
|
||||
add: 'إضافة إلى المفضلة'
|
||||
toolCard:
|
||||
new: جديد
|
||||
search:
|
||||
label: بحث
|
||||
tools:
|
||||
categories:
|
||||
favorite-tools: 'أدواتك المفضلة'
|
||||
crypto: التشفير
|
||||
converter: التحويل
|
||||
web: الويب
|
||||
images and videos: 'الصور والفيديو'
|
||||
development: التطوير
|
||||
network: الشبكة
|
||||
math: الرياضيات
|
||||
measurement: القياس
|
||||
text: النصوص
|
||||
data: البيانات
|
||||
|
||||
password-strength-analyser:
|
||||
title: محلل قوة كلمة المرور
|
||||
description: اكتشف قوة كلمة المرور الخاصة بك باستخدام أداة التحليل هذه التي تعمل على جانب العميل فقط مع تقدير الوقت اللازم لكسرها.
|
||||
|
||||
chronometer:
|
||||
title: مقياس الزمن
|
||||
description: مراقبة مدة حدوث شيء ما. عبارة عن مقياس زمني بميزات أساسية.
|
||||
|
||||
token-generator:
|
||||
title: مولد الرموز
|
||||
description: توليد سلسلة عشوائية بالأحرف التي تريدها بأحرف كبيرة أو صغيرة أو أرقام أو رموز.
|
||||
|
||||
uppercase: أحرف كبيرة (ABC...)
|
||||
lowercase: أحرف صغيرة (abc...)
|
||||
numbers: أرقام (123...)
|
||||
symbols: رموز (!-;...)
|
||||
length: الطول
|
||||
tokenPlaceholder: 'الرمز...'
|
||||
copied: تم نسخ الرمز إلى الحافظة
|
||||
button:
|
||||
copy: نسخ
|
||||
refresh: تحديث
|
||||
percentage-calculator:
|
||||
title: حاسبة النسب المئوية
|
||||
description: احسب النسب المئوية بسهولة بين قيمتين أو من نسبة إلى قيمة.
|
||||
|
||||
svg-placeholder-generator:
|
||||
title: مولد صور SVG مؤقتة
|
||||
description: إنشاء صور SVG لاستخدامها كعناصر نائبة في تطبيقاتك.
|
||||
|
||||
json-to-csv:
|
||||
title: JSON إلى CSV
|
||||
description: تحويل من تنسيق JSON إلى CSV مع الكشف التلقائي للرؤوس.
|
||||
|
||||
csv-to-json:
|
||||
title: CSV إلى JSON
|
||||
description: تحويل من تنسيق CSV إلى JSON مع الكشف التلقائي للرؤوس.
|
||||
|
||||
camera-recorder:
|
||||
title: مسجل الكاميرا
|
||||
description: التقاط صورة أو تسجيل فيديو من كاميرا الويب أو كاميرا الجهاز.
|
||||
|
||||
keycode-info:
|
||||
title: معلومات رموز المفاتيح
|
||||
description: استكشاف الرمز المميز في جافا سكريبت والكود والموقع والمعدِّلات لأي مفتاح يتم الضغط عليه.
|
||||
|
||||
emoji-picker:
|
||||
title: منتقي الرموز التعبيرية
|
||||
description: نسخ ولصق الرموز التعبيرية بسهولة والحصول على الترميز الموحد (Unicode) وقيمة نقطة الرمز (code point) لكل رمز تعبيري.
|
||||
|
||||
color-converter:
|
||||
title: محول الألوان
|
||||
description: تحويل الألوان بين التنسيقات المختلفة (hex, rgb, hsl, وأسماء CSS).
|
||||
|
||||
bcrypt:
|
||||
title: Bcrypt
|
||||
description: تجزئة ومقارنة سلسلة نصية باستخدام Bcrypt .bcrypt هي دالة تجزئة لكلمات المرور تعتمد على تشفير Blowfish.
|
||||
|
||||
crontab-generator:
|
||||
title: مولد Crontab
|
||||
description: توليد تعبيرات crontab والتحقق منها والحصول على وصف سهل القراءة للجدول الزمني للـ cron.
|
||||
|
||||
http-status-codes:
|
||||
title: رموز حالة HTTP
|
||||
description: قائمة تضم كافة رموز حالة HTTP واسمائها ومعانيها.
|
||||
|
||||
sql-prettify:
|
||||
title: تجميل وتنسيق SQL
|
||||
description: تجميل وتنسيق استعلامات SQL الخاصة بك عبر الإنترنت (يدعم العديد من لهجات SQL).
|
||||
|
||||
benchmark-builder:
|
||||
title: صانع مقاييس الأداء
|
||||
description: مقارنة وقت تنفيذ المهام بسهولة باستخدام أداة صنع مقاييس الأداء البسيطة جدًا المتاحة عبر الإنترنت.
|
||||
|
||||
git-memo:
|
||||
title: ملخص أوامر Git
|
||||
description: Git هو برمجية لا مركزية لإدارة الإصدارات. باستخدام هذا الملخص، سوف يكون لديك وصول سريع إلى أوامر git الأكثر شيوعًا.
|
||||
|
||||
slugify-string:
|
||||
title: تهيئة سلسلة نصية كـ Slug
|
||||
description: جعل سلسلة نصية لرابط أو اسم ملف أو معرف آمنة.
|
||||
|
||||
encryption:
|
||||
title: تشفير / فك تشفير النص
|
||||
description: تشفير نص واضح وفك تشفير نص مشفر باستخدام خوارزميات تشفير مثل AES أو TripleDES أو Rabbit أو RC4.
|
||||
|
||||
random-port-generator:
|
||||
title: مولد منفذ عشوائي
|
||||
description: توليد أرقام منافذ عشوائية خارج نطاق المنافذ "المعروفة" (0-1023).
|
||||
|
||||
yaml-prettify:
|
||||
title: تجميل وتنسيق YAML
|
||||
description: تجميل سلسلة نصية بتسنيق YAML إلى صيغة سلسة وسهلة القراءة.
|
||||
|
||||
eta-calculator:
|
||||
title: حاسبة وقت الوصول المتوقع (ETA)
|
||||
description: حاسبة وقت الوصول المتوقع (ETA) لحساب الوقت التقريبي لانتهاء مهمة ما، على سبيل المثال، وقت انتهاء تنزيل ملف ومدته.
|
||||
|
||||
roman-numeral-converter:
|
||||
title: محول الأرقام الرومانية
|
||||
description: تحويل الأرقام الرومانية إلى أرقام والعكس.
|
||||
|
||||
hmac-generator:
|
||||
title: مولد HMAC
|
||||
description: حساب رمز مصادقة الرسائل القائم على التجزئة (HMAC) باستخدام مفتاح سري ودالة التجزئة المفضلة لديك.
|
||||
|
||||
bip39-generator:
|
||||
title: مولد عبارات مرور BIP39
|
||||
description: توليد عبارة مرور BIP39 من عبارة ذاكرة (mnemonic) موجودة أو عشوائية، أو الحصول على عبارة الذاكرة من عبارة المرور.
|
||||
|
||||
base64-file-converter:
|
||||
title: تحويل الملفات إلى Base64
|
||||
description: تحويل سلسلة نصية أو ملف أو صورة إلى تمثيل Base64 الخاص بها.
|
||||
|
||||
list-converter:
|
||||
title: محول القوائم
|
||||
description: يمكن لهذه الأداة معالجة البيانات ذات الأعمدة وتطبيق تغييرات متنوعة (التبديل وإضافة بادئة ولاحقة وعكس القائمة وترتيب القائمة وتحويل القيم إلى أحرف صغيرة وكذلك اقتطاع القيم) لكل الصفوف في القائمة.
|
||||
|
||||
base64-string-converter:
|
||||
title: مرمز Base64 للنصوص
|
||||
description: ترميز النصوص وفك ترميزها بصيغة Base64 بكل بساطة.
|
||||
|
||||
toml-to-yaml:
|
||||
title: تحويل TOML إلى YAML
|
||||
description: تحليل TOML وتحويله إلى YAML.
|
||||
|
||||
math-evaluator:
|
||||
title: محلل رياضي
|
||||
description: آلة حاسبة لتقييم التعابير الرياضية. يمكنك استخدام دوال مثل الجذر التربيعي (sqrt) وجيب التمام (cos) والجيب (sin) والقيمة المطلقة (abs) وغيرها.
|
||||
|
||||
json-to-yaml-converter:
|
||||
title: محول JSON إلى YAML
|
||||
description: تحويل JSON إلى YAML ببساطة عبر الإنترنت باستخدام أداة التحويل هذه.
|
||||
|
||||
json-to-javascript:
|
||||
title: محول JSON إلى JS
|
||||
description: تحويل JSON إلى كائن JavaScript ببساطة عبر الإنترنت باستخدام أداة التحويل هذه.
|
||||
|
||||
javascript-to-json:
|
||||
title: محول JS إلى JSON
|
||||
description: تحويل كائن JavaScript إلى JSON ببساطة عبر الإنترنت باستخدام أداة التحويل هذه.
|
||||
|
||||
url-parser:
|
||||
title: محلل عنوان URL
|
||||
description: تفكيك عنوان URL إلى أجزائه الأساسية (البروتوكول والمصدر والمعاملات والمنفذ واسم المستخدم-كلمة المرور ...)
|
||||
|
||||
iban-validator-and-parser:
|
||||
title: محلل ومدقق رقم الحساب المصرفي الدولي (IBAN)
|
||||
description: تحليل أرقام IBAN والتحقق من صحتها. تحقق مما إذا كان رقم الحساب المصرفي الدولي (IBAN) صالحًا واحصل على البلد ورقم الحساب المصرفي الأساسي (BBAN) في حال إذا كان هذا الرقم يمثل QR-IBAN ويستخدم تنسيق IBAN الملائم.
|
||||
|
||||
user-agent-parser:
|
||||
title: محلل وكيل المستخدم
|
||||
description: تحليل سلسلة نصية لوكيل المستخدم (user-agent) للتعرف على المتصفح والمحرك ونظام التشغيل ووحدة المعالجة المركزية ونوع/طراز الجهاز.
|
||||
|
||||
numeronym-generator:
|
||||
title: مولد الاختصارات الرقمية (Numeronym)
|
||||
description: الاختصار الرقمي (Numeronym) هو مصطلح يشير إلى الكلمة التي يُستخدم فيها رقم لتكوين اختصار. على سبيل المثال، "i18n" هو اختصار رقمي لكلمة "internationalization"، حيث يرمز الرقم 18 إلى عدد الحروف بين أول حرف i وآخر حرف n في الكلمة.
|
||||
|
||||
case-converter:
|
||||
title: محول حالة الأحرف
|
||||
description: تحويل حالة الأحرف في سلسلة نصية مع إمكانية الاختيار من بين صيغ متعددة
|
||||
|
||||
html-entities:
|
||||
title: تهريب كيانات HTML (HTML Entities)
|
||||
description: تهريب أو الغاء تهريب كيانات HTML ( استبدال أحرف مثل < و > و & و " و \' بصيغة HTML الخاصة بها)
|
||||
|
||||
json-prettify:
|
||||
title: تجميل وتنسيق JSON
|
||||
description: تجميل سلسلة نصية بتنسيق JSON إلى صيغة سلسة وسهلة القراءة.
|
||||
|
||||
docker-run-to-docker-compose-converter:
|
||||
title: محول أوامر Docker run إلى Docker compose
|
||||
description: تحويل أوامر "docker run" إلى ملفات docker-compose!
|
||||
|
||||
mac-address-lookup:
|
||||
title: التحقق من عنوان MAC
|
||||
description: العثور على البائع والشركة المصنعة لجهاز ما من خلال عنوان MAC الخاص به.
|
||||
|
||||
mime-types:
|
||||
title: أنواع الوسائط (MIME types)
|
||||
description: تحويل أنواع الوسائط (MIME types) إلى امتدادات ملفات وبالعكس.
|
||||
|
||||
mic-tester:
|
||||
title: أداة اختبار الميكروفون
|
||||
description: تسجيل الصوت من الميكروفون ومن ثم تشغيله مع عرض مرئي له و إضافة ثانية واحدة من التأخير
|
||||
start-button-text: بدء تشغيل الميكروفون
|
||||
stop-button-text: إيقاف تشغيل الميكروفون
|
||||
|
||||
toml-to-json:
|
||||
title: TOML إلى JSON
|
||||
description: تحليل TOML وتحويله إلى JSON.
|
||||
|
||||
lorem-ipsum-generator:
|
||||
title: مولد نصوص Lorem ipsum
|
||||
description: Lorem ipsum هو عبارة عن نص نائب يستخدم عادةً لتوضيح الشكل المرئي لمستند أو محرف دون الاعتماد على محتوى ذو معنى.
|
||||
|
||||
qrcode-generator:
|
||||
title: مولد رمز الاستجابة السريعة (QR Code)
|
||||
description: إنشاء وتنزيل رمز الاستجابة السريعة (QR Code) لعنوان URL (أو لمجرد نص عادي)، وتخصيص ألوان الخلفية والنمط.
|
||||
|
||||
wifi-qrcode-generator:
|
||||
title: مولد رمز الاستجابة السريعة (QR Code) للشبكة اللاسلكية
|
||||
description: إنشاء وتنزيل رموز الاستجابة السريعة (QR Code) للاتصال السريع بالشبكات اللاسلكية.
|
||||
|
||||
qr-contact-info-generator:
|
||||
title: مولد رمز الاستجابة السريعة (QR Code) لمعلومات الاتصال
|
||||
description: إنشاء وتنزيل رموز الاستجابة السريعة (QR Code) لمعلومات الاتصال (vCard)، وتخصيص ألوان الخلفية والنمط.
|
||||
|
||||
xml-formatter:
|
||||
title: منسق XML
|
||||
description: تجميل سلسلة نصية بتنسيق XML إلى هيئة سهلة القراءة من قبل البشر.
|
||||
|
||||
temperature-converter:
|
||||
title: محول درجات الحرارة
|
||||
description: تحويلات لدرجات الحرارة بين وحدات كلفن ومئوية وفهرنهايت ورانكين وديليسل ونيوتن وريومور ورومر.
|
||||
|
||||
chmod-calculator:
|
||||
title: حاسبة أمر Chmod
|
||||
description: حساب أذونات وأوامر chmod الخاصة بك باستخدام هذه الآلة الحاسبة المتوفرة على الويب.
|
||||
|
||||
rsa-key-pair-generator:
|
||||
title: مولد زوج مفاتيح RSA
|
||||
description: توليد زوج مفاتيح RSA عشوائي جديد بصيغة PEM (خاص/عام)
|
||||
|
||||
html-wysiwyg-editor:
|
||||
title: محرر HTML مرئي
|
||||
description: محرر ويب لصفحات HTML (ما تراه هو ما تحصل عليه WYSIWYG). يتيح لك هذ المحرر الحصول على الكود المصدري للمحتوى على الفور.
|
||||
|
||||
yaml-to-toml:
|
||||
title: YAML إلى TOML
|
||||
description: تحليل YAML وتحويله إلى TOML.
|
||||
|
||||
mac-address-generator:
|
||||
title: مولد عناوين MAC
|
||||
description: قم بإدخال الكمية والبادئة. سيتم إنشاء عناوين MAC بالحالة التي اخترتها (أحرف كبيرة أو صغيرة)
|
||||
|
||||
json-diff:
|
||||
title: مقارنة JSON
|
||||
description: مقارنة كائنين بتنسيق JSON وعرض الاختلافات بينهما.
|
||||
|
||||
jwt-parser:
|
||||
title: محلل JWT
|
||||
description: تحليل وفك تشفير رمز JSON Web Token (الذي يُعرف اختصارًا بـ JWT) ثم عرض محتواه.
|
||||
|
||||
date-converter:
|
||||
title: محول الوقت والتاريخ
|
||||
description: تحويل التاريخ والوقت إلى صيغ متعددة
|
||||
|
||||
phone-parser-and-formatter:
|
||||
title: محلل ومنسق رقم الهاتف
|
||||
description: تحليل أرقام الهواتف وتنسيقها والتحقق من صحتها. الحصول على معلومات حول رقم الهاتف، مثل رمز البلد والنوع وما إلى ذلك. وبالإضافة إلى ذلك، إنشاء رابط مباشر لإرسالة رسالة عبر WhatsApp أو رسالة نصية قصيرة (SMS)
|
||||
|
||||
ipv4-subnet-calculator:
|
||||
title: حاسبة الشبكات الفرعية لـ IPv4
|
||||
description: تحليل كتل ترميز CIDR لبروتوكول IPv4 للحصول على كافة المعلومات التي تحتاجها حول شبكتك الفرعية.
|
||||
|
||||
og-meta-generator:
|
||||
title: مولد علامات Open Graph
|
||||
description: توليد علامات HTML الوصفية (meta tags) الخاصة بـ open-graph ومواقع التواصل الاجتماعي لموقعك على الويب.
|
||||
|
||||
ipv6-ula-generator:
|
||||
title: مولد عناوين IPv6 ULA
|
||||
description: توليد عناوين IP محلية خاصة بك وغير قابلة للتوجيه للشبكة الخاصة بك وفقًا لـ RFC4193.
|
||||
|
||||
hash-text:
|
||||
title: تجزئة النص
|
||||
description: 'تجزئة سلسلة نصية باستخدام الدالة التي تريدها : MD5 أو SHA1 أو SHA256 أو SHA256 أو SHA224 أو SHA512 أو SHA384 أو SHA3 أو RIPEMD160'
|
||||
|
||||
json-to-toml:
|
||||
title: JSON إلى TOML
|
||||
description: تحليل JSON وتحويله إلى TOML.
|
||||
|
||||
json-to-ts:
|
||||
title: JSON إلى TS
|
||||
description: تحويل من تنسيق JSON إلى نوع بيانات TS.
|
||||
|
||||
device-information:
|
||||
title: معلومات الجهاز
|
||||
description: الحصول على معلومات حول جهازك الحالي (حجم الشاشة ونسبة البكسل ووكيل المستخدم ...)
|
||||
|
||||
pdf-signature-checker:
|
||||
title: مدقق تواقيع PDF
|
||||
description: التحقق من تواقيع ملف PDF. يحتوي ملف PDF الموقع على توقيع واحد أو أكثر، والتي يمكن استخدامها لتحديد ما إذا كان قد تم إجراء تغييرات على محتويات الملف منذ توقعيه.
|
||||
|
||||
json-sort-master:
|
||||
title: أداة ترتيب JSON
|
||||
description: ترتيب JSON حسب القيم أو المفاتيح .
|
||||
|
||||
json-minify:
|
||||
title: مصغر JSON
|
||||
description: تصغير وضغط بيانات JSON من خلال إزالة المسافات البيضاء غير الضرورية.
|
||||
|
||||
json-string-converter:
|
||||
title: أداة التحويل الى نص بتنسيق JSON
|
||||
description: تحويل النص العادي أو كائنات JavaScript إلى سلسلة نصية بتنسيق JSON وبالعكس.
|
||||
|
||||
ulid-generator:
|
||||
title: مولد ULID
|
||||
description: توليد معرف فريد عالميًا قابل للفرز المعجمي (ULID) بشكل عشوائي.
|
||||
|
||||
string-obfuscator:
|
||||
title: تعتيم سلسلة نصية
|
||||
description: تعتيم سلسلة نصية (مثل سر ما أو رقم الحساب المصرفي الدولي (IBAN) أو رمز معين) لجعلها قابلة للمشاركة والتعرف عليها دون الكشف عن محتواها.
|
||||
|
||||
base-converter:
|
||||
title: محول الأنظمة العددية
|
||||
description: تحويل رقم بين أنظمة عد مختلفة (عشري وسادس عشري وثنائي وثماني وbase64 ...)
|
||||
|
||||
floating-point-converter:
|
||||
title: محول أرقام الفاصلة العائمة (float number)
|
||||
description: تحويل رقم عشري إلى رقم فاصلة عائمة بنظام IEEE 754 الثنائي وبالعكس.
|
||||
|
||||
yaml-to-json-converter:
|
||||
title: محول YAML إلى JSON
|
||||
description: تحويل YAML إلى JSON ببساطة عبر الإنترنت باستخدام أداة التحويل هذه.
|
||||
|
||||
uuid-generator:
|
||||
title: مولد معرفات UUIDs
|
||||
description: المعرف الفريد عالميًا (UUID) هو رقم يتكون من 128 بت يستخدم لتحديد المعلومات في أنظمة الحاسوب. عدد معرفات UUID الممكنة هي 16^32، أي 2^128 وهو ما يساوي 3.4x10^38 (وهو عدد كبير!).
|
||||
|
||||
nanoid-generator:
|
||||
title: مولد معرفات NanoIDs
|
||||
description: إنشاء معرفات عشوائية وفريدة وملائمة لعناوين URL لتطبيقاتك
|
||||
uppercase: أحرف كبيرة
|
||||
lowercase: أحرف صغيرة
|
||||
numbers: أرقام
|
||||
symbols: رموز
|
||||
excludeLookalikes: استبعاد المتشابهة
|
||||
length: الطول
|
||||
quantity: الكمية
|
||||
copied: تم نسخ معرف NanoID إلى الحافظة
|
||||
button:
|
||||
copy: نسخ
|
||||
refresh: تحديث
|
||||
|
||||
|
||||
ipv4-address-converter:
|
||||
title: محول عناوين IPv4
|
||||
description: تحويل عنوان IP إلى رقم عشري أو ثنائي أو سداسي عشري أو حتى صيغة IPv6 له.
|
||||
|
||||
text-statistics:
|
||||
title: إحصائيات النص
|
||||
description: الحصول على معلومات حول نص معين من حيث عدد الأحرف وعدد الكلمات وحجمه بالبايت ...
|
||||
|
||||
text-to-nato-alphabet:
|
||||
title: نص إلى أبجدية الناتو
|
||||
description: تحويل نص إلى أبجدية الناتو الصوتية للإرسال الشفهي.
|
||||
|
||||
basic-auth-generator:
|
||||
title: مولد مصادقة أساسية
|
||||
description: توليد ترويسة مصادقة أساسية مرمزة باستخدام base64 من اسم مستخدم وكلمة مرور.
|
||||
|
||||
text-to-unicode:
|
||||
title: نص إلى الترميز الموحد (Unicode)
|
||||
description: تحليل نص وتحويله إلى رمز موحد (Unicode) وبالعكس
|
||||
|
||||
ipv4-range-expander:
|
||||
title: موسع نطاقات IPv4
|
||||
description: احسب CIDR والمساحة المتاحة من نطاق عناوين IPv4.
|
||||
|
||||
text-diff:
|
||||
title: مقارنة النصوص
|
||||
description: مقارنة بين نصين اثنين والاطلاع على الاختلافات بينهما.
|
||||
|
||||
otp-generator:
|
||||
title: مولد رمز كلمة مرور لمرة واحدة (OTP)
|
||||
description: توليد والتحقق من صحة رمز كلمة مرور لمرة واحدة (OTP) المعتمد على الوقت أو الحدث لإجراء مصادقة متعددة العوامل.
|
||||
|
||||
url-encoder:
|
||||
title: ترميز/فك ترميز السلاسل النصية بصيغة ترميز عنوان URL
|
||||
description: ترميز نص إلى صيغة ترميز عنوان URL (يُعرف أيضًا باسم "ترميز النسبة المئوية")، أو فك ترميز النص المرمز.
|
||||
|
||||
text-to-binary:
|
||||
title: تحويل نص إلى تمثيله الثنائي في UTF-8
|
||||
description: تحويل النص إلى تمثيله الثنائي في UTF-8 وبالعكس.
|
||||
|
||||
image-resizer:
|
||||
title: أداة تغيير حجم الصورة
|
||||
description: تغيير العرض والارتفاع لملف صورة مع عرض معاينة للصورة الجديدة وتنزيلها بالصيغة المرغوبة (.jpg أو .jpeg أو .png أو .bmp أو .ico أو .svg)
|
||||
|
||||
json-to-object:
|
||||
title: JSON إلى object
|
||||
description: تحليل JSON وتحويله إلى كائن.
|
||||
|
||||
multi-link-downloader:
|
||||
title: أداة تنزيل الروابط المتعددة
|
||||
description: التنزيل بشكل غير متزامن من روابط متعددة في ملف مضغوط أو التنزيل من رابط واحد مباشرةً. (يتطلب اتصالاً بالإنترنت)
|
||||
|
||||
unicode-to-java-entities:
|
||||
title: محول أحرف Unicode إلى كيانات جافا
|
||||
description: تحويل أحرف Unicode إلى كيانات جافا وبالعكس
|
||||
|
||||
sip-auth:
|
||||
password: كلمة مرور SIP
|
||||
password-tips: أدخل كلمة المرور...
|
||||
message: نص رسالة SIP
|
||||
message-tips: الصق نص رسالة SIP هنا...
|
||||
result: النتيجة
|
||||
sucess: نجاح
|
||||
failure: فشل
|
||||
|
||||
uuid-converter:
|
||||
title: محول UUID
|
||||
description: تحويل UUID مع واصلة أو بدون واصلة إلى ترميزات SQL الشائعة الأخرى وبالعكس.
|
||||
|
||||
uuid: معرف UUID
|
||||
uuidhexupper: تمثيل في النظام السادس عشري (أحرف كبيرة)
|
||||
uuidhexlower: تمثيل في النظام السادس عشري (أحرف صغيرة)
|
||||
uuidversion: نسخة RFC
|
||||
input:
|
||||
label: النص المدخل
|
||||
placeholder: معرف UUID الخاص بك مع أو بدون واصلة
|
||||
+1
-1
@@ -453,7 +453,7 @@ tools:
|
||||
otp-generator:
|
||||
title: OTP-Code-Generator
|
||||
description: >-
|
||||
Generiere und validiere zeitbasierte OTPs (Einmalpasswörter) für
|
||||
Generiere und validiere zeitbasierte und ereignisgesteuertes OTPs (Einmalpasswörter) für
|
||||
Multi-Faktor-Authentifizierung.
|
||||
url-encoder:
|
||||
title: Kodieren/Decodieren von URL-formatierten Zeichenfolgen
|
||||
|
||||
+721
-6
@@ -156,6 +156,9 @@ tools:
|
||||
encryption:
|
||||
title: Encrypt / decrypt text
|
||||
description: Encrypt clear text and decrypt ciphertext using crypto algorithms like AES, TripleDES, Rabbit or RC4.
|
||||
defaultErrorMessage: Unable to cypher your text
|
||||
title-encrypt: Encrypt
|
||||
title-decrypt: Decrypt
|
||||
|
||||
random-port-generator:
|
||||
title: Random port generator
|
||||
@@ -311,10 +314,6 @@ tools:
|
||||
title: JSON diff
|
||||
description: Compare two JSON objects and get the differences between them.
|
||||
|
||||
jwt-parser:
|
||||
title: JWT parser
|
||||
description: Parse and decode your JSON Web Token (jwt) and display its content.
|
||||
|
||||
date-converter:
|
||||
title: Date-time converter
|
||||
description: Convert date and time into the various different formats
|
||||
@@ -437,7 +436,7 @@ tools:
|
||||
|
||||
otp-generator:
|
||||
title: OTP code generator
|
||||
description: Generate and validate time-based OTP (one time password) for multi-factor authentication.
|
||||
description: Generate and validate time-based and event-based OTP (one time password) for multi-factor authentication.
|
||||
|
||||
url-encoder:
|
||||
title: Encode/decode URL-formatted strings
|
||||
@@ -464,6 +463,9 @@ tools:
|
||||
description: Unicode Characters to Java Entities Converter and vice-versa
|
||||
|
||||
sip-auth:
|
||||
title: SIP Authorization
|
||||
description: This tool helps you to verify the SIP authorization header. The tool performs all calculations in the browser and does not transmit sensitive information over the network, so feel free to use it.
|
||||
|
||||
password: SIP password
|
||||
password-tips: Enter a password...
|
||||
message: SIP message
|
||||
@@ -482,4 +484,717 @@ tools:
|
||||
uuidversion: RFC Version
|
||||
input:
|
||||
label: Your Input
|
||||
placeholder: Your UUID with/without hyphen
|
||||
placeholder: Your UUID with/without hyphen
|
||||
|
||||
ad-ldap-searcher:
|
||||
title: ActiveDirectory LDAP properties searcher
|
||||
description: Search in mapping of LDAP properties and ActiveDirectory UI
|
||||
|
||||
ai-prompt-splitter:
|
||||
title: AI Prompt Splitter
|
||||
description: Split a long document to multiple chat (ie ChatGPT) prompts
|
||||
|
||||
angle-converter:
|
||||
title: Angle Units Converter
|
||||
description: Convert values between angle units
|
||||
|
||||
ansible-vault-crypt-decrypt:
|
||||
title: Ansible vault crypt decrypt
|
||||
description: Encrypt and decrypt Ansible Vault Secrets
|
||||
|
||||
api-tester:
|
||||
title: API Tester
|
||||
description: HTTP API Tester
|
||||
|
||||
area-converter:
|
||||
title: Area Units Converter
|
||||
description: Convert values between area units
|
||||
|
||||
ascii-text-drawer:
|
||||
title: ASCII Text Drawer
|
||||
description: Create ASCII art text with many fonts and styles.
|
||||
|
||||
aspect-ratio-calculator:
|
||||
title: Aspect Ratio Calculator
|
||||
description: Use this ratio calculator to check the dimensions when resizing images.
|
||||
|
||||
barcode-generator:
|
||||
title: Barcode generator
|
||||
description: Barcode generator
|
||||
|
||||
barcode-reader:
|
||||
title: Barcode Reader
|
||||
description: Barcode reader
|
||||
|
||||
base64-hex-converter:
|
||||
title: Base64 Hex array encoder/decoder
|
||||
description: Simply encode and decode Hex array into a their base64 representation.
|
||||
|
||||
bounce-parser:
|
||||
title: Bounce Email Parser
|
||||
description: Parse SMTP Bounce Emails
|
||||
|
||||
card-picker:
|
||||
title: Card Picker
|
||||
description: Generate a deck of playing cards
|
||||
|
||||
certificate-key-parser:
|
||||
title: Certificate/Key parser
|
||||
description: Parse Key and Certificate
|
||||
|
||||
cidr-in-cidr:
|
||||
title: IPv4-6/IPRange/CIDR in IPRange/CIDR/IPMask
|
||||
description: Given a CIDR/IP Range/Wildcard IP/IP Mask, tell if a given IPv4-6/Range/CIDR/Wildcard IP/IP Mask is in subnet range
|
||||
|
||||
code-highlighter:
|
||||
title: Code/Scripts Highlighter
|
||||
description: Highlight programming code fragments
|
||||
|
||||
coin-flipper:
|
||||
title: Coin Flipper
|
||||
description: Flip a coin
|
||||
|
||||
color-contrast-checker:
|
||||
title: Color Contrast Checker
|
||||
description: Check the WCAG constrast level between two colors
|
||||
|
||||
color-wheel:
|
||||
title: Color Wheel
|
||||
description: Choose a color palette/theme using a wheel and mode
|
||||
|
||||
common-regex-memo:
|
||||
title: Common Regex Cheatsheet
|
||||
description: Cheatsheet for common regex patterns
|
||||
|
||||
countdown:
|
||||
title: Countdown
|
||||
description: Countdown and alarm at ellapsed duration
|
||||
|
||||
crc-calculator:
|
||||
title: CRC calculator
|
||||
description: Compute text or file CRC (CRC1, CRC8, CRC8 1-Wire, CRC8 DVB-S2, CRC16, CRC16 CCITT, CRC16 Modbus, CRC16 Kermit, CRC16 XModem, CRC24, CRC32, CRC32 MPEG-2, CRCJAM)
|
||||
|
||||
csr-generator:
|
||||
title: CSR Generator
|
||||
description: Certificate Signing Request generator (PEM format)
|
||||
|
||||
css-prettifier:
|
||||
title: Css prettifier
|
||||
description: CSS Prettify
|
||||
|
||||
css-selectors-memo:
|
||||
title: CSS Selectors Cheatsheet
|
||||
description: CSS Selectors Syntax Cheatsheet
|
||||
|
||||
css-xpath-converter:
|
||||
title: CSS XPath Converter
|
||||
description: Convert CSS selector to/from XPath expression
|
||||
|
||||
curl-converter:
|
||||
title: Curl Converter
|
||||
description: Generate common coding languages version of provided curl command line
|
||||
|
||||
currency-converter:
|
||||
title: Currency Converter
|
||||
description: Convert currency values using https://github.com/fawazahmed0/exchange-api
|
||||
|
||||
data-storage-unit-converter:
|
||||
title: Data Storage Unit converter
|
||||
description: Convert data storage or transfer units (bytes, bibytes, bits, kilobytes...)
|
||||
|
||||
data-transfer-rate-converter:
|
||||
title: Data Transfer Rate Calculator
|
||||
description: Compute Data Transfer times, rates and amount of data
|
||||
|
||||
date-duration-calculator:
|
||||
title: Date+Durations Calculator
|
||||
description: Add/substract durations from a specific date
|
||||
|
||||
days-calculator:
|
||||
title: Days Calculator
|
||||
description: Calculate days interval, holidays, difference, business times
|
||||
|
||||
dice-roller:
|
||||
title: Dice Roller
|
||||
description: RPG Dice Roller using Dice Notation
|
||||
|
||||
dmarc-report-analyzer:
|
||||
title: DMARC Report Analyzer
|
||||
description: Read and display DMARC Xml Reports
|
||||
|
||||
dns-queries:
|
||||
title: DNS Queries
|
||||
description: Perform DNS Queries (over HTTPS)
|
||||
|
||||
docker-compose-converter:
|
||||
title: Docker Compose Format Converter
|
||||
description: Convert Docker Compose file between V1, 2.x, 3.x or CommonSpec and may expand ports/volumes syntaxes
|
||||
|
||||
docker-compose-to-docker-run-converter:
|
||||
title: Docker Compose to Docker run converter
|
||||
description: Turns Docker Compose filt to docker run command(s)!
|
||||
|
||||
docker-compose-to-kubernetes:
|
||||
title: Docker compose to kubernetes
|
||||
description: Docker Compose to Kubernetes manifests
|
||||
|
||||
docker-compose-validator:
|
||||
title: Docker Compose Validator
|
||||
description: Validate Docker Compose files against CommonSpec schema
|
||||
|
||||
docker-memo:
|
||||
title: Docker Cheatsheet
|
||||
description: Docker command memo
|
||||
|
||||
docker-run-to-kubernetes:
|
||||
title: Docker run to kubernetes
|
||||
description: Docker run command(s) to Kubernetes manifests
|
||||
|
||||
duplicate-line-finder:
|
||||
title: Duplicate Lines Finder
|
||||
description: Find and list duplicated lines
|
||||
|
||||
duration-calculator:
|
||||
title: Duration Calculator
|
||||
description: Calculate/parse durations
|
||||
|
||||
ecdsa-key-pair-generator:
|
||||
title: ECDSA key pair generator
|
||||
description: Generate new random ECDSA private and public keys (with or without passphrase).
|
||||
|
||||
ed25519-key-pair-generator:
|
||||
title: Ed25519 key pair generator
|
||||
description: Generate new random Ed25519 private and public keys (with or without passphrase).
|
||||
|
||||
email-normalizer:
|
||||
title: Email normalizer
|
||||
description: Normalize email addresses to a standard format for easier comparison. Useful for deduplication and data cleaning.
|
||||
|
||||
email-parser:
|
||||
title: Email Parser
|
||||
description: Parse and extract information from raw Email content
|
||||
|
||||
energy-computer:
|
||||
title: Energy Consumption and Expense Computer
|
||||
description: Compute energy consumption and expense
|
||||
|
||||
energy-converter:
|
||||
title: Energy Units Converter
|
||||
description: Convert values between energy units
|
||||
|
||||
file-hasher:
|
||||
title: File Hasher
|
||||
description: Compute Hash of files
|
||||
|
||||
file-type:
|
||||
title: File Type Detector
|
||||
description: Identify the type of a file
|
||||
|
||||
folder-structure-diagram:
|
||||
title: Folder Structure Diagram
|
||||
description: tree-like utility for generating ASCII folder structure diagrams
|
||||
|
||||
force-converter:
|
||||
title: Force Units Converter
|
||||
description: Convert values between force units
|
||||
|
||||
geo-distance-calculator:
|
||||
title: Geo distance calculator
|
||||
description: Compute distance between two geo location (and display current user location information)
|
||||
|
||||
gpt-token-estimator:
|
||||
title: GPT Token Estimator
|
||||
description: OpenAI GPT Token Estimator
|
||||
|
||||
gzip-converter:
|
||||
title: GZip/Deflate converter
|
||||
description: Convert text from/to gzip/deflate
|
||||
|
||||
har-sanitizer:
|
||||
title: HAR Sanitizer
|
||||
description: HAR Files Sanitizer
|
||||
|
||||
hdd-calculator:
|
||||
title: HDD calculator
|
||||
description: Storage device manufacturers report capacities in decimal form (like GB), while operating systems and other software uses binary form (GiB), although still incorrectly using the decimal unit (GiB). This tool converts decimal form capacity into various binary forms.
|
||||
|
||||
heic-converter:
|
||||
title: HEIC Converter
|
||||
description: HEIC Converter to JPEG or PNG
|
||||
|
||||
hex-converter:
|
||||
title: Hex Encoder/Decoder
|
||||
description: Encode and decode Hex buffers to number (bits, endianess, sign or floating point or chars) and structures
|
||||
|
||||
hex-file-converter:
|
||||
title: HEX File Converter
|
||||
description: Convert between file and hexadecimal representation
|
||||
|
||||
html-cleaner:
|
||||
title: Html cleaner
|
||||
description: Clean HTML
|
||||
|
||||
html-prettifier:
|
||||
title: Html Prettifier
|
||||
description: Prettify HTML code
|
||||
|
||||
html-to-markdown:
|
||||
title: Html to markdown
|
||||
description: Convert HTML (either from clipboard) to Markdown
|
||||
|
||||
htpasswd-generator:
|
||||
title: Htpasswd/htaccess generator
|
||||
description: htpassword/htaccess user/password generator
|
||||
|
||||
ical-generator:
|
||||
title: ICAL Generator
|
||||
description: Generate ICAL/ICS file from event infos
|
||||
|
||||
ical-merger:
|
||||
title: iCal Merger
|
||||
description: Merge many iCal file to a single
|
||||
|
||||
ical-parser:
|
||||
title: ICAL File Parser
|
||||
description: Parse ICAL/ICS file to event display
|
||||
|
||||
ico-converter:
|
||||
title: ICO/PNG converter
|
||||
description: Convert from PNG/JPEG to/from ICO
|
||||
|
||||
ies-lighting-guidelines:
|
||||
title: IES Lighting Guidelines
|
||||
description: Search in the Illuminating Engineering Society’s (IES) current illuminance recommendations.
|
||||
|
||||
illuminance-converter:
|
||||
title: Illuminance Converter
|
||||
description: Illuminance units converter (Lux, Foot Candles, Nox, Phot, Flame)
|
||||
|
||||
image-converter:
|
||||
title: Image Formats Converter
|
||||
description: Convert images from one format to another
|
||||
|
||||
image-exif-reader:
|
||||
title: Image EXIF/Metadata/GPS/JPEG Quality reader
|
||||
description: Read EXIF, IPTC, XMP, GPS and other metadata, JPEG Quality, and other infos from images files
|
||||
|
||||
image-to-ascii-art:
|
||||
title: Image to ASCII Art
|
||||
description: Image to ASCII Art Generator
|
||||
|
||||
image-to-css:
|
||||
title: Image to CSS
|
||||
description: Convert image to CSS (url, background, ...)
|
||||
|
||||
integers-to-ip:
|
||||
title: Integers to IPv4/IPv6
|
||||
description: Convert integers to IP
|
||||
|
||||
ip-cidr-to-range:
|
||||
title: Ipv4/6 CIDR to IP Range Calculator
|
||||
description: Calculate IP Range from a CIDR (IPv4/6)
|
||||
|
||||
ip-geo-location:
|
||||
title: IP Geo Location
|
||||
description: Retrieve information about an IPv4/6 address or domain location
|
||||
|
||||
ip-include-exclude:
|
||||
title: IP Subnets Exclude Calculator
|
||||
description: Substract a disallowed IP Ranges/Mask/CIDR list from an allowed IP Ranges/Mask/CIDR list
|
||||
|
||||
ip-range-to-cidr:
|
||||
title: IPv4/6 Range to CIDR(s) Calculator
|
||||
description: Calculate CIDR(s) from an IP Range (IPv4/6)
|
||||
|
||||
ipv6-address-converter:
|
||||
title: Ipv6 address converter
|
||||
description: Convert an ip address into decimal, binary, hexadecimal and get infos
|
||||
|
||||
ipv6-subnet-calculator:
|
||||
title: Ipv6 subnet calculator
|
||||
description: Parse your IPv6 CIDR blocks and get all the info you need about your sub network.
|
||||
|
||||
isbn-validator-and-parser:
|
||||
title: ISBN Validator and Parser
|
||||
description: Parse, validate, format and get infos for an ISBN
|
||||
|
||||
iso-3166-searcher:
|
||||
title: ISO 3166 Country Codes Searcher
|
||||
description: Allow searching for Country Code (ISO 3166) and info
|
||||
|
||||
javascript-prettifier:
|
||||
title: Javascript Prettifier
|
||||
description: JS/Javascript Prettifier
|
||||
|
||||
jq-memo:
|
||||
title: Jq Cheatsheet
|
||||
description: JQ command cheatsheet
|
||||
|
||||
jq-tester:
|
||||
title: Jq/JSONPath Tester
|
||||
description: Test jq/JSONPath expression against a JSON content
|
||||
|
||||
js-unobfuscator:
|
||||
title: Javascript Unobfuscator/Unpacker
|
||||
description: webcrack is a tool for reverse engineering javascript. It can deobfuscate obfuscator.io, unminify, transpile, and unpack webpack/browserify, to resemble the original source code as much as possible.
|
||||
|
||||
json-editor:
|
||||
title: JSON Editor
|
||||
description: Edit JSON content
|
||||
|
||||
json-escaper:
|
||||
title: Json Escaper/Unescaper
|
||||
description: Escape and unescape JSON string
|
||||
|
||||
json-linter:
|
||||
title: JSON Linter
|
||||
description: Check and lint JSON content
|
||||
|
||||
json-size-analyzer:
|
||||
title: Json Size Analyzer
|
||||
description: Measure JSON nodes relative weights
|
||||
|
||||
json-to-csharp:
|
||||
title: JSON to C#
|
||||
description: Convert JSON data to C# type definition
|
||||
|
||||
json-to-go:
|
||||
title: JSON to Go
|
||||
description: Convert JSON to Go struct
|
||||
|
||||
json-to-java:
|
||||
title: JSON to Java Entity
|
||||
description: Convert JSON into Java entities
|
||||
|
||||
json-to-php-array:
|
||||
title: Json to PHP-Array
|
||||
description: Convert JSON to PHP Array
|
||||
|
||||
json-to-schema:
|
||||
title: Json to Schema
|
||||
description: Convert JSON data to JSON Schema, MySQL DDL, Mongoose Schema, Google BigQuery schema or ClickHouse Table Schema
|
||||
|
||||
json-to-xml:
|
||||
title: Json to XML
|
||||
description: Convert JSON to XML
|
||||
|
||||
jsonpath-memo:
|
||||
title: JSONPath Syntax Cheatsheet
|
||||
description: JSONPath Syntax Cheatsheet
|
||||
|
||||
jwt-generator:
|
||||
title: JWT Generator
|
||||
description: JWT Token generator and editor
|
||||
|
||||
jwt-parser:
|
||||
title: JWT parser
|
||||
description: Parse and decode your JSON Web Token (jwt) and display its content.
|
||||
|
||||
length-converter:
|
||||
title: Length Units Converter
|
||||
description: Convert values from length units
|
||||
|
||||
list-comparer:
|
||||
title: Lists Comparer
|
||||
description: Compare two list items
|
||||
|
||||
luhn-validator:
|
||||
title: Luhn Validator
|
||||
description: Check and generate key for identifier validated by a Luhn checknum
|
||||
|
||||
mac-address-converter:
|
||||
title: MAC Address Converter
|
||||
description: Change the format of a MAC address and chose between different formats (EUI-48, EUI-64, IPv6)
|
||||
|
||||
many-units-converter:
|
||||
title: Many Units Converter
|
||||
description: Convert all kind of units
|
||||
|
||||
markdown-cheatsheet:
|
||||
title: Markdown Cheat Sheet
|
||||
description: Markdown Cheat Sheet
|
||||
|
||||
markdown-editor:
|
||||
title: Markdown Editor
|
||||
description: Simple Markdown Editor
|
||||
|
||||
markdown-to-html:
|
||||
title: Markdown to HTML
|
||||
description: Convert Markdown to Html and allow to print (as PDF)
|
||||
|
||||
markdown-toc-generator:
|
||||
title: Markdown toc generator
|
||||
description: Generate a TOC from a markdown file/content
|
||||
|
||||
mass-converter:
|
||||
title: Mass Units Converter
|
||||
description: Convert values between mass units
|
||||
|
||||
math-formats-converter:
|
||||
title: Math Formats Converter
|
||||
description: Convert mathematical expression between formats
|
||||
|
||||
math-ocr:
|
||||
title: Math OCR
|
||||
description: Convert Math Formula images to Latex
|
||||
|
||||
mermaid-exporter:
|
||||
title: Mermaid exporter
|
||||
description: Convert Markdown (Mermaid) to image and allow to export to PNG, JPG & SVG
|
||||
|
||||
mime-converter:
|
||||
title: MIME Encoding Converter
|
||||
description: Convert from/to MIME Encoded-Word format (Mail Subject)
|
||||
|
||||
mongo-objectid-converter:
|
||||
title: MongoDB ObjectId Converter
|
||||
description: Convert between MongoDB ObjectId and internal timestamp
|
||||
|
||||
morse-converter:
|
||||
title: Morse Code Converter
|
||||
description: Encode/Decode to Morse code
|
||||
|
||||
my-ip:
|
||||
title: My IP Address
|
||||
description: Get your client IP Address (IPv4/6) using https://www.ipify.org/
|
||||
|
||||
nano-memo:
|
||||
title: Nano CheatSheet
|
||||
description: Nano Editor Cheatsheet
|
||||
|
||||
nginx-formatter:
|
||||
title: Nginx formatter
|
||||
description: Format/prettify Nginx configuration files
|
||||
|
||||
ocr-image:
|
||||
title: OCRize image and PDF
|
||||
description: Perform OCR (Tesseract) on an image or PDF
|
||||
|
||||
option43-generator:
|
||||
title: Option43 generator
|
||||
description: Generate Option43 Wifi DHCP configuration
|
||||
|
||||
outlook-parser:
|
||||
title: Outlook MSG Parser
|
||||
description: Parse Outlook MSG Files
|
||||
|
||||
parquets-reader:
|
||||
title: Parquet files Reader
|
||||
description: Read parquet file as JSON object arrays
|
||||
|
||||
passphrase-generator:
|
||||
title: Passphrase Generator
|
||||
description: Generate random memoizable Passphrases
|
||||
|
||||
paste-as-markdown:
|
||||
title: Paste as Markdown
|
||||
description: Paste cells/tables and links from clipboard content as Markdown
|
||||
|
||||
pdf-encrypt:
|
||||
title: Pdf Encrypt
|
||||
description: Encrypt and add protection to a PDF File
|
||||
|
||||
pdf-linearize:
|
||||
title: Pdf Linearize/FastWeb
|
||||
description: Create a Linearized version of a PDF (turn to FastWeb)
|
||||
|
||||
pdf-unlock:
|
||||
title: Pdf Decrypt and Unlock
|
||||
description: Decrypt a PDF and unlock (remove security permissions)
|
||||
|
||||
pgp-encryption:
|
||||
title: PGP encryption
|
||||
description: Encrypt and decrypt text clear text using PGP Keys.
|
||||
|
||||
pgp-key-pair-generator:
|
||||
title: PGP keygen
|
||||
description: Generate new random PGP private and public keys (with or without passphrase).
|
||||
|
||||
php-array-to-json:
|
||||
title: PHP-Array to JSON
|
||||
description: Convert PHP Array to JSON
|
||||
|
||||
pin-code-generator:
|
||||
title: Pin Code Generator
|
||||
description: Generate Unique PIN (digits) codes
|
||||
|
||||
pomodoro-timer:
|
||||
title: Pomodoro Timer
|
||||
description: Basic Pomodoro Timer
|
||||
|
||||
port-numbers:
|
||||
title: Port Numbers
|
||||
description: Search for assigned usage of a given port and protocol
|
||||
|
||||
potrace:
|
||||
title: Image to SVG (potrace)
|
||||
description: Convert an raster image to vectorial SVG
|
||||
|
||||
power-converter:
|
||||
title: Power Converter
|
||||
description: Convert values between power units
|
||||
|
||||
pressure-converter:
|
||||
title: Pressure Units Converter
|
||||
description: Convert values between pressure units
|
||||
|
||||
properties-to-yaml:
|
||||
title: Properties to YAML
|
||||
description: Convert Java .properties content to Yaml
|
||||
|
||||
raid-calculator:
|
||||
title: RAID Calculator
|
||||
description: Calculate storage capacity, fault tolerance and space efficiency of an array based on the number of disks, size, and RAID type
|
||||
|
||||
regex-memo:
|
||||
title: Regex cheatsheet
|
||||
description: Javascript Regex/Regular Expression cheatsheet
|
||||
|
||||
regex-tester:
|
||||
title: Regex Tester
|
||||
description: Test your regular expressions with sample text.
|
||||
|
||||
rem-px-converter:
|
||||
title: REM Pixel converter
|
||||
description: Convert px to rem and vice versa
|
||||
|
||||
remove-exif:
|
||||
title: Remove EXIF
|
||||
description: Remove Exif from JPEG Files
|
||||
|
||||
rmb-numbers:
|
||||
title: RMB Uppercase Converter
|
||||
description: RMB/Renminbi Capitalization Conversion Tool
|
||||
|
||||
rsa-ecdsa-signing:
|
||||
title: RSA/DSA/ECDSA Signer and Verifier
|
||||
description: Sign data and verify signature using RSA/DSA/ECDSA Keys
|
||||
|
||||
rsa-encryption:
|
||||
title: RSA encryption
|
||||
description: Encrypt and decrypt text clear text using RSA Keys.
|
||||
|
||||
rune-converter:
|
||||
title: Rune converter
|
||||
description: Convert Text to Runes and vice-versa
|
||||
|
||||
safelink-decoder:
|
||||
title: Outlook Safelink decoder
|
||||
description: Decode Outlook SafeLink links
|
||||
|
||||
sensitive-data-masker:
|
||||
title: Sensitive data masker
|
||||
description: Clean sensitive data from textual content (ie logs)
|
||||
|
||||
sharepoint-decoder:
|
||||
title: Sharepoint Share Url Decoder
|
||||
description: Decode sharepoint.com share urls to "normal" Sharepoint Url
|
||||
|
||||
sla-calculator:
|
||||
title: SLA calculator
|
||||
description: Service Level Agreement Calcultator
|
||||
|
||||
smart-raw-converter:
|
||||
title: SMART Raw Converter
|
||||
description: Convert SMART Raw values to human readable
|
||||
|
||||
smart-text-replacer:
|
||||
title: Smart Text Replacer and Linebreaker
|
||||
description: Search and replace a word on single or multiple occurrences just like windows notepad search and replace. Also allows to manage linebreaking and text splitting
|
||||
|
||||
snowflake-id-extractor:
|
||||
title: Snowflake ID extractor
|
||||
description: Extract timestamp, machine ID, and sequence number from a Snowflake ID
|
||||
|
||||
software-licence-compatibility:
|
||||
title: Software licence compatibility
|
||||
description: Software Licence compatibility checker and information
|
||||
|
||||
ssl-cert-converter:
|
||||
title: SSL Certificate converter
|
||||
description: Convert SSL Certificate from different formats
|
||||
|
||||
stacktrace-prettier:
|
||||
title: Stacktrace prettier
|
||||
description: Highlight .Net and JS stacktraces
|
||||
|
||||
timezone-converter:
|
||||
title: Timezone Converter
|
||||
description: Convert Date-Time from a timezone to others and get timezone vs countries infos
|
||||
|
||||
torrent-to-magnet:
|
||||
title: Torrent to Magnet
|
||||
description: Convert a torrent file to a Magnet url
|
||||
|
||||
ttl-calculator:
|
||||
title: TTL calculator
|
||||
description: TTL to Time converter
|
||||
|
||||
unicode-formatter:
|
||||
title: Unicode Formatter
|
||||
description: Format text using Unicode fonts
|
||||
|
||||
unicode-search:
|
||||
title: Unicode Search
|
||||
description: Search in Unicode Characters
|
||||
|
||||
url-cleaner:
|
||||
title: Url Cleaner
|
||||
description: Clean Ads tracker, UTM, Facebook and other ads provider parameters from an URL
|
||||
|
||||
url-fanger:
|
||||
title: Url Fanger
|
||||
description: Defang/Refang an URL or email address
|
||||
|
||||
url-text-fragment-maker:
|
||||
title: Url Text Search Fragment Maker
|
||||
description: Create url that allows linking directly to a specific portion of text in a web document
|
||||
|
||||
utm-url-generator:
|
||||
title: UTM Url Generator
|
||||
description: Generate an URL with utm_ parameters
|
||||
|
||||
vat-validator:
|
||||
title: VAT Numbers Validator
|
||||
description: Validate VAT Numbers
|
||||
|
||||
volume-converter:
|
||||
title: Volume Units Converter
|
||||
description: Convert values from volume units
|
||||
|
||||
websocket-tester:
|
||||
title: Websocket tester
|
||||
description: Allows to test WebSocket connections
|
||||
|
||||
week-number-converter:
|
||||
title: Week Numbers Converter
|
||||
description: Convert between ISO Week number, Week number in month and date
|
||||
|
||||
wpa-psk-generator:
|
||||
title: WPA PSK generator
|
||||
description: WPA Pre-shared Key Generator to convert a WPA passphrase and SSID to the 256-bit pre-shared ("raw") key
|
||||
|
||||
x-vr-spamcause-decoder:
|
||||
title: X-VR-SpamCause Decoder
|
||||
description: Decode X-VR-SPAMCAUSE header in OVH mails
|
||||
|
||||
x509-certificate-generator:
|
||||
title: X509 certificate generator
|
||||
description: Generate a self signed SSL/x509 certificate
|
||||
|
||||
xml-to-json:
|
||||
title: XML to Json
|
||||
description: Convert XML to JSON
|
||||
|
||||
xpath-memo:
|
||||
title: XPath Syntax Cheatsheet
|
||||
description: XPath Syntax Cheatsheet
|
||||
|
||||
xpath-tester:
|
||||
title: XPath Tester
|
||||
description: Test XPath expression against XML content
|
||||
|
||||
xslt-tester:
|
||||
title: XSLT tester
|
||||
description: Allows to test XML transformation using XSLT Stylesheets
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ home:
|
||||
favoriteTools: 'Suas ferramentas favoritas'
|
||||
allTools: 'Todas as ferramentas'
|
||||
favoritesDndToolTip: 'Arraste e solte para reordenar favoritos'
|
||||
subtitle: 'Ferraentas úteis para desenvolvedores'
|
||||
subtitle: 'Ferramentas úteis para desenvolvedores'
|
||||
toggleMenu: 'Menu'
|
||||
home: 'Início'
|
||||
uiLib: 'Biblioteca de UI'
|
||||
|
||||
+1186
File diff suppressed because it is too large.
Load diff
+1112
-3
File diff suppressed because it is too large.
Load diff
@@ -6,6 +6,7 @@ server {
|
||||
index index.html;
|
||||
|
||||
location / {
|
||||
rewrite ^/it-tools/(.*) /$1 break;
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
}
|
||||
+39
-8
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "it-tools",
|
||||
"type": "module",
|
||||
"version": "2025.2.9-b99a19c",
|
||||
"version": "2025.4.21-70194069",
|
||||
"packageManager": "pnpm@9.11.0",
|
||||
"description": "Collection of handy online tools for developers, with great UX. ",
|
||||
"author": "Corentin Th <corentin.thomasset74+it-tools@gmail.com> (https://corentin.tech)",
|
||||
@@ -40,6 +40,7 @@
|
||||
"@chenfengyuan/vue-barcode": "^2.0.2",
|
||||
"@date-fns/utc": "^1.2.0",
|
||||
"@dice-roller/rpg-dice-roller": "^5.5.1",
|
||||
"@faker-js/faker": "^9.7.0",
|
||||
"@fortawesome/fontawesome-svg-core": "^6.7.2",
|
||||
"@fortawesome/free-solid-svg-icons": "^6.7.2",
|
||||
"@fortawesome/vue-fontawesome": "^3.0.8",
|
||||
@@ -53,6 +54,7 @@
|
||||
"@kenjiuno/decompressrtf": "^0.1.4",
|
||||
"@kenjiuno/msgreader": "^1.22.0",
|
||||
"@mdit/plugin-align": "^0.16.0",
|
||||
"@noble/ciphers": "^1.2.1",
|
||||
"@regexper/render": "^1.0.0",
|
||||
"@sindresorhus/slugify": "^2.2.1",
|
||||
"@tabler/icons-vue": "^3.20.0",
|
||||
@@ -69,6 +71,7 @@
|
||||
"@tiptap/starter-kit": "2.9.1",
|
||||
"@tiptap/vue-3": "2.9.1",
|
||||
"@types/haversine": "^1.1.8",
|
||||
"@types/moment": "^2.13.0",
|
||||
"@unicode/unicode-15.1.0": "^1.6.5",
|
||||
"@vicons/material": "^0.12.0",
|
||||
"@vicons/tabler": "^0.12.0",
|
||||
@@ -78,12 +81,14 @@
|
||||
"@xmldom/xmldom": "^0.8.10",
|
||||
"@younestouati/playing-cards-standard-deck": "^6.0.1",
|
||||
"@zxing/library": "^0.21.3",
|
||||
"a11y-color-contrast": "^0.2.0",
|
||||
"aircodes": "^1.3.16",
|
||||
"ansible-vault": "^1.3.0",
|
||||
"apache-md5": "^1.1.8",
|
||||
"arr-diff": "^4.0.0",
|
||||
"bcryptjs": "^2.4.3",
|
||||
"big.js": "^6.2.2",
|
||||
"braces": "^3.0.3",
|
||||
"bwip-js": "^4.5.1",
|
||||
"byte-data": "^19.0.1",
|
||||
"change-case": "^5.4.4",
|
||||
@@ -91,7 +96,7 @@
|
||||
"chinesegen": "^0.3.3",
|
||||
"cidr-tools": "^11.0.2",
|
||||
"colord": "^2.9.3",
|
||||
"composerize": "^1.7.1",
|
||||
"composerize": "^1.7.2",
|
||||
"composeverter": "^1.7.4",
|
||||
"convert": "^5.7.0",
|
||||
"countries-and-timezones": "^3.7.2",
|
||||
@@ -101,6 +106,7 @@
|
||||
"cron-parser": "^4.9.0",
|
||||
"cron-validator": "^1.3.1",
|
||||
"cronstrue": "^2.54.0",
|
||||
"cross-spawn": "^7.0.6",
|
||||
"crypto-js": "^4.2.0",
|
||||
"csstoxpath": "^2.0.0",
|
||||
"curlconverter": "^4.12.0",
|
||||
@@ -110,6 +116,7 @@
|
||||
"date-fns": "^2.30.0",
|
||||
"date-holidays": "^3.23.21",
|
||||
"decomposerize": "^1.4.4",
|
||||
"detect-csv": "^1.1.0",
|
||||
"dmarc-report-parser": "^0.1.5",
|
||||
"dns-query": "^0.11.2",
|
||||
"docker2kube": "^0.0.14",
|
||||
@@ -129,6 +136,7 @@
|
||||
"figue": "^1.2.0",
|
||||
"file-type": "^20.1.0",
|
||||
"flatten-anything": "^4.0.1",
|
||||
"flexsearch": "^0.8.167",
|
||||
"fuse.js": "^7.1.0",
|
||||
"generate-schema": "^2.6.0",
|
||||
"get-timezone-offset": "^1.0.5",
|
||||
@@ -160,7 +168,7 @@
|
||||
"jks-js": "^1.1.4",
|
||||
"jose": "^5.9.6",
|
||||
"jpeg-quality-estimator": "^1.0.1",
|
||||
"jq-wasm": "^0.0.9",
|
||||
"jq-wasm": "^1.0.0",
|
||||
"js-base64": "^3.7.7",
|
||||
"js-beautify": "^1.15.2",
|
||||
"jsbarcode": "^3.11.6",
|
||||
@@ -171,6 +179,8 @@
|
||||
"jsonar-mod": "^1.9.0",
|
||||
"jsonlint-mod": "^1.7.6",
|
||||
"jsonpath": "^1.1.1",
|
||||
"jsonrepair": "^3.12.0",
|
||||
"jsonschema-protobuf": "^1.0.2",
|
||||
"jsstack.js": "^2.0.0",
|
||||
"jsvat-next": "^3.0.4",
|
||||
"jszip": "^3.10.1",
|
||||
@@ -195,20 +205,25 @@
|
||||
"mathjs": "^14.2.1",
|
||||
"md-editor-v3": "^4.21.3",
|
||||
"memorystream": "^0.3.1",
|
||||
"mermaid": "^11.6.0",
|
||||
"mime-types": "^2.1.35",
|
||||
"mitex-wasm": "^0.2.5",
|
||||
"moment": "^2.30.1",
|
||||
"monaco-editor": "^0.43.0",
|
||||
"morsee": "^1.0.10",
|
||||
"naive-ui": "^2.35.0",
|
||||
"nanoid": "^5.0.9",
|
||||
"nanoid-dictionary": "^4.3.0",
|
||||
"nestify-anything": "^3.0.3",
|
||||
"netmask": "^2.0.2",
|
||||
"netstack.js": "^2.1.1",
|
||||
"nginx-config-formatter": "^1.4.5",
|
||||
"node-forge": "^1.3.1",
|
||||
"openpgp": "^6.1.0",
|
||||
"openpgp": "^6.1.1",
|
||||
"oui-data": "^1.1.281",
|
||||
"parse-duration": "^2.1.2",
|
||||
"parse-torrent": "^11.0.18",
|
||||
"paseto-ts": "^2.0.5",
|
||||
"path2d-polyfill": "^3.1.3",
|
||||
"pdf-signature-reader": "^1.4.3",
|
||||
"pdfjs-dist": "^4.8.69",
|
||||
@@ -219,14 +234,17 @@
|
||||
"potrace": "^2.1.8",
|
||||
"pp-qr-code": "^0.6.4",
|
||||
"pretty-ms": "^9.2.0",
|
||||
"properties": "^1.2.1",
|
||||
"punycode": "^2.3.1",
|
||||
"pythonstack.js": "^1.0.2",
|
||||
"qpdf-wasm-esm-embedded": "^1.1.1",
|
||||
"qrcode": "^1.5.4",
|
||||
"qrcode-parser": "^2.1.3",
|
||||
"qrcode-terminal-nooctal": "^0.12.1",
|
||||
"quicktype-core": "^23.1.3",
|
||||
"randexp": "^0.5.3",
|
||||
"regex": "^4.4.0",
|
||||
"riimut": "^0.9.1",
|
||||
"roboto-base64": "^0.1.2",
|
||||
"rtf-stream-parser": "^3.8.0",
|
||||
"safe-license-list": "^0.1.2",
|
||||
@@ -238,37 +256,43 @@
|
||||
"spdx-satisfies": "^5.0.1",
|
||||
"sql-formatter": "^15.5.1",
|
||||
"sshpk": "^1.18.0",
|
||||
"staveless-futhark": "^0.6.1",
|
||||
"stringify-object": "^5.0.0",
|
||||
"svg2png-wasm": "^1.4.1",
|
||||
"svgo": "^3.3.2",
|
||||
"tesseract.js": "^5.1.1",
|
||||
"text-encoding-utf-8": "^1.0.2",
|
||||
"tidy-url": "^1.18.3",
|
||||
"to-double-quotes": "^4.0.0",
|
||||
"to-single-quotes": "^4.0.0",
|
||||
"turndown": "^7.2.0",
|
||||
"ua-parser-js": "^2.0.1",
|
||||
"ulid": "^2.3.0",
|
||||
"unicode-emoji-json": "^0.4.0",
|
||||
"unique-random": "^4.0.0",
|
||||
"unixcrypt-browser": "^2.0.4",
|
||||
"unpdf": "^1.0.5",
|
||||
"unplugin-auto-import": "^0.16.4",
|
||||
"utf8": "^3.0.0",
|
||||
"uuid": "^11.0.5",
|
||||
"vanilla-jsoneditor": "^0.23.8",
|
||||
"vue": "^3.3.4",
|
||||
"vue-color-wheel": "^0.1.1",
|
||||
"vue-i18n": "^9.9.1",
|
||||
"vue-i18n": "^9.14.3",
|
||||
"vue-markdown-render": "^2.2.1",
|
||||
"vue-mathjax-next": "^0.0.6",
|
||||
"vue-mermaid-string": "^7.0.0",
|
||||
"vue-router": "^4.1.6",
|
||||
"vue-shadow-dom": "^4.2.0",
|
||||
"vue-tsc": "^1.8.1",
|
||||
"vue3-flip-countdown": "^0.1.6",
|
||||
"vue3-fortune-wheel": "^2.0.5",
|
||||
"vuedraggable": "^4.1.0",
|
||||
"vuex": "^4.1.0",
|
||||
"w-websocket-client": "^1.0.29",
|
||||
"wcag-contrast-utils": "^1.0.1",
|
||||
"webcrack": "^2.15.0",
|
||||
"webcrypto-liner-shim": "^1.4.8",
|
||||
"webp-converter-browser": "^1.0.4",
|
||||
"xlsx": "https://cdn.sheetjs.com/xlsx-0.20.2/xlsx-0.20.2.tgz",
|
||||
"xml-formatter": "^3.6.4",
|
||||
"xml-js": "^1.6.11",
|
||||
"xpath": "^0.0.34",
|
||||
@@ -334,18 +358,25 @@
|
||||
"jsdom": "^22.0.0",
|
||||
"less": "^4.2.2",
|
||||
"prettier": "^3.0.0",
|
||||
"semver": "^7.5.2",
|
||||
"typescript": "~5.2.2",
|
||||
"unocss": "^0.57.1",
|
||||
"unocss-preset-scrollbar": "^0.2.1",
|
||||
"unplugin-icons": "^0.17.0",
|
||||
"unplugin-vue-components": "^0.25.0",
|
||||
"vite": "^4.4.9",
|
||||
"vite-plugin-node-polyfills": "^0.22.0",
|
||||
"vite-plugin-node-polyfills": "^0.23.0",
|
||||
"vite-plugin-pwa": "^1.0.0",
|
||||
"vite-plugin-vue-markdown": "^0.23.5",
|
||||
"vite-plugin-wasm": "^3.4.1",
|
||||
"vite-svg-loader": "^4.0.0",
|
||||
"vitest": "^0.34.6",
|
||||
"workbox-window": "^7.3.0",
|
||||
"zx": "^7.2.3"
|
||||
},
|
||||
"pnpm": {
|
||||
"overrides": {
|
||||
"xlsx": "https://cdn.sheetjs.com/xlsx-0.20.2/xlsx-0.20.2.tgz"
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
+1434
-955
File diff suppressed because it is too large.
Load diff
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,575 @@
|
||||
// Copyright 2018 The Go Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
"use strict";
|
||||
|
||||
(() => {
|
||||
const enosys = () => {
|
||||
const err = new Error("not implemented");
|
||||
err.code = "ENOSYS";
|
||||
return err;
|
||||
};
|
||||
|
||||
if (!globalThis.fs) {
|
||||
let outputBuf = "";
|
||||
globalThis.fs = {
|
||||
constants: { O_WRONLY: -1, O_RDWR: -1, O_CREAT: -1, O_TRUNC: -1, O_APPEND: -1, O_EXCL: -1, O_DIRECTORY: -1 }, // unused
|
||||
writeSync(fd, buf) {
|
||||
outputBuf += decoder.decode(buf);
|
||||
const nl = outputBuf.lastIndexOf("\n");
|
||||
if (nl != -1) {
|
||||
console.log(outputBuf.substring(0, nl));
|
||||
outputBuf = outputBuf.substring(nl + 1);
|
||||
}
|
||||
return buf.length;
|
||||
},
|
||||
write(fd, buf, offset, length, position, callback) {
|
||||
if (offset !== 0 || length !== buf.length || position !== null) {
|
||||
callback(enosys());
|
||||
return;
|
||||
}
|
||||
const n = this.writeSync(fd, buf);
|
||||
callback(null, n);
|
||||
},
|
||||
chmod(path, mode, callback) { callback(enosys()); },
|
||||
chown(path, uid, gid, callback) { callback(enosys()); },
|
||||
close(fd, callback) { callback(enosys()); },
|
||||
fchmod(fd, mode, callback) { callback(enosys()); },
|
||||
fchown(fd, uid, gid, callback) { callback(enosys()); },
|
||||
fstat(fd, callback) { callback(enosys()); },
|
||||
fsync(fd, callback) { callback(null); },
|
||||
ftruncate(fd, length, callback) { callback(enosys()); },
|
||||
lchown(path, uid, gid, callback) { callback(enosys()); },
|
||||
link(path, link, callback) { callback(enosys()); },
|
||||
lstat(path, callback) { callback(enosys()); },
|
||||
mkdir(path, perm, callback) { callback(enosys()); },
|
||||
open(path, flags, mode, callback) { callback(enosys()); },
|
||||
read(fd, buffer, offset, length, position, callback) { callback(enosys()); },
|
||||
readdir(path, callback) { callback(enosys()); },
|
||||
readlink(path, callback) { callback(enosys()); },
|
||||
rename(from, to, callback) { callback(enosys()); },
|
||||
rmdir(path, callback) { callback(enosys()); },
|
||||
stat(path, callback) { callback(enosys()); },
|
||||
symlink(path, link, callback) { callback(enosys()); },
|
||||
truncate(path, length, callback) { callback(enosys()); },
|
||||
unlink(path, callback) { callback(enosys()); },
|
||||
utimes(path, atime, mtime, callback) { callback(enosys()); },
|
||||
};
|
||||
}
|
||||
|
||||
if (!globalThis.process) {
|
||||
globalThis.process = {
|
||||
getuid() { return -1; },
|
||||
getgid() { return -1; },
|
||||
geteuid() { return -1; },
|
||||
getegid() { return -1; },
|
||||
getgroups() { throw enosys(); },
|
||||
pid: -1,
|
||||
ppid: -1,
|
||||
umask() { throw enosys(); },
|
||||
cwd() { throw enosys(); },
|
||||
chdir() { throw enosys(); },
|
||||
}
|
||||
}
|
||||
|
||||
if (!globalThis.path) {
|
||||
globalThis.path = {
|
||||
resolve(...pathSegments) {
|
||||
return pathSegments.join("/");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!globalThis.crypto) {
|
||||
throw new Error("globalThis.crypto is not available, polyfill required (crypto.getRandomValues only)");
|
||||
}
|
||||
|
||||
if (!globalThis.performance) {
|
||||
throw new Error("globalThis.performance is not available, polyfill required (performance.now only)");
|
||||
}
|
||||
|
||||
if (!globalThis.TextEncoder) {
|
||||
throw new Error("globalThis.TextEncoder is not available, polyfill required");
|
||||
}
|
||||
|
||||
if (!globalThis.TextDecoder) {
|
||||
throw new Error("globalThis.TextDecoder is not available, polyfill required");
|
||||
}
|
||||
|
||||
const encoder = new TextEncoder("utf-8");
|
||||
const decoder = new TextDecoder("utf-8");
|
||||
|
||||
globalThis.Go = class {
|
||||
constructor() {
|
||||
this.argv = ["js"];
|
||||
this.env = {};
|
||||
this.exit = (code) => {
|
||||
if (code !== 0) {
|
||||
console.warn("exit code:", code);
|
||||
}
|
||||
};
|
||||
this._exitPromise = new Promise((resolve) => {
|
||||
this._resolveExitPromise = resolve;
|
||||
});
|
||||
this._pendingEvent = null;
|
||||
this._scheduledTimeouts = new Map();
|
||||
this._nextCallbackTimeoutID = 1;
|
||||
|
||||
const setInt64 = (addr, v) => {
|
||||
this.mem.setUint32(addr + 0, v, true);
|
||||
this.mem.setUint32(addr + 4, Math.floor(v / 4294967296), true);
|
||||
}
|
||||
|
||||
const setInt32 = (addr, v) => {
|
||||
this.mem.setUint32(addr + 0, v, true);
|
||||
}
|
||||
|
||||
const getInt64 = (addr) => {
|
||||
const low = this.mem.getUint32(addr + 0, true);
|
||||
const high = this.mem.getInt32(addr + 4, true);
|
||||
return low + high * 4294967296;
|
||||
}
|
||||
|
||||
const loadValue = (addr) => {
|
||||
const f = this.mem.getFloat64(addr, true);
|
||||
if (f === 0) {
|
||||
return undefined;
|
||||
}
|
||||
if (!isNaN(f)) {
|
||||
return f;
|
||||
}
|
||||
|
||||
const id = this.mem.getUint32(addr, true);
|
||||
return this._values[id];
|
||||
}
|
||||
|
||||
const storeValue = (addr, v) => {
|
||||
const nanHead = 0x7FF80000;
|
||||
|
||||
if (typeof v === "number" && v !== 0) {
|
||||
if (isNaN(v)) {
|
||||
this.mem.setUint32(addr + 4, nanHead, true);
|
||||
this.mem.setUint32(addr, 0, true);
|
||||
return;
|
||||
}
|
||||
this.mem.setFloat64(addr, v, true);
|
||||
return;
|
||||
}
|
||||
|
||||
if (v === undefined) {
|
||||
this.mem.setFloat64(addr, 0, true);
|
||||
return;
|
||||
}
|
||||
|
||||
let id = this._ids.get(v);
|
||||
if (id === undefined) {
|
||||
id = this._idPool.pop();
|
||||
if (id === undefined) {
|
||||
id = this._values.length;
|
||||
}
|
||||
this._values[id] = v;
|
||||
this._goRefCounts[id] = 0;
|
||||
this._ids.set(v, id);
|
||||
}
|
||||
this._goRefCounts[id]++;
|
||||
let typeFlag = 0;
|
||||
switch (typeof v) {
|
||||
case "object":
|
||||
if (v !== null) {
|
||||
typeFlag = 1;
|
||||
}
|
||||
break;
|
||||
case "string":
|
||||
typeFlag = 2;
|
||||
break;
|
||||
case "symbol":
|
||||
typeFlag = 3;
|
||||
break;
|
||||
case "function":
|
||||
typeFlag = 4;
|
||||
break;
|
||||
}
|
||||
this.mem.setUint32(addr + 4, nanHead | typeFlag, true);
|
||||
this.mem.setUint32(addr, id, true);
|
||||
}
|
||||
|
||||
const loadSlice = (addr) => {
|
||||
const array = getInt64(addr + 0);
|
||||
const len = getInt64(addr + 8);
|
||||
return new Uint8Array(this._inst.exports.mem.buffer, array, len);
|
||||
}
|
||||
|
||||
const loadSliceOfValues = (addr) => {
|
||||
const array = getInt64(addr + 0);
|
||||
const len = getInt64(addr + 8);
|
||||
const a = new Array(len);
|
||||
for (let i = 0; i < len; i++) {
|
||||
a[i] = loadValue(array + i * 8);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
const loadString = (addr) => {
|
||||
const saddr = getInt64(addr + 0);
|
||||
const len = getInt64(addr + 8);
|
||||
return decoder.decode(new DataView(this._inst.exports.mem.buffer, saddr, len));
|
||||
}
|
||||
|
||||
const testCallExport = (a, b) => {
|
||||
this._inst.exports.testExport0();
|
||||
return this._inst.exports.testExport(a, b);
|
||||
}
|
||||
|
||||
const timeOrigin = Date.now() - performance.now();
|
||||
this.importObject = {
|
||||
_gotest: {
|
||||
add: (a, b) => a + b,
|
||||
callExport: testCallExport,
|
||||
},
|
||||
gojs: {
|
||||
// Go's SP does not change as long as no Go code is running. Some operations (e.g. calls, getters and setters)
|
||||
// may synchronously trigger a Go event handler. This makes Go code get executed in the middle of the imported
|
||||
// function. A goroutine can switch to a new stack if the current stack is too small (see morestack function).
|
||||
// This changes the SP, thus we have to update the SP used by the imported function.
|
||||
|
||||
// func wasmExit(code int32)
|
||||
"runtime.wasmExit": (sp) => {
|
||||
sp >>>= 0;
|
||||
const code = this.mem.getInt32(sp + 8, true);
|
||||
this.exited = true;
|
||||
delete this._inst;
|
||||
delete this._values;
|
||||
delete this._goRefCounts;
|
||||
delete this._ids;
|
||||
delete this._idPool;
|
||||
this.exit(code);
|
||||
},
|
||||
|
||||
// func wasmWrite(fd uintptr, p unsafe.Pointer, n int32)
|
||||
"runtime.wasmWrite": (sp) => {
|
||||
sp >>>= 0;
|
||||
const fd = getInt64(sp + 8);
|
||||
const p = getInt64(sp + 16);
|
||||
const n = this.mem.getInt32(sp + 24, true);
|
||||
fs.writeSync(fd, new Uint8Array(this._inst.exports.mem.buffer, p, n));
|
||||
},
|
||||
|
||||
// func resetMemoryDataView()
|
||||
"runtime.resetMemoryDataView": (sp) => {
|
||||
sp >>>= 0;
|
||||
this.mem = new DataView(this._inst.exports.mem.buffer);
|
||||
},
|
||||
|
||||
// func nanotime1() int64
|
||||
"runtime.nanotime1": (sp) => {
|
||||
sp >>>= 0;
|
||||
setInt64(sp + 8, (timeOrigin + performance.now()) * 1000000);
|
||||
},
|
||||
|
||||
// func walltime() (sec int64, nsec int32)
|
||||
"runtime.walltime": (sp) => {
|
||||
sp >>>= 0;
|
||||
const msec = (new Date).getTime();
|
||||
setInt64(sp + 8, msec / 1000);
|
||||
this.mem.setInt32(sp + 16, (msec % 1000) * 1000000, true);
|
||||
},
|
||||
|
||||
// func scheduleTimeoutEvent(delay int64) int32
|
||||
"runtime.scheduleTimeoutEvent": (sp) => {
|
||||
sp >>>= 0;
|
||||
const id = this._nextCallbackTimeoutID;
|
||||
this._nextCallbackTimeoutID++;
|
||||
this._scheduledTimeouts.set(id, setTimeout(
|
||||
() => {
|
||||
this._resume();
|
||||
while (this._scheduledTimeouts.has(id)) {
|
||||
// for some reason Go failed to register the timeout event, log and try again
|
||||
// (temporary workaround for https://github.com/golang/go/issues/28975)
|
||||
console.warn("scheduleTimeoutEvent: missed timeout event");
|
||||
this._resume();
|
||||
}
|
||||
},
|
||||
getInt64(sp + 8),
|
||||
));
|
||||
this.mem.setInt32(sp + 16, id, true);
|
||||
},
|
||||
|
||||
// func clearTimeoutEvent(id int32)
|
||||
"runtime.clearTimeoutEvent": (sp) => {
|
||||
sp >>>= 0;
|
||||
const id = this.mem.getInt32(sp + 8, true);
|
||||
clearTimeout(this._scheduledTimeouts.get(id));
|
||||
this._scheduledTimeouts.delete(id);
|
||||
},
|
||||
|
||||
// func getRandomData(r []byte)
|
||||
"runtime.getRandomData": (sp) => {
|
||||
sp >>>= 0;
|
||||
crypto.getRandomValues(loadSlice(sp + 8));
|
||||
},
|
||||
|
||||
// func finalizeRef(v ref)
|
||||
"syscall/js.finalizeRef": (sp) => {
|
||||
sp >>>= 0;
|
||||
const id = this.mem.getUint32(sp + 8, true);
|
||||
this._goRefCounts[id]--;
|
||||
if (this._goRefCounts[id] === 0) {
|
||||
const v = this._values[id];
|
||||
this._values[id] = null;
|
||||
this._ids.delete(v);
|
||||
this._idPool.push(id);
|
||||
}
|
||||
},
|
||||
|
||||
// func stringVal(value string) ref
|
||||
"syscall/js.stringVal": (sp) => {
|
||||
sp >>>= 0;
|
||||
storeValue(sp + 24, loadString(sp + 8));
|
||||
},
|
||||
|
||||
// func valueGet(v ref, p string) ref
|
||||
"syscall/js.valueGet": (sp) => {
|
||||
sp >>>= 0;
|
||||
const result = Reflect.get(loadValue(sp + 8), loadString(sp + 16));
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 32, result);
|
||||
},
|
||||
|
||||
// func valueSet(v ref, p string, x ref)
|
||||
"syscall/js.valueSet": (sp) => {
|
||||
sp >>>= 0;
|
||||
Reflect.set(loadValue(sp + 8), loadString(sp + 16), loadValue(sp + 32));
|
||||
},
|
||||
|
||||
// func valueDelete(v ref, p string)
|
||||
"syscall/js.valueDelete": (sp) => {
|
||||
sp >>>= 0;
|
||||
Reflect.deleteProperty(loadValue(sp + 8), loadString(sp + 16));
|
||||
},
|
||||
|
||||
// func valueIndex(v ref, i int) ref
|
||||
"syscall/js.valueIndex": (sp) => {
|
||||
sp >>>= 0;
|
||||
storeValue(sp + 24, Reflect.get(loadValue(sp + 8), getInt64(sp + 16)));
|
||||
},
|
||||
|
||||
// valueSetIndex(v ref, i int, x ref)
|
||||
"syscall/js.valueSetIndex": (sp) => {
|
||||
sp >>>= 0;
|
||||
Reflect.set(loadValue(sp + 8), getInt64(sp + 16), loadValue(sp + 24));
|
||||
},
|
||||
|
||||
// func valueCall(v ref, m string, args []ref) (ref, bool)
|
||||
"syscall/js.valueCall": (sp) => {
|
||||
sp >>>= 0;
|
||||
try {
|
||||
const v = loadValue(sp + 8);
|
||||
const m = Reflect.get(v, loadString(sp + 16));
|
||||
const args = loadSliceOfValues(sp + 32);
|
||||
const result = Reflect.apply(m, v, args);
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 56, result);
|
||||
this.mem.setUint8(sp + 64, 1);
|
||||
} catch (err) {
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 56, err);
|
||||
this.mem.setUint8(sp + 64, 0);
|
||||
}
|
||||
},
|
||||
|
||||
// func valueInvoke(v ref, args []ref) (ref, bool)
|
||||
"syscall/js.valueInvoke": (sp) => {
|
||||
sp >>>= 0;
|
||||
try {
|
||||
const v = loadValue(sp + 8);
|
||||
const args = loadSliceOfValues(sp + 16);
|
||||
const result = Reflect.apply(v, undefined, args);
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 40, result);
|
||||
this.mem.setUint8(sp + 48, 1);
|
||||
} catch (err) {
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 40, err);
|
||||
this.mem.setUint8(sp + 48, 0);
|
||||
}
|
||||
},
|
||||
|
||||
// func valueNew(v ref, args []ref) (ref, bool)
|
||||
"syscall/js.valueNew": (sp) => {
|
||||
sp >>>= 0;
|
||||
try {
|
||||
const v = loadValue(sp + 8);
|
||||
const args = loadSliceOfValues(sp + 16);
|
||||
const result = Reflect.construct(v, args);
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 40, result);
|
||||
this.mem.setUint8(sp + 48, 1);
|
||||
} catch (err) {
|
||||
sp = this._inst.exports.getsp() >>> 0; // see comment above
|
||||
storeValue(sp + 40, err);
|
||||
this.mem.setUint8(sp + 48, 0);
|
||||
}
|
||||
},
|
||||
|
||||
// func valueLength(v ref) int
|
||||
"syscall/js.valueLength": (sp) => {
|
||||
sp >>>= 0;
|
||||
setInt64(sp + 16, parseInt(loadValue(sp + 8).length));
|
||||
},
|
||||
|
||||
// valuePrepareString(v ref) (ref, int)
|
||||
"syscall/js.valuePrepareString": (sp) => {
|
||||
sp >>>= 0;
|
||||
const str = encoder.encode(String(loadValue(sp + 8)));
|
||||
storeValue(sp + 16, str);
|
||||
setInt64(sp + 24, str.length);
|
||||
},
|
||||
|
||||
// valueLoadString(v ref, b []byte)
|
||||
"syscall/js.valueLoadString": (sp) => {
|
||||
sp >>>= 0;
|
||||
const str = loadValue(sp + 8);
|
||||
loadSlice(sp + 16).set(str);
|
||||
},
|
||||
|
||||
// func valueInstanceOf(v ref, t ref) bool
|
||||
"syscall/js.valueInstanceOf": (sp) => {
|
||||
sp >>>= 0;
|
||||
this.mem.setUint8(sp + 24, (loadValue(sp + 8) instanceof loadValue(sp + 16)) ? 1 : 0);
|
||||
},
|
||||
|
||||
// func copyBytesToGo(dst []byte, src ref) (int, bool)
|
||||
"syscall/js.copyBytesToGo": (sp) => {
|
||||
sp >>>= 0;
|
||||
const dst = loadSlice(sp + 8);
|
||||
const src = loadValue(sp + 32);
|
||||
if (!(src instanceof Uint8Array || src instanceof Uint8ClampedArray)) {
|
||||
this.mem.setUint8(sp + 48, 0);
|
||||
return;
|
||||
}
|
||||
const toCopy = src.subarray(0, dst.length);
|
||||
dst.set(toCopy);
|
||||
setInt64(sp + 40, toCopy.length);
|
||||
this.mem.setUint8(sp + 48, 1);
|
||||
},
|
||||
|
||||
// func copyBytesToJS(dst ref, src []byte) (int, bool)
|
||||
"syscall/js.copyBytesToJS": (sp) => {
|
||||
sp >>>= 0;
|
||||
const dst = loadValue(sp + 8);
|
||||
const src = loadSlice(sp + 16);
|
||||
if (!(dst instanceof Uint8Array || dst instanceof Uint8ClampedArray)) {
|
||||
this.mem.setUint8(sp + 48, 0);
|
||||
return;
|
||||
}
|
||||
const toCopy = src.subarray(0, dst.length);
|
||||
dst.set(toCopy);
|
||||
setInt64(sp + 40, toCopy.length);
|
||||
this.mem.setUint8(sp + 48, 1);
|
||||
},
|
||||
|
||||
"debug": (value) => {
|
||||
console.log(value);
|
||||
},
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
async run(instance) {
|
||||
if (!(instance instanceof WebAssembly.Instance)) {
|
||||
throw new Error("Go.run: WebAssembly.Instance expected");
|
||||
}
|
||||
this._inst = instance;
|
||||
this.mem = new DataView(this._inst.exports.mem.buffer);
|
||||
this._values = [ // JS values that Go currently has references to, indexed by reference id
|
||||
NaN,
|
||||
0,
|
||||
null,
|
||||
true,
|
||||
false,
|
||||
globalThis,
|
||||
this,
|
||||
];
|
||||
this._goRefCounts = new Array(this._values.length).fill(Infinity); // number of references that Go has to a JS value, indexed by reference id
|
||||
this._ids = new Map([ // mapping from JS values to reference ids
|
||||
[0, 1],
|
||||
[null, 2],
|
||||
[true, 3],
|
||||
[false, 4],
|
||||
[globalThis, 5],
|
||||
[this, 6],
|
||||
]);
|
||||
this._idPool = []; // unused ids that have been garbage collected
|
||||
this.exited = false; // whether the Go program has exited
|
||||
|
||||
// Pass command line arguments and environment variables to WebAssembly by writing them to the linear memory.
|
||||
let offset = 4096;
|
||||
|
||||
const strPtr = (str) => {
|
||||
const ptr = offset;
|
||||
const bytes = encoder.encode(str + "\0");
|
||||
new Uint8Array(this.mem.buffer, offset, bytes.length).set(bytes);
|
||||
offset += bytes.length;
|
||||
if (offset % 8 !== 0) {
|
||||
offset += 8 - (offset % 8);
|
||||
}
|
||||
return ptr;
|
||||
};
|
||||
|
||||
const argc = this.argv.length;
|
||||
|
||||
const argvPtrs = [];
|
||||
this.argv.forEach((arg) => {
|
||||
argvPtrs.push(strPtr(arg));
|
||||
});
|
||||
argvPtrs.push(0);
|
||||
|
||||
const keys = Object.keys(this.env).sort();
|
||||
keys.forEach((key) => {
|
||||
argvPtrs.push(strPtr(`${key}=${this.env[key]}`));
|
||||
});
|
||||
argvPtrs.push(0);
|
||||
|
||||
const argv = offset;
|
||||
argvPtrs.forEach((ptr) => {
|
||||
this.mem.setUint32(offset, ptr, true);
|
||||
this.mem.setUint32(offset + 4, 0, true);
|
||||
offset += 8;
|
||||
});
|
||||
|
||||
// The linker guarantees global data starts from at least wasmMinDataAddr.
|
||||
// Keep in sync with cmd/link/internal/ld/data.go:wasmMinDataAddr.
|
||||
const wasmMinDataAddr = 4096 + 8192;
|
||||
if (offset >= wasmMinDataAddr) {
|
||||
throw new Error("total length of command line and environment variables exceeds limit");
|
||||
}
|
||||
|
||||
this._inst.exports.run(argc, argv);
|
||||
if (this.exited) {
|
||||
this._resolveExitPromise();
|
||||
}
|
||||
await this._exitPromise;
|
||||
}
|
||||
|
||||
_resume() {
|
||||
if (this.exited) {
|
||||
throw new Error("Go program has already exited");
|
||||
}
|
||||
this._inst.exports.resume();
|
||||
if (this.exited) {
|
||||
this._resolveExitPromise();
|
||||
}
|
||||
}
|
||||
|
||||
_makeFuncWrapper(id) {
|
||||
const go = this;
|
||||
return function () {
|
||||
const event = { id: id, this: this, args: arguments };
|
||||
go._pendingEvent = event;
|
||||
go._resume();
|
||||
return event.result;
|
||||
};
|
||||
}
|
||||
}
|
||||
})();
|
||||
Whitespace-only changes.
+1
-1
@@ -36,7 +36,7 @@ window.IpLookup = (function () {
|
||||
return getUnderberFill(num.toString(36), 2)
|
||||
};
|
||||
|
||||
const TOP_URL = 'https://cdn.jsdelivr.net/npm/@iplookup/country-extra/';
|
||||
const TOP_URL = '//cdn.jsdelivr.net/npm/@iplookup/country-extra/';
|
||||
const MAIN_RECORD_SIZE = 2 ;
|
||||
const sleep = (ms) => new Promise(resolve => setTimeout(resolve, ms));
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
(function(e){var t,r,n,a,s,i,o,l;if("undefined"!=typeof globalThis?e=globalThis:"undefined"!=typeof global?e=global:"undefined"!=typeof window&&(e=window),null==e.console&&(e.console={}),"log"in(t="object"==typeof e.console?e.console:{})||(t.log=function(){}),"warn"in t||(t.warn=t.log),void 0!==e.Opal)return t.warn("Opal already loaded. Loading twice can cause troubles, please fix your setup."),e.Opal;var $=e.Opal={};$.global=e,$.config={missing_require_severity:"error",unsupported_features_severity:"warning",experimental_features_severity:"warning",enable_stack_trace:!0};var u=Function.prototype.call,c=Function.prototype.bind,_=Object.hasOwn||u.bind(Object.prototype.hasOwnProperty),p=Object.setPrototypeOf,m=u.bind(Array.prototype.slice),d=u.bind(Array.prototype.splice),f=4;function h(){return f+=2}$.uid=h,$.id=function(e){return e.$$is_number?2*e+1:(null==e.$$id&&y(e,"$$id",h()),e.$$id)};var g=$.gvars={};function b(e,t){if(e||(e=$.Exception||Error),!l||!l.$raise)throw e.$new?e.$new(t):new e(t);arguments.length>2?l.$raise(e.$new.apply(e,m(arguments,1))):l.$raise(e,t)}$.exit=function(e){g.DEBUG&&t.log("Exited with status "+e)},$.exceptions=[],$.pop_exception=function(e){var t=$.exceptions.pop();t===e||(g["!"]=t||r)};var v={value:void 0,enumerable:!1,configurable:!0,writable:!0};function y(e,t,r){"string"==typeof e?e[t]=r:(v.value=r,Object.defineProperty(e,t,v))}$.prop=y,$.defineProperty=$.prop,$.slice=m;var x=$.truthy=function(e){return!(!1===e||r===e||null==e||e instanceof Boolean&&!0!==e.valueOf())};function w(e){var t,r,n;for(t=0,r=$.tracers_for_class.length;t<r;t++)(n=$.tracers_for_class[t]).trace_object=e,n.block.$call(n)}function k(e,t){if(e.$$autoload[t].loaded){if(e.$$autoload[t].loaded&&!e.$$autoload[t].required&&e.$$autoload[t].exception)throw e.$$autoload[t].exception}else{e.$$autoload[t].loaded=!0;try{$.Kernel.$require(e.$$autoload[t].path)}catch(r){throw e.$$autoload[t].exception=r,r}if(e.$$autoload[t].required=!0,null!=e.$$const[t])return e.$$autoload[t].success=!0,e.$$const[t]}}function U(e,t){if(e){if(null!=e.$$const[t])return e.$$const[t];if(e.$$autoload&&e.$$autoload[t])return k(e,t)}}function E(e,t){var r,n,a;if(null!=e)for(r=0,n=(a=P(e)).length;r<n;r++){if(a[r].$$const&&_(a[r].$$const,t))return a[r].$$const[t];if(a[r].$$autoload&&a[r].$$autoload[t])return k(a[r],t)}}function M(e,t){return(e||a).$const_missing(t)}function q(e,t,n){var s=!0;return null!=e&&"::"!==e||(e=a),n.$$is_a_module&&(null!=n.$$name&&n.$$name!==r||(n.$$name=t),null==n.$$base_module&&(n.$$base_module=e)),e.$$const=e.$$const||Object.create(null),(t in e.$$const||"$$autoload"in e&&t in e.$$autoload)&&(s=!1),e.$$const[t]=n,e.$$=e.$$const,$.const_cache_version++,e===a&&($[t]=n),y(e,t,n),s&&e.$const_added&&!e.$const_added.$$pristine&&e.$const_added(t),n}function S(e){return null!=e&&(e.$$bridge?e:!!e.$$super&&S(e.$$super))}function O(e,t,n){var a,s;if(a=(s=S(t))?function(){var e=new(c.apply(s.$$constructor,G(null,arguments)));return p(e,a.$$prototype),e}:function(){},e&&e!==r&&y(a,"displayName","::"+e),y(a,"$$name",e),y(a,"$$constructor",a),y(a,"$$prototype",a.prototype),y(a,"$$const",{}),y(a,"$$is_class",!0),y(a,"$$is_a_module",!0),y(a,"$$super",t),y(a,"$$cvars",{}),y(a,"$$own_included_modules",[]),y(a,"$$own_prepended_modules",[]),y(a,"$$ancestors",[]),y(a,"$$ancestors_cache_version",null),y(a,"$$subclasses",[]),y(a,"$$cloned_from",[]),y(a.$$prototype,"$$class",a),$.Class&&p(a,$.Class.prototype),null!=t){if(p(a.$$prototype,t.$$prototype),!0!==n)if("undefined"!=typeof WeakRef){var i,o,l=[];for(i=0;i<t.$$subclasses.length;i++)void 0!==(o=t.$$subclasses[i]).deref()&&l.push(o);l.push(new WeakRef(a)),t.$$subclasses=l}else t.$$subclasses.push(a);t.$$meta&&$.build_class_singleton_class(a)}return a}function A(e){var t=function(){},r=t;return e&&y(t,"displayName",e+".constructor"),y(r,"$$name",e),y(r,"$$prototype",t.prototype),y(r,"$$const",{}),y(r,"$$is_module",!0),y(r,"$$is_a_module",!0),y(r,"$$cvars",{}),y(r,"$$iclasses",[]),y(r,"$$own_included_modules",[]),y(r,"$$own_prepended_modules",[]),y(r,"$$ancestors",[r]),y(r,"$$ancestors_cache_version",null),y(r,"$$cloned_from",[]),p(r,$.Module.prototype),r}function T(e,t){e.hasOwnProperty("$$meta")?e.$$meta=t:y(e,"$$meta",t),e.$$frozen?e.$$meta.$freeze():p(e,t.$$prototype)}function N(e){return e.hasOwnProperty("$$iclass")&&e.hasOwnProperty("$$root")}function z(e){var t=R(e);return e.$$is_module&&e.$$iclasses.push(t),t}function R(e){var t={},r=e.$$prototype;r.hasOwnProperty("$$dummy")&&(r=r.$$define_methods_on);var n,a=Object.getOwnPropertyNames(r),s=a.length;for(n=0;n<s;n++){var i=a[n];y(t,i,r[i])}return y(t,"$$iclass",!0),y(t,"$$module",e),t}function I(e){var t=e.length,r=e[0];if(y(r,"$$root",!0),1===t)return{first:r,last:r};for(var n=r,a=1;a<t;a++){var s=e[a];p(n,s),n=s}return{first:e[0],last:e[t-1]}}function C(e){if(!e.hasOwnProperty("$$dummy"))return e.hasOwnProperty("$$iclass")?e.$$module:e.hasOwnProperty("$$class")?e.$$class:void 0}function P(e){if(!e)return[];if(e.$$ancestors_cLine truncated
|
||||
(function(e){var t,r,n,a,s,i,o,l;if("undefined"!=typeof globalThis?e=globalThis:"undefined"!=typeof global?e=global:"undefined"!=typeof window&&(e=window),null==e.console&&(e.console={}),"log"in(t="object"==typeof e.console?e.console:{})||(t.log=function(){}),"warn"in t||(t.warn=t.log),void 0!==e.Opal)return t.warn("Opal already loaded. Loading twice can cause troubles, please fix your setup."),e.Opal;var $=e.Opal={};$.global=e,$.config={missing_require_severity:"error",unsupported_features_severity:"warning",experimental_features_severity:"warning",enable_stack_trace:!0};var u=Function.prototype.call,c=Function.prototype.bind,_=Object.hasOwn||u.bind(Object.prototype.hasOwnProperty),p=Object.setPrototypeOf,m=u.bind(Array.prototype.slice),d=u.bind(Array.prototype.splice),f=4;function h(){return f+=2}$.uid=h,$.id=function(e){return e.$$is_number?2*e+1:(null==e.$$id&&y(e,"$$id",h()),e.$$id)};var g=$.gvars={};function b(e,t){if(e||(e=$.Exception||Error),!l||!l.$raise)throw e.$new?e.$new(t):new e(t);arguments.length>2?l.$raise(e.$new.apply(e,m(arguments,1))):l.$raise(e,t)}$.exit=function(e){g.DEBUG&&t.log("Exited with status "+e)},$.exceptions=[],$.pop_exception=function(e){var t=$.exceptions.pop();t===e||(g["!"]=t||r)};var v={value:void 0,enumerable:!1,configurable:!0,writable:!0};function y(e,t,r){"string"==typeof e?e[t]=r:(v.value=r,Object.defineProperty(e,t,v))}$.prop=y,$.defineProperty=$.prop,$.slice=m;var x=$.truthy=function(e){return!(!1===e||r===e||null==e||e instanceof Boolean&&!0!==e.valueOf())};function w(e){var t,r,n;for(t=0,r=$.tracers_for_class.length;t<r;t++)(n=$.tracers_for_class[t]).trace_object=e,n.block.$call(n)}function k(e,t){if(e.$$autoload[t].loaded){if(e.$$autoload[t].loaded&&!e.$$autoload[t].required&&e.$$autoload[t].exception)throw e.$$autoload[t].exception}else{e.$$autoload[t].loaded=!0;try{$.Kernel.$require(e.$$autoload[t].path)}catch(r){throw e.$$autoload[t].exception=r,r}if(e.$$autoload[t].required=!0,null!=e.$$const[t])return e.$$autoload[t].success=!0,e.$$const[t]}}function U(e,t){if(e){if(null!=e.$$const[t])return e.$$const[t];if(e.$$autoload&&e.$$autoload[t])return k(e,t)}}function E(e,t){var r,n,a;if(null!=e)for(r=0,n=(a=P(e)).length;r<n;r++){if(a[r].$$const&&_(a[r].$$const,t))return a[r].$$const[t];if(a[r].$$autoload&&a[r].$$autoload[t])return k(a[r],t)}}function M(e,t){return(e||a).$const_missing(t)}function q(e,t,n){var s=!0;return null!=e&&"::"!==e||(e=a),n.$$is_a_module&&(null!=n.$$name&&n.$$name!==r||(n.$$name=t),null==n.$$base_module&&(n.$$base_module=e)),e.$$const=e.$$const||Object.create(null),(t in e.$$const||"$$autoload"in e&&t in e.$$autoload)&&(s=!1),e.$$const[t]=n,e.$$=e.$$const,$.const_cache_version++,e===a&&($[t]=n),y(e,t,n),s&&e.$const_added&&!e.$const_added.$$pristine&&e.$const_added(t),n}function S(e){return null!=e&&(e.$$bridge?e:!!e.$$super&&S(e.$$super))}function O(e,t,n){var a,s;if(a=(s=S(t))?function(){var e=new(c.apply(s.$$constructor,G(null,arguments)));return p(e,a.$$prototype),e}:function(){},e&&e!==r&&y(a,"displayName","::"+e),y(a,"$$name",e),y(a,"$$constructor",a),y(a,"$$prototype",a.prototype),y(a,"$$const",{}),y(a,"$$is_class",!0),y(a,"$$is_a_module",!0),y(a,"$$super",t),y(a,"$$cvars",{}),y(a,"$$own_included_modules",[]),y(a,"$$own_prepended_modules",[]),y(a,"$$ancestors",[]),y(a,"$$ancestors_cache_version",null),y(a,"$$subclasses",[]),y(a,"$$cloned_from",[]),y(a.$$prototype,"$$class",a),$.Class&&p(a,$.Class.prototype),null!=t){if(p(a.$$prototype,t.$$prototype),!0!==n)if("undefined"!=typeof WeakRef){var i,o,l=[];for(i=0;i<t.$$subclasses.length;i++)void 0!==(o=t.$$subclasses[i]).deref()&&l.push(o);l.push(new WeakRef(a)),t.$$subclasses=l}else t.$$subclasses.push(a);t.$$meta&&$.build_class_singleton_class(a)}return a}function A(e){var t=function(){},r=t;return e&&y(t,"displayName",e+".constructor"),y(r,"$$name",e),y(r,"$$prototype",t.prototype),y(r,"$$const",{}),y(r,"$$is_module",!0),y(r,"$$is_a_module",!0),y(r,"$$cvars",{}),y(r,"$$iclasses",[]),y(r,"$$own_included_modules",[]),y(r,"$$own_prepended_modules",[]),y(r,"$$ancestors",[r]),y(r,"$$ancestors_cache_version",null),y(r,"$$cloned_from",[]),p(r,$.Module.prototype),r}function T(e,t){e.hasOwnProperty("$$meta")?e.$$meta=t:y(e,"$$meta",t),e.$$frozen?e.$$meta.$freeze():p(e,t.$$prototype)}function N(e){return e.hasOwnProperty("$$iclass")&&e.hasOwnProperty("$$root")}function z(e){var t=R(e);return e.$$is_module&&e.$$iclasses.push(t),t}function R(e){var t={},r=e.$$prototype;r.hasOwnProperty("$$dummy")&&(r=r.$$define_methods_on);var n,a=Object.getOwnPropertyNames(r),s=a.length;for(n=0;n<s;n++){var i=a[n];y(t,i,r[i])}return y(t,"$$iclass",!0),y(t,"$$module",e),t}function I(e){var t=e.length,r=e[0];if(y(r,"$$root",!0),1===t)return{first:r,last:r};for(var n=r,a=1;a<t;a++){var s=e[a];p(n,s),n=s}return{first:e[0],last:e[t-1]}}function C(e){if(!e.hasOwnProperty("$$dummy"))return e.hasOwnProperty("$$iclass")?e.$$module:e.hasOwnProperty("$$class")?e.$$class:void 0}function P(e){if(!e)return[];if(e.$$ancestors_cLine truncated
|
||||
//# sourceMappingURL=plurimath-opal.js.map
|
||||
@@ -0,0 +1 @@
|
||||
{}
|
||||
@@ -16,6 +16,7 @@ const props = withDefaults(
|
||||
outputLanguage?: string
|
||||
downloadFileName?: string
|
||||
downloadButtonText?: string
|
||||
rows?: number
|
||||
}>(),
|
||||
{
|
||||
transformer: _.identity,
|
||||
@@ -27,12 +28,13 @@ const props = withDefaults(
|
||||
outputLanguage: '',
|
||||
downloadFileName: '',
|
||||
downloadButtonText: 'Download',
|
||||
rows: 15,
|
||||
},
|
||||
);
|
||||
|
||||
const {
|
||||
transformer, inputValidationRules, inputLabel, outputLabel, outputLanguage,
|
||||
inputPlaceholder, inputDefault, downloadFileName, downloadButtonText,
|
||||
inputPlaceholder, inputDefault, downloadFileName, downloadButtonText, rows,
|
||||
} = toRefs(props);
|
||||
|
||||
const inputElement = ref<typeof CInputText>();
|
||||
@@ -54,13 +56,14 @@ const { download } = useDownloadFileFromBase64(
|
||||
v-model:value="input"
|
||||
:placeholder="inputPlaceholder"
|
||||
:label="inputLabel"
|
||||
rows="20"
|
||||
:rows="rows"
|
||||
autosize
|
||||
raw-text
|
||||
multiline
|
||||
test-id="input"
|
||||
:validation-rules="inputValidationRules"
|
||||
monospace
|
||||
mb-1
|
||||
/>
|
||||
|
||||
<div overflow-auto>
|
||||
|
||||
@@ -7,6 +7,7 @@ const props = defineProps<{
|
||||
multiline?: boolean
|
||||
rows?: number | string
|
||||
autosize?: boolean
|
||||
readonly?: boolean
|
||||
}>();
|
||||
const emit = defineEmits(['update:value']);
|
||||
|
||||
@@ -21,6 +22,7 @@ const tooltipText = computed(() => isJustCopied.value ? 'Copied!' : 'Copy to cli
|
||||
:multiline="multiline"
|
||||
:rows="rows"
|
||||
:autosize="autosize"
|
||||
:readonly="readonly"
|
||||
>
|
||||
<template #suffix>
|
||||
<c-tooltip :tooltip="tooltipText">
|
||||
|
||||
@@ -13,7 +13,10 @@ import markdownHljs from 'highlight.js/lib/languages/markdown';
|
||||
import jsHljs from 'highlight.js/lib/languages/javascript';
|
||||
import cssHljs from 'highlight.js/lib/languages/css';
|
||||
import goHljs from 'highlight.js/lib/languages/go';
|
||||
import pythonHljs from 'highlight.js/lib/languages/python';
|
||||
import phpHljs from 'highlight.js/lib/languages/php';
|
||||
import csharpHljs from 'highlight.js/lib/languages/csharp';
|
||||
import protobufHljs from 'highlight.js/lib/languages/protobuf';
|
||||
import { Base64 } from 'js-base64';
|
||||
import { useCopy } from '@/composable/copy';
|
||||
import { useDownloadFileFromBase64 } from '@/composable/downloadBase64';
|
||||
@@ -45,12 +48,16 @@ hljs.registerLanguage('xml', xmlHljs);
|
||||
hljs.registerLanguage('yaml', yamlHljs);
|
||||
hljs.registerLanguage('toml', iniHljs);
|
||||
hljs.registerLanguage('ts', tsHljs);
|
||||
hljs.registerLanguage('typescript', tsHljs);
|
||||
hljs.registerLanguage('bash', bashHljs);
|
||||
hljs.registerLanguage('markdown', markdownHljs);
|
||||
hljs.registerLanguage('css', cssHljs);
|
||||
hljs.registerLanguage('javascript', jsHljs);
|
||||
hljs.registerLanguage('go', goHljs);
|
||||
hljs.registerLanguage('csharp', csharpHljs);
|
||||
hljs.registerLanguage('python', pythonHljs);
|
||||
hljs.registerLanguage('php', phpHljs);
|
||||
hljs.registerLanguage('protobuf', protobufHljs);
|
||||
|
||||
const { value, language, followHeightOf, copyPlacement, copyMessage, downloadFileName, downloadButtonText } = toRefs(props);
|
||||
const { height } = followHeightOf.value ? useElementSize(followHeightOf) : { height: ref(null) };
|
||||
@@ -68,7 +75,10 @@ const { download } = useDownloadFileFromBase64(
|
||||
|
||||
<template>
|
||||
<div style="overflow-x: hidden; width: 100%">
|
||||
<c-card relative>
|
||||
<c-card
|
||||
relative
|
||||
:style="(copyPlacement === 'top-right' || copyPlacement === 'bottom-right') ? `padding-bottom: 50px` : ''"
|
||||
>
|
||||
<n-scrollbar
|
||||
x-scrollable
|
||||
trigger="none"
|
||||
@@ -80,9 +90,10 @@ const { download } = useDownloadFileFromBase64(
|
||||
</n-scrollbar>
|
||||
<div
|
||||
v-if="value && copyPlacement !== 'none'"
|
||||
absolute right-10px
|
||||
|
||||
:top-10px="copyPlacement === 'top-right' ? '' : 'no'"
|
||||
:bottom-10px="copyPlacement === 'bottom-right' ? '' : 'no'"
|
||||
absolute right-10px
|
||||
>
|
||||
<c-tooltip v-if="value && copyPlacement !== 'outside'" :tooltip="tooltipText" position="left">
|
||||
<c-button circle important:h-10 important:w-10 @click="copy()">
|
||||
|
||||
@@ -0,0 +1,223 @@
|
||||
import { type MaybeRef, get } from '@vueuse/core';
|
||||
import { computed, ref, watch } from 'vue';
|
||||
import FlexSearch from 'flexsearch';
|
||||
|
||||
// Define key types to match Fuse.js format
|
||||
type SearchKey = string | { name: string; weight?: number };
|
||||
|
||||
export function useFlexSearch<Data extends Record<string, any>>({
|
||||
search,
|
||||
data,
|
||||
options = {
|
||||
keys: [],
|
||||
},
|
||||
limit = -1,
|
||||
}: {
|
||||
search: MaybeRef<string>
|
||||
data: Data[]
|
||||
options?: {
|
||||
keys: SearchKey[]
|
||||
/**
|
||||
* Whether to show or not show items with an empty search query. `true` won't show any items, `false` will show all items.
|
||||
* @default true
|
||||
*/
|
||||
filterEmpty?: boolean
|
||||
/**
|
||||
* Whether the results should be sorted by similarity score using the Levenshtein distance.
|
||||
* @default true
|
||||
*/
|
||||
shouldSort?: boolean
|
||||
/**
|
||||
* Type of tokenization logic to use (Determines how the search logic will behave).
|
||||
* @default 'forward'
|
||||
* @see {@link https://github.com/nextapps-de/flexsearch?tab=readme-ov-file#tokenizer-partial-match | FlexSearch Tokenizer Documentation}
|
||||
*
|
||||
* Note: The `'tolerant'` tokenizer option mentioned in the documentation doesn't exist anymore in the current version of FlexSearch.
|
||||
*/
|
||||
tokenize?: 'strict' | 'forward' | 'reverse' | 'full'
|
||||
resolution?: number
|
||||
optimize?: boolean
|
||||
cache?: boolean | number
|
||||
}
|
||||
limit?: MaybeRef<number>
|
||||
}) {
|
||||
// Extract options
|
||||
const { keys, filterEmpty = true, shouldSort = true, tokenize = 'forward', ...indexOptions } = options;
|
||||
|
||||
// Normalize keys to include weights
|
||||
const normalizedKeys = keys.map((key) => {
|
||||
if (typeof key === 'string') {
|
||||
return { name: key, weight: 1 };
|
||||
}
|
||||
return { name: key.name, weight: key.weight ?? 1 };
|
||||
});
|
||||
|
||||
// Helper to get unique key for each item (prefer 'id', fallback to index)
|
||||
const getItemKey = (item: Data, idx: number) => (item.id !== undefined ? item.id : idx);
|
||||
|
||||
// Map to store original data items by unique key
|
||||
const dataMap = ref(new Map<any, Data>());
|
||||
|
||||
// Create separate indices for each key with weight info
|
||||
const indices = normalizedKeys.map(({ name, weight }) => ({
|
||||
key: name,
|
||||
weight,
|
||||
index: new FlexSearch.Index({
|
||||
tokenize,
|
||||
preset: 'performance',
|
||||
resolution: 9,
|
||||
optimize: true,
|
||||
cache: 100,
|
||||
fastupdate: true,
|
||||
...indexOptions,
|
||||
}),
|
||||
}));
|
||||
|
||||
// Initialize indices with data
|
||||
const initializeIndices = () => {
|
||||
dataMap.value.clear();
|
||||
indices.forEach(({ index }) => index.clear());
|
||||
|
||||
data.forEach((item, idx) => {
|
||||
const itemKey = getItemKey(item, idx);
|
||||
dataMap.value.set(itemKey, item);
|
||||
|
||||
indices.forEach(({ key, index }) => {
|
||||
// Support nested keys (e.g., 'foo.bar')
|
||||
const value = key.split('.').reduce((obj, path) => obj?.[path], item);
|
||||
if (value) {
|
||||
index.add(itemKey, String(value));
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
// Initialize on creation
|
||||
initializeIndices();
|
||||
|
||||
// Watch for data changes (deep watch for array content)
|
||||
watch(
|
||||
() => data,
|
||||
initializeIndices,
|
||||
{ deep: true },
|
||||
);
|
||||
|
||||
// Function to search across all indices with weight consideration
|
||||
const searchAllIndices = (query: string, searchLimit: number) => {
|
||||
if (!query) {
|
||||
return [];
|
||||
}
|
||||
|
||||
// Use a higher individual limit for each index to ensure we don't miss potential matches
|
||||
const individualLimit = searchLimit > 0 ? searchLimit * 2 : undefined;
|
||||
|
||||
// Search each index and collect results with weights
|
||||
const weightedResults = new Map<any, number>();
|
||||
|
||||
indices.forEach(({ index, weight }) => {
|
||||
const results = index.search(query, individualLimit ? { limit: individualLimit } : undefined);
|
||||
|
||||
results.forEach((id) => {
|
||||
const currentScore = weightedResults.get(id) || 0;
|
||||
weightedResults.set(id, currentScore + weight);
|
||||
});
|
||||
});
|
||||
|
||||
// Sort by weight (higher weight = better match) and convert to array
|
||||
const sortedIds = Array.from(weightedResults.entries())
|
||||
.sort((a, b) => b[1] - a[1])
|
||||
.map(([id]) => id);
|
||||
|
||||
// Apply limit and convert back to original items
|
||||
const limitedIds = searchLimit > 0 ? sortedIds.slice(0, searchLimit) : sortedIds;
|
||||
|
||||
// Return the limited results early if it shouldn't be sorted by similarity
|
||||
if (!shouldSort) {
|
||||
return limitedIds
|
||||
.map(id => dataMap.value.get(id))
|
||||
.filter(Boolean) as Data[];
|
||||
}
|
||||
|
||||
// Calculate Levenshtein distance
|
||||
const levenshteinDistance = (str1: string, str2: string): number => {
|
||||
const matrix = Array(str2.length + 1).fill(null).map(() => Array(str1.length + 1).fill(null));
|
||||
|
||||
for (let i = 0; i <= str1.length; i++) {
|
||||
matrix[0][i] = i;
|
||||
}
|
||||
for (let j = 0; j <= str2.length; j++) {
|
||||
matrix[j][0] = j;
|
||||
}
|
||||
|
||||
for (let j = 1; j <= str2.length; j++) {
|
||||
for (let i = 1; i <= str1.length; i++) {
|
||||
const indicator = str1[i - 1] === str2[j - 1] ? 0 : 1;
|
||||
matrix[j][i] = Math.min(
|
||||
matrix[j][i - 1] + 1, // deletion
|
||||
matrix[j - 1][i] + 1, // insertion
|
||||
matrix[j - 1][i - 1] + indicator, // substitution
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
return matrix[str2.length][str1.length];
|
||||
};
|
||||
|
||||
// Calculate similarity score (0-1, where 1 is perfect match)
|
||||
const calculateSimilarity = (str1: string, str2: string): number => {
|
||||
const maxLength = Math.max(str1.length, str2.length);
|
||||
if (maxLength === 0) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
const distance = levenshteinDistance(str1.toLowerCase(), str2.toLowerCase());
|
||||
return 1 - (distance / maxLength);
|
||||
};
|
||||
|
||||
// Sort limited results by similarity score
|
||||
const sortedResults = limitedIds
|
||||
.map((id) => {
|
||||
const item = dataMap.value.get(id);
|
||||
if (!item) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// Calculate best similarity score across all searchable fields
|
||||
const similarities = normalizedKeys.map(({ name }) => {
|
||||
const value = name.split('.').reduce((obj, path) => obj?.[path], item);
|
||||
return value ? calculateSimilarity(query, String(value)) : 0;
|
||||
});
|
||||
|
||||
const bestSimilarity = Math.max(...similarities);
|
||||
|
||||
return {
|
||||
item,
|
||||
similarity: bestSimilarity,
|
||||
};
|
||||
})
|
||||
.filter(Boolean)
|
||||
.sort((a, b) => b!.similarity - a!.similarity)
|
||||
.map(result => result!.item);
|
||||
|
||||
return sortedResults as Data[];
|
||||
};
|
||||
|
||||
// Computed results
|
||||
const searchResult = computed<Data[]>(() => {
|
||||
const query = get(search);
|
||||
const searchLimit: number = get(limit);
|
||||
|
||||
// Handle empty query case
|
||||
if (!query && !filterEmpty) {
|
||||
return searchLimit > 0 ? data.slice(0, searchLimit) : data;
|
||||
}
|
||||
|
||||
if (!query) {
|
||||
return [];
|
||||
}
|
||||
|
||||
return searchAllIndices(query, searchLimit);
|
||||
});
|
||||
|
||||
return { searchResult };
|
||||
}
|
||||
@@ -72,7 +72,9 @@ const themeVars = useThemeVars();
|
||||
</div>
|
||||
|
||||
<div class="tool-content">
|
||||
<slot />
|
||||
<Suspense>
|
||||
<slot />
|
||||
</Suspense>
|
||||
</div>
|
||||
|
||||
<div class="tool-footer">
|
||||
|
||||
@@ -4,9 +4,6 @@ import { createHead } from '@vueuse/head';
|
||||
import { library } from '@fortawesome/fontawesome-svg-core';
|
||||
import { fas } from '@fortawesome/free-solid-svg-icons';
|
||||
|
||||
import { install as VueMonacoEditorPlugin, loader } from '@guolao/vue-monaco-editor';
|
||||
import * as monaco from 'monaco-editor';
|
||||
|
||||
import { registerSW } from 'virtual:pwa-register';
|
||||
import shadow from 'vue-shadow-dom';
|
||||
import { plausible } from './plugins/plausible.plugin';
|
||||
@@ -23,14 +20,10 @@ import store from './tools/pomodoro-timer/app/store';
|
||||
|
||||
library.add(fas);
|
||||
|
||||
// loaded monaco-editor from `node_modules`
|
||||
loader.config({ monaco });
|
||||
|
||||
registerSW();
|
||||
|
||||
const app = createApp(App);
|
||||
|
||||
app.use(VueMonacoEditorPlugin);
|
||||
app.use(createPinia());
|
||||
app.use(createHead());
|
||||
app.use(i18nPlugin);
|
||||
|
||||
@@ -13,6 +13,7 @@ const localesLong: Record<string, string> = {
|
||||
uk: 'Українська',
|
||||
zh: '中文',
|
||||
vi: 'Tiếng Việt',
|
||||
ar: 'عربي',
|
||||
};
|
||||
|
||||
const localeOptions = computed(() =>
|
||||
|
||||
@@ -3,11 +3,24 @@ import { IconDragDrop, IconFileDescription, IconHeart } from '@tabler/icons-vue'
|
||||
import { useHead } from '@vueuse/head';
|
||||
import { computed } from 'vue';
|
||||
import Draggable from 'vuedraggable';
|
||||
import VueMarkdown from 'vue-markdown-render';
|
||||
import ColoredCard from '../components/ColoredCard.vue';
|
||||
import ToolCard from '../components/ToolCard.vue';
|
||||
import { useToolStore } from '@/tools/tools.store';
|
||||
import { config } from '@/config';
|
||||
|
||||
const base = import.meta.env.BASE_URL ?? '/';
|
||||
const homeCustomMarkdown = computedAsync(async () => {
|
||||
try {
|
||||
const remoteCustomHomeMarkdownResponse = await fetch(`${base}home.custom.md`);
|
||||
if (remoteCustomHomeMarkdownResponse.ok) {
|
||||
return await remoteCustomHomeMarkdownResponse.text();
|
||||
}
|
||||
}
|
||||
catch {}
|
||||
return '';
|
||||
});
|
||||
|
||||
const toolStore = useToolStore();
|
||||
|
||||
useHead({ title: 'IT Tools - Handy online tools for developers' });
|
||||
@@ -87,6 +100,10 @@ function onUpdateFavoriteTools() {
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="homeCustomMarkdown">
|
||||
<VueMarkdown :source="homeCustomMarkdown" />
|
||||
</div>
|
||||
|
||||
<h3 class="mb-5px mt-25px font-500 text-neutral-400">
|
||||
{{ $t('home.categories.allTools') }}
|
||||
</h3>
|
||||
|
||||
@@ -0,0 +1,74 @@
|
||||
<script setup lang="ts">
|
||||
import mappingData from './ad-mapping.json';
|
||||
import { useFuzzySearch } from '@/composable/fuzzySearch';
|
||||
import useDebouncedRef from '@/composable/debouncedref';
|
||||
|
||||
const data = mappingData.map(i => ({ ...i, all: `${i.TAB} - ${i.ActiveDirectoryField}` }));
|
||||
const searchQuery = useDebouncedRef('', 500);
|
||||
|
||||
const { searchResult } = useFuzzySearch({
|
||||
search: searchQuery,
|
||||
data,
|
||||
options: {
|
||||
keys: ['all'],
|
||||
threshold: 0.2,
|
||||
isCaseSensitive: false,
|
||||
minMatchCharLength: 3,
|
||||
useExtendedSearch: true,
|
||||
filterEmpty: false,
|
||||
},
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div mx-auto max-w-2400px important:flex-1>
|
||||
<div flex items-center gap-3>
|
||||
<c-input-text
|
||||
v-model:value="searchQuery"
|
||||
placeholder="Search Active Directory LDAP mapping"
|
||||
mx-auto max-w-600px
|
||||
>
|
||||
<template #prefix>
|
||||
<icon-mdi-search mr-6px color-black op-70 dark:color-white />
|
||||
</template>
|
||||
</c-input-text>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<div
|
||||
v-if="searchResult.length === 0"
|
||||
|
||||
mt-4 text-center text-20px font-bold
|
||||
>
|
||||
No results
|
||||
</div>
|
||||
|
||||
<div v-else>
|
||||
<div mt-4 text-20px font-bold>
|
||||
Search result
|
||||
</div>
|
||||
|
||||
<n-table>
|
||||
<thead>
|
||||
<th>TAB</th>
|
||||
<th>Active Directory Field</th>
|
||||
<th>LDAP Attribute</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(result, ix) in searchResult" :key="ix">
|
||||
<td>
|
||||
<input-copyable :value="result.TAB" />
|
||||
</td>
|
||||
<td>
|
||||
<input-copyable :value="result.ActiveDirectoryField" />
|
||||
</td>
|
||||
<td>
|
||||
<input-copyable :value="result.LDAPAttribute" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</n-table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -0,0 +1,157 @@
|
||||
[
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "First Name",
|
||||
"LDAPAttribute": "givenName"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Initials",
|
||||
"LDAPAttribute": "initials"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Last name",
|
||||
"LDAPAttribute": "sn"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Display name",
|
||||
"LDAPAttribute": "displayName"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Description",
|
||||
"LDAPAttribute": "description"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Office",
|
||||
"LDAPAttribute": "physicalDeliveryOfficeName"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Telephone number",
|
||||
"LDAPAttribute": "telephoneNumber"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "E-mail",
|
||||
"LDAPAttribute": "mail"
|
||||
},
|
||||
{
|
||||
"TAB": "General",
|
||||
"ActiveDirectoryField": "Web page",
|
||||
"LDAPAttribute": "wWWHomePage"
|
||||
},
|
||||
{
|
||||
"TAB": "Address",
|
||||
"ActiveDirectoryField": "Street",
|
||||
"LDAPAttribute": "streetAddress"
|
||||
},
|
||||
{
|
||||
"TAB": "Address",
|
||||
"ActiveDirectoryField": "P.O Box",
|
||||
"LDAPAttribute": "postOfficeBox"
|
||||
},
|
||||
{
|
||||
"TAB": "Address",
|
||||
"ActiveDirectoryField": "City",
|
||||
"LDAPAttribute": "l"
|
||||
},
|
||||
{
|
||||
"TAB": "Address",
|
||||
"ActiveDirectoryField": "State/province",
|
||||
"LDAPAttribute": "St"
|
||||
},
|
||||
{
|
||||
"TAB": "Address",
|
||||
"ActiveDirectoryField": "Zip/Postal Code",
|
||||
"LDAPAttribute": "postalCode"
|
||||
},
|
||||
{
|
||||
"TAB": "Address",
|
||||
"ActiveDirectoryField": "County/region",
|
||||
"LDAPAttribute": "co"
|
||||
},
|
||||
{
|
||||
"TAB": "Account",
|
||||
"ActiveDirectoryField": "User logon name",
|
||||
"LDAPAttribute": "userPrincipalName"
|
||||
},
|
||||
{
|
||||
"TAB": "Account",
|
||||
"ActiveDirectoryField": "user logon name (pre-Windows 200)",
|
||||
"LDAPAttribute": "sAMAccountName"
|
||||
},
|
||||
{
|
||||
"TAB": "Profile",
|
||||
"ActiveDirectoryField": "Profile path",
|
||||
"LDAPAttribute": "profilePath"
|
||||
},
|
||||
{
|
||||
"TAB": "Profile",
|
||||
"ActiveDirectoryField": "Logon script",
|
||||
"LDAPAttribute": "scriptPath"
|
||||
},
|
||||
{
|
||||
"TAB": "Profile",
|
||||
"ActiveDirectoryField": "Local path",
|
||||
"LDAPAttribute": "homeDirectory"
|
||||
},
|
||||
{
|
||||
"TAB": "Profile",
|
||||
"ActiveDirectoryField": "Connect",
|
||||
"LDAPAttribute": "homeDrive"
|
||||
},
|
||||
{
|
||||
"TAB": "Telephones",
|
||||
"ActiveDirectoryField": "Home",
|
||||
"LDAPAttribute": "homePhone"
|
||||
},
|
||||
{
|
||||
"TAB": "Telephones",
|
||||
"ActiveDirectoryField": "Pager",
|
||||
"LDAPAttribute": "pager"
|
||||
},
|
||||
{
|
||||
"TAB": "Telephones",
|
||||
"ActiveDirectoryField": "Mobile",
|
||||
"LDAPAttribute": "Mobile"
|
||||
},
|
||||
{
|
||||
"TAB": "Telephones",
|
||||
"ActiveDirectoryField": "Fax",
|
||||
"LDAPAttribute": "facsimileTelephoneNumber"
|
||||
},
|
||||
{
|
||||
"TAB": "Telephones",
|
||||
"ActiveDirectoryField": "IP Phone",
|
||||
"LDAPAttribute": "ipPhone"
|
||||
},
|
||||
{
|
||||
"TAB": "Organization",
|
||||
"ActiveDirectoryField": "Job Title",
|
||||
"LDAPAttribute": "title"
|
||||
},
|
||||
{
|
||||
"TAB": "Organization",
|
||||
"ActiveDirectoryField": "Department",
|
||||
"LDAPAttribute": "department"
|
||||
},
|
||||
{
|
||||
"TAB": "Organization",
|
||||
"ActiveDirectoryField": "Company",
|
||||
"LDAPAttribute": "company"
|
||||
},
|
||||
{
|
||||
"TAB": "Organization",
|
||||
"ActiveDirectoryField": "Manager",
|
||||
"LDAPAttribute": "manager"
|
||||
},
|
||||
{
|
||||
"TAB": "Organization",
|
||||
"ActiveDirectoryField": "Direct Reports",
|
||||
"LDAPAttribute": "directreports"
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,14 @@
|
||||
import { Folder } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: translate('tools.ad-ldap-searcher.title'),
|
||||
path: '/ad-ldap-searcher',
|
||||
description: translate('tools.ad-ldap-searcher.description'),
|
||||
keywords: ['active', 'directory', 'ad', 'ldap', 'prop', 'searcher'],
|
||||
component: () => import('./ad-ldap-searcher.vue'),
|
||||
icon: Folder,
|
||||
createdAt: new Date('2024-08-15'),
|
||||
category: 'Forensic',
|
||||
});
|
||||
@@ -0,0 +1,261 @@
|
||||
<script setup lang="ts">
|
||||
import { useScriptTag } from '@vueuse/core';
|
||||
import ageWasmUrl from '/age-wasm/age.wasm?url';
|
||||
|
||||
declare global {
|
||||
interface Window {
|
||||
generateX25519Identity: () => {
|
||||
privateKey: string
|
||||
publicKey: string
|
||||
}
|
||||
encrypt: (publicKeys: string, message: string) => {
|
||||
error?: string
|
||||
output: string
|
||||
}
|
||||
decrypt: (privateKeys: string, message: string) => {
|
||||
error?: string
|
||||
output: string
|
||||
}
|
||||
encryptBinary: (publicKeys: string, buffer: Uint8Array) => string | Uint8Array
|
||||
decryptBinary: (privateKeys: string, buffer: Uint8Array) => string | Uint8Array
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Go is the class as defined in the Golang `wasm_exec.js` distributable file required for WebAssembly.
|
||||
* Golang WebAssembly wiki: https://github.com/golang/go/wiki/WebAssembly
|
||||
*/
|
||||
declare class Go {
|
||||
argv: string[];
|
||||
env: { [envKey: string]: string };
|
||||
exit: (code: number) => void;
|
||||
importObject: WebAssembly.Imports;
|
||||
exited: boolean;
|
||||
mem: DataView;
|
||||
run(instance: WebAssembly.Instance): Promise<void>;
|
||||
}
|
||||
|
||||
const { load: loadGo } = useScriptTag('/age-wasm/wasm_exec.js', undefined, { type: 'module', manual: true });
|
||||
|
||||
await loadGo();
|
||||
|
||||
const go = new Go();
|
||||
const result = await WebAssembly.instantiateStreaming(fetch(ageWasmUrl), go.importObject);
|
||||
go.run(result.instance);
|
||||
|
||||
const privKey = ref('');
|
||||
const pubKey = ref('');
|
||||
const recipients = ref('');
|
||||
const message = ref('');
|
||||
const encryptedOutput = ref('');
|
||||
const recipientsBinary = ref('');
|
||||
const filesEncrypt = ref<File[]>([]);
|
||||
const identities = ref('');
|
||||
const encryptedText = ref('');
|
||||
const decryptedOutput = ref('');
|
||||
const identitiesBinary = ref('');
|
||||
const filesDecrypt = ref<File[]>([]);
|
||||
const error = ref('');
|
||||
|
||||
function downloadURL(data: string, fileName: string) {
|
||||
const a = document.createElement('a');
|
||||
a.href = data;
|
||||
a.download = fileName;
|
||||
document.body.appendChild(a);
|
||||
a.style.display = 'none';
|
||||
a.click();
|
||||
a.remove();
|
||||
}
|
||||
|
||||
function downloadBlob(data: Uint8Array, fileName: string) {
|
||||
const blob = new Blob([data], {
|
||||
type: 'application/octet-stream',
|
||||
});
|
||||
const url = window.URL.createObjectURL(blob);
|
||||
downloadURL(url, fileName);
|
||||
setTimeout(() => window.URL.revokeObjectURL(url), 1000);
|
||||
}
|
||||
|
||||
function generateKeys() {
|
||||
const keys = window.generateX25519Identity();
|
||||
privKey.value = keys.privateKey;
|
||||
pubKey.value = keys.publicKey;
|
||||
}
|
||||
|
||||
function encrypt() {
|
||||
error.value = '';
|
||||
const result = window.encrypt(recipients.value, message.value);
|
||||
if (result.error) {
|
||||
error.value = result.error;
|
||||
}
|
||||
else {
|
||||
encryptedOutput.value = result.output;
|
||||
}
|
||||
}
|
||||
|
||||
function encryptBinary() {
|
||||
error.value = '';
|
||||
const file = filesEncrypt.value;
|
||||
if (!file.length) {
|
||||
return;
|
||||
}
|
||||
|
||||
file.forEach((f) => {
|
||||
const reader = new FileReader();
|
||||
reader.onload = () => {
|
||||
const buffer = new Uint8Array(reader.result as ArrayBuffer);
|
||||
const result = window.encryptBinary(recipientsBinary.value, buffer);
|
||||
if (typeof result === 'string') {
|
||||
error.value = result;
|
||||
}
|
||||
else {
|
||||
downloadBlob(result, `${f.name}.age`);
|
||||
}
|
||||
};
|
||||
reader.readAsArrayBuffer(f);
|
||||
});
|
||||
|
||||
filesEncrypt.value = [];
|
||||
}
|
||||
|
||||
function decrypt() {
|
||||
error.value = '';
|
||||
const result = window.decrypt(identities.value, encryptedText.value);
|
||||
if (result.error) {
|
||||
error.value = result.error;
|
||||
}
|
||||
else {
|
||||
decryptedOutput.value = result.output;
|
||||
}
|
||||
}
|
||||
|
||||
function decryptBinary() {
|
||||
error.value = '';
|
||||
const file = filesDecrypt.value;
|
||||
if (!file.length) {
|
||||
return;
|
||||
}
|
||||
|
||||
file.forEach((f) => {
|
||||
const reader = new FileReader();
|
||||
reader.onload = () => {
|
||||
const buffer = new Uint8Array(reader.result as ArrayBuffer);
|
||||
const result = window.decryptBinary(identitiesBinary.value, buffer);
|
||||
if (typeof result === 'string') {
|
||||
error.value = result;
|
||||
}
|
||||
else {
|
||||
downloadBlob(result, f.name.replace('.age', ''));
|
||||
}
|
||||
};
|
||||
reader.readAsArrayBuffer(f);
|
||||
});
|
||||
|
||||
filesDecrypt.value = [];
|
||||
}
|
||||
|
||||
function onEncryptFilesUploaded(uploadedFiles: File[]) {
|
||||
filesEncrypt.value = uploadedFiles;
|
||||
}
|
||||
function onDecryptFilesUploaded(uploadedFiles: File[]) {
|
||||
filesDecrypt.value = uploadedFiles;
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<n-tabs type="card">
|
||||
<!-- Generate Keys -->
|
||||
<n-tab-pane name="keys" tab="Generate Keys">
|
||||
<n-card title="Private Key" mb-1>
|
||||
<textarea-copyable v-model:value="privKey" rows="3" multiline placeholder="Your private key will be generated here." />
|
||||
</n-card>
|
||||
<n-card title="Public Key" mb-1>
|
||||
<textarea-copyable v-model:value="pubKey" rows="3" multiline placeholder="Your public key will be generated here." />
|
||||
</n-card>
|
||||
<n-button type="primary" @click="generateKeys">
|
||||
Generate Keys
|
||||
</n-button>
|
||||
</n-tab-pane>
|
||||
|
||||
<!-- Encrypt Text -->
|
||||
<n-tab-pane name="encrypt" tab="Encrypt">
|
||||
<n-card title="Public Keys" mb-1>
|
||||
<n-input v-model:value="recipients" type="textarea" placeholder="Recipient key or keys one per line" required />
|
||||
</n-card>
|
||||
<n-card title="Message" mb-1>
|
||||
<n-input v-model:value="message" type="textarea" placeholder="Message to encrypt" required />
|
||||
</n-card>
|
||||
<n-card title="Output" mb-1>
|
||||
<textarea-copyable v-model:value="encryptedOutput" rows="3" multiline placeholder="Encrypted output will be generated here." />
|
||||
</n-card>
|
||||
<n-button type="primary" @click="encrypt">
|
||||
Encrypt
|
||||
</n-button>
|
||||
</n-tab-pane>
|
||||
|
||||
<!-- Encrypt Binary -->
|
||||
<n-tab-pane name="encryptBinary" tab="Encrypt Binary">
|
||||
<n-card title="Public Keys" mb-1>
|
||||
<n-input v-model:value="recipientsBinary" type="textarea" placeholder="Recipient key or keys one per line" required />
|
||||
</n-card>
|
||||
<n-card title="Files" mb-1>
|
||||
<c-file-upload
|
||||
title="Drag and drop files here, or click to select some files"
|
||||
multiple
|
||||
@files-upload="onEncryptFilesUploaded"
|
||||
/>
|
||||
<ul>
|
||||
<li v-for="(file, index) in filesEncrypt" :key="index">
|
||||
{{ file.name }}
|
||||
</li>
|
||||
</ul>
|
||||
</n-card>
|
||||
<n-card title="Output" mb-1>
|
||||
<p>The encrypted files will be downloaded.</p>
|
||||
</n-card>
|
||||
<n-button type="primary" @click="encryptBinary">
|
||||
Encrypt Binary
|
||||
</n-button>
|
||||
</n-tab-pane>
|
||||
|
||||
<!-- Decrypt Text -->
|
||||
<n-tab-pane name="decrypt" tab="Decrypt">
|
||||
<n-card title="Private Keys" mb-1>
|
||||
<n-input v-model:value="identities" type="textarea" placeholder="Identity key or keys one per line" required />
|
||||
</n-card>
|
||||
<n-card title="Encrypted Text" mb-1>
|
||||
<n-input v-model:value="encryptedText" type="textarea" placeholder="Paste here encrypted text" required />
|
||||
</n-card>
|
||||
<n-card title="Output" mb-1>
|
||||
<textarea-copyable v-model:value="decryptedOutput" rows="3" multiline placeholder="Decrypted output will be generated here." />
|
||||
</n-card>
|
||||
<n-button type="primary" @click="decrypt">
|
||||
Decrypt
|
||||
</n-button>
|
||||
</n-tab-pane>
|
||||
|
||||
<!-- Decrypt Binary -->
|
||||
<n-tab-pane name="decryptBinary" tab="Decrypt Binary">
|
||||
<n-card title="Private Keys" mb-1>
|
||||
<n-input v-model:value="identitiesBinary" type="textarea" placeholder="Identity key or keys one per line" required />
|
||||
</n-card>
|
||||
<n-card title="Encrypted Files" mb-1>
|
||||
<c-file-upload
|
||||
title="Drag and drop files here, or click to select some files"
|
||||
multiple
|
||||
@files-upload="onDecryptFilesUploaded"
|
||||
/>
|
||||
<ul>
|
||||
<li v-for="(file, index) in filesDecrypt" :key="index">
|
||||
{{ file.name }}
|
||||
</li>
|
||||
</ul>
|
||||
</n-card>
|
||||
<n-card title="Output" mb-1>
|
||||
<p>The decrypted files will be downloaded.</p>
|
||||
</n-card>
|
||||
<n-button type="primary" @click="decryptBinary">
|
||||
Decrypt Binary
|
||||
</n-button>
|
||||
</n-tab-pane>
|
||||
</n-tabs>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { EyeOff } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'AGE Cryptography',
|
||||
path: '/age-crypto',
|
||||
description: 'Provides a simple and easy-to-use open-source Age tool for generating keys, encrypting, and decrypting messages.',
|
||||
keywords: ['age'],
|
||||
component: () => import('./age-crypto.vue'),
|
||||
icon: EyeOff,
|
||||
createdAt: new Date('2025-05-08'),
|
||||
category: 'Crypto',
|
||||
});
|
||||
@@ -1,10 +1,11 @@
|
||||
import { Prompt } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'AI Prompt Splitter',
|
||||
name: translate('tools.ai-prompt-splitter.title'),
|
||||
path: '/ai-prompt-splitter',
|
||||
description: 'Split a long document to multiple chat (ie ChatGPT) prompts',
|
||||
description: translate('tools.ai-prompt-splitter.description'),
|
||||
keywords: ['ai', 'chatgpt', 'gpt', 'prompt', 'splitter'],
|
||||
component: () => import('./ai-prompt-splitter.vue'),
|
||||
icon: Prompt,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { Angle } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Angle Units Converter',
|
||||
name: translate('tools.angle-converter.title'),
|
||||
path: '/angle-converter',
|
||||
description: 'Convert values between angle units',
|
||||
description: translate('tools.angle-converter.description'),
|
||||
keywords: ['angle', 'converter'],
|
||||
component: () => import('./angle-converter.vue'),
|
||||
icon: Angle,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { LockSquare } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Ansible vault crypt decrypt',
|
||||
name: translate('tools.ansible-vault-crypt-decrypt.title'),
|
||||
path: '/ansible-vault-crypt-decrypt',
|
||||
description: 'Encrypt and decrypt Ansible Vault Secrets',
|
||||
description: translate('tools.ansible-vault-crypt-decrypt.description'),
|
||||
keywords: ['ansible', 'vault', 'crypt', 'decrypt'],
|
||||
component: () => import('./ansible-vault-crypt-decrypt.vue'),
|
||||
icon: LockSquare,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { World } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'API Tester',
|
||||
name: translate('tools.api-tester.title'),
|
||||
path: '/api-tester',
|
||||
description: 'HTTP API Tester',
|
||||
description: translate('tools.api-tester.description'),
|
||||
keywords: ['api', 'http', 'call', 'tester'],
|
||||
component: () => import('./api-tester.vue'),
|
||||
icon: World,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { SquaresDiagonal } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Area Units Converter',
|
||||
name: translate('tools.area-converter.title'),
|
||||
path: '/area-converter',
|
||||
description: 'Convert values between area units',
|
||||
description: translate('tools.area-converter.description'),
|
||||
keywords: ['area', 'converter'],
|
||||
component: () => import('./area-converter.vue'),
|
||||
icon: SquaresDiagonal,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<script setup lang="ts">
|
||||
import figlet from 'figlet';
|
||||
import TextareaCopyable from '@/components/TextareaCopyable.vue';
|
||||
import { languages, translateToLanguage } from '@/utils/ascii-lang-utils';
|
||||
import { languages, printToLanguage } from '@/utils/ascii-lang-utils';
|
||||
|
||||
const input = ref('Ascii ART');
|
||||
const language = useStorage('ascii-text-drawer:language', 'raw');
|
||||
@@ -40,7 +40,7 @@ watchEffect(async () => {
|
||||
resolve(text ?? '');
|
||||
})));
|
||||
|
||||
output.value = translateToLanguage(rawOutput, languageValue);
|
||||
output.value = printToLanguage(rawOutput, languageValue);
|
||||
errored.value = false;
|
||||
}
|
||||
catch (e: any) {
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { Artboard } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'ASCII Art Text Generator',
|
||||
name: translate('tools.ascii-text-drawer.title'),
|
||||
path: '/ascii-text-drawer',
|
||||
description: 'Create ASCII art text with many fonts and styles.',
|
||||
description: translate('tools.ascii-text-drawer.description'),
|
||||
keywords: ['ascii', 'asciiart', 'text', 'drawer'],
|
||||
component: () => import('./ascii-text-drawer.vue'),
|
||||
icon: Artboard,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { AspectRatio } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Aspect Ratio Calculator',
|
||||
name: translate('tools.aspect-ratio-calculator.title'),
|
||||
path: '/aspect-ratio-calculator',
|
||||
description: 'Use this ratio calculator to check the dimensions when resizing images.',
|
||||
description: translate('tools.aspect-ratio-calculator.description'),
|
||||
keywords: ['aspect', 'ratio', 'calculator'],
|
||||
component: () => import('./aspect-ratio-calculator.vue'),
|
||||
icon: AspectRatio,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { Barcode } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Barcode Generator',
|
||||
name: translate('tools.barcode-generator.title'),
|
||||
path: '/barcode-generator',
|
||||
description: 'Barcode generator',
|
||||
description: translate('tools.barcode-generator.description'),
|
||||
keywords: ['barcode', 'generator'],
|
||||
component: () => import('./barcode-generator.vue'),
|
||||
icon: Barcode,
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { Barcode } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
import { translate } from '@/plugins/i18n.plugin';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Barcode Reader',
|
||||
name: translate('tools.barcode-reader.title'),
|
||||
path: '/barcode-reader',
|
||||
description: 'Barcode reader',
|
||||
description: translate('tools.barcode-reader.description'),
|
||||
keywords: ['barcode', 'reader'],
|
||||
component: () => import('./barcode-reader.vue'),
|
||||
icon: Barcode,
|
||||
|
||||
@@ -0,0 +1,112 @@
|
||||
<script setup lang="ts">
|
||||
import { Base64 } from 'js-base64';
|
||||
import hexArray from 'hex-array';
|
||||
import { useCopy } from '@/composable/copy';
|
||||
import { isValidBase64 } from '@/utils/base64';
|
||||
|
||||
const textInput = ref('');
|
||||
const base64Output = computed(() => {
|
||||
try {
|
||||
return Base64.fromUint8Array(hexArray.fromString(textInput.value));
|
||||
}
|
||||
catch (e: any) {
|
||||
return e.toString();
|
||||
}
|
||||
});
|
||||
const { copy: copyTextBase64 } = useCopy({ source: base64Output, text: 'Base64 Hex Array copied to the clipboard' });
|
||||
|
||||
const uppercase = ref(false);
|
||||
const grouping = ref(0);
|
||||
const rowlength = ref(0);
|
||||
|
||||
const base64Input = ref('');
|
||||
const textOutput = computed(() => {
|
||||
try {
|
||||
return hexArray.toString(Base64.toUint8Array(base64Input.value), {
|
||||
uppercase: uppercase.value,
|
||||
grouping: grouping.value,
|
||||
rowlength: rowlength.value,
|
||||
});
|
||||
}
|
||||
catch (e: any) {
|
||||
return e.toString();
|
||||
}
|
||||
},
|
||||
);
|
||||
const { copy: copyText } = useCopy({ source: textOutput, text: 'Hex Array copied to the clipboard' });
|
||||
const b64ValidationRules = [
|
||||
{
|
||||
message: 'Invalid base64 string',
|
||||
validator: (value: string) => isValidBase64(value.trim()),
|
||||
},
|
||||
];
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<c-card title="Hex Array to Base64">
|
||||
<c-input-text
|
||||
v-model:value="textInput"
|
||||
multiline
|
||||
placeholder="Put your Hex Array here..."
|
||||
rows="5"
|
||||
label="Hex Array to encode"
|
||||
raw-text
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<c-input-text
|
||||
label="Base64 of Hex Array"
|
||||
:value="base64Output"
|
||||
multiline
|
||||
readonly
|
||||
placeholder="The Base64 encoding of your Hex Array will be here"
|
||||
rows="5"
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<div flex justify-center>
|
||||
<c-button @click="copyTextBase64()">
|
||||
Copy Base64
|
||||
</c-button>
|
||||
</div>
|
||||
</c-card>
|
||||
|
||||
<c-card title="Base64 to Hex Array">
|
||||
<n-space align="baseline" justify="center" mb-1>
|
||||
<n-form-item label="Uppercase" label-placement="left">
|
||||
<n-switch v-model:value="uppercase" />
|
||||
</n-form-item>
|
||||
<n-form-item label="Group by" label-placement="left">
|
||||
<n-input-number v-model:value="grouping" :min="0" style="width: 6em" mr-1 /> digits (0 = no grouping)
|
||||
</n-form-item>
|
||||
<n-form-item label="Split as rows by" label-placement="left">
|
||||
<n-input-number v-model:value="rowlength" :min="0" style="width: 6em" mr-1 /> group of digits (0 = no rows)
|
||||
</n-form-item>
|
||||
</n-space>
|
||||
<c-input-text
|
||||
v-model:value="base64Input"
|
||||
multiline
|
||||
placeholder="Your Base64 Hex Array..."
|
||||
rows="5"
|
||||
:validation-rules="b64ValidationRules"
|
||||
label="Base64 Hex Array to decode"
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<c-input-text
|
||||
v-model:value="textOutput"
|
||||
label="Decoded Hex Array"
|
||||
placeholder="The decoded Hex Array will be here"
|
||||
multiline
|
||||
rows="5"
|
||||
readonly
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<div flex justify-center>
|
||||
<c-button @click="copyText()">
|
||||
Copy Decoded Hex Array
|
||||
</c-button>
|
||||
</div>
|
||||
</c-card>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { FileDigit } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Base64 Hex array encoder/decoder',
|
||||
path: '/base64-hex-converter',
|
||||
description: 'Simply encode and decode Hex array into a their base64 representation.',
|
||||
keywords: ['base64', 'converter', 'conversion', 'web', 'data', 'format', 'atob', 'btoa', 'hex'],
|
||||
component: () => import('./base64-hex-converter.vue'),
|
||||
icon: FileDigit,
|
||||
createdAt: new Date('2025-02-09'),
|
||||
category: 'Converters',
|
||||
});
|
||||
@@ -0,0 +1,573 @@
|
||||
```bash
|
||||
#!/bin/bash
|
||||
##############################################################################
|
||||
# SHORTCUTS and HISTORY
|
||||
##############################################################################
|
||||
|
||||
CTRL+A # move to beginning of line
|
||||
CTRL+B # moves backward one character
|
||||
CTRL+C # halts the current command
|
||||
CTRL+D # deletes one character backward or logs out of current session, similar to exit
|
||||
CTRL+E # moves to end of line
|
||||
CTRL+F # moves forward one character
|
||||
CTRL+G # aborts the current editing command and ring the terminal bell
|
||||
CTRL+H # deletes one character under cursor (same as DELETE)
|
||||
CTRL+J # same as RETURN
|
||||
CTRL+K # deletes (kill) forward to end of line
|
||||
CTRL+L # clears screen and redisplay the line
|
||||
CTRL+M # same as RETURN
|
||||
CTRL+N # next line in command history
|
||||
CTRL+O # same as RETURN, then displays next line in history file
|
||||
CTRL+P # previous line in command history
|
||||
CTRL+Q # resumes suspended shell output
|
||||
CTRL+R # searches backward
|
||||
CTRL+S # searches forward or suspends shell output
|
||||
CTRL+T # transposes two characters
|
||||
CTRL+U # kills backward from point to the beginning of line
|
||||
CTRL+V # makes the next character typed verbatim
|
||||
CTRL+W # kills the word behind the cursor
|
||||
CTRL+X # lists the possible filename completions of the current word
|
||||
CTRL+Y # retrieves (yank) last item killed
|
||||
CTRL+Z # stops the current command, resume with fg in the foreground or bg in the background
|
||||
|
||||
ALT+B # moves backward one word
|
||||
ALT+D # deletes next word
|
||||
ALT+F # moves forward one word
|
||||
ALT+H # deletes one character backward
|
||||
ALT+T # transposes two words
|
||||
ALT+. # pastes last word from the last command. Pressing it repeatedly traverses through command history.
|
||||
ALT+U # capitalizes every character from the current cursor position to the end of the word
|
||||
ALT+L # uncapitalizes every character from the current cursor position to the end of the word
|
||||
ALT+C # capitalizes the letter under the cursor. The cursor then moves to the end of the word.
|
||||
ALT+R # reverts any changes to a command you’ve pulled from your history if you’ve edited it.
|
||||
ALT+? # list possible completions to what is typed
|
||||
ALT+^ # expand line to most recent match from history
|
||||
|
||||
CTRL+X then ( # start recording a keyboard macro
|
||||
CTRL+X then ) # finish recording keyboard macro
|
||||
CTRL+X then E # recall last recorded keyboard macro
|
||||
CTRL+X then CTRL+E # invoke text editor (specified by $EDITOR) on current command line then execute resultes as shell commands
|
||||
CTRL+A then D # logout from screen but don't kill it, if any command exist, it will continue
|
||||
|
||||
BACKSPACE # deletes one character backward
|
||||
DELETE # deletes one character under cursor
|
||||
|
||||
history # shows command line history
|
||||
!! # repeats the last command
|
||||
!<n> # refers to command line 'n'
|
||||
!<string> # refers to command starting with 'string'
|
||||
esc :wq # exits and saves script
|
||||
|
||||
exit # logs out of current session
|
||||
|
||||
|
||||
##############################################################################
|
||||
# BASH BASICS
|
||||
##############################################################################
|
||||
|
||||
env # displays all environment variables
|
||||
|
||||
echo $SHELL # displays the shell you're using
|
||||
echo $BASH_VERSION # displays bash version
|
||||
|
||||
bash # if you want to use bash (type exit to go back to your previously opened shell)
|
||||
whereis bash # locates the binary, source and manual-page for a command
|
||||
which bash # finds out which program is executed as 'bash' (default: /bin/bash, can change across environments)
|
||||
|
||||
clear # clears content on window (hide displayed lines)
|
||||
|
||||
|
||||
##############################################################################
|
||||
# FILE COMMANDS
|
||||
##############################################################################
|
||||
|
||||
|
||||
ls # lists your files in current directory, ls <dir> to print files in a specific directory
|
||||
ls -l # lists your files in 'long format', which contains the exact size of the file, who owns the file and who has the right to look at it, and when it was last modified
|
||||
ls -a # lists all files in 'long format', including hidden files (name beginning with '.')
|
||||
ln -s <filename> <link> # creates symbolic link to file
|
||||
readlink <filename> # shows where a symbolic links points to
|
||||
tree # show directories and subdirectories in easilly readable file tree
|
||||
mc # terminal file explorer (alternative to ncdu)
|
||||
touch <filename> # creates or updates (edit) your file
|
||||
mktemp -t <filename> # make a temp file in /tmp/ which is deleted at next boot (-d to make directory)
|
||||
cat <filename> # displays file raw content (will not be interpreted)
|
||||
cat -n <filename> # shows number of lines
|
||||
nl <file.sh> # shows number of lines in file
|
||||
cat filename1 > filename2 # Copy filename1 to filename2
|
||||
cat filename1 >> filename2 # merge two files texts together
|
||||
any_command > <filename> # '>' is used to perform redirections, it will set any_command's stdout to file instead of "real stdout" (generally /dev/stdout)
|
||||
more <filename> # shows the first part of a file (move with space and type q to quit)
|
||||
head <filename> # outputs the first lines of file (default: 10 lines)
|
||||
tail <filename> # outputs the last lines of file (useful with -f option) (default: 10 lines)
|
||||
vim <filename> # opens a file in VIM (VI iMproved) text editor, will create it if it doesn't exist
|
||||
mv <filename1> <dest> # moves a file to destination, behavior will change based on 'dest' type (dir: file is placed into dir; file: file will replace dest (tip: useful for renaming))
|
||||
cp <filename1> <dest> # copies a file
|
||||
rm <filename> # removes a file
|
||||
find . -name <name> <type> # searches for a file or a directory in the current directory and all its sub-directories by its name
|
||||
diff <filename1> <filename2> # compares files, and shows where they differ
|
||||
wc <filename> # tells you how many lines, words and characters there are in a file. Use -lwc (lines, word, character) to ouput only 1 of those informations
|
||||
sort <filename> # sorts the contents of a text file line by line in alphabetical order, use -n for numeric sort and -r for reversing order.
|
||||
sort -t -k <filename> # sorts the contents on specific sort key field starting from 1, using the field separator t.
|
||||
rev # reverse string characters (hello becomes olleh)
|
||||
chmod -options <filename> # lets you change the read, write, and execute permissions on your files (more infos: SUID, GUID)
|
||||
gzip <filename> # compresses files using gzip algorithm
|
||||
gunzip <filename> # uncompresses files compressed by gzip
|
||||
gzcat <filename> # lets you look at gzipped file without actually having to gunzip it
|
||||
lpr <filename> # prints the file
|
||||
lpq # checks out the printer queue
|
||||
lprm <jobnumber> # removes something from the printer queue
|
||||
genscript # converts plain text files into postscript for printing and gives you some options for formatting
|
||||
dvips <filename> # prints .dvi files (i.e. files produced by LaTeX)
|
||||
grep <pattern> <filenames> # looks for the string in the files
|
||||
grep -r <pattern> <dir> # search recursively for pattern in directory
|
||||
head -n file_name | tail +n # Print nth line from file.
|
||||
head -y lines.txt | tail +x # want to display all the lines from x to y. This includes the xth and yth lines.
|
||||
|
||||
sed 's/<pattern>/<replacement>/g' <filename> # replace pattern in file with replacement value to std output the character after s (/) is the delimeter
|
||||
sed -i 's/<pattern>/<replacement>/g' <filename> # replace pattern in file with replacement value in place
|
||||
echo "this" | sed 's/is/at/g' # replace pattern from input stream with replacement value
|
||||
|
||||
##############################################################################
|
||||
# DIRECTORY COMMANDS
|
||||
##############################################################################
|
||||
|
||||
|
||||
mkdir <dirname> # makes a new directory
|
||||
rmdir <dirname> # remove an empty directory
|
||||
rmdir -rf <dirname> # remove a non-empty directory
|
||||
mv <dir1> <dir2> # rename a directory from <dir1> to <dir2>
|
||||
cd # changes to home
|
||||
cd .. # changes to the parent directory
|
||||
cd <dirname> # changes directory
|
||||
cp -r <dir1> <dir2> # copy <dir1> into <dir2> including sub-directories
|
||||
pwd # tells you where you currently are
|
||||
cd ~ # changes to home.
|
||||
cd - # changes to previous working directory
|
||||
|
||||
##############################################################################
|
||||
# SSH, SYSTEM INFO & NETWORK COMMANDS
|
||||
##############################################################################
|
||||
|
||||
|
||||
ssh user@host # connects to host as user
|
||||
ssh -p <port> user@host # connects to host on specified port as user
|
||||
ssh-copy-id user@host # adds your ssh key to host for user to enable a keyed or passwordless login
|
||||
|
||||
whoami # returns your username
|
||||
su <user> # switch to a different user
|
||||
su - # switch to root, likely needs to be sudo su -
|
||||
sudo <command> # execute command as the root user
|
||||
passwd # lets you change your password
|
||||
quota -v # shows what your disk quota is
|
||||
date # shows the current date and time
|
||||
cal # shows the month's calendar
|
||||
uptime # shows current uptime
|
||||
w # displays whois online
|
||||
finger <user> # displays information about user
|
||||
uname -a # shows kernel information
|
||||
man <command> # shows the manual for specified command
|
||||
info <command> # shows another documentation system for the specific command
|
||||
help # shows documentation about built-in commands and functions
|
||||
df # shows disk usage
|
||||
du <filename> # shows the disk usage of the files and directories in filename (du -s give only a total)
|
||||
resize2fs # ext2/ext3/ext4 file system resizer
|
||||
last <yourUsername> # lists your last logins
|
||||
ps -u yourusername # lists your processes
|
||||
kill <PID> # kills the processes with the ID you gave
|
||||
killall <processname> # kill all processes with the name
|
||||
top # displays your currently active processes
|
||||
lsof # lists open files
|
||||
bg # lists stopped or background jobs ; resume a stopped job in the background
|
||||
fg # brings the most recent job in the foreground
|
||||
fg <job> # brings job to the foreground
|
||||
|
||||
ping <host> # pings host and outputs results
|
||||
whois <domain> # gets whois information for domain
|
||||
dig <domain> # gets DNS information for domain
|
||||
dig -x <host> # reverses lookup host
|
||||
wget <file> # downloads file
|
||||
netstat # Print network connections, routing tables, interface statistics, masquerade connections, and multicast memberships
|
||||
|
||||
time <command> # report time consumed by command execution
|
||||
|
||||
|
||||
##############################################################################
|
||||
# VARIABLES
|
||||
##############################################################################
|
||||
|
||||
|
||||
varname=value # defines a variable
|
||||
varname=value command # defines a variable to be in the environment of a particular subprocess
|
||||
echo $varname # checks a variable's value
|
||||
echo $$ # prints process ID of the current shell
|
||||
echo $! # prints process ID of the most recently invoked background job
|
||||
echo $? # displays the exit status of the last command
|
||||
read <varname> # reads a string from the input and assigns it to a variable
|
||||
read -p "prompt" <varname> # same as above but outputs a prompt to ask user for value
|
||||
column -t <filename> # display info in pretty columns (often used with pipe)
|
||||
let <varname> = <equation> # performs mathematical calculation using operators like +, -, *, /, %
|
||||
export VARNAME=value # defines an environment variable (will be available in subprocesses)
|
||||
export -f <funcname> # Exports function 'funcname'
|
||||
export var1="var1 value" # Export and assign in the same statement
|
||||
export <varname> # Copy Bash variable
|
||||
declare -x <varname> # Copy Bash variable
|
||||
|
||||
array[0]=valA # how to define an array
|
||||
array[1]=valB
|
||||
array[2]=valC
|
||||
array=([2]=valC [0]=valA [1]=valB) # another way
|
||||
array=(valA valB valC) # and another
|
||||
|
||||
${array[i]} # displays array's value for this index. If no index is supplied, array element 0 is assumed
|
||||
${#array[i]} # to find out the length of any element in the array
|
||||
${#array[@]} # to find out how many values there are in the array
|
||||
|
||||
declare -a # the variables are treated as arrays
|
||||
declare -f # uses function names only
|
||||
declare -F # displays function names without definitions
|
||||
declare -i # the variables are treated as integers
|
||||
declare -r # makes the variables read-only
|
||||
declare -x # marks the variables for export via the environment
|
||||
declare -l # uppercase values in the variable are converted to lowercase
|
||||
declare -A # makes it an associative array
|
||||
|
||||
${varname:-word} # if varname exists and isn't null, return its value; otherwise return word
|
||||
${varname:word} # if varname exists and isn't null, return its value; otherwise return word
|
||||
${varname:=word} # if varname exists and isn't null, return its value; otherwise set it word and then return its value
|
||||
${varname:?message} # if varname exists and isn't null, return its value; otherwise print varname, followed by message and abort the current command or script
|
||||
${varname:+word} # if varname exists and isn't null, return word; otherwise return null
|
||||
${varname:offset:length} # performs substring expansion. It returns the substring of $varname starting at offset and up to length characters
|
||||
|
||||
${variable#pattern} # if the pattern matches the beginning of the variable's value, delete the shortest part that matches and return the rest
|
||||
${variable##pattern} # if the pattern matches the beginning of the variable's value, delete the longest part that matches and return the rest
|
||||
${variable%pattern} # if the pattern matches the end of the variable's value, delete the shortest part that matches and return the rest
|
||||
${variable%%pattern} # if the pattern matches the end of the variable's value, delete the longest part that matches and return the rest
|
||||
${variable/pattern/string} # the longest match to pattern in variable is replaced by string. Only the first match is replaced
|
||||
${variable//pattern/string} # the longest match to pattern in variable is replaced by string. All matches are replaced
|
||||
|
||||
${#varname} # returns the length of the value of the variable as a character string
|
||||
|
||||
*(patternlist) # matches zero or more occurrences of the given patterns
|
||||
+(patternlist) # matches one or more occurrences of the given patterns
|
||||
?(patternlist) # matches zero or one occurrence of the given patterns
|
||||
@(patternlist) # matches exactly one of the given patterns
|
||||
!(patternlist) # matches anything except one of the given patterns
|
||||
|
||||
$(UNIX command) # command substitution: runs the command and returns standard output
|
||||
|
||||
typeset -l <x> # makes variable local - <x> must be an interger
|
||||
|
||||
##############################################################################
|
||||
# FUNCTIONS
|
||||
##############################################################################
|
||||
|
||||
|
||||
# The function refers to passed arguments by position (as if they were positional parameters), that is, $1, $2, and so forth.
|
||||
# $@ is equal to "$1" "$2"... "$N", where N is the number of positional parameters. $# holds the number of positional parameters.
|
||||
|
||||
|
||||
function functname() {
|
||||
shell commands
|
||||
}
|
||||
|
||||
unset -f functname # deletes a function definition
|
||||
declare -f # displays all defined functions in your login session
|
||||
|
||||
|
||||
##############################################################################
|
||||
# FLOW CONTROLS
|
||||
##############################################################################
|
||||
|
||||
|
||||
statement1 && statement2 # and operator
|
||||
statement1 || statement2 # or operator
|
||||
|
||||
-a # and operator inside a test conditional expression
|
||||
-o # or operator inside a test conditional expression
|
||||
|
||||
# STRINGS
|
||||
|
||||
str1 == str2 # str1 matches str2
|
||||
str1 != str2 # str1 does not match str2
|
||||
str1 < str2 # str1 is less than str2 (alphabetically)
|
||||
str1 > str2 # str1 is greater than str2 (alphabetically)
|
||||
str1 \> str2 # str1 is sorted after str2
|
||||
str1 \< str2 # str1 is sorted before str2
|
||||
-n str1 # str1 is not null (has length greater than 0)
|
||||
-z str1 # str1 is null (has length 0)
|
||||
|
||||
# FILES
|
||||
|
||||
-a file # file exists or its compilation is successful
|
||||
-d file # file exists and is a directory
|
||||
-e file # file exists; same -a
|
||||
-f file # file exists and is a regular file (i.e., not a directory or other special type of file)
|
||||
-r file # you have read permission
|
||||
-s file # file exists and is not empty
|
||||
-w file # your have write permission
|
||||
-x file # you have execute permission on file, or directory search permission if it is a directory
|
||||
-N file # file was modified since it was last read
|
||||
-O file # you own file
|
||||
-G file # file's group ID matches yours (or one of yours, if you are in multiple groups)
|
||||
file1 -nt file2 # file1 is newer than file2
|
||||
file1 -ot file2 # file1 is older than file2
|
||||
|
||||
# NUMBERS
|
||||
|
||||
-lt # less than
|
||||
-le # less than or equal
|
||||
-eq # equal
|
||||
-ge # greater than or equal
|
||||
-gt # greater than
|
||||
-ne # not equal
|
||||
|
||||
if condition
|
||||
then
|
||||
statements
|
||||
[elif condition
|
||||
then statements...]
|
||||
[else
|
||||
statements]
|
||||
fi
|
||||
|
||||
for x in {1..10}
|
||||
do
|
||||
statements
|
||||
done
|
||||
|
||||
for name [in list]
|
||||
do
|
||||
statements that can use $name
|
||||
done
|
||||
|
||||
for (( initialisation ; ending condition ; update ))
|
||||
do
|
||||
statements...
|
||||
done
|
||||
|
||||
case expression in
|
||||
pattern1 )
|
||||
statements ;;
|
||||
pattern2 )
|
||||
statements ;;
|
||||
esac
|
||||
|
||||
select name [in list]
|
||||
do
|
||||
statements that can use $name
|
||||
done
|
||||
|
||||
while condition; do
|
||||
statements
|
||||
done
|
||||
|
||||
until condition; do
|
||||
statements
|
||||
done
|
||||
|
||||
##############################################################################
|
||||
# COMMAND-LINE PROCESSING CYCLE
|
||||
##############################################################################
|
||||
|
||||
|
||||
# The default order for command lookup is functions, followed by built-ins, with scripts and executables last.
|
||||
# There are three built-ins that you can use to override this order: `command`, `builtin` and `enable`.
|
||||
|
||||
command # removes alias and function lookup. Only built-ins and commands found in the search path are executed
|
||||
builtin # looks up only built-in commands, ignoring functions and commands found in PATH
|
||||
enable # enables and disables shell built-ins
|
||||
|
||||
eval # takes arguments and run them through the command-line processing steps all over again
|
||||
|
||||
|
||||
##############################################################################
|
||||
# INPUT/OUTPUT REDIRECTORS
|
||||
##############################################################################
|
||||
|
||||
|
||||
cmd1|cmd2 # pipe; takes standard output of cmd1 as standard input to cmd2
|
||||
< file # takes standard input from file
|
||||
> file # directs standard output to file
|
||||
>> file # directs standard output to file; append to file if it already exists
|
||||
>|file # forces standard output to file even if noclobber is set
|
||||
n>|file # forces output to file from file descriptor n even if noclobber is set
|
||||
<> file # uses file as both standard input and standard output
|
||||
n<>file # uses file as both input and output for file descriptor n
|
||||
n>file # directs file descriptor n to file
|
||||
n<file # takes file descriptor n from file
|
||||
n>>file # directs file description n to file; append to file if it already exists
|
||||
n>& # duplicates standard output to file descriptor n
|
||||
n<& # duplicates standard input from file descriptor n
|
||||
n>&m # file descriptor n is made to be a copy of the output file descriptor
|
||||
n<&m # file descriptor n is made to be a copy of the input file descriptor
|
||||
&>file # directs standard output and standard error to file
|
||||
<&- # closes the standard input
|
||||
>&- # closes the standard output
|
||||
n>&- # closes the ouput from file descriptor n
|
||||
n<&- # closes the input from file descriptor n
|
||||
|
||||
|tee <file># output command to both terminal and a file (-a to append to file)
|
||||
|
||||
|
||||
##############################################################################
|
||||
# PROCESS HANDLING
|
||||
##############################################################################
|
||||
|
||||
|
||||
# To suspend a job, type CTRL+Z while it is running. You can also suspend a job with CTRL+Y.
|
||||
# This is slightly different from CTRL+Z in that the process is only stopped when it attempts to read input from terminal.
|
||||
# Of course, to interrupt a job, type CTRL+C.
|
||||
|
||||
myCommand & # runs job in the background and prompts back the shell
|
||||
|
||||
jobs # lists all jobs (use with -l to see associated PID)
|
||||
|
||||
fg # brings a background job into the foreground
|
||||
fg %+ # brings most recently invoked background job
|
||||
fg %- # brings second most recently invoked background job
|
||||
fg %N # brings job number N
|
||||
fg %string # brings job whose command begins with string
|
||||
fg %?string # brings job whose command contains string
|
||||
|
||||
kill -l # returns a list of all signals on the system, by name and number
|
||||
kill PID # terminates process with specified PID
|
||||
kill -s SIGKILL 4500 # sends a signal to force or terminate the process
|
||||
kill -15 913 # Ending PID 913 process with signal 15 (TERM)
|
||||
kill %1 # Where %1 is the number of job as read from 'jobs' command.
|
||||
|
||||
ps # prints a line of information about the current running login shell and any processes running under it
|
||||
ps -a # selects all processes with a tty except session leaders
|
||||
|
||||
trap cmd sig1 sig2 # executes a command when a signal is received by the script
|
||||
trap "" sig1 sig2 # ignores that signals
|
||||
trap - sig1 sig2 # resets the action taken when the signal is received to the default
|
||||
|
||||
disown <PID|JID> # removes the process from the list of jobs
|
||||
|
||||
wait # waits until all background jobs have finished
|
||||
sleep <number> # wait # of seconds before continuing
|
||||
|
||||
pv # display progress bar for data handling commands. often used with pipe like |pv
|
||||
yes # give yes response everytime an input is requested from script/process
|
||||
|
||||
|
||||
##############################################################################
|
||||
# TIPS & TRICKS
|
||||
##############################################################################
|
||||
|
||||
|
||||
# set an alias
|
||||
cd; nano .bash_profile
|
||||
> alias gentlenode='ssh admin@gentlenode.com -p 3404' # add your alias in .bash_profile
|
||||
|
||||
# to quickly go to a specific directory
|
||||
cd; nano .bashrc
|
||||
> shopt -s cdable_vars
|
||||
> export websites="/Users/mac/Documents/websites"
|
||||
|
||||
source .bashrc
|
||||
cd $websites
|
||||
|
||||
|
||||
##############################################################################
|
||||
# DEBUGGING SHELL PROGRAMS
|
||||
##############################################################################
|
||||
|
||||
|
||||
bash -n scriptname # don't run commands; check for syntax errors only
|
||||
set -o noexec # alternative (set option in script)
|
||||
|
||||
bash -v scriptname # echo commands before running them
|
||||
set -o verbose # alternative (set option in script)
|
||||
|
||||
bash -x scriptname # echo commands after command-line processing
|
||||
set -o xtrace # alternative (set option in script)
|
||||
|
||||
trap 'echo $varname' EXIT # useful when you want to print out the values of variables at the point that your script exits
|
||||
|
||||
function errtrap {
|
||||
es=$?
|
||||
echo "ERROR line $1: Command exited with status $es."
|
||||
}
|
||||
|
||||
trap 'errtrap $LINENO' ERR # is run whenever a command in the surrounding script or function exits with non-zero status
|
||||
|
||||
function dbgtrap {
|
||||
echo "badvar is $badvar"
|
||||
}
|
||||
|
||||
trap dbgtrap DEBUG # causes the trap code to be executed before every statement in a function or script
|
||||
# ...section of code in which the problem occurs...
|
||||
trap - DEBUG # turn off the DEBUG trap
|
||||
|
||||
function returntrap {
|
||||
echo "A return occurred"
|
||||
}
|
||||
|
||||
trap returntrap RETURN # is executed each time a shell function or a script executed with the . or source commands finishes executing
|
||||
|
||||
##############################################################################
|
||||
# COLORS AND BACKGROUNDS
|
||||
##############################################################################
|
||||
# note: \e or \x1B also work instead of \033
|
||||
# Reset
|
||||
Color_Off='\033[0m' # Text Reset
|
||||
|
||||
# Regular Colors
|
||||
Black='\033[0;30m' # Black
|
||||
Red='\033[0;31m' # Red
|
||||
Green='\033[0;32m' # Green
|
||||
Yellow='\033[0;33m' # Yellow
|
||||
Blue='\033[0;34m' # Blue
|
||||
Purple='\033[0;35m' # Purple
|
||||
Cyan='\033[0;36m' # Cyan
|
||||
White='\033[0;97m' # White
|
||||
|
||||
# Additional colors
|
||||
LGrey='\033[0;37m' # Light Gray
|
||||
DGrey='\033[0;90m' # Dark Gray
|
||||
LRed='\033[0;91m' # Light Red
|
||||
LGreen='\033[0;92m' # Light Green
|
||||
LYellow='\033[0;93m'# Light Yellow
|
||||
LBlue='\033[0;94m' # Light Blue
|
||||
LPurple='\033[0;95m'# Light Purple
|
||||
LCyan='\033[0;96m' # Light Cyan
|
||||
|
||||
|
||||
# Bold
|
||||
BBlack='\033[1;30m' # Black
|
||||
BRed='\033[1;31m' # Red
|
||||
BGreen='\033[1;32m' # Green
|
||||
BYellow='\033[1;33m'# Yellow
|
||||
BBlue='\033[1;34m' # Blue
|
||||
BPurple='\033[1;35m'# Purple
|
||||
BCyan='\033[1;36m' # Cyan
|
||||
BWhite='\033[1;37m' # White
|
||||
|
||||
# Underline
|
||||
UBlack='\033[4;30m' # Black
|
||||
URed='\033[4;31m' # Red
|
||||
UGreen='\033[4;32m' # Green
|
||||
UYellow='\033[4;33m'# Yellow
|
||||
UBlue='\033[4;34m' # Blue
|
||||
UPurple='\033[4;35m'# Purple
|
||||
UCyan='\033[4;36m' # Cyan
|
||||
UWhite='\033[4;37m' # White
|
||||
|
||||
# Background
|
||||
On_Black='\033[40m' # Black
|
||||
On_Red='\033[41m' # Red
|
||||
On_Green='\033[42m' # Green
|
||||
On_Yellow='\033[43m'# Yellow
|
||||
On_Blue='\033[44m' # Blue
|
||||
On_Purple='\033[45m'# Purple
|
||||
On_Cyan='\033[46m' # Cyan
|
||||
On_White='\033[47m' # White
|
||||
|
||||
# Example of usage
|
||||
echo -e "${Green}This is GREEN text${Color_Off} and normal text"
|
||||
echo -e "${Red}${On_White}This is Red test on White background${Color_Off}"
|
||||
# option -e is mandatory, it enable interpretation of backslash escapes
|
||||
printf "${Red} This is red \n"
|
||||
```
|
||||
@@ -0,0 +1,22 @@
|
||||
<script setup lang="ts">
|
||||
import { useThemeVars } from 'naive-ui';
|
||||
import Memo from './bash-memo.content.md';
|
||||
|
||||
const themeVars = useThemeVars();
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<Memo />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style lang="less" scoped>
|
||||
::v-deep(pre) {
|
||||
margin: 0;
|
||||
padding: 15px 22px;
|
||||
background-color: v-bind('themeVars.cardColor');
|
||||
border-radius: 4px;
|
||||
overflow: auto;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Command } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Bash Cheatsheet',
|
||||
path: '/bash-memo',
|
||||
description: 'Bash common commands',
|
||||
keywords: ['bash', 'shell'],
|
||||
component: () => import('./bash-memo.vue'),
|
||||
icon: Command,
|
||||
createdAt: new Date('2025-05-08'),
|
||||
category: 'Cheatsheets',
|
||||
});
|
||||
@@ -7,7 +7,7 @@ const themeVars = useThemeVars();
|
||||
|
||||
const input = ref('');
|
||||
const saltCount = ref(10);
|
||||
const hashed = computed(() => hashSync(input.value, saltCount.value));
|
||||
const hashed = computed(() => hashSync(input.value, saltCount.value || 10));
|
||||
const { copy } = useCopy({ source: hashed, text: 'Hashed string copied to the clipboard' });
|
||||
|
||||
const compareString = ref('');
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
import { NCard, NForm, NFormItem, NInput } from 'naive-ui';
|
||||
|
||||
const bimiData = ref({
|
||||
domain: '',
|
||||
logoUrl: '',
|
||||
vmcUrl: '',
|
||||
});
|
||||
|
||||
const bimiRecord = computed(() => {
|
||||
if (!bimiData.value.domain || !bimiData.value.logoUrl) {
|
||||
return '';
|
||||
}
|
||||
|
||||
let record = `default._bimi.${bimiData.value.domain} IN TXT "v=BIMI1; l=${bimiData.value.logoUrl}`;
|
||||
|
||||
if (bimiData.value.vmcUrl) {
|
||||
record += `; a=${bimiData.value.vmcUrl}`;
|
||||
}
|
||||
|
||||
record += '"';
|
||||
|
||||
return record;
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<NCard title="BIMI DNS Record Generator">
|
||||
<NForm :model="bimiData" label-placement="left" label-width="150px">
|
||||
<NFormItem label="Domain:">
|
||||
<NInput v-model:value="bimiData.domain" placeholder="example.com" />
|
||||
</NFormItem>
|
||||
<NFormItem label="Logo URL:">
|
||||
<NInput v-model:value="bimiData.logoUrl" placeholder="https://example.com/logo.svg" />
|
||||
</NFormItem>
|
||||
<NFormItem label="VMC Certificate URL:">
|
||||
<NInput v-model:value="bimiData.vmcUrl" placeholder="https://example.com/vmc.pem" />
|
||||
</NFormItem>
|
||||
</NForm>
|
||||
|
||||
<c-card title="Generated BIMI record">
|
||||
<textarea-copyable :value="bimiRecord" />
|
||||
</c-card>
|
||||
</NCard>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { World } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'BIMI DNS Generator',
|
||||
path: '/bimi-dns-generator',
|
||||
description: 'Generate BIMI DNS TXT record',
|
||||
keywords: ['bimi', 'dns', 'txt'],
|
||||
component: () => import('./bimi-dns-generator.vue'),
|
||||
icon: World,
|
||||
createdAt: new Date('2025-04-21'),
|
||||
category: 'Network',
|
||||
});
|
||||
@@ -0,0 +1,66 @@
|
||||
<script setup lang="ts">
|
||||
const units = ref('metric');
|
||||
const weight = ref<number | null>(null);
|
||||
const height = ref<number | null>(null);
|
||||
|
||||
const options = [
|
||||
{ label: 'Metric (kg, m)', value: 'metric' },
|
||||
{ label: 'US (lbs, in)', value: 'us' },
|
||||
];
|
||||
|
||||
const bmi = computed(() => {
|
||||
if (!weight.value || !height.value) {
|
||||
return null;
|
||||
}
|
||||
let convertedWeight = weight.value;
|
||||
let convertedHeight = height.value;
|
||||
|
||||
if (units.value === 'us') {
|
||||
convertedWeight = weight.value * 0.453592; // lbs to kg
|
||||
convertedHeight = height.value * 0.0254; // inches to meters
|
||||
}
|
||||
|
||||
return (convertedWeight / (convertedHeight * convertedHeight)).toFixed(2);
|
||||
});
|
||||
|
||||
const bmiCategory = computed(() => {
|
||||
if (!bmi.value) {
|
||||
return '';
|
||||
}
|
||||
const value = Number.parseFloat(bmi.value);
|
||||
if (value < 18.5) {
|
||||
return 'Underweight';
|
||||
}
|
||||
if (value < 24.999) {
|
||||
return 'Normal weight';
|
||||
}
|
||||
if (value < 29.999) {
|
||||
return 'Overweight';
|
||||
}
|
||||
if (value < 34.999) {
|
||||
return 'Class 1 Obesity';
|
||||
}
|
||||
if (value < 39.999) {
|
||||
return 'Class 2 Obesity';
|
||||
}
|
||||
return 'Severe Obesity (Class 3 Obesity)';
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<c-card title="BMI Calculator" max-w-800px>
|
||||
<c-select v-model:value="units" label="Select Units:" :options="options" mb-2 label-position="left" />
|
||||
<n-space justify="space-evenly">
|
||||
<n-form-item :label="`Weight (${(units === 'metric' ? 'kg' : 'lbs')}):`" label-placement="left" mb-2>
|
||||
<n-input-number v-model:value="weight" placeholder="Enter weight" />
|
||||
</n-form-item>
|
||||
<n-form-item :label="`Height (${(units === 'metric' ? 'm' : 'in')}):`" label-placement="left" mb-2>
|
||||
<n-input-number v-model:value="height" placeholder="Enter height" />
|
||||
</n-form-item>
|
||||
</n-space>
|
||||
<c-card v-if="bmi" title="Result">
|
||||
<input-copyable label="BMI:" label-position="left" label-width="100px" :value="bmi" mb-1 />
|
||||
<input-copyable label="Category:" label-position="left" label-width="100px" :value="bmiCategory" />
|
||||
</c-card>
|
||||
</c-card>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { MedicalCross } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'BMI Calculator',
|
||||
path: '/bmi-calculator',
|
||||
description: 'Body Mass Index Calculator (us or metric units)',
|
||||
keywords: ['bmi', 'body', 'mass'],
|
||||
component: () => import('./bmi-calculator.vue'),
|
||||
icon: MedicalCross,
|
||||
createdAt: new Date('2025-04-21'),
|
||||
category: 'Data',
|
||||
});
|
||||
@@ -5,6 +5,7 @@ import type {
|
||||
Key,
|
||||
PrivateKey, Signature,
|
||||
} from 'sshpk';
|
||||
import 'webcrypto-liner-shim';
|
||||
import type * as openpgp from 'openpgp';
|
||||
import * as forge from 'node-forge';
|
||||
import oids from './oids.json';
|
||||
@@ -63,6 +64,11 @@ export function getPublicKeyLabelValues(publicKey: Key) {
|
||||
value: onErrorReturnErrorMessage(() => publicKey.fingerprint('sha512')),
|
||||
multiline: true,
|
||||
},
|
||||
{
|
||||
label: 'Key (PEM):',
|
||||
value: onErrorReturnErrorMessage(() => publicKey.toString('pem')),
|
||||
multiline: true,
|
||||
},
|
||||
] as LabelValue[];
|
||||
}
|
||||
|
||||
@@ -99,6 +105,11 @@ export function getPrivateKeyLabelValues(privateKey: PrivateKey) {
|
||||
value: onErrorReturnErrorMessage(() => privateKey.fingerprint('sha512')),
|
||||
multiline: true,
|
||||
},
|
||||
{
|
||||
label: 'Key (PEM):',
|
||||
value: onErrorReturnErrorMessage(() => privateKey.toString('pem')),
|
||||
multiline: true,
|
||||
},
|
||||
] as LabelValue[];
|
||||
}
|
||||
|
||||
|
||||
@@ -14,10 +14,27 @@ import type {
|
||||
PrivateKey, Signature, SignatureFormatType,
|
||||
} from 'sshpk';
|
||||
import { Base64 } from 'js-base64';
|
||||
import 'webcrypto-liner-shim';
|
||||
import * as openpgp from 'openpgp';
|
||||
import * as forge from 'node-forge';
|
||||
import { type LabelValue, getCSRLabelValues, getCertificateLabelValues, getFingerprintLabelValues, getPGPPrivateKeyLabelValuesAsync, getPGPPublicKeyLabelValuesAsync, getPrivateKeyLabelValues, getPublicKeyLabelValues, getSignatureLabelValues } from './certificate-key-parser.infos';
|
||||
|
||||
export async function getKeysOrCertificatesInfosAsync(keyOrCertificateValue: string | Buffer, passphrase: string) {
|
||||
const parts = keyOrCertificateValue.toString().trim().split(/(-----BEGIN [^-]+-----\n)/).filter(s => s !== '');
|
||||
if (!parts.length) {
|
||||
return [await getKeyOrCertificateInfosAsync(keyOrCertificateValue, passphrase)];
|
||||
}
|
||||
const parsedPEMs: Array<{
|
||||
values: LabelValue[]
|
||||
certificateX509DER?: undefined | string
|
||||
}> = [];
|
||||
for (let i = 0; i < parts.length; i += 2) {
|
||||
const pemPart = parts[i] + parts[i + 1];
|
||||
parsedPEMs.push(await getKeyOrCertificateInfosAsync(pemPart, passphrase));
|
||||
}
|
||||
return parsedPEMs;
|
||||
}
|
||||
|
||||
export async function getKeyOrCertificateInfosAsync(keyOrCertificateValue: string | Buffer, passphrase: string) {
|
||||
try {
|
||||
const canParse = (value: string | Buffer, parseFunction: (value: string | Buffer) => any) => {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<script setup lang="ts">
|
||||
import { Buffer } from 'node:buffer';
|
||||
|
||||
import { getKeyOrCertificateInfosAsync } from './certificate-key-parser.service';
|
||||
import { getKeysOrCertificatesInfosAsync } from './certificate-key-parser.service';
|
||||
import { type LabelValue } from './certificate-key-parser.infos';
|
||||
import { useDownloadFileFromBase64 } from '@/composable/downloadBase64';
|
||||
|
||||
@@ -37,7 +37,7 @@ function downloadX509DERFile() {
|
||||
}
|
||||
}
|
||||
|
||||
const parsedSections = computedAsync<LabelValue[]>(async () => {
|
||||
const parsedSections = computedAsync<LabelValue[][]>(async () => {
|
||||
const inputContent = inputKeyOrCertificate.value;
|
||||
const file = fileInput.value;
|
||||
let inputKeyOrCertificateValue: string | Buffer = '';
|
||||
@@ -47,9 +47,22 @@ const parsedSections = computedAsync<LabelValue[]>(async () => {
|
||||
else if (inputType.value === 'content' && inputContent) {
|
||||
inputKeyOrCertificateValue = inputContent;
|
||||
}
|
||||
const { values, certificateX509DER: certPEM } = await getKeyOrCertificateInfosAsync(inputKeyOrCertificateValue, passphrase.value);
|
||||
certificateX509DER.value = certPEM || '';
|
||||
return values;
|
||||
try {
|
||||
const parsed = await getKeysOrCertificatesInfosAsync(inputKeyOrCertificateValue, passphrase.value);
|
||||
if (parsed.length === 1) {
|
||||
const { values, certificateX509DER: certPEM } = parsed[0];
|
||||
certificateX509DER.value = certPEM || '';
|
||||
return [values];
|
||||
}
|
||||
else {
|
||||
return parsed.map(p => p.values);
|
||||
}
|
||||
}
|
||||
catch (e: any) {
|
||||
return [
|
||||
[{ label: 'Parsing Error', value: e.toString() }],
|
||||
];
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
@@ -96,20 +109,26 @@ const parsedSections = computedAsync<LabelValue[]>(async () => {
|
||||
|
||||
<n-divider />
|
||||
|
||||
<input-copyable
|
||||
v-for="{ label, value, multiline } of parsedSections"
|
||||
:key="label"
|
||||
:label="label"
|
||||
:data-test-id="label"
|
||||
label-position="left"
|
||||
label-width="100px"
|
||||
label-align="right"
|
||||
<c-card
|
||||
v-for="(part, partIndex) of parsedSections"
|
||||
:key="partIndex"
|
||||
mb-2
|
||||
>
|
||||
<input-copyable
|
||||
v-for="{ label, value, multiline } of part"
|
||||
:key="label"
|
||||
:label="label"
|
||||
:data-test-id="label"
|
||||
label-position="left"
|
||||
label-width="100px"
|
||||
label-align="right"
|
||||
|
||||
autosize mb-2
|
||||
:multiline="multiline"
|
||||
:value="value"
|
||||
placeholder="Not Set"
|
||||
/>
|
||||
autosize mb-2
|
||||
:multiline="multiline"
|
||||
:value="value"
|
||||
placeholder="Not Set"
|
||||
/>
|
||||
</c-card>
|
||||
|
||||
<div v-if="certificateX509DER !== ''" flex justify-center>
|
||||
<c-button @click="downloadX509DERFile()">
|
||||
|
||||
@@ -12,7 +12,7 @@ const [coinFlip, refreshCoinFlip] = computedRefreshable(() => ({
|
||||
<div>
|
||||
<Transition name="bounce" mode="out-in">
|
||||
<div :key="coinFlip.dt" flex items-center justify-center>
|
||||
<div flex items-center justify-center rounded-full outline style="width: 5em; height: 5em">
|
||||
<div style="width: 5em; height: 5em" mb-1 mt-1 flex items-center justify-center rounded-full outline>
|
||||
{{ coinFlip.coin }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,25 +1,49 @@
|
||||
<script setup lang="ts">
|
||||
import { contrastRatio, passesWCAG } from 'wcag-contrast-utils';
|
||||
import { apcaContrastValue, hex, wcag, wcagContrastValue } from 'a11y-color-contrast';
|
||||
import { useQueryParam } from '@/composable/queryParams';
|
||||
|
||||
const forecolor = useQueryParam({ name: 'fg', defaultValue: '#000' });
|
||||
const backcolor = useQueryParam({ name: 'bg', defaultValue: '#fff' });
|
||||
|
||||
const levels = [
|
||||
{ score: 3, text: 'Very poor', bg: '#fbd0da', fg: '#5f071c', stars: 1 },
|
||||
{ score: 4.5, text: 'Poor', bg: '#fbd0da', fg: '#5f071c', stars: 2 },
|
||||
{ score: 7, text: 'Good', bg: '#fbf5d0', fg: '#5f5207', stars: 3 },
|
||||
{ score: 12, text: 'Very good', bg: '#d2fbd0', fg: '#0d5f07', stars: 4 },
|
||||
{ score: 9999, text: 'Super', bg: '#d2fbd0', fg: '#0d5f07', stars: 5 },
|
||||
];
|
||||
const smallLevels = [
|
||||
{ score: 4.5, bg: '#fbd0da', fg: '#5f071c', stars: 1 },
|
||||
{ score: 7, bg: '#fbf5d0', fg: '#5f5207', stars: 2 },
|
||||
{ score: 9999, bg: '#d2fbd0', fg: '#0d5f07', stars: 3 },
|
||||
];
|
||||
const largeLevels = [
|
||||
{ score: 3, bg: '#fbd0da', fg: '#5f071c', stars: 1 },
|
||||
{ score: 4.5, bg: '#fbf5d0', fg: '#5f5207', stars: 2 },
|
||||
{ score: 9999, bg: '#d2fbd0', fg: '#0d5f07', stars: 3 },
|
||||
];
|
||||
|
||||
const result = computed(() => {
|
||||
try {
|
||||
const constrastValue = contrastRatio(forecolor.value, backcolor.value);
|
||||
const wcagLevel = passesWCAG(constrastValue);
|
||||
const fgHex = hex(forecolor.value);
|
||||
const bgHex = hex(backcolor.value);
|
||||
|
||||
const wcagLevel = wcagContrastValue(bgHex, fgHex);
|
||||
return {
|
||||
constrastValue,
|
||||
wcagLevel,
|
||||
wcag21ConstrastValue: wcagLevel,
|
||||
aaNormal: wcag(bgHex, fgHex, { level: 'AA', size: 'normal' }).pass,
|
||||
aaaNormal: wcag(bgHex, fgHex, { level: 'AAA', size: 'normal' }).pass,
|
||||
aaLarge: wcag(bgHex, fgHex, { level: 'AA', size: 'large' }).pass,
|
||||
aaaLarge: wcag(bgHex, fgHex, { level: 'AAA', size: 'large' }).pass,
|
||||
level: levels.find(l => wcagLevel < l.score),
|
||||
largeLevel: largeLevels.find(l => wcagLevel < l.score),
|
||||
smallLevel: smallLevels.find(l => wcagLevel < l.score),
|
||||
apcaContrastValue: apcaContrastValue(bgHex, fgHex),
|
||||
error: '',
|
||||
};
|
||||
}
|
||||
catch (e: any) {
|
||||
return {
|
||||
constrastValue: -1,
|
||||
wcagLevel: '',
|
||||
error: e.toString(),
|
||||
};
|
||||
}
|
||||
@@ -57,7 +81,57 @@ const result = computed(() => {
|
||||
{{ result.error }}
|
||||
</c-alert>
|
||||
|
||||
<input-copyable v-if="!result.error" readonly label="Constrast:" label-width="100px" label-position="left" :value="result.constrastValue" mb-2 />
|
||||
<input-copyable v-if="!result.error" readonly label="Level:" label-width="100px" label-position="left" :value="result.wcagLevel" />
|
||||
<c-card v-if="!result.error" title="WCAG 2.1">
|
||||
<input-copyable readonly label="WCAG Constrast:" label-width="130px" label-position="left" :value="result.wcag21ConstrastValue" mb-3 />
|
||||
|
||||
<n-form-item v-if="result.level" label="Contrast quality:" label-width="130px" label-placement="left">
|
||||
<n-tag :max="5" :color="{ color: result.level.bg, textColor: result.level.fg, borderColor: result.level.fg }" mr-2>
|
||||
<span>{{ result.wcag21ConstrastValue.toFixed(2) }} - {{ result.level.text }}</span>
|
||||
</n-tag>
|
||||
<n-tag :max="5" :color="{ color: result.level.bg, textColor: result.level.fg, borderColor: result.level.fg }">
|
||||
<n-rate :count="5" readonly :default-value="result.level.stars" :color="result.level.fg" />
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
<n-form-item v-if="result.smallLevel" label="Small texts:" label-width="130px" label-placement="left">
|
||||
<n-tag :color="{ color: result.smallLevel.bg, textColor: result.smallLevel.fg, borderColor: result.smallLevel.fg }">
|
||||
<n-rate :count="3" readonly :default-value="result.smallLevel.stars" :color="result.smallLevel.fg" />
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
<n-form-item v-if="result.largeLevel" label="Large texts:" label-width="130px" label-placement="left">
|
||||
<n-tag :color="{ color: result.largeLevel.bg, textColor: result.largeLevel.fg, borderColor: result.largeLevel.fg }">
|
||||
<n-rate :count="3" readonly :default-value="result.largeLevel.stars" :color="result.largeLevel.fg" />
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
|
||||
<c-card title="Normal text">
|
||||
<n-form-item label="WCAG 2.1 AA:" label-width="130px" label-placement="left">
|
||||
<n-tag :bordered="false" :type="result.aaNormal ? 'success' : 'error'">
|
||||
{{ result.aaNormal ? 'Pass' : 'Fail' }}
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
<n-form-item label="WCAG 2.1 AAA:" label-width="130px" label-placement="left">
|
||||
<n-tag :bordered="false" :type="result.aaaNormal ? 'success' : 'error'">
|
||||
{{ result.aaaNormal ? 'Pass' : 'Fail' }}
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
</c-card>
|
||||
<c-card title="Large text">
|
||||
<n-p><i>Text that is 14pt (18.67px) and bold or any text bigger than 18pt (24px) is defined as large scale text.</i></n-p>
|
||||
<n-form-item label="WCAG 2.1 AA:" label-width="130px" label-placement="left">
|
||||
<n-tag :bordered="false" :type="result.aaLarge ? 'success' : 'error'">
|
||||
{{ result.aaLarge ? 'Pass' : 'Fail' }}
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
<n-form-item label="WCAG 2.1 AAA:" label-width="130px" label-placement="left">
|
||||
<n-tag :bordered="false" :type="result.aaaLarge ? 'success' : 'error'">
|
||||
{{ result.aaaLarge ? 'Pass' : 'Fail' }}
|
||||
</n-tag>
|
||||
</n-form-item>
|
||||
</c-card>
|
||||
</c-card>
|
||||
|
||||
<c-card v-if="!result.error" title="APCA">
|
||||
<input-copyable readonly label="APCA Constrast:" label-width="130px" label-position="left" :value="result.apcaContrastValue" mb-2 />
|
||||
</c-card>
|
||||
</div>
|
||||
</template>
|
||||
@@ -0,0 +1,41 @@
|
||||
<script lang="ts" setup>
|
||||
import { useQueryParam } from '@/composable/queryParams';
|
||||
|
||||
const cookieHeader = useQueryParam({ name: 'cookies', defaultValue: '' });
|
||||
|
||||
const parsedCookies = computed(() => {
|
||||
return (cookieHeader.value || '').replace(/^Cookie:\s*/, '').split('; ').map((cookie) => {
|
||||
const [name, ...values] = cookie.split('=');
|
||||
return { name, value: decodeURIComponent(values?.join('=') || '') };
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<n-card title="Cookie Parser">
|
||||
<n-space vertical>
|
||||
<n-input v-model:value="cookieHeader" placeholder="Enter cookie header" type="text" />
|
||||
</n-space>
|
||||
<n-p>
|
||||
Tip: Navigate to a website to test, open F12 Console and run <n-tag :bordered="false">
|
||||
<code>window.copy(document.cookie)</code>
|
||||
</n-tag>. This will copy the cookie string to your clipboard. Note: This will only copy cookies available to javascript (HTTP only and secure cookies will be omitted).
|
||||
</n-p>
|
||||
<n-table v-if="parsedCookies.length">
|
||||
<thead><tr><th>Name</th><th>Value</th></tr></thead>
|
||||
<tbody>
|
||||
<tr v-for="cookie in parsedCookies" :key="cookie.name">
|
||||
<td>
|
||||
<n-a :href="`https://cookiedatabase.org/?s=${cookie.name}`" target="_blank">
|
||||
{{ cookie.name }}
|
||||
</n-a>
|
||||
</td>
|
||||
<td>{{ cookie.value }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</n-table>
|
||||
<n-alert v-else type="warning">
|
||||
No cookies found
|
||||
</n-alert>
|
||||
</n-card>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Cookie } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Cookies Parser',
|
||||
path: '/cookies-parser',
|
||||
description: 'Parse Cookie HTTP Header',
|
||||
keywords: ['cookies', 'parser'],
|
||||
component: () => import('./cookies-parser.vue'),
|
||||
icon: Cookie,
|
||||
createdAt: new Date('2025-05-01'),
|
||||
category: 'Forensic',
|
||||
});
|
||||
@@ -0,0 +1,203 @@
|
||||
<script setup lang="ts">
|
||||
import { Countdown } from 'vue3-flip-countdown';
|
||||
import moment from 'moment';
|
||||
import { useQueryParam } from '@/composable/queryParams';
|
||||
|
||||
interface CountDown {
|
||||
d: number
|
||||
h: number
|
||||
m: number
|
||||
s: number
|
||||
}
|
||||
|
||||
function getCountDownHref(c: CountDown) {
|
||||
const parsedUrl = new URL(window.location.href);
|
||||
parsedUrl.searchParams.set('d', c.d.toString());
|
||||
parsedUrl.searchParams.set('h', c.h.toString());
|
||||
parsedUrl.searchParams.set('m', c.m.toString());
|
||||
parsedUrl.searchParams.set('s', c.s.toString());
|
||||
return parsedUrl.toString();
|
||||
}
|
||||
|
||||
const days = useQueryParam({ name: 'd', defaultValue: 0 });
|
||||
const hours = useQueryParam({ name: 'h', defaultValue: 0 });
|
||||
const minutes = useQueryParam({ name: 'm', defaultValue: 0 });
|
||||
const seconds = useQueryParam({ name: 's', defaultValue: 0 });
|
||||
const history = useStorage<CountDown[]>('countdown:hst', []);
|
||||
|
||||
const status = ref<'stopped' | 'ended' | 'running'>('stopped');
|
||||
|
||||
const audio = ref<HTMLAudioElement | null>(null);
|
||||
|
||||
watchEffect(() => {
|
||||
if (status.value === 'ended') {
|
||||
audio.value?.play();
|
||||
}
|
||||
});
|
||||
|
||||
const now = ref(moment());
|
||||
const deadlineDate = computed(() => {
|
||||
return now.value
|
||||
.add(days.value, 'd')
|
||||
.add(hours.value, 'h')
|
||||
.add(minutes.value, 'm')
|
||||
.add(seconds.value, 's')
|
||||
.toDate();
|
||||
});
|
||||
const fmt = 'YYYY-MM-DD HH:mm:ss';
|
||||
const deadlineFormatted = computed(() => {
|
||||
return now.value
|
||||
.add(days.value, 'd')
|
||||
.add(hours.value, 'h')
|
||||
.add(minutes.value, 'm')
|
||||
.add(seconds.value, 's')
|
||||
.format(fmt);
|
||||
});
|
||||
|
||||
function start() {
|
||||
now.value = moment();
|
||||
status.value = 'running';
|
||||
const histoEntry = { d: days.value, h: hours.value, m: minutes.value, s: seconds.value };
|
||||
if (!history.value.find(h => h.d === histoEntry.d && h.h === histoEntry.h && h.m === histoEntry.m && h.s === histoEntry.s)) {
|
||||
history.value = [histoEntry, ...history.value];
|
||||
}
|
||||
}
|
||||
|
||||
function stop() {
|
||||
status.value = 'stopped';
|
||||
audio.value?.pause();
|
||||
}
|
||||
|
||||
function ended() {
|
||||
if (status.value === 'running') {
|
||||
status.value = 'ended';
|
||||
}
|
||||
if (document.fullscreenElement) {
|
||||
document.exitFullscreen?.();
|
||||
}
|
||||
}
|
||||
|
||||
const fullScreenElement = ref<HTMLElement>();
|
||||
function toggleFullScreen() {
|
||||
const element = fullScreenElement.value;
|
||||
if (!element) {
|
||||
return;
|
||||
}
|
||||
if (!document.fullscreenElement) {
|
||||
element?.requestFullscreen();
|
||||
}
|
||||
else {
|
||||
document.exitFullscreen?.();
|
||||
}
|
||||
}
|
||||
|
||||
const isEnded = computed(() => status.value === 'ended');
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div max-w-600px>
|
||||
<c-card :disabled="status !== 'stopped'" title="Countdown time" mb-4>
|
||||
<div mb-4 flex justify-center gap-2>
|
||||
<n-input-number v-model:value="days" :min="0">
|
||||
<template #suffix>
|
||||
days
|
||||
</template>
|
||||
</n-input-number>
|
||||
<n-input-number v-model:value="hours" :min="0">
|
||||
<template #suffix>
|
||||
hours
|
||||
</template>
|
||||
</n-input-number>
|
||||
<n-input-number v-model:value="minutes" :min="0">
|
||||
<template #suffix>
|
||||
minutes
|
||||
</template>
|
||||
</n-input-number>
|
||||
<n-input-number v-model:value="seconds" :min="0">
|
||||
<template #suffix>
|
||||
seconds
|
||||
</template>
|
||||
</n-input-number>
|
||||
</div>
|
||||
|
||||
<div flex justify-center>
|
||||
<c-button
|
||||
@click="start"
|
||||
>
|
||||
Start
|
||||
</c-button>
|
||||
</div>
|
||||
</c-card>
|
||||
|
||||
<div id="fullScreenElement" ref="fullScreenElement" mb-2>
|
||||
<div>
|
||||
<Countdown :deadline="deadlineFormatted" :stop="status !== 'running'" mb-2 countdown-size="4rem" @time-elapsed="ended()" />
|
||||
|
||||
<div mb-2 flex justify-center>
|
||||
<c-button
|
||||
:disabled="status === 'stopped'"
|
||||
@click="toggleFullScreen"
|
||||
>
|
||||
Toggle Fullscreen
|
||||
</c-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<n-modal v-model:show="isEnded" mask-closable="false">
|
||||
<n-card
|
||||
style="width: 600px"
|
||||
title="Timer finished"
|
||||
:bordered="false"
|
||||
size="huge"
|
||||
role="dialog"
|
||||
aria-modal="true"
|
||||
>
|
||||
<p>Timer ellapsed!</p>
|
||||
<template #footer>
|
||||
<n-button @click="stop()">
|
||||
OK
|
||||
</n-button>
|
||||
</template>
|
||||
</n-card>
|
||||
</n-modal>
|
||||
|
||||
<div mb-2 flex justify-center>
|
||||
<c-button
|
||||
:disabled="status === 'stopped'"
|
||||
@click="stop"
|
||||
>
|
||||
Stop
|
||||
</c-button>
|
||||
</div>
|
||||
|
||||
<n-p align="center">
|
||||
Alarm at: {{ deadlineDate }}
|
||||
</n-p>
|
||||
|
||||
<c-card v-if="history" title="History">
|
||||
<div flex justify-center gap-1>
|
||||
<template v-for="(entry, index) in history" :key="index">
|
||||
{{ index > 0 ? ' / ' : '' }}
|
||||
<n-a :href="getCountDownHref(entry)">
|
||||
{{ entry.d > 0 ? `${entry.d} days` : '' }}
|
||||
{{ entry.h > 0 ? `${entry.h}h` : '' }}
|
||||
{{ entry.m > 0 ? `${entry.m}m` : '' }}
|
||||
{{ entry.s > 0 ? `${entry.s}s` : '' }}
|
||||
</n-a>
|
||||
</template>
|
||||
</div>
|
||||
</c-card>
|
||||
|
||||
<audio ref="audio" loop src="/Beep.mp3" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
#fullScreenElement:fullscreen {
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Alarm } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Countdown',
|
||||
path: '/countdown',
|
||||
description: 'Countdown and alarm at ellapsed duration',
|
||||
keywords: ['countdown'],
|
||||
component: () => import('./countdown.vue'),
|
||||
icon: Alarm,
|
||||
createdAt: new Date('2025-03-09'),
|
||||
category: 'Datetime',
|
||||
});
|
||||
@@ -0,0 +1,3 @@
|
||||
declare module "vue3-flip-countdown" {
|
||||
export function Countdown(): any;
|
||||
}
|
||||
@@ -0,0 +1,190 @@
|
||||
<script setup lang="ts">
|
||||
import { Countdown } from 'vue3-flip-countdown';
|
||||
import { parseExpression } from 'cron-parser';
|
||||
import moment from 'moment';
|
||||
import { useQueryParam } from '@/composable/queryParams';
|
||||
|
||||
const allDays = '0,1,2,3,4,5,6';
|
||||
const alarmAt = useQueryParam({ name: 'at', defaultValue: '17:30:00' });
|
||||
const alarmDays = useQueryParam({ name: 'days', defaultValue: allDays });
|
||||
const history = useStorage<{ days: string; at: string }[]>('cronalarm:hst', []);
|
||||
|
||||
function getTimeHref(at: string, days: string) {
|
||||
const parsedUrl = new URL(window.location.href);
|
||||
parsedUrl.searchParams.set('at', at);
|
||||
parsedUrl.searchParams.set('days', days);
|
||||
return parsedUrl.toString();
|
||||
}
|
||||
|
||||
const status = ref<'stopped' | 'ended' | 'running'>('stopped');
|
||||
|
||||
const audio = ref<HTMLAudioElement | null>(null);
|
||||
|
||||
watchEffect(() => {
|
||||
if (status.value === 'ended') {
|
||||
audio.value?.play();
|
||||
}
|
||||
});
|
||||
|
||||
const now = ref(moment());
|
||||
const daysArray = computed<string[]>({
|
||||
get() {
|
||||
return (alarmDays.value || allDays).split(',').map(s => s.trim());
|
||||
},
|
||||
set(newValue) {
|
||||
alarmDays.value = newValue.join(',');
|
||||
},
|
||||
});
|
||||
const cronExpression = computed(() => {
|
||||
const [h, m, s] = alarmAt.value.split(':');
|
||||
return `${s} ${m} ${h} * * ${alarmDays.value}`;
|
||||
});
|
||||
const alarmAtDate = computed(() => {
|
||||
const interval = parseExpression(cronExpression.value);
|
||||
return interval.next().toDate();
|
||||
});
|
||||
|
||||
const fmt = 'YYYY-MM-DD HH:mm:ss';
|
||||
const alarmAtFormatted = computed(() => {
|
||||
return moment(alarmAtDate.value).format(fmt);
|
||||
});
|
||||
|
||||
function start() {
|
||||
now.value = moment();
|
||||
status.value = 'running';
|
||||
const histoEntry = { at: alarmAt.value, days: alarmDays.value };
|
||||
if (!history.value.find(h => h.at === histoEntry.at && h.days === histoEntry.days)) {
|
||||
history.value = [histoEntry, ...history.value];
|
||||
}
|
||||
}
|
||||
|
||||
function stop() {
|
||||
status.value = 'stopped';
|
||||
audio.value?.pause();
|
||||
}
|
||||
|
||||
function ended() {
|
||||
if (status.value === 'running') {
|
||||
status.value = 'ended';
|
||||
}
|
||||
if (document.fullscreenElement) {
|
||||
document.exitFullscreen?.();
|
||||
}
|
||||
}
|
||||
|
||||
const fullScreenElement = ref<HTMLElement>();
|
||||
function toggleFullScreen() {
|
||||
const element = fullScreenElement.value;
|
||||
if (!element) {
|
||||
return;
|
||||
}
|
||||
if (!document.fullscreenElement) {
|
||||
element?.requestFullscreen();
|
||||
}
|
||||
else {
|
||||
document.exitFullscreen?.();
|
||||
}
|
||||
}
|
||||
|
||||
const isEnded = computed(() => status.value === 'ended');
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div max-w-600px>
|
||||
<c-card :disabled="status !== 'stopped'" title="Alarm" mb-4>
|
||||
<div mb-1 flex justify-center>
|
||||
<n-form-item label="Alarm at:" label-placement="left">
|
||||
<n-time-picker v-model:formatted-value="alarmAt" />
|
||||
</n-form-item>
|
||||
</div>
|
||||
<div flex justify-center>
|
||||
<n-checkbox-group v-model:value="daysArray">
|
||||
<n-space item-style="display: flex;">
|
||||
<n-checkbox value="1" label="Monday" />
|
||||
<n-checkbox value="2" label="Tuesday" />
|
||||
<n-checkbox value="3" label="Wednesday" />
|
||||
<n-checkbox value="4" label="Thursday" />
|
||||
<n-checkbox value="5" label="Friday" />
|
||||
<n-checkbox value="6" label="Saturday" />
|
||||
<n-checkbox value="0" label="Sunday" />
|
||||
</n-space>
|
||||
</n-checkbox-group>
|
||||
</div>
|
||||
|
||||
<div flex justify-center>
|
||||
<c-button
|
||||
@click="start"
|
||||
>
|
||||
Start
|
||||
</c-button>
|
||||
</div>
|
||||
</c-card>
|
||||
|
||||
<div id="fullScreenElement" ref="fullScreenElement" mb-2>
|
||||
<div>
|
||||
<Countdown :deadline="alarmAtFormatted" :stop="status !== 'running'" mb-2 @time-elapsed="ended()" />
|
||||
<div mb-2 flex justify-center>
|
||||
<c-button
|
||||
:disabled="status === 'stopped'"
|
||||
@click="toggleFullScreen"
|
||||
>
|
||||
Toggle Fullscreen
|
||||
</c-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div mb-2 flex justify-center>
|
||||
<c-button
|
||||
:disabled="status === 'stopped'"
|
||||
@click="stop"
|
||||
>
|
||||
Stop
|
||||
</c-button>
|
||||
</div>
|
||||
|
||||
<n-p align="center">
|
||||
Next alarm at: {{ alarmAtDate }}
|
||||
</n-p>
|
||||
|
||||
<n-modal v-model:show="isEnded" mask-closable="false">
|
||||
<n-card
|
||||
style="width: 600px"
|
||||
title="Timer finished"
|
||||
:bordered="false"
|
||||
size="huge"
|
||||
role="dialog"
|
||||
aria-modal="true"
|
||||
>
|
||||
<p>Timer elapsed!</p>
|
||||
<template #footer>
|
||||
<n-button @click="stop()">
|
||||
OK
|
||||
</n-button>
|
||||
</template>
|
||||
</n-card>
|
||||
</n-modal>
|
||||
|
||||
<c-card v-if="history" title="History">
|
||||
<div flex justify-center gap-1>
|
||||
<template v-for="(entry, index) in history" :key="index">
|
||||
{{ index > 0 ? ' / ' : '' }}
|
||||
<n-a :href="getTimeHref(entry.at, entry.days)">
|
||||
At: {{ entry.at }} ; Days: {{ entry.days || '*' }}
|
||||
</n-a>
|
||||
</template>
|
||||
</div>
|
||||
</c-card>
|
||||
|
||||
<audio ref="audio" loop src="/Beep.mp3" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
#fullScreenElement:fullscreen {
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Alarm } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Cron/Weekday Alarm',
|
||||
path: '/cron-alarm',
|
||||
description: 'Alarm based on time and weekdays expression',
|
||||
keywords: ['cron', 'week', 'day', 'alarm'],
|
||||
component: () => import('./cron-alarm.vue'),
|
||||
icon: Alarm,
|
||||
createdAt: new Date('2025-04-21'),
|
||||
category: 'Datetime',
|
||||
});
|
||||
@@ -36,25 +36,25 @@ const commonHelpers = [
|
||||
{
|
||||
symbol: '*',
|
||||
meaning: 'Any value',
|
||||
example: '* * * *',
|
||||
example: '* * * * *',
|
||||
equivalent: 'Every minute',
|
||||
},
|
||||
{
|
||||
symbol: '-',
|
||||
meaning: 'Range of values',
|
||||
example: '1-10 * * *',
|
||||
example: '1-10 * * * *',
|
||||
equivalent: 'Minutes 1 through 10',
|
||||
},
|
||||
{
|
||||
symbol: ',',
|
||||
meaning: 'List of values',
|
||||
example: '1,10 * * *',
|
||||
example: '1,10 * * * *',
|
||||
equivalent: 'At minutes 1 and 10',
|
||||
},
|
||||
{
|
||||
symbol: '/',
|
||||
meaning: 'Step values',
|
||||
example: '*/10 * * *',
|
||||
example: '*/10 * * * *',
|
||||
equivalent: 'Every 10 minutes',
|
||||
},
|
||||
];
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script setup lang="ts">
|
||||
import { useThemeVars } from 'naive-ui';
|
||||
import Memo from './css-selectors-memo.md';
|
||||
import Memo from './css-selectors.md';
|
||||
|
||||
const themeVars = useThemeVars();
|
||||
</script>
|
||||
|
||||
File renamed without changes.
@@ -0,0 +1,130 @@
|
||||
<script lang="ts" setup>
|
||||
import { convertCsvToArray } from '../csv-to-json/csv-to-json.service';
|
||||
import { objectArrayToData } from '@/utils/objectarray.export';
|
||||
import type { ExportFormat } from '@/utils/objectarray.export';
|
||||
|
||||
const inputType = ref<'file' | 'content'>('file');
|
||||
const csvContent = ref('');
|
||||
const fileInput = ref() as Ref<File | null>;
|
||||
const error = ref('');
|
||||
|
||||
const convertedData = ref<string>('');
|
||||
const selectedFormat = ref<string>('json');
|
||||
const tableName = ref<string>('TableName');
|
||||
const nestify = ref(false);
|
||||
const typedValues = ref(false);
|
||||
|
||||
const formats = [
|
||||
{ label: 'JSON', value: 'json' },
|
||||
{ label: 'YAML', value: 'yaml' },
|
||||
{ label: 'SQL INSERT', value: 'sql' },
|
||||
{ label: 'CSV (comma)', value: 'csv' },
|
||||
{ label: 'CSV (semicolon)', value: 'csv_semicolon' },
|
||||
{ label: 'CSV (tab)', value: 'tsv' },
|
||||
{ label: 'Markdown', value: 'markdown' },
|
||||
{ label: 'XML', value: 'xml' },
|
||||
];
|
||||
|
||||
async function handleFileUpload(file: File) {
|
||||
if (file) {
|
||||
fileInput.value = file;
|
||||
}
|
||||
}
|
||||
|
||||
function readFileAsString(file: File) {
|
||||
return new Promise<string>((resolve, reject) => {
|
||||
const fr = new FileReader();
|
||||
fr.onload = () => {
|
||||
resolve(fr.result as string || '');
|
||||
};
|
||||
fr.onerror = reject;
|
||||
fr.readAsText(file);
|
||||
});
|
||||
}
|
||||
|
||||
async function convertFile() {
|
||||
let csvContentValue = csvContent.value;
|
||||
const file = fileInput.value;
|
||||
error.value = '';
|
||||
try {
|
||||
if (inputType.value === 'file' && file) {
|
||||
csvContentValue = await readFileAsString(file);
|
||||
}
|
||||
|
||||
const data = convertCsvToArray(csvContentValue, typedValues.value);
|
||||
convertedData.value = objectArrayToData(data, selectedFormat.value as ExportFormat, {
|
||||
tableName: tableName.value,
|
||||
nestify: nestify.value,
|
||||
});
|
||||
}
|
||||
catch (e: any) {
|
||||
error.value = e.toString();
|
||||
return null;
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<NCard title="CSV Converter">
|
||||
<c-card>
|
||||
<n-radio-group v-model:value="inputType" name="radiogroup" mb-2 flex justify-center>
|
||||
<n-space>
|
||||
<n-radio
|
||||
value="file"
|
||||
label="File"
|
||||
/>
|
||||
<n-radio
|
||||
value="content"
|
||||
label="Content"
|
||||
/>
|
||||
</n-space>
|
||||
</n-radio-group>
|
||||
|
||||
<c-file-upload
|
||||
v-if="inputType === 'file'"
|
||||
accept=".csv,.tsv"
|
||||
title="Drag and drop a CSV file here, or click to select a file"
|
||||
@file-upload="handleFileUpload"
|
||||
/>
|
||||
|
||||
<c-input-text
|
||||
v-if="inputType === 'content'"
|
||||
v-model:value="csvContent"
|
||||
label="Paste your CSV Content:"
|
||||
placeholder="Your CSV..."
|
||||
multiline
|
||||
rows="8"
|
||||
data-test-id="input"
|
||||
/>
|
||||
</c-card>
|
||||
|
||||
<n-space justify="center">
|
||||
<n-form-item label="Typed Values" label-placement="left">
|
||||
<n-checkbox v-model:checked="typedValues" />
|
||||
</n-form-item>
|
||||
<n-form-item label="Nestify ('a.b.c' to nested objects)" label-placement="left">
|
||||
<n-checkbox v-model:checked="nestify" />
|
||||
</n-form-item>
|
||||
</n-space>
|
||||
|
||||
<NFormItem label="Select output format:" label-placement="left">
|
||||
<NSelect v-model:value="selectedFormat" :options="formats" placeholder="Select format" />
|
||||
</NFormItem>
|
||||
|
||||
<c-input-text v-if="selectedFormat === 'sql'" v-model:value="tableName" label="Table Name:" label-placement="left" />
|
||||
|
||||
<div mt-3 flex justify-center>
|
||||
<NButton :disabled="!((inputType === 'file' && fileInput) || csvContent)" @click="convertFile">
|
||||
Convert
|
||||
</NButton>
|
||||
</div>
|
||||
|
||||
<c-alert v-if="error">
|
||||
{{ error }}
|
||||
</c-alert>
|
||||
|
||||
<c-card v-if="convertedData" title="Converted data">
|
||||
<textarea-copyable :value="convertedData" :language="selectedFormat" />
|
||||
</c-card>
|
||||
</NCard>
|
||||
</template>
|
||||
@@ -0,0 +1,14 @@
|
||||
import { TableExport } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Csv to Data',
|
||||
path: '/csv-to-data',
|
||||
description: 'Convert CSV file to JSON, YAML, CSV, SQL INSERT, XML or Markdown',
|
||||
keywords: ['excel', 'csv', 'xlsx', 'sql', 'json', 'yaml', 'insert', 'markdown', 'md', 'tsv', 'xml'],
|
||||
component: () => import('./csv-to-data.vue'),
|
||||
icon: TableExport,
|
||||
createdAt: new Date('2025-05-01'),
|
||||
redirectFrom: ['/csv-to-json'],
|
||||
category: 'Converters',
|
||||
});
|
||||
@@ -4,15 +4,27 @@ import { convertCsvToArray, getHeaders } from './csv-to-json.service';
|
||||
describe('csv-to-json service', () => {
|
||||
describe('getHeaders', () => {
|
||||
it('extracts all the keys from the first line of the CSV', () => {
|
||||
expect(getHeaders('a,b,c\n1,2,3\n4,5,6')).toEqual(['a', 'b', 'c']);
|
||||
expect(getHeaders('a,b,c\n1,2,3\n4,5,6', ',')).toEqual(['a', 'b', 'c']);
|
||||
});
|
||||
|
||||
it('returns an empty array if the CSV is empty', () => {
|
||||
expect(getHeaders('')).toEqual([]);
|
||||
expect(getHeaders('', ',')).toEqual([]);
|
||||
});
|
||||
});
|
||||
|
||||
describe('convertCsvToArray', () => {
|
||||
it('detects and converts with different separators', () => {
|
||||
const res = [
|
||||
{ a: '1', b: '2' },
|
||||
{ a: '3', b: '4' },
|
||||
];
|
||||
|
||||
expect(convertCsvToArray('a,b\n1,2\n3,4')).toEqual(res);
|
||||
expect(convertCsvToArray('a;b\n1;2\n3;4')).toEqual(res);
|
||||
expect(convertCsvToArray('a\tb\n1\t2\n3\t4')).toEqual(res);
|
||||
expect(convertCsvToArray('a|b\n1|2\n3|4')).toEqual(res);
|
||||
});
|
||||
|
||||
it('converts a CSV string to an array of objects', () => {
|
||||
const csv = 'a,b\n1,2\n3,4';
|
||||
|
||||
@@ -22,6 +34,16 @@ describe('csv-to-json service', () => {
|
||||
]);
|
||||
});
|
||||
|
||||
it('converts a CSV string to an array of typed objects', () => {
|
||||
const csv = 'a,b\n1,2\ntrue, false\ntruc, bidule';
|
||||
|
||||
expect(convertCsvToArray(csv, true)).toEqual([
|
||||
{ a: 1, b: 2 },
|
||||
{ a: true, b: false },
|
||||
{ a: 'truc', b: 'bidule' },
|
||||
]);
|
||||
});
|
||||
|
||||
it('converts a CSV string with different keys to an array of objects', () => {
|
||||
const csv = 'a,b,c\n1,2,\n3,,4';
|
||||
|
||||
|
||||
@@ -1,19 +1,21 @@
|
||||
import detectCSV from 'detect-csv';
|
||||
|
||||
export { getHeaders, convertCsvToArray };
|
||||
|
||||
function getHeaders(csv: string): string[] {
|
||||
function getHeaders(csv: string, delimiter: string): string[] {
|
||||
if (csv.trim() === '') {
|
||||
return [];
|
||||
}
|
||||
|
||||
const firstLine = csv.split('\n')[0];
|
||||
return firstLine.split(/[,;]/).map(header => header.trim());
|
||||
return firstLine.split(new RegExp(`[${delimiter}]`)).map(header => header.trim());
|
||||
}
|
||||
function deserializeValue(value: string): unknown {
|
||||
function deserializeValue(value: string, tryParseValues: boolean): unknown {
|
||||
if (value === 'null') {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (value === '') {
|
||||
if (value === '' || typeof value === 'undefined') {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
@@ -23,18 +25,26 @@ function deserializeValue(value: string): unknown {
|
||||
return valueAsString.slice(1, -1);
|
||||
}
|
||||
|
||||
return valueAsString;
|
||||
if (!tryParseValues) {
|
||||
return valueAsString;
|
||||
}
|
||||
try {
|
||||
return JSON.parse(valueAsString);
|
||||
}
|
||||
catch (_) {
|
||||
return valueAsString;
|
||||
}
|
||||
}
|
||||
|
||||
function convertCsvToArray(csv: string): Record<string, unknown>[] {
|
||||
const lines = csv.split('\n');
|
||||
const headers = getHeaders(csv);
|
||||
function convertCsvToArray(csv: string, tryParseValues: boolean = false): Record<string, unknown>[] {
|
||||
const delimiter = detectCSV(csv)?.delimiter || ',';
|
||||
const headers = getHeaders(csv, delimiter);
|
||||
|
||||
return lines.slice(1).map((line) => {
|
||||
return csv.split('\n').slice(1).map((line) => {
|
||||
// Split on comma or semicolon not within quotes
|
||||
const data = line.split(/[,;](?=(?:(?:[^"]*"){2})*[^"]*$)/).map(value => value.trim());
|
||||
const data = line.split(new RegExp(`[${delimiter}](?=(?:(?:[^"]*"){2})*[^"]*$)`)).map(value => value.trim());
|
||||
return headers.reduce((obj, header, index) => {
|
||||
obj[header] = deserializeValue(data[index]);
|
||||
obj[header] = deserializeValue(data[index], tryParseValues);
|
||||
return obj;
|
||||
}, {} as Record<string, unknown>);
|
||||
});
|
||||
|
||||
@@ -4,24 +4,29 @@ import FormatTransformer from '@/components/FormatTransformer.vue';
|
||||
import type { UseValidationRule } from '@/composable/validation';
|
||||
import { withDefaultOnError } from '@/utils/defaults';
|
||||
|
||||
const typedValues = ref(false);
|
||||
|
||||
function transformer(value: string) {
|
||||
return withDefaultOnError(() => {
|
||||
if (value === '') {
|
||||
return '';
|
||||
}
|
||||
return JSON.stringify(convertCsvToArray(value), null, 2);
|
||||
return JSON.stringify(convertCsvToArray(value, typedValues.value), null, 2);
|
||||
}, '');
|
||||
}
|
||||
|
||||
const rules: UseValidationRule<string>[] = [
|
||||
{
|
||||
validator: (v: string) => v === '' || ((v.includes(',') || v.includes(';')) && v.includes('\n')),
|
||||
validator: (v: string) => v === '' || ((v.includes(',') || v.includes(';') || v.includes('\t') || v.includes('|')) && v.includes('\n')),
|
||||
message: 'Provided CSV is not valid.',
|
||||
},
|
||||
];
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<n-form-item label="Typed Values" label-placement="left">
|
||||
<n-checkbox v-model:checked="typedValues" />
|
||||
</n-form-item>
|
||||
<FormatTransformer
|
||||
input-label="Your raw CSV"
|
||||
input-placeholder="Paste your raw CSV here..."
|
||||
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
declare module "detect-csv" {
|
||||
export default function DetectCSV(content: string): Nullable<{
|
||||
delimiter: string
|
||||
newline: string
|
||||
}>
|
||||
}
|
||||
@@ -0,0 +1,124 @@
|
||||
<script setup lang="ts">
|
||||
import JSON5 from 'json5';
|
||||
import { useValidation } from '@/composable/validation';
|
||||
|
||||
const url = ref('');
|
||||
const method = ref('POST'); // Default method set to POST for body support
|
||||
const bodyType = ref('json'); // Default body type
|
||||
const jsonData = ref('');
|
||||
|
||||
const headers = ref([{ key: '', value: '' }]);
|
||||
const formData = ref([{ key: '', value: '' }]);
|
||||
|
||||
const methods = ['GET', 'POST', 'PUT', 'DELETE', 'PATCH'];
|
||||
|
||||
const optionsList = [
|
||||
{ key: 'compressed', description: 'Request compressed response' },
|
||||
{ key: 'compressed-ssh', description: 'Enable SSH compression' },
|
||||
{ key: 'fail', description: 'Fail silently on HTTP errors' },
|
||||
{ key: 'fail-early', description: 'Fail on first transfer error, do not continue' },
|
||||
{ key: 'head', description: 'Show document info only' },
|
||||
{ key: 'include', description: 'Include protocol response headers in output' },
|
||||
{ key: 'insecure', description: 'Allow insecure server connections when using SSL' },
|
||||
{ key: 'ipv4', description: 'Resolve names to IPv4 addresses' },
|
||||
{ key: 'ipv6', description: 'Resolve names to IPv6 addresses' },
|
||||
{ key: 'list-only', description: 'List only mode' },
|
||||
{ key: 'location', description: 'Follow redirects' },
|
||||
{ key: 'location-trusted', description: 'Follow redirects and send auth to other hosts' },
|
||||
{ key: 'no-keepalive', description: 'Disable TCP keepalive on connection' },
|
||||
{ key: 'show-error', description: 'Show error even when silent mode is used' },
|
||||
{ key: 'silent', description: 'Suppress output' },
|
||||
{ key: 'ssl', description: 'Try SSL/TLS connection' },
|
||||
{ key: 'sslv2', description: 'Use SSLv2' },
|
||||
{ key: 'sslv3', description: 'Use SSLv3' },
|
||||
{ key: 'verbose', description: 'Increase output verbosity' },
|
||||
];
|
||||
|
||||
const selectedOptions = ref<Record<string, boolean>>({});
|
||||
|
||||
const curlCommand = computed(() => {
|
||||
let command = `curl -X ${method.value} "${url.value}"`;
|
||||
|
||||
headers.value.forEach(({ key, value }) => {
|
||||
if (key && value) {
|
||||
command += ` -H "${key}: ${value}"`;
|
||||
}
|
||||
});
|
||||
|
||||
if (bodyType.value === 'json' && jsonData.value) {
|
||||
command += ` -H "Content-Type: application/json" --data '${JSON.stringify(JSON5.parse(jsonData.value))}'`;
|
||||
}
|
||||
else if (bodyType.value === 'form-data') {
|
||||
formData.value.forEach(({ key, value }) => {
|
||||
if (key && value) {
|
||||
command += ` -F "${key}=${value}"`;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
optionsList.forEach(({ key }) => {
|
||||
if (selectedOptions.value[key]) {
|
||||
command += ` --${key}`;
|
||||
}
|
||||
});
|
||||
|
||||
return command;
|
||||
});
|
||||
|
||||
const jsonBodyValidation = useValidation({
|
||||
source: jsonData,
|
||||
rules: [
|
||||
{
|
||||
message: 'Invalid JSON string',
|
||||
validator: value => !value || JSON5.parse(value),
|
||||
},
|
||||
],
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<NFormItem label="Url:" label-placement="left">
|
||||
<NInput v-model:value="url" placeholder="Enter URL" />
|
||||
</NFormItem>
|
||||
<NFormItem label="Method:" label-placement="left">
|
||||
<NSelect v-model:value="method" :options="methods.map(m => ({ label: m, value: m }))" />
|
||||
</NFormItem>
|
||||
|
||||
<NRadioGroup v-model:value="bodyType" mb-2>
|
||||
<NRadio value="json">
|
||||
JSON Body
|
||||
</NRadio>
|
||||
<NRadio value="form-data">
|
||||
Multipart Form-Data
|
||||
</NRadio>
|
||||
</NRadioGroup>
|
||||
|
||||
<c-card v-if="bodyType === 'json'" title="JSON Body:" mb-2>
|
||||
<c-input-text
|
||||
v-model:value="jsonData" multiline rows="6"
|
||||
placeholder="Enter JSON body" :validation="jsonBodyValidation"
|
||||
/>
|
||||
</c-card>
|
||||
|
||||
<c-card v-else title="Form entries:" mb-2>
|
||||
<NDynamicInput v-model:value="formData" preset="pair" key-placeholder="Key" value-placeholder="Value" />
|
||||
</c-card>
|
||||
|
||||
<c-card title="HTTP Headers:" mb-2>
|
||||
<NDynamicInput v-model:value="headers" preset="pair" key-placeholder="Header" value-placeholder="Value" />
|
||||
</c-card>
|
||||
|
||||
<c-card title="Options:" mb-2>
|
||||
<template v-for="option in optionsList" :key="option.key">
|
||||
<NCheckbox v-model:checked="selectedOptions[option.key]">
|
||||
{{ `--${option.key}` }} <em>({{ option.description }})</em>
|
||||
</NCheckbox>
|
||||
</template>
|
||||
</c-card>
|
||||
|
||||
<c-card title="Generated curl command">
|
||||
<textarea-copyable :value="curlCommand" />
|
||||
</c-card>
|
||||
</div>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Download } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Curl Command Generator',
|
||||
path: '/curl-generator',
|
||||
description: 'Generate CURL command lines',
|
||||
keywords: ['curl'],
|
||||
component: () => import('./curl-generator.vue'),
|
||||
icon: Download,
|
||||
createdAt: new Date('2025-04-21'),
|
||||
category: 'Network',
|
||||
});
|
||||
@@ -0,0 +1,156 @@
|
||||
<script setup lang="ts">
|
||||
import { type Faker, allFakers } from '@faker-js/faker';
|
||||
import JSON5 from 'json5';
|
||||
import { objectArrayToData } from '@/utils/objectarray.export';
|
||||
import type { ExportFormat } from '@/utils/objectarray.export';
|
||||
import type { UseValidationRule } from '@/composable/validation';
|
||||
import { useQueryParamOrStorage } from '@/composable/queryParams';
|
||||
|
||||
const jsonInput = useQueryParamOrStorage({
|
||||
name: 'template',
|
||||
storageName: 'faker:tmpl',
|
||||
defaultValue: JSON.stringify({
|
||||
name: 'faker.person.fullName',
|
||||
email: 'faker.internet.email',
|
||||
address: {
|
||||
street: 'faker.location.streetAddress',
|
||||
city: 'faker.location.city',
|
||||
country: 'faker.location.country',
|
||||
},
|
||||
phone: 'faker.phone.number',
|
||||
}, null, 2),
|
||||
});
|
||||
|
||||
const generatedData = ref<string>('');
|
||||
const itemCount = useQueryParamOrStorage({ name: 'count', storageName: 'faker:c', defaultValue: 1 });
|
||||
const error = ref('');
|
||||
const selectedFormat = useQueryParamOrStorage({ name: 'fmt', storageName: 'faker:f', defaultValue: 'json' });
|
||||
const tableName = ref<string>('TableName');
|
||||
const nestify = ref(false);
|
||||
|
||||
const allLocales = Object.keys(allFakers);
|
||||
const selectedLocale = useQueryParamOrStorage({ name: 'locale', storageName: 'faker:l', defaultValue: 'en' });
|
||||
const faker = computed(() => (allFakers as Record<string, Faker>)[selectedLocale.value]);
|
||||
|
||||
const formats = [
|
||||
{ label: 'JSON', value: 'json' },
|
||||
{ label: 'YAML', value: 'yaml' },
|
||||
{ label: 'SQL INSERT', value: 'sql' },
|
||||
{ label: 'CSV (comma)', value: 'csv' },
|
||||
{ label: 'CSV (semicolon)', value: 'csv_semicolon' },
|
||||
{ label: 'CSV (tab)', value: 'tsv' },
|
||||
{ label: 'Markdown', value: 'markdown' },
|
||||
{ label: 'XML', value: 'xml' },
|
||||
];
|
||||
|
||||
// Extract all faker methods dynamically
|
||||
const fakerMethods = computed(() => {
|
||||
const methods: string[] = [];
|
||||
const fakerObj = (faker as Record<string, any>);
|
||||
Object.keys(fakerObj).forEach((category) => {
|
||||
if (typeof fakerObj[category] === 'object') {
|
||||
Object.keys(fakerObj[category]).forEach((method) => {
|
||||
methods.push(`faker.${category}.${method}`);
|
||||
});
|
||||
}
|
||||
});
|
||||
return methods.map(method => ({ label: method, value: method }));
|
||||
});
|
||||
|
||||
// Selected faker method for insertion
|
||||
const selectedMethod = ref<string>('');
|
||||
|
||||
function resolveFakerValue(value: string) {
|
||||
try {
|
||||
return value.startsWith('faker.')
|
||||
? value.split('.').slice(1).reduce((acc: any, prop: string) => acc[prop], faker.value)()
|
||||
: value;
|
||||
}
|
||||
catch {
|
||||
return value; // Fallback for invalid faker function names
|
||||
}
|
||||
}
|
||||
|
||||
function generateFakeData(template: Record<string, any>): Record<string, any> {
|
||||
return Object.entries(template).reduce((result, [key, value]) => {
|
||||
result[key] = typeof value === 'object' && value !== null
|
||||
? generateFakeData(value) // Recursive handling for nested objects
|
||||
: resolveFakerValue(value);
|
||||
return result;
|
||||
}, {} as Record<string, any>);
|
||||
}
|
||||
|
||||
function handleGenerate() {
|
||||
try {
|
||||
error.value = '';
|
||||
const parsedTemplate = JSON.parse(jsonInput.value);
|
||||
generatedData.value = objectArrayToData(
|
||||
Array.from({ length: itemCount.value },
|
||||
() => generateFakeData(parsedTemplate)),
|
||||
selectedFormat.value as ExportFormat, {
|
||||
tableName: tableName.value,
|
||||
nestify: nestify.value,
|
||||
});
|
||||
}
|
||||
catch (e: any) {
|
||||
error.value = e.toString();
|
||||
}
|
||||
}
|
||||
|
||||
function insertMethodIntoJson() {
|
||||
if (selectedMethod.value) {
|
||||
jsonInput.value = jsonInput.value.replace(/\n?\}$/, `,\n "newField": "${selectedMethod.value}"\n}`);
|
||||
}
|
||||
}
|
||||
|
||||
const rules: UseValidationRule<string>[] = [
|
||||
{
|
||||
validator: (v: string) => v === '' || JSON5.parse(v),
|
||||
message: 'Provided JSON is not valid.',
|
||||
},
|
||||
];
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<NCard title="Fake Data Generator">
|
||||
<c-input-text v-model:value="jsonInput" label="JSON Template:" multiline mb-1 rows="10" placeholder="Enter JSON template..." :validation-rules="rules" />
|
||||
|
||||
<c-card title="Faker Method insertion" mb-1>
|
||||
<n-space>
|
||||
<c-select v-model:value="selectedMethod" style="width: 200px" :options="fakerMethods" searchable placeholder="Search Faker Method" />
|
||||
<NButton @click="insertMethodIntoJson">
|
||||
Insert Selected Method
|
||||
</NButton>
|
||||
</n-space>
|
||||
</c-card>
|
||||
|
||||
<n-space mb-1>
|
||||
<NFormItem label="Number of objects to generate:" label-placement="left">
|
||||
<NInputNumber v-model:value="itemCount" :min="1" placeholder="Number of objects to generate" />
|
||||
</NFormItem>
|
||||
<n-form-item label="Nestify (handle nested objects)" label-placement="left">
|
||||
<n-checkbox v-model:checked="nestify" />
|
||||
</n-form-item>
|
||||
</n-space>
|
||||
|
||||
<c-select v-model:value="selectedLocale" label="Locale:" label-position="left" :options="allLocales" searchable mb-1 placeholder="Search locale version" />
|
||||
|
||||
<NFormItem label="Select output format:" label-placement="left" mb-1>
|
||||
<NSelect v-model:value="selectedFormat" :options="formats" placeholder="Select format" />
|
||||
</NFormItem>
|
||||
|
||||
<c-input-text v-if="selectedFormat === 'sql'" v-model:value="tableName" label="Table Name:" label-placement="left" mb-1 />
|
||||
|
||||
<NButton mb-2 mt-2 @click="handleGenerate">
|
||||
Generate Fake Data
|
||||
</NButton>
|
||||
|
||||
<c-alert v-if="error">
|
||||
{{ error }}
|
||||
</c-alert>
|
||||
|
||||
<c-card v-if="generatedData" title="Generated data">
|
||||
<textarea-copyable :value="generatedData" :language="selectedFormat" />
|
||||
</c-card>
|
||||
</NCard>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { ArrowsShuffle } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Data Faker',
|
||||
path: '/data-faker',
|
||||
description: 'Generate fake data using JSON template',
|
||||
keywords: ['data', 'json', 'sample', 'faker'],
|
||||
component: () => import('./data-faker.vue'),
|
||||
icon: ArrowsShuffle,
|
||||
createdAt: new Date('2025-05-01'),
|
||||
category: 'Development',
|
||||
});
|
||||
@@ -53,6 +53,13 @@ const convertedValue = computed(() => {
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<n-p text-center>
|
||||
1MiB = 1024KiB ; 1MB = 1000kB ; 1GiB = 1024MiB ; 1GB = 1000MB ;
|
||||
<n-a href="https://en.wikipedia.org/wiki/Byte" target="_blank" rel="noopener">
|
||||
see here for details
|
||||
</n-a>
|
||||
</n-p>
|
||||
|
||||
<c-card>
|
||||
<n-form-item label="Input Size:" label-placement="left" mb-1>
|
||||
<c-input-text
|
||||
|
||||
@@ -142,6 +142,13 @@ const amountTransferableOutput = computed(() => {
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<n-p text-center>
|
||||
1MiB = 1024KiB ; 1MB = 1000kB ; 1GiB = 1024MiB ; 1GB = 1000MB ;
|
||||
<n-a href="https://en.wikipedia.org/wiki/Byte" target="_blank" rel="noopener">
|
||||
see here for details
|
||||
</n-a>
|
||||
</n-p>
|
||||
|
||||
<c-card title="Transfer Time" mb-2>
|
||||
<n-form-item label="Data Size:" label-placement="left">
|
||||
<n-input v-model:value="transferTimeInput.dataSize" placeholder="Data Size..." :min="0" w-full />
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
<script lang="ts" setup>
|
||||
import { computed, ref } from 'vue';
|
||||
import { countBy, orderBy } from 'lodash';
|
||||
|
||||
const inputText = ref('');
|
||||
const sortedWordCounts = computed(() => {
|
||||
// Remove punctuation, extract words, count occurrences
|
||||
const cleanedText = inputText.value.replace(/\p{P}+\s|\s\p{P}+|\p{P}+$|^\p{P}+|\s+/gu, ' ').trim(); // Remove punctuation
|
||||
const wordCountObj = countBy(cleanedText.split(' ') || []);
|
||||
|
||||
// Convert to array and sort by count descending
|
||||
return orderBy(Object.entries(wordCountObj), ([, count]) => count, 'desc');
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<c-input-text v-model:value="inputText" multiline rows="10" label="Text:" placeholder="Enter text..." mb-1 />
|
||||
<c-card title="Distinct words">
|
||||
<n-table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Word</th>
|
||||
<th>Count</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="([word, count]) in sortedWordCounts" :key="word">
|
||||
<td>{{ word }}</td><td>{{ count }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</n-table>
|
||||
</c-card>
|
||||
</div>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { FileText } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Distinct Words',
|
||||
path: '/distinct-words',
|
||||
description: 'Extract and count occurences of each unique word in a text',
|
||||
keywords: ['distinct', 'words'],
|
||||
component: () => import('./distinct-words.vue'),
|
||||
icon: FileText,
|
||||
createdAt: new Date('2025-05-01'),
|
||||
category: 'Text',
|
||||
});
|
||||
@@ -0,0 +1,86 @@
|
||||
<script setup lang="ts">
|
||||
import { NForm, NFormItem, NInput, NSelect } from 'naive-ui';
|
||||
import { generateKeyPair } from '../rsa-key-pair-generator/rsa-key-pair-generator.service';
|
||||
import { withDefaultOnErrorAsync } from '@/utils/defaults';
|
||||
import { computedRefreshableAsync } from '@/composable/computedRefreshable';
|
||||
|
||||
const domain = ref('');
|
||||
const selector = ref('default');
|
||||
const keySize = ref('2048');
|
||||
const password = ref('');
|
||||
|
||||
const keySizes = [
|
||||
{ label: '1024-bit (Less secure, but faster)', value: '1024' },
|
||||
{ label: '2048-bit (Recommended for security)', value: '2048' },
|
||||
{ label: '4096-bit (Stronger security, but slower)', value: '4096' },
|
||||
];
|
||||
|
||||
const emptyCerts = { publicKey: '', privateKey: '' };
|
||||
const [certs, refreshCerts] = computedRefreshableAsync(
|
||||
() => withDefaultOnErrorAsync(() => generateKeyPair({
|
||||
bits: Number(keySize.value),
|
||||
password: password.value,
|
||||
format: 'pem',
|
||||
}), emptyCerts),
|
||||
emptyCerts,
|
||||
);
|
||||
|
||||
const dKIMRecord = computed(() => {
|
||||
if (!domain.value || !selector.value) {
|
||||
return '';
|
||||
}
|
||||
|
||||
const pubKey = certs.value.publicKey.replace(/-----(BEGIN|END) PUBLIC KEY-----|\s/g, '');
|
||||
const parts = [
|
||||
'v=DKIM1',
|
||||
'k=rsa',
|
||||
`p=${pubKey}`,
|
||||
];
|
||||
|
||||
const record = parts.join('; ');
|
||||
return `${selector.value}._domainkey.${domain.value} IN TXT "${record}"`;
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<NForm label-placement="top">
|
||||
<NFormItem label="Domain Name:">
|
||||
<NInput v-model:value="domain" placeholder="Enter domain (e.g., example.com)" />
|
||||
</NFormItem>
|
||||
|
||||
<NFormItem label="Selector (Unique name used to distinguish DKIM records for the same domain):">
|
||||
<NInput v-model:value="selector" placeholder="Enter selector (e.g., default)" />
|
||||
</NFormItem>
|
||||
|
||||
<NFormItem label="Key Size (of the RSA key used for signing emails):">
|
||||
<NSelect v-model:value="keySize" :options="keySizes" placeholder="Select key size" />
|
||||
</NFormItem>
|
||||
|
||||
<NFormItem label="Passphrase (of private key):">
|
||||
<NInput
|
||||
v-model:value="password"
|
||||
type="password"
|
||||
show-password-on="mousedown"
|
||||
placeholder="Passphrase"
|
||||
/>
|
||||
</NFormItem>
|
||||
|
||||
<div mb-2 flex justify-center>
|
||||
<n-button @click="refreshCerts()">
|
||||
Refresh Certificate
|
||||
</n-button>
|
||||
</div>
|
||||
|
||||
<c-card title="Generate DKIM Record" mb-1>
|
||||
<textarea-copyable :value="dKIMRecord" />
|
||||
</c-card>
|
||||
|
||||
<c-card v-if="dKIMRecord" title="RSA Public Key" mb-1>
|
||||
<textarea-copyable :value="certs.publicKey" />
|
||||
</c-card>
|
||||
|
||||
<c-card v-if="dKIMRecord" title="PEM RSA Private key">
|
||||
<textarea-copyable :value="certs.privateKey" />
|
||||
</c-card>
|
||||
</NForm>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { World } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'DKIM DNS Generator',
|
||||
path: '/dkim-dns-generator',
|
||||
description: 'Generate DKIM DNS TXT record',
|
||||
keywords: ['dkim', 'dns'],
|
||||
component: () => import('./dkim-dns-generator.vue'),
|
||||
icon: World,
|
||||
createdAt: new Date('2025-04-21'),
|
||||
category: 'Network',
|
||||
});
|
||||
@@ -0,0 +1,96 @@
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
|
||||
const domain = ref('');
|
||||
const policy = ref('none');
|
||||
const subPolicy = ref('none');
|
||||
const percentage = ref(100);
|
||||
const rua = ref('');
|
||||
const ruf = ref('');
|
||||
const aspf = ref('r');
|
||||
const adkim = ref('r');
|
||||
const ri = ref(86400);
|
||||
const dmarcRecord = computed(() => {
|
||||
const recordParts = ['v=DMARC1', `p=${policy.value}`, `sp=${subPolicy.value}`];
|
||||
|
||||
if (percentage.value !== 100) {
|
||||
recordParts.push(`pct=${percentage.value}`);
|
||||
}
|
||||
if (rua.value) {
|
||||
recordParts.push(`rua=mailto:${rua.value}`);
|
||||
}
|
||||
if (ruf.value) {
|
||||
recordParts.push(`ruf=mailto:${ruf.value}`);
|
||||
}
|
||||
if (aspf.value) {
|
||||
recordParts.push(`aspf=${aspf.value}`);
|
||||
}
|
||||
if (adkim.value) {
|
||||
recordParts.push(`adkim=${adkim.value}`);
|
||||
}
|
||||
if (ri.value) {
|
||||
recordParts.push(`ri=${ri.value}`);
|
||||
}
|
||||
|
||||
return recordParts.join('; ');
|
||||
});
|
||||
|
||||
const policies = [
|
||||
{ label: 'None', value: 'none' },
|
||||
{ label: 'Quarantine', value: 'quarantine' },
|
||||
{ label: 'Reject', value: 'reject' },
|
||||
];
|
||||
|
||||
const alignments = [
|
||||
{ label: 'Relaxed (r)', value: 'r' },
|
||||
{ label: 'Strict (s)', value: 's' },
|
||||
];
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<n-card title="DMARC Record Generator" max-w-600px>
|
||||
<n-form-item label="Domain:" label-placement="left">
|
||||
<n-input v-model:value="domain" placeholder="example.com" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Policy:" label-placement="left">
|
||||
<n-select v-model:value="policy" :options="policies" placeholder="Select policy" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Subdomain Policy:" label-placement="left">
|
||||
<n-select v-model:value="subPolicy" :options="policies" placeholder="Select policy" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Percentage (of emails subject to DMARC policy enforcement (0-100%)):" label-placement="top">
|
||||
<n-input-number v-model:value="percentage" :min="0" :max="100" placeholder="Enter percentage" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Aggregate Email (where aggregate DMARC reports should be sent):" label-placement="top">
|
||||
<n-input v-model:value="rua" placeholder="admin@example.com" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Forensic Email (where forensic DMARC failure reports should be sent):" label-placement="top">
|
||||
<n-input v-model:value="ruf" placeholder="admin@example.com" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Alignment (SPF):" label-placement="left">
|
||||
<n-select v-model:value="aspf" :options="alignments" placeholder="Select alignment" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Alignment (DKIM):" label-placement="left">
|
||||
<n-select v-model:value="adkim" :options="alignments" placeholder="Select alignment" />
|
||||
</n-form-item>
|
||||
|
||||
<n-form-item label="Reporting Interval (for sending DMARC aggregate reports):" label-placement="top">
|
||||
<n-input-number v-model:value="ri" :min="3600" placeholder="Enter interval">
|
||||
<template #suffix>
|
||||
seconds
|
||||
</template>
|
||||
</n-input-number>
|
||||
</n-form-item>
|
||||
|
||||
<n-card v-if="dmarcRecord" title="Generated DMARC Record">
|
||||
<textarea-copyable :value="dmarcRecord" />
|
||||
</n-card>
|
||||
</n-card>
|
||||
</template>
|
||||
@@ -0,0 +1,13 @@
|
||||
import { World } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'DMARC DNS Generator',
|
||||
path: '/dmarc-dns-generator',
|
||||
description: 'Generate DMARC DNS TXT record',
|
||||
keywords: ['dmarc', 'dns'],
|
||||
component: () => import('./dmarc-dns-generator.vue'),
|
||||
icon: World,
|
||||
createdAt: new Date('2025-04-21'),
|
||||
category: 'Network',
|
||||
});
|
||||
@@ -0,0 +1,32 @@
|
||||
<script setup lang="ts">
|
||||
import { useThemeVars } from 'naive-ui';
|
||||
import Memo from './docker.md';
|
||||
|
||||
const themeVars = useThemeVars();
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<Memo style="overflow-x: auto;" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style lang="less" scoped>
|
||||
::v-deep(pre) {
|
||||
margin: 0;
|
||||
padding: 15px 22px;
|
||||
background-color: v-bind('themeVars.cardColor');
|
||||
border-radius: 4px;
|
||||
overflow: auto;
|
||||
}
|
||||
::v-deep(table) {
|
||||
border-collapse: collapse;
|
||||
}
|
||||
::v-deep(table), ::v-deep(td), ::v-deep(th) {
|
||||
border: 1px solid v-bind('themeVars.textColor1');
|
||||
padding: 5px;
|
||||
}
|
||||
::v-deep(a) {
|
||||
color: v-bind('themeVars.textColor1');
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,163 @@
|
||||
Docker provides the ability to package and run an application in a loosely isolated environment called a container. The isolation and security allows you to run many containers simultaneously on a given host. Containers are lightweight and contain everything needed to run the application, so you do not need to rely on what is currently installed on the host. You can easily share containers while you work, and be sure that everyone you share with gets the same container that works in the same way.
|
||||
|
||||
## INSTALLATION
|
||||
|
||||
## GENERAL COMMANDS
|
||||
|
||||
Docker Desktop is available for Mac, Linux and Windows https://docs.docker.com/desktop
|
||||
|
||||
View example projects that use Docker
|
||||
|
||||
https://github.com/docker/awesome-compose
|
||||
|
||||
Check out our docs for information on using Docker https://docs.docker.com
|
||||
|
||||
## IMAGES
|
||||
|
||||
Docker images are a lightweight, standalone, executable package of software that includes everything needed to run an application: code, runtime, system tools, system libraries and settings.
|
||||
|
||||
Build an Image from a Dockerfile
|
||||
|
||||
```bash
|
||||
docker build -t <image_name> .
|
||||
```
|
||||
|
||||
Build an Image from a Dockerfile without the cache
|
||||
|
||||
```bash
|
||||
docker build -t <image\_name> . -no-cache
|
||||
```
|
||||
|
||||
List local images
|
||||
|
||||
```bash
|
||||
docker images
|
||||
```
|
||||
|
||||
Delete an Image
|
||||
|
||||
```bash
|
||||
docker rmi <image\_name>
|
||||
```
|
||||
|
||||
Remove all unused images
|
||||
|
||||
```bash
|
||||
docker image prune
|
||||
```
|
||||
|
||||
## DOCKER HUB
|
||||
|
||||
Docker Hub is a service provided by Docker for finding and sharing container images with your team. Learn more and find images at https://hub.docker.com
|
||||
|
||||
Login into Docker
|
||||
|
||||
```bash
|
||||
docker login -u <username>
|
||||
```
|
||||
|
||||
Publish an image to Docker Hub
|
||||
|
||||
```bash
|
||||
docker push <username>/<image\_name>
|
||||
```
|
||||
|
||||
Search Hub for an image
|
||||
|
||||
```bash
|
||||
docker search <image\_name>
|
||||
```
|
||||
|
||||
Pull an image from a Docker Hub
|
||||
|
||||
```bash
|
||||
docker pull <image\_name>
|
||||
```
|
||||
|
||||
Start the docker daemon
|
||||
|
||||
```bash
|
||||
docker -d
|
||||
```
|
||||
|
||||
Get help with Docker. Can also use -help on all subcommands
|
||||
|
||||
```bash
|
||||
docker --help
|
||||
```
|
||||
|
||||
Display system-wide information
|
||||
|
||||
```bash
|
||||
docker info
|
||||
```
|
||||
|
||||
## CONTAINERS
|
||||
|
||||
A container is a runtime instance of a docker image. A container will always run the same, regardless of the infrastructure. Containers isolate software from its environment and ensure that it works uniformly despite differences for instance between development and staging.
|
||||
|
||||
Create and run a container from an image, with a custom name:
|
||||
|
||||
```bash
|
||||
docker run --name <container\_name> <image\_name>
|
||||
```
|
||||
|
||||
Run a container with and publish a container's port(s) to the host.
|
||||
|
||||
```bash
|
||||
docker run -p <host\_port>:<container\_port> <image\_name>
|
||||
```
|
||||
|
||||
Run a container in the background
|
||||
|
||||
```bash
|
||||
docker run -d <image\_name>
|
||||
```
|
||||
|
||||
Start or stop an existing container:
|
||||
|
||||
```bash
|
||||
docker start|stop <container\_name> (or <container-id>)
|
||||
```
|
||||
|
||||
Remove a stopped container:
|
||||
|
||||
```bash
|
||||
docker rm <container\_name>
|
||||
```
|
||||
|
||||
Open a shell inside a running container:
|
||||
|
||||
```bash
|
||||
docker exec -it <container\_name> sh
|
||||
```
|
||||
|
||||
Fetch and follow the logs of a container:
|
||||
|
||||
```bash
|
||||
docker logs -f <container\_name>
|
||||
```
|
||||
|
||||
To inspect a running container:
|
||||
|
||||
```bash
|
||||
docker inspect <container\_name> (or <container\_id>)
|
||||
```
|
||||
|
||||
To list currently running containers:
|
||||
|
||||
```bash
|
||||
docker ps
|
||||
```
|
||||
|
||||
List all docker containers (running and stopped):
|
||||
|
||||
```bash
|
||||
docker ps --all
|
||||
```
|
||||
|
||||
View resource usage stats
|
||||
|
||||
```bash
|
||||
docker container stats
|
||||
```
|
||||
@@ -0,0 +1,13 @@
|
||||
import { BrandDocker } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Docker Cheatsheet',
|
||||
path: '/docker-memo',
|
||||
description: 'Docker command memo',
|
||||
keywords: ['docker', 'memo'],
|
||||
component: () => import('./docker-memo.vue'),
|
||||
icon: BrandDocker,
|
||||
createdAt: new Date('2025-03-09'),
|
||||
category: 'Cheatsheets',
|
||||
});
|
||||
@@ -0,0 +1,56 @@
|
||||
<script setup lang="ts">
|
||||
import _ from 'lodash';
|
||||
import { useQueryParamOrStorage } from '@/composable/queryParams';
|
||||
import { useValidation } from '@/composable/validation';
|
||||
|
||||
const input = ref('');
|
||||
const cleaningRegex = useQueryParamOrStorage({ name: 'clean', storageName: 'dedup:clean', defaultValue: '' });
|
||||
const regexValidation = useValidation({
|
||||
source: cleaningRegex,
|
||||
rules: [
|
||||
{
|
||||
message: 'Invalid regex: {0}',
|
||||
validator: value => new RegExp(value),
|
||||
getErrorMessage: (value) => {
|
||||
const _ = new RegExp(value);
|
||||
return '';
|
||||
},
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
const duplicatedLines = computed(() => {
|
||||
const clean = new RegExp(cleaningRegex.value, 'g');
|
||||
const lines = input.value.split('\n');
|
||||
return _.uniq(_.filter(lines.map(val => val.replace(clean, '')), (val, i, iteratee) => val && _.includes(iteratee, val, i + 1))).join('\n');
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<c-input-text
|
||||
v-model:value="input"
|
||||
placeholder="Your string to list duplicated lines..."
|
||||
raw-text
|
||||
multiline
|
||||
rows="10"
|
||||
label="Your text: "
|
||||
mb-2
|
||||
/>
|
||||
<c-input-text
|
||||
v-model:value="cleaningRegex"
|
||||
placeholder="Your cleaning regex..."
|
||||
raw-text
|
||||
label="Cleaning regex: "
|
||||
label-position="left"
|
||||
label-align="right"
|
||||
label-width="120px"
|
||||
:validation="regexValidation"
|
||||
mb-2
|
||||
/>
|
||||
|
||||
<n-form-item label="Duplicated lines:">
|
||||
<textarea-copyable :value="duplicatedLines" />
|
||||
</n-form-item>
|
||||
</div>
|
||||
</template>
|
||||
Loaded 100 of 243 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user