@dxtmisha/functional-basic 0.1.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.
Files changed (124) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +829 -0
  3. package/dist/classes/Api.d.ts +161 -0
  4. package/dist/classes/ApiDefault.d.ts +43 -0
  5. package/dist/classes/ApiHeaders.d.ts +23 -0
  6. package/dist/classes/ApiPreparation.d.ts +56 -0
  7. package/dist/classes/ApiResponse.d.ts +111 -0
  8. package/dist/classes/ApiStatus.d.ts +89 -0
  9. package/dist/classes/BroadcastMessage.d.ts +36 -0
  10. package/dist/classes/Cache.d.ts +34 -0
  11. package/dist/classes/CacheItem.d.ts +55 -0
  12. package/dist/classes/CacheStatic.d.ts +17 -0
  13. package/dist/classes/Cookie.d.ts +58 -0
  14. package/dist/classes/CookieBlock.d.ts +22 -0
  15. package/dist/classes/DataStorage.d.ts +82 -0
  16. package/dist/classes/Datetime.d.ts +482 -0
  17. package/dist/classes/EventItem.d.ts +160 -0
  18. package/dist/classes/Geo.d.ts +168 -0
  19. package/dist/classes/GeoFlag.d.ts +79 -0
  20. package/dist/classes/GeoIntl.d.ts +262 -0
  21. package/dist/classes/GeoPhone.d.ts +107 -0
  22. package/dist/classes/Global.d.ts +21 -0
  23. package/dist/classes/Hash.d.ts +59 -0
  24. package/dist/classes/Icons.d.ts +90 -0
  25. package/dist/classes/Loading.d.ts +49 -0
  26. package/dist/classes/Meta.d.ts +168 -0
  27. package/dist/classes/MetaManager.d.ts +103 -0
  28. package/dist/classes/MetaOg.d.ts +101 -0
  29. package/dist/classes/MetaTwitter.d.ts +101 -0
  30. package/dist/classes/ScrollbarWidth.d.ts +33 -0
  31. package/dist/classes/Translate.d.ts +116 -0
  32. package/dist/classes/__tests__/Api.test.d.ts +4 -0
  33. package/dist/classes/__tests__/ApiDefault.test.d.ts +1 -0
  34. package/dist/classes/__tests__/ApiHeaders.test.d.ts +1 -0
  35. package/dist/classes/__tests__/ApiPreparation.test.d.ts +1 -0
  36. package/dist/classes/__tests__/ApiResponse.test.d.ts +4 -0
  37. package/dist/classes/__tests__/ApiStatus.test.d.ts +1 -0
  38. package/dist/classes/__tests__/Meta.test.d.ts +4 -0
  39. package/dist/classes/__tests__/MetaManager.test.d.ts +4 -0
  40. package/dist/classes/__tests__/MetaOg.test.d.ts +4 -0
  41. package/dist/classes/__tests__/MetaTwitter.test.d.ts +4 -0
  42. package/dist/functions/anyToString.d.ts +7 -0
  43. package/dist/functions/applyTemplate.d.ts +10 -0
  44. package/dist/functions/arrFill.d.ts +8 -0
  45. package/dist/functions/copyObject.d.ts +8 -0
  46. package/dist/functions/createElement.d.ts +13 -0
  47. package/dist/functions/domQuerySelector.d.ts +7 -0
  48. package/dist/functions/domQuerySelectorAll.d.ts +7 -0
  49. package/dist/functions/encodeAttribute.d.ts +7 -0
  50. package/dist/functions/eventStopPropagation.d.ts +7 -0
  51. package/dist/functions/executeFunction.d.ts +8 -0
  52. package/dist/functions/executePromise.d.ts +7 -0
  53. package/dist/functions/forEach.d.ts +11 -0
  54. package/dist/functions/frame.d.ts +16 -0
  55. package/dist/functions/getAttributes.d.ts +8 -0
  56. package/dist/functions/getClipboardData.d.ts +11 -0
  57. package/dist/functions/getColumn.d.ts +10 -0
  58. package/dist/functions/getElement.d.ts +8 -0
  59. package/dist/functions/getElementId.d.ts +9 -0
  60. package/dist/functions/getElementItem.d.ts +11 -0
  61. package/dist/functions/getElementOrWindow.d.ts +8 -0
  62. package/dist/functions/getExp.d.ts +13 -0
  63. package/dist/functions/getItemByPath.d.ts +8 -0
  64. package/dist/functions/getKey.d.ts +7 -0
  65. package/dist/functions/getLengthOfAllArray.d.ts +8 -0
  66. package/dist/functions/getMaxLengthAllArray.d.ts +8 -0
  67. package/dist/functions/getMinLengthAllArray.d.ts +8 -0
  68. package/dist/functions/getMouseClient.d.ts +8 -0
  69. package/dist/functions/getMouseClientX.d.ts +7 -0
  70. package/dist/functions/getMouseClientY.d.ts +7 -0
  71. package/dist/functions/getObjectByKeys.d.ts +8 -0
  72. package/dist/functions/getObjectNoUndefined.d.ts +8 -0
  73. package/dist/functions/getObjectOrNone.d.ts +7 -0
  74. package/dist/functions/getRandomText.d.ts +11 -0
  75. package/dist/functions/getRequestString.d.ts +9 -0
  76. package/dist/functions/getStepPercent.d.ts +8 -0
  77. package/dist/functions/getStepValue.d.ts +8 -0
  78. package/dist/functions/goScroll.d.ts +10 -0
  79. package/dist/functions/inArray.d.ts +8 -0
  80. package/dist/functions/initScrollbarOffset.d.ts +6 -0
  81. package/dist/functions/intersectKey.d.ts +8 -0
  82. package/dist/functions/isArray.d.ts +7 -0
  83. package/dist/functions/isDifferent.d.ts +9 -0
  84. package/dist/functions/isDomRuntime.d.ts +10 -0
  85. package/dist/functions/isFilled.d.ts +9 -0
  86. package/dist/functions/isFloat.d.ts +7 -0
  87. package/dist/functions/isFunction.d.ts +8 -0
  88. package/dist/functions/isInDom.d.ts +8 -0
  89. package/dist/functions/isIntegerBetween.d.ts +8 -0
  90. package/dist/functions/isNull.d.ts +8 -0
  91. package/dist/functions/isNumber.d.ts +7 -0
  92. package/dist/functions/isObject.d.ts +7 -0
  93. package/dist/functions/isObjectNotArray.d.ts +7 -0
  94. package/dist/functions/isSelected.d.ts +8 -0
  95. package/dist/functions/isSelectedByList.d.ts +8 -0
  96. package/dist/functions/isString.d.ts +7 -0
  97. package/dist/functions/isWindow.d.ts +7 -0
  98. package/dist/functions/random.d.ts +8 -0
  99. package/dist/functions/replaceRecursive.d.ts +10 -0
  100. package/dist/functions/replaceTemplate.d.ts +9 -0
  101. package/dist/functions/secondToTime.d.ts +7 -0
  102. package/dist/functions/setElementItem.d.ts +10 -0
  103. package/dist/functions/setValues.d.ts +17 -0
  104. package/dist/functions/splice.d.ts +12 -0
  105. package/dist/functions/strFill.d.ts +8 -0
  106. package/dist/functions/toArray.d.ts +17 -0
  107. package/dist/functions/toCamelCase.d.ts +7 -0
  108. package/dist/functions/toCamelCaseFirst.d.ts +7 -0
  109. package/dist/functions/toDate.d.ts +7 -0
  110. package/dist/functions/toKebabCase.d.ts +15 -0
  111. package/dist/functions/toNumber.d.ts +8 -0
  112. package/dist/functions/toNumberByMax.d.ts +9 -0
  113. package/dist/functions/toPercent.d.ts +8 -0
  114. package/dist/functions/toPercentBy100.d.ts +8 -0
  115. package/dist/functions/transformation.d.ts +21 -0
  116. package/dist/functions/uniqueArray.d.ts +7 -0
  117. package/dist/functions/writeClipboardData.d.ts +7 -0
  118. package/dist/library.d.ts +109 -0
  119. package/dist/library.js +4916 -0
  120. package/dist/types/apiTypes.d.ts +116 -0
  121. package/dist/types/basicTypes.d.ts +126 -0
  122. package/dist/types/geoTypes.d.ts +86 -0
  123. package/dist/types/metaTypes.d.ts +584 -0
  124. package/package.json +68 -0
