From 956596dd9930136ec9d60f0282c61cd7496503ba Mon Sep 17 00:00:00 2001 From: PupoSDC Date: Sat, 20 Jan 2024 12:14:16 +0000 Subject: [PATCH] feat: create blog post for search improvements (#87) --- .../001-welcome-to-chair-flight-blog.page.mdx | 2 - .../blog/003-new-737-question-bank.page.mdx | 35 ++-------- .../blog/005-new-a320-question-bank.page.mdx | 9 --- .../blog/006-improving-search.page.mdx | 66 +++++++++++++++++++ .../components/src/flashcard/flashcard.tsx | 1 - .../question-variant-preview.tsx | 2 +- .../layouts/layout-module/layout-module.tsx | 1 - .../question-search/question-search.tsx | 2 +- 8 files changed, 74 insertions(+), 44 deletions(-) create mode 100644 apps/next-app/pages/articles/blog/006-improving-search.page.mdx diff --git a/apps/next-app/pages/articles/blog/001-welcome-to-chair-flight-blog.page.mdx b/apps/next-app/pages/articles/blog/001-welcome-to-chair-flight-blog.page.mdx index bbbd41a39..baef3161a 100644 --- a/apps/next-app/pages/articles/blog/001-welcome-to-chair-flight-blog.page.mdx +++ b/apps/next-app/pages/articles/blog/001-welcome-to-chair-flight-blog.page.mdx @@ -95,8 +95,6 @@ incorrect. For this simple question, it's possible to write 18 variations! That's 16 times more seeing this question than you really need to see it. In Chair Flight, these question variants are combined into a single question: -{" "} - { - const router = useRouter(); - const fallback = - - return ( - - - - { - router.push(`/modules/type/tests/${test.id}/${test.mode}`); - }} - /> - - - - ); -} - - + +
+ +You can get started here: [B737 Question Bank](/modules/type) + +
**See you in the skies!** diff --git a/apps/next-app/pages/articles/blog/005-new-a320-question-bank.page.mdx b/apps/next-app/pages/articles/blog/005-new-a320-question-bank.page.mdx index 49a9f94b2..dc579eabd 100644 --- a/apps/next-app/pages/articles/blog/005-new-a320-question-bank.page.mdx +++ b/apps/next-app/pages/articles/blog/005-new-a320-question-bank.page.mdx @@ -1,12 +1,3 @@ -import { Suspense } from "react"; -import { useRouter } from "next/router"; -import { NoSsr } from "@mui/base"; -import { default as AirplaneTicketIcon } from "@mui/icons-material/AirplaneTicket"; -import { default as FlightTakeoffIcon } from "@mui/icons-material/FlightTakeoff"; -import { default as StyleIcon } from "@mui/icons-material/Style"; -import { Stack, Link } from "@mui/joy"; -import { ModuleSelectionButton } from "@chair-flight/react/components"; -import { TestMaker, useTestProgress } from "@chair-flight/react/containers"; import { BlogPageLayout } from "./_blog-page.layout"; export const meta = { diff --git a/apps/next-app/pages/articles/blog/006-improving-search.page.mdx b/apps/next-app/pages/articles/blog/006-improving-search.page.mdx new file mode 100644 index 000000000..1bdf54f31 --- /dev/null +++ b/apps/next-app/pages/articles/blog/006-improving-search.page.mdx @@ -0,0 +1,66 @@ +import { Link } from "@mui/joy"; +import { QuestionSearch } from "@chair-flight/react/containers"; +import { BlogPageLayout } from "./_blog-page.layout"; + +export const meta = { + title: "Improving Search", + linkTitle: "Improving Search", + file: "006-improving-search", + description: [ + "Finding questions on the Chair Flight Database has now become both faster and ", + "easier! We have added the ability to filter by subjects, learning objectives, as", + "well as the ability to specify what exactly you are searching for.", + ].join(""), + tags: ["Feature"], + author: "PupoSDC", + isoDate: "2024-01-20T20:00:00.000Z", +}; + +# Improving Search + +Finding questions on the Chair Flight Database has now become both faster and +easier! We have added the ability to filter by subjects, learning objectives, as +well as the ability to specify what exactly you are searching for. + +Since Demos are worth 1000 pictures, have a go at the new question search forsti +the ATPL module right here: + +
+ + + +
+ + + + + + + +
+ +**See you in the skies!** + +export default ({ children }) => ( + {children} +); diff --git a/libs/react/components/src/flashcard/flashcard.tsx b/libs/react/components/src/flashcard/flashcard.tsx index 0bc909c85..d526d93c4 100644 --- a/libs/react/components/src/flashcard/flashcard.tsx +++ b/libs/react/components/src/flashcard/flashcard.tsx @@ -39,7 +39,6 @@ export const Flashcard = forwardRef( variant="outlined" sx={{ transform: flipped ? "rotateY(180deg)" : "rotateY(0deg)" }} > - {" "} - {`${id}`}{" "} + {`${id}`} {variantId && {`${variantId}`}} {topRightCorner} diff --git a/libs/react/containers/src/layouts/layout-module/layout-module.tsx b/libs/react/containers/src/layouts/layout-module/layout-module.tsx index 4b2e075cf..4a2d115ae 100644 --- a/libs/react/containers/src/layouts/layout-module/layout-module.tsx +++ b/libs/react/containers/src/layouts/layout-module/layout-module.tsx @@ -82,7 +82,6 @@ export const LayoutModule = container( const secondToLastBreadcrumb = breadcrumbs?.at(-2); const lastBreadcrumb = breadcrumbs?.at(-1); - console.log(secondToLastBreadcrumb); return ( <> diff --git a/libs/react/containers/src/questions/question-search/question-search.tsx b/libs/react/containers/src/questions/question-search/question-search.tsx index 46ce105b0..ad0c0b159 100644 --- a/libs/react/containers/src/questions/question-search/question-search.tsx +++ b/libs/react/containers/src/questions/question-search/question-search.tsx @@ -95,7 +95,7 @@ export const QuestionSearch = container( - + {subjects.map(({ id, shortName }) => (