umanggarg Claude Sonnet 4.6 commited on
Commit
715a128
·
1 Parent(s): ca834c8

fix(sidebar): icon-only submit button — no more text overlap

Browse files

Replace 'Index Repo' text with arrow SVG icon (→), same pattern as
Linear/Raycast search inputs. Button is now a fixed 36px square so
the input placeholder has room to breathe. Spinner icon shown while indexing.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

ui/src/components/Sidebar.jsx CHANGED
@@ -306,8 +306,11 @@ export default function Sidebar({ repos, reposLoading, activeRepo, onSelectRepo,
306
  onChange={(e) => setUrl(e.target.value)}
307
  disabled={isIngesting}
308
  />
309
- <button className="btn" type="submit" disabled={isIngesting || !url.trim()}>
310
- {isIngesting ? "Indexing…" : "Index Repo"}
 
 
 
311
  </button>
312
  </form>
313
  {/* Curated repos — quick-start for new users */}
 
306
  onChange={(e) => setUrl(e.target.value)}
307
  disabled={isIngesting}
308
  />
309
+ <button className="btn" type="submit" disabled={isIngesting || !url.trim()} title="Index repository">
310
+ {isIngesting
311
+ ? <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2.5" strokeLinecap="round"><path d="M12 2v4M12 18v4M4.93 4.93l2.83 2.83M16.24 16.24l2.83 2.83M2 12h4M18 12h4M4.93 19.07l2.83-2.83M16.24 7.76l2.83-2.83"/></svg>
312
+ : <svg width="14" height="14" viewBox="0 0 16 16" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"><path d="M3 8h10M9 4l4 4-4 4"/></svg>
313
+ }
314
  </button>
315
  </form>
316
  {/* Curated repos — quick-start for new users */}
ui/src/index.css CHANGED
@@ -360,8 +360,8 @@ textarea:focus-visible {
360
  color: var(--text);
361
  font-size: 12px;
362
  font-family: var(--mono);
363
- /* Right padding must clear the "Index Repo" button (~90px wide + 10px gap) */
364
- padding: 11px 108px 11px 13px;
365
  outline: none;
366
  transition: border-color 180ms ease, box-shadow 180ms ease;
367
  width: 100%;
@@ -378,17 +378,18 @@ textarea:focus-visible {
378
  font-family: var(--mono);
379
  }
380
 
381
- /* Submit button — glass pill inside the input, white text always ───────── */
382
  .ingest-form .btn {
383
  position: absolute !important;
384
  right: 5px;
385
  top: 5px;
386
  bottom: 5px;
387
  height: auto;
388
- padding: 0 12px;
389
- font-size: 11px;
390
- font-weight: 600;
391
- letter-spacing: 0.02em;
 
392
  border-radius: 7px;
393
  color: #ffffff !important;
394
  /* Solid enough to read white text clearly, with top-edge shimmer */
 
360
  color: var(--text);
361
  font-size: 12px;
362
  font-family: var(--mono);
363
+ /* Right padding clears the icon button (36px) + gap */
364
+ padding: 11px 48px 11px 13px;
365
  outline: none;
366
  transition: border-color 180ms ease, box-shadow 180ms ease;
367
  width: 100%;
 
378
  font-family: var(--mono);
379
  }
380
 
381
+ /* Submit button — icon-only square button inside the input ─────────────── */
382
  .ingest-form .btn {
383
  position: absolute !important;
384
  right: 5px;
385
  top: 5px;
386
  bottom: 5px;
387
  height: auto;
388
+ width: 36px;
389
+ padding: 0;
390
+ display: flex;
391
+ align-items: center;
392
+ justify-content: center;
393
  border-radius: 7px;
394
  color: #ffffff !important;
395
  /* Solid enough to read white text clearly, with top-edge shimmer */