mirror of
https://github.com/lissy93/networking-toolbox.git
synced 2026-11-25 23:24:14 +03:00
Navigation icons
This commit is contained in:
1 parent
7a0573df64
commit
b85edaac09
5 files changed
+30
-16
No files matched your search
@@ -3,6 +3,7 @@
|
||||
import { TOP_NAV, isActive } from '$lib/constants/nav';
|
||||
import { site } from '$lib/constants/site';
|
||||
import favicon from '$lib/assets/favicon.svg';
|
||||
import Icon from '$lib/components/Icon.svelte';
|
||||
|
||||
// Props from +layout for theme state & toggler
|
||||
export let darkMode: boolean;
|
||||
@@ -20,9 +21,7 @@
|
||||
<div class="logo">
|
||||
<div class="logo-icon">
|
||||
<a href="/" aria-label="Home">
|
||||
<svg fill="currentColor" viewBox="0 0 24 24">
|
||||
<path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/>
|
||||
</svg>
|
||||
<Icon name="networking" size="lg" />
|
||||
</a>
|
||||
</div>
|
||||
<div>
|
||||
|
||||
@@ -40,6 +40,20 @@
|
||||
<svg fill="currentColor" viewBox="0 0 24 24">
|
||||
<path d="M12,1L3,5V11C3,16.55 6.84,21.74 12,23C17.16,21.74 21,16.55 21,11V5L12,1M12,7C13.4,7 14.8,8.6 14.8,10V11.5C14.8,12.4 14.4,13.8 13,13.8H11C9.6,13.8 9.2,12.4 9.2,11.5V10C9.2,8.6 10.6,7 12,7Z"/>
|
||||
</svg>
|
||||
{:else if name === 'networking'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M112 304L112 464L152 464L152 408C152 394.7 162.7 384 176 384C189.3 384 200 394.7 200 408L200 464L248 464L248 408C248 394.7 258.7 384 272 384C285.3 384 296 394.7 296 408L296 464L344 464L344 408C344 394.7 354.7 384 368 384C381.3 384 392 394.7 392 408L392 464L440 464L440 408C440 394.7 450.7 384 464 384C477.3 384 488 394.7 488 408L488 464L528 464L528 304L488 304C474.7 304 464 293.3 464 280L464 240L424 240C410.7 240 400 229.3 400 216L400 176L240 176L240 216C240 229.3 229.3 240 216 240L176 240L176 280C176 293.3 165.3 304 152 304L112 304z"/><path d="M192 160C192 142.3 206.3 128 224 128L416 128C433.7 128 448 142.3 448 160L448 192L480 192C497.7 192 512 206.3 512 224L512 256L544 256C561.7 256 576 270.3 576 288L576 480C576 497.7 561.7 512 544 512L96 512C78.3 512 64 497.7 64 480L64 288C64 270.3 78.3 256 96 256L128 256L128 224C128 206.3 142.3 192 160 192L192 192L192 160zM240 176L240 216C240 229.3 229.3 240 216 240L176 240L176 280C176 293.3 165.3 304 152 304L112 304L112 464L152 464L152 408C152 394.7 162.7 384 176 384C189.3 384 200 394.7 200 408L200 464L248 464L248 408C248 394.7 258.7 384 272 384C285.3 384 296 394.7 296 408L296 464L344 464L344 408C344 394.7 354.7 384 368 384C381.3 384 392 394.7 392 408L392 464L440 464L440 408C440 394.7 450.7 384 464 384C477.3 384 488 394.7 488 408L488 464L528 464L528 304L488 304C474.7 304 464 293.3 464 280L464 240L424 240C410.7 240 400 229.3 400 216L400 176L240 176z"/></svg>
|
||||
{:else if name === 'ip-convertor'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M112 272C112 289.7 126.3 304 144 304C161.7 304 176 289.7 176 272C176 254.3 161.7 240 144 240C126.3 240 112 254.3 112 272zM368 496C368 513.7 382.3 528 400 528C417.7 528 432 513.7 432 496C432 478.3 417.7 464 400 464C382.3 464 368 478.3 368 496zM432 144C432 161.7 446.3 176 464 176C481.7 176 496 161.7 496 144C496 126.3 481.7 112 464 112C446.3 112 432 126.3 432 144z"/><path d="M432 144C432 126.3 446.3 112 464 112C481.7 112 496 126.3 496 144C496 161.7 481.7 176 464 176C446.3 176 432 161.7 432 144zM402.1 194.6C408.9 202.9 417.3 209.8 426.8 214.8L390 416.6C378.5 418 367.8 421.9 358.3 427.7L217.3 304.2C221.6 294.3 224 283.5 224 272C224 270 223.9 267.9 223.8 265.9L402.1 194.6zM474 223.4C513.5 218.5 544 184.8 544 144C544 99.8 508.2 64 464 64C419.8 64 384 99.8 384 144C384 146 384.1 148.1 384.2 150.1L205.9 221.4C191.3 203.4 169 192 144 192C99.8 192 64 227.8 64 272C64 316.2 99.8 352 144 352C159.3 352 173.5 347.7 185.6 340.3L326.7 463.8C322.4 473.7 320 484.5 320 496C320 540.2 355.8 576 400 576C444.2 576 480 540.2 480 496C480 465.3 462.7 438.6 437.3 425.2L474 223.4zM368 496C368 478.3 382.3 464 400 464C417.7 464 432 478.3 432 496C432 513.7 417.7 528 400 528C382.3 528 368 513.7 368 496zM144 240C161.7 240 176 254.3 176 272C176 289.7 161.7 304 144 304C126.3 304 112 289.7 112 272C112 254.3 126.3 240 144 240z"/></svg>
|
||||
{:else if name === 'subnet-calculator'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M176 240L176 512C176 520.8 183.2 528 192 528L448 528C456.8 528 464 520.8 464 512L464 240L176 240zM256 296C256 309.3 245.3 320 232 320C218.7 320 208 309.3 208 296C208 282.7 218.7 272 232 272C245.3 272 256 282.7 256 296zM256 384C256 397.3 245.3 408 232 408C218.7 408 208 397.3 208 384C208 370.7 218.7 360 232 360C245.3 360 256 370.7 256 384zM208 472C208 458.7 218.7 448 232 448L320 448C333.3 448 344 458.7 344 472C344 485.3 333.3 496 320 496L232 496C218.7 496 208 485.3 208 472zM344 296C344 309.3 333.3 320 320 320C306.7 320 296 309.3 296 296C296 282.7 306.7 272 320 272C333.3 272 344 282.7 344 296zM344 384C344 397.3 333.3 408 320 408C306.7 408 296 397.3 296 384C296 370.7 306.7 360 320 360C333.3 360 344 370.7 344 384zM432 296C432 309.3 421.3 320 408 320C394.7 320 384 309.3 384 296C384 282.7 394.7 272 408 272C421.3 272 432 282.7 432 296zM432 384C432 397.3 421.3 408 408 408C394.7 408 384 397.3 384 384C384 370.7 394.7 360 408 360C421.3 360 432 370.7 432 384zM384 472C384 458.7 394.7 448 408 448C421.3 448 432 458.7 432 472C432 485.3 421.3 496 408 496C394.7 496 384 485.3 384 472z"/><path d="M464 240L464 512C464 520.8 456.8 528 448 528L192 528C183.2 528 176 520.8 176 512L176 240L464 240zM464 192L176 192L176 128C176 119.2 183.2 112 192 112L448 112C456.8 112 464 119.2 464 128L464 192zM512 192L512 128C512 92.7 483.3 64 448 64L192 64C156.7 64 128 92.7 128 128L128 512C128 547.3 156.7 576 192 576L448 576C483.3 576 512 547.3 512 512L512 192zM208 296C208 309.3 218.7 320 232 320C245.3 320 256 309.3 256 296C256 282.7 245.3 272 232 272C218.7 272 208 282.7 208 296zM232 360C218.7 360 208 370.7 208 384C208 397.3 218.7 408 232 408C245.3 408 256 397.3 256 384C256 370.7 245.3 360 232 360zM208 472C208 485.3 218.7 496 232 496L320 496C333.3 496 344 485.3 344 472C344 458.7 333.3 448 320 448L232 448C218.7 448 208 458.7 208 472zM320 272C306.7 272 296 282.7 296 296C296 309.3 306.7 320 320 320C333.3 320 344 309.3 344 296C344 282.7 333.3 272 320 272zM296 384C296 397.3 306.7 408 320 408C333.3 408 344 397.3 344 384C344 370.7 333.3 360 320 360C306.7 360 296 370.7 296 384zM408 272C394.7 272 384 282.7 384 296C384 309.3 394.7 320 408 320C421.3 320 432 309.3 432 296C432 282.7 421.3 272 408 272zM384 384C384 397.3 394.7 408 408 408C421.3 408 432 397.3 432 384C432 370.7 421.3 360 408 360C394.7 360 384 370.7 384 384zM408 448C394.7 448 384 458.7 384 472C384 485.3 394.7 496 408 496C421.3 496 432 485.3 432 472C432 458.7 421.3 448 408 448z"/></svg>
|
||||
{:else if name === 'cidr-convertor'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M86.6 384L208 262.6L208 320C208 326.4 210.5 332.5 215 337C219.5 341.5 225.6 344 232 344L320 344L320 448C320 434.7 309.3 424 296 424L232 424C218.7 424 208 434.7 208 448L208 505.4L86.6 384zM320 192C320 205.3 330.7 216 344 216L408 216C421.3 216 432 205.3 432 192L432 134.6L553.4 256L432 377.4L432 320C432 313.6 429.5 307.5 425 303C420.5 298.5 414.4 296 408 296L320 296L320 192z"/><path d="M432 134.6L432 192C432 205.3 421.3 216 408 216L344 216C330.7 216 320 205.3 320 192C320 178.7 330.7 168 344 168L384 168L384 96C384 83.1 391.8 71.4 403.8 66.4L403.8 66.4C415.8 61.4 429.5 64.2 438.7 73.3L598.7 233.3C611.2 245.8 611.2 266.1 598.7 278.6L438.7 438.6C429.5 447.8 415.8 450.5 403.8 445.5C391.8 440.5 384 428.9 384 416L384 344L232 344C225.6 344 219.5 341.5 215 337C210.5 332.5 208 326.4 208 320L208 262.6L86.6 384L208 505.4L208 448C208 434.7 218.7 424 232 424L296 424C309.3 424 320 434.7 320 448C320 461.3 309.3 472 296 472L256 472L256 544C256 556.9 248.2 568.6 236.2 573.6L236.2 573.6C224.2 578.6 210.5 575.8 201.3 566.7L41.3 406.7C28.8 394.2 28.8 373.9 41.3 361.4L201.3 201.4C210.5 192.2 224.2 189.5 236.2 194.5C248.2 199.5 256 211.1 256 224L256 296L408 296C414.4 296 420.5 298.5 425 303C429.5 307.5 432 313.6 432 320L432 377.4L553.4 256L432 134.6zM404.7 404.7L404.7 404.7zM235.3 532.7L235.3 532.7C235.3 532.7 235.3 532.7 235.3 532.7zM75.3 372.7C75.3 372.7 75.3 372.7 75.3 372.7L75.3 372.7L75.3 372.7z"/></svg>
|
||||
{:else if name === 'network-classes'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M40 368C40 381.3 50.7 392 64 392C77.3 392 88 381.3 88 368C88 354.7 77.3 344 64 344C50.7 344 40 354.7 40 368zM200 128C200 141.3 210.7 152 224 152C237.3 152 248 141.3 248 128C248 114.7 237.3 104 224 104C210.7 104 200 114.7 200 128zM240 368C240 421 283 464 336 464C389 464 432 421 432 368C432 315 389 272 336 272C283 272 240 315 240 368zM552 192C552 205.3 562.7 216 576 216C589.3 216 600 205.3 600 192C600 178.7 589.3 168 576 168C562.7 168 552 178.7 552 192zM552 512C552 525.3 562.7 536 576 536C589.3 536 600 525.3 600 512C600 498.7 589.3 488 576 488C562.7 488 552 498.7 552 512z"/><path d="M224 104C237.3 104 248 114.7 248 128C248 141.3 237.3 152 224 152C210.7 152 200 141.3 200 128C200 114.7 210.7 104 224 104zM224 192C225.1 192 226.2 192 227.3 191.9L254.2 249.5C222.9 271.2 200.5 304.9 194 344L123.4 344C113.9 320.5 90.9 304 64.1 304C28.8 304 .1 332.7 .1 368C.1 403.3 28.8 432 64.1 432C91 432 114 415.5 123.4 392L194 392C205.4 460.1 264.7 512 336 512C379.8 512 419 492.5 445.4 461.6L512.8 502C512.3 505.2 512 508.6 512 511.9C512 547.2 540.7 575.9 576 575.9C611.3 575.9 640 547.2 640 511.9C640 476.6 611.3 447.9 576 447.9C561.5 447.9 548.2 452.7 537.5 460.8L470.2 420.4C476.6 404.1 480.1 386.4 480.1 367.9C480.1 344.7 474.6 322.7 464.8 303.3L542.4 246.4C552.2 252.5 563.7 256 576.1 256C611.4 256 640.1 227.3 640.1 192C640.1 156.7 611.4 128 576.1 128C540.8 128 512.1 156.7 512.1 192C512.1 197.4 512.8 202.7 514 207.7L436.4 264.6C410.5 239.4 375.1 223.9 336.1 223.9C322.8 223.9 310 225.7 297.8 229.1L270.9 171.6C281.5 160.2 288 144.9 288 128C288 92.7 259.3 64 224 64C188.7 64 160 92.7 160 128C160 163.3 188.7 192 224 192zM576 168C589.3 168 600 178.7 600 192C600 205.3 589.3 216 576 216C562.7 216 552 205.3 552 192C552 178.7 562.7 168 576 168zM552 512C552 498.7 562.7 488 576 488C589.3 488 600 498.7 600 512C600 525.3 589.3 536 576 536C562.7 536 552 525.3 552 512zM64 344C77.3 344 88 354.7 88 368C88 381.3 77.3 392 64 392C50.7 392 40 381.3 40 368C40 354.7 50.7 344 64 344zM336 272C389 272 432 315 432 368C432 421 389 464 336 464C283 464 240 421 240 368C240 315 283 272 336 272z"/></svg>
|
||||
{:else if name === 'reserved-ranges'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M112 432L112 528L528 528L528 432L112 432z"/><path d="M344 64L344 192C344 205.3 333.3 216 320 216C306.7 216 296 205.3 296 192L296 64C296 50.7 306.7 40 320 40C333.3 40 344 50.7 344 64zM192 352C192 334.3 206.3 320 224 320L416 320C433.7 320 448 334.3 448 352L448 384L528 384C554.5 384 576 405.5 576 432L576 528C576 554.5 554.5 576 528 576L112 576C85.5 576 64 554.5 64 528L64 432C64 405.5 85.5 384 112 384L192 384L192 352zM528 528L528 432L112 432L112 528L528 528zM44 178.7C51.4 167.7 66.3 164.7 77.3 172L173.3 236C184.3 243.4 187.3 258.3 180 269.3C172.7 280.3 157.7 283.3 146.7 276L50.7 212C39.7 204.6 36.7 189.7 44 178.7zM562.7 172C573.7 164.6 588.6 167.6 596 178.7C603.4 189.8 600.4 204.6 589.3 212L493.3 276C482.3 283.4 467.4 280.4 460 269.3C452.6 258.2 455.6 243.4 466.7 236L562.7 172z"/></svg>
|
||||
{:else if name === 'common-subnets'}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 640"><!--!Font Awesome Pro v7.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path opacity=".4" d="M112 144L208 144L208 240L112 240L112 144zM304 400L400 400L400 496L304 496L304 400zM432 144L528 144L528 240L432 240L432 144z"/><path d="M112 144L112 240L208 240L208 144L112 144zM64 144C64 117.5 85.5 96 112 96L208 96C234.5 96 256 117.5 256 144L256 168L384 168L384 144C384 117.5 405.5 96 432 96L528 96C554.5 96 576 117.5 576 144L576 240C576 266.5 554.5 288 528 288L432 288C405.5 288 384 266.5 384 240L384 216L256 216L256 240C256 250.4 252.7 260.1 247 268L310 352L400 352C426.5 352 448 373.5 448 400L448 496C448 522.5 426.5 544 400 544L304 544C277.5 544 256 522.5 256 496L256 400C256 389.6 259.3 379.9 265 372L202 288L112 288C85.5 288 64 266.5 64 240L64 144zM304 400L304 496L400 496L400 400L304 400zM528 144L432 144L432 240L528 240L528 144z"/></svg>
|
||||
{:else if name === 'grid'}
|
||||
<svg fill="currentColor" viewBox="0 0 24 24">
|
||||
<path d="M3 3h8v8H3V3zm10 0h8v8h-8V3zM3 13h8v8H3v-8zm10 0h8v8h-8v-8z"/>
|
||||
@@ -63,4 +77,4 @@
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
@@ -11,13 +11,13 @@ export const STANDALONE_PAGES: NavItem[] = [
|
||||
href: '/subnet-calculator',
|
||||
label: 'Subnet Calculator',
|
||||
description: 'Calculate subnet information, network addresses, broadcast addresses, and host ranges with visual network analysis',
|
||||
icon: 'calculator'
|
||||
icon: 'subnet-calculator'
|
||||
},
|
||||
{
|
||||
href: '/ip-address-convertor',
|
||||
label: 'IP Address Converter',
|
||||
description: 'Convert IP addresses between decimal, binary, hexadecimal, and octal number systems',
|
||||
icon: 'transform'
|
||||
icon: 'ip-convertor'
|
||||
}
|
||||
];
|
||||
|
||||
@@ -35,13 +35,13 @@ export const SUB_NAV: Record<string, NavItem[]> = {
|
||||
href: '/cidr-convertor/cidr-to-subnet-mask',
|
||||
label: 'CIDR → Mask',
|
||||
description: 'Convert CIDR notation (e.g. /24) to subnet mask format (255.255.255.0)',
|
||||
icon: 'arrow-right'
|
||||
icon: 'cidr-convertor'
|
||||
},
|
||||
{
|
||||
href: '/cidr-convertor/subnet-mask-to-cidr',
|
||||
label: 'Mask → CIDR',
|
||||
description: 'Convert subnet mask format (255.255.255.0) to CIDR notation (/24)',
|
||||
icon: 'arrow-left'
|
||||
icon: 'cidr-convertor'
|
||||
}
|
||||
],
|
||||
'/ip-reference': [
|
||||
@@ -49,19 +49,19 @@ export const SUB_NAV: Record<string, NavItem[]> = {
|
||||
href: '/ip-reference/network-classes',
|
||||
label: 'Network Classes',
|
||||
description: 'IP address classes (A, B, C, D, E) and their characteristics',
|
||||
icon: 'layers'
|
||||
icon: 'network-classes'
|
||||
},
|
||||
{
|
||||
href: '/ip-reference/reserved-ranges',
|
||||
label: 'Reserved Ranges',
|
||||
description: 'Private networks, loopback, multicast, and special IP ranges',
|
||||
icon: 'shield'
|
||||
icon: 'reserved-ranges'
|
||||
},
|
||||
{
|
||||
href: '/ip-reference/common-subnets',
|
||||
label: 'Common Subnets',
|
||||
description: 'Quick reference for frequently used subnet configurations',
|
||||
icon: 'grid'
|
||||
icon: 'common-subnets'
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
export const site = {
|
||||
title: 'IP Calc',
|
||||
title: 'Networking Toolbox',
|
||||
description: 'A free set of online tools to help with IP addressing and subnetting.',
|
||||
longDescription: 'Comprehensive IP address calculator with subnet calculations, CIDR conversion, IP format conversion, and network reference tools.',
|
||||
heroDescription: 'Comprehensive suite of networking tools for subnet calculations, CIDR conversions, IP format transformations, and network reference information.',
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts">
|
||||
import '../styles/pages.scss';
|
||||
import { site, pages } from '$lib/constants/site';
|
||||
import { site, pages, about } from '$lib/constants/site';
|
||||
import { ALL_PAGES } from '$lib/constants/nav';
|
||||
import Icon from '$lib/components/Icon.svelte';
|
||||
|
||||
@@ -54,9 +54,10 @@
|
||||
<!-- Hero Section -->
|
||||
<section class="hero">
|
||||
<div class="hero-content">
|
||||
<h2>Professional Network Calculation Tools</h2>
|
||||
<h2>{site.title}</h2>
|
||||
<p class="hero-description">
|
||||
{site.heroDescription}
|
||||
{about.line1}<br>
|
||||
{about.line2}
|
||||
</p>
|
||||
</div>
|
||||
</section>
|
||||
@@ -88,7 +89,7 @@
|
||||
padding: var(--spacing-xl) 0 var(--spacing-lg);
|
||||
|
||||
.hero-content {
|
||||
max-width: 600px;
|
||||
max-width: 900px;
|
||||
margin: 0 auto;
|
||||
|
||||
h2 {
|
||||
|
||||
Reference in new issue
Block a user