Skip to content

armgit / mimik

Public Imported from GitHub
0

🎬 A browser extension and desktop app that turns your clicks into step-by-step guides with annotated screenshots πŸ“–

refactor(desktop): build the shortcut clear button from Button

Luis Ortiz029e8550fa58
diff --git a/apps/desktop/src/renderer/ShortcutRecorder.tsx b/apps/desktop/src/renderer/ShortcutRecorder.tsx
index 664bcda..6702643 100644
--- a/apps/desktop/src/renderer/ShortcutRecorder.tsx
+++ b/apps/desktop/src/renderer/ShortcutRecorder.tsx
@@ -1,4 +1,5 @@
import { i18n } from '@mimik/core/env';
+import { Button } from '@mimik/ui/components/ui/button';
import { X } from 'lucide-react';
import { useState } from 'react';
@@ -48,15 +49,17 @@ export default function ShortcutRecorder({ label, value, onChange }: ShortcutRec
>
{listening ? i18n.t('desktop_shortcutPress') : (value ?? 'β€”')}
</button>
- <button
+ <Button
type="button"
+ variant="outline"
+ size="icon"
aria-label={i18n.t('desktop_shortcutClear')}
onClick={() => onChange(null)}
disabled={!value}
- className="flex size-9 items-center justify-center rounded-[10px] border border-border bg-card text-muted-foreground hover:text-accent disabled:opacity-35"
+ className="rounded-lg text-muted-foreground hover:text-accent"
>
<X size={15} />
- </button>
+ </Button>
</div>
);
}