Skip to content

feat: add I9kAskAi and an extra row in I9kFooter - #45

Merged
ismail9k merged 2 commits into
mainfrom
feat/ask-ai
Oct 26, 2026
Merged

ismail9k merged 2 commits into
mainfrom
feat/ask-ai

Conversation

@ismail9k

@ismail9k ismail9k commented Oct 26, 2026 •

Copy link
Copy Markdown
Member

What

  • I9kAskAi: a heading plus three pill links (ChatGPT, Perplexity, Claude). Each opens the assistant in a new tab with a question already typed in, through its q parameter:
    • chatgpt.com/?q=
    • perplexity.ai/search?q=
    • claude.ai/new?q=
  • Its props are prompt, heading, headingTag (default h2), providers and align. align="center" is for the footer's centred layout.
  • Links use rel="noopener noreferrer", so the assistant gets the question but never the page's address.
  • askAiUrl() and I9K_ASK_AI_PROVIDERS are exported.
  • I9kFooter gets an extra slot: a row of its own under a divider, between the columns and the bottom bar (after the tagline in the centred layout).
  • The ChatGPT, Perplexity and Claude logos join the icon set. Perplexity and Claude come from simple-icons 16 (CC0). The OpenAI logo comes from simple-icons 11, because later versions withdrew it.

The three sites use it in their footers, each with its own question that also names the other two:

  • ismail9k/9k.school: the "Ask AI about 9k School" PR
  • ismail9k/ismail9k.com: the "Ask AI about Abdelrahman Ismail" PR
  • the9klabs/the9klabs.com: the "Ask AI about 9k Labs" PR

Merge

Merge with a merge commit, not a squash. 9k.school locks 09d4b88 in its lockfile. ismail9k.com and the9klabs.com pin it in package.json. The commit has to stay in main's history.

This branch starts from cec6be3, not from current main. Current main also has 2a67c62 ("skip I9kModal showModal when the dialog left the page"), which fails 12 of 9k.school's admin dialog tests: they mount dialogs that aren't attached to the document. Basing the branch on cec6be3 keeps that change out of these PRs. It still needs sorting out before 9k.school next updates the design system.

Checks

  • npm run check passes: 1,132 tests, format, lint, types, library, Storybook and showcase builds.
  • New tests cover the URL encoding (Arabic included), new tab with no referrer, the heading, the provider choice, the centred layout, and the footer's extra slot in both layouts.
  • Checked by eye in all three sites: light and dark themes, Arabic (right to left) and English, a 375px phone, and ismail9k.com's centred /links footer.

🤖 Generated with Claude Code

ismail9k and others added 2 commits October 26, 2026 12:49
I9kAskAi is a heading and pill links that open ChatGPT, Perplexity and
Claude in a new tab with a question about the site already typed in.
I9kFooter gains an `extra` slot, a row of its own between the columns
and the bottom bar, where the sites put it.

The ChatGPT, Perplexity and Claude logos join the icon set (simple-icons,
CC0; OpenAI's from simple-icons 11, before it was withdrawn).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ismail9k
ismail9k merged commit 53ad141 into main Oct 26, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant