Deployed the page to Github Pages.
This commit is contained in:
		
							parent
							
								
									1d79754e93
								
							
						
					
					
						commit
						2c89899458
					
				
					 62797 changed files with 6551425 additions and 15279 deletions
				
			
		
							
								
								
									
										45
									
								
								node_modules/ip-address/dist/v6/constants.d.ts
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								node_modules/ip-address/dist/v6/constants.d.ts
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,45 @@ | |||
| export declare const BITS = 128; | ||||
| export declare const GROUPS = 8; | ||||
| /** | ||||
|  * Represents IPv6 address scopes | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| export declare const SCOPES: { | ||||
|     [key: number]: string | undefined; | ||||
| }; | ||||
| /** | ||||
|  * Represents IPv6 address types | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| export declare const TYPES: { | ||||
|     [key: string]: string | undefined; | ||||
| }; | ||||
| /** | ||||
|  * A regular expression that matches bad characters in an IPv6 address | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| export declare const RE_BAD_CHARACTERS: RegExp; | ||||
| /** | ||||
|  * A regular expression that matches an incorrect IPv6 address | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| export declare const RE_BAD_ADDRESS: RegExp; | ||||
| /** | ||||
|  * A regular expression that matches an IPv6 subnet | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| export declare const RE_SUBNET_STRING: RegExp; | ||||
| /** | ||||
|  * A regular expression that matches an IPv6 zone | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| export declare const RE_ZONE_STRING: RegExp; | ||||
| export declare const RE_URL: RegExp; | ||||
| export declare const RE_URL_WITH_PORT: RegExp; | ||||
| //# sourceMappingURL=constants.d.ts.map
 | ||||
							
								
								
									
										1
									
								
								node_modules/ip-address/dist/v6/constants.d.ts.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								node_modules/ip-address/dist/v6/constants.d.ts.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1 @@ | |||
| {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/v6/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,IAAI,MAAM,CAAC;AACxB,eAAO,MAAM,MAAM,IAAI,CAAC;AAExB;;;;GAIG;AACH,eAAO,MAAM,MAAM,EAAE;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAA;CAS9C,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,KAAK,EAAE;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAA;CAuB7C,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,QAAqB,CAAC;AAEpD;;;;GAIG;AACH,eAAO,MAAM,cAAc,QAA6C,CAAC;AAEzE;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,QAAqB,CAAC;AAEnD;;;;GAIG;AACH,eAAO,MAAM,cAAc,QAAS,CAAC;AAErC,eAAO,MAAM,MAAM,QAA4C,CAAC;AAChE,eAAO,MAAM,gBAAgB,QAA8C,CAAC"} | ||||
							
								
								
									
										76
									
								
								node_modules/ip-address/dist/v6/constants.js
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										76
									
								
								node_modules/ip-address/dist/v6/constants.js
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,76 @@ | |||
| "use strict"; | ||||
| Object.defineProperty(exports, "__esModule", { value: true }); | ||||
| exports.RE_URL_WITH_PORT = exports.RE_URL = exports.RE_ZONE_STRING = exports.RE_SUBNET_STRING = exports.RE_BAD_ADDRESS = exports.RE_BAD_CHARACTERS = exports.TYPES = exports.SCOPES = exports.GROUPS = exports.BITS = void 0; | ||||
| exports.BITS = 128; | ||||
| exports.GROUPS = 8; | ||||
| /** | ||||
|  * Represents IPv6 address scopes | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| exports.SCOPES = { | ||||
|     0: 'Reserved', | ||||
|     1: 'Interface local', | ||||
|     2: 'Link local', | ||||
|     4: 'Admin local', | ||||
|     5: 'Site local', | ||||
|     8: 'Organization local', | ||||
|     14: 'Global', | ||||
|     15: 'Reserved', | ||||
| }; | ||||
| /** | ||||
|  * Represents IPv6 address types | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| exports.TYPES = { | ||||
|     'ff01::1/128': 'Multicast (All nodes on this interface)', | ||||
|     'ff01::2/128': 'Multicast (All routers on this interface)', | ||||
|     'ff02::1/128': 'Multicast (All nodes on this link)', | ||||
|     'ff02::2/128': 'Multicast (All routers on this link)', | ||||
|     'ff05::2/128': 'Multicast (All routers in this site)', | ||||
|     'ff02::5/128': 'Multicast (OSPFv3 AllSPF routers)', | ||||
|     'ff02::6/128': 'Multicast (OSPFv3 AllDR routers)', | ||||
|     'ff02::9/128': 'Multicast (RIP routers)', | ||||
|     'ff02::a/128': 'Multicast (EIGRP routers)', | ||||
|     'ff02::d/128': 'Multicast (PIM routers)', | ||||
|     'ff02::16/128': 'Multicast (MLDv2 reports)', | ||||
|     'ff01::fb/128': 'Multicast (mDNSv6)', | ||||
|     'ff02::fb/128': 'Multicast (mDNSv6)', | ||||
|     'ff05::fb/128': 'Multicast (mDNSv6)', | ||||
|     'ff02::1:2/128': 'Multicast (All DHCP servers and relay agents on this link)', | ||||
|     'ff05::1:2/128': 'Multicast (All DHCP servers and relay agents in this site)', | ||||
|     'ff02::1:3/128': 'Multicast (All DHCP servers on this link)', | ||||
|     'ff05::1:3/128': 'Multicast (All DHCP servers in this site)', | ||||
|     '::/128': 'Unspecified', | ||||
|     '::1/128': 'Loopback', | ||||
|     'ff00::/8': 'Multicast', | ||||
|     'fe80::/10': 'Link-local unicast', | ||||
| }; | ||||
| /** | ||||
|  * A regular expression that matches bad characters in an IPv6 address | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| exports.RE_BAD_CHARACTERS = /([^0-9a-f:/%])/gi; | ||||
| /** | ||||
|  * A regular expression that matches an incorrect IPv6 address | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| exports.RE_BAD_ADDRESS = /([0-9a-f]{5,}|:{3,}|[^:]:$|^:[^:]|\/$)/gi; | ||||
| /** | ||||
|  * A regular expression that matches an IPv6 subnet | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| exports.RE_SUBNET_STRING = /\/\d{1,3}(?=%|$)/; | ||||
| /** | ||||
|  * A regular expression that matches an IPv6 zone | ||||
|  * @memberof Address6 | ||||
|  * @static | ||||
|  */ | ||||
| exports.RE_ZONE_STRING = /%.*$/; | ||||
| exports.RE_URL = new RegExp(/^\[{0,1}([0-9a-f:]+)\]{0,1}/); | ||||
| exports.RE_URL_WITH_PORT = new RegExp(/\[([0-9a-f:]+)\]:([0-9]{1,5})/); | ||||
| //# sourceMappingURL=constants.js.map
 | ||||
							
								
								
									
										1
									
								
								node_modules/ip-address/dist/v6/constants.js.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								node_modules/ip-address/dist/v6/constants.js.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1 @@ | |||
