11"use client" ;
22
33import React , { useEffect , useRef } from "react" ;
4+ import styles from "./token-encoder.module.scss"
45import { EncodedJwtOutputComponent } from "@/features/encoder/components/encoded-jwt-output.component" ;
56import { TokenEncoderInputComponent } from "@/features/encoder/components/token-encoder-input.component" ;
67import { useEncoderStore } from "@/features/encoder/services/encoder.store" ;
@@ -10,6 +11,7 @@ import { SigningAlgCategoryValues } from "@/features/common/values/signing-alg-c
1011import { WidgetComponent } from "@/features/common/components/widget/widget/widget.component" ;
1112import { dataTestidDictionary } from "@/libs/testing/data-testid.dictionary" ;
1213import { DebuggerWidgetValues } from "@/features/common/values/debugger-widget.values" ;
14+ import { WidgetAlgPickerComponent } from "@/features/debugger/components/debugger-alg-picker/debugger-alg-picker.component" ;
1315
1416interface TokenEncoderComponentProps {
1517 languageCode : string ;
@@ -99,27 +101,37 @@ export const TokenEncoderComponent: React.FC<TokenEncoderComponentProps> = ({
99101 } , [ encoderInputs$ , loadEncoderInputs , headlineConfig . isVisible ] ) ;
100102
101103 return (
102- < WidgetComponent
103- id = { dataTestidDictionary . encoder . id }
104- widget = { DebuggerWidgetValues . ENCODER }
105- languageCode = { languageCode }
106- headlineConfig = { headlineConfig }
107- title = { dictionary . title }
108- description = { dictionary . description }
109- exampleGenerator = { dictionary . exampleGenerator }
110- contentInput = {
111- < TokenEncoderInputComponent
104+ < >
105+ < div className = { styles . input__description } >
106+ < span > { dictionary . description } </ span >
107+ < WidgetAlgPickerComponent
108+ label = { dictionary . exampleGenerator . label }
112109 languageCode = { languageCode }
113- dictionary = { dictionary }
110+ widget = { DebuggerWidgetValues . ENCODER }
114111 />
115- }
116- contentOutput = {
117- < EncodedJwtOutputComponent
118- languageCode = { languageCode }
119- dictionary = { dictionary . encodedJwt }
120- />
121- }
122- warnings = { encodingWarnings$ }
123- />
112+ </ div >
113+ < WidgetComponent
114+ id = { dataTestidDictionary . encoder . id }
115+ widget = { DebuggerWidgetValues . ENCODER }
116+ languageCode = { languageCode }
117+ headlineConfig = { headlineConfig }
118+ title = { dictionary . title }
119+ description = { dictionary . description }
120+ exampleGenerator = { dictionary . exampleGenerator }
121+ contentInput = {
122+ < TokenEncoderInputComponent
123+ languageCode = { languageCode }
124+ dictionary = { dictionary }
125+ />
126+ }
127+ contentOutput = {
128+ < EncodedJwtOutputComponent
129+ languageCode = { languageCode }
130+ dictionary = { dictionary . encodedJwt }
131+ />
132+ }
133+ warnings = { encodingWarnings$ }
134+ />
135+ </ >
124136 ) ;
125137} ;
0 commit comments