@dxtmisha/functional-basic 1.1.0 → 1.1.6

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 (178) hide show
  1. package/CHANGELOG.md +81 -0
  2. package/ai-description.txt +1 -0
  3. package/ai-types.txt +1062 -951
  4. package/dist/classes/Api.d.ts +201 -0
  5. package/dist/classes/ApiCache.d.ts +152 -0
  6. package/dist/classes/ApiDataReturn.d.ts +76 -0
  7. package/dist/classes/ApiDefault.d.ts +49 -0
  8. package/dist/classes/ApiHeaders.d.ts +37 -0
  9. package/dist/classes/ApiHydration.d.ts +39 -0
  10. package/dist/classes/ApiInstance.d.ts +283 -0
  11. package/dist/classes/ApiPreparation.d.ts +58 -0
  12. package/dist/classes/ApiResponse.d.ts +154 -0
  13. package/dist/classes/ApiStatus.d.ts +130 -0
  14. package/dist/classes/BroadcastMessage.d.ts +75 -0
  15. package/dist/classes/Cache.d.ts +38 -0
  16. package/dist/classes/CacheItem.d.ts +62 -0
  17. package/dist/classes/CacheStatic.d.ts +36 -0
  18. package/dist/classes/Cookie.d.ts +54 -0
  19. package/dist/classes/CookieBlock.d.ts +30 -0
  20. package/dist/classes/CookieBlockInstance.d.ts +23 -0
  21. package/dist/classes/CookieStorage.d.ts +174 -0
  22. package/dist/classes/DataStorage.d.ts +107 -0
  23. package/dist/classes/Datetime.d.ts +570 -0
  24. package/dist/classes/ErrorCenter.d.ts +72 -0
  25. package/dist/classes/ErrorCenterHandler.d.ts +64 -0
  26. package/dist/classes/ErrorCenterInstance.d.ts +85 -0
  27. package/dist/classes/EventItem.d.ts +251 -0
  28. package/dist/classes/Formatters.d.ts +161 -0
  29. package/dist/classes/Geo.d.ts +151 -0
  30. package/dist/classes/GeoFlag.d.ts +98 -0
  31. package/dist/classes/GeoInstance.d.ts +215 -0
  32. package/dist/classes/GeoIntl.d.ts +304 -0
  33. package/dist/classes/GeoPhone.d.ts +108 -0
  34. package/dist/classes/Global.d.ts +29 -0
  35. package/dist/classes/Hash.d.ts +57 -0
  36. package/dist/classes/HashInstance.d.ts +95 -0
  37. package/dist/classes/Icons.d.ts +128 -0
  38. package/dist/classes/Loading.d.ts +66 -0
  39. package/dist/classes/LoadingInstance.d.ts +99 -0
  40. package/dist/classes/Meta.d.ts +186 -0
  41. package/dist/classes/MetaManager.d.ts +121 -0
  42. package/dist/classes/MetaOg.d.ts +115 -0
  43. package/dist/classes/MetaStatic.d.ts +179 -0
  44. package/dist/classes/MetaTwitter.d.ts +115 -0
  45. package/dist/classes/ResumableTimer.d.ts +81 -0
  46. package/dist/classes/ScrollbarWidth.d.ts +51 -0
  47. package/dist/classes/SearchList.d.ts +128 -0
  48. package/dist/classes/SearchListData.d.ts +143 -0
  49. package/dist/classes/SearchListItem.d.ts +49 -0
  50. package/dist/classes/SearchListMatcher.d.ts +57 -0
  51. package/dist/classes/SearchListOptions.d.ts +66 -0
  52. package/dist/classes/ServerStorage.d.ts +106 -0
  53. package/dist/classes/StorageCallback.d.ts +84 -0
  54. package/dist/classes/Translate.d.ts +119 -0
  55. package/dist/classes/TranslateFile.d.ts +81 -0
  56. package/dist/classes/TranslateInstance.d.ts +206 -0
  57. package/dist/functions/addTagHighlightMatch.d.ts +11 -0
  58. package/dist/functions/anyToString.d.ts +10 -0
  59. package/dist/functions/applyTemplate.d.ts +10 -0
  60. package/dist/functions/arrFill.d.ts +9 -0
  61. package/dist/functions/blobToBase64.d.ts +9 -0
  62. package/dist/functions/capitalize.d.ts +9 -0
  63. package/dist/functions/copyObject.d.ts +10 -0
  64. package/dist/functions/copyObjectLite.d.ts +9 -0
  65. package/dist/functions/createElement.d.ts +21 -0
  66. package/dist/functions/domQuerySelector.d.ts +8 -0
  67. package/dist/functions/domQuerySelectorAll.d.ts +8 -0
  68. package/dist/functions/encodeAttribute.d.ts +8 -0
  69. package/dist/functions/encodeLiteAttribute.d.ts +8 -0
  70. package/dist/functions/ensureMaxSize.d.ts +10 -0
  71. package/dist/functions/escapeExp.d.ts +7 -0
  72. package/dist/functions/eventStopPropagation.d.ts +7 -0
  73. package/dist/functions/executeFunction.d.ts +12 -0
  74. package/dist/functions/executePromise.d.ts +11 -0
  75. package/dist/functions/forEach.d.ts +14 -0
  76. package/dist/functions/frame.d.ts +10 -0
  77. package/dist/functions/getArrayHighlightMatch.d.ts +10 -0
  78. package/dist/functions/getAttributes.d.ts +9 -0
  79. package/dist/functions/getClipboardData.d.ts +9 -0
  80. package/dist/functions/getColumn.d.ts +10 -0
  81. package/dist/functions/getCurrentDate.d.ts +19 -0
  82. package/dist/functions/getCurrentTime.d.ts +15 -0
  83. package/dist/functions/getElement.d.ts +9 -0
  84. package/dist/functions/getElementId.d.ts +26 -0
  85. package/dist/functions/getElementImage.d.ts +8 -0
  86. package/dist/functions/getElementItem.d.ts +12 -0
  87. package/dist/functions/getElementOrWindow.d.ts +8 -0
  88. package/dist/functions/getElementSafeScript.d.ts +9 -0
  89. package/dist/functions/getExactSearchExp.d.ts +8 -0
  90. package/dist/functions/getExp.d.ts +14 -0
  91. package/dist/functions/getHydrationData.d.ts +10 -0
  92. package/dist/functions/getItemByPath.d.ts +9 -0
  93. package/dist/functions/getKey.d.ts +8 -0
  94. package/dist/functions/getLengthOfAllArray.d.ts +8 -0
  95. package/dist/functions/getMaxLengthAllArray.d.ts +9 -0
  96. package/dist/functions/getMinLengthAllArray.d.ts +8 -0
  97. package/dist/functions/getMouseClient.d.ts +9 -0
  98. package/dist/functions/getMouseClientX.d.ts +8 -0
  99. package/dist/functions/getMouseClientY.d.ts +8 -0
  100. package/dist/functions/getObjectByKeys.d.ts +8 -0
  101. package/dist/functions/getObjectNoUndefined.d.ts +9 -0
  102. package/dist/functions/getObjectOrNone.d.ts +8 -0
  103. package/dist/functions/getOnlyText.d.ts +8 -0
  104. package/dist/functions/getRandomText.d.ts +12 -0
  105. package/dist/functions/getRequestString.d.ts +11 -0
  106. package/dist/functions/getSearchExp.d.ts +12 -0
  107. package/dist/functions/getSeparatingSearchExp.d.ts +9 -0
  108. package/dist/functions/getStepPercent.d.ts +9 -0
  109. package/dist/functions/getStepValue.d.ts +9 -0
  110. package/dist/functions/goScroll.d.ts +10 -0
  111. package/dist/functions/goScrollSmooth.d.ts +10 -0
  112. package/dist/functions/goScrollTo.d.ts +10 -0
  113. package/dist/functions/handleShare.d.ts +10 -0
  114. package/dist/functions/inArray.d.ts +9 -0
  115. package/dist/functions/initScrollbarOffset.d.ts +7 -0
  116. package/dist/functions/intersectKey.d.ts +9 -0
  117. package/dist/functions/isApiSuccess.d.ts +9 -0
  118. package/dist/functions/isArray.d.ts +8 -0
  119. package/dist/functions/isDifferent.d.ts +10 -0
  120. package/dist/functions/isDomData.d.ts +7 -0
  121. package/dist/functions/isDomRuntime.d.ts +10 -0
  122. package/dist/functions/isElementVisible.d.ts +11 -0
  123. package/dist/functions/isEnter.d.ts +9 -0
  124. package/dist/functions/isFilled.d.ts +10 -0
  125. package/dist/functions/isFloat.d.ts +8 -0
  126. package/dist/functions/isFunction.d.ts +9 -0
  127. package/dist/functions/isInDom.d.ts +9 -0
  128. package/dist/functions/isInput.d.ts +8 -0
  129. package/dist/functions/isIntegerBetween.d.ts +9 -0
  130. package/dist/functions/isNull.d.ts +9 -0
  131. package/dist/functions/isNumber.d.ts +8 -0
  132. package/dist/functions/isObject.d.ts +8 -0
  133. package/dist/functions/isObjectNotArray.d.ts +8 -0
  134. package/dist/functions/isOnLine.d.ts +7 -0
  135. package/dist/functions/isSelected.d.ts +9 -0
  136. package/dist/functions/isSelectedByList.d.ts +9 -0
  137. package/dist/functions/isShare.d.ts +7 -0
  138. package/dist/functions/isString.d.ts +8 -0
  139. package/dist/functions/isWindow.d.ts +7 -0
  140. package/dist/functions/random.d.ts +9 -0
  141. package/dist/functions/removeCommonPrefix.d.ts +9 -0
  142. package/dist/functions/replaceComponentName.d.ts +9 -0
  143. package/dist/functions/replaceRecursive.d.ts +11 -0
  144. package/dist/functions/replaceTemplate.d.ts +10 -0
  145. package/dist/functions/resizeImageByMax.d.ts +19 -0
  146. package/dist/functions/secondToTime.d.ts +9 -0
  147. package/dist/functions/setElementItem.d.ts +11 -0
  148. package/dist/functions/setValues.d.ts +18 -0
  149. package/dist/functions/sleep.d.ts +8 -0
  150. package/dist/functions/splice.d.ts +13 -0
  151. package/dist/functions/strFill.d.ts +9 -0
  152. package/dist/functions/strSplit.d.ts +12 -0
  153. package/dist/functions/toArray.d.ts +17 -0
  154. package/dist/functions/toCamelCase.d.ts +8 -0
  155. package/dist/functions/toCamelCaseFirst.d.ts +8 -0
  156. package/dist/functions/toDate.d.ts +8 -0
  157. package/dist/functions/toKebabCase.d.ts +15 -0
  158. package/dist/functions/toNumber.d.ts +19 -0
  159. package/dist/functions/toNumberByMax.d.ts +11 -0
  160. package/dist/functions/toPercent.d.ts +9 -0
  161. package/dist/functions/toPercentBy100.d.ts +9 -0
  162. package/dist/functions/toString.d.ts +8 -0
  163. package/dist/functions/transformation.d.ts +21 -0
  164. package/dist/functions/uint8ArrayToBase64.d.ts +8 -0
  165. package/dist/functions/uniqueArray.d.ts +8 -0
  166. package/dist/functions/writeClipboardData.d.ts +8 -0
  167. package/dist/library.d.ts +171 -8722
  168. package/dist/library.js +416 -338
  169. package/dist/media/errorCauseList.d.ts +2 -0
  170. package/dist/types/apiTypes.d.ts +217 -0
  171. package/dist/types/basicTypes.d.ts +131 -0
  172. package/dist/types/errorCenter.d.ts +42 -0
  173. package/dist/types/formattersTypes.d.ts +224 -0
  174. package/dist/types/geoTypes.d.ts +86 -0
  175. package/dist/types/metaTypes.d.ts +586 -0
  176. package/dist/types/searchTypes.d.ts +53 -0
  177. package/dist/types/translateTypes.d.ts +54 -0
  178. package/package.json +7 -5
