@@ -43,6 +43,8 @@ type ProductsTranslation = {
4343 plans : string ,
4444 change : string ,
4545 noProducts : string ,
46+ noContracts : string ,
47+ lookAt : string ,
4648} & ProductPlanTranslation
4749
4850const defaultProductsTranslations : Record < Languages , ProductsTranslation > = {
@@ -63,7 +65,9 @@ const defaultProductsTranslations: Record<Languages, ProductsTranslation> = {
6365 pay : 'Pay' ,
6466 plans : 'Plans' ,
6567 change : 'Change' ,
66- noProducts : 'No Products found.'
68+ noProducts : 'No Products found.' ,
69+ noContracts : 'No Contracts' ,
70+ lookAt : 'Look at'
6771 } ,
6872 de : {
6973 ...defaultProductPlanTranslation . de ,
@@ -82,7 +86,9 @@ const defaultProductsTranslations: Record<Languages, ProductsTranslation> = {
8286 pay : 'Bezahlen' ,
8387 plans : 'Pläne' ,
8488 change : 'Wechseln' ,
85- noProducts : 'Keine Produkte gefunden.'
89+ noProducts : 'Keine Produkte gefunden.' ,
90+ noContracts : 'Keine Verträge' ,
91+ lookAt : 'Anzeigen'
8692 }
8793}
8894
@@ -111,9 +117,9 @@ const ProductShop: NextPage = () => {
111117 < span > { productModal ?. description } </ span >
112118 < div className = { tw ( 'flex flex-col gap-y-1' ) } >
113119 < h3 className = { tw ( 'text-lg font-semibold' ) } > { translation . contracts } </ h3 >
114- { ( contracts ?? [ ] ) . length === 0 ? (
120+ { ( contracts ?? [ ] ) . length === 0 && contracts ? (
115121 < span className = { tw ( 'text-bg-gray-300' ) } > { translation . noContracts } </ span >
116- ) : contracts . map ( contract => (
122+ ) : contracts ! . map ( contract => (
117123 < Link href = { contract . url } target = "_blank" key = { contract . uuid } className = { tw ( 'inline-flex flex-row gap-x-2' ) } >
118124 { contract . key }
119125 < span className = { tw ( 'inline-flex flex-row gap-x-1/2' ) } >
0 commit comments