@stacksjs/types 0.66.0 → 0.68.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ai.d.ts +17 -14
- package/dist/analytics.d.ts +12 -14
- package/dist/api.d.ts +25 -66
- package/dist/app.d.ts +29 -134
- package/dist/auto-imports.d.ts +1 -1
- package/dist/binary.d.ts +7 -10
- package/dist/build.d.ts +2 -2
- package/dist/cache.d.ts +48 -61
- package/dist/cdn.d.ts +3 -15
- package/dist/chat.d.ts +2 -2
- package/dist/cli.d.ts +252 -238
- package/dist/cloud.d.ts +305 -68
- package/dist/components.d.ts +11 -59
- package/dist/configure.d.ts +11 -11
- package/dist/cron-jobs.d.ts +34 -41
- package/dist/database.d.ts +50 -45
- package/dist/dependencies.d.ts +15 -61
- package/dist/deploy.d.ts +10 -16
- package/dist/dns.d.ts +349 -167
- package/dist/docs.d.ts +20 -19
- package/dist/email.d.ts +15 -10
- package/dist/errors.d.ts +87 -69
- package/dist/events.d.ts +3 -30
- package/dist/exit-code.d.ts +4 -9
- package/dist/file-systems.d.ts +52 -56
- package/dist/git.d.ts +54 -126
- package/dist/hashing.d.ts +30 -97
- package/dist/helpers.d.ts +1 -1
- package/dist/i18n.d.ts +10 -18
- package/dist/index.d.ts +62 -61
- package/dist/index.js +1 -4
- package/dist/inspect.d.ts +3 -9
- package/dist/library.d.ts +798 -139
- package/dist/logging.d.ts +5 -27
- package/dist/manifest.d.ts +6 -9
- package/dist/model-names.d.ts +1 -1
- package/dist/model.d.ts +150 -130
- package/dist/notifications.d.ts +150 -105
- package/dist/pages.d.ts +10 -10
- package/dist/payments.d.ts +84 -55
- package/dist/ports.d.ts +13 -20
- package/dist/promise.d.ts +1 -1
- package/dist/push.d.ts +34 -30
- package/dist/pwa.d.ts +3 -7
- package/dist/queue.d.ts +36 -33
- package/dist/reactivity.d.ts +1 -1
- package/dist/request.d.ts +39 -26
- package/dist/router.d.ts +51 -51
- package/dist/saas.d.ts +32 -0
- package/dist/scheduler.d.ts +1 -1
- package/dist/search-engine.d.ts +85 -111
- package/dist/security.d.ts +18 -16
- package/dist/server.d.ts +16 -6
- package/dist/services.d.ts +34 -28
- package/dist/settings-config.d.ts +8 -8
- package/dist/ssg.d.ts +3 -2
- package/dist/stacks.d.ts +53 -203
- package/dist/storage.d.ts +29 -11
- package/dist/tables.d.ts +34 -52
- package/dist/team.d.ts +7 -8
- package/dist/ui.d.ts +39 -162
- package/dist/utils.d.ts +20 -30
- package/package.json +9 -10
- package/src/cache.ts +18 -0
- package/src/cli.ts +4 -0
- package/src/cloud.ts +16 -4
- package/src/errors.ts +8 -0
- package/src/index.ts +1 -0
- package/src/model-names.ts +1 -1
- package/src/model.ts +6 -0
- package/src/payments.ts +32 -0
- package/src/router.ts +1 -2
- package/src/saas.ts +33 -0
- package/src/stacks.ts +10 -0
- package/src/storage.ts +27 -0
- package/dist/env.d.ts +0 -0
- package/dist/index.js.map +0 -20
- package/dist/layout.d.ts +0 -0
- package/dist/native.d.ts +0 -0
- package/dist/sms.d.ts +0 -0
package/src/storage.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import type { ChecksumOptions, DirectoryListing, FileContents, MimeTypeOptions, PublicUrlOptions, StatEntry, TemporaryUrlOptions } from '@flystorage/file-storage'
|
|
2
|
+
import type { Buffer } from 'node:buffer'
|
|
3
|
+
|
|
1
4
|
export interface StorageOptions {
|
|
2
5
|
/**
|
|
3
6
|
* **Storage Driver**
|
|
@@ -11,3 +14,27 @@ export interface StorageOptions {
|
|
|
11
14
|
}
|
|
12
15
|
|
|
13
16
|
export type StorageConfig = Partial<StorageOptions>
|
|
17
|
+
|
|
18
|
+
export interface StorageDriver {
|
|
19
|
+
list: (path: string, options?: any) => DirectoryListing
|
|
20
|
+
changeVisibility: (path: string, visibility: string) => Promise<void>
|
|
21
|
+
visibility: (path: string) => Promise<string>
|
|
22
|
+
fileExists: (path: string) => Promise<boolean>
|
|
23
|
+
directoryExists: (path: string) => Promise<boolean>
|
|
24
|
+
publicUrl: (path: string, options: PublicUrlOptions) => Promise<string>
|
|
25
|
+
temporaryUrl: (path: string, options: TemporaryUrlOptions) => Promise<string>
|
|
26
|
+
checksum: (path: string, options: ChecksumOptions) => Promise<string>
|
|
27
|
+
mimeType: (path: string, options: MimeTypeOptions) => Promise<string>
|
|
28
|
+
lastModified: (path: string) => Promise<number>
|
|
29
|
+
fileSize: (path: string) => Promise<number>
|
|
30
|
+
read: (path: string) => Promise<FileContents>
|
|
31
|
+
readToString: (path: string) => Promise<string>
|
|
32
|
+
readToBuffer: (path: string) => Promise<Buffer>
|
|
33
|
+
readToUint8Array: (path: string) => Promise<Uint8Array>
|
|
34
|
+
deleteFile: (path: string) => Promise<void>
|
|
35
|
+
copyFile: (from: string, to: string) => Promise<void>
|
|
36
|
+
moveFile: (from: string, to: string) => Promise<void>
|
|
37
|
+
stat: (path: string) => Promise<StatEntry>
|
|
38
|
+
createDirectory: (path: string) => Promise<void>
|
|
39
|
+
write: (path: string, contents: FileContents) => Promise<void>
|
|
40
|
+
}
|
package/dist/env.d.ts
DELETED
|
File without changes
|
package/dist/index.js.map
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../node_modules/pluralize/pluralize.js", "../../../../../node_modules/slugify/slugify.js", "../src/cron-jobs.ts", "../src/docs.ts", "../src/exit-code.ts", "../../../../../node_modules/title-case/dist/index.js", "../../strings/src/helpers.ts", "../../strings/src/pluralize.ts", "../../strings/src/utils.ts", "../../strings/src/string.ts", "../src/helpers.ts"],
|
|
4
|
-
"sourcesContent": [
|
|
5
|
-
"/* global define */\n\n(function (root, pluralize) {\n /* istanbul ignore else */\n if (typeof require === 'function' && typeof exports === 'object' && typeof module === 'object') {\n // Node.\n module.exports = pluralize();\n } else if (typeof define === 'function' && define.amd) {\n // AMD, registers as an anonymous module.\n define(function () {\n return pluralize();\n });\n } else {\n // Browser global.\n root.pluralize = pluralize();\n }\n})(this, function () {\n // Rule storage - pluralize and singularize need to be run sequentially,\n // while other rules can be optimized using an object for instant lookups.\n var pluralRules = [];\n var singularRules = [];\n var uncountables = {};\n var irregularPlurals = {};\n var irregularSingles = {};\n\n /**\n * Sanitize a pluralization rule to a usable regular expression.\n *\n * @param {(RegExp|string)} rule\n * @return {RegExp}\n */\n function sanitizeRule (rule) {\n if (typeof rule === 'string') {\n return new RegExp('^' + rule + '$', 'i');\n }\n\n return rule;\n }\n\n /**\n * Pass in a word token to produce a function that can replicate the case on\n * another word.\n *\n * @param {string} word\n * @param {string} token\n * @return {Function}\n */\n function restoreCase (word, token) {\n // Tokens are an exact match.\n if (word === token) return token;\n\n // Lower cased words. E.g. \"hello\".\n if (word === word.toLowerCase()) return token.toLowerCase();\n\n // Upper cased words. E.g. \"WHISKY\".\n if (word === word.toUpperCase()) return token.toUpperCase();\n\n // Title cased words. E.g. \"Title\".\n if (word[0] === word[0].toUpperCase()) {\n return token.charAt(0).toUpperCase() + token.substr(1).toLowerCase();\n }\n\n // Lower cased words. E.g. \"test\".\n return token.toLowerCase();\n }\n\n /**\n * Interpolate a regexp string.\n *\n * @param {string} str\n * @param {Array} args\n * @return {string}\n */\n function interpolate (str, args) {\n return str.replace(/\\$(\\d{1,2})/g, function (match, index) {\n return args[index] || '';\n });\n }\n\n /**\n * Replace a word using a rule.\n *\n * @param {string} word\n * @param {Array} rule\n * @return {string}\n */\n function replace (word, rule) {\n return word.replace(rule[0], function (match, index) {\n var result = interpolate(rule[1], arguments);\n\n if (match === '') {\n return restoreCase(word[index - 1], result);\n }\n\n return restoreCase(match, result);\n });\n }\n\n /**\n * Sanitize a word by passing in the word and sanitization rules.\n *\n * @param {string} token\n * @param {string} word\n * @param {Array} rules\n * @return {string}\n */\n function sanitizeWord (token, word, rules) {\n // Empty string or doesn't need fixing.\n if (!token.length || uncountables.hasOwnProperty(token)) {\n return word;\n }\n\n var len = rules.length;\n\n // Iterate over the sanitization rules and use the first one to match.\n while (len--) {\n var rule = rules[len];\n\n if (rule[0].test(word)) return replace(word, rule);\n }\n\n return word;\n }\n\n /**\n * Replace a word with the updated word.\n *\n * @param {Object} replaceMap\n * @param {Object} keepMap\n * @param {Array} rules\n * @return {Function}\n */\n function replaceWord (replaceMap, keepMap, rules) {\n return function (word) {\n // Get the correct token and case restoration functions.\n var token = word.toLowerCase();\n\n // Check against the keep object map.\n if (keepMap.hasOwnProperty(token)) {\n return restoreCase(word, token);\n }\n\n // Check against the replacement map for a direct word replacement.\n if (replaceMap.hasOwnProperty(token)) {\n return restoreCase(word, replaceMap[token]);\n }\n\n // Run all the rules against the word.\n return sanitizeWord(token, word, rules);\n };\n }\n\n /**\n * Check if a word is part of the map.\n */\n function checkWord (replaceMap, keepMap, rules, bool) {\n return function (word) {\n var token = word.toLowerCase();\n\n if (keepMap.hasOwnProperty(token)) return true;\n if (replaceMap.hasOwnProperty(token)) return false;\n\n return sanitizeWord(token, token, rules) === token;\n };\n }\n\n /**\n * Pluralize or singularize a word based on the passed in count.\n *\n * @param {string} word The word to pluralize\n * @param {number} count How many of the word exist\n * @param {boolean} inclusive Whether to prefix with the number (e.g. 3 ducks)\n * @return {string}\n */\n function pluralize (word, count, inclusive) {\n var pluralized = count === 1\n ? pluralize.singular(word) : pluralize.plural(word);\n\n return (inclusive ? count + ' ' : '') + pluralized;\n }\n\n /**\n * Pluralize a word.\n *\n * @type {Function}\n */\n pluralize.plural = replaceWord(\n irregularSingles, irregularPlurals, pluralRules\n );\n\n /**\n * Check if a word is plural.\n *\n * @type {Function}\n */\n pluralize.isPlural = checkWord(\n irregularSingles, irregularPlurals, pluralRules\n );\n\n /**\n * Singularize a word.\n *\n * @type {Function}\n */\n pluralize.singular = replaceWord(\n irregularPlurals, irregularSingles, singularRules\n );\n\n /**\n * Check if a word is singular.\n *\n * @type {Function}\n */\n pluralize.isSingular = checkWord(\n irregularPlurals, irregularSingles, singularRules\n );\n\n /**\n * Add a pluralization rule to the collection.\n *\n * @param {(string|RegExp)} rule\n * @param {string} replacement\n */\n pluralize.addPluralRule = function (rule, replacement) {\n pluralRules.push([sanitizeRule(rule), replacement]);\n };\n\n /**\n * Add a singularization rule to the collection.\n *\n * @param {(string|RegExp)} rule\n * @param {string} replacement\n */\n pluralize.addSingularRule = function (rule, replacement) {\n singularRules.push([sanitizeRule(rule), replacement]);\n };\n\n /**\n * Add an uncountable word rule.\n *\n * @param {(string|RegExp)} word\n */\n pluralize.addUncountableRule = function (word) {\n if (typeof word === 'string') {\n uncountables[word.toLowerCase()] = true;\n return;\n }\n\n // Set singular and plural references for the word.\n pluralize.addPluralRule(word, '$0');\n pluralize.addSingularRule(word, '$0');\n };\n\n /**\n * Add an irregular word definition.\n *\n * @param {string} single\n * @param {string} plural\n */\n pluralize.addIrregularRule = function (single, plural) {\n plural = plural.toLowerCase();\n single = single.toLowerCase();\n\n irregularSingles[single] = plural;\n irregularPlurals[plural] = single;\n };\n\n /**\n * Irregular rules.\n */\n [\n // Pronouns.\n ['I', 'we'],\n ['me', 'us'],\n ['he', 'they'],\n ['she', 'they'],\n ['them', 'them'],\n ['myself', 'ourselves'],\n ['yourself', 'yourselves'],\n ['itself', 'themselves'],\n ['herself', 'themselves'],\n ['himself', 'themselves'],\n ['themself', 'themselves'],\n ['is', 'are'],\n ['was', 'were'],\n ['has', 'have'],\n ['this', 'these'],\n ['that', 'those'],\n // Words ending in with a consonant and `o`.\n ['echo', 'echoes'],\n ['dingo', 'dingoes'],\n ['volcano', 'volcanoes'],\n ['tornado', 'tornadoes'],\n ['torpedo', 'torpedoes'],\n // Ends with `us`.\n ['genus', 'genera'],\n ['viscus', 'viscera'],\n // Ends with `ma`.\n ['stigma', 'stigmata'],\n ['stoma', 'stomata'],\n ['dogma', 'dogmata'],\n ['lemma', 'lemmata'],\n ['schema', 'schemata'],\n ['anathema', 'anathemata'],\n // Other irregular rules.\n ['ox', 'oxen'],\n ['axe', 'axes'],\n ['die', 'dice'],\n ['yes', 'yeses'],\n ['foot', 'feet'],\n ['eave', 'eaves'],\n ['goose', 'geese'],\n ['tooth', 'teeth'],\n ['quiz', 'quizzes'],\n ['human', 'humans'],\n ['proof', 'proofs'],\n ['carve', 'carves'],\n ['valve', 'valves'],\n ['looey', 'looies'],\n ['thief', 'thieves'],\n ['groove', 'grooves'],\n ['pickaxe', 'pickaxes'],\n ['passerby', 'passersby']\n ].forEach(function (rule) {\n return pluralize.addIrregularRule(rule[0], rule[1]);\n });\n\n /**\n * Pluralization rules.\n */\n [\n [/s?$/i, 's'],\n [/[^\\u0000-\\u007F]$/i, '$0'],\n [/([^aeiou]ese)$/i, '$1'],\n [/(ax|test)is$/i, '$1es'],\n [/(alias|[^aou]us|t[lm]as|gas|ris)$/i, '$1es'],\n [/(e[mn]u)s?$/i, '$1s'],\n [/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i, '$1'],\n [/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i, '$1i'],\n [/(alumn|alg|vertebr)(?:a|ae)$/i, '$1ae'],\n [/(seraph|cherub)(?:im)?$/i, '$1im'],\n [/(her|at|gr)o$/i, '$1oes'],\n [/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i, '$1a'],\n [/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i, '$1a'],\n [/sis$/i, 'ses'],\n [/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i, '$1$2ves'],\n [/([^aeiouy]|qu)y$/i, '$1ies'],\n [/([^ch][ieo][ln])ey$/i, '$1ies'],\n [/(x|ch|ss|sh|zz)$/i, '$1es'],\n [/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i, '$1ices'],\n [/\\b((?:tit)?m|l)(?:ice|ouse)$/i, '$1ice'],\n [/(pe)(?:rson|ople)$/i, '$1ople'],\n [/(child)(?:ren)?$/i, '$1ren'],\n [/eaux$/i, '$0'],\n [/m[ae]n$/i, 'men'],\n ['thou', 'you']\n ].forEach(function (rule) {\n return pluralize.addPluralRule(rule[0], rule[1]);\n });\n\n /**\n * Singularization rules.\n */\n [\n [/s$/i, ''],\n [/(ss)$/i, '$1'],\n [/(wi|kni|(?:after|half|high|low|mid|non|night|[^\\w]|^)li)ves$/i, '$1fe'],\n [/(ar|(?:wo|[ae])l|[eo][ao])ves$/i, '$1f'],\n [/ies$/i, 'y'],\n [/\\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i, '$1ie'],\n [/\\b(mon|smil)ies$/i, '$1ey'],\n [/\\b((?:tit)?m|l)ice$/i, '$1ouse'],\n [/(seraph|cherub)im$/i, '$1'],\n [/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i, '$1'],\n [/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i, '$1sis'],\n [/(movie|twelve|abuse|e[mn]u)s$/i, '$1'],\n [/(test)(?:is|es)$/i, '$1is'],\n [/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i, '$1us'],\n [/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i, '$1um'],\n [/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i, '$1on'],\n [/(alumn|alg|vertebr)ae$/i, '$1a'],\n [/(cod|mur|sil|vert|ind)ices$/i, '$1ex'],\n [/(matr|append)ices$/i, '$1ix'],\n [/(pe)(rson|ople)$/i, '$1rson'],\n [/(child)ren$/i, '$1'],\n [/(eau)x?$/i, '$1'],\n [/men$/i, 'man']\n ].forEach(function (rule) {\n return pluralize.addSingularRule(rule[0], rule[1]);\n });\n\n /**\n * Uncountable rules.\n */\n [\n // Singular words with no plurals.\n 'adulthood',\n 'advice',\n 'agenda',\n 'aid',\n 'aircraft',\n 'alcohol',\n 'ammo',\n 'analytics',\n 'anime',\n 'athletics',\n 'audio',\n 'bison',\n 'blood',\n 'bream',\n 'buffalo',\n 'butter',\n 'carp',\n 'cash',\n 'chassis',\n 'chess',\n 'clothing',\n 'cod',\n 'commerce',\n 'cooperation',\n 'corps',\n 'debris',\n 'diabetes',\n 'digestion',\n 'elk',\n 'energy',\n 'equipment',\n 'excretion',\n 'expertise',\n 'firmware',\n 'flounder',\n 'fun',\n 'gallows',\n 'garbage',\n 'graffiti',\n 'hardware',\n 'headquarters',\n 'health',\n 'herpes',\n 'highjinks',\n 'homework',\n 'housework',\n 'information',\n 'jeans',\n 'justice',\n 'kudos',\n 'labour',\n 'literature',\n 'machinery',\n 'mackerel',\n 'mail',\n 'media',\n 'mews',\n 'moose',\n 'music',\n 'mud',\n 'manga',\n 'news',\n 'only',\n 'personnel',\n 'pike',\n 'plankton',\n 'pliers',\n 'police',\n 'pollution',\n 'premises',\n 'rain',\n 'research',\n 'rice',\n 'salmon',\n 'scissors',\n 'series',\n 'sewage',\n 'shambles',\n 'shrimp',\n 'software',\n 'species',\n 'staff',\n 'swine',\n 'tennis',\n 'traffic',\n 'transportation',\n 'trout',\n 'tuna',\n 'wealth',\n 'welfare',\n 'whiting',\n 'wildebeest',\n 'wildlife',\n 'you',\n /pok[eé]mon$/i,\n // Regexes.\n /[^aeiou]ese$/i, // \"chinese\", \"japanese\"\n /deer$/i, // \"deer\", \"reindeer\"\n /fish$/i, // \"fish\", \"blowfish\", \"angelfish\"\n /measles$/i,\n /o[iu]s$/i, // \"carnivorous\"\n /pox$/i, // \"chickpox\", \"smallpox\"\n /sheep$/i\n ].forEach(pluralize.addUncountableRule);\n\n return pluralize;\n});\n",
|
|
6
|
-
"\n;(function (name, root, factory) {\n if (typeof exports === 'object') {\n module.exports = factory()\n module.exports['default'] = factory()\n }\n /* istanbul ignore next */\n else if (typeof define === 'function' && define.amd) {\n define(factory)\n }\n else {\n root[name] = factory()\n }\n}('slugify', this, function () {\n var charMap = JSON.parse('{\"$\":\"dollar\",\"%\":\"percent\",\"&\":\"and\",\"<\":\"less\",\">\":\"greater\",\"|\":\"or\",\"¢\":\"cent\",\"£\":\"pound\",\"¤\":\"currency\",\"¥\":\"yen\",\"©\":\"(c)\",\"ª\":\"a\",\"®\":\"(r)\",\"º\":\"o\",\"À\":\"A\",\"Á\":\"A\",\"Â\":\"A\",\"Ã\":\"A\",\"Ä\":\"A\",\"Å\":\"A\",\"Æ\":\"AE\",\"Ç\":\"C\",\"È\":\"E\",\"É\":\"E\",\"Ê\":\"E\",\"Ë\":\"E\",\"Ì\":\"I\",\"Í\":\"I\",\"Î\":\"I\",\"Ï\":\"I\",\"Ð\":\"D\",\"Ñ\":\"N\",\"Ò\":\"O\",\"Ó\":\"O\",\"Ô\":\"O\",\"Õ\":\"O\",\"Ö\":\"O\",\"Ø\":\"O\",\"Ù\":\"U\",\"Ú\":\"U\",\"Û\":\"U\",\"Ü\":\"U\",\"Ý\":\"Y\",\"Þ\":\"TH\",\"ß\":\"ss\",\"à\":\"a\",\"á\":\"a\",\"â\":\"a\",\"ã\":\"a\",\"ä\":\"a\",\"å\":\"a\",\"æ\":\"ae\",\"ç\":\"c\",\"è\":\"e\",\"é\":\"e\",\"ê\":\"e\",\"ë\":\"e\",\"ì\":\"i\",\"í\":\"i\",\"î\":\"i\",\"ï\":\"i\",\"ð\":\"d\",\"ñ\":\"n\",\"ò\":\"o\",\"ó\":\"o\",\"ô\":\"o\",\"õ\":\"o\",\"ö\":\"o\",\"ø\":\"o\",\"ù\":\"u\",\"ú\":\"u\",\"û\":\"u\",\"ü\":\"u\",\"ý\":\"y\",\"þ\":\"th\",\"ÿ\":\"y\",\"Ā\":\"A\",\"ā\":\"a\",\"Ă\":\"A\",\"ă\":\"a\",\"Ą\":\"A\",\"ą\":\"a\",\"Ć\":\"C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\":\"o\",\"Ư\":\"U\",\"ư\":\"u\",\"Lj\":\"LJ\",\"lj\":\"lj\",\"Nj\":\"NJ\",\"nj\":\"nj\",\"Ș\":\"S\",\"ș\":\"s\",\"Ț\":\"T\",\"ț\":\"t\",\"ə\":\"e\",\"˚\":\"o\",\"Ά\":\"A\",\"Έ\":\"E\",\"Ή\":\"H\",\"Ί\":\"I\",\"Ό\":\"O\",\"Ύ\":\"Y\",\"Ώ\":\"W\",\"ΐ\":\"i\",\"Α\":\"A\",\"Β\":\"B\",\"Γ\":\"G\",\"Δ\":\"D\",\"Ε\":\"E\",\"Ζ\":\"Z\",\"Η\":\"H\",\"Θ\":\"8\",\"Ι\":\"I\",\"Κ\":\"K\",\"Λ\":\"L\",\"Μ\":\"M\",\"Ν\":\"N\",\"Ξ\":\"3\",\"Ο\":\"O\",\"Π\":\"P\",\"Ρ\":\"R\",\"Σ\":\"S\",\"Τ\":\"T\",\"Υ\":\"Y\",\"Φ\":\"F\",\"Χ\":\"X\",\"Ψ\":\"PS\",\"Ω\":\"W\",\"Ϊ\":\"I\",\"Ϋ\":\"Y\",\"ά\":\"a\",\"έ\":\"e\",\"ή\":\"h\",\"ί\":\"i\",\"ΰ\":\"y\",\"α\":\"a\",\"β\":\"b\",\"γ\":\"g\",\"δ\":\"d\",\"ε\":\"e\",\"ζ\":\"z\",\"η\":\"h\",\"θ\":\"8\",\"ι\":\"i\",\"κ\":\"k\",\"λ\":\"l\",\"μ\":\"m\",\"ν\":\"n\",\"ξ\":\"3\",\"ο\":\"o\",\"π\":\"p\",\"ρ\":\"r\",\"ς\":\"s\",\"σ\":\"s\",\"τ\":\"t\",\"υ\":\"y\",\"φ\":\"f\",\"χ\":\"x\",\"ψ\":\"ps\",\"ω\":\"w\",\"ϊ\":\"i\",\"ϋ\":\"y\",\"ό\":\"o\",\"ύ\":\"y\",\"ώ\":\"w\",\"Ё\":\"Yo\",\"Ђ\":\"DJ\",\"Є\":\"Ye\",\"І\":\"I\",\"Ї\":\"Yi\",\"Ј\":\"J\",\"Љ\":\"LJ\",\"Њ\":\"NJ\",\"Ћ\":\"C\",\"Џ\":\"DZ\",\"А\":\"A\",\"Б\":\"B\",\"В\":\"V\",\"Г\":\"G\",\"Д\":\"D\",\"Е\":\"E\",\"Ж\":\"Zh\",\"З\":\"Z\",\"И\":\"I\",\"Й\":\"J\",\"К\":\"K\",\"Л\":\"L\",\"М\":\"M\",\"Н\":\"N\",\"О\":\"O\",\"П\":\"P\",\"Р\":\"R\",\"С\":\"S\",\"Т\":\"T\",\"У\":\"U\",\"Ф\":\"F\",\"Х\":\"H\",\"Ц\":\"C\",\"Ч\":\"Ch\",\"Ш\":\"Sh\",\"Щ\":\"Sh\",\"Ъ\":\"U\",\"Ы\":\"Y\",\"Ь\":\"\",\"Э\":\"E\",\"Ю\":\"Yu\",\"Я\":\"Ya\",\"а\":\"a\",\"б\":\"b\",\"в\":\"v\",\"г\":\"g\",\"д\":\"d\",\"е\":\"e\",\"ж\":\"zh\",\"з\":\"z\",\"и\":\"i\",\"й\":\"j\",\"к\":\"k\",\"л\":\"l\",\"м\":\"m\",\"н\":\"n\",\"о\":\"o\",\"п\":\"p\",\"р\":\"r\",\"с\":\"s\",\"т\":\"t\",\"у\":\"u\",\"ф\":\"f\",\"х\":\"h\",\"ц\":\"c\",\"ч\":\"ch\",\"ш\":\"sh\",\"щ\":\"sh\",\"ъ\":\"u\",\"ы\":\"y\",\"ь\":\"\",\"э\":\"e\",\"ю\":\"yu\",\"я\":\"ya\",\"ё\":\"yo\",\"ђ\":\"dj\",\"є\":\"ye\",\"і\":\"i\",\"ї\":\"yi\",\"ј\":\"j\",\"љ\":\"lj\",\"њ\":\"nj\",\"ћ\":\"c\",\"ѝ\":\"u\",\"џ\":\"dz\",\"Ґ\":\"G\",\"ґ\":\"g\",\"Ғ\":\"GH\",\"ғ\":\"gh\",\"Қ\":\"KH\",\"қ\":\"kh\",\"Ң\":\"NG\",\"ң\":\"ng\",\"Ү\":\"UE\",\"ү\":\"ue\",\"Ұ\":\"U\",\"ұ\":\"u\",\"Һ\":\"H\",\"һ\":\"h\",\"Ә\":\"AE\",\"ә\":\"ae\",\"Ө\":\"OE\",\"ө\":\"oe\",\"Ա\":\"A\",\"Բ\":\"B\",\"Գ\":\"G\",\"Դ\":\"D\",\"Ե\":\"E\",\"Զ\":\"Z\",\"Է\":\"E\\'\",\"Ը\":\"Y\\'\",\"Թ\":\"T\\'\",\"Ժ\":\"JH\",\"Ի\":\"I\",\"Լ\":\"L\",\"Խ\":\"X\",\"Ծ\":\"C\\'\",\"Կ\":\"K\",\"Հ\":\"H\",\"Ձ\":\"D\\'\",\"Ղ\":\"GH\",\"Ճ\":\"TW\",\"Մ\":\"M\",\"Յ\":\"Y\",\"Ն\":\"N\",\"Շ\":\"SH\",\"Չ\":\"CH\",\"Պ\":\"P\",\"Ջ\":\"J\",\"Ռ\":\"R\\'\",\"Ս\":\"S\",\"Վ\":\"V\",\"Տ\":\"T\",\"Ր\":\"R\",\"Ց\":\"C\",\"Փ\":\"P\\'\",\"Ք\":\"Q\\'\",\"Օ\":\"O\\'\\'\",\"Ֆ\":\"F\",\"և\":\"EV\",\"ء\":\"a\",\"آ\":\"aa\",\"أ\":\"a\",\"ؤ\":\"u\",\"إ\":\"i\",\"ئ\":\"e\",\"ا\":\"a\",\"ب\":\"b\",\"ة\":\"h\",\"ت\":\"t\",\"ث\":\"th\",\"ج\":\"j\",\"ح\":\"h\",\"خ\":\"kh\",\"د\":\"d\",\"ذ\":\"th\",\"ر\":\"r\",\"ز\":\"z\",\"س\":\"s\",\"ش\":\"sh\",\"ص\":\"s\",\"ض\":\"dh\",\"ط\":\"t\",\"ظ\":\"z\",\"ع\":\"a\",\"غ\":\"gh\",\"ف\":\"f\",\"ق\":\"q\",\"ك\":\"k\",\"ل\":\"l\",\"م\":\"m\",\"ن\":\"n\",\"ه\":\"h\",\"و\":\"w\",\"ى\":\"a\",\"ي\":\"y\",\"ً\":\"an\",\"ٌ\":\"on\",\"ٍ\":\"en\",\"َ\":\"a\",\"ُ\":\"u\",\"ِ\":\"e\",\"ْ\":\"\",\"٠\":\"0\",\"١\":\"1\",\"٢\":\"2\",\"٣\":\"3\",\"٤\":\"4\",\"٥\":\"5\",\"٦\":\"6\",\"٧\":\"7\",\"٨\":\"8\",\"٩\":\"9\",\"پ\":\"p\",\"چ\":\"ch\",\"ژ\":\"zh\",\"ک\":\"k\",\"گ\":\"g\",\"ی\":\"y\",\"۰\":\"0\",\"۱\":\"1\",\"۲\":\"2\",\"۳\":\"3\",\"۴\":\"4\",\"۵\":\"5\",\"۶\":\"6\",\"۷\":\"7\",\"۸\":\"8\",\"۹\":\"9\",\"฿\":\"baht\",\"ა\":\"a\",\"ბ\":\"b\",\"გ\":\"g\",\"დ\":\"d\",\"ე\":\"e\",\"ვ\":\"v\",\"ზ\":\"z\",\"თ\":\"t\",\"ი\":\"i\",\"კ\":\"k\",\"ლ\":\"l\",\"მ\":\"m\",\"ნ\":\"n\",\"ო\":\"o\",\"პ\":\"p\",\"ჟ\":\"zh\",\"რ\":\"r\",\"ს\":\"s\",\"ტ\":\"t\",\"უ\":\"u\",\"ფ\":\"f\",\"ქ\":\"k\",\"ღ\":\"gh\",\"ყ\":\"q\",\"შ\":\"sh\",\"ჩ\":\"ch\",\"ც\":\"ts\",\"ძ\":\"dz\",\"წ\":\"ts\",\"ჭ\":\"ch\",\"ხ\":\"kh\",\"ჯ\":\"j\",\"ჰ\":\"h\",\"Ṣ\":\"S\",\"ṣ\":\"s\",\"Ẁ\":\"W\",\"ẁ\":\"w\",\"Ẃ\":\"W\",\"ẃ\":\"w\",\"Ẅ\":\"W\",\"ẅ\":\"w\",\"ẞ\":\"SS\",\"Ạ\":\"A\",\"ạ\":\"a\",\"Ả\":\"A\",\"ả\":\"a\",\"Ấ\":\"A\",\"ấ\":\"a\",\"Ầ\":\"A\",\"ầ\":\"a\",\"Ẩ\":\"A\",\"ẩ\":\"a\",\"Ẫ\":\"A\",\"ẫ\":\"a\",\"Ậ\":\"A\",\"ậ\":\"a\",\"Ắ\":\"A\",\"ắ\":\"a\",\"Ằ\":\"A\",\"ằ\":\"a\",\"Ẳ\":\"A\",\"ẳ\":\"a\",\"Ẵ\":\"A\",\"ẵ\":\"a\",\"Ặ\":\"A\",\"ặ\":\"a\",\"Ẹ\":\"E\",\"ẹ\":\"e\",\"Ẻ\":\"E\",\"ẻ\":\"e\",\"Ẽ\":\"E\",\"ẽ\":\"e\",\"Ế\":\"E\",\"ế\":\"e\",\"Ề\":\"E\",\"ề\":\"e\",\"Ể\":\"E\",\"ể\":\"e\",\"Ễ\":\"E\",\"ễ\":\"e\",\"Ệ\":\"E\",\"ệ\":\"e\",\"Ỉ\":\"I\",\"ỉ\":\"i\",\"Ị\":\"I\",\"ị\":\"i\",\"Ọ\":\"O\",\"ọ\":\"o\",\"Ỏ\":\"O\",\"ỏ\":\"o\",\"Ố\":\"O\",\"ố\":\"o\",\"Ồ\":\"O\",\"ồ\":\"o\",\"Ổ\":\"O\",\"ổ\":\"o\",\"Ỗ\":\"O\",\"ỗ\":\"o\",\"Ộ\":\"O\",\"ộ\":\"o\",\"Ớ\":\"O\",\"ớ\":\"o\",\"Ờ\":\"O\",\"ờ\":\"o\",\"Ở\":\"O\",\"ở\":\"o\",\"Ỡ\":\"O\",\"ỡ\":\"o\",\"Ợ\":\"O\",\"ợ\":\"o\",\"Ụ\":\"U\",\"ụ\":\"u\",\"Ủ\":\"U\",\"ủ\":\"u\",\"Ứ\":\"U\",\"ứ\":\"u\",\"Ừ\":\"U\",\"ừ\":\"u\",\"Ử\":\"U\",\"ử\":\"u\",\"Ữ\":\"U\",\"ữ\":\"u\",\"Ự\":\"U\",\"ự\":\"u\",\"Ỳ\":\"Y\",\"ỳ\":\"y\",\"Ỵ\":\"Y\",\"ỵ\":\"y\",\"Ỷ\":\"Y\",\"ỷ\":\"y\",\"Ỹ\":\"Y\",\"ỹ\":\"y\",\"–\":\"-\",\"‘\":\"\\'\",\"’\":\"\\'\",\"“\":\"\\\\\\\"\",\"”\":\"\\\\\\\"\",\"„\":\"\\\\\\\"\",\"†\":\"+\",\"•\":\"*\",\"…\":\"...\",\"₠\":\"ecu\",\"₢\":\"cruzeiro\",\"₣\":\"french franc\",\"₤\":\"lira\",\"₥\":\"mill\",\"₦\":\"naira\",\"₧\":\"peseta\",\"₨\":\"rupee\",\"₩\":\"won\",\"₪\":\"new shequel\",\"₫\":\"dong\",\"€\":\"euro\",\"₭\":\"kip\",\"₮\":\"tugrik\",\"₯\":\"drachma\",\"₰\":\"penny\",\"₱\":\"peso\",\"₲\":\"guarani\",\"₳\":\"austral\",\"₴\":\"hryvnia\",\"₵\":\"cedi\",\"₸\":\"kazakhstani tenge\",\"₹\":\"indian rupee\",\"₺\":\"turkish lira\",\"₽\":\"russian ruble\",\"₿\":\"bitcoin\",\"℠\":\"sm\",\"™\":\"tm\",\"∂\":\"d\",\"∆\":\"delta\",\"∑\":\"sum\",\"∞\":\"infinity\",\"♥\":\"love\",\"元\":\"yuan\",\"円\":\"yen\",\"﷼\":\"rial\",\"ﻵ\":\"laa\",\"ﻷ\":\"laa\",\"ﻹ\":\"lai\",\"ﻻ\":\"la\"}')\n var locales = JSON.parse('{\"bg\":{\"Й\":\"Y\",\"Ц\":\"Ts\",\"Щ\":\"Sht\",\"Ъ\":\"A\",\"Ь\":\"Y\",\"й\":\"y\",\"ц\":\"ts\",\"щ\":\"sht\",\"ъ\":\"a\",\"ь\":\"y\"},\"de\":{\"Ä\":\"AE\",\"ä\":\"ae\",\"Ö\":\"OE\",\"ö\":\"oe\",\"Ü\":\"UE\",\"ü\":\"ue\",\"ß\":\"ss\",\"%\":\"prozent\",\"&\":\"und\",\"|\":\"oder\",\"∑\":\"summe\",\"∞\":\"unendlich\",\"♥\":\"liebe\"},\"es\":{\"%\":\"por ciento\",\"&\":\"y\",\"<\":\"menor que\",\">\":\"mayor que\",\"|\":\"o\",\"¢\":\"centavos\",\"£\":\"libras\",\"¤\":\"moneda\",\"₣\":\"francos\",\"∑\":\"suma\",\"∞\":\"infinito\",\"♥\":\"amor\"},\"fr\":{\"%\":\"pourcent\",\"&\":\"et\",\"<\":\"plus petit\",\">\":\"plus grand\",\"|\":\"ou\",\"¢\":\"centime\",\"£\":\"livre\",\"¤\":\"devise\",\"₣\":\"franc\",\"∑\":\"somme\",\"∞\":\"infini\",\"♥\":\"amour\"},\"pt\":{\"%\":\"porcento\",\"&\":\"e\",\"<\":\"menor\",\">\":\"maior\",\"|\":\"ou\",\"¢\":\"centavo\",\"∑\":\"soma\",\"£\":\"libra\",\"∞\":\"infinito\",\"♥\":\"amor\"},\"uk\":{\"И\":\"Y\",\"и\":\"y\",\"Й\":\"Y\",\"й\":\"y\",\"Ц\":\"Ts\",\"ц\":\"ts\",\"Х\":\"Kh\",\"х\":\"kh\",\"Щ\":\"Shch\",\"щ\":\"shch\",\"Г\":\"H\",\"г\":\"h\"},\"vi\":{\"Đ\":\"D\",\"đ\":\"d\"},\"da\":{\"Ø\":\"OE\",\"ø\":\"oe\",\"Å\":\"AA\",\"å\":\"aa\",\"%\":\"procent\",\"&\":\"og\",\"|\":\"eller\",\"$\":\"dollar\",\"<\":\"mindre end\",\">\":\"større end\"},\"nb\":{\"&\":\"og\",\"Å\":\"AA\",\"Æ\":\"AE\",\"Ø\":\"OE\",\"å\":\"aa\",\"æ\":\"ae\",\"ø\":\"oe\"},\"it\":{\"&\":\"e\"},\"nl\":{\"&\":\"en\"},\"sv\":{\"&\":\"och\",\"Å\":\"AA\",\"Ä\":\"AE\",\"Ö\":\"OE\",\"å\":\"aa\",\"ä\":\"ae\",\"ö\":\"oe\"}}')\n\n function replace (string, options) {\n if (typeof string !== 'string') {\n throw new Error('slugify: string argument expected')\n }\n\n options = (typeof options === 'string')\n ? {replacement: options}\n : options || {}\n\n var locale = locales[options.locale] || {}\n\n var replacement = options.replacement === undefined ? '-' : options.replacement\n\n var trim = options.trim === undefined ? true : options.trim\n\n var slug = string.normalize().split('')\n // replace characters based on charMap\n .reduce(function (result, ch) {\n var appendChar = locale[ch];\n if (appendChar === undefined) appendChar = charMap[ch];\n if (appendChar === undefined) appendChar = ch;\n if (appendChar === replacement) appendChar = ' ';\n return result + appendChar\n // remove not allowed characters\n .replace(options.remove || /[^\\w\\s$*_+~.()'\"!\\-:@]+/g, '')\n }, '');\n\n if (options.strict) {\n slug = slug.replace(/[^A-Za-z0-9\\s]/g, '');\n }\n\n if (trim) {\n slug = slug.trim()\n }\n\n // Replace spaces with replacement character, treating multiple consecutive\n // spaces as a single space.\n slug = slug.replace(/\\s+/g, replacement);\n\n if (options.lower) {\n slug = slug.toLowerCase()\n }\n\n return slug\n }\n\n replace.extend = function (customMap) {\n Object.assign(charMap, customMap)\n }\n\n return replace\n}))\n",
|
|
7
|
-
"import type { IntRange } from '@stacksjs/scheduler'\n\n/**\n * Cron Job Options.\n */\nexport interface JobOptions {\n /**\n * The name of the job.\n */\n name?: string\n\n // eslint-disable-next-line ts/no-unsafe-function-type\n handle?: string | Function\n action?: string\n description?: string\n queue?: string\n timezone?: string\n /**\n * Number of tries. Must be between 0 and 185.\n */\n tries?: IntRange<0, 185>\n backoff?: number | number[]\n rate?: string | Every\n enabled?: boolean\n}\n\nexport type JobConfig = JobOptions\nexport type Job = JobOptions\nexport type Jobs = Job[]\nexport type CronJob = Job\nexport type CronJobs = Jobs\n\nexport enum Every {\n // Second = '* * * * * *',\n // FiveSeconds = '*/5 * * * * *',\n // TenSeconds = '*/10 * * * * *',\n // ThirtySeconds = '*/30 * * * * *',\n Minute = '* * * * *',\n TwoMinutes = '*/2 * * * *',\n FiveMinutes = '*/5 * * * *',\n TenMinutes = '*/10 * * * *',\n FifteenMinutes = '*/15 * * * *',\n ThirtyMinutes = '*/30 * * * *',\n Hour = '0 * * * *',\n HalfHour = '0,30 * * * *',\n Day = '0 0 * * *',\n Week = '0 0 * * 0',\n Weekday = '0 0 * * 1-5',\n Weekend = '0 0 * * 0,6',\n Month = '0 0 1 * *',\n Year = '0 0 1 1 *',\n}\n",
|
|
8
|
-
"import type { UserConfig } from 'vitepress'\n\nexport interface DocsUserConfig extends UserConfig {\n deploy: boolean\n}\n\nexport type DocsConfig = DocsUserConfig\nexport type DocsOptions = Partial<DocsConfig>\n\nexport interface SocialLink {\n icon: SocialLinkIcon\n link: string\n ariaLabel?: string\n}\n\nexport enum SocialLinkIcon {\n Discord = 'discord',\n Facebook = 'facebook',\n GitHub = 'github',\n Instagram = 'instagram',\n LinkedIn = 'linkedin',\n Mastodon = 'mastodon',\n Slack = 'slack',\n Twitter = 'twitter',\n YouTube = 'youtube',\n}\n",
|
|
9
|
-
"/**\n * CLI exit codes.\n *\n * @see https://nodejs.org/api/process.html#process_exit_codes\n */\nexport enum ExitCode {\n Success = 0,\n FatalError = 1,\n InvalidArgument = 9,\n}\n",
|
|
10
|
-
"const TOKENS = /(\\S+)|(.)/g;\nconst IS_SPECIAL_CASE = /[\\.#][\\p{L}\\p{N}]/u; // #tag, example.com, etc.\nconst IS_MANUAL_CASE = /\\p{Ll}(?=[\\p{Lu}])/u; // iPhone, iOS, etc.\nconst ALPHANUMERIC_PATTERN = /[\\p{L}\\p{N}]+/gu;\nconst IS_ACRONYM = /^([^\\p{L}])*(?:\\p{L}\\.){2,}([^\\p{L}])*$/u;\nexport const WORD_SEPARATORS = new Set([\"—\", \"–\", \"-\", \"―\", \"/\"]);\nexport const SENTENCE_TERMINATORS = new Set([\".\", \"!\", \"?\"]);\nexport const TITLE_TERMINATORS = new Set([\n ...SENTENCE_TERMINATORS,\n \":\",\n '\"',\n \"'\",\n \"”\",\n]);\nexport const SMALL_WORDS = new Set([\n \"a\",\n \"an\",\n \"and\",\n \"as\",\n \"at\",\n \"because\",\n \"but\",\n \"by\",\n \"en\",\n \"for\",\n \"if\",\n \"in\",\n \"neither\",\n \"nor\",\n \"of\",\n \"on\",\n \"only\",\n \"or\",\n \"over\",\n \"per\",\n \"so\",\n \"some\",\n \"than\",\n \"that\",\n \"the\",\n \"to\",\n \"up\",\n \"upon\",\n \"v\",\n \"versus\",\n \"via\",\n \"vs\",\n \"when\",\n \"with\",\n \"without\",\n \"yet\",\n]);\nexport function titleCase(input, options = {}) {\n const { locale = undefined, sentenceCase = false, sentenceTerminators = SENTENCE_TERMINATORS, titleTerminators = TITLE_TERMINATORS, smallWords = SMALL_WORDS, wordSeparators = WORD_SEPARATORS, } = typeof options === \"string\" || Array.isArray(options)\n ? { locale: options }\n : options;\n const terminators = sentenceCase ? sentenceTerminators : titleTerminators;\n let result = \"\";\n let isNewSentence = true;\n // tslint:disable-next-line\n for (const m of input.matchAll(TOKENS)) {\n const { 1: token, 2: whiteSpace, index = 0 } = m;\n if (whiteSpace) {\n result += whiteSpace;\n continue;\n }\n // Ignore URLs, email addresses, acronyms, etc.\n if (IS_SPECIAL_CASE.test(token)) {\n const acronym = token.match(IS_ACRONYM);\n // The period at the end of an acronym is not a new sentence,\n // but we should uppercase first for i.e., e.g., etc.\n if (acronym) {\n const [_, prefix = \"\", suffix = \"\"] = acronym;\n result +=\n sentenceCase && !isNewSentence\n ? token\n : upperAt(token, prefix.length, locale);\n isNewSentence = terminators.has(suffix.charAt(0));\n continue;\n }\n result += token;\n isNewSentence = terminators.has(token.charAt(token.length - 1));\n }\n else {\n const matches = Array.from(token.matchAll(ALPHANUMERIC_PATTERN));\n let value = token;\n let isSentenceEnd = false;\n for (let i = 0; i < matches.length; i++) {\n const { 0: word, index: wordIndex = 0 } = matches[i];\n const nextChar = token.charAt(wordIndex + word.length);\n isSentenceEnd = terminators.has(nextChar);\n // Always the capitalize first word and reset \"new sentence\".\n if (isNewSentence) {\n isNewSentence = false;\n }\n // Skip capitalizing all words if sentence case is enabled.\n else if (sentenceCase || IS_MANUAL_CASE.test(word)) {\n continue;\n }\n // Handle simple words.\n else if (matches.length === 1) {\n // Avoid capitalizing small words, except at the end of a sentence.\n if (smallWords.has(word)) {\n const isFinalToken = index + token.length === input.length;\n if (!isFinalToken && !isSentenceEnd) {\n continue;\n }\n }\n }\n // Multi-word tokens need to be parsed differently.\n else if (i > 0) {\n // Avoid capitalizing words without a valid word separator,\n // e.g. \"apple's\" or \"test(ing)\".\n if (!wordSeparators.has(token.charAt(wordIndex - 1))) {\n continue;\n }\n // Ignore small words in the middle of hyphenated words.\n if (smallWords.has(word) && wordSeparators.has(nextChar)) {\n continue;\n }\n }\n value = upperAt(value, wordIndex, locale);\n }\n result += value;\n isNewSentence =\n isSentenceEnd || terminators.has(token.charAt(token.length - 1));\n }\n }\n return result;\n}\nfunction upperAt(input, index, locale) {\n return (input.slice(0, index) +\n input.charAt(index).toLocaleUpperCase(locale) +\n input.slice(index + 1));\n}\n//# sourceMappingURL=index.js.map",
|
|
11
|
-
"export function toString(v: any): string {\n return Object.prototype.toString.call(v)\n}\n",
|
|
12
|
-
"import * as pluralize from 'pluralize'\n\ntype Rule = string | RegExp\ntype Replacement = string\ntype Word = string\nexport type PluralizeTest = (word: Word) => boolean\n\nexport interface Pluralize {\n plural: (word: Word, count?: number, inclusive?: boolean) => Word\n singular: (word: Word) => Word\n isPlural: (word: Word) => boolean\n isSingular: (word: Word) => boolean\n addPluralRule: (rule: Rule, replacement: Replacement) => void\n addSingularRule: (rule: Rule, replacement: Replacement) => void\n addIrregularRule: (single: Word, plural: Word) => void\n addUncountableRule: (word: Word | RegExp) => void\n}\n\nexport const plural: Pluralize['plural'] = (word, count, inclusive) => {\n if (count !== undefined && inclusive)\n return `${count} ${pluralize.plural(word)}`\n\n return pluralize.plural(word)\n}\n\nexport const singular: Pluralize['singular'] = word => pluralize.singular(word)\nexport const isPlural: Pluralize['isPlural'] = word => pluralize.isPlural(word)\nexport const isSingular: Pluralize['isSingular'] = word => pluralize.isSingular(word)\nexport const addPluralRule: Pluralize['addPluralRule'] = (rule, replacement) =>\n pluralize.addPluralRule(rule, replacement)\nexport const addSingularRule: Pluralize['addSingularRule'] = (rule, replacement) =>\n pluralize.addSingularRule(rule, replacement)\nexport const addIrregularRule: Pluralize['addIrregularRule'] = (single, plural) =>\n pluralize.addIrregularRule(single, plural)\nexport const addUncountableRule: Pluralize['addUncountableRule'] = word => pluralize.addUncountableRule(word)\n",
|
|
13
|
-
"import slugify from 'slugify'\n\ninterface SlugOptions {\n replacement?: string\n remove?: RegExp\n lower?: boolean\n strict?: boolean\n locale?: string\n trim?: boolean\n}\n\n// port from nanoid\n// https://github.com/ai/nanoid\nexport const urlAlphabet = 'useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict'\n\n/**\n * Replace backslash to slash\n *\n * @category String\n * @example\n * ```\n * slash('C:\\\\Users\\\\Chris') => 'C:/Users/Chris'\n * ```\n */\nexport function slash(str: string): string {\n return str.replace(/\\\\/g, '/')\n}\n\n/**\n * Ensure prefix of a string\n *\n * @category String\n * @example\n * ```\n * ensurePrefix('https://', 'google.com') => 'https://google.com'\n * ensurePrefix('https://', 'http://google.com') => 'https://google.com'\n */\nexport function ensurePrefix(prefix: string, str: string): string {\n if (!str.startsWith(prefix))\n return prefix + str\n return str\n}\n\n/**\n * Ensure suffix of a string\n *\n * @category String\n * @example\n * ```\n * ensureSuffix('.js', 'index') => 'index.js'\n * ensureSuffix('.js', 'index.js') => 'index.js'\n * ```\n */\nexport function ensureSuffix(suffix: string, str: string): string {\n return str.endsWith(suffix) ? str : str + suffix\n}\n\n/**\n * Dead simple template engine, just like Python's `.format()`\n *\n * @category String\n * @example\n * ```\n * const result = template('Hello {0}! My name is {1}.',\n * 'Buddy',\n * 'Chris'\n * ) // Hello Buddy! My name is Chris.\n * ```\n */\nexport function template(str: string, ...args: any[]): string {\n return str.replace(/\\{(\\d+)\\}/g, (match, key) => {\n const index = Number(key)\n\n return Number.isNaN(index) ? match : args[index]\n })\n}\n\nexport function truncate(str: string, length: number, end = '...'): string {\n if (str.length <= length)\n return str\n\n return str.slice(0, length - end.length) + end\n}\n\n/**\n * Generate a random string\n * @category String\n */\nexport function random(size = 16, dict: string = urlAlphabet): string {\n let id = ''\n let i = size\n const len = dict.length\n while (i--) id += dict[(Math.random() * len) | 0]\n return id\n}\n\n/**\n * Slugify a string\n * @category string\n * @example\n * ```\n * slug('Hello World') => 'hello-world'\n * ```\n */\nexport function slug(str: string, options?: SlugOptions): string {\n if (options)\n return slugify(str, options)\n\n return slugify(str, {\n lower: true,\n strict: true,\n })\n}\n\nexport { default as detectIndent } from 'detect-indent'\nexport { detectNewline } from 'detect-newline'\n",
|
|
14
|
-
"export * from './case'\nexport * from './helpers'\nexport * from './macro'\nexport * from './pluralize'\nexport * from './utils'\n\nexport { isString } from '@stacksjs/validation'\n",
|
|
15
|
-
"import { toString } from '@stacksjs/strings'\n\nexport function getTypeName(v: any): string {\n if (v === null)\n return 'null'\n const type = toString(v).slice(8, -1).toLowerCase()\n\n return typeof v === 'object' || typeof v === 'function' ? type : typeof v\n}\n"
|
|
16
|
-
],
|
|
17
|
-
"mappings": ";uYAEA,SAAU,CAAC,EAAM,EAAW,CAE1B,UAA4C,IAAY,iBAAmB,IAAW,SAEpF,EAAO,QAAU,EAAU,iBACX,SAAW,YAAc,OAAO,IAEhD,eAAgB,EAAG,CACjB,OAAO,EAAU,EAClB,MAGD,GAAK,UAAY,EAAU,IAE5B,UAAe,EAAG,CAGnB,IAAI,EAAc,CAAC,EACf,EAAgB,CAAC,EACjB,EAAe,CAAC,EAChB,EAAmB,CAAC,EACpB,EAAmB,CAAC,EAQxB,SAAS,CAAa,CAAC,EAAM,CAC3B,UAAW,IAAS,SAClB,OAAO,IAAI,OAAO,IAAM,EAAO,IAAK,GAAG,EAGzC,OAAO,EAWT,SAAS,CAAY,CAAC,EAAM,EAAO,CAEjC,GAAI,IAAS,EAAO,OAAO,EAG3B,GAAI,IAAS,EAAK,YAAY,EAAG,OAAO,EAAM,YAAY,EAG1D,GAAI,IAAS,EAAK,YAAY,EAAG,OAAO,EAAM,YAAY,EAG1D,GAAI,EAAK,KAAO,EAAK,GAAG,YAAY,EAClC,OAAO,EAAM,OAAO,CAAC,EAAE,YAAY,EAAI,EAAM,OAAO,CAAC,E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,EAAO,EAAK,QAAQ,OAAQ,CAAW,EAEnC,EAAQ,MACV,EAAO,EAAK,YAAY,EAG1B,OAAO,EAOT,OAJA,EAAQ,eAAkB,CAAC,EAAW,CACpC,OAAO,OAAO,EAAS,CAAS,GAG3B,EACR,ICpCM,IAAK,EAAL,EAAK,IAAL,CAKL,SAAS,YACT,aAAa,cACb,cAAc,cACd,aAAa,eACb,iBAAiB,eACjB,gBAAgB,eAChB,OAAO,YACP,WAAW,eACX,MAAM,YACN,OAAO,YACP,UAAU,cACV,UAAU,cACV,QAAQ,YACR,OAAO,cAlBG,QCjBL,IAAK,EAAL,EAAK,IAAL,CACL,UAAU,UACV,WAAW,WACX,SAAS,SACT,YAAY,YACZ,WAAW,WACX,WAAW,WACX,QAAQ,QACR,UAAU,UACV,UAAU,YATA,QCVL,IAAK,EAAL,EAAK,IAAL,CACL,YAAU,GAAV,UACA,eAAa,GAAb,aACA,oBAAkB,GAAlB,oBAHU,QCCL,IAAM,EAAuB,IAAI,IAAI,CAAC,IAAK,IAAK,GAAG,CAAC,EAC9C,GAAoB,IAAI,IAAI,CACrC,GAAG,EACH,IACA,IACA,IACA,QACJ,CAAC,ECbM,SAAS,CAAQ,CAAC,EAAgB,CACvC,OAAO,OAAO,UAAU,SAAS,KAAK,CAAC,ECDzC,eCAA,eCMA,mBAAS,8BCJF,SAAS,EAAW,CAAC,EAAgB,CAC1C,GAAI,IAAM,KACR,MAAO,OACT,MAAM,EAAO,EAAS,CAAC,EAAE,MAAM,EAAG,EAAE,EAAE,YAAY,EAElD,cAAc,IAAM,iBAAmB,IAAM,WAAa,SAAc",
|
|
18
|
-
"debugId": "8B4FA949DED5E05864756E2164756E21",
|
|
19
|
-
"names": []
|
|
20
|
-
}
|
package/dist/layout.d.ts
DELETED
|
File without changes
|
package/dist/native.d.ts
DELETED
|
File without changes
|
package/dist/sms.d.ts
DELETED
|
File without changes
|