diff --git a/package.json b/package.json
index 71cbd44f..6333cdb3 100644
--- a/package.json
+++ b/package.json
@@ -106,6 +106,7 @@
"countries-db": "^1.2.0",
"composerize": "^1.6.12",
"countries-and-timezones": "^3.7.2",
+ "countries-and-timezones": "^3.6.0",
"country-code-lookup": "^0.1.0",
"crc": "^4.3.2",
"cron-validator": "^1.3.1",
@@ -135,6 +136,7 @@
"fuse.js": "^6.6.2",
"hash-wasm": "^4.11.0",
"generate-schema": "^2.6.0",
+ "get-timezone-offset": "^1.0.5",
"highlight.js": "^11.7.0",
"iarna-toml-esm": "^3.0.5",
"ibantools": "^4.3.3",
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 742e5854..82e0f1e0 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -177,7 +177,7 @@ dependencies:
specifier: ^0.6.2
version: 0.6.2
countries-and-timezones:
- specifier: ^3.7.2
+ specifier: ^3.6.0
version: 3.7.2
countries-db:
specifier: ^1.2.0
@@ -263,6 +263,9 @@ dependencies:
generate-schema:
specifier: ^2.6.0
version: 2.6.0
+ get-timezone-offset:
+ specifier: ^1.0.5
+ version: 1.0.5
hash-wasm:
specifier: ^4.11.0
version: 4.11.0
@@ -6296,7 +6299,7 @@ packages:
/@vueuse/shared@10.0.0(vue@3.3.4):
resolution: {integrity: sha512-Zh3LgJqvUBWVY3SiMvXanTcfAneGbt63QPczBRDNgQ6jd/ehodO9a1lCFzaA6SWJJoI+ugVTjHFYJdoR656DVQ==}
dependencies:
- vue-demi: 0.14.10(vue@3.3.4)
+ vue-demi: 0.14.5(vue@3.3.4)
transitivePeerDependencies:
- '@vue/composition-api'
- vue
@@ -9235,6 +9238,11 @@ packages:
get-intrinsic: 1.2.2
dev: true
+ /get-timezone-offset@1.0.5:
+ resolution: {integrity: sha512-+B+/vEJ9qJgZheDVNmuY+4il8sJhTFXRvSiiqyRfwiCEhTaZqn/yCoNToDzQL+Mv9DLKlyO1bSIP5nUCJQN9Aw==}
+ engines: {node: '>=4.0.0'}
+ dev: false
+
/get-tsconfig@4.7.2:
resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==}
dependencies:
@@ -15526,7 +15534,6 @@ packages:
/yamljs@0.3.0:
resolution: {integrity: sha512-C/FsVVhht4iPQYXOInoxUM/1ELSf9EsgKH34FofQOp6hwCPrW4vG4w5++TED3xRUo8gD7l0P1J1dLlDYzODsTQ==}
- hasBin: true
dependencies:
argparse: 1.0.10
glob: 7.2.3
diff --git a/src/tools/index.ts b/src/tools/index.ts
index bf854c54..d4b88335 100644
--- a/src/tools/index.ts
+++ b/src/tools/index.ts
@@ -79,6 +79,7 @@ import { tool as imageToCss } from './image-to-css';
import { tool as jsonToGo } from './json-to-go';
import { tool as jsonToSchema } from './json-to-schema';
import { tool as qrCodeDecoder } from './qr-code-decoder';
+import { tool as timezoneConverter } from './timezone-converter';
import { tool as markdownToHtml } from './markdown-to-html';
import { tool as nginxFormatter } from './nginx-formatter';
import { tool as potrace } from './potrace';
@@ -211,6 +212,7 @@ export const toolsByCategory: ToolCategory[] = [
name: 'Converter',
components: [
dateTimeConverter,
+ timezoneConverter,
baseConverter,
romanNumeralConverter,
base64StringConverter,
diff --git a/src/tools/timezone-converter/get-timezone-offset.d.ts b/src/tools/timezone-converter/get-timezone-offset.d.ts
new file mode 100644
index 00000000..e7f4320f
--- /dev/null
+++ b/src/tools/timezone-converter/get-timezone-offset.d.ts
@@ -0,0 +1,3 @@
+declare module "get-timezone-offset" {
+ export default function(timeZoneName: string, date: Date);
+}
\ No newline at end of file
diff --git a/src/tools/timezone-converter/index.ts b/src/tools/timezone-converter/index.ts
new file mode 100644
index 00000000..318fcf94
--- /dev/null
+++ b/src/tools/timezone-converter/index.ts
@@ -0,0 +1,12 @@
+import { CalendarTime } from '@vicons/tabler';
+import { defineTool } from '../tool';
+
+export const tool = defineTool({
+ name: 'Timezone Converter',
+ path: '/timezone-converter',
+ description: 'Convert Date-Time from a timezone to others and get timezone vs countries infos',
+ keywords: ['timezone', 'tz', 'date', 'time', 'country', 'converter'],
+ component: () => import('./timezone-converter.vue'),
+ icon: CalendarTime,
+ createdAt: new Date('2024-08-15'),
+});
diff --git a/src/tools/timezone-converter/timezone-converter.vue b/src/tools/timezone-converter/timezone-converter.vue
new file mode 100644
index 00000000..ba11a7f9
--- /dev/null
+++ b/src/tools/timezone-converter/timezone-converter.vue
@@ -0,0 +1,138 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+ {{ tz.name }} ({{ tz.countries.join(', ') }}): UTC= {{ tz.utcOffsetStr }}, DST= {{ tz.dstOffsetStr }}
+
+
+
+
+
+
+
+
+
+
+ -
+ {{ country.name }} ({{ country.id }}): {{ country.timezones.join(', ') }}
+
+
+
+
+