Add settings page for managing forecasting API key and URL via UI
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
cae411eae7
commit
1c411e402e
19809 changed files with 1962608 additions and 97 deletions
41
frontend/node_modules/es-toolkit/dist/string/words.mjs
generated
vendored
Normal file
41
frontend/node_modules/es-toolkit/dist/string/words.mjs
generated
vendored
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
//#region src/string/words.ts
|
||||
/**
|
||||
* Regular expression pattern to split strings into words for various case conversions
|
||||
*
|
||||
* This pattern matches sequences of characters in a string, considering the following cases:
|
||||
* - Sequences of two or more uppercase letters followed by an uppercase letter and lowercase letters or digits (for acronyms)
|
||||
* - Sequences of one uppercase letter optionally followed by lowercase letters and digits
|
||||
* - Single uppercase letters
|
||||
* - Sequences of digits
|
||||
* - Emojis and other Unicode characters
|
||||
*
|
||||
* The resulting match can be used to convert camelCase, snake_case, kebab-case, and other mixed formats into
|
||||
* a consistent format like snake case. It also supports emojis and other Unicode characters.
|
||||
*
|
||||
* @example
|
||||
* const matches = 'camelCaseHTTPRequest🚀'.match(CASE_SPLIT_PATTERN);
|
||||
* // matches: ['camel', 'Case', 'HTTP', 'Request', '🚀']
|
||||
*/
|
||||
const CASE_SPLIT_PATTERN = /\p{Lu}?\p{Ll}+|[0-9]+|\p{Lu}+(?!\p{Ll})|\p{Emoji_Presentation}|\p{Extended_Pictographic}|\p{L}+/gu;
|
||||
/**
|
||||
* Splits `string` into an array of its words, treating spaces and punctuation marks as separators.
|
||||
*
|
||||
* @param str The string to inspect.
|
||||
* @param [pattern] The pattern to match words.
|
||||
* @returns Returns the words of `string`.
|
||||
*
|
||||
* @example
|
||||
* words('fred, barney, & pebbles');
|
||||
* // => ['fred', 'barney', 'pebbles']
|
||||
*
|
||||
* words('camelCaseHTTPRequest🚀');
|
||||
* // => ['camel', 'Case', 'HTTP', 'Request', '🚀']
|
||||
*
|
||||
* words('Lunedì 18 Set')
|
||||
* // => ['Lunedì', '18', 'Set']
|
||||
*/
|
||||
function words(str) {
|
||||
return Array.from(str.match(CASE_SPLIT_PATTERN) ?? []);
|
||||
}
|
||||
//#endregion
|
||||
export { words };
|
||||
Loading…
Add table
Add a link
Reference in a new issue