Skip to content

Commit

Permalink
Fix button types
Browse files Browse the repository at this point in the history
  • Loading branch information
istarkov committed Sep 23, 2024
1 parent 4f47271 commit c6e8abc
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 1 deletion.
1 change: 1 addition & 0 deletions apps/builder/app/builder/features/topbar/add-domain.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ export const AddDomain = ({
<Button
color={"dark"}
prefix={<CustomCodeIcon />}
type="button"
onClick={onExportClick}
>
Export
Expand Down
1 change: 1 addition & 0 deletions apps/builder/app/builder/features/topbar/domains.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ const CopyToClipboard = (props: { text: string }) => {
return (
<Tooltip content={"Copy to clipboard"}>
<NestedInputButton
type="button"
onClick={() => {
navigator.clipboard.writeText(props.text);
}}
Expand Down
1 change: 1 addition & 0 deletions apps/builder/app/builder/features/topbar/entri.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export const Entri = ({
disabled={isOpen}
color="neutral"
css={{ width: "100%", flexShrink: 0 }}
type="button"
onClick={() => {
showDialog();
}}
Expand Down
9 changes: 8 additions & 1 deletion apps/builder/app/builder/features/topbar/publish.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,7 @@ const PublishStatic = ({
content={isPublishInProgress ? "Preparing static site" : undefined}
>
<Button
type="button"
color="positive"
state={isPublishInProgress ? "pending" : undefined}
onClick={() => {
Expand Down Expand Up @@ -721,6 +722,7 @@ const ExportContent = (props: { projectId: Project["id"] }) => {

<Tooltip content={"Copy to clipboard"}>
<Button
type="button"
color="neutral"
onClick={() => {
navigator.clipboard.writeText(npxCommand);
Expand Down Expand Up @@ -762,6 +764,7 @@ const ExportContent = (props: { projectId: Project["id"] }) => {
/>
<Tooltip content={"Copy to clipboard"}>
<Button
type="button"
css={{ flexShrink: 0 }}
color="neutral"
onClick={() => {
Expand Down Expand Up @@ -835,7 +838,11 @@ export const PublishButton = ({ projectId }: PublishProps) => {
sideOffset={Number.parseFloat(rawTheme.spacing[5])}
>
<FloatingPanelPopoverTrigger asChild>
<Button disabled={isPublishEnabled === false} color="positive">
<Button
type="button"
disabled={isPublishEnabled === false}
color="positive"
>
Publish
</Button>
</FloatingPanelPopoverTrigger>
Expand Down

0 comments on commit c6e8abc

Please sign in to comment.