@bobfrankston/msgapidefs 0.1.3 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,11 @@
1
1
  {
2
2
  "permissions": {
3
3
  "allow": [
4
- "Bash(tsc:*)"
4
+ "Bash(tsc:*)",
5
+ "Bash(npm init:*)",
6
+ "Bash(npm install:*)",
7
+ "Bash(node cli.js:*)",
8
+ "Bash(node --version:*)"
5
9
  ],
6
10
  "deny": [],
7
11
  "ask": []
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bobfrankston/msgapidefs",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "TypeScript definitions for msgapi JavaScript API (msgview/msger)",
5
5
  "type": "module",
6
6
  "main": "./msgapidefs.js",
package/samples.html CHANGED
@@ -1,4 +1,3 @@
1
- <!DOCTYPE html>
2
1
  <html>
3
2
  <head>
4
3
  <meta charset="UTF-8">
@@ -72,6 +71,27 @@
72
71
  border-radius: 3px;
73
72
  font-family: 'Courier New', monospace;
74
73
  }
74
+ button.danger {
75
+ background: #dc3545;
76
+ }
77
+ button.danger:hover {
78
+ background: #c82333;
79
+ }
80
+ .small-text {
81
+ font-size: 12px;
82
+ color: #666;
83
+ margin-top: 10px;
84
+ }
85
+ .medium-text {
86
+ margin-top: 10px;
87
+ font-size: 13px;
88
+ }
89
+ h3.spaced {
90
+ margin-top: 20px;
91
+ }
92
+ ul.feature-list {
93
+ font-size: 13px;
94
+ }
75
95
  </style>
76
96
  </head>
77
97
  <body>
@@ -118,11 +138,11 @@
118
138
  <div class="section">
119
139
  <h2>Window Controls (⚠️ Currently Broken)</h2>
120
140
  <p>These buttons demonstrate the broken IPC window controls. They will log errors but not crash.</p>
121
- <button onclick="tryOK()" style="background: #dc3545;">Try OK (Logs Error)</button>
122
- <button onclick="tryCancel()" style="background: #dc3545;" class="secondary">Try Cancel (Logs Error)</button>
123
- <button onclick="tryClose()" style="background: #dc3545;" class="secondary">Try Close (Logs Error)</button>
141
+ <button onclick="tryOK()" class="danger">Try OK (Logs Error)</button>
142
+ <button onclick="tryCancel()" class="danger secondary">Try Cancel (Logs Error)</button>
143
+ <button onclick="tryClose()" class="danger secondary">Try Close (Logs Error)</button>
124
144
  <div id="outputControls" class="output">Click any button to see why window controls don't work</div>
125
- <p style="font-size: 12px; color: #666; margin-top: 10px;">
145
+ <p class="small-text">
126
146
  <strong>Why broken:</strong> wry 0.47.2 has a bug where window.ipc.postMessage() crashes with "InvalidUri" error.<br>
127
147
  <strong>Workarounds:</strong> Use CLI flags (-size, -title), F11 for fullscreen, X button to close, or Alt+F4.
128
148
  </p>
@@ -145,18 +165,18 @@
145
165
  <h2>Storage Location & PWA Support</h2>
146
166
  <p><strong>localStorage is saved to:</strong></p>
147
167
  <code>%LOCALAPPDATA%\Microsoft\Edge\User Data\WebView2\Default\Local Storage\leveldb\</code>
148
- <p style="margin-top: 10px; font-size: 13px;">
168
+ <p class="medium-text">
149
169
  Data persists across sessions and survives app restarts.
150
170
  Each URL origin has its own storage partition.
151
171
  </p>
152
172
  <button onclick="showStorageInfo()">Show Storage Info</button>
153
173
  <div id="output5" class="output">Click to see current storage info</div>
154
174
 
155
- <h3 style="margin-top: 20px;">PWA Support ✅</h3>
156
- <p style="font-size: 13px;">
175
+ <h3 class="spaced">PWA Support ✅</h3>
176
+ <p class="medium-text">
157
177
  msger supports Progressive Web Apps loaded via <code>-url</code>:
158
178
  </p>
159
- <ul style="font-size: 13px;">
179
+ <ul class="feature-list">
160
180
  <li>✅ <strong>Service Workers</strong> - Background sync, offline support</li>
161
181
  <li>✅ <strong>IndexedDB</strong> - Large data storage (GBs)</li>
162
182
  <li>✅ <strong>Cache API</strong> - Offline assets</li>
@@ -165,7 +185,7 @@
165
185
  <li>❌ <strong>Push Notifications</strong> - Platform dependent</li>
166
186
  <li>❌ <strong>"Install" UI</strong> - Already native window</li>
167
187
  </ul>
168
- <p style="font-size: 12px; color: #666;">
188
+ <p class="small-text">
169
189
  Example: <code>node cli.js -url https://your-pwa.app -detach</code>
170
190
  </p>
171
191
  </div>