@topvisor/ui 0.9.36 → 1.0.0-colors-3

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 (196) hide show
  1. package/.chunks/{datepicker-CMuCkYBj.amd.js → datepicker-CGWwMJRV.amd.js} +10 -10
  2. package/.chunks/datepicker-CGWwMJRV.amd.js.map +1 -0
  3. package/.chunks/{datepicker-CtcFJYEp.es.js → datepicker-INKeNnsk.es.js} +22 -22
  4. package/.chunks/datepicker-INKeNnsk.es.js.map +1 -0
  5. package/.chunks/debounce-4ipCj607.amd.js +2 -0
  6. package/.chunks/debounce-4ipCj607.amd.js.map +1 -0
  7. package/.chunks/debounce-BISRz08p.es.js +116 -0
  8. package/.chunks/debounce-BISRz08p.es.js.map +1 -0
  9. package/.chunks/{forms-Cay_sybt.es.js → forms-BDAati-M.es.js} +264 -249
  10. package/.chunks/forms-BDAati-M.es.js.map +1 -0
  11. package/.chunks/forms-ZqLh7cu5.amd.js +3 -0
  12. package/.chunks/forms-ZqLh7cu5.amd.js.map +1 -0
  13. package/.chunks/i18n-C_OH9IT3.amd.js +2 -0
  14. package/.chunks/{i18n-eDh3Aaw9.amd.js.map → i18n-C_OH9IT3.amd.js.map} +1 -1
  15. package/.chunks/i18n-DuTvft1T.es.js +26 -0
  16. package/.chunks/{i18n-qpB8zyhD.es.js.map → i18n-DuTvft1T.es.js.map} +1 -1
  17. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-B-fUb36w.amd.js +2 -0
  18. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-B-fUb36w.amd.js.map +1 -0
  19. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CaEDfkda.es.js +174 -0
  20. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CaEDfkda.es.js.map +1 -0
  21. package/.chunks/menu-BDD1uC-t.amd.js +2 -0
  22. package/.chunks/menu-BDD1uC-t.amd.js.map +1 -0
  23. package/.chunks/{menu-B3Nf7_NC.es.js → menu-DJZI8eh6.es.js} +30 -32
  24. package/.chunks/menu-DJZI8eh6.es.js.map +1 -0
  25. package/.chunks/{popup-B7UOyCUj.es.js → popup-C18N-1yr.es.js} +23 -18
  26. package/.chunks/popup-C18N-1yr.es.js.map +1 -0
  27. package/.chunks/{popup-BGuc5GyB.amd.js → popup-C497Sl7G.amd.js} +16 -11
  28. package/.chunks/popup-C497Sl7G.amd.js.map +1 -0
  29. package/assets/core.css +1 -1
  30. package/assets/dark.css +1 -1
  31. package/assets/forms.css +1 -1
  32. package/assets/formsExt.css +1 -1
  33. package/assets/light.css +1 -1
  34. package/assets/listItem.css +1 -1
  35. package/assets/menu.css +1 -1
  36. package/assets/popup.css +1 -1
  37. package/assets/tabs.css +1 -1
  38. package/assets/tabsView.css +1 -1
  39. package/common/common.d.ts +1 -1
  40. package/components/forms/avatar/avatar.vue.d.ts +12 -12
  41. package/components/forms/button/button.d.ts +14 -2
  42. package/components/forms/button/button.vue.d.ts +11 -12
  43. package/components/forms/checkbox/checkbox.vue.d.ts +19 -43
  44. package/components/forms/controlLabel/controlLabel.vue.d.ts +7 -8
  45. package/components/forms/forms.d.ts +0 -1
  46. package/components/forms/hint/hint.vue.d.ts +2 -3
  47. package/components/forms/input/input.d.ts +0 -1
  48. package/components/forms/input/input.vue.d.ts +11 -12
  49. package/components/forms/inputDate/inputDate.d.ts +0 -1
  50. package/components/forms/inputDate/inputDate.vue.d.ts +11 -12
  51. package/components/forms/radio/radio.vue.d.ts +8 -9
  52. package/components/forms/select/select.d.ts +0 -1
  53. package/components/forms/select/select.vue.d.ts +31 -69
  54. package/components/forms/select/stories/exampleOptions.d.ts +0 -1
  55. package/components/forms/switcher/switcher.vue.d.ts +8 -9
  56. package/components/forms/textarea/textarea.vue.d.ts +11 -12
  57. package/components/formsExt/editArea/editArea.d.ts +0 -1
  58. package/components/formsExt/editArea/editArea.vue.d.ts +13 -14
  59. package/components/formsExt/editInput/editInput.d.ts +0 -1
  60. package/components/formsExt/editInput/editInput.vue.d.ts +3 -4
  61. package/components/formsExt/formsExt.d.ts +0 -1
  62. package/components/formsExt/menu/menu.d.ts +0 -1
  63. package/components/formsExt/menu/menu.vue.d.ts +32 -48
  64. package/components/formsExt/menu/stories/items.d.ts +0 -1
  65. package/components/formsExt/radioGroup/radioGroup.d.ts +0 -1
  66. package/components/formsExt/radioGroup/radioGroup.vue.d.ts +31 -42
  67. package/components/formsExt/selector2/api.d.ts +0 -1
  68. package/components/formsExt/selector2/itemMulti.vue.d.ts +3 -4
  69. package/components/formsExt/selector2/selector2.d.ts +0 -1
  70. package/components/formsExt/selector2/selector2.vue.d.ts +37 -117
  71. package/components/popup/alert/alert.d.ts +8 -0
  72. package/components/popup/alert/alert.vue.d.ts +33 -0
  73. package/components/popup/confirm/confirm.d.ts +21 -0
  74. package/components/popup/confirm/confirm.vue.d.ts +35 -0
  75. package/components/popup/lib/popup.d.ts +0 -1
  76. package/components/popup/lib/worker.d.ts +4 -5
  77. package/components/popup/popup/listItem.vue.d.ts +11 -12
  78. package/components/popup/popup/opener.vue.d.ts +13 -14
  79. package/components/popup/popup/popup.d.ts +8 -2
  80. package/components/popup/popup/popup.vue.d.ts +13 -14
  81. package/components/popup/popup/widgetInput.vue.d.ts +32 -82
  82. package/components/popup/popup.d.ts +6 -1
  83. package/components/popup/prompt/prompt.d.ts +21 -0
  84. package/components/popup/prompt/prompt.vue.d.ts +35 -0
  85. package/components/project/project.d.ts +0 -1
  86. package/components/project/selectorCompetitors/composables.d.ts +0 -1
  87. package/components/project/selectorCompetitors/selectorCompetitors.d.ts +0 -1
  88. package/components/project/selectorCompetitors/selectorCompetitors.vue.d.ts +32 -24
  89. package/components/tabs/tabs/content.vue.d.ts +7 -8
  90. package/components/tabs/tabs/tab.vue.d.ts +7 -8
  91. package/components/tabs/tabs/tabs.vue.d.ts +7 -8
  92. package/components/tabs/tabs.d.ts +0 -1
  93. package/components/tabsView/tabsView/menu.vue.d.ts +22 -14
  94. package/components/tabsView/tabsView/menuItem.vue.d.ts +12 -12
  95. package/components/tabsView/tabsView/menuTitle.vue.d.ts +8 -8
  96. package/components/tabsView/tabsView/store.d.ts +1 -2
  97. package/components/tabsView/tabsView/tabsView.d.ts +0 -1
  98. package/components/tabsView/tabsView/tabsView.vue.d.ts +34 -34
  99. package/components/tabsView/tabsView.d.ts +0 -1
  100. package/core/app.amd.js +1 -1
  101. package/core/app.amd.js.map +1 -1
  102. package/core/app.d.ts +0 -1
  103. package/core/app.js +23 -21
  104. package/core/app.js.map +1 -1
  105. package/core/core/core.d.ts +14 -0
  106. package/core/core.amd.js +1 -1
  107. package/core/core.d.ts +2 -1
  108. package/core/core.js +1 -1
  109. package/core/directives/focus.d.ts +0 -1
  110. package/core/directives/sticky.d.ts +0 -1
  111. package/core/directives/swimUp.d.ts +0 -1
  112. package/core/directives/tooltip.d.ts +0 -1
  113. package/core/plugins/core.d.ts +0 -1
  114. package/core/plugins/i18n.d.ts +0 -1
  115. package/core/plugins/piniaTPA.d.ts +0 -1
  116. package/core/utils/lodash.d.ts +6 -0
  117. package/core/utils/price.d.ts +0 -1
  118. package/core/utils/store/localStorage.d.ts +0 -1
  119. package/core/utils/store/plugin.d.ts +0 -1
  120. package/core/utils/store/store.d.ts +0 -1
  121. package/forms/forms.amd.js +1 -1
  122. package/forms/forms.d.ts +1 -0
  123. package/forms/forms.js +1 -1
  124. package/forms/helpers.d.ts +1 -0
  125. package/formsExt/formsExt.amd.js +1 -1
  126. package/formsExt/formsExt.amd.js.map +1 -1
  127. package/formsExt/formsExt.d.ts +1 -0
  128. package/formsExt/formsExt.js +3 -3
  129. package/formsExt/formsExt.js.map +1 -1
  130. package/package.json +1 -2
  131. package/popup/popup.amd.js +1 -1
  132. package/popup/popup.amd.js.map +1 -1
  133. package/popup/popup.d.ts +1 -0
  134. package/popup/popup.js +219 -21
  135. package/popup/popup.js.map +1 -1
  136. package/popup/worker.amd.js +1 -1
  137. package/popup/worker.amd.js.map +1 -1
  138. package/popup/worker.d.ts +3 -0
  139. package/popup/worker.js +2 -2
  140. package/popup/worker.js.map +1 -1
  141. package/project/project.amd.js +1 -1
  142. package/project/project.amd.js.map +1 -1
  143. package/project/project.d.ts +1 -0
  144. package/project/project.js +20 -20
  145. package/tabs/tabs.amd.js +1 -1
  146. package/tabs/tabs.d.ts +1 -0
  147. package/tabs/tabs.js +1 -1
  148. package/tabsView/tabsView.amd.js +1 -1
  149. package/tabsView/tabsView.amd.js.map +1 -1
  150. package/tabsView/tabsView.d.ts +1 -0
  151. package/tabsView/tabsView.js +1 -1
  152. package/tabsView/tabsView.js.map +1 -1
  153. package/utils/check.d.ts +1 -0
  154. package/utils/clipboard.d.ts +1 -0
  155. package/utils/date.amd.js +1 -1
  156. package/utils/date.d.ts +1 -0
  157. package/utils/date.js +2 -2
  158. package/utils/device.amd.js +1 -1
  159. package/utils/device.d.ts +1 -0
  160. package/utils/device.js +1 -1
  161. package/utils/dom.d.ts +3 -0
  162. package/utils/image.d.ts +1 -0
  163. package/utils/keyboard.d.ts +1 -0
  164. package/utils/lodash.amd.js +2 -0
  165. package/utils/lodash.amd.js.map +1 -0
  166. package/utils/lodash.d.ts +2 -0
  167. package/utils/lodash.js +706 -0
  168. package/utils/lodash.js.map +1 -0
  169. package/utils/number.d.ts +1 -0
  170. package/utils/price.amd.js +1 -1
  171. package/utils/price.d.ts +1 -0
  172. package/utils/price.js +2 -2
  173. package/utils/route.d.ts +1 -0
  174. package/utils/scroll.d.ts +1 -0
  175. package/utils/store.d.ts +1 -0
  176. package/utils/string.amd.js +1 -1
  177. package/utils/string.d.ts +1 -0
  178. package/utils/string.js +1 -1
  179. package/utils/system.d.ts +1 -0
  180. package/utils/url.d.ts +1 -0
  181. package/.chunks/datepicker-CMuCkYBj.amd.js.map +0 -1
  182. package/.chunks/datepicker-CtcFJYEp.es.js.map +0 -1
  183. package/.chunks/forms-Cay_sybt.es.js.map +0 -1
  184. package/.chunks/forms-Lm1WM1gO.amd.js +0 -3
  185. package/.chunks/forms-Lm1WM1gO.amd.js.map +0 -1
  186. package/.chunks/i18n-eDh3Aaw9.amd.js +0 -2
  187. package/.chunks/i18n-qpB8zyhD.es.js +0 -20
  188. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-B3TjT92k.es.js +0 -161
  189. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-B3TjT92k.es.js.map +0 -1
  190. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-D1glM0F3.amd.js +0 -2
  191. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-D1glM0F3.amd.js.map +0 -1
  192. package/.chunks/menu-B3Nf7_NC.es.js.map +0 -1
  193. package/.chunks/menu-Dg2EKy3O.amd.js +0 -2
  194. package/.chunks/menu-Dg2EKy3O.amd.js.map +0 -1
  195. package/.chunks/popup-B7UOyCUj.es.js.map +0 -1
  196. package/.chunks/popup-BGuc5GyB.amd.js.map +0 -1
@@ -0,0 +1,35 @@
1
+ import { Props } from './prompt';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
+ declare function __VLS_template(): {
4
+ opener?(_: {}): any;
5
+ header?(_: {}): any;
6
+ default?(_: {}): any;
7
+ footer?(_: {}): any;
8
+ };
9
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<Props>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
10
+ open: () => void;
11
+ close: () => void;
12
+ scrollContentList: (value: Event) => void;
13
+ submit: (value: string) => void;
14
+ }, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<Props>>> & {
15
+ onSubmit?: ((value: string) => any) | undefined;
16
+ onClose?: (() => any) | undefined;
17
+ onOpen?: (() => any) | undefined;
18
+ onScrollContentList?: ((value: Event) => any) | undefined;
19
+ }, {}, {}>;
20
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
21
+ export default _default;
22
+ type __VLS_WithTemplateSlots<T, S> = T & {
23
+ new (): {
24
+ $slots: S;
25
+ };
26
+ };
27
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
28
+ type __VLS_TypePropsToOption<T> = {
29
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
30
+ type: PropType<__VLS_NonUndefinedable<T[K]>>;
31
+ } : {
32
+ type: PropType<T[K]>;
33
+ required: true;
34
+ };
35
+ };
@@ -1,4 +1,3 @@
1
1
  import { ComponentCustomProps } from 'vue';
2
2
  import { default as SelectorCompetitors } from './selectorCompetitors/selectorCompetitors.vue';
3
-
4
3
  export declare const TopSelectorCompetitors: typeof SelectorCompetitors & ComponentCustomProps;
@@ -1,5 +1,4 @@
1
1
  import { MaybeRefOrGetter, ComputedRef } from 'vue';
2
2
  import { Item } from './selectorCompetitors';
3
3
  import { Competitor } from './types/competitor';
4
-
5
4
  export declare const useItemsFromCompetitors: (competitors: MaybeRefOrGetter<Competitor[]>, projectId: MaybeRefOrGetter<number>) => ComputedRef<Item[]>;
@@ -1,5 +1,4 @@
1
1
  import { Props as ButtonProps } from '../../forms/button/button';
2
-
3
2
  export interface Props {
4
3
  /**
5
4
  * Выбранные элементы меню
@@ -1,27 +1,35 @@
1
- import { Props, Item } from './selectorCompetitors';
2
- import { DefineComponent, PropType, ComponentOptionsMixin, PublicProps, ExtractPropTypes } from 'vue';
3
-
4
- declare const _default: DefineComponent<{
5
- modelValue: PropType<Props["modelValue"]>;
6
- items: {
7
- type: PropType< Item[]>;
8
- required: true;
9
- };
10
- showSelectAllItem: {
11
- type: PropType<boolean>;
12
- default: boolean;
13
- };
14
- }, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
15
- modelValue: PropType<Props["modelValue"]>;
16
- items: {
17
- type: PropType< Item[]>;
18
- required: true;
19
- };
20
- showSelectAllItem: {
21
- type: PropType<boolean>;
22
- default: boolean;
23
- };
24
- }>>, {
1
+ import { Props } from './selectorCompetitors';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
+ declare let __VLS_typeProps: Props;
4
+ type __VLS_PublicProps = {
5
+ modelValue?: Props['modelValue'];
6
+ } & typeof __VLS_typeProps;
7
+ declare const _default: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
8
+ showSelectAllItem: boolean;
9
+ }>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
10
+ "update:modelValue": (modelValue: number[]) => void;
11
+ }, string, PublicProps, Readonly< ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
12
+ showSelectAllItem: boolean;
13
+ }>>> & {
14
+ "onUpdate:modelValue"?: ((modelValue: number[]) => any) | undefined;
15
+ }, {
25
16
  showSelectAllItem: boolean;
26
17
  }, {}>;
27
18
  export default _default;
19
+ type __VLS_WithDefaults<P, D> = {
20
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
21
+ default: D[K];
22
+ }> : P[K];
23
+ };
24
+ type __VLS_Prettify<T> = {
25
+ [K in keyof T]: T[K];
26
+ } & {};
27
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
28
+ type __VLS_TypePropsToOption<T> = {
29
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
30
+ type: PropType<__VLS_NonUndefinedable<T[K]>>;
31
+ } : {
32
+ type: PropType<T[K]>;
33
+ required: true;
34
+ };
35
+ };
@@ -1,14 +1,18 @@
1
1
  import { PropsContent } from './tabs';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
-
4
3
  declare function __VLS_template(): {
5
4
  default?(_: {}): any;
6
5
  };
7
- declare const __VLS_component: DefineComponent<__VLS_TypePropsToRuntimeProps<PropsContent>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToRuntimeProps<PropsContent>>>, {}, {}>;
6
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<PropsContent>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<PropsContent>>>, {}, {}>;
8
7
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
9
8
  export default _default;
9
+ type __VLS_WithTemplateSlots<T, S> = T & {
10
+ new (): {
11
+ $slots: S;
12
+ };
13
+ };
10
14
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
11
- type __VLS_TypePropsToRuntimeProps<T> = {
15
+ type __VLS_TypePropsToOption<T> = {
12
16
  [K in keyof T]-?: {} extends Pick<T, K> ? {
13
17
  type: PropType<__VLS_NonUndefinedable<T[K]>>;
14
18
  } : {
@@ -16,8 +20,3 @@ type __VLS_TypePropsToRuntimeProps<T> = {
16
20
  required: true;
17
21
  };
18
22
  };
19
- type __VLS_WithTemplateSlots<T, S> = T & {
20
- new (): {
21
- $slots: S;
22
- };
23
- };
@@ -1,14 +1,18 @@
1
1
  import { PropsTab } from './tabs';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
-
4
3
  declare function __VLS_template(): {
5
4
  default?(_: {}): any;
6
5
  };
7
- declare const __VLS_component: DefineComponent<__VLS_TypePropsToRuntimeProps<PropsTab>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToRuntimeProps<PropsTab>>>, {}, {}>;
6
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<PropsTab>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<PropsTab>>>, {}, {}>;
8
7
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
9
8
  export default _default;
9
+ type __VLS_WithTemplateSlots<T, S> = T & {
10
+ new (): {
11
+ $slots: S;
12
+ };
13
+ };
10
14
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
11
- type __VLS_TypePropsToRuntimeProps<T> = {
15
+ type __VLS_TypePropsToOption<T> = {
12
16
  [K in keyof T]-?: {} extends Pick<T, K> ? {
13
17
  type: PropType<__VLS_NonUndefinedable<T[K]>>;
14
18
  } : {
@@ -16,8 +20,3 @@ type __VLS_TypePropsToRuntimeProps<T> = {
16
20
  required: true;
17
21
  };
18
22
  };
19
- type __VLS_WithTemplateSlots<T, S> = T & {
20
- new (): {
21
- $slots: S;
22
- };
23
- };
@@ -1,16 +1,20 @@
1
1
  import { Props } from './tabs';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
-
4
3
  declare function __VLS_template(): {
5
4
  buttons?(_: {}): any;
6
5
  header?(_: {}): any;
7
6
  contents?(_: {}): any;
8
7
  };
9
- declare const __VLS_component: DefineComponent<__VLS_TypePropsToRuntimeProps<Props>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToRuntimeProps<Props>>>, {}, {}>;
8
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<Props>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<Props>>>, {}, {}>;
10
9
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
11
10
  export default _default;
11
+ type __VLS_WithTemplateSlots<T, S> = T & {
12
+ new (): {
13
+ $slots: S;
14
+ };
15
+ };
12
16
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
13
- type __VLS_TypePropsToRuntimeProps<T> = {
17
+ type __VLS_TypePropsToOption<T> = {
14
18
  [K in keyof T]-?: {} extends Pick<T, K> ? {
15
19
  type: PropType<__VLS_NonUndefinedable<T[K]>>;
16
20
  } : {
@@ -18,8 +22,3 @@ type __VLS_TypePropsToRuntimeProps<T> = {
18
22
  required: true;
19
23
  };
20
24
  };
21
- type __VLS_WithTemplateSlots<T, S> = T & {
22
- new (): {
23
- $slots: S;
24
- };
25
- };
@@ -2,7 +2,6 @@ import { ComponentCustomProps } from 'vue';
2
2
  import { default as Tabs } from './tabs/tabs.vue';
3
3
  import { default as TabsTab } from './tabs/tab.vue';
4
4
  import { default as TabsContent } from './tabs/content.vue';
5
-
6
5
  export declare const TopTabs: typeof Tabs & ComponentCustomProps;
7
6
  export declare const TopTabsTab: typeof TabsTab & ComponentCustomProps;
8
7
  export declare const TopTabsContent: typeof TabsContent & ComponentCustomProps;
@@ -1,20 +1,19 @@
1
- import { DefineComponent, PropType, ComponentOptionsMixin, PublicProps, ExtractPropTypes } from 'vue';
1
+ import { PropsMenu } from './tabsView';
2
+ import { ModelRef, DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
+ declare let __VLS_typeProps: PropsMenu;
4
+ declare const isLoading: ModelRef<unknown, string>;
5
+ type __VLS_PublicProps = {
6
+ 'isLoading'?: NonNullable<typeof isLoading['value']>;
7
+ } & typeof __VLS_typeProps;
2
8
  declare function __VLS_template(): {
3
9
  default?(_: {}): any;
10
+ default?(_: {}): any;
4
11
  };
5
- declare const __VLS_component: DefineComponent<{
6
- isLoading: PropType<any>;
7
- isShortable: {
8
- type: PropType<boolean | undefined>;
9
- required: true;
10
- };
11
- }, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
12
- isLoading: PropType<any>;
13
- isShortable: {
14
- type: PropType<boolean | undefined>;
15
- required: true;
16
- };
17
- }>>, {}, {}>;
12
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<__VLS_PublicProps>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
13
+ "update:isLoading": (isLoading: {}) => void;
14
+ }, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<__VLS_PublicProps>>> & {
15
+ "onUpdate:isLoading"?: ((isLoading: {}) => any) | undefined;
16
+ }, {}, {}>;
18
17
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
19
18
  export default _default;
20
19
  type __VLS_WithTemplateSlots<T, S> = T & {
@@ -22,3 +21,12 @@ type __VLS_WithTemplateSlots<T, S> = T & {
22
21
  $slots: S;
23
22
  };
24
23
  };
24
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
25
+ type __VLS_TypePropsToOption<T> = {
26
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
27
+ type: PropType<__VLS_NonUndefinedable<T[K]>>;
28
+ } : {
29
+ type: PropType<T[K]>;
30
+ required: true;
31
+ };
32
+ };
@@ -1,13 +1,13 @@
1
1
  import { PropsMenuItem } from './tabsView';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, Component, PropType } from 'vue';
3
-
4
3
  declare function __VLS_template(): {
5
4
  default?(_: {}): any;
5
+ default?(_: {}): any;
6
6
  };
7
- declare const __VLS_component: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<PropsMenuItem>, {
7
+ declare const __VLS_component: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<PropsMenuItem>, {
8
8
  scrollable: boolean;
9
9
  component: undefined;
10
- }>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<PropsMenuItem>, {
10
+ }>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<PropsMenuItem>, {
11
11
  scrollable: boolean;
12
12
  component: undefined;
13
13
  }>>>, {
@@ -16,15 +16,6 @@ declare const __VLS_component: DefineComponent<__VLS_WithDefaults<__VLS_TypeProp
16
16
  }, {}>;
17
17
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
18
18
  export default _default;
19
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
20
- type __VLS_TypePropsToRuntimeProps<T> = {
21
- [K in keyof T]-?: {} extends Pick<T, K> ? {
22
- type: PropType<__VLS_NonUndefinedable<T[K]>>;
23
- } : {
24
- type: PropType<T[K]>;
25
- required: true;
26
- };
27
- };
28
19
  type __VLS_WithDefaults<P, D> = {
29
20
  [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
30
21
  default: D[K];
@@ -38,3 +29,12 @@ type __VLS_WithTemplateSlots<T, S> = T & {
38
29
  $slots: S;
39
30
  };
40
31
  };
32
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
33
+ type __VLS_TypePropsToOption<T> = {
34
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
35
+ type: PropType<__VLS_NonUndefinedable<T[K]>>;
36
+ } : {
37
+ type: PropType<T[K]>;
38
+ required: true;
39
+ };
40
+ };
@@ -1,14 +1,19 @@
1
1
  import { PropsMenuTitle } from './tabsView';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
-
4
3
  declare function __VLS_template(): {
5
4
  default?(_: {}): any;
5
+ default?(_: {}): any;
6
6
  };
7
- declare const __VLS_component: DefineComponent<__VLS_TypePropsToRuntimeProps<PropsMenuTitle>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToRuntimeProps<PropsMenuTitle>>>, {}, {}>;
7
+ declare const __VLS_component: DefineComponent<__VLS_TypePropsToOption<PropsMenuTitle>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_TypePropsToOption<PropsMenuTitle>>>, {}, {}>;
8
8
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
9
9
  export default _default;
10
+ type __VLS_WithTemplateSlots<T, S> = T & {
11
+ new (): {
12
+ $slots: S;
13
+ };
14
+ };
10
15
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
11
- type __VLS_TypePropsToRuntimeProps<T> = {
16
+ type __VLS_TypePropsToOption<T> = {
12
17
  [K in keyof T]-?: {} extends Pick<T, K> ? {
13
18
  type: PropType<__VLS_NonUndefinedable<T[K]>>;
14
19
  } : {
@@ -16,8 +21,3 @@ type __VLS_TypePropsToRuntimeProps<T> = {
16
21
  required: true;
17
22
  };
18
23
  };
19
- type __VLS_WithTemplateSlots<T, S> = T & {
20
- new (): {
21
- $slots: S;
22
- };
23
- };
@@ -2,7 +2,6 @@ import { ModelRef, InjectionKey, Slot, Component, Directive, ComputedOptions, Me
2
2
  import { Props, Store, PropsMenuItem } from './tabsView';
3
3
  import { LooseRequired } from '@vue/shared';
4
4
  import { Store } from '../../../core/utils/store/store';
5
-
6
5
  export declare const injectionKey: InjectionKey<Store>;
7
6
  /**
8
7
  * Инициировать Store компонента
@@ -126,7 +125,7 @@ export declare const defineTabsStore: (props: Props, model: ModelRef<string | un
126
125
  __name: string;
127
126
  } | {
128
127
  props: ComponentPropsOptions<any>;
129
- emits: {} | never[];
128
+ emits: never[] | {};
130
129
  slots: Readonly<{
131
130
  [name: string]: Slot<any> | undefined;
132
131
  }>;
@@ -1,5 +1,4 @@
1
1
  import { Component } from 'vue';
2
-
3
2
  export interface Store {
4
3
  /**
5
4
  * Если true - меню будет скрыто в popup под кнопку, которая его открывает, на кнопке будет текст активного элемента меню
@@ -1,47 +1,47 @@
1
- import { DefineComponent, PropType, ComponentOptionsMixin, PublicProps, ExtractPropTypes } from 'vue';
1
+ import { Props } from './tabsView';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
+ declare let __VLS_typeProps: Props;
4
+ type __VLS_PublicProps = {
5
+ modelValue?: string;
6
+ } & typeof __VLS_typeProps;
2
7
  declare function __VLS_template(): {
3
8
  menu?(_: {}): any;
4
9
  };
5
- declare const __VLS_component: DefineComponent<{
6
- modelValue: PropType<string>;
7
- showMenuInPopup: {
8
- type: PropType<boolean>;
9
- default: undefined;
10
- };
11
- isShortable: {
12
- type: PropType<boolean>;
13
- default: boolean;
14
- };
15
- pageMod: {
16
- type: PropType<boolean>;
17
- };
18
- idState: {
19
- type: PropType<string>;
20
- };
21
- }, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
22
- modelValue: PropType<string>;
23
- showMenuInPopup: {
24
- type: PropType<boolean>;
25
- default: undefined;
26
- };
27
- isShortable: {
28
- type: PropType<boolean>;
29
- default: boolean;
30
- };
31
- pageMod: {
32
- type: PropType<boolean>;
33
- };
34
- idState: {
35
- type: PropType<string>;
36
- };
37
- }>>, {
10
+ declare const __VLS_component: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
11
+ showMenuInPopup: undefined;
12
+ isShortable: boolean;
13
+ }>, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
14
+ "update:modelValue": (modelValue: string) => void;
15
+ }, string, PublicProps, Readonly< ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
16
+ showMenuInPopup: undefined;
17
+ isShortable: boolean;
18
+ }>>> & {
19
+ "onUpdate:modelValue"?: ((modelValue: string) => any) | undefined;
20
+ }, {
38
21
  showMenuInPopup: boolean;
39
22
  isShortable: boolean;
40
23
  }, {}>;
41
24
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
42
25
  export default _default;
26
+ type __VLS_WithDefaults<P, D> = {
27
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
28
+ default: D[K];
29
+ }> : P[K];
30
+ };
31
+ type __VLS_Prettify<T> = {
32
+ [K in keyof T]: T[K];
33
+ } & {};
43
34
  type __VLS_WithTemplateSlots<T, S> = T & {
44
35
  new (): {
45
36
  $slots: S;
46
37
  };
47
38
  };
39
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
40
+ type __VLS_TypePropsToOption<T> = {
41
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
42
+ type: PropType<__VLS_NonUndefinedable<T[K]>>;
43
+ } : {
44
+ type: PropType<T[K]>;
45
+ required: true;
46
+ };
47
+ };
@@ -2,7 +2,6 @@ import { ComponentCustomProps } from 'vue';
2
2
  import { default as TabsView } from './tabsView/tabsView.vue';
3
3
  import { default as TabsViewMenuItem } from './tabsView/menuItem.vue';
4
4
  import { default as TabsViewMenuTitle } from './tabsView/menuTitle.vue';
5
-
6
5
  export declare const TopTabsView: typeof TabsView & ComponentCustomProps;
7
6
  export declare const TopTabsViewMenuItem: typeof TabsViewMenuItem & ComponentCustomProps;
8
7
  export declare const TopTabsViewMenuTitle: typeof TabsViewMenuTitle & ComponentCustomProps;
package/core/app.amd.js CHANGED
@@ -1,2 +1,2 @@
1
- define(["require","exports","../.chunks/forms-Lm1WM1gO.amd","../.chunks/i18n-eDh3Aaw9.amd","vue","lodash","../utils/clipboard.amd","../utils/string.amd","../utils/route.amd"],function(_,c,a,u,g,v,I,L,w){"use strict";if(typeof g>"u")var g=window.Vue;const E={mounted:function(s,t){t.value.disabled||s.focus()}};let h;const y={mounted(s,t,e){const o=t.value||"top-sticky";h=new IntersectionObserver(n=>{let i=n[0].intersectionRatio<1;i&&t.modifiers.bottom&&n[0].intersectionRect.y===0&&(i=!1),s.classList.toggle(o,i)},{threshold:[1]}),h.observe(s)},unmounted(s,t,e){h==null||h.disconnect()}};let S=!1,l;const f=new Map,O=(s,t)=>{const{distance:e,percent:o}=s.directiveSwipUpOptions,n=s.getBoundingClientRect().top,i=t*o/100/e,r=(t-n)/i;r<=e?s.style.transform=`translateY(${e-r}px)`:s.style.transform="translateY(0px)"},k=s=>{let t=window.innerHeight;window.addEventListener("scroll",()=>{f.forEach(e=>O(e,t))},{passive:!0}),l=new IntersectionObserver(e=>{t=window.innerHeight,e.forEach(o=>{const n=o.target;if(o.intersectionRatio<.1?f.delete(n):f.set(n,n),o.intersectionRatio===0){const{distance:i}=n.directiveSwipUpOptions;n.style.transform=`translateY(${i}px)`}})},{threshold:.1})},C={mounted(s,t,e){var o,n;a.Core.state.isMobileUA||(s.directiveSwipUpOptions={distance:((o=t.value)==null?void 0:o.distance)??100,percent:((n=t.value)==null?void 0:n.percent)??30},S||(k(),S=!0),l.observe(s))},unmounted(s,t,e){f.delete(s),l==null||l.unobserve(s)}},m=s=>{var t,e;if(!((e=(t=a.Core.$)==null?void 0:t.ui)!=null&&e.tooltip)){console.info("Для работы v-top-tooltip требуется глобальная загрузка jQuery UI Tooltip");return}return a.Core.$(s)},b=(s,t)=>{var o;const e=s.value??{};return e.content??=(o=t.props)==null?void 0:o.title,e.content=String(e.content).replace(/\r\n|\r|\n/g,"<br>"),e.position??={my:"bottom-18px",at:"top center"},e},N={mounted(s,t,e){var o;(o=m(s))==null||o.tooltip(b(t,e))},updated(s,t,e,o){var r;const n=b(t,e),i=(r=m(s))==null?void 0:r.tooltip("instance");i&&(i.options={...i.options,...n})},unmounted(s,t,e){var o;(o=m(s))==null||o.tooltip("destroy")}},H={install:(s,t)=>{s.config.globalProperties.$core=a.Core;for(const e in t)a.Core.state[e]=t[e];a.Core._setState(),s.directive("top-focus",E),s.directive("top-sticky",y),s.directive("top-swim-up",C),s.directive("top-tooltip",N),s.component("TopAvatar",a.TopAvatar),s.component("TopButton",a.TopButton$1),s.component("TopCheckbox",a.TopCheckbox),s.component("TopControlLabel",a.TopControlLabel),s.component("TopHint",a.TopHint),s.component("TopInput",a.TopInput$1),s.component("TopInputDate",a.TopInputDate),s.component("TopInputRange",a.TopInputRange),s.component("TopLoadbar",a.TopLoadbar),s.component("TopRadio",a.TopRadio),s.component("TopSelect",a.TopSelect),s.component("TopSwitcher",a.TopSwitcher),s.component("TopTextarea",a.TopTextarea)}};class P{#e;#t;#o;#n;#d;#s=[];#i=[];#p=[];#a=[];constructor(t){var o;this.#t=t.store,this.#e=this.#t.$id,this.#o=t.options.Page,this.#n=t.options.user,this.#d=t.options.Api,this.#s=t.options.tpaNamesUrlHash||[],this.#i=t.options.tpaNamesStorage||[],this.#p=t.options.tpaNamesStorageLocal||[],this.#a=t.options.tpaNamesGuestLink||[],t.store.genGuestLink=(n,i)=>this.genGuestLink(n,i),(o=this.#n.guest_data)!=null&&o.data||(this.#h(),this.#h(!0),this.#g()),this.#T(),this.#w();const e=v.debounce(()=>{this.#f(),this.#m()});t.store.$subscribe(e)}async genGuestLink(t,e){const o=this.#l();e=Object.assign(e,Object.fromEntries(o));const n=await this.#d.gen(t,"fetchColumn").call({},e);n!=null&&n.errors||(await I.setClipboard(n.result),alert("Link copied"))}#l(){const t=new Map;return this.#a.forEach(e=>{const o=L.camelToSnakeCase(e);t.set(o,this.#t[e])}),t}#r(t){if(Object.isFrozen(this))throw"Please, use setOptions only inner commit function";t.forEach((e,o)=>{const n=this.#t[o];if(e!=null&&e!=null&&e.constructor&&e.constructor===n.constructor){if(o.indexOf("date")===0&&!Array.isArray(e)){if(typeof e=="string"&&!/\d\d\d\d-\d\d-\d\d/.test(e))return}this.#t[o]=e}})}#u(t){const e=new Map;return t.forEach((o,n)=>{o!==null&&(o=JSON.stringify(o),e.set(n,o))}),e}#c(t){const e=new Map;return t.forEach((o,n)=>{if(!(o==null||o==="false")){try{if(typeof o=="string"&&!/^\d\d\d\d-\d\d-\d\d$/.test(o)&&(o=JSON.parse(o)),o==null||o==="false")return}catch{}e.set(n,o)}}),e}#g(){let t;try{t=JSON.parse(w.getHash(this.#e))}catch{}if(!t)return;const e=new Map;this.#s.forEach(n=>{const i=t[n];i&&e.set(n,i)});const o=this.#c(e);this.#r(o)}#f(){const t=new Map;this.#s.forEach(n=>{const i=this.#t[n];t.set(n,i)});const e=Object.fromEntries(t),o=JSON.stringify(e);w.setHash(this.#e,o)}#h(t=!1){const e=new Map;let o="state:"+this.#e;t&&(o="state:"+this.#e+":"+location.pathname),this.#i.forEach(i=>{const r=localStorage.getItem(o+":"+i);e.set(i,r)});const n=this.#c(e);this.#r(n)}#m(t=!1){const e=new Map;let o=this.#i,n="state:"+this.#e;t&&(o=this.#p,n="state:"+this.#e+":"+location.pathname),o.forEach(r=>{const d=this.#t[r];e.set(r,d)});const i=this.#u(e);o.forEach(r=>{const d=i.get(r);localStorage.setItem(n+":"+r,d)})}#T(){var i,r,d;const t=(r=(i=this.#n)==null?void 0:i.guest_data)==null?void 0:r.data;if(!t)return;this.#n.id===-1&&(this.#n.positionsReverseDates=t.positionsReverseDates);const e=new Map;this.#a.forEach(p=>{const T=t[p];e.set(p,T)});const o=this.#c(e);this.#r(o);const n=$(".mod_guest_title");if(((d=this.#t.competitorsIds)==null?void 0:d.length)===1&&this.#o.page.data.competitors){let p=this.#o.page.data.competitors.filter(T=>T.id===t.competitorsIds[0]);p.length&&($("a",n).attr("href","http://"+p[0].url),$("a",n).text(p[0].name))}}#w(){this.#t.regionsIndexes&&g.watch(this.#t,t=>{if(!t.length)return;t.forEach((n,i)=>t[i]=n);const e=TplProjectSelectorRegion.genSearchersMap(),o=[];e.forEach(n=>{n.regions.forEach(i=>{i.index!==-1&&o.push(i.index)})}),this.#t.regionsIndexes=t.filter(n=>o.includes(n))},{immediate:!0}),this.#t.competitorsIds&&g.watch(this.#t,t=>{if(!t.length)return;t.forEach((o,n)=>o[n]=o);const e=[this.#o.page.data.project.id];this.#o.page.data.project.competitors.forEach(o=>{o.on>=0&&e.push(o.id)}),this.#t.competitorsIds=t.filter(o=>e.includes(o))})}}const R=s=>{var e,o,n,i;const t=s;!((e=t.options.tpaNamesUrlHash)!=null&&e.length)&&!((o=t.options.tpaNamesStorage)!=null&&o.length)&&!((n=t.options.tpaNamesStorageLocal)!=null&&n.length)&&!((i=t.options.tpaNamesGuestLink)!=null&&i.length)||new P(t)};c.Core=a.Core,c.i18nPlugin=u.i18n,c.useI18n=u.useI18n,c.useI18nLang=u.useI18nLang,c.useI18nSetLang=u.useI18nSetLang,c.corePlugin=H,c.piniaTPAPlugin=R,Object.defineProperty(c,Symbol.toStringTag,{value:"Module"})});
1
+ define(["require","exports","../.chunks/forms-ZqLh7cu5.amd","../.chunks/i18n-C_OH9IT3.amd","vue","../.chunks/debounce-4ipCj607.amd","../utils/clipboard.amd","../utils/string.amd","../utils/route.amd"],function(R,c,a,u,g,v,I,E,T){"use strict";if(typeof g>"u")var g=window.Vue;const L={mounted:function(s,t){t.value.disabled||s.focus()}};let h;const y={mounted(s,t,e){const o=t.value||"top-sticky";h=new IntersectionObserver(n=>{let i=n[0].intersectionRatio<1;i&&t.modifiers.bottom&&n[0].intersectionRect.y===0&&(i=!1),s.classList.toggle(o,i)},{threshold:[1]}),h.observe(s)},unmounted(s,t,e){h==null||h.disconnect()}};let S=!1,l;const f=new Map,k=(s,t)=>{const{distance:e,percent:o}=s.directiveSwipUpOptions,n=s.getBoundingClientRect().top,i=t*o/100/e,r=(t-n)/i;r<=e?s.style.transform=`translateY(${e-r}px)`:s.style.transform="translateY(0px)"},O=s=>{let t=window.innerHeight;window.addEventListener("scroll",()=>{f.forEach(e=>k(e,t))},{passive:!0}),l=new IntersectionObserver(e=>{t=window.innerHeight,e.forEach(o=>{const n=o.target;if(o.intersectionRatio<.1?f.delete(n):f.set(n,n),o.intersectionRatio===0){const{distance:i}=n.directiveSwipUpOptions;n.style.transform=`translateY(${i}px)`}})},{threshold:.1})},C={mounted(s,t,e){var o,n;a.Core.state.isMobileUA||(s.directiveSwipUpOptions={distance:((o=t.value)==null?void 0:o.distance)??100,percent:((n=t.value)==null?void 0:n.percent)??30},S||(O(),S=!0),l.observe(s))},unmounted(s,t,e){f.delete(s),l==null||l.unobserve(s)}},m=s=>{var t,e;if(!((e=(t=a.Core.$)==null?void 0:t.ui)!=null&&e.tooltip)){console.info("Для работы v-top-tooltip требуется глобальная загрузка jQuery UI Tooltip");return}return a.Core.$(s)},b=(s,t)=>{var o;const e=s.value??{};return e.content??=(o=t.props)==null?void 0:o.title,e.content=String(e.content).replace(/\r\n|\r|\n/g,"<br>"),e.position??={my:"bottom-18px",at:"top center"},e},N={mounted(s,t,e){var o;(o=m(s))==null||o.tooltip(b(t,e))},updated(s,t,e,o){var r;const n=b(t,e),i=(r=m(s))==null?void 0:r.tooltip("instance");i&&(i.options={...i.options,...n})},unmounted(s,t,e){var o;(o=m(s))==null||o.tooltip("destroy")}},_={install:(s,t)=>{s.config.globalProperties.$core=a.Core;for(const e in t)a.Core.state[e]=t[e];a.Core._setState(),s.directive("top-focus",L),s.directive("top-sticky",y),s.directive("top-swim-up",C),s.directive("top-tooltip",N),s.component("TopAvatar",a.TopAvatar),s.component("TopButton",a.TopButton$1),s.component("TopCheckbox",a.TopCheckbox),s.component("TopControlLabel",a.TopControlLabel),s.component("TopHint",a.TopHint),s.component("TopInput",a.TopInput),s.component("TopInputDate",a.TopInputDate),s.component("TopInputRange",a.TopInputRange),s.component("TopLoadbar",a.TopLoadbar),s.component("TopRadio",a.TopRadio),s.component("TopSelect",a.TopSelect),s.component("TopSwitcher",a.TopSwitcher),s.component("TopTextarea",a.TopTextarea)}};class H{#e;#t;#o;#n;#d;#s=[];#i=[];#p=[];#a=[];constructor(t){var o;this.#t=t.store,this.#e=this.#t.$id,this.#o=t.options.Page,this.#n=t.options.user,this.#d=t.options.Api,this.#s=t.options.tpaNamesUrlHash||[],this.#i=t.options.tpaNamesStorage||[],this.#p=t.options.tpaNamesStorageLocal||[],this.#a=t.options.tpaNamesGuestLink||[],t.store.genGuestLink=(n,i)=>this.genGuestLink(n,i),(o=this.#n.guest_data)!=null&&o.data||(this.#h(),this.#h(!0),this.#g()),this.#w(),this.#T();const e=v.debounce(()=>{this.#f(),this.#m()});t.store.$subscribe(e)}async genGuestLink(t,e){const o=this.#l();e=Object.assign(e,Object.fromEntries(o));const n=await this.#d.gen(t,"fetchColumn").call({},e);n!=null&&n.errors||(await I.setClipboard(n.result),window.requirejs&&window.requirejs(["es6!@/component/utils/info.ts"],({showInfo:i})=>{i("Гостевая ссылка скопирована в буфер обмена"+': <a href="'+n.result+'" target="_blank">'+n.result+"</a>",n.result,3)}))}#l(){const t=new Map;return this.#a.forEach(e=>{const o=E.camelToSnakeCase(e);t.set(o,this.#t[e])}),t}#r(t){if(Object.isFrozen(this))throw"Please, use setOptions only inner commit function";t.forEach((e,o)=>{const n=this.#t[o];if(e!=null&&e!=null&&e.constructor&&e.constructor===n.constructor){if(o.indexOf("date")===0&&!Array.isArray(e)){if(typeof e=="string"&&!/\d\d\d\d-\d\d-\d\d/.test(e))return}this.#t[o]=e}})}#u(t){const e=new Map;return t.forEach((o,n)=>{o!==null&&(o=JSON.stringify(o),e.set(n,o))}),e}#c(t){const e=new Map;return t.forEach((o,n)=>{if(!(o==null||o==="false")){try{if(typeof o=="string"&&!/^\d\d\d\d-\d\d-\d\d$/.test(o)&&(o=JSON.parse(o)),o==null||o==="false")return}catch{}e.set(n,o)}}),e}#g(){let t;try{t=JSON.parse(T.getHash(this.#e))}catch{}if(!t)return;const e=new Map;this.#s.forEach(n=>{const i=t[n];i&&e.set(n,i)});const o=this.#c(e);this.#r(o)}#f(){const t=new Map;this.#s.forEach(n=>{const i=this.#t[n];t.set(n,i)});const e=Object.fromEntries(t),o=JSON.stringify(e);T.setHash(this.#e,o)}#h(t=!1){const e=new Map;let o="state:"+this.#e;t&&(o="state:"+this.#e+":"+location.pathname),this.#i.forEach(i=>{const r=localStorage.getItem(o+":"+i);e.set(i,r)});const n=this.#c(e);this.#r(n)}#m(t=!1){const e=new Map;let o=this.#i,n="state:"+this.#e;t&&(o=this.#p,n="state:"+this.#e+":"+location.pathname),o.forEach(r=>{const d=this.#t[r];e.set(r,d)});const i=this.#u(e);o.forEach(r=>{const d=i.get(r);localStorage.setItem(n+":"+r,d)})}#w(){var i,r,d;const t=(r=(i=this.#n)==null?void 0:i.guest_data)==null?void 0:r.data;if(!t)return;this.#n.id===-1&&(this.#n.positionsReverseDates=t.positionsReverseDates);const e=new Map;this.#a.forEach(p=>{const w=t[p];e.set(p,w)});const o=this.#c(e);this.#r(o);const n=$(".mod_guest_title");if(((d=this.#t.competitorsIds)==null?void 0:d.length)===1&&this.#o.page.data.competitors){let p=this.#o.page.data.competitors.filter(w=>w.id===t.competitorsIds[0]);p.length&&($("a",n).attr("href","http://"+p[0].url),$("a",n).text(p[0].name))}}#T(){this.#t.regionsIndexes&&g.watch(this.#t,t=>{if(!t.length)return;t.forEach((n,i)=>t[i]=n);const e=TplProjectSelectorRegion.genSearchersMap(),o=[];e.forEach(n=>{n.regions.forEach(i=>{i.index!==-1&&o.push(i.index)})}),this.#t.regionsIndexes=t.filter(n=>o.includes(n))},{immediate:!0}),this.#t.competitorsIds&&g.watch(this.#t,t=>{if(!t.length)return;t.forEach((o,n)=>o[n]=o);const e=[this.#o.page.data.project.id];this.#o.page.data.project.competitors.forEach(o=>{o.on>=0&&e.push(o.id)}),this.#t.competitorsIds=t.filter(o=>e.includes(o))})}}const P=s=>{var e,o,n,i;const t=s;!((e=t.options.tpaNamesUrlHash)!=null&&e.length)&&!((o=t.options.tpaNamesStorage)!=null&&o.length)&&!((n=t.options.tpaNamesStorageLocal)!=null&&n.length)&&!((i=t.options.tpaNamesGuestLink)!=null&&i.length)||new H(t)};c.Core=a.Core,c.i18nPlugin=u.i18n,c.useI18n=u.useI18n,c.useI18nLang=u.useI18nLang,c.useI18nSetLang=u.useI18nSetLang,c.corePlugin=_,c.piniaTPAPlugin=P,Object.defineProperty(c,Symbol.toStringTag,{value:"Module"})});
2
2
  //# sourceMappingURL=app.amd.js.map