4sp-dv 1.1.1 → 1.1.2

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.
@@ -6,7 +6,7 @@
6
6
  <title>4SP - VERSION 5 CLIENT</title>
7
7
  <link rel="icon" type="image/png" href="https://cdn.jsdelivr.net/npm/4sp-dv@latest/images/logo.png">
8
8
 
9
- <base href="https://cdn.jsdelivr.net/npm/4sp-dv@1.0.44/logged-in/">
9
+ <base href="https://cdn.jsdelivr.net/npm/4sp-dv@1.1.2/logged-in/">
10
10
  <script src="https://cdn.tailwindcss.com"></script>
11
11
  <link href="https://fonts.googleapis.com/css2?family=Geist:wght@100..900&display=swap" rel="stylesheet">
12
12
 
@@ -851,7 +851,7 @@
851
851
  const displayUsername = document.getElementById('display-username');
852
852
  const displayEmail = document.getElementById('display-email');
853
853
 
854
- const BASE_URL = 'https://cdn.jsdelivr.net/npm/4sp-dv@1.0.44/logged-in/';
854
+ const BASE_URL = 'https://cdn.jsdelivr.net/npm/4sp-dv@1.1.2/logged-in/';
855
855
 
856
856
  // Preload Logos
857
857
  const preloadImgs = [
@@ -129,9 +129,7 @@
129
129
 
130
130
  <div class="mb-6">
131
131
  <label class="block text-gray-500 text-xs uppercase tracking-wider mb-2 font-semibold">Student Email</label>
132
- <div id="email-display" class="w-full p-3 bg-black border border-[#333] rounded-xl text-gray-400 font-mono text-sm truncate">
133
- Detecting user...
134
- </div>
132
+ <input type="email" id="email-input" class="input-text-style font-mono text-sm" placeholder="student@school.edu">
135
133
  </div>
136
134
 
137
135
  <div class="mb-6">
@@ -155,7 +153,7 @@
155
153
  </div>
156
154
 
157
155
  <script>
158
- const emailDisplay = document.getElementById('email-display');
156
+ const emailInput = document.getElementById('email-input');
159
157
  const urlInput = document.getElementById('url-input');
160
158
  const checkBtn = document.getElementById('check-btn');
161
159
  const resultBox = document.getElementById('result-box');
@@ -163,10 +161,9 @@
163
161
  const SECURLY_SERVER = 'https://useast-www.securly.com';
164
162
  const CORS_PROXY = 'https://corsproxy.io/?';
165
163
 
166
- let userEmail = null;
167
-
168
164
  // --- AUTH DETECTION ---
169
165
  function detectUser() {
166
+ let userEmail = '';
170
167
  // 1. Try injected window.currentUser (from 4simpleproblems_v5.html)
171
168
  if (window.currentUser && window.currentUser.email) {
172
169
  userEmail = window.currentUser.email;
@@ -180,13 +177,14 @@
180
177
  userEmail = 'client@4sp'; // Default for testing/unauthed
181
178
  }
182
179
 
183
- emailDisplay.textContent = userEmail;
180
+ emailInput.value = userEmail;
184
181
  }
185
182
 
186
183
  // --- CHECK LOGIC ---
187
184
  async function checkStatus() {
188
185
  const rawUrl = urlInput.value.trim();
189
- if (!rawUrl) return;
186
+ const userEmail = emailInput.value.trim();
187
+ if (!rawUrl || !userEmail) return;
190
188
 
191
189
  // Normalize URL
192
190
  let targetUrl = rawUrl;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "4sp-dv",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "homepage": "https://github.com/v5-4simpleproblems/v5-4simpleproblems-dv#readme",