@@ -31,6 +31,7 @@ export const DataLink = (props: Props) => {
31
31
const styles = useStyles2 ( getStyles ) ;
32
32
const [ showInternalLink , setShowInternalLink ] = useInternalLink ( value . datasourceUid ) ;
33
33
const [ base64TraceId , setBase64TraceId ] = useState ( true )
34
+ const labelWidth = 24
34
35
35
36
const handleChange = ( field : keyof typeof value ) => ( event : React . ChangeEvent < HTMLInputElement > ) => {
36
37
onChange ( {
@@ -50,7 +51,7 @@ export const DataLink = (props: Props) => {
50
51
< InlineField
51
52
label = "Field"
52
53
htmlFor = "elasticsearch-datasource-config-field"
53
- labelWidth = { 12 }
54
+ labelWidth = { labelWidth }
54
55
tooltip = { 'Can be exact field name or a regex pattern that will match on the field name.' }
55
56
>
56
57
< Input
@@ -74,7 +75,7 @@ export const DataLink = (props: Props) => {
74
75
75
76
< InlineFieldRow >
76
77
< div className = { styles . urlField } >
77
- < InlineLabel htmlFor = "elasticsearch-datasource-internal-link" width = { 12 } >
78
+ < InlineLabel htmlFor = "elasticsearch-datasource-internal-link" width = { labelWidth } >
78
79
{ showInternalLink ? 'Query' : 'URL' }
79
80
</ InlineLabel >
80
81
< DataLinkInput
@@ -108,7 +109,16 @@ export const DataLink = (props: Props) => {
108
109
</ InlineFieldRow >
109
110
110
111
< div className = { styles . row } >
111
- < InlineField label = "Internal link" labelWidth = { 12 } >
112
+ < InlineField label = "Field encoded in base64?" labelWidth = { labelWidth } tooltip = "Quickwit encodes the traceID in base64 by default whereas Jaeger uses hex" >
113
+ < InlineSwitch
114
+ value = { base64TraceId }
115
+ onChange = { ( ) => handleBase64TraceId ( ! base64TraceId , value ) }
116
+ />
117
+ </ InlineField >
118
+ </ div >
119
+
120
+ < div className = { styles . row } >
121
+ < InlineField label = "Internal link" labelWidth = { labelWidth } >
112
122
< InlineSwitch
113
123
label = "Internal link"
114
124
value = { showInternalLink || false }
@@ -137,16 +147,6 @@ export const DataLink = (props: Props) => {
137
147
/>
138
148
) }
139
149
</ div >
140
-
141
- < div className = { styles . row } >
142
- < InlineField label = "Base64" labelWidth = { 12 } title = "Base64 traceId" >
143
- < InlineSwitch
144
- label = "Base64 traceId"
145
- value = { base64TraceId }
146
- onChange = { ( ) => handleBase64TraceId ( ! base64TraceId , value ) }
147
- />
148
- </ InlineField >
149
- </ div >
150
150
</ div >
151
151
) ;
152
152
} ;
0 commit comments