//#region ../types/src/api/api.d.ts /** * **ValueCallback**`` * * A type utility to build a simple "value callback". * * ```ts * // (v: V) => `hi ${string}`; * type T = ValueCallback; * ``` */ type ValueCallback = (v: V) => TReturn; //#endregion //#region ../constants/src/Alpha.d.ts /** * An array of all the lower-cased alphabetic characters */ declare const LOWER_ALPHA_CHARS: ["a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z"]; /** * An array of all the upper-cased alphabetic characters */ declare const UPPER_ALPHA_CHARS: ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z"]; //#endregion //#region ../constants/src/Characters.d.ts declare const WHITESPACE_CHARS: readonly [" ", "\n", "\t", "\b"]; //#endregion //#region ../constants/src/colors.d.ts declare const CSS_NAMED_COLORS: ["aliceblue", "antiquewhite", "aqua", "aquamarine", "azure", "beige", "bisque", "black", "blanchedalmond", "blue", "blueviolet", "brown", "burlywood", "cadetblue", "chartreuse", "chocolate", "coral", "cornflowerblue", "cornsilk", "crimson", "cyan", "darkblue", "darkcyan", "darkgoldenrod", "darkgray", "darkgreen", "darkgrey", "darkkhaki", "darkmagenta", "darkolivegreen", "darkorange", "darkorchid", "darkred", "darksalmon", "darkseagreen", "darkslateblue", "darkslategray", "darkslategrey", "darkturquoise", "darkviolet", "deeppink", "deepskyblue", "dimgray", "dimgrey", "dodgerblue", "firebrick", "floralwhite", "forestgreen", "fuchsia", "gainsboro", "ghostwhite", "gold", "goldenrod", "gray", "green", "greenyellow", "grey", "honeydew", "hotpink", "indianred", "indigo", "ivory", "khaki", "lavender", "lavenderblush", "lawngreen", "lemonchiffon", "lightblue", "lightcoral", "lightcyan", "lightgoldenrodyellow", "lightgray", "lightgreen", "lightgrey", "lightpink", "lightsalmon", "lightseagreen", "lightskyblue", "lightslategray", "lightslategrey", "lightsteelblue", "lightyellow", "lime", "limegreen", "linen", "magenta", "maroon", "mediumaquamarine", "mediumblue", "mediumorchid", "mediumpurple", "mediumseagreen", "mediumslateblue", "mediumspringgreen", "mediumturquoise", "mediumvioletred", "midnightblue", "mintcream", "mistyrose", "moccasin", "navajowhite", "navy", "oldlace", "olive", "olivedrab", "orange", "orangered", "orchid", "palegoldenrod", "palegreen", "paleturquoise", "palevioletred", "papayawhip", "peachpuff", "peru", "pink", "plum", "powderblue", "purple", "rebeccapurple", "red", "rosybrown", "royalblue", "saddlebrown", "salmon", "sandybrown", "seagreen", "seashell", "sienna", "silver", "skyblue", "slateblue", "slategray", "slategrey", "snow", "springgreen", "steelblue", "tan", "teal", "thistle", "tomato", "turquoise", "violet", "wheat", "white", "whitesmoke", "yellow", "yellowgreen"]; declare const CSS_COLOR_LOOKUP: { aliceblue: "rgb(240,248,255)"; antiquewhite: "rgb(250,235,215)"; aqua: "rgb(0,255,255)"; aquamarine: "rgb(127,255,212)"; azure: "rgb(240,255,255)"; beige: "rgb(245,245,220)"; bisque: "rgb(255,228,196)"; black: "rgb(0,0,0)"; blanchedalmond: "rgb(255,235,205)"; blue: "rgb(0,0,255)"; blueviolet: "rgb(138,43,226)"; brown: "rgb(165,42,42)"; burlywood: "rgb(222,184,135)"; cadetblue: "rgb(95,158,160)"; chartreuse: "rgb(127,255,0)"; chocolate: "rgb(210,105,30)"; coral: "rgb(255,127,80)"; cornflowerblue: "rgb(100,149,237)"; cornsilk: "rgb(255,248,220)"; crimson: "rgb(220,20,60)"; cyan: "rgb(0,255,255)"; darkblue: "rgb(0,0,139)"; darkcyan: "rgb(0,139,139)"; darkgoldenrod: "rgb(184,134,11)"; darkgray: "rgb(169,169,169)"; darkgreen: "rgb(0,100,0)"; darkgrey: "rgb(169,169,169)"; darkkhaki: "rgb(189,183,107)"; darkmagenta: "rgb(139,0,139)"; darkolivegreen: "rgb(85,107,47)"; darkorange: "rgb(255,140,0)"; darkorchid: "rgb(153,50,204)"; darkred: "rgb(139,0,0)"; darksalmon: "rgb(233,150,122)"; darkseagreen: "rgb(143,188,143)"; darkslateblue: "rgb(72,61,139)"; darkslategray: "rgb(47,79,79)"; darkslategrey: "rgb(47,79,79)"; darkturquoise: "rgb(0,206,209)"; darkviolet: "rgb(148,0,211)"; deeppink: "rgb(255,20,147)"; deepskyblue: "rgb(0,191,255)"; dimgray: "rgb(105,105,105)"; dimgrey: "rgb(105,105,105)"; dodgerblue: "rgb(30,144,255)"; firebrick: "rgb(178,34,34)"; floralwhite: "rgb(255,250,240)"; forestgreen: "rgb(34,139,34)"; fuchsia: "rgb(255,0,255)"; gainsboro: "rgb(220,220,220)"; ghostwhite: "rgb(248,248,255)"; gold: "rgb(255,215,0)"; goldenrod: "rgb(218,165,32)"; gray: "rgb(128,128,128)"; green: "rgb(0,128,0)"; greenyellow: "rgb(173,255,47)"; grey: "rgb(128,128,128)"; honeydew: "rgb(240,255,240)"; hotpink: "rgb(255,105,180)"; indianred: "rgb(205,92,92)"; indigo: "rgb(75,0,130)"; ivory: "rgb(255,255,240)"; khaki: "rgb(240,230,140)"; lavender: "rgb(230,230,250)"; lavenderblush: "rgb(255,240,245)"; lawngreen: "rgb(124,252,0)"; lemonchiffon: "rgb(255,250,205)"; lightblue: "rgb(173,216,230)"; lightcoral: "rgb(240,128,128)"; lightcyan: "rgb(224,255,255)"; lightgoldenrodyellow: "rgb(250,250,210)"; lightgray: "rgb(211,211,211)"; lightgreen: "rgb(144,238,144)"; lightgrey: "rgb(211,211,211)"; lightpink: "rgb(255,182,193)"; lightsalmon: "rgb(255,160,122)"; lightseagreen: "rgb(32,178,170)"; lightskyblue: "rgb(135,206,250)"; lightslategray: "rgb(119,136,153)"; lightslategrey: "rgb(119,136,153)"; lightsteelblue: "rgb(176,196,222)"; lightyellow: "rgb(255,255,224)"; lime: "rgb(0,255,0)"; limegreen: "rgb(50,205,50)"; linen: "rgb(250,240,230)"; magenta: "rgb(255,0,255)"; maroon: "rgb(128,0,0)"; mediumaquamarine: "rgb(102,205,170)"; mediumblue: "rgb(0,0,205)"; mediumorchid: "rgb(186,85,211)"; mediumpurple: "rgb(147,112,219)"; mediumseagreen: "rgb(60,179,113)"; mediumslateblue: "rgb(123,104,238)"; mediumspringgreen: "rgb(0,250,154)"; mediumturquoise: "rgb(72,209,204)"; mediumvioletred: "rgb(199,21,133)"; midnightblue: "rgb(25,25,112)"; mintcream: "rgb(245,255,250)"; mistyrose: "rgb(255,228,225)"; moccasin: "rgb(255,228,181)"; navajowhite: "rgb(255,222,173)"; navy: "rgb(0,0,128)"; oldlace: "rgb(253,245,230)"; olive: "rgb(128,128,0)"; olivedrab: "rgb(107,142,35)"; orange: "rgb(255,165,0)"; orangered: "rgb(255,69,0)"; orchid: "rgb(218,112,214)"; palegoldenrod: "rgb(238,232,170)"; palegreen: "rgb(152,251,152)"; paleturquoise: "rgb(175,238,238)"; palevioletred: "rgb(219,112,147)"; papayawhip: "rgb(255,239,213)"; peachpuff: "rgb(255,218,185)"; peru: "rgb(205,133,63)"; pink: "rgb(255,192,203)"; plum: "rgb(221,160,221)"; powderblue: "rgb(176,224,230)"; purple: "rgb(128,0,128)"; rebeccapurple: "rgb(102,51,153)"; red: "rgb(255,0,0)"; rosybrown: "rgb(188,143,143)"; royalblue: "rgb(65,105,225)"; saddlebrown: "rgb(139,69,19)"; salmon: "rgb(250,128,114)"; sandybrown: "rgb(244,164,96)"; seagreen: "rgb(46,139,87)"; seashell: "rgb(255,245,238)"; sienna: "rgb(160,82,45)"; silver: "rgb(192,192,192)"; skyblue: "rgb(135,206,235)"; slateblue: "rgb(106,90,205)"; slategray: "rgb(112,128,144)"; slategrey: "rgb(112,128,144)"; snow: "rgb(255,250,250)"; springgreen: "rgb(0,255,127)"; steelblue: "rgb(70,130,180)"; tan: "rgb(210,180,140)"; teal: "rgb(0,128,128)"; thistle: "rgb(216,191,216)"; tomato: "rgb(255,99,71)"; turquoise: "rgb(64,224,208)"; violet: "rgb(238,130,238)"; wheat: "rgb(245,222,179)"; white: "rgb(255,255,255)"; whitesmoke: "rgb(245,245,245)"; yellow: "rgb(255,255,0)"; yellowgreen: "rgb(154,205,50)"; }; //#endregion //#region ../constants/src/Comparisons.d.ts declare const COMPARISON_OPERATIONS: readonly ["extends", "startsWith", "endsWith", "endsWithNumber", "startsWithNumber", "onlyNumbers", "alphaNumeric", "onlyLetters", "contains", "containsSome", "containsAll", "greaterThan", "greaterThanOrEqual", "lessThan", "lessThanOrEqual", "objectKeyGreaterThan", "objectKeyGreaterThanOrEqual", "objectKeyLessThan", "objectKeyLessThanOrEqual", "objectKeyEquals", "objectKeyExtends", "objectKeyStartsWith", "betweenInclusively", "betweenExclusively", "equals", "equalsSome", "errors", "errorsOfType", "before", "after", "sameDay", "sameMonth", "sameMonthYear", "sameYear", "truthy", "falsy", "true", "false", "returnEquals", "returnExtends", "isTemplateLiteral", "hasLength"]; //#endregion //#region ../constants/src/Constant.d.ts /** * **Constant**`` * * A static value of a particular _kind_. */ interface Constant { _type: "Constant"; kind: TKind; value: TVal; } //#endregion //#region ../constants/src/DateTime.d.ts /** * **MONTH_NAME** * * Full month names. */ declare const MONTH_NAME: readonly ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"]; /** * **MONTH_ABBR** * * Abbreviated month names. */ declare const MONTH_ABBR: readonly ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]; declare const MONTH_NAME_LOOKUP: { readonly January: { readonly abbrev: "Jan"; readonly num: 1; readonly twoDigitStr: "01"; }; readonly February: { readonly abbrev: "Feb"; readonly num: 2; readonly twoDigitStr: "02"; }; readonly March: { readonly abbrev: "Mar"; readonly num: 3; readonly twoDigitStr: "03"; }; readonly April: { readonly abbrev: "Apr"; readonly num: 4; readonly twoDigitStr: "04"; }; readonly May: { readonly abbrev: "May"; readonly num: 5; readonly twoDigitStr: "05"; }; readonly June: { readonly abbrev: "Jun"; readonly num: 6; readonly twoDigitStr: "06"; }; readonly July: { readonly abbrev: "Jul"; readonly num: 7; readonly twoDigitStr: "07"; }; readonly August: { readonly abbrev: "Aug"; readonly num: 8; readonly twoDigitStr: "08"; }; readonly September: { readonly abbrev: "Sep"; readonly num: 9; readonly twoDigitStr: "09"; }; readonly October: { readonly abbrev: "Oct"; readonly num: 10; readonly twoDigitStr: "10"; }; readonly November: { readonly abbrev: "Nov"; readonly num: 11; readonly twoDigitStr: "11"; }; readonly December: { readonly abbrev: "Dec"; readonly num: 12; readonly twoDigitStr: "12"; }; }; declare const MONTH_ABBREV_LOOKUP: { readonly Jan: { readonly name: "January"; readonly num: 1; readonly twoDigitStr: "01"; }; readonly Feb: { readonly name: "February"; readonly num: 2; readonly twoDigitStr: "02"; }; readonly Mar: { readonly name: "March"; readonly num: 3; readonly twoDigitStr: "03"; }; readonly Apr: { readonly name: "April"; readonly num: 4; readonly twoDigitStr: "04"; }; readonly May: { readonly name: "May"; readonly num: 5; readonly twoDigitStr: "05"; }; readonly Jun: { readonly name: "June"; readonly num: 6; readonly twoDigitStr: "06"; }; readonly Jul: { readonly name: "July"; readonly num: 7; readonly twoDigitStr: "07"; }; readonly Aug: { readonly name: "August"; readonly num: 8; readonly twoDigitStr: "08"; }; readonly Sep: { readonly name: "September"; readonly num: 9; readonly twoDigitStr: "09"; }; readonly Oct: { readonly name: "October"; readonly num: 10; readonly twoDigitStr: "10"; }; readonly Nov: { readonly name: "November"; readonly num: 11; readonly twoDigitStr: "11"; }; readonly Dec: { readonly name: "December"; readonly num: 12; readonly twoDigitStr: "12"; }; }; /** the seasons in a year */ declare const SEASONS: readonly ["Summer", "Spring", "Fall", "Winter"]; type Season$1 = typeof SEASONS[number]; type MonthAbbr = typeof MONTH_ABBR[number]; type Hemisphere$1 = "northern" | "southern"; /** * Maps each season to the months which represent that season (by * hemisphere). */ declare const MONTH_TO_SEASON_LOOKUP: Record>; declare const DATE_TYPE: readonly ["datetime", "date", "year-independent", "year-month", "year"]; /** * months with 30 days */ declare const ISO_DATE_30: readonly ["04", "06", "09", "11"]; //#endregion //#region ../constants/src/DoubleLeap_Typical.d.ts /** * Double Leap Years for modern times (1400-2300) */ declare const DOUBLE_LEAP_MODERN: readonly [1408, 1416, 1444, 1452, 1460, 1468, 1476, 1484, 1492, 1520, 1528, 1536, 1544, 1552, 1560, 1568, 1596, 1604, 1612, 1620, 1628, 1636, 1644, 1672, 1680, 1688, 1696, 1704, 1712, 1720, 1748, 1756, 1764, 1772, 1780, 1788, 1796, 1824, 1832, 1840, 1848, 1856, 1864, 1872, 1908, 1916, 1924, 1932, 1940, 1948, 1976, 1984, 1992, 2000, 2008, 2016, 2024, 2052, 2060, 2068, 2076, 2084, 2092, 2128, 2136, 2144, 2152, 2160, 2168, 2176, 2204, 2212, 2220, 2228, 2236, 2244, 2252, 2280, 2288, 2296]; //#endregion //#region ../constants/src/EscapeCodes.d.ts /** * Escape Code Characters * * Includes: * - `ESCAPE_CODE`, * - `BEL`, * - `NON_BREAKING_SPACE`, * - `LINE_FEED`, * - `FORM_FEED`, * - `HORIZONTAL_TAB`, * - `CARRIAGE_RETURN`, * - `FILE_SEPARATOR` * - `GROUP_SEPARATOR`, * - `RECORD_SEPARATOR`, * - `UNIT_SEPARATOR`, * - `NULL_CHAR`, * - Unicode _space_ characters with differing widths/behaviors * - _and more_ */ declare const ESCAPE_CODE_CHARS: ["\u001B", "\u0007", "\b", "\t", "\n", "\r", "\v", "\f", "\0", "", "\u001C", "\u001D", "\u001E", "\u001F", " ", " ", " ", " ", " ", " ", " "]; //#endregion //#region ../constants/src/Geo.d.ts declare const HEMISPHERE: readonly ["northern", "southern"]; /** * The 9 provinces to the US which are granted State codes. */ declare const US_STATE_LOOKUP_PROVINCES: readonly [{ readonly name: "Puerto Rico"; readonly abbrev: "PR"; }, { readonly name: "Virgin Islands"; readonly abbrev: "VI"; }, { readonly name: "Palau"; readonly abbrev: "PW"; }, { readonly name: "Federated States of Micronesia"; readonly abbrev: "FM"; }, { readonly name: "Northern Mariana Islands"; readonly abbrev: "MP"; }, { readonly name: "District of Columbia"; readonly abbrev: "DC"; }, { readonly name: "Marshall Islands"; readonly abbrev: "MH"; }, { readonly name: "American Samoa"; readonly abbrev: "AS"; }, { readonly name: "Guam"; readonly abbrev: "GU"; }]; /** * All 50 states and 9 provinces which have State abbreviations. * * Data format is: `[name, abbrev, flag]` where the boolean flag * indicates whether the line item is one of the 50 true states. */ declare const US_STATE_LOOKUP: readonly [{ readonly name: "Alabama"; readonly abbrev: "AL"; }, { readonly name: "Alaska"; readonly abbrev: "AK"; }, { readonly name: "Arizona"; readonly abbrev: "AZ"; }, { readonly name: "Arkansas"; readonly abbrev: "AR"; }, { readonly name: "California"; readonly abbrev: "CA"; }, { readonly name: "Colorado"; readonly abbrev: "CO"; }, { readonly name: "Connecticut"; readonly abbrev: "CT"; }, { readonly name: "Delaware"; readonly abbrev: "DE"; }, { readonly name: "Florida"; readonly abbrev: "FL"; }, { readonly name: "Georgia"; readonly abbrev: "GA"; }, { readonly name: "Hawaii"; readonly abbrev: "HI"; }, { readonly name: "Idaho"; readonly abbrev: "ID"; }, { readonly name: "Illinois"; readonly abbrev: "IL"; }, { readonly name: "Indiana"; readonly abbrev: "IN"; }, { readonly name: "Iowa"; readonly abbrev: "IA"; }, { readonly name: "Kansas"; readonly abbrev: "KS"; }, { readonly name: "Kentucky"; readonly abbrev: "KY"; }, { readonly name: "Louisiana"; readonly abbrev: "LA"; }, { readonly name: "Maine"; readonly abbrev: "ME"; }, { readonly name: "Maryland"; readonly abbrev: "MD"; }, { readonly name: "Massachusetts"; readonly abbrev: "MA"; }, { readonly name: "Michigan"; readonly abbrev: "MI"; }, { readonly name: "Minnesota"; readonly abbrev: "MN"; }, { readonly name: "Mississippi"; readonly abbrev: "MS"; }, { readonly name: "Missouri"; readonly abbrev: "MO"; }, { readonly name: "Montana"; readonly abbrev: "MT"; }, { readonly name: "Nebraska"; readonly abbrev: "NE"; }, { readonly name: "Nevada"; readonly abbrev: "NV"; }, { readonly name: "New Hampshire"; readonly abbrev: "NH"; }, { readonly name: "New Jersey"; readonly abbrev: "NJ"; }, { readonly name: "New Mexico"; readonly abbrev: "NM"; }, { readonly name: "New York"; readonly abbrev: "NY"; }, { readonly name: "North Carolina"; readonly abbrev: "NC"; }, { readonly name: "North Dakota"; readonly abbrev: "ND"; }, { readonly name: "Ohio"; readonly abbrev: "OH"; }, { readonly name: "Oklahoma"; readonly abbrev: "OK"; }, { readonly name: "Oregon"; readonly abbrev: "OR"; }, { readonly name: "Pennsylvania"; readonly abbrev: "PA"; }, { readonly name: "Rhode Island"; readonly abbrev: "RI"; }, { readonly name: "South Carolina"; readonly abbrev: "SC"; }, { readonly name: "South Dakota"; readonly abbrev: "SD"; }, { readonly name: "Tennessee"; readonly abbrev: "TN"; }, { readonly name: "Texas"; readonly abbrev: "TX"; }, { readonly name: "Utah"; readonly abbrev: "UT"; }, { readonly name: "Vermont"; readonly abbrev: "VT"; }, { readonly name: "Virginia"; readonly abbrev: "VA"; }, { readonly name: "Washington"; readonly abbrev: "WA"; }, { readonly name: "West Virginia"; readonly abbrev: "WV"; }, { readonly name: "Wisconsin"; readonly abbrev: "WI"; }, { readonly name: "Wyoming"; readonly abbrev: "WY"; }, { readonly name: "Puerto Rico"; readonly abbrev: "PR"; }, { readonly name: "Virgin Islands"; readonly abbrev: "VI"; }, { readonly name: "Palau"; readonly abbrev: "PW"; }, { readonly name: "Federated States of Micronesia"; readonly abbrev: "FM"; }, { readonly name: "Northern Mariana Islands"; readonly abbrev: "MP"; }, { readonly name: "District of Columbia"; readonly abbrev: "DC"; }, { readonly name: "Marshall Islands"; readonly abbrev: "MH"; }, { readonly name: "American Samoa"; readonly abbrev: "AS"; }, { readonly name: "Guam"; readonly abbrev: "GU"; }]; //#endregion //#region ../constants/src/HTML.d.ts /** * An array of all valid HTML tags that have both opening and closing tags. */ declare const HTML_BLOCK_TAGS: readonly ["a", "abbr", "address", "article", "aside", "b", "bdi", "bdo", "blockquote", "body", "button", "canvas", "caption", "cite", "code", "colgroup", "data", "datalist", "dd", "del", "details", "dfn", "dialog", "div", "dl", "dt", "em", "fieldset", "figcaption", "figure", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "html", "i", "iframe", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "menu", "meter", "nav", "noscript", "object", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "script", "section", "select", "small", "span", "strong", "style", "sub", "summary", "sup", "svg", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "title", "tr", "u", "ul", "var", "video"]; /** * An array of all valid HTML tags that are self-closing (do not have closing tags). */ declare const HTML_ATOMIC_TAGS: readonly ["area", "base", "br", "col", "embed", "hr", "img", "input", "link", "meta", "param", "source", "track", "wbr"]; //#endregion //#region ../constants/src/ISO3166.d.ts /** * All country codes (name, alpha-2, country-code) */ declare const ISO3166_1: readonly [{ readonly name: "Afghanistan"; readonly alpha2: "AF"; readonly countryCode: "004"; readonly alpha3: "AFG"; }, { readonly name: "Albania"; readonly alpha2: "AL"; readonly countryCode: "008"; readonly alpha3: "ALB"; }, { readonly name: "Algeria"; readonly alpha2: "DZ"; readonly countryCode: "012"; readonly alpha3: "DZA"; }, { readonly name: "Andorra"; readonly alpha2: "AD"; readonly countryCode: "020"; readonly alpha3: "AND"; }, { readonly name: "Angola"; readonly alpha2: "AO"; readonly countryCode: "024"; readonly alpha3: "AGO"; }, { readonly name: "Argentina"; readonly alpha2: "AR"; readonly countryCode: "032"; readonly alpha3: "ARG"; }, { readonly name: "Australia"; readonly alpha2: "AU"; readonly countryCode: "036"; readonly alpha3: "AUS"; }, { readonly name: "Austria"; readonly alpha2: "AT"; readonly countryCode: "040"; readonly alpha3: "AUT"; }, { readonly name: "Azerbaijan"; readonly alpha2: "AZ"; readonly countryCode: "031"; readonly alpha3: "AZE"; }, { readonly name: "Bahamas"; readonly alpha2: "BS"; readonly countryCode: "044"; readonly alpha3: "BHS"; }, { readonly name: "Bangladesh"; readonly alpha2: "BD"; readonly countryCode: "050"; readonly alpha3: "BGD"; }, { readonly name: "Belgium"; readonly alpha2: "BE"; readonly countryCode: "056"; readonly alpha3: "BEL"; }, { readonly name: "Belize"; readonly alpha2: "BZ"; readonly countryCode: "084"; readonly alpha3: "BLZ"; }, { readonly name: "Benin"; readonly alpha2: "BJ"; readonly countryCode: "204"; readonly alpha3: "BEN"; }, { readonly name: "Bhutan"; readonly alpha2: "BT"; readonly countryCode: "064"; readonly alpha3: "BTN"; }, { readonly name: "Bolivia"; readonly alpha2: "BO"; readonly countryCode: "068"; readonly alpha3: "BOL"; }, { readonly name: "Bosnia and Herzegovina"; readonly alpha2: "BA"; readonly countryCode: "070"; readonly alpha3: "BIH"; }, { readonly name: "Botswana"; readonly alpha2: "BW"; readonly countryCode: "072"; readonly alpha3: "BWA"; }, { readonly name: "Brazil"; readonly alpha2: "BR"; readonly countryCode: "076"; readonly alpha3: "BRA"; }, { readonly name: "Brunei Darussalam"; readonly alpha2: "BN"; readonly countryCode: "096"; readonly alpha3: "BRN"; }, { readonly name: "Bulgaria"; readonly alpha2: "BG"; readonly countryCode: "100"; readonly alpha3: "BGR"; }, { readonly name: "Burkina Faso"; readonly alpha2: "BF"; readonly countryCode: "854"; readonly alpha3: "BFA"; }, { readonly name: "Burundi"; readonly alpha2: "BI"; readonly countryCode: "108"; readonly alpha3: "BDI"; }, { readonly name: "Cambodia"; readonly alpha2: "KH"; readonly countryCode: "116"; readonly alpha3: "KHM"; }, { readonly name: "Cameroon"; readonly alpha2: "CM"; readonly countryCode: "120"; readonly alpha3: "CMR"; }, { readonly name: "Canada"; readonly alpha2: "CA"; readonly countryCode: "124"; readonly alpha3: "CAN"; }, { readonly name: "Afghanistan"; readonly alpha2: "AF"; readonly countryCode: "004"; readonly alpha3: "AFG"; }, { readonly name: "Albania"; readonly alpha2: "AL"; readonly countryCode: "008"; readonly alpha3: "ALB"; }, { readonly name: "Algeria"; readonly alpha2: "DZ"; readonly countryCode: "012"; readonly alpha3: "DZA"; }, { readonly name: "Andorra"; readonly alpha2: "AD"; readonly countryCode: "020"; readonly alpha3: "AND"; }, { readonly name: "Angola"; readonly alpha2: "AO"; readonly countryCode: "024"; readonly alpha3: "AGO"; }, { readonly name: "Argentina"; readonly alpha2: "AR"; readonly countryCode: "032"; readonly alpha3: "ARG"; }, { readonly name: "Australia"; readonly alpha2: "AU"; readonly countryCode: "036"; readonly alpha3: "AUS"; }, { readonly name: "Austria"; readonly alpha2: "AT"; readonly countryCode: "040"; readonly alpha3: "AUT"; }, { readonly name: "Azerbaijan"; readonly alpha2: "AZ"; readonly countryCode: "031"; readonly alpha3: "AZE"; }, { readonly name: "Bahamas"; readonly alpha2: "BS"; readonly countryCode: "044"; readonly alpha3: "BHS"; }, { readonly name: "Bangladesh"; readonly alpha2: "BD"; readonly countryCode: "050"; readonly alpha3: "BGD"; }, { readonly name: "Belgium"; readonly alpha2: "BE"; readonly countryCode: "056"; readonly alpha3: "BEL"; }, { readonly name: "Belize"; readonly alpha2: "BZ"; readonly countryCode: "084"; readonly alpha3: "BLZ"; }, { readonly name: "Benin"; readonly alpha2: "BJ"; readonly countryCode: "204"; readonly alpha3: "BEN"; }, { readonly name: "Bhutan"; readonly alpha2: "BT"; readonly countryCode: "064"; readonly alpha3: "BTN"; }, { readonly name: "Bolivia"; readonly alpha2: "BO"; readonly countryCode: "068"; readonly alpha3: "BOL"; }, { readonly name: "Bosnia and Herzegovina"; readonly alpha2: "BA"; readonly countryCode: "070"; readonly alpha3: "BIH"; }, { readonly name: "Botswana"; readonly alpha2: "BW"; readonly countryCode: "072"; readonly alpha3: "BWA"; }, { readonly name: "Brazil"; readonly alpha2: "BR"; readonly countryCode: "076"; readonly alpha3: "BRA"; }, { readonly name: "Brunei Darussalam"; readonly alpha2: "BN"; readonly countryCode: "096"; readonly alpha3: "BRN"; }, { readonly name: "Bulgaria"; readonly alpha2: "BG"; readonly countryCode: "100"; readonly alpha3: "BGR"; }, { readonly name: "Burkina Faso"; readonly alpha2: "BF"; readonly countryCode: "854"; readonly alpha3: "BFA"; }, { readonly name: "Burundi"; readonly alpha2: "BI"; readonly countryCode: "108"; readonly alpha3: "BDI"; }, { readonly name: "Cambodia"; readonly alpha2: "KH"; readonly countryCode: "116"; readonly alpha3: "KHM"; }, { readonly name: "Cameroon"; readonly alpha2: "CM"; readonly countryCode: "120"; readonly alpha3: "CMR"; }, { readonly name: "Canada"; readonly alpha2: "CA"; readonly countryCode: "124"; readonly alpha3: "CAN"; }, { readonly name: "Maldives"; readonly alpha2: "MV"; readonly countryCode: "462"; readonly alpha3: "MDV"; }, { readonly name: "Mali"; readonly alpha2: "ML"; readonly countryCode: "466"; readonly alpha3: "MLI"; }, { readonly name: "Malta"; readonly alpha2: "MT"; readonly countryCode: "470"; readonly alpha3: "MLT"; }, { readonly name: "Marshall Islands"; readonly alpha2: "MH"; readonly countryCode: "584"; readonly alpha3: "MHL"; }, { readonly name: "Mauritania"; readonly alpha2: "MR"; readonly countryCode: "478"; readonly alpha3: "MRT"; }, { readonly name: "Mauritius"; readonly alpha2: "MU"; readonly countryCode: "480"; readonly alpha3: "MUS"; }, { readonly name: "Mexico"; readonly alpha2: "MX"; readonly countryCode: "484"; readonly alpha3: "MEX"; }, { readonly name: "Micronesia (Federated States of)"; readonly alpha2: "FM"; readonly countryCode: "583"; readonly alpha3: "FSM"; }, { readonly name: "Moldova (Republic of)"; readonly alpha2: "MD"; readonly countryCode: "498"; readonly alpha3: "MDA"; }, { readonly name: "Monaco"; readonly alpha2: "MC"; readonly countryCode: "492"; readonly alpha3: "MCO"; }, { readonly name: "Mongolia"; readonly alpha2: "MN"; readonly countryCode: "496"; readonly alpha3: "MNG"; }, { readonly name: "Montenegro"; readonly alpha2: "ME"; readonly countryCode: "499"; readonly alpha3: "MNE"; }, { readonly name: "Morocco"; readonly alpha2: "MA"; readonly countryCode: "504"; readonly alpha3: "MAR"; }, { readonly name: "Mozambique"; readonly alpha2: "MZ"; readonly countryCode: "508"; readonly alpha3: "MOZ"; }, { readonly name: "Myanmar"; readonly alpha2: "MM"; readonly countryCode: "104"; readonly alpha3: "MMR"; }, { readonly name: "Namibia"; readonly alpha2: "NA"; readonly countryCode: "516"; readonly alpha3: "NAM"; }, { readonly name: "Nauru"; readonly alpha2: "NR"; readonly countryCode: "520"; readonly alpha3: "NRU"; }, { readonly name: "Nepal"; readonly alpha2: "NP"; readonly countryCode: "524"; readonly alpha3: "NPL"; }, { readonly name: "Netherlands"; readonly alpha2: "NL"; readonly countryCode: "528"; readonly alpha3: "NLD"; }, { readonly name: "New Zealand"; readonly alpha2: "NZ"; readonly countryCode: "554"; readonly alpha3: "NZL"; }, { readonly name: "Nicaragua"; readonly alpha2: "NI"; readonly countryCode: "558"; readonly alpha3: "NIC"; }, { readonly name: "Niger"; readonly alpha2: "NE"; readonly countryCode: "562"; readonly alpha3: "NER"; }, { readonly name: "Nigeria"; readonly alpha2: "NG"; readonly countryCode: "566"; readonly alpha3: "NGA"; }, { readonly name: "North Macedonia"; readonly alpha2: "MK"; readonly countryCode: "807"; readonly alpha3: "MKD"; }, { readonly name: "Norway"; readonly alpha2: "NO"; readonly countryCode: "578"; readonly alpha3: "NOR"; }, { readonly name: "Oman"; readonly alpha2: "OM"; readonly countryCode: "512"; readonly alpha3: "OMN"; }, { readonly name: "Pakistan"; readonly alpha2: "PK"; readonly countryCode: "586"; readonly alpha3: "PAK"; }, { readonly name: "Palau"; readonly alpha2: "PW"; readonly countryCode: "585"; readonly alpha3: "PLW"; }, { readonly name: "Panama"; readonly alpha2: "PA"; readonly countryCode: "591"; readonly alpha3: "PAN"; }, { readonly name: "Papua New Guinea"; readonly alpha2: "PG"; readonly countryCode: "598"; readonly alpha3: "PNG"; }, { readonly name: "Paraguay"; readonly alpha2: "PY"; readonly countryCode: "600"; readonly alpha3: "PRY"; }, { readonly name: "Peru"; readonly alpha2: "PE"; readonly countryCode: "604"; readonly alpha3: "PER"; }, { readonly name: "Philippines"; readonly alpha2: "PH"; readonly countryCode: "608"; readonly alpha3: "PHL"; }, { readonly name: "Poland"; readonly alpha2: "PL"; readonly countryCode: "616"; readonly alpha3: "POL"; }, { readonly name: "Portugal"; readonly alpha2: "PT"; readonly countryCode: "620"; readonly alpha3: "PRT"; }, { readonly name: "Qatar"; readonly alpha2: "QA"; readonly countryCode: "634"; readonly alpha3: "QAT"; }, { readonly name: "Romania"; readonly alpha2: "RO"; readonly countryCode: "642"; readonly alpha3: "ROU"; }, { readonly name: "Russian Federation"; readonly alpha2: "RU"; readonly countryCode: "643"; readonly alpha3: "RUS"; }, { readonly name: "Rwanda"; readonly alpha2: "RW"; readonly countryCode: "646"; readonly alpha3: "RWA"; }, { readonly name: "Saint Kitts and Nevis"; readonly alpha2: "KN"; readonly countryCode: "659"; readonly alpha3: "KNA"; }, { readonly name: "Saint Lucia"; readonly alpha2: "LC"; readonly countryCode: "662"; readonly alpha3: "LCA"; }, { readonly name: "Saint Vincent and the Grenadines"; readonly alpha2: "VC"; readonly countryCode: "670"; readonly alpha3: "VCT"; }, { readonly name: "Samoa"; readonly alpha2: "WS"; readonly countryCode: "882"; readonly alpha3: "WSM"; }, { readonly name: "San Marino"; readonly alpha2: "SM"; readonly countryCode: "674"; readonly alpha3: "SMR"; }, { readonly name: "Sao Tome and Principe"; readonly alpha2: "ST"; readonly countryCode: "678"; readonly alpha3: "STP"; }, { readonly name: "Saudi Arabia"; readonly alpha2: "SA"; readonly countryCode: "682"; readonly alpha3: "SAU"; }, { readonly name: "Senegal"; readonly alpha2: "SN"; readonly countryCode: "686"; readonly alpha3: "SEN"; }, { readonly name: "Serbia"; readonly alpha2: "RS"; readonly countryCode: "688"; readonly alpha3: "SRB"; }, { readonly name: "Seychelles"; readonly alpha2: "SC"; readonly countryCode: "690"; readonly alpha3: "SYC"; }, { readonly name: "Sierra Leone"; readonly alpha2: "SL"; readonly countryCode: "694"; readonly alpha3: "SLE"; }, { readonly name: "Singapore"; readonly alpha2: "SG"; readonly countryCode: "702"; readonly alpha3: "SGP"; }, { readonly name: "Slovakia"; readonly alpha2: "SK"; readonly countryCode: "703"; readonly alpha3: "SVK"; }, { readonly name: "Slovenia"; readonly alpha2: "SI"; readonly countryCode: "705"; readonly alpha3: "SVN"; }, { readonly name: "Solomon Islands"; readonly alpha2: "SB"; readonly countryCode: "090"; readonly alpha3: "SLB"; }, { readonly name: "Somalia"; readonly alpha2: "SO"; readonly countryCode: "706"; readonly alpha3: "SOM"; }, { readonly name: "South Africa"; readonly alpha2: "ZA"; readonly countryCode: "710"; readonly alpha3: "ZAF"; }, { readonly name: "South Sudan"; readonly alpha2: "SS"; readonly countryCode: "728"; readonly alpha3: "SSD"; }, { readonly name: "Spain"; readonly alpha2: "ES"; readonly countryCode: "724"; readonly alpha3: "ESP"; }, { readonly name: "Sri Lanka"; readonly alpha2: "LK"; readonly countryCode: "144"; readonly alpha3: "LKA"; }, { readonly name: "Sudan"; readonly alpha2: "SD"; readonly countryCode: "729"; readonly alpha3: "SDN"; }, { readonly name: "Suriname"; readonly alpha2: "SR"; readonly countryCode: "740"; readonly alpha3: "SUR"; }, { readonly name: "Sweden"; readonly alpha2: "SE"; readonly countryCode: "752"; readonly alpha3: "SWE"; }, { readonly name: "Switzerland"; readonly alpha2: "CH"; readonly countryCode: "756"; readonly alpha3: "CHE"; }, { readonly name: "Syrian Arab Republic"; readonly alpha2: "SY"; readonly countryCode: "760"; readonly alpha3: "SYR"; }, { readonly name: "Taiwan"; readonly alpha2: "TW"; readonly countryCode: "158"; readonly alpha3: "TWN"; }, { readonly name: "Tajikistan"; readonly alpha2: "TJ"; readonly countryCode: "762"; readonly alpha3: "TJK"; }, { readonly name: "Tanzania"; readonly alpha2: "TZ"; readonly countryCode: "834"; readonly alpha3: "TZA"; }, { readonly name: "Thailand"; readonly alpha2: "TH"; readonly countryCode: "764"; readonly alpha3: "THA"; }, { readonly name: "Timor-Leste"; readonly alpha2: "TL"; readonly countryCode: "626"; readonly alpha3: "TLS"; }, { readonly name: "Togo"; readonly alpha2: "TG"; readonly countryCode: "768"; readonly alpha3: "TGO"; }, { readonly name: "Tonga"; readonly alpha2: "TO"; readonly countryCode: "776"; readonly alpha3: "TON"; }, { readonly name: "Tonga"; readonly alpha2: "TO"; readonly countryCode: "776"; readonly alpha3: "TON"; }, { readonly name: "Trinidad and Tobago"; readonly alpha2: "TT"; readonly countryCode: "780"; readonly alpha3: "TTO"; }, { readonly name: "Tunisia"; readonly alpha2: "TN"; readonly countryCode: "788"; readonly alpha3: "TUN"; }, { readonly name: "Turkey"; readonly alpha2: "TR"; readonly countryCode: "792"; readonly alpha3: "TUR"; }, { readonly name: "Turkmenistan"; readonly alpha2: "TM"; readonly countryCode: "795"; readonly alpha3: "TKM"; }, { readonly name: "Tuvalu"; readonly alpha2: "TV"; readonly countryCode: "798"; readonly alpha3: "TUV"; }, { readonly name: "Uganda"; readonly alpha2: "UG"; readonly countryCode: "800"; readonly alpha3: "UGA"; }, { readonly name: "Ukraine"; readonly alpha2: "UA"; readonly countryCode: "804"; readonly alpha3: "UKR"; }, { readonly name: "United Arab Emirates"; readonly alpha2: "AE"; readonly countryCode: "784"; readonly alpha3: "ARE"; }, { readonly name: "United Kingdom"; readonly alpha2: "GB"; readonly countryCode: "826"; readonly alpha3: "GBR"; }, { readonly name: "United States of America"; readonly alpha2: "US"; readonly countryCode: "840"; readonly alpha3: "USA"; }, { readonly name: "Uruguay"; readonly alpha2: "UY"; readonly countryCode: "858"; readonly alpha3: "URY"; }, { readonly name: "Uzbekistan"; readonly alpha2: "UZ"; readonly countryCode: "860"; readonly alpha3: "UZB"; }, { readonly name: "Vanuatu"; readonly alpha2: "VU"; readonly countryCode: "548"; readonly alpha3: "VUT"; }, { readonly name: "Venezuela"; readonly alpha2: "VE"; readonly countryCode: "862"; readonly alpha3: "VEN"; }, { readonly name: "Viet Nam"; readonly alpha2: "VN"; readonly countryCode: "704"; readonly alpha3: "VNM"; }, { readonly name: "Yemen"; readonly alpha2: "YE"; readonly countryCode: "887"; readonly alpha3: "YEM"; }, { readonly name: "Zambia"; readonly alpha2: "ZM"; readonly countryCode: "894"; readonly alpha3: "ZMB"; }, { readonly name: "Zimbabwe"; readonly alpha2: "ZW"; readonly countryCode: "716"; readonly alpha3: "ZWE"; }]; //#endregion //#region ../constants/src/Marked.d.ts declare const MARKED: Constant<"Marked", unknown>; /** * **Marked** * * A constant that indicates that an item has been marked for * some ongoing operation. */ type Marked$2 = typeof MARKED; //#endregion //#region ../constants/src/Metrics.d.ts declare const DISTANCE_METRICS_LOOKUP: readonly [{ readonly abbrev: "km"; readonly name: "kilometer"; }, { readonly abbrev: "mi"; readonly name: "mile"; }, { readonly abbrev: "mm"; readonly name: "millimeter"; }, { readonly abbrev: "cm"; readonly name: "centimeter"; }, { readonly abbrev: "yd"; readonly name: "yard"; }, { readonly abbrev: "ft"; readonly name: "foot"; }, { readonly abbrev: "in"; readonly name: "inch"; }, { readonly abbrev: "m"; readonly name: "meter"; }, { readonly abbrev: "nm"; readonly name: "nautical mile"; }, { readonly abbrev: "nmi"; readonly name: "nanometer"; }, { readonly abbrev: "µm"; readonly name: "micrometer"; }, { readonly abbrev: "dm"; readonly name: "decimeter"; }, { readonly abbrev: "AU"; readonly name: "astronomical unit"; }, { readonly abbrev: "ly"; readonly name: "light year"; }, { readonly abbrev: "pc"; readonly name: "parsec"; }]; declare const MASS_METRICS_LOOKUP: readonly [{ readonly abbrev: "g"; readonly name: "gram"; }, { readonly abbrev: "kg"; readonly name: "kilogram"; }, { readonly abbrev: "mg"; readonly name: "milligram"; }, { readonly abbrev: "µg"; readonly name: "microgram"; }, { readonly abbrev: "t"; readonly name: "tonne"; }, { readonly abbrev: "lb"; readonly name: "pound"; }, { readonly abbrev: "oz"; readonly name: "ounce"; }, { readonly abbrev: "st"; readonly name: "stone"; }, { readonly abbrev: "ct"; readonly name: "carat"; }, { readonly abbrev: "Mt"; readonly name: "megatonne"; }, { readonly abbrev: "gt"; readonly name: "gigatonne"; }, { readonly abbrev: "slug"; readonly name: "slug"; }, { readonly abbrev: "dr"; readonly name: "dram"; }, { readonly abbrev: "gr"; readonly name: "grain"; }, { readonly abbrev: "q"; readonly name: "quintal"; }]; declare const SPEED_METRICS_LOOKUP: readonly [{ readonly abbrev: "m/s"; readonly name: "meters per second"; }, { readonly abbrev: "km/h"; readonly name: "kilometers per hour"; }, { readonly abbrev: "mph"; readonly name: "miles per hour"; }, { readonly abbrev: "kn"; readonly name: "knot"; }, { readonly abbrev: "ft/s"; readonly name: "feet per second"; }, { readonly abbrev: "c"; readonly name: "speed of light"; }, { readonly abbrev: "mach"; readonly name: "mach"; }, { readonly abbrev: "cm/s"; readonly name: "centimeters per second"; }, { readonly abbrev: "in/s"; readonly name: "inches per second"; }, { readonly abbrev: "ly/y"; readonly name: "light years per year"; }]; declare const ACCELERATION_METRICS_LOOKUP: readonly [{ readonly abbrev: "m/s²"; readonly name: "meters per second squared"; }, { readonly abbrev: "ft/s²"; readonly name: "feet per second squared"; }, { readonly abbrev: "g"; readonly name: "g-force"; }, { readonly abbrev: "Gal"; readonly name: "galileo"; }, { readonly abbrev: "cm/s²"; readonly name: "centimeters per second squared"; }, { readonly abbrev: "km/h²"; readonly name: "kilometers per hour squared"; }, { readonly abbrev: "in/s²"; readonly name: "inches per second squared"; }, { readonly abbrev: "mi/h²"; readonly name: "miles per hour squared"; }, { readonly abbrev: "kn/s²"; readonly name: "knots per second squared"; }]; declare const VOLUME_METRICS_LOOKUP: readonly [{ readonly abbrev: "L"; readonly name: "liter"; }, { readonly abbrev: "dL"; readonly name: "deciliter"; }, { readonly abbrev: "mL"; readonly name: "milliliter"; }, { readonly abbrev: "µL"; readonly name: "microliter"; }, { readonly abbrev: "cm³"; readonly name: "cubic centimeter"; }, { readonly abbrev: "m³"; readonly name: "cubic meter"; }, { readonly abbrev: "ft³"; readonly name: "cubic foot"; }, { readonly abbrev: "in³"; readonly name: "cubic inch"; }, { readonly abbrev: "gallon"; readonly name: "gallon"; }, { readonly abbrev: "qt"; readonly name: "quart"; }, { readonly abbrev: "pt"; readonly name: "pint"; }, { readonly abbrev: "fl oz"; readonly name: "fluid ounce"; }, { readonly abbrev: "barrel"; readonly name: "barrel"; }, { readonly abbrev: "tbsp"; readonly name: "tablespoon"; }, { readonly abbrev: "tsp"; readonly name: "teaspoon"; }]; declare const TEMPERATURE_METRICS_LOOKUP: readonly [{ readonly abbrev: "°C"; readonly name: "celsius"; }, { readonly abbrev: "°F"; readonly name: "fahrenheit"; }, { readonly abbrev: "K"; readonly name: "kelvin"; }]; declare const PRESSURE_METRICS_LOOKUP: readonly [{ readonly abbrev: "Pa"; readonly name: "pascal"; }, { readonly abbrev: "bar"; readonly name: "bar"; }, { readonly abbrev: "atm"; readonly name: "atmosphere"; }, { readonly abbrev: "mmHg"; readonly name: "millimeters of mercury"; }, { readonly abbrev: "psi"; readonly name: "pounds per square inch"; }]; declare const ENERGY_METRICS_LOOKUP: readonly [{ readonly abbrev: "J"; readonly name: "joule"; }, { readonly abbrev: "cal"; readonly name: "calorie"; }, { readonly abbrev: "kcal"; readonly name: "kilocalorie"; }, { readonly abbrev: "kWh"; readonly name: "kilowatt-hour"; }, { readonly abbrev: "BTU"; readonly name: "british thermal unit"; }, { readonly abbrev: "eV"; readonly name: "electronvolt"; }]; declare const TIME_METRICS_LOOKUP: readonly [{ readonly abbrev: "s"; readonly name: "second"; }, { readonly abbrev: "m"; readonly name: "minute"; }, { readonly abbrev: "h"; readonly name: "hour"; }, { readonly abbrev: "day"; readonly name: "day"; }, { readonly abbrev: "week"; readonly name: "week"; }, { readonly abbrev: "mo"; readonly name: "month"; }, { readonly abbrev: "ms"; readonly name: "millisecond"; }, { readonly abbrev: "µs"; readonly name: "microsecond"; }, { readonly abbrev: "ns"; readonly name: "nanosecond"; }]; declare const POWER_METRICS_LOOKUP: readonly [{ readonly abbrev: "W"; readonly name: "Watt"; }, { readonly abbrev: "kW"; readonly name: "kilowatt"; }, { readonly abbrev: "MW"; readonly name: "megawatt"; }, { readonly abbrev: "hp"; readonly name: "horsepower"; }, { readonly abbrev: "GW"; readonly name: "gigawatt"; }]; declare const FREQUENCY_METRICS_LOOKUP: readonly [{ readonly abbrev: "Hz"; readonly name: "hertz"; }, { readonly abbrev: "kHz"; readonly name: "kilohertz"; }, { readonly abbrev: "MHz"; readonly name: "megahertz"; }, { readonly abbrev: "GHz"; readonly name: "gigahertz"; }, { readonly abbrev: "THz"; readonly name: "terahertz"; }]; declare const VOLTAGE_METRICS_LOOKUP: readonly [{ readonly abbrev: "V"; readonly name: "volt"; }, { readonly abbrev: "kV"; readonly name: "kilovolt"; }, { readonly abbrev: "mV"; readonly name: "millivolt"; }, { readonly abbrev: "µV"; readonly name: "microvolt"; }]; declare const CURRENT_METRICS_LOOKUP: readonly [{ readonly abbrev: "A"; readonly name: "ampere"; }, { readonly abbrev: "mA"; readonly name: "milliampere"; }, { readonly abbrev: "µA"; readonly name: "microampere"; }, { readonly abbrev: "kA"; readonly name: "kiloampere"; }]; declare const RESISTANCE_METRICS_LOOKUP: readonly [{ readonly abbrev: "Ω"; readonly name: "ohm"; }, { readonly abbrev: "kΩ"; readonly name: "kiloohm"; }, { readonly abbrev: "MΩ"; readonly name: "megaohm"; }]; declare const LUMINOSITY_METRICS_LOOKUP: readonly [{ readonly abbrev: "cd"; readonly name: "candela"; }, { readonly abbrev: "lm"; readonly name: "lumen"; }, { readonly abbrev: "lx"; readonly name: "lux"; }]; declare const AREA_METRICS_LOOKUP: readonly [{ readonly abbrev: "m²"; readonly name: "square meter"; }, { readonly abbrev: "cm²"; readonly name: "square centimeter"; }, { readonly abbrev: "mm²"; readonly name: "square millimeter"; }, { readonly abbrev: "km²"; readonly name: "square kilometer"; }, { readonly abbrev: "ft²"; readonly name: "square foot"; }, { readonly abbrev: "in²"; readonly name: "square inch"; }, { readonly abbrev: "acre"; readonly name: "acre"; }, { readonly abbrev: "ha"; readonly name: "hectare"; }]; //#endregion //#region ../constants/src/Nesting.d.ts /** * the named nested configuration defined in this repo */ declare const KNOWN_NESTING_CONFIGURATIONS: ["brackets", "quotes", "brackets-and-quotes", "shallow-brackets", "shallow-brackets-and-quotes", "shallow-quotes"]; /** * A paired bracketing strategy which matches on * bracket characters: * * - parenthesis: `(` -> `)` * - square brackets: `[` -> `]` * - angle brackets: `<` -> `>` * - and curlies: `{` -> `}` */ declare const BRACKET_NESTING: { "{": "}"; "[": "]"; "<": ">"; "(": ")"; }; /** * A paired bracketing strategy which includes the three * main quotation symbols: * * - single quote (**'**), * - double quote (**"**), * - and backtick (**`**) */ declare const QUOTE_NESTING: { "\"": "\""; "'": "'"; "`": "`"; }; /** * A paired bracketing strategy which includes: * * - all bracket characters * - all quote characters */ declare const BRACKET_AND_QUOTE_NESTING: { "\"": "\""; "'": "'"; "`": "`"; "{": "}"; "[": "]"; "<": ">"; "(": ")"; }; /** * **Shallow Bracket Nesting** * * A hierarchical nesting configuration where bracket characters * are recognized at level 0, but inside brackets no further * nesting is recognized (empty config `{}`). * * This prevents "unbalanced" errors in utilities that only * care about the root level. */ declare const SHALLOW_BRACKET_NESTING: { "(": { exit: ")"; children: {}; }; "[": { exit: "]"; children: {}; }; "{": { exit: "}"; children: {}; }; "<": { exit: ">"; children: {}; }; }; /** * **Shallow Quote Nesting** * * A hierarchical nesting configuration where quote characters * are recognized at level 0, but inside quotes no further * nesting is recognized (empty config `{}`). * * This allows treating quoted content as literals, preventing * split characters inside quotes from being recognized. */ declare const SHALLOW_QUOTE_NESTING: { "\"": { exit: "\""; children: {}; }; "'": { exit: "'"; children: {}; }; "`": { exit: "`"; children: {}; }; }; /** * **Shallow Bracket and Quote Nesting** * * Combines shallow bracket and quote nesting strategies. * Both brackets and quotes are recognized at level 0, but * inside either, no further nesting is recognized. */ declare const SHALLOW_BRACKET_AND_QUOTE_NESTING: { "\"": { exit: "\""; children: {}; }; "'": { exit: "'"; children: {}; }; "`": { exit: "`"; children: {}; }; "(": { exit: ")"; children: {}; }; "[": { exit: "]"; children: {}; }; "{": { exit: "}"; children: {}; }; "<": { exit: ">"; children: {}; }; }; //#endregion //#region ../constants/src/NetworkConstants.d.ts declare const NETWORK_PROTOCOL: readonly ["http", "ftp", "ws", "dns", "telnet", "imap", "pop3", "smtp", "https", "sftp", "wss", "sdns", "ssh"]; declare const PROTOCOL_DEFAULT_PORTS: { readonly http: 80; readonly https: 443; readonly ws: 80; readonly wss: 443; readonly ssh: 22; readonly telnet: 23; readonly dns: 53; readonly sdns: 853; readonly smtp: 25; readonly imap: 142; readonly pop3: 110; readonly ftp: 21; readonly sftp: 22; }; //#endregion //#region ../constants/src/News.d.ts declare const US_NEWS: readonly [{ readonly company: "New York Times"; readonly baseUrls: readonly ["www.nytimes.com"]; }, { readonly company: "CNN"; readonly baseUrls: readonly ["www.cnn.com"]; }, { readonly company: "Fox News"; readonly baseUrls: readonly ["www.foxnews.com"]; }, { readonly company: "NBC News"; readonly baseUrls: readonly ["www.nbcnews.com", "www.msnbc.com"]; }, { readonly company: "ABC News"; readonly baseUrls: readonly ["abcnews.go.com"]; }, { readonly company: "The Washington Post"; readonly baseUrls: readonly ["www.washingtonpost.com"]; }, { readonly company: "USA Today"; readonly baseUrls: readonly ["www.usatoday.com"]; }, { readonly company: "Bloomberg"; readonly baseUrls: readonly ["www.bloomberg.com"]; }, { readonly company: "NPR"; readonly baseUrls: readonly ["www.npr.org"]; }, { readonly company: "CBS News"; readonly baseUrls: readonly ["www.cbsnews.com"]; }, { readonly company: "The Wall Street Journal"; readonly baseUrls: readonly ["www.wsj.com"]; }, { readonly company: "Associated Press (AP)"; readonly baseUrls: readonly ["www.apnews.com", "www.ap.org"]; }, { readonly company: "Reuters"; readonly baseUrls: readonly ["www.reuters.com"]; }, { readonly company: "Newsweek"; readonly baseUrls: readonly ["www.newsweek.com"]; }, { readonly company: "Politico"; readonly baseUrls: readonly ["www.politico.com"]; }, { readonly company: "The Atlantic"; readonly baseUrls: readonly ["www.theatlantic.com"]; }, { readonly company: "Nexstar Media Group"; readonly baseUrls: readonly ["www.nexstar.tv"]; }, { readonly company: "PBS News"; readonly baseUrls: readonly ["www.pbs.org"]; }, { readonly company: "HuffPost"; readonly baseUrls: readonly ["www.huffpost.com"]; }, { readonly company: "The Boston Globe"; readonly baseUrls: readonly ["www.bostonglobe.com"]; }]; declare const UK_NEWS: readonly [{ readonly company: "BBC"; readonly baseUrls: readonly ["www.bbc.co.uk", "www.bbc.com"]; }, { readonly company: "The Guardian"; readonly baseUrls: readonly ["www.theguardian.com/uk"]; }, { readonly company: "The Daily Mail"; readonly baseUrls: readonly ["www.dailymail.co.uk"]; }, { readonly company: "The Sun"; readonly baseUrls: readonly ["www.thesun.co.uk"]; }, { readonly company: "The Times"; readonly baseUrls: readonly ["www.thetimes.co.uk"]; }, { readonly company: "Sky News"; readonly baseUrls: readonly ["news.sky.com"]; }, { readonly company: "The Telegraph"; readonly baseUrls: readonly ["www.telegraph.co.uk"]; }, { readonly company: "ITV News"; readonly baseUrls: readonly ["www.itv.com/news"]; }, { readonly company: "Financial Times"; readonly baseUrls: readonly ["www.ft.com"]; }, { readonly company: "Metro"; readonly baseUrls: readonly ["www.metro.co.uk"]; }, { readonly company: "The Independent"; readonly baseUrls: readonly ["www.independent.co.uk"]; }, { readonly company: "Evening Standard"; readonly baseUrls: readonly ["www.standard.co.uk"]; }, { readonly company: "Daily Mirror"; readonly baseUrls: readonly ["www.mirror.co.uk"]; }, { readonly company: "Channel 4 News"; readonly baseUrls: readonly ["www.channel4.com/news"]; }, { readonly company: "LBC"; readonly baseUrls: readonly ["www.lbc.co.uk"]; }, { readonly company: "Daily Express"; readonly baseUrls: readonly ["www.express.co.uk"]; }, { readonly company: "Birmingham Mail"; readonly baseUrls: readonly ["www.birminghammail.co.uk"]; }, { readonly company: "Manchester Evening News"; readonly baseUrls: readonly ["www.manchestereveningnews.co.uk"]; }, { readonly company: "The Scotsman"; readonly baseUrls: readonly ["www.scotsman.com"]; }, { readonly company: "Daily Record"; readonly baseUrls: readonly ["www.dailyrecord.co.uk"]; }]; declare const GERMAN_NEWS: readonly [{ readonly company: "BILD"; readonly baseUrls: readonly ["www.bild.de"]; }, { readonly company: "Die Zeit"; readonly baseUrls: readonly ["www.zeit.de"]; }, { readonly company: "Frankfurter Allgemeine Zeitung"; readonly baseUrls: readonly ["www.faz.net"]; }, { readonly company: "Süddeutsche Zeitung"; readonly baseUrls: readonly ["www.sueddeutsche.de"]; }, { readonly company: "Der Spiegel"; readonly baseUrls: readonly ["www.spiegel.de"]; }, { readonly company: "Die Welt"; readonly baseUrls: readonly ["www.welt.de"]; }, { readonly company: "Tagesschau"; readonly baseUrls: readonly ["www.tagesschau.de"]; }, { readonly company: "t-online"; readonly baseUrls: readonly ["www.t-online.de"]; }, { readonly company: "n-tv"; readonly baseUrls: readonly ["www.n-tv.de"]; }, { readonly company: "Handelsblatt"; readonly baseUrls: readonly ["www.handelsblatt.com"]; }, { readonly company: "Focus Online"; readonly baseUrls: readonly ["www.focus.de"]; }, { readonly company: "Frankfurter Rundschau"; readonly baseUrls: readonly ["www.fr.de", "www.fr-online.de"]; }, { readonly company: "taz - die tageszeitung"; readonly baseUrls: readonly ["www.taz.de"]; }, { readonly company: "Der Tagesspiegel"; readonly baseUrls: readonly ["www.tagesspiegel.de"]; }, { readonly company: "Rheinische Post"; readonly baseUrls: readonly ["www.rp-online.de"]; }, { readonly company: "Express"; readonly baseUrls: readonly ["www.express.de"]; }, { readonly company: "Münchner Merkur"; readonly baseUrls: readonly ["www.merkur.de"]; }, { readonly company: "Stuttgarter Zeitung"; readonly baseUrls: readonly ["www.stuttgarter-zeitung.de"]; }, { readonly company: "Hamburger Abendblatt"; readonly baseUrls: readonly ["www.abendblatt.de"]; }, { readonly company: "Deutsche Welle"; readonly baseUrls: readonly ["www.dw.com"]; }]; declare const FRENCH_NEWS: readonly [{ readonly company: "Le Figaro"; readonly baseUrls: readonly ["www.lefigaro.fr"]; }, { readonly company: "Le Monde"; readonly baseUrls: readonly ["www.lemonde.fr"]; }, { readonly company: "France 24"; readonly baseUrls: readonly ["www.france24.com"]; }, { readonly company: "Libération"; readonly baseUrls: readonly ["www.liberation.fr"]; }, { readonly company: "Les Echos"; readonly baseUrls: readonly ["www.lesechos.fr"]; }, { readonly company: "Ouest-France"; readonly baseUrls: readonly ["www.ouest-france.fr"]; }, { readonly company: "Le Parisien"; readonly baseUrls: readonly ["www.leparisien.fr"]; }, { readonly company: "Mediapart"; readonly baseUrls: readonly ["www.mediapart.fr"]; }, { readonly company: "L'Express"; readonly baseUrls: readonly ["www.lexpress.fr"]; }, { readonly company: "La Croix"; readonly baseUrls: readonly ["www.la-croix.com"]; }, { readonly company: "20 Minutes"; readonly baseUrls: readonly ["www.20minutes.fr"]; }, { readonly company: "Courrier International"; readonly baseUrls: readonly ["www.courrierinternational.com"]; }, { readonly company: "Le Point"; readonly baseUrls: readonly ["www.lepoint.fr"]; }, { readonly company: "Marianne"; readonly baseUrls: readonly ["www.marianne.net"]; }, { readonly company: "BFM TV"; readonly baseUrls: readonly ["www.bfmtv.com"]; }, { readonly company: "RTL France"; readonly baseUrls: readonly ["www.rtl.fr"]; }, { readonly company: "Charlie Hebdo"; readonly baseUrls: readonly ["www.charliehebdo.fr"]; }, { readonly company: "Challenges"; readonly baseUrls: readonly ["www.challenges.fr"]; }, { readonly company: "Télérama"; readonly baseUrls: readonly ["www.telerama.fr"]; }, { readonly company: "L'Obs"; readonly baseUrls: readonly ["www.nouvelobs.com"]; }]; declare const CANADIAN_NEWS: readonly [{ readonly company: "CBC News"; readonly baseUrls: readonly ["www.cbc.ca"]; }, { readonly company: "CTV News"; readonly baseUrls: readonly ["www.ctvnews.ca"]; }, { readonly company: "The Globe and Mail"; readonly baseUrls: readonly ["www.theglobeandmail.com"]; }, { readonly company: "Global News"; readonly baseUrls: readonly ["www.globalnews.ca"]; }, { readonly company: "Toronto Star"; readonly baseUrls: readonly ["www.thestar.com"]; }, { readonly company: "National Post"; readonly baseUrls: readonly ["www.nationalpost.com"]; }, { readonly company: "La Presse"; readonly baseUrls: readonly ["www.lapresse.ca"]; }, { readonly company: "Radio-Canada"; readonly baseUrls: readonly ["ici.radio-canada.ca"]; }, { readonly company: "The Canadian Press"; readonly baseUrls: readonly ["www.thecanadianpress.com"]; }, { readonly company: "Financial Post"; readonly baseUrls: readonly ["financialpost.com"]; }, { readonly company: "The Weather Network"; readonly baseUrls: readonly ["www.theweathernetwork.com"]; }, { readonly company: "Le Devoir"; readonly baseUrls: readonly ["www.ledevoir.com"]; }, { readonly company: "TVA Nouvelles"; readonly baseUrls: readonly ["www.tvanouvelles.ca"]; }, { readonly company: "Journal de Montréal"; readonly baseUrls: readonly ["www.journaldemontreal.com"]; }, { readonly company: "CityNews"; readonly baseUrls: readonly ["www.citynews.ca"]; }, { readonly company: "BNN Bloomberg"; readonly baseUrls: readonly ["www.bnnbloomberg.ca"]; }, { readonly company: "The Hamilton Spectator"; readonly baseUrls: readonly ["www.thespec.com"]; }, { readonly company: "Ottawa Citizen"; readonly baseUrls: readonly ["ottawacitizen.com"]; }, { readonly company: "Windsor Star"; readonly baseUrls: readonly ["windsorstar.com"]; }, { readonly company: "Edmonton Journal"; readonly baseUrls: readonly ["edmontonjournal.com"]; }]; declare const DUTCH_NEWS: readonly [{ readonly company: "Algemeen Dagblad (AD)"; readonly baseUrls: readonly ["www.ad.nl"]; }, { readonly company: "NOS"; readonly baseUrls: readonly ["www.nos.nl"]; }, { readonly company: "De Telegraaf"; readonly baseUrls: readonly ["www.telegraaf.nl"]; }, { readonly company: "NU.nl"; readonly baseUrls: readonly ["www.nu.nl"]; }, { readonly company: "Volkskrant"; readonly baseUrls: readonly ["www.volkskrant.nl"]; }, { readonly company: "NRC Handelsblad"; readonly baseUrls: readonly ["www.nrc.nl"]; }, { readonly company: "Trouw"; readonly baseUrls: readonly ["www.trouw.nl"]; }, { readonly company: "Het Parool"; readonly baseUrls: readonly ["www.parool.nl"]; }, { readonly company: "RTL Nieuws"; readonly baseUrls: readonly ["www.rtlnieuws.nl"]; }, { readonly company: "BNR Nieuwsradio"; readonly baseUrls: readonly ["www.bnr.nl"]; }, { readonly company: "Emerce"; readonly baseUrls: readonly ["www.emerce.nl"]; }, { readonly company: "VPRO"; readonly baseUrls: readonly ["www.vpro.nl"]; }, { readonly company: "De Gelderlander"; readonly baseUrls: readonly ["www.gelderlander.nl"]; }, { readonly company: "Friesch Dagblad"; readonly baseUrls: readonly ["www.frieschdagblad.nl"]; }, { readonly company: "De Stentor"; readonly baseUrls: readonly ["www.destentor.nl"]; }, { readonly company: "Metro Nieuws"; readonly baseUrls: readonly ["www.metronieuws.nl"]; }, { readonly company: "ANP"; readonly baseUrls: readonly ["www.anp.nl"]; }, { readonly company: "Dagblad van het Noorden"; readonly baseUrls: readonly ["www.dvhn.nl"]; }, { readonly company: "Reformatorisch Dagblad"; readonly baseUrls: readonly ["www.rd.nl"]; }, { readonly company: "Financieele Dagblad"; readonly baseUrls: readonly ["www.fd.nl"]; }]; declare const ITALIAN_NEWS: readonly [{ readonly company: "ANSA"; readonly baseUrls: readonly ["www.ansa.it", "www.ansamed.info"]; }, { readonly company: "Corriere della Sera"; readonly baseUrls: readonly ["www.corriere.it"]; }, { readonly company: "la Repubblica"; readonly baseUrls: readonly ["www.repubblica.it"]; }, { readonly company: "Il Sole 24 Ore"; readonly baseUrls: readonly ["www.ilsole24ore.com"]; }, { readonly company: "La Stampa"; readonly baseUrls: readonly ["www.lastampa.it"]; }, { readonly company: "Il Messaggero"; readonly baseUrls: readonly ["www.ilmessaggero.it"]; }, { readonly company: "Il Giornale"; readonly baseUrls: readonly ["www.ilgiornale.it"]; }, { readonly company: "Avvenire"; readonly baseUrls: readonly ["www.avvenire.it"]; }, { readonly company: "Il Fatto Quotidiano"; readonly baseUrls: readonly ["www.ilfattoquotidiano.it"]; }, { readonly company: "La Nazione"; readonly baseUrls: readonly ["www.lanazione.it"]; }, { readonly company: "TgCom24"; readonly baseUrls: readonly ["www.tgcom24.mediaset.it"]; }, { readonly company: "Sky TG24"; readonly baseUrls: readonly ["tg24.sky.it"]; }, { readonly company: "Rai News"; readonly baseUrls: readonly ["www.rainews.it"]; }, { readonly company: "Gazzetta dello Sport"; readonly baseUrls: readonly ["www.gazzetta.it"]; }, { readonly company: "Il Resto del Carlino"; readonly baseUrls: readonly ["www.ilrestodelcarlino.it"]; }, { readonly company: "Il Mattino"; readonly baseUrls: readonly ["www.ilmattino.it"]; }, { readonly company: "Il Secolo XIX"; readonly baseUrls: readonly ["www.ilsecoloxix.it"]; }, { readonly company: "Italia Oggi"; readonly baseUrls: readonly ["www.italiaoggi.it"]; }, { readonly company: "Libero"; readonly baseUrls: readonly ["www.liberoquotidiano.it"]; }, { readonly company: "Il Tirreno"; readonly baseUrls: readonly ["www.iltirreno.it"]; }]; declare const BELGIUM_NEWS: readonly [{ readonly company: "Het Laatste Nieuws (HLN)"; readonly baseUrls: readonly ["www.hln.be"]; }, { readonly company: "Nieuwsblad"; readonly baseUrls: readonly ["www.nieuwsblad.be"]; }, { readonly company: "RTBF"; readonly baseUrls: readonly ["www.rtbf.be"]; }, { readonly company: "Sudinfo"; readonly baseUrls: readonly ["www.sudinfo.be"]; }, { readonly company: "7sur7"; readonly baseUrls: readonly ["www.7sur7.be"]; }, { readonly company: "Le Soir"; readonly baseUrls: readonly ["www.lesoir.be"]; }, { readonly company: "De Standaard"; readonly baseUrls: readonly ["www.standaard.be"]; }, { readonly company: "VRT NWS"; readonly baseUrls: readonly ["www.vrt.be"]; }, { readonly company: "La Libre"; readonly baseUrls: readonly ["www.lalibre.be"]; }, { readonly company: "Gazet van Antwerpen"; readonly baseUrls: readonly ["www.gva.be"]; }, { readonly company: "Het Belang van Limburg"; readonly baseUrls: readonly ["www.hbvl.be"]; }, { readonly company: "De Morgen"; readonly baseUrls: readonly ["www.demorgen.be"]; }, { readonly company: "L'Avenir"; readonly baseUrls: readonly ["www.lavenir.net"]; }, { readonly company: "The Brussels Times"; readonly baseUrls: readonly ["www.brusselstimes.com"]; }, { readonly company: "Metro Belgique"; readonly baseUrls: readonly ["nl.metrotime.be"]; }, { readonly company: "Sudpresse"; readonly baseUrls: readonly ["www.sudpress.be"]; }, { readonly company: "Flamish Radio and TV Broadcasting Organization (VRT)"; readonly baseUrls: readonly ["www.vrt.be"]; }, { readonly company: "Knack"; readonly baseUrls: readonly ["www.knack.be"]; }, { readonly company: "De Tijd"; readonly baseUrls: readonly ["www.tijd.be"]; }, { readonly company: "BX1"; readonly baseUrls: readonly ["www.bx1.be"]; }]; declare const MEXICAN_NEWS: readonly [{ readonly company: "Televisa"; readonly baseUrls: readonly ["www.televisa.news"]; }, { readonly company: "El Universal"; readonly baseUrls: readonly ["www.eluniversal.com.mx"]; }, { readonly company: "Milenio"; readonly baseUrls: readonly ["www.milenio.com"]; }, { readonly company: "Excélsior"; readonly baseUrls: readonly ["www.excelsior.com.mx"]; }, { readonly company: "Reforma"; readonly baseUrls: readonly ["www.reforma.com"]; }, { readonly company: "La Jornada"; readonly baseUrls: readonly ["www.jornada.com.mx"]; }, { readonly company: "El Financiero"; readonly baseUrls: readonly ["www.elfinanciero.com.mx"]; }, { readonly company: "Proceso"; readonly baseUrls: readonly ["www.proceso.com.mx"]; }, { readonly company: "SDP Noticias"; readonly baseUrls: readonly ["www.sdpnoticias.com"]; }, { readonly company: "Diario de Yucatán"; readonly baseUrls: readonly ["www.yucatan.com.mx"]; }, { readonly company: "El Economista"; readonly baseUrls: readonly ["www.eleconomista.com.mx"]; }, { readonly company: "El Heraldo de México"; readonly baseUrls: readonly ["www.heraldodemexico.com.mx"]; }, { readonly company: "Noticieros Televisa"; readonly baseUrls: readonly ["noticieros.televisa.com"]; }, { readonly company: "Expansión"; readonly baseUrls: readonly ["expansion.mx"]; }, { readonly company: "La Razón"; readonly baseUrls: readonly ["www.razon.com.mx"]; }, { readonly company: "Noroeste"; readonly baseUrls: readonly ["www.noroeste.com.mx"]; }, { readonly company: "Uniradio Noticias"; readonly baseUrls: readonly ["www.uniradionoticias.com"]; }, { readonly company: "El Imparcial"; readonly baseUrls: readonly ["www.elimparcial.com"]; }, { readonly company: "Publimetro México"; readonly baseUrls: readonly ["www.publimetro.com.mx"]; }, { readonly company: "Notimex"; readonly baseUrls: readonly ["www.notimex.gob.mx"]; }]; declare const SPANISH_NEWS: readonly [{ readonly company: "El País"; readonly baseUrls: readonly ["www.elpais.com"]; }, { readonly company: "El Mundo"; readonly baseUrls: readonly ["www.elmundo.es"]; }, { readonly company: "ABC"; readonly baseUrls: readonly ["www.abc.es"]; }, { readonly company: "La Vanguardia"; readonly baseUrls: readonly ["www.lavanguardia.com"]; }, { readonly company: "El Confidencial"; readonly baseUrls: readonly ["www.elconfidencial.com"]; }, { readonly company: "La Razón"; readonly baseUrls: readonly ["www.larazon.es"]; }, { readonly company: "20 Minutos"; readonly baseUrls: readonly ["www.20minutos.es"]; }, { readonly company: "Agencia EFE"; readonly baseUrls: readonly ["www.efe.com"]; }, { readonly company: "Europa Press"; readonly baseUrls: readonly ["www.europapress.es"]; }, { readonly company: "Diario AS"; readonly baseUrls: readonly ["www.as.com"]; }, { readonly company: "Mundo Deportivo"; readonly baseUrls: readonly ["www.mundodeportivo.com"]; }, { readonly company: "El Periódico"; readonly baseUrls: readonly ["www.elperiodico.com"]; }, { readonly company: "Cinco Días"; readonly baseUrls: readonly ["www.cincodias.com"]; }, { readonly company: "Expansión"; readonly baseUrls: readonly ["www.expansion.com"]; }, { readonly company: "La Información"; readonly baseUrls: readonly ["www.lainformacion.com"]; }, { readonly company: "OK Diario"; readonly baseUrls: readonly ["www.okdiario.com"]; }, { readonly company: "Heraldo de Aragón"; readonly baseUrls: readonly ["www.heraldo.es"]; }, { readonly company: "Faro de Vigo"; readonly baseUrls: readonly ["www.farodevigo.es"]; }, { readonly company: "El Correo"; readonly baseUrls: readonly ["www.elcorreo.com"]; }, { readonly company: "Diario Sur"; readonly baseUrls: readonly ["www.diariosur.es"]; }]; declare const INDIAN_NEWS: readonly [{ readonly company: "The Times of India"; readonly baseUrls: readonly ["timesofindia.indiatimes.com"]; }, { readonly company: "The Hindu"; readonly baseUrls: readonly ["www.thehindu.com"]; }, { readonly company: "Hindustan Times"; readonly baseUrls: readonly ["www.hindustantimes.com"]; }, { readonly company: "NDTV"; readonly baseUrls: readonly ["www.ndtv.com"]; }, { readonly company: "India Today"; readonly baseUrls: readonly ["www.indiatoday.in"]; }, { readonly company: "Zee News"; readonly baseUrls: readonly ["zeenews.india.com"]; }, { readonly company: "Indian Express"; readonly baseUrls: readonly ["indianexpress.com"]; }, { readonly company: "The Economic Times"; readonly baseUrls: readonly ["economictimes.indiatimes.com"]; }, { readonly company: "Deccan Herald"; readonly baseUrls: readonly ["www.deccanherald.com"]; }, { readonly company: "DNA India"; readonly baseUrls: readonly ["www.dnaindia.com"]; }, { readonly company: "The Print"; readonly baseUrls: readonly ["theprint.in"]; }, { readonly company: "News18"; readonly baseUrls: readonly ["www.news18.com"]; }, { readonly company: "Scroll.in"; readonly baseUrls: readonly ["scroll.in"]; }, { readonly company: "Asian News International (ANI)"; readonly baseUrls: readonly ["www.aninews.in"]; }, { readonly company: "Outlook India"; readonly baseUrls: readonly ["www.outlookindia.com"]; }, { readonly company: "Business Standard"; readonly baseUrls: readonly ["www.business-standard.com"]; }, { readonly company: "Mint"; readonly baseUrls: readonly ["www.livemint.com"]; }, { readonly company: "OneIndia"; readonly baseUrls: readonly ["www.oneindia.com"]; }, { readonly company: "Quint"; readonly baseUrls: readonly ["www.thequint.com"]; }, { readonly company: "Free Press Journal"; readonly baseUrls: readonly ["www.freepressjournal.in"]; }]; declare const CHINESE_NEWS: readonly [{ readonly company: "Xinhua News Agency"; readonly baseUrls: readonly ["www.xinhuanet.com"]; }, { readonly company: "China Central Television (CCTV)"; readonly baseUrls: readonly ["www.cctv.com"]; }, { readonly company: "China Daily"; readonly baseUrls: readonly ["www.chinadaily.com.cn"]; }, { readonly company: "CGTN (China Global Television Network)"; readonly baseUrls: readonly ["www.cgtn.com"]; }, { readonly company: "People's Daily"; readonly baseUrls: readonly ["www.people.cn"]; }, { readonly company: "Global Times"; readonly baseUrls: readonly ["www.globaltimes.cn"]; }, { readonly company: "South China Morning Post"; readonly baseUrls: readonly ["www.scmp.com"]; }, { readonly company: "Shanghai Daily"; readonly baseUrls: readonly ["www.shanghaidaily.com"]; }, { readonly company: "China News Service"; readonly baseUrls: readonly ["www.ecns.cn"]; }, { readonly company: "Caixin"; readonly baseUrls: readonly ["www.caixinglobal.com"]; }, { readonly company: "The Paper"; readonly baseUrls: readonly ["www.thepaper.cn"]; }, { readonly company: "Yicai Global"; readonly baseUrls: readonly ["www.yicaiglobal.com"]; }, { readonly company: "Economic Daily"; readonly baseUrls: readonly ["www.ce.cn"]; }, { readonly company: "21st Century Business Herald"; readonly baseUrls: readonly ["www.21jingji.com"]; }, { readonly company: "Beijing Review"; readonly baseUrls: readonly ["www.bjreview.com"]; }, { readonly company: "China Economic Net"; readonly baseUrls: readonly ["www.ce.cn"]; }, { readonly company: "Tencent News"; readonly baseUrls: readonly ["news.qq.com"]; }, { readonly company: "Sina News"; readonly baseUrls: readonly ["news.sina.com.cn"]; }, { readonly company: "NetEase News"; readonly baseUrls: readonly ["news.163.com"]; }, { readonly company: "Phoenix TV"; readonly baseUrls: readonly ["www.ifeng.com"]; }]; /** news sites in Denmark */ declare const DANISH_NEWS: readonly [{ readonly company: "Politiken"; readonly baseUrls: readonly ["www.politiken.dk"]; }, { readonly company: "Berlingske"; readonly baseUrls: readonly ["www.berlingske.dk"]; }, { readonly company: "Jyllands-Posten"; readonly baseUrls: readonly ["jyllands-posten.dk"]; }, { readonly company: "Ekstra Bladet"; readonly baseUrls: readonly ["ekstrabladet.dk"]; }, { readonly company: "Information"; readonly baseUrls: readonly ["www.information.dk"]; }, { readonly company: "BT"; readonly baseUrls: readonly ["www.bt.dk"]; }, { readonly company: "Weekendavisen"; readonly baseUrls: readonly ["www.weekendavisen.dk"]; }, { readonly company: "Fyens Stiftstidende"; readonly baseUrls: readonly ["fyens.dk"]; }, { readonly company: "Kristeligt Dagblad"; readonly baseUrls: readonly ["www.kristeligt-dagblad.dk"]; }, { readonly company: "Copenhagen Post"; readonly baseUrls: readonly ["cphpost.dk"]; }, { readonly company: "Nordjyske Stiftstidende"; readonly baseUrls: readonly ["nordjyske.dk"]; }, { readonly company: "Århus Stiftstidende"; readonly baseUrls: readonly ["stiften.dk"]; }, { readonly company: "Dagbladet Børsen"; readonly baseUrls: readonly ["borsen.dk"]; }, { readonly company: "Lokalavisen"; readonly baseUrls: readonly ["lokalavisen.dk"]; }, { readonly company: "TV2 Nyheder"; readonly baseUrls: readonly ["tv2.dk"]; }, { readonly company: "DR Nyheder"; readonly baseUrls: readonly ["dr.dk"]; }, { readonly company: "Avisen Danmark"; readonly baseUrls: readonly ["avisen.dk"]; }, { readonly company: "Fagbladet 3F"; readonly baseUrls: readonly ["fagbladet3f.dk"]; }, { readonly company: "Herning Folkeblad"; readonly baseUrls: readonly ["herningfolkeblad.dk"]; }, { readonly company: "Midtjyllands Avis"; readonly baseUrls: readonly ["midtjyllandsavis.dk"]; }]; declare const SWISS_NEWS: readonly [{ readonly company: "Neue Zürcher Zeitung (NZZ)"; readonly baseUrls: readonly ["www.nzz.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Swissinfo"; readonly baseUrls: readonly ["www.swissinfo.ch"]; readonly type: readonly ["digital-first"]; }, { readonly company: "20 Minuten"; readonly baseUrls: readonly ["www.20min.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Blick"; readonly baseUrls: readonly ["www.blick.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Le Temps"; readonly baseUrls: readonly ["www.letemps.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Tages-Anzeiger"; readonly baseUrls: readonly ["www.tagesanzeiger.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "SRF News"; readonly baseUrls: readonly ["www.srf.ch"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "Luzerner Zeitung"; readonly baseUrls: readonly ["www.luzernerzeitung.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "La Tribune de Genève"; readonly baseUrls: readonly ["www.tdg.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Aargauer Zeitung"; readonly baseUrls: readonly ["www.aargauerzeitung.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "24 Heures"; readonly baseUrls: readonly ["www.24heures.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Radio Télévision Suisse (RTS)"; readonly baseUrls: readonly ["www.rts.ch"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "Der Bund"; readonly baseUrls: readonly ["www.derbund.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Schweizer Radio und Fernsehen (SRF)"; readonly baseUrls: readonly ["www.srf.ch"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "Basler Zeitung"; readonly baseUrls: readonly ["www.bazonline.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Handelszeitung"; readonly baseUrls: readonly ["www.handelszeitung.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Watson"; readonly baseUrls: readonly ["www.watson.ch"]; readonly type: readonly ["digital-first"]; }, { readonly company: "Le Matin"; readonly baseUrls: readonly ["www.lematin.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "La Liberté"; readonly baseUrls: readonly ["www.laliberte.ch"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "The Swiss Times"; readonly baseUrls: readonly ["www.theswisstimes.ch"]; readonly type: readonly ["digital-first"]; }]; declare const AUSTRALIAN_NEWS: readonly [{ readonly company: "ABC News"; readonly baseUrls: readonly ["www.abc.net.au"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "The Sydney Morning Herald"; readonly baseUrls: readonly ["www.smh.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "The Australian"; readonly baseUrls: readonly ["www.theaustralian.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Herald Sun"; readonly baseUrls: readonly ["www.heraldsun.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "9News"; readonly baseUrls: readonly ["www.9news.com.au"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "SBS News"; readonly baseUrls: readonly ["www.sbs.com.au"]; readonly type: readonly ["television", "digital", "multicultural"]; }, { readonly company: "The Age"; readonly baseUrls: readonly ["www.theage.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Sky News Australia"; readonly baseUrls: readonly ["www.skynews.com.au"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Australian Financial Review"; readonly baseUrls: readonly ["www.afr.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "news.com.au"; readonly baseUrls: readonly ["www.news.com.au"]; readonly type: readonly ["digital-first"]; }, { readonly company: "The Courier-Mail"; readonly baseUrls: readonly ["www.couriermail.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "7NEWS"; readonly baseUrls: readonly ["7news.com.au"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "The West Australian"; readonly baseUrls: readonly ["www.thewest.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Daily Telegraph"; readonly baseUrls: readonly ["www.dailytelegraph.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Guardian Australia"; readonly baseUrls: readonly ["www.theguardian.com/au"]; readonly type: readonly ["digital-first"]; }, { readonly company: "Crikey"; readonly baseUrls: readonly ["www.crikey.com.au"]; readonly type: readonly ["digital-first", "independent"]; }, { readonly company: "AAP (Australian Associated Press)"; readonly baseUrls: readonly ["www.aap.com.au"]; readonly type: readonly ["news agency", "digital"]; }, { readonly company: "NT News"; readonly baseUrls: readonly ["www.ntnews.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "The Canberra Times"; readonly baseUrls: readonly ["www.canberratimes.com.au"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Brisbane Times"; readonly baseUrls: readonly ["www.brisbanetimes.com.au"]; readonly type: readonly ["digital-first"]; }]; declare const JAPANESE_NEWS: readonly [{ readonly company: "The Asahi Shimbun"; readonly baseUrls: readonly ["www.asahi.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Yomiuri Shimbun"; readonly baseUrls: readonly ["www.yomiuri.co.jp"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Nikkei"; readonly baseUrls: readonly ["www.nikkei.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Mainichi Shimbun"; readonly baseUrls: readonly ["mainichi.jp"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Kyodo News"; readonly baseUrls: readonly ["www.kyodonews.jp"]; readonly type: readonly ["news agency", "digital"]; }, { readonly company: "Japan Times"; readonly baseUrls: readonly ["www.japantimes.co.jp"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "NHK"; readonly baseUrls: readonly ["www.nhk.or.jp"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "Fuji News Network (FNN)"; readonly baseUrls: readonly ["www.fnn.jp"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Sankei Shimbun"; readonly baseUrls: readonly ["www.sankei.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Toyo Keizai"; readonly baseUrls: readonly ["www.toyokeizai.net"]; readonly type: readonly ["digital", "business magazine"]; }, { readonly company: "Hokkaido Shimbun"; readonly baseUrls: readonly ["www.hokkaido-np.co.jp"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Shizuoka Shimbun"; readonly baseUrls: readonly ["www.at-s.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Tokyo Shimbun"; readonly baseUrls: readonly ["www.tokyo-np.co.jp"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Yahoo Japan News"; readonly baseUrls: readonly ["news.yahoo.co.jp"]; readonly type: readonly ["digital-first"]; }, { readonly company: "TBS News"; readonly baseUrls: readonly ["news.tbs.co.jp"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Nippon TV News 24 Japan"; readonly baseUrls: readonly ["www.news24.jp"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Jiji Press"; readonly baseUrls: readonly ["www.jiji.com"]; readonly type: readonly ["news agency", "digital"]; }, { readonly company: "TV Asahi News"; readonly baseUrls: readonly ["news.tv-asahi.co.jp"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "WOWOW Prime News"; readonly baseUrls: readonly ["www.wowow.co.jp"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Kansai Telecasting Corporation (KTV)"; readonly baseUrls: readonly ["www.ktv.jp"]; readonly type: readonly ["television", "digital"]; }]; declare const SOUTH_KOREAN_NEWS: readonly [{ readonly company: "Yonhap News Agency"; readonly baseUrls: readonly ["www.yonhapnews.co.kr"]; readonly type: readonly ["news agency", "digital"]; }, { readonly company: "The Korea Herald"; readonly baseUrls: readonly ["www.koreaherald.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "The Korea Times"; readonly baseUrls: readonly ["www.koreatimes.co.kr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Chosun Ilbo"; readonly baseUrls: readonly ["www.chosun.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "JoongAng Ilbo"; readonly baseUrls: readonly ["www.joongang.co.kr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Dong-A Ilbo"; readonly baseUrls: readonly ["www.donga.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "MBC News"; readonly baseUrls: readonly ["www.imnews.imbc.com"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "SBS News"; readonly baseUrls: readonly ["news.sbs.co.kr"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "KBS News"; readonly baseUrls: readonly ["news.kbs.co.kr"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "Hankyoreh"; readonly baseUrls: readonly ["english.hani.co.kr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Maeil Business Newspaper"; readonly baseUrls: readonly ["www.mk.co.kr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "MoneyToday"; readonly baseUrls: readonly ["www.mt.co.kr"]; readonly type: readonly ["digital-first", "business"]; }, { readonly company: "Seoul Shinmun"; readonly baseUrls: readonly ["www.seoul.co.kr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "OhmyNews"; readonly baseUrls: readonly ["www.ohmynews.com"]; readonly type: readonly ["digital-first"]; }, { readonly company: "News1 Korea"; readonly baseUrls: readonly ["www.news1.kr"]; readonly type: readonly ["news agency", "digital"]; }, { readonly company: "Asia Business Daily"; readonly baseUrls: readonly ["www.asiae.co.kr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Herald Business"; readonly baseUrls: readonly ["biz.heraldcorp.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "eDaily"; readonly baseUrls: readonly ["www.edaily.co.kr"]; readonly type: readonly ["digital-first", "business"]; }, { readonly company: "Seoul Economic Daily"; readonly baseUrls: readonly ["www.sedaily.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "JTBC News"; readonly baseUrls: readonly ["news.jtbc.co.kr"]; readonly type: readonly ["television", "digital"]; }]; declare const TURKISH_NEWS: readonly [{ readonly company: "Anadolu Agency (AA)"; readonly baseUrls: readonly ["www.aa.com.tr"]; readonly type: readonly ["news agency", "digital"]; }, { readonly company: "Hürriyet"; readonly baseUrls: readonly ["www.hurriyet.com.tr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Sabah"; readonly baseUrls: readonly ["www.sabah.com.tr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Milliyet"; readonly baseUrls: readonly ["www.milliyet.com.tr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "TRT World"; readonly baseUrls: readonly ["www.trtworld.com"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "CNN Türk"; readonly baseUrls: readonly ["www.cnnturk.com"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Sozcu"; readonly baseUrls: readonly ["www.sozcu.com.tr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Daily Sabah"; readonly baseUrls: readonly ["www.dailysabah.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Yeni Şafak"; readonly baseUrls: readonly ["www.yenisafak.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Habertürk"; readonly baseUrls: readonly ["www.haberturk.com"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "BirGün"; readonly baseUrls: readonly ["www.birgun.net"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Türkiye Gazetesi"; readonly baseUrls: readonly ["www.turkiyegazetesi.com.tr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Cumhuriyet"; readonly baseUrls: readonly ["www.cumhuriyet.com.tr"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Diken"; readonly baseUrls: readonly ["www.diken.com.tr"]; readonly type: readonly ["digital-first"]; }, { readonly company: "NTV"; readonly baseUrls: readonly ["www.ntv.com.tr"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Ensonhaber"; readonly baseUrls: readonly ["www.ensonhaber.com"]; readonly type: readonly ["digital-first"]; }, { readonly company: "T24"; readonly baseUrls: readonly ["www.t24.com.tr"]; readonly type: readonly ["digital-first"]; }, { readonly company: "Karar"; readonly baseUrls: readonly ["www.karar.com"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Gazete Duvar"; readonly baseUrls: readonly ["www.gazeteduvar.com.tr"]; readonly type: readonly ["digital-first"]; }, { readonly company: "Bloomberg HT"; readonly baseUrls: readonly ["www.bloomberght.com"]; readonly type: readonly ["television", "digital"]; }]; declare const NORWEGIAN_NEWS: readonly [{ readonly company: "Aftenposten"; readonly baseUrls: readonly ["www.aftenposten.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Verdens Gang (VG)"; readonly baseUrls: readonly ["www.vg.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Dagbladet"; readonly baseUrls: readonly ["www.dagbladet.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "NRK"; readonly baseUrls: readonly ["www.nrk.no"]; readonly type: readonly ["television", "radio", "digital"]; }, { readonly company: "Dagens Næringsliv"; readonly baseUrls: readonly ["www.dn.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Nettavisen"; readonly baseUrls: readonly ["www.nettavisen.no"]; readonly type: readonly ["digital-first"]; }, { readonly company: "Klassekampen"; readonly baseUrls: readonly ["www.klassekampen.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Morgenbladet"; readonly baseUrls: readonly ["www.morgenbladet.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "E24"; readonly baseUrls: readonly ["www.e24.no"]; readonly type: readonly ["digital-first", "business"]; }, { readonly company: "TV2"; readonly baseUrls: readonly ["www.tv2.no"]; readonly type: readonly ["television", "digital"]; }, { readonly company: "Bergens Tidende"; readonly baseUrls: readonly ["www.bt.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Adresseavisen"; readonly baseUrls: readonly ["www.adressa.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Stavanger Aftenblad"; readonly baseUrls: readonly ["www.aftenbladet.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Fædrelandsvennen"; readonly baseUrls: readonly ["www.fvn.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "ABC Nyheter"; readonly baseUrls: readonly ["www.abcnyheter.no"]; readonly type: readonly ["digital-first"]; }, { readonly company: "Romerikes Blad"; readonly baseUrls: readonly ["www.rb.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Sunnmørsposten"; readonly baseUrls: readonly ["www.smp.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Finansavisen"; readonly baseUrls: readonly ["www.finansavisen.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Nordlys"; readonly baseUrls: readonly ["www.nordlys.no"]; readonly type: readonly ["newspaper", "digital"]; }, { readonly company: "Hamar Arbeiderblad"; readonly baseUrls: readonly ["www.h-a.no"]; readonly type: readonly ["newspaper", "digital"]; }]; //#endregion //#region ../constants/src/NoDefaultValue.d.ts /** * A constant which indicates that a particular * type/property was not given a _default value_. */ declare const NO_DEFAULT_VALUE: Constant<"no-default-value", unknown>; /** * A unique symbol which indicates that a particular * type was not given a "default value". */ type NoDefaultValue = typeof NO_DEFAULT_VALUE; //#endregion //#region ../constants/src/NotDefined.d.ts /** * **NOT_DEFINED** * * A runtime constant which indicates that some value has not been defined (yet). */ declare const NOT_DEFINED: Constant<"not-defined", unknown>; type NotDefined = typeof NOT_DEFINED; //#endregion //#region ../constants/src/NumericChar.d.ts /** * **NUMERIC_CHAR** * * A tuple containing all numeric characters. * * **Related:** `NumericChar` */ declare const NUMERIC_CHAR: ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9"]; /** * **HEXADECIMAL_CHAR** * * All numeric and alpha (upper and lower) characters used to represent * a **hexadecimal** number. */ declare const HEXADECIMAL_CHAR: ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "A", "b", "B", "c", "C", "d", "D", "e", "E", "f", "F"]; //#endregion //#region ../constants/src/Phone.d.ts /** * **PHONE_COUNTRY_CODES** * * `[code, 3 letter country code, 2 letter country code]` */ declare const PHONE_COUNTRY_CODES: readonly [readonly ["886", "TWN", "TW"], readonly ["93", "AFG", "AF"], readonly ["355", "ALB", "AL"], readonly ["213", "DZA", "DZ"], readonly ["1-684", "ASM", "AS"], readonly ["376", "AND", "AD"], readonly ["244", "AGO", "AO"], readonly ["1-264", "AIA", "AI"], readonly ["672", "ATA", "AQ"], readonly ["1-268", "ATG", "AG"], readonly ["54", "ARG", "AR"], readonly ["374", "ARM", "AM"], readonly ["297", "ABW", "AW"], readonly ["61", "AUS", "AU"], readonly ["43", "AUT", "AT"], readonly ["994", "AZE", "AZ"], readonly ["1-242", "BHS", "BS"], readonly ["973", "BHR", "BH"], readonly ["880", "BGD", "BD"], readonly ["1-246", "BRB", "BB"], readonly ["375", "BLR", "BY"], readonly ["32", "BEL", "BE"], readonly ["501", "BLZ", "BZ"], readonly ["229", "BEN", "BJ"], readonly ["1-441", "BMU", "BM"], readonly ["975", "BTN", "BT"], readonly ["591", "BOL", "BO"], readonly ["599", "BES", "BQ"], readonly ["387", "BIH", "BA"], readonly ["267", "BWA", "BW"], readonly ["47", "BVT", "BV"], readonly ["55", "BRA", "BR"], readonly ["246", "IOT", "IO"], readonly ["1-284", "VGB", "VG"], readonly ["673", "BRN", "BN"], readonly ["359", "BGR", "BG"], readonly ["226", "BFA", "BF"], readonly ["257", "BDI", "BI"], readonly ["238", "CPV", "CV"], readonly ["855", "KHM", "KH"], readonly ["237", "CMR", "CM"], readonly ["1", "CAN", "CA"], readonly ["1-345", "CYM", "KY"], readonly ["236", "CAF", "CF"], readonly ["235", "TCD", "TD"], readonly ["56", "CHL", "CL"], readonly ["86", "CHN", "CN"], readonly ["852", "HKG", "HK"], readonly ["853", "MAC", "MO"], readonly ["61", "CXR", "CX"], readonly ["61", "CCK", "CC"], readonly ["57", "COL", "CO"], readonly ["269", "COM", "KM"], readonly ["242", "COG", "CG"], readonly ["682", "COK", "CK"], readonly ["506", "CRI", "CR"], readonly ["385", "HRV", "HR"], readonly ["53", "CUB", "CU"], readonly ["599", "CUW", "CW"], readonly ["357", "CYP", "CY"], readonly ["420", "CZE", "CZ"], readonly ["225", "CIV", "CI"], readonly ["850", "PRK", "KP"], readonly ["243", "COD", "CD"], readonly ["45", "DNK", "DK"], readonly ["253", "DJI", "DJ"], readonly ["1-767", "DMA", "DM"], readonly ["1-809", "DOM", "DO"], readonly ["1-829", "DOM", "DO"], readonly ["1-849", "DOM", "DO"], readonly ["593", "ECU", "EC"], readonly ["20", "EGY", "EG"], readonly ["503", "SLV", "SV"], readonly ["240", "GNQ", "GQ"], readonly ["291", "ERI", "ER"], readonly ["372", "EST", "EE"], readonly ["268", "SWZ", "SZ"], readonly ["251", "ETH", "ET"], readonly ["500", "FLK", "FK"], readonly ["298", "FRO", "FO"], readonly ["679", "FJI", "FJ"], readonly ["358", "FIN", "FI"], readonly ["33", "FRA", "FR"], readonly ["594", "GUF", "GF"], readonly ["689", "PYF", "PF"], readonly ["262", "ATF", "TF"], readonly ["241", "GAB", "GA"], readonly ["220", "GMB", "GM"], readonly ["995", "GEO", "GE"], readonly ["49", "DEU", "DE"], readonly ["233", "GHA", "GH"], readonly ["350", "GIB", "GI"], readonly ["30", "GRC", "GR"], readonly ["299", "GRL", "GL"], readonly ["1-473", "GRD", "GD"], readonly ["590", "GLP", "GP"], readonly ["1-671", "GUM", "GU"], readonly ["502", "GTM", "GT"], readonly ["44", "GGY", "GG"], readonly ["224", "GIN", "GN"], readonly ["245", "GNB", "GW"], readonly ["592", "GUY", "GY"], readonly ["509", "HTI", "HT"], readonly ["672", "HMD", "HM"], readonly ["39-06", "VAT", "VA"], readonly ["504", "HND", "HN"], readonly ["36", "HUN", "HU"], readonly ["354", "ISL", "IS"], readonly ["91", "IND", "IN"], readonly ["62", "IDN", "ID"], readonly ["98", "IRN", "IR"], readonly ["964", "IRQ", "IQ"], readonly ["353", "IRL", "IE"], readonly ["44", "IMN", "IM"], readonly ["972", "ISR", "IL"], readonly ["39", "ITA", "IT"], readonly ["1-876", "JAM", "JM"], readonly ["81", "JPN", "JP"], readonly ["44", "JEY", "JE"], readonly ["962", "JOR", "JO"], readonly ["7", "KAZ", "KZ"], readonly ["254", "KEN", "KE"], readonly ["686", "KIR", "KI"], readonly ["965", "KWT", "KW"], readonly ["996", "KGZ", "KG"], readonly ["856", "LAO", "LA"], readonly ["371", "LVA", "LV"], readonly ["961", "LBN", "LB"], readonly ["266", "LSO", "LS"], readonly ["231", "LBR", "LR"], readonly ["218", "LBY", "LY"], readonly ["423", "LIE", "LI"], readonly ["370", "LTU", "LT"], readonly ["352", "LUX", "LU"], readonly ["261", "MDG", "MG"], readonly ["265", "MWI", "MW"], readonly ["60", "MYS", "MY"], readonly ["960", "MDV", "MV"], readonly ["223", "MLI", "ML"], readonly ["356", "MLT", "MT"], readonly ["692", "MHL", "MH"], readonly ["596", "MTQ", "MQ"], readonly ["222", "MRT", "MR"], readonly ["230", "MUS", "MU"], readonly ["262", "MYT", "YT"], readonly ["52", "MEX", "MX"], readonly ["691", "FSM", "FM"], readonly ["377", "MCO", "MC"], readonly ["976", "MNG", "MN"], readonly ["382", "MNE", "ME"], readonly ["1-664", "MSR", "MS"], readonly ["212", "MAR", "MA"], readonly ["258", "MOZ", "MZ"], readonly ["95", "MMR", "MM"], readonly ["264", "NAM", "NA"], readonly ["674", "NRU", "NR"], readonly ["977", "NPL", "NP"], readonly ["31", "NLD", "NL"], readonly ["687", "NCL", "NC"], readonly ["64", "NZL", "NZ"], readonly ["505", "NIC", "NI"], readonly ["227", "NER", "NE"], readonly ["234", "NGA", "NG"], readonly ["683", "NIU", "NU"], readonly ["672", "NFK", "NF"], readonly ["1-670", "MNP", "MP"], readonly ["47", "NOR", "NO"], readonly ["968", "OMN", "OM"], readonly ["92", "PAK", "PK"], readonly ["680", "PLW", "PW"], readonly ["507", "PAN", "PA"], readonly ["675", "PNG", "PG"], readonly ["595", "PRY", "PY"], readonly ["51", "PER", "PE"], readonly ["63", "PHL", "PH"], readonly ["870", "PCN", "PN"], readonly ["48", "POL", "PL"], readonly ["351", "PRT", "PT"], readonly ["974", "QAT", "QA"], readonly ["82", "KOR", "KR"], readonly ["373", "MDA", "MD"], readonly ["40", "ROU", "RO"], readonly ["7", "RUS", "RU"], readonly ["250", "RWA", "RW"], readonly ["262", "REU", "RE"], readonly ["590", "BLM", "BL"], readonly ["290", "SHN", "SH"], readonly ["1-869", "KNA", "KN"], readonly ["1-758", "LCA", "LC"], readonly ["590", "MAF", "MF"], readonly ["508", "SPM", "PM"], readonly ["1-784", "VCT", "VC"], readonly ["685", "WSM", "WS"], readonly ["378", "SMR", "SM"], readonly ["239", "STP", "ST"], readonly ["966", "SAU", "SA"], readonly ["221", "SEN", "SN"], readonly ["381", "SRB", "RS"], readonly ["248", "SYC", "SC"], readonly ["232", "SLE", "SL"], readonly ["65", "SGP", "SG"], readonly ["1-721", "SXM", "SX"], readonly ["421", "SVK", "SK"], readonly ["386", "SVN", "SI"], readonly ["677", "SLB", "SB"], readonly ["252", "SOM", "SO"], readonly ["27", "ZAF", "ZA"], readonly ["500", "SGS", "GS"], readonly ["211", "SSD", "SS"], readonly ["34", "ESP", "ES"], readonly ["94", "LKA", "LK"], readonly ["970", "PSE", "PS"], readonly ["249", "SDN", "SD"], readonly ["597", "SUR", "SR"], readonly ["47", "SJM", "SJ"], readonly ["46", "SWE", "SE"], readonly ["41", "CHE", "CH"], readonly ["963", "SYR", "SY"], readonly ["992", "TJK", "TJ"], readonly ["66", "THA", "TH"], readonly ["389", "MKD", "MK"], readonly ["670", "TLS", "TL"], readonly ["228", "TGO", "TG"], readonly ["690", "TKL", "TK"], readonly ["676", "TON", "TO"], readonly ["1-868", "TTO", "TT"], readonly ["216", "TUN", "TN"], readonly ["90", "TUR", "TR"], readonly ["993", "TKM", "TM"], readonly ["1-649", "TCA", "TC"], readonly ["688", "TUV", "TV"], readonly ["256", "UGA", "UG"], readonly ["380", "UKR", "UA"], readonly ["971", "ARE", "AE"], readonly ["44", "GBR", "GB"], readonly ["255", "TZA", "TZ"], readonly ["1-340", "VIR", "VI"], readonly ["1", "USA", "US"], readonly ["598", "URY", "UY"], readonly ["998", "UZB", "UZ"], readonly ["678", "VUT", "VU"], readonly ["58", "VEN", "VE"], readonly ["84", "VNM", "VN"], readonly ["681", "WLF", "WF"], readonly ["212", "ESH", "EH"], readonly ["967", "YEM", "YE"], readonly ["260", "ZMB", "ZM"], readonly ["263", "ZWE", "ZW"], readonly ["358", "ALA", "AX"]]; //#endregion //#region ../constants/src/PluralExceptions.d.ts /** * **PLURAL_EXCEPTIONS** * * A lookup table that maps singular words to their _plural_ counterpart. */ declare const PLURAL_EXCEPTIONS: { readonly photo: "photos"; readonly piano: "pianos"; readonly halo: "halos"; readonly foot: "feet"; readonly man: "men"; readonly woman: "women"; readonly person: "people"; readonly mouse: "mice"; readonly series: "series"; readonly sheep: "sheep"; readonly money: "monies"; readonly deer: "deer"; readonly goose: "geese"; readonly child: "children"; readonly tooth: "teeth"; readonly ox: "oxen"; readonly basis: "bases"; readonly radius: "radii"; readonly syllabus: "syllabi"; readonly ice: "ice"; readonly fish: "fish"; readonly means: "means"; readonly phenomenon: "phenomena"; readonly criterion: "criteria"; readonly datum: "data"; readonly memorandum: "memoranda"; readonly bacterium: "bacteria"; readonly stratum: "strata"; readonly curriculum: "curricula"; readonly index: "indices"; readonly appendix: "appendices"; readonly vortex: "vortices"; readonly bison: "bison"; readonly axis: "axes"; readonly antenna: "antennas"; readonly cactus: "cacti"; readonly corpus: "corpora"; readonly beau: "beaux"; readonly die: "dice"; readonly ellipsis: "ellipses"; readonly erratum: "errata"; readonly focus: "foci"; readonly formula: "formulas"; readonly fungus: "fungi"; readonly genus: "genera"; readonly graffito: "graffiti"; readonly grouse: "grouses"; readonly half: "halves"; readonly hoof: "hooves"; readonly hypothesis: "hypothesis"; readonly larva: "larvae"; readonly libretto: "libretti"; readonly loaf: "loaves"; readonly locus: "loci"; readonly medium: "mediums"; readonly minutia: "minutiae"; readonly nucleus: "nuclei"; readonly oasis: "oases"; readonly opus: "opuses"; readonly ovum: "ova"; readonly parenthesis: "parentheses"; readonly phylum: "phyla"; readonly quiz: "quizzes"; readonly referendum: "referendums"; readonly self: "selves"; readonly species: "species"; readonly stimulus: "stimuli"; readonly swine: "swine"; readonly synopsis: "synopses"; readonly thesis: "theses"; readonly thief: "thieves"; readonly vertex: "vertexes"; readonly wife: "wives"; readonly wolf: "wolves"; }; //#endregion //#region ../constants/src/RepoConstants.d.ts /** * common sources for source code repositories */ declare const REPO_SOURCES: readonly ["github", "bitbucket", "gitlab", "codecommit", "local"]; declare const REPO_SOURCE_LOOKUP: { readonly github: readonly ["https://github.com", "https://github.io"]; readonly bitbucket: readonly ["https://bitbucket.org"]; readonly gitlab: readonly ["https://gitlab.com"]; readonly codecommit: readonly ["https://aws.amazon.com/codecommit/"]; readonly local: readonly []; }; //#endregion //#region ../constants/src/Retail.d.ts /** * Amazon's DNS entries (for retail business) */ declare const AMAZON_DNS: readonly ["www.amazon.com", "www.amazon.co.uk", "www.amazon.fr", "www.amazon.de", "www.amazon.it", "www.amazon.es"]; declare const WALMART_DNS: readonly ["www.walmart.com", "www.walmart.ca", "www.walmart.com.mx"]; declare const APPLE_DNS: readonly ["store.apple.com", "www.apple.com"]; declare const HOME_DEPOT_DNS: readonly ["www.homedepot.com", "www.homedepot.ca"]; declare const EBAY_DNS: readonly ["www.ebay.com", "www.ebay.co.uk", "www.ebay.fr", "www.ebay.de", "www.ebay.it"]; declare const TARGET_DNS: readonly ["www.target.com"]; declare const ETSY_DNS: readonly ["www.etsy.com"]; declare const COSTCO_DNS: readonly ["www.costco.com", "www.costco.co.uk", "www.costco.ca"]; declare const CHEWY_DNS: readonly ["www.chewy.com"]; declare const BEST_BUY_DNS: readonly ["www.bestbuy.com", "www.bestbuy.ca"]; declare const WAYFAIR_DNS: readonly ["www.wayfair.com", "www.wayfair.ca", "www.wayfair.co.uk"]; declare const NIKE_DNS: readonly ["www.nike.com"]; declare const MACYS_DNS: readonly ["www.macys.com"]; declare const LOWES_DNS: readonly ["www.lowes.com"]; declare const IKEA_DNS: readonly ["www.ikea.com"]; declare const DELL_DNS: readonly ["www.dell.com"]; /** DNS for H&M retailer */ declare const HM_DNS: readonly ["www2.hm.com"]; declare const ZARA_DNS: readonly ["www.zara.com"]; declare const KROGER_DNS: readonly ["www.kroger.com"]; declare const WALGREENS_DNS: readonly ["www.walgreens.com"]; declare const CVS_DNS: readonly ["www.cvs.com"]; declare const WHOLE_FOODS_DNS: readonly ["www.wholefoodsmarket.com", "www.wholefoodsmarket.co.uk"]; //#endregion //#region ../constants/src/SafeEncoding.d.ts declare const SAFE_ENCODING__QUOTES: { readonly "\"": "^"; readonly "'": "^"; readonly "`": "^"; }; declare const SAFE_ENCODING__WHITESPACE: { readonly " ": "^"; readonly "\t": "^"; readonly "\n": "^"; readonly "\r": "^"; }; declare const SAFE_ENCODING__BRACKETS: { readonly "[": "^"; readonly "]": "^"; readonly "(": "^"; readonly ")": "^"; readonly "{": "^"; readonly "}": "^"; }; //#endregion //#region ../constants/src/SimpleTokens.d.ts declare const SIMPLE_DICT_VALUES: readonly ["string", "number", "boolean", "unknown", "Opt", "Opt", "Opt", "Opt"]; declare const SIMPLE_SET_TYPES: readonly ["string", "number", "boolean", "unknown", "Opt", "Opt", "Opt", "Opt"]; declare const SIMPLE_SCALAR_TOKENS: readonly ["string", "number", `string(${string})`, `number(${number})` | `number(${number},${string})`, "boolean", "true", "false", "null", "undefined", "unknown", "any", "never"]; declare const SIMPLE_OPT_SCALAR_TOKENS: readonly ["Opt", "Opt", "Opt", "Opt", "Opt", "Opt", "Opt", "Opt", "Opt", `Opt` | `Opt`, `Opt"]; declare const SIMPLE_UNION_TOKENS: readonly [`union(${string})` | `union(${string},${string})`]; declare const SIMPLE_MAP_KEYS: readonly ["string", "number", "Dict", "Dict", "Dict", "Dict", "Dict", "Dict>", "Dict>", "Dict>"]; declare const SIMPLE_MAP_VALUES: readonly ["string", "number", "Dict", "Dict", "Dict", "Dict", "Dict", "Dict>", "Dict>", "Dict>", "boolean", "unknown", "undefined", "Dict", "Array", "Dict>", "Dict>", "Dict>", "Dict>"]; declare const SIMPLE_DICT_TOKENS: readonly ["Dict", "Dict", "Dict", "Dict", "Dict", "Dict>", "Dict>", "Dict>", "Dict>", `Dict<{${string}: string}>` | `Dict<{${string}: number}>` | `Dict<{${string}: boolean}>` | `Dict<{${string}: undefined}>` | `Dict<{${string}: null}>` | `Dict<{${string}: unknown}>` | `Dict<{${string}: true}>` | `Dict<{${string}: false}>` | `Dict<{${string}: string(${string})}>` | `Dict<{${string}: number(${number})}>` | `Dict<{${string}: number(${number},${string})}>` | `Dict<{${string}: any}>` | `Dict<{${string}: never}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt}>` | `Dict<{${string}: Opt` | `Dict<{${string}: Opt`, `Dict<{${string}: string, ${string}: ${string}}` | `Dict<{${string}: number, ${string}: ${string}}` | `Dict<{${string}: boolean, ${string}: ${string}}` | `Dict<{${string}: undefined, ${string}: ${string}}` | `Dict<{${string}: null, ${string}: ${string}}` | `Dict<{${string}: unknown, ${string}: ${string}}` | `Dict<{${string}: true, ${string}: ${string}}` | `Dict<{${string}: false, ${string}: ${string}}` | `Dict<{${string}: string(${string}), ${string}: ${string}}` | `Dict<{${string}: number(${number}), ${string}: ${string}}` | `Dict<{${string}: number(${number},${string}), ${string}: ${string}}` | `Dict<{${string}: any, ${string}: ${string}}` | `Dict<{${string}: never, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt, ${string}: ${string}}` | `Dict<{${string}: Opt", `Array`, "Array", `Array` | `Array`, "Array", "Array", "Array", "Array", "Array"]; declare const SIMPLE_MAP_TOKENS: readonly ["Map", "Map" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map>" | "Map>" | "Map>" | "Map>" | "Map>>" | "Map>>" | "Map>>" | "Map>>" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map>" | "Map>" | "Map>" | "Map>" | "Map>>" | "Map>>" | "Map>>" | "Map>>" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map" | "Map>" | "Map>" | "Map>" | "Map>" | "Map>>" | "Map>>" | "Map>>" | "Map>>" | "Map, string>" | "Map, number>" | "Map, boolean>" | "Map, undefined>" | "Map, unknown>" | "Map, Array>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, string>" | "Map, number>" | "Map, boolean>" | "Map, undefined>" | "Map, unknown>" | "Map, Array>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, string>" | "Map, number>" | "Map, boolean>" | "Map, undefined>" | "Map, unknown>" | "Map, Array>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, string>" | "Map, number>" | "Map, boolean>" | "Map, undefined>" | "Map, unknown>" | "Map, Array>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map, Dict>>" | "Map>, string>" | "Map>, number>" | "Map>, boolean>" | "Map>, undefined>" | "Map>, unknown>" | "Map>, Array>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, string>" | "Map>, number>" | "Map>, boolean>" | "Map>, undefined>" | "Map>, unknown>" | "Map>, Array>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, string>" | "Map>, number>" | "Map>, boolean>" | "Map>, undefined>" | "Map>, unknown>" | "Map>, Array>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, Dict>>" | "Map>, Dict>>", "WeakMap"]; declare const SIMPLE_SET_TOKENS: readonly ["Set", "Set" | "Set" | "Set" | "Set" | "Set>" | "Set>" | "Set>" | "Set>"]; //#endregion //#region ../constants/src/Social.d.ts declare const SOCIAL_MEDIA: [{ readonly name: "Facebook"; readonly description: "Connect with friends, family, and communities worldwide on one of the largest social networks."; readonly baseUrls: ["https://www.facebook.com"]; readonly profileUrl: "https://www.facebook.com/:user_id"; readonly approximateUserSize: 3000000000; readonly tickerSymbol: "META"; }, { readonly name: "YouTube"; readonly description: "A platform for sharing and watching videos, connecting creators with audiences globally."; readonly baseUrls: ["https://www.youtube.com"]; readonly profileUrl: "https://www.youtube.com/user/:user_id"; readonly approximateUserSize: 2500000000; readonly tickerSymbol: "GOOGL"; }, { readonly name: "WhatsApp"; readonly description: "A secure messaging app for personal and business communication."; readonly baseUrls: ["https://www.whatsapp.com", "https://wa.me"]; readonly profileUrl: "https://wa.me/:user_id"; readonly approximateUserSize: 2000000000; readonly tickerSymbol: "META"; }, { readonly name: "Instagram"; readonly description: "Share photos and videos with friends and followers through posts, stories, and reels."; readonly baseUrls: ["https://www.instagram.com"]; readonly profileUrl: "https://www.instagram.com/:user_id"; readonly approximateUserSize: 2000000000; readonly tickerSymbol: "META"; }, { readonly name: "TikTok"; readonly description: "A short-form video platform known for its highly engaging content and viral trends."; readonly baseUrls: ["https://www.tiktok.com"]; readonly profileUrl: "https://www.tiktok.com/@:user_id"; readonly approximateUserSize: 1600000000; }, { readonly name: "WeChat"; readonly description: "China's popular messaging and lifestyle app, integrating social media and mobile payments."; readonly baseUrls: ["https://www.wechat.com"]; readonly profileUrl: "https://www.wechat.com/:user_id"; readonly approximateUserSize: 1300000000; }, { readonly name: "Facebook Messenger"; readonly description: "A messaging app used for personal and business interactions, seamlessly integrated with Facebook."; readonly baseUrls: ["https://www.messenger.com"]; readonly profileUrl: "https://www.messenger.com/t/:user_id"; readonly approximateUserSize: 1000000000; readonly tickerSymbol: "META"; }, { readonly name: "Telegram"; readonly description: "A messaging platform focused on privacy, with channels and group capabilities."; readonly baseUrls: ["https://www.telegram.org", "https://t.me"]; readonly profileUrl: "https://t.me/:user_id"; readonly approximateUserSize: 900000000; }, { readonly name: "Snapchat"; readonly description: "A multimedia app popular for its disappearing messages and creative filters."; readonly baseUrls: ["https://www.snapchat.com"]; readonly profileUrl: "https://www.snapchat.com/add/:user_id"; readonly approximateUserSize: 800000000; readonly tickerSymbol: "SNAP"; }, { readonly name: "Douyin"; readonly description: "The Chinese version of TikTok, with similar short-form video content tailored for China."; readonly baseUrls: ["https://www.douyin.com"]; readonly profileUrl: "https://www.douyin.com/user/:user_id"; readonly approximateUserSize: 750000000; }, { readonly name: "LinkedIn"; readonly description: "The largest professional networking platform, where users connect for career opportunities, insights, and business networking."; readonly baseUrls: ["https://www.linkedin.com"]; readonly profileUrl: "https://www.linkedin.com/in/:user_id"; readonly approximateUserSize: 930000000; readonly tickerSymbol: "MSFT"; }, { readonly name: "X (formerly Twitter)"; readonly description: "A platform for real-time updates, news sharing, and public discourse with a focus on brief, impactful posts."; readonly baseUrls: ["https://www.twitter.com", "https://x.com"]; readonly profileUrl: "https://twitter.com/:user_id"; readonly approximateUserSize: 540000000; }, { readonly name: "Pinterest"; readonly description: "A visually-driven platform for sharing ideas, DIY projects, fashion, and more."; readonly baseUrls: ["https://www.pinterest.com"]; readonly profileUrl: "https://www.pinterest.com/:user_id"; readonly approximateUserSize: 460000000; readonly tickerSymbol: "PINS"; }, { readonly name: "Reddit"; readonly description: "A community-driven platform organized into niche forums or 'subreddits' focused on various topics."; readonly baseUrls: ["https://www.reddit.com"]; readonly profileUrl: "https://www.reddit.com/user/:user_id"; readonly approximateUserSize: 430000000; }, { readonly name: "Clubhouse"; readonly description: "A voice-based social network where users engage in live audio conversations on various topics."; readonly baseUrls: ["https://www.clubhouse.com"]; readonly profileUrl: "https://www.clubhouse.com/:user_id"; readonly approximateUserSize: 10000000; }, { readonly name: "Discord"; readonly description: "Originally aimed at gamers, Discord is now widely used by various communities for group chat, video, and voice calls."; readonly baseUrls: ["https://www.discord.com", "https://discord.com"]; readonly profileUrl: "https://discord.com/users/:user_id"; readonly approximateUserSize: 300000000; }]; //#endregion //#region ../constants/src/Tailwind.d.ts declare const TW_HUE_NEUTRAL: { readonly slate: 262; readonly gray: 270; readonly zinc: 269; readonly neutral: 270; readonly stone: 273; }; declare const TW_HUE_VIBRANT: { readonly red: 24; readonly orange: 44; readonly amber: 79; readonly yellow: 100; readonly lime: 132; readonly green: 144; readonly emerald: 159; readonly teal: 182; readonly cyan: 192; readonly sky: 219; readonly blue: 240; readonly indigo: 268; readonly violet: 283; readonly purple: 294; readonly fuchsia: 319; readonly pink: 334; readonly rose: 15; }; /** * **TW_COLOR_HUE** * * The _hue_ values for [TailwindCSS](https://tailwindcss.com/docs/customizing-colors) * when moved into the **oklch** color space. */ declare const TW_HUE: { readonly black: 0; readonly white: 106.37411429114086; readonly red: 24; readonly orange: 44; readonly amber: 79; readonly yellow: 100; readonly lime: 132; readonly green: 144; readonly emerald: 159; readonly teal: 182; readonly cyan: 192; readonly sky: 219; readonly blue: 240; readonly indigo: 268; readonly violet: 283; readonly purple: 294; readonly fuchsia: 319; readonly pink: 334; readonly rose: 15; readonly slate: 262; readonly gray: 270; readonly zinc: 269; readonly neutral: 270; readonly stone: 273; }; declare const TW_LUMINOSITY: { readonly 50: 97.78; readonly 100: 93.56; readonly 200: 88.11; readonly 300: 82.67; readonly 400: 74.22; readonly 500: 64.78; readonly 600: 57.33; readonly 700: 46.89; readonly 800: 39.44; readonly 900: 32; readonly 950: 23.78; }; /** * **TW_CHROMA** * * The possible chroma values from Tailwind CSS when using * the **okhsl** color model. * * **Related:** `TW_CHROMA_50`, `TW_CHROMA_100`, ... */ declare const TW_CHROMA: { readonly 50: 0.0108; readonly 100: 0.0321; readonly 200: 0.0609; readonly 300: 0.0908; readonly 400: 0.1398; readonly 500: 0.1472; readonly 600: 0.1299; readonly 700: 0.1067; readonly 800: 0.0898; readonly 900: 0.0726; readonly 950: 0.054; }; /** * The list of "targets" where Tailwind color string references * can be applied to. These domains are prefixes to the color string * when used (e.g., `bg-green-500`) */ declare const TW_COLOR_TARGETS: readonly ["bg", "text", "border", "ring", "shadow", "border"]; declare const TW_MODIFIERS_CORE: readonly ["dark", "focus", "hover", "active", "visited", "disabled"]; declare const TW_MODIFIERS_ORDER: readonly ["first", "last", "odd", "even"]; declare const TW_MODIFIERS_RELN: readonly ["focus-within", "focus-visible", "checked", "peer-invalid", "peer-checked/{{string}}"]; /** * The list of page size prefixes which Tailwind provides for adjusting to * device size. These are the defaults and can be customized. */ declare const TW_MODIFIERS_SIZING: readonly ["sm", "md", "lg", "xl", "2xl"]; //#endregion //#region ../constants/src/Timezones.d.ts declare const IANA_TIMEZONES: readonly ["Africa/Abidjan", "Africa/Accra", "Africa/Addis_Ababa", "Africa/Algiers", "Africa/Asmara", "Africa/Bamako", "Africa/Bangui", "Africa/Banjul", "Africa/Bissau", "Africa/Blantyre", "Africa/Brazzaville", "Africa/Bujumbura", "Africa/Cairo", "Africa/Casablanca", "Africa/Ceuta", "Africa/Conakry", "Africa/Dakar", "Africa/Dar_es_Salaam", "Africa/Djibouti", "Africa/Douala", "Africa/El_Aaiun", "Africa/Freetown", "Africa/Gaborone", "Africa/Harare", "Africa/Johannesburg", "Africa/Juba", "Africa/Kampala", "Africa/Khartoum", "Africa/Kigali", "Africa/Kinshasa", "Africa/Lagos", "Africa/Libreville", "Africa/Lome", "Africa/Luanda", "Africa/Lubumbashi", "Africa/Lusaka", "Africa/Malabo", "Africa/Maputo", "Africa/Maseru", "Africa/Mbabane", "Africa/Mogadishu", "Africa/Monrovia", "Africa/Nairobi", "Africa/Ndjamena", "Africa/Niamey", "Africa/Nouakchott", "Africa/Ouagadougou", "Africa/Porto-Novo", "Africa/Sao_Tome", "Africa/Tripoli", "Africa/Tunis", "Africa/Windhoek", "America/Adak", "America/Anchorage", "America/Anguilla", "America/Antigua", "America/Araguaina", "America/Argentina/Buenos_Aires", "America/Argentina/Catamarca", "America/Argentina/Cordoba", "America/Argentina/Jujuy", "America/Argentina/La_Rioja", "America/Argentina/Mendoza", "America/Argentina/Rio_Gallegos", "America/Argentina/Salta", "America/Argentina/San_Juan", "America/Argentina/San_Luis", "America/Argentina/Tucuman", "America/Argentina/Ushuaia", "America/Aruba", "America/Asuncion", "America/Atikokan", "America/Atka", "America/Bahia", "America/Bahia_Banderas", "America/Barbados", "America/Belem", "America/Belize", "America/Blanc-Sablon", "America/Boa_Vista", "America/Bogota", "America/Boise", "America/Cambridge_Bay", "America/Campo_Grande", "America/Cancun", "America/Caracas", "America/Cayenne", "America/Cayman", "America/Chicago", "America/Chihuahua", "America/Creston", "America/Cuiaba", "America/Curacao", "America/Danmarkshavn", "America/Dawson", "America/Dawson_Creek", "America/Denver", "America/Detroit", "America/Dominica", "America/Edmonton", "America/Eirunepe", "America/El_Salvador", "America/Fort_Nelson", "America/Fortaleza", "America/Glace_Bay", "America/Godthab", "America/Goose_Bay", "America/Grand_Turk", "America/Grenada", "America/Guadeloupe", "America/Guatemala", "America/Guayaquil", "America/Guyana", "America/Halifax", "America/Havana", "America/Hermosillo", "America/Indiana/Indianapolis", "America/Indiana/Knox", "America/Indiana/Marengo", "America/Indiana/Petersburg", "America/Indiana/Tell_City", "America/Indiana/Vevay", "America/Indiana/Vincennes", "America/Indiana/Winamac", "America/Inuvik", "America/Iqaluit", "America/Jamaica", "America/Juneau", "America/Kentucky/Louisville", "America/Kentucky/Monticello", "America/Kralendijk", "America/La_Paz", "America/Lima", "America/Los_Angeles", "America/Lower_Princes", "America/Maceio", "America/Managua", "America/Manaus", "America/Marigot", "America/Martinique", "America/Matamoros", "America/Mazatlan", "America/Menominee", "America/Merida", "America/Metlakatla", "America/Mexico_City", "America/Miquelon", "America/Moncton", "America/Monterrey", "America/Montevideo", "America/Montserrat", "America/Nassau", "America/New_York", "America/Nipigon", "America/Nome", "America/Noronha", "America/North_Dakota/Beulah", "America/North_Dakota/Center", "America/North_Dakota/New_Salem", "America/Ojinaga", "America/Panama", "America/Pangnirtung", "America/Paramaribo", "America/Phoenix", "America/Port-au-Prince", "America/Port_of_Spain", "America/Porto_Velho", "America/Puerto_Rico", "America/Punta_Arenas", "America/Rainy_River", "America/Rankin_Inlet", "America/Recife", "America/Regina", "America/Resolute", "America/Rio_Branco", "America/Santarem", "America/Santiago", "America/Santo_Domingo", "America/Sao_Paulo", "America/Scoresbysund", "America/Sitka", "America/St_Barthelemy", "America/St_Johns", "America/St_Kitts", "America/St_Lucia", "America/St_Thomas", "America/St_Vincent", "America/Swift_Current", "America/Tegucigalpa", "America/Thule", "America/Thunder_Bay", "America/Tijuana", "America/Toronto", "America/Tortola", "America/Vancouver", "America/Whitehorse", "America/Winnipeg", "America/Yakutat", "America/Yellowknife", "Antarctica/Casey", "Antarctica/Davis", "Antarctica/DumontDUrville", "Antarctica/Macquarie", "Antarctica/Mawson", "Antarctica/McMurdo", "Antarctica/Palmer", "Antarctica/Rothera", "Antarctica/South_Pole", "Antarctica/Syowa", "Antarctica/Troll", "Antarctica/Vostok", "Arctic/Longyearbyen", "Asia/Almaty", "Asia/Amman", "Asia/Anadyr", "Asia/Aqtau", "Asia/Aqtobe", "Asia/Ashgabat", "Asia/Atyrau", "Asia/Baghdad", "Asia/Baku", "Asia/Bangkok", "Asia/Barnaul", "Asia/Beirut", "Asia/Bishkek", "Asia/Brunei", "Asia/Chita", "Asia/Choibalsan", "Asia/Colombo", "Asia/Damascus", "Asia/Dhaka", "Asia/Dili", "Asia/Dubai", "Asia/Dushanbe", "Asia/Famagusta", "Asia/Gaza", "Asia/Hebron", "Asia/Ho_Chi_Minh", "Asia/Hong_Kong", "Asia/Hovd", "Asia/Irkutsk", "Asia/Jakarta", "Asia/Jayapura", "Asia/Jerusalem", "Asia/Kabul", "Asia/Kamchatka", "Asia/Karachi", "Asia/Kathmandu", "Asia/Khandyga", "Asia/Kolkata", "Asia/Krasnoyarsk", "Asia/Kuala_Lumpur", "Asia/Kuching", "Asia/Kuwait", "Asia/Macau", "Asia/Magadan", "Asia/Makassar", "Asia/Manila", "Asia/Muscat", "Asia/Nicosia", "Asia/Novokuznetsk", "Asia/Novosibirsk", "Asia/Omsk", "Asia/Oral", "Asia/Phnom_Penh", "Asia/Pontianak", "Asia/Pyongyang", "Asia/Qatar", "Asia/Qostanay", "Asia/Qyzylorda", "Asia/Riyadh", "Asia/Sakhalin", "Asia/Samarkand", "Asia/Seoul", "Asia/Shanghai", "Asia/Singapore", "Asia/Srednekolymsk", "Asia/Taipei", "Asia/Tashkent", "Asia/Tbilisi", "Asia/Tehran", "Asia/Thimphu", "Asia/Tokyo", "Asia/Tomsk", "Asia/Ulaanbaatar", "Asia/Urumqi", "Asia/Ust-Nera", "Asia/Vientiane", "Asia/Vladivostok", "Asia/Yakutsk", "Asia/Yangon", "Asia/Yekaterinburg", "Asia/Yerevan", "Atlantic/Azores", "Atlantic/Bermuda", "Atlantic/Canary", "Atlantic/Cape_Verde", "Atlantic/Faroe", "Atlantic/Madeira", "Atlantic/Reykjavik", "Atlantic/South_Georgia", "Atlantic/St_Helena", "Atlantic/Stanley", "Australia/Adelaide", "Australia/Brisbane", "Australia/Broken_Hill", "Australia/Currie", "Australia/Darwin", "Australia/Eucla", "Australia/Hobart", "Australia/Lindeman", "Australia/Lord_Howe", "Australia/Melbourne", "Australia/Perth", "Australia/Sydney", "Europe/Amsterdam", "Europe/Andorra", "Europe/Astrakhan", "Europe/Athens", "Europe/Belgrade", "Europe/Berlin", "Europe/Brussels", "Europe/Bucharest", "Europe/Budapest", "Europe/Chisinau", "Europe/Copenhagen", "Europe/Dublin", "Europe/Gibraltar", "Europe/Guernsey", "Europe/Helsinki", "Europe/Isle_of_Man", "Europe/Istanbul", "Europe/Jersey", "Europe/Kaliningrad", "Europe/Kiev", "Europe/Kirov", "Europe/Lisbon", "Europe/Ljubljana", "Europe/London", "Europe/Luxembourg", "Europe/Madrid", "Europe/Malta", "Europe/Mariehamn", "Europe/Minsk", "Europe/Monaco", "Europe/Moscow", "Europe/Oslo", "Europe/Paris", "Europe/Podgorica", "Europe/Prague", "Europe/Riga", "Europe/Rome", "Europe/Samara", "Europe/San_Marino", "Europe/Sarajevo", "Europe/Simferopol", "Europe/Skopje", "Europe/Sofia", "Europe/Stockholm", "Europe/Tallinn", "Europe/Tirane", "Europe/Ulyanovsk", "Europe/Uzhgorod", "Europe/Vaduz", "Europe/Vatican", "Europe/Vienna", "Europe/Vilnius", "Europe/Volgograd", "Europe/Warsaw", "Europe/Zagreb", "Europe/Zaporozhye", "Europe/Zurich", "Indian/Antananarivo", "Indian/Chagos", "Indian/Christmas", "Indian/Cocos", "Indian/Comoro", "Indian/Kerguelen", "Indian/Mahe", "Indian/Maldives", "Indian/Mauritius", "Indian/Mayotte", "Indian/Reunion", "UTC", "Zulu", "Pacific/Apia", "Pacific/Auckland", "Pacific/Bougainville", "Pacific/Chatham", "Pacific/Chuuk", "Pacific/Easter", "Pacific/Efate", "Pacific/Enderbury", "Pacific/Fakaofo", "Pacific/Fiji", "Pacific/Funafuti", "Pacific/Galapagos", "Pacific/Gambier", "Pacific/Guadalcanal", "Pacific/Guam", "Pacific/Honolulu", "Pacific/Kiritimati", "Pacific/Kosrae", "Pacific/Kwajalein", "Pacific/Majuro", "Pacific/Marquesas", "Pacific/Midway", "Pacific/Nauru", "Pacific/Niue", "Pacific/Norfolk", "Pacific/Noumea", "Pacific/Pago_Pago", "Pacific/Palau", "Pacific/Pitcairn", "Pacific/Pohnpei", "Pacific/Port_Moresby", "Pacific/Rarotonga", "Pacific/Saipan", "Pacific/Tahiti", "Pacific/Tarawa", "Pacific/Tongatapu", "Pacific/Wake", "Pacific/Wallis"]; //#endregion //#region ../constants/src/TypeOf.d.ts /** * **TYPE_OF** * * The set of values which are possible results of the `typeof` command in Javascript. */ declare const TYPE_OF: readonly ["string", "number", "boolean", "undefined", "symbol", "bigint", "function", "object"]; //#endregion //#region ../constants/src/TypeTokens.d.ts /** * **Type Tokens** which have zero configuration elements. */ declare const TT_ATOMICS: readonly ["undefined", "null", "boolean", "true", "false"]; /** * **Type Tokens** which have a literal variant which represents * the _single_ configuration of this type which is available. */ declare const TT_SINGLETONS: readonly ["string", "number"]; declare const TT_SETS: readonly ["string-set", "numeric-set", "fn-set", "union-set"]; /** * **Type Tokens** which represent _functions_ (either the typical * variety or Generator functions). */ declare const TT_FUNCTIONS: readonly ["fn", "gen"]; /** * **Type Tokens** which _contain_ other **Type Tokens** to make up their * identity. */ declare const TT_CONTAINERS: readonly ["rec", "arr", "set", "map", "union", "obj", "tuple"]; declare const TT_START: "<<"; declare const TT_STOP: ">>"; declare const TT_DELIMITER: "::"; //#endregion //#region ../constants/src/TypeTokenVariants.d.ts declare const TYPE_TOKEN_REC_VARIANTS: readonly ["object-key", "string-key"]; declare const TYPE_TOKEN_REC_KEY_VARIANTS: readonly ["unknown", "any", "string", "number", "boolean", "truthy", "numberlike", "scalar", "object", "string|undefined", "number|undefined", "boolean|undefined", "object|undefined", "unknown[]", "any[]", "string[]", "number[]", "boolean[]"]; declare const TYPE_TOKEN_STRING_SET_VARIANTS: readonly ["endsWith::${string}", "startsWith::${string}", "contains::${string}", "civilianTime", "militaryTime", "ipv4Address", "ipv4Address::tight", "ipv4Address::loose", "ipv6Address", "ipv6Address::${string}", "numericString", "zipCode5", "zipCode5+4", "countryCode2", "countryCode3", "countryName", "capitalized", "url", "url::${string}", "isoDate", "isoDateTime", "usStateAbbrev", "usCitySuggestions", "metricCategory", "metric", "metric::${Metric}"]; declare const TYPE_TOKEN_UNION_SET_VARIANTS: string[]; //#endregion //#region ../types/src/base-types/AnyMap.d.ts /** * represents _any_ `Map` type */ type AnyMap = Map; //#endregion //#region ../types/src/base-types/AnyObject.d.ts /** * **AnyObject** * * Meant to represent any valid object type (both indexable and not). */ type AnyObject = Dictionary | EmptyObject | ExplicitlyEmptyObject; //#endregion //#region ../types/src/base-types/AnySet.d.ts /** * represents _any_ `Set` type */ type AnySet = Set; //#endregion //#region ../types/src/base-types/AnyWeakMap.d.ts /** * represents _any_ `WeakMap` type */ type AnyWeakMap = WeakMap; //#endregion //#region ../types/src/base-types/Container.d.ts /** * **Container** * * A type which represents common container types including: * * - any object-based dictionary type (Record) * - any array or tuple * - any `Map`, `WeakMap`, or `Set` * * Note: functions are intentionally excluded to avoid excessive type * comparisons when treating functions as containers. */ type Container = readonly unknown[] | Dictionary | Map | WeakMap | Set; //#endregion //#region ../types/src/base-types/Defined.d.ts /** * **Defined** * * Represents **every** type except for the _undefined_ type. */ type Defined = Something | null; //#endregion //#region ../types/src/base-types/Dictionary.d.ts /** * **Dictionary**`<[K],[V]>` * * Represents a Key/Value dictionary type. * * **Note:** this is pretty much the same as the built-in * `Record` type of Typescript but */ type Dictionary = Record; //#endregion //#region ../types/src/base-types/Empty.d.ts /** * **Empty** * * values/types considered to be "empty" */ type Empty = undefined | null | ExplicitlyEmptyObject | [] | ""; //#endregion //#region ../types/src/base-types/EmptyObject.d.ts /** * **EmptyObject** * * An object/dictionary with **no** defined properties. */ type EmptyObject = NonNullable; /** * **ExplicitlyEmptyObject** * * An `EmptyObject` with it's index keys set to _never_ (which prohibits any * key from being added) */ type ExplicitlyEmptyObject = NonNullable<{ [x: string]: never; [x: symbol]: never; }>; //#endregion //#region ../types/src/base-types/FalsyValue.d.ts /** * **FalsyValue** * * A union of all _falsy_ values. * * **Note:** * - any value which is _not_ falsy is "truthy" * - in addition to the types in this union type; `NaN` too is * considered _falsy_ but there is no type representation for this. */ type FalsyValue = false | 0 | -0 | "" | "false" | null | undefined; //#endregion //#region ../types/src/base-types/fns/AnyFunction.d.ts /** * **AnyFunction** * * A type which is meant to match on _all_ types of functions which can exist. */ type AnyFunction = CallableFunction; //#endregion //#region ../types/src/base-types/fns/OptionalParamFn.d.ts /** * **OptionalParamFn** * * A function which either has _no_ parameters or any parameters it * does have are _optional_ in a way that it is safe to call it without * any parameters. * * To make the runtime aware of this flexibility, a property `optionalParams` * must be set to **true**. To convert a regular function to be this kind of * function you can use the `AsOptionalParamFn` utility. */ type OptionalParamFn = ((() => any) | ((p1?: any, p2?: any, p3?: any, p4?: any) => any)) & { optionalParams: true; }; //#endregion //#region ../types/src/base-types/fns/ParameterlessFn.d.ts /** * **ParameterlessFn** * * A function which returns takes no parameters. */ type ParameterlessFn = () => R; //#endregion //#region ../types/src/base-types/fns/TakeFunction.d.ts /** * **TakeWrapper** * * A builder/wrapper function around the core take callback. */ type TakeWrapper = , TParseString extends string, TLexerTokens extends readonly TToken[]>(state: TState) => StartsWith extends true ? LexerState, [...TLexerTokens, TToken]> | Error : NoMatch; //#endregion //#region ../types/src/literals/BooleanLike.d.ts /** * **BooleanLike** * * A union of all boolean types plus the string literal representations of these * literals. */ type BooleanLike = boolean | "true" | "false" | "boolean"; //#endregion //#region ../types/src/literals/branding/BrandSymbol.d.ts declare const BrandSymbol: unique symbol; //#endregion //#region ../types/src/literals/branding/Brand.d.ts /** * **Brand** * * Brands a scalar `Base` type with `{ [BrandSymbol]: Kind }`. * * - you may optionally choose to add other key/value pairs * to the metadata. */ type Brand | undefined = undefined> = [Kv] extends [undefined] ? Base & { [BrandSymbol]: Kind; } : Base & { [BrandSymbol]: Kind; } & Kv; //#endregion //#region ../types/src/literals/branding/IsBranded.d.ts /** * **IsBranded**`` * * Boolean operator which tests whether `T` has been _branded_ with the * `Brand` utility. */ type IsBranded = typeof BrandSymbol extends keyof T ? true : false; //#endregion //#region ../types/src/literals/branding/Unbrand.d.ts type Digit$6 = "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9"; type ValidTwoDigitMonth$1 = `0${Exclude}` | `1${"0" | "1" | "2"}`; type ValidTwoDigitDate$1 = `0${Exclude}` | `1${Digit$6}` | `2${Digit$6}` | `3${"0" | "1"}`; type UnbrandTwoDigitMonth = { [M in ValidTwoDigitMonth$1]: T extends Brand ? M : never }[ValidTwoDigitMonth$1]; type UnbrandTwoDigitDate = { [D in ValidTwoDigitDate$1]: T extends Brand ? D : never }[ValidTwoDigitDate$1]; /** * **Unbrand**`` * * Removes branding from a branded type, returning the original base type. * * Note: This utility has a known limitation with intersection types. * When a branded type is intersected with a literal (e.g., `Brand & "literal"`), * TypeScript creates a composite type that cannot be decomposed to extract just the literal. * This is a fundamental TypeScript limitation. * * @example * * ```ts * // string & { [Brand Symbol]: "UserId" } * type Branded = Brand; * type Unbranded = Unbrand; // string * ``` */ type Unbrand = T extends `${infer A extends Digit$6}${infer B extends Digit$6}${infer C extends Digit$6}${infer D extends Digit$6}` & { [BrandSymbol]: "FourDigitYear"; } ? `${A}${B}${C}${D}` : T extends { [BrandSymbol]: "TwoDigitMonth"; } ? UnbrandTwoDigitMonth : T extends { [BrandSymbol]: "TwoDigitDate"; } ? UnbrandTwoDigitDate : T extends Brand ? B : T; //#endregion //#region ../types/src/literals/Color.d.ts /** * **HexColor** * * A color value based in hexadecimal format */ type HexColor = `#${HexadecimalChar}${HexadecimalChar}${string}`; /** * **RgbColor** * * Type to enforce an `rgb()` color definition */ type RgbColor = CssRgb; //#endregion //#region ../types/src/literals/ExpandRecursively.d.ts type ExpandParameters = [] extends TParams ? IsNarrowingFn extends true ? AsNarrowingFn, ExpandDictionary>> : AsStaticFn, ExpandDictionary>> : ExpandParameters, [...TResults, First$1 extends Dictionary ? ExpandDictionary> : First$1]>; /** * Recursively goes over an object based structure and tries to reduce * it down to just a simple key/value type. */ type ExpandRecursively = T extends Dictionary ? { [K in keyof T]: T[K] extends AnyFunction ? T[K] extends TypedFunction ? ExpandParameters> : T[K] : ExpandRecursively } : T; /** * Recursively goes over an object based structure and tries to reduce * it down to just a simple key/value type. */ type ExpandDictionary = T extends Dictionary ? { [K in keyof T]: T[K] extends AnyFunction ? T[K] : ExpandRecursively } : T; type Expand = T extends infer O ? { [K in keyof O]: O[K] } : never; //#endregion //#region ../types/src/literals/FromTokenNames.d.ts type WideTokenNames = "string" | "number" | "boolean" | "null" | "undefined" | "never" | "unknown" | "string[]" | "number[]" | "boolean[]" | "unknown[]"; type ConvertWideTokenNames = T extends "string" ? string : T extends "number" ? number : T extends "boolean" ? boolean : T extends "null" ? null : T extends "undefined" ? undefined : T extends "never" ? never : T extends "unknown" ? unknown : T extends "string[]" ? string[] : T extends "number[]" ? number[] : T extends "boolean[]" ? boolean[] : T extends "unknown[]" ? unknown[] : never; type WideContainerNames = "object" | "Dictionary" | "Map" | "Set" | "WeakMap"; type ConvertWideContainerNames = T extends "object" ? object : T extends "Dictionary" ? Record : T extends "Map" ? Map : T extends "Set" ? Set : T extends "WeakMap" ? WeakMap : never; /** * **FromWideTokens**`` * * Looks for `WideContainerNames` or `WideTokenNames` and converts them to * the type they describe. If it is `T` is not any of these tokens it is * simply proxied through. * * If you'd prefer to setup a different type for when no token is matched * you can add it under `TElse`. */ type FromWideTokens = T extends WideTokenNames | WideContainerNames ? T extends WideTokenNames ? ConvertWideTokenNames : T extends WideContainerNames ? ConvertWideContainerNames : never : IsNever extends true ? T : TElse; //#endregion //#region ../types/src/literals/Narrowable.d.ts /** * **Narrowable** * * A union of types which when used as a generic's base value helps to extract * the most narrow definition available. * * **Related:** `NarrowableDefined`, `NarrowableScalar` */ type Narrowable = string | number | boolean | symbol | object | undefined | void | null; //#endregion //#region ../types/src/literals/RuntimeUnion.d.ts /** * **RuntimeUnion**`` * * Represents a _union type_ at runtime where the `ReturnType` is the * union type of the member in the `members` array. */ interface RuntimeUnion { kind: "Union"; members: T; type: TupleToUnion; includes: (v: unknown) => boolean; } //#endregion //#region ../types/src/literals/Unset.d.ts /** * **Unset** * * The **Unset** type allows you to specify a _parameter_ which * has **not** been set yet but then allows a user to choose any * value they like. * * **Related:** `unset()` */ interface Unset { kind: "Unset"; } //#endregion //#region ../types/src/literals/VueRef.d.ts declare const Ref: unique symbol; /** * **VueRef**`` * * Intended to be the same type as VueJS's `Ref` but without the need * to include any of the VueJS framework in deps. * * **Notes:** * * - a real `Ref` has both the `value` property and a _private_ symbol * exposed to the runtime as a type (but the type is intentionally not exported). * - whenever using this type, please use it with `IsRef()`,`isRef()` utils * * **Related:** * * - `IsRef`, `isRef()`, `VueComputedRef` */ interface VueRef { [Ref]: "VueRef"; value: T; } //#endregion //#region ../types/src/base-types/fns/TypedFunction.d.ts /** * **TypedFunction**`<[P],[R]>` * * A function which has basic typing information. * * **Related:** `TypedFunctionWithDictionary>` */ type TypedFunction

= ((...args: P) => R); //#endregion //#region ../types/src/base-types/functional/LeftRight.d.ts /** * **LeftRight**`` * * A tuple which has two possible states represented as `L` * and `R`. * * **Related:** `AsLeft`, `AsRight`, `WhereLeft`, `HandleRight`, `LeftExtends`, ... */ type LeftRight = [kind: "LeftRight", left: L, right: R]; //#endregion //#region ../types/src/base-types/Indexable.d.ts /** * **Indexable** * * A type which can be _indexed_. This means either an array of * some sort, an indexable object, a `Map`, or a `WeakMap`. */ type Indexable = IndexableObject | unknown[] | readonly unknown[] | WeakMap | Map; //#endregion //#region ../types/src/base-types/IndexableObject.d.ts type Len$1 = UnionToTuple>["length"]; /** * **IndexableObject**`<[TObj], [TIndex]>` * * Type utility which receives a `KV` object and and adds an _index signature_ * so that other properties may be added in the runtime. * * - by default the index signature is `{ [key: string]: unknown; [key: symbol]: unknown }` * but this can be changed by changing `TIndex` * * ```ts * // { [x: string]: unknown; foo: 1; bar: 2 } * type FooBarIdx = IndexableObject<{foo: 1; bar: 2}, KV>; * ``` * * **Related:** `EmptyObject`, `IndexedObject` */ type IndexableObject = If, never, IsEqual extends true ? Dictionary : IsNever> extends true ? Dictionary : ExpandRecursively>>; //#endregion //#region ../types/src/base-types/LikeRegExp.d.ts /** * **LikeRegExp** * * Is either a real Regular Expression or a string * that has been has been validated it _can_ be a * regular expression with utilities like `isLikeRegExp()` */ type LikeRegExp = RegExp | string; //#endregion //#region ../types/src/base-types/NarrowObject.d.ts /** * **NarrowObject**`` * * Defines a `Record` type who's values extends `Narrowable`. This type is most * commonly used in runtime settings where a function wants to _extend_ this * type to ensure that the received values are as narrow as could be available * from the input source. */ type NarrowObject = Record; //#endregion //#region ../types/src/base-types/Nothing.d.ts /** * **Nothing** * * This type represents a type which holds no real value; this * is a union between `null` and `undefined`. */ type Nothing = null | undefined; //#endregion //#region ../types/src/base-types/ObjectKey.d.ts /** * **ObjectKey** * * The union of `string` and `symbol` represents the valid key types for a * object/dictionary type. */ type ObjectKey = string | symbol; //#endregion //#region ../types/src/base-types/objects/FromTo.d.ts /** * An object type which semantically is meant to express the * movement from one type to another. * * - it can be used to express any type movement but the most * common scenario is to move from one string literal to another * so both TFrom and TTo _default_ to `string`. */ interface FromTo { from: TFrom; to: TTo; } //#endregion //#region ../types/src/base-types/Scalar.d.ts /** * **Scalar** * * Defines the types which makeup a "scalar" type. */ type Scalar = string | number | bigint | boolean | null | symbol | undefined | void; //#endregion //#region ../types/src/base-types/Something.d.ts /** * **Something** * * This type represents **any** type _other than_ `null` or `undefined` (aka, the `Nothing` types). * * **Note:** _this is equivalent to the `{}` type (which is often a surprise to many)_ */ interface Something {} //#endregion //#region ../types/src/base-types/Thenable.d.ts /** * **Thenable**`` * * An object which resembles a promise and is guarenteed to provide a `.then` and `.catch` * callback hook. */ interface Thenable extends PromiseLike { then: (...args: any[]) => any; } //#endregion //#region ../types/src/base-types/Tuple.d.ts type TupleRange = [required: number, optional: number]; type _Tuple = 0 extends TLength ? TType extends unknown[] ? Readonly : readonly TType[] : TLength extends number ? Readonly> : TLength extends TupleRange ? Readonly<[...FixedLengthArray, ...FixedLengthArray]> : TLength extends `${infer Num extends number}+` ? Num extends number ? Readonly<[...FixedLengthArray, ...TType[]]> : never : never; /** * **Tuple**`` * * As a default, a **Tuple** is represented as a readonly array of _unknown_ properties. * * - by expressing `TType` you can state either a constant type _or_ a list of types * - by expressing `TLength` it will make the tuple a fixed length (assuming that `TType` * is set to a constant value rather than as a list) * ```ts * // readonly unknown[] * type T1 = Tuple; * // readonly [string, string, string, string] * type T2 = Tuple; * ``` */ type Tuple$1 = _Tuple extends readonly unknown[] ? _Tuple : never; //#endregion //#region ../types/src/base-types/Variable.d.ts /** * **Variable** * * the **Variable** type reinforces that a variable: * * - start with an alpha character (upper or lower) * - end with an alphanumeric character * * Further type safety would become too expensive. */ type Variable = `${AlphaChar}${string}${AlphanumericChar}`; //#endregion //#region ../types/src/boolean-logic/branching/Fallback.d.ts /** * **Fallback**`` * * Branching operator which allows giving a value `TVal` a _default value_ when * it's value is either `null`, `undefined`, or `never`. */ type Fallback = [IsUnion] extends [true] ? [UnionMemberExtends] extends [true] ? UnionFilter | TFallback : TVal : IsNull extends true ? TFallback : IsUndefined extends true ? TFallback : TVal; //#endregion //#region ../types/src/boolean-logic/branching/If.d.ts /** * **If**`` * * Branching utility which tests `TTest` for a boolean value. */ type If = [IsNever] extends [true] ? TNever : [TTest] extends [Error] ? TError : [TTest] extends [boolean] ? [IsTrue] extends [true] ? TIf : [IsBooleanLiteral] extends [true] ? TElse : TMaybe : [TTest] extends [LogicFunction] ? [IsTrue>] extends [true] ? TIf : [IsFalse>] extends [true] ? TElse : [IsBoolean>] extends [true] ? TMaybe : never : never; //#endregion //#region ../types/src/boolean-logic/branching/IfAllLiteral.d.ts /** * **IfAllLiteral**`` * * Branching utility which branches on whether the tuple passed in * has _literal_ values for every member. */ type IfAllLiteral = AllLiteral extends true ? IF : ELSE; //#endregion //#region ../types/src/boolean-logic/branching/IfEqual.d.ts /** * **IfEqual**`` * * Type utility which returns type `IF` _if_ `X` is equal to `Y`; otherwise returns * type `ELSE`. */ type IfEqual> = IsEqual extends true ? IF : ELSE; //#endregion //#region ../types/src/boolean-logic/branching/IfLength.d.ts /** * **IfLength**`` * * Type utility which returns type `IF` when `TEvaluate` evaluates to being * a length of `TLength`. It returns type `ELSE` if it can determine the length * at design time and otherwise returns `MAYBE`. * * - the `ELSE` type will default to `TEvaluate` by default * - the `MAYBE` type will default to `IF | ELSE` by default * - If a _non-array_ type is passed into `TEvaluate` then utility will result `ELSE` * type. */ type IfLength = TEvaluate extends readonly unknown[] ? IsNumericLiteral extends true ? IfEqual, TLength, IF, ELSE> : MAYBE : TEvaluate extends unknown[] ? MAYBE : TEvaluate extends string ? If, IfEqual, TLength, IF, ELSE>, MAYBE> : MAYBE; //#endregion //#region ../types/src/boolean-logic/branching/IfNever.d.ts /** * **IfNever**`` * * Type utility which transforms type `T` based on whether it extends the _never_ * type. */ type IfNever = [IsNever] extends [true] ? IF : ELSE; //#endregion //#region ../types/src/boolean-logic/branching/IfUnset.d.ts /** * **IfUnset**`` * * Branching utility which will proxy _any_ type through except * for those set with `Unset<[T]>`. * * When `Unset` is found then it will be replaced with `TElse`. */ type IfUnset = TTest extends Unset ? TElse : Exclude; //#endregion //#region ../types/src/boolean-logic/combinators/And.d.ts interface LogicOptions$1 { empty?: boolean | unknown; err?: "false" | "error" | unknown; } type Reduce$2 = { [K in keyof T]: T[K] extends TypedFunction ? ReturnType : T[K] }; /** * **And**`` * * Performs logical AND operation on an array of boolean values or functions returning boolean. * * - Returns `false` if any element is `false` * - Returns `boolean` if any element is wide `boolean` type * - Returns `true` if all elements are `true` * - Returns `false` for empty arrays (or value from options.empty) * - Returns `boolean` for wide arrays (length not known at compile time) * - Supports functions that return boolean values * - Configurable error handling via options parameter * * **Related:** `Or`, `Not` */ type And = IsAny extends true ? TOpt extends { err: "error"; } ? Err<"invalid/and", "The And logical combinator has a 'any' type! And is expecting a tuple of boolean values (or functions which return boolean).", { library: "inferred-types"; }> : false : IsNever extends true ? TOpt extends { err: "error"; } ? Err<"invalid/and", "The And logical combinator has a 'never' type! And is expecting a tuple of boolean values (or functions which return boolean).", { library: "inferred-types"; }> : false : HasAny<[...T]> extends true ? TOpt extends { err: "error"; } ? Err<"invalid/and", "The And found elements in T which were the 'any' type! And expects all elements to be a boolean value or a function which returns a boolean value.", { value: T; library: "inferred-types"; }> : false : HasNever<[...T]> extends true ? TOpt extends { err: "error"; } ? Err<"invalid/and", "The And found elements in T which were the 'never' type! And expects all elements to be a boolean value or a function which returns a boolean value.", { value: T; library: "inferred-types"; }> : false : [[...T]] extends [readonly (boolean | TypedFunction)[]] ? number extends T["length"] ? boolean : [[]] extends [[...T]] ? TOpt extends { empty: infer E; } ? E : false : [[...T]] extends [readonly boolean[]] ? HasFalse extends true ? false : HasWideBoolean extends true ? boolean : true : Reduce$2<[...T]> extends readonly boolean[] ? HasFalse> extends true ? false : HasWideBoolean> extends true ? boolean : true : TOpt extends { err: "error"; } ? Err<"invalid/and", "The conditions passed into And could not be reduced down to just a boolean array.", { library: "inferred-types"; value: T; }> : false : TOpt extends { err: "error"; } ? Err<"invalid/and", "The And type utility requires that all elements passed to it are either a boolean value directly or a LogicFunction which returns a boolean value"> : false; //#endregion //#region ../types/src/boolean-logic/combinators/comparison/Compare.d.ts type ContainsAllParams = number extends TParams["length"] ? boolean : TParams extends readonly [infer Head, ...infer Rest] ? Contains extends true ? ContainsAllParams : false : true; /** * **Comparator** * * A _comparator_ is a runtime function which is created when calling * the `compare(op, params) utility. * * - a _comparator_ also has `op`, and `params` properties */ type Comparator = [IsNever] extends [true] ? Err<`invalid-operation`, `An invalid operation was presented as a Comparator!`> : { kind: "comparator"; op: TOp; params: TParams; } & (>(val: TVal) => Compare); type Process__DateTime = TOp extends "after" ? TVal extends DateLike ? First$1 extends DateLike ? IsAfter> : false : Err<`invalid-value/not-date-like`> : TOp extends "before" ? TVal extends DateLike ? First$1 extends DateLike ? IsBefore> : Err<`invalid-params/not-date-like`, `The '${TOp}' operation expects the parameter used for comparator to be a valid representation of a date but it was not!`, { param: TVal; val: TVal; }> : Err<`invalid-value/not-date-like`, `The '${TOp}' operation expects the value passed in to be a valid representation of a date but it was not!`, { val: TVal; }> : TOp extends "sameDay" ? TVal extends DateLike ? First$1 extends DateLike ? IsSameDay> : Err<`invalid-params/not-date-like`> : Err<`invalid-value/not-date-like`> : TOp extends "sameMonthYear" ? TVal extends DateLike ? First$1 extends DateLike ? IsSameMonthYear> : Err<`invalid-params/not-date-like`, `The '${TOp}' operation expects the parameter used for comparator to be a valid representation of a date but it was not!`, { param: TVal; val: TVal; }> : Err<`invalid-value/not-date-like`, `The '${TOp}' operation expects the value passed in to be a valid representation of a date but it was not!`, { val: TVal; }> : TOp extends "sameMonth" ? TVal extends DateLike ? First$1 extends DateLike ? IsSameMonth> : Err<`invalid-params/not-date-like`, `The '${TOp}' operation expects the parameter used for comparator to be a valid representation of a date but it was not!`, { param: TVal; val: TVal; }> : Err<`invalid-value/not-date-like`, `The '${TOp}' operation expects the value passed in to be a valid representation of a date but it was not!`, { val: TVal; }> : TOp extends "sameYear" ? TVal extends DateLike ? First$1 extends DateLike ? IsSameYear> : Err<`invalid-params/not-date-like`, `The '${TOp}' operation expects the parameter used for comparator to be a valid representation of a date but it was not!`, { param: TVal; val: TVal; }> : Err<`invalid-value/not-date-like`, `The '${TOp}' operation expects the value passed in to be a valid representation of a date but it was not!`, { val: TVal; }> : Unset; type Process__General = TOp extends "extends" ? DoesExtend> : TOp extends "equals" ? IsEqual : TOp extends "false" ? [TVal] extends [boolean] ? [boolean] extends [TVal] ? boolean : IsFalse : [TVal] extends [null] ? false : [TVal] extends [undefined] ? false : [TVal] extends [0] ? false : [TVal] extends [""] ? false : [TVal] extends [true] ? false : [TVal] extends [false] ? true : IsFalse : TOp extends "falsy" ? IsFalsy : TOp extends "true" ? AreIncompatible extends true ? false : IsTrue : TOp extends "truthy" ? IsTruthy : TOp extends "equalsSome" ? TParams extends readonly [...infer L] ? number extends As$1["length"] ? boolean : SomeEqual, TVal> : boolean : TOp extends "contains" ? TVal extends string | number | readonly unknown[] ? Contains> : false : TOp extends "containsSome" ? TVal extends string | number | readonly unknown[] ? Contains>, TParams> : false : TOp extends "containsAll" ? TVal extends string | number | readonly unknown[] ? ContainsAllParams>, TParams> : false : Unset; type Process__String = TOp extends "startsWith" ? TVal extends ComparisonAccept<"startsWith"> ? TParams extends readonly (string | number)[] ? number extends TParams["length"] ? boolean : StartsWith, TParams[number]> : Err<`invalid-type/parameters`> : Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a valid representation of a date but it was not!`, { val: TVal; }> : TOp extends "endsWith" ? TVal extends ComparisonAccept<"endsWith"> ? TParams extends readonly (string | number)[] ? number extends TParams["length"] ? boolean : EndsWith, TParams[number]> : Err<`invalid-type/parameters`> : Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a valid representation of a date but it was not!`, { val: TVal; }> : TOp extends "endsWithNumber" ? EndsWithNumber : TOp extends "startsWithNumber" ? IsStringLiteral$1 extends true ? FirstChar> extends NumericChar ? true : false : IsString extends true ? boolean : false : TOp extends "onlyNumbers" ? IsStringLiteral$1 extends true ? TVal extends "" ? false : IsEqual, NumericChar>, TVal> : IsString extends true ? boolean : false : TOp extends "onlyLetters" ? IsStringLiteral$1 extends true ? TVal extends "" ? false : IsEqual, AlphaChar>, TVal> : IsString extends true ? boolean : false : TOp extends "alphaNumeric" ? IsStringLiteral$1 extends true ? TVal extends "" ? false : IsEqual, AlphanumericChar>, TVal> : IsString extends true ? boolean : false : TOp extends "isTemplateLiteral" ? IsStringLiteral$1 extends true ? IsTemplateLiteral : false : Unset; type Process__Object = TOp extends "objectKeyGreaterThan" ? IsDictionary extends false ? Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a dictionary object but it wasn't!`> : [Extends, NumberLike>] extends [true] ? [First$1] extends [keyof TVal] ? Extends], NumberLike> extends true ? IsGreaterThan], NumberLike>, As$1, NumberLike>> : Err<`invalid-value/non-numeric`, `The '${TOp}' operation expects the key '${AsString>}' in the value passed in to be a numeric value but it wasn't!`, { val: TVal; }> : false : Err<`invalid-params/${TOp}`, `The '${TOp}' operation expects the second param to be NumberLike but it wasn't!`, { val: TVal; params: TParams; invalid: TParams[1]; }> : TOp extends "objectKeyGreaterThanOrEqual" ? IsDictionary extends false ? Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a dictionary object but it wasn't!`> : [Extends, NumberLike>] extends [true] ? [First$1] extends [keyof TVal] ? Extends], NumberLike> extends true ? IsGreaterThanOrEqual], NumberLike>, As$1, NumberLike>> : Err<`invalid-value/non-numeric`, `The '${TOp}' operation expects the key '${AsString>}' in the value passed in to be a numeric value but it wasn't!`, { val: TVal; }> : false : Err<`invalid-params/${TOp}`, `The '${TOp}' operation expects the second param to be NumberLike but it wasn't!`, { val: TVal; params: TParams; invalid: TParams[1]; }> : TOp extends "objectKeyLessThan" ? IsDictionary extends false ? Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a dictionary object but it wasn't!`> : [Extends, NumberLike>] extends [true] ? [First$1] extends [keyof TVal] ? Extends], NumberLike> extends true ? IsLessThan], NumberLike>, As$1, NumberLike>> : Err<`invalid-value/non-numeric`, `The '${TOp}' operation expects the key '${AsString>}' in the value passed in to be a numeric value but it wasn't!`, { val: TVal; }> : false : Err<`invalid-params/${TOp}`, `The '${TOp}' operation expects the second param to be NumberLike but it wasn't!`, { val: TVal; params: TParams; invalid: TParams[1]; }> : TOp extends "objectKeyLessThanOrEqual" ? IsDictionary extends false ? Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a dictionary object but it wasn't!`> : [Extends, NumberLike>] extends [true] ? [First$1] extends [keyof TVal] ? Extends], NumberLike> extends true ? IsLessThanOrEqual], NumberLike>, As$1, NumberLike>> : Err<`invalid-value/non-numeric`, `The '${TOp}' operation expects the key '${AsString>}' in the value passed in to be a numeric value but it wasn't!`, { val: TVal; }> : false : Err<`invalid-params/${TOp}`, `The '${TOp}' operation expects the second param to be NumberLike but it wasn't!`, { val: TVal; params: TParams; invalid: TParams[1]; }> : TOp extends "objectKeyEquals" ? IsDictionary extends false ? Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a dictionary object but it wasn't!`> : [First$1] extends [keyof TVal] ? IsEqual], Second$2> : false : TOp extends "objectKeyExtends" ? TVal extends Dictionary ? First$1 extends keyof TVal ? TVal[First$1] extends Second$2 ? true : false : false : Err<`invalid-value`, `The operation '' expects values to be a valid container!`, { val: TVal; params: TParams; }> : TOp extends "objectKeyStartsWith" ? TVal extends Dictionary ? First$1 extends infer Key extends keyof TVal ? TVal[Key] extends string | number ? StartsWith, string | number>> : false : Err<`invalid-value/wrong-type`, `The '${TOp}' operation expects the value passed in to be a dictionary object but it wasn't!`> : false : Unset; type Process__Numeric = TOp extends "greaterThan" ? TVal extends NumberLike ? First$1 extends NumberLike ? IsGreaterThan> : Err<`invalid-param/not-number-like`, `The operation '${TOp}' expects the first parameter to be NumberLike!`, { val: TVal; params: TParams; }> : Err<`invalid-value/not-number-like`, `The operation '${TOp}' expects the value to be compared with the comparator to be NumberLike!`, { val: TVal; params: TParams; }> : TOp extends "greaterThanOrEqual" ? TVal extends NumberLike ? First$1 extends NumberLike ? IsGreaterThanOrEqual> : Err<`invalid-param/not-number-like`, `The operation '${TOp}' expects the first parameter to be NumberLike!`, { val: TVal; params: TParams; }> : Err<`invalid-value/not-number-like`, `The operation '${TOp}' expects the value to be compared with the comparator to be NumberLike!`, { val: TVal; params: TParams; }> : TOp extends "lessThan" ? TVal extends NumberLike ? First$1 extends NumberLike ? IsLessThan> : Err<`invalid-param/not-number-like`, `The operation '${TOp}' expects the first parameter to be NumberLike!`, { val: TVal; params: TParams; }> : Err<`invalid-value/not-number-like`, `The operation '${TOp}' expects the value to be compared with the comparator to be NumberLike!`, { val: TVal; params: TParams; }> : TOp extends "lessThanOrEqual" ? TVal extends NumberLike ? First$1 extends NumberLike ? IsLessThanOrEqual> : Err<`invalid-param/not-number-like`, `The operation '${TOp}' expects the first parameter to be NumberLike!`, { val: TVal; params: TParams; }> : Err<`invalid-value/not-number-like`, `The operation '${TOp}' expects the value to be compared with the comparator to be NumberLike!`, { val: TVal; params: TParams; }> : TOp extends "betweenExclusively" ? TVal extends NumberLike ? TParams extends readonly [infer Min extends NumberLike, infer Max extends NumberLike] ? IsBetweenExclusively : false : false : TOp extends "betweenInclusively" ? TVal extends NumberLike ? TParams extends readonly [infer Min extends NumberLike, infer Max extends NumberLike] ? IsBetweenInclusively : false : false : Unset; type Process__Other = TOp extends "errors" ? IsError : TOp extends "hasLength" ? TVal extends string ? Contains["length"]> : TVal extends readonly unknown[] ? Contains : TVal extends number ? Contains["length"]> : false : TOp extends "errorsOfType" ? TVal extends Error ? "type" extends keyof TVal ? First$1 extends TVal["type"] ? true : false : false : false : TOp extends "returnEquals" ? TVal extends TypedFunction ? IsEqual, TParams[0]> : TVal extends AnyFunction ? boolean : false : TOp extends "returnExtends" ? TVal extends ((...args: any[]) => any) ? Extends, TParams[0]> : false : Unset; /** * process the type for the comparison */ type Comparison = Process__DateTime extends Unset ? Process__General extends Unset ? Process__String extends Unset ? Process__Object extends Unset ? Process__Numeric extends Unset ? Process__Other extends Unset ? Err<`invalid-operation/compare`, `The operation '${TOp}' is not a recognized operation in the Compare<...> type utility!`> : Process__Other : Process__Numeric : Process__Object : Process__String : Process__General : Process__DateTime; /** * **Compare**`` * * Compares the value `TVal` with `TComparator` using * the `TOp` _operator_. * * When either TVal or any parameter is a wide type (like `string`, `number`), * returns `boolean` instead of a definitive `true`/`false`. */ type ValidateParams = TOp extends "equals" ? TParams extends readonly [unknown] ? true : Err<"invalid-parameters", "equals operation requires exactly 1 parameter"> : TOp extends "equalsSome" ? TParams extends readonly [unknown, unknown, ...unknown[]] ? true : Err<"invalid-parameters", "equalsSome operation requires at least 2 parameters"> : TOp extends "extends" ? TParams extends readonly [unknown, ...unknown[]] ? true : Err<"invalid-parameters", "extends operation requires exactly 1 parameter"> : true; type Compare, TOp extends Suggest, TParams extends readonly unknown[]> = TOp extends ComparisonOperation ? ValidateParams extends Error ? ValidateParams : Comparison : Err<`invalid-operation/${TOp}`, `The operation '${TOp}' is not a valid operation for the Compare utility!`, { op: TOp; params: TParams; }>; //#endregion //#region ../types/src/boolean-logic/combinators/comparison/ComparisonAccept.d.ts /** * **ComparisonAccept**`` * * Provides the _base type_ which a comparison function will accept. * * - those operations which don't state an explicit `accept` property * in their definitions will be assigned the type `unknown`. */ type ComparisonAccept = TOp extends keyof ComparisonLookup ? "accept" extends keyof ComparisonLookup[TOp] ? ComparisonLookup[TOp]["accept"] : Narrowable : TOp extends ComparisonOperation ? Narrowable : Narrowable; //#endregion //#region ../types/src/boolean-logic/combinators/comparison/ComparisonLookup.d.ts /** * **ComparisonOperation**`` * * Operations known by the `Compare` and `compare()` utilities * and leveraged by utilities like `Filter`/`filter()`, etc. * * - the generic `T` is used to switch between `run-time` and `design-time` * modes */ type ComparisonOperation = typeof COMPARISON_OPERATIONS[number]; /** * A type which provides a lookup table for standard conversion types. */ interface ComparisonLookup { isTemplateLiteral: { params: readonly []; accept: unknown; take: 1; }; extends: { params: readonly [types: unknown, ...unknown[]]; accept: unknown; }; startsWith: { params: readonly [startsWith: string | number, ...variants: (string | number)[]]; accept: string | number; }; endsWith: { params: readonly (string | number)[]; convert: "stringUnion"; accept: string | number; take: 1; }; endsWithNumber: { params: []; desc: "tests whether a string literal ends with a numeric value"; accept: string; take: 0; }; startsWithNumber: { params: []; desc: "tests whether a string literal starts with a numeric value"; accept: string; take: 0; }; onlyNumbers: { params: []; desc: "tests whether a string literal contains only numeric characters"; accept: string; take: 0; }; alphaNumeric: { params: []; desc: "tests whether a string literal contains only alphabetic and numeric characters"; accept: string; take: 0; }; onlyLetters: { params: readonly []; desc: "tests whether a string literal contains only letter characters"; accept: string; take: 0; }; contains: { params: readonly [substring: string | number]; convert: ["stringLiteral"]; accept: string | number | readonly (string | number)[]; take: 1; }; containsAll: { params: readonly [substrings: string | number, ...readonly (string | number)[]]; accept: string | number | readonly (string | number)[]; convert: "stringArray"; take: "*"; }; containsSome: { params: readonly [val1: string | number, val2: string | number, ...(string | number)[]]; accept: string | number | readonly (string | number)[]; convert: "stringUnion"; take: "1"; }; greaterThan: { params: readonly [value: NumberLike]; accept: NumberLike; take: 1; }; greaterThanOrEqual: { params: readonly [value: NumberLike]; accept: NumberLike; take: 1; }; lessThan: { params: readonly [value: NumberLike]; accept: NumberLike; take: 1; }; lessThanOrEqual: { params: readonly [value: NumberLike]; accept: NumberLike; take: 1; }; objectKeyGreaterThan: { params: readonly [key: string, type: NumberLike]; take: 2; }; objectKeyGreaterThanOrEqual: { params: readonly [key: string, type: NumberLike]; take: 2; }; objectKeyLessThan: { params: readonly [key: string, type: NumberLike]; take: 2; }; objectKeyLessThanOrEqual: { params: readonly [key: string, type: NumberLike]; take: 2; }; betweenInclusively: { params: readonly [greaterThan: NumberLike, lessThan: NumberLike]; accept: NumberLike; take: 2; }; betweenExclusively: { params: readonly [greaterThan: NumberLike, lessThan: NumberLike]; accept: NumberLike; take: 2; }; equals: { params: readonly [value: unknown]; take: 1; accept: unknown; }; equalsSome: { params: readonly [potentialValues: unknown, unknown, ...unknown[]]; take: "*"; }; errors: { params: readonly []; take: 0; }; errorsOfType: { params: readonly [type: string | Error]; take: 1; }; before: { params: readonly [date: DateLike]; accept: DateLike; take: 1; }; after: { params: readonly [date: DateLike]; accept: DateLike; take: 1; }; sameDay: { params: readonly [date: DateLike]; accept: DateLike; take: 1; }; sameMonth: { params: readonly [date: DateLike]; accept: DateLike; take: 1; }; sameMonthYear: { params: readonly [date: DateLike]; accept: DateLike; take: 1; }; sameYear: { params: readonly [date: DateLike]; accept: DateLike; take: 1; }; truthy: { params: readonly []; take: 0; accept: Narrowable; }; falsy: { params: readonly []; accept: Narrowable; take: 0; }; true: { params: readonly []; take: 0; }; false: { params: readonly []; take: 0; }; objectKeyEquals: { params: readonly [key: string, value: unknown]; take: 2; }; objectKeyExtends: { params: readonly [key: string, type: unknown]; accept: Dictionary; take: 2; }; objectExtends: { params: readonly [type: unknown]; take: 1; accept: Dictionary; }; objectKeyStartsWith: { params: readonly [prop: ObjectKey, comparator: string | number]; take: 2; accept: Dictionary; }; returnEquals: { params: readonly [validReturnTypes: unknown, ...unknown[]]; take: "*"; accept: (...args: any[]) => any; }; returnExtends: { params: readonly [validReturnTypes: unknown, ...unknown[]]; take: "1"; convert: "union"; accept: (...args: any[]) => any; }; } //#endregion //#region ../types/src/boolean-logic/combinators/comparison/GetComparisonParams.d.ts /** * Presents the type options for entering a comparison's * parameters. This is meant as a convenience function * and allows you to not be forced to enter parameter * that aren't required. */ type GetComparisonParams = As$1<[IsUnion] extends [true] ? readonly unknown[] : TOp extends keyof ComparisonLookup ? ["params"] extends [keyof ComparisonLookup[TOp]] ? ComparisonLookup[TOp]["params"] extends readonly unknown[] ? ComparisonLookup[TOp]["params"] : never : readonly unknown[] : readonly unknown[], readonly unknown[]>; //#endregion //#region ../types/src/boolean-logic/combinators/Every.d.ts type Process$50> = TElements extends [infer Head, ...infer Rest] ? TElements extends readonly unknown[] ? Head extends ComparisonAccept ? [Compare] extends [true] ? Process$50 : false : Process$50 : false : true; /** * **Every**`` * * Evaluates a container (_a tuple or kv object_) to see if **every** one of * the _values_ it contains match the comparison provided by the `TOp` and * `TComparator`. * * ```ts * // true * type T = Every<["foo","bar","baz"], "extends", [string]>; * // false * type F = Every<["foo","bar","baz", 42], "extends", [string]>; * ``` */ type Every | First$1>> = IsWideContainer extends true ? boolean : Process$50, TOp, TComparator extends GetComparisonParams ? TComparator : TComparator extends First$1> ? [TComparator] extends GetComparisonParams ? [TComparator] : never : never>; //#endregion //#region ../types/src/boolean-logic/combinators/Logic.d.ts type LogicHandler = "truthy" | "false" | "never"; type Handle = THandler extends "truthy" ? IsTruthy : THandler extends "false" ? false : THandler extends "never" ? never : never; /** * Converts any type `T` into a `true`, `false` or `boolean`. * * - if `never` is passed in it will always be proxied through * - if a value is neither: * - `true`, `false`, or `boolean` * - nor _returns_ `true`, `false`, or `boolean` * - the generic `U` will come into effect * - by default it is set to `truthy` */ type Logic = [IsTrue] extends [true] ? true : [IsFalse] extends [true] ? false : [IsBoolean] extends [true] ? boolean : [IsNever] extends [true] ? never : [T] extends [LogicFunction] ? [IsTrue>] extends [true] ? true : [IsFalse>] extends [true] ? false : [IsBoolean>] extends [true] ? boolean : [IsNever>] extends [true] ? never : Handle : Handle; //#endregion //#region ../types/src/boolean-logic/combinators/Not.d.ts /** * **Not**`` * * A boolean negation that can work on both a single value or an * tuple of values. * * ```ts * // false * type Single = Not; * // [ false, true, boolean ] * type Multi = Not<[true,false,boolean]>; * ``` * * **Related:** `Inverse` */ type Not = [IsAny] extends [true] ? Logic : [IsNever] extends [true] ? Logic : [IsUnknown] extends [true] ? Logic : [TVal] extends [readonly unknown[]] ? { [K in keyof TVal]: Logic } : [IsTrue>] extends [true] ? false : [IsFalse>] extends [true] ? true : [IsBoolean>] extends [true] ? boolean : never; //#endregion //#region ../types/src/boolean-logic/combinators/Or.d.ts interface LogicOptions { empty?: boolean | unknown; err?: "false" | "error" | unknown; } type Reduce$1 = { [K in keyof T]: T[K] extends TypedFunction ? ReturnType : T[K] }; /** * **Or**`` * * Performs logical OR operation on an array of boolean values or functions returning boolean. * * - Returns `true` if any element is `true` * - Returns `boolean` if any element is wide `boolean` type * - Returns `false` if all elements are `false` * - Returns `false` for empty arrays (or value from options.empty) * - Returns `boolean` for wide arrays (length not known at compile time) * - Supports functions that return boolean values * - Configurable error handling via options parameter * * **Related:** `And`, `Not` */ type Or = IsAny extends true ? TOpt extends { err: "error"; } ? Err<"invalid/or", "The Or<...> logical combinator has a 'any' type! Or is expecting a tuple of boolean values (or functions which return boolean).", { library: "inferred-types"; }> : false : IsNever extends true ? TOpt extends { err: "error"; } ? Err<"invalid/or", "The Or<...> logical combinator has a 'never' type! Or is expecting a tuple of boolean values (or functions which return boolean).", { library: "inferred-types"; }> : false : HasAny extends true ? TOpt extends { err: "error"; } ? Err<"invalid/or", "The Or found elements in T which were the 'any' type! Or expects all elements to be a boolean value or a function which returns a boolean value.", { value: T; }> : false : HasNever extends true ? TOpt extends { err: "error"; } ? Err<"invalid/or", "The Or found elements in T which were the 'never' type! Or expects all elements to be a boolean value or a function which returns a boolean value.", { value: T; }> : false : T extends readonly (boolean | TypedFunction)[] ? number extends T["length"] ? boolean : [] extends T ? TOpt extends { empty: infer E; } ? E : false : T extends readonly boolean[] ? HasTrue extends true ? true : HasWideBoolean extends true ? boolean : false : Reduce$1 extends readonly boolean[] ? HasTrue> extends true ? true : HasWideBoolean> extends true ? boolean : false : TOpt extends { err: "error"; } ? Err<"invalid/or", "The conditions passed into Or could not be reduced down to just a boolean array.", { library: "inferred-types"; value: T; }> : false : TOpt extends { err: "error"; } ? Err<"invalid/or", "The Or type utility requires that all elements passed to it are either a boolean value directly or a LogicFunction which returns a boolean value", { value: T; }> : false; //#endregion //#region ../types/src/boolean-logic/combinators/Some.d.ts type Process$49, THasBool extends boolean = false> = [] extends TComparator ? IsTrue extends true ? boolean : false : T extends readonly unknown[] ? T extends readonly [infer First, ...infer Rest] ? First extends ComparisonAccept ? [Compare] extends [false] ? Process$49 : [Compare] extends [true] ? true : [Compare] extends [boolean] ? Process$49 : Process$49, TOp, TComparator, THasBool> : false : false : false; /** * **Some**`` * * Evaluates a container (_a tuple or kv object_) to see if **some** of the _values_ it contains * match the comparison provided by the `TOp` and `TComparator`. * * ```ts * // true * type Test = Some<["foo","bar","baz"], "equals", ["foo"]>; * ``` */ type Some | GetComparisonParams[0]> = IsWideContainer extends true ? boolean : Process$49, TOp, TComparator extends GetComparisonParams ? TComparator : TComparator extends GetComparisonParams[0] ? [TComparator] extends GetComparisonParams ? [TComparator] : never : never>; //#endregion //#region ../types/src/boolean-logic/narrowing/As.d.ts /** * **As**`` * * Ensures that `TContent` _extends_ `TType` or turns type to `never`. */ type As$1 = [TContent] extends [TType] ? TContent : never; //#endregion //#region ../types/src/boolean-logic/narrowing/AsDoneFn.d.ts /** * **AsDoneFn**`` * * Narrows */ type AsDoneFn = T extends { done: FnWithDescription; } ? T & { done: () => unknown; } : never; //#endregion //#region ../types/src/boolean-logic/operators/compare/AllLiteral.d.ts /** * **AllLiteral**`` * * A boolean operator which tests whether all properties in * the tuple `TTuple` are _literal_ types. */ type AllLiteral = And<{ [K in keyof T]: IsLiteralLike extends true ? true : false }>; //#endregion //#region ../types/src/boolean-logic/operators/compare/AreIncompatible.d.ts /** * **AreIncompatible**`` * * Checks if two types are fundamentally incompatible and can never be equal. * For example, string and number are incompatible, but string and string | number * are not incompatible because they could overlap. */ type AreIncompatible = Or<[IsNever, IsNever]> extends true ? false : [T] extends [U] ? false : [U] extends [T] ? false : [T, U] extends [string, number] ? true : [T, U] extends [number, string] ? true : [T, U] extends [string, boolean] ? true : [T, U] extends [boolean, string] ? true : [T, U] extends [number, boolean] ? true : [T, U] extends [boolean, number] ? true : [T, U] extends [string, null] ? true : [T, U] extends [null, string] ? true : [T, U] extends [number, null] ? true : [T, U] extends [null, number] ? true : [T, U] extends [boolean, null] ? true : [T, U] extends [null, boolean] ? true : [T, U] extends [string, undefined] ? true : [T, U] extends [undefined, string] ? true : [T, U] extends [number, undefined] ? true : [T, U] extends [undefined, number] ? true : [T, U] extends [boolean, undefined] ? true : [T, U] extends [undefined, boolean] ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/compare/DoesExtend.d.ts /** * **DoesExtend**`` * * Boolean type utility which returns `true` if `TValue` _extends_ `TExtends`. */ type DoesExtend = IsNever extends true ? false : [TValue] extends [TExtends] ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/compare/Extends.d.ts /** * **Extends**`` * * A boolean operator which checks whether `T` extends `U` and returns * **true** or **false**. This is an _alias_ for `DoesExtend`. */ type Extends = IsNever extends true ? IsNever extends true ? true : false : DoesExtend; //#endregion //#region ../types/src/boolean-logic/operators/compare/HasOtherCharacters.d.ts type Process$48 = ReplaceAll extends "" ? false : true; /** * **HasOtherCharacters**`` * * Boolean type utility which tests whether `TStr` has any * characters _other_ than those in `TChars`. * * - union types are fine for `TChars` * - a tuple for `TChars` behaves the same as union type * * **Related:** `HasCharacters` */ type HasOtherCharacters = [IsWideType] extends [true] ? boolean : [TChars] extends [string] ? IsWideType extends true ? boolean : Process$48 : TChars extends readonly string[] ? Process$48> : never; //#endregion //#region ../types/src/boolean-logic/operators/compare/IsEmpty.d.ts /** * Boolean operator which returns `true` when `T` is: * * - `null` or `undefined` * - and empty array * - an empty object * - an empty string (aka, `""`) * * If `T` is a _wide_ type this will always return `boolean` */ type IsEmpty = T extends undefined ? true : T extends null ? true : IsWideType extends true ? boolean : IsEmptyObject extends true ? true : IsEmptyArray extends true ? true : IsEmptyString extends true ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/compare/IsEqual.d.ts /** * **IsEqual**`` * * Type utility which tests whether two types -- `X` and `Y` -- are * exactly the same type. * * - if either `X` or `Y` are **any** then this test resolves to **false** * * **Alias:** `Equals` */ type IsEqual = Equals; /** * **Equals**`` * * Type utility which tests whether two types -- `X` and `Y` -- are * exactly the same type. * * - if either `X` or `Y` are **any** then this test resolves to **false** * * **Alias:** `IsEqual` */ type Equals = As$1<[IsAny] extends [true] ? false : [IsAny] extends [true] ? false : [X] extends [Y] ? [Y] extends [X] ? [X] extends [Container] ? [Keys$1] extends [Keys$1>] ? [Keys$1>] extends [Keys$1] ? TTrue : TFalse : TFalse : TTrue : TFalse : TFalse, TTrue | TFalse>; //#endregion //#region ../types/src/boolean-logic/operators/compare/IsUnknown.d.ts /** * **IsUnknown**`` * * Tests whether a given `T` is of the **unknown** type. */ type IsUnknown = [IsNever] extends [true] ? false : [IsAny] extends [true] ? false : IsEqual extends true ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/compare/IsUnset.d.ts /** * **IsUnset**`` * * Boolean operator which reports true/false on whether * `T` is the value `Unset`. */ type IsUnset = IsEqual; //#endregion //#region ../types/src/boolean-logic/operators/compare/IsVueRef.d.ts /** * **IsVueRef**`` * * Boolean type utility that detects whether the type passed in * is a VueJS `Ref<...>` type or this library's `VueRef<...>` * (which serves as a lightweight proxy type for Vue's `Ref`). */ type IsVueRef = T extends object ? And<[Keys$1["length"] extends 2 ? true : false, "value" extends keyof T ? true : false]> extends true ? true : false : false; //#endregion //#region ../types/src/boolean-logic/operators/compare/NarrowlyContains.d.ts /** * **NarrowlyContains**`` * * Type utility which checks whether all elements in a tuple `TList` * **equal** the type contained in `TContains`.s * * @deprecated use `Contains` with "equals" operator for this * functionality. * * **Related:** `Contains`, `ContainsAll`, `ContainsSome` */ type NarrowlyContains = IsEqual, TContains> extends true ? true : [] extends AfterFirst ? false : NarrowlyContains, TContains>; //#endregion //#region ../types/src/boolean-logic/operators/compare/NotEqual.d.ts /** * **NotEqual**`` * * Boolean utility to determine whether two values are **not** equal. */ type NotEqual = IsEqual extends true ? false : true; //#endregion //#region ../types/src/boolean-logic/operators/compare/SomeEqual.d.ts /** * **SomeEqual**`` * * A type utility which tests whether `TVal` is exactly equal to an array of values * stored in `TList`. Possible results are `true`, `false`. A wide `boolean` type * is not possible as equality operator can always be evaluated at design time. * * **See Also:** `SomeExtend` and `IfSomeEqual` */ type SomeEqual = Or<{ [K in keyof TList]: IsEqual }>; //#endregion //#region ../types/src/boolean-logic/operators/containers/AllStringLiterals.d.ts /** * **AllStringLiterals**`` * * Boolean operator which checks whether **all** of the * passed in elements are _string literals_. */ type AllStringLiterals = And<{ [K in keyof T]: IsStringLiteral$1 }>; //#endregion //#region ../types/src/boolean-logic/operators/containers/HasArray.d.ts type _HasArray = [] extends TList ? false : IsArray> extends true ? true : _HasArray>; /** * **HasArray**`` * * Checks whether a list of items includes an _array_ (tuple or wide array type) within it. */ type HasArray = _HasArray; //#endregion //#region ../types/src/boolean-logic/operators/containers/HasSameKeys.d.ts /** * **AsTuple**`` * * Type utility which ensures that `T` is tuple value * encapsulating it as a single item array if it is a * non-array type. * * **Related:** `AsArray` */ type AsTuple = T extends Tuple$1 ? T : T extends unknown[] ? readonly [...T] : If, readonly [], readonly [T]>; type Process$47 = And<{ [K in keyof A]: K extends keyof B ? true : false }>; type _Keys$1 = UnionToTuple> extends readonly ObjectKey[] ? UnionToTuple> : never; /** * **HasSameKeys**`` * * Boolean operator which compares two lists to see if they have the same keys. */ type HasSameKeys = IsTuple extends true ? IsTuple extends true ? AsTuple["length"] extends AsTuple["length"] ? Process$47, AsTuple> : false : false : DoesExtend extends true ? DoesExtend extends true ? _Keys$1["length"] extends _Keys$1["length"] ? HasSameValues<_Keys$1, _Keys$1> : false : false : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/HasSameValues.d.ts type CheckAllExist = [] extends A ? true : And<{ [K in keyof A]: NarrowlyContains }>; type Test$6 = A extends readonly unknown[] ? B extends readonly unknown[] ? [] extends A ? [] extends B ? true : false : [] extends B ? false : A["length"] extends B["length"] ? CheckAllExist extends true ? CheckAllExist extends true ? true : false : false : false : false : false; /** * **HasSameValues**`` * * Boolean type utility which determines if the values in * `TContainer` and `TComparator` are the same (even if the order * is different). * * #### Wide Types * * - if _either_ `TContainer` or `TComparator` are wide types then * this utility will evaluate to `boolean` rather than the typical `true` * or `false` literals * * #### `any` and `never` * * - if _either_ `TContainer` or `TComparator` or _both_ are equal to * `never` or `any` then this utility will resolve to `TException` (which * defaults to being `false`)! */ type HasSameValues = [IsAny] extends [true] ? TException : [IsNever] extends [true] ? TException : [IsAny] extends [true] ? TException : [IsNever] extends [true] ? TException : Test$6>, Values>> extends true ? TContainer extends readonly unknown[] ? TComparator extends readonly unknown[] ? IsEqual, GetOptionalElementCount> : false : TContainer extends Dictionary ? TComparator extends Dictionary ? IsEqual>, GetOptionalElementCount>> : false : never : TException; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsArray.d.ts /** * **IsArray** * * Boolean utility which tests for whether `T` is an array ( * both a mutable array or a readonly array) */ type IsArray = [T] extends [any[]] ? true : [T] extends [readonly any[]] ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsContainer.d.ts /** * **IsContainer**`` * * Boolean operator which detects whether `T` is a "container" where a * container is any object or array. */ type IsContainer = [IsNever] extends [true] ? false : [T] extends [null | undefined] ? false : [T] extends [AnyFunction] ? false : [T] extends [readonly any[]] ? true : [T] extends [object] ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsDictionary.d.ts type IsDictionary = T extends Dictionary ? Not> : false; //#endregion //#region ../types/src/lists/AfterFirst.d.ts /** * **AfterFirst**`` * * returns the elements in an array _after_ the first element */ type AfterFirst = T extends readonly [unknown, ...unknown[]] ? T extends readonly [unknown, ...infer Rest] ? readonly [...Rest] : never : T extends unknown[] ? [] : T extends [unknown, ...infer Rest] ? Rest : []; //#endregion //#region ../types/src/lists/AppendToLast.d.ts /** * **AppendToLast**`` * * Appends some text `TAppend` to the last element of `TList`. */ type AppendToLast = TList extends readonly [...infer LeadIn extends readonly string[], infer Last extends string] ? [...LeadIn, `${Last}${TAppend}`] : [TAppend]; //#endregion //#region ../types/src/lists/AsArray.d.ts type NonArrayMembers = NotFilter extends infer Members extends readonly unknown[] ? Members[number] : never; type ArrayMembers = { [K in keyof T]: T[K] extends readonly (infer Kind)[] ? As$1[]> : never }[number]; /** * **AsArray**`` * * Type utility which ensures that `T` is an array by: * * - encapsulating it as a single item array if it is a * non-array type (but not _undefined_). * - converting a union type into a tuple (unless it contains undefined) * - if `T` is undefined then it is converted to an empty array `[]` * - if `T` was already an array then it is just proxied through * - if `T` is a union then non array elements are converted to array types */ type AsArray = [IsAny] extends [true] ? unknown[] : [IsNever] extends [true] ? [] : [IsUnknown] extends [true] ? unknown[] : [T] extends [readonly (infer Kind)[]] ? As$1[]> : [IsUndefined] extends [true] ? [] : [IsUnion] extends [true] ? [UnionToTuple] extends [infer Tuple extends readonly unknown[]] ? Expand> | ArrayMembers> : never : IsUndefined extends true ? [] : [T]; //#endregion //#region ../types/src/lists/BeforeLast.d.ts /** * **BeforeLast**`` * * Returns: * * - the _elements_ in an **array**; _excluding_ the last element * - the _characters_ in a **string** excluding the last character * * This behavior is _very_ much like `Pop` but where `Pop` will * return _never_ when an empty input is passed in, this utility returns * the "empty" state: * * - a _tuple_ will return `[]` * - a _string_ will return "" * * **Related:** `Pop`, `Last`, `AfterFirst`, `First` */ type BeforeLast = [T] extends [string] ? string extends T ? string : IsEqual extends true ? "" : Pop> extends infer Leading extends readonly string[] ? Concat : never : [T] extends [readonly unknown[]] ? T extends readonly [...infer Leading, unknown] ? Leading : [] : never; //#endregion //#region ../types/src/lists/ConvertAndMap.d.ts /** * **ConverterDefn**`` * * A conversion definition which has wide types for keys and * callback functions to call when a particular type is provided * as input. */ interface ConverterDefn { string: (v: T) => TStr; number: (v: T) => TNum; boolean: (v: T) => TBool; object: (v: T) => TObj; tuple: (v: T) => TTuple; nothing: (v: T) => TNothing; } //#endregion //#region ../types/src/lists/EachAsString.d.ts type EachAsString = { [K in keyof T]: T[K] extends string ? T[K] : T[K] extends number ? `${T[K]}` : T[K] extends boolean ? `${T[K]}` : T[K] extends AnyObject ? ObjectToString : T[K] extends readonly any[] ? ToJsonArray : T[K] extends Map ? `Map<${AsString},${AsString}>` : "" }; //#endregion //#region ../types/src/lists/ElementOf.d.ts /** * **ElementOf**`` * * Pulls the type of an array's element out of the array type itself. */ type ElementOf = T extends (infer U)[] ? U : never; //#endregion //#region ../types/src/lists/Filter.d.ts type Process$46[], TOp extends ComparisonOperation, TParams extends readonly unknown[]> = RemoveMarked<{ [K in keyof TList]: Compare extends true ? TList[K] : Marked$2 }>; /** * **Filter**`` * * Allows a known tuple `TList` to be reduced to just those elements which * _extend_ type `TFilter`. * * - `TFilter` can be single value, an array of values, or even no values at all * - the number of parameters is dictated by the operation * - if _either_ zero or one parameters are required you may also just * express the first parameter outside of array syntax. * * **Related:** `NotFilter` * * ```ts * // [1,2,3] * type Num = Filter<[1,2,3,"foo","bar"], "extends", number>; * ``` */ type Filter[], TOp extends ComparisonOperation, TParams extends readonly unknown[]> = Process$46; //#endregion //#region ../types/src/lists/Find.d.ts type FindAcc)[], TOp extends ComparisonOperation, TParams extends GetComparisonParams> = [] extends TList ? undefined : First$1 extends ComparisonAccept ? [Compare, TOp, TParams>] extends [true] ? First$1 : FindAcc, TOp, TParams> : never; /** * **Find**`` * * Type utility used to find the first value in `TList` which _equals_ `TValue`. * Will return _undefined_ if no matches found. * * - use **FindExtends** if you want a more permissive match * - by default, values in `TList` will be compared directly but you can _dereference_ * array and object properties with `TIndex` if you want to compare on a child property * * ```ts * type List = [ { id: 1, value: "hi" }, { id: 2, value: "bye" } ] * // { id: 1; value: "hi" } * type T = Find * ``` */ type Find$2> = TList extends readonly ComparisonAccept[] ? FindAcc : undefined; //#endregion //#region ../types/src/lists/FindMaxLength.d.ts type Reduce = [] extends T ? TVal : Reduce, First$1 extends [string, infer Len extends number] ? If, Len, TMax> : TMax, First$1 extends [infer Val extends string, infer Len extends number] ? If, Val, TVal> : TVal>; /** * **FindMaxLength**`` * * Utility which reduces a tuple of strings to only the * string which is longest. */ type FindMaxLength = T extends readonly string[] ? Reduce<{ [K in keyof T]: T[K] extends string ? [T[K], StrLen] : never }> : never; //#endregion //#region ../types/src/lists/First.d.ts /** * **First**`` * * Returns the _first_ type in a list. If `TElse` is provided it will set * the type to `TElse` when: * - `T` is a Tuple type * - `T[1]` is not a valid index of `T` * - by default `TElse` is set to _never_ * * **Related:** `Second`, `Last` */ type First$1 = T extends readonly unknown[] ? T[0] extends T[number] ? T[0] : ELSE : never; //#endregion //#region ../types/src/lists/Flatten.d.ts type ToFlat = IsArray extends true ? As$1 : IsUnion extends true ? UnionHasArray extends true ? [FlattenUnion] : [T] : [T]; type FlatPass = [] extends TList ? TResult : FlatPass, [...TResult, ...ToFlat>]>; /** * Processes Tuple structures. * * - Each pass will start by validating that `TList` still has * either Tuples within it or values which are Tuples * - Assuming it does */ type FlattenTuple = TLevel extends 0 ? TList : Or<[HasUnionType, HasArray]> extends true ? FlattenTuple, Decrement> : TList; type Iterate$6 = TupleToUnion<{ [K in keyof T]: T[K] extends readonly unknown[] ? Flatten : T[K] }>; type FlattenUnion = IsUnion extends true ? Iterate$6, 1> : TValue; type WideFlatten = T extends (infer Type)[] ? Type extends unknown[] ? Type : T : never; /** * Responsible for branching the flattening operation * to either `_Flat`, `WideFlatten` for Tuples or Arrays * and `FlattenUnion` for a union type. * * Just returns `TList` "as is" if it's not a a Tuple or * Union type. */ type Process$45 = TList extends readonly unknown[] ? IsTuple extends true ? FlattenTuple : WideFlatten : IsUnion extends true ? FlattenUnion : TList; /** * converts a wide array to a scalar and tuple * to a union type */ type ToScalar = [IsTuple>] extends [true] ? TupleToUnion> : Process$45 extends (infer Type)[] ? Type : never; type IterateScalar = TupleToUnion<{ [K in keyof T]: T[K] extends unknown[] ? ToScalar : T[K] }>; /** * **Flatten**`` * * - where `TList` is an array, this utility will flatten the array to a depth of * `TLevel` (by default one level). * - where `TList` is a _union type_ it will flatten any of it's elements * - where `TList is neither an array nor has a union type which is, this utility * simply proxies the value `TList` through * - in most cases you would not _flatten_ below a single dimensional array but * if you set `ToScalar` to `true` then it will flatten right out of being an array * into a union type */ type Flatten = [ToScalar] extends [false] ? Process$45 : [IsUnion>] extends [true] ? IterateScalar>, TLevel> : [IsTuple>] extends [true] ? TupleToUnion> : Process$45 extends (infer Type)[] ? Type : never; //#endregion //#region ../types/src/lists/GetEach.d.ts type Process$44 = RemoveNever<{ [K in keyof TList]: TList[K] extends Container | TypedFunction | Error ? Get$2 : TList[K] extends TypedFunction ? Get$2, TKey, TDefault> : TKey extends "." ? TList[K] : never }>; /** * **GetEach**`` * * Type utility which receives a list of types -- `TList` -- and then _gets_ a * key `TKey` (using dot syntax) from each element in the array. * * - if a given element is not an object then it is excluded from the result set * - values which evaluate to _undefined_ are also removed from the result set * - if either `null` or "" are used for `TKey` then this simply proxies `TList` * through * * ```ts * // ["Bob", "Wendy"] * type T = GetEach<[ * { name: "Bob", age: 12 }, * { name: "Wendy", age: 24 } * ], "name"> * ``` */ type GetEach = TKey extends null ? TList : TKey extends "" ? TList : Process$44<[...TList], Exclude, TDefault> extends readonly unknown[] ? Process$44<[...TList], Exclude, TDefault> : never; //#endregion //#region ../types/src/lists/IndexOf.d.ts type Override$1 = TOverride extends Constant<"no-override"> ? TValue : TValue extends Error ? TOverride : TValue; type NegativeIndex = TDepth["length"] extends TPositive ? TValue extends readonly [infer Head, ...readonly unknown[]] ? Head : Err<"invalid-index", `Use of a negative index [${AsString}] was unsuccessful in matching a valid index`, { container: TValue; key: TIdx; revIndex: TPositive; revContainer: Reverse; }> : TValue extends readonly [unknown, ...infer Rest] ? NegativeIndex : If, TValue[TPositive], Err<"invalid-index", `Use of a negative index [${AsString}] was unsuccessful in matching a valid index`, { container: TValue; key: TIdx; revIndex: TPositive; revContainer: Reverse; }>>; type HandleArr = TIdx extends number ? IsNegativeNumber extends true ? NegativeIndex, TIdx> : If, TValue[TIdx], Err<"invalid-index", Concat<["Attempt to index [", ToString, "] into a non-container type!"]>, { container: TValue; key: TIdx; library: "inferred-types/constants"; }>> : Err<"invalid-index", `IndexOf}> failed because a tuple container must use numeric indexes!`, { container: TValue; key: TIdx; library: "inferred-types/constants"; }>; type HandleObj = TIdx extends keyof TValue ? TValue[TIdx] : Err<"invalid-index", Concat<["Attempt to index [", ToString, "] into a non-container type!"]>, { container: TValue; key: TIdx; library: "inferred-types/constants"; }>; type Process$43 = If, TValue, TValue extends readonly unknown[] ? If>, HandleArr>, Err<"invalid-index", `Call to IndexOf,${AsString}> is not allowed as an tuple based container must receive either null or numeric index value.`, { library: "inferred-types/constants"; container: TValue; key: TIdx; }>> : TValue extends Dictionary ? TIdx extends ObjectKey ? HandleObj : Err<"invalid-index", `Call to IndexOf,${AsString}> is not allowed as an object based container must receive either null, a string, or a symbol index value.`, { library: "inferred-types/constants"; container: TValue; key: TIdx; }> : Err<"invalid-index", `IndexOf,${AsString}> was called but a non-null value was used to index a non-container which will never work!`, { library: "inferred-types/constants"; container: TValue; key: TIdx; }>>; /** * **IndexOf** * * A type utility which _dereferences_ a property/index item on an array * or object. * * - if `TIdx` is passed in as `null` then this will act as an identity * function and return `TValue`. * - if `TIdx` is a negative number it will index in reverse for tuple based * containers * * **Related:** `Get`, `IsValidIndex` * * **Errors:** produces an Error when an a bad index value * is passed in for the given container */ type IndexOf> = TIdx extends null ? TValue : Override$1>, TOverride>; //#endregion //#region ../types/src/lists/Last.d.ts /** * **Last**`` * * Returns the _last_ element in a list of elements. * * - by default `TEmpty` is _never_ but this can be changed. */ type Last$1 = IfLength extends readonly unknown[] ? TContent[AfterFirst["length"]] extends TContent[number] ? TContent[AfterFirst["length"]] : TEmpty : TEmpty>>; //#endregion //#region ../types/src/lists/LogicalReturns.d.ts type Process$42 = { [K in keyof TValues]: TValues[K] extends ((...args: any[]) => boolean) ? ReturnType : TValues[K] }; /** * **LogicalReturns**`` * * Given a known tuple of values, this utility will reduce it to * another tuple of items which are either a _boolean type_ or a function * with a boolean return. In the latter case the function's return value * will be represented in the Tuple. * * **Related**: `ReturnTypes` and `TruthyReturns` */ type LogicalReturns = Process$42 extends readonly boolean[] ? Process$42 : never; //#endregion //#region ../types/src/lists/MakeOptional.d.ts type Process$41 = TInput extends readonly [infer Head extends unknown, ...infer Rest extends readonly unknown[]] ? Depth["length"] extends 128 ? readonly unknown[] : IsGreaterThan extends true ? Process$41, { required: TOutput["required"]; optional: [...TOutput["optional"], Head]; }, [unknown, ...Depth]> : Process$41, { required: [...TOutput["required"], Head]; optional: TOutput["optional"]; }, [unknown, ...Depth]> : [...TOutput["required"], ...Partial]; /** * **MakeOptional**`` * * Take a tuple `T` and makes the last `U` elements _optional_ with the * `?` optional modifier. * * ```ts * // [ string, number, string? ] * type Test = MakeOptional<[string, number, string], 1>; * ``` * * **Note:** * - the mix of optional vs. required elements in `T` has no bearing on * the outcome. * * **Related:** `MakeKeysOptional` */ type MakeOptional = Subtract["length"], U> extends infer Req extends number ? number extends Req ? never : Process$41, Req> : never; //#endregion //#region ../types/src/lists/NotFilter.d.ts type Process$40[], TOp extends ComparisonOperation, TParams extends readonly unknown[]> = RemoveMarked<{ [K in keyof TList]: [Compare] extends [false] ? TList[K] : Marked$2 }>; /** * **NotFilter**`` * * Performs the same task as `Filter` but with the opposite results. * * - when elements are evaluated to `true` on their comparison operation * they are _removed_ * * **Related:** `Filter` * * ```ts * // ["foo","bar"] * type NotNum = NotFilter<[1,2,3,"foo","bar"], "extends", number>; * ``` */ type NotFilter[], TOp extends ComparisonOperation, TParams extends readonly unknown[]> = Process$40; //#endregion //#region ../types/src/lists/NumericKeys.d.ts type IndicesTuple = number extends T["length"] ? number[] : T extends readonly [any, ...infer R] ? IndicesTuple : Acc; /** * **NumericKeys**<`TList`> * * Will provide a tuple of numeric keys for * a literal array and `number[]` for a wide array. * * ```ts * type Arr = ["foo", "bar", "baz"]; * // readonly [0, 1, 2] * type T = NumericKeys; * ``` * * **Related:** `NumericKeys__Union`, `Keys`, `ObjectKeys` */ type NumericKeys = HasVariadicTail extends true ? DropVariadicTail extends infer NonVariadic extends readonly unknown[] ? IndicesTuple extends infer NonVariadic extends readonly unknown[] ? [...NonVariadic, ...number[]] : never : never : IndicesTuple; //#endregion //#region ../types/src/lists/Pop.d.ts type _Pop = TVal extends [...(infer Rest), unknown] ? Rest : []; type AdjustVariadic< /** the list of elements with any variadic elements removed */TList extends readonly unknown[], /** the original array which we'll use to detect variadic properties */TOrigin extends readonly unknown[], /** the element which was just removed */TRemoved, TType = (VariadicType extends (infer Base)[] ? Base : never)> = IsVariadicArray extends true ? TRemoved extends TType ? [...TList, ...TType[]] : [...TList, ...TType[]] | [...TList, TRemoved, ...TType[]] : TList; /** * **Pop**`` * * Removes the last element of a list. * ```ts * // [1,2] * type T = Pop<[1,2,3]>; * ``` * * - to provide additional utility, you can also pass * in a string literal and get back the literal with the last * character removed. * - when popping an empty tuple/array, the type remains `[]` */ type Pop = TList extends readonly unknown[] ? IsWideArray extends true ? TList : DropVariadic> extends [...infer NewList extends readonly [unknown, ...unknown[]], infer Removed] ? HasOptionalElements extends true ? TupleMeta["optionalElementCount"] extends infer Optional extends number ? IsGreaterThan, 0> extends true ? MakeOptional> extends infer Next extends readonly unknown[] ? AdjustVariadic), TList, Removed> : never : NewList | Pop : NewList | Pop : AdjustVariadic : [] : TList extends string ? IsWideType extends true ? string : IsStringLiteral$1 extends true ? TList extends string ? TList extends "" ? "" : Chars extends readonly string[] ? Concat<_Pop>> : never : never : string : _Pop>; //#endregion //#region ../types/src/lists/Push.d.ts type Process$39 = [...TList, TValue]; /** * **Push**`` * * Pushes a value `TVal` onto an existing list `TList`. * * - If you want to make the push conditional you can add `TCondition` */ type Push = [TCondition] extends [true] ? As$1, readonly unknown[]> : TList; //#endregion //#region ../types/src/lists/Reverse.d.ts type RevAcc = TInput extends [infer Head, ...infer Rest] ? RevAcc : TResults; /** * **Reverse**`` * * Reverses the order of a `Tuple` or a `string`. * * **Note:** * - to ensure all elements are retained while **not** breaking the rules * regarding _optional_ elements not being allowed to precede _required_ ones * we convert all elements to **required** rather than risk losing elements. */ type Reverse = T extends readonly unknown[] ? RevAcc> : T extends string ? Join>> : never; //#endregion //#region ../types/src/lists/Second.d.ts /** * **Second**`` * * Returns the _second_ type in a list. If `TElse` is provided it will set * the type to `TElse` when: * - `T` is a Tuple type * - `T[1]` is not a valid index of `T` * - by default `TElse` is set to _never_ * * **Related:** `First`, `Last` */ type Second$2 = T extends readonly unknown[] ? T[1] extends T[number] ? T[1] : ELSE : never; //#endregion //#region ../types/src/lists/Shift.d.ts type _Shift = TList extends [unknown, ...(infer Tail)] ? Tail : undefined; /** * **Shift**`` * * Removes the first element of a list, returning the rest. * ```ts * // [2,3] * type T = Shift<[1,2,3]>; * ``` * * - to provide additional utility, you can also pass * in a string literal and get back the literal with the first * character removed. * - if there is nothing left in Tuple or an empty string is passed in as input * then the output will _undefined_. */ type Shift$1 = IsUndefined extends true ? undefined : [] extends T ? undefined : T extends readonly unknown[] ? _Shift> : string extends T ? string : T extends string ? T extends "" ? undefined : _Shift>>> extends readonly string[] ? Concat<_Shift>>>> : undefined : never; //#endregion //#region ../types/src/lists/Shortest.d.ts type Process$38 = T extends [infer Head extends string, ...infer Rest extends readonly string[]] ? Depth["length"] extends 128 ? TResult extends Unset ? string : TResult : Process$38 extends true ? Min$1<[TShortest, Length]> : TShortest, IsStringLiteral$1 extends true ? IsLessThan, TShortest> extends true ? Head : TResult : TResult, [unknown, ...Depth]> : TResult extends Unset ? string : TResult; /** * **Shortest**`` * * Takes a tuple of strings and returns the shortest one in the tuple. * * - if more than one string is _tied_ for being shortest then * the **first** one found will be returned. * - if _all_ elements passed in were wide then the result will be `string` * - if _some_ of the elements passed in were wide then they will be * ignored and only the literal strings will be compared */ type Shortest = Process$38; //#endregion //#region ../types/src/lists/Slice.d.ts type PositiveOfNegative = `${T}` extends `-${infer N extends number}` ? N : never; type DropLeading = TDepth["length"] extends TStart ? TList : number extends TStart ? TList : TDepth["length"] extends 64 ? TList : TList extends readonly [unknown, ...infer Rest] ? DropLeading : never; type DropTrailing = Subtract extends infer Keep extends number ? number extends TStart ? TList : TakeFirst : []; type TruncateAtLen = TLen extends number ? number extends TLen ? TList : `${TLen}` extends `-${string}` ? DropTrailing> : TakeFirst : TList; type ProcessList = TList extends readonly unknown[] ? number extends TStart ? TruncateAtLen : `${TStart}` extends `-${string}` ? TakeLast> : IsGreaterThan extends true ? TLen extends number ? [] : never : TruncateAtLen, TLen> : never; type ProcessChars = ProcessList extends readonly string[] ? ProcessList extends infer Result extends readonly string[] ? Concat : never : never; /** * **Slice**`` * * Provides a slice of a tuple or a string. * * - negative indexes for `TEnd` can be used * - `TStart` defaults to 0 * - `TLen` defaults to the all the remaining elements * but can be any amount; if you use negative values this * will drop that many values off the end of the tuple * * **Related:** `SliceArray`, `SliceString` */ type Slice = [TList] extends [string] ? SliceString : [TList] extends [readonly unknown[]] ? SliceArray : never; /** * **SliceArray** * * Slices an array. * * - negative indexes for `TEnd` can be used * - `TStart` defaults to 0 * - `TLen` defaults to the all the remaining elements * but can be any amount; if you use negative values this * will drop that many values off the end of the tuple * * **Related:** `Slice`, `SliceArray` */ type SliceString = Chars extends infer Characters extends readonly string[] ? IsGreaterThan extends true ? "" : ProcessChars : never; /** * **SliceArray** * * Slices an array. * * - negative indexes for `TEnd` can be used * - `TStart` defaults to 0 * - `TLen` defaults to the all the remaining elements * but can be any amount; if you use negative values this * will drop that many values off the end of the tuple * * **Related:** `Slice`, `SliceString` */ type SliceArray = ProcessList<[...TList], TStart, TLen> extends infer Result extends readonly unknown[] ? Result extends readonly (TList[number])[] ? Result : never : never; //#endregion //#region ../types/src/lists/sort/Sort.d.ts type SortOrder$1 = "ASC" | "DESC" | "Natural"; type Dotpath = string; /** * **SortOptions**`<[TOrder],[TOffset],[TStart],[TEnd]>` * * Specifies how you'd like a list sorted. */ interface SortOptions { /** * the sorting strategy for the list * * @default "ASC" */ order?: SortOrder$1; /** * by adding a `DotPath` to the offset you are expressing that * the items in your list are some sort of a container and you'd * like the sorting comparison to be done on the offset/index specified. * * @default undefined */ offset?: Dotpath | undefined; /** * allows pinning items to the _start_ of the list * Can be a single value or array of values * * @default undefined */ start?: unknown; /** * allows pinning items to the _end_ of the list * Can be a single value or array of values * * @default undefined */ end?: unknown; } //#endregion //#region ../types/src/lists/sort/SortByLength.d.ts /** * Returns true if A is longer than B. * We compare by stripping one char at a time. */ type IsLonger = A extends `${string}${infer ARest}` ? B extends `${string}${infer BRest}` ? IsLonger : true : false; /** Find the longest string in a readonly tuple */ type Longest = T extends readonly [infer H extends string, ...infer R extends readonly string[]] ? Longest extends true ? H : Curr> : Curr; /** * Remove the first occurrence of V from a readonly tuple */ type RemoveFirst = T extends readonly [infer H, ...infer R] ? H extends V ? [...Acc, ...R] : RemoveFirst : Acc; type Sort = T["length"] extends 0 ? Acc : Longest extends infer L extends string ? Sort, [...Acc, L]> : never; /** * **SortByLength**`` * * Sorts the elements from longest to shortest. * * - use `Reverse` utility if you want the opposite. */ type SortByLength = Sort; //#endregion //#region ../types/src/lists/SortByKey.d.ts /** * default options for sorting */ interface SortByKeyOptions { /** Object Key's that should be pinned to the start of the array */ start?: T | readonly T[]; /** Object keys's that should be pinned to the end of the array */ end?: T | readonly T[]; order?: SortOrder; } type ToArray = T extends readonly unknown[] ? T : readonly [T]; type SortByKey = TList extends readonly any[] ? Mutable<_SortByKey> : TList; type _SortByKey = _Reorder : readonly [], TConfig["end"] extends any ? ToArray : readonly []>; type _Reorder = readonly [..._GetStartElements, ..._GetMiddleElements, ..._GetEndElements]; type _GetStartElements = TStart extends readonly [infer First, ...infer Rest] ? [..._FilterByValue, ..._GetStartElements] : []; type _GetEndElements = TEnd extends readonly [infer First, ...infer Rest] ? [..._FilterByValue, ..._GetEndElements] : []; type _GetMiddleElements = _FilterByValues; type _FilterByValue = TList extends readonly [infer First, ...infer Rest extends object[]] ? First extends object ? TKey extends keyof First ? First[TKey] extends TValue ? readonly [First, ..._FilterByValue] : _FilterByValue : _FilterByValue : _FilterByValue : []; type _FilterByValues = TList extends readonly [infer First, ...infer Rest extends object[]] ? First extends object ? TKey extends keyof First ? First[TKey] extends TValues[number] ? _FilterByValues : [First, ..._FilterByValues] : [First, ..._FilterByValues] : [First, ..._FilterByValues] : []; //#endregion //#region ../types/src/lists/TakeFirst.d.ts type Take$8 = TDepth["length"] extends TLen ? TResult : number extends TLen ? TContent : TDepth["length"] extends 64 ? TResult : [] extends TContent ? TResult : TContent extends readonly [infer Head, ...infer Tail] ? Take$8 : TResult; type CountOptionalInFirstN = number extends N ? number : GetRequiredElementCount extends infer Req extends number ? GetOptionalElementCount extends infer Opt extends number ? Subtract extends infer Delta extends number ? IsLessThan extends true ? 0 : Min$1<[Opt, Delta]> : 0 : 0 : 0; /** * **TakeFirst**`` * * Takes the first `TLen` items from `TContent` and discards the rest. * * **Note:** * - if `TLen` is larger then the number of elements left in * `TContent` then only the remaining elements will be returned. */ type TakeFirst> = HasOptionalElements extends true ? AllOptionalElements extends true ? Partial> : number extends TLen ? TContent : Take$8 extends infer FirstN extends readonly unknown[] ? CountOptionalInFirstN extends infer Optional extends number ? MakeOptional : never : never : Take$8; //#endregion //#region ../types/src/lists/TakeLast.d.ts /** * **TakeLast**`` * * Takes the last `TLen` items from `TContent` and discards the rest. * * Note: * - by default if `TLen` is larger than the size of `TContent` this * is fine and instead of getting precisely `TLen` elements you'll get */ type TakeLast> = HasOptionalElements extends true ? MakeOptional, TLen>> extends readonly unknown[] ? Reverse, TLen>> : [], As$1, TLen]>, number>> : Reverse, TLen>>; //#endregion //#region ../types/src/lists/Variadic.d.ts /** Does T have at least one fixed (non-variadic) element? */ type HasFixedHead = Exclude extends never ? false : true; /** * **SplitAtVariadic**`` * * Split T into: * - Prefix: whatever remains after removing the maximal fixed suffix * - Suffix: the maximal fixed suffix (elements guaranteed to be present at the end) * * For example: * - SplitAtVariadic<[...string[], 1, 2]> -> [[...string[]], [1, 2]] * - SplitAtVariadic<[1, ...string[], 2]> -> [[1, ...string[]], [2]] * - SplitAtVariadic<[1, 2]> -> [[], [1, 2]] * - SplitAtVariadic -> [string[], []] */ type SplitAtVariadic = Depth["length"] extends 30 ? [T, Acc] : T extends readonly [...infer P, infer L] ? SplitAtVariadic : [T, Acc]; /** * **HasVariadicTail**`` * * Boolean operator which tests whether the tuple `T` concludes with * a _variadic_ type. * * - **Note**: while all wide type arrays like `number[]` or even `[...number[]]` ( * which coincidentally are the same type) are by nature _variadic_. This utility, * however, will return `false` for wide types so we can isolate only literal types * that have variadic tails. * * **Related:** * - `HasVariadicHead`, `HasVariadicInterior`, `IsVariadicArray` * - `VariadicType`, `GetNonVariadicLength` */ type HasVariadicTail = [IsAny] extends [true] ? false : [IsNever] extends [true] ? false : IsVariadicArray extends true ? HasFixedHead extends true ? SplitAtVariadic extends [...any[], []] ? true : false : false : false; /** * **HasVariadicHead**`` * * Tests whether if `T` starts with a variadic type with a fixed * type at the end. * * - **Note**: while all wide type arrays like `number[]` or even `[...number[]]` ( * which coincidentally are the same type) are by nature _variadic_. This utility, * however, will return `false` for wide types so we can isolate only literal types * that have variadic tails. * * **Related:** * - `HasVariadicTail`, `HasVariadicInterior`, `IsVariadicArray` * - `VariadicType`, `GetNonVariadicLength` */ type HasVariadicHead = [IsAny] extends [true] ? false : [IsNever] extends [true] ? false : IsVariadicArray extends true ? HasFixedHead extends true ? false : SplitAtVariadic extends [...unknown[], []] ? false : true : false; /** * **HasVariadicInterior**`` * * tests whether `T` has a _variadic_ element in the _interior_ of * the array. * * **Related:** `HasVariadicHead`, `HasVariadicTail`, `IsVariadicArray` */ type HasVariadicInterior = [IsAny] extends [true] ? false : [IsNever] extends [true] ? false : IsVariadicArray extends true ? Not, HasVariadicTail]>> extends true ? SplitAtVariadic extends [...unknown[], []] ? false : true : false : false; /** * **AllOptionalElements** * * Boolean operator which detects whether `T`'s elements are ALL designed as optional (e.g., marked with the * `?` modifier). * * **Related:** `HasOptionalElements` */ type AllOptionalElements = IsEqual, T>; /** * **GetNonVariadicLength**`` * * Determines the length of the tuple when the variadic tail has been stripped off. * * - if `T` is not variadic then this will simply report the length of the tuple` * - _optional_ elements (e.g., marked with the `?` modifier) are always included in the length */ type GetNonVariadicLength = Depth["length"] extends 25 ? F["length"] : [] extends Required ? F["length"] : Required> extends [infer Explicit, ...infer REST] ? GetNonVariadicLength : F["length"]; /** * **NonVariadicRequired**`` * * Get's the elements which have a fixed value (aka, are not * _variadic_) as well as are "required" (aka, no `?` modifier used) */ type NonVariadicRequired = Depth["length"] extends 25 ? F["length"] : [] extends T ? F["length"] : Mutable extends [infer Explicit, ...infer REST] ? NonVariadicRequired : F["length"]; /** * **GetRequiredElementCount**`` * * counts only the **required** elements of `T` * * **Related:** `GetOptionalElementCount`, `TupleMeta` */ type GetRequiredElementCount = NonVariadicRequired; /** * **GetOptionalElementCount**`` * * counts only the **optional** elements of `T` (e.g., those with the `?` modifier). * * **Related:** `GetRequiredElementCount`, `TupleMeta`, `MakeOptional` */ type GetOptionalElementCount = T extends readonly unknown[] ? T["length"] extends number ? GetNonVariadicLength extends infer NonVarLen extends number ? GetRequiredElementCount extends infer ReqLen extends number ? Subtract : 0 : 0 : 0 : never; /** * **DropVariadicTail**`` * * Removes the variadic tail found on the tuple `T`. * * - if no variadic tuple is found on `T` then it is just passed through * as is * * ```ts * // [ string, number? ] * type Test = ExcludeVariadicTail<[string, number?, ...string[]]>; * ``` */ type DropVariadicTail = HasVariadicTail extends true ? GetNonVariadicLength extends infer Len extends number ? SliceArray : T : T; /** * **IsVariadicArray**`` * * Boolean operator which determines if this tuple/array is variadic. * * - unlike some other utilities, this does not distinguish between * variadic arrays with fixed type elements versus **wide** array types; * both will return `true` */ type IsVariadicArray = number extends T["length"] ? true : false; /** * **DropVariadicHead**`` * * Removes the variadic head found on the tuple `T`. * * - if no variadic head is found on `T` then it is just passed through * * ```ts * // [ string, number? ] * type Test = ExcludeVariadicHead<[...string[], string, number?]>; * ``` */ type DropVariadicHead = SplitAtVariadic extends [infer Prefix extends readonly unknown[], infer Suffix extends readonly unknown[]] ? IsVariadicArray extends true ? HasFixedHead extends false ? Suffix : T : T : never; /** * **DropVariadic**`` * * Drops any variadic element found in `T` while retaining all the fixed length * elements. * * - if `T` has no variadic elements then it will be returned "as is" * * ```ts * // [1,2,3] * type Test = DropVariadic<[1,2,3, ...string[]]>; * ``` * * **Related:** `DropVariadicHead`, `DropVariadicTail`, `IsVariadicArray` */ type DropVariadic = IsVariadicArray extends false ? T : HasVariadicHead extends true ? DropVariadicHead : HasVariadicTail extends true ? DropVariadicTail : HasVariadicInterior extends true ? SplitAtVariadic extends [...infer Head, ...infer Tail] ? IsVariadicArray extends true ? Tail extends readonly unknown[] ? Tail : never : IsVariadicArray extends true ? Head extends readonly unknown[] ? Head : never : T : T : T; /** * **VariadicType**`` * * Returns the element type of a tuple's variadic tail. * * - Returns `never` if the tuple has no variadic tail * - For tuples with variadic tails like `[1, 2, ...number[]]`, returns the element type (`number`) * - Empty tuples and tuples with only optional elements return `never` * - Wide array types like `string[]`, or `number[]` -- _which are innately variadic types_ -- will correctly * report their variadic type as `string`, `number`, etc. * * **Related:** `GetNonVariadicLength`, `NonVariadic`, `VariadicType` */ type VariadicType = IsVariadicArray extends true ? HasVariadicHead extends true ? DropVariadicHead extends infer DroppedHead extends readonly unknown[] ? R extends readonly [...infer Head, ...DroppedHead] ? Head : never : never : HasVariadicTail extends true ? DropVariadicTail extends infer DroppedTail extends readonly unknown[] ? R extends readonly [...DroppedTail, ...infer Tail] ? Tail : never : never : never : never; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsEmptyArray.d.ts /** * Boolean operator which tests `T` for whether it is an array * with zero elements. * * - if `T` is a wide array it will return `boolean` */ type IsEmptyArray = T extends any[] ? number extends T["length"] ? GetNonVariadicLength extends 0 ? boolean : false : T["length"] extends 0 ? true : false : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsEmptyObject.d.ts /** * **IsEmptyObject**`` * * - T must be an object (but not a function and not an array/tuple) * - T must expose **no known keys** (`keyof T` is `never`) * - `any`, `unknown`, and `never` are rejected */ type IsEmptyObject = IsAny extends true ? false : IsNever extends true ? false : IsNull extends true ? false : IsUndefined extends true ? false : T extends AnyFunction ? false : IsObject extends true ? ObjectKeys extends readonly PropertyKey[] ? TupleMeta>["isEmpty"] : false : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsNonEmptyObject.d.ts /** * **IsNonEmptyObject**`` * * Boolean type util which detects whether `T` _is_ an object * and _has at least one property_. * * **Note:** this will report **false** for`ExplicitlyEmptyObject` but * not `EmptyObject` * * **Related:** `IsEmptyObject` */ type IsNonEmptyObject = T extends AnyObject ? IsEqual extends true ? false : Keys$1>["length"] extends 0 ? false : IsNumericLiteral>["length"]> extends true ? true : false : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsObject.d.ts /** * **IsObject**`` * * Boolean operator which tests whether `T` extends `object` in a non-nullable fashion. */ type IsObject = [IsAny] extends [true] ? false : [IsNever] extends [true] ? false : [IsNull] extends [true] ? false : [IsUndefined] extends [true] ? false : T extends object ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsReadonlyArray.d.ts /** * **IsReadonlyArray**`` * * Boolean type utility which detects whether `T` is a readonly array. */ type IsReadonlyArray = T extends unknown[] ? false : T extends readonly unknown[] ? true : false; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsSameContainerType.d.ts /** * test that `A` and `B` are both a Dictionary object or both are an array */ type IsSameContainerType = Or<[And<[IsDictionary, IsDictionary]>, And<[IsArray, IsArray]>]>; //#endregion //#region ../types/src/boolean-logic/operators/containers/IsValidIndex.d.ts type HasPositiveIndex = TDepth["length"] extends TKey ? TContainer extends readonly [unknown, ...readonly unknown[]] ? true : false : TContainer extends readonly [unknown, ...infer Rest] ? HasPositiveIndex : false; type HasNegativeIndex = TDepth["length"] extends TKey ? TContainer extends readonly [unknown, ...readonly unknown[]] ? true : false : TContainer extends readonly [unknown, ...infer Rest] ? HasNegativeIndex : false; type PositiveIndexOf = `${T}` extends `-${infer N extends number}` ? N : never; /** * **IsValidIndex**`` * * Provides a boolean check on whether `TKey` is a valid key for `TContainer`. * * - valid responses are `true` or `false` if literal types found; otherwise `boolean` * - negative indexes are allowed when `TContainer` is a tuple */ type IsValidIndex = TContainer extends Tuple$1 ? IsTuple extends true ? TKey extends number ? number extends TKey ? boolean : `${TKey}` extends `-${string}` ? PositiveIndexOf extends infer Positive extends number ? Positive extends 0 ? false : HasNegativeIndex : false : HasPositiveIndex : false : boolean : TContainer extends Dictionary ? IsEqual extends true ? false : [IsLiteralLikeObject] extends [true] ? [IsStringLiteral$1] extends [true] ? [TKey] extends [keyof TContainer] ? true : false : [TKey] extends [symbol] ? [TKey] extends [keyof TContainer] ? true : false : false : boolean : false; //#endregion //#region ../types/src/boolean-logic/operators/datetime/IsAfter.d.ts type IsSameDateDifferentPrecision$1 = A extends `${infer DatePart}T00:00:00Z` ? B extends DatePart ? true : false : B extends `${infer DatePart}T00:00:00Z` ? A extends DatePart ? true : false : false; type IsCharGreater$1 = A extends "0" ? false : A extends "1" ? B extends "0" ? true : false : A extends "2" ? B extends "0" | "1" ? true : false : A extends "3" ? B extends "0" | "1" | "2" ? true : false : A extends "4" ? B extends "0" | "1" | "2" | "3" ? true : false : A extends "5" ? B extends "0" | "1" | "2" | "3" | "4" ? true : false : A extends "6" ? B extends "0" | "1" | "2" | "3" | "4" | "5" ? true : false : A extends "7" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" ? true : false : A extends "8" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" ? true : false : A extends "9" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" ? true : false : A extends ":" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" ? true : false : A extends "T" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "-" | ":" ? true : false : A extends "Z" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "-" | ":" | "T" ? true : false : A extends "-" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" ? true : false : false; type LexicographicCompare$1 = A extends B ? false : IsSameDateDifferentPrecision$1 extends true ? false : [A] extends [never] ? false : [B] extends [never] ? false : [A, B] extends [string, string] ? A extends `${infer AFirst}${infer ARest}` ? B extends `${infer BFirst}${infer BRest}` ? AFirst extends BFirst ? LexicographicCompare$1 : IsCharGreater$1 : true : false : false; /** * **IsAfter**`` * * Tests whether `A` is _after_ (in time) `B`. * * Preserves literal types by using string comparison for ISO date strings. * For wide types or complex dates, it returns boolean. */ type IsAfter = A extends object ? boolean : B extends object ? boolean : string extends A ? boolean : string extends B ? boolean : number extends A ? boolean : number extends B ? boolean : A extends number ? B extends number ? IsGreaterThan : boolean : A extends string ? B extends string ? LexicographicCompare$1 : boolean : boolean; //#endregion //#region ../types/src/interpolation/ApplyTemplate.d.ts type ToBaseType = { [K in keyof T]: T[K] extends NumberLike ? AsNumber : T[K] extends BooleanLike ? AsBoolean : T[K] }; type Finalize$2 = TOnlyStringLit extends true ? [TContent, ...TApplied] : [TContent, ...ToBaseType]; type Apply$1 = [] extends TStatic ? TResults : TStatic extends readonly [infer Head extends string, infer Next extends string, ...infer Rest extends string[]] ? Apply$1, Next>]> : TStatic extends readonly [infer Head extends string] ? [...TResults, RetainAfter] : TResults; /** * **ApplyTemplate**`` * * If the content found in `TContent` is a match for `TTemplate`, then * the type returned will be the dynamic segments defined in the template. * * Alternatively, if `TContent` _does not_ match the dynamic segments * defined in `TTemplate` then a **invalid-content** error will be returned. * * Returns a tuple of the format: * * - [ full, p1, p2, p3, ... ] */ type ApplyTemplate = IsStringLiteral$1 extends true ? FromLiteralTemplate extends infer Template extends string ? Finalize$2>, TOnlyStringLit> : never : string; //#endregion //#region ../types/src/interpolation/AsLiteralTemplate.d.ts type Convert$8> = TKeys extends [infer Head extends string & keyof TSegments, ...infer Rest extends readonly string[]] ? [FromInputToken__String>] extends [string | number | boolean] ? Convert$8>}`>, TSegments, Rest> : TContent extends `{{${Head}}}` ? FromInputToken__String> : Err<`invalid-type/template`, `The segment '{{${Head}}}' was configured as a type which can not be embedded inside of a string literal!`, { segment: Head; invalidType: FromInputToken__String>; content: TContent; }> : TContent; /** * **AsLiteralTemplate**`` * * Converts Static Template sections to a Literal Template */ type AsLiteralTemplate = TContent extends number ? `${TContent}` : TContent extends string ? TContent extends `{{${infer Inner extends string}}}` ? Inner extends keyof TSegments ? FromInputToken__String> : Convert$8 : Convert$8 : never; //#endregion //#region ../types/src/interpolation/AsStaticTemplate.d.ts type NoBooleanConversion = Err<`invalid-string/boolean-literal`, `An attempt was made to convert a string from a "literal template" to a "static template" but the use of ${boolean} converts to a union type and quickly becomes unmanageable. Use the static {{boolean}} form instead.`, { template: T; }>; type RestoreVocabularyPlaceholders = TContent extends `${infer Before}${"$"}{${infer Name}}${infer After}` ? Name extends Extract ? RestoreVocabularyPlaceholders<`${Before}{{${Name}}}${After}`, TSegments> : `${Before}${"$"}{${Name}}${RestoreVocabularyPlaceholders}` : TContent; type HasVocabularyPlaceholder = TContent extends `${string}${"$"}{${string}}${string}` ? true : false; /** * **FromLiteralTemplate**`` * * Converts a string literal type into a Static Template where: * * - `${string}` is `{{string}}` * - `${number}` is `{{number}}` * - the `${boolean}` literal will produce a union and is too expensive to try and * capture so instead we'll return an error. * * This type utility is the _inverse_ of `StringLiteralTemplate`. */ type FromLiteralTemplate = string extends T ? string | Error : IsUnion extends true ? NoBooleanConversion : ReplaceStringInterpolation, "{{string}}">; type Convert$7> extends readonly string[] ? UnionToTuple> : [])> = TKeys extends [infer Head extends string, ...infer Rest extends readonly string[]] ? Convert$7, TSegments, Rest> : TContent; /** * **AsStaticTemplate**`` * * Converts a string literal type into a Static Template where: * * - `${string}` is `{{string}}` * - `${number}` is `{{number}}` * - the `${boolean}` literal will produce a union and is too expensive to try and * capture so instead we'll throw an error. * * In addition you can optionally add a **template map** which will allow for additional * vocabulary to be used. There are a few pre-configured maps: * * - `TemplateMap__Basics` - this is the default of strings, numbers, and booleans * - `TemplateMap__Generics` - an easy way to allow for generic params to included */ type AsStaticTemplate = As$1 extends true ? HasVocabularyPlaceholder extends true ? RestoreVocabularyPlaceholders : Convert$7, string>, TSegments> : Convert$7, string>, TSegments>, string>; //#endregion //#region ../types/src/dictionary/Get.d.ts type _Get = K extends `${infer A}.${infer B}` ? A extends keyof T ? _Get> : Acc : K extends keyof T ? _Get : Acc; /** * **Get**`` * * Provides a type utility which allows reaching into * a container using a _dot path_ to get the type * somewhere inside the parent structure. */ type Get$2 = IsNever<_Get> extends true ? TDefVal : _Get extends undefined ? TDefVal : _Get; //#endregion //#region ../types/src/dictionary/GetFixedKeys.d.ts /** * **GetFixedKeys**`` * * Returns a union type for all _fixed_ keys found in `T` (aka, not indexed keys). * * **Related:** `GetIndexKeys`, `OnlyFixedKeys`, `RemoveIndexKeys` */ type GetFixedKeys = IsEqual extends true ? ObjectKey[] : T extends Dictionary ? keyof RemoveIndexKeys : never; //#endregion //#region ../types/src/dictionary/GetIndexKeys.d.ts /** * **GetIndexKeys`` * * Returns a union type of all the _index_ types found in `T`. * * - an index can be wide-type indexes such as `{ [x: string]: string }` * _or_ `{ [x: symbol]: number }` * - but they can also be _template literal_ indexes like `{ [x: `_${string}`]: string }` * * **Related:** `OnlyIndexKeys` */ type GetIndexKeys = keyof OnlyIndexKeys & (string | symbol); //#endregion //#region ../types/src/dictionary/KeysWithError.d.ts type Process$37, readonly ObjectKey[]>, R extends readonly ObjectKey[] = []> = [] extends K ? R : First$1 extends keyof T ? T[First$1] extends Error ? Process$37, [...R, First$1]> : Process$37, R> : never; /** * **KeysWithError**`` * * Returns all of the keys in a dictionary `T` which _extend_ `Error`. */ type KeysWithError = Process$37; //#endregion //#region ../types/src/dictionary/KeysWithoutValue.d.ts /** * **KeysWithoutValue**`` * * The _keys_ on a given object `T` which _do not_ extend the type value of `W`. * * ```ts * // "foo" * type T = KeysWithoutValue<{ foo: "hi"; bar: 5; baz: number }, number>; * ``` */ type KeysWithoutValue = { [K in keyof TObj]: TObj[K] extends TValue ? never : Readonly }[keyof TObj]; //#endregion //#region ../types/src/dictionary/MakeKeysOptional.d.ts type Iterate$5 = ExpandRecursively & { [K in keyof WithKeys]?: K extends keyof TObj ? TObj[K] : never }>; type ConvertArray = IsGreaterThanOrEqual extends true ? Partial : Subtract extends infer ReqNum extends number ? Negative extends infer OptNum extends number ? [Slice, Slice] extends [infer ReqElements extends readonly unknown[], infer OptElements extends readonly unknown[]] ? [...ReqElements, ...Partial] : never : never : never; /** * **MakeKeysOptional**`` * * Makes a set of keys on a known container `T`: * * - if `T` is a **dictionary** object then `U` should: * - be a tuple of keys which you want to force * to _optional_. * - all other keys will be kept "as is" * - if `T` is an **array** then `U` should be: * - in a tuple, only the _last_ items are allowed to be optional * - therefore `U` is a number indicating _how many_ values should be optional * * **Related:** `MakeKeysRequired` */ type MakeKeysOptional = T extends Dictionary ? Iterate$5> : T extends readonly unknown[] ? ConvertArray, As$1> : never; //#endregion //#region ../types/src/dictionary/MixObjects.d.ts type Mix, readonly (PropertyKey & keyof B)[]>> = K extends [infer Head extends keyof B & PropertyKey, ...infer Rest extends readonly (keyof B & PropertyKey)[]] ? Head extends keyof A ? Mix & Record, B, Rest> : Mix, B, Rest> : ExpandDictionary; /** * **MixObjects**`` * * Combines two objects by unionizing the values of shared keys * and adding keys in `B` to `A` which didn't exist. */ type MixObjects = Mix; //#endregion //#region ../types/src/dictionary/ObjectKeys.d.ts type Shaped = [] extends TKeys ? [...L, ...Partial, ...Partial] : IsTemplateLiteral> extends true ? First$1 & string extends infer Pattern extends string ? Shaped, TOpt, L, O, [...V, ...Pattern[]]> : never : Contains> extends true ? Shaped, TOpt, L, [...O, First$1], V> : Shaped, TOpt, [...L, First$1], O, V>; type HandleDict = Required extends Record ? IsNever extends true ? TObj extends Dictionary ? [] : PropertyKey[] : IsEqual extends true ? ObjectKey[] : IsEqual extends true ? string[] : IsEqual extends true ? symbol[] : IsEqual extends true ? number[] : IsNever extends true ? PropertyKey[] : IsNever> extends true ? IsLiteralString extends true ? Shaped, readonly PropertyKey[]>, OptionalKeysTuple> : IsUnion extends true ? Shaped, readonly PropertyKey[]>, OptionalKeysTuple> : K[] : [...UnionToTuple>, ...(GetIndexKeys)[]] : never; /** * **ObjectKeys**`` * * Provides the keys of a given object in a tuple form. * * **Related:** `Keys`, `OptionalKeys`, `RequiredKeys`, `NumericKeys` */ type ObjectKeys = [IsAny] extends [true] ? Err<`invalid-type/object-keys`, `Call to ObjectKeys where T was 'any'!`> : IsNever extends true ? Err<`invalid-type/object-keys`, `Call to ObjectKeys where T was 'never'!`> : TObj extends object ? TObj extends Map ? IsUnion extends true ? IsLiteralUnion extends true ? Required, readonly PropertyKey[]>, OptionalKeysTuple>> : IsWideUnion extends true ? UnionToTuple[] : "mixed" : K[] : TObj extends Set ? Err<`invalid-type/object-keys`, `The type passed into ObjectKeys was a Set. Set's do not have keys`> : TObj extends WeakMap ? IsUnion extends true ? K : K extends Scalar | object | readonly unknown[] ? K[] : unknown : Required extends Record ? IsNever extends true ? TObj extends Dictionary ? [] : PropertyKey[] : IsEqual extends true ? ObjectKey[] : IsEqual extends true ? RemoveIndexKeys> extends Record ? [...(As$1>>, readonly PropertyKey[]>), ...string[]] : PropertyKey[] : IsNever extends true ? PropertyKey[] : TObj extends Dictionary ? HandleDict : K[] : ObjectKey[] : Err<`invalid-type/object-keys`, `The type passed into ObjectKeys was not an object!`, { value: TObj; }>; //#endregion //#region ../types/src/dictionary/OnlyIndexKeys.d.ts type ExtractIndexKeysFromObj = { [K in keyof T as string extends K ? K : number extends K ? K : symbol extends K ? K : never]: T[K] }; type GetTemplateLiteralIndexes = TKeys extends [infer Head extends ObjectKey, ...infer Rest extends readonly ObjectKey[]] ? IsTemplateLiteral extends true ? GetTemplateLiteralIndexes> : GetTemplateLiteralIndexes : ExpandDictionary; /** * **OnlyIndexKeys**<`T`> * * Returns a dictionary with all fixed keys removed and only _index_ * signatures remaining. * * - index can be wide-type indexes such as `{ [x: string]: string }` * - but they can also be _template literal_ indexes like `{ [x: `_${string}`]: string }` * * **Related: `GetIndexKeys` */ type OnlyIndexKeys = ExpandDictionary & GetTemplateLiteralIndexes>>; //#endregion //#region ../types/src/dictionary/OptionalKeys.d.ts /** * **OptionalKeys**`` * * Provides a union type of the _keys_ in `T` which are * **optional** properties. * * **Note:** you also may optionally filter further by specifying a value * by the _value_ of the key and then only keys which are required AND * who extend `V` will be included in the union. * * **Related:** `OptionalKeys`, `RequiredProps` * Provides a union type of the _keys_ in `T` which are * **required** properties. * * **Note:** you also may optionally filter further by specifying a value * by the _value_ of the key and then only keys which are required AND * who extend `V` will be included in the union. * * **Related:** `RequiredKeys`, `RequiredProps` */ type OptionalKeys = T extends Dictionary ? { [K in keyof T]-?: EmptyObject extends { [P in K]: T[K] } ? If, K, K extends V ? K : never> : never }[keyof T] : never; /** * **OptionalKeysTuple**`` * * Provides a tuple of the _keys_ in `T` which are * **optional** properties. * * **Related:** `RequiredKeys`, `OptionalProps` */ type OptionalKeysTuple = T extends Dictionary ? As$1>, "equals", [boolean]>, readonly ObjectKey[]> : never; //#endregion //#region ../types/src/dictionary/OptRecord.d.ts /** * **OptRecord**`` * * Create a Record with the optional property set. */ type OptRecord = MakeKeysOptional, [T]>; //#endregion //#region ../types/src/dictionary/RemoveIndexKeys.d.ts type Arr$1 = { [K in keyof T as number extends K ? never : string extends K ? never : symbol extends K ? never : K]: T[K] }; type FilterDictKeys = { [K in keyof T as string extends K ? never : number extends K ? never : symbol extends K ? never : IsTemplateLiteral extends true ? never : K]: T[K] }; /** * **RemoveIndexKeys**`` * * Removes _index_ keys which permit key/values to be added to an object while * retaining all explicit key/values defined on an object. * * - this includes both _wide_ indexes like `string` but also literal template * indexes like `_${string}` * * ```ts * type Obj = { [key: string]: unknown; foo: 42 }; * // { foo: 42 } * type Obj2 = RemoveIndexKeys; * ``` */ type RemoveIndexKeys = T extends Dictionary ? HasIndexKeys extends true ? Required>> extends infer Keys extends readonly PropertyKey[] ? WithKeys : never : T : T extends readonly any[] ? Arr$1 : never; //#endregion //#region ../types/src/dictionary/RequiredKeys.d.ts /** * **RequiredKeys**`` * * Provides a union type of the _keys_ in `T` which are * **required** properties. * * **Note:** you also may optionally filter further by specifying a value * by the _value_ of the key and then only keys which are required AND * who extend `V` will be included in the union. * * **Related:** `OptionalKeys`, `RequiredProps`, `RequiredKeysTuple` */ type RequiredKeys = As$1<{ [K in keyof T]-?: EmptyObject extends { [P in K]: T[K] } ? never : IfUnset }[keyof T], ObjectKey>; //#endregion //#region ../types/src/dictionary/ReverseLookup.d.ts /** * **ReverseLookup**`` * * Inverts a table of string to string lookups so that the values * can now lookup the keys. * * Uses mapped types for O(1) complexity instead of recursive processing, * significantly improving performance for large mappings while preserving * narrow literal types. */ type ReverseLookup> = { [K in keyof T as T[K]]: K }; //#endregion //#region ../types/src/dictionary/SharedKeys.d.ts /** * **SharedKeys**`` * * Given two objects `A` and `B`, this type utility will provide the * _keys_ which both objects contain. * ```ts * type O1 = { foo: 1; bar: 2; baz: 88 }; * type O2 = { bar: 5; baz: 3; nada: true }; * // ["bar", "baz"] * type X = SharedKeys; * ``` * * **Note:** this is now just an alias to `IntersectingKeys` */ type SharedKeys | object, B extends Record | object> = IntersectingKeys, As$1>; //#endregion //#region ../types/src/dictionary/StringKeys.d.ts type _StringKeys = UnionToTuple<{ [K in keyof T]: K extends string ? Readonly : never }[keyof T]>; /** * **SKeys**`` * * Creates a tuple of all _string_ keys of `T`. * * **Related:** `Keys`, `StringKeys` * @deprecated prefer use of `StringKeys` */ /** * **StringKeys**`` * * Creates a tuple of all _string_ keys of `T`. * * **Related:** `Keys` */ type StringKeys = IsVueRef extends true ? ["value"] : _StringKeys extends readonly string[] ? _StringKeys : never; //#endregion //#region ../types/src/dictionary/Values.d.ts type Validate$7 = [IsAny] extends [true] ? Err<`invalid-type/values`, `Values was called where T was the 'any' type`> : [IsNever] extends [true] ? Err<`invalid-type/values`, `Values was called where T was the 'never' type`> : T; type GetValues = [] extends TKeys ? TAcc : Required extends readonly [infer First, ...infer Rest] ? First extends keyof TObj ? Rest extends readonly PropertyKey[] ? IsTuple extends true ? UnionMemberEquals extends true ? GetValues : GetValues : GetValues : never : never : TAcc; /** * **Values**`` * * Produces a tuple of all the _values_ in an object. * * - you _can_ run it on a tuple too but this is in effect an identity * function and will just return the tuple's values/types "as is" * - passing in `any` or `never` to this utility will result in an Error */ type Values = As$1 extends Error ? Validate$7 : T extends readonly unknown[] ? T : Keys$1 extends readonly unknown[] ? number extends Keys$1["length"] ? T extends Record ? V[] : T extends readonly (infer V)[] ? V[] : unknown[] : GetValues> extends infer V extends readonly unknown[] ? OptionalKeysTuple["length"] extends infer OptNum extends number ? OptNum extends 0 ? GetValues> : MakeKeysOptional : GetValues> : never : never, readonly unknown[]>; //#endregion //#region ../types/src/dictionary/WithKeys.d.ts type MakeIntoUnion = K extends readonly PropertyKey[] ? TupleToUnion : K; type MakeNumericIndex = T; /** * **WithKeys**`` * * This type utility will ensure that the type `T` will _retain_ the key/value * pairs which extend `K`. * * It is very similar to **Pick** but rather `K` being restricted to * being a string union, wth **WithKeys** you can use the union type * or a readonly array of strings. * * ```ts * type Test = { foo: 1, bar: number, baz: string }; * // { foo: 1, bar: number } * type T1 = WithKeys; // Pick syntax * type T2 = WithKeys; * ``` */ type WithKeys = ExpandRecursively extends keyof T ? T extends Tuple$1 ? MakeNumericIndex>> : Pick> : never>>; //#endregion //#region ../types/src/dictionary/WithoutKeys.d.ts /** * **WithoutKeys**`` * * Removes the keys in `TKeys` from an object `TObj`. * * **Note:** This is functionally equivalent to the `Omit` built-in but: * * - allows passing in a union type (like Omit) * - or a tuple of ObjectKey's (distinct from Omit). */ type WithoutKeys = TKeys extends readonly ObjectKey[] ? Omit : TKeys extends ObjectKey ? ExpandDictionary> : never; //#endregion //#region ../types/src/dictionary/WithoutValue.d.ts /** * **WithoutValue** * * Reduces an object's type down to only those key/value pairs where the * value is **NOT** of type `W`. * * ```ts * const foo = { a: 1, b: "hi", c: () => "hello" } * // { a: 1, b: "hi" } * type W = WithValue * ``` * * You manually exclude keys as well by setting the optional `E` generic. */ type WithoutValue = Mutable>>>; //#endregion //#region ../types/src/dictionary/WithValue.d.ts type Marked$1 = typeof MARKED; type Process$36 = RemoveMarked<{ [K in keyof TObj]: If : Extends, TObj[K], Marked$1> }>; /** * **WithValue**`` * * Reduces an object's type down to only those key/value pairs where the * value is of type `W`. * ```ts * const foo = { a: 1, b: "hi", c: () => "hello" } * // { c: () => "hello" } * type W = WithValue * ``` * * **Related:** `WithoutValue`, `WithKeys`, `WithoutKeys` */ type WithValue = ExpandRecursively>; //#endregion //#region ../types/src/interpolation/IsStaticTemplate.d.ts type Curly, O extends string = never> = K extends [infer Head extends string, ...infer Rest extends readonly string[]] ? Curly : O; /** * **IsStaticTemplate**`` * * A boolean operator which indicates whether any of the dynamic segments * defined in `TSegments` was found in `TContent`. */ type IsStaticTemplate = Contains>; //#endregion //#region ../types/src/type-conversion/AsBoolean.d.ts /** * **AsBoolean**`` * * Converts any `BooleanLike` value to a boolean value * and return `never` otherwise. */ type AsBoolean = T extends boolean ? T : T extends "true" ? true : T extends "false" ? false : T extends "boolean" ? boolean : never; //#endregion //#region ../types/src/type-conversion/AsFromTo.d.ts /** converts an object's key values into FromTo tuple */ type ConvertFromTo = Values<{ [K in keyof TObj]: { from: K; to: TObj[K]; } }>; /** * **AsFromTo**`` * * Converts: * - an object KV is converted into a `FromTo[]` tuple * * **Notes:** * - any value which is already a FromTo will be kept as is * - any value which is _not_ a number will be converted to a `NumberLike` string and added * - any value which is neither a string or any of the above will be discarded */ type AsFromTo> = IsLiteralLikeObject extends true ? ConvertFromTo extends readonly FromTo[] ? ConvertFromTo : never : FromTo[]; //#endregion //#region ../types/src/type-conversion/AsNumber.d.ts /** * **ParseInt**`` * * Converts a known string literal representation of a number * to an actual number. */ type ParseInt = T extends `${infer Int}.${infer Dec}` ? StripChars extends "" ? Int extends `${infer N extends number}` ? N : never : `${Int}.${TrimCharEnd}` extends `${infer N extends number}` ? N : never : T extends `${infer N extends number}` ? N : never; type JustZeros = T extends `${infer HEAD extends string}${infer REST extends string}` ? HEAD extends "0" ? JustZeros : false : true; /** * Addresses the possibility of leading zeros for both integer values * and decimal values, positive and negative values */ type Handler = StartsWith extends true ? Contains extends true ? JustZeros> extends true ? As$1<`0.${RetainAfter}`, `${number}`> : As$1, `${number}`> : JustZeros extends true ? "0" : StripWhile : StartsWith extends true ? As$1<`0${T}`, `${number}`> : T; /** * **AsNumber**`` * * Returns a _number_ for `T` where `T` extends a _number_ or * `${number}` type; otherwise return _never_. Literal types are * preserved. * * ```ts * // 4 * type Num = AsNumber<"4">; * ``` * **Related:** `ToNumber` */ type AsNumber = IsBranded extends true ? AsNumber> : T extends number ? T : T extends `${number}` ? StartsWith extends true ? ParseInt<`-${Handler, `${number}`>>}`> : ParseInt> : never; //#endregion //#region ../types/src/type-conversion/AsPropertyKey.d.ts /** * **AsPropertyKey**`` * * Ensures that `T` is a property key or, if a tuple is passed in, that * all values extend `PropertyKey` */ type AsPropertyKey = T extends PropertyKey ? T : never; //#endregion //#region ../types/src/type-conversion/AsRecord.d.ts /** * **AsRecord**`` * * Receives a `Record`, `object`, or `Tuple` and ensures the type * is a `Record` type for all object-like types and just passes * Tuples through "as is". */ type AsRecord = T extends Tuple$1 ? T : T extends Dictionary ? T : T extends object ? T extends any[] ? never : NonNullable : never; //#endregion //#region ../types/src/type-conversion/AsString.d.ts type OnlyString = As$1, readonly string[]>; /** * **AsString** * * Attempts to convert `T` to a string type where possible. * * - will convert any string, boolean, or numeric value * to a string value * - `42` -> `"42"` * - number -> `${number}` * - true -> `"true"` * - union types who's elements include at least one element of * `string` | `number | `boolean` will be converted to an appropriate * string literal: * - `"foo" | 42 | true` will be converted to `"foo" | "42" | "true"` * - wide `string[]` arrays will be converted to `string` * - a tuple of values will be made into a JS string representing that type: * - `[string, number, "foo"]` -> `"[ string, number 'foo' ]""` * * **Related:** `ToString` */ type AsString = [string] extends [T] ? string : [T] extends [string] ? T : [IsUnion] extends [true] ? OnlyString>[number] : [T] extends [number] ? `${T}` : [T] extends [boolean] ? `${T}` : [T] extends [readonly (unknown)[]] ? IsWideArray extends true ? T extends (infer Type extends string | number | boolean)[] ? `${Type}` : never : ToJsonArray : [T] extends [object] ? [T] extends [Dictionary] ? ToJsonObject : never : never; //#endregion //#region ../types/src/type-conversion/AsStringUnion.d.ts type ConvertUnion$1 = TupleToUnion<{ [K in keyof T]: [T[K]] extends [string] ? T[K] : [T[K]] extends [number] ? `${T[K]}` : [T[K]] extends [boolean] ? `${T[K]}` : [THandle] extends ["drop"] ? never : T[K] }>; /** * **AsStringUnion**`` * * A type conversion utility which ensures unions (and a few literals) are * converted to string literal variants: * * - if `T` is a union type, all _numeric_ or _boolean_ elements in the union * will be converted to a string literal equivalent and others will be dropped * - if you would prefer non-convertible types are left as part of the union * you can set the `THandle` to "proxy" (instead of the default "drop") * * For non-union types, the goal is to address a similar outcome which is: * * - if `T` is of type `number` or `boolean` then this is converted to a * string literal equivalent * - all other types result in `never` or are just proxied through if * `THandle` is set to "proxy" */ type AsStringUnion = [IsUnion] extends [true] ? ConvertUnion$1, THandle> : [T] extends [string] ? T : [T] extends [number] ? `${T}` : [T] extends [boolean] ? `${T}` : [THandle] extends ["drop"] ? never : T; //#endregion //#region ../types/src/type-conversion/AsUnion.d.ts /** * **AsUnion**`` * * Converts any tuple into a union based on the tuples elements. Otherwise, * simply passes `T` through unchanged. */ type AsUnion = T extends readonly any[] ? T[number] : T; //#endregion //#region ../types/src/type-conversion/encoding/EncodingLookups.d.ts type SafeEncoding__Quotes = Mutable; type SafeEncoding__Whitespace = Mutable; type SafeEncoding__Brackets = Mutable; type SafeEncodingConversion = [] extends T ? R : SafeEncodingConversion, [...R, ...(First$1 extends "quotes" ? AsFromTo : First$1 extends "brackets" ? AsFromTo : First$1 extends "whitespace" ? AsFromTo : [])]>; type SafeDecodingConversion = [] extends T ? R : SafeDecodingConversion, [...R, ...(First$1 extends "quotes" ? AsFromTo> : First$1 extends "brackets" ? AsFromTo> : First$1 extends "whitespace" ? AsFromTo> : [])]>; //#endregion //#region ../types/src/type-conversion/encoding/SafeDecode.d.ts /** * **SafeDecode**`` * * Decodes an encoded `SafeString` back to a normal string. * Groups are: * * - "whitespace" * - "quotes" * - and "brackets" * * By default ALL are used. */ type SafeDecode = IsStringLiteral$1 extends true ? ReplaceAllFromTo> : string; //#endregion //#region ../types/src/type-conversion/encoding/SafeEncode.d.ts /** * **SafeEncode**`` * * Encodes string into a `SafeString` using some or all of the * "safe key" groups. Groups are: * * - "whitespace" * - "quotes" * - and "brackets" * * By default ALL are used. * * **Related:** `SafeEncodeEscaped` */ type SafeEncode = IsStringLiteral$1 extends true ? ReplaceAllFromTo> : SafeString; //#endregion //#region ../types/src/type-conversion/encoding/SafeEncodingGroup.d.ts type SafeEncodingGroup = "whitespace" | "brackets" | "quotes"; //#endregion //#region ../types/src/type-conversion/encoding/SafeString.d.ts /** * **SafeString** * * A string which was encoded using `safeEncode()` runtime utility or `SafeEncode` type * utility. It is a string which has had one of several "groups" of characters replaced * (aka., encoded) into a safe token value. * * - use `safeDecode()` or `SafeDecode` utilities to move back to the original string value. */ type SafeString = Brand; encoded: T; }>; //#endregion //#region ../types/src/type-conversion/encoding/StringEncoder.d.ts /** * **StringEncoder** * * A base type for _string encoders_ which take a string and convert * to anther type of string. */ type StringEncoder = (input: T) => R; //#endregion //#region ../types/src/type-conversion/form-fields.d.ts /** * **Email** * * A simple email address representation * * **Related:** `IsEmail`, `isEmail()` */ type Email = `${string}@${string}.${T}`; //#endregion //#region ../types/src/type-conversion/Immutable.d.ts type NeverOnSet = T extends `set${infer Name}` ? Name extends Capitalize ? never : T : T; /** * **Immutable**`` * * An alternative to `Readonly` but adds: * * - removes the types of all _setter_ methods in the values of `T` * - deeply sets container properties as read-only (rather than just top level properties) * * **Related:** `immutable()`, `freeze()`, `var Object.freeze()` */ type Immutable = Expand<{ readonly [K in keyof T as T[K] extends AnyFunction ? NeverOnSet : K]: T[K] extends object ? TDeep extends false ? T[K] : Immutable : T[K] }>; //#endregion //#region ../types/src/type-conversion/LeftWhitespace.d.ts /** * Provides the _left_ whitespace of a string * ```ts * // "\n\t " * type T = LeftWhitespace<"\n\t foobar">; * ``` */ type LeftWhitespace = string extends S ? string : Replace extends string ? TrimLeft : never, "">; //#endregion //#region ../types/src/type-conversion/Merge.d.ts /** * **MergeScalars**`` * * Provides a `Scalar` value by evaluating whether `TDefault` * and `TOverride` extends `TEmpty` (which is `null` | `undefined` * by default). * * Note: if both `TDefault` and `TOverride` are _undefined_ then the * exiting type will be _undefined_ (which isn't strictly a `Scalar` * value). */ type MergeScalars = TDefault extends TEmpty ? TOverride : TOverride extends TEmpty ? TDefault : TOverride; type MergeTuplesAcc = TOverride extends [infer Override, ...infer Rest extends unknown[]] ? If, MergeTuplesAcc, Rest, TKey, [...TResults, First$1]>, MergeTuplesAcc, Rest, TKey, [...TResults, Override]>> : readonly [...TResults, ...TDefault]; /** * **MergeTuples** * * Merges two tuple arrays by position in the tuple: * * - if `TOverride` is longer than `TDefault` then no defaults will be provided * - if `TDefault` is longer than `TOverride` then `TDefault` will be extended */ type MergeTuples = MergeTuplesAcc<[...TDefault], [...TOverride], TKey>; //#endregion //#region ../types/src/type-conversion/MergeObjects.d.ts /** * **MergeObjects**`` * * A type utility that _shallowly merges_ two object types. * * Properties in TOverride will override properties in TDef. * This implementation avoids excessive recursion when dealing with optional properties. */ type MergeObjects = ExpandDictionary & TOverride>; //#endregion //#region ../types/src/type-conversion/Mutable.d.ts type MutableObject = [T] extends [boolean] ? T : { -readonly [K in keyof T]: T[K] extends Dictionary ? Mutable> : IsTuple extends true ? Mutable : T[K] extends readonly (infer R)[] ? [...R[]] : Mutable }; type MutableArray = [...{ [K in keyof T]: Mutable }]; /** * **Mutable**`` * * Makes a readonly type -- either a dictionary or an array -- into a mutable value without * widening the type. */ type Mutable = [IsUnion] extends [true] ? T : [T] extends [infer Arr extends readonly unknown[]] ? MutableArray : [T] extends [infer Dict extends Dictionary] ? MutableObject : T; //#endregion //#region ../types/src/type-conversion/numeric/HexToDecimal.d.ts type H2D = Lowercase extends "f" ? 15 : Lowercase extends "e" ? 14 : Lowercase extends "d" ? 13 : Lowercase extends "c" ? 12 : Lowercase extends "b" ? 11 : Lowercase extends "a" ? 10 : Lowercase extends "9" ? 9 : Lowercase extends "8" ? 8 : Lowercase extends "7" ? 7 : Lowercase extends "6" ? 6 : Lowercase extends "5" ? 5 : Lowercase extends "4" ? 4 : Lowercase extends "3" ? 3 : Lowercase extends "2" ? 2 : Lowercase extends "1" ? 1 : 0; type HexByte = Lowercase extends "0" ? H2D : Lowercase extends "1" ? [16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31][H2D] : Lowercase extends "2" ? [32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47][H2D] : Lowercase extends "3" ? [48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63][H2D] : Lowercase extends "4" ? [64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79][H2D] : Lowercase extends "5" ? [80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95][H2D] : Lowercase extends "6" ? [96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111][H2D] : Lowercase extends "7" ? [112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127][H2D] : Lowercase extends "8" ? [128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143][H2D] : Lowercase extends "9" ? [144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159][H2D] : Lowercase extends "a" ? [160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175][H2D] : Lowercase extends "b" ? [176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191][H2D] : Lowercase extends "c" ? [192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207][H2D] : Lowercase extends "d" ? [208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223][H2D] : Lowercase extends "e" ? [224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239][H2D] : [240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 255][H2D]; type HexCharsToDecimal = T extends readonly [infer A extends HexadecimalChar, infer B extends HexadecimalChar, ...infer Rest extends readonly HexadecimalChar[]] ? TDepth["length"] extends 64 ? number[] : HexCharsToDecimal], [...TDepth, unknown]> : T extends readonly [infer A extends HexadecimalChar] ? [...V, H2D] : V; /** * **HexToDecimal**`` * * Iterates left-to-right, peeling off two hexadecimal digits at a time * until there are only 0 or 1 digits left (adds final digit if 1 is left). * What is left is an array of decimal numbers ranging from 0-255. * * ```ts * // [15] * type T1 = HexToDecimal<"f">; * // [255] * type T2 = HexToDecimal<"ff"> * // [255] * type T3 = HexToDecimal<"0xFF"> * // [255, 238, 9] * type T4 = HexToDecimal<"ffee09"> * ``` */ type HexToDecimal = T extends number ? number extends T ? number[] : [T] : T extends `0x${infer Rest}` ? HexToDecimal : T extends "" ? [0] : string extends T ? number[] | Err<"invalid-type/hexadecimal"> : IsHexadecimal extends true ? string extends T ? number | Error : Chars> extends readonly HexadecimalChar[] ? HexCharsToDecimal>> : never : Err<"invalid-type/hexadecimal">; //#endregion //#region ../types/src/type-conversion/RemoveIndex.d.ts /** * **RemoveIndex**`` * * Removes an index like below while retaining other key/value pairs. * ```ts * interface Foo { * foo: string; * [key: string]: any; * } * // { foo: string } * type T = RemoveIndex; * ``` * * @deprecated use `RemoveIndexKeys` instead * */ type RemoveIndex> = { [P in keyof T as string extends P ? never : number extends P ? never : symbol extends P ? never : P]: T[P] }; //#endregion //#region ../types/src/type-conversion/Replace.d.ts type Process$35 = TText extends "" ? If, TReplace, ""> : TFind extends "" ? TText : TText extends `${infer F}${TFind}${infer E}` ? `${F}${TReplace}${E}` : TText; /** * **Replace**`` * * Type utility which takes a string `TText` and finds the _first instance_ of * `TFind` and replaces it with `TReplace`. * * ```ts * type Fooy = "fooy"; * // "Foo" * type Foo = Replace; * ``` * * Alternatively you can pass in `TFind` as an array of `FromTo` objects to describe * multiple transformations at once. * * ```ts * type Fooy = "fooy"; * // "Pooey" * type Pooey = Replace; * ``` * * **Related:** `ReplaceAll`, `ReplaceToFrom`, `ReplaceAllToFrom` */ type Replace = IsStringLiteral$1 extends true ? As$1, string> : string; //#endregion //#region ../types/src/type-conversion/ReplaceAll.d.ts type ReplaceAllLiterals$1 = TText extends `${infer Head}${TFind}${infer Tail}` ? `${Head}${TReplace}${ReplaceAllLiterals$1}` : TText; type Iterate$4 = [] extends TFind ? TText : Iterate$4, TReplace>, AfterFirst, TReplace>; type Singular = IsStringLiteral$1 extends true ? IsStringLiteral$1 extends true ? IsUnion extends true ? UnionToTuple extends readonly string[] ? Iterate$4, TReplace> : never : ReplaceAllLiterals$1 : string : string; type EachTupleElement = { [K in keyof TText]: ReplaceAll }; /** * **ReplaceAll**`` * * Type utility which takes a string `TText` and finds _all_ instances of * `TFind` and replaces it with `TReplace`. * * ```ts * const fooy = "fooy, Joey"; * // "foo, Joe" * type Foo = ReplaceAll; * ``` * * **Related:** `Replace` * * - **Note:** this utility has been upgraded to take either a _string_ or a * _tuple_ of strings for `TText`. */ type ReplaceAll = TText extends readonly string[] ? IsLiteralLike extends true ? EachTupleElement : string[] : TText extends string ? Singular : never; //#endregion //#region ../types/src/type-conversion/ReplaceAllFromTo.d.ts type ReplaceAllFromToLiteral = Mappings extends readonly [infer First extends { from: string; to: string; }, ...infer Rest extends { from: string; to: string; }[]] ? ReplaceAllFromToLiteral, Rest> : S; type ReplaceAllLiterals = TText extends `${infer Head}${TFind}${infer Tail}` ? `${Head}${TReplace}${ReplaceAllLiterals}` : TText; type ApplyMapping = ReplaceAllLiterals; /** * **ReplaceAllFromTo**`` * * Replaces the _all instances_ of the `from` element of `TFromTo` found in * `TText` with the corresponding `to` value in `TFromTo`. * * ```ts * // "Foo-bar-baz" * type Dashing = Replace<"Foo Bar Baz", [ * { from: " "; to: "-" }, * { from: "B"; to: "b" } * ]>; * ``` * **Related:** `Replace`, `ReplaceAll` * * **Notes:** * - does allow TText to be passed in as a _symbol_ but when it is * it is ignored and passed through * - it also allows numeric values to be passed through and in those cases * the numbers are converted to a `NumberLike` type */ type ReplaceAllFromTo = TText extends string ? ReplaceAllFromToLiteral : TText extends number ? ReplaceAllFromTo<`${TText}`, TMappings> : TText; //#endregion //#region ../types/src/type-conversion/RetainChars.d.ts type Retention = TChar extends `${infer Head}${infer Rest}` ? Head extends TRemove ? Retention : Retention : TRetain; /** * **RetainChars**`` * * Converts a string `TContent` into a string with all * of the characters in `TRetain` _retained_ while all * other characters are removed. */ type RetainChars = string extends TContent ? string : string extends TRetain ? string : Retention; //#endregion //#region ../types/src/type-conversion/RightWhitespace.d.ts /** * Provides the _left_ whitespace of a string * ```ts * // "\n\t " * type T = LeftWhitespace<"\n\t foobar">; * ``` */ type RightWhitespace = string extends S ? string : Replace, "">; //#endregion //#region ../types/src/type-conversion/StringLength.d.ts /** * Type utility that provides the _length_ of a given string type in a way which * is _not_ limited to TS's recursive string length of roughly 48. * * ```ts * // 3 * type Three = StringLength<"foo">; * ``` */ type StringLength = S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer _Fifth}${infer _Sixth}${infer _Seventh}${infer _Eighth}${infer _Ninth}${infer _Tenth}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer _Fifth}${infer _Sixth}${infer _Seventh}${infer _Eighth}${infer _Ninth}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer _Fifth}${infer _Sixth}${infer _Seventh}${infer _Eighth}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer _Fifth}${infer _Sixth}${infer _Seventh}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer _Fifth}${infer _Sixth}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer _Fifth}}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer _Fourth}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer _Third}${infer Rest}` ? StringLength : S extends `${infer _First}${infer _Second}${infer Rest}` ? StringLength : S extends `${infer _First}${infer Rest}` ? StringLength : [...R]["length"]; //#endregion //#region ../types/src/type-conversion/StripChars.d.ts type Removal = TContent extends `${infer Head}${infer Remaining}` ? Removal : TCollect; /** * **StripChars**`` * * Converts a string `TContent` into a string with all * of the characters in `TStrip` removed. * * - `TStrip` must be a single character or a union * of single characters */ type StripChars = string extends TContent ? string : string extends TStrip ? string : Removal; //#endregion //#region ../types/src/type-conversion/ToJson.d.ts type Enc$1> = TOpt["encode"] extends true ? SafeEncode : T; type InnerArray$1> = As$1<{ [K in keyof T]: T[K] extends string ? `${O["quote"]}${T[K]}${O["quote"]}` : Or<[Extends, Extends, Extends, Extends]> extends true ? `${As$1}` : T[K] extends readonly any[] ? ToJsonArray : T[K] extends Dictionary ? `{ ${InnerObject$2, O>} }` : never }, readonly string[]>; /** * **ToJsonArray**`` * * Converts an array to a JSON string of the same type. * * **Related:** `ToJson`, `ToJsonObject`, `ToJsonScalar` */ type ToJsonArray = InnerArray$1> extends readonly string[] ? Join>, ", "> extends infer Inner extends string ? `[ ${Inner} ]` : never : never; type InnerObject$2 = { quote: "\""; encode: false; }, R extends readonly string[] = []> = [] extends K ? Join : InnerObject$2, O, [...R, Or<[Extends], number>, Extends], boolean>, Equals], null>, Equals], undefined>]> extends true ? `${O["quote"]}${First$1}${O["quote"]}: ${As$1], boolean | number | null | undefined>}` : T[First$1] extends string ? `${O["quote"]}${First$1}${O["quote"]}: ${O["quote"]}${T[First$1]}${O["quote"]}` : T[First$1] extends readonly unknown[] ? `${O["quote"]}${First$1}${O["quote"]}: ${ToJsonArray], O>}` : T[First$1] extends Dictionary ? `${O["quote"]}${First$1}${O["quote"]}: ${ToJsonObject]>}` : never]>; /** * **ToJsonObject**`` * * Converts an object type `T` to a JSON string of the same type. * * **Related:** `ToJson`, `ToJsonArray`, `ToJsonScalar` */ type ToJsonObject = { quote: "\""; encode: false; }> = `{ ${InnerObject$2, O>} }`; /** * **ToJsonScalar**`` * * Converts a scalar value to the JSON string representation. * * **Related:** `ToJson`, `ToJsonArray`, `ToJsonObject` */ type ToJsonScalar, O extends Required = { quote: "\""; encode: false; }> = T extends string ? `${O["quote"]}${Enc$1}${O["quote"]}` : `${As$1}`; interface ToJsonOptions { quote?: QuoteCharacter; encode?: boolean; } /** * Merges user options with defaults to create `Required` */ type O$2 = As$1>, Required>; /** * Converts an object, array or scalar value to a * strongly typed JSON string. * * **Related:** * - `ToJsonObject`, `ToJsonArray`, `ToJsonScalar` * - `ToStringLiteral` */ type ToJson | Dictionary | Tuple$1, Opt extends ToJsonOptions = { quote: "\""; encode: false; }> = T extends Exclude ? ToJsonScalar, Required>> : T extends Dictionary ? ToJsonObject, Required>> : T extends Tuple$1 ? ToJsonArray, Required>> : never; //#endregion //#region ../types/src/type-conversion/ToNumber.d.ts /** * **ToNumber**`` * * - Converts `T` into a numeric type: * - if `T` is a Scalar/Object it's converted to a number where possible * - if `T` is an array then each element will be converted to a number where possible * - any non-numeric content which can not be converted to a number will be convert to `never` * - a number or a numeric array will be proxied through "as is" */ type ToNumber = IsTuple extends true ? TValue extends readonly unknown[] ? ToNumericArray extends readonly (number | never)[] ? ToNumericArray : Err<"can-not-convert", `Attempt to convert a tuple into a numeric tuple failed!`, { library: "inferred-types/constants"; value: TValue; }> : never : TValue extends number ? TValue : TValue extends `${infer Num extends number}` ? Num : If, IsEqual]>, 1, If, IsEqual]>, 0, If, readonly (number | never)[], never>>>; //#endregion //#region ../types/src/type-conversion/ToString.d.ts type _ArrayToString = { quote: "'"; encode: false; }, TOut extends string = "[ "> = [] extends T ? `${TOut} ]` : _ArrayToString, O, ToString> extends string ? TOut extends "[ " ? `[ ${ToString>}` : `${TOut}, ${ToString>}` : never>; type ArrayToString = { quote: "'"; encode: false; }> = IsWideContainer extends true ? T extends (infer Kind)[] ? `${ToString}[]` : `unknown[]` : _ArrayToString; type InnerObject$1 = { quote: "'"; encode: false; }, R extends readonly string[] = []> = [] extends K ? Join : InnerObject$1, O, [...R, Or<[Extends], number>, Extends], boolean>, Equals], null>, Equals], undefined>]> extends true ? `${First$1}: ${As$1], boolean | number | null | undefined>}` : T[First$1] extends string ? `${First$1}: ${O["quote"]}${T[First$1]}${O["quote"]}` : T[First$1] extends readonly unknown[] ? `${First$1}: ${ArrayToString], O>}` : T[First$1] extends Dictionary ? `${First$1}: ${ObjectToString]>}` : never]>; type ObjectToString = { quote: "'"; encode: false; }> = IsLiteralLikeObject extends true ? `{ ${InnerObject$1, O>} }` : T extends Record ? `Record}>` : "object"; type MapToString> = T extends Map ? `Map<${ToString}, ${ToString}>` : `Map`; type SetToString> = T extends Set ? `Set<${ToString}>` : `Set`; type WeakMapToString> = T extends WeakMap ? `WeakMap<${ToString}, ${ToString}}` : `WeakMap`; /** * **ToString** * * Converts _any_ type into a string representation of that type. * * **Related:** `AsString`, `ToJson` */ type ToString = { quote: "'"; encode: false; }> = [T] extends [readonly unknown[]] ? ArrayToString : [T] extends [string] ? [IsStringLiteral$1] extends [true] ? `${O["quote"]}${T}${O["quote"]}` : "string" : [T] extends [number] ? [IsNumericLiteral] extends [true] ? `${T}` : "number" : [T] extends [boolean] ? [IsBooleanLiteral] extends [true] ? `${T}` : "boolean" : [T] extends [null] ? `null` : [T] extends [undefined] ? `undefined` : [T] extends [Set] ? SetToString : [T] extends [Map] ? MapToString : [T] extends [WeakMap] ? WeakMapToString : [T] extends [Dictionary] ? ObjectToString : [IsUnion] extends [true] ? "Union<...>" : "unknown"; //#endregion //#region ../types/src/type-conversion/ToStringArray.d.ts /** * **ToStringArray**`` * * Receives a tuple of values and converts each item * into a _string_ value using the `ToString` utility. */ type ToStringArray = As$1<{ [K in keyof T]: AsString }, readonly string[]>; //#endregion //#region ../types/src/type-conversion/ToStringLiteral.d.ts interface ToLiteralOptions { quote?: QuoteCharacter; encode?: boolean; /** * by default all scalar values are taken to be _what they are_ * but if this flag is set to `true` then string literals will * be evaluated as being an `InputToken`. */ tokensAllowed?: boolean; /** * for containers which support the concept of "optional" keys */ isOptional?: boolean; } type Enc = TOpt["encode"] extends true ? SafeEncode : T; /** * Converts the elements in an array to tokens. */ type InnerArray = As$1<{ [K in keyof T]: T[K] extends string ? `${O["quote"]}${T[K]}${O["quote"]}` : Or<[Extends, Extends, Extends, Extends]> extends true ? `${As$1}` : T[K] extends readonly any[] ? ToStringLiteral__Array : T[K] extends Dictionary ? ToStringLiteral__Object : never }, readonly string[]>; type Wrap = `(${T})[]`; type AsUnionArrayString = [] extends T ? Wrap, string>> : AsUnionArrayString, ToStringLiteral> extends infer Type extends string ? [...O, Type] : O>; type Splitter = T extends [infer Head, ...infer Rest extends readonly unknown[]] ? IsGreaterThan extends true ? Splitter, [...R, Head], O> : Splitter, R, [...O, Head]> : [R, T extends [infer Last] ? [...O, Last] : O]; type ArrayWithOptionalElements> = Required extends infer Tuple extends readonly unknown[] ? Splitter extends [infer Req extends readonly unknown[], infer Opt extends readonly unknown[]] ? InnerArray extends infer Req extends readonly string[] ? InnerArray extends infer Opt extends readonly string[] ? Join<[...Req, ...Each], ", "> extends infer Inner extends string ? `[ ${Inner} ]` : never : never : never : never : never; /** * **ToStringLiteral__Array**`` * * Converts an array to a string literal representing that array. * * ```ts * // "[ 1, 2, 3 ]"" * type Test = ToStringLiteral__Array<[1,2,3]>; * ``` * * **Related:** * - `ToStringLiteral`, `ToStringLiteral__Object` * - `ToJson`, `ToJsonObject`, `ToJsonScalar` */ type ToStringLiteral__Array = [TupleMeta["hasOptionalElements"]] extends [true] ? ArrayWithOptionalElements : [TupleMeta["isWide"]] extends [true] ? [T] extends [readonly (infer Type)[]] ? [IsUnion] extends [true] ? [UnionToTuple] extends [readonly unknown[]] ? AsUnionArrayString> : never : [Type] extends [Scalar] ? `${ToStringLiteral__Scalar}[]` : [Type] extends [Dictionary] ? ToStringLiteral__Object extends infer Obj extends string ? `${Obj}[]` : never : never : never : [T["length"]] extends [0] ? `[]` : InnerArray extends (infer Arr extends readonly string[]) ? Join extends infer Inner extends string ? `[ ${Inner} ]` : never : never; /** * Object keys typically do not need be surrounded by quotations * marks at least if they are of the `PascalCase` or `camelCase` * variety but if they contain spaces, dashes, or really any character * other than alphanumeric characters then they must be quoted. */ type IsObjectKeyRequiringQuotes> = [] extends TChars ? false : First$1 extends AlphanumericChar ? IsObjectKeyRequiringQuotes> : true; type KeyName = As$1; type Quote$1 = As$1}${O["quote"]}` : `"${Enc}"`, string>; /** * Builds out the key/value pairs in the an object */ type InnerObject & ObjectKey)[] = As$1>, readonly (keyof Required & ObjectKey)[]>, TOptKeys extends string | symbol = OptionalKeys, TReq extends Dictionary = Required, TResult extends readonly string[] = []> = TKeys extends [infer K extends ObjectKey & keyof TDict, ...infer Rest extends readonly ObjectKey[]] ? TReq[K] extends infer Value ? Value extends Error ? Value : [IsUnion] extends [true] ? InnerObject, TOpt> extends infer Union extends string ? [...TResult, `${KeyName}: ${Union}`] : never> : Value extends Scalar ? InnerObject}: ${ToStringLiteral__Scalar}`]> : Value extends readonly unknown[] ? InnerObject}: ${ToStringLiteral__Array}`]> : Value extends Dictionary ? ToStringLiteral__Object extends infer ObjResult ? ObjResult extends Error ? ObjResult : ObjResult extends string ? InnerObject}: ${ObjResult}`]> : never : never : never : never : TKeys extends [infer Last extends keyof Required & ObjectKey] ? [...TResult, ToStringLiteral] : TResult; /** * **ToStringLiteral__Object**`` * * Converts an object type `T` to a JSON string of the same type. * * **Related:** `ToJson`, `ToJsonArray`, `ToJsonScalar` */ type ToStringLiteral__Object = InnerObject extends infer Inner ? Inner extends Error ? Inner : Inner extends readonly string[] ? `{ ${Join} }` : never : never; /** * **ToJsonScalar**`` * * Converts a scalar value to the JSON string representation. * * **Related:** `ToJson`, `ToJsonArray`, `ToJsonObject` */ type ToStringLiteral__Scalar = [IsAny] extends [true] ? `any` : [IsNever] extends [true] ? `never` : [T] extends [string] ? [string] extends [T] ? `string` : `${Quote$1}` : [T] extends [number] ? [number] extends [T] ? `number` : `${T}` : [T] extends [bigint] ? [bigint] extends [T] ? `bigint` : `${T}` : [IsNull] extends [true] ? `null` : [IsUndefined] extends [true] ? `undefined` : [IsUnknown] extends [true] ? `unknown` : [IsTrue] extends [true] ? `true` : [IsFalse] extends [true] ? `false` : [IsBoolean] extends [true] ? `boolean` : [T] extends [void] ? `void` : [T] extends [symbol] ? `symbol` : never; type ToStringLiteral__Union = Join<{ [K in keyof T]: ToStringLiteral }, " | ">; interface O$1 { quote: T["quote"] extends QuoteCharacter ? T["quote"] : "\""; encode: T["encode"] extends boolean ? T["encode"] : false; } /** * Converts any Typescript type into a string literal * _representation_ of that type. * * **Related:** * - `ToStringLiteral__Scalar`, `ToStringLiteral__Object` * - `ToJsonObject`, `ToJsonArray`, `ToJsonScalar` */ type ToStringLiteral = [IsAny] extends [true] ? "any" : [IsNever] extends [true] ? "never" : [T] extends [Error] ? T : [IsUnion] extends [true] ? ToStringLiteral__Union, Opt> : [T] extends [Scalar] ? ToStringLiteral__Scalar : [T] extends [readonly unknown[]] ? ToStringLiteral__Array> : [T] extends [Dictionary] ? ToStringLiteral__Object> : never; //#endregion //#region ../types/src/type-conversion/TrimEach.d.ts /** * **TrimEach**`` * * Trims each element of a Tuple/Array which extends _string_. * * - Non-string values are left as-is * * **Related:** `TrimDictionary` */ type TrimEach = { [K in keyof T]: T[K] extends string ? Trim : T[K] }; //#endregion //#region ../types/src/type-conversion/TupleToIntersection.d.ts type Break$2 = E extends "error" ? Err<"invalid-intersection", TMsg, TCtx> : never; type Set$1 = IsUnset extends true ? W : V & W; type Intersect$1 = T extends [infer Head, ...infer Rest] ? Head extends TypedFunction ? IsNever>> extends true ? Break$2<`A function with a key-value dictionary caused the intersection type to become 'never'`, { intersection: V; conflict: Head; }, E> : Intersect$1>> : IsNever> extends true ? Break$2<`TupleToIntersection hit an element which caused the intersection type to become 'never'`, { intersection: V; conflict: Head; }, E> : Intersect$1> : F extends undefined ? ExpandRecursively : F extends TypedFunction ? F & ExpandRecursively : never; /** * **TupleToIntersection**`` * * Recursively intersects all the elements of a tuple. * * - Empty tuples will return `unknown` as type * - if you want an Error instead of the `never` type you can set `E` to * "error" and the conflicting element which _caused_ the intersection to * become `never` will be highlighted. */ type TupleToIntersection = [] extends T ? unknown : Intersect$1; //#endregion //#region ../types/src/type-conversion/TupleToUnion.d.ts /** * Converts a Tuple type into a _union_ of the tuple elements * * ```ts * const arr = [1, 3, 5] as const; * // 1 | 3 | 5 * type U = TupleToUnion; * ``` * * **Note:** an empty array will be converted to a `string` type. */ type TupleToUnion = [T] extends [readonly unknown[]] ? [Keys$1["length"]] extends [0] ? never : T[number] : never; //#endregion //#region ../types/src/type-conversion/UnionArrayToTuple.d.ts type UnionToIntersection$2 = (U extends unknown ? (arg: U) => 0 : never) extends ((arg: infer I) => 0) ? I : never; type LastInUnion$1 = UnionToIntersection$2 0 : never> extends ((x: infer L) => 0) ? L : never; type UnionToTuple$1> = [U] extends [never] ? [] : [...UnionToTuple$1>, Last]; /** * **UnionArrayToTuple**`` * * If you have a type which is an _array_ of a Union type but you want to * represent this as a Tuple, this utility will make this conversion for you. * * **Related:** `UnionToTuple` */ type UnionArrayToTuple = T extends any[] ? UnionToTuple$1> : never; //#endregion //#region ../types/src/type-conversion/UnionToIntersection.d.ts /** * **UnionToIntersection**`` * * Type utility which converts a union type to an intersection */ type UnionToIntersection$1 = (U extends U ? (x: U) => unknown : never) extends ((x: infer R) => unknown) ? R : never; //#endregion //#region ../types/src/type-conversion/UnionToTuple.d.ts /** * UnionToIntersection<{ foo: string } | { bar: string }> = * { foo: string } & { bar: string }. */ type UnionToIntersection = (U extends unknown ? (arg: U) => 0 : never) extends ((arg: infer I) => 0) ? I : never; /** * LastInUnion<1 | 2> = 2. */ type LastInUnion = UnionToIntersection 0 : never> extends ((x: infer L) => 0) ? L : never; /** * ExcludeExact - Excludes from T only members that are EXACTLY equal to U * (not just extending U). This prevents tuples like [1,2,3] from being excluded * when excluding number[], since [1,2,3] extends number[] but is not equal to it. */ type ExcludeExact = T extends U ? U extends T ? never : T : T; /** * **UnionToTuple**`<1 | 2> => [1, 2]` * * Converts union members into a tuple. * * **Related**: `UnionArrayToTuple`, `UnionToTuple__PreserveBoolean` */ type UnionToTuple> = [U] extends [never] ? [] : [...UnionToTuple>, Last]; //#endregion //#region ../types/src/type-conversion/Widen.d.ts /** * **WidenScalar**`` * * Widens any _scalar_ type `T`. */ type WidenScalar = T extends string ? string : T extends number ? number : T extends boolean ? boolean : T extends bigint ? bigint : T extends symbol ? symbol : T extends null ? null : T extends undefined ? undefined : never; type Process$34 = T extends Scalar ? WidenScalar : T extends AnyFunction ? T extends TypedFunction ? WidenFunc : AnyFunction : T extends readonly unknown[] ? WidenTuple : T extends Dictionary ? WidenDictionary> : T; type WidenDictionary, readonly ObjectKey[]>, TResults extends Dictionary = EmptyObject> = K extends [infer Head extends ObjectKey, ...infer Rest extends ObjectKey[]] ? WidenDictionary>> : ExpandRecursively; type WidenTuple = { [K in keyof T]: IsLiteralLike extends true ? WidenLiteral : Process$34 }; /** * **WidenUnion** * * Widens all the elements in the union type. */ type WidenUnion = WidenTuple>[number]; type WidenLiteral = T extends Scalar ? WidenScalar : IsUnion extends true ? WidenUnion : T extends readonly unknown[] ? WidenTuple : T extends Dictionary ? WidenDictionary> : never; /** * Widens each element of a _fixed-length_ tuple, accumulating into `R`. * * The recursion peels elements with a **readonly** head/rest pattern so it * matches both mutable and `readonly` tuples (a mutable-only pattern would * fail to match a `readonly` tuple and collapse the result to `[]`). */ type WidenArrayInner = T extends readonly [infer Head, ...infer Rest] ? WidenArrayInner]> : R; /** * Widens the elements of an array/tuple `T` by one level while preserving its * structure. _Wide_ (variadic-length) arrays pass through untouched; a * fixed-length tuple has each element widened and its `readonly` modifier * re-applied so that, e.g., `readonly [string, 1 | 2 | 3]` widens to * `readonly [string, number]` (not the narrower mutable form). */ type WidenArray = number extends T["length"] ? T : [IsReadonlyArray] extends [true] ? readonly [...WidenArrayInner] : WidenArrayInner; /** * Recovers a function's return type **without** the `any`-collapse that the * built-in `ReturnType` suffers for a _union_-constrained generic whose type * parameter is woven into a template literal (e.g. * `` (name: T) => `hi ${T}` ``). Re-inferring `R` * through a fresh call signature keeps the concrete (often _union_) return. */ type RecoverFnReturn = T extends { (...args: infer _A): infer R; } ? R : never; /** * Widens a _recovered_ function return value. * * For string (or string-union) returns we collapse to the widest template * literal that still preserves the shared prefix — e.g. * `"hi Bob" | "hi Nancy"` becomes `` `hi ${string}` ``. Non-string returns * defer to the ordinary `Widen`. */ type WidenFnReturnValue = [R] extends [string] ? LongestCommonPrefix> extends infer TPrefix extends string ? [TPrefix] extends [""] ? string : `${TPrefix}${string}` : string : Widen; /** * **WidenFunc**`` * * Widens a function `T` while preserving its _narrowing_ vs _static_ character: * * - a **narrowing** function keeps its generic input constraint and widens * only its return value; a single-parameter narrowing function is rebuilt * in the ergonomic `` (x: X) => R `` form. * - a **static** function widens through `FnFrom`. * * Unlike the (now deprecated) `WidenFunction`, `WidenFunc` receives the whole * function and can therefore _recover_ template-literal returns that * `ReturnType` would otherwise collapse to `any`. * * The widened pieces are computed **once** in the `_Params`/`_Return`/`_Props` * helper parameters; hoisting `FnMeta["params"]` into an eager type * parameter is also what keeps the rebuilt parameter tuple at the correct * _arity_ (passing it lazily lets TypeScript collapse `[P]` to `P[]`). */ type WidenFunc["params"] : []), _Return = (T extends TypedFunction ? WidenFnReturnValue> : never), _Props extends Dictionary = (T extends TypedFunction ? ExpandDictionary> : EmptyObject)> = Function extends T ? Function : T extends TypedFunction ? [IsNarrowingFn] extends [true] ? _Params extends readonly [infer P0] ? [IsNonEmptyContainer<_Props>] extends [true] ? ((x: X) => _Return) & _Props : (x: X) => _Return : FnFrom<_Params, _Return, _Props> : FnFrom<_Params, _Return, _Props> : never; type WidenContainer = [T] extends [readonly unknown[]] ? TForce extends true ? readonly unknown[] : WidenArray : [T] extends [Dictionary] ? TForce extends true ? Dictionary : WidenDictionary : [T] extends [Map] ? TForce extends true ? AnyMap : Map> : [T] extends [WeakMap] ? TForce extends true ? AnyWeakMap : WeakMap> : [T] extends [Set] ? TForce extends true ? AnySet : Set> : T; /** * **Widen**`` * * Converts a literal type to a _wider_ type. * * - for _scalar values_ `T` will just become wide variant (e.g., `5` → `number`) * - for _union types_ all elements of the union will be made wide * - for _container values_ it will widen the items inside the container * * **Note:** should you want the container values to be fully widened you * can set `TForce` to true. */ type Widen = [IsUnion] extends [true] ? WidenUnion : [T] extends [TypedFunction] ? FnFrom> extends true ? Parameters : WidenArray>, Widen>, WidenDictionary>> : [T] extends [Scalar] ? WidenScalar : [T] extends [Container] ? WidenContainer : T extends Scalar ? WidenScalar : Process$34; //#endregion //#region ../types/src/interpolation/IsTemplateLiteral.d.ts type CountTemplates = string extends T ? 1 : T extends `${infer First}${infer Rest}` ? Or<[string extends First ? true : false, `${number}` extends First ? true : false]> extends true ? CountTemplates : CountTemplates : C["length"]; /** * **isTemplateLiteral**`` * * A boolean operator which evaluates if `T` has dynamic types * like `${string}`, `${number}`, or `${boolean}` included in * it. * * - Note a wide `string` and a `${string}` type will result in `false` as they * are both equivalent to a wide string in the type system. */ type IsTemplateLiteral = IsUnion extends true ? Every, "containsSome", ["true", "false"]> : T extends string ? string extends T ? false : T extends "" ? false : [CountTemplates<`|${T}|`>] extends [0] ? false : true : false; //#endregion //#region ../types/src/interpolation/ReplaceInterpolation.d.ts /** * determine replacement type */ type R$1 = T extends string ? T : T extends readonly (string | number | boolean)[] ? T["length"] extends 0 ? D : First$1 : never; type Next$1 = T extends string ? T : T extends readonly (string | number | boolean)[] ? AfterFirst : never; /** * **ReplaceStringInterpolation**`` * * Replaces all instances of `${string}` in `TContent` with `TReplace` */ type ReplaceStringInterpolation = TContent extends `${infer First}${infer Rest}` ? [IsEqual] extends [true] ? ReplaceStringInterpolation, `${TResult}${R$1}`> : ReplaceStringInterpolation : [TContent] extends [""] ? TResult : [IsEqual] extends [true] ? `${TResult}${R$1}` : `${TResult}${TContent}`; /** * **ReplaceNumericInterpolation**`` * * Replaces all instances of `${number}` in `TContent` with `TReplace` * * - when `TReplace` is single string then all instances are replaced with * this value * - when `TReplace` is an array of strings then strings are pulled off in a FIFO * manner to replace * * **Related:** `ReplaceStringInterpolation` */ type ReplaceNumericInterpolation = TContent extends `${infer First}${infer Rest}` ? [IsEqual] extends [true] ? ReplaceNumericInterpolation, `${TResult}${R$1}`> : ReplaceNumericInterpolation : [TContent] extends [""] ? TResult : [IsEqual] extends [true] ? `${TResult}${R$1}` : `${TResult}${TContent}`; //#endregion //#region ../types/src/interpolation/StartsWithTemplateLiteral.d.ts type UnionStartsBoolean = And<{ [K in keyof T]: T[K] extends string ? StartsWith : never }>; /** * **HasLeadingTemplateLiteral**`` * * tests whether `T` _starts with_ a leading template literal * such as `${string}`, `${number}`, or `${boolean}` */ type StartsWithTemplateLiteral = T extends string ? [IsUnion] extends [true] ? [UnionToTuple] extends [readonly string[]] ? UnionStartsBoolean> : never : T extends `${infer First}${infer _Rest}` ? IsEqual<`${string}`, First> extends true ? true : IsEqual<`${number}`, First> extends true ? true : false : false : false; //#endregion //#region ../types/src/interpolation/StaticTemplateSections.d.ts type Finalize$1 = TWithType extends true ? { [K in keyof TResults]: StringLiteralTemplate } : TResults; type Section$1 = TWithType extends null ? THead : `${THead}${TBlock}`; type Scan = TTemplate extends `{{string}}${infer Rest}` ? Scan]> : TTemplate extends `{{number}}${infer Rest}` ? Scan]> : TTemplate extends `{{boolean}}${infer Rest}` ? Scan]> : TTemplate extends `{{true}}${infer Rest}` ? Scan]> : TTemplate extends `{{false}}${infer Rest}` ? Scan]> : TTemplate extends `${infer Head}${infer Rest}` ? Scan : TResults; /** * **StaticTemplateSections**`` * * Segments the various static sections defined in the `TTemplate`. * * - if you optionally set the `TWithType` generic to `true` then the * string literal templates will be added * - if you set `TWithType` generic to `false` then the template blocks * like `{{string}}`, etc. will be added. */ type StaticTemplateSections = Finalize$1 extends infer Template extends string ? As$1, readonly string[]> : [], TWithType>; //#endregion //#region ../types/src/interpolation/StringLiteralTemplate.d.ts type _StringLiteralTemplate = T extends number ? `${number}` : T extends boolean ? `${boolean}` : T extends `${infer Before}{{string}}${infer After}` ? StringLiteralTemplate<`${Before}${string}${After}`> : T extends `${infer Before}{{number}}${infer After}` ? StringLiteralTemplate<`${Before}${number}${After}`> : T extends `${infer Before}{{boolean}}${infer After}` ? StringLiteralTemplate<`${Before}${boolean}${After}`> : T extends `${infer Before}{{true}}${infer After}` ? StringLiteralTemplate<`${Before}${true}${After}`> : T extends `${infer Before}{{false}}${infer After}` ? StringLiteralTemplate<`${Before}${false}${After}`> : T; /** * **StringLiteralTemplate**`` * * Converts a string literal into a "template" by replacing tokens * like `{{string}}`, `{{number}}`, or `{{boolean}}` with the * corresponding string literal equivalent. * * **Related:** `EachAsStringLiteralTemplate`, `ObjectValuesAsStringLiteralTemplate` */ type StringLiteralTemplate = IsStringLiteral$1 extends true ? _StringLiteralTemplate : never; //#endregion //#region ../types/src/interpolation/StripSurroundingStringTemplate.d.ts /** * **StripLeadingStringTemplate**`` * * Strips any existing `${string}` type when it starts the type T. * * ```ts * // `FooBar${string}` * type Foobar = StripLeadingStringTemplate<`${string}Foobar${string}`> * ``` */ type StripLeadingStringTemplate = T extends `${infer First}${infer Rest}` ? IsEqual extends true ? StripLeadingStringTemplate : T : never; /** * **StripTrailingStringTemplate**`` * * Strips any existing `${string}` type when ity terminates the type T. * * ```ts * // `${string}FooBar` * type Foobar = StripTailingStringTemplate<`${string}Foobar${string}`> * ``` */ type StripTrailingStringTemplate = IsStringLiteral$1 extends true ? Join> : never; /** * **StripSurroundingStringTemplate**`` * * Strips any existing `${string}` type when it _leads_ or _terminates_ the type T. * * ```ts * // `FooBar` * type Foobar = StripTailingStringTemplate<`${string}Foobar${string}`> * ``` */ type StripSurroundingStringTemplate = IsStringLiteral$1 extends true ? StripTrailingStringTemplate> : never; //#endregion //#region ../types/src/interpolation/template-maps.d.ts interface TemplateMap__Basic { string: "string"; number: "number"; boolean: "boolean"; } type AddGeneric = { [K in keyof G | T["name"]]: K extends T["name"] ? T["token"] : K extends keyof G ? G[K] : never }; /** * **TemplateMap__Generics**`` * * Provides a static template based on the generic types provided. It also * always includes the basics for `string`, `number`, and `boolean`. */ type TemplateMap__Generics = T extends [infer Head extends GenericParam, ...infer Rest extends readonly GenericParam[]] ? TemplateMap__Generics> : G; //#endregion //#region ../types/src/boolean-logic/operators/datetime/IsBefore.d.ts type IsSameDateDifferentPrecision = A extends `${infer DatePart}T00:00:00Z` ? B extends DatePart ? true : false : B extends `${infer DatePart}T00:00:00Z` ? A extends DatePart ? true : false : false; type IsCharGreater = A extends "0" ? false : A extends "1" ? B extends "0" ? true : false : A extends "2" ? B extends "0" | "1" ? true : false : A extends "3" ? B extends "0" | "1" | "2" ? true : false : A extends "4" ? B extends "0" | "1" | "2" | "3" ? true : false : A extends "5" ? B extends "0" | "1" | "2" | "3" | "4" ? true : false : A extends "6" ? B extends "0" | "1" | "2" | "3" | "4" | "5" ? true : false : A extends "7" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" ? true : false : A extends "8" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" ? true : false : A extends "9" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" ? true : false : A extends ":" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" ? true : false : A extends "T" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "-" | ":" ? true : false : A extends "Z" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "-" | ":" | "T" ? true : false : A extends "-" ? B extends "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" ? true : false : false; type LexicographicCompare = A extends B ? false : IsSameDateDifferentPrecision extends true ? false : [A] extends [never] ? false : [B] extends [never] ? false : [A, B] extends [string, string] ? A extends `${infer AFirst}${infer ARest}` ? B extends `${infer BFirst}${infer BRest}` ? AFirst extends BFirst ? LexicographicCompare : IsCharGreater : true : false : false; /** * **IsBefore**`` * * Tests whether `A` is _before_ (in time) `B`. */ type IsBefore = A extends object ? boolean : B extends object ? boolean : string extends A ? boolean : string extends B ? boolean : IsTemplateLiteral extends true ? boolean : IsTemplateLiteral extends true ? boolean : number extends A ? boolean : number extends B ? boolean : A extends number ? B extends number ? IsLessThan : boolean : A extends string ? B extends string ? LexicographicCompare : boolean : boolean; //#endregion //#region ../types/src/boolean-logic/operators/datetime/IsDayJs.d.ts interface Shape$5 { add: AnyFunction; clone: AnyFunction; date: AnyFunction; endOf: AnyFunction; isAfter: AnyFunction; isBefore: AnyFunction; daysInMonth: AnyFunction; millisecond: AnyFunction; calendar: unknown; } /** * **IsDayJs**`` * * Boolean utility to test whether `T` is DayJS date object. */ type IsDayJs = [IsAny] extends [true] ? false : [IsNever] extends [true] ? false : [IsUnknown] extends [true] ? boolean : [IsUnion] extends [true] ? true extends (T extends Shape$5 ? true : false) ? T extends Shape$5 ? true : boolean : false : IsDictionary extends true ? T extends Shape$5 ? true : false : false; //#endregion //#region ../types/src/datetime/AsDateMeta.d.ts type ParsedDateType = T extends [infer Year, infer Month, infer Date, infer Time] ? Date extends null ? Month extends null ? "year" : "year-month" : Year extends null ? "year-independent" : Time extends null ? "date" : "datetime" : never; type HasTime = ParsedDateType extends "datetime" ? T[3] extends [infer Hour, infer Minute, infer Second, infer MS, infer TZ] ? Hour extends "00" ? Minute extends "00" ? Or<[Extends, IsNull]> extends true ? Or<[Extends, IsNull]> extends true ? Or<[Extends, IsNull]> extends true ? false : true : true : true : true : true : never : false; type Hour$1 = T extends null ? null : T extends ParsedTime ? T[0] : never; type Minute$1 = T extends null ? null : T extends ParsedTime ? T[1] : never; type Second$1 = T extends null ? null : T extends ParsedTime ? T[2] : never; type Millisecond = T extends null | undefined ? null : T extends ParsedTime ? T[3] : never; type Offset = T extends null ? null : T extends ParsedTime ? T[4] : never; type SetParsed = { dateType: ParsedDateType; hasTime: HasTime; year: T[0]; month: T[1]; date: T[2]; hour: Hour$1; minute: Minute$1; second: Second$1; ms: Millisecond; timezone: Offset; }; /** * **AsDateMeta**`` * * Tests to see if `T` can be parsed into a `DateMeta` type. * * - a valid ISO string _or_ a `ParsedData` array should be * able to be parsed. * - if it can then `DateMeta` is returned * - if not then an `Error` will be returned * * Note: if the value passed in as `T` is a `ParsedDate` type * then this utility will never return an error as the validation * has already been done. */ type AsDateMeta = T extends ParsedDate ? SetParsed : ParseDate extends infer P ? P extends Error ? P : P extends ParsedDate ? SetParsed

: never : never; //#endregion //#region ../types/src/datetime/AsFourDigitYear.d.ts type Digit$5 = "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9"; type IsDigits = T extends "" ? false : T extends `${Digit$5}${infer Rest}` ? Rest extends "" ? true : IsDigits : false; type IsFourDigits = T extends `${Digit$5}${Digit$5}${Digit$5}${Digit$5}` ? true : false; type BrandYear = IsTrue extends true ? FourDigitYear> : T; type ConvertNumericString = T extends `-${string}` ? Err<`year-invalid/negative`, `The generic passed into AsFourDigitYear was a NEGATIVE number. This is not allowed!`, { T: T; }> : T extends `${string}.${string}` ? TNumberInput extends true ? Err<`year-invalid/float`, `The generic passed into AsFourDigitYear was a number but not an integer!`, { T: T; }> : Err<"year-invalid/type"> : IsDigits extends true ? PadStart extends infer Padded extends string ? IsFourDigits extends true ? BrandYear : TNumberInput extends true ? Err<`year-invalid/too-large`, `The generic passed into AsFourDigitYear was an integer number but it was larger than 9999 so it will not fit into the ISO FourDigitYear format!`, { T: T; }> : Err<"year-invalid/type"> : Err<"year-invalid/type"> : Err<"year-invalid/type">; type Convert$6 = T extends string ? IsBranded extends true ? Convert$6, B> : ConvertNumericString : T extends number ? number extends T ? IsTrue extends true ? FourDigitYear<"branded"> | Error : FourDigitYear | Error : ConvertNumericString<`${T}`, B, true> : Err<`year-invalid/wrong-type`, `The type passed in as T to AsFourDigitYear was an invalid type! T must be a number or a string literal that can be converted into a number`, { T: T; }>; /** * **AsFourDigitYear**`` * * A type conversion utility which tries to convert `T` into a valid `FourDigitYear` type. * * - by default the conversion is done but the type returned is _not_ a branded type * - to switch this behavior then pass in `true` to the generic `B` * * If there is no way to convert `T` to a `FourDigitYear` then an Error will be returned. */ type AsFourDigitYear = [IsAny] extends [true] ? IsTrue extends true ? FourDigitYear<"branded"> | Error : FourDigitYear | Error : As$1, IsTrue extends true ? FourDigitYear<"branded"> | Error : FourDigitYear | Error>; //#endregion //#region ../types/src/errors/Err.d.ts /** * **TypedError** * * An `Error` which is guaranteed to have a `type` property * and may optionally have a `subType` property. */ type TypedError = Expand; type _Err$1 = EmptyObject> = TType extends `${infer Type}/${infer Subtype}` ? Expand<{ name: PascalCase extends string ? RetainUntil : never>; type: KebabCase; subType: Subtype extends string ? KebabCase : undefined; message: TMsg extends "" ? string : TMsg; cause?: unknown; stack?: string; } & TCtx> & Error : Expand<{ name: PascalCase>; message: TMsg extends "" ? string : TMsg; type: TType; cause?: unknown; stack?: string; } & TCtx> & Error; /** * handles when the "type" is a wide string */ type WideErrType$1 = EmptyObject> = string extends TMsg ? IsEqual extends true ? Error : _Err$1 : _Err$1; /** * **Err**`` * * Create a strongly typed error with type and subType information. * * - TType assigns the type to the errors `type` property until a `/` character is found * - the `subType` property is the string literal portion of `TType` after the `/` character * - any key/value pairs on `TCtx` will be available on the error too * * **Related:** * - `err(type, msg, ctx)` mirrors same functionality for runtime * - `ErrContext` allows _adding_ context to an existing Error * - `WhenErr` allows conditionally adding context to an Error * when/if `T` extends Error. Otherwise proxies `T` through "as is" */ type Err = EmptyObject> = string extends TType ? WideErrType$1 : _Err$1; /** * Adds "context" to an existing `Error`. */ type ErrContext = Expand & C> extends Error ? Expand & C> & Error : never; //#endregion //#region ../types/src/errors/ErrMsg.d.ts type ErrMsg = TContext extends string ? TType & { desc: TContext; kind: "ErrMsg"; } : TType & ExpandDictionary; //#endregion //#region ../types/src/errors/ErrType.d.ts /** * **ErrType**`` * * Return the `type` property of `T` if: * * - T is an Error * - T has the property `type` * * **Related:** `Err`, `ErrSubType` */ type ErrType = T extends Error ? "type" extends keyof T ? T["type"] extends infer Type ? Type : undefined : undefined : undefined; //#endregion //#region ../types/src/errors/HasErrors.d.ts type CheckArray$1 = T extends [infer Head, ...infer Rest] ? U extends string ? Head extends Err ? true : CheckArray$1 : Head extends Error ? true : CheckArray$1 : false; type CheckDictionary$1 = CheckArray$1, U>; /** * **HasErrors**`` * * Checks whether a container `T` has _values_ which extend Error. */ type HasErrors = T extends readonly unknown[] ? CheckArray$1 : T extends Dictionary ? CheckDictionary$1 : never; //#endregion //#region ../types/src/errors/IsolateErrors.d.ts /** * The results produced by the `IsolateErrors` utility */ interface IsolatedResults { successes: readonly unknown[]; errors: readonly Error[]; otherErrors: readonly Error[]; } type CheckArray = T extends readonly [infer Head, ...infer Rest] ? Head extends Error ? U extends string ? CheckArray ? { successes: R["successes"]; errors: [...R["errors"], Head]; otherErrors: R["otherErrors"]; } : { successes: R["successes"]; errors: R["errors"]; otherErrors: [...R["otherErrors"], Head]; }, IsolatedResults>> : CheckArray> : CheckArray> : R; type CheckDictionary = CheckArray, U>; /** * **IsolateErrors**`` * * Isolates error's from successful outcomes in the _values_ of `T`. * * - When `U` is unset then you will be returned a dictionary with `successes` and `errors` properties. * - When `U` **is** set then it represents a type/subtype of the error. The result this utility * returns is `successes`, `errors`, and `otherErrors` (for errors which were found but not errors * of the specified type) */ type IsolateErrors = T extends readonly unknown[] ? CheckArray : T extends Dictionary ? CheckDictionary : never; //#endregion //#region ../types/src/string-literals/AsTypeSubtype.d.ts type AsTypeSubtype = IsWideString extends true ? [string, string | undefined] : T extends `${infer Type}/${infer Subtype}` ? [Type, Subtype] : [T, undefined]; //#endregion //#region ../types/src/string-literals/casing/CamelCase.d.ts /** * Direct camelCase conversion that leverages optimized PascalCase */ type CamelCaseSimple = IsAllCaps extends true ? Uncapitalize>>> : Uncapitalize>>; /** * **CamelCase**`` * * Converts a string to `CamelCase` format. */ type CamelCase = string extends T ? string : T extends string ? CamelCaseSimple : T extends readonly unknown[] ? { [K in keyof T]: T[K] extends string ? CamelCase : T[K] } : never; //#endregion //#region ../types/src/string-literals/casing/DashUppercase.d.ts type _DU = T extends Lowercase ? T : `-${Lowercase}`; /** * Converts uppercase characters to a dash and then the lowercase equivalent * * ```ts * // "one-two-three" * type T = DashUppercase<"oneTwoThree">; * ``` * * _Intended to be used as a lower level utility; prefer `Dasherize` for more full-fledged * dash solution_. */ type DashUppercase = HasUppercase extends false ? T : T extends `${infer C0}${infer C1}${infer R}` ? `${_DU}${_DU}${DashUppercase}` : T extends `${infer C0}${infer R}` ? `${_DU}${DashUppercase}` : ""; //#endregion //#region ../types/src/string-literals/casing/KebabCase.d.ts type Process$33 = TPreserve extends true ? Concat<[LeftWhitespace, KebabCase, RightWhitespace]> : string extends TString ? string : DashUppercase>> extends `${infer Begin}${"_" | " "}${infer Rest}` ? KebabCase<`${Lowercase}-${Rest}`> : Replace>>>>, "--", "-">; /** * **KebabCase**`` * * Converts a string literal into a `kebab-case` format while optionally * allowing surrounding whitespace. * * ```ts * // "foo-bar" * type Dash = Dasherize<"foo_bar">; * type Dash = Dasherize<"fooBar">; * type Dash = Dasherize<"FooBar">; * // "\n foo-bar \t" * type Dash = Dasherize<"\n foo bar \t">; * ``` */ type KebabCase = TInput extends string ? Process$33 extends string ? Process$33 : never : TInput extends readonly unknown[] ? As$1<{ [K in keyof TInput]: TInput[K] extends string ? KebabCase : TInput[K] }, readonly unknown[]> : never; //#endregion //#region ../types/src/string-literals/casing/LowerAllCaps.d.ts /** * **LowerAllCaps**` * * Type utility which will convert an "all caps" string to a string where all characters are lowercase; in * all other cases it will do nothing and simply return `T` as `T`. * * **Related:** `RaiseAllLowercase` */ type LowerAllCaps = IsAllCaps extends true ? Lowercase : T; //#endregion //#region ../types/src/string-literals/casing/PascalCase.d.ts /** * Limited depth PascalCase - processes up to 20 segments to avoid deep recursion */ type LimitedPascalCase = Depth["length"] extends 20 ? T : T extends `${infer Before}-${infer After}` ? `${Capitalize}${LimitedPascalCase}` : T extends `${infer Before}_${infer After}` ? `${Capitalize}${LimitedPascalCase}` : T extends `${infer Before} ${infer After}` ? `${Capitalize}${LimitedPascalCase}` : Capitalize; /** * Recursive PascalCase for strings with delimiters * Processes one character at a time to handle mixed delimiters correctly */ type RecursivePascalCase = T extends `${string}${"-" | "_" | " "}${string}` ? LimitedPascalCase : T extends `${infer First}${infer Rest}` ? First extends "-" | "_" | " " ? RecursivePascalCase : CapNext extends true ? `${Uppercase}${RecursivePascalCase}` : `${Lowercase}${RecursivePascalCase}` : ""; /** * Handles camelCase strings by detecting uppercase letters as word boundaries */ type HandleCamelCase = T extends `${infer First}${infer Rest}` ? Uppercase extends First ? Lowercase extends First ? HandleCamelCase : Result extends "" ? HandleCamelCase : HandleCamelCase : Rest extends `${infer Next}${string}` ? Uppercase extends Next ? Lowercase extends Next ? HandleCamelCase}`> : HandleCamelCase}-`> : HandleCamelCase}`> : `${Result}${Lowercase}` : Result; /** * Simplified PascalCase conversion that uses recursive approach for delimited strings */ type PascalCaseSimple = T extends `${string}-${string}` | `${string}_${string}` | `${string} ${string}` ? RecursivePascalCase : T extends `${infer _First}${infer Rest}` ? Rest extends `${string}${Uppercase}${string}` ? RecursivePascalCase> : Capitalize : Capitalize; /** * Converts a string literal type to a **PascalCase** representation. * ```ts * // "FooBar" * type T = PascalCase<"fooBar">; * type T = PascalCase<"foo-bar">; * type T = PascalCase<"foo_bar">; * type T = PascalCase<"\n foo_bar \t">; * ``` */ type PascalCase = string extends T ? string : T extends string ? IsAllCaps extends true ? PascalCaseSimple>> : PascalCaseSimple> : T extends readonly unknown[] ? { [K in keyof T]: T[K] extends string ? PascalCase : T[K] } : never; //#endregion //#region ../types/src/string-literals/casing/SnakeCase.d.ts /** * Direct snake_case conversion in a single pass * Handles camelCase, PascalCase, kebab-case, spaces, and existing snake_case */ type SnakeCaseCore = T extends `${infer First}${infer Rest}` ? First extends "-" | " " ? SnakeCaseCore : First extends "_" ? SnakeCaseCore : Uppercase extends First ? Lowercase extends First ? SnakeCaseCore : PrevWasLower extends true ? SnakeCaseCore}`, false> : SnakeCaseCore}`, false> : SnakeCaseCore}`, true> : Result; /** * Limited depth snake_case to avoid deep recursion on very long strings */ type LimitedSnakeCase = Depth["length"] extends 25 ? T : T extends `${infer Before}-${infer After}` ? `${Lowercase}_${LimitedSnakeCase}` : T extends `${infer Before} ${infer After}` ? `${Lowercase}_${LimitedSnakeCase}` : Lowercase; /** * Optimized SnakeCase that tries fast paths first */ type SnakeCaseSimple = T extends `${string}${"-" | " "}${string}` ? LimitedSnakeCase : IsAllCaps extends true ? Lowercase : SnakeCaseCore; /** * **SnakeCase**`` * * Converts a string literal type to _snake_case_. * ```ts * // "foo_bar" * type T = SnakeCase<"fooBar">; * type T = SnakeCase<"foo bar">; * type T = SnakeCase<"foo-bar">; * ``` */ type SnakeCase = string extends T ? string : T extends string ? SnakeCaseSimple> : T extends readonly unknown[] ? { [K in keyof T]: T[K] extends string ? SnakeCase : T[K] } : never; //#endregion //#region ../types/src/string-literals/character-sets/AlphaChar.d.ts /** * **AlphaChar** * * Alphabetical character (both upper and lowercase). * * **Related:** `UpperAlphaChar`, `LowerAlphaChar`, `Alpha` */ type AlphaChar = UpperAlphaChar | LowerAlphaChar; //#endregion //#region ../types/src/string-literals/character-sets/AlphanumericChar.d.ts /** * **AlphanumericChar** * * A character which is either a letter (upper or lower) or a number. */ type AlphanumericChar = AlphaChar | NumericChar; //#endregion //#region ../types/src/string-literals/character-sets/brackets/Brackets.d.ts /** * Opening and closing brackets. Where brackets are parenthesis, square brackets, and curly brackets. * * **Related:** `OpeningBracket`, `ClosingBracket` */ type Bracket = "(" | "[" | "{" | "<" | ")" | "]" | "}" | ">"; //#endregion //#region ../types/src/string-literals/character-sets/Char.d.ts /** * **Char** * * Meant to represent a single character. Includes: * * - Alphanumeric characters * - Punctuation ( . , ; ! ? ) * - Whitespace ( " " "\t" "\n" "\b" ) * - Bracket characters ( { [ ( ) ] } ) * - Quote characters ( " ' ` ) * - Currency characters ( $ ¢ £ € ฿ ¥ ₹ ₽ ) * - Math characters ( + - * / ^ ✕ ÷ = ≄ > < ) * - Special Chars ( @ ~ # & | \ # ) */ type Char$1 = AlphanumericChar | Punctuation | Whitespace | Bracket | SpecialChar | QuoteCharacter | PlusMinus | NBSP | CurrencyChar | MatchChar | EscapeCodeChars; //#endregion //#region ../types/src/string-literals/character-sets/Country.d.ts type Iso3166_1_Lookup = typeof ISO3166_1; type Props = "alpha2" | "alpha3" | "countryCode" | "name"; /** * **Iso3166_1_Alpha2** * * A union of all 2 character country codes defined by the ISO3166-1 * standard. */ type Iso3166_1_Alpha2 = { [K in keyof Iso3166_1_Lookup]: "alpha2" extends keyof Iso3166_1_Lookup[K] ? Iso3166_1_Lookup[K]["alpha2"] : never }[number]; /** * **Iso3166_1_Alpha3** * * A union of all 2 character country codes defined by the ISO3166-1 * standard. */ type Iso3166_1_Alpha3 = { [K in keyof Iso3166_1_Lookup]: "alpha3" extends keyof Iso3166_1_Lookup[K] ? Iso3166_1_Lookup[K]["alpha3"] : never }[number]; /** * **Iso3166_1_Alpha3** * * A union of all 2 character country codes defined by the ISO3166-1 * standard. */ type Iso3166_1_CountryCode = { [K in keyof Iso3166_1_Lookup]: "countryCode" extends keyof Iso3166_1_Lookup[K] ? Iso3166_1_Lookup[K]["countryCode"] : never }[number]; /** * **Iso3166_1_Alpha3** * * A union of all 2 character country codes defined by the ISO3166-1 * standard. */ type Iso3166_1_CountryName = { [K in keyof Iso3166_1_Lookup]: "name" extends keyof Iso3166_1_Lookup[K] ? Iso3166_1_Lookup[K]["name"] : never }[number]; type LookupAlpha2 = [] extends Lookup ? undefined : T extends First$1["alpha2"] ? First$1[`${Prop}`] : LookupAlpha2, Prop>; type LookupAlpha3 = [] extends Lookup ? undefined : T extends First$1["alpha3"] ? First$1[`${Prop}`] : LookupAlpha3, Prop>; type LookupCountryCode = [] extends Lookup ? undefined : T extends First$1["countryCode"] ? First$1[`${Prop}`] : LookupCountryCode, Prop>; type LookupCountryName = [] extends Lookup ? undefined : T extends First$1["name"] ? First$1[`${Prop}`] : LookupCountryName, Prop>; /** * **Iso3166Country**`` * * Provides the ISO3166-1 **country name** if provided a valid lookup value ( * aka, a alpha-2, alpha-3, or country code). If not valid returns _undefined_. */ type Iso3166CountryLookup = T extends number ? Iso3166CountryLookup<`${T}`> : T extends string ? IsStringLiteral$1 extends true ? T extends Iso3166_1_Alpha2 ? LookupAlpha2 : T extends Iso3166_1_Alpha3 ? LookupAlpha3 : T extends Iso3166_1_CountryCode ? LookupCountryCode : T extends Iso3166_1_CountryName ? LookupCountryName : IsStringLiteral$1 extends true ? undefined : If, Iso3166_1_CountryCode | undefined, undefined> : undefined : undefined; /** * **Iso3166Alpha2Lookup**`` * * Provides the ISO3166-1 **Alpha 2** code if provided a valid lookup value ( * aka, a alpha-3, country code, or country name). If not valid returns _undefined_. */ type Iso3166Alpha2Lookup = T extends number ? Iso3166CountryLookup<`${T}`> : T extends string ? IsStringLiteral$1 extends true ? T extends Iso3166_1_Alpha2 ? LookupAlpha2 : T extends Iso3166_1_Alpha3 ? LookupAlpha3 : T extends Iso3166_1_CountryCode ? LookupCountryCode : T extends Iso3166_1_CountryName ? LookupCountryName : IsStringLiteral$1 extends true ? undefined : If, Iso3166_1_Alpha2 | undefined, undefined> : undefined : undefined; /** * **Iso3166Alpha33Lookup**`` * * Provides the ISO3166-1 **Alpha 3** code if provided a valid lookup value ( * aka, a alpha-3, country code, or country name). If not valid returns _undefined_. */ type Iso3166Alpha3Lookup = T extends number ? Iso3166CountryLookup<`${T}`> : T extends string ? IsStringLiteral$1 extends true ? T extends Iso3166_1_Alpha2 ? LookupAlpha2 : T extends Iso3166_1_Alpha3 ? LookupAlpha3 : T extends Iso3166_1_CountryCode ? LookupCountryCode : T extends Iso3166_1_CountryName ? LookupCountryName : IsStringLiteral$1 extends true ? undefined : If, Iso3166_1_Alpha3 | undefined, undefined> : undefined : undefined; /** * **Iso3166Alpha33Lookup**`` * * Provides the ISO3166-1 **Alpha 3** code if provided a valid lookup value ( * aka, a alpha-3, country code, or country name). If not valid returns _undefined_. */ type Iso3166CodeLookup = T extends number ? Iso3166CountryLookup<`${T}`> : T extends string ? IsStringLiteral$1 extends true ? T extends Iso3166_1_Alpha2 ? LookupAlpha2 : T extends Iso3166_1_Alpha3 ? LookupAlpha3 : T extends Iso3166_1_CountryCode ? LookupCountryCode : T extends Iso3166_1_CountryName ? LookupCountryName : IsStringLiteral$1 extends true ? undefined : If, Iso3166_1_CountryCode | undefined, undefined> : undefined : undefined; //#endregion //#region ../types/src/string-literals/character-sets/css/absolute.d.ts interface CssAbsolutionPositioningProperties { /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/top) */ "top"?: CssSizing; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/bottom) */ "bottom"?: CssSizing; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/left) */ "left"?: CssSizing; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/right) */ "right"?: CssSizing; /** * The inset CSS property is a shorthand that corresponds to the top, right, bottom, * and/or left properties. It has the same multi-value syntax of the margin shorthand. * * This inset properties, including inset, have no effect on non-positioned elements. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset) */ "inset"?: CssSizing | `${CssSizing} ${string}`; /** * The `inset-block` CSS property defines the logical block start and end offsets of an * element, which maps to physical offsets depending on the element's writing mode, * directionality, and text orientation. It corresponds to the top and bottom, or * right and left properties depending on the values defined for writing-mode, direction, * and text-orientation. * * This inset property has no effect on non-positioned elements. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset-block) */ "inset-block"?: CssSizing | `${CssSizing} ${string}`; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset-block-end) */ "inset-block-end"?: CssSizing; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset-block-start) */ "inset-block-start"?: CssSizing; /** * The `inset-inline` CSS property defines the logical start and end offsets of an element * in the inline direction, which maps to physical offsets depending on the element's * * writing mode, directionality, and text orientation. It corresponds to the top and * bottom, or right and left properties depending on the values defined for writing-mode, * direction, and text-orientation. * * This inset property has no effect on non-positioned elements. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset-inline) */ "inset-inline"?: CssSizing | `${CssSizing} ${string}`; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset-inline-end) */ "inset-inline-end"?: CssSizing; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/inset-inline-start) */ "inset-inline-start"?: CssSizing; } //#endregion //#region ../types/src/string-literals/character-sets/css/align.d.ts type Positions$1 = "normal" | "start" | "center" | "end" | "flex-start" | "flex-end" | "baseline" | "first baseline" | "space-between" | "space-around" | "space-evenly" | "stretch" | "safe center" | "unsafe center" | CssGlobal; type CssAlignContent = Positions$1; type CssAlignItems = Positions$1 | "anchor-center"; type CssAlignSelf = Positions$1 | "anchor-center"; interface CssAlignProperties { /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/align-content) */ "align-content"?: CssAlignContent; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/align-items) */ "align-items"?: CssAlignItems; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/align-self) */ "align-self"?: CssAlignSelf; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/vertical-align) */ "vertical-align"?: "baseline" | "top" | "middle" | "bottom" | "sub" | "text-top"; } //#endregion //#region ../types/src/string-literals/character-sets/css/animation.d.ts type CssAnimationDelay = CssTiming; type Direction$1 = "normal" | "reverse" | "alternate" | "alternate-reverse"; type CssAnimationDirection = Direction$1 | `${Direction$1}${Opt$1<`, ${Direction$1}`>}` | `${Direction$1}${Opt$1<`, ${Direction$1}`>}${Opt$1<`, ${Direction$1}`>}${string}`; type FillMode = "none" | "forwards" | "backwards" | "both"; type CssAnimationFillMode = FillMode | `${FillMode}${Opt$1<`, ${FillMode}`>}` | `${FillMode}${Opt$1<`, ${FillMode}`>}${Opt$1<`, ${FillMode}`>}${string}`; type Composition = "replace" | "add" | "accumulate"; type CssAnimationComposition = Composition | `${Composition}${Opt$1<`, ${Composition}`>}` | `${Composition}${Opt$1<`, ${Composition}`>}${Opt$1<`, ${Composition}`>}${string}`; type TimingFunction = "ease" | "ease-in" | "ease-out" | "ease-in-out" | "linear" | "step-start" | "step-end" | `cubic-bezier(${string})` | `linear(${string})` | `steps(${string})`; type CssAnimationTimingFunction = TimingFunction | `${TimingFunction}${Opt$1<`, ${TimingFunction}`>}${string}`; type PlayState = "paused" | "running"; type CssAnimationPlayState = PlayState | `${PlayState}${Opt$1<`, ${PlayState}`>}` | `${PlayState}${Opt$1<`, ${PlayState}`>}${Opt$1<`, ${PlayState}`>}${string}`; interface CssAnimationProperties { /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation) */ "animation"?: string; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-composition) */ "animation-composition"?: CssAnimationComposition | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-delay) */ "animation-delay"?: CssAnimationDelay | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-direction) */ "animation-direction"?: CssAnimationDirection | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-fill-mode) */ "animation-fill-mode"?: CssAnimationFillMode | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-name) */ "animation-name"?: string; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-play-state) */ "animation-play-state"?: CssAnimationPlayState | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-range) */ "animation-range"?: string; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-range-end) */ "animation-range-end"?: string; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-range-start) */ "animation-range-start"?: string; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-timeline) */ "animation-timeline"?: string; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/animation-timing-function) */ "animation-timing-function"?: CssAnimationTimingFunction | CssGlobal; } //#endregion //#region ../types/src/string-literals/character-sets/css/background.d.ts interface CssBackgroundProperties { "background"?: string; "background-attachment"?: string; "background-blend-mode"?: string; "background-clip"?: string; "background-color"?: Suggest; "background-image"?: string; "background-origin"?: string; "background-position"?: string; "background-position-x"?: string; "background-position-y"?: string; "background-repeat"?: string; "background-size"?: CssSizing; } //#endregion //#region ../types/src/string-literals/character-sets/css/border.d.ts /** * CSS Border Styles * ([reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-style)) */ type CssBorderStyle = "none" | "hidden" | "dotted" | "dashed" | "solid" | "double" | "groove" | "ridge" | "inset" | "outset"; /** * CSS Border Width * ([reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-width)) */ type CssBorderWidth = "thin" | "medium" | "thick" | CssSizing; type CssBorderImageSource = `url(${string})` | `url(${string}) ${number}` | `url(${string}) ${number} space` | `linear-gradient(${string},${string}) ${number} / ${CssSizing}` | `url(${string}) ${number} ${number} / ${CssSizing} ${string} / ${string}` | CssGlobal; /** * **CssBorderCollapse** * * The border-collapse CSS property sets whether cells inside a have shared * or separate borders. * * - [reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-collapse) */ type CssBorderCollapse = "collapse" | "separate" | CssGlobal; /** * The border-image-repeat CSS property defines how the edge regions and * middle region of a source image are adjusted to fit the dimensions of * an element's border image. The middle region can be displayed by using * the keyword "fill" in the border-image-slice property. */ type CssBorderImageRepeat = "stretch" | "repeat" | "round" | "space"; type CssBorderInlineSizing = CssBorderStyle | CssSizing | `${CssSizing} ${CssBorderStyle}` | `${CssSizing} ${CssBorderStyle} ${string}`; type CssBorderProperties = { "border"?: string; /** * The border-spacing CSS property sets the distance between the borders of * adjacent cells in a
. * This property applies only when border-collapse is separate. */ "border-spacing"?: CssSizing | `${CssSizing} ${string}`; "border-radius"?: CssSizing | `${CssSizing} ${string}`; "border-collapse"?: CssBorderCollapse; /** * Formats: * - single * - two: `[top & bottom, left & right]` * - three: `[top, left & right, bottom]` * - four: `[top, left, right, bottom]` */ "border-style"?: CssBorderStyle | `${CssBorderStyle} ${CssBorderStyle}` | `${CssBorderStyle} ${CssBorderStyle} ${string}`; /** * Formats: * - single * - two: `[top & bottom, left & right]` * - three: `[top, left & right, bottom]` * - four: `[top, left, right, bottom]` */ "border-width"?: CssBorderWidth | `${CssBorderWidth} ${string}`; "border-image"?: CssBorderImageSource; /** * The `border-image-outset` CSS property sets the distance by which an * element's border image is set out from its border box. * * The parts of the border image that are rendered outside the element's * border box with `border-image-outset` do not trigger overflow scrollbars * and don't capture mouse events. */ "border-image-outset"?: CssSizing; /** * The border-image-repeat CSS property defines how the edge regions and * middle region of a source image are adjusted to fit the dimensions of * an element's border image. The middle region can be displayed by using * the keyword "fill" in the border-image-slice property. * * Format: * - use once for all edges * - use two -- `CssBorderImageRepeat` x 2 - for: `[ top & bottom, left & right ]` */ "border-image-repeat"?: CssBorderImageRepeat | `${CssBorderImageRepeat} ${CssBorderImageRepeat}`; /** * The `border-image-slice` CSS property divides the image specified by * `border-image-source` into regions. These regions form the components * of an element's border image. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-image-slice) */ "border-image-slice"?: `${number}` | `${number} fill`; "border-image-source"?: CssBorderImageSource | "none"; /** * The `border-end-end-radius` CSS property defines a logical border * radius on an element, which maps to a physical border radius * that depends on the element's writing-mode, direction, and * text-orientation. This is useful when building styles to work * regardless of the text orientation and writing mode. */ "border-end-end-radius"?: CssSizing; /** * The `border-end-start-radius` CSS property defines a logical border * radius on an element, which maps to a physical border radius depending * on the element's writing-mode, direction, and text-orientation. This is * useful when building styles to work regardless of the text orientation * and writing mode. */ "border-end-start-radius"?: CssSizing; /** * Formats: * - single * - two: `[top & bottom, left & right]` * - three: `[top, left & right, bottom]` * - four: `[top, left, right, bottom]` */ "border-color"?: CssColor | `${CssColor} ${string}`; /** * The border-block-color CSS property defines the color of the logical * block borders of an element, which maps to a physical border color * depending on the element's writing mode, directionality, and text * orientation */ "border-block-color"?: CssColor; /** * The border-block-end-color CSS property defines the color of the logical * block-end border of an element, which maps to a physical border color * depending on the element's writing mode, directionality, and text orientation. */ "border-block-end-color"?: CssColor; /** * The border-block-end-color CSS property defines the color of the logical * block-end border of an element, which maps to a physical border color * depending on the element's writing mode, directionality, and text * orientation. */ "border-block-start-color"?: CssColor; /** * The border-inline CSS property is a shorthand property for setting * the individual logical inline border property values in a single place * in the style sheet. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-inline) */ "border-inline"?: `${CssBorderWidth} ${string}` | `${CssColor} ${string}` | `${CssBorderStyle} ${string}`; "border-inline-style"?: CssBorderStyle; /** * The `border-inline-width` CSS property defines the width of the logical inline * borders of an element, which maps to a physical border width depending on the * element's writing mode, directionality, and text orientation. It corresponds to the * border-top-width and border-bottom-width, or border-left-width, and border-right-width * property depending on the values defined for writing-mode, direction, and text-orientation. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-inline-width) */ "border-inline-width"?: CssBorderWidth | `${CssBorderWidth} ${string}`; "border-inline-color"?: CssColor; "border-inline-start-style"?: CssBorderStyle; "border-inline-start-color"?: CssColor; "border-inline-start-width"?: CssBorderWidth; "border-inline-end-style"?: CssBorderStyle; "border-inline-end-color"?: CssColor; "border-inline-end-width"?: CssBorderWidth; "border-left"?: `${CssColor} ${string}` | `${CssBorderStyle} ${string}` | `${CssBorderWidth} ${string}`; "border-left-style"?: CssBorderStyle; "border-left-color"?: CssColor; "border-left-width"?: CssBorderWidth; "border-left-top-radius"?: CssSizing; "border-left-bottom-radius"?: CssSizing; "border-right"?: `${CssColor} ${string}` | `${CssBorderStyle} ${string}` | `${CssBorderWidth} ${string}`; "border-right-style"?: CssBorderStyle; "border-right-color"?: CssColor; "border-right-width"?: CssBorderWidth; "border-right-top-radius"?: CssSizing; "border-right-bottom-radius"?: CssSizing; "border-bottom"?: `${CssColor} ${string}` | `${CssBorderStyle} ${string}` | `${CssBorderWidth} ${string}`; "border-bottom-style"?: CssBorderStyle; "border-bottom-color"?: CssColor; "border-bottom-width"?: CssBorderWidth; "border-bottom-left-radius"?: CssSizing; "border-bottom-right-radius"?: CssSizing; "border-top"?: `${CssColor} ${string}` | `${CssBorderStyle} ${string}` | `${CssBorderWidth} ${string}`; "border-top-style"?: CssBorderStyle; "border-top-color"?: CssColor; "border-top-width"?: CssBorderWidth; "border-top-left-radius"?: CssSizing; "border-top-right-radius"?: CssSizing; /** * The `border-inline-end` CSS property is a shorthand property for setting the * individual logical inline-end border property values in a single place in * the style sheet. * * - [Refererence](https://developer.mozilla.org/en-US/docs/Web/CSS/border-inline-end) */ "border-inline-end"?: CssBorderInlineSizing; /** * The `border-inline-start` CSS property is a shorthand property for setting the * individual logical inline-start border property values in a single place in * the style sheet. * * - [Refererence](https://developer.mozilla.org/en-US/docs/Web/CSS/border-inline-start) */ "border-inline-start"?: CssBorderInlineSizing; } | { [key: `border-${string}`]: string; }; //#endregion //#region ../types/src/string-literals/character-sets/css/box.d.ts /** * [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/box-decoration-break) */ type CssBoxDecorationBreak = "slice" | "clone" | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/box-shadow) */ type CssBoxShadow = "none" | `inset ${string}${CssColorLight}` | `${CssSizingLight}${string}${CssColorLight}` | `${CssSizingLight}${string},${string}` | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/box-sizing) */ type CssBoxSizing = "border-box" | "content-box" | CssGlobal; interface CssBoxProperties { "box-decoration-break"?: CssBoxDecorationBreak; "box-shadow"?: CssBoxShadow; "box-sizing"?: CssBoxSizing; } //#endregion //#region ../types/src/string-literals/character-sets/css/break.d.ts type CssBreak = "auto" | "avoid" | "always" | "all" | "avoid-page" | "page" | "left" | "right" | "recto" | "verso" | "avoid-column" | "region" | CssGlobal; type CssBreakInside = "auto" | "avoid" | "avoid-page" | "avoid-column" | "avoid-region" | CssGlobal; interface CssBreakProperties { /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/break-after) */ "break-after"?: CssBreak; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/break-before) */ "break-before"?: CssBreak; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/break-inside) */ "break-inside"?: CssBreakInside; } //#endregion //#region ../types/src/string-literals/character-sets/css/color.d.ts type CssNamedColor = typeof CSS_NAMED_COLORS[number]; /** * Type lookup table with _keys_ of CSS Named Colors and _values_ * being the string `RgbColor` definition. */ type CssNamedColorLookup = typeof CSS_COLOR_LOOKUP; type CssColorSpace = "srgb" | "srgb-linear" | "display-p3" | "rec2020" | "a98-rgb" | "prophoto-rgb" | "xyz" | "xyz-d50" | "xyz-d65" | "hsl" | "hwb" | "lch" | "oklch"; /** * **CssRgb** * * CSS RGB colors (e.g., `rgb(123,86,255)`) */ type CssRgb = `rgb(${OptionalSpace}${number} ${number} ${number}${OptionalSpace})` | `rgb(${OptionalSpace}${number},${OptionalSpace}${number},${OptionalSpace}${number}${OptionalSpace})`; type CssRgba = `rgba(${number} ${number} ${number} ${number})` | `rgba(${number},${OptionalSpace}${number},${OptionalSpace}${number},${OptionalSpace}${number})`; /** * Hue, Saturation, and Lightness level (**HSL** color model) */ type CssHsl = `hsl(${number} ${number} ${number})` | `hsl(${number},${OptionalSpace}${number},${OptionalSpace}${number})`; /** * Hue, Saturation, and Brightness (**HSB** color model) */ type CssHsb = `hsb(${number} ${number} ${number})` | `hsb(${number},${OptionalSpace}${number},${OptionalSpace}${number})`; type OptionalPercent = "%" | ""; /** * [**CssOkLch**](https://oklch.com/)`(lightness, chroma, hue)` * * - Lightness is critical to **contrast** between _background_ and _foreground_ elements * - Saturation levels are seen in _chroma_ values. * - Hue distinguishes the actual color you're viewing */ type CssOkLch = `oklch(${number}${OptionalPercent} ${number}${OptionalPercent} ${number})`; /** * a hexadecimal color representation for CSS */ type CssHexColor = `#${HexadecimalChar}${HexadecimalChar}${string}`; type ColorFnValue = `${number}` | `${number}%` | "none"; type ColorFnOptOpacity = "" | ` / ${number}`; /** * **CssColor** * * Intended to represent _any_ CSS color value. */ type CssColor = CssNamedColor | CssHexColor | CssRgb | CssRgba | CssOkLch | CssHsb | CssHsl | "currentcolor" | `color(${string})`; type CssColorLight = CssNamedColor | `#${number}` | "currentcolor" | `${"rgb" | "rgba" | "hsb" | "hsl"}(${string})` | `color(${string})`; /** * The new CSS 4 `color(colorspace v1 v2 v3 [/ alpha])` function. * * **Related:** `CssColorSpace`, `ColorFnValue`, `ColorFnOptOpacity` */ type CssColorFn = `color(${TColorSpace} ${TV1} ${TV2} ${TV3})${TOp}` | `color(${CssColor} from ${TColorSpace} ${TV1} ${TV2} ${TV3})${TOp}`; //#endregion //#region ../types/src/string-literals/character-sets/css/definition.d.ts /** * **CssDefinition** * * Provides a means to define a CSS selector in a type strong manner. * * - each _key_ is a possible CSS property with a type definition provided to constrain it * - it is also indexed so that any property without a strong type definition can still be * added as a string value. */ type CssDefinition = { /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/appearance) */"appearance"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/backdrop-filter) */ "backdrop-filter"?: Suggest; /** * The valid values for the * [**display**](https://developer.mozilla.org/en-US/docs/Web/CSS/display) * property in CSS. */ "display"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/position) */ "position"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/aspect-ratio) */ "aspect-ratio"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/opacity) */ "opacity"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/gap) */ "gap"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/flex) */ "flex"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/flex-grow) */ "flex-grow"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/flex-shrink) */ "flex-shrink"?: CssFlexShrink; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/flex-direction) */ "flex-direction"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/flex-flow) */ "flex-flow"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/flex-basis) */ "flex-basis"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/float) */ "float"?: Suggest; /** * a union of valid values for the **CSS** [`list-style`](https://developer.mozilla.org/en-US/docs/Web/CSS/list-style) property. * * The list-style CSS shorthand property allows you to set all the list style properties * at once. */ "list-style"?: Suggest; /** * The block-size CSS property defines the horizontal or vertical size of an element's block, * depending on its writing mode. It corresponds to either the width or the height property, * depending on the value of writing-mode. * * If the writing mode is vertically oriented, the value of block-size relates to the width of * the element; otherwise, it relates to the height of the element. A related property is * inline-size, which defines the other dimension of the element. * /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/block-size) */ "block-size"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/border-size) */ "border-size"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/content) */ "content"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/color) */ "color"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/cursor) */ "cursor"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/height) */ "height"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/width) */ "width"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/perspective) */ "perspective"?: Suggest; "perspective-origin"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/mix-blend-mode) */ "mix-blend-mode"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/letter-spacing) */ "letter-spacing"?: Suggest; /** * The lighting-color CSS property defines the color of the light source for the * and SVG lighting filter primitives within an * SVG . If present, it overrides the element's lighting-color attribute. * * - [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/lighting-color) */ "lighting-color"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit) */ "object-fit"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/object-position) */ "object-position"?: Suggest; "order"?: Suggest<`${number}` | CssGlobal>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/image-orientation) */ "image-orientation"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/image-rendering) */ "image-rendering"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/image-resolution) */ "image-resolution"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/hanging-punction) */ "hanging-punctuation"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/min-height) */ "min-height"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/min-width) */ "min-width"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/min-block-size) */ "min-block-size"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/min-inline-size) */ "min-inline-size"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/stop-color) */ "stop-color"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/stop-opacity) */ "stop-opacity"?: Suggest<`${number}` | `${number}%` | CssGlobal>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/tab-size) */ "tab-size"?: Suggest<`${number}` | CssSizingLight | CssGlobal>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/table-layout) */ "table-layout"?: Suggest<"auto" | "fixed" | CssGlobal>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/translate) */ "translate"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/quotes) */ "quotes"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/r) */ "r"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/pointer-events) */ "pointer-events"?: string; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/resize) */ "resize"?: Suggest<"both" | "horizontal" | "vertical" | "none" | CssGlobal>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/rotate) */ "rotate"?: Suggest; "row-gap"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/rx) */ "rx"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/ry) */ "ry"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/x) */ "x"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/y) */ "y"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/white-space) */ "white-space"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/white-space-collapse) */ "white-space-collapse"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/widows) */ "widows"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/will-change) */ "will-change"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/word-break) */ "word-break"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/word-spacing) */ "word-spacing"?: Suggest<"normal" | CssSizing>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/writing-mode) */ "writing-mode"?: Suggest; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/z-index) */ "z-index"?: Suggest<`${number}` | "auto" | CssGlobal>; /** [MDN Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/zoom) */ "zoom"?: Suggest<`${number}` | `${number}%` | "normal" | "reset" | CssGlobal>; } & CssBorderProperties & CssBackgroundProperties & CssAbsolutionPositioningProperties & CssOffsetProperties & CssBreakProperties & CssBoxProperties & CssTextProperties & CssStrokeProperties & CssJustifyProperties & CssAlignProperties & CssPlaceProperties & CssAnimationProperties & CssMarginProperties & CssPaddingProperties & CssOutlineProperties & CssOverflowProperties & CssOffsetProperties & CssTransformProperties & CssFontProperties & { [key: string]: string; }; //#endregion //#region ../types/src/string-literals/character-sets/css/display-position.d.ts type Ratio = `${number}${OptionalSpace}/${OptionalSpace}${number}`; type One = `1`; type Special = "inherit" | "initial" | "revert" | "revert-layer" | "unset"; type Auto = "auto" | `auto ${Ratio}` | `${Ratio} auto`; /** * **CssAspectRatio** * * Allowed values for CSS's `aspect-ratio` property. */ type CssAspectRatio = Ratio | One | Special | Auto; /** * **CssPosition** * * The valid values for the `position` property in CSS. */ type CssPosition = "static" | "relative" | "absolute" | "fixed" | "sticky" | "inherit" | "initial" | "revert" | "revert-layer" | "unset"; /** * **CssDisplay** * * The valid values for the [**display**](https://developer.mozilla.org/en-US/docs/Web/CSS/display) * property in CSS. */ type CssDisplay = "block" | "flex" | "inline" | "inline-block" | "inline-flex" | "inline-grid" | "grid" | "flow-root" | "none" | "contents" | "block flex" | "block flow" | "block flow-root" | "block grid" | "inline flex" | "inline flow" | "inline flow-root" | "inline-grid" | "table" | "table-row" | "list-item" | CssGlobal; //#endregion //#region ../types/src/string-literals/character-sets/css/font.d.ts type CssFontFamily = `"${string}"` | "serif" | "san-serif" | "monospace" | "cursive" | "fantasy" | "system-ui" | "ui-serif" | "ui-sans-serif" | "ui-monospace" | "ui-rounded" | "emoji" | "math" | "fansong"; type CssFontFeatureSetting = "normal" | "liga" | "tnum" | "smcp"; type CssFontKerning = "auto" | "normal" | "none" | CssGlobal; type CssFontPalette = "normal" | "light" | "dark" | `--${string}` | `palette-mix(in ${ColorGamut},${string})`; type CssFontWidth = "normal" | "ultra-condensed" | "extra-condensed" | "condensed" | "semi-condensed" | "expanded" | "extra-expanded" | "ultra-expanded" | `${number}%` | CssGlobal; type CssFontStyle = "normal" | "italic" | "oblique" | `oblique ${CssRotation}` | CssGlobal; type CssFontSynthesis = "none" | "weight" | "style" | "position" | "small-caps"; type CssFontWeight = "normal" | "bold" | "100" | "200" | "300" | "400" | "500" | "600" | "700" | "800" | "900" | "lighter" | "bolder" | CssGlobal; /** * The font-language-override CSS property controls the use of language-specific glyphs in a typeface. * * By default, HTML's lang attribute tells browsers to display glyphs designed specifically * for that language. For example, a lot of fonts have a special character for the digraph * fi that merge the dot on the "i" with the "f." However, if the language is set to Turkish * the typeface will likely know not to use the merged glyph; Turkish has two versions of * the "i," one with a dot (i) and one without (ı), and using the ligature would incorrectly * transform a dotted "i" into a dotless "i." * * The font-language-override property lets you override the typeface behavior for a specific * language. This is useful, for example, when the typeface you're using lacks proper support * for the language. For instance, if a typeface doesn't have proper rules for the Azeri * language, you can force the font to use Turkish glyphs, which follow similar rules. */ type CssFontLanguageOverride = string; interface CssFontProperties { "font-family"?: CssFontFamily | `${CssFontFamily}, ${CssFontFamily}${string}` | CssGlobal; "font-feature-settings"?: CssFontFeatureSetting | `${CssFontFeatureSetting} ${number | "on" | "off"}` | `${CssFontFeatureSetting} ${number | "on" | "off"},${string}`; "font-kerning"?: CssFontKerning; "font-language-override"?: CssFontLanguageOverride; "font-size"?: CssSizing | "xx-small" | "x-small" | "small" | "medium" | "large" | "x-large" | "xx-large" | "xxx-large"; /** * The font-size-adjust CSS property provides a way to modify the size of lowercase * letters relative to the size of uppercase letters, which defines the overall * font-size. This property is useful for situations where font fallback can * occur. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size-adjust) */ "font-size-adjust"?: CssSizingLight | "none" | `${number}` | `from-font${Opt$1<` ${CssSizingLight}`>}` | `cap-height${Opt$1<` ${CssSizingLight}`>}` | `ex-height${Opt$1<` ${CssSizingLight}`>}` | `ch-width${Opt$1<` ${CssSizingLight}`>}` | `ic-width${Opt$1<` ${CssSizingLight}`>}` | `ic-height${Opt$1<` ${CssSizingLight}`>}`; /** * The font-palette CSS property allows specifying one of the many palettes contained in a * color font that a user agent may use for the font. Users can also override the values in * a palette or create a new palette by using the @font-palette-values at-rule. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/font-palette) */ "font-palette"?: CssFontPalette; /** * An alias for `font-width` */ "font-stretch"?: CssFontWidth; /** * The font-stretch CSS property selects a normal, condensed, or expanded face from a font. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/font-width) */ "font-width"?: CssFontWidth; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/font-style) */ "font-style"?: CssFontStyle; /** * The `font-synthesis` shorthand CSS property lets you specify whether or not the browser * may synthesize the bold, italic, small-caps, and/or subscript and superscript typefaces * when they are missing in the specified font-family. * * - [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/font-synthesis) */ "font-synthesis"?: CssFontSynthesis | `${CssFontSynthesis} ${CssFontSynthesis}` | `${CssFontSynthesis} ${CssFontSynthesis} ${CssFontSynthesis}${string}` | CssGlobal; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight) */ "font-weight"?: CssFontWeight; } //#endregion //#region ../types/src/string-literals/character-sets/css/global.d.ts type CssGlobal = "inherit" | "initial" | "revert" | "unset" | "revert-layer"; //#endregion //#region ../types/src/string-literals/character-sets/css/html-element.d.ts type HtmlTableElement = "col" | "colgroup" | "hgroup" | "table" | "tbody" | "td" | "tfoot" | "th" | "thead" | "time" | "tr"; type HtmlSymantecElement = "abbr" | "acronym" | "address" | "area" | "article" | "aside" | "blockquote" | "caption" | "cite" | "details" | "dfn" | "dialog" | "fieldset" | "figure" | "figcaption" | "header" | "footer" | "legend" | "nav" | "menu" | "search" | "summary" | "section"; type HtmlInputElement = "button" | "form" | "label" | "optgroup" | "option" | "select" | "input" | "textarea"; type HtmlFunctionalElement = "a" | "br" | "canvas" | "code" | "data" | "embed" | "em" | "font" | "hr" | "i" | "iframe" | "img" | "mark" | "strike" | "progress" | "p" | "picture" | "plaintext" | "pre"; type HtmlMediaElement = "audio" | "video"; type HtmlFrameworkElement = "template" | "slot"; type HtmlStructuralElement = "div" | `h${"1" | "2" | "3" | "4" | "5" | "6"}` | "frame" | "frameset" | "html" | "head" | "span"; type HtmlListElement = "li" | "ol" | "ul"; type HtmlBodyElement = "body" | "main" | HtmlListElement | HtmlStructuralElement | HtmlSymantecElement | HtmlMediaElement | HtmlInputElement | HtmlFunctionalElement | HtmlFrameworkElement | HtmlTableElement; //#endregion //#region ../types/src/string-literals/character-sets/css/justify.d.ts type CssJustifyContent = "center" | "start" | "end" | "flex-start" | "flex-end" | "left" | "right" | "normal" | "space-between" | "space-around" | "space-evenly" | "stretch" | "safe center" | "unsafe center" | CssGlobal; type Positions = "stretch" | "center" | "start" | "end" | "flex-start" | "flex-end" | "self-start" | "self-end" | "left" | "right" | "anchor-center" | "baseline" | "first baseline" | "last baseline" | "safe center" | "unsafe center" | "legacy left" | "legacy right" | "legacy center" | CssGlobal; type CssJustifyItems = Positions; type CssJustifySelf = Positions; interface CssJustifyProperties { /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/justify-content) */ "justify-content"?: CssJustifyContent; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/justify-items) */ "justify-items"?: CssJustifyItems; /** [Reference](https://developer.mozilla.org/en-US/docs/Web/CSS/justify-self) */ "justify-self"?: CssJustifySelf; } //#endregion //#region ../types/src/string-literals/character-sets/css/keyframe.d.ts /** * The _timestamp_ of a [CSS keyframe animation](https://developer.mozilla.org/en-US/docs/Web/CSS/@keyframes) * (e.g., "from", "to", "50%") */ type CssKeyframeTimestamp = "from" | "to" | `${number}%` | `${number}%${string},${number}%`; //#endregion //#region ../types/src/string-literals/character-sets/css/margin.d.ts type CssMargin = CssSizingLight | `${CssSizingLight}, ${CssSizingLight}${Opt$1<`, ${CssSizingLight}`>}${string}`; type CssMarginBlock = `${CssSizingLight}${Opt$1<`, ${CssSizingLight}`>}${string}`; type CssMarginBlockEnd = CssSizingLight; type CssMarginBlockStart = CssSizingLight; type CssMarginInline = `${CssSizingLight}${Opt$1<`, ${CssSizingLight}`>}${string}`; type CssMarginInlineEnd = CssSizingLight; type CssMarginInlineStart = CssSizingLight; type CssMarginLeft = CssSizingLight; type CssMarginRight = CssSizingLight; type CssMarginTop = CssSizingLight; type CssMarginBottom = CssSizingLight; interface CssMarginProperties { "margin"?: CssMargin; "margin-block"?: CssMarginBlock; "margin-block-end"?: CssMarginBlockEnd; "margin-block-start"?: CssMarginBlockStart; "margin-inline"?: CssMarginInline; "margin-inline-end"?: CssMarginInlineEnd; "margin-inline-start"?: CssMarginInlineStart; "margin-left"?: CssMarginLeft; "margin-right"?: CssMarginRight; "margin-top"?: CssMarginTop; "margin-bottom"?: CssMarginBottom; "margin-trim"?: string; } //#endregion //#region ../types/src/string-literals/character-sets/css/object.d.ts /** * **CssObjectFit** * * The [object-fit](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit) CSS property sets how the * content of a replaced element, such as an or