From 65343786063ff4e87df158349dffe438a97a8ad7 Mon Sep 17 00:00:00 2001 From: h7x4 Date: Sun, 23 Jan 2022 03:46:03 +0100 Subject: [PATCH] Make antonyms clickable --- .../search_results_body/parts/sense/antonyms.dart | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/lib/components/search/search_results_body/parts/sense/antonyms.dart b/lib/components/search/search_results_body/parts/sense/antonyms.dart index 3c40993..8346962 100644 --- a/lib/components/search/search_results_body/parts/sense/antonyms.dart +++ b/lib/components/search/search_results_body/parts/sense/antonyms.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:jisho_study_tool/routing/routes.dart'; import '../../../../../models/themes/theme.dart'; import 'search_chip.dart'; @@ -26,11 +27,14 @@ class Antonyms extends StatelessWidget { runSpacing: 5, children: antonyms .map( - (a) => SearchChip( - text: a, - colors: const ColorSet( - foreground: Colors.white, - background: Colors.blue, + (a) => InkWell( + onTap: () => Navigator.pushNamed(context, Routes.search, arguments: a), + child: SearchChip( + text: a, + colors: const ColorSet( + foreground: Colors.white, + background: Colors.blue, + ), ), ), )