@useinsider/guido 3.17.0-beta.3e9d6e7 → 3.17.0-beta.3ff6ea0

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 (111) hide show
  1. package/README.md +0 -1
  2. package/dist/@types/config/schemas.js +6 -12
  3. package/dist/components/Guido.vue.js +6 -6
  4. package/dist/components/Guido.vue2.js +61 -63
  5. package/dist/composables/useCustomInterfaceAppearance.js +16 -19
  6. package/dist/composables/useRecommendation.js +34 -41
  7. package/dist/composables/useStripo.js +14 -14
  8. package/dist/config/migrator/index.js +9 -8
  9. package/dist/config/migrator/recommendation/compositionMapper.js +20 -20
  10. package/dist/config/migrator/recommendation/extractors.js +29 -24
  11. package/dist/config/migrator/recommendation/htmlBuilder.js +116 -130
  12. package/dist/config/migrator/recommendationMigrator.js +16 -15
  13. package/dist/config/migrator/recommendationTitleMigrator.js +119 -0
  14. package/dist/enums/date.js +3 -4
  15. package/dist/enums/extensions/recommendationBlock.js +23 -25
  16. package/dist/extensions/Blocks/Recommendation/constants/blockIds.js +1 -1
  17. package/dist/extensions/Blocks/Recommendation/constants/controlIds.js +1 -1
  18. package/dist/extensions/Blocks/Recommendation/constants/defaultConfig.js +20 -21
  19. package/dist/extensions/Blocks/Recommendation/constants/selectors.js +34 -28
  20. package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +306 -238
  21. package/dist/extensions/Blocks/Recommendation/controls/main/index.js +95 -122
  22. package/dist/extensions/Blocks/Recommendation/controls/main/utils.js +1 -0
  23. package/dist/extensions/Blocks/Recommendation/controls/title/index.js +44 -0
  24. package/dist/extensions/Blocks/Recommendation/extension.js +31 -29
  25. package/dist/extensions/Blocks/Recommendation/settingsPanel.js +23 -4
  26. package/dist/extensions/Blocks/Recommendation/store/recommendation.js +53 -199
  27. package/dist/extensions/Blocks/Recommendation/templates/grid/template.js +3 -3
  28. package/dist/extensions/Blocks/Recommendation/templates/titleRows.js +33 -0
  29. package/dist/extensions/Blocks/Recommendation/templates/utils.js +85 -107
  30. package/dist/extensions/Blocks/common-control.js +19 -22
  31. package/dist/guido.css +1 -1
  32. package/dist/services/recommendationApi.js +28 -77
  33. package/dist/src/@types/config/schemas.d.ts +0 -12
  34. package/dist/src/composables/useConfig.d.ts +0 -2
  35. package/dist/src/composables/useRecommendation.d.ts +0 -1
  36. package/dist/src/config/migrator/recommendation/extractors.d.ts +8 -0
  37. package/dist/src/config/migrator/recommendationTitleMigrator.d.ts +5 -0
  38. package/dist/src/enums/extensions/recommendationBlock.d.ts +0 -2
  39. package/dist/src/extensions/Blocks/Recommendation/constants/blockIds.d.ts +2 -1
  40. package/dist/src/extensions/Blocks/Recommendation/constants/controlIds.d.ts +7 -0
  41. package/dist/src/extensions/Blocks/Recommendation/constants/defaultConfig.d.ts +1 -0
  42. package/dist/src/extensions/Blocks/Recommendation/constants/index.d.ts +1 -1
  43. package/dist/src/extensions/Blocks/Recommendation/constants/selectors.d.ts +10 -0
  44. package/dist/src/extensions/Blocks/Recommendation/controls/cardComposition/index.d.ts +10 -0
  45. package/dist/src/extensions/Blocks/Recommendation/controls/index.d.ts +1 -0
  46. package/dist/src/extensions/Blocks/Recommendation/controls/main/index.d.ts +3 -12
  47. package/dist/src/extensions/Blocks/Recommendation/controls/main/utils.d.ts +1 -0
  48. package/dist/src/extensions/Blocks/Recommendation/controls/title/index.d.ts +86 -0
  49. package/dist/src/extensions/Blocks/Recommendation/store/recommendation.d.ts +10 -210
  50. package/dist/src/extensions/Blocks/Recommendation/templates/titleRows.d.ts +13 -0
  51. package/dist/src/extensions/Blocks/Recommendation/types/nodeConfig.d.ts +0 -6
  52. package/dist/src/extensions/Blocks/common-control.d.ts +1 -4
  53. package/dist/src/services/recommendationApi.d.ts +1 -4
  54. package/dist/src/stores/config.d.ts +0 -18
  55. package/dist/static/styles/customEditorStyle.css.js +3 -1
  56. package/dist/utils/dateUtil.js +10 -23
  57. package/dist/utils/templatePreparation.js +34 -37
  58. package/package.json +1 -2
  59. package/dist/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue.js +0 -18
  60. package/dist/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue2.js +0 -67
  61. package/dist/components/organisms/extensions/recommendation/StrategyInfoBox.vue.js +0 -20
  62. package/dist/components/organisms/extensions/recommendation/StrategyInfoBox.vue2.js +0 -55
  63. package/dist/extensions/Blocks/Recommendation/controls/main/strategy.js +0 -132
  64. package/dist/node_modules/@useinsider/design-system-organisms/dist/index-Dc9AygoZ.js +0 -526
  65. package/dist/node_modules/@useinsider/design-system-organisms/dist/index.js +0 -9345
  66. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InAccordion.js +0 -174
  67. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InBasicTextInput.js +0 -381
  68. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InBox.js +0 -236
  69. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InBulkActions.js +0 -70
  70. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InButton.js +0 -350
  71. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InButtonV2.js +0 -371
  72. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InCheckBox.js +0 -152
  73. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InChips.js +0 -141
  74. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InCustomDropDown.js +0 -1047
  75. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InDataTableV2.js +0 -96050
  76. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InDatePicker.js +0 -2042
  77. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InDrawer.js +0 -166
  78. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InDropDown.js +0 -1098
  79. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InIcons.js +0 -55
  80. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InInfoBox.js +0 -265
  81. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InLinks.js +0 -184
  82. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InLoading.js +0 -50
  83. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InModals.js +0 -453
  84. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InNoData.js +0 -145
  85. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InOnPageMessage.js +0 -176
  86. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InProgress.js +0 -266
  87. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InRadioButton.js +0 -114
  88. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InSegments.js +0 -200
  89. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InSelect.js +0 -451
  90. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InSkeleton.js +0 -49
  91. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InStatusText.js +0 -119
  92. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InTabs.js +0 -4309
  93. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InTagsText.js +0 -129
  94. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InTextInput.js +0 -503
  95. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InToasts.js +0 -253
  96. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InToggle.js +0 -107
  97. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InTooltip.js +0 -134
  98. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/InTooltipV2.js +0 -464
  99. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/_commonjsHelpers.BItOPCY9.js +0 -28
  100. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/_plugin-vue2_normalizer.WQT2Fc8L.js +0 -23
  101. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/clickOutside.qP9M0QCm.js +0 -29
  102. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/helpers.CgHNyjAJ.js +0 -109
  103. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/index.Bw_06igr.js +0 -2339
  104. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/localLocalesMixin.DYMhydo2.js +0 -16
  105. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/useLocalLocales.Ckuhy7d-.js +0 -17
  106. package/dist/node_modules/@useinsider/design-system-organisms/node_modules/@useinsider/design-system-vue/dist/chunks/vue-property-decorator.BtlM7Epa.js +0 -188
  107. package/dist/src/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue.d.ts +0 -3
  108. package/dist/src/components/organisms/extensions/recommendation/StrategyInfoBox.vue.d.ts +0 -24
  109. package/dist/src/extensions/Blocks/Recommendation/controls/main/strategy.d.ts +0 -37
  110. package/dist/src/mock/api/recommendation-strategies.d.ts +0 -43
  111. package/dist/static/styles/components/recommendation-strategy.css.js +0 -171
