Add SQLite database preview support to Peek#45846
Add SQLite database preview support to Peek#45846thomastv wants to merge 1 commit intomicrosoft:mainfrom
Conversation
|
|
||
| public IArchivePreviewer? ArchivePreviewer => Previewer as IArchivePreviewer; | ||
|
|
||
| public ISQLitePreviewer? SQLitePreviewer => Previewer as ISQLitePreviewer; |
Check failure
Code scanning / check-spelling
Unrecognized Spelling Error
|
|
||
| public IArchivePreviewer? ArchivePreviewer => Previewer as IArchivePreviewer; | ||
|
|
||
| public ISQLitePreviewer? SQLitePreviewer => Previewer as ISQLitePreviewer; |
Check failure
Code scanning / check-spelling
Unrecognized Spelling Error
| @@ -0,0 +1,18 @@ | |||
| // Copyright (c) Microsoft Corporation | |||
Check failure
Code scanning / check-spelling
Check File Path Error
|
|
||
| namespace Peek.FilePreviewer.Previewers.Interfaces | ||
| { | ||
| public interface ISQLitePreviewer : IPreviewer, IPreviewTarget, IDisposable |
Check failure
Code scanning / check-spelling
Unrecognized Spelling Error
|
|
||
| namespace Peek.FilePreviewer.Previewers.SQLitePreviewer | ||
| { | ||
| public partial class SQLitePreviewer : ObservableObject, ISQLitePreviewer |
Check failure
Code scanning / check-spelling
Unrecognized Spelling Error
@check-spelling-bot Report🔴 Please reviewSee the 📂 files view, the 📜action log, or 📝 job summary for details.Unrecognized words (1)ISQ To accept these unrecognized words as correct, you could run the following commands... in a clone of the git@github.com:thomastv/PowerToys.git repository curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/c635c2f3f714eec2fcf27b643a1919b9a811ef2e/apply.pl' |
perl - 'https://github.com/microsoft/PowerToys/actions/runs/22515739657/attempts/1' &&
git commit -m 'Update check-spelling metadata'Errors and Warnings ❌ (2)See the 📂 files view, the 📜action log, or 📝 job summary for details.
See ❌ Event descriptions for more information. If the flagged items are 🤯 false positivesIf items relate to a ...
|
Summary of the Pull Request
This PR adds SQLite database file preview support to the Peek utility, resolving issue #45757 . Three new model classes (SQLiteTableInfo, SQLiteColumnInfo, ISQLitePreviewer) and a core SQLitePreviewer class were added to read .db, .sqlite, and .sqlite3 files read-only using Microsoft.Data.Sqlite, fetching table schema via PRAGMA table_info and up to 200 rows per table. A new SQLiteControl XAML control presents the data in a two-pane layout — a tree view listing all tables on the left and a data grid showing columns and rows on the right, with intelligent column sizing that stretches the last column when space allows and falls back to horizontal scrolling for wide tables. The previewer was wired into the existing previewerFactory and FilePreview host, and three localizable strings were added to Resources.resw.
PR Checklist
Detailed Description of the Pull Request / Additional comments
Validation Steps Performed