| {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/v6/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,IAAI,GAAG,GAAG,CAAC;AACX,QAAA,MAAM,GAAG,CAAC,CAAC;AAExB;;;;GAIG;AACU,QAAA,MAAM,GAA0C;IAC3D,CAAC,EAAE,UAAU;IACb,CAAC,EAAE,iBAAiB;IACpB,CAAC,EAAE,YAAY;IACf,CAAC,EAAE,aAAa;IAChB,CAAC,EAAE,YAAY;IACf,CAAC,EAAE,oBAAoB;IACvB,EAAE,EAAE,QAAQ;IACZ,EAAE,EAAE,UAAU;CACN,CAAC;AAEX;;;;GAIG;AACU,QAAA,KAAK,GAA0C;IAC1D,aAAa,EAAE,yCAAyC;IACxD,aAAa,EAAE,2CAA2C;IAC1D,aAAa,EAAE,oCAAoC;IACnD,aAAa,EAAE,sCAAsC;IACrD,aAAa,EAAE,sCAAsC;IACrD,aAAa,EAAE,mCAAmC;IAClD,aAAa,EAAE,kCAAkC;IACjD,aAAa,EAAE,yBAAyB;IACxC,aAAa,EAAE,2BAA2B;IAC1C,aAAa,EAAE,yBAAyB;IACxC,cAAc,EAAE,2BAA2B;IAC3C,cAAc,EAAE,oBAAoB;IACpC,cAAc,EAAE,oBAAoB;IACpC,cAAc,EAAE,oBAAoB;IACpC,eAAe,EAAE,4DAA4D;IAC7E,eAAe,EAAE,4DAA4D;IAC7E,eAAe,EAAE,2CAA2C;IAC5D,eAAe,EAAE,2CAA2C;IAC5D,QAAQ,EAAE,aAAa;IACvB,SAAS,EAAE,UAAU;IACrB,UAAU,EAAE,WAAW;IACvB,WAAW,EAAE,oBAAoB;CACzB,CAAC;AAEX;;;;GAIG;AACU,QAAA,iBAAiB,GAAG,kBAAkB,CAAC;AAEpD;;;;GAIG;AACU,QAAA,cAAc,GAAG,0CAA0C,CAAC;AAEzE;;;;GAIG;AACU,QAAA,gBAAgB,GAAG,kBAAkB,CAAC;AAEnD;;;;GAIG;AACU,QAAA,cAAc,GAAG,MAAM,CAAC;AAExB,QAAA,MAAM,GAAG,IAAI,MAAM,CAAC,6BAA6B,CAAC,CAAC;AACnD,QAAA,gBAAgB,GAAG,IAAI,MAAM,CAAC,+BAA+B,CAAC,CAAC"} | ||||
							
								
								
									
										18
									
								
								node_modules/ip-address/dist/v6/helpers.d.ts
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								node_modules/ip-address/dist/v6/helpers.d.ts
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,18 @@ | |||
| /** | ||||
|  * @returns {String} the string with all zeroes contained in a <span> | ||||
|  */ | ||||
| export declare function spanAllZeroes(s: string): string; | ||||
| /** | ||||
|  * @returns {String} the string with each character contained in a <span> | ||||
|  */ | ||||
| export declare function spanAll(s: string, offset?: number): string; | ||||
| /** | ||||
|  * @returns {String} the string with leading zeroes contained in a <span> | ||||
|  */ | ||||
| export declare function spanLeadingZeroes(address: string): string; | ||||
| /** | ||||
|  * Groups an address | ||||
|  * @returns {String} a grouped address | ||||
|  */ | ||||
| export declare function simpleGroup(addressString: string, offset?: number): string[]; | ||||
| //# sourceMappingURL=helpers.d.ts.map
 | ||||
							
								
								
									
										1
									
								
								node_modules/ip-address/dist/v6/helpers.d.ts.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								node_modules/ip-address/dist/v6/helpers.d.ts.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1 @@ | |||
| {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../src/v6/helpers.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,wBAAgB,aAAa,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,CAE/C;AAED;;GAEG;AACH,wBAAgB,OAAO,CAAC,CAAC,EAAE,MAAM,EAAE,MAAM,GAAE,MAAU,GAAG,MAAM,CAc7D;AAMD;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAIzD;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,aAAa,EAAE,MAAM,EAAE,MAAM,GAAE,MAAU,GAAG,MAAM,EAAE,CAc/E"} | ||||
							
								
								
									
										48
									
								
								node_modules/ip-address/dist/v6/helpers.js
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										48
									
								
								node_modules/ip-address/dist/v6/helpers.js
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,48 @@ | |||
| "use strict"; | ||||
| Object.defineProperty(exports, "__esModule", { value: true }); | ||||
| exports.simpleGroup = exports.spanLeadingZeroes = exports.spanAll = exports.spanAllZeroes = void 0; | ||||
| const sprintf_js_1 = require("sprintf-js"); | ||||
| /** | ||||
|  * @returns {String} the string with all zeroes contained in a <span> | ||||
|  */ | ||||
| function spanAllZeroes(s) { | ||||
|     return s.replace(/(0+)/g, '<span class="zero">$1</span>'); | ||||
| } | ||||
| exports.spanAllZeroes = spanAllZeroes; | ||||
| /** | ||||
|  * @returns {String} the string with each character contained in a <span> | ||||
|  */ | ||||
| function spanAll(s, offset = 0) { | ||||
|     const letters = s.split(''); | ||||
|     return letters | ||||
|         .map((n, i) => (0, sprintf_js_1.sprintf)('<span class="digit value-%s position-%d">%s</span>', n, i + offset, spanAllZeroes(n)) // XXX Use #base-2 .value-0 instead?
 | ||||
|     ) | ||||
|         .join(''); | ||||
| } | ||||
| exports.spanAll = spanAll; | ||||
| function spanLeadingZeroesSimple(group) { | ||||
|     return group.replace(/^(0+)/, '<span class="zero">$1</span>'); | ||||
| } | ||||
| /** | ||||
|  * @returns {String} the string with leading zeroes contained in a <span> | ||||
|  */ | ||||
| function spanLeadingZeroes(address) { | ||||
|     const groups = address.split(':'); | ||||
|     return groups.map((g) => spanLeadingZeroesSimple(g)).join(':'); | ||||
| } | ||||
| exports.spanLeadingZeroes = spanLeadingZeroes; | ||||
| /** | ||||
|  * Groups an address | ||||
|  * @returns {String} a grouped address | ||||
|  */ | ||||
| function simpleGroup(addressString, offset = 0) { | ||||
|     const groups = addressString.split(':'); | ||||
|     return groups.map((g, i) => { | ||||
|         if (/group-v4/.test(g)) { | ||||
|             return g; | ||||
|         } | ||||
|         return (0, sprintf_js_1.sprintf)('<span class="hover-group group-%d">%s</span>', i + offset, spanLeadingZeroesSimple(g)); | ||||
|     }); | ||||
| } | ||||
| exports.simpleGroup = simpleGroup; | ||||
| //# sourceMappingURL=helpers.js.map
 | ||||
							
								
								
									
										1
									
								
								node_modules/ip-address/dist/v6/helpers.js.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								node_modules/ip-address/dist/v6/helpers.js.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1 @@ | |||
| {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../src/v6/helpers.ts"],"names":[],"mappings":";;;AAAA,2CAAqC;AAErC;;GAEG;AACH,SAAgB,aAAa,CAAC,CAAS;IACrC,OAAO,CAAC,CAAC,OAAO,CAAC,OAAO,EAAE,8BAA8B,CAAC,CAAC;AAC5D,CAAC;AAFD,sCAEC;AAED;;GAEG;AACH,SAAgB,OAAO,CAAC,CAAS,EAAE,SAAiB,CAAC;IACnD,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;IAE5B,OAAO,OAAO;SACX,GAAG,CACF,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CACP,IAAA,oBAAO,EACL,oDAAoD,EACpD,CAAC,EACD,CAAC,GAAG,MAAM,EACV,aAAa,CAAC,CAAC,CAAC,CACjB,CAAC,oCAAoC;KACzC;SACA,IAAI,CAAC,EAAE,CAAC,CAAC;AACd,CAAC;AAdD,0BAcC;AAED,SAAS,uBAAuB,CAAC,KAAa;IAC5C,OAAO,KAAK,CAAC,OAAO,CAAC,OAAO,EAAE,8BAA8B,CAAC,CAAC;AAChE,CAAC;AAED;;GAEG;AACH,SAAgB,iBAAiB,CAAC,OAAe;IAC/C,MAAM,MAAM,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAElC,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,uBAAuB,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACjE,CAAC;AAJD,8CAIC;AAED;;;GAGG;AACH,SAAgB,WAAW,CAAC,aAAqB,EAAE,SAAiB,CAAC;IACnE,MAAM,MAAM,GAAG,aAAa,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAExC,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE;QACzB,IAAI,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE;YACtB,OAAO,CAAC,CAAC;SACV;QAED,OAAO,IAAA,oBAAO,EACZ,8CAA8C,EAC9C,CAAC,GAAG,MAAM,EACV,uBAAuB,CAAC,CAAC,CAAC,CAC3B,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC;AAdD,kCAcC"} | ||||
							
								
								
									
										6
									
								
								node_modules/ip-address/dist/v6/regular-expressions.d.ts
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								node_modules/ip-address/dist/v6/regular-expressions.d.ts
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,6 @@ | |||
| export declare function groupPossibilities(possibilities: string[]): string; | ||||
| export declare function padGroup(group: string): string; | ||||
| export declare const ADDRESS_BOUNDARY = "[^A-Fa-f0-9:]"; | ||||
| export declare function simpleRegularExpression(groups: string[]): string; | ||||
| export declare function possibleElisions(elidedGroups: number, moreLeft?: boolean, moreRight?: boolean): string; | ||||
| //# sourceMappingURL=regular-expressions.d.ts.map
 | ||||
							
								
								
									
										1
									
								
								node_modules/ip-address/dist/v6/regular-expressions.d.ts.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								node_modules/ip-address/dist/v6/regular-expressions.d.ts.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1 @@ | |||
| {"version":3,"file":"regular-expressions.d.ts","sourceRoot":"","sources":["../../src/v6/regular-expressions.ts"],"names":[],"mappings":"AAGA,wBAAgB,kBAAkB,CAAC,aAAa,EAAE,MAAM,EAAE,GAAG,MAAM,CAElE;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAM9C;AAED,eAAO,MAAM,gBAAgB,kBAAkB,CAAC;AAEhD,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,MAAM,EAAE,UA+BvD;AAED,wBAAgB,gBAAgB,CAC9B,YAAY,EAAE,MAAM,EACpB,QAAQ,CAAC,EAAE,OAAO,EAClB,SAAS,CAAC,EAAE,OAAO,GAClB,MAAM,CA4CR"} | ||||
							
								
								
									
										96
									
								
								node_modules/ip-address/dist/v6/regular-expressions.js
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										96
									
								
								node_modules/ip-address/dist/v6/regular-expressions.js
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,96 @@ | |||
| "use strict"; | ||||
| var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||||
|     if (k2 === undefined) k2 = k; | ||||
|     var desc = Object.getOwnPropertyDescriptor(m, k); | ||||
|     if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||||
|       desc = { enumerable: true, get: function() { return m[k]; } }; | ||||
|     } | ||||
|     Object.defineProperty(o, k2, desc); | ||||
| }) : (function(o, m, k, k2) { | ||||
|     if (k2 === undefined) k2 = k; | ||||
|     o[k2] = m[k]; | ||||
| })); | ||||
| var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { | ||||
|     Object.defineProperty(o, "default", { enumerable: true, value: v }); | ||||
| }) : function(o, v) { | ||||
|     o["default"] = v; | ||||
| }); | ||||
| var __importStar = (this && this.__importStar) || function (mod) { | ||||
|     if (mod && mod.__esModule) return mod; | ||||
|     var result = {}; | ||||
|     if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); | ||||
|     __setModuleDefault(result, mod); | ||||
|     return result; | ||||
| }; | ||||
| Object.defineProperty(exports, "__esModule", { value: true }); | ||||
| exports.possibleElisions = exports.simpleRegularExpression = exports.ADDRESS_BOUNDARY = exports.padGroup = exports.groupPossibilities = void 0; | ||||
| const v6 = __importStar(require("./constants")); | ||||
| const sprintf_js_1 = require("sprintf-js"); | ||||
| function groupPossibilities(possibilities) { | ||||
|     return (0, sprintf_js_1.sprintf)('(%s)', possibilities.join('|')); | ||||
| } | ||||
| exports.groupPossibilities = groupPossibilities; | ||||
| function padGroup(group) { | ||||
|     if (group.length < 4) { | ||||
|         return (0, sprintf_js_1.sprintf)('0{0,%d}%s', 4 - group.length, group); | ||||
|     } | ||||
|     return group; | ||||
| } | ||||
| exports.padGroup = padGroup; | ||||
| exports.ADDRESS_BOUNDARY = '[^A-Fa-f0-9:]'; | ||||
| function simpleRegularExpression(groups) { | ||||
|     const zeroIndexes = []; | ||||
|     groups.forEach((group, i) => { | ||||
|         const groupInteger = parseInt(group, 16); | ||||
|         if (groupInteger === 0) { | ||||
|             zeroIndexes.push(i); | ||||
|         } | ||||
|     }); | ||||
|     // You can technically elide a single 0, this creates the regular expressions
 | ||||
|     // to match that eventuality
 | ||||
|     const possibilities = zeroIndexes.map((zeroIndex) => groups | ||||
|         .map((group, i) => { | ||||
|         if (i === zeroIndex) { | ||||
|             const elision = i === 0 || i === v6.GROUPS - 1 ? ':' : ''; | ||||
|             return groupPossibilities([padGroup(group), elision]); | ||||
|         } | ||||
|         return padGroup(group); | ||||
|     }) | ||||
|         .join(':')); | ||||
|     // The simplest case
 | ||||
|     possibilities.push(groups.map(padGroup).join(':')); | ||||
|     return groupPossibilities(possibilities); | ||||
| } | ||||
| exports.simpleRegularExpression = simpleRegularExpression; | ||||
| function possibleElisions(elidedGroups, moreLeft, moreRight) { | ||||
|     const left = moreLeft ? '' : ':'; | ||||
|     const right = moreRight ? '' : ':'; | ||||
|     const possibilities = []; | ||||
|     // 1. elision of everything (::)
 | ||||
|     if (!moreLeft && !moreRight) { | ||||
|         possibilities.push('::'); | ||||
|     } | ||||
|     // 2. complete elision of the middle
 | ||||
|     if (moreLeft && moreRight) { | ||||
|         possibilities.push(''); | ||||
|     } | ||||
|     if ((moreRight && !moreLeft) || (!moreRight && moreLeft)) { | ||||
|         // 3. complete elision of one side
 | ||||
|         possibilities.push(':'); | ||||
|     } | ||||
|     // 4. elision from the left side
 | ||||
|     possibilities.push((0, sprintf_js_1.sprintf)('%s(:0{1,4}){1,%d}', left, elidedGroups - 1)); | ||||
|     // 5. elision from the right side
 | ||||
|     possibilities.push((0, sprintf_js_1.sprintf)('(0{1,4}:){1,%d}%s', elidedGroups - 1, right)); | ||||
|     // 6. no elision
 | ||||
|     possibilities.push((0, sprintf_js_1.sprintf)('(0{1,4}:){%d}0{1,4}', elidedGroups - 1)); | ||||
|     // 7. elision (including sloppy elision) from the middle
 | ||||
|     for (let groups = 1; groups < elidedGroups - 1; groups++) { | ||||
|         for (let position = 1; position < elidedGroups - groups; position++) { | ||||
|             possibilities.push((0, sprintf_js_1.sprintf)('(0{1,4}:){%d}:(0{1,4}:){%d}0{1,4}', position, elidedGroups - position - groups - 1)); | ||||
|         } | ||||
|     } | ||||
|     return groupPossibilities(possibilities); | ||||
| } | ||||
| exports.possibleElisions = possibleElisions; | ||||
| //# sourceMappingURL=regular-expressions.js.map
 | ||||
							
								
								
									
										1
									
								
								node_modules/ip-address/dist/v6/regular-expressions.js.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								node_modules/ip-address/dist/v6/regular-expressions.js.map
									
										
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1 @@ | |||
| {"version":3,"file":"regular-expressions.js","sourceRoot":"","sources":["../../src/v6/regular-expressions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,gDAAkC;AAClC,2CAAqC;AAErC,SAAgB,kBAAkB,CAAC,aAAuB;IACxD,OAAO,IAAA,oBAAO,EAAC,MAAM,E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