@@ -0,0 +1,115 @@
1
+ import { MetaManager } from './MetaManager';
2
+ import { MetaOpenGraphTag, MetaOpenGraphType } from '../types/metaTypes';
3
+ /**
4
+ * Class for working with Open Graph meta tags.
5
+ *
6
+ * Класс для управления мета-тегами Open Graph.
7
+ */
8
+ export declare class MetaOg extends MetaManager<MetaOpenGraphTag[]> {
9
+ constructor();
10
+ /**
11
+ * Gets the Open Graph title.
12
+ *
13
+ * Получает заголовок Open Graph.
14
+ * @returns title / заголовок
15
+ */
16
+ getTitle(): string;
17
+ /**
18
+ * Gets the Open Graph type.
19
+ *
20
+ * Получает тип Open Graph.
21
+ * @returns type / тип
22
+ */
23
+ getType(): MetaOpenGraphType;
24
+ /**
25
+ * Gets the Open Graph URL.
26
+ *
27
+ * Получает URL Open Graph.
28
+ * @returns URL / URL
29
+ */
30
+ getUrl(): string;
31
+ /**
32
+ * Gets the Open Graph image URL.
33
+ *
34
+ * Получает URL изображения Open Graph.
35
+ * @returns image URL / URL изображения
36
+ */
37
+ getImage(): string;
38
+ /**
39
+ * Gets the Open Graph description.
40
+ *
41
+ * Получает описание Open Graph.
42
+ * @returns description / описание
43
+ */
44
+ getDescription(): string;
45
+ /**
46
+ * Gets the Open Graph locale.
47
+ *
48
+ * Получает локаль Open Graph.
49
+ * @returns locale / локаль
50
+ */
51
+ getLocale(): string;
52
+ /**
53
+ * Gets the Open Graph site name.
54
+ *
55
+ * Получает название сайта Open Graph.
56
+ * @returns site name / название сайта
57
+ */
58
+ getSiteName(): string;
59
+ /**
60
+ * Sets the Open Graph title.
61
+ *
62
+ * Устанавливает заголовок Open Graph.
63
+ * @param title title / заголовок
64
+ * @returns current instance / текущий экземпляр
65
+ */
66
+ setTitle(title: string): this;
67
+ /**
68
+ * Sets the Open Graph type.
69
+ *
70
+ * Устанавливает тип Open Graph.
71
+ * @param type type / тип
72
+ * @returns current instance / текущий экземпляр
73
+ */
74
+ setType(type: MetaOpenGraphType): this;
75
+ /**
76
+ * Sets the Open Graph URL.
77
+ *
78
+ * Устанавливает URL Open Graph.
79
+ * @param url URL / URL
80
+ * @returns current instance / текущий экземпляр
81
+ */
82
+ setUrl(url: string): this;
83
+ /**
84
+ * Sets the Open Graph image URL.
85
+ *
86
+ * Устанавливает URL изображения Open Graph.
87
+ * @param url image URL / URL изображения
88
+ * @returns current instance / текущий экземпляр
89
+ */
90
+ setImage(url: string): this;
91
+ /**
92
+ * Sets the Open Graph description.
93
+ *
94
+ * Устанавливает описание Open Graph.
95
+ * @param description description / описание
96
+ * @returns current instance / текущий экземпляр
97
+ */
98
+ setDescription(description: string): this;
99
+ /**
100
+ * Sets the Open Graph locale.
101
+ *
102
+ * Устанавливает локаль Open Graph.
103
+ * @param locale locale (e.g. 'en_US', 'ru_RU') / локаль (например, 'en_US', 'ru_RU')
104
+ * @returns current instance / текущий экземпляр
105
+ */
106
+ setLocale(locale: string): this;
107
+ /**
108
+ * Sets the Open Graph site name.
109
+ *
110
+ * Устанавливает название сайта Open Graph.
111
+ * @param siteName site name / название сайта
112
+ * @returns current instance / текущий экземпляр
113
+ */
114
+ setSiteName(siteName: string): this;
115
+ }
@@ -0,0 +1,179 @@
1
+ import { Meta } from './Meta';
2
+ import { MetaOg } from './MetaOg';
3
+ import { MetaTwitter } from './MetaTwitter';
4
+ import { MetaRobots } from '../types/metaTypes';
5
+ /**
6
+ * Static class for managing meta tags.
7
+ *
8
+ * Статичный класс для управления мета-тегами.
9
+ */
10
+ export declare class MetaStatic {
11
+ /**
12
+ * Returns the singleton instance of the Meta class.
13
+ *
14
+ * Возвращает синглтон-экземпляр класса Meta.
15
+ * @returns Meta singleton / синглтон Meta
16
+ */
17
+ static getItem(): Meta;
18
+ /**
19
+ * Gets the MetaOg instance for advanced Open Graph operations.
20
+ *
21
+ * Получает экземпляр MetaOg для расширенных операций с Open Graph.
22
+ * @returns MetaOg instance / экземпляр MetaOg
23
+ */
24
+ static getOg(): MetaOg;
25
+ /**
26
+ * Gets the MetaTwitter instance for advanced Twitter Card operations.
27
+ *
28
+ * Получает экземпляр MetaTwitter для расширенных операций с Twitter Card.
29
+ * @returns MetaTwitter instance / экземпляр MetaTwitter
30
+ */
31
+ static getTwitter(): MetaTwitter;
32
+ /**
33
+ * Gets the page title without suffix.
34
+ *
35
+ * Получает заголовок страницы без суффикса.
36
+ * @returns title without suffix / заголовок без суффикса
37
+ */
38
+ static getTitle(): string;
39
+ /**
40
+ * Gets the keywords meta tag.
41
+ *
42
+ * Получает мета-тег keywords.
43
+ * @returns keywords content / содержимое keywords
44
+ */
45
+ static getKeywords(): string;
46
+ /**
47
+ * Gets the description meta tag.
48
+ *
49
+ * Получает мета-тег description.
50
+ * @returns description content / содержимое description
51
+ */
52
+ static getDescription(): string;
53
+ /**
54
+ * Gets the Open Graph image URL.
55
+ *
56
+ * Получает URL изображения Open Graph.
57
+ * @returns image URL / URL изображения
58
+ */
59
+ static getImage(): string;
60
+ /**
61
+ * Gets the canonical URL.
62
+ *
63
+ * Получает канонический URL.
64
+ * @returns canonical URL / канонический URL
65
+ */
66
+ static getCanonical(): string;
67
+ /**
68
+ * Gets the robots meta tag value.
69
+ *
70
+ * Получает значение мета-тега robots.
71
+ * @returns robots directive / директива robots
72
+ */
73
+ static getRobots(): MetaRobots;
74
+ /**
75
+ * Gets the author meta tag.
76
+ *
77
+ * Получает мета-тег author.
78
+ * @returns author name / имя автора
79
+ */
80
+ static getAuthor(): string;
81
+ /**
82
+ * Gets the Open Graph site name.
83
+ *
84
+ * Получает название сайта Open Graph.
85
+ * @returns site name / название сайта
86
+ */
87
+ static getSiteName(): string;
88
+ /**
89
+ * Gets the Open Graph locale.
90
+ *
91
+ * Получает локаль Open Graph.
92
+ * @returns locale / локаль
93
+ */
94
+ static getLocale(): string;
95
+ /**
96
+ * Sets the page title (with suffix) and updates Open Graph and Twitter Card titles.
97
+ *
98
+ * Устанавливает заголовок страницы (с суффиксом) и обновляет заголовки Open Graph и Twitter Card.
99
+ * @param title page title / заголовок страницы
100
+ */
101
+ static setTitle(title: string): typeof MetaStatic;
102
+ /**
103
+ * Sets the keywords meta tag.
104
+ *
105
+ * Устанавливает мета-тег keywords.
106
+ * @param keywords keywords as string or array / ключевые слова в виде строки или массива
107
+ */
108
+ static setKeywords(keywords: string | string[]): typeof MetaStatic;
109
+ /**
110
+ * Sets the description meta tag.
111
+ *
112
+ * Устанавливает мета-тег description.
113
+ * @param description page description / описание страницы
114
+ */
115
+ static setDescription(description: string): typeof MetaStatic;
116
+ /**
117
+ * Sets the image for Open Graph and Twitter Card.
118
+ *
119
+ * Устанавливает изображение для Open Graph и Twitter Card.
120
+ * @param image image URL / URL изображения
121
+ */
122
+ static setImage(image: string): typeof MetaStatic;
123
+ /**
124
+ * Sets the canonical URL and updates Open Graph and Twitter Card URLs.
125
+ *
126
+ * Устанавливает канонический URL и обновляет URL для Open Graph и Twitter Card.
127
+ * @param canonical canonical URL / канонический URL
128
+ */
129
+ static setCanonical(canonical: string): typeof MetaStatic;
130
+ /**
131
+ * Sets the robots meta tag.
132
+ *
133
+ * Устанавливает мета-тег robots.
134
+ * @param robots robots directive / директива robots
135
+ */
136
+ static setRobots(robots: MetaRobots): typeof MetaStatic;
137
+ /**
138
+ * Sets the author meta tag.
139
+ *
140
+ * Устанавливает мета-тег author.
141
+ * @param author author name / имя автора
142
+ */
143
+ static setAuthor(author: string): typeof MetaStatic;
144
+ /**
145
+ * Sets the site name for Open Graph and Twitter Card.
146
+ *
147
+ * Устанавливает название сайта для Open Graph и Twitter Card.
148
+ * @param siteName site name / название сайта
149
+ */
150
+ static setSiteName(siteName: string): typeof MetaStatic;
151
+ /**
152
+ * Sets the locale for Open Graph.
153
+ *
154
+ * Устанавливает локаль для Open Graph.
155
+ * @param locale locale (e.g. 'en_US', 'ru_RU') / локаль (например, 'en_US', 'ru_RU')
156
+ */
157
+ static setLocale(locale: string): typeof MetaStatic;
158
+ /**
159
+ * Sets the suffix to append to page title.
160
+ *
161
+ * Устанавливает суффикс для добавления к заголовку страницы.
162
+ * @param suffix title suffix (e.g. 'My Site') / суффикс заголовка (например, 'Мой Сайт')
163
+ */
164
+ static setSuffix(suffix?: string): typeof MetaStatic;
165
+ /**
166
+ * Generates the complete HTML for all meta-tags including Open Graph and Twitter Card.
167
+ *
168
+ * Генерирует полный HTML для всех мета-тегов, включая Open Graph и Twitter Card.
169
+ * @returns complete HTML string / полная HTML-строка
170
+ */
171
+ static html(): string;
172
+ /**
173
+ * Generates the title as an HTML-safe string.
174
+ *
175
+ * Генерирует заголовок в виде HTML-безопасной строки.
176
+ * @returns title HTML-safe string / HTML-безопасная строка заголовка
177
+ */
178
+ static htmlTitle(): string;
179
+ }
@@ -0,0 +1,115 @@
1
+ import { MetaManager } from './MetaManager';
2
+ import { MetaTwitterCard, MetaTwitterTag } from '../types/metaTypes';
3
+ /**
4
+ * Class for working with Twitter Card meta tags.
5
+ *
6
+ * Класс для управления мета-тегами Twitter Card.
7
+ */
8
+ export declare class MetaTwitter extends MetaManager<MetaTwitterTag[]> {
9
+ constructor();
10
+ /**
11
+ * Gets the Twitter Card type.
12
+ *
13
+ * Получает тип Twitter Card.
14
+ * @returns card type / тип карточки
15
+ */
16
+ getCard(): MetaTwitterCard;
17
+ /**
18
+ * Gets the website or brand @username.
19
+ *
20
+ * Получает аккаунт сайта или бренда (@username).
21
+ * @returns @username / аккаунт
22
+ */
23
+ getSite(): string;
24
+ /**
25
+ * Gets the content creator @username.
26
+ *
27
+ * Получает автора контента (@username).
28
+ * @returns @username / аккаунт автора
29
+ */
30
+ getCreator(): string;
31
+ /**
32
+ * Gets the page URL.
33
+ *
34
+ * Получает URL страницы.
35
+ * @returns URL / URL
36
+ */
37
+ getUrl(): string;
38
+ /**
39
+ * Gets the card title.
40
+ *
41
+ * Получает заголовок карточки.
42
+ * @returns title / заголовок
43
+ */
44
+ getTitle(): string;
45
+ /**
46
+ * Gets the card description.
47
+ *
48
+ * Получает описание карточки.
49
+ * @returns description / описание
50
+ */
51
+ getDescription(): string;
52
+ /**
53
+ * Gets the card image URL.
54
+ *
55
+ * Получает URL изображения карточки.
56
+ * @returns image URL / URL изображения
57
+ */
58
+ getImage(): string;
59
+ /**
60
+ * Sets the Twitter Card type.
61
+ *
62
+ * Устанавливает тип Twitter Card.
63
+ * @param card card type / тип карточки
64
+ * @returns current instance / текущий экземпляр
65
+ */
66
+ setCard(card: MetaTwitterCard): this;
67
+ /**
68
+ * Sets the website or brand @username.
69
+ *
70
+ * Устанавливает аккаунт сайта или бренда (@username).
71
+ * @param site @username / аккаунт
72
+ * @returns current instance / текущий экземпляр
73
+ */
74
+ setSite(site: string): this;
75
+ /**
76
+ * Sets the content creator @username.
77
+ *
78
+ * Устанавливает автора контента (@username).
79
+ * @param creator @username / аккаунт автора
80
+ * @returns current instance / текущий экземпляр
81
+ */
82
+ setCreator(creator: string): this;
83
+ /**
84
+ * Sets the page URL.
85
+ *
86
+ * Устанавливает URL страницы.
87
+ * @param url URL / URL
88
+ * @returns current instance / текущий экземпляр
89
+ */
90
+ setUrl(url: string): this;
91
+ /**
92
+ * Sets the card title.
93
+ *
94
+ * Устанавливает заголовок карточки.
95
+ * @param title title / заголовок
96
+ * @returns current instance / текущий экземпляр
97
+ */
98
+ setTitle(title: string): this;
99
+ /**
100
+ * Sets the card description.
101
+ *
102
+ * Устанавливает описание карточки.
103
+ * @param description description / описание
104
+ * @returns current instance / текущий экземпляр
105
+ */
106
+ setDescription(description: string): this;
107
+ /**
108
+ * Sets the card image URL.
109
+ *
110
+ * Устанавливает URL изображения карточки.
111
+ * @param image image URL / URL изображения
112
+ * @returns current instance / текущий экземпляр
113
+ */
114
+ setImage(image: string): this;
115
+ }
@@ -0,0 +1,81 @@
1
+ import { FunctionVoid } from '../types/basicTypes';
2
+ /**
3
+ * Class for creating a timer that can be paused and resumed.
4
+ *
5
+ * Класс для создания таймера, который можно приостанавливать и возобновлять.
6
+ */
7
+ export declare class ResumableTimer {
8
+ protected callback: FunctionVoid;
9
+ protected delay: number;
10
+ protected timerId?: ReturnType<typeof setTimeout>;
11
+ protected startTime?: number;
12
+ protected remaining?: number;
13
+ protected completed: boolean;
14
+ /**
15
+ * Constructor
16
+ * @param callback function to be called after the delay / функция, которая будет вызвана после задержки
17
+ * @param delay delay in milliseconds / задержка в миллисекундах
18
+ * @param blockStart if true, the timer will not start immediately / если true, таймер не запустится сразу
19
+ */
20
+ constructor(callback: FunctionVoid, delay?: number, blockStart?: boolean);
21
+ /**
22
+ * Resumes the timer if it was paused or starts it for the first time.
23
+ *
24
+ * Возобновляет таймер, если он был приостановлен, или запускает его впервые.
25
+ */
26
+ resume(): this;
27
+ /**
28
+ * Pauses the timer and calculates the remaining time.
29
+ *
30
+ * Приостанавливает таймер и вычисляет оставшееся время.
31
+ */
32
+ pause(): this;
33
+ /**
34
+ * Resets and restarts the timer with the original delay.
35
+ *
36
+ * Сбрасывает и перезапускает таймер с исходной задержкой.
37
+ */
38
+ reset(): this;
39
+ /**
40
+ * Completely clears the timer and resets its state.
41
+ *
42
+ * Полностью очищает таймер и сбрасывает его состояние.
43
+ */
44
+ clear(): this;
45
+ /**
46
+ * Returns the remaining time or the initial delay.
47
+ *
48
+ * Возвращает оставшееся время или начальную задержку.
49
+ */
50
+ protected getRemaining(): number;
51
+ /**
52
+ * Returns the time when the timer was started or the current time.
53
+ *
54
+ * Возвращает время запуска таймера или текущее время.
55
+ */
56
+ protected getStartTime(): number;
57
+ /**
58
+ * Executes the callback and marks the timer as completed.
59
+ *
60
+ * Выполняет колбэк и отмечает таймер как завершенный.
61
+ */
62
+ protected go(): this;
63
+ /**
64
+ * Updates the remaining time based on the elapsed time.
65
+ *
66
+ * Обновляет оставшееся время на основе прошедшего времени.
67
+ */
68
+ protected updateRemaining(): this;
69
+ /**
70
+ * Sets the current time as the start time.
71
+ *
72
+ * Устанавливает текущее время как время начала.
73
+ */
74
+ protected updateStartTime(): this;
75
+ /**
76
+ * Stops the timer and clears the timeout ID.
77
+ *
78
+ * Останавливает таймер и очищает идентификатор таймаута.
79
+ */
80
+ protected stop(): this;
81
+ }
@@ -0,0 +1,51 @@
1
+ import { DataStorage } from './DataStorage';
2
+ /**
3
+ * Class for getting the scroll width.
4
+ *
5
+ * Класс для получения ширины скролла.
6
+ */
7
+ export declare class ScrollbarWidth {
8
+ private static calculate;
9
+ /**
10
+ * Checks whether to enable scroll hiding.
11
+ *
12
+ * Проверяет, надо ли включить скрытие скролла.
13
+ * @returns boolean indicating if scroll hiding is enabled/ логическое значение, указывающее, включено ли скрытие скролла
14
+ */
15
+ static is(): Promise<boolean>;
16
+ /**
17
+ * Returns the width of the scroll.
18
+ *
19
+ * Возвращает ширину скролла.
20
+ * @returns scrollbar width in pixels/ ширина скролла в пикселях
21
+ */
22
+ static get(): Promise<number>;
23
+ /**
24
+ * Returns the storage for scroll width.
25
+ *
26
+ * Возвращает хранилище для ширины скролла.
27
+ * @returns DataStorage instance/ экземпляр DataStorage
28
+ */
29
+ static getStorage(): DataStorage<number>;
30
+ /**
31
+ * Returns the calculate flag, indicating if width calculation is in progress.
32
+ *
33
+ * Возвращает флаг вычисления, указывающий, идет ли расчет ширины.
34
+ * @returns calculation flag/ флаг вычисления
35
+ */
36
+ static getCalculate(): boolean;
37
+ /**
38
+ * Creates elements to check the width of the scroll.
39
+ *
40
+ * Создает элементы для проверки ширины скролла.
41
+ * @returns created element / созданный элемент
42
+ */
43
+ private static createElement;
44
+ /**
45
+ * Initialization of data to check the width of the scroll.
46
+ *
47
+ * Инициализация данных для проверки ширины скролла.
48
+ * @returns a promise that resolves with the scrollbar width / промис, который разрешается шириной скролла
49
+ */
50
+ private static init;
51
+ }
@@ -0,0 +1,128 @@
1
+ import { SearchListData } from './SearchListData';
2
+ import { SearchListItem } from './SearchListItem';
3
+ import { SearchListMatcher } from './SearchListMatcher';
4
+ import { SearchListOptions } from './SearchListOptions';
5
+ import { SearchCacheItem, SearchColumns, SearchFormatItem, SearchFormatList, SearchItem, SearchListValue, SearchOptions } from '../types/searchTypes';
6
+ /**
7
+ * Main class for managing a searchable list.
8
+ * Coordinates between options, item state, matching logic, and data storage.
9
+ *
10
+ * Основной класс для управления списком с возможностью поиска.
11
+ * Координирует работу опций, состояния элементов, логики сопоставления и хранения данных.
12
+ */
13
+ export declare class SearchList<T extends SearchItem, K extends SearchColumns<T>> {
14
+ protected options: SearchListOptions;
15
+ protected item: SearchListItem;
16
+ protected matcher: SearchListMatcher;
17
+ protected data: SearchListData<T, K>;
18
+ /**
19
+ * Constructor for SearchList.
20
+ *
21
+ * Конструктор для SearchList.
22
+ * @param list initial list of items/ исходный список элементов
23
+ * @param columns columns to perform search on/ столбцы для выполнения поиска
24
+ * @param value initial search value/ начальное значение поиска
25
+ * @param options search options/ опции поиска
26
+ */
27
+ constructor(list: SearchListValue<T>, columns?: K, value?: string, options?: SearchOptions);
28
+ /**
29
+ * Returns the search data management instance.
30
+ *
31
+ * Возвращает экземпляр управления данными поиска.
32
+ * @returns SearchListData instance/ экземпляр SearchListData
33
+ */
34
+ getData(): SearchListData<T, K>;
35
+ /**
36
+ * Returns the current list of items.
37
+ *
38
+ * Возвращает текущий список элементов.
39
+ * @returns list of items/ список элементов
40
+ */
41
+ getList(): SearchListValue<T>;
42
+ /**
43
+ * Returns the current search columns.
44
+ *
45
+ * Возвращает текущие столбцы поиска.
46
+ * @returns columns or undefined/ столбцы или undefined
47
+ */
48
+ getColumns(): K | undefined;
49
+ /**
50
+ * Returns the search item instance.
51
+ *
52
+ * Возвращает экземпляр элемента поиска.
53
+ * @returns SearchListItem instance/ экземпляр SearchListItem
54
+ */
55
+ getItem(): SearchListItem;
56
+ /**
57
+ * Returns the current search value.
58
+ *
59
+ * Возвращает текущее значение поиска.
60
+ * @returns search value string or undefined/ строка значения поиска или undefined
61
+ */
62
+ getValue(): string | undefined;
63
+ /**
64
+ * Returns the search options instance.
65
+ *
66
+ * Возвращает экземпляр опций поиска.
67
+ * @returns SearchListOptions instance/ экземпляр SearchListOptions
68
+ */
69
+ getOptions(): SearchListOptions;
70
+ /**
71
+ * Sets a new list of items and resets the cache.
72
+ *
73
+ * Устанавливает новый список элементов и сбрасывает кэш.
74
+ * @param list new list/ новый список
75
+ * @returns this instance/ данный экземпляр
76
+ */
77
+ setList(list: SearchListValue<T>): this;
78
+ /**
79
+ * Sets new search columns and resets the cache.
80
+ *
81
+ * Устанавливает новые столбцы поиска и сбрасывает кэш.
82
+ * @param columns new columns/ новые столбцы
83
+ * @returns this instance/ данный экземпляр
84
+ */
85
+ setColumns(columns?: K): this;
86
+ /**
87
+ * Sets a new search value and updates the matcher.
88
+ *
89
+ * Устанавливает новое значение поиска и обновляет сопоставитель.
90
+ * @param value new search value/ новое значение поиска
91
+ * @returns this instance/ данный экземпляр
92
+ */
93
+ setValue(value?: string): this;
94
+ /**
95
+ * Sets new search options and updates the matcher.
96
+ *
97
+ * Устанавливает новые опции поиска и обновляет сопоставитель.
98
+ * @param options new options/ новые опции
99
+ * @returns this instance/ данный экземпляр
100
+ */
101
+ setOptions(options: SearchOptions): this;
102
+ /**
103
+ * Processes the list and returns a formatted list of items based on the current search state.
104
+ *
105
+ * Обрабатывает список и возвращает отформатированный список элементов на основе текущего состояния поиска.
106
+ * @returns formatted list of items/ отформатированный список элементов
107
+ */
108
+ to(): SearchFormatList<T, K>;
109
+ /**
110
+ * Callback for processing items when a search is active.
111
+ * Checks for selection and handles "return everything" option.
112
+ *
113
+ * Обратный вызов для обработки элементов при активном поиске.
114
+ * Проверяет выбор и обрабатывает опцию "возвращать всё".
115
+ * @param item item / элемент
116
+ * @param value search value / значение поиска
117
+ * @returns formatted item or undefined / отформатированный элемент или undefined
118
+ */
119
+ protected readonly callbackToSelection: (item: SearchCacheItem<T>["item"], value: SearchCacheItem<T>["value"]) => SearchFormatItem<T, K> | undefined;
120
+ /**
121
+ * Callback for processing items when no search is active.
122
+ *
123
+ * Обратный вызов для обработки элементов, когда поиск не активен.
124
+ * @param item item / элемент
125
+ * @returns formatted item / отформатированный элемент
126
+ */
127
+ protected readonly callbackToNone: (item: SearchCacheItem<T>["item"]) => SearchFormatItem<T, K>;
128
+ }