mirror of
https://github.com/sharevb/it-tools.git
synced 2026-11-24 06:40:20 +03:00
Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ecf0eacc32 | ||
|
|
ffc635ef26 | ||
|
|
3ad648d569 |
No files matched your search
@@ -15,7 +15,7 @@ jobs:
|
||||
- run: corepack enable
|
||||
- uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 20
|
||||
node-version: 16
|
||||
cache: 'pnpm'
|
||||
|
||||
- name: Install dependencies
|
||||
|
||||
@@ -18,7 +18,7 @@ jobs:
|
||||
|
||||
- uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 20
|
||||
node-version: 16
|
||||
cache: 'pnpm'
|
||||
|
||||
- name: Get Playwright version
|
||||
|
||||
Vendored
+1
-7
@@ -81,6 +81,7 @@ declare module '@vue/runtime-core' {
|
||||
FormatTransformer: typeof import('./src/components/FormatTransformer.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']
|
||||
GzipConverter: typeof import('./src/tools/gzip-converter/gzip-converter.vue')['default']
|
||||
HashText: typeof import('./src/tools/hash-text/hash-text.vue')['default']
|
||||
HmacGenerator: typeof import('./src/tools/hmac-generator/hmac-generator.vue')['default']
|
||||
'Home.page': typeof import('./src/pages/Home.page.vue')['default']
|
||||
@@ -130,21 +131,14 @@ declare module '@vue/runtime-core' {
|
||||
NCode: typeof import('naive-ui')['NCode']
|
||||
NCollapseTransition: typeof import('naive-ui')['NCollapseTransition']
|
||||
NConfigProvider: typeof import('naive-ui')['NConfigProvider']
|
||||
NDivider: typeof import('naive-ui')['NDivider']
|
||||
NEllipsis: typeof import('naive-ui')['NEllipsis']
|
||||
NFormItem: typeof import('naive-ui')['NFormItem']
|
||||
NGi: typeof import('naive-ui')['NGi']
|
||||
NGrid: typeof import('naive-ui')['NGrid']
|
||||
NH1: typeof import('naive-ui')['NH1']
|
||||
NH3: typeof import('naive-ui')['NH3']
|
||||
NIcon: typeof import('naive-ui')['NIcon']
|
||||
NInputNumber: typeof import('naive-ui')['NInputNumber']
|
||||
NLabel: typeof import('naive-ui')['NLabel']
|
||||
NLayout: typeof import('naive-ui')['NLayout']
|
||||
NLayoutSider: typeof import('naive-ui')['NLayoutSider']
|
||||
NMenu: typeof import('naive-ui')['NMenu']
|
||||
NScrollbar: typeof import('naive-ui')['NScrollbar']
|
||||
NSpin: typeof import('naive-ui')['NSpin']
|
||||
NumeronymGenerator: typeof import('./src/tools/numeronym-generator/numeronym-generator.vue')['default']
|
||||
OtpCodeGeneratorAndValidator: typeof import('./src/tools/otp-code-generator-and-validator/otp-code-generator-and-validator.vue')['default']
|
||||
PasswordStrengthAnalyser: typeof import('./src/tools/password-strength-analyser/password-strength-analyser.vue')['default']
|
||||
|
||||
+2
-1
@@ -58,12 +58,14 @@
|
||||
"date-fns": "^2.29.3",
|
||||
"dompurify": "^3.0.6",
|
||||
"emojilib": "^3.0.10",
|
||||
"fflate": "^0.8.2",
|
||||
"figlet": "^1.7.0",
|
||||
"figue": "^1.2.0",
|
||||
"fuse.js": "^6.6.2",
|
||||
"highlight.js": "^11.7.0",
|
||||
"iarna-toml-esm": "^3.0.5",
|
||||
"ibantools": "^4.3.3",
|
||||
"js-base64": "^3.7.7",
|
||||
"json5": "^2.2.3",
|
||||
"jwt-decode": "^3.1.2",
|
||||
"libphonenumber-js": "^1.10.28",
|
||||
@@ -80,7 +82,6 @@
|
||||
"pinia": "^2.0.34",
|
||||
"plausible-tracker": "^0.3.8",
|
||||
"qrcode": "^1.5.1",
|
||||
"slashes": "^3.0.12",
|
||||
"sql-formatter": "^13.0.0",
|
||||
"ua-parser-js": "^1.0.35",
|
||||
"ulid": "^2.3.0",
|
||||
|
||||
@@ -9,7 +9,7 @@ const useWebServer = process.env.NO_WEB_SERVER !== 'true';
|
||||
*/
|
||||
export default defineConfig({
|
||||
testDir: './src',
|
||||
testMatch: /\.e2e\.(spec\.)?ts$/,
|
||||
testMatch: /.*\.e2e\.(spec\.)?ts/,
|
||||
/* Run tests in files in parallel */
|
||||
fullyParallel: true,
|
||||
/* Fail the build on CI if you accidentally left test.only in the source code. */
|
||||
@@ -57,7 +57,7 @@ export default defineConfig({
|
||||
&& {
|
||||
webServer: {
|
||||
command: 'npm run preview',
|
||||
url: 'http://localhost:5050',
|
||||
url: 'http://127.0.0.1:5050',
|
||||
reuseExistingServer: !isCI,
|
||||
},
|
||||
}
|
||||
|
||||
Generated
+14
-7
@@ -74,6 +74,9 @@ dependencies:
|
||||
emojilib:
|
||||
specifier: ^3.0.10
|
||||
version: 3.0.10
|
||||
fflate:
|
||||
specifier: ^0.8.2
|
||||
version: 0.8.2
|
||||
figlet:
|
||||
specifier: ^1.7.0
|
||||
version: 1.7.0
|
||||
@@ -92,6 +95,9 @@ dependencies:
|
||||
ibantools:
|
||||
specifier: ^4.3.3
|
||||
version: 4.3.3
|
||||
js-base64:
|
||||
specifier: ^3.7.7
|
||||
version: 3.7.7
|
||||
json5:
|
||||
specifier: ^2.2.3
|
||||
version: 2.2.3
|
||||
@@ -140,9 +146,6 @@ dependencies:
|
||||
qrcode:
|
||||
specifier: ^1.5.1
|
||||
version: 1.5.1
|
||||
slashes:
|
||||
specifier: ^3.0.12
|
||||
version: 3.0.12
|
||||
sql-formatter:
|
||||
specifier: ^13.0.0
|
||||
version: 13.0.0
|
||||
@@ -5598,6 +5601,10 @@ packages:
|
||||
web-streams-polyfill: 3.2.1
|
||||
dev: true
|
||||
|
||||
/fflate@0.8.2:
|
||||
resolution: {integrity: sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==}
|
||||
dev: false
|
||||
|
||||
/figlet@1.7.0:
|
||||
resolution: {integrity: sha512-gO8l3wvqo0V7wEFLXPbkX83b7MVjRrk1oRLfYlZXol8nEpb/ON9pcKLI4qpBv5YtOTfrINtqb7b40iYY2FTWFg==}
|
||||
engines: {node: '>= 0.4.0'}
|
||||
@@ -6475,6 +6482,10 @@ packages:
|
||||
hasBin: true
|
||||
dev: true
|
||||
|
||||
/js-base64@3.7.7:
|
||||
resolution: {integrity: sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw==}
|
||||
dev: false
|
||||
|
||||
/js-beautify@1.14.6:
|
||||
resolution: {integrity: sha512-GfofQY5zDp+cuHc+gsEXKPpNw2KbPddreEo35O6jT6i0RVK6LhsoYBhq5TvK4/n74wnA0QbK8gGd+jUZwTMKJw==}
|
||||
engines: {node: '>=10'}
|
||||
@@ -8111,10 +8122,6 @@ packages:
|
||||
engines: {node: '>=12'}
|
||||
dev: true
|
||||
|
||||
/slashes@3.0.12:
|
||||
resolution: {integrity: sha512-Q9VME8WyGkc7pJf6QEkj3wE+2CnvZMI+XJhwdTPR8Z/kWQRXi7boAWLDibRPyHRTUTPx5FaU7MsyrjI3yLB4HA==}
|
||||
dev: false
|
||||
|
||||
/snake-case@2.1.0:
|
||||
resolution: {integrity: sha512-FMR5YoPFwOLuh4rRz92dywJjyKYZNLpMn1R5ujVpIYkbA9p01fq8RMg0FkO4M+Yobt4MjHeLTJVm5xFFBHSV2Q==}
|
||||
dependencies:
|
||||
|
||||
@@ -16,6 +16,7 @@ const props = withDefaults(
|
||||
language?: string
|
||||
copyPlacement?: 'top-right' | 'bottom-right' | 'outside' | 'none'
|
||||
copyMessage?: string
|
||||
wordWrap?: boolean
|
||||
}>(),
|
||||
{
|
||||
followHeightOf: null,
|
||||
@@ -47,7 +48,7 @@ const tooltipText = computed(() => isJustCopied.value ? 'Copied!' : copyMessage.
|
||||
:style="height ? `min-height: ${height - 40 /* card padding */ + 10 /* negative margin compensation */}px` : ''"
|
||||
>
|
||||
<n-config-provider :hljs="hljs">
|
||||
<n-code :code="value" :language="language" :trim="false" data-test-id="area-content" />
|
||||
<n-code :code="value" :language="language" :word-wrap="wordWrap" :trim="false" data-test-id="area-content" />
|
||||
</n-config-provider>
|
||||
</n-scrollbar>
|
||||
<div absolute right-10px top-10px>
|
||||
|
||||
@@ -0,0 +1,88 @@
|
||||
<script setup lang="ts">
|
||||
import * as fflate from 'fflate';
|
||||
import { Base64 } from 'js-base64';
|
||||
import TextareaCopyable from '@/components/TextareaCopyable.vue';
|
||||
import { withDefaultOnError } from '@/utils/defaults';
|
||||
|
||||
const compressedInput = ref('');
|
||||
const decompressedOutput = computed(() => withDefaultOnError(() => {
|
||||
const compressedBuf = Base64.toUint8Array(compressedInput.value);
|
||||
return fflate.strFromU8(fflate.decompressSync(compressedBuf));
|
||||
}, '# invalid compressed base64 string'));
|
||||
|
||||
const rawInput = ref('');
|
||||
const compressedGzipOutput = computed(() => withDefaultOnError(() => Base64.fromUint8Array(fflate.gzipSync(fflate.strToU8(rawInput.value))), ''));
|
||||
const compressedDeflateOutput = computed(() => withDefaultOnError(() => Base64.fromUint8Array(fflate.deflateSync(fflate.strToU8(rawInput.value))), ''));
|
||||
const compressedZlibOutput = computed(() => withDefaultOnError(() => Base64.fromUint8Array(fflate.zlibSync(fflate.strToU8(rawInput.value))), ''));
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div style="max-width: 600px;">
|
||||
<c-card title="Compress string" mb-5>
|
||||
<c-input-text
|
||||
v-model:value="rawInput"
|
||||
multiline
|
||||
placeholder="Put your string here..."
|
||||
rows="5"
|
||||
label="String to compress"
|
||||
raw-text
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<div>
|
||||
<h3>GZIP compressed string</h3>
|
||||
<TextareaCopyable
|
||||
:value="compressedGzipOutput"
|
||||
:word-wrap="true"
|
||||
multiline
|
||||
placeholder="The GZip compressed version of your string will be here"
|
||||
mb-5
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h3>Zlib compressed string</h3>
|
||||
<TextareaCopyable
|
||||
:value="compressedZlibOutput"
|
||||
:word-wrap="true"
|
||||
multiline
|
||||
placeholder="The Zlib compressed version of your string will be here"
|
||||
mb-5
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h3>Deflate compressed string</h3>
|
||||
<TextareaCopyable
|
||||
:value="compressedDeflateOutput"
|
||||
:word-wrap="true"
|
||||
multiline
|
||||
placeholder="The Deflate compressed version of your string will be here"
|
||||
mb-5
|
||||
/>
|
||||
</div>
|
||||
</c-card>
|
||||
|
||||
<c-card title="Decompress string">
|
||||
<c-input-text
|
||||
v-model:value="compressedInput"
|
||||
multiline
|
||||
placeholder="Your compressed string..."
|
||||
rows="5"
|
||||
label="Compressed string to decompress"
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<div>
|
||||
<h3>Decompressed string</h3>
|
||||
<TextareaCopyable
|
||||
v-model:value="decompressedOutput"
|
||||
:word-wrap="true"
|
||||
multiline
|
||||
placeholder="The decompressed string will be here"
|
||||
mb-5
|
||||
/>
|
||||
</div>
|
||||
</c-card>
|
||||
</div>
|
||||
</template>
|
||||
@@ -0,0 +1,12 @@
|
||||
import { FileZip } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'GZip/Deflate converter',
|
||||
path: '/gzip-converter',
|
||||
description: 'Convert text from/to gzip/deflate',
|
||||
keywords: ['gzip', 'deflate', 'converter'],
|
||||
component: () => import('./gzip-converter.vue'),
|
||||
icon: FileZip,
|
||||
createdAt: new Date('2024-03-09'),
|
||||
});
|
||||
+2
-2
@@ -5,8 +5,8 @@ import { tool as basicAuthGenerator } from './basic-auth-generator';
|
||||
import { tool as asciiTextDrawer } from './ascii-text-drawer';
|
||||
|
||||
import { tool as textToUnicode } from './text-to-unicode';
|
||||
import { tool as gzipConverter } from './gzip-converter';
|
||||
import { tool as safelinkDecoder } from './safelink-decoder';
|
||||
import { tool as jsonEscaper } from './json-escaper';
|
||||
import { tool as pdfSignatureChecker } from './pdf-signature-checker';
|
||||
import { tool as numeronymGenerator } from './numeronym-generator';
|
||||
import { tool as macAddressGenerator } from './mac-address-generator';
|
||||
@@ -108,6 +108,7 @@ export const toolsByCategory: ToolCategory[] = [
|
||||
listConverter,
|
||||
tomlToJson,
|
||||
tomlToYaml,
|
||||
gzipConverter,
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -129,7 +130,6 @@ export const toolsByCategory: ToolCategory[] = [
|
||||
httpStatusCodes,
|
||||
jsonDiff,
|
||||
safelinkDecoder,
|
||||
jsonEscaper,
|
||||
],
|
||||
},
|
||||
{
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
import { Braces } from '@vicons/tabler';
|
||||
import { defineTool } from '../tool';
|
||||
|
||||
export const tool = defineTool({
|
||||
name: 'Json Escaper/Unescaper',
|
||||
path: '/json-escaper',
|
||||
description: 'Escape and unescape JSON string',
|
||||
keywords: ['json', 'string', 'escape', 'unescape'],
|
||||
component: () => import('./json-escaper.vue'),
|
||||
icon: Braces,
|
||||
createdAt: new Date('2024-03-09'),
|
||||
});
|
||||
@@ -1,78 +0,0 @@
|
||||
<script setup lang="ts">
|
||||
import { addSlashes, removeSlashes } from 'slashes';
|
||||
import TextareaCopyable from '@/components/TextareaCopyable.vue';
|
||||
|
||||
const unescapedInput = ref('');
|
||||
const escapedOutput = computed(
|
||||
() => {
|
||||
try {
|
||||
return addSlashes(unescapedInput.value);
|
||||
}
|
||||
catch (e: any) {
|
||||
return e.toString();
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
const escapedInput = ref('');
|
||||
const unescapedOutput = computed(
|
||||
() => {
|
||||
try {
|
||||
return removeSlashes(escapedInput.value);
|
||||
}
|
||||
catch (e: any) {
|
||||
return e.toString();
|
||||
}
|
||||
},
|
||||
);
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div max-w-600>
|
||||
<c-card title="Escape JSON string">
|
||||
<c-input-text
|
||||
v-model:value="unescapedInput"
|
||||
placeholder="Put your string to escape..."
|
||||
label="String to escape"
|
||||
raw-text
|
||||
multiline
|
||||
rows="5"
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<n-divider />
|
||||
|
||||
<TextareaCopyable
|
||||
label="Escaped string"
|
||||
:value="escapedOutput"
|
||||
multiline
|
||||
readonly
|
||||
rows="5"
|
||||
mb-5
|
||||
/>
|
||||
</c-card>
|
||||
|
||||
<c-card title="Unescape JSON string" mt-5>
|
||||
<c-input-text
|
||||
v-model:value="escapedInput"
|
||||
placeholder="Put your string to unescape..."
|
||||
label="String to unescape"
|
||||
raw-text
|
||||
multiline
|
||||
rows="5"
|
||||
mb-5
|
||||
/>
|
||||
|
||||
<n-divider />
|
||||
|
||||
<TextareaCopyable
|
||||
label="Unescaped string"
|
||||
:value="unescapedOutput"
|
||||
multiline
|
||||
readonly
|
||||
rows="5"
|
||||
mb-5
|
||||
/>
|
||||
</c-card>
|
||||
</div>
|
||||
</template>
|
||||
Reference in new issue
Block a user