Skip to content

loonghfut/siyuan-database-display

Repository files navigation

SiYuan Database Display Plugin

Display database attribute values of blocks, supporting 99% of blocks!

✨ Features

πŸ“Š Database Field Display

  • Comprehensive Support: Supports 99% of block types for database attribute display
  • Multi-field Types: Supports multiple select, number, date, text, asset, checkbox, phone, URL, email and other field types
  • Smart Filtering: Automatically filters empty values, null and undefined

πŸŽ›οΈ Field Display Control

  • Custom Display Fields: Configure which field types to display for document blocks and regular blocks separately
  • Field Hiding: Support hiding sensitive or unnecessary fields (such as passwords, private information, etc.)
  • Real-time Configuration: Settings take effect immediately after modification, no restart required

πŸ“… Date Time Formatting

  • Multiple Date Formats:
    • YYYY-MM-DD: 2023-12-25
    • YYYY/MM/DD: 2023/12/25
    • MM/DD/YYYY: 12/25/2023
    • DD/MM/YYYY: 25/12/2023
    • Full Format: Monday, December 25, 2023
    • Relative Time: 3 days ago, tomorrow, today
  • Time Display Control: Option to show or hide specific time (hour:minute:second)
  • Smart Timestamp Recognition: Automatically handles second-level and millisecond-level timestamps

β˜‘οΈ Checkbox Beautified Display

  • Emoji Style: βœ… / ❌ (default, intuitive and easy to understand)
  • Symbol Style: β˜‘ / ☐ (simple and professional)
  • Text Description: Selected / Unselected (clear and explicit)

🎨 Interface Beautification

  • Responsive Layout: Adapts to different screen sizes
  • Modern Design: Clean and beautiful user interface

βš™οΈ Settings Options

Field Display Settings

  • Document Block Display Fields: Set field types to display for document blocks
  • Regular Block Display Fields: Set field types to display for regular blocks
  • Hidden Field Names: Set specific field names to hide (comma-separated)

Display Format Settings

  • Date Display Format: Choose the display format for date fields
  • Show Time: Control whether to include specific time in dates
  • Checkbox Display Style: Choose the display style for checkboxes

πŸš€ Usage

  1. Install Plugin: Download and install from SiYuan plugin marketplace
  2. Basic Usage: The plugin automatically displays database attributes of blocks
  3. Custom Settings:
    • Open plugin settings page
    • Configure display fields and formats as needed
    • Set fields to hide
    • Choose preferred date and checkbox display styles

πŸ“ Configuration Examples

Hide Sensitive Fields

password,private_info,internal_notes,confidential

Custom Display Fields

mSelect,text,date,checkbox

πŸ› οΈ Technical Features

  • TypeScript: Full type safety support
  • Modular Design: Clear code structure and component separation
  • Error Handling: Graceful error handling and user feedback
  • Performance Optimization: Efficient data processing and DOM operations
  • Extensibility: Easy to add new field types and display styles

πŸ“‹ Changelog

Latest Version

  • βœ… Added field hiding functionality
  • βœ… Optimized date time display, fixed time offset issues
  • βœ… Added multiple date format support
  • βœ… Beautified checkbox display effects
  • βœ… Enhanced settings page configuration options
  • βœ… Improved error handling and user feedback

Completed Features

  • βœ… Basic database attribute display functionality
  • βœ… Support for 99% of block types
  • βœ… Beautified display interface
  • βœ… Field type filtering
  • βœ… Real-time configuration updates
  • βœ… Multiple display format support

πŸ› Issue Reporting

If you find any issues or have feature suggestions, please:

  1. Submit detailed problem descriptions and reproduction steps
  2. Or provide feedback in the SiYuan community

πŸ™ Acknowledgments

  • Thanks to A-chuan for the design inspiration from the tsundoku theme
  • Thanks to the SiYuan community for support

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published