Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
30f10cfc36 | ||
|
|
a6caa88d9c |
No files matched your search
@@ -8,6 +8,21 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and
|
||||
|
||||
No unreleased changes at this time. Future work tracked in `docs/ROADMAP.md` under "Beyond Phase 3".
|
||||
|
||||
## [1.4.3] — 2026-05-14
|
||||
|
||||
### Fixed
|
||||
|
||||
- **Toast close button (`×`) did nothing on click/tap** on both desktop and mobile. `sonner@1.7.4`'s toast root attached `r.target.setPointerCapture(r.pointerId)` unconditionally on `pointerdown`, and combined with React 19's new container-root event delegation, the pointer-capture quirk swallowed the synthetic click event on the close button — so the bundled `dismiss()` handler never ran. The bug fired on both mouse and touch because the PointerEvent API is unified. Upgraded `sonner` `^1.7.0` → `^2.0.7`, which rewrote pointer/swipe handling and ships first-class React 19 support. `<Toaster>` props (`position`, `theme`, `richColors`, `closeButton`, `toastOptions.classNames`) and the `toast.success/warning/error/info` call sites are API-compatible — no code changes needed beyond the version bump.
|
||||
|
||||
### Added
|
||||
|
||||
- **`docs/tested-viewports.md`** — the maintainer's manual device test matrix (BlackBerry Z30 / Galaxy S9+ / Pixel 3/4/7 / iPhone SE/12/14 Pro/XR/Pro Max / iPad / BlackBerry PlayBook). Documents Nokia Lumia 520 (320×533) as a known limitation below the recommended `360×640` minimum. README EN + VI link to it.
|
||||
- **Touch hit-area expansion on the toast close button.** A `::after` pseudo gives an effective ~36–40px tap target (visible size stays at sonner's 20px default), plus `touch-action: manipulation` to drop the 300ms tap delay on touch devices. Defensive — sonner v2 already fixes the underlying click — but a free mobile UX win.
|
||||
|
||||
### Dependencies
|
||||
|
||||
- Bumped `sonner` `^1.7.0` → `^2.0.7` (MIT). THIRD-PARTY.md updated.
|
||||
|
||||
## [1.4.2] — 2026-05-14
|
||||
|
||||
### Added
|
||||
|
||||
@@ -42,7 +42,7 @@ JSONPrism is a refracting tool for developers. It takes a single JSON input and
|
||||
- **Smart shape detection** — recognizes flat objects, arrays of objects, scalars; suggests the best target format.
|
||||
- **Per-format options** — pretty-print, indentation, dialect (for SQL), alignment (for Markdown), and more.
|
||||
- **Dark + light themes** — Prism Spectrum palette with violet / cyan / amber / rose accents.
|
||||
- **Responsive — designed for viewports ≥ 360 × 640.** Smaller screens still work but may feel cramped; on mobile, Input and Output use a Tabs UI to give each panel full height.
|
||||
- **Responsive — designed for viewports ≥ 360 × 640.** Smaller screens still work but may feel cramped; on mobile, Input and Output use a Tabs UI to give each panel full height. See [`docs/tested-viewports.md`](docs/tested-viewports.md) for the full device test matrix.
|
||||
- **EN + VI** — bilingual interface out of the box. More languages welcome.
|
||||
- **Tauri desktop build** — drag-and-drop file workflow, offline-first (Phase 2 milestone).
|
||||
|
||||
|
||||
+1
-1
@@ -42,7 +42,7 @@ JSONPrism là công cụ "tán sắc" cho developer. Nhận một JSON đầu v
|
||||
- **Phát hiện shape thông minh** — nhận diện flat object, mảng object, scalar; gợi ý format đích phù hợp.
|
||||
- **Tuỳ chọn theo từng format** — pretty-print, indentation, dialect (SQL), alignment (Markdown), v.v.
|
||||
- **Theme sáng/tối** — bảng màu Prism Spectrum với violet / cyan / amber / rose.
|
||||
- **Responsive — tối ưu cho viewport ≥ 360 × 640.** Màn hình nhỏ hơn vẫn dùng được nhưng có thể chật; trên mobile, Input và Output dùng Tabs UI để mỗi panel có toàn bộ chiều cao.
|
||||
- **Responsive — tối ưu cho viewport ≥ 360 × 640.** Màn hình nhỏ hơn vẫn dùng được nhưng có thể chật; trên mobile, Input và Output dùng Tabs UI để mỗi panel có toàn bộ chiều cao. Xem [`docs/tested-viewports.md`](docs/tested-viewports.md) cho ma trận thiết bị đã kiểm thử.
|
||||
- **Đa ngôn ngữ EN + VI** — sẵn sàng từ ngày đầu. Hoan nghênh thêm ngôn ngữ khác.
|
||||
- **Bản desktop Tauri** — drag-and-drop file, hoạt động offline (mốc Phase 2).
|
||||
|
||||
|
||||
+1
-1
@@ -31,7 +31,7 @@ the relevant notices. This file is a starting point.
|
||||
| `@radix-ui/react-switch` | ^1.1.0 | MIT | [radix-ui.com](https://www.radix-ui.com/) |
|
||||
| `@radix-ui/react-tabs` | ^1.1.0 | MIT | [radix-ui.com](https://www.radix-ui.com/) |
|
||||
| `lucide-react` | ^0.460.0 | ISC | [lucide.dev](https://lucide.dev/) |
|
||||
| `sonner` | ^1.7.0 | MIT | [sonner.emilkowal.ski](https://sonner.emilkowal.ski/) |
|
||||
| `sonner` | ^2.0.7 | MIT | [sonner.emilkowal.ski](https://sonner.emilkowal.ski/) |
|
||||
| `react-dropzone` | ^14.3.0 | MIT | [react-dropzone.js.org](https://react-dropzone.js.org/) |
|
||||
|
||||
The component patterns under `src/components/ui/` are generated from
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
# Tested viewports
|
||||
|
||||
JSONPrism's mobile and tablet rendering is verified across the devices below.
|
||||
|
||||
Status legend:
|
||||
|
||||
- ✅ Works as expected
|
||||
- ⚠️ Cramped but functional
|
||||
- ❌ Known limitation (typically below recommended minimum)
|
||||
|
||||
Recommended minimum viewport: **360 × 640**. Phones in landscape orientation are best-effort — see [recommendation](#recommendation).
|
||||
|
||||
## Test results (last verified 2026-05-14)
|
||||
|
||||
### Phones (portrait)
|
||||
|
||||
| Device | Viewport | Status | Notes |
|
||||
| ------------------------------------------------ | --------- | ------ | ------------------------------ |
|
||||
| BlackBerry Z30 / Samsung Galaxy Note 3 / Nexus 5 | 360 × 640 | ✅ | Minimum recommended viewport |
|
||||
| Samsung Galaxy S9+ | 320 × 658 | ✅ | Below recommended width, works |
|
||||
| Pixel 4 | 353 × 745 | ✅ | |
|
||||
| Pixel 3 | 393 × 786 | ✅ | |
|
||||
| iPhone SE (2nd/3rd gen) | 375 × 667 | ✅ | |
|
||||
| iPhone 12 Pro | 390 × 844 | ✅ | |
|
||||
| iPhone 14 Pro | 393 × 852 | ✅ | Verified on real device |
|
||||
| iPhone XR | 414 × 896 | ✅ | |
|
||||
| Pixel 7 | 412 × 915 | ✅ | |
|
||||
| iPhone 14 Pro Max | 420 × 932 | ✅ | |
|
||||
|
||||
### Tablets
|
||||
|
||||
| Device | Viewport | Status | Notes |
|
||||
| ------------------- | ---------- | ------ | -------------------------------------------------- |
|
||||
| BlackBerry PlayBook | 600 × 1024 | ✅ | |
|
||||
| iPad | 768 × 1024 | ✅ | Side-by-side input/output kicks in at `md` (768px) |
|
||||
|
||||
### Known limitations
|
||||
|
||||
| Device | Viewport | Status | Notes |
|
||||
| -------------- | --------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| Nokia Lumia 520 | 320 × 533 | ❌ | Code editor disappears — viewport is below the recommended minimum height (640). Worth revisiting in a future round if demand surfaces. |
|
||||
|
||||
## Recommendation
|
||||
|
||||
- **Portrait orientation only on phones.** Landscape on phones (height < width) compresses each tab's content area to ~150–200px after chrome and is best-effort.
|
||||
- **Below recommended minimum (360 × 640)**: layout is functional but the code editor may collapse on very short heights (< 600px).
|
||||
|
||||
## How to retest
|
||||
|
||||
1. Open Chrome DevTools → "Toggle device toolbar" (Ctrl+Shift+M).
|
||||
2. Pick a device from the dropdown or set a custom viewport.
|
||||
3. Verify on the Home page: Header navigation visible, Input/Output Tabs accessible, FormatPicker trigger fits, no horizontal scroll on `<body>`.
|
||||
|
||||
Test results contributed by the maintainer. PRs welcome to expand the matrix.
|
||||
Generated
+6
-6
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "jsonprism",
|
||||
"version": "1.4.2",
|
||||
"version": "1.4.3",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "jsonprism",
|
||||
"version": "1.4.2",
|
||||
"version": "1.4.3",
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"@codemirror/lang-json": "^6.0.0",
|
||||
@@ -48,7 +48,7 @@
|
||||
"react-i18next": "^15.0.0",
|
||||
"react-router-dom": "^7.0.0",
|
||||
"smol-toml": "^1.3.0",
|
||||
"sonner": "^1.7.0",
|
||||
"sonner": "^2.0.7",
|
||||
"tailwind-merge": "^2.5.0",
|
||||
"zustand": "^5.0.0"
|
||||
},
|
||||
@@ -5603,9 +5603,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/sonner": {
|
||||
"version": "1.7.4",
|
||||
"resolved": "https://registry.npmjs.org/sonner/-/sonner-1.7.4.tgz",
|
||||
"integrity": "sha512-DIS8z4PfJRbIyfVFDVnK9rO3eYDtse4Omcm6bt0oEr5/jtLgysmjuBl1frJ9E/EQZrFmKx2A8m/s5s9CRXIzhw==",
|
||||
"version": "2.0.7",
|
||||
"resolved": "https://registry.npmjs.org/sonner/-/sonner-2.0.7.tgz",
|
||||
"integrity": "sha512-W6ZN4p58k8aDKA4XPcx2hpIQXBRAgyiWVkYhT7CvK6D3iAu7xjvVyhQHg2/iaKJZ1XVJ4r7XuwGL+WGEK37i9w==",
|
||||
"license": "MIT",
|
||||
"peerDependencies": {
|
||||
"react": "^18.0.0 || ^19.0.0 || ^19.0.0-rc",
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "jsonprism",
|
||||
"private": true,
|
||||
"version": "1.4.2",
|
||||
"version": "1.4.3",
|
||||
"type": "module",
|
||||
"description": "Disperse JSON into many formats — JSONL, CSV, YAML, XML, TOML, RESX, Markdown, SQL — fully client-side.",
|
||||
"author": "poli0981 <https://github.com/poli0981>",
|
||||
@@ -72,7 +72,7 @@
|
||||
"react-i18next": "^15.0.0",
|
||||
"react-router-dom": "^7.0.0",
|
||||
"smol-toml": "^1.3.0",
|
||||
"sonner": "^1.7.0",
|
||||
"sonner": "^2.0.7",
|
||||
"tailwind-merge": "^2.5.0",
|
||||
"zustand": "^5.0.0"
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "jsonprism"
|
||||
version = "1.4.2"
|
||||
version = "1.4.3"
|
||||
description = "Disperse JSON into many formats."
|
||||
authors = ["poli0981 <https://github.com/poli0981>"]
|
||||
license = "Apache-2.0"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"$schema": "https://schema.tauri.app/config/2",
|
||||
"productName": "JSONPrism",
|
||||
"version": "1.4.2",
|
||||
"version": "1.4.3",
|
||||
"identifier": "com.poli0981.jsonprism",
|
||||
"build": {
|
||||
"beforeDevCommand": "npm run dev",
|
||||
|
||||
@@ -198,4 +198,16 @@
|
||||
)
|
||||
1;
|
||||
}
|
||||
|
||||
/* Expand the Sonner close-button hit-test radius for touch.
|
||||
Visible size stays at sonner's 20px default; the ::after pseudo
|
||||
gives an effective ~36–40px tap target without changing layout. */
|
||||
[data-sonner-toaster] [data-close-button] {
|
||||
touch-action: manipulation;
|
||||
}
|
||||
[data-sonner-toaster] [data-close-button]::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
inset: -8px;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user