Merge branch 'main' into feat/email-parser
This commit is contained in:
		
						commit
						357384949d
					
				
							
								
								
									
										
											BIN
										
									
								
								.github/logo-dark.png
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								.github/logo-dark.png
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 40 KiB | 
							
								
								
									
										
											BIN
										
									
								
								.github/logo-white.png
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								.github/logo-white.png
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 39 KiB | 
							
								
								
									
										
											BIN
										
									
								
								.github/logo.png
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										
											BIN
										
									
								
								.github/logo.png
									
									
									
									
										vendored
									
									
								
							
										
											Binary file not shown.
										
									
								
							| Before Width: | Height: | Size: 7.8 KiB | 
| @ -1,4 +1,8 @@ | ||||
|  | ||||
| <picture> | ||||
|     <source srcset="./.github/logo-dark.png" media="(prefers-color-scheme: light)"> | ||||
|     <source srcset="./.github/logo-white.png" media="(prefers-color-scheme: dark)"> | ||||
|     <img src="./.github/logo-dark.png" alt="logo"> | ||||
| </picture> | ||||
| 
 | ||||
| Useful tools for developer and people working in IT. [Have a look !](https://it-tools.tech). | ||||
| 
 | ||||
|  | ||||
							
								
								
									
										1
									
								
								components.d.ts
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								components.d.ts
									
									
									
									
										vendored
									
									
								
							| @ -122,6 +122,7 @@ declare module '@vue/runtime-core' { | ||||
|     LoremIpsumGenerator: typeof import('./src/tools/lorem-ipsum-generator/lorem-ipsum-generator.vue')['default'] | ||||
|     MacAddressGenerator: typeof import('./src/tools/mac-address-generator/mac-address-generator.vue')['default'] | ||||
|     MacAddressLookup: typeof import('./src/tools/mac-address-lookup/mac-address-lookup.vue')['default'] | ||||
|     MarkdownToHtml: typeof import('./src/tools/markdown-to-html/markdown-to-html.vue')['default'] | ||||
|     MathEvaluator: typeof import('./src/tools/math-evaluator/math-evaluator.vue')['default'] | ||||
|     MenuBar: typeof import('./src/tools/html-wysiwyg-editor/editor/menu-bar.vue')['default'] | ||||
|     MenuBarItem: typeof import('./src/tools/html-wysiwyg-editor/editor/menu-bar-item.vue')['default'] | ||||
|  | ||||
| @ -43,6 +43,7 @@ | ||||
|     "@tiptap/pm": "2.1.6", | ||||
|     "@tiptap/starter-kit": "2.1.6", | ||||
|     "@tiptap/vue-3": "2.0.3", | ||||
|     "@types/markdown-it": "^13.0.7", | ||||
|     "@types/figlet": "^1.5.8", | ||||
|     "@vicons/material": "^0.12.0", | ||||
|     "@vicons/tabler": "^0.12.0", | ||||
| @ -73,6 +74,7 @@ | ||||
|     "jwt-decode": "^3.1.2", | ||||
|     "libphonenumber-js": "^1.10.28", | ||||
|     "lodash": "^4.17.21", | ||||
|     "markdown-it": "^14.0.0", | ||||
|     "marked": "^10.0.0", | ||||
|     "mathjs": "^11.9.1", | ||||
|     "mime-types": "^2.1.35", | ||||
|  | ||||
							
								
								
									
										42
									
								
								pnpm-lock.yaml
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										42
									
								
								pnpm-lock.yaml
									
									
									
										generated
									
									
									
								
							| @ -32,6 +32,9 @@ dependencies: | ||||
|   '@types/figlet': | ||||
|     specifier: ^1.5.8 | ||||
|     version: 1.5.8 | ||||
|   '@types/markdown-it': | ||||
|     specifier: ^13.0.7 | ||||
|     version: 13.0.9 | ||||
|   '@vicons/material': | ||||
|     specifier: ^0.12.0 | ||||
|     version: 0.12.0 | ||||
| @ -119,6 +122,9 @@ dependencies: | ||||
|   lodash: | ||||
|     specifier: ^4.17.21 | ||||
|     version: 4.17.21 | ||||
|   markdown-it: | ||||
|     specifier: ^14.0.0 | ||||
|     version: 14.1.0 | ||||
|   marked: | ||||
|     specifier: ^10.0.0 | ||||
|     version: 10.0.0 | ||||
| @ -2997,7 +3003,6 @@ packages: | ||||
| 
 | ||||
|   /@types/linkify-it@3.0.2: | ||||
|     resolution: {integrity: sha512-HZQYqbiFVWufzCwexrvh694SOim8z2d+xJl5UNamcvQFejLY/2YUtzXHYi3cHdI7PMlS8ejH2slRAOJQ32aNbA==} | ||||
|     dev: true | ||||
| 
 | ||||
|   /@types/lodash-es@4.17.10: | ||||
|     resolution: {integrity: sha512-YJP+w/2khSBwbUSFdGsSqmDvmnN3cCKoPOL7Zjle6s30ZtemkkqhjVfFqGwPN7ASil5VyjE2GtyU/yqYY6mC0A==} | ||||
| @ -3019,6 +3024,13 @@ packages: | ||||
|       '@types/mdurl': 1.0.2 | ||||
|     dev: true | ||||
| 
 | ||||
|   /@types/markdown-it@13.0.9: | ||||
|     resolution: {integrity: sha512-1XPwR0+MgXLWfTn9gCsZ55AHOKW1WN+P9vr0PaQh5aerR9LLQXUbjfEAFhjmEmyoYFWAyuN2Mqkn40MZ4ukjBw==} | ||||
|     dependencies: | ||||
|       '@types/linkify-it': 3.0.2 | ||||
|       '@types/mdurl': 1.0.2 | ||||
|     dev: false | ||||
| 
 | ||||
|   /@types/mdast@3.0.11: | ||||
|     resolution: {integrity: sha512-Y/uImid8aAwrEA24/1tcRZwpxX3pIFTSilcNDKSPn+Y2iDywSEachzRuvgAYYLR3wpGXAsMbv5lvKLDZLeYPAw==} | ||||
|     dependencies: | ||||
| @ -3027,7 +3039,6 @@ packages: | ||||
| 
 | ||||
|   /@types/mdurl@1.0.2: | ||||
|     resolution: {integrity: sha512-eC4U9MlIcu2q0KQmXszyn5Akca/0jrQmwDRgpAMJai7qBWq4amIQhZyNau4VYGtCeALvW1/NtjzJJ567aZxfKA==} | ||||
|     dev: true | ||||
| 
 | ||||
|   /@types/mime-types@2.1.1: | ||||
|     resolution: {integrity: sha512-vXOTGVSLR2jMw440moWTC7H19iUyLtP3Z1YTj7cSsubOICinjMxFeb/V57v9QdyyPGbbWolUFSSmSiRSn94tFw==} | ||||
| @ -5281,7 +5292,6 @@ packages: | ||||
|   /entities@4.5.0: | ||||
|     resolution: {integrity: sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==} | ||||
|     engines: {node: '>=0.12'} | ||||
|     dev: true | ||||
| 
 | ||||
|   /errno@0.1.8: | ||||
|     resolution: {integrity: sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A==} | ||||
| @ -7061,6 +7071,12 @@ packages: | ||||
|     dependencies: | ||||
|       uc.micro: 1.0.6 | ||||
| 
 | ||||
|   /linkify-it@5.0.0: | ||||
|     resolution: {integrity: sha512-5aHCbzQRADcdP+ATqnDuhhJ/MRIqDkZX5pyjFHRRysS8vZ5AbqGEoFIb6pYHPZ+L/OC2Lc+xT8uHVVR5CAK/wQ==} | ||||
|     dependencies: | ||||
|       uc.micro: 2.1.0 | ||||
|     dev: false | ||||
| 
 | ||||
|   /local-pkg@0.4.3: | ||||
|     resolution: {integrity: sha512-SFppqq5p42fe2qcZQqqEOiVRXl+WCP1MdT6k7BDEW1j++sp5fIY+/fdRQitvKgB5BrBcmrs5m/L0v2FrU5MY1g==} | ||||
|     engines: {node: '>=14'} | ||||
| @ -7198,6 +7214,18 @@ packages: | ||||
|       mdurl: 1.0.1 | ||||
|       uc.micro: 1.0.6 | ||||
| 
 | ||||
|   /markdown-it@14.1.0: | ||||
|     resolution: {integrity: sha512-a54IwgWPaeBCAAsv13YgmALOF1elABB08FxO9i+r4VFk5Vl4pKokRPeX8u5TCgSsPi6ec1otfLjdOpVcgbpshg==} | ||||
|     hasBin: true | ||||
|     dependencies: | ||||
|       argparse: 2.0.1 | ||||
|       entities: 4.5.0 | ||||
|       linkify-it: 5.0.0 | ||||
|       mdurl: 2.0.0 | ||||
|       punycode.js: 2.3.1 | ||||
|       uc.micro: 2.1.0 | ||||
|     dev: false | ||||
| 
 | ||||
|   /marked@10.0.0: | ||||
|     resolution: {integrity: sha512-YiGcYcWj50YrwBgNzFoYhQ1hT6GmQbFG8SksnYJX1z4BXTHSOrz1GB5/Jm2yQvMg4nN1FHP4M6r03R10KrVUiA==} | ||||
|     engines: {node: '>= 18'} | ||||
| @ -7254,6 +7282,10 @@ packages: | ||||
|   /mdurl@1.0.1: | ||||
|     resolution: {integrity: sha512-/sKlQJCBYVY9Ers9hqzKou4H6V5UWc/M59TH2dvkt+84itfnq7uFOMLpOiOS4ujvHP4etln18fmIxA5R5fll0g==} | ||||
| 
 | ||||
|   /mdurl@2.0.0: | ||||
|     resolution: {integrity: sha512-Lf+9+2r+Tdp5wXDXC4PcIBjTDtq4UKjCPMQhKIuzpJNW0b96kVqSwW0bT7FhRSfmAiFYgP+SCRvdrDozfh0U5w==} | ||||
|     dev: false | ||||
| 
 | ||||
|   /merge-stream@2.0.0: | ||||
|     resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} | ||||
|     dev: true | ||||
| @ -9246,6 +9278,10 @@ packages: | ||||
|   /uc.micro@1.0.6: | ||||
|     resolution: {integrity: sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA==} | ||||
| 
 | ||||
|   /uc.micro@2.1.0: | ||||
|     resolution: {integrity: sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==} | ||||
|     dev: false | ||||
| 
 | ||||
|   /ufo@1.1.2: | ||||
|     resolution: {integrity: sha512-TrY6DsjTQQgyS3E3dBaOXf0TpPD8u9FVrVYmKVegJuFw51n/YB9XPt+U6ydzFG5ZIN7+DIjPbNmXoBj9esYhgQ==} | ||||
| 
 | ||||
|  | ||||
| @ -11,6 +11,7 @@ import { tool as textToUnicode } from './text-to-unicode'; | ||||
| import { tool as safelinkDecoder } from './safelink-decoder'; | ||||
| import { tool as xmlToJson } from './xml-to-json'; | ||||
| import { tool as jsonToXml } from './json-to-xml'; | ||||
| import { tool as markdownToHtml } from './markdown-to-html'; | ||||
| import { tool as pdfSignatureChecker } from './pdf-signature-checker'; | ||||
| import { tool as numeronymGenerator } from './numeronym-generator'; | ||||
| import { tool as macAddressGenerator } from './mac-address-generator'; | ||||
| @ -114,6 +115,7 @@ export const toolsByCategory: ToolCategory[] = [ | ||||
|       tomlToYaml, | ||||
|       xmlToJson, | ||||
|       jsonToXml, | ||||
|       markdownToHtml, | ||||
|     ], | ||||
|   }, | ||||
|   { | ||||
|  | ||||
							
								
								
									
										12
									
								
								src/tools/markdown-to-html/index.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								src/tools/markdown-to-html/index.ts
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,12 @@ | ||||
| import { Markdown } from '@vicons/tabler'; | ||||
| import { defineTool } from '../tool'; | ||||
| 
 | ||||
| export const tool = defineTool({ | ||||
|   name: 'Markdown to HTML', | ||||
|   path: '/markdown-to-html', | ||||
|   description: 'Convert Markdown to Html and allow to print (as PDF)', | ||||
|   keywords: ['markdown', 'html', 'converter', 'pdf'], | ||||
|   component: () => import('./markdown-to-html.vue'), | ||||
|   icon: Markdown, | ||||
|   createdAt: new Date('2024-08-25'), | ||||
| }); | ||||
							
								
								
									
										44
									
								
								src/tools/markdown-to-html/markdown-to-html.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										44
									
								
								src/tools/markdown-to-html/markdown-to-html.vue
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,44 @@ | ||||
| <script setup lang="ts"> | ||||
| import markdownit from 'markdown-it'; | ||||
| import TextareaCopyable from '@/components/TextareaCopyable.vue'; | ||||
| 
 | ||||
| const inputMarkdown = ref(''); | ||||
| const outputHtml = computed(() => { | ||||
|   const md = markdownit(); | ||||
|   return md.render(inputMarkdown.value); | ||||
| }); | ||||
| 
 | ||||
| function printHtml() { | ||||
|   const w = window.open(); | ||||
|   if (w === null) { | ||||
|     return; | ||||
|   } | ||||
|   w.document.body.innerHTML = outputHtml.value; | ||||
|   w.print(); | ||||
| } | ||||
| </script> | ||||
| 
 | ||||
| <template> | ||||
|   <div> | ||||
|     <c-input-text | ||||
|       v-model:value="inputMarkdown" | ||||
|       multiline raw-text | ||||
|       placeholder="Your Markdown content..." | ||||
|       rows="8" | ||||
|       autofocus | ||||
|       label="Your Markdown to convert:" | ||||
|     /> | ||||
| 
 | ||||
|     <n-divider /> | ||||
| 
 | ||||
|     <n-form-item label="Output HTML:"> | ||||
|       <TextareaCopyable :value="outputHtml" :word-wrap="true" language="html" /> | ||||
|     </n-form-item> | ||||
| 
 | ||||
|     <div flex justify-center> | ||||
|       <n-button @click="printHtml"> | ||||
|         Print as PDF | ||||
|       </n-button> | ||||
|     </div> | ||||
|   </div> | ||||
| </template> | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user