Skip to content

Commit 7deeb50

Browse files
committed
improvement: UI consolidation
1 parent 6f54c47 commit 7deeb50

File tree

74 files changed

+349
-432
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+349
-432
lines changed

apps/sim/app/(landing)/careers/page.tsx

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
'use client'
22

33
import { useRef, useState } from 'react'
4-
import { Loader2, X } from 'lucide-react'
4+
import { X } from 'lucide-react'
55
import { Button } from '@/components/ui/button'
66
import { Input } from '@/components/ui/input'
77
import { Label } from '@/components/ui/label'
@@ -499,16 +499,11 @@ export default function CareersPage() {
499499
className='min-w-[200px] rounded-[10px] border border-[#6F3DFA] bg-gradient-to-b from-[#8357FF] to-[#6F3DFA] text-white shadow-[inset_0_2px_4px_0_#9B77FF] transition-all duration-300 hover:opacity-90 disabled:opacity-50'
500500
size='lg'
501501
>
502-
{isSubmitting ? (
503-
<>
504-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
505-
Submitting...
506-
</>
507-
) : submitStatus === 'success' ? (
508-
'Submitted'
509-
) : (
510-
'Submit Application'
511-
)}
502+
{isSubmitting
503+
? 'Submitting...'
504+
: submitStatus === 'success'
505+
? 'Submitted'
506+
: 'Submit Application'}
512507
</Button>
513508
</div>
514509
</form>

apps/sim/app/_styles/globals.css

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99
:root {
1010
--sidebar-width: 232px;
11-
--panel-width: 244px;
11+
--panel-width: 260px;
1212
--toolbar-triggers-height: 300px;
1313
--editor-connections-height: 200px;
1414
--terminal-height: 196px;
@@ -181,10 +181,10 @@
181181
--surface-1: #1e1e1e;
182182
--surface-2: #232323;
183183
--surface-3: #242424;
184-
--surface-4: #282828;
184+
--surface-4: #292929;
185185
--border: #2c2c2c;
186186
--surface-5: #363636;
187-
--surface-11: #3d3d3d;
187+
--border-1: #3d3d3d;
188188
--surface-12: #434343;
189189
--surface-13: #454545;
190190
--surface-14: #4a4a4a;
@@ -203,7 +203,7 @@
203203

204204
/* Borders / dividers */
205205

206-
--border-strong: #303030;
206+
/* --border-strong: #303030; */
207207
--divider: #393939;
208208
--border-muted: #424242;
209209
--border-success: #575757;
@@ -224,7 +224,7 @@
224224
--font-weight-semibold: 550;
225225

226226
/* RGB for opacity usage */
227-
--surface-4-rgb: 40 40 40;
227+
--surface-4-rgb: 41 41 41;
228228
--surface-5-rgb: 39 39 39;
229229
--surface-7-rgb: 44 44 44;
230230
--surface-9-rgb: 54 54 54;
@@ -606,7 +606,7 @@ input[type="search"]::-ms-clear {
606606
}
607607

608608
html[data-panel-active-tab="copilot"] .panel-container [data-tab-button="copilot"] {
609-
background-color: var(--surface-11) !important;
609+
background-color: var(--border-1) !important;
610610
color: var(--text-primary) !important;
611611
}
612612
html[data-panel-active-tab="copilot"] .panel-container [data-tab-button="toolbar"],
@@ -616,7 +616,7 @@ input[type="search"]::-ms-clear {
616616
}
617617

618618
html[data-panel-active-tab="toolbar"] .panel-container [data-tab-button="toolbar"] {
619-
background-color: var(--surface-11) !important;
619+
background-color: var(--border-1) !important;
620620
color: var(--text-primary) !important;
621621
}
622622
html[data-panel-active-tab="toolbar"] .panel-container [data-tab-button="copilot"],
@@ -626,7 +626,7 @@ input[type="search"]::-ms-clear {
626626
}
627627

628628
html[data-panel-active-tab="editor"] .panel-container [data-tab-button="editor"] {
629-
background-color: var(--surface-11) !important;
629+
background-color: var(--border-1) !important;
630630
color: var(--text-primary) !important;
631631
}
632632
html[data-panel-active-tab="editor"] .panel-container [data-tab-button="copilot"],

apps/sim/app/chat/components/auth/email/email-auth.tsx

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
'use client'
22

33
import { type KeyboardEvent, useEffect, useState } from 'react'
4-
import { Loader2 } from 'lucide-react'
54
import { Button } from '@/components/ui/button'
65
import { Input } from '@/components/ui/input'
76
import { InputOTP, InputOTPGroup, InputOTPSlot } from '@/components/ui/input-otp'
@@ -299,14 +298,7 @@ export default function EmailAuth({
299298
className={`${buttonClass} flex w-full items-center justify-center gap-2 rounded-[10px] border font-medium text-[15px] text-white transition-all duration-200`}
300299
disabled={isSendingOtp}
301300
>
302-
{isSendingOtp ? (
303-
<>
304-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
305-
Sending Code...
306-
</>
307-
) : (
308-
'Continue'
309-
)}
301+
{isSendingOtp ? 'Sending Code...' : 'Continue'}
310302
</Button>
311303
</form>
312304
) : (

apps/sim/app/invite/components/status-card.tsx

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -162,14 +162,7 @@ export function InviteStatusCard({
162162
onClick={action.onClick}
163163
disabled={action.disabled || action.loading}
164164
>
165-
{action.loading ? (
166-
<>
167-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
168-
{action.label}...
169-
</>
170-
) : (
171-
action.label
172-
)}
165+
{action.loading ? `${action.label}...` : action.label}
173166
</Button>
174167
))}
175168
</div>

apps/sim/app/layout.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ export default function RootLayout({ children }: { children: React.ReactNode })
8484
var panelWidth = panelState && panelState.panelWidth;
8585
var maxPanelWidth = window.innerWidth * 0.4;
8686
87-
if (panelWidth >= 244 && panelWidth <= maxPanelWidth) {
87+
if (panelWidth >= 260 && panelWidth <= maxPanelWidth) {
8888
document.documentElement.style.setProperty('--panel-width', panelWidth + 'px');
8989
} else if (panelWidth > maxPanelWidth) {
9090
document.documentElement.style.setProperty('--panel-width', maxPanelWidth + 'px');

apps/sim/app/playground/page.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -317,10 +317,10 @@ export default function PlaygroundPage() {
317317
</PopoverContent>
318318
</Popover>
319319
</VariantRow>
320-
<VariantRow label='primary variant'>
321-
<Popover variant='primary'>
320+
<VariantRow label='secondary variant'>
321+
<Popover variant='secondary'>
322322
<PopoverTrigger asChild>
323-
<Button variant='primary'>Primary Popover</Button>
323+
<Button variant='secondary'>Secondary Popover</Button>
324324
</PopoverTrigger>
325325
<PopoverContent>
326326
<PopoverItem>Item 1</PopoverItem>

apps/sim/app/unsubscribe/unsubscribe.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -294,14 +294,14 @@ function UnsubscribeContent() {
294294
variant='destructive'
295295
className='w-full'
296296
>
297-
{processing ? (
298-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
299-
) : data?.currentPreferences.unsubscribeAll ? (
297+
{data?.currentPreferences.unsubscribeAll ? (
300298
<CheckCircle className='mr-2 h-4 w-4' />
301299
) : null}
302-
{data?.currentPreferences.unsubscribeAll
303-
? 'Unsubscribed from All Emails'
304-
: 'Unsubscribe from All Marketing Emails'}
300+
{processing
301+
? 'Unsubscribing...'
302+
: data?.currentPreferences.unsubscribeAll
303+
? 'Unsubscribed from All Emails'
304+
: 'Unsubscribe from All Marketing Emails'}
305305
</Button>
306306

307307
<div className='text-center text-muted-foreground text-sm'>

apps/sim/app/workspace/[workspaceId]/knowledge/[id]/[documentId]/components/create-chunk-modal/create-chunk-modal.tsx

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
'use client'
22

33
import { useRef, useState } from 'react'
4-
import { AlertCircle, Loader2 } from 'lucide-react'
4+
import { AlertCircle } from 'lucide-react'
55
import {
66
Button,
77
Label,
@@ -162,14 +162,7 @@ export function CreateChunkModal({
162162
type='button'
163163
disabled={!isFormValid || isCreating}
164164
>
165-
{isCreating ? (
166-
<>
167-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
168-
Creating...
169-
</>
170-
) : (
171-
'Create Chunk'
172-
)}
165+
{isCreating ? 'Creating...' : 'Create Chunk'}
173166
</Button>
174167
</ModalFooter>
175168
</form>

apps/sim/app/workspace/[workspaceId]/knowledge/[id]/[documentId]/components/document-tags-modal/document-tags-modal.tsx

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
'use client'
22

33
import { useCallback, useEffect, useState } from 'react'
4-
import { Loader2 } from 'lucide-react'
54
import {
65
Button,
76
Combobox,
@@ -755,14 +754,7 @@ export function DocumentTagsModal({
755754
))
756755
}
757756
>
758-
{isSavingTag ? (
759-
<>
760-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
761-
Creating...
762-
</>
763-
) : (
764-
'Create Tag'
765-
)}
757+
{isSavingTag ? 'Creating...' : 'Create Tag'}
766758
</Button>
767759
</div>
768760
</div>

apps/sim/app/workspace/[workspaceId]/knowledge/[id]/[documentId]/components/edit-chunk-modal/edit-chunk-modal.tsx

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import { useEffect, useState } from 'react'
44
import * as DialogPrimitive from '@radix-ui/react-dialog'
5-
import { AlertCircle, ChevronDown, ChevronUp, Loader2, X } from 'lucide-react'
5+
import { AlertCircle, ChevronDown, ChevronUp, X } from 'lucide-react'
66
import {
77
Button,
88
Label,
@@ -280,14 +280,7 @@ export function EditChunkModal({
280280
type='button'
281281
disabled={!isFormValid || isSaving || !hasUnsavedChanges || isNavigating}
282282
>
283-
{isSaving ? (
284-
<>
285-
<Loader2 className='mr-2 h-4 w-4 animate-spin' />
286-
Saving...
287-
</>
288-
) : (
289-
'Save'
290-
)}
283+
{isSaving ? 'Saving...' : 'Save'}
291284
</Button>
292285
)}
293286
</ModalFooter>

0 commit comments

Comments
 (0)