@integry/sdk 4.6.58 → 4.6.60
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.
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
import { html } from 'htm/preact';
|
|
4
|
-
import { render } from 'preact';
|
|
5
4
|
import { useState, useEffect } from 'preact/hooks';
|
|
5
|
+
import { Hint } from '@/components/Tooltip';
|
|
6
6
|
import styles from './styles.module.scss';
|
|
7
7
|
|
|
8
8
|
// Update the TagNode interface to better handle various types
|
|
@@ -848,6 +848,35 @@ const TagList = ({
|
|
|
848
848
|
tagsParamForOutput = value as Record<string, unknown>;
|
|
849
849
|
}
|
|
850
850
|
|
|
851
|
+
const handleMenuRowClcik = (e: Event) => {
|
|
852
|
+
if (isStep && hasOutput) {
|
|
853
|
+
// For step nodes with output, toggle output expansion
|
|
854
|
+
setExpandedOutputs((prev) => ({
|
|
855
|
+
...prev,
|
|
856
|
+
[key]: !prev[key],
|
|
857
|
+
}));
|
|
858
|
+
} else if (hasChildren) {
|
|
859
|
+
// For array/object nodes, toggle node expansion
|
|
860
|
+
toggleExpand(key);
|
|
861
|
+
toggleOutputExpand(key, e);
|
|
862
|
+
} else {
|
|
863
|
+
// For leaf nodes, select the value
|
|
864
|
+
const tagPath = `${activeTab}.${extractStepsFromOutputPath(
|
|
865
|
+
currentPath,
|
|
866
|
+
)}`;
|
|
867
|
+
onSelect({
|
|
868
|
+
currentPath: tagPath
|
|
869
|
+
.replace(/\bparameters\.parameters\b/g, 'parameters')
|
|
870
|
+
.replace(
|
|
871
|
+
/\bauthorization\.authorization\b/g,
|
|
872
|
+
'authorization',
|
|
873
|
+
),
|
|
874
|
+
key,
|
|
875
|
+
value: escapeHTMLIfNeeded(value),
|
|
876
|
+
});
|
|
877
|
+
}
|
|
878
|
+
};
|
|
879
|
+
|
|
851
880
|
return html`
|
|
852
881
|
<li key=${key} class="${nodeMatches ? styles.searchMatch : ''}">
|
|
853
882
|
<div
|
|
@@ -898,17 +927,23 @@ const TagList = ({
|
|
|
898
927
|
(typeof value === 'string' ||
|
|
899
928
|
typeof value === 'number' ||
|
|
900
929
|
typeof value === 'boolean')
|
|
901
|
-
? html
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
930
|
+
? html`<${Hint}
|
|
931
|
+
dismissOnClick=${false}
|
|
932
|
+
position="top"
|
|
933
|
+
deltaY=${0}
|
|
934
|
+
className=${styles.hint}
|
|
935
|
+
><span class="${styles.value}">
|
|
936
|
+
${value ? ' ' : ''}
|
|
937
|
+
<span
|
|
938
|
+
data-hint=${value ? String(value) : ''}
|
|
939
|
+
dangerouslySetInnerHTML=${{
|
|
940
|
+
__html: highlightSearchTerm(
|
|
941
|
+
String(value),
|
|
942
|
+
searchTerm,
|
|
943
|
+
),
|
|
944
|
+
}}
|
|
945
|
+
></span> </span
|
|
946
|
+
><//>`
|
|
912
947
|
: ''}
|
|
913
948
|
${isStep &&
|
|
914
949
|
value !== undefined &&
|
|
@@ -951,7 +986,7 @@ const TagList = ({
|
|
|
951
986
|
${Array.isArray(value) && value.length > 0
|
|
952
987
|
? html`<span
|
|
953
988
|
class="${styles.outputIndicator} ${styles.objectExpandIcon}"
|
|
954
|
-
onClick=${(e: Event) =>
|
|
989
|
+
onClick=${(e: Event) => handleMenuRowClcik(e)}
|
|
955
990
|
title="Toggle expand output"
|
|
956
991
|
>
|
|
957
992
|
<svg
|
|
@@ -982,7 +1017,9 @@ const TagList = ({
|
|
|
982
1017
|
Object.keys(value as Record<string, unknown>).length > 0
|
|
983
1018
|
? html`<span
|
|
984
1019
|
class="${styles.outputIndicator} ${styles.objectExpandIcon}"
|
|
985
|
-
onClick=${(e: Event) =>
|
|
1020
|
+
onClick=${(e: Event) => {
|
|
1021
|
+
handleMenuRowClcik(e);
|
|
1022
|
+
}}
|
|
986
1023
|
title="Toggle expand output"
|
|
987
1024
|
>
|
|
988
1025
|
<svg
|
|
@@ -120,6 +120,10 @@
|
|
|
120
120
|
border-radius: 4px;
|
|
121
121
|
padding-left: 4px;
|
|
122
122
|
padding-right: 4px;
|
|
123
|
+
[class^='styles-module_preact-hint__content_'] {
|
|
124
|
+
white-space: pre-wrap;
|
|
125
|
+
word-break: break-word;
|
|
126
|
+
}
|
|
123
127
|
|
|
124
128
|
&:hover {
|
|
125
129
|
background-color: rgba(66, 80, 240, 0.1);
|
|
@@ -134,8 +138,8 @@
|
|
|
134
138
|
}
|
|
135
139
|
}
|
|
136
140
|
span.tagIcon {
|
|
137
|
-
margin-right:
|
|
138
|
-
order:
|
|
141
|
+
margin-right: 5px;
|
|
142
|
+
order: 2;
|
|
139
143
|
svg,
|
|
140
144
|
img {
|
|
141
145
|
width: 1rem;
|
|
@@ -194,6 +198,12 @@
|
|
|
194
198
|
}
|
|
195
199
|
}
|
|
196
200
|
}
|
|
201
|
+
div.hint {
|
|
202
|
+
order: 4;
|
|
203
|
+
max-width: 100%;
|
|
204
|
+
min-width: 0;
|
|
205
|
+
width: 100%;
|
|
206
|
+
}
|
|
197
207
|
span.value {
|
|
198
208
|
color: hsl(240 3.8% 60%);
|
|
199
209
|
font-size: 0.75rem;
|
|
@@ -204,6 +214,9 @@
|
|
|
204
214
|
white-space: nowrap;
|
|
205
215
|
margin-left: 5px;
|
|
206
216
|
order: 4;
|
|
217
|
+
display: inline-block;
|
|
218
|
+
max-width: 100%;
|
|
219
|
+
vertical-align: middle;
|
|
207
220
|
|
|
208
221
|
mark {
|
|
209
222
|
background-color: yellow;
|
|
@@ -223,6 +236,9 @@
|
|
|
223
236
|
white-space: nowrap;
|
|
224
237
|
margin-left: 5px;
|
|
225
238
|
min-width: 20px;
|
|
239
|
+
width: 100%;
|
|
240
|
+
max-width: fit-content;
|
|
241
|
+
flex-shrink: 0;
|
|
226
242
|
|
|
227
243
|
mark {
|
|
228
244
|
background-color: yellow;
|