Skip to content

お気に入り機能を追加#16

Merged
MurakawaTakuya merged 22 commits intomainfrom
add-favorite-folders
Feb 15, 2026
Merged

お気に入り機能を追加#16
MurakawaTakuya merged 22 commits intomainfrom
add-favorite-folders

Conversation

@MurakawaTakuya
Copy link
Owner

No description provided.

@MurakawaTakuya MurakawaTakuya self-assigned this Feb 15, 2026
@gemini-code-assist
Copy link

Summary of Changes

Hello @MurakawaTakuya, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

このプルリクエストは、ユーザーが論文をお気に入りとして保存し、カスタムフォルダで整理できる包括的なお気に入り機能を追加します。これには、お気に入りやフォルダを管理するための新しいバックエンドAPI、専用のお気に入りページ、および既存のUIへのシームレスな統合が含まれます。これにより、ユーザーは興味のある論文をより効率的に追跡し、管理できるようになります。

Highlights

  • お気に入り機能の追加: ユーザーが論文をお気に入りとして保存し、後で簡単にアクセスできるようになりました。
  • フォルダ管理機能: お気に入りの論文をカスタムフォルダに整理できるようになり、フォルダの作成、名前変更、および論文の追加/削除が可能です。
  • 新しいAPIエンドポイント: お気に入り(/api/favorites)とフォルダ(/api/folders)を管理するためのRESTful APIエンドポイントが追加されました。
  • UI/UXの改善: お気に入りページ、サイドバーのナビゲーション、および論文テーブルに、お気に入り機能とフォルダ管理のための新しいUI要素が統合されました。
  • トースト通知の導入: ユーザー操作(お気に入りの追加/削除など)に対するフィードバックを提供するために、sonnerライブラリを使用したトースト通知が追加されました。

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • package-lock.json
    • sonnerパッケージの依存関係が追加されました。
  • package.json
    • sonnerパッケージが依存関係として追加されました。
  • src/app/api/favorites/[id]/route.ts
    • 特定のお気に入りを削除するためのDELETE APIルートが追加されました。
  • src/app/api/favorites/route.ts
    • お気に入りリストを取得するためのGET APIルートと、お気に入りを追加するためのPOST APIルートが追加されました。
  • src/app/api/folders/[id]/route.ts
    • 特定のフォルダの名前を変更するためのPATCH APIルートが追加されました。
  • src/app/api/folders/route.ts
    • フォルダリストを取得するためのGET APIルートと、フォルダを作成するためのPOST APIルートが追加されました。
  • src/app/favorites/page.tsx
    • お気に入りの論文を表示および管理するための新しいページが追加されました。
  • src/app/layout.tsx
    • sonnerのToasterコンポーネントが追加され、AuthContextのネストが修正されました。
  • src/app/page.tsx
    • ヘッダーの幅とメインタイトルのマージンがレスポンシブデザインのために調整されました。
  • src/components/app-sidebar.tsx
    • サイドバーのナビゲーションが更新され、「保存した論文」セクションと、お気に入りフォルダへのリンクが追加されました。
  • src/components/categorization-results.tsx
    • CollapsibleTriggerにカーソルポインターのスタイルが追加されました。
  • src/components/favorite-button.tsx
    • 論文をお気に入りに追加/削除し、フォルダを管理するための新しいコンポーネントが追加されました。
  • src/components/introduction.tsx
    • 紹介文のカンファレンスリストが更新されました(ECCVがWACVに変更されました)。
  • src/components/papers-table.tsx
    • FavoriteButtonコンポーネントとuseFavoritesフックが統合され、テーブルの列幅が調整されました。
  • src/components/search-stepper.tsx
    • 検索ステッパーのアイテムとセパレーターがレスポンシブデザインに対応するように調整されました。
  • src/components/ui/animated-gradient-text.tsx
    • アニメーショングラデーションテキストの色が調整されました。
  • src/components/ui/sonner.tsx
    • トースト通知を表示するためのsonner Toasterコンポーネントが追加されました。
  • src/db/schema.ts
    • データベーススキーマにfoldersテーブルとfavoritesテーブルが追加されました。
  • src/hooks/use-favorites.ts
    • お気に入りの論文とフォルダを管理するための新しいカスタムフックが追加されました。
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a comprehensive favorites and folder management system. Key changes include adding new API endpoints for managing user favorites (GET, POST, DELETE) and folders (GET, POST, PATCH), along with corresponding database schema updates for folders and favorites tables. A new FavoritesPage was created to display and manage user's saved papers, leveraging a new useFavorites hook for data fetching and state management, which also includes optimistic updates and toast notifications using the newly integrated sonner library. The sidebar (AppSidebar) was updated to dynamically list user-created folders, and a FavoriteButton component was added to the PapersTable for in-line favorite management, including adding to folders and creating new ones. Minor UI adjustments were made to the home page and categorization results for responsiveness and user experience. Review comments highlighted several issues: incorrect type definitions for params in API routes, a redundant AuthProvider in the root layout, a security vulnerability in the POST /api/favorites endpoint where folderId ownership was not validated, a bug in the useFavorites hook's optimistic update rollback logic where stale state was referenced, and an inconsistency in folder name validation between POST /api/folders and PATCH /api/folders/[id]. Additionally, it was suggested that folderIdParam should return an empty array for invalid IDs on the favorites page, an unused pathname variable should be removed, and a unique constraint should be added to the favorites table in the database schema to ensure data integrity.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds a comprehensive favorites/bookmarking feature to the application, allowing users to save papers and organize them into folders. The feature includes optimistic UI updates, folder management capabilities, and integration throughout the existing paper browsing experience.

Changes:

  • Added database schema for favorites and folders tables with appropriate indexes
  • Implemented API routes for CRUD operations on favorites and folders
  • Created a custom React hook (useFavorites) with optimistic update patterns
  • Added UI components for favorite management including a popover-based folder selector
  • Integrated favorites functionality into existing paper tables and sidebar navigation

Reviewed changes

Copilot reviewed 19 out of 20 changed files in this pull request and generated 18 comments.

Show a summary per file
File Description
src/db/schema.ts Defines database schema for folders and favorites tables with foreign key relationships
src/hooks/use-favorites.ts Custom hook managing favorites state with optimistic updates and API interactions
src/components/favorite-button.tsx Popover UI component for adding/removing favorites and managing folder assignments
src/components/ui/sonner.tsx Toast notification component wrapper for user feedback
src/app/api/folders/route.ts API endpoints for fetching and creating folders
src/app/api/folders/[id]/route.ts API endpoint for renaming folders
src/app/api/favorites/route.ts API endpoints for fetching and creating favorites
src/app/api/favorites/[id]/route.ts API endpoint for deleting favorites
src/app/favorites/page.tsx Page component displaying favorited papers with folder filtering and rename functionality
src/components/app-sidebar.tsx Updated sidebar to include favorites navigation with dynamic folder list
src/components/papers-table.tsx Integrated favorite button into paper listings
src/app/layout.tsx Added toast notification provider (with duplicate AuthProvider issue)
src/app/page.tsx Responsive layout adjustments for mobile displays
src/components/search-stepper.tsx Responsive design improvements for mobile stepper
src/components/categorization-results.tsx Added cursor-pointer class to collapsible triggers
src/components/introduction.tsx Updated conference name from ECCV to WACV
src/components/ui/animated-gradient-text.tsx Adjusted gradient colors for better visual appearance
package.json Added sonner toast library dependency

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@MurakawaTakuya MurakawaTakuya merged commit 687355d into main Feb 15, 2026
1 check 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.

2 participants