@@ -0,0 +1,160 @@
1
+ import { ElementOrString, ElementOrWindow, EventActivityItem, EventListenerDetail, EventOptions } from '../types/basicTypes';
2
+ /**
3
+ * Class for working with events.
4
+ *
5
+ * Класс для работы с событиями.
6
+ */
7
+ export declare class EventItem<E extends ElementOrWindow, O extends Event, D extends Record<string, any> = Record<string, any>> {
8
+ protected listener?: EventListenerDetail<O, D> | undefined;
9
+ protected options?: EventOptions;
10
+ protected detail?: D | undefined;
11
+ /**
12
+ * Element.
13
+ *
14
+ * Элемент.
15
+ */
16
+ protected element?: E;
17
+ /**
18
+ * Element for checking. If the element is missing in the DOM, the event is turned off.
19
+ *
20
+ * Элемент для проверки. Если элемент отсутствует в DOM, событие выключается.
21
+ */
22
+ protected elementControl?: ElementOrWindow;
23
+ protected elementControlEdit?: boolean;
24
+ /**
25
+ * A case-sensitive string representing the event type to listen for.
26
+ *
27
+ * Чувствительная к регистру строка, представляющая тип обрабатываемого события.
28
+ */
29
+ protected type: string[];
30
+ /**
31
+ * The object that receives a notification (an object that implements the Event interface)
32
+ * when an event of the specified type occurs. This must be null, an object with a
33
+ * handleEvent() method, or a JavaScript function.
34
+ *
35
+ * Объект, который принимает уведомление, когда событие указанного типа произошло.
36
+ * Это должен быть объект, реализующий интерфейс EventListener или просто функция JavaScript.
37
+ */
38
+ protected listenerRecent: (event?: O | ResizeObserverEntry) => void;
39
+ /**
40
+ * Event states.
41
+ *
42
+ * Состояния события.
43
+ */
44
+ protected activity: boolean;
45
+ protected activityItems: EventActivityItem<E>[];
46
+ /**
47
+ * Classes Constructor
48
+ * @param elementSelector element/ элемент
49
+ * @param type type/ тип
50
+ * @param listener the object that receives a notification (an object that implements the
51
+ * Event interface) when an event of the specified type occurs/ объект, который принимает
52
+ * уведомление, когда событие указанного типа произошло
53
+ * @param options object that specifies characteristics/ объект options
54
+ * @param detail an event-dependent value associated with the event/ зависимое от события
55
+ * значение, связанное с событием
56
+ */
57
+ constructor(elementSelector?: ElementOrString<E>, type?: string | string[], listener?: EventListenerDetail<O, D> | undefined, options?: EventOptions, detail?: D | undefined);
58
+ /**
59
+ * Checks whether event listening is currently enabled.
60
+ *
61
+ * Проверяет, включено ли сейчас прослушивание события.
62
+ */
63
+ isActive(): boolean;
64
+ getElement(): E | undefined;
65
+ /**
66
+ * Change of an element for tracking.
67
+ *
68
+ * Изменение элемента для прослеживания.
69
+ * @param elementSelector element/ элемент
70
+ */
71
+ setElement(elementSelector?: ElementOrString<E>): this;
72
+ /**
73
+ * Modifies the object that receives the notification.
74
+ *
75
+ * Модифицирует объект, который получает уведомление.
76
+ * @param elementSelector element/ элемент
77
+ */
78
+ setElementControl<EC extends HTMLElement>(elementSelector?: ElementOrString<EC>): this;
79
+ /**
80
+ * Changes the type of the handled event.
81
+ *
82
+ * Изменяет тип обрабатываемого события.
83
+ * @param type type/ тип
84
+ */
85
+ setType(type: string | string[]): this;
86
+ /**
87
+ * Modifies the object that receives the notification.
88
+ *
89
+ * Модифицирует объект, который получает уведомление.
90
+ * @param listener
91
+ */
92
+ setListener(listener: EventListenerDetail<O, D>): this;
93
+ /**
94
+ * Modifying the options object that defines the characteristics of an object.
95
+ *
96
+ * Изменение объекта options, который определяет характеристики объекта.
97
+ * @param options
98
+ */
99
+ setOptions(options?: EventOptions): this;
100
+ /**
101
+ * Modifying a dependent value for the dispatch method.
102
+ *
103
+ * Изменение зависимого значения для метода dispatch.
104
+ * @param detail
105
+ */
106
+ setDetail(detail?: D): this;
107
+ /**
108
+ * The method of the EventTarget sends an Event to the object, (synchronously) invoking
109
+ * the affected EventListeners in the appropriate order.
110
+ *
111
+ * Отправляет событие в общую систему событий. Это событие подчиняется тем же правилам
112
+ * поведения "Захвата" и "Всплывания" как и непосредственно инициированные события.
113
+ * @param detail an event-dependent value associated with the event/ зависимое от события
114
+ * значение, связанное с событием
115
+ */
116
+ dispatch(detail?: D | undefined): this;
117
+ /**
118
+ * Starting event listening.
119
+ *
120
+ * Запуск прослушивания события.
121
+ */
122
+ start(): this;
123
+ /**
124
+ * Stopping event listening.
125
+ *
126
+ * Остановка прослушивания события.
127
+ */
128
+ stop(): this;
129
+ /**
130
+ * Toggling event handler state.
131
+ *
132
+ * Переключение состояния работы события.
133
+ * @param activity event activation/ активация события
134
+ */
135
+ toggle(activity: boolean): this;
136
+ /**
137
+ * Overloads the listening events.
138
+ *
139
+ * Перегружает события прослушивания.
140
+ */
141
+ reset(): this;
142
+ /**
143
+ * Checks if the ResizeObserver object exists.
144
+ *
145
+ * Проверяет, существует ли объект ResizeObserver.
146
+ */
147
+ protected isObserver(): boolean;
148
+ /**
149
+ * The implementation of the resize event for an element.
150
+ *
151
+ * Реализация события изменения размера для элемента.
152
+ */
153
+ protected makeResize(): boolean;
154
+ /**
155
+ * Implementation of the scroll event for an element.
156
+ *
157
+ * Реализация события изменения положения скролла для элемента.
158
+ */
159
+ protected makeScroll(): boolean;
160
+ }
@@ -0,0 +1,168 @@
1
+ import { GeoItem, GeoItemFull } from '../types/geoTypes';
2
+ /**
3
+ * Base class for working with geographic data.
4
+ *
5
+ * Базовый класс для работы с географическими данными.
6
+ */
7
+ export declare class Geo {
8
+ private static storage;
9
+ private static location;
10
+ private static item;
11
+ private static language;
12
+ private static timezone;
13
+ /**
14
+ * Information about the current country.
15
+ *
16
+ * Информация об текущей стране.
17
+ */
18
+ static get(): GeoItemFull;
19
+ /**
20
+ * Current country.
21
+ *
22
+ * Текущая страна.
23
+ */
24
+ static getCountry(): string;
25
+ /**
26
+ * Current language.
27
+ *
28
+ * Текущий язык.
29
+ */
30
+ static getLanguage(): string;
31
+ /**
32
+ * Full format according to the standard.
33
+ *
34
+ * Полный формат согласно стандарту.
35
+ */
36
+ static getStandard(): string;
37
+ /**
38
+ * Returns the first day of the week.
39
+ *
40
+ * Возвращает первый день недели.
41
+ */
42
+ static getFirstDay(): string;
43
+ /**
44
+ * Full format.
45
+ *
46
+ * Полный формат.
47
+ */
48
+ static getLocation(): string;
49
+ /**
50
+ * Obtaining processed data.
51
+ *
52
+ * Получение обработанных данных.
53
+ */
54
+ static getItem(): GeoItemFull;
55
+ /**
56
+ * Returns the full list of countries.
57
+ *
58
+ * Возвращает полный список стран.
59
+ */
60
+ static getList(): GeoItem[];
61
+ /**
62
+ * Returns the data about the country by its full code.
63
+ *
64
+ * Возвращает данные о стране по ее полному коду.
65
+ * @param code country code, full form language-country or one of them/
66
+ * код страны, полный вид язык-страна или один из них
67
+ */
68
+ static getByCode(code?: string): GeoItemFull;
69
+ /**
70
+ * Returns the full data by language and country.
71
+ *
72
+ * Возвращает полные данные по языку и стране.
73
+ * @param code string in the form of language-country/ строка в виде язык-страна
74
+ */
75
+ static getByCodeFull(code: string): GeoItem | undefined;
76
+ /**
77
+ * Returns the full data by country.
78
+ *
79
+ * Возвращает полные данные по стране.
80
+ * @param country country/ страна
81
+ */
82
+ static getByCountry(country: string): GeoItem | undefined;
83
+ /**
84
+ * Returns the full data by language.
85
+ *
86
+ * Возвращает полные данные по языку.
87
+ * @param language language/ язык
88
+ */
89
+ static getByLanguage(language: string): GeoItem | undefined;
90
+ /**
91
+ * Retrieving the default timezone.
92
+ *
93
+ * Получение временной зоны по умолчанию
94
+ */
95
+ static getTimezone(): number;
96
+ /**
97
+ * Retrieving the default timezone (formatted view).
98
+ *
99
+ * Получение временной зоны по умолчанию (отформатированный вид).
100
+ */
101
+ static getTimezoneFormat(): string;
102
+ /**
103
+ * Determines the current country by its full name.
104
+ *
105
+ * Определяет текущую страну по ее полному названию.
106
+ * @param code country code, full form language-country or one of them/
107
+ * код страны, полный вид язык-страна или один из них
108
+ */
109
+ static find(code: string): GeoItemFull;
110
+ /**
111
+ * Returns a complete string with the country code and language.
112
+ *
113
+ * Возвращает полную строку с кодом страны и языка.
114
+ * @param item object with data about the current country/
115
+ * объект с данными об текущей стране
116
+ */
117
+ static toStandard(item: GeoItem): string;
118
+ /**
119
+ * Changes the data by the full code.
120
+ *
121
+ * Изменяет данные по полному коду.
122
+ * @param code country code, full form language-country or one of them/
123
+ * код страны, полный вид язык-страна или один из них
124
+ * @param save save the result/ сохранить результат
125
+ */
126
+ static set(code: string, save?: boolean): void;
127
+ /**
128
+ * Changing the default timezone for transmitted dates.
129
+ *
130
+ * Изменение временной зоны по умолчанию для отправляемых дат
131
+ * @param timezone new time zone/ новая временная зона
132
+ */
133
+ static setTimezone(timezone: number): void;
134
+ /**
135
+ * Determines the current location.
136
+ *
137
+ * Определяет текущую локацию.
138
+ */
139
+ private static findLocation;
140
+ /**
141
+ * Determines the current language.
142
+ *
143
+ * Определяет текущий язык.
144
+ * @param code country code, full form language-country or one of them/
145
+ * код страны, полный вид язык-страна или один из них
146
+ */
147
+ private static findLanguage;
148
+ /**
149
+ * Returns the country code by its full language-country.
150
+ *
151
+ * Возвращает код страны по ее полному язык-страна.
152
+ * @param code country code/ код страна
153
+ */
154
+ private static toCountry;
155
+ /**
156
+ * Returns the language code by its full language-country.<br>
157
+ * Возвращает код языка по его полному язык-страна.
158
+ * @param code country code/ код страна
159
+ */
160
+ private static toLanguage;
161
+ /**
162
+ * Adding missing data.<br>
163
+ * Добавление недостающих данных.
164
+ * @param item object with data about the current country/
165
+ * объект с данными об текущей стране
166
+ */
167
+ private static toFull;
168
+ }
@@ -0,0 +1,79 @@
1
+ import { GeoIntl } from './GeoIntl';
2
+ import { GeoFlagItem, GeoFlagNational, GeoItemFull } from '../types/geoTypes';
3
+ export declare const GEO_FLAG_ICON_NAME = "@flag";
4
+ /**
5
+ * Class for working with Flags.
6
+ *
7
+ * Класс для работы с Флагами.
8
+ */
9
+ export declare class GeoFlag {
10
+ protected code: string;
11
+ static flags: Record<string, string>;
12
+ /**
13
+ * Constructor
14
+ * @param code country and language code/ код страны и языка
15
+ */
16
+ constructor(code?: string);
17
+ /**
18
+ * Returns information about the country and its flag.
19
+ *
20
+ * Возвращает информацию о стране и её флаге.
21
+ * @param code country code/ код страны
22
+ */
23
+ get(code?: string): GeoFlagItem | undefined;
24
+ /**
25
+ * Getting a link to the flag.
26
+ *
27
+ * Получение ссылки на флаг.
28
+ * @param code country code/ код страны
29
+ */
30
+ getFlag(code?: string): string | undefined;
31
+ /**
32
+ * Getting a list of countries by an array of codes.
33
+ *
34
+ * Получение списка стран по массиву с кодами.
35
+ * @param codes country code/ код страны
36
+ */
37
+ getList(codes?: string[]): GeoFlagItem[];
38
+ /**
39
+ * Getting a list of countries by an array of codes in national language.
40
+ *
41
+ * Получение списка стран по массиву с кодами на национальный язык.
42
+ * @param codes country code/ код страны.
43
+ */
44
+ getNational(codes?: string[]): GeoFlagNational[];
45
+ /**
46
+ * To change the location.
47
+ *
48
+ * Изменить местоположение.
49
+ * @param code country and language code/ код страны и языка
50
+ */
51
+ setCode(code: string): this;
52
+ /**
53
+ * Returns a special object for formatting.
54
+ *
55
+ * Возвращает специальный объект для работы с форматированием.
56
+ */
57
+ protected getLocation(): GeoIntl;
58
+ /**
59
+ * Returns a list of countries to retrieve data from.
60
+ *
61
+ * Возвращает список стран для получения данных.
62
+ * @param codes country code/ код страны
63
+ */
64
+ protected getCodes(codes?: string[]): string[];
65
+ /**
66
+ * Getting the name of the language.
67
+ *
68
+ * Получение названия языка.
69
+ * @param data object with information of data/ объект с информацией данных
70
+ */
71
+ protected getLanguage(data: GeoItemFull): string;
72
+ /**
73
+ * Getting the name of the country.
74
+ *
75
+ * Получение названия страны.
76
+ * @param data object with information of data/ объект с информацией данных
77
+ */
78
+ protected getCountry(data: GeoItemFull): string;
79
+ }
@@ -0,0 +1,262 @@
1
+ import { NumberOrStringOrDate, NumberOrString, ItemValue } from '../types/basicTypes';
2
+ import { GeoDate } from '../types/geoTypes';
3
+ /**
4
+ * The Intl namespace object contains several constructors as well as functionality common
5
+ * to the internationalization constructors and other language sensitive functions. Collectively,
6
+ * they comprise the ECMAScript Internationalization API, which provides language sensitive
7
+ * string comparison, number formatting, date and time formatting, and more
8
+ *
9
+ * Объект Intl является пространством имён для API интернационализации ECMAScript, предоставляющим
10
+ * языка-зависимое сравнение строк, форматирование чисел и дат со временем. Конструкторы объектов
11
+ * Collator, NumberFormat и DateTimeFormat являются свойствами объекта Intl. На этой странице
12
+ * описаны эти свойства, а также общая функциональность конструкторов интернационализации и других
13
+ * языка-зависимых функций
14
+ */
15
+ export declare class GeoIntl {
16
+ /**
17
+ * Returns an instance of the class according to the specified country code.
18
+ *
19
+ * Возвращает экземпляр класса по указанному коду страны.
20
+ * @param code country code, full form language-country or one of them/
21
+ * код страны, полный вид язык-страна или один из них
22
+ */
23
+ static getInstance(code?: string): GeoIntl;
24
+ private readonly geo;
25
+ /**
26
+ * Constructor
27
+ * @param code country code, full form language-country or one of them/
28
+ * код страны, полный вид язык-страна или один из них
29
+ */
30
+ constructor(code?: string);
31
+ /**
32
+ * Returns country code and language.
33
+ *
34
+ * Возвращает код страны и языка.
35
+ */
36
+ getLocation(): string;
37
+ /**
38
+ * Returns the first day of the week.
39
+ *
40
+ * Возвращает первый день недели.
41
+ */
42
+ getFirstDay(): string;
43
+ /**
44
+ * The consistent translation of language, region and script display names.
45
+ *
46
+ * Последовательный перевод отображаемых названий языка, региона и скрипта.
47
+ * @param value the code to provide depends on the type/ предоставляемый код зависит от типа
48
+ * @param typeOptions an object with some or all of the following properties/
49
+ * объект с некоторыми или всеми из следующих свойств
50
+ */
51
+ display(value?: string, typeOptions?: Intl.DisplayNamesOptions['type'] | Intl.DisplayNamesOptions): string;
52
+ /**
53
+ * Get display names of language.
54
+ *
55
+ * Получить отображаемые имена языка.
56
+ * @param value the code to provide depends on the type/ предоставляемый код зависит от типа
57
+ * @param style the formatting style to use/ используемый стиль форматирования
58
+ */
59
+ languageName(value?: string, style?: Intl.RelativeTimeFormatStyle): string;
60
+ /**
61
+ * Get display names of region.
62
+ *
63
+ * Получить отображаемые имена региона.
64
+ * @param value the code to provide depends on the type/ предоставляемый код зависит от типа
65
+ * @param style the formatting style to use/ используемый стиль форматирования
66
+ */
67
+ countryName(value?: string, style?: Intl.RelativeTimeFormatStyle): string;
68
+ /**
69
+ * The method returns a string containing the full name in a specific format.
70
+ *
71
+ * Метод возвращает строку, содержащую полное имя в определённом формате.
72
+ * @param last last name/ фамилию
73
+ * @param first first name/ имя
74
+ * @param surname surname middle name (optional)/ отчество
75
+ * @param short shorten the names/ сократить названия
76
+ */
77
+ fullName(last: string, first: string, surname?: string, short?: boolean): string;
78
+ /**
79
+ * In basic use without specifying a locale, a formatted string.
80
+ *
81
+ * При обычном использовании без указания локали форматированная строка.
82
+ * @param value a number, bigint, or string, to format/ число для форматирования
83
+ * @param options an object with some or all properties/ объект с некоторыми
84
+ * или всеми свойствами
85
+ */
86
+ number(value: NumberOrString, options?: Intl.NumberFormatOptions): string;
87
+ /**
88
+ * Decimal point symbol.
89
+ *
90
+ * Символ десятичной точки.
91
+ */
92
+ decimal(): string;
93
+ /**
94
+ * Currency formatting.
95
+ *
96
+ * Форматирование валюты.
97
+ * @param value a number, bigint, or string, to format/ число для форматирования
98
+ * @param currencyOptions the currency to use in currency formatting/
99
+ * валюта для использования в форматировании валюты
100
+ * @param numberOnly do not display the currency symbol/ не выводить значок валюты
101
+ */
102
+ currency(value: NumberOrString, currencyOptions?: string | Intl.NumberFormatOptions, numberOnly?: boolean): string;
103
+ /**
104
+ * Returns the currency symbol if it exists, otherwise the currency code.
105
+ *
106
+ * Возвращает символ для валюты, если он есть, или сам код валюты.
107
+ * @param currency the currency to use in currency formatting/
108
+ * валюта для использования в форматировании валюты
109
+ * @param currencyDisplay how to display the currency in currency formatting/
110
+ * как отобразить валюту в формате валюты
111
+ */
112
+ currencySymbol(currency: string, currencyDisplay?: keyof Intl.NumberFormatOptionsCurrencyDisplayRegistry): string;
113
+ /**
114
+ * Unit formatting.
115
+ * If the style is 'unit', a unit property must be provided.
116
+ *
117
+ * Форматирование юнитов.
118
+ * @param value a number, bigint, or string, to format/ число для форматирования
119
+ * @param unitOptions the unit to use in unit formatting/ блок для использования
120
+ * в форматировании блока
121
+ */
122
+ unit(value: NumberOrString, unitOptions?: string | Intl.NumberFormatOptions): string;
123
+ /**
124
+ * Возвращает отформатированный размер файла
125
+ * @param value a number, bigint, or string, to format /<br>число для форматирования
126
+ * @param unitOptions the unit to use in unit formatting /<br>блок для использования
127
+ * в форматировании блока
128
+ */
129
+ sizeFile(value: NumberOrString, unitOptions?: 'byte' | 'kilobyte' | 'megabyte' | 'gigabyte' | 'terabyte' | 'petabyte' | Intl.NumberFormatOptions): string;
130
+ /**
131
+ * Number as a percentage.
132
+ *
133
+ * Число в виде процента.
134
+ * @param value a number, bigint, or string, to format/ число для форматирования
135
+ * @param options an object with some or all properties/ объект с некоторыми или всеми свойствами
136
+ */
137
+ percent(value: NumberOrString, options?: Intl.NumberFormatOptions): string;
138
+ /**
139
+ * Number as a percentage (unit).
140
+ *
141
+ * Число в виде процента (единица).
142
+ * @param value a number, bigint, or string, to format/ число для форматирования
143
+ * @param options an object with some or all properties/
144
+ * объект с некоторыми или всеми свойствами
145
+ */
146
+ percentBy100(value: NumberOrString, options?: Intl.NumberFormatOptions): string;
147
+ /**
148
+ * Применять форматирование, учитывающее множественное число, и языковые правила, связанные с множественным числом
149
+ * @param value a number, bigint, or string, to format/ число для форматирования
150
+ * @param words list of words for formatting (in the format one|two|few|many|other|zero)/
151
+ * список слов для форматирования (в формате `one|two|few|many|other|zero`)
152
+ * @param options Property for PluralRules/ свойство для PluralRules
153
+ * @param optionsNumber an object with some or all properties/ объект с некоторыми или всеми свойствами
154
+ */
155
+ plural(value: NumberOrString, words: string, options?: Intl.PluralRulesOptions, optionsNumber?: Intl.NumberFormatOptions): string;
156
+ /**
157
+ * Enables language-sensitive date and time formatting.
158
+ *
159
+ * Конструктором объектов, включающих языка-зависимое форматирование даты и времени.
160
+ * @param value the date to format/ дата для форматирования
161
+ * @param type type of data format/ тип формата data
162
+ * @param styleOptions the representation of the month/ представление месяца
163
+ * @param hour24 whether to use 12-hour time/ использовать ли 12-часовое время
164
+ */
165
+ date(value: NumberOrStringOrDate, type?: GeoDate, styleOptions?: Intl.DateTimeFormatOptions['month'] | Intl.DateTimeFormatOptions, hour24?: boolean): string;
166
+ /**
167
+ * Enables language-sensitive relative time formatting.
168
+ *
169
+ * Включает форматирование относительного времени с учетом языка.
170
+ * @param value a number, bigint, or string, to format/ число для форматирования
171
+ * @param styleOptions the length of the internationalized message/
172
+ * длина интернационализированного сообщения
173
+ * @param todayValue current day/ текущий день
174
+ */
175
+ relative(value: NumberOrStringOrDate, styleOptions?: Intl.RelativeTimeFormatStyle | Intl.RelativeTimeFormatOptions, todayValue?: Date): string;
176
+ /**
177
+ * Enables language-sensitive relative time formatting
178
+ * Including the ability to add a limit to output the standard time format if the value
179
+ * exceeds the allowable limit.
180
+ *
181
+ * Включает форматирование относительного времени с учетом языка.
182
+ * Включая возможность добавления лимита, чтобы выводить уже стандартный формат времени,
183
+ * если значение вышло за пределы допустимого.
184
+ * @param value a number, bigint, or string, to format/ число для форматирования
185
+ * @param limit values that determine the output limit (values per day)/
186
+ * значения, по которым определяем предел вывода (значения в день)
187
+ * @param todayValue current day/ текущий день
188
+ * @param relativeOptions the length of the internationalized message/
189
+ * длина интернационализированного сообщения
190
+ * @param dateOptions the representation of the month/ представление месяца
191
+ * @param type type of data format/ тип формата data
192
+ * @param hour24 whether to use 12-hour time/ использовать ли 12-часовое время
193
+ */
194
+ relativeLimit(value: NumberOrStringOrDate, limit: number, todayValue?: Date, relativeOptions?: Intl.RelativeTimeFormatStyle | Intl.RelativeTimeFormatOptions, dateOptions?: Intl.DateTimeFormatOptions['month'] | Intl.DateTimeFormatOptions, type?: GeoDate, hour24?: boolean): string;
195
+ /**
196
+ * Возвращает отформатированное значение времени, прошедшего с момента события
197
+ * @param value a number, bigint, or string, to format/ число для форматирования
198
+ * @param unit time unit/ единица времени
199
+ * @param styleOptions additional option or formatting style/ дополнительная опция или стиль форматирования
200
+ */
201
+ relativeByValue(value: NumberOrString, unit: Intl.RelativeTimeFormatUnit, styleOptions?: Intl.RelativeTimeFormatStyle | Intl.RelativeTimeFormatOptions): string;
202
+ /**
203
+ * Names of months.<br>
204
+ * Названия месяцев.
205
+ * @param value the date to format/ дата для форматирования
206
+ * @param style the representation of the month/ представление месяца
207
+ */
208
+ month(value?: NumberOrStringOrDate, style?: Intl.DateTimeFormatOptions['month']): string;
209
+ /**
210
+ * Array to list of months.
211
+ *
212
+ * Массив в список месяцев.
213
+ * @param style the representation of the month/ представление месяца
214
+ */
215
+ months(style?: Intl.DateTimeFormatOptions['month']): ItemValue<number | undefined>[];
216
+ /**
217
+ * Returns names of days of the week.
218
+ *
219
+ * Возвращает названия дней недели.
220
+ * @param value the date to format/ дата для форматирования
221
+ * @param style the representation of the weekday/ представление о дне недели
222
+ */
223
+ weekday(value?: NumberOrStringOrDate, style?: Intl.DateTimeFormatOptions['weekday']): string;
224
+ /**
225
+ * An array of the list of names of the days of the week.
226
+ *
227
+ * Массив из списка названий дней недели.
228
+ * @param style the representation of the weekday/ представление о дне недели
229
+ */
230
+ weekdays(style?: Intl.DateTimeFormatOptions['weekday']): ItemValue<number | undefined>[];
231
+ /**
232
+ * Time.
233
+ *
234
+ * Время.
235
+ * @param value the date to format/ дата для форматирования
236
+ */
237
+ time(value: NumberOrStringOrDate): string;
238
+ /**
239
+ * Sorts strings taking into account the characteristics of countries.
240
+ *
241
+ * Сортирует строки с учетом особенностей стран.
242
+ * @param data an array with data/ массив с данными
243
+ * @param compareFn a function for sorting/ функция для сортировки
244
+ */
245
+ sort<T>(data: T[], compareFn?: (a: T, b: T) => [string, string]): T[];
246
+ /**
247
+ * The object enables language-sensitive number formatting.
248
+ *
249
+ * Объект включает форматирование чисел с учетом языка.
250
+ * @param options an object with some or all properties/
251
+ * объект с некоторыми или всеми свойствами
252
+ */
253
+ private numberObject;
254
+ /**
255
+ * Returns options for data according to its type.
256
+ *
257
+ * Возвращает options для data по его типу.
258
+ * @param type type of data format/ тип формата data
259
+ * @param display the representation of the month/ представление месяца
260
+ */
261
+ private dateOptions;
262
+ }