new calendar component
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 5/5
- 預估耗時
- 一週以上
- 新手友好度
- 25/100
- Issue 類型
- 功能
- 描述清晰度
- 基本清楚
- 活躍度
- 停滯
- 技術堆疊
- javascript, sql
研究方向
Start by comparing sqlpage/templates/chart.handlebars and map.handlebars, then read sqlpage/apexcharts.js and the chart/map component migrations for existing patterns. The proposal also points to the timeline component for color handling and the dynamic component for JSON loading. Done means implementing and integrating the calendar template and JavaScript, registering and documenting its properties, and adding the proposed tests and examples.
由索引模型根據 Issue 內容生成。
描述
SQLPage Calendar Component - Technical Design Document
Overview
The Calendar component will allow users to visualize and interact with time-based data in a familiar calendar interface. This document outlines the technical design and implementation strategy.
Component Properties
Top-Level Properties
-
title (optional)
- Text displayed above calendar
- Similar to chart/map components' title implementation
-
initial_view (optional)
- Controls initial calendar display format
- Options: "month", "week", "day"
- Defaults to "month"
-
height (optional)
- Sets fixed calendar height in pixels
- Similar to chart component's height property
- Defaults to auto-height
-
json_url (optional)
- Enables dynamic event loading
- Points to SQLPage JSON endpoint
- Similar to dynamic component's implementation
-
navigation (optional, boolean)
- Enables/disables date navigation controls
- Defaults to true
-
today (optional, boolean)
- Shows/hides "Today" button
- Defaults to true
Row-Level Properties
-
title (required)
- Event title text
- Displayed in calendar cells
-
start (required)
- Event start time
- Supports both date and datetime
-
end (optional)
- Event end time
- Defaults to start time for single-day events
-
color (optional)
- Event visual styling
- Uses SQLPage color system (like chart/timeline components)
-
url (optional)
- Click destination
- Similar to list component's link property
-
description and description_md (optional)
- Event details
- Shown in tooltip/popup
-
all_day (optional, boolean)
- Indicates full-day events
- Affects visual display
Technical Implementation Details
File Structure
Look at these existing files for reference patterns:
sqlpage/templates/chart.handlebars- For component template structuresqlpage/apexcharts.js- For JavaScript initialization patternsexamples/official-site/sqlpage/migrations/- For component documentation
Required Changes
- Component Registration
- Location:
examples/official-site/sqlpage/migrations/ - New file:
XX_calendar.sql(XX = next number in sequence) - Purpose: Register component and document properties
- Reference: See how chart/map components are documented
- Template Creation
- Location:
sqlpage/templates/ - New file:
calendar.handlebars - Structure:
- Card wrapper (like map component)
- Title section
- Calendar container
- Data embedding section
- Reference: Study
map.handlebarsfor structure
- JavaScript Integration
- Location:
sqlpage/ - New file:
calendar.js - Key sections:
- Initialization function
- Event handling
- View management
- Data processing
- Reference: Study
apexcharts.jsinitialization patterns
Integration Points
- JSON API Integration
- Uses existing JSON component
- Enables dynamic event loading
- Reference: Study dynamic component implementation
- SQLPage Core Integration
- Component registration
- Reference: Study how chart component is integrated
- Color System Integration
- Uses existing SQLPage color system
- Reference: Study timeline component's color handling
Testing Strategy
- Unit Tests
- Test date handling
- Validate property processing
- Integration Tests
- Add a spec file to the end to end tests
Documentation
- Component Documentation
- Usage examples
- Property descriptions
- Common patterns
- Location:
examples/official-site/sqlpage/migrations/XXX-calendar.sql
- Example Application
- Basic calendar
- Dynamic calendar
- Multi-calendar view
- Location: Create new directory in
examples/
- 主要語言
- Rust
- 星號
- 2.6k
- 分支
- 175
- 平均合併
- 14 小時 16 分鐘
- 30 天內合併 PR
- 43
環境準備
- 提供 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
sqlpage/SQLPage 的其他 Issue
-
enhancement
難度 2/5 1-3 小時 新手友好度 84/100
維護者通常 1 天內回覆
-
enhancement
難度 2/5 1-3 小時 新手友好度 65/100
sqlpage/SQLPage#1218 · 3 則留言 ·
維護者通常 1 天內回覆
-
There is no convenient way to reproduce issues可能已有人在做 @81reap 於 26 天前認領。 未關閉enhancement
sqlpage/SQLPage#1566 · 已指派 1 人 ·
維護者通常 1 天內回覆
-
Confusing sort interface可能已有人在做 @lovasoa 於 74 天前認領。 未關閉bug
難度 4/5 3-5 天 新手友好度 20/100
sqlpage/SQLPage#1442 · 3 則留言 ·
維護者通常 1 天內回覆
-
Mutation Testing Results :: Dead Code + Missing Tests可能重新可做 @81reap 於 61 天前認領,目前沒有進行中的 PR。 未關閉
sqlpage/SQLPage#1396 · 5 則留言 · 已指派 1 人 ·
維護者通常 1 天內回覆
相似的 Issue
-
CI/CD ignore-for-release
難度 2/5 1-3 小時 新手友好度 70/100
eclipse-ankaios/ankaios#844 ·
-
難度 2/5 1-3 小時 新手友好度 82/100
維護者通常 1 天內回覆
-
std: `SliceIndex<str>` missing for `std::ops` ranges, so generic `R: SliceIndex<str>` bounds fail未關閉
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 70/100
symposium-dev/symposium#530 ·
維護者通常 5 天內回覆
-
難度 2/5 1-3 小時 新手友好度 76/100
維護者通常 1 天內回覆