@@ -1,200 +0,0 @@
1
- import { InIcons as r } from "./InIcons.js";
2
- import { InTooltip as _ } from "./InTooltip.js";
3
- import { InSkeleton as p } from "./InSkeleton.js";
4
- import { n as a } from "./chunks/_plugin-vue2_normalizer.WQT2Fc8L.js";
5
- /* empty css */
6
- const l = "_in-segments-wrapper_v01428_jcUep", g = "_in-segments-wrapper_1_v01428_KSjhH", o = "_in-segments-wrapper_2_v01428_2iPZg", m = "_in-segments-wrapper_3_v01428_BkryD", w = "_in-segments-wrapper_4_v01428_rgpMk", c = "_in-segments-wrapper_5_v01428_2qFIT", u = "_in-segments-wrapper_6_v01428_WJGwb", b = "_in-segments-wrapper_7_v01428_-Dmhj", d = "_in-segments-wrapper__button_v01428_qeBIT", v = "_in-segments-wrapper__button__title_v01428_BEK7A", S = "_in-segments-wrapper__button__description_v01428_d3zCc", h = "_in-segments-wrapper__button_disable_v01428_L1-8E", f = "_in-segments-wrapper__button_selected_v01428_FObt7", y = "_in-segments-wrapper__button_small_v01428_NYVw5", $ = "_in-segments-wrapper_disable_v01428_ltfhv", W = "_in-segments-wrapper_vertical_v01428_RTN8K", C = "_in-segments-wrapper_single_v01428_X4F6V", I = "_in-segments-wrapper__tooltip-align-right_v01428_pCoD-", B = "_in-segments-wrapper__tooltip-align-center_v01428_y8GSe", k = {
7
- "in-segments-wrapper": "_in-segments-wrapper_v01428_jcUep",
8
- inSegmentsWrapper: l,
9
- "in-segments-wrapper_1": "_in-segments-wrapper_1_v01428_KSjhH",
10
- inSegmentsWrapper1: g,
11
- "in-segments-wrapper_2": "_in-segments-wrapper_2_v01428_2iPZg",
12
- inSegmentsWrapper2: o,
13
- "in-segments-wrapper_3": "_in-segments-wrapper_3_v01428_BkryD",
14
- inSegmentsWrapper3: m,
15
- "in-segments-wrapper_4": "_in-segments-wrapper_4_v01428_rgpMk",
16
- inSegmentsWrapper4: w,
17
- "in-segments-wrapper_5": "_in-segments-wrapper_5_v01428_2qFIT",
18
- inSegmentsWrapper5: c,
19
- "in-segments-wrapper_6": "_in-segments-wrapper_6_v01428_WJGwb",
20
- inSegmentsWrapper6: u,
21
- "in-segments-wrapper_7": "_in-segments-wrapper_7_v01428_-Dmhj",
22
- inSegmentsWrapper7: b,
23
- "in-segments-wrapper__button": "_in-segments-wrapper__button_v01428_qeBIT",
24
- inSegmentsWrapperButton: d,
25
- "in-segments-wrapper__button__title": "_in-segments-wrapper__button__title_v01428_BEK7A",
26
- inSegmentsWrapperButtonTitle: v,
27
- "in-segments-wrapper__button__description": "_in-segments-wrapper__button__description_v01428_d3zCc",
28
- inSegmentsWrapperButtonDescription: S,
29
- "in-segments-wrapper__button_disable": "_in-segments-wrapper__button_disable_v01428_L1-8E",
30
- inSegmentsWrapperButtonDisable: h,
31
- "in-segments-wrapper__button_selected": "_in-segments-wrapper__button_selected_v01428_FObt7",
32
- inSegmentsWrapperButtonSelected: f,
33
- "in-segments-wrapper__button_small": "_in-segments-wrapper__button_small_v01428_NYVw5",
34
- inSegmentsWrapperButtonSmall: y,
35
- "in-segments-wrapper_disable": "_in-segments-wrapper_disable_v01428_ltfhv",
36
- inSegmentsWrapperDisable: $,
37
- "in-segments-wrapper_vertical": "_in-segments-wrapper_vertical_v01428_RTN8K",
38
- inSegmentsWrapperVertical: W,
39
- "in-segments-wrapper_single": "_in-segments-wrapper_single_v01428_X4F6V",
40
- inSegmentsWrapperSingle: C,
41
- "in-segments-wrapper__tooltip-align-right": "_in-segments-wrapper__tooltip-align-right_v01428_pCoD-",
42
- inSegmentsWrapperTooltipAlignRight: I,
43
- "in-segments-wrapper__tooltip-align-center": "_in-segments-wrapper__tooltip-align-center_v01428_y8GSe",
44
- inSegmentsWrapperTooltipAlignCenter: B
45
- }, T = {
46
- components: {
47
- InIcons: r,
48
- InTooltip: _,
49
- InSkeleton: p
50
- },
51
- props: {
52
- /**
53
- * @property {string} id
54
- */
55
- id: {
56
- type: String,
57
- default: "qa-segments"
58
- },
59
- /**
60
- * @property {array} segmentList
61
- */
62
- segmentList: {
63
- type: Array,
64
- required: !0
65
- },
66
- /**
67
- * @property {string|number} selected
68
- */
69
- selected: {
70
- type: String | Number,
71
- default: ""
72
- },
73
- /**
74
- * @property {boolean} withIcon
75
- */
76
- withIcon: {
77
- type: Boolean,
78
- default: !1
79
- },
80
- /**
81
- * @property {boolean} small
82
- */
83
- small: {
84
- type: Boolean,
85
- default: !1
86
- },
87
- /**
88
- * @property {boolean} disable
89
- */
90
- disable: {
91
- type: Boolean,
92
- default: !1
93
- },
94
- /**
95
- * @property {string} align
96
- */
97
- align: {
98
- type: String,
99
- default: "horizontal"
100
- },
101
- /**
102
- * @property {boolean} skeletonStatus
103
- */
104
- skeletonStatus: {
105
- type: Boolean,
106
- default: !1
107
- },
108
- /**
109
- * @property {number} skeletonSizing
110
- */
111
- skeletonSizing: {
112
- type: Object,
113
- default: () => ({
114
- width: 0,
115
- number: 0
116
- })
117
- }
118
- },
119
- computed: {
120
- /**
121
- * @return {number}
122
- */
123
- segmentLength() {
124
- return this.segmentList.length;
125
- },
126
- /**
127
- * @return {boolean}
128
- */
129
- isSingleSegment() {
130
- return this.segmentLength === 1;
131
- },
132
- isVertical() {
133
- return this.align === "vertical";
134
- },
135
- iconSize() {
136
- return this.isVertical ? "40" : "24";
137
- }
138
- },
139
- methods: {
140
- /**
141
- * @param {string} value
142
- * @param {disable} boolean
143
- * @return {boolean}
144
- */
145
- selectSegment({ value: e, disable: t }) {
146
- if (t || this.disable)
147
- return !1;
148
- this.$emit("click", e);
149
- }
150
- }
151
- };
152
- var z = function() {
153
- var e = this, t = e._self._c;
154
- return t("div", { staticClass: "in-segments-wrapper qa-segments", class: [
155
- e.$style["in-segments-wrapper"],
156
- `in-segments-wrapper_${e.segmentLength}`,
157
- e.$style[`in-segments-wrapper_${e.segmentLength}`],
158
- { "in-segments-wrapper_vertical": e.isVertical },
159
- { [e.$style["in-segments-wrapper_vertical"]]: e.isVertical },
160
- { "in-segments-wrapper_disable": e.disable },
161
- { [e.$style["in-segments-wrapper_disable"]]: e.disable },
162
- { "in-segments-wrapper_single": e.isSingleSegment },
163
- { [e.$style["in-segments-wrapper_single"]]: e.isSingleSegment }
164
- ] }, [e._l(e.segmentList, function(s, i) {
165
- return e.skeletonStatus ? e._e() : t("button", { key: i, staticClass: "in-segments-wrapper__button", class: [
166
- e.$style["in-segments-wrapper__button"],
167
- { "in-segments-wrapper__button_selected": s.value === e.selected },
168
- { [e.$style["in-segments-wrapper__button_selected"]]: s.value === e.selected },
169
- { "in-segments-wrapper__button_small": e.small },
170
- { [e.$style["in-segments-wrapper__button_small"]]: e.small },
171
- { "in-segments-wrapper__button_disable": s.disable || e.disable },
172
- { [e.$style["in-segments-wrapper__button_disable"]]: s.disable || e.disable },
173
- { "in-segments-wrapper__tooltip-align-right": s.tooltipAlignRight },
174
- { [e.$style["in-segments-wrapper__tooltip-align-right"]]: s.tooltipAlignRight },
175
- { "in-segments-wrapper__tooltip-align-center": s.tooltipAlignCenter },
176
- { [e.$style["in-segments-wrapper__tooltip-align-center"]]: s.tooltipAlignCenter },
177
- `${e.id}-${s.value}`
178
- ], attrs: { type: "button", value: s.value }, on: { click: function(D) {
179
- return e.selectSegment(s);
180
- } } }, [s.tooltipText ? t("in-tooltip", { attrs: { text: s.tooltipText, position: s.position || "top", align: s.align || "start", "with-icon": !1 } }, [t("div", { class: { "cur-p": !s.disable && !e.disable }, attrs: { slot: "element" }, slot: "element" }, [t("span", { staticClass: "w-1 h-1 d-b" }, [t("span", { staticClass: "clearfix d-i-f" }, [e.withIcon ? t("in-icons", { staticClass: "mr-1", attrs: { name: s.icon, size: e.iconSize } }) : e._e(), t("span", [t("span", { staticClass: "in-segments-wrapper__button__title d-b", class: e.$style["in-segments-wrapper__button__title"] }, [e._v(" " + e._s(s.text) + " ")]), e.isVertical ? t("span", { staticClass: "in-segments-wrapper__button__description d-b", class: e.$style["in-segments-wrapper__button__description"] }, [e._v(" " + e._s(s.description) + " ")]) : e._e()])], 1)])])]) : t("span", { staticClass: "w-1 h-1 d-b" }, [t("span", { staticClass: "clearfix d-i-f" }, [e.withIcon ? t("in-icons", { staticClass: "mr-1", attrs: { name: s.icon, size: e.iconSize } }) : e._e(), t("span", [t("span", { staticClass: "in-segments-wrapper__button__title d-b", class: e.$style["in-segments-wrapper__button__title"] }, [e._v(" " + e._s(s.text) + " ")]), e.isVertical ? t("span", { staticClass: "in-segments-wrapper__button__description d-b", class: e.$style["in-segments-wrapper__button__description"] }, [e._v(" " + e._s(s.description) + " ")]) : e._e()])], 1)])], 1);
181
- }), e.skeletonStatus ? t("in-skeleton", { attrs: { sizing: e.skeletonSizing, name: "InSegments" } }) : e._e()], 2);
182
- }, V = [];
183
- const n = {
184
- $style: k
185
- };
186
- function x(e) {
187
- for (var t in n)
188
- this[t] = n[t];
189
- }
190
- var A = /* @__PURE__ */ a(
191
- T,
192
- z,
193
- V,
194
- !1,
195
- x
196
- );
197
- const N = A.exports;
198
- export {
199
- N as InSegments
200
- };
@@ -1,451 +0,0 @@
1
- import { I as _, c as h } from "./chunks/index.Bw_06igr.js";
2
- import { c as S } from "./chunks/clickOutside.qP9M0QCm.js";
3
- import { p as f, j as a, i as m } from "./chunks/helpers.CgHNyjAJ.js";
4
- import { InSkeleton as r } from "./InSkeleton.js";
5
- import { InIcons as c } from "./InIcons.js";
6
- import { InTooltipV2 as b } from "./InTooltipV2.js";
7
- import { n as d } from "./chunks/_plugin-vue2_normalizer.WQT2Fc8L.js";
8
- /* empty css */
9
- const g = {
10
- components: {
11
- InIcons: c,
12
- InSkeleton: r
13
- },
14
- props: {
15
- /**
16
- * @property {string} id
17
- */
18
- id: {
19
- type: String,
20
- required: !0
21
- },
22
- /**
23
- * @property {string|number} text
24
- */
25
- text: {
26
- type: String | Number,
27
- required: !0
28
- },
29
- /**
30
- * @property {string|number|boolean} value
31
- */
32
- value: {
33
- type: String | Number | Boolean,
34
- default: ""
35
- },
36
- /**
37
- * @property {string} icon
38
- */
39
- icon: {
40
- type: String,
41
- default: ""
42
- },
43
- /**
44
- * @property {boolean} disable
45
- */
46
- disable: {
47
- type: Boolean,
48
- default: !1
49
- },
50
- /**
51
- * @property {boolean} isPlaceholderText
52
- */
53
- isPlaceholderText: {
54
- type: Boolean,
55
- default: !1
56
- },
57
- /**
58
- * @property {string} theme
59
- */
60
- theme: {
61
- type: String,
62
- default: "grey"
63
- },
64
- /**
65
- * @property {string} status
66
- */
67
- status: {
68
- type: String,
69
- default: "default"
70
- },
71
- /**
72
- * @property {boolean} skeletonStatus
73
- */
74
- skeletonStatus: {
75
- type: Boolean,
76
- default: !1
77
- },
78
- /**
79
- * @property {number} skeletonSizing
80
- */
81
- skeletonSizing: {
82
- type: Object,
83
- default: () => ({
84
- width: 0,
85
- number: 0
86
- })
87
- },
88
- /**
89
- * @property {boolean} dropdownMenuStatus
90
- */
91
- dropdownMenuStatus: {
92
- type: Boolean,
93
- default: !1
94
- }
95
- },
96
- computed: {
97
- /**
98
- * @return {string}
99
- */
100
- disabledCLass() {
101
- return this.disable ? "in-select-button-wrapper_disabled" : "";
102
- },
103
- /**
104
- * @return {string}
105
- */
106
- buttonTheme() {
107
- return `in-select-button-wrapper_${this.theme}`;
108
- },
109
- /**
110
- * @return {string}
111
- */
112
- buttonStatus() {
113
- return `in-select-button-wrapper_${this.theme}-${this.status}`;
114
- },
115
- /**
116
- * @return {string}
117
- */
118
- buttonTextStatus() {
119
- return this.isPlaceholderText && !this.disable ? "in-select-button-wrapper_placeholder-text" : "";
120
- }
121
- },
122
- methods: {
123
- /**
124
- * @param {String | Number | Boolean} value
125
- * @return {void}
126
- */
127
- click(e) {
128
- this.disable || this.$emit("click", e);
129
- },
130
- /**
131
- * @return {void}
132
- */
133
- mouseover() {
134
- this.$emit("mouseover");
135
- }
136
- }
137
- };
138
- var y = function() {
139
- var e = this, t = e._self._c;
140
- return t("div", { staticClass: "d-b", class: { "cur-na": e.disable } }, [e.skeletonStatus ? e._e() : t("button", { staticClass: "in-select-button-wrapper qa-button", class: [
141
- e.buttonTextStatus,
142
- e.disabledCLass,
143
- e.buttonTheme,
144
- e.buttonStatus,
145
- { "active-list-button": e.dropdownMenuStatus }
146
- ], attrs: { id: e.id, type: "button", disabled: e.disable, value: e.value, "data-title": e.text }, on: { mouseover: e.mouseover, click: function(s) {
147
- return e.click(e.value);
148
- } } }, [t("in-icons", { staticClass: "in-select-button-wrapper_icon", attrs: { size: "24", name: e.icon }, on: { click: function(s) {
149
- return e.$emit("clickIcon");
150
- } } }), e.text ? t("p", { staticClass: "in-select-button-wrapper_text", attrs: { title: e.text } }, [e._v(" " + e._s(e.text) + " ")]) : e._e()], 1), e.skeletonStatus ? t("in-skeleton", { attrs: { sizing: e.skeletonSizing, name: "InButton" } }) : e._e()], 1);
151
- }, v = [], w = /* @__PURE__ */ d(
152
- g,
153
- y,
154
- v,
155
- !1,
156
- null
157
- );
158
- const x = w.exports, C = "_in-select_v01428_p1JtT", k = "_in-select__label_v01428_Xq7ru", T = "_in-select__label--disabled_v01428_0OPuN", B = "_in-select__tooltip_v01428_ObdZQ", M = "_in-select__state-wrapper_v01428_zbUQ-", $ = "_in-select__state-icon_v01428_WT-MX", O = "_in-select__state-icon--warning_v01428_0zwdC", L = "_in-select__state-icon--error_v01428_OFyCx", I = "_in-select__state-message_v01428_mNj--", P = "_in-select__state-message--disabled_v01428_ru-Lu", V = "_in-select__button_v01428_ueW0J", z = "_in-select__button--margin_v01428_3zQOY", D = "_in-select__button-container_v01428_nvRXH", H = "_in-select__dropdown_v01428_Ifutl", A = "_in-select__dropdown--margin_v01428_Lqpki", N = {
159
- "in-select": "_in-select_v01428_p1JtT",
160
- inSelect: C,
161
- "in-select__label": "_in-select__label_v01428_Xq7ru",
162
- inSelectLabel: k,
163
- "in-select__label--disabled": "_in-select__label--disabled_v01428_0OPuN",
164
- inSelectLabelDisabled: T,
165
- "in-select__tooltip": "_in-select__tooltip_v01428_ObdZQ",
166
- inSelectTooltip: B,
167
- "in-select__state-wrapper": "_in-select__state-wrapper_v01428_zbUQ-",
168
- inSelectStateWrapper: M,
169
- "in-select__state-icon": "_in-select__state-icon_v01428_WT-MX",
170
- inSelectStateIcon: $,
171
- "in-select__state-icon--warning": "_in-select__state-icon--warning_v01428_0zwdC",
172
- inSelectStateIconWarning: O,
173
- "in-select__state-icon--error": "_in-select__state-icon--error_v01428_OFyCx",
174
- inSelectStateIconError: L,
175
- "in-select__state-message": "_in-select__state-message_v01428_mNj--",
176
- inSelectStateMessage: I,
177
- "in-select__state-message--disabled": "_in-select__state-message--disabled_v01428_ru-Lu",
178
- inSelectStateMessageDisabled: P,
179
- "in-select__button": "_in-select__button_v01428_ueW0J",
180
- inSelectButton: V,
181
- "in-select__button--margin": "_in-select__button--margin_v01428_3zQOY",
182
- inSelectButtonMargin: z,
183
- "in-select__button-container": "_in-select__button-container_v01428_nvRXH",
184
- inSelectButtonContainer: D,
185
- "in-select__dropdown": "_in-select__dropdown_v01428_Ifutl",
186
- inSelectDropdown: H,
187
- "in-select__dropdown--margin": "_in-select__dropdown--margin_v01428_Lqpki",
188
- inSelectDropdownMargin: A
189
- }, u = "bottom left", p = "bottom right", E = "top left", q = "top right", i = [u, p, E, q], W = Object.freeze({ All: "all", Number: "number", Text: "text" }), l = {
190
- ArrowUp: 38,
191
- ArrowDown: 40
192
- }, X = [
193
- l.ArrowUp,
194
- l.ArrowDown
195
- ], F = {
196
- directives: { clickOutside: S },
197
- components: {
198
- InDropdownMenu: _,
199
- SelectButton: x,
200
- InIcons: c,
201
- InTooltipV2: b,
202
- InSkeleton: r
203
- },
204
- props: {
205
- id: { type: String, default: "qa-select" },
206
- options: { type: Array, default: () => [] },
207
- value: { type: Array, default: () => [] },
208
- loadingState: { type: Boolean, default: !1 },
209
- labelStatus: { type: Boolean, default: !0 },
210
- labelText: { type: String, default: "" },
211
- tooltipStatus: { type: Boolean, default: !1 },
212
- tooltipText: { type: String, default: "" },
213
- disabledStatus: { type: Boolean, default: !1 },
214
- dropdownMenuStatus: { type: Boolean, default: !1 },
215
- searchStatus: { type: Boolean, default: !1 },
216
- theme: { type: String, default: "grey" },
217
- buttonType: { type: String, default: "dropdown" },
218
- placeholderText: { type: String, default: "" },
219
- clearSelectionButton: { type: Boolean, default: !1 },
220
- staticPosition: {
221
- type: String,
222
- default: u,
223
- validator(e) {
224
- return i.includes(e);
225
- }
226
- },
227
- dynamicPosition: { type: Boolean, default: !1 },
228
- dynamicChildPosition: { type: Boolean, default: !0 },
229
- staticChildPosition: {
230
- type: String,
231
- default: p,
232
- validator(e) {
233
- return i.includes(e);
234
- }
235
- },
236
- createButtonLabel: { type: String, default: "" },
237
- createOptionStatus: { type: Boolean, default: !1 },
238
- buttonStatus: { type: Boolean, default: !0 },
239
- buttonIcon: { type: String, default: "" },
240
- buttonLabel: { type: String, default: "" },
241
- state: { type: String, default: "default" },
242
- stateMessage: { type: String, default: "State Message" },
243
- skeletonStatus: { type: Boolean, default: !1 },
244
- skeletonSizing: { type: Object, default: () => ({ width: 0, number: 0 }) },
245
- optionValidationType: { type: [String, RegExp], default: W.All },
246
- minCharacterLimit: { type: Number | String, default: 1 },
247
- maxCharacterLimit: { type: Number | String, default: 10 },
248
- optionValidationText: { type: String, default: "Enter a valid value to continue." },
249
- characterLimitValidationText: {
250
- type: String,
251
- default: "Enter a value between 1 and 10 characters to continue."
252
- },
253
- bottomOffsetForDynamicPosition: { type: Number, default: 0 },
254
- maxHeight: { type: Number, default: 240 },
255
- maxChildHeight: { type: Number, default: 480 },
256
- fetchPage: { type: Number, default: 1 },
257
- lazyLoad: { type: Boolean, default: !1 },
258
- lazyLoadSearch: { type: Boolean, default: !1 },
259
- isWrappedDescription: { type: Boolean, default: !1 },
260
- helperMessageStatus: { type: Boolean, default: !1 },
261
- helperMessage: { type: String, default: "" },
262
- customOptionText: { type: String, default: "" },
263
- preventXss: { type: Boolean, default: !0 },
264
- preventFocus: { type: Boolean, default: !1 },
265
- allowAddAllCases: { type: Boolean, default: !0 },
266
- sameValueExistsValidationText: { type: String, default: "This value already exists." }
267
- },
268
- data() {
269
- return {
270
- dropdownMenuStatusClone: this.dropdownMenuStatus,
271
- preSelectedValues: this.value,
272
- fetchPageClone: this.fetchPage
273
- };
274
- },
275
- computed: {
276
- /**
277
- * @return {string|void}
278
- */
279
- buttonValue() {
280
- var e;
281
- return (e = this.value[0]) == null ? void 0 : e.value;
282
- },
283
- /**
284
- * @return {string|void}
285
- */
286
- hasCustomOptionText() {
287
- return !m(this.customOptionText);
288
- },
289
- /**
290
- * @return {string}
291
- */
292
- selectedOptionText() {
293
- var e;
294
- return this.hasCustomOptionText ? this.customOptionText : ((e = this.flattenedOptions.find((t) => {
295
- var s, n;
296
- return (s = this.preSelectedValues) != null && s.length ? String(t == null ? void 0 : t.value) === String((n = this.preSelectedValues[0]) == null ? void 0 : n.value) : !1;
297
- })) == null ? void 0 : e.text) || this.placeholderText;
298
- },
299
- /**
300
- * @return {boolean}
301
- */
302
- showPlaceHolderText() {
303
- return this.selectedOptionText === this.placeholderText;
304
- },
305
- /**
306
- * @return {string}
307
- */
308
- icon() {
309
- return this.clearSelectionButton ? this.selectedOptionText === this.placeholderText ? "filled-dropdown-down" : "line-architect-segments-closed" : "filled-dropdown-down";
310
- },
311
- /**
312
- * @return {boolean}
313
- */
314
- isMessageVisible() {
315
- return (this.helperMessageStatus || this.errorState || this.warningState) && !this.skeletonStatus;
316
- },
317
- /**
318
- * @return {string}
319
- */
320
- message() {
321
- return this.warningState || this.errorState ? this.stateMessage : this.helperMessage;
322
- },
323
- /**
324
- * @return {array}
325
- */
326
- flattenedOptions() {
327
- const e = h(this.options);
328
- return this.lazyLoad && this.preSelectedValues.length && this.preSelectedValues[0] ? a([...e, this.preSelectedValues[0]], "children") : a(e, "children");
329
- },
330
- errorState() {
331
- return this.state === "error";
332
- },
333
- warningState() {
334
- return this.state === "warning";
335
- },
336
- secureLabelText() {
337
- return this.preventXss ? f(this.labelText) : this.labelText;
338
- }
339
- },
340
- watch: {
341
- dropdownMenuStatus() {
342
- this.dropdownMenuStatusClone = this.dropdownMenuStatus;
343
- },
344
- dropdownMenuStatusClone(e) {
345
- this.$emit("openList", e);
346
- },
347
- value: {
348
- handler() {
349
- this.preSelectedValues = this.value;
350
- },
351
- deep: !0
352
- },
353
- fetchPage() {
354
- this.fetchPageClone = this.fetchPage;
355
- }
356
- },
357
- mounted() {
358
- this.setKeydownListeners();
359
- },
360
- methods: {
361
- closeDropdownMenu() {
362
- this.$refs.dropdownMenu.invalidOption = !1, this.dropdownMenuStatusClone = !1, this.$emit("close");
363
- },
364
- /**
365
- * @param {object} item
366
- */
367
- selectItem({ text: e, value: t }) {
368
- this.preSelectedValues = [{ text: e, value: t }];
369
- },
370
- /**
371
- * @param {object} item
372
- */
373
- optionClickHandler(e) {
374
- if (e.inActive) {
375
- this.$emit("selectedInActiveOption", e), this.closeDropdownMenu();
376
- return;
377
- }
378
- e.children || (this.selectItem(e), this.closeDropdownMenu(), this.$emit("select", e));
379
- },
380
- /**
381
- * @param {string} searchString
382
- */
383
- searchHandler(e) {
384
- this.$emit("search", e);
385
- },
386
- deleteSelectedOption() {
387
- this.clearSelectionButton && (this.$emit("unSelect", this.value), this.$emit("select", ""), this.preSelectedValues = []);
388
- },
389
- endScrollHandler() {
390
- this.fetchPageClone++, this.$emit("endScroll", this.fetchPageClone);
391
- },
392
- /**
393
- * @return {void}
394
- */
395
- secondaryButtonClickHandler() {
396
- this.$emit("secondaryButtonClick");
397
- },
398
- /**
399
- * @return {void}
400
- */
401
- setKeydownListeners() {
402
- this.$el.addEventListener("keydown", (e) => {
403
- X.includes(e.keyCode) && e.preventDefault();
404
- }, !1);
405
- }
406
- }
407
- };
408
- var j = function() {
409
- var e = this, t = e._self._c;
410
- return t("div", { staticClass: "in-select", class: e.$style["in-select"], on: { keyup: function(s) {
411
- return !s.type.indexOf("key") && e._k(s.keyCode, "esc", 27, s.key, ["Esc", "Escape"]) ? null : e.closeDropdownMenu.apply(null, arguments);
412
- } } }, [!e.skeletonStatus && e.labelStatus ? t("label", { staticClass: "in-select__label", class: [
413
- e.$style["in-select__label"],
414
- { "in-select__label--disabled": e.disabledStatus },
415
- { [e.$style["in-select__label--disabled"]]: e.disabledStatus }
416
- ], on: { click: e.closeDropdownMenu } }, [t("span", { domProps: { innerHTML: e._s(e.secureLabelText) } }), e.tooltipStatus ? t("in-tooltip-v2", { staticClass: "in-select__tooltip", class: e.$style["in-select__tooltip"], attrs: { id: `tooltip-${e.id}`, text: e.tooltipText, "static-position": "top center", "icon-status": !0 } }) : e._e()], 1) : e._e(), t("div", { staticClass: "in-select__button-container", class: e.$style["in-select__button-container"] }, [e.skeletonStatus ? e._e() : t("select-button", { ref: "dropdownButton", staticClass: "in-select__button", class: e.$style["in-select__button"], attrs: { id: e.id, "tab-index": 0, icon: e.icon, theme: e.theme, status: e.state, text: e.selectedOptionText, "is-placeholder-text": e.showPlaceHolderText, disable: e.disabledStatus, value: e.buttonValue, "dropdown-menu-status": e.dropdownMenuStatusClone }, on: { click: function(s) {
417
- e.dropdownMenuStatusClone = !e.dropdownMenuStatusClone;
418
- }, clickIcon: e.deleteSelectedOption } }), t("in-dropdown-menu", { ref: "dropdownMenu", staticClass: "in-select__dropdown mt-1", class: [
419
- e.$style["in-select__dropdown"],
420
- { "in-select__dropdown--margin": e.errorState || e.warningState },
421
- { [e.$style["in-select__dropdown--margin"]]: e.errorState || e.warningState }
422
- ], attrs: { id: e.id, "search-tab-index": 1, status: e.dropdownMenuStatusClone && !e.skeletonStatus, "loading-state": e.loadingState, "pre-selected-values": e.preSelectedValues, "search-status": e.searchStatus, "static-position": e.staticPosition, "dynamic-position": e.dynamicPosition, "dynamic-child-position": e.dynamicChildPosition, "static-child-position": e.staticChildPosition, "create-button-label": e.createButtonLabel, "create-option-status": e.createOptionStatus, "button-status": e.buttonStatus, "button-icon": e.buttonIcon, "button-label": e.buttonLabel, "prevent-focus": e.preventFocus, "box-width": "basedOnField", options: e.options, "fetch-page": e.fetchPageClone, "option-validation-type": e.optionValidationType, "min-character-limit": e.minCharacterLimit, "max-character-limit": e.maxCharacterLimit, "option-validation-text": e.optionValidationText, "character-limit-validation-text": e.characterLimitValidationText, "bottom-offset-for-dynamic-position": e.bottomOffsetForDynamicPosition, "max-height": e.maxHeight, "max-child-height": e.maxChildHeight, "lazy-load": e.lazyLoad, "lazy-load-search": e.lazyLoadSearch, "is-wrapped-description": e.isWrappedDescription, state: e.state, "state-message": e.stateMessage, "allow-add-all-cases": e.allowAddAllCases, "same-value-exists-validation-text": e.sameValueExistsValidationText }, on: { clickOutside: e.closeDropdownMenu, endScroll: e.endScrollHandler, addOption: (s) => e.$emit("addOption", s), search: e.searchHandler, optionClick: e.optionClickHandler, secondaryButtonClick: e.secondaryButtonClickHandler, infoBoxButtonClick: (s) => e.$emit("infoBoxButtonClick", s), infoBoxClickIcon: (s) => e.$emit("infoBoxClickIcon", s) } })], 1), e.isMessageVisible ? t("div", { staticClass: "in-select__state-wrapper", class: e.$style["in-select__state-wrapper"] }, [e.warningState || e.errorState ? t("in-icons", { staticClass: "in-select__state-icon", class: [
423
- e.$style["in-select__state-icon"],
424
- { "in-select__state-icon--warning": e.warningState },
425
- { [e.$style["in-select__state-icon--warning"]]: e.warningState },
426
- { "in-select__state-icon--error": e.errorState },
427
- { [e.$style["in-select__state-icon--error"]]: e.errorState }
428
- ], attrs: { name: e.warningState ? "filled-caution-triangle-colored" : "filled-error-box-colored", size: "16" } }) : e._e(), t("p", { staticClass: "in-select__state-message", class: [
429
- e.$style["in-select__state-message"],
430
- { "in-select__state-message--disabled": e.disabledStatus },
431
- { [e.$style["in-select__state-message--disabled"]]: e.disabledStatus }
432
- ] }, [e._v(" " + e._s(e.message) + " ")])], 1) : e._e(), e.skeletonStatus ? t("in-skeleton", { attrs: { sizing: e.skeletonSizing, name: "InDropDown" } }) : e._e()], 1);
433
- }, Q = [];
434
- const o = {
435
- $style: N
436
- };
437
- function U(e) {
438
- for (var t in o)
439
- this[t] = o[t];
440
- }
441
- var J = /* @__PURE__ */ d(
442
- F,
443
- j,
444
- Q,
445
- !1,
446
- U
447
- );
448
- const ne = J.exports;
449
- export {
450
- ne as InSelect
